cart function update

This commit is contained in:
magepeopleteam 2022-08-24 06:54:33 +00:00
parent dfbda2d3e9
commit 68505426f7
1 changed files with 6 additions and 0 deletions

View File

@ -120,6 +120,8 @@ function mep_add_custom_price($cart_object)
*/ */
function mep_display_custom_fields_text_cart($item_data, $cart_item) function mep_display_custom_fields_text_cart($item_data, $cart_item)
{ {
ob_start();
$mep_events_extra_prices = array_key_exists('event_extra_option', $cart_item) ? $cart_item['event_extra_option'] : array(); //$cart_item['event_extra_option']; $mep_events_extra_prices = array_key_exists('event_extra_option', $cart_item) ? $cart_item['event_extra_option'] : array(); //$cart_item['event_extra_option'];
$eid = array_key_exists('event_id', $cart_item) ? $cart_item['event_id'] : 0; //$cart_item['event_id']; $eid = array_key_exists('event_id', $cart_item) ? $cart_item['event_id'] : 0; //$cart_item['event_id'];
@ -219,11 +221,15 @@ function mep_display_custom_fields_text_cart($item_data, $cart_item)
do_action('mep_after_cart_item_display_list', $cart_item); do_action('mep_after_cart_item_display_list', $cart_item);
echo "</ul>"; echo "</ul>";
} }
$item_data[] = array('key' => __('Details Information','mage-eventpress'), 'value' => ob_get_clean());
return $item_data; return $item_data;
} }
add_filter('woocommerce_get_item_data', 'mep_display_custom_fields_text_cart', 90, 2); add_filter('woocommerce_get_item_data', 'mep_display_custom_fields_text_cart', 90, 2);
/** /**
* Now before placing the order we need to check seats are available or not, the below function doing this task its validate the user selected seat numbers are available or not. * Now before placing the order we need to check seats are available or not, the below function doing this task its validate the user selected seat numbers are available or not.
*/ */