@@ -13,8 +13,8 @@ |
||
13 | 13 | */ |
14 | 14 | namespace EventEspressoBatchRequest\JobHandlerBaseClasses; |
15 | 15 | |
16 | -if ( ! defined( 'EVENT_ESPRESSO_VERSION' ) ) { |
|
17 | - exit( 'No direct script access allowed' ); |
|
16 | +if ( ! defined('EVENT_ESPRESSO_VERSION')) { |
|
17 | + exit('No direct script access allowed'); |
|
18 | 18 | } |
19 | 19 | |
20 | 20 |
@@ -22,9 +22,9 @@ discard block |
||
22 | 22 | * @param null $timezone |
23 | 23 | * @return EE_Extra_Join|mixed |
24 | 24 | */ |
25 | - public static function new_instance( $props_n_values = array(), $timezone = NULL ) { |
|
26 | - $has_object = parent::_check_for_object( $props_n_values, __CLASS__, $timezone ); |
|
27 | - return $has_object ? $has_object : new self( $props_n_values, FALSE, $timezone ); |
|
25 | + public static function new_instance($props_n_values = array(), $timezone = NULL) { |
|
26 | + $has_object = parent::_check_for_object($props_n_values, __CLASS__, $timezone); |
|
27 | + return $has_object ? $has_object : new self($props_n_values, FALSE, $timezone); |
|
28 | 28 | } |
29 | 29 | |
30 | 30 | |
@@ -34,8 +34,8 @@ discard block |
||
34 | 34 | * @param null $timezone |
35 | 35 | * @return EE_Extra_Join |
36 | 36 | */ |
37 | - public static function new_instance_from_db ( $props_n_values = array(), $timezone = NULL ) { |
|
38 | - return new self( $props_n_values, TRUE, $timezone ); |
|
37 | + public static function new_instance_from_db($props_n_values = array(), $timezone = NULL) { |
|
38 | + return new self($props_n_values, TRUE, $timezone); |
|
39 | 39 | } |
40 | 40 | |
41 | 41 | } |
@@ -1,4 +1,6 @@ |
||
1 | -<?php if ( ! defined('EVENT_ESPRESSO_VERSION')) exit('No direct script access allowed'); |
|
1 | +<?php if ( ! defined('EVENT_ESPRESSO_VERSION')) { |
|
2 | + exit('No direct script access allowed'); |
|
3 | +} |
|
2 | 4 | /** |
3 | 5 | * Contains definition for EE_Extra_Join model object |
4 | 6 | * @package Event Espresso |
@@ -19,11 +19,11 @@ discard block |
||
19 | 19 | <div id="espresso-event-details-dv" class="" > |
20 | 20 | <?php |
21 | 21 | // Start the Loop. |
22 | - while ( have_posts() ) : the_post(); |
|
22 | + while (have_posts()) : the_post(); |
|
23 | 23 | // Include the post TYPE-specific template for the content. |
24 | - espresso_get_template_part( 'content', 'espresso_events' ); |
|
24 | + espresso_get_template_part('content', 'espresso_events'); |
|
25 | 25 | // If comments are open or we have at least one comment, load up the comment template. |
26 | - if ( comments_open() || get_comments_number() ) { |
|
26 | + if (comments_open() || get_comments_number()) { |
|
27 | 27 | comments_template(); |
28 | 28 | } |
29 | 29 | endwhile; |
@@ -35,6 +35,6 @@ discard block |
||
35 | 35 | </div><!-- #primary --> |
36 | 36 | |
37 | 37 | <?php |
38 | -get_sidebar( 'content' ); |
|
38 | +get_sidebar('content'); |
|
39 | 39 | get_sidebar(); |
40 | 40 | get_footer(); |
41 | 41 | \ No newline at end of file |
@@ -1,6 +1,7 @@ |
||
1 | 1 | <?php |
2 | -if (!defined('EVENT_ESPRESSO_VERSION') ) |
|
2 | +if (!defined('EVENT_ESPRESSO_VERSION') ) { |
|
3 | 3 | exit('NO direct script access allowed'); |
4 | +} |
|
4 | 5 | |
5 | 6 | /** |
6 | 7 | * Event Espresso |
@@ -1,5 +1,5 @@ discard block |
||
1 | 1 | <?php |
2 | -if (!defined('EVENT_ESPRESSO_VERSION') ) |
|
2 | +if ( ! defined('EVENT_ESPRESSO_VERSION')) |
|
3 | 3 | exit('NO direct script access allowed'); |
4 | 4 | |
5 | 5 | /** |
@@ -30,8 +30,8 @@ discard block |
||
30 | 30 | class Support_Admin_Page extends EE_Admin_Page { |
31 | 31 | |
32 | 32 | |
33 | - public function __construct( $routing = TRUE ) { |
|
34 | - parent::__construct( $routing ); |
|
33 | + public function __construct($routing = TRUE) { |
|
34 | + parent::__construct($routing); |
|
35 | 35 | } |
36 | 36 | |
37 | 37 | |
@@ -84,14 +84,14 @@ discard block |
||
84 | 84 | 'nav' => array( |
85 | 85 | 'label' => __('Shortcodes', 'event_espresso'), |
86 | 86 | 'order' => 30), |
87 | - 'metaboxes' => array_merge( $this->_default_espresso_metaboxes, array('_shortcodes_boxes' ) ), |
|
87 | + 'metaboxes' => array_merge($this->_default_espresso_metaboxes, array('_shortcodes_boxes')), |
|
88 | 88 | 'require_nonce' => FALSE |
89 | 89 | ), |
90 | 90 | 'contact_support' => array( |
91 | 91 | 'nav' => array( |
92 | 92 | 'label' => __('Support', 'event_espresso'), |
93 | 93 | 'order' => 40), |
94 | - 'metaboxes' => array_merge( $this->_default_espresso_metaboxes, array( '_support_boxes' ) ), |
|
94 | + 'metaboxes' => array_merge($this->_default_espresso_metaboxes, array('_support_boxes')), |
|
95 | 95 | 'require_nonce' => FALSE |
96 | 96 | ), |
97 | 97 | 'developers' => array( |
@@ -119,8 +119,8 @@ discard block |
||
119 | 119 | |
120 | 120 | |
121 | 121 | protected function _installation() { |
122 | - $template_path = EE_SUPPORT_ADMIN_TEMPLATE_PATH . 'support_admin_details_installation.template.php'; |
|
123 | - $this->_template_args['admin_page_content'] = EEH_Template::display_template( $template_path, '', TRUE); |
|
122 | + $template_path = EE_SUPPORT_ADMIN_TEMPLATE_PATH.'support_admin_details_installation.template.php'; |
|
123 | + $this->_template_args['admin_page_content'] = EEH_Template::display_template($template_path, '', TRUE); |
|
124 | 124 | $this->display_admin_page_with_sidebar(); |
125 | 125 | } |
126 | 126 | |
@@ -145,10 +145,10 @@ discard block |
||
145 | 145 | 'other_resources' => __('Other Resources', 'event_espresso') |
146 | 146 | ); |
147 | 147 | |
148 | - foreach ( $boxes as $box => $label ) { |
|
149 | - $template_path = EE_SUPPORT_ADMIN_TEMPLATE_PATH . 'support_admin_details_' . $box . '.template.php'; |
|
148 | + foreach ($boxes as $box => $label) { |
|
149 | + $template_path = EE_SUPPORT_ADMIN_TEMPLATE_PATH.'support_admin_details_'.$box.'.template.php'; |
|
150 | 150 | $callback_args = array('template_path' => $template_path); |
151 | - add_meta_box( 'espresso_' . $box . '_settings', $label, create_function('$post, $metabox', 'echo EEH_Template::display_template( $metabox["args"]["template_path"], "", TRUE );'), $this->_current_screen_id, 'normal', 'high', $callback_args); |
|
151 | + add_meta_box('espresso_'.$box.'_settings', $label, create_function('$post, $metabox', 'echo EEH_Template::display_template( $metabox["args"]["template_path"], "", TRUE );'), $this->_current_screen_id, 'normal', 'high', $callback_args); |
|
152 | 152 | } |
153 | 153 | } |
154 | 154 | |
@@ -169,15 +169,15 @@ discard block |
||
169 | 169 | 'shortcodes_event_listings' => __('Event Listings', 'event_espresso'), |
170 | 170 | 'shortcodes_ticket_selector' => __('Event Ticket Selector', 'event_espresso'), |
171 | 171 | 'shortcodes_category' => __('Event Categories', 'event_espresso'), |
172 | - 'shortcodes_attendee' => __( 'Event Attendees', 'event_espresso' ) |
|
172 | + 'shortcodes_attendee' => __('Event Attendees', 'event_espresso') |
|
173 | 173 | /*'shortcodes_single_events' => __('Single Events', 'event_espresso'),*/ |
174 | 174 | /*'shortcodes_attendee_listings' => __('Attendee Listings', 'event_espresso'),*/ |
175 | 175 | ); |
176 | 176 | |
177 | - foreach ( $boxes as $box => $label ) { |
|
178 | - $template_path = EE_SUPPORT_ADMIN_TEMPLATE_PATH . 'support_admin_details_' . $box . '.template.php'; |
|
177 | + foreach ($boxes as $box => $label) { |
|
178 | + $template_path = EE_SUPPORT_ADMIN_TEMPLATE_PATH.'support_admin_details_'.$box.'.template.php'; |
|
179 | 179 | $callback_args = array('template_path' => $template_path); |
180 | - add_meta_box( 'espresso_' . $box . '_settings', $label, create_function('$post, $metabox', 'echo EEH_Template::display_template( $metabox["args"]["template_path"], "", TRUE );'), $this->_current_screen_id, 'normal', 'high', $callback_args); |
|
180 | + add_meta_box('espresso_'.$box.'_settings', $label, create_function('$post, $metabox', 'echo EEH_Template::display_template( $metabox["args"]["template_path"], "", TRUE );'), $this->_current_screen_id, 'normal', 'high', $callback_args); |
|
181 | 181 | } |
182 | 182 | } |
183 | 183 | |
@@ -196,17 +196,17 @@ discard block |
||
196 | 196 | 'important_information' => __('Important Information', 'event_espresso') |
197 | 197 | ); |
198 | 198 | |
199 | - foreach ( $boxes as $box => $label ) { |
|
200 | - $template_path = EE_SUPPORT_ADMIN_TEMPLATE_PATH . 'support_admin_details_' . $box . '.template.php'; |
|
199 | + foreach ($boxes as $box => $label) { |
|
200 | + $template_path = EE_SUPPORT_ADMIN_TEMPLATE_PATH.'support_admin_details_'.$box.'.template.php'; |
|
201 | 201 | $callback_args = array('template_path' => $template_path, 'template_args' => $this->_template_args); |
202 | - add_meta_box( 'espresso_' . $box . '_settings', $label, create_function('$post, $metabox', 'echo EEH_Template::display_template( $metabox["args"]["template_path"], $metabox["args"]["template_args"], TRUE );'), $this->_current_screen_id, 'normal', 'high', $callback_args); |
|
202 | + add_meta_box('espresso_'.$box.'_settings', $label, create_function('$post, $metabox', 'echo EEH_Template::display_template( $metabox["args"]["template_path"], $metabox["args"]["template_args"], TRUE );'), $this->_current_screen_id, 'normal', 'high', $callback_args); |
|
203 | 203 | } |
204 | 204 | } |
205 | 205 | |
206 | 206 | |
207 | 207 | protected function _developers() { |
208 | - $template_path = EE_SUPPORT_ADMIN_TEMPLATE_PATH . 'developers_admin_details.template.php'; |
|
209 | - $this->_template_args['admin_page_content'] = EEH_Template::display_template($template_path, array(), true ); |
|
208 | + $template_path = EE_SUPPORT_ADMIN_TEMPLATE_PATH.'developers_admin_details.template.php'; |
|
209 | + $this->_template_args['admin_page_content'] = EEH_Template::display_template($template_path, array(), true); |
|
210 | 210 | $this->display_admin_page_with_sidebar(); |
211 | 211 | } |
212 | 212 | } //end Support_Admin_Page class |
@@ -19,7 +19,6 @@ |
||
19 | 19 | * @package Event Espresso |
20 | 20 | * @subpackage includes/models/ |
21 | 21 | * @author Michael Nelson |
22 | - |
|
23 | 22 | * Model field for representing a column that CAN contain serialized text, or a regular string. |
24 | 23 | * But either way, the string or the array's values can ONLY contain simple HTML tags. |
25 | 24 | * If you want to allow Full HTML in the value, use EE_Maybe_Serialized_Text_Field |
@@ -21,16 +21,16 @@ discard block |
||
21 | 21 | * |
22 | 22 | * ------------------------------------------------------------------------ |
23 | 23 | */ |
24 | -require_once ( EE_MODELS . 'EEM_Base.model.php' ); |
|
24 | +require_once (EE_MODELS.'EEM_Base.model.php'); |
|
25 | 25 | |
26 | 26 | class EEM_Venue extends EEM_CPT_Base { |
27 | 27 | |
28 | 28 | // private instance of the Attendee object |
29 | 29 | protected static $_instance = NULL; |
30 | 30 | |
31 | - protected function __construct( $timezone = NULL ) { |
|
32 | - $this->singular_item = __('Venue','event_espresso'); |
|
33 | - $this->plural_item = __('Venues','event_espresso'); |
|
31 | + protected function __construct($timezone = NULL) { |
|
32 | + $this->singular_item = __('Venue', 'event_espresso'); |
|
33 | + $this->plural_item = __('Venues', 'event_espresso'); |
|
34 | 34 | $this->_tables = array( |
35 | 35 | 'Venue_CPT'=> new EE_Primary_Table('posts', 'ID'), |
36 | 36 | 'Venue_Meta'=>new EE_Secondary_Table('esp_venue_meta', 'VNUM_ID', 'VNU_ID') |
@@ -39,32 +39,32 @@ discard block |
||
39 | 39 | 'Venue_CPT'=>array( |
40 | 40 | 'VNU_ID'=>new EE_Primary_Key_Int_Field('ID', __("Venue ID", "event_espresso")), |
41 | 41 | 'VNU_name'=>new EE_Plain_Text_Field('post_title', __("Venue Name", "event_espresso"), false, ''), |
42 | - 'VNU_desc'=>new EE_Post_Content_Field('post_content', __("Venue Description", "event_espresso"), false,''), |
|
43 | - 'VNU_identifier'=>new EE_Slug_Field('post_name', __("Venue Identifier", "event_espresso"), false,''), |
|
44 | - 'VNU_created'=>new EE_Datetime_Field('post_date', __("Date Venue Created", "event_espresso"), FALSE,time()), |
|
45 | - 'VNU_short_desc'=>new EE_Plain_Text_Field('post_excerpt', __("Short Description of Venue", "event_espresso"), true,''), |
|
46 | - 'VNU_modified'=>new EE_Datetime_Field('post_modified', __("Venue Modified Date", "event_espresso"), FALSE,time()), |
|
47 | - 'VNU_wp_user'=>new EE_WP_User_Field('post_author', __("Venue Creator ID", "event_espresso"), false ), |
|
48 | - 'parent'=>new EE_Integer_Field('post_parent', __("Venue Parent ID", "event_espresso"), false,0), |
|
42 | + 'VNU_desc'=>new EE_Post_Content_Field('post_content', __("Venue Description", "event_espresso"), false, ''), |
|
43 | + 'VNU_identifier'=>new EE_Slug_Field('post_name', __("Venue Identifier", "event_espresso"), false, ''), |
|
44 | + 'VNU_created'=>new EE_Datetime_Field('post_date', __("Date Venue Created", "event_espresso"), FALSE, time()), |
|
45 | + 'VNU_short_desc'=>new EE_Plain_Text_Field('post_excerpt', __("Short Description of Venue", "event_espresso"), true, ''), |
|
46 | + 'VNU_modified'=>new EE_Datetime_Field('post_modified', __("Venue Modified Date", "event_espresso"), FALSE, time()), |
|
47 | + 'VNU_wp_user'=>new EE_WP_User_Field('post_author', __("Venue Creator ID", "event_espresso"), false), |
|
48 | + 'parent'=>new EE_Integer_Field('post_parent', __("Venue Parent ID", "event_espresso"), false, 0), |
|
49 | 49 | 'VNU_order'=>new EE_Integer_Field('menu_order', __("Venue order", "event_espresso"), false, 1), |
50 | - 'post_type'=>new EE_WP_Post_Type_Field('espresso_venues'),// EE_Plain_Text_Field('post_type', __("Venue post type", "event_espresso"), false, 'espresso_venues'), |
|
50 | + 'post_type'=>new EE_WP_Post_Type_Field('espresso_venues'), // EE_Plain_Text_Field('post_type', __("Venue post type", "event_espresso"), false, 'espresso_venues'), |
|
51 | 51 | ), |
52 | 52 | 'Venue_Meta'=>array( |
53 | 53 | 'VNUM_ID'=>new EE_DB_Only_Int_Field('VNUM_ID', __("ID of Venue Meta Row", "event_espresso"), false), |
54 | 54 | 'VNU_ID_fk'=>new EE_DB_Only_Int_Field('VNU_ID', __("Foreign Key to Venue Post ", "event_espresso"), false), |
55 | 55 | 'VNU_address'=>new EE_Plain_Text_Field('VNU_address', __("Venue Address line 1", "event_espresso"), true, ''), |
56 | - 'VNU_address2'=>new EE_Plain_Text_Field('VNU_address2', __("Venue Address line 2", "event_espresso"), true,''), |
|
56 | + 'VNU_address2'=>new EE_Plain_Text_Field('VNU_address2', __("Venue Address line 2", "event_espresso"), true, ''), |
|
57 | 57 | 'VNU_city'=>new EE_Plain_Text_Field('VNU_city', __("Venue City", "event_espresso"), true, ''), |
58 | 58 | 'STA_ID'=>new EE_Foreign_Key_Int_Field('STA_ID', __("State ID", "event_espresso"), true, null, 'State'), |
59 | 59 | 'CNT_ISO'=>new EE_Foreign_Key_String_Field('CNT_ISO', __("Country Code", "event_espresso"), true, null, 'Country'), |
60 | 60 | 'VNU_zip'=>new EE_Plain_Text_Field('VNU_zip', __("Venue Zip/Postal Code", "event_espresso"), true), |
61 | 61 | 'VNU_phone'=>new EE_Plain_Text_Field('VNU_phone', __("Venue Phone", "event_espresso"), true), |
62 | - 'VNU_capacity'=>new EE_Infinite_Integer_Field('VNU_capacity', __("Venue Capacity", "event_espresso"), true,EE_INF), |
|
62 | + 'VNU_capacity'=>new EE_Infinite_Integer_Field('VNU_capacity', __("Venue Capacity", "event_espresso"), true, EE_INF), |
|
63 | 63 | 'VNU_url'=>new EE_Plain_Text_Field('VNU_url', __('Venue Website', 'event_espresso'), true), |
64 | 64 | 'VNU_virtual_phone'=>new EE_Plain_Text_Field('VNU_virtual_phone', __('Call in Number', 'event_espresso'), true), |
65 | - 'VNU_virtual_url'=>new EE_Plain_Text_Field('VNU_virtual_url', __('Virtual URL', 'event_espresso'), true ), |
|
66 | - 'VNU_google_map_link'=>new EE_Plain_Text_Field('VNU_google_map_link', __('Google Map Link', 'event_espresso'), true ), |
|
67 | - 'VNU_enable_for_gmap'=>new EE_Boolean_Field('VNU_enable_for_gmap', __('Show Google Map?', 'event_espresso'), false, false ) |
|
65 | + 'VNU_virtual_url'=>new EE_Plain_Text_Field('VNU_virtual_url', __('Virtual URL', 'event_espresso'), true), |
|
66 | + 'VNU_google_map_link'=>new EE_Plain_Text_Field('VNU_google_map_link', __('Google Map Link', 'event_espresso'), true), |
|
67 | + 'VNU_enable_for_gmap'=>new EE_Boolean_Field('VNU_enable_for_gmap', __('Show Google Map?', 'event_espresso'), false, false) |
|
68 | 68 | |
69 | 69 | )); |
70 | 70 | $this->_model_relations = array( |
@@ -75,8 +75,8 @@ discard block |
||
75 | 75 | 'WP_User' => new EE_Belongs_To_Relation() |
76 | 76 | ); |
77 | 77 | //this model is generally available for reading |
78 | - $this->_cap_restriction_generators[ EEM_Base::caps_read ] = new EE_Restriction_Generator_Public(); |
|
79 | - parent::__construct( $timezone ); |
|
78 | + $this->_cap_restriction_generators[EEM_Base::caps_read] = new EE_Restriction_Generator_Public(); |
|
79 | + parent::__construct($timezone); |
|
80 | 80 | } |
81 | 81 | |
82 | 82 | } |
@@ -1,4 +1,6 @@ |
||
1 | -<?php if ( ! defined('EVENT_ESPRESSO_VERSION')) exit('No direct script access allowed'); |
|
1 | +<?php if ( ! defined('EVENT_ESPRESSO_VERSION')) { |
|
2 | + exit('No direct script access allowed'); |
|
3 | +} |
|
2 | 4 | /** |
3 | 5 | * Event Espresso |
4 | 6 | * |
@@ -7,33 +7,33 @@ discard block |
||
7 | 7 | * other than explicitly setting it to EE_INF. |
8 | 8 | * Makes use of constant EE_INF_IN_DB set in espresso.php, and EE_INF, which is a PHP constant definedin the ether |
9 | 9 | */ |
10 | -class EE_Infinite_Integer_Field extends EE_Model_Field_Base{ |
|
11 | - function get_wpdb_data_type(){ |
|
10 | +class EE_Infinite_Integer_Field extends EE_Model_Field_Base { |
|
11 | + function get_wpdb_data_type() { |
|
12 | 12 | return '%d'; |
13 | 13 | } |
14 | 14 | function prepare_for_use_in_db($value_of_field_on_model_object) { |
15 | - if($value_of_field_on_model_object === EE_INF){ |
|
15 | + if ($value_of_field_on_model_object === EE_INF) { |
|
16 | 16 | return EE_INF_IN_DB; |
17 | - }else{ |
|
17 | + } else { |
|
18 | 18 | return intval($value_of_field_on_model_object); |
19 | 19 | } |
20 | 20 | } |
21 | 21 | function prepare_for_set($value_inputted_for_field_on_model_object) { |
22 | - if($value_inputted_for_field_on_model_object === EE_INF_IN_DB || |
|
22 | + if ($value_inputted_for_field_on_model_object === EE_INF_IN_DB || |
|
23 | 23 | $value_inputted_for_field_on_model_object === EE_INF || |
24 | 24 | $value_inputted_for_field_on_model_object === "EE_INF" || |
25 | 25 | $value_inputted_for_field_on_model_object === "" |
26 | - ){ |
|
26 | + ) { |
|
27 | 27 | return EE_INF; |
28 | - }else{ |
|
28 | + } else { |
|
29 | 29 | return intval($value_inputted_for_field_on_model_object); |
30 | 30 | } |
31 | 31 | } |
32 | 32 | function prepare_for_set_from_db($value_inputted_for_field_on_model_object) { |
33 | 33 | $intval = intval($value_inputted_for_field_on_model_object); |
34 | - if($intval == EE_INF_IN_DB){ |
|
34 | + if ($intval == EE_INF_IN_DB) { |
|
35 | 35 | return EE_INF; |
36 | - }else{ |
|
36 | + } else { |
|
37 | 37 | return $intval; |
38 | 38 | } |
39 | 39 | } |
@@ -46,9 +46,9 @@ discard block |
||
46 | 46 | * @param string $schema input, symbol, text; or any string you want to show if the value equals EE_INF |
47 | 47 | * @return string |
48 | 48 | */ |
49 | - function prepare_for_pretty_echoing( $value_on_field_to_be_outputted, $schema = null ) { |
|
50 | - if( $value_on_field_to_be_outputted === EE_INF ){ |
|
51 | - switch($schema){ |
|
49 | + function prepare_for_pretty_echoing($value_on_field_to_be_outputted, $schema = null) { |
|
50 | + if ($value_on_field_to_be_outputted === EE_INF) { |
|
51 | + switch ($schema) { |
|
52 | 52 | case 'input': |
53 | 53 | case 'form_input': |
54 | 54 | return ''; |
@@ -14,7 +14,7 @@ discard block |
||
14 | 14 | function prepare_for_use_in_db($value_of_field_on_model_object) { |
15 | 15 | if($value_of_field_on_model_object === EE_INF){ |
16 | 16 | return EE_INF_IN_DB; |
17 | - }else{ |
|
17 | + } else{ |
|
18 | 18 | return intval($value_of_field_on_model_object); |
19 | 19 | } |
20 | 20 | } |
@@ -25,7 +25,7 @@ discard block |
||
25 | 25 | $value_inputted_for_field_on_model_object === "" |
26 | 26 | ){ |
27 | 27 | return EE_INF; |
28 | - }else{ |
|
28 | + } else{ |
|
29 | 29 | return intval($value_inputted_for_field_on_model_object); |
30 | 30 | } |
31 | 31 | } |
@@ -33,7 +33,7 @@ discard block |
||
33 | 33 | $intval = intval($value_inputted_for_field_on_model_object); |
34 | 34 | if($intval == EE_INF_IN_DB){ |
35 | 35 | return EE_INF; |
36 | - }else{ |
|
36 | + } else{ |
|
37 | 37 | return $intval; |
38 | 38 | } |
39 | 39 | } |
@@ -1,4 +1,6 @@ |
||
1 | -<?php if ( ! defined('EVENT_ESPRESSO_VERSION')) exit('No direct script access allowed'); |
|
1 | +<?php if ( ! defined('EVENT_ESPRESSO_VERSION')) { |
|
2 | + exit('No direct script access allowed'); |
|
3 | +} |
|
2 | 4 | require_once ( EE_MODELS . 'EEM_Base.model.php' ); |
3 | 5 | /** |
4 | 6 | * |
@@ -1,5 +1,5 @@ discard block |
||
1 | 1 | <?php if ( ! defined('EVENT_ESPRESSO_VERSION')) exit('No direct script access allowed'); |
2 | -require_once ( EE_MODELS . 'EEM_Base.model.php' ); |
|
2 | +require_once (EE_MODELS.'EEM_Base.model.php'); |
|
3 | 3 | /** |
4 | 4 | * |
5 | 5 | * Transaction Model |
@@ -68,35 +68,35 @@ discard block |
||
68 | 68 | * Note this just sends the timezone info to the date time model field objects. Default is NULL (and will be assumed using the set timezone in the 'timezone_string' wp option) |
69 | 69 | * @return EEM_Transaction |
70 | 70 | */ |
71 | - protected function __construct( $timezone ) { |
|
72 | - $this->singular_item = __('Transaction','event_espresso'); |
|
73 | - $this->plural_item = __('Transactions','event_espresso'); |
|
71 | + protected function __construct($timezone) { |
|
72 | + $this->singular_item = __('Transaction', 'event_espresso'); |
|
73 | + $this->plural_item = __('Transactions', 'event_espresso'); |
|
74 | 74 | |
75 | 75 | $this->_tables = array( |
76 | - 'Transaction'=>new EE_Primary_Table('esp_transaction','TXN_ID') |
|
76 | + 'Transaction'=>new EE_Primary_Table('esp_transaction', 'TXN_ID') |
|
77 | 77 | ); |
78 | 78 | $this->_fields = array( |
79 | 79 | 'Transaction'=>array( |
80 | - 'TXN_ID'=>new EE_Primary_Key_Int_Field('TXN_ID', __('Transaction ID','event_espresso')), |
|
81 | - 'TXN_timestamp'=>new EE_Datetime_Field('TXN_timestamp', __('date when transaction was created','event_espresso'), false, time(), $timezone ), |
|
82 | - 'TXN_total'=>new EE_Money_Field('TXN_total', __('Total value of Transaction','event_espresso'), false, 0), |
|
83 | - 'TXN_paid'=>new EE_Money_Field('TXN_paid', __('Amount paid towards transaction to date','event_espresso'), false, 0), |
|
84 | - 'STS_ID'=>new EE_Foreign_Key_String_Field('STS_ID', __('Status ID','event_espresso'), false, EEM_Transaction::failed_status_code, 'Status'), |
|
85 | - 'TXN_session_data'=>new EE_Serialized_Text_Field('TXN_session_data', __('Serialized session data','event_espresso'), true, ''), |
|
86 | - 'TXN_hash_salt'=>new EE_Plain_Text_Field('TXN_hash_salt', __('Transaction Hash Salt','event_espresso'), true, ''), |
|
80 | + 'TXN_ID'=>new EE_Primary_Key_Int_Field('TXN_ID', __('Transaction ID', 'event_espresso')), |
|
81 | + 'TXN_timestamp'=>new EE_Datetime_Field('TXN_timestamp', __('date when transaction was created', 'event_espresso'), false, time(), $timezone), |
|
82 | + 'TXN_total'=>new EE_Money_Field('TXN_total', __('Total value of Transaction', 'event_espresso'), false, 0), |
|
83 | + 'TXN_paid'=>new EE_Money_Field('TXN_paid', __('Amount paid towards transaction to date', 'event_espresso'), false, 0), |
|
84 | + 'STS_ID'=>new EE_Foreign_Key_String_Field('STS_ID', __('Status ID', 'event_espresso'), false, EEM_Transaction::failed_status_code, 'Status'), |
|
85 | + 'TXN_session_data'=>new EE_Serialized_Text_Field('TXN_session_data', __('Serialized session data', 'event_espresso'), true, ''), |
|
86 | + 'TXN_hash_salt'=>new EE_Plain_Text_Field('TXN_hash_salt', __('Transaction Hash Salt', 'event_espresso'), true, ''), |
|
87 | 87 | 'PMD_ID'=>new EE_Foreign_Key_Int_Field('PMD_ID', __("Last Used Payment Method", 'event_espresso'), true, NULL, 'Payment_Method'), |
88 | - 'TXN_reg_steps' => new EE_Serialized_Text_Field( 'TXN_reg_steps', __( 'Registration Steps', 'event_espresso' ), FALSE, array() ), |
|
88 | + 'TXN_reg_steps' => new EE_Serialized_Text_Field('TXN_reg_steps', __('Registration Steps', 'event_espresso'), FALSE, array()), |
|
89 | 89 | ) |
90 | 90 | ); |
91 | 91 | $this->_model_relations = array( |
92 | 92 | 'Registration'=>new EE_Has_Many_Relation(), |
93 | 93 | 'Payment'=>new EE_Has_Many_Relation(), |
94 | 94 | 'Status'=>new EE_Belongs_To_Relation(), |
95 | - 'Line_Item'=>new EE_Has_Many_Relation(false),//you can delete a transaction without needing to delete its line items |
|
95 | + 'Line_Item'=>new EE_Has_Many_Relation(false), //you can delete a transaction without needing to delete its line items |
|
96 | 96 | 'Payment_Method'=>new EE_Belongs_To_Relation(), |
97 | 97 | ); |
98 | 98 | $this->_model_chain_to_wp_user = 'Registration.Event'; |
99 | - parent::__construct( $timezone ); |
|
99 | + parent::__construct($timezone); |
|
100 | 100 | |
101 | 101 | } |
102 | 102 | |
@@ -107,19 +107,19 @@ discard block |
||
107 | 107 | * @param string $period |
108 | 108 | * @return \stdClass[] |
109 | 109 | */ |
110 | - public function get_revenue_per_day_report( $period = '-1 month' ) { |
|
110 | + public function get_revenue_per_day_report($period = '-1 month') { |
|
111 | 111 | |
112 | - $sql_date = $this->convert_datetime_for_query( 'TXN_timestamp', date("Y-m-d H:i:s", strtotime($period) ), 'Y-m-d H:i:s', 'UTC' ); |
|
112 | + $sql_date = $this->convert_datetime_for_query('TXN_timestamp', date("Y-m-d H:i:s", strtotime($period)), 'Y-m-d H:i:s', 'UTC'); |
|
113 | 113 | $results = $this->_get_all_wpdb_results( |
114 | 114 | array( |
115 | 115 | array( |
116 | 116 | 'TXN_timestamp' => array('>=', $sql_date)), |
117 | 117 | 'group_by' => 'txnDate', |
118 | - 'order_by' => array('TXN_timestamp' => 'DESC' ) |
|
118 | + 'order_by' => array('TXN_timestamp' => 'DESC') |
|
119 | 119 | ), |
120 | 120 | OBJECT, |
121 | 121 | array( |
122 | - 'txnDate' => array('DATE(Transaction.TXN_timestamp)','%s'), |
|
122 | + 'txnDate' => array('DATE(Transaction.TXN_timestamp)', '%s'), |
|
123 | 123 | 'revenue' => array('SUM(Transaction.TXN_paid)', '%d') |
124 | 124 | )); |
125 | 125 | return $results; |
@@ -135,22 +135,22 @@ discard block |
||
135 | 135 | * @throws \EE_Error |
136 | 136 | * @return mixed |
137 | 137 | */ |
138 | - public function get_revenue_per_event_report( $period = 'month' ) { |
|
138 | + public function get_revenue_per_event_report($period = 'month') { |
|
139 | 139 | /** @type WPDB $wpdb */ |
140 | 140 | global $wpdb; |
141 | - $date_mod = strtotime( '-1 ' . $period ); |
|
141 | + $date_mod = strtotime('-1 '.$period); |
|
142 | 142 | |
143 | 143 | $SQL = 'SELECT post_title as event_name, SUM(TXN_paid) AS revenue'; |
144 | - $SQL .= ' FROM ' . $this->_get_main_table()->get_table_name() . ' txn'; |
|
145 | - $SQL .= ' LEFT JOIN ' . $wpdb->prefix . 'esp_registration reg ON reg.TXN_ID = txn.TXN_ID'; |
|
146 | - $SQL .= ' LEFT JOIN ' . $wpdb->posts . ' evt ON evt.ID = reg.EVT_ID'; |
|
144 | + $SQL .= ' FROM '.$this->_get_main_table()->get_table_name().' txn'; |
|
145 | + $SQL .= ' LEFT JOIN '.$wpdb->prefix.'esp_registration reg ON reg.TXN_ID = txn.TXN_ID'; |
|
146 | + $SQL .= ' LEFT JOIN '.$wpdb->posts.' evt ON evt.ID = reg.EVT_ID'; |
|
147 | 147 | $SQL .= ' WHERE REG_count = 1'; |
148 | 148 | $SQL .= ' AND REG_date >= %d'; |
149 | 149 | $SQL .= ' GROUP BY event_name'; |
150 | 150 | $SQL .= ' ORDER BY event_name'; |
151 | 151 | $SQL .= ' LIMIT 0, 24'; |
152 | 152 | |
153 | - return $this->_do_wpdb_query( 'get_results', array( $wpdb->prepare( $SQL, $date_mod ) ) ); |
|
153 | + return $this->_do_wpdb_query('get_results', array($wpdb->prepare($SQL, $date_mod))); |
|
154 | 154 | |
155 | 155 | } |
156 | 156 | |
@@ -166,10 +166,10 @@ discard block |
||
166 | 166 | * @param string $reg_url_link |
167 | 167 | * @return EE_Transaction |
168 | 168 | */ |
169 | - public function get_transaction_from_reg_url_link( $reg_url_link = '' ){ |
|
170 | - return $this->get_one( array( |
|
169 | + public function get_transaction_from_reg_url_link($reg_url_link = '') { |
|
170 | + return $this->get_one(array( |
|
171 | 171 | array( |
172 | - 'Registration.REG_url_link' => ! empty( $reg_url_link ) ? $reg_url_link : EE_Registry::instance()->REQ->get( 'e_reg_url_link', '' ) |
|
172 | + 'Registration.REG_url_link' => ! empty($reg_url_link) ? $reg_url_link : EE_Registry::instance()->REQ->get('e_reg_url_link', '') |
|
173 | 173 | ) |
174 | 174 | )); |
175 | 175 | } |
@@ -189,15 +189,15 @@ discard block |
||
189 | 189 | * @param boolean $save_txn whether or not to save the transaction during this function call |
190 | 190 | * @return boolean |
191 | 191 | */ |
192 | - public function update_based_on_payments( $transaction_obj_or_id, $save_txn = TRUE ){ |
|
192 | + public function update_based_on_payments($transaction_obj_or_id, $save_txn = TRUE) { |
|
193 | 193 | EE_Error::doing_it_wrong( |
194 | - __CLASS__ . '::' . __FUNCTION__, |
|
195 | - sprintf( __( 'This method is deprecated. Please use "%s" instead', 'event_espresso' ), 'EE_Transaction_Processor::update_transaction_and_registrations_after_checkout_or_payment()' ), |
|
194 | + __CLASS__.'::'.__FUNCTION__, |
|
195 | + sprintf(__('This method is deprecated. Please use "%s" instead', 'event_espresso'), 'EE_Transaction_Processor::update_transaction_and_registrations_after_checkout_or_payment()'), |
|
196 | 196 | '4.6.0' |
197 | 197 | ); |
198 | 198 | /** @type EE_Transaction_Processor $transaction_processor */ |
199 | - $transaction_processor = EE_Registry::instance()->load_class( 'Transaction_Processor' ); |
|
200 | - return $transaction_processor->update_transaction_and_registrations_after_checkout_or_payment( $this->ensure_is_obj( $transaction_obj_or_id )); |
|
199 | + $transaction_processor = EE_Registry::instance()->load_class('Transaction_Processor'); |
|
200 | + return $transaction_processor->update_transaction_and_registrations_after_checkout_or_payment($this->ensure_is_obj($transaction_obj_or_id)); |
|
201 | 201 | } |
202 | 202 | |
203 | 203 | /** |
@@ -228,7 +228,7 @@ discard block |
||
228 | 228 | array( |
229 | 229 | 0 => array( |
230 | 230 | 'STS_ID' => EEM_Transaction::failed_status_code, |
231 | - 'TXN_timestamp' => array( '<', time() - $time_to_leave_alone ) |
|
231 | + 'TXN_timestamp' => array('<', time() - $time_to_leave_alone) |
|
232 | 232 | ) |
233 | 233 | ), |
234 | 234 | $time_to_leave_alone |
@@ -241,26 +241,26 @@ discard block |
||
241 | 241 | */ |
242 | 242 | $txn_ids = apply_filters( |
243 | 243 | 'FHEE__EEM_Transaction__delete_junk_transactions__transaction_ids_to_delete', |
244 | - EEM_Transaction::instance()->get_col( $ids_query, 'TXN_ID' ), |
|
244 | + EEM_Transaction::instance()->get_col($ids_query, 'TXN_ID'), |
|
245 | 245 | $time_to_leave_alone |
246 | 246 | ); |
247 | 247 | |
248 | 248 | //now that we have the ids to delete, let's get deletin' |
249 | 249 | //Why no wpdb->prepare? Because the data is trusted. We got the ids from the original query to get them FROM |
250 | 250 | //the db (which is sanitized) so no need to prepare them again. |
251 | - if ( $txn_ids ) { |
|
252 | - $query = ' |
|
251 | + if ($txn_ids) { |
|
252 | + $query = ' |
|
253 | 253 | DELETE |
254 | - FROM ' . $this->table() . ' |
|
254 | + FROM ' . $this->table().' |
|
255 | 255 | WHERE |
256 | - TXN_ID IN ( ' . implode( ",", $txn_ids ) . ')'; |
|
257 | - $deleted = $wpdb->query( $query ); |
|
256 | + TXN_ID IN ( ' . implode(",", $txn_ids).')'; |
|
257 | + $deleted = $wpdb->query($query); |
|
258 | 258 | } |
259 | - if ( $deleted ) { |
|
259 | + if ($deleted) { |
|
260 | 260 | /** |
261 | 261 | * Allows code to do something after the transactions have been deleted. |
262 | 262 | */ |
263 | - do_action( 'AHEE__EEM_Transaction__delete_junk_transactions__successful_deletion', $txn_ids ); |
|
263 | + do_action('AHEE__EEM_Transaction__delete_junk_transactions__successful_deletion', $txn_ids); |
|
264 | 264 | } |
265 | 265 | return $deleted; |
266 | 266 | } |
@@ -170,7 +170,7 @@ |
||
170 | 170 | |
171 | 171 | |
172 | 172 | /** |
173 | - * @return boolean |
|
173 | + * @return boolean|null |
|
174 | 174 | */ |
175 | 175 | public function update_reg_step() { |
176 | 176 | EE_Error::doing_it_wrong( __CLASS__ . '::' . __FILE__, __( 'Can not call update_reg_step() on the Finalize Registration reg step.', 'event_espresso'), '4.6.0' ); |
@@ -20,7 +20,7 @@ discard block |
||
20 | 20 | * @param EE_Checkout $checkout |
21 | 21 | * @return \EE_SPCO_Reg_Step_Finalize_Registration |
22 | 22 | */ |
23 | - public function __construct( EE_Checkout $checkout ) { |
|
23 | + public function __construct(EE_Checkout $checkout) { |
|
24 | 24 | $this->_slug = 'finalize_registration'; |
25 | 25 | $this->_name = __('Finalize Registration', 'event_espresso'); |
26 | 26 | $this->_submit_button_text = $this->_name; |
@@ -46,9 +46,9 @@ discard block |
||
46 | 46 | */ |
47 | 47 | public function initialize_reg_step() { |
48 | 48 | // there's actually no reg form to process if this is the final step |
49 | - if ( $this->is_current_step() ) { |
|
49 | + if ($this->is_current_step()) { |
|
50 | 50 | $this->checkout->step = $_REQUEST['step'] = $this->slug(); |
51 | - $this->checkout->action = $_REQUEST[ 'action' ] = 'process_reg_step'; |
|
51 | + $this->checkout->action = $_REQUEST['action'] = 'process_reg_step'; |
|
52 | 52 | $this->checkout->generate_reg_form = false; |
53 | 53 | } |
54 | 54 | return true; |
@@ -71,7 +71,7 @@ discard block |
||
71 | 71 | */ |
72 | 72 | public function process_reg_step() { |
73 | 73 | // ensure all data gets refreshed from the db |
74 | - $this->checkout->refresh_all_entities( true ); |
|
74 | + $this->checkout->refresh_all_entities(true); |
|
75 | 75 | // ensures that all details and statuses for transaction, registration, and payments are updated |
76 | 76 | $txn_update_params = $this->_finalize_transaction(); |
77 | 77 | // DEBUG LOG |
@@ -85,16 +85,16 @@ discard block |
||
85 | 85 | // ) |
86 | 86 | //); |
87 | 87 | // set a hook point |
88 | - do_action( 'AHEE__EE_SPCO_Reg_Step_Finalize_Registration__process_reg_step__completed', $this->checkout, $txn_update_params ); |
|
88 | + do_action('AHEE__EE_SPCO_Reg_Step_Finalize_Registration__process_reg_step__completed', $this->checkout, $txn_update_params); |
|
89 | 89 | // check if transaction has a primary registrant and that it has a related Attendee object |
90 | - if ( $this->checkout->transaction_has_primary_registrant() ) { |
|
90 | + if ($this->checkout->transaction_has_primary_registrant()) { |
|
91 | 91 | // setup URL for redirect |
92 | 92 | $this->checkout->redirect_url = add_query_arg( |
93 | - array( 'e_reg_url_link' => $this->checkout->transaction->primary_registration()->reg_url_link() ), |
|
93 | + array('e_reg_url_link' => $this->checkout->transaction->primary_registration()->reg_url_link()), |
|
94 | 94 | $this->checkout->thank_you_page_url |
95 | 95 | ); |
96 | 96 | } else { |
97 | - EE_Error::add_error( __( 'A valid Primary Registration for this Transaction could not be found.', 'event_espresso' ), __FILE__, __FUNCTION__, __LINE__ ); |
|
97 | + EE_Error::add_error(__('A valid Primary Registration for this Transaction could not be found.', 'event_espresso'), __FILE__, __FUNCTION__, __LINE__); |
|
98 | 98 | $this->checkout->redirect = false; |
99 | 99 | $this->checkout->continue_reg = false; |
100 | 100 | return false; |
@@ -102,8 +102,8 @@ discard block |
||
102 | 102 | // you don't have to go home but you can't stay here ! |
103 | 103 | $this->checkout->redirect = true; |
104 | 104 | $this->checkout->continue_reg = true; |
105 | - $this->checkout->json_response->set_redirect_url( $this->checkout->redirect_url ); |
|
106 | - if ( ! ( $this->checkout->payment_method instanceof EE_Payment_Method && $this->checkout->payment_method->is_off_site() ) ) { |
|
105 | + $this->checkout->json_response->set_redirect_url($this->checkout->redirect_url); |
|
106 | + if ( ! ($this->checkout->payment_method instanceof EE_Payment_Method && $this->checkout->payment_method->is_off_site())) { |
|
107 | 107 | // mark this reg step as completed |
108 | 108 | $this->set_completed(); |
109 | 109 | } |
@@ -120,43 +120,43 @@ discard block |
||
120 | 120 | */ |
121 | 121 | protected function _finalize_transaction() { |
122 | 122 | /** @type EE_Transaction_Processor $transaction_processor */ |
123 | - $transaction_processor = EE_Registry::instance()->load_class( 'Transaction_Processor' ); |
|
123 | + $transaction_processor = EE_Registry::instance()->load_class('Transaction_Processor'); |
|
124 | 124 | //set revisit flag in txn processor |
125 | - $transaction_processor->set_revisit( $this->checkout->revisit ); |
|
125 | + $transaction_processor->set_revisit($this->checkout->revisit); |
|
126 | 126 | // at this point we'll consider a TXN to not have been abandoned |
127 | - $transaction_processor->toggle_abandoned_transaction_status( $this->checkout->transaction ); |
|
128 | - if ( $this->checkout->cart instanceof EE_Cart ) { |
|
127 | + $transaction_processor->toggle_abandoned_transaction_status($this->checkout->transaction); |
|
128 | + if ($this->checkout->cart instanceof EE_Cart) { |
|
129 | 129 | // save TXN data to the cart |
130 | - $this->checkout->cart->get_grand_total()->save_this_and_descendants_to_txn( $this->checkout->transaction->ID() ); |
|
130 | + $this->checkout->cart->get_grand_total()->save_this_and_descendants_to_txn($this->checkout->transaction->ID()); |
|
131 | 131 | } |
132 | 132 | /** @type EE_Transaction_Payments $transaction_payments */ |
133 | - $transaction_payments = EE_Registry::instance()->load_class( 'Transaction_Payments' ); |
|
133 | + $transaction_payments = EE_Registry::instance()->load_class('Transaction_Payments'); |
|
134 | 134 | // maybe update status, but don't save transaction just yet |
135 | - $transaction_payments->update_transaction_status_based_on_total_paid( $this->checkout->transaction, false ); |
|
135 | + $transaction_payments->update_transaction_status_based_on_total_paid($this->checkout->transaction, false); |
|
136 | 136 | // If the selected method of payment used an off-site gateway... |
137 | - if ( $this->checkout->payment_method instanceof EE_Payment_Method ) { |
|
138 | - $is_revisit = filter_var( $this->checkout->revisit, FILTER_VALIDATE_BOOLEAN ); |
|
139 | - if ( $this->checkout->payment_method instanceof EE_Payment_Method && $this->checkout->payment_method->is_off_site() ) { |
|
140 | - $gateway= $this->checkout->payment_method->type_obj()->get_gateway(); |
|
141 | - if ( $gateway instanceof EE_Offsite_Gateway && $gateway->uses_separate_IPN_request() ) { |
|
137 | + if ($this->checkout->payment_method instanceof EE_Payment_Method) { |
|
138 | + $is_revisit = filter_var($this->checkout->revisit, FILTER_VALIDATE_BOOLEAN); |
|
139 | + if ($this->checkout->payment_method instanceof EE_Payment_Method && $this->checkout->payment_method->is_off_site()) { |
|
140 | + $gateway = $this->checkout->payment_method->type_obj()->get_gateway(); |
|
141 | + if ($gateway instanceof EE_Offsite_Gateway && $gateway->uses_separate_IPN_request()) { |
|
142 | 142 | // do NOT trigger notifications because it was already done during the IPN |
143 | - remove_all_filters( 'FHEE__EED_Messages___maybe_registration__deliver_notifications' ); |
|
144 | - add_filter( 'FHEE__EED_Messages___maybe_registration__deliver_notifications', '__return_false', 15 ); |
|
145 | - } else if ( ! $is_revisit ) { |
|
146 | - add_filter( 'FHEE__EED_Messages___maybe_registration__deliver_notifications', '__return_true', 10 ); |
|
143 | + remove_all_filters('FHEE__EED_Messages___maybe_registration__deliver_notifications'); |
|
144 | + add_filter('FHEE__EED_Messages___maybe_registration__deliver_notifications', '__return_false', 15); |
|
145 | + } else if ( ! $is_revisit) { |
|
146 | + add_filter('FHEE__EED_Messages___maybe_registration__deliver_notifications', '__return_true', 10); |
|
147 | 147 | } |
148 | 148 | } else if ( |
149 | 149 | // if SPCO revisit and TXN status has changed due to a payment |
150 | - $is_revisit && ( $this->checkout->txn_status_updated || $this->checkout->any_reg_status_updated() ) |
|
150 | + $is_revisit && ($this->checkout->txn_status_updated || $this->checkout->any_reg_status_updated()) |
|
151 | 151 | ) { |
152 | 152 | // send out notifications |
153 | - add_filter( 'FHEE__EED_Messages___maybe_registration__deliver_notifications', '__return_true', 10 ); |
|
154 | - } else if ( ! $is_revisit ) { |
|
155 | - add_filter( 'FHEE__EED_Messages___maybe_registration__deliver_notifications', '__return_true', 10 ); |
|
153 | + add_filter('FHEE__EED_Messages___maybe_registration__deliver_notifications', '__return_true', 10); |
|
154 | + } else if ( ! $is_revisit) { |
|
155 | + add_filter('FHEE__EED_Messages___maybe_registration__deliver_notifications', '__return_true', 10); |
|
156 | 156 | } |
157 | 157 | } |
158 | 158 | // this will result in the base session properties getting saved to the TXN_Session_data field |
159 | - $this->checkout->transaction->set_txn_session_data( EE_Registry::instance()->SSN->get_session_data( null, true )); |
|
159 | + $this->checkout->transaction->set_txn_session_data(EE_Registry::instance()->SSN->get_session_data(null, true)); |
|
160 | 160 | |
161 | 161 | // update the TXN if payment conditions have changed |
162 | 162 | return $transaction_processor->update_transaction_and_registrations_after_checkout_or_payment( |
@@ -173,7 +173,7 @@ discard block |
||
173 | 173 | * @return boolean |
174 | 174 | */ |
175 | 175 | public function update_reg_step() { |
176 | - EE_Error::doing_it_wrong( __CLASS__ . '::' . __FILE__, __( 'Can not call update_reg_step() on the Finalize Registration reg step.', 'event_espresso'), '4.6.0' ); |
|
176 | + EE_Error::doing_it_wrong(__CLASS__.'::'.__FILE__, __('Can not call update_reg_step() on the Finalize Registration reg step.', 'event_espresso'), '4.6.0'); |
|
177 | 177 | } |
178 | 178 | |
179 | 179 |