readme text change
This commit is contained in:
parent
6e03e72477
commit
aa5e49e043
|
@ -836,13 +836,13 @@ $more_date = get_post_meta($post->ID, 'mep_event_more_date', true);
|
||||||
<div class="sec">
|
<div class="sec">
|
||||||
<table width="100%" class="mama">
|
<table width="100%" class="mama">
|
||||||
<tr >
|
<tr >
|
||||||
<td><input placeholder="Day 2" type="text" class='event_more_date' name="event_more_date[]" value="<?php if(array_key_exists('mep_event_more_date', $values)){ echo $more_date[0]['event_more_date']; } ?>" /></td>
|
<td><input placeholder="Day 2 (Use this only if you have same event multiple day)" type="text" class='event_more_date' name="event_more_date[]" value="<?php if(array_key_exists('mep_event_more_date', $values)){ echo $more_date[0]['event_more_date']; } ?>" /></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr >
|
<tr >
|
||||||
<td><input placeholder="Day 3" type="text" class='event_more_date' name="event_more_date[]" value="<?php if(array_key_exists('mep_event_more_date', $values)){ echo $more_date[1]['event_more_date']; } ?>" /></td>
|
<td><input placeholder="Day 3(Use this only if you have same event multiple day)" type="text" class='event_more_date' name="event_more_date[]" value="<?php if(array_key_exists('mep_event_more_date', $values)){ echo $more_date[1]['event_more_date']; } ?>" /></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr >
|
<tr >
|
||||||
<td><input placeholder="Day 4" type="text" class='event_more_date' name="event_more_date[]" value="<?php if(array_key_exists('mep_event_more_date', $values)){ echo $more_date[2]['event_more_date']; } ?>" /></td>
|
<td><input placeholder="Day 4(Use this only if you have same event multiple day)" type="text" class='event_more_date' name="event_more_date[]" value="<?php if(array_key_exists('mep_event_more_date', $values)){ echo $more_date[2]['event_more_date']; } ?>" /></td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -104,7 +104,8 @@ if (get_post_type($eid) == 'mep_events') {
|
||||||
function mep_display_custom_fields_text_cart( $item_data, $cart_item ) {
|
function mep_display_custom_fields_text_cart( $item_data, $cart_item ) {
|
||||||
$mep_events_extra_prices = $cart_item['event_extra_option'];
|
$mep_events_extra_prices = $cart_item['event_extra_option'];
|
||||||
// print_r($cart_item);
|
// print_r($cart_item);
|
||||||
|
$eid = $cart_item['event_id'];
|
||||||
|
if (get_post_type($eid) == 'mep_events') {
|
||||||
echo "<ul class='event-custom-price'>";
|
echo "<ul class='event-custom-price'>";
|
||||||
?>
|
?>
|
||||||
<li><?php _e('Event Date','mage-eventpress'); ?>: <?php echo $cart_item['event_cart_date']; ?></li>
|
<li><?php _e('Event Date','mage-eventpress'); ?>: <?php echo $cart_item['event_cart_date']; ?></li>
|
||||||
|
@ -124,6 +125,7 @@ if(array_key_exists('event_ticket_type', $cart_item)){
|
||||||
echo "<li> Ticket: ".$cart_item['event_ticket_type']." x ".$cart_item['event_ticket_qty'].": ".get_woocommerce_currency_symbol().$cart_item['event_ticket_price']."</li>";
|
echo "<li> Ticket: ".$cart_item['event_ticket_type']." x ".$cart_item['event_ticket_qty'].": ".get_woocommerce_currency_symbol().$cart_item['event_ticket_price']."</li>";
|
||||||
}
|
}
|
||||||
echo "</ul>";
|
echo "</ul>";
|
||||||
|
}
|
||||||
return $item_data;
|
return $item_data;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -136,9 +138,21 @@ function mep_add_custom_fields_text_to_order_items( $item, $cart_item_key, $valu
|
||||||
$eid = $values['event_id'];
|
$eid = $values['event_id'];
|
||||||
if (get_post_type($eid) == 'mep_events') {
|
if (get_post_type($eid) == 'mep_events') {
|
||||||
$mep_events_extra_prices = $values['event_extra_option'];
|
$mep_events_extra_prices = $values['event_extra_option'];
|
||||||
|
if(isset($values['event_ticket_type'])){
|
||||||
$event_ticket_type = $values['event_ticket_type'];
|
$event_ticket_type = $values['event_ticket_type'];
|
||||||
|
}else{
|
||||||
|
$event_ticket_type = " ";
|
||||||
|
}
|
||||||
|
if(isset($values['event_ticket_price'])){
|
||||||
$event_ticket_price = $values['event_ticket_price'];
|
$event_ticket_price = $values['event_ticket_price'];
|
||||||
|
}else{
|
||||||
|
$event_ticket_price = " ";
|
||||||
|
}
|
||||||
|
if(isset($values['event_ticket_qty'])){
|
||||||
$event_ticket_qty = $values['event_ticket_qty'];
|
$event_ticket_qty = $values['event_ticket_qty'];
|
||||||
|
}else{
|
||||||
|
$event_ticket_qty = " ";
|
||||||
|
}
|
||||||
$product_id = $values['product_id'];
|
$product_id = $values['product_id'];
|
||||||
$cart_location = $values['event_cart_location'];
|
$cart_location = $values['event_cart_location'];
|
||||||
$cart_date = $values['event_cart_date'];
|
$cart_date = $values['event_cart_date'];
|
||||||
|
@ -181,8 +195,9 @@ update_post_meta( $product_id, "mep_xtra_$opt_name",$ntes);
|
||||||
|
|
||||||
if($event_ticket_type){
|
if($event_ticket_type){
|
||||||
|
|
||||||
$event_ticket_type = "Ticket:".$event_ticket_type;
|
// $event_ticket_type = "Ticket:".$event_ticket_type;
|
||||||
$item->add_meta_data( $event_ticket_type." x ".$event_ticket_qty,get_woocommerce_currency_symbol().$event_ticket_price);
|
|
||||||
|
// $item->add_meta_data( $event_ticket_type." x ".$event_ticket_qty,get_woocommerce_currency_symbol().$event_ticket_price);
|
||||||
$tck_name = $product_id.str_replace(' ', '', $event_ticket_type);
|
$tck_name = $product_id.str_replace(' ', '', $event_ticket_type);
|
||||||
$tesqt = get_post_meta($product_id,"mep_xtra_$tck_name",true);
|
$tesqt = get_post_meta($product_id,"mep_xtra_$tck_name",true);
|
||||||
$ntesqt = ($tesqt+$event_ticket_qty);
|
$ntesqt = ($tesqt+$event_ticket_qty);
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue