version 3.30 released
This commit is contained in:
parent
3f2589d3a8
commit
d712d9b515
|
@ -1841,7 +1841,7 @@ div > .ppof-metabox {
|
|||
.form-table th,
|
||||
.form-table td,
|
||||
#postbox-container-2 p.description{padding: 5px;line-height: 1;}
|
||||
.form-table pre{display: none;}
|
||||
/* .form-table pre{display: none;} */
|
||||
.ppof-button,
|
||||
#create_seat_plan,
|
||||
#create_seat_plan_dd,
|
||||
|
|
|
@ -35,9 +35,10 @@ if (!class_exists('MAGE_Events_Setting_Controls')) :
|
|||
|
||||
function admin_menu()
|
||||
{
|
||||
$event_label = mep_get_option('mep_event_label', 'general_setting_sec', 'Events');
|
||||
//add_options_page( 'Event Settings', 'Event Settings', 'delete_posts', 'mep_event_settings_page', array($this, 'plugin_page') );
|
||||
|
||||
add_submenu_page('edit.php?post_type=mep_events', __('Event Settings', 'mage-eventpress'), __('Event Settings', 'mage-eventpress'), 'manage_options', 'mep_event_settings_page', array($this, 'plugin_page'));
|
||||
add_submenu_page('edit.php?post_type=mep_events', __($event_label.' Settings', 'mage-eventpress'), __($event_label.' Settings', 'mage-eventpress'), 'manage_options', 'mep_event_settings_page', array($this, 'plugin_page'));
|
||||
}
|
||||
|
||||
function get_settings_sections()
|
||||
|
@ -75,7 +76,33 @@ if (!class_exists('MAGE_Events_Setting_Controls')) :
|
|||
function get_settings_fields()
|
||||
{
|
||||
$settings_fields = array(
|
||||
'general_setting_sec' => array(
|
||||
'general_setting_sec' => apply_filters('mep_settings_general_arr',array(
|
||||
|
||||
array(
|
||||
'name' => 'mep_event_label',
|
||||
'label' => __('Event Label', 'mage-eventpress'),
|
||||
'desc' => __('If you want to change the event label in the dashboard menu you can change here', 'mage-eventpress'),
|
||||
'type' => 'text',
|
||||
'default' => 'Events'
|
||||
),
|
||||
|
||||
array(
|
||||
'name' => 'mep_event_slug',
|
||||
'label' => __('Event Slug', 'mage-eventpress'),
|
||||
'desc' => __('Please enter the slug name you want. Remember after change this slug you need to flush permalink, Just go to Settings->Permalink hit the Save Settings button', 'mage-eventpress'),
|
||||
'type' => 'text',
|
||||
'default' => 'events'
|
||||
),
|
||||
|
||||
array(
|
||||
'name' => 'mep_event_icon',
|
||||
'label' => __('Event Icon', 'mage-eventpress'),
|
||||
'desc' => __('If you want to change the event icon in the dashboard menu you can change from here, Dashboard icon only support dashicon, So please go to <a href=https://developer.wordpress.org/resource/dashicons/#calendar-alt target=_blank>Dash Icon</a> and copy your icon code and paste here', 'mage-eventpress'),
|
||||
'type' => 'text',
|
||||
'default' => 'dashicons-calendar-alt'
|
||||
),
|
||||
|
||||
|
||||
array(
|
||||
'name' => 'mep_google_map_type',
|
||||
'label' => __('Google Map Type?', 'mage-eventpress'),
|
||||
|
@ -351,9 +378,10 @@ if (!class_exists('MAGE_Events_Setting_Controls')) :
|
|||
'no' => 'No'
|
||||
)
|
||||
)
|
||||
)
|
||||
),
|
||||
|
||||
'email_setting_sec' => array(
|
||||
'email_setting_sec' => apply_filters('mep_settings_email_arr',array(
|
||||
array(
|
||||
'name' => 'mep_email_form_name',
|
||||
'label' => __('Email Form Name', 'mage-eventpress'),
|
||||
|
@ -379,9 +407,10 @@ if (!class_exists('MAGE_Events_Setting_Controls')) :
|
|||
'type' => 'wysiwyg',
|
||||
'default' => '',
|
||||
),
|
||||
)
|
||||
),
|
||||
|
||||
'label_setting_sec' => array(
|
||||
'label_setting_sec' => apply_filters('mep_translation_string_arr',array(
|
||||
array(
|
||||
'name' => 'mep_event_ticket_type_text',
|
||||
'label' => __('Ticket Type Table Label', 'mage-eventpress'),
|
||||
|
@ -598,9 +627,31 @@ if (!class_exists('MAGE_Events_Setting_Controls')) :
|
|||
'type' => 'text',
|
||||
'default' => 'Virtual Event'
|
||||
),
|
||||
),
|
||||
array(
|
||||
'name' => 'mep_event_multidate_ribon_text',
|
||||
'label' => __('Multi Date Event Rebon', 'mage-eventpress'),
|
||||
'desc' => __('Enter Text For Multi Date Event Rebon', 'mage-eventpress'),
|
||||
'type' => 'text',
|
||||
'default' => 'Multi Date Event'
|
||||
),
|
||||
array(
|
||||
'name' => 'mep_event_view_more_date_btn_text',
|
||||
'label' => __('View More Date Button', 'mage-eventpress'),
|
||||
'desc' => __('Enter Text For View More Date button', 'mage-eventpress'),
|
||||
'type' => 'text',
|
||||
'default' => 'View More Date'
|
||||
),
|
||||
array(
|
||||
'name' => 'mep_event_hide_date_list_btn_text',
|
||||
'label' => __('Hide Date Lists Button', 'mage-eventpress'),
|
||||
'desc' => __('Enter Text For Hide Date Lists button', 'mage-eventpress'),
|
||||
'type' => 'text',
|
||||
'default' => 'Hide Date Lists'
|
||||
)
|
||||
|
||||
)),
|
||||
|
||||
'style_setting_sec' => array(
|
||||
'style_setting_sec' => apply_filters('mep_settings_styling_arr',array(
|
||||
array(
|
||||
'name' => 'mep_base_color',
|
||||
'label' => __('Base Color', 'mage-eventpress'),
|
||||
|
@ -657,7 +708,7 @@ if (!class_exists('MAGE_Events_Setting_Controls')) :
|
|||
),
|
||||
)
|
||||
|
||||
|
||||
)
|
||||
);
|
||||
|
||||
return apply_filters('mep_settings_sec_fields', $settings_fields);
|
||||
|
|
|
@ -8,44 +8,47 @@ if (!defined('ABSPATH')) {
|
|||
*/
|
||||
function mep_cpt()
|
||||
{
|
||||
$speaker_status = mep_get_option('mep_enable_speaker_list', 'general_setting_sec', 'no');
|
||||
$speaker_status = mep_get_option('mep_enable_speaker_list', 'general_setting_sec', 'no');
|
||||
$event_label = mep_get_option('mep_event_label', 'general_setting_sec', 'Events');
|
||||
$event_slug = mep_get_option('mep_event_slug', 'general_setting_sec', 'events');
|
||||
$event_icon = mep_get_option('mep_event_icon', 'general_setting_sec', 'dashicons-calendar-alt');
|
||||
|
||||
$labels = array(
|
||||
'name' => __('Events', 'mage-eventpress'),
|
||||
'singular_name' => __('Events', 'mage-eventpress'),
|
||||
'menu_name' => __('Events', 'mage-eventpress'),
|
||||
'name_admin_bar' => __('Events', 'mage-eventpress'),
|
||||
'archives' => __('Events List', 'mage-eventpress'),
|
||||
'attributes' => __('Events List', 'mage-eventpress'),
|
||||
'parent_item_colon' => __('Event Item:', 'mage-eventpress'),
|
||||
'all_items' => __('All Events', 'mage-eventpress'),
|
||||
'add_new_item' => __('Add New Event', 'mage-eventpress'),
|
||||
'add_new' => __('Add New Event', 'mage-eventpress'),
|
||||
'new_item' => __('New Event', 'mage-eventpress'),
|
||||
'edit_item' => __('Edit Event', 'mage-eventpress'),
|
||||
'update_item' => __('Update Event', 'mage-eventpress'),
|
||||
'view_item' => __('View Event', 'mage-eventpress'),
|
||||
'view_items' => __('View Event', 'mage-eventpress'),
|
||||
'search_items' => __('Search Event', 'mage-eventpress'),
|
||||
'not_found' => __('Event Not found', 'mage-eventpress'),
|
||||
'not_found_in_trash' => __('Event Not found in Trash', 'mage-eventpress'),
|
||||
'featured_image' => __('Event Feature Image', 'mage-eventpress'),
|
||||
'set_featured_image' => __('Set Event featured image', 'mage-eventpress'),
|
||||
'remove_featured_image' => __('Remove Event featured image', 'mage-eventpress'),
|
||||
'use_featured_image' => __('Use as Event featured image', 'mage-eventpress'),
|
||||
'insert_into_item' => __('Insert into Event', 'mage-eventpress'),
|
||||
'uploaded_to_this_item' => __('Uploaded to this Event', 'mage-eventpress'),
|
||||
'items_list' => __('Event list', 'mage-eventpress'),
|
||||
'items_list_navigation' => __('Event list navigation', 'mage-eventpress'),
|
||||
'filter_items_list' => __('Filter Event list', 'mage-eventpress'),
|
||||
'name' => __($event_label, 'mage-eventpress'),
|
||||
'singular_name' => __($event_label, 'mage-eventpress'),
|
||||
'menu_name' => __($event_label, 'mage-eventpress'),
|
||||
'name_admin_bar' => __($event_label, 'mage-eventpress'),
|
||||
'archives' => __($event_label.' List', 'mage-eventpress'),
|
||||
'attributes' => __($event_label.' List', 'mage-eventpress'),
|
||||
'parent_item_colon' => __($event_label.' Item:', 'mage-eventpress'),
|
||||
'all_items' => __('All '.$event_label, 'mage-eventpress'),
|
||||
'add_new_item' => __('Add New '.$event_label, 'mage-eventpress'),
|
||||
'add_new' => __('Add New '.$event_label, 'mage-eventpress'),
|
||||
'new_item' => __('New '.$event_label, 'mage-eventpress'),
|
||||
'edit_item' => __('Edit '.$event_label, 'mage-eventpress'),
|
||||
'update_item' => __('Update '.$event_label, 'mage-eventpress'),
|
||||
'view_item' => __('View '.$event_label, 'mage-eventpress'),
|
||||
'view_items' => __('View '.$event_label, 'mage-eventpress'),
|
||||
'search_items' => __('Search '.$event_label, 'mage-eventpress'),
|
||||
'not_found' => __($event_label.' Not found', 'mage-eventpress'),
|
||||
'not_found_in_trash' => __($event_label.' Not found in Trash', 'mage-eventpress'),
|
||||
'featured_image' => __($event_label.' Feature Image', 'mage-eventpress'),
|
||||
'set_featured_image' => __('Set '.$event_label.' featured image', 'mage-eventpress'),
|
||||
'remove_featured_image' => __('Remove '.$event_label.' featured image', 'mage-eventpress'),
|
||||
'use_featured_image' => __('Use as '.$event_label.' featured image', 'mage-eventpress'),
|
||||
'insert_into_item' => __('Insert into '.$event_label, 'mage-eventpress'),
|
||||
'uploaded_to_this_item' => __('Uploaded to this '.$event_label, 'mage-eventpress'),
|
||||
'items_list' => __($event_label.' list', 'mage-eventpress'),
|
||||
'items_list_navigation' => __($event_label.' list navigation', 'mage-eventpress'),
|
||||
'filter_items_list' => __('Filter '.$event_label.' list', 'mage-eventpress'),
|
||||
);
|
||||
|
||||
$args = array(
|
||||
'public' => true,
|
||||
'labels' => $labels,
|
||||
'menu_icon' => 'dashicons-calendar-alt',
|
||||
'menu_icon' => $event_icon,
|
||||
'supports' => array('title', 'editor', 'thumbnail', 'excerpt'),
|
||||
'rewrite' => array('slug' => 'events')
|
||||
'rewrite' => array('slug' => $event_slug)
|
||||
|
||||
);
|
||||
register_post_type('mep_events', $args);
|
||||
|
|
|
@ -59,6 +59,7 @@ function mep_add_admin_scripts($hook)
|
|||
wp_enqueue_script('select2.min', plugins_url('js/select2.min.js', __DIR__), array('jquery'));
|
||||
wp_enqueue_script('codemirror', plugin_dir_url(__DIR__) . 'js/codemirror.min.js', array('jquery'), null, false);
|
||||
wp_enqueue_script('form-field-dependency', plugins_url('js/form-field-dependency.js', __DIR__), array('jquery'), null, false);
|
||||
wp_localize_script('jquery', 'mep_ajax', array( 'mep_ajaxurl' => admin_url( 'admin-ajax.php')));
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -68,6 +69,8 @@ add_action('wp_enqueue_scripts', 'mep_event_enqueue_scripts', 90);
|
|||
function mep_event_enqueue_scripts()
|
||||
{
|
||||
wp_enqueue_script('jquery');
|
||||
wp_enqueue_script('jquery-ui-datepicker');
|
||||
wp_enqueue_script('jquery-ui-core');
|
||||
wp_enqueue_script('jquery-ui-accordion');
|
||||
wp_enqueue_style('mep-jquery-ui-style', plugin_dir_url(__DIR__) . 'css/jquery-ui.css', array());
|
||||
wp_enqueue_style('mep-event-style', plugin_dir_url(__DIR__) . 'css/style.css', array());
|
||||
|
@ -83,4 +86,6 @@ function mep_event_enqueue_scripts()
|
|||
wp_enqueue_script('mep-owl-carousel-min', plugin_dir_url(__DIR__) . 'js/owl.carousel.min.js', array('jquery'), 1, true);
|
||||
wp_enqueue_script('mep-timeline-min', plugin_dir_url(__DIR__) . 'js/timeline.min.js', array('jquery'), 1, true);
|
||||
wp_enqueue_script('mep-event-custom-scripts', plugin_dir_url(__DIR__) . 'js/mkb-scripts.js', array(), 1, true);
|
||||
}
|
||||
wp_localize_script('jquery', 'mep_ajax', array( 'mep_ajaxurl' => admin_url( 'admin-ajax.php')));
|
||||
}
|
||||
|
||||
|
|
|
@ -5,7 +5,7 @@ function mep_event_meta_box_add(){
|
|||
|
||||
add_meta_box( 'mep-event-meta', __('<span class="dashicons dashicons-location" style="color:green; padding-right:10px;"></span>Event Venue','mage-eventpress'), 'mep_event_venue_meta_box_cb', 'mep_events', 'normal', 'high' );
|
||||
|
||||
add_meta_box( 'mep-event-price', __('Event Price (Event Base price, It will not work if you add Event Ticket type Price)','mage-eventpress'), 'mep_event_price_meta_box_cb', 'mep_events', 'normal', 'high' );
|
||||
// add_meta_box( 'mep-event-price', __('Event Price (Event Base price, It will not work if you add Event Ticket type Price)','mage-eventpress'), 'mep_event_price_meta_box_cb', 'mep_events', 'normal', 'high' );
|
||||
|
||||
add_meta_box( 'mep-event-ticket-type', __('<span class="dashicons dashicons-buddicons-tracking" style="color:green; padding-right:10px;"></span>Event Ticket Type and Pricing','mage-eventpress'), 'mep_event_ticket_type', 'mep_events', 'normal', 'high' );
|
||||
|
||||
|
@ -1003,7 +1003,7 @@ $opt_rst_qty = isset($field['option_rsv_t']) ? $field['option_rsv_t'] : 0;
|
|||
<tr>
|
||||
<td><input type="text" class="widefat" name="option_name_t[]" placeholder="Ex: Adult" value="<?php if($field['option_name_t'] != '') echo esc_attr( $field['option_name_t'] ); ?>" /></td>
|
||||
|
||||
<td><input type="number" size="4" pattern="[0-9]*" step="0.01" class="widefat" name="option_price_t[]" placeholder="Ex: 10" value="<?php if ($field['option_price_t'] != '') echo esc_attr( $field['option_price_t'] ); else echo ''; ?>" /></td>
|
||||
<td><input type="number" size="4" pattern="[0-9]*" step="0.01" class="widefat" name="option_price_t[]" placeholder="Ex: 10" value="<?php if (array_key_exists('option_price_t',$field) && $field['option_price_t'] != '') echo esc_attr( $field['option_price_t'] ); else echo ''; ?>" /></td>
|
||||
|
||||
<td><input type="number" size="4" pattern="[0-9]*" step="1" class="widefat" name="option_qty_t[]" placeholder="Ex: 500" value="<?php if(isset($field['option_qty_t'])){ echo $field['option_qty_t']; }else{ echo 0; } ?>" /></td>
|
||||
<td><input type="number" size="2" pattern="[0-9]*" step="1" class="widefat" name="option_default_qty_t[]" placeholder="Ex: 1" value="<?php if(isset($field['option_default_qty_t'])){ echo $field['option_default_qty_t']; }else{ echo 0; } ?>" /></td>
|
||||
|
@ -1447,17 +1447,17 @@ if (get_post_type($post_id) == 'mep_events') {
|
|||
$event_rt_atdnce_mode = $_POST['mep_rt_event_attandence_mode'];
|
||||
$event_rt_prv_date = $_POST['mep_rt_event_prvdate'];
|
||||
|
||||
$seat = isset( $_POST['mep_total_seat'] ) ? strip_tags( $_POST['mep_total_seat'] ) : "";
|
||||
$rsvs = isset( $_POST['mep_rsv_seat'] ) ? strip_tags( $_POST['mep_rsv_seat'] ) : "";
|
||||
$seat = 0;
|
||||
$rsvs = 0;
|
||||
$mep_location_venue = isset( $_POST['mep_location_venue'] ) ? strip_tags( $_POST['mep_location_venue'] ) : "";
|
||||
$mep_street = isset( $_POST['mep_street'] ) ? strip_tags( $_POST['mep_street'] ) : "";
|
||||
$mep_city = isset( $_POST['mep_city'] ) ? strip_tags( $_POST['mep_city'] ) : "";
|
||||
$mep_state = isset($_POST['mep_state']) ? strip_tags( $_POST['mep_state'] ) : "";
|
||||
$mep_postcode = isset($_POST['mep_postcode']) ? strip_tags( $_POST['mep_postcode'] ) : "";
|
||||
$mep_country = isset($_POST['mep_country']) ? strip_tags( $_POST['mep_country'] ) : "";
|
||||
$mep_price_label = isset($_POST['mep_price_label']) ? strip_tags( $_POST['mep_price_label'] ) : "";
|
||||
$mep_sqi = isset($_POST['mep_sqi']) ? strip_tags( $_POST['mep_sqi'] ) : "";
|
||||
$qty_box_type = isset($_POST['qty_box_type']) ? strip_tags( $_POST['qty_box_type'] ) : "";
|
||||
// $mep_price_label = isset($_POST['mep_price_label']) ? strip_tags( $_POST['mep_price_label'] ) : "";
|
||||
// $mep_sqi = isset($_POST['mep_sqi']) ? strip_tags( $_POST['mep_sqi'] ) : "";
|
||||
// $qty_box_type = isset($_POST['qty_box_type']) ? strip_tags( $_POST['qty_box_type'] ) : "";
|
||||
$mep_sgm = isset($_POST['mep_sgm']) ? strip_tags( $_POST['mep_sgm'] ) : "";
|
||||
$mep_org_address = isset($_POST['mep_org_address']) ? strip_tags( $_POST['mep_org_address'] ) : "";
|
||||
$_price = isset($_POST['_price']) ? strip_tags( $_POST['_price'] ) : "";
|
||||
|
@ -1538,11 +1538,11 @@ if (get_post_type($post_id) == 'mep_events') {
|
|||
update_post_meta( $pid, 'mep_state', $mep_state);
|
||||
update_post_meta( $pid, 'mep_postcode', $mep_postcode);
|
||||
update_post_meta( $pid, 'mep_country', $mep_country);
|
||||
update_post_meta( $pid, 'mep_sqi', $mep_sqi);
|
||||
update_post_meta( $pid, 'qty_box_type', $qty_box_type);
|
||||
// update_post_meta( $pid, 'mep_sqi', $mep_sqi);
|
||||
// update_post_meta( $pid, 'qty_box_type', $qty_box_type);
|
||||
update_post_meta( $pid, 'mep_sgm', $mep_sgm);
|
||||
update_post_meta( $pid, 'mep_price_label', $mep_price_label);
|
||||
update_post_meta( $pid, '_price', $_price);
|
||||
// update_post_meta( $pid, 'mep_price_label', $mep_price_label);
|
||||
update_post_meta( $pid, '_price', 0);
|
||||
update_post_meta( $pid, '_virtual', 'yes');
|
||||
update_post_meta( $pid, 'mep_event_cc_email_text', $mep_event_cc_email_text);
|
||||
update_post_meta( $pid, '_sku', $pid);
|
||||
|
|
|
@ -36,13 +36,20 @@ function mep_add_custom_fields_text_to_cart_item($cart_item_data, $product_id, $
|
|||
$validate = mep_cart_ticket_type('validation_data', $total_price,$product_id);
|
||||
|
||||
|
||||
// echo '<pre>';
|
||||
// echo '<pre>';
|
||||
// print_r($user);
|
||||
// print_r($ticket_type_arr);
|
||||
// // print_r($qty);
|
||||
// die();
|
||||
|
||||
/**
|
||||
* Now Store the datas into Cart Session
|
||||
*/
|
||||
$time_slot_text = isset($_REQUEST['time_slot_name']) ? $_REQUEST['time_slot_name'] : '';
|
||||
if(!empty($time_slot_text)){
|
||||
$cart_item_data['event_everyday_time_slot'] = $time_slot_text;
|
||||
}
|
||||
|
||||
|
||||
$cart_item_data['event_ticket_info'] = $ticket_type_arr;
|
||||
$cart_item_data['event_validate_info'] = $validate;
|
||||
$cart_item_data['event_user_info'] = $user;
|
||||
|
@ -55,6 +62,7 @@ function mep_add_custom_fields_text_to_cart_item($cart_item_data, $product_id, $
|
|||
$cart_item_data['event_recurring_date'] = array_unique($recurring_event_date);
|
||||
$cart_item_data['event_recurring_date_arr'] = $recurring_event_date;
|
||||
$cart_item_data['event_cart_display_date'] = $mep_event_start_date[0];
|
||||
do_action('mep_event_cart_data_reg');
|
||||
}
|
||||
$cart_item_data['event_id'] = $product_id;
|
||||
|
||||
|
@ -101,6 +109,7 @@ $hide_date_status = mep_get_option('mep_hide_date_from_order_page', 'general_se
|
|||
$ticket_type_arr = $cart_item['event_ticket_info'];
|
||||
$event_extra_service = $cart_item['event_extra_service'];
|
||||
$event_recurring_date = $cart_item['event_recurring_date'];
|
||||
|
||||
|
||||
|
||||
$recurring = get_post_meta($eid, 'mep_enable_recurring', true) ? get_post_meta($eid, 'mep_enable_recurring', true) : 'no';
|
||||
|
@ -142,15 +151,14 @@ $hide_date_status = mep_get_option('mep_hide_date_from_order_page', 'general_se
|
|||
<?php
|
||||
}
|
||||
if (is_array($ticket_type_arr) && sizeof($ticket_type_arr) > 0) {
|
||||
foreach ($ticket_type_arr as $ticket) {
|
||||
echo '<li>' . $ticket['ticket_name'] . " - " . wc_price($ticket['ticket_price']) . ' x ' . $ticket['ticket_qty'] . ' = ' . wc_price($ticket['ticket_price'] * $ticket['ticket_qty']) . '</li>';
|
||||
}
|
||||
echo mep_cart_display_ticket_type_list($ticket_type_arr);
|
||||
}
|
||||
if (is_array($event_extra_service) && sizeof($event_extra_service) > 0) {
|
||||
foreach ($event_extra_service as $extra_service) {
|
||||
echo '<li>' . $extra_service['service_name'] . " - " . wc_price($extra_service['service_price']) . ' x ' . $extra_service['service_qty'] . ' = ' . wc_price( (int) $extra_service['service_price'] * (int) $extra_service['service_qty']) . '</li>';
|
||||
}
|
||||
}
|
||||
do_action('mep_after_cart_item_display_list',$cart_item);
|
||||
echo "</ul>";
|
||||
}
|
||||
return $item_data;
|
||||
|
@ -221,12 +229,10 @@ function mep_add_custom_fields_text_to_order_items($item, $cart_item_key, $value
|
|||
$item->add_meta_data('Date',$cart_date);
|
||||
}
|
||||
|
||||
if (is_array($ticket_type_arr) && sizeof($ticket_type_arr) > 0) {
|
||||
foreach ($ticket_type_arr as $ticket) {
|
||||
$ticket_type_name = $ticket['ticket_name'] . " - " . wc_price($ticket['ticket_price']) . ' x ' . $ticket['ticket_qty'] . ' = ';
|
||||
$ticket_type_val = wc_price($ticket['ticket_price'] * $ticket['ticket_qty']);
|
||||
$item->add_meta_data($ticket_type_name, $ticket_type_val);
|
||||
}
|
||||
if (is_array($ticket_type_arr) && sizeof($ticket_type_arr) > 0) {
|
||||
|
||||
mep_cart_order_data_save_ticket_type($item,$ticket_type_arr);
|
||||
|
||||
}
|
||||
|
||||
if (is_array($event_extra_service) && sizeof($event_extra_service) > 0) {
|
||||
|
@ -244,6 +250,7 @@ function mep_add_custom_fields_text_to_order_items($item, $cart_item_key, $value
|
|||
$item->add_meta_data('event_id', $eid);
|
||||
$item->add_meta_data('_product_id', $eid);
|
||||
$item->add_meta_data('_event_extra_service', $event_extra_service);
|
||||
do_action('mep_event_cart_order_data_add',$values,$item);
|
||||
}
|
||||
}
|
||||
add_action('woocommerce_checkout_create_order_line_item', 'mep_add_custom_fields_text_to_order_items', 90, 4);
|
|
@ -287,6 +287,23 @@ function mep_city_template_chooser($template){
|
|||
add_filter('template_include', 'mep_city_template_chooser');
|
||||
|
||||
|
||||
|
||||
function mep_get_event_ticket_price_by_name($event,$type) {
|
||||
$ticket_type = get_post_meta($event,'mep_event_ticket_type',true);
|
||||
if(sizeof($ticket_type)){
|
||||
foreach ($ticket_type as $key => $val) {
|
||||
if ($val['option_name_t'] === $type) {
|
||||
return $val['option_price_t'];
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (!function_exists('mep_attendee_create')) {
|
||||
function mep_attendee_create($type,$order_id,$event_id,$_user_info = array()){
|
||||
|
||||
|
@ -346,6 +363,8 @@ function mep_attendee_create($type,$order_id,$event_id,$_user_info = array()){
|
|||
}
|
||||
|
||||
|
||||
// $ticket_single_price = mep_get_event_ticket_price_by_name($event_id,$ticket_type);
|
||||
$ticket_total_price = (mep_get_event_ticket_price_by_name($event_id,$ticket_type) * $ticket_qty);
|
||||
|
||||
$new_post = array(
|
||||
'post_title' => $uname,
|
||||
|
@ -370,7 +389,8 @@ function mep_attendee_create($type,$order_id,$event_id,$_user_info = array()){
|
|||
update_post_meta( $pid, 'ea_vegetarian', $vegetarian );
|
||||
update_post_meta( $pid, 'ea_tshirtsize', $tshirtsize );
|
||||
update_post_meta( $pid, 'ea_ticket_type', $ticket_type );
|
||||
update_post_meta( $pid, 'ea_ticket_qty', $ticket_qty);
|
||||
update_post_meta( $pid, 'ea_ticket_qty', $ticket_qty);
|
||||
update_post_meta( $pid, 'ea_ticket_price', $ticket_total_price);
|
||||
update_post_meta( $order_id, 'ea_ticket_qty', $ticket_qty);
|
||||
update_post_meta( $order_id, 'ea_ticket_type', $ticket_type );
|
||||
update_post_meta( $order_id, 'ea_event_id', $event_id );
|
||||
|
@ -380,11 +400,20 @@ function mep_attendee_create($type,$order_id,$event_id,$_user_info = array()){
|
|||
update_post_meta( $pid, 'ea_order_id', $order_id );
|
||||
update_post_meta( $pid, 'ea_user_id', $user_id );
|
||||
update_post_meta( $order_id, 'ea_user_id', $user_id );
|
||||
update_post_meta( $order_id, 'order_type_name', 'mep_events' );
|
||||
update_post_meta( $pid, 'ea_ticket_no', $pin );
|
||||
update_post_meta( $pid, 'ea_event_date', $event_date );
|
||||
update_post_meta( $pid, 'ea_order_status', $order_status );
|
||||
update_post_meta( $order_id, 'ea_order_status', $order_status );
|
||||
|
||||
$hooking_data = apply_filters('mep_event_attendee_dynamic_data',array(),$pid,$type,$order_id,$event_id,$_user_info);
|
||||
|
||||
if(is_array($hooking_data) && sizeof($hooking_data) > 0){
|
||||
foreach ($hooking_data as $_data) {
|
||||
update_post_meta( $pid, $_data['name'], $_data['value'] );
|
||||
}
|
||||
}
|
||||
|
||||
// Checking if the form builder addon is active and have any custom fields
|
||||
$mep_form_builder_data = get_post_meta($event_id, 'mep_form_builder_data', true);
|
||||
if ( $mep_form_builder_data ) {
|
||||
|
@ -400,10 +429,13 @@ function mep_attendee_create($type,$order_id,$event_id,$_user_info = array()){
|
|||
if (!function_exists('mep_attendee_extra_service_create')) {
|
||||
function mep_attendee_extra_service_create($order_id,$event_id, $_event_extra_service){
|
||||
|
||||
|
||||
$order = wc_get_order( $order_id );
|
||||
$order_meta = get_post_meta($order_id);
|
||||
$order_status = $order->get_status();
|
||||
if(is_array($_event_extra_service) && sizeof($_event_extra_service) > 0){
|
||||
|
||||
foreach($_event_extra_service as $extra_serive){
|
||||
if($extra_serive['service_name']){
|
||||
$uname = 'Extra Service for '.get_the_title($event_id).' Order #'.$order_id;
|
||||
$new_post = array(
|
||||
'post_title' => $uname,
|
||||
|
@ -424,6 +456,7 @@ if (!function_exists('mep_attendee_extra_service_create')) {
|
|||
update_post_meta( $pid, 'ea_extra_service_order', $order_id );
|
||||
update_post_meta( $pid, 'ea_extra_service_order_status', $order_status );
|
||||
update_post_meta( $pid, 'ea_extra_service_event_date', $extra_serive['event_date'] );
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -491,6 +524,7 @@ if (!function_exists('mep_attendee_extra_service_create')) {
|
|||
$event_ticket_info_arr = wc_get_order_item_meta($item_id,'_event_ticket_info',true);
|
||||
$_event_extra_service = wc_get_order_item_meta($item_id,'_event_extra_service',true);
|
||||
$item_quantity = 0;
|
||||
|
||||
mep_attendee_extra_service_create($order_id,$event_id,$_event_extra_service);
|
||||
foreach ( $event_ticket_info_arr as $field ) {
|
||||
if($field['ticket_qty']>0){
|
||||
|
@ -710,9 +744,7 @@ if (!function_exists('change_wc_event_product_status')) {
|
|||
}
|
||||
} // End of Post Type Check
|
||||
} // End order item foreach
|
||||
|
||||
} // End Function
|
||||
|
||||
} // End Function
|
||||
}
|
||||
|
||||
|
||||
|
@ -834,12 +866,18 @@ if (!function_exists('change_wc_event_product_status')) {
|
|||
// if($recurring == 'yes'){
|
||||
?>
|
||||
<form action="" method="get">
|
||||
<?php
|
||||
if($recurring == 'everyday'){
|
||||
do_action('mep_before_attendee_list_btn',$post_id);
|
||||
}else{
|
||||
?>
|
||||
<select name="ea_event_date" id="" style='font-size: 14px;border: 1px solid blue;width: 110px;display:<?php if($recurring == 'yes'){ echo 'block'; }else{ echo 'none'; } ?>'>
|
||||
<option value="<?php echo get_post_meta($post_id,'event_start_date',true).' '.get_post_meta($post_id,'event_start_time',true); ?>"><?php echo get_mep_datetime(get_post_meta($post_id,'event_start_date',true),'date-text').' '.get_mep_datetime(get_post_meta($post_id,'event_start_date',true).' '.get_post_meta($post_id,'event_start_time',true),'time'); ?></option>
|
||||
<?php foreach($multi_date as $multi){ ?>
|
||||
<option value="<?php echo $multi['event_more_start_date'].' '.$multi['event_more_start_time']; ?>"><?php echo get_mep_datetime($multi['event_more_start_date'],'date-text').' '.get_mep_datetime($multi['event_more_start_time'],'time'); ?></option>
|
||||
<?php } ?>
|
||||
</select>
|
||||
<?php } ?>
|
||||
<input type="hidden" name='post_type' value='mep_events_attendees'>
|
||||
<input type="hidden" name='event_id' value='<?php echo $post_id; ?>'>
|
||||
<button class="button button-primary button-large">Attendees List</button>
|
||||
|
@ -1000,14 +1038,9 @@ if (!function_exists('mep_add_to_google_calender_link')) {
|
|||
|
||||
$location = $event_meta['mep_location_venue'][0]." ".$event_meta['mep_street'][0]." ".$event_meta['mep_city'][0]." ".$event_meta['mep_state'][0]." ".$event_meta['mep_postcode'][0]." ".$event_meta['mep_country'][0];
|
||||
ob_start();
|
||||
require(mep_template_file_path('single/add_calendar.php'));
|
||||
?>
|
||||
<div id="mep_add_calender_button" class='mep-add-calender'><i class="fa fa-calendar"></i><?php _e(mep_get_label($pid,'mep_calender_btn_text','Add Calendar'),'mage-eventpress'); ?></div>
|
||||
<ul id="mep_add_calender_links">
|
||||
<li><a href="https://calendar.google.com/calendar/r/eventedit?text=<?php echo $event->post_title; ?>&dates=<?php echo mep_calender_date($event_start); ?>/<?php echo mep_calender_date($event_end); ?>&details=<?php echo substr(strip_tags($event->post_content),0,1000); ?>&location=<?php echo $location; ?>&sf=true" rel="noopener noreferrer" target='_blank' class='mep-add-calender' rel="nofollow">Google</a></li>
|
||||
<li><a href="https://calendar.yahoo.com/?v=60&view=d&type=20&title=<?php echo $event->post_title; ?>&st=<?php echo mep_calender_date($event_start); ?>&et=<?php echo mep_calender_date($event_end); ?>&desc=<?php echo substr(strip_tags($event->post_content),0,1000); ?>&in_loc=<?php echo $location; ?>&uid=" rel="noopener noreferrer" target='_blank' class='mep-add-calender' rel="nofollow">Yahoo</a></li>
|
||||
<li><a href ="https://outlook.live.com/owa/?path=/calendar/view/Month&rru=addevent&startdt=<?php echo mep_calender_date($event_start); ?>&enddt=<?php echo mep_calender_date($event_end); ?>&subject=<?php echo $event->post_title; ?>" rel="noopener noreferrer" target='_blank' class='mep-add-calender' rel="nofollow">Outlook</a></li>
|
||||
<li><a href="https://webapps.genprod.com/wa/cal/download-ics.php?date_end=<?php echo mep_calender_date($event_end); ?>&date_start=<?php echo mep_calender_date($event_start); ?>&summary=<?php echo $event->post_title; ?>&location=<?php echo $location; ?>&description=<?php echo substr(strip_tags($event->post_content),0,1000); ?>" rel="noopener noreferrer" target='_blank' class='mep-add-calender'>Apple</a></li>
|
||||
</ul>
|
||||
|
||||
<script type="text/javascript">
|
||||
jQuery(document).ready(function() {
|
||||
jQuery("#mep_add_calender_button").click(function () {
|
||||
|
@ -1503,6 +1536,13 @@ if (!function_exists('mep_get_event_locaion_item')) {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (!function_exists('mep_save_attendee_info_into_cart')) {
|
||||
function mep_save_attendee_info_into_cart($product_id){
|
||||
|
||||
|
@ -1581,6 +1621,12 @@ if (!function_exists('mep_save_attendee_info_into_cart')) {
|
|||
$mep_user_cfd = "";
|
||||
}
|
||||
|
||||
|
||||
// echo $p =
|
||||
|
||||
|
||||
|
||||
|
||||
if($mep_user_name){ $count_user = count($mep_user_name); } else{ $count_user = 0; }
|
||||
|
||||
for ( $iu = 0; $iu < $count_user; $iu++ ) {
|
||||
|
@ -1629,6 +1675,10 @@ if (!function_exists('mep_save_attendee_info_into_cart')) {
|
|||
$user[$iu]['user_ticket_type'] = stripslashes( strip_tags( $mep_user_ticket_type[$iu] ) );
|
||||
endif;
|
||||
|
||||
// if ($ticket_price) :
|
||||
// $user[$iu]['user_ticket_price'] = mep_get_event_ticket_price_by_name($mep_event_id,$mep_user_ticket_type);
|
||||
// endif;
|
||||
|
||||
if (isset($event_date[$iu])) :
|
||||
$user[$iu]['user_event_date'] = stripslashes( strip_tags( $event_date[$iu] ) );
|
||||
endif;
|
||||
|
@ -1649,7 +1699,7 @@ if (!function_exists('mep_save_attendee_info_into_cart')) {
|
|||
}
|
||||
}
|
||||
}
|
||||
return $user;
|
||||
return apply_filters('mep_cart_user_data_prepare',$user,$product_id);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1806,6 +1856,7 @@ if (!function_exists('mep_get_term_as_class')) {
|
|||
|
||||
if (!function_exists('mep_ticket_type_sold')) {
|
||||
function mep_ticket_type_sold($event_id,$type,$date=''){
|
||||
|
||||
if($date){
|
||||
$args = array(
|
||||
'post_type' => 'mep_events_attendees',
|
||||
|
@ -2048,7 +2099,7 @@ if (!function_exists('mep_get_event_upcomming_date')) {
|
|||
|
||||
if(sizeof($more_date) > 0){
|
||||
foreach($more_date as $mdate){
|
||||
$all_datetime[] = date('Y-m-d H:i:s',strtotime($mdate['event_more_start_date'].' '.$madate['event_more_start_time']));
|
||||
$all_datetime[] = date('Y-m-d H:i:s',strtotime($mdate['event_more_start_date'].' '.$mdate['event_more_start_time']));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2058,8 +2109,9 @@ if (!function_exists('mep_get_event_upcomming_date')) {
|
|||
$adt[] = $ald;
|
||||
}
|
||||
}
|
||||
|
||||
return get_mep_datetime($adt[0],$type);
|
||||
if(sizeof($adt) > 0){
|
||||
return get_mep_datetime($adt[0],$type);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -2413,8 +2465,8 @@ function mep_event_recurring_date_list_in_event_list_loop($event_id){
|
|||
}
|
||||
echo '</ul>';
|
||||
?>
|
||||
<?php if($show_multidate == 'yes'){ ?><span id="show_event_schdule<?php echo $event_id; ?>" class='mep_more_date_btn mep-tem3-title-sec'><?php _e('View More Date','mage-eventpress'); ?></span><?php } ?>
|
||||
<span id="hide_event_schdule<?php echo $event_id; ?>" class='mep_more_date_btn mep-tem3-title-sec'><?php _e('Hide Date Lists','mage-eventpress'); ?></span>
|
||||
<?php if($show_multidate == 'yes'){ ?><span id="show_event_schdule<?php echo $event_id; ?>" class='mep_more_date_btn mep-tem3-title-sec'><?php echo mep_get_option('mep_event_view_more_date_btn_text', 'label_setting_sec', __('View More Date', 'mage-eventpress')); //_e('View More Date','mage-eventpress'); ?></span><?php } ?>
|
||||
<span id="hide_event_schdule<?php echo $event_id; ?>" class='mep_more_date_btn mep-tem3-title-sec'><?php echo mep_get_option('mep_event_hide_date_list_btn_text', 'label_setting_sec', __('Hide Date Lists', 'mage-eventpress')); // _e('Hide Date Lists','mage-eventpress'); ?></span>
|
||||
<script>
|
||||
jQuery('.mep-more-date-lists<?php echo $event_id; ?>, #hide_event_schdule<?php echo $event_id; ?>').hide();
|
||||
|
||||
|
@ -2449,9 +2501,11 @@ add_action('wp_head','mep_event_rich_text_data');
|
|||
if (!function_exists('mep_event_rich_text_data')) {
|
||||
function mep_event_rich_text_data(){
|
||||
global $post;
|
||||
$event_id = $post->ID;
|
||||
if(is_single() && $event_id && get_post_type($event_id) == 'mep_events'){
|
||||
|
||||
|
||||
if(is_single()){
|
||||
$event_id = $post->ID;
|
||||
if($event_id && get_post_type($event_id) == 'mep_events'){
|
||||
|
||||
$event_name = get_the_title($event_id);
|
||||
$event_start_date = get_post_meta($post->ID,'event_start_datetime',true) ? get_post_meta($post->ID,'event_start_datetime',true) : '';
|
||||
$event_end_date = get_post_meta($post->ID,'event_end_datetime',true) ? get_post_meta($post->ID,'event_end_datetime',true) : '';
|
||||
|
@ -2498,6 +2552,7 @@ function mep_event_rich_text_data(){
|
|||
|
||||
<?php
|
||||
echo $content = ob_get_clean();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -2596,8 +2651,11 @@ function mep_cart_ticket_type($type,$total_price,$product_id){
|
|||
$price = isset($_POST['option_price']) ? $_POST['option_price'] : array();
|
||||
$count = count( $names );
|
||||
$ticket_type_arr = [];
|
||||
|
||||
|
||||
// echo '<pre>';
|
||||
// print_r($names);
|
||||
// print_r($mep_event_start_date);
|
||||
// print_r($qty);
|
||||
// echo '</pre>';
|
||||
$vald = 0;
|
||||
if(sizeof($names) > 0){
|
||||
for ( $i = 0; $i < $count; $i++ ) {
|
||||
|
@ -2619,7 +2677,7 @@ function mep_cart_ticket_type($type,$total_price,$product_id){
|
|||
}elseif($type == 'validation_data'){
|
||||
return $validate;
|
||||
}else{
|
||||
return $ticket_type_arr;
|
||||
return apply_filters('mep_cart_ticket_type_data_prepare',$ticket_type_arr,$type,$total_price,$product_id);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -2685,11 +2743,37 @@ function mep_cart_display_user_list($user_info){
|
|||
|
||||
<?php
|
||||
}
|
||||
return ob_get_clean();
|
||||
return apply_filters('mep_display_user_info_in_cart_list',ob_get_clean(),$user_info);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (!function_exists('mep_cart_display_ticket_type_list')) {
|
||||
function mep_cart_display_ticket_type_list($ticket_type_arr){
|
||||
ob_start();
|
||||
foreach ($ticket_type_arr as $ticket) {
|
||||
echo '<li>' . $ticket['ticket_name'] . " - " . wc_price($ticket['ticket_price']) . ' x ' . $ticket['ticket_qty'] . ' = ' . wc_price((int) $ticket['ticket_price'] * (int) $ticket['ticket_qty']) . '</li>';
|
||||
}
|
||||
return apply_filters('mep_display_ticket_in_cart_list',ob_get_clean(),$ticket_type_arr);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
if (!function_exists('mep_cart_order_data_save_ticket_type')) {
|
||||
function mep_cart_order_data_save_ticket_type($item,$ticket_type_arr){
|
||||
foreach ($ticket_type_arr as $ticket) {
|
||||
$ticket_type_name = $ticket['ticket_name'] . " - " . wc_price($ticket['ticket_price']) . ' x ' . $ticket['ticket_qty'] . ' = ';
|
||||
$ticket_type_val = wc_price($ticket['ticket_price'] * $ticket['ticket_qty']);
|
||||
$ticket_name_meta = apply_filters('mep_event_order_meta_ticket_name_filter',$ticket_type_name,$ticket);
|
||||
$item->add_meta_data($ticket_name_meta, $ticket_type_val);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
if (!function_exists('mep_get_event_expire_date')) {
|
||||
function mep_get_event_expire_date($event_id){
|
||||
$event_expire_on_old = mep_get_option('mep_event_expire_on_datetimes', 'general_setting_sec', 'event_start_datetime');
|
||||
|
@ -2702,6 +2786,7 @@ return $expire_date;
|
|||
}
|
||||
|
||||
|
||||
|
||||
add_action('mep_event_single_template_end','mep_single_page_js_script');
|
||||
add_action('mep_add_to_cart_shortcode_js','mep_single_page_js_script');
|
||||
if (!function_exists('mep_single_page_js_script')) {
|
||||
|
@ -2750,11 +2835,7 @@ function mep_single_page_js_script($event_id){
|
|||
//Bind the change event
|
||||
jQuery(".extra-qty-box").on('change', function() {
|
||||
var sum = 0;
|
||||
var total = <?php if ($event_meta['_price'][0]) {
|
||||
echo $event_meta['_price'][0];
|
||||
} else {
|
||||
echo 0;
|
||||
} ?>;
|
||||
var total = 0;
|
||||
jQuery('.price_jq').each(function() {
|
||||
var price = jQuery(this);
|
||||
var count = price.closest('tr').find('.extra-qty-box');
|
||||
|
@ -2857,9 +2938,7 @@ if (!function_exists('mep_single_page_script')) {
|
|||
function mep_single_page_script(){
|
||||
ob_start();
|
||||
?>
|
||||
<script>
|
||||
// jQuery('.mep-more-date-lists<?php echo $event_id; ?>, #hide_event_schdule<?php echo $event_id; ?>').hide();
|
||||
|
||||
<script>
|
||||
jQuery('#mep_single_view_all_date').click(function(){
|
||||
jQuery(this).hide()
|
||||
jQuery('#mep_event_date_sch').addClass('mep_view_all_date');
|
||||
|
|
|
@ -2,12 +2,13 @@
|
|||
if ( ! defined( 'ABSPATH' ) ) { die; } // Cannot access pages directly.
|
||||
function mep_cpt_tax(){
|
||||
|
||||
$event_label = mep_get_option('mep_event_label', 'general_setting_sec', 'Events');
|
||||
|
||||
$labels = array(
|
||||
'name' => _x( 'Event Category','mage-eventpress' ),
|
||||
'singular_name' => _x( 'Event Category','mage-eventpress' ),
|
||||
'name' => _x( $event_label.' Category','mage-eventpress' ),
|
||||
'singular_name' => _x( $event_label.' Category','mage-eventpress' ),
|
||||
'menu_name' => __( 'Category', 'mage-eventpress' ),
|
||||
'all_items' => __( 'All Event Category', 'mage-eventpress' ),
|
||||
'all_items' => __( 'All '.$event_label.' Category', 'mage-eventpress' ),
|
||||
'parent_item' => __( 'Parent Category', 'mage-eventpress' ),
|
||||
'parent_item_colon' => __( 'Parent Category:', 'mage-eventpress' ),
|
||||
'new_item_name' => __( 'New Category Name', 'mage-eventpress' ),
|
||||
|
@ -40,10 +41,10 @@ register_taxonomy('mep_cat', 'mep_events', $args);
|
|||
|
||||
|
||||
$labelso = array(
|
||||
'name' => _x( 'Event Organizer','mage-eventpress' ),
|
||||
'singular_name' => _x( 'Event Organizer','mage-eventpress' ),
|
||||
'name' => _x( $event_label.' Organizer','mage-eventpress' ),
|
||||
'singular_name' => _x( $event_label.' Organizer','mage-eventpress' ),
|
||||
'menu_name' => __( 'Organizer', 'mage-eventpress' ),
|
||||
'all_items' => __( 'All Event Organizer', 'mage-eventpress' ),
|
||||
'all_items' => __( 'All '.$event_label.' Organizer', 'mage-eventpress' ),
|
||||
'parent_item' => __( 'Parent Organizer', 'mage-eventpress' ),
|
||||
'parent_item_colon' => __( 'Parent Organizer:', 'mage-eventpress' ),
|
||||
'new_item_name' => __( 'New Organizer Name', 'mage-eventpress' ),
|
||||
|
|
|
@ -59,7 +59,6 @@ add_action('admin_init', 'mep_flash_permalink_once');
|
|||
|
||||
|
||||
add_action('admin_init', 'mep_get_all_order_data_and_create_attendee');
|
||||
|
||||
function mep_get_all_order_data_and_create_attendee()
|
||||
{
|
||||
|
||||
|
@ -305,6 +304,41 @@ function mep_get_all_order_data_and_create_attendee()
|
|||
}
|
||||
update_option('mep_event_magor_update_3', 'completed');
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Update Ticket Price for all existing event attendee
|
||||
*/
|
||||
|
||||
if (get_option('mep_attendee_price_update_2') != 'completed') {
|
||||
$args = array(
|
||||
'post_type' => 'mep_events_attendees',
|
||||
'posts_per_page' => -1
|
||||
);
|
||||
$qr = new WP_Query($args);
|
||||
foreach ($qr->posts as $result) {
|
||||
$post_id = $result->ID;
|
||||
$ea_ticket_price = get_post_meta($post_id, 'ea_ticket_price', true);
|
||||
// if (empty($ea_ticket_price)) {
|
||||
$event_id = get_post_meta($post_id, 'ea_event_id', true);
|
||||
$ea_ticket_type = get_post_meta($post_id, 'ea_ticket_type', true);
|
||||
$ticket_total_price = mep_get_event_ticket_price_by_name($event_id,$ea_ticket_type);
|
||||
update_post_meta($post_id, 'ea_ticket_price', $ticket_total_price);
|
||||
// }
|
||||
}
|
||||
update_option('mep_attendee_price_update_2', 'completed');
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -73,6 +73,7 @@ function mep_user_custom_styles()
|
|||
.mep_list_event_details p.read-more a{
|
||||
color: <?php echo $base_color; ?>;
|
||||
}
|
||||
<?php do_action('mep_event_user_custom_styling'); ?>
|
||||
</style>
|
||||
<?php
|
||||
}
|
||||
|
|
|
@ -15,7 +15,7 @@ if (!function_exists('mep_get_event_reg_btn')) {
|
|||
$event_expire_on_old = mep_get_option('mep_event_expire_on_datetimes', 'general_setting_sec', 'event_start_datetime');
|
||||
$event_expire_on = $event_expire_on_old == 'event_end_datetime' ? 'event_expire_datetime' : $event_expire_on_old;
|
||||
$event_expire_date = $event_meta[$event_expire_on][0];
|
||||
$event_sqi = $event_meta['mep_sqi'][0];
|
||||
// $event_sqi = array_key_exists('mep_sqi',$event_meta) ? $event_meta['mep_sqi'][0] : '';
|
||||
$mep_full_name = strip_tags($event_meta['mep_full_name'][0]);
|
||||
$mep_reg_email = strip_tags($event_meta['mep_reg_email'][0]);
|
||||
$mep_reg_phone = strip_tags($event_meta['mep_reg_phone'][0]);
|
||||
|
@ -65,9 +65,10 @@ if (!function_exists('mep_get_event_reg_btn')) {
|
|||
$dd = $days > 0 ? $days . " days " : '';
|
||||
$hh = $hours > 0 ? $hours . " hours " : '';
|
||||
$mm = $minutes > 0 ? $minutes . " minutes " : '';
|
||||
$qty_typec = $event_meta['qty_box_type'][0];
|
||||
// $qty_typec = array_key_exists('qty_box_type',$event_meta) ? $event_meta['qty_box_type'][0] : '';
|
||||
$cart_product_id = get_post_meta($post_id, 'link_wc_product', true) ? esc_attr(get_post_meta($post_id, 'link_wc_product', true)) : esc_attr($post_id);
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* First Checking If the registration status enable or disable
|
||||
|
@ -76,7 +77,7 @@ if (!function_exists('mep_get_event_reg_btn')) {
|
|||
/**
|
||||
* Then Checking If the event date already gone or not
|
||||
*/
|
||||
if (strtotime(current_time('Y-m-d H:i:s')) > strtotime($newformat)) {
|
||||
if (strtotime(current_time('Y-m-d H:i:s')) > strtotime(apply_filters('mep_event_expire_datetime_val',$newformat,$post_id))) {
|
||||
/**
|
||||
* If The event expired then it fire below Hook, The event expire texts arein the inc/template-parts/event_labels.php file
|
||||
*/
|
||||
|
@ -154,7 +155,7 @@ if (!function_exists('mep_get_event_reg_btn_list')) {
|
|||
$event_expire_on_old = mep_get_option('mep_event_expire_on_datetimes', 'general_setting_sec', 'event_start_datetime');
|
||||
$event_expire_on = $event_expire_on_old == 'event_end_datetime' ? 'event_expire_datetime' : $event_expire_on_old;
|
||||
$event_expire_date = $event_meta[$event_expire_on][0];
|
||||
$event_sqi = $event_meta['mep_sqi'][0];
|
||||
// $event_sqi = $event_meta['mep_sqi'][0];
|
||||
$mep_full_name = strip_tags($event_meta['mep_full_name'][0]);
|
||||
$mep_reg_email = strip_tags($event_meta['mep_reg_email'][0]);
|
||||
$mep_reg_phone = strip_tags($event_meta['mep_reg_phone'][0]);
|
||||
|
@ -207,7 +208,7 @@ if (!function_exists('mep_get_event_reg_btn_list')) {
|
|||
$dd = $days > 0 ? $days . " days " : '';
|
||||
$hh = $hours > 0 ? $hours . " hours " : '';
|
||||
$mm = $minutes > 0 ? $minutes . " minutes " : '';
|
||||
$qty_typec = $event_meta['qty_box_type'][0];
|
||||
// $qty_typec = $event_meta['qty_box_type'][0];
|
||||
$cart_product_id = get_post_meta($post_id, 'link_wc_product', true) ? esc_attr(get_post_meta($post_id, 'link_wc_product', true)) : esc_attr($post_id);
|
||||
|
||||
|
||||
|
|
|
@ -90,9 +90,7 @@ if (!function_exists('mep_date_in_default_theme')) {
|
|||
$mep_show_upcoming_event = get_post_meta($event_id, 'mep_show_upcoming_event', true) ? get_post_meta($event_id, 'mep_show_upcoming_event', true) : 'no';
|
||||
$cn = 1;
|
||||
$more_date = array_key_exists('mep_event_more_date', $event_meta) ? unserialize($event_meta['mep_event_more_date'][0]) : array();
|
||||
?>
|
||||
<h3><i class="fa fa-calendar"></i> <?php echo mep_get_option('mep_event_schedule_text', 'label_setting_sec', __('Event Schedule Details', 'mage-eventpress')); ?></h3>
|
||||
<?php
|
||||
require(mep_template_file_path('single/date_list_title.php'));
|
||||
if (sizeof($more_date) > 2) {
|
||||
echo '<ul id="mep_event_date_sch">';
|
||||
} else {
|
||||
|
@ -101,14 +99,14 @@ if (!function_exists('mep_date_in_default_theme')) {
|
|||
|
||||
if ($recurring == 'yes') {
|
||||
if (strtotime(current_time('Y-m-d H:i')) < strtotime($start_datetime)) {
|
||||
?>
|
||||
<li><i class="fa fa-calendar"></i> <?php echo get_mep_datetime($start_datetime, 'date-text'); ?> <br><i class="fa fa-clock-o"></i> <?php echo get_mep_datetime($start_datetime, 'time'); ?> - <?php if ($start_date != $end_date) {
|
||||
echo get_mep_datetime($end_datetime, 'date-text') . ' - ';
|
||||
}
|
||||
echo get_mep_datetime($end_datetime, 'time'); ?></li>
|
||||
<?php
|
||||
require(mep_template_file_path('single/date_list.php'));
|
||||
}
|
||||
foreach ($more_date as $_more_date) {
|
||||
$start_date = $_more_date['event_more_start_date'];
|
||||
$end_date = $_more_date['event_more_end_date'];
|
||||
$start_datetime = $_more_date['event_more_start_date'] . ' ' . $_more_date['event_more_start_time'];
|
||||
$end_datetime = $_more_date['event_more_end_date'] . ' ' . $_more_date['event_more_end_time'];
|
||||
|
||||
if (strtotime(current_time('Y-m-d H:i')) < strtotime($_more_date['event_more_start_date'] . ' ' . $_more_date['event_more_start_time'])) {
|
||||
if ($mep_show_upcoming_event == 'yes') {
|
||||
$cnt = 1;
|
||||
|
@ -116,43 +114,23 @@ if (!function_exists('mep_date_in_default_theme')) {
|
|||
$cnt = $cn;
|
||||
}
|
||||
if ($cn == $cnt) {
|
||||
?>
|
||||
<li><i class="fa fa-calendar"></i> <?php echo get_mep_datetime($_more_date['event_more_start_date'] . ' ' . $_more_date['event_more_start_time'], 'date-text'); ?> <br><i class="fa fa-clock-o"></i> <?php echo get_mep_datetime($_more_date['event_more_start_date'] . ' ' . $_more_date['event_more_start_time'], 'time'); ?> - <?php if ($_more_date['event_more_start_date'] != $_more_date['event_more_end_date']) {
|
||||
echo get_mep_datetime($_more_date['event_more_end_date'] . ' ' . $_more_date['event_more_end_time'], 'date-text') . ' - ';
|
||||
}
|
||||
echo get_mep_datetime($_more_date['event_more_end_date'] . ' ' . $_more_date['event_more_end_time'], 'time'); ?></li>
|
||||
<?php
|
||||
require(mep_template_file_path('single/date_list.php'));
|
||||
$cn++;
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if (is_array($more_date) && sizeof($more_date) > 0) {
|
||||
?>
|
||||
<li><i class="fa fa-calendar"></i> <?php echo get_mep_datetime($start_datetime, 'date-text'); ?><br>
|
||||
<i class="fa fa-clock-o"></i> <?php echo get_mep_datetime($start_datetime, 'time'); ?> <?php if ($start_date != $end_date) {
|
||||
echo ' - ' . get_mep_datetime($end_datetime, 'date-text');
|
||||
}
|
||||
echo ' - ' . get_mep_datetime($end_datetime, 'time'); ?></li>
|
||||
<?php
|
||||
|
||||
|
||||
require(mep_template_file_path('single/date_list.php'));
|
||||
foreach ($more_date as $_more_date) {
|
||||
?>
|
||||
<li><i class="fa fa-calendar"></i> <?php echo get_mep_datetime($_more_date['event_more_start_date'] . ' ' . $_more_date['event_more_start_time'], 'date-text'); ?> <br><i class="fa fa-clock-o"></i> <?php echo get_mep_datetime($_more_date['event_more_start_date'] . ' ' . $_more_date['event_more_start_time'], 'time'); ?> - <?php if ($_more_date['event_more_start_date'] != $_more_date['event_more_end_date']) {
|
||||
echo get_mep_datetime($_more_date['event_more_end_date'] . ' ' . $_more_date['event_more_end_time'], 'date-text') . ' - ';
|
||||
}
|
||||
echo get_mep_datetime($_more_date['event_more_end_date'] . ' ' . $_more_date['event_more_end_time'], 'time'); ?></li>
|
||||
<?php
|
||||
$start_date = $_more_date['event_more_start_date'];
|
||||
$end_date = $_more_date['event_more_end_date'];
|
||||
$start_datetime = $_more_date['event_more_start_date'] . ' ' . $_more_date['event_more_start_time'];
|
||||
$end_datetime = $_more_date['event_more_end_date'] . ' ' . $_more_date['event_more_end_time'];
|
||||
require(mep_template_file_path('single/date_list.php'));
|
||||
}
|
||||
} else {
|
||||
|
||||
?>
|
||||
<li><i class="fa fa-calendar"></i> <?php echo get_mep_datetime($start_datetime, 'date-text'); ?> <br><i class="fa fa-clock-o"></i> <?php echo get_mep_datetime($start_datetime, 'time'); ?> - <?php if ($start_date != $end_date) {
|
||||
echo get_mep_datetime($end_datetime, 'date-text') . ' - ';
|
||||
}
|
||||
echo get_mep_datetime($end_datetime, 'time'); ?></li>
|
||||
<?php
|
||||
require(mep_template_file_path('single/date_list.php'));
|
||||
}
|
||||
}
|
||||
echo '</ul>';
|
||||
|
|
|
@ -12,7 +12,7 @@ if (!function_exists('mep_ev_details')) {
|
|||
$content = $content_event->post_content;
|
||||
$content = apply_filters('the_content', $content);
|
||||
$content = str_replace(']]>', ']]>', $content);
|
||||
echo apply_filters('mep_event_details_content', $content, get_the_id());
|
||||
require(mep_template_file_path('single/details.php'));
|
||||
do_action('mep_after_event_details');
|
||||
}
|
||||
}
|
||||
|
@ -25,19 +25,7 @@ if (!function_exists('mep_display_event_daywise_details')) {
|
|||
global $post, $event_meta;
|
||||
$mep_event_day = get_post_meta($post->ID, 'mep_event_day', true) ? get_post_meta($post->ID, 'mep_event_day', true) : array();
|
||||
if (sizeof($mep_event_day) > 0) {
|
||||
echo '<div class="mep-day-details-section">';
|
||||
?>
|
||||
<h4><?php _e('Event Days', 'mage-eventpress'); ?></h4>
|
||||
<?php
|
||||
foreach ($mep_event_day as $field) {
|
||||
?>
|
||||
<div class="mep-day-title"><?php echo $field['mep_day_title']; ?></div>
|
||||
<div class="mep-day-details">
|
||||
<p><?php echo $field['mep_day_content']; ?></p>
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
echo '</div>';
|
||||
require(mep_template_file_path('single/daywise_details.php'));
|
||||
}
|
||||
}
|
||||
}
|
|
@ -13,65 +13,7 @@ if (!function_exists('mep_ev_extra_serv')) {
|
|||
$mep_events_extra_prices = get_post_meta($post_id, 'mep_events_extra_prices', true) ? get_post_meta($post_id, 'mep_events_extra_prices', true) : array();
|
||||
ob_start();
|
||||
if (sizeof($mep_events_extra_prices) > 0) {
|
||||
echo "<h3 class='ex-sec-title'>" . mep_get_label($post_id, 'mep_event_extra_service_text', 'Extra Service:') . "</h3>";
|
||||
?>
|
||||
<table>
|
||||
<tr>
|
||||
<td align="left"><?php echo mep_get_option('mep_name_text', 'label_setting_sec', __('Name:', 'mage-eventpress')); ?></td>
|
||||
<td class="mage_text_center"><?php echo mep_get_option('mep_quantity_text', 'label_setting_sec', __('Quantity:', 'mage-eventpress')); ?></td>
|
||||
<td class="mage_text_center"><?php echo mep_get_option('mep_price_text', 'label_setting_sec', __('Price:', 'mage-eventpress')); ?></td>
|
||||
</tr>
|
||||
<?php
|
||||
foreach ($mep_events_extra_prices as $field) {
|
||||
$event_date = get_post_meta($post_id, 'event_start_date', true) . ' ' . get_post_meta($post_id, 'event_start_time', true);
|
||||
$total_extra_service = (int) $field['option_qty'];
|
||||
$qty_type = $field['option_qty_type'];
|
||||
$total_sold = (int) mep_extra_service_sold($post_id, $field['option_name'], $event_date);
|
||||
$ext_left = ($total_extra_service - $total_sold);
|
||||
?>
|
||||
<tr>
|
||||
<td align="Left"><?php echo $field['option_name']; ?>
|
||||
<div class="xtra-item-left"><?php echo $ext_left; ?>
|
||||
<?php echo mep_get_option('mep_left_text', 'label_setting_sec') ? mep_get_option('mep_left_text', 'label_setting_sec') : _e('Left:', 'mage-eventpress'); ?>
|
||||
</div>
|
||||
<input type="hidden" name='mep_event_start_date_es[]' value='<?php echo $event_date; ?>'>
|
||||
</td>
|
||||
<td class="mage_text_center">
|
||||
<?php
|
||||
if ($ext_left > 0) {
|
||||
if ($qty_type == 'dropdown') { ?>
|
||||
<select name="event_extra_service_qty[]" id="eventpxtp_<?php //echo $count;
|
||||
?>" class='extra-qty-box'>
|
||||
<?php for ($i = 0; $i <= $ext_left; $i++) { ?>
|
||||
<option value="<?php echo $i; ?>"><?php echo $i; ?> <?php echo $field['option_name']; ?></option>
|
||||
<?php } ?>
|
||||
</select>
|
||||
<?php } else { ?>
|
||||
<div class="mage_input_group">
|
||||
<span class="fa fa-minus qty_dec"></span>
|
||||
<input id="eventpx" <?php //if($ext_left<=0){ echo "disabled"; }
|
||||
?> size="4" inputmode="numeric" type="text" class='extra-qty-box' name='event_extra_service_qty[]' data-price='<?php echo $field['option_price']; ?>' value='0' min="0" max="<?php echo $ext_left; ?>">
|
||||
<span class="fa fa-plus qty_inc"></span>
|
||||
</div>
|
||||
<?php }
|
||||
} else {
|
||||
echo mep_get_option('mep_not_available_text', 'label_setting_sec') ? mep_get_option('mep_not_available_text', 'label_setting_sec') : _e('Not Available', 'mage-eventpress');
|
||||
} ?>
|
||||
</td>
|
||||
<td class="mage_text_center"><?php echo wc_price($field['option_price']);
|
||||
if ($ext_left > 0) { ?>
|
||||
<p style="display: none;" class="price_jq"><?php echo $field['option_price']; ?></p>
|
||||
<input type="hidden" name='event_extra_service_name[]' value='<?php echo $field['option_name']; ?>'>
|
||||
<input type="hidden" name='event_extra_service_price[]' value='<?php echo $field['option_price']; ?>'>
|
||||
<?php } ?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php
|
||||
$count++;
|
||||
}
|
||||
?>
|
||||
</table>
|
||||
<?php
|
||||
require(mep_template_file_path('single/extra_service_list.php'));
|
||||
}
|
||||
$content = ob_get_clean();
|
||||
$event_meta = get_post_custom($post_id);
|
||||
|
|
|
@ -321,21 +321,7 @@ function mep_event_address_list_sidebar_html($event_id){
|
|||
$state = !empty($location_sts) ? get_term_meta( $org_id, 'org_state', true ) : get_post_meta($event_id,'mep_state',true);
|
||||
$country = !empty($location_sts) ? get_term_meta( $org_id, 'org_country', true ) : get_post_meta($event_id,'mep_country',true);
|
||||
ob_start();
|
||||
?>
|
||||
<ul>
|
||||
<?php if($venue){ ?> <li><i class="fa fa-arrow-circle-right"></i> <?php do_action('mep_event_location_venue'); ?>
|
||||
</li> <?php } ?>
|
||||
<?php if($street){ ?><li><i class="fa fa-arrow-circle-right"></i> <?php do_action('mep_event_location_street'); ?>
|
||||
</li><?php } ?>
|
||||
<?php if($city){ ?><li><i class="fa fa-arrow-circle-right"></i> <?php do_action('mep_event_location_city'); ?></li>
|
||||
<?php } ?>
|
||||
<?php if($state){ ?><li><i class="fa fa-arrow-circle-right"></i> <?php do_action('mep_event_location_state'); ?>
|
||||
</li><?php } ?>
|
||||
<?php if($country){ ?><li><i class="fa fa-arrow-circle-right"></i>
|
||||
<?php do_action('mep_event_location_country'); ?><?php } ?>
|
||||
</li>
|
||||
</ul>
|
||||
<?php
|
||||
require(mep_template_file_path('single/location_list.php'));
|
||||
echo ob_get_clean();
|
||||
}
|
||||
}
|
|
@ -9,7 +9,6 @@ if (!function_exists('mep_display_event_loop_list')) {
|
|||
{
|
||||
$now = current_time('Y-m-d H:i:s');
|
||||
$show_price = mep_get_option('mep_event_price_show', 'general_setting_sec', 'yes');
|
||||
|
||||
$show_price_label = mep_get_option('event-price-label', 'general_setting_sec', 'Price Starts from:');
|
||||
$event_meta = get_post_custom($event_id);
|
||||
$author_terms = get_the_terms($event_id, 'mep_org') ? get_the_terms($event_id, 'mep_org') : [];
|
||||
|
@ -28,109 +27,11 @@ if (!function_exists('mep_display_event_loop_list')) {
|
|||
$recurring = get_post_meta($event_id, 'mep_enable_recurring', true) ? get_post_meta($event_id, 'mep_enable_recurring', true) : 'no';
|
||||
$event_type = get_post_meta(get_the_id(), 'mep_event_type', true) ? get_post_meta(get_the_id(), 'mep_event_type', true) : 'offline';
|
||||
ob_start();
|
||||
require(mep_template_file_path('list/default.php'));
|
||||
?>
|
||||
<div class='mep-event-list-loop <?php echo $columnNumber; ?> mep_event_<?php echo $style; ?>_item mix <?php if ($tt) { echo $org_class; } ?> <?php if ($torg) { echo $cat_class; } ?>'>
|
||||
<?php do_action('mep_event_list_loop_header', $event_id); ?>
|
||||
<div class="mep_list_thumb">
|
||||
<a href="<?php echo get_the_permalink($event_id); ?>"><?php echo get_the_post_thumbnail($event_id, 'full'); ?></a>
|
||||
<?php if (sizeof($event_multidate) == 0) { ?>
|
||||
<div class="mep-ev-start-date">
|
||||
<div class="mep-day"><?php echo get_mep_datetime($event_meta['event_start_datetime'][0], 'day'); ?></div>
|
||||
<div class="mep-month"><?php echo get_mep_datetime($event_meta['event_start_datetime'][0], 'month'); ?></div>
|
||||
</div>
|
||||
<?php }
|
||||
if (is_array($event_multidate) && sizeof($event_multidate) > 0) { ?>
|
||||
<div class='mep-multidate-ribbon mep-tem3-title-sec'>
|
||||
<span><?php _e('Multi Date Event', 'mage-eventpress'); ?></span>
|
||||
</div>
|
||||
<?php }
|
||||
if ($event_type == 'online') { ?>
|
||||
<div class='mep-eventtype-ribbon mep-tem3-title-sec'>
|
||||
<span><?php echo mep_get_option('mep_event_virtual_label', 'label_setting_sec') ? mep_get_option('mep_event_virtual_label', 'label_setting_sec') : _e('Virtual Event', 'mage-eventpress'); ?></span>
|
||||
</div>
|
||||
<?php } ?>
|
||||
</div>
|
||||
<div class="mep_list_event_details">
|
||||
<a href="<?php the_permalink(); ?>">
|
||||
<div class="mep-list-header">
|
||||
<h2 class='mep_list_title'><?php the_title(); ?></h2>
|
||||
<?php if ($available_seat == 0) {
|
||||
do_action('mep_show_waitlist_label');
|
||||
} ?>
|
||||
<h3 class='mep_list_date'>
|
||||
<?php if ($show_price == 'yes') {
|
||||
echo $show_price_label . " " . mep_event_list_price($event_id);
|
||||
} ?>
|
||||
</h3>
|
||||
</div>
|
||||
<?php
|
||||
if ($style == 'list') {
|
||||
?>
|
||||
<div class="mep-event-excerpt">
|
||||
<?php the_excerpt(); ?>
|
||||
</div>
|
||||
<?php } ?>
|
||||
|
||||
<div class="mep-list-footer">
|
||||
<ul>
|
||||
<?php
|
||||
if ($hide_org_list == 'no') {
|
||||
if(sizeof($author_terms) > 0) {
|
||||
?>
|
||||
<li>
|
||||
<div class="evl-ico"><i class="fa fa-university"></i></div>
|
||||
<div class="evl-cc">
|
||||
<h5>
|
||||
<?php echo mep_get_option('mep_organized_by_text', 'label_setting_sec') ? mep_get_option('mep_organized_by_text', 'label_setting_sec') : _e('Organized By:', 'mage-eventpress'); ?>
|
||||
</h5>
|
||||
<h6><?php
|
||||
echo $author_terms[0]->name;
|
||||
?></h6>
|
||||
</div>
|
||||
</li>
|
||||
<?php } }
|
||||
if ($event_type != 'online') {
|
||||
if ($hide_location_list == 'no') { ?>
|
||||
|
||||
<li>
|
||||
<div class="evl-ico"><i class="fa fa-location-arrow"></i></div>
|
||||
<div class="evl-cc">
|
||||
<h5>
|
||||
<?php echo mep_get_option('mep_location_text', 'label_setting_sec') ? mep_get_option('mep_location_text', 'label_setting_sec') : _e('Location:', 'mage-eventpress'); ?>
|
||||
|
||||
</h5>
|
||||
<h6><?php mep_get_event_city($event_id); ?></h6>
|
||||
</div>
|
||||
</li>
|
||||
<?php }
|
||||
}
|
||||
if ($hide_time_list == 'no') {
|
||||
if (strtotime(current_time('Y-m-d H:i')) < strtotime($event_meta['event_start_datetime'][0])) {
|
||||
?>
|
||||
<li>
|
||||
<div class="evl-ico"><i class="fa fa-calendar"></i></div>
|
||||
<div class="evl-cc">
|
||||
<h5>
|
||||
<?php if (sizeof($event_multidate) > 0) {
|
||||
|
||||
echo get_mep_datetime($event_meta['event_start_datetime'][0], 'date-text');
|
||||
}
|
||||
?>
|
||||
<?php echo mep_get_option('mep_time_text', 'label_setting_sec') ? mep_get_option('mep_time_text', 'label_setting_sec') : _e('Time:', 'mage-eventpress'); ?>
|
||||
</h5>
|
||||
<h6><?php echo get_mep_datetime($event_meta['event_start_datetime'][0], 'time');
|
||||
if ($hide_only_end_time_list == 'no') { ?> - <?php echo get_mep_datetime($event_meta['event_end_datetime'][0], 'time'); } ?></h6>
|
||||
</div>
|
||||
</li>
|
||||
<?php } } ?>
|
||||
</ul>
|
||||
</a>
|
||||
<?php do_action('mep_event_list_loop_footer', $event_id); ?>
|
||||
</div>
|
||||
</div>
|
||||
<?php do_action('mep_event_list_loop_end', $event_id); ?>
|
||||
</div>
|
||||
<?php
|
||||
<?php
|
||||
$content = ob_get_clean();
|
||||
echo apply_filters('mage_event_loop_list_shortcode', $content, $event_id, $style);
|
||||
}
|
||||
|
|
|
@ -6,68 +6,38 @@ if (!defined('ABSPATH')) {
|
|||
/**
|
||||
* This is the templates of the event minimal list shortcode
|
||||
*/
|
||||
add_filter('mage_event_loop_list_shortcode','mep_event_loop_minimal_style',10,3);
|
||||
add_filter('mage_event_loop_list_shortcode', 'mep_event_loop_minimal_style', 10, 3);
|
||||
if (!function_exists('mep_event_loop_minimal_style')) {
|
||||
function mep_event_loop_minimal_style($content, $event_id,$style){
|
||||
if($style == 'minimal'){
|
||||
|
||||
$now = current_time('Y-m-d H:i:s');
|
||||
$show_price = mep_get_option('mep_event_price_show', 'general_setting_sec', 'yes');
|
||||
$show_price_label = mep_get_option('event-price-label', 'general_setting_sec', 'Price Starts from:');
|
||||
$event_meta = get_post_custom($event_id);
|
||||
$author_terms = get_the_terms($event_id, 'mep_org');
|
||||
$time = strtotime($event_meta['event_start_date'][0] . ' ' . $event_meta['event_start_time'][0]);
|
||||
$newformat = date_i18n('Y-m-d H:i:s', $time);
|
||||
$tt = get_the_terms($event_id, 'mep_cat');
|
||||
$torg = get_the_terms($event_id, 'mep_org');
|
||||
$org_class = mep_get_term_as_class($event_id, 'mep_org');
|
||||
$cat_class = mep_get_term_as_class($event_id, 'mep_cat');
|
||||
$event_multidate = array_key_exists('mep_event_more_date', $event_meta) ? maybe_unserialize($event_meta['mep_event_more_date'][0]) : array();
|
||||
$available_seat = mep_get_total_available_seat($event_id, $event_meta);
|
||||
$hide_org_list = mep_get_option('mep_event_hide_organizer_list', 'general_setting_sec', 'no');
|
||||
$hide_location_list = mep_get_option('mep_event_hide_location_list', 'general_setting_sec', 'no');
|
||||
$hide_time_list = mep_get_option('mep_event_hide_time_list', 'general_setting_sec', 'no');
|
||||
$hide_only_end_time_list = mep_get_option('mep_event_hide_end_time_list', 'general_setting_sec', 'no');
|
||||
$recurring = get_post_meta($event_id, 'mep_enable_recurring', true) ? get_post_meta($event_id, 'mep_enable_recurring', true) : 'no';
|
||||
$start_datetime = $event_meta['event_start_date'][0];
|
||||
$end_datetime = $event_meta['event_end_date'][0];
|
||||
|
||||
ob_start();
|
||||
?>
|
||||
<div class='mep-event-list-loop mep_event_list_item mep_event_minimal_list mix <?php if ($tt) { echo $org_class; } ?> <?php if ($torg) { echo $cat_class; } ?>'>
|
||||
<?php do_action('mep_event_minimal_list_loop_header',$event_id); ?>
|
||||
<div class="mep_list_thumb">
|
||||
<a href="<?php echo get_the_permalink($event_id); ?>"></a>
|
||||
<div class="mep-ev-start-date">
|
||||
<div class="mep-day"><?php echo mep_get_event_upcomming_date($event_id,'day'); //get_mep_datetime($event_meta['event_start_datetime'][0],'day'); ?></div>
|
||||
<div class="mep-month"><?php echo mep_get_event_upcomming_date($event_id,'month'); //get_mep_datetime($event_meta['event_start_datetime'][0],'month'); ?></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="mep_list_event_details">
|
||||
<a href="<?php the_permalink(); ?>">
|
||||
<div class="mep-list-header">
|
||||
<h2 class='mep_list_title'><?php the_title(); ?></h2>
|
||||
<?php
|
||||
mep_get_event_upcomming_date($event_id,1);
|
||||
?>
|
||||
<?php if ($available_seat == 0) {
|
||||
do_action('mep_show_waitlist_label');
|
||||
} ?>
|
||||
<h3 class='mep_list_date'> <span class='mep_minimal_list_date'><i class="fa fa-calendar"></i> <?php echo mep_get_event_upcomming_date($event_id,'time'); ?> - <?php if($start_datetime == $end_datetime){ echo get_mep_datetime($event_meta['event_end_datetime'][0],'time'); }else{ echo get_mep_datetime($event_meta['event_end_datetime'][0],'date-time-text'); } ?></span> <span class='mep_minimal_list_location'><i class='fa fa-map-marker'></i> <?php mep_get_event_city($event_id); ?></span></h3></a>
|
||||
<?php do_action('mep_event_list_loop_footer',$event_id); ?>
|
||||
</div>
|
||||
function mep_event_loop_minimal_style($content, $event_id, $style)
|
||||
{
|
||||
if ($style == 'minimal') {
|
||||
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
<?php do_action('mep_event_minimal_list_loop_end',$event_id); ?>
|
||||
</div>
|
||||
<?php
|
||||
$content = ob_get_clean();
|
||||
return $content;
|
||||
}else{
|
||||
return $content;
|
||||
$now = current_time('Y-m-d H:i:s');
|
||||
$show_price = mep_get_option('mep_event_price_show', 'general_setting_sec', 'yes');
|
||||
$show_price_label = mep_get_option('event-price-label', 'general_setting_sec', 'Price Starts from:');
|
||||
$event_meta = get_post_custom($event_id);
|
||||
$author_terms = get_the_terms($event_id, 'mep_org');
|
||||
$time = strtotime($event_meta['event_start_date'][0] . ' ' . $event_meta['event_start_time'][0]);
|
||||
$newformat = date_i18n('Y-m-d H:i:s', $time);
|
||||
$tt = get_the_terms($event_id, 'mep_cat');
|
||||
$torg = get_the_terms($event_id, 'mep_org');
|
||||
$org_class = mep_get_term_as_class($event_id, 'mep_org');
|
||||
$cat_class = mep_get_term_as_class($event_id, 'mep_cat');
|
||||
$event_multidate = array_key_exists('mep_event_more_date', $event_meta) ? maybe_unserialize($event_meta['mep_event_more_date'][0]) : array();
|
||||
$available_seat = mep_get_total_available_seat($event_id, $event_meta);
|
||||
$hide_org_list = mep_get_option('mep_event_hide_organizer_list', 'general_setting_sec', 'no');
|
||||
$hide_location_list = mep_get_option('mep_event_hide_location_list', 'general_setting_sec', 'no');
|
||||
$hide_time_list = mep_get_option('mep_event_hide_time_list', 'general_setting_sec', 'no');
|
||||
$hide_only_end_time_list = mep_get_option('mep_event_hide_end_time_list', 'general_setting_sec', 'no');
|
||||
$recurring = get_post_meta($event_id, 'mep_enable_recurring', true) ? get_post_meta($event_id, 'mep_enable_recurring', true) : 'no';
|
||||
$start_datetime = $event_meta['event_start_date'][0];
|
||||
$end_datetime = $event_meta['event_end_date'][0];
|
||||
ob_start();
|
||||
require(mep_template_file_path('list/minimal.php'));
|
||||
$content = ob_get_clean();
|
||||
return $content;
|
||||
} else {
|
||||
return $content;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -6,66 +6,39 @@ if (!defined('ABSPATH')) {
|
|||
/**
|
||||
* This is the templates of the event native list shortcode
|
||||
*/
|
||||
|
||||
add_filter('mage_event_loop_list_shortcode','mep_event_loop_native_style',10,3);
|
||||
|
||||
add_filter('mage_event_loop_list_shortcode', 'mep_event_loop_native_style', 10, 3);
|
||||
if (!function_exists('mep_event_loop_native_style')) {
|
||||
function mep_event_loop_native_style($content, $event_id,$style){
|
||||
if($style == 'native'){
|
||||
|
||||
$now = current_time('Y-m-d H:i:s');
|
||||
$show_price = mep_get_option('mep_event_price_show', 'general_setting_sec', 'yes');
|
||||
$show_price_label = mep_get_option('event-price-label', 'general_setting_sec', 'Price Starts from:');
|
||||
$event_meta = get_post_custom($event_id);
|
||||
$author_terms = get_the_terms($event_id, 'mep_org');
|
||||
$time = strtotime($event_meta['event_start_date'][0] . ' ' . $event_meta['event_start_time'][0]);
|
||||
$newformat = date_i18n('Y-m-d H:i:s', $time);
|
||||
$tt = get_the_terms($event_id, 'mep_cat');
|
||||
$torg = get_the_terms($event_id, 'mep_org');
|
||||
$org_class = mep_get_term_as_class($event_id, 'mep_org');
|
||||
$cat_class = mep_get_term_as_class($event_id, 'mep_cat');
|
||||
$event_multidate = array_key_exists('mep_event_more_date', $event_meta) ? maybe_unserialize($event_meta['mep_event_more_date'][0]) : array();
|
||||
$available_seat = mep_get_total_available_seat($event_id, $event_meta);
|
||||
$hide_org_list = mep_get_option('mep_event_hide_organizer_list', 'general_setting_sec', 'no');
|
||||
$hide_location_list = mep_get_option('mep_event_hide_location_list', 'general_setting_sec', 'no');
|
||||
$hide_time_list = mep_get_option('mep_event_hide_time_list', 'general_setting_sec', 'no');
|
||||
$hide_only_end_time_list = mep_get_option('mep_event_hide_end_time_list', 'general_setting_sec', 'no');
|
||||
$recurring = get_post_meta($event_id, 'mep_enable_recurring', true) ? get_post_meta($event_id, 'mep_enable_recurring', true) : 'no';
|
||||
$start_datetime = $event_meta['event_start_date'][0];
|
||||
$end_datetime = $event_meta['event_end_date'][0];
|
||||
|
||||
ob_start();
|
||||
?>
|
||||
<div class='mep-event-list-loop mep_event_list_item mep_event_native_list mix <?php if ($tt) { echo $org_class; } ?> <?php if ($torg) { echo $cat_class; } ?>'>
|
||||
<?php do_action('mep_event_minimal_list_loop_header',$event_id); ?>
|
||||
<div class="mep_list_thumb">
|
||||
<a href="<?php echo get_the_permalink($event_id); ?>"><?php echo get_the_post_thumbnail($event_id,'full'); ?></a>
|
||||
<!--<div class="mep-ev-start-date">-->
|
||||
<!-- <div class="mep-day"><?php echo get_mep_datetime($event_meta['event_start_datetime'][0],'day'); ?></div>-->
|
||||
<!-- <div class="mep-month"><?php echo get_mep_datetime($event_meta['event_start_datetime'][0],'month'); ?></div>-->
|
||||
<!--</div>-->
|
||||
</div>
|
||||
<div class="mep_list_event_details">
|
||||
<a href="<?php the_permalink(); ?>">
|
||||
<div class="mep-list-header">
|
||||
<h2 class='mep_list_title'><?php the_title(); ?></h2>
|
||||
<?php if ($available_seat == 0) {
|
||||
do_action('mep_show_waitlist_label');
|
||||
} ?>
|
||||
<h3 class='mep_list_date'> <span class='mep_minimal_list_date'><i class="fa fa-calendar"></i> <?php echo get_mep_datetime($event_meta['event_start_datetime'][0],'date-time-text'); ?> - <?php if($start_datetime == $end_datetime){ echo get_mep_datetime($event_meta['event_end_datetime'][0],'time'); }else{ echo get_mep_datetime($event_meta['event_end_datetime'][0],'date-time-text'); } ?></span> <span class='mep_minimal_list_location'><i class='fa fa-map-marker'></i> <?php mep_get_event_city($event_id); ?></span></h3></a>
|
||||
<?php do_action('mep_event_list_loop_footer',$event_id); ?>
|
||||
</div>
|
||||
function mep_event_loop_native_style($content, $event_id, $style)
|
||||
{
|
||||
if ($style == 'native') {
|
||||
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
<?php do_action('mep_event_minimal_list_loop_end',$event_id); ?>
|
||||
</div>
|
||||
<?php
|
||||
$content = ob_get_clean();
|
||||
return $content;
|
||||
}else{
|
||||
return $content;
|
||||
$now = current_time('Y-m-d H:i:s');
|
||||
$show_price = mep_get_option('mep_event_price_show', 'general_setting_sec', 'yes');
|
||||
$show_price_label = mep_get_option('event-price-label', 'general_setting_sec', 'Price Starts from:');
|
||||
$event_meta = get_post_custom($event_id);
|
||||
$author_terms = get_the_terms($event_id, 'mep_org');
|
||||
$time = strtotime($event_meta['event_start_date'][0] . ' ' . $event_meta['event_start_time'][0]);
|
||||
$newformat = date_i18n('Y-m-d H:i:s', $time);
|
||||
$tt = get_the_terms($event_id, 'mep_cat');
|
||||
$torg = get_the_terms($event_id, 'mep_org');
|
||||
$org_class = mep_get_term_as_class($event_id, 'mep_org');
|
||||
$cat_class = mep_get_term_as_class($event_id, 'mep_cat');
|
||||
$event_multidate = array_key_exists('mep_event_more_date', $event_meta) ? maybe_unserialize($event_meta['mep_event_more_date'][0]) : array();
|
||||
$available_seat = mep_get_total_available_seat($event_id, $event_meta);
|
||||
$hide_org_list = mep_get_option('mep_event_hide_organizer_list', 'general_setting_sec', 'no');
|
||||
$hide_location_list = mep_get_option('mep_event_hide_location_list', 'general_setting_sec', 'no');
|
||||
$hide_time_list = mep_get_option('mep_event_hide_time_list', 'general_setting_sec', 'no');
|
||||
$hide_only_end_time_list = mep_get_option('mep_event_hide_end_time_list', 'general_setting_sec', 'no');
|
||||
$recurring = get_post_meta($event_id, 'mep_enable_recurring', true) ? get_post_meta($event_id, 'mep_enable_recurring', true) : 'no';
|
||||
$start_datetime = $event_meta['event_start_date'][0];
|
||||
$end_datetime = $event_meta['event_end_date'][0];
|
||||
ob_start();
|
||||
require(mep_template_file_path('list/native.php'));
|
||||
$content = ob_get_clean();
|
||||
return $content;
|
||||
} else {
|
||||
return $content;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -6,100 +6,72 @@ if (!defined('ABSPATH')) {
|
|||
/**
|
||||
* This is the templates of the event timeline view shortcode
|
||||
*/
|
||||
|
||||
add_filter('mage_event_loop_list_shortcode','mep_event_loop_timeline_style',10,3);
|
||||
|
||||
add_filter('mage_event_loop_list_shortcode', 'mep_event_loop_timeline_style', 10, 3);
|
||||
if (!function_exists('mep_event_loop_timeline_style')) {
|
||||
function mep_event_loop_timeline_style($content, $event_id,$style){
|
||||
if($style == 'timeline'){
|
||||
|
||||
$now = current_time('Y-m-d H:i:s');
|
||||
$show_price = mep_get_option('mep_event_price_show', 'general_setting_sec', 'yes');
|
||||
$show_price_label = mep_get_option('event-price-label', 'general_setting_sec', 'Price Starts from:');
|
||||
$event_meta = get_post_custom($event_id);
|
||||
$author_terms = get_the_terms($event_id, 'mep_org');
|
||||
$time = strtotime($event_meta['event_start_date'][0] . ' ' . $event_meta['event_start_time'][0]);
|
||||
$newformat = date_i18n('Y-m-d H:i:s', $time);
|
||||
$tt = get_the_terms($event_id, 'mep_cat');
|
||||
$torg = get_the_terms($event_id, 'mep_org');
|
||||
$org_class = mep_get_term_as_class($event_id, 'mep_org');
|
||||
$cat_class = mep_get_term_as_class($event_id, 'mep_cat');
|
||||
$event_multidate = array_key_exists('mep_event_more_date', $event_meta) ? maybe_unserialize($event_meta['mep_event_more_date'][0]) : array();
|
||||
$available_seat = mep_get_total_available_seat($event_id, $event_meta);
|
||||
$hide_org_list = mep_get_option('mep_event_hide_organizer_list', 'general_setting_sec', 'no');
|
||||
$hide_location_list = mep_get_option('mep_event_hide_location_list', 'general_setting_sec', 'no');
|
||||
$hide_time_list = mep_get_option('mep_event_hide_time_list', 'general_setting_sec', 'no');
|
||||
$hide_only_end_time_list = mep_get_option('mep_event_hide_end_time_list', 'general_setting_sec', 'no');
|
||||
$recurring = get_post_meta($event_id, 'mep_enable_recurring', true) ? get_post_meta($event_id, 'mep_enable_recurring', true) : 'no';
|
||||
$start_datetime = $event_meta['event_start_date'][0];
|
||||
$end_datetime = $event_meta['event_end_date'][0];
|
||||
|
||||
ob_start();
|
||||
?>
|
||||
<div class="timeline__item">
|
||||
<div class="timeline__content">
|
||||
<div class='mep_event_timeline_list'>
|
||||
<?php do_action('mep_event_minimal_list_loop_header',$event_id); ?>
|
||||
<div class="mep_list_thumb">
|
||||
<a href="<?php echo get_the_permalink($event_id); ?>"><?php echo get_the_post_thumbnail($event_id,'full'); ?></a>
|
||||
<div class="mep-ev-start-date">
|
||||
<div class="mep-day"><?php echo get_mep_datetime($event_meta['event_start_datetime'][0],'day'); ?></div>
|
||||
<div class="mep-month"><?php echo get_mep_datetime($event_meta['event_start_datetime'][0],'month'); ?></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="mep_list_event_details">
|
||||
<a href="<?php the_permalink(); ?>">
|
||||
<div class="mep-list-header">
|
||||
<h2 class='mep_list_title'><?php the_title(); ?></h2>
|
||||
<?php if ($available_seat == 0) {
|
||||
do_action('mep_show_waitlist_label');
|
||||
} ?>
|
||||
<h3 class='mep_list_date'> <span class='mep_minimal_list_date'><i class="fa fa-calendar"></i> <?php echo get_mep_datetime($event_meta['event_start_datetime'][0],'time'); ?> - <?php if($start_datetime == $end_datetime){ echo get_mep_datetime($event_meta['event_end_datetime'][0],'time'); }else{ echo get_mep_datetime($event_meta['event_end_datetime'][0],'date-time-text'); } ?></span> <span class='mep_minimal_list_location'><i class='fa fa-map-marker'></i> <?php mep_get_event_city($event_id); ?></span></h3></a>
|
||||
<?php do_action('mep_event_list_loop_footer',$event_id); ?>
|
||||
</div>
|
||||
</div>
|
||||
<?php do_action('mep_event_minimal_list_loop_end',$event_id); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php
|
||||
$content = ob_get_clean();
|
||||
return $content;
|
||||
}else{
|
||||
return $content;
|
||||
function mep_event_loop_timeline_style($content, $event_id, $style)
|
||||
{
|
||||
if ($style == 'timeline') {
|
||||
$now = current_time('Y-m-d H:i:s');
|
||||
$show_price = mep_get_option('mep_event_price_show', 'general_setting_sec', 'yes');
|
||||
$show_price_label = mep_get_option('event-price-label', 'general_setting_sec', 'Price Starts from:');
|
||||
$event_meta = get_post_custom($event_id);
|
||||
$author_terms = get_the_terms($event_id, 'mep_org');
|
||||
$time = strtotime($event_meta['event_start_date'][0] . ' ' . $event_meta['event_start_time'][0]);
|
||||
$newformat = date_i18n('Y-m-d H:i:s', $time);
|
||||
$tt = get_the_terms($event_id, 'mep_cat');
|
||||
$torg = get_the_terms($event_id, 'mep_org');
|
||||
$org_class = mep_get_term_as_class($event_id, 'mep_org');
|
||||
$cat_class = mep_get_term_as_class($event_id, 'mep_cat');
|
||||
$event_multidate = array_key_exists('mep_event_more_date', $event_meta) ? maybe_unserialize($event_meta['mep_event_more_date'][0]) : array();
|
||||
$available_seat = mep_get_total_available_seat($event_id, $event_meta);
|
||||
$hide_org_list = mep_get_option('mep_event_hide_organizer_list', 'general_setting_sec', 'no');
|
||||
$hide_location_list = mep_get_option('mep_event_hide_location_list', 'general_setting_sec', 'no');
|
||||
$hide_time_list = mep_get_option('mep_event_hide_time_list', 'general_setting_sec', 'no');
|
||||
$hide_only_end_time_list = mep_get_option('mep_event_hide_end_time_list', 'general_setting_sec', 'no');
|
||||
$recurring = get_post_meta($event_id, 'mep_enable_recurring', true) ? get_post_meta($event_id, 'mep_enable_recurring', true) : 'no';
|
||||
$start_datetime = $event_meta['event_start_date'][0];
|
||||
$end_datetime = $event_meta['event_end_date'][0];
|
||||
ob_start();
|
||||
require(mep_template_file_path('list/timeline.php'));
|
||||
$content = ob_get_clean();
|
||||
return $content;
|
||||
} else {
|
||||
return $content;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
add_action('mep_event_shortcode_js_script','mep_shortcode_timeline_js_script');
|
||||
add_action('mep_event_shortcode_js_script', 'mep_shortcode_timeline_js_script');
|
||||
if (!function_exists('mep_shortcode_timeline_js_script')) {
|
||||
function mep_shortcode_timeline_js_script($params){
|
||||
$cat = $params['cat'];
|
||||
$org = $params['org'];
|
||||
$style = $params['style'];
|
||||
$cat_f = $params['cat-filter'];
|
||||
$org_f = $params['org-filter'];
|
||||
$show = $params['show'];
|
||||
$pagination = $params['pagination'];
|
||||
$sort = $params['sort'];
|
||||
$column = $style != 'grid' ? 1 : $params['column'];
|
||||
$nav = $params['carousal-nav'] == 'yes' ? 1 : 0;
|
||||
$dot = $params['carousal-dots'] == 'yes' ? 1 : 0;
|
||||
$city = $params['city'];
|
||||
$country = $params['country'];
|
||||
$cid = $params['carousal-id'];
|
||||
$tmode = $params['timeline-mode'];
|
||||
$main_div = $pagination == 'carousal' ? '<div class="mage_grid_box owl-theme owl-carousel" id="mep-carousel'.$cid.'">' : '<div class="mage_grid_box">';
|
||||
ob_start();
|
||||
if($style == 'timeline'){
|
||||
?>
|
||||
function mep_shortcode_timeline_js_script($params)
|
||||
{
|
||||
$cat = $params['cat'];
|
||||
$org = $params['org'];
|
||||
$style = $params['style'];
|
||||
$cat_f = $params['cat-filter'];
|
||||
$org_f = $params['org-filter'];
|
||||
$show = $params['show'];
|
||||
$pagination = $params['pagination'];
|
||||
$sort = $params['sort'];
|
||||
$column = $style != 'grid' ? 1 : $params['column'];
|
||||
$nav = $params['carousal-nav'] == 'yes' ? 1 : 0;
|
||||
$dot = $params['carousal-dots'] == 'yes' ? 1 : 0;
|
||||
$city = $params['city'];
|
||||
$country = $params['country'];
|
||||
$cid = $params['carousal-id'];
|
||||
$tmode = $params['timeline-mode'];
|
||||
$main_div = $pagination == 'carousal' ? '<div class="mage_grid_box owl-theme owl-carousel" id="mep-carousel' . $cid . '">' : '<div class="mage_grid_box">';
|
||||
ob_start();
|
||||
if ($style == 'timeline') {
|
||||
?>
|
||||
|
||||
jQuery('.timeline').timeline({
|
||||
mode: '<?php echo $tmode; ?>',
|
||||
visibleItems: 4
|
||||
});
|
||||
|
||||
<?php
|
||||
jQuery('.timeline').timeline({
|
||||
mode: '<?php echo $tmode; ?>',
|
||||
visibleItems: 4
|
||||
});
|
||||
<?php
|
||||
}
|
||||
echo ob_get_clean();
|
||||
}
|
||||
echo ob_get_clean();
|
||||
}
|
||||
}
|
|
@ -6,41 +6,39 @@ if (!defined('ABSPATH')) {
|
|||
/**
|
||||
* This is the templates of the event timeline view shortcode
|
||||
*/
|
||||
|
||||
add_filter('mage_event_loop_list_shortcode','mep_event_loop_title_style',10,3);
|
||||
|
||||
add_filter('mage_event_loop_list_shortcode', 'mep_event_loop_title_style', 10, 3);
|
||||
if (!function_exists('mep_event_loop_title_style')) {
|
||||
function mep_event_loop_title_style($content, $event_id,$style){
|
||||
if($style == 'title'){
|
||||
|
||||
$now = current_time('Y-m-d H:i:s');
|
||||
$show_price = mep_get_option('mep_event_price_show', 'general_setting_sec', 'yes');
|
||||
$show_price_label = mep_get_option('event-price-label', 'general_setting_sec', 'Price Starts from:');
|
||||
$event_meta = get_post_custom($event_id);
|
||||
$author_terms = get_the_terms($event_id, 'mep_org');
|
||||
$time = strtotime($event_meta['event_start_date'][0] . ' ' . $event_meta['event_start_time'][0]);
|
||||
$newformat = date_i18n('Y-m-d H:i:s', $time);
|
||||
$tt = get_the_terms($event_id, 'mep_cat');
|
||||
$torg = get_the_terms($event_id, 'mep_org');
|
||||
$org_class = mep_get_term_as_class($event_id, 'mep_org');
|
||||
$cat_class = mep_get_term_as_class($event_id, 'mep_cat');
|
||||
$event_multidate = array_key_exists('mep_event_more_date', $event_meta) ? maybe_unserialize($event_meta['mep_event_more_date'][0]) : array();
|
||||
$available_seat = mep_get_total_available_seat($event_id, $event_meta);
|
||||
$hide_org_list = mep_get_option('mep_event_hide_organizer_list', 'general_setting_sec', 'no');
|
||||
$hide_location_list = mep_get_option('mep_event_hide_location_list', 'general_setting_sec', 'no');
|
||||
$hide_time_list = mep_get_option('mep_event_hide_time_list', 'general_setting_sec', 'no');
|
||||
$hide_only_end_time_list = mep_get_option('mep_event_hide_end_time_list', 'general_setting_sec', 'no');
|
||||
$recurring = get_post_meta($event_id, 'mep_enable_recurring', true) ? get_post_meta($event_id, 'mep_enable_recurring', true) : 'no';
|
||||
$start_datetime = $event_meta['event_start_date'][0];
|
||||
$end_datetime = $event_meta['event_end_date'][0];
|
||||
|
||||
ob_start();
|
||||
?>
|
||||
<div class='mep_event_title_list_item'><a href='<?php the_permalink(); ?>'><?php the_title(); ?></a></div>
|
||||
<?php
|
||||
$content = ob_get_clean();
|
||||
return $content;
|
||||
}else{
|
||||
return $content;
|
||||
function mep_event_loop_title_style($content, $event_id, $style)
|
||||
{
|
||||
if ($style == 'title') {
|
||||
|
||||
$now = current_time('Y-m-d H:i:s');
|
||||
$show_price = mep_get_option('mep_event_price_show', 'general_setting_sec', 'yes');
|
||||
$show_price_label = mep_get_option('event-price-label', 'general_setting_sec', 'Price Starts from:');
|
||||
$event_meta = get_post_custom($event_id);
|
||||
$author_terms = get_the_terms($event_id, 'mep_org');
|
||||
$time = strtotime($event_meta['event_start_date'][0] . ' ' . $event_meta['event_start_time'][0]);
|
||||
$newformat = date_i18n('Y-m-d H:i:s', $time);
|
||||
$tt = get_the_terms($event_id, 'mep_cat');
|
||||
$torg = get_the_terms($event_id, 'mep_org');
|
||||
$org_class = mep_get_term_as_class($event_id, 'mep_org');
|
||||
$cat_class = mep_get_term_as_class($event_id, 'mep_cat');
|
||||
$event_multidate = array_key_exists('mep_event_more_date', $event_meta) ? maybe_unserialize($event_meta['mep_event_more_date'][0]) : array();
|
||||
$available_seat = mep_get_total_available_seat($event_id, $event_meta);
|
||||
$hide_org_list = mep_get_option('mep_event_hide_organizer_list', 'general_setting_sec', 'no');
|
||||
$hide_location_list = mep_get_option('mep_event_hide_location_list', 'general_setting_sec', 'no');
|
||||
$hide_time_list = mep_get_option('mep_event_hide_time_list', 'general_setting_sec', 'no');
|
||||
$hide_only_end_time_list = mep_get_option('mep_event_hide_end_time_list', 'general_setting_sec', 'no');
|
||||
$recurring = get_post_meta($event_id, 'mep_enable_recurring', true) ? get_post_meta($event_id, 'mep_enable_recurring', true) : 'no';
|
||||
$start_datetime = $event_meta['event_start_date'][0];
|
||||
$end_datetime = $event_meta['event_end_date'][0];
|
||||
ob_start();
|
||||
require(mep_template_file_path('list/title.php'));
|
||||
$content = ob_get_clean();
|
||||
return $content;
|
||||
} else {
|
||||
return $content;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -7,27 +7,15 @@ if (!defined('ABSPATH')) {
|
|||
* This Function will hooked up with the speaker action hook mep_event_speakers_list to display the Event Speaker List
|
||||
*/
|
||||
|
||||
add_action('mep_event_speakers_list','mep_display_speaker_list');
|
||||
if (!function_exists('mep_display_speaker_list')) {
|
||||
function mep_display_speaker_list($event_id){
|
||||
$speakers_id = get_post_meta($event_id,'mep_event_speakers_list',true) ? maybe_unserialize(get_post_meta($event_id,'mep_event_speakers_list',true)) : array();
|
||||
$speaker_icon = get_post_meta($event_id,'mep_event_speaker_icon',true) ? get_post_meta($event_id,'mep_event_speaker_icon',true) : 'fa fa-microphone';
|
||||
$speaker_label = get_post_meta($event_id,'mep_speaker_title',true) ? get_post_meta($event_id,'mep_speaker_title',true) : __("Speaker's","mage-eventpress");
|
||||
|
||||
if(is_array($speakers_id) && sizeof($speakers_id) > 0){
|
||||
?>
|
||||
<h3><?php ?><i class="<?php echo $speaker_icon; ?>"></i> <?php echo $speaker_label; ?></h3>
|
||||
<?php
|
||||
echo '<ul>';
|
||||
foreach($speakers_id as $speakers){
|
||||
?>
|
||||
<li>
|
||||
<a href='<?php echo get_the_permalink($speakers); ?>'><?php if(has_post_thumbnail($speakers)){ echo get_the_post_thumbnail($speakers,'medium'); }else{ echo '<img src="'.plugins_url( '../images/no-photo.jpg' , __DIR__ ).'"/>'; } ?>
|
||||
<h6><?php echo get_the_title($speakers); ?></h6></a>
|
||||
</li>
|
||||
<?php
|
||||
add_action('mep_event_speakers_list', 'mep_display_speaker_list');
|
||||
if (!function_exists('mep_display_speaker_list')) {
|
||||
function mep_display_speaker_list($event_id)
|
||||
{
|
||||
$speakers_id = get_post_meta($event_id, 'mep_event_speakers_list', true) ? maybe_unserialize(get_post_meta($event_id, 'mep_event_speakers_list', true)) : array();
|
||||
$speaker_icon = get_post_meta($event_id, 'mep_event_speaker_icon', true) ? get_post_meta($event_id, 'mep_event_speaker_icon', true) : 'fa fa-microphone';
|
||||
$speaker_label = get_post_meta($event_id, 'mep_speaker_title', true) ? get_post_meta($event_id, 'mep_speaker_title', true) : __("Speaker's", "mage-eventpress");
|
||||
if (is_array($speakers_id) && sizeof($speakers_id) > 0) {
|
||||
require(mep_template_file_path('single/speaker-list.php'));
|
||||
}
|
||||
echo '</ul>';
|
||||
}
|
||||
}
|
||||
}
|
|
@ -13,87 +13,40 @@ if (!function_exists('mep_event_ticket_type_loop_list_html')) {
|
|||
?>
|
||||
<?php
|
||||
$count = 1;
|
||||
$seat_plan = get_post_meta($post_id, 'mepsp_event_seat_plan_info', true) ? get_post_meta($post_id, 'mepsp_event_seat_plan_info', true) : [];
|
||||
if (sizeof($seat_plan) > 0) {
|
||||
$event_start_date = get_post_meta($post_id, 'event_start_date', true) . ' ' . get_post_meta($post_id, 'event_start_time', true);
|
||||
$ticket_type_file_path = apply_filters('mep_ticket_type_file_path',mep_template_file_path('single/ticket_type_list.php'),$post_id);
|
||||
require($ticket_type_file_path);
|
||||
}else{
|
||||
foreach ($mep_event_ticket_type as $field) {
|
||||
$qty_t_type = $field['option_qty_t_type'];
|
||||
$ticket_type_name = array_key_exists('option_name_t',$field) ? $field['option_name_t'] : '';
|
||||
$ticket_type = array_key_exists('option_qty_t_type',$field) ? $field['option_qty_t_type'] : '';
|
||||
$ticket_type_qty = array_key_exists('option_qty_t',$field) ? $field['option_qty_t'] : 0;
|
||||
$ticket_type_price = array_key_exists('option_price_t',$field) ? $field['option_price_t'] : 0;
|
||||
$qty_t_type = $ticket_type;
|
||||
$total_quantity = isset($field['option_qty_t']) ? $field['option_qty_t'] : 0;
|
||||
$default_qty = isset($field['option_default_qty_t']) && $field['option_default_qty_t'] > 0 ? $field['option_default_qty_t'] : 0;
|
||||
$total_resv_quantity = isset($field['option_rsv_t']) ? $field['option_rsv_t'] : 0;
|
||||
$event_date = get_post_meta($post_id, 'event_start_date', true) . ' ' . get_post_meta($post_id, 'event_start_time', true);
|
||||
$total_sold = (int) mep_ticket_type_sold($post_id, $field['option_name_t'], $event_date);
|
||||
$event_start_date = get_post_meta($post_id, 'event_start_date', true) . ' ' . get_post_meta($post_id, 'event_start_time', true);
|
||||
$total_sold = (int) mep_ticket_type_sold($post_id, $ticket_type_name, $event_date);
|
||||
$total_tickets = (int) $total_quantity - ((int) $total_sold + (int) $total_resv_quantity);
|
||||
$total_seats = apply_filters('mep_total_ticket_of_type', $total_tickets, $post_id, $field);
|
||||
$total_min_seat = apply_filters('mep_ticket_min_qty', 0, $post_id, $field);
|
||||
$default_quantity = apply_filters('mep_ticket_default_qty', $default_qty, $post_id, $field);
|
||||
$total_left = apply_filters('mep_total_ticket_of_type', $total_tickets, $post_id, $field);
|
||||
$ticket_price = apply_filters('mep_ticket_type_price', $field['option_price_t'], $field['option_name_t'], $post_id, $field);
|
||||
$ticket_price = apply_filters('mep_ticket_type_price', $ticket_type_price, $ticket_type_name, $post_id, $field);
|
||||
$passed = apply_filters('mep_ticket_type_validation', true);
|
||||
$start_date = get_post_meta($post_id, 'event_start_datetime', true);
|
||||
$default_path = mep_template_file_path('single/ticket_type_list.php');
|
||||
$ticket_type_file_path = apply_filters('mep_ticket_type_file_path',$default_path,$post_id);
|
||||
require($ticket_type_file_path);
|
||||
|
||||
$count++;
|
||||
}
|
||||
}
|
||||
?>
|
||||
<tr>
|
||||
<td align="Left"><?php echo $field['option_name_t']; ?>
|
||||
<input type="hidden" name='mep_event_start_date[]' value="<?php echo get_post_meta($post_id, 'event_start_datetime', true); ?>">
|
||||
<?php if ($mep_available_seat == 'on') { ?><div class="xtra-item-left"><?php echo max($total_left, 0); ?>
|
||||
|
||||
<?php echo mep_get_option('mep_left_text', 'label_setting_sec') ? mep_get_option('mep_left_text', 'label_setting_sec') : _e('Left:', 'mage-eventpress'); ?>
|
||||
|
||||
</div> <?php } ?>
|
||||
</td>
|
||||
<td class="ticket-qty">
|
||||
<span class="tkt-qty">
|
||||
<?php echo mep_get_option('mep_ticket_qty_text', 'label_setting_sec') ? mep_get_option('mep_ticket_qty_text', 'label_setting_sec') : _e('Ticket Qty:', 'mage-eventpress'); ?>
|
||||
</span>
|
||||
<?php
|
||||
if ($total_left > 0) {
|
||||
if ($qty_t_type == 'dropdown') { ?>
|
||||
<select name="option_qty[]" id="eventpxtp_<?php echo $count; ?>" <?php if ($total_left <= 0) { ?> style='display: none!important;' <?php } ?> class='extra-qty-box etp'>
|
||||
<?php
|
||||
for ($i = $total_min_seat; $i <= $total_left; $i++) { ?>
|
||||
<option value="<?php echo $i; ?>" <?php if ($i == $default_quantity) {
|
||||
echo 'Selected';
|
||||
} ?>><?php echo $i; ?>
|
||||
<?php echo mep_get_option('mep_ticket_text', 'label_setting_sec') ? mep_get_option('mep_ticket_text', 'label_setting_sec') : _e('Ticket:', 'mage-eventpress'); ?>
|
||||
</option>
|
||||
<?php } ?>
|
||||
</select>
|
||||
<?php } else { ?>
|
||||
|
||||
<div class="mage_input_group">
|
||||
<span class="fa fa-minus qty_dec"></span>
|
||||
<input id="eventpxtp_<?php echo $count; ?>" type="text" class='extra-qty-box etp' name='option_qty[]' data-price='<?php echo $ticket_price; ?>' value='<?php echo $default_quantity; ?>' min="<?php echo $total_min_seat; ?>" max="<?php echo max($total_seats, 0); ?>">
|
||||
<span class="fa fa-plus qty_inc"></span>
|
||||
</div>
|
||||
<?php }
|
||||
} else {
|
||||
_e('No Seat Available', 'mage-eventpress');
|
||||
}
|
||||
$ticket_name = $field['option_name_t'];
|
||||
do_action('mep_after_ticket_type_qty', $post_id, $ticket_name, $field, $default_quantity);
|
||||
?>
|
||||
|
||||
|
||||
|
||||
</td>
|
||||
<td class="ticket-price"><span class="tkt-pric">
|
||||
|
||||
<?php echo mep_get_option('mep_per_ticket_price_text', 'label_setting_sec') ? mep_get_option('mep_per_ticket_price_text', 'label_setting_sec') : _e('Per Ticket Price:', 'mage-eventpress'); ?>
|
||||
</span> <strong><?php echo wc_price($ticket_price); ?></strong>
|
||||
|
||||
<?php if ($total_left > 0) { ?>
|
||||
<p style="display: none;" class="price_jq"><?php echo $ticket_price; ?></p>
|
||||
<input type="hidden" name='option_name[]' value='<?php echo $field['option_name_t']; ?>'>
|
||||
<input type="hidden" name='option_price[]' value='<?php echo $ticket_price; ?>'>
|
||||
<input type="hidden" name='max_qty[]' value='<?php echo $field['option_max_qty']; ?>'>
|
||||
<?php } ?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="3" class='user-innnf'>
|
||||
<div class="user-info-sec">
|
||||
<div id="dadainfo_<?php echo $count; ?>" class="dada-info"></div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<?php $count++;
|
||||
} ?>
|
||||
|
||||
<?php
|
||||
$loop_list = ob_get_clean();
|
||||
|
|
|
@ -10,21 +10,7 @@ if (!function_exists('mep_faq_part')) {
|
|||
ob_start();
|
||||
$mep_event_faq = get_post_meta($event_id, 'mep_event_faq', true) ? get_post_meta($event_id, 'mep_event_faq', true) : '';
|
||||
if ($mep_event_faq) {
|
||||
?>
|
||||
<div class="mep-event-faq-part">
|
||||
<h3 class="ex-sec-title"><?php _e('Event F.A.Q', 'mage-eventpress'); ?></h3>
|
||||
<div id='mep-event-accordion' class="">
|
||||
<?php
|
||||
foreach ($mep_event_faq as $field) {
|
||||
?>
|
||||
<h3><?php if ($field['mep_faq_title'] != '') echo esc_attr($field['mep_faq_title']); ?></h3>
|
||||
<p><?php if ($field['mep_faq_content'] != '') echo esc_attr($field['mep_faq_content']); ?></p>
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<?php
|
||||
require(mep_template_file_path('single/faq.php'));
|
||||
}
|
||||
$content = ob_get_clean();
|
||||
echo apply_filters('mage_event_faq_list', $content, $event_id);
|
||||
|
|
|
@ -16,11 +16,11 @@ if (!function_exists('mep_event_google_map')) {
|
|||
if ($location_sts) {
|
||||
$org_arr = get_the_terms($event_id, 'mep_org');
|
||||
$org_id = $org_arr[0]->term_id;
|
||||
$lat = get_term_meta($org_id, 'latitude', true);
|
||||
$lon = get_term_meta($org_id, 'longitude', true);
|
||||
$lat = get_term_meta($org_id, 'latitude', true) ? get_term_meta($org_id, 'latitude', true) : 0;
|
||||
$lon = get_term_meta($org_id, 'longitude', true) ? get_term_meta($org_id, 'longitude', true) : 0;
|
||||
} else {
|
||||
$lat = $event_meta['latitude'][0];
|
||||
$lon = $event_meta['longitude'][0];
|
||||
$lat = $event_meta['latitude'][0] ? $event_meta['latitude'][0] : 0;
|
||||
$lon = $event_meta['longitude'][0] ? $event_meta['longitude'][0] : 0;
|
||||
}
|
||||
|
||||
if ($event_meta['mep_sgm'][0]) {
|
||||
|
|
|
@ -1,15 +1,18 @@
|
|||
<?php
|
||||
<?php
|
||||
if (!defined('ABSPATH')) {
|
||||
die;
|
||||
} // Cannot access pages directly.
|
||||
|
||||
add_action('mep_event_organizer','mep_ev_org');
|
||||
add_action('mep_event_organizer', 'mep_ev_org');
|
||||
if (!function_exists('mep_ev_org')) {
|
||||
function mep_ev_org(){
|
||||
global $post,$author_terms;
|
||||
ob_start();
|
||||
if($author_terms){ ?><p> <?php echo mep_get_option('mep_by_text', 'label_setting_sec') ? mep_get_option('mep_by_text', 'label_setting_sec') : _e('By:','mage-eventpress'); ?> <a href="<?php echo get_term_link( $author_terms[0]->term_id, 'mep_org' ); ?>"><?php echo $author_terms[0]->name; ?></a></p><?php }
|
||||
$content = ob_get_clean();
|
||||
echo apply_filters('mage_event_single_org_name', $content,$post->ID);
|
||||
function mep_ev_org()
|
||||
{
|
||||
global $post, $author_terms;
|
||||
ob_start();
|
||||
if ($author_terms) {
|
||||
require(mep_template_file_path('single/organizer.php'));
|
||||
}
|
||||
$content = ob_get_clean();
|
||||
echo apply_filters('mage_event_single_org_name', $content, $post->ID);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -20,6 +20,7 @@ $global_template = mep_get_option('mep_global_single_template', 'general_s
|
|||
$current_template = $event_meta['mep_event_template'][0];
|
||||
$_current_template = $current_template ? $current_template : $global_template;
|
||||
$currency_pos = get_option('woocommerce_currency_pos');
|
||||
do_action('mep_event_single_page_after_header');
|
||||
?>
|
||||
<div class="mep-events-wrapper">
|
||||
<?php
|
||||
|
@ -36,6 +37,7 @@ $currency_pos = get_option('woocommerce_currency_pos');
|
|||
</div>
|
||||
<?php
|
||||
$builder_version = mep_get_builder_version();
|
||||
|
||||
if($builder_version < 3.5){
|
||||
?>
|
||||
<script>
|
||||
|
@ -153,7 +155,7 @@ $qm = $field['option_name_t'];
|
|||
jQuery('#dadainfo_<?php echo $count; ?>').append(
|
||||
jQuery('<div/>')
|
||||
.attr("id", "newDiv" + i)
|
||||
.html("<?php do_action('mep_reg_fields',$start_date); ?>")
|
||||
.html("<?php do_action('mep_reg_fields',$start_date, get_the_id(), $qm); ?>")
|
||||
);
|
||||
}
|
||||
|
||||
|
@ -176,7 +178,7 @@ jQuery('#eventpxtp_<?php echo $count; ?>').on('change', function () {
|
|||
jQuery('#dadainfo_<?php echo $count; ?>').append(
|
||||
jQuery('<div/>')
|
||||
.attr("id", "newDiv" + i)
|
||||
.html("<?php do_action('mep_reg_fields',$start_date); ?>")
|
||||
.html("<?php do_action('mep_reg_fields',$start_date, get_the_id(), $qm); ?>")
|
||||
);
|
||||
}
|
||||
});
|
||||
|
@ -211,4 +213,6 @@ jQuery('#quantity_5a7abbd1bff73').on('change', function () {
|
|||
}else{
|
||||
do_action('mep_event_single_template_end',get_the_id());
|
||||
}?>
|
||||
<?php get_footer(); ?>
|
||||
<?php
|
||||
do_action('mep_event_single_page_before_footer');
|
||||
get_footer();
|
||||
|
|
|
@ -10,11 +10,7 @@ if (!function_exists('mep_ev_social_share')) {
|
|||
global $post;
|
||||
ob_start();
|
||||
$post_id = $post->ID;
|
||||
?>
|
||||
<div class="mep-event-meta">
|
||||
<?php _e(mep_get_label($post_id, 'mep_share_text', 'Share This Event:'), 'mage-eventpress'); ?><?php mep_social_share(); ?>
|
||||
</div>
|
||||
<?php
|
||||
require(mep_template_file_path('single/share_btn.php'));
|
||||
$content = ob_get_clean();
|
||||
echo apply_filters('mage_event_single_social_share', $content, $post->ID);
|
||||
}
|
||||
|
|
|
@ -9,12 +9,8 @@ if (!function_exists('mep_thumbnail')) {
|
|||
{
|
||||
global $post;
|
||||
ob_start();
|
||||
?>
|
||||
<div class="mep-event-thumbnail">
|
||||
<?php the_post_thumbnail('full'); ?>
|
||||
</div>
|
||||
<?php
|
||||
require(mep_template_file_path('single/thumbnail.php'));
|
||||
$content = ob_get_clean();
|
||||
echo apply_filters('mage_event_single_thumbnail', $content, $post->ID);
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,17 +1,16 @@
|
|||
<?php
|
||||
<?php
|
||||
if (!defined('ABSPATH')) {
|
||||
die;
|
||||
} // Cannot access pages directly.
|
||||
|
||||
add_action('mep_event_title','mep_ev_title');
|
||||
add_action('mep_event_title', 'mep_ev_title');
|
||||
if (!function_exists('mep_ev_title')) {
|
||||
function mep_ev_title(){
|
||||
global $post;
|
||||
ob_start();
|
||||
?>
|
||||
<h2><?php the_title(); ?></h2>
|
||||
<?php
|
||||
$content = ob_get_clean();
|
||||
echo apply_filters('mage_event_single_title', $content,$post->ID);
|
||||
}
|
||||
function mep_ev_title()
|
||||
{
|
||||
global $post;
|
||||
ob_start();
|
||||
require(mep_template_file_path('single/title.php'));
|
||||
$content = ob_get_clean();
|
||||
echo apply_filters('mage_event_single_title', $content, $post->ID);
|
||||
}
|
||||
}
|
|
@ -1,13 +1,14 @@
|
|||
<?php
|
||||
if (!defined('ABSPATH')) {
|
||||
die;
|
||||
die;
|
||||
} // Cannot access pages directly.
|
||||
|
||||
add_action('mep_event_seat', 'mep_ev_seat');
|
||||
if (!function_exists('mep_ev_seat')) {
|
||||
function mep_ev_seat()
|
||||
{
|
||||
global $post, $event_meta;
|
||||
global $post;
|
||||
$event_meta = get_post_custom(get_the_id());
|
||||
$recurring = get_post_meta(get_the_id(), 'mep_enable_recurring', true) ? get_post_meta(get_the_id(), 'mep_enable_recurring', true) : 'no';
|
||||
ob_start();
|
||||
if ($recurring == 'no') {
|
||||
|
@ -20,14 +21,11 @@ if (!function_exists('mep_ev_seat')) {
|
|||
$total_resv = apply_filters('mep_event_total_resv_seat_count', mep_event_total_seat(get_the_id(), 'resv'), get_the_id());
|
||||
$total_sold = mep_ticket_sold(get_the_id());
|
||||
$total_left = $total_seat - ($total_sold + $total_resv);
|
||||
?>
|
||||
<h5><strong><?php echo mep_get_option('mep_total_seat_text', 'label_setting_sec') ? mep_get_option('mep_total_seat_text', 'label_setting_sec') : _e('Total Seat:', 'mage-eventpress'); ?></strong> <?php echo $total_seat;
|
||||
if ($mep_available_seat == 'on') { ?> (<strong><?php echo max($total_left, 0); ?></strong> <?php _e('Left', 'mage-eventpress'); ?>)<?php } ?></h5>
|
||||
<?php
|
||||
require(mep_template_file_path('single/total_seat.php'));
|
||||
}
|
||||
}
|
||||
|
||||
$content = ob_get_clean();
|
||||
echo apply_filters('mage_event_single_title', $content, $post->ID);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Binary file not shown.
File diff suppressed because it is too large
Load Diff
|
@ -1,5 +1,5 @@
|
|||
<?php
|
||||
if ( ! defined('ABSPATH')) exit; // if direct access
|
||||
if ( ! defined('ABSPATH')) exit; // if direct access
|
||||
|
||||
|
||||
/*Input fields
|
||||
|
@ -5909,12 +5909,9 @@ if( ! class_exists( 'FormFieldsGenerator' ) ) {
|
|||
$placeholder = isset( $option['placeholder'] ) ? $option['placeholder'] : "";
|
||||
$default = isset( $option['default'] ) ? $option['default'] : "";
|
||||
$editor_settings= isset( $option['editor_settings'] ) ? $option['editor_settings'] : array('textarea_name'=>$field_name);
|
||||
|
||||
$value = isset( $option['value'] ) ? $option['value'] : "";
|
||||
$value = !empty($value) ? $value : $default;
|
||||
|
||||
$field_id = $id;
|
||||
|
||||
if(!empty($conditions)):
|
||||
|
||||
$depends = '';
|
||||
|
@ -8451,17 +8448,14 @@ if( ! class_exists( 'FormFieldsGenerator' ) ) {
|
|||
foreach ($fields as $key => $value) {
|
||||
# code...
|
||||
$new[$key]['type'] = $fields[$key]['type'];
|
||||
$new[$key]['default'] = isset($fields[$key]['default']) ? $fields[$key]['default'] : "";
|
||||
$new[$key]['default'] = $fields[$key]['default'];
|
||||
$new[$key]['item_id'] = $fields[$key]['item_id'];
|
||||
$new[$key]['name'] = $fields[$key]['name'];
|
||||
|
||||
$define_args = isset($fields[$key]['args']) ? $fields[$key]['args'] : "";
|
||||
|
||||
$new[$key]['args'] = $this->args_from_string( $define_args );
|
||||
|
||||
$new[$key]['args'] = !is_array($fields[$key]['args']) ? $this->args_from_string($fields[$key]['args']):$fields[$key]['args'];
|
||||
|
||||
}
|
||||
$fields = $new;
|
||||
|
||||
|
||||
|
||||
if(!empty($conditions)):
|
||||
|
||||
|
@ -8649,7 +8643,7 @@ if( ! class_exists( 'FormFieldsGenerator' ) ) {
|
|||
}else if(type == 'select'){
|
||||
args = element.args;
|
||||
html+='<select name="<?php echo $field_name; ?>['+now+']['+element.item_id+']">';
|
||||
for(argKey in args){
|
||||
for(argKey in args){
|
||||
html+='<option value="'+argKey+'">'+args[argKey]+'</option>';
|
||||
}
|
||||
html+='</select>';
|
||||
|
@ -8700,7 +8694,7 @@ if( ! class_exists( 'FormFieldsGenerator' ) ) {
|
|||
</script>
|
||||
<div <?php if(!empty($depends)) {?> data-depends="[<?php echo $depends; ?>]" <?php } ?> id="field-wrapper-<?php echo $id; ?>" class="<?php if(!empty($depends)) echo 'dependency-field'; ?> field-wrapper field-repeatable-wrapper
|
||||
field-repeatable-wrapper-<?php echo $id; ?>">
|
||||
|
||||
|
||||
<div class="field-list <?php if($sortable){ echo 'sortable'; }?>" id="<?php echo $id; ?>">
|
||||
<?php
|
||||
if(!empty($values)):
|
||||
|
@ -8712,7 +8706,7 @@ if( ! class_exists( 'FormFieldsGenerator' ) ) {
|
|||
<?php if($collapsible):?>
|
||||
<div class="header">
|
||||
<?php endif; ?>
|
||||
|
||||
|
||||
<!-- <span index_id="--><?php //echo $index; ?><!--" class="button clone"><i class="far fa-clone"></i></span>-->
|
||||
<?php if($sortable):?>
|
||||
<span class="button sort"><i class="fas fa-arrows-alt"></i></span>
|
||||
|
@ -8723,7 +8717,7 @@ if( ! class_exists( 'FormFieldsGenerator' ) ) {
|
|||
</div>
|
||||
<?php endif; ?>
|
||||
<?php foreach ($fields as $field_index => $field):
|
||||
$type = $field['type'];
|
||||
$type = $field['type'];
|
||||
$item_id = $field['item_id'];
|
||||
$name = $field['name'];
|
||||
$title_field_class = ($title_field == $field_index) ? 'title-field':'';
|
||||
|
@ -8794,10 +8788,10 @@ if( ! class_exists( 'FormFieldsGenerator' ) ) {
|
|||
$value = !empty($val[$item_id]) ? $val[$item_id] : $default;
|
||||
?>
|
||||
<select class="" name="<?php echo $field_name; ?>[<?php echo $index; ?>][<?php echo $item_id; ?>]">
|
||||
<?php
|
||||
if(!is_array($args)){
|
||||
<?php
|
||||
if(!is_array($args)){
|
||||
$this->args_from_string($args);
|
||||
}else{
|
||||
}else{
|
||||
foreach ($args as $argIndex => $argName):
|
||||
$selected = ($argIndex == $value) ? 'selected' : '';
|
||||
?>
|
||||
|
@ -8809,13 +8803,13 @@ if( ! class_exists( 'FormFieldsGenerator' ) ) {
|
|||
$default = isset($field['default']) ? $field['default'] : '';
|
||||
$value = !empty($val[$item_id]) ? $val[$item_id] : $default;
|
||||
?>
|
||||
<?php
|
||||
if(!is_array($args)){
|
||||
<?php
|
||||
if(!is_array($args)){
|
||||
$this->args_from_string($args);
|
||||
}else{
|
||||
}else{
|
||||
foreach ($args as $argIndex => $argName):
|
||||
$checked = ($argIndex == $value) ? 'checked' : '';
|
||||
|
||||
|
||||
?>
|
||||
<label class="" >
|
||||
<input type="radio" name="<?php echo $field_name; ?>[<?php echo $index; ?>][<?php echo $item_id; ?>]" <?php echo $checked; ?> value="<?php echo $argIndex; ?>"><?php echo $argName; ?></input>
|
||||
|
@ -8826,10 +8820,13 @@ if( ! class_exists( 'FormFieldsGenerator' ) ) {
|
|||
$default = isset($field['default']) ? $field['default'] : '';
|
||||
$value = !empty($val[$item_id]) ? $val[$item_id] : $default;
|
||||
?>
|
||||
<?php
|
||||
|
||||
<?php
|
||||
|
||||
foreach ($args as $argIndex => $argName):
|
||||
$value = is_array($value) ? $value : array();
|
||||
// print_r($value);
|
||||
$checked = in_array($argIndex, $value ) ? 'checked' : '';
|
||||
// $checked = isset($argIndex) ? 'checked' : '';
|
||||
?>
|
||||
<label class="" >
|
||||
<input type="checkbox" name="<?php echo $field_name; ?>[<?php echo $index; ?>][<?php echo $item_id; ?>][]" <?php echo $checked; ?> value="<?php echo $argIndex; ?>"><?php echo $argName; ?></input>
|
||||
|
@ -8846,7 +8843,7 @@ if( ! class_exists( 'FormFieldsGenerator' ) ) {
|
|||
</div>
|
||||
<?php endforeach; ?>
|
||||
</div>
|
||||
|
||||
|
||||
<?php
|
||||
//endforeach;
|
||||
$count++;
|
||||
|
@ -8858,7 +8855,7 @@ if( ! class_exists( 'FormFieldsGenerator' ) ) {
|
|||
?>
|
||||
<?php
|
||||
endif;
|
||||
?>
|
||||
?>
|
||||
</div>
|
||||
<div class="error-mgs"></div>
|
||||
<div class="ppof-button add-item"><i class="fas fa-plus-square"></i> <?php echo $btntext; ?></div>
|
||||
|
@ -10035,4 +10032,4 @@ if( ! class_exists( 'FormFieldsGenerator' ) ) {
|
|||
}
|
||||
global $wbtmcore;
|
||||
$wbtmcore = new FormFieldsGenerator();
|
||||
}
|
||||
}
|
16
readme.txt
16
readme.txt
|
@ -7,7 +7,7 @@ Version: 2.1.3
|
|||
Tested up to: 5.4
|
||||
Requires PHP: 7.0
|
||||
WC requires at least: 3.0
|
||||
WC tested up to: 4.0
|
||||
WC tested up to: 4.2
|
||||
Requires PHP: 7.0
|
||||
License: GPLv2 or later
|
||||
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
||||
|
@ -556,4 +556,16 @@ Fix Event Date issue in Event List For Multidate
|
|||
Event Location modified in event list
|
||||
WooCommerce Hidden Product issue fixed
|
||||
New Filter hooked added in Total Seat value
|
||||
24 May 2020*
|
||||
24 May 2020*
|
||||
|
||||
|
||||
|
||||
= 3.3.0 =
|
||||
* Update Release:
|
||||
Code Optimized & Improved
|
||||
Child Theme Support added for event temlates
|
||||
New Hooks added
|
||||
Event Label & Slug change settings added
|
||||
PHP Warning in cart page issue fixed
|
||||
More...
|
||||
12 July 2020*
|
|
@ -0,0 +1,102 @@
|
|||
<div class='mep-event-list-loop <?php echo $columnNumber; ?> mep_event_<?php echo $style; ?>_item mix <?php if ($tt) { echo $org_class; } ?> <?php if ($torg) { echo $cat_class; } ?>'>
|
||||
<?php do_action('mep_event_list_loop_header', $event_id); ?>
|
||||
<div class="mep_list_thumb">
|
||||
<a href="<?php echo get_the_permalink($event_id); ?>"><?php echo get_the_post_thumbnail($event_id, 'full'); ?></a>
|
||||
<?php if (sizeof($event_multidate) == 0) { ?>
|
||||
<div class="mep-ev-start-date">
|
||||
<div class="mep-day"><?php echo get_mep_datetime($event_meta['event_start_datetime'][0], 'day'); ?></div>
|
||||
<div class="mep-month"><?php echo get_mep_datetime($event_meta['event_start_datetime'][0], 'month'); ?></div>
|
||||
</div>
|
||||
<?php }
|
||||
if (is_array($event_multidate) && sizeof($event_multidate) > 0) { ?>
|
||||
<div class='mep-multidate-ribbon mep-tem3-title-sec'>
|
||||
<span><?php echo mep_get_option('mep_event_multidate_ribon_text', 'label_setting_sec', __('Multi Date Event', 'mage-eventpress')); ?></span>
|
||||
</div>
|
||||
<?php }
|
||||
if ($event_type == 'online') { ?>
|
||||
<div class='mep-eventtype-ribbon mep-tem3-title-sec'>
|
||||
<span><?php echo mep_get_option('mep_event_virtual_label', 'label_setting_sec') ? mep_get_option('mep_event_virtual_label', 'label_setting_sec') : _e('Virtual Event', 'mage-eventpress'); ?></span>
|
||||
</div>
|
||||
<?php } ?>
|
||||
</div>
|
||||
<div class="mep_list_event_details">
|
||||
<a href="<?php the_permalink(); ?>">
|
||||
<div class="mep-list-header">
|
||||
<h2 class='mep_list_title'><?php the_title(); ?></h2>
|
||||
<?php if ($available_seat == 0) {
|
||||
do_action('mep_show_waitlist_label');
|
||||
} ?>
|
||||
<h3 class='mep_list_date'>
|
||||
<?php if ($show_price == 'yes') {
|
||||
echo $show_price_label . " " . mep_event_list_price($event_id);
|
||||
} ?>
|
||||
</h3>
|
||||
</div>
|
||||
<?php
|
||||
if ($style == 'list') {
|
||||
?>
|
||||
<div class="mep-event-excerpt">
|
||||
<?php the_excerpt(); ?>
|
||||
</div>
|
||||
<?php } ?>
|
||||
|
||||
<div class="mep-list-footer">
|
||||
<ul>
|
||||
<?php
|
||||
if ($hide_org_list == 'no') {
|
||||
if (sizeof($author_terms) > 0) {
|
||||
?>
|
||||
<li>
|
||||
<div class="evl-ico"><i class="fa fa-university"></i></div>
|
||||
<div class="evl-cc">
|
||||
<h5>
|
||||
<?php echo mep_get_option('mep_organized_by_text', 'label_setting_sec') ? mep_get_option('mep_organized_by_text', 'label_setting_sec') : _e('Organized By:', 'mage-eventpress'); ?>
|
||||
</h5>
|
||||
<h6><?php
|
||||
echo $author_terms[0]->name;
|
||||
?></h6>
|
||||
</div>
|
||||
</li>
|
||||
<?php }
|
||||
}
|
||||
if ($event_type != 'online') {
|
||||
if ($hide_location_list == 'no') { ?>
|
||||
|
||||
<li>
|
||||
<div class="evl-ico"><i class="fa fa-location-arrow"></i></div>
|
||||
<div class="evl-cc">
|
||||
<h5>
|
||||
<?php echo mep_get_option('mep_location_text', 'label_setting_sec') ? mep_get_option('mep_location_text', 'label_setting_sec') : _e('Location:', 'mage-eventpress'); ?>
|
||||
|
||||
</h5>
|
||||
<h6><?php mep_get_event_city($event_id); ?></h6>
|
||||
</div>
|
||||
</li>
|
||||
<?php }
|
||||
}
|
||||
if ($hide_time_list == 'no') {
|
||||
if (strtotime(current_time('Y-m-d H:i')) < strtotime($event_meta['event_start_datetime'][0])) {
|
||||
?>
|
||||
<li>
|
||||
<div class="evl-ico"><i class="fa fa-calendar"></i></div>
|
||||
<div class="evl-cc">
|
||||
<h5>
|
||||
<?php if (sizeof($event_multidate) > 0) {
|
||||
|
||||
echo get_mep_datetime($event_meta['event_start_datetime'][0], 'date-text');
|
||||
}
|
||||
?>
|
||||
<?php echo mep_get_option('mep_time_text', 'label_setting_sec') ? mep_get_option('mep_time_text', 'label_setting_sec') : _e('Time:', 'mage-eventpress'); ?>
|
||||
</h5>
|
||||
<h6><?php echo get_mep_datetime($event_meta['event_start_datetime'][0], 'time');
|
||||
if ($hide_only_end_time_list == 'no') { ?> - <?php echo get_mep_datetime($event_meta['event_end_datetime'][0], 'time');
|
||||
} ?></h6>
|
||||
</div>
|
||||
</li>
|
||||
<?php }
|
||||
} ?>
|
||||
</ul>
|
||||
</a>
|
||||
<?php do_action('mep_event_list_loop_footer', $event_id); ?>
|
||||
</div>
|
||||
</div>
|
|
@ -0,0 +1,27 @@
|
|||
<div class='mep-event-list-loop mep_event_list_item mep_event_minimal_list mix <?php if ($tt) { echo $org_class; } ?> <?php if ($torg) { echo $cat_class; } ?>'>
|
||||
<?php do_action('mep_event_minimal_list_loop_header',$event_id); ?>
|
||||
<div class="mep_list_thumb">
|
||||
<a href="<?php echo get_the_permalink($event_id); ?>"></a>
|
||||
<div class="mep-ev-start-date">
|
||||
<div class="mep-day"><?php echo mep_get_event_upcomming_date($event_id,'day'); //get_mep_datetime($event_meta['event_start_datetime'][0],'day'); ?></div>
|
||||
<div class="mep-month"><?php echo mep_get_event_upcomming_date($event_id,'month'); //get_mep_datetime($event_meta['event_start_datetime'][0],'month'); ?></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="mep_list_event_details">
|
||||
<a href="<?php the_permalink(); ?>">
|
||||
<div class="mep-list-header">
|
||||
<h2 class='mep_list_title'><?php the_title(); ?></h2>
|
||||
<?php
|
||||
mep_get_event_upcomming_date($event_id,1);
|
||||
?>
|
||||
<?php if ($available_seat == 0) {
|
||||
do_action('mep_show_waitlist_label');
|
||||
} ?>
|
||||
<h3 class='mep_list_date'> <span class='mep_minimal_list_date'><i class="fa fa-calendar"></i> <?php echo mep_get_event_upcomming_date($event_id,'time'); ?> - <?php if($start_datetime == $end_datetime){ echo get_mep_datetime($event_meta['event_end_datetime'][0],'time'); }else{ echo get_mep_datetime($event_meta['event_end_datetime'][0],'date-time-text'); } ?></span> <span class='mep_minimal_list_location'><i class='fa fa-map-marker'></i> <?php mep_get_event_city($event_id); ?></span></h3>
|
||||
|
||||
</a>
|
||||
<?php do_action('mep_event_list_loop_footer',$event_id); ?>
|
||||
</div>
|
||||
</div>
|
||||
<?php do_action('mep_event_minimal_list_loop_end',$event_id); ?>
|
||||
</div>
|
|
@ -0,0 +1,18 @@
|
|||
<div class='mep-event-list-loop mep_event_list_item mep_event_native_list mix <?php if ($tt) { echo $org_class; } ?> <?php if ($torg) { echo $cat_class; } ?>'>
|
||||
<?php do_action('mep_event_minimal_list_loop_header',$event_id); ?>
|
||||
<div class="mep_list_thumb">
|
||||
<a href="<?php echo get_the_permalink($event_id); ?>"><?php echo get_the_post_thumbnail($event_id,'full'); ?></a>
|
||||
</div>
|
||||
<div class="mep_list_event_details">
|
||||
<a href="<?php the_permalink(); ?>">
|
||||
<div class="mep-list-header">
|
||||
<h2 class='mep_list_title'><?php the_title(); ?></h2>
|
||||
<?php if ($available_seat == 0) {
|
||||
do_action('mep_show_waitlist_label');
|
||||
} ?>
|
||||
<h3 class='mep_list_date'> <span class='mep_minimal_list_date'><i class="fa fa-calendar"></i> <?php echo get_mep_datetime($event_meta['event_start_datetime'][0],'date-time-text'); ?> - <?php if($start_datetime == $end_datetime){ echo get_mep_datetime($event_meta['event_end_datetime'][0],'time'); }else{ echo get_mep_datetime($event_meta['event_end_datetime'][0],'date-time-text'); } ?></span> <span class='mep_minimal_list_location'><i class='fa fa-map-marker'></i> <?php mep_get_event_city($event_id); ?></span></h3></a>
|
||||
<?php do_action('mep_event_list_loop_footer',$event_id); ?>
|
||||
</div>
|
||||
</div>
|
||||
<?php do_action('mep_event_minimal_list_loop_end',$event_id); ?>
|
||||
</div>
|
|
@ -0,0 +1,26 @@
|
|||
<div class="timeline__item">
|
||||
<div class="timeline__content">
|
||||
<div class='mep_event_timeline_list'>
|
||||
<?php do_action('mep_event_minimal_list_loop_header',$event_id); ?>
|
||||
<div class="mep_list_thumb">
|
||||
<a href="<?php echo get_the_permalink($event_id); ?>"><?php echo get_the_post_thumbnail($event_id,'full'); ?></a>
|
||||
<div class="mep-ev-start-date">
|
||||
<div class="mep-day"><?php echo get_mep_datetime($event_meta['event_start_datetime'][0],'day'); ?></div>
|
||||
<div class="mep-month"><?php echo get_mep_datetime($event_meta['event_start_datetime'][0],'month'); ?></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="mep_list_event_details">
|
||||
<a href="<?php the_permalink(); ?>">
|
||||
<div class="mep-list-header">
|
||||
<h2 class='mep_list_title'><?php the_title(); ?></h2>
|
||||
<?php if ($available_seat == 0) {
|
||||
do_action('mep_show_waitlist_label');
|
||||
} ?>
|
||||
<h3 class='mep_list_date'> <span class='mep_minimal_list_date'><i class="fa fa-calendar"></i> <?php echo get_mep_datetime($event_meta['event_start_datetime'][0],'time'); ?> - <?php if($start_datetime == $end_datetime){ echo get_mep_datetime($event_meta['event_end_datetime'][0],'time'); }else{ echo get_mep_datetime($event_meta['event_end_datetime'][0],'date-time-text'); } ?></span> <span class='mep_minimal_list_location'><i class='fa fa-map-marker'></i> <?php mep_get_event_city($event_id); ?></span></h3></a>
|
||||
<?php do_action('mep_event_list_loop_footer',$event_id); ?>
|
||||
</div>
|
||||
</div>
|
||||
<?php do_action('mep_event_minimal_list_loop_end',$event_id); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
|
@ -0,0 +1 @@
|
|||
<div class='mep_event_title_list_item'><a href='<?php the_permalink(); ?>'><?php the_title(); ?></a></div>
|
|
@ -0,0 +1,7 @@
|
|||
<div id="mep_add_calender_button" class='mep-add-calender'><i class="fa fa-calendar"></i><?php _e(mep_get_label($pid,'mep_calender_btn_text','Add Calendar'),'mage-eventpress'); ?></div>
|
||||
<ul id="mep_add_calender_links">
|
||||
<li><a href="https://calendar.google.com/calendar/r/eventedit?text=<?php echo $event->post_title; ?>&dates=<?php echo mep_calender_date($event_start); ?>/<?php echo mep_calender_date($event_end); ?>&details=<?php echo substr(strip_tags($event->post_content),0,1000); ?>&location=<?php echo $location; ?>&sf=true" rel="noopener noreferrer" target='_blank' class='mep-add-calender' rel="nofollow">Google</a></li>
|
||||
<li><a href="https://calendar.yahoo.com/?v=60&view=d&type=20&title=<?php echo $event->post_title; ?>&st=<?php echo mep_calender_date($event_start); ?>&et=<?php echo mep_calender_date($event_end); ?>&desc=<?php echo substr(strip_tags($event->post_content),0,1000); ?>&in_loc=<?php echo $location; ?>&uid=" rel="noopener noreferrer" target='_blank' class='mep-add-calender' rel="nofollow">Yahoo</a></li>
|
||||
<li><a href ="https://outlook.live.com/owa/?path=/calendar/view/Month&rru=addevent&startdt=<?php echo mep_calender_date($event_start); ?>&enddt=<?php echo mep_calender_date($event_end); ?>&subject=<?php echo $event->post_title; ?>" rel="noopener noreferrer" target='_blank' class='mep-add-calender' rel="nofollow">Outlook</a></li>
|
||||
<li><a href="https://webapps.genprod.com/wa/cal/download-ics.php?date_end=<?php echo mep_calender_date($event_end); ?>&date_start=<?php echo mep_calender_date($event_start); ?>&summary=<?php echo $event->post_title; ?>&location=<?php echo $location; ?>&description=<?php echo substr(strip_tags($event->post_content),0,1000); ?>" rel="noopener noreferrer" target='_blank' class='mep-add-calender'>Apple</a></li>
|
||||
</ul>
|
|
@ -0,0 +1,4 @@
|
|||
<li>
|
||||
<i class="fa fa-calendar"></i> <?php echo get_mep_datetime($start_datetime, 'date-text'); ?><br>
|
||||
<i class="fa fa-clock-o"></i> <?php echo get_mep_datetime($start_datetime, 'time'); ?> <?php if ($start_date != $end_date) { echo ' - ' . get_mep_datetime($end_datetime, 'date-text'); } echo ' - ' . get_mep_datetime($end_datetime, 'time'); ?>
|
||||
</li>
|
|
@ -0,0 +1 @@
|
|||
<h3><i class="fa fa-calendar"></i> <?php echo mep_get_option('mep_event_schedule_text', 'label_setting_sec', __('Event Schedule Details', 'mage-eventpress')); ?></h3>
|
|
@ -0,0 +1,13 @@
|
|||
<div class="mep-day-details-section">
|
||||
<h4><?php _e('Event Days', 'mage-eventpress'); ?></h4>
|
||||
<?php
|
||||
foreach ($mep_event_day as $field) {
|
||||
?>
|
||||
<div class="mep-day-title"><?php echo $field['mep_day_title']; ?></div>
|
||||
<div class="mep-day-details">
|
||||
<p><?php echo $field['mep_day_content']; ?></p>
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
</div>
|
|
@ -0,0 +1,2 @@
|
|||
<?php
|
||||
echo apply_filters('mep_event_details_content', $content, get_the_id());
|
|
@ -0,0 +1,57 @@
|
|||
<h3 class='ex-sec-title'><?php echo mep_get_label($post_id, 'mep_event_extra_service_text', 'Extra Service:'); ?></h3>
|
||||
<table>
|
||||
<tr>
|
||||
<td align="left"><?php echo mep_get_option('mep_name_text', 'label_setting_sec', __('Name:', 'mage-eventpress')); ?></td>
|
||||
<td class="mage_text_center"><?php echo mep_get_option('mep_quantity_text', 'label_setting_sec', __('Quantity:', 'mage-eventpress')); ?></td>
|
||||
<td class="mage_text_center"><?php echo mep_get_option('mep_price_text', 'label_setting_sec', __('Price:', 'mage-eventpress')); ?></td>
|
||||
</tr>
|
||||
<?php
|
||||
foreach ($mep_events_extra_prices as $field) {
|
||||
$event_date = get_post_meta($post_id, 'event_start_date', true) . ' ' . get_post_meta($post_id, 'event_start_time', true);
|
||||
$total_extra_service = (int) $field['option_qty'];
|
||||
$qty_type = $field['option_qty_type'];
|
||||
$total_sold = (int) mep_extra_service_sold($post_id, $field['option_name'], $event_date);
|
||||
$ext_left = ($total_extra_service - $total_sold);
|
||||
?>
|
||||
<tr>
|
||||
<td align="Left"><?php echo $field['option_name']; ?>
|
||||
<div class="xtra-item-left"><?php echo $ext_left; ?>
|
||||
<?php echo mep_get_option('mep_left_text', 'label_setting_sec') ? mep_get_option('mep_left_text', 'label_setting_sec') : _e('Left:', 'mage-eventpress'); ?>
|
||||
</div>
|
||||
<input type="hidden" name='mep_event_start_date_es[]' value='<?php echo $event_date; ?>'>
|
||||
</td>
|
||||
<td class="mage_text_center">
|
||||
<?php
|
||||
if ($ext_left > 0) {
|
||||
if ($qty_type == 'dropdown') { ?>
|
||||
<select name="event_extra_service_qty[]" id="eventpxtp_<?php //echo $count;
|
||||
?>" class='extra-qty-box'>
|
||||
<?php for ($i = 0; $i <= $ext_left; $i++) { ?>
|
||||
<option value="<?php echo $i; ?>"><?php echo $i; ?> <?php echo $field['option_name']; ?></option>
|
||||
<?php } ?>
|
||||
</select>
|
||||
<?php } else { ?>
|
||||
<div class="mage_input_group">
|
||||
<span class="fa fa-minus qty_dec"></span>
|
||||
<input id="eventpx" <?php //if($ext_left<=0){ echo "disabled"; }
|
||||
?> size="4" inputmode="numeric" type="text" class='extra-qty-box' name='event_extra_service_qty[]' data-price='<?php echo $field['option_price']; ?>' value='0' min="0" max="<?php echo $ext_left; ?>">
|
||||
<span class="fa fa-plus qty_inc"></span>
|
||||
</div>
|
||||
<?php }
|
||||
} else {
|
||||
echo mep_get_option('mep_not_available_text', 'label_setting_sec') ? mep_get_option('mep_not_available_text', 'label_setting_sec') : _e('Not Available', 'mage-eventpress');
|
||||
} ?>
|
||||
</td>
|
||||
<td class="mage_text_center"><?php echo wc_price($field['option_price']);
|
||||
if ($ext_left > 0) { ?>
|
||||
<p style="display: none;" class="price_jq"><?php echo $field['option_price']; ?></p>
|
||||
<input type="hidden" name='event_extra_service_name[]' value='<?php echo $field['option_name']; ?>'>
|
||||
<input type="hidden" name='event_extra_service_price[]' value='<?php echo $field['option_price']; ?>'>
|
||||
<?php } ?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php
|
||||
$count++;
|
||||
}
|
||||
?>
|
||||
</table>
|
|
@ -0,0 +1,13 @@
|
|||
<div class="mep-event-faq-part">
|
||||
<h3 class="ex-sec-title"><?php _e('Event F.A.Q', 'mage-eventpress'); ?></h3>
|
||||
<div id='mep-event-accordion' class="">
|
||||
<?php
|
||||
foreach ($mep_event_faq as $field) {
|
||||
?>
|
||||
<h3><?php if ($field['mep_faq_title'] != '') echo esc_attr($field['mep_faq_title']); ?></h3>
|
||||
<p><?php if ($field['mep_faq_content'] != '') echo esc_attr($field['mep_faq_content']); ?></p>
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</div>
|
|
@ -0,0 +1,13 @@
|
|||
<ul>
|
||||
<?php if($venue){ ?> <li><i class="fa fa-arrow-circle-right"></i> <?php do_action('mep_event_location_venue'); ?>
|
||||
</li> <?php } ?>
|
||||
<?php if($street){ ?><li><i class="fa fa-arrow-circle-right"></i> <?php do_action('mep_event_location_street'); ?>
|
||||
</li><?php } ?>
|
||||
<?php if($city){ ?><li><i class="fa fa-arrow-circle-right"></i> <?php do_action('mep_event_location_city'); ?></li>
|
||||
<?php } ?>
|
||||
<?php if($state){ ?><li><i class="fa fa-arrow-circle-right"></i> <?php do_action('mep_event_location_state'); ?>
|
||||
</li><?php } ?>
|
||||
<?php if($country){ ?><li><i class="fa fa-arrow-circle-right"></i>
|
||||
<?php do_action('mep_event_location_country'); ?><?php } ?>
|
||||
</li>
|
||||
</ul>
|
|
@ -0,0 +1 @@
|
|||
<p> <?php echo mep_get_option('mep_by_text', 'label_setting_sec') ? mep_get_option('mep_by_text', 'label_setting_sec') : _e('By:','mage-eventpress'); ?> <a href="<?php echo get_term_link( $author_terms[0]->term_id, 'mep_org' ); ?>"><?php echo $author_terms[0]->name; ?></a></p>
|
|
@ -0,0 +1,7 @@
|
|||
<div class="mep-event-meta">
|
||||
<?php _e(mep_get_label($post_id, 'mep_share_text', 'Share This Event:'), 'mage-eventpress'); ?>
|
||||
<ul class='mep-social-share'>
|
||||
<li> <a data-toggle="tooltip" title="" class="facebook" onclick="window.open('https://www.facebook.com/sharer.php?u=<?php the_permalink(); ?>','Facebook','width=600,height=300,left='+(screen.availWidth/2-300)+',top='+(screen.availHeight/2-150)+''); return false;" href="http://www.facebook.com/sharer.php?u=<?php the_permalink(); ?>" data-original-title="Share on Facebook"><i class="fa fa-facebook"></i></a></li>
|
||||
<li><a data-toggle="tooltip" title="" class="twitter" onclick="window.open('https://twitter.com/share?url=<?php the_permalink(); ?>&text=<?php the_title(); ?>','Twitter share','width=600,height=300,left='+(screen.availWidth/2-300)+',top='+(screen.availHeight/2-150)+''); return false;" href="http://twitter.com/share?url=<?php the_permalink(); ?>&text=<?php the_title(); ?>" data-original-title="Twittet it"><i class="fa fa-twitter"></i></a></li>
|
||||
</ul>
|
||||
</div>
|
|
@ -0,0 +1,18 @@
|
|||
<h3><?php ?><i class="<?php echo $speaker_icon; ?>"></i> <?php echo $speaker_label; ?></h3>
|
||||
<ul>
|
||||
<?php
|
||||
foreach ($speakers_id as $speakers) {
|
||||
?>
|
||||
<li>
|
||||
<a href='<?php echo get_the_permalink($speakers); ?>'><?php if (has_post_thumbnail($speakers)) {
|
||||
echo get_the_post_thumbnail($speakers, 'medium');
|
||||
} else {
|
||||
echo '<img src="' . plugins_url('../images/no-photo.jpg', __DIR__) . '"/>';
|
||||
} ?>
|
||||
<h6><?php echo get_the_title($speakers); ?></h6>
|
||||
</a>
|
||||
</li>
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
</ul>
|
|
@ -0,0 +1,3 @@
|
|||
<div class="mep-event-thumbnail">
|
||||
<?php the_post_thumbnail('full'); ?>
|
||||
</div>
|
|
@ -0,0 +1,64 @@
|
|||
<tr>
|
||||
<td align="Left"><?php echo $field['option_name_t']; ?>
|
||||
|
||||
<?php if ($mep_available_seat == 'on') { ?><div class="xtra-item-left"><?php echo max($total_left, 0); ?>
|
||||
|
||||
<?php echo mep_get_option('mep_left_text', 'label_setting_sec') ? mep_get_option('mep_left_text', 'label_setting_sec') : _e('Left:', 'mage-eventpress'); ?>
|
||||
|
||||
</div> <?php } ?>
|
||||
</td>
|
||||
<td class="ticket-qty">
|
||||
<span class="tkt-qty">
|
||||
<?php echo mep_get_option('mep_ticket_qty_text', 'label_setting_sec') ? mep_get_option('mep_ticket_qty_text', 'label_setting_sec') : _e('Ticket Qty:', 'mage-eventpress'); ?>
|
||||
</span>
|
||||
<?php
|
||||
if ($total_left > 0) {
|
||||
if ($qty_t_type == 'dropdown') { ?>
|
||||
<select name="option_qty[]" id="eventpxtp_<?php echo $count; ?>" <?php if ($total_left <= 0) { ?> style='display: none!important;' <?php } ?> class='extra-qty-box etp'>
|
||||
<?php
|
||||
for ($i = $total_min_seat; $i <= $total_left; $i++) { ?>
|
||||
<option value="<?php echo $i; ?>" <?php if ($i == $default_quantity) {
|
||||
echo 'Selected';
|
||||
} ?>><?php echo $i; ?>
|
||||
<?php echo mep_get_option('mep_ticket_text', 'label_setting_sec') ? mep_get_option('mep_ticket_text', 'label_setting_sec') : _e('Ticket:', 'mage-eventpress'); ?>
|
||||
</option>
|
||||
<?php } ?>
|
||||
</select>
|
||||
<?php } else { ?>
|
||||
|
||||
<div class="mage_input_group">
|
||||
<span class="fa fa-minus qty_dec"></span>
|
||||
<input id="eventpxtp_<?php echo $count; ?>" type="text" class='extra-qty-box etp' name='option_qty[]' data-price='<?php echo $ticket_price; ?>' value='<?php echo $default_quantity; ?>' min="<?php echo $total_min_seat; ?>" max="<?php echo max($total_seats, 0); ?>">
|
||||
<span class="fa fa-plus qty_inc"></span>
|
||||
</div>
|
||||
<?php }
|
||||
} else {
|
||||
?>
|
||||
<input id="eventpxtp_<?php echo $count; ?>" type="hidden" class='extra-qty-box etp' name='option_qty[]' data-price='0' value='0' min="0" max="0">
|
||||
<?php
|
||||
_e('No Seat Available', 'mage-eventpress');
|
||||
}
|
||||
$ticket_name = $field['option_name_t'];
|
||||
do_action('mep_after_ticket_type_qty', $post_id, $ticket_name, $field, $default_quantity);
|
||||
?>
|
||||
</td>
|
||||
<td class="ticket-price"><span class="tkt-pric">
|
||||
<?php echo mep_get_option('mep_per_ticket_price_text', 'label_setting_sec') ? mep_get_option('mep_per_ticket_price_text', 'label_setting_sec') : _e('Per Ticket Price:', 'mage-eventpress'); ?>
|
||||
</span> <strong><?php echo wc_price($ticket_price); ?></strong>
|
||||
<?php if ($total_left > 0) { ?>
|
||||
<p style="display: none;" class="price_jq"><?php echo $ticket_price; ?></p>
|
||||
|
||||
<?php } ?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td colspan="3" class='user-innnf'>
|
||||
<input type="hidden" name='mep_event_start_date[]' value="<?php echo $start_date; ?>">
|
||||
<input type="hidden" name='option_name[]' value='<?php echo $field['option_name_t']; ?>'>
|
||||
<input type="hidden" name='option_price[]' value='<?php echo $ticket_price; ?>'>
|
||||
<input type="hidden" name='max_qty[]' value='<?php if(array_key_exists('option_max_qty',$field)){ echo $field['option_max_qty']; }else{ echo ''; } ?>'>
|
||||
<div class="user-info-sec">
|
||||
<div id="dadainfo_<?php echo $count; ?>" class="dada-info"></div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
|
@ -0,0 +1 @@
|
|||
<h2><?php the_title(); ?></h2>
|
|
@ -0,0 +1 @@
|
|||
<h5><strong><?php echo mep_get_option('mep_total_seat_text', 'label_setting_sec') ? mep_get_option('mep_total_seat_text', 'label_setting_sec') : _e('Total Seat:', 'mage-eventpress'); ?></strong> <?php echo $total_seat; if ($mep_available_seat == 'on') { ?> (<strong><?php echo max($total_left, 0); ?></strong> <?php _e('Left', 'mage-eventpress'); ?>)<?php } ?></h5>
|
|
@ -3,11 +3,13 @@
|
|||
* Plugin Name: Woocommerce Events Manager
|
||||
* Plugin URI: http://mage-people.com
|
||||
* Description: A Complete Event Solution for WordPress by MagePeople..
|
||||
* Version: 3.2.6
|
||||
* Version: 3.3.0
|
||||
* Author: MagePeople Team
|
||||
* Author URI: http://www.mage-people.com/
|
||||
* Text Domain: mage-eventpress
|
||||
* Domain Path: /languages/
|
||||
* WC requires at least: 3.0.9
|
||||
* WC tested up to: 4.2.0*
|
||||
*/
|
||||
|
||||
if (!defined('ABSPATH')) {
|
||||
|
|
Loading…
Reference in New Issue