ob_start();
$sep = '';
if(hikashop_level(2)) {
$fields = $fieldsClass->getFields('frontcomp',$data,'order','');
foreach($fields as $fieldName => $oneExtraField) {
if(empty($data->cart->$fieldName))
continue;
echo '<span class="top_pkinfo_headers">' .$sep . $fieldsClass->trans($oneExtraField->field_realname).' : <span>'.$fieldsClass->show($oneExtraField, $data->cart->$fieldName,'admin_email').'</span></span>';
$sep = ' ';
}
}
// This is the part added by wildweststudios
$fieldsClass = hikashop_get('class.field');
$element=null;
$fields = $fieldsClass->getFields('',$order->cart,'order');
echo $fieldsClass->show($fields['yourdesiredduedate'], $this->row->yourdesiredduedate);
// End part added by wildweststudios
JPluginHelper::importPlugin('hikashop');
$dispatcher = JDispatcher::getInstance();
$dispatcher->trigger('onAfterOrderProductsListingDisplay', array(&$data->cart, 'email_notification_html'));
$content = ob_get_clean();
$vars['ORDER_SUMMARY'] = $content;
$vars['BILLING_ADDRESS'] = '';
$vars['SHIPPING_ADDRESS'] = '';
$params = null;
$js = '';
$fieldsClass = hikashop_get('class.field');
$template = trim(hikashop_getLayout($view,'address_template',$params,$js));
if(!empty($data->cart->billing_address) && !empty($data->cart->fields)){
$billing = ''.$template;
foreach($data->cart->fields as $field){
$fieldname = $field->field_namekey;
if(!empty($data->cart->billing_address->$fieldname)) $billing=str_replace('{'.$fieldname.'}',$fieldsClass->show($field,$data->cart->billing_address->$fieldname),$billing);
}
$vars['BILLING_ADDRESS'] = str_replace(array("\r\n","\r","\n"),'<br/>',preg_replace('#{(?:(?!}).)*}#i','',$billing));
}
if(!empty($data->cart->override_shipping_address)) {
$vars['SHIPPING_ADDRESS'] = $data->cart->override_shipping_address;
} elseif(!empty($data->order_shipping_id) && !empty($data->cart->shipping_address)) {
$shipping = ''.$template;
foreach($data->cart->fields as $field) {
$fieldname = $field->field_namekey;
if(!empty($data->cart->shipping_address->$fieldname)) $shipping=str_replace('{'.$fieldname.'}',$fieldsClass->show($field,$data->cart->shipping_address->$fieldname),$shipping);
}
$vars['SHIPPING_ADDRESS'] = str_replace(array("\r\n","\r","\n"),'<br/>',preg_replace('#{(?:(?!}).)*}#i','',$shipping));
} else {
$vars['SHIPPING_ADDRESS'] = $vars['BILLING_ADDRESS'];
}