v 3.4.2
This commit is contained in:
parent
b122a3ba9a
commit
f86821706f
@ -825,11 +825,19 @@ class MP_Event_All_Info_In_One
|
||||
$reg_checked = 'checked';
|
||||
}
|
||||
?>
|
||||
<tr>
|
||||
<th><span><?php _e('Event SKU No:', 'mage-eventpress'); ?></span></th>
|
||||
<td colspan="3">
|
||||
<label>
|
||||
<input class="mep_input_text" type="text" name="mep_event_sku" value="<?php echo get_post_meta($post_id,'_sku',true); ?>" />
|
||||
</label>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<th><span><?php _e('Registration On/Off:', 'mage-eventpress'); ?></span></th>
|
||||
<td colspan="3">
|
||||
<label>
|
||||
|
||||
<input class="mp_opacity_zero" type="checkbox" name="mep_reg_status" <?php echo $reg_checked; ?> />
|
||||
<span class="slider round"></span>
|
||||
</label>
|
||||
@ -1226,6 +1234,7 @@ function mep_event_meta_save($post_id)
|
||||
$mep_available_seat = isset($_POST['mep_available_seat']) ? strip_tags($_POST['mep_available_seat']) : 'off';
|
||||
$_tax_status = isset($_POST['_tax_status']) ? strip_tags($_POST['_tax_status']) : 'none';
|
||||
$_tax_class = isset($_POST['_tax_class']) ? strip_tags($_POST['_tax_class']) : '';
|
||||
$sku = isset($_POST['mep_event_sku']) ? strip_tags($_POST['mep_event_sku']) : $post_id;
|
||||
$mep_rich_text_status = isset($_POST['mep_rich_text_status']) ? strip_tags($_POST['mep_rich_text_status']) : 'enable';
|
||||
|
||||
if ($mep_reset_status == 'on') {
|
||||
@ -1282,7 +1291,7 @@ function mep_event_meta_save($post_id)
|
||||
update_post_meta($pid, 'mep_sgm', $mep_sgm);
|
||||
update_post_meta($pid, '_price', 0);
|
||||
update_post_meta($pid, '_virtual', 'yes');
|
||||
update_post_meta($pid, '_sku', $pid);
|
||||
update_post_meta($pid, '_sku', $sku);
|
||||
|
||||
if (isset($_POST['mep_event_type']) && strip_tags($_POST['mep_event_type'])) {
|
||||
$mep_event_type = 'online';
|
||||
|
@ -127,13 +127,13 @@ function mep_display_custom_fields_text_cart($item_data, $cart_item)
|
||||
}
|
||||
if (is_array($user_info) && sizeof($user_info) > 0) {
|
||||
echo '<li>';
|
||||
echo mep_cart_display_user_list($user_info);
|
||||
echo mep_cart_display_user_list($user_info,$eid);
|
||||
echo '</li>';
|
||||
}
|
||||
} else {
|
||||
if (is_array($user_info) && sizeof($user_info) > 0) {
|
||||
echo '<li>';
|
||||
echo mep_cart_display_user_list($user_info);
|
||||
echo mep_cart_display_user_list($user_info,$eid);
|
||||
echo '</li>';
|
||||
} else {
|
||||
if($hide_date_status == 'no'){
|
||||
@ -242,6 +242,29 @@ function mep_add_custom_fields_text_to_order_items($item, $cart_item_key, $value
|
||||
mep_cart_order_data_save_ticket_type($item,$ticket_type_arr,$eid);
|
||||
|
||||
}
|
||||
$custom_forms_id = mep_get_user_custom_field_ids($eid);
|
||||
|
||||
foreach ($event_user_info as $userinf) {
|
||||
if ($userinf['user_name']) { $item->add_meta_data(__('Name', 'mage-eventpress'), $userinf['user_name']); }
|
||||
if ($userinf['user_email']) { $item->add_meta_data(__('Email', 'mage-eventpress'), $userinf['user_email']); }
|
||||
if ($userinf['user_phone']) { $item->add_meta_data(__('Phone', 'mage-eventpress'), $userinf['user_phone']); }
|
||||
if ($userinf['user_address']) { $item->add_meta_data(__('Address', 'mage-eventpress'), $userinf['user_address']); }
|
||||
if ($userinf['user_gender']) { $item->add_meta_data(__('Gender', 'mage-eventpress'), $userinf['user_gender']); }
|
||||
if ($userinf['user_tshirtsize']) { $item->add_meta_data(__('T-Shirt Size', 'mage-eventpress'), $userinf['user_tshirtsize']); }
|
||||
if ($userinf['user_company']) { $item->add_meta_data(__('Company', 'mage-eventpress'), $userinf['user_company']); }
|
||||
if ($userinf['user_designation']) { $item->add_meta_data(__('Designation', 'mage-eventpress'), $userinf['user_designation']); }
|
||||
if ($userinf['user_website']) { $item->add_meta_data(__('Website', 'mage-eventpress'), $userinf['user_website']); }
|
||||
if ($userinf['user_vegetarian']) { $item->add_meta_data(__('Vegetarian', 'mage-eventpress'), $userinf['user_vegetarian']); }
|
||||
if(sizeof($custom_forms_id) > 0){
|
||||
foreach($custom_forms_id as $key => $value){
|
||||
$item->add_meta_data(__($key, 'mage-eventpress'), $userinf[$value]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (is_array($event_extra_service) && sizeof($event_extra_service) > 0) {
|
||||
foreach ($event_extra_service as $extra_service) {
|
||||
|
@ -9,6 +9,7 @@ require_once(dirname(__DIR__) . '/lib/classes/class-theme-page.php');
|
||||
require_once(dirname(__DIR__) . '/lib/classes/class-menu-page.php');
|
||||
require_once(dirname(__DIR__) . "/inc/class/mep_settings_api.php");
|
||||
require_once(dirname(__DIR__) . "/inc/welcome.php");
|
||||
require_once(dirname(__DIR__) . "/inc/status.php");
|
||||
require_once(dirname(__DIR__) . "/inc/mep_cpt.php");
|
||||
require_once(dirname(__DIR__) . "/inc/mep_tax.php");
|
||||
require_once(dirname(__DIR__) . "/inc/mep_event_meta.php");
|
||||
|
@ -1026,8 +1026,7 @@ function mep_merge_saved_array($arr1,$arr2){
|
||||
|
||||
|
||||
if (!function_exists('mep_template_file_path')) {
|
||||
function mep_template_file_path($file_name){
|
||||
// $template_path = ;
|
||||
function mep_template_file_path($file_name){
|
||||
$template_path = get_stylesheet_directory().'/mage-events/';
|
||||
$default_path = plugin_dir_path( __DIR__ ) . 'templates/';
|
||||
$thedir = is_dir($template_path) ? $template_path : $default_path;
|
||||
@ -2917,12 +2916,33 @@ function mep_cart_event_extra_service($type,$total_price,$product_id){
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
function mep_get_user_custom_field_ids($event_id){
|
||||
$reg_form_id = mep_fb_get_reg_form_id($event_id);
|
||||
$mep_form_builder_data = get_post_meta($reg_form_id, 'mep_form_builder_data', true) ? get_post_meta($reg_form_id, 'mep_form_builder_data', true) : [];
|
||||
$form_id = [];
|
||||
// print_r($mep_form_builder_data); mep_fbc_label
|
||||
if ( sizeof($mep_form_builder_data) > 0 ) {
|
||||
foreach ( $mep_form_builder_data as $_field ) {
|
||||
$form_id[$_field['mep_fbc_label']] = $_field['mep_fbc_id'];
|
||||
}
|
||||
}
|
||||
return $form_id;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (!function_exists('mep_cart_display_user_list')) {
|
||||
function mep_cart_display_user_list($user_info){
|
||||
function mep_cart_display_user_list($user_info,$event_id){
|
||||
$custom_forms_id = mep_get_user_custom_field_ids($event_id);
|
||||
ob_start();
|
||||
foreach ($user_info as $userinf) {
|
||||
// echo 123;
|
||||
?>
|
||||
<ul>
|
||||
<ul>
|
||||
<?php if ($userinf['user_name']) { ?> <li><?php _e('Name', 'mage-eventpress'); echo ": ";
|
||||
echo $userinf['user_name']; ?></li> <?php } ?>
|
||||
<?php if ($userinf['user_email']) { ?> <li><?php _e('Email', 'mage-eventpress'); echo ": ";
|
||||
@ -2942,12 +2962,17 @@ function mep_cart_display_user_list($user_info){
|
||||
<?php if ($userinf['user_website']) { ?> <li><?php _e('Website', 'mage-eventpress'); echo ": ";
|
||||
echo $userinf['user_website']; ?></li> <?php } ?>
|
||||
<?php if ($userinf['user_vegetarian']) { ?> <li><?php _e('Vegetarian', 'mage-eventpress'); echo ": ";
|
||||
echo $userinf['user_vegetarian']; ?></li> <?php } ?>
|
||||
<?php if ($userinf['user_ticket_type']) { ?> <li><?php _e('Ticket Type', 'mage-eventpress'); echo ": ";
|
||||
echo $userinf['user_ticket_type']; ?></li> <?php } ?>
|
||||
echo $userinf['user_vegetarian']; ?></li> <?php } ?>
|
||||
<?php if(sizeof($custom_forms_id) > 0){
|
||||
foreach($custom_forms_id as $key => $value){
|
||||
?>
|
||||
<li><?php _e($key, 'mage-eventpress'); echo ": ".$userinf[$value]; ?></li>
|
||||
<?php
|
||||
}
|
||||
} ?>
|
||||
<?php if ($userinf['user_ticket_type']) { ?> <li><?php _e('Ticket Type', 'mage-eventpress'); echo ": ".$userinf['user_ticket_type']; ?></li> <?php } ?>
|
||||
<li><?php _e('Event Date', 'mage-eventpress'); echo ": "; ?> <?php echo get_mep_datetime($userinf['user_event_date'], 'date-time-text'); ?></li>
|
||||
</ul>
|
||||
|
||||
<?php
|
||||
}
|
||||
return apply_filters('mep_display_user_info_in_cart_list',ob_get_clean(),$user_info);
|
||||
@ -3523,4 +3548,17 @@ function mep_show_product_cat_in_event() {
|
||||
}else{
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
function mep_woo_install_check(){
|
||||
include_once(ABSPATH . 'wp-admin/includes/plugin.php');
|
||||
$plugin_dir = ABSPATH . 'wp-content/plugins/woocommerce';
|
||||
if (is_plugin_active('woocommerce/woocommerce.php')) {
|
||||
return 'Yes';
|
||||
}elseif(is_dir($plugin_dir)){
|
||||
return 'Installed But Not Active';
|
||||
}else{
|
||||
return 'No';
|
||||
}
|
||||
}
|
@ -81,12 +81,10 @@ function mep_get_all_order_data_and_create_attendee()
|
||||
|
||||
|
||||
if (get_option('mep_event_default_date_update_2020') != 'completed') {
|
||||
|
||||
$args = array(
|
||||
'post_type' => 'mep_events',
|
||||
'posts_per_page' => -1
|
||||
);
|
||||
|
||||
$qr = new WP_Query($args);
|
||||
foreach ($qr->posts as $result) {
|
||||
$post_id = $result->ID;
|
||||
@ -101,8 +99,7 @@ function mep_get_all_order_data_and_create_attendee()
|
||||
update_post_meta($post_id, 'event_start_datetime', $event_start_datetime);
|
||||
update_post_meta($post_id, 'event_end_datetime', $event_end_datetime);
|
||||
}
|
||||
update_option('mep_event_default_date_update_2020', 'completed');
|
||||
//die();
|
||||
update_option('mep_event_default_date_update_2020', 'completed');
|
||||
}
|
||||
|
||||
/**
|
||||
@ -123,8 +120,7 @@ function mep_get_all_order_data_and_create_attendee()
|
||||
$event_expire_datetime = sizeof($md) > 0 ? date('Y-m-d H:i:s', strtotime($md['event_more_end_date'] . ' ' . $md['event_more_end_time'])) : date('Y-m-d H:i:s', strtotime(get_post_meta($post_id, 'event_end_datetime', true)));
|
||||
update_post_meta($post_id, 'event_expire_datetime', $event_expire_datetime);
|
||||
}
|
||||
update_option('mep_event_expire_date_upgration', 'completed');
|
||||
// die();
|
||||
update_option('mep_event_expire_date_upgration', 'completed');
|
||||
}
|
||||
|
||||
|
||||
|
84
inc/status.php
Normal file
84
inc/status.php
Normal file
@ -0,0 +1,84 @@
|
||||
<?php
|
||||
if (!defined('ABSPATH')) {
|
||||
die;
|
||||
} // Cannot access pages directly.
|
||||
|
||||
|
||||
|
||||
//Add admin page to the menu
|
||||
add_action('admin_menu', 'mep_event_status_admin_menu');
|
||||
function mep_event_status_admin_menu()
|
||||
{
|
||||
add_submenu_page('edit.php?post_type=mep_events', __('Status', 'mage-eventpress'), __('<span style="color:yellow">Status</span>', 'mage-eventpress'), 'manage_options', 'mep_event_status_page', 'mep_event_status_page');
|
||||
}
|
||||
function mep_event_status_page()
|
||||
{
|
||||
$wp_v = get_bloginfo( 'version' );
|
||||
$wc_v = WC()->version;
|
||||
$wc_i = mep_woo_install_check();
|
||||
$from_name = mep_get_option( 'mep_email_form_name', 'email_setting_sec', '');
|
||||
$from_email = mep_get_option( 'mep_email_form_email', 'email_setting_sec', '');
|
||||
?>
|
||||
<style>
|
||||
.mep_success{
|
||||
color:green;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.mep_warning{
|
||||
color:#e6b14e;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.mep_error{
|
||||
color:red;
|
||||
font-weight: bold;
|
||||
}
|
||||
</style>
|
||||
|
||||
<!-- Create a header in the default WordPress 'wrap' container -->
|
||||
<div class="wrap">
|
||||
<?php do_action('mep_event_status_notice_sec'); ?>
|
||||
<table class="wc_status_table widefat" cellspacing="0" id="status">
|
||||
<thead>
|
||||
<tr>
|
||||
<th colspan="3" data-export-label="WordPress Environment"><h2>WooCommerce Event Manager Environment Status</h2></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td data-export-label="WC Version">WordPress Version:</td>
|
||||
<td class="help"><span class="woocommerce-help-tip"></span></td>
|
||||
<td><?php if($wp_v > 5.5){ echo '<span class="mep_success"> <span class="dashicons dashicons-saved"></span>'.$wp_v.'</span>'; }else{ echo '<span class="mep_warning"> <span class="dashicons dashicons-saved"></span>'.$wp_v.'</span>'; } ?></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td data-export-label="WC Version">Woocommerce Installed:</td>
|
||||
<td class="help"><span class="woocommerce-help-tip"></span></td>
|
||||
<td><?php if($wc_i == 'Yes'){ echo '<span class="mep_success"> <span class="dashicons dashicons-saved"></span>'.$wc_i.'</span>'; }else{ echo '<span class="mep_error"> <span class="dashicons dashicons-no-alt"></span>'.$wc_i.'</span>'; } ?></td>
|
||||
</tr>
|
||||
<?php if(mep_woo_install_check() == 'Yes'){ ?>
|
||||
<tr>
|
||||
<td data-export-label="WC Version">Woocommerce Version:</td>
|
||||
<td class="help"><span class="woocommerce-help-tip"></span></td>
|
||||
<td><?php if($wc_v > 4.8){ echo '<span class="mep_success"> <span class="dashicons dashicons-saved"></span>'.$wc_v.'</span>'; }else{ echo '<span class="mep_warning"> <span class="dashicons dashicons-no-alt"></span>'.$wc_v.'</span>'; } ?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td data-export-label="WC Version">Email From Name:</td>
|
||||
<td class="help"><span class="woocommerce-help-tip"></span></td>
|
||||
<td><?php if($from_name){ echo '<span class="mep_success"> <span class="dashicons dashicons-saved"></span>'.$from_name.'</span>'; }else{ echo '<span class="mep_error"> <span class="dashicons dashicons-no-alt"></span></span>'; } ?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td data-export-label="WC Version">From Email Address:</td>
|
||||
<td class="help"><span class="woocommerce-help-tip"></span></td>
|
||||
<td><?php if($from_email){ echo '<span class="mep_success"> <span class="dashicons dashicons-saved"></span>'.$from_email.'</span>'; }else{ echo '<span class="mep_error"> <span class="dashicons dashicons-no-alt"></span></span>'; } ?></td>
|
||||
</tr>
|
||||
<?php }
|
||||
|
||||
|
||||
do_action('mep_event_status_table_item_sec'); ?>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<?php
|
||||
}
|
@ -15,4 +15,19 @@
|
||||
$(this).slideUp('fast').siblings('.mp_event_visible_event_time').slideDown('slow').siblings('.mp_event_hide_event_time').slideUp('slow');
|
||||
});
|
||||
});
|
||||
}(jQuery));
|
||||
}(jQuery));
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
jQuery(document).ready(function($){
|
||||
function mp_remove_required(){
|
||||
jQuery('input, select, textarea').each(function (){
|
||||
jQuery(this).removeAttr('required');
|
||||
});
|
||||
}
|
||||
mp_remove_required();
|
||||
|
||||
});
|
@ -321,7 +321,7 @@ msgstr ""
|
||||
|
||||
#: inc/admin_setting_panel.php:540
|
||||
msgid "Enter the text which you want to display as Left."
|
||||
msgstr "Geben Sie den Text für die Anzeige Links ein."
|
||||
msgstr "Geben Sie den Text für die Anzeige Verfügbar ein."
|
||||
|
||||
#: inc/admin_setting_panel.php:412
|
||||
msgid ""
|
||||
|
Binary file not shown.
@ -2,12 +2,12 @@ msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: EN\n"
|
||||
"POT-Creation-Date: 2018-11-01 11:20+0600\n"
|
||||
"PO-Revision-Date: 2021-01-25 18:25+0600\n"
|
||||
"PO-Revision-Date: 2018-12-17 16:28+0600\n"
|
||||
"Language-Team: \n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"X-Generator: Poedit 2.3.1\n"
|
||||
"X-Generator: Poedit 2.0.6\n"
|
||||
"X-Poedit-Basepath: ..\n"
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"X-Poedit-KeywordsList: __;_e\n"
|
||||
@ -800,7 +800,7 @@ msgstr "Naam"
|
||||
|
||||
#: templates/template-prts/event_ticket_type.php:28
|
||||
msgid "Left"
|
||||
msgstr "Beschikbaar"
|
||||
msgstr "Links"
|
||||
|
||||
#: templates/template-prts/event_ticket_type.php:31
|
||||
msgid "Ticket Qty:"
|
||||
|
12
readme.txt
12
readme.txt
@ -694,4 +694,14 @@ Hook Added
|
||||
Some Bug fixed.
|
||||
Early Bird Ticket Feature added
|
||||
|
||||
25 Jan 2021*
|
||||
25 Jan 2021*
|
||||
|
||||
|
||||
= 3.4.2=
|
||||
* Update Release:
|
||||
Event SKU Added.
|
||||
Hook Added
|
||||
Some Bug fixed.
|
||||
Event Server Status Check Page Added
|
||||
|
||||
03 Feb 2021*
|
@ -3,7 +3,7 @@
|
||||
* Plugin Name: Woocommerce Events Manager
|
||||
* Plugin URI: http://mage-people.com
|
||||
* Description: A Complete Event Solution for WordPress by MagePeople..
|
||||
* Version: 3.4.1
|
||||
* Version: 3.4.2
|
||||
* Author: MagePeople Team
|
||||
* Author URI: http://www.mage-people.com/
|
||||
* Text Domain: mage-eventpress
|
||||
|
Loading…
x
Reference in New Issue
Block a user