Hi,
The add_to_cart_ajax view file is used on listings were the has_options information is generated because it is needed to know if be can display the add to cart button or the "choose options" button.
On the cart module, we don't know to know about that so there is no has_options variable already generated.
If you want to know if a product has options, you need to do like the code which displays the options. So you need to do a foreach on the products of the cart $this->element->products and if the attribute cart_product_option_parent_id of the product is equal to the cart_product_id of the current product then that first product is an option of the second.
For example:
$has_options = false;
foreach($this->element->products as $j => $optionElement) {
if($optionElement->cart_product_option_parent_id != $product->cart_product_id)
continue;
$has_options = true;
break;
}