php warning removed
This commit is contained in:
parent
a4cce24213
commit
db293f6c53
|
@ -211,6 +211,7 @@ function mep_display_custom_fields_text_cart( $item_data, $cart_item ) {
|
|||
$mep_events_extra_prices = $cart_item['event_extra_option'];
|
||||
if($mep_events_extra_prices){
|
||||
echo "<ul class='event-custom-price'>";
|
||||
|
||||
foreach ( $mep_events_extra_prices as $field ) {
|
||||
if($field['option_qty']>0){
|
||||
?>
|
||||
|
@ -219,13 +220,14 @@ echo "<ul class='event-custom-price'>";
|
|||
<?php
|
||||
}
|
||||
}
|
||||
}
|
||||
if(array_key_exists('event_ticket_type', $cart_item)){
|
||||
// if($cart_item['event_ticket_type']){
|
||||
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>";
|
||||
return $item_data;
|
||||
}
|
||||
|
||||
}
|
||||
add_filter( 'woocommerce_get_item_data', 'mep_display_custom_fields_text_cart', 10, 2 );
|
||||
|
||||
|
@ -240,7 +242,7 @@ $event_ticket_price = $values['event_ticket_price'];
|
|||
$event_ticket_qty = $values['event_ticket_qty'];
|
||||
$product_id = $values['product_id'];
|
||||
|
||||
|
||||
if (is_array($mep_events_extra_prices) || is_object($mep_events_extra_prices)){
|
||||
foreach ( $mep_events_extra_prices as $field ) {
|
||||
if($field['option_qty']>0){
|
||||
|
||||
|
@ -258,22 +260,16 @@ update_post_meta( $product_id, "mep_xtra_$opt_name",$ntes);
|
|||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
if($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);
|
||||
|
||||
|
||||
$tck_name = $product_id.str_replace(' ', '', $event_ticket_type);
|
||||
|
||||
$tesqt = get_post_meta($product_id,"mep_xtra_$tck_name",true);
|
||||
$ntesqt = ($tesqt+$event_ticket_qty);
|
||||
update_post_meta( $product_id, "mep_xtra_$tck_name",$ntesqt);
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@ Contributors: MagePeople Team
|
|||
Tags: event, event with woocommerce, woocommerce event, wordpress event plugin, event management wordpress, event booking for woocommerce, best wordpress event plugin, event booking manager wordpress, wordpress event, woocomerce events manager, events manager, Wordpress Events plugin, Events plugin, wp events
|
||||
Requires at least: 4.5
|
||||
Stable tag: 2.1
|
||||
Version: 2.1.1
|
||||
Version: 2.1.2
|
||||
Tested up to: 4.9
|
||||
License: GPLv2 or later
|
||||
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
||||
|
@ -171,4 +171,7 @@ You can display the event list on any page by using the ShortCode. Just use this
|
|||
*Update Release, jQuery Conflict fixed with DiVi theme. 8 Aug 2018*
|
||||
|
||||
= 2.1.1 =
|
||||
*Update Release, php warning and notice removed and date issue fixed. 16 Aug 2018*
|
||||
*Update Release, php warning and notice removed and date issue fixed. 16 Aug 2018*
|
||||
|
||||
= 2.1.2 =
|
||||
*Update Release, php warning and notice removed and date issue fixed. 25 Aug 2018*
|
|
@ -35,7 +35,8 @@ if($book_count){ $total_book = $book_count; }else{ $total_book = 0; }
|
|||
|
||||
$stc = 0;
|
||||
$leftt = 0;
|
||||
foreach ( $mep_event_ticket_type as $field ) {
|
||||
if (is_array($mep_event_ticket_type) || is_object($mep_event_ticket_type)){
|
||||
foreach ($mep_event_ticket_type as $field ) {
|
||||
$qm = $field['option_name_t'];
|
||||
$tesqn = $post_id.str_replace(' ', '', $qm);
|
||||
$tesq = get_post_meta($post_id,"mep_xtra_$tesqn",true);
|
||||
|
@ -43,7 +44,7 @@ foreach ( $mep_event_ticket_type as $field ) {
|
|||
$llft = ($field['option_qty_t'] - $tesq);
|
||||
$leftt = $leftt+$llft;
|
||||
}
|
||||
|
||||
}else{$qm='';}
|
||||
if($mep_event_ticket_type){
|
||||
$seat_left = $leftt;
|
||||
}else{
|
||||
|
@ -102,6 +103,7 @@ if($qty_typec=='dropdown'){ ?>
|
|||
<?php
|
||||
$mep_event_ticket_type = get_post_meta($post->ID, 'mep_event_ticket_type', true);
|
||||
if(!$mep_event_ticket_type){
|
||||
if($qm){$qm=$qm;}else{$qm='';}
|
||||
?>
|
||||
<div class="user-info-sec">
|
||||
<div id="divParent"><div class='mep-user-info-sec'><h5><?php echo $qm; ?> Attendee info:1</h5><input type='<?php if($mep_full_name){ echo 'text'; }else{ echo 'hidden'; } ?>' <?php if($mep_full_name){ ?> required='required' <?php } ?> name='user_name[]' class='mep_input' placeholder='Enter Your Name'/><input type='<?php if($mep_reg_email){ echo 'email'; }else{ echo 'hidden'; } ?>' <?php if($mep_reg_email){ ?> required='required' <?php } ?> name='user_email[]' class='mep_input' placeholder='Enter Your Email'/><input type='<?php if($mep_reg_phone){ echo 'text'; }else{ echo 'hidden'; } ?>' <?php if($mep_reg_phone){ ?> required='required' <?php } ?> name='user_phone[]' class='mep_input' placeholder='Enter Your Phone'/><textarea name='user_address[]' class='mep_input <?php if($mep_reg_address){ echo 'mep-show'; }else{ echo 'mep-hidden'; } ?>' rows='3' <?php if($mep_reg_address){ ?> required='required' <?php } ?> placeholder='Enter you address'></textarea><label class='<?php if($mep_reg_tshirtsize){ echo "mep-show"; }else{ echo "mep-hidden"; } ?>' for='gen' style='text-align: left;'>T-Shirt Size<select name='tshirtsize[]' id='gen'><option value=''>Please Select</option><?php echo mep_get_tshirts_sizes($post->ID); ?></select></label><label class='<?php if($mep_reg_gender){ echo 'mep-show'; }else{ echo 'mep-hidden'; } ?>' for='gen' style='text-align: left;'>Gender<select name='gender[]' id='gen'><option value=''>Please Select</option><option value='Male'>Male</option><option value='Female'>Female</option></select></label><input type='<?php if($mep_reg_company){ echo 'text'; }else{ echo 'hidden'; } ?>' name='user_company[]' class='mep_input' placeholder='Company'/><input type='<?php if($mep_reg_designation){ echo 'text'; }else{ echo 'hidden'; } ?>' name='user_designation[]' class='mep_input' placeholder='Designation'/><input type='<?php if($mep_reg_website){ echo 'text'; }else{ echo 'hidden'; } ?>' name='user_website[]' class='mep_input' placeholder='Website'/><label class='<?php if($mep_reg_veg){ echo 'mep-show'; }else{ echo 'mep-hidden'; } ?>' for='veg' style='text-align: left;'>Vegetarian<select name='vegetarian[]' id='veg'><option value=''>Please Select</option><option value='Yes'>Yes</option><option value='No'>No</option></select></label><input type='hidden' name='ticket_type[]' class='mep_input' value='<?php echo $qm; ?>' /><?php do_action('mep_after_reg_form_front'); ?></div>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
* Plugin Name: Woocommerce Events Manager
|
||||
* Plugin URI: http://mage-people.com
|
||||
* Description: A Complete Event Solution for WordPress by MagePeople..
|
||||
* Version: 2.1.1
|
||||
* Version: 2.1.2
|
||||
* Author: MagePeople Team
|
||||
* Author URI: http://www.mage-people.com/
|
||||
*/
|
||||
|
@ -404,6 +404,10 @@ if($mep_stock_order==$order_id){
|
|||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue