Completed
Branch BUG-9680-compress-dompdf-files... (43e183)
by
unknown
71:45 queued 57:19
created
caffeinated/admin/new/pricing/Pricing_Admin_Page.core.php 3 patches
Indentation   +81 added lines, -81 removed lines patch added patch discarded remove patch
@@ -78,9 +78,9 @@  discard block
 block discarded – undo
78 78
 
79 79
 	/**
80 80
 	 * 		an array for storing request actions and their corresponding methods
81
-	*		@access private
82
-	*		@return void
83
-	*/
81
+	 *		@access private
82
+	 *		@return void
83
+	 */
84 84
 	protected function _set_page_routes() {
85 85
 		$prc_id = ! empty( $this->_req_data['PRC_ID'] ) && ! is_array( $this->_req_data['PRC_ID'] ) ? $this->_req_data['PRC_ID'] : 0;
86 86
 		$prt_id =  ! empty( $this->_req_data['PRT_ID'] ) && ! is_array( $this->_req_data['PRT_ID'] ) ? $this->_req_data['PRT_ID'] : 0;
@@ -200,7 +200,7 @@  discard block
 block discarded – undo
200 200
 							'order' => 10
201 201
 						),
202 202
 					'list_table' => 'Prices_List_Table',
203
-                    'help_tabs' => array(
203
+					'help_tabs' => array(
204 204
 						'pricing_default_pricing_help_tab' => array(
205 205
 							'title' => __('Default Pricing', 'event_espresso'),
206 206
 							'filename' => 'pricing_default_pricing'
@@ -223,13 +223,13 @@  discard block
 block discarded – undo
223 223
 							'order' => 20,
224 224
 							'persistent' => FALSE
225 225
 						),
226
-                    'help_tabs' => array(
226
+					'help_tabs' => array(
227 227
 						'add_new_default_price_help_tab' => array(
228 228
 							'title' => __('Add New Default Price', 'event_espresso'),
229 229
 							'filename' => 'pricing_add_new_default_price'
230 230
 							)
231 231
 						),
232
-                    'help_tour' => array('Pricing_Add_New_Default_Price_Help_Tour'),
232
+					'help_tour' => array('Pricing_Add_New_Default_Price_Help_Tour'),
233 233
 					'metaboxes' => array( '_publish_post_box', '_espresso_news_post_box', '_price_details_meta_boxes' ),
234 234
 					'require_nonce' => FALSE
235 235
 				),
@@ -241,7 +241,7 @@  discard block
 block discarded – undo
241 241
 							'persistent' => FALSE
242 242
 						),
243 243
 					'metaboxes' => array( '_publish_post_box', '_espresso_news_post_box', '_price_details_meta_boxes' ),
244
-                    'help_tabs' => array(
244
+					'help_tabs' => array(
245 245
 						'edit_default_price_help_tab' => array(
246 246
 							'title' => __('Edit Default Price', 'event_espresso'),
247 247
 							'filename' => 'pricing_edit_default_price'
@@ -256,7 +256,7 @@  discard block
 block discarded – undo
256 256
 							'order' => 30
257 257
 						),
258 258
 					'list_table' => 'Price_Types_List_Table',
259
-                    'help_tabs' => array(
259
+					'help_tabs' => array(
260 260
 						'pricing_price_types_help_tab' => array(
261 261
 							'title' => __('Price Types', 'event_espresso'),
262 262
 							'filename' => 'pricing_price_types'
@@ -280,13 +280,13 @@  discard block
 block discarded – undo
280 280
 							'order' => 40,
281 281
 							'persistent' => FALSE
282 282
 						),
283
-                    'help_tabs' => array(
283
+					'help_tabs' => array(
284 284
 						'add_new_price_type_help_tab' => array(
285 285
 							'title' => __('Add New Price Type', 'event_espresso'),
286 286
 							'filename' => 'pricing_add_new_price_type'
287 287
 							)
288 288
 						),
289
-                    'help_tour' => array( 'Pricing_Add_New_Price_Type_Help_Tour' ),
289
+					'help_tour' => array( 'Pricing_Add_New_Price_Type_Help_Tour' ),
290 290
 					'metaboxes' => array( '_publish_post_box', '_espresso_news_post_box', '_price_type_details_meta_boxes' ),
291 291
 					'require_nonce' => FALSE
292 292
 				),
@@ -296,13 +296,13 @@  discard block
 block discarded – undo
296 296
 							'order' => 40,
297 297
 							'persistent' => FALSE
298 298
 						),
299
-                    'help_tabs' => array(
299
+					'help_tabs' => array(
300 300
 						'edit_price_type_help_tab' => array(
301 301
 							'title' => __('Edit Price Type', 'event_espresso'),
302 302
 							'filename' => 'pricing_edit_price_type'
303 303
 							)
304 304
 						),
305
-                    'help_tour' => array( 'Pricing_Edit_Price_Type_Help_Tour' ),
305
+					'help_tour' => array( 'Pricing_Edit_Price_Type_Help_Tour' ),
306 306
 					'metaboxes' => array( '_publish_post_box', '_espresso_news_post_box', '_price_type_details_meta_boxes' ),
307 307
 
308 308
 					'require_nonce' => FALSE
@@ -433,9 +433,9 @@  discard block
 block discarded – undo
433 433
 
434 434
 	/**
435 435
 	 * 		generates HTML for main Prices Admin page
436
-	*		@access protected
437
-	*		@return void
438
-	*/
436
+	 *		@access protected
437
+	 *		@return void
438
+	 */
439 439
 	protected function _price_overview_list_table() {
440 440
 		$this->_admin_page_title .= $this->get_action_link_or_button('add_new_price', 'add', array(), 'add-new-h2');
441 441
 		$this->admin_page_title .= $this->_learn_more_about_pricing_link();
@@ -449,13 +449,13 @@  discard block
 block discarded – undo
449 449
 
450 450
 
451 451
 	/**
452
-	*	retrieve data for Prices List table
453
-	*	@access public
454
-	* 	@param  int  $per_page    how many prices displayed per page
455
-	* 	@param  boolean $count   return the count or objects
456
-	* 	@param  boolean $trashed   whether the current view is of the trash can - eww yuck!
457
-	* 	@return mixed (int|array)  int = count || array of price objects
458
-	*/
452
+	 *	retrieve data for Prices List table
453
+	 *	@access public
454
+	 * 	@param  int  $per_page    how many prices displayed per page
455
+	 * 	@param  boolean $count   return the count or objects
456
+	 * 	@param  boolean $trashed   whether the current view is of the trash can - eww yuck!
457
+	 * 	@return mixed (int|array)  int = count || array of price objects
458
+	 */
459 459
 	public function get_prices_overview_data( $per_page = 10, $count = FALSE, $trashed = FALSE ) {
460 460
 
461 461
 		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
@@ -525,9 +525,9 @@  discard block
 block discarded – undo
525 525
 
526 526
 	/**
527 527
 	 * 		_price_details
528
-	*		@access protected
529
-	*		@return void
530
-	*/
528
+	 *		@access protected
529
+	 *		@return void
530
+	 */
531 531
 	protected function _edit_price_details() {
532 532
 		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
533 533
 		// grab price ID
@@ -587,9 +587,9 @@  discard block
 block discarded – undo
587 587
 
588 588
 	/**
589 589
 	 * 		declare price details page metaboxes
590
-	*		@access protected
591
-	*		@return void
592
-	*/
590
+	 *		@access protected
591
+	 *		@return void
592
+	 */
593 593
 	protected function _price_details_meta_boxes() {
594 594
 		add_meta_box( 'edit-price-details-mbox', __( 'Default Price Details', 'event_espresso' ), array( $this, '_edit_price_details_meta_box' ), $this->wp_page_slug, 'normal', 'high' );
595 595
 	}
@@ -601,9 +601,9 @@  discard block
 block discarded – undo
601 601
 
602 602
 	/**
603 603
 	 * 		_edit_price_details_meta_box
604
-	*		@access public
605
-	*		@return void
606
-	*/
604
+	 *		@access public
605
+	 *		@return void
606
+	 */
607 607
 	public function _edit_price_details_meta_box() {
608 608
 		echo EEH_Template::display_template( PRICING_TEMPLATE_PATH . 'pricing_details_main_meta_box.template.php', $this->_template_args, TRUE );
609 609
 	}
@@ -614,9 +614,9 @@  discard block
 block discarded – undo
614 614
 
615 615
 	/**
616 616
 	 * 		set_price_column_values
617
-	*		@access protected
618
-	*		@return array
619
-	*/
617
+	 *		@access protected
618
+	 *		@return array
619
+	 */
620 620
 	protected function set_price_column_values() {
621 621
 
622 622
 		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
@@ -643,10 +643,10 @@  discard block
 block discarded – undo
643 643
 
644 644
 	/**
645 645
 	 * 		insert_or_update_price
646
-	*		@param boolean 		$insert - whether to insert or update
647
-	*		@access protected
648
-	*		@return void
649
-	*/
646
+	 *		@param boolean 		$insert - whether to insert or update
647
+	 *		@access protected
648
+	 *		@return void
649
+	 */
650 650
 	protected function _insert_or_update_price( $insert = FALSE ) {
651 651
 
652 652
 		//echo '<h3>'. __CLASS__ . '->' . __FUNCTION__ . ' <br /><span style="font-size:10px;font-weight:normal;">' . __FILE__ . '<br />line no: ' . __LINE__ . '</span></h3>';
@@ -719,10 +719,10 @@  discard block
 block discarded – undo
719 719
 
720 720
 	/**
721 721
 	 * 		_trash_or_restore_price
722
-	*		@param boolean 		$trash - whether to move item to trash (TRUE) or restore it (FALSE)
723
-	*		@access protected
724
-	*		@return void
725
-	*/
722
+	 *		@param boolean 		$trash - whether to move item to trash (TRUE) or restore it (FALSE)
723
+	 *		@access protected
724
+	 *		@return void
725
+	 */
726 726
 	protected function _trash_or_restore_price( $trash = TRUE ) {
727 727
 
728 728
 		//echo '<h3>'. __CLASS__ . '->' . __FUNCTION__ . ' <br /><span style="font-size:10px;font-weight:normal;">' . __FILE__ . '<br />line no: ' . __LINE__ . '</span></h3>';
@@ -802,9 +802,9 @@  discard block
 block discarded – undo
802 802
 
803 803
 	/**
804 804
 	 * 		_delete_price
805
-	*		@access protected
806
-	*		@return void
807
-	*/
805
+	 *		@access protected
806
+	 *		@return void
807
+	 */
808 808
 	protected function _delete_price() {
809 809
 
810 810
 		//echo '<h3>'. __CLASS__ . '->' . __FUNCTION__ . ' <br /><span style="font-size:10px;font-weight:normal;">' . __FILE__ . '<br />line no: ' . __LINE__ . '</span></h3>';
@@ -881,9 +881,9 @@  discard block
 block discarded – undo
881 881
 
882 882
 	/**
883 883
 	 * 		generates HTML for main Prices Admin page
884
-	*		@access protected
885
-	*		@return void
886
-	*/
884
+	 *		@access protected
885
+	 *		@return void
886
+	 */
887 887
 	protected function _price_types_overview_list_table() {
888 888
 		$this->_admin_page_title .= $this->get_action_link_or_button('add_new_price_type', 'add_type', array(), 'add-new-h2');
889 889
 		$this->admin_page_title .= $this->_learn_more_about_pricing_link();
@@ -897,13 +897,13 @@  discard block
 block discarded – undo
897 897
 
898 898
 
899 899
 	/**
900
-	*	retrieve data for Price Types List table
901
-	*	@access public
902
-	* 	@param  int  $per_page    how many prices displayed per page
903
-	* 	@param  boolean $count   return the count or objects
904
-	* 	@param  boolean $trashed   whether the current view is of the trash can - eww yuck!
905
-	* 	@return mixed (int|array)  int = count || array of price objects
906
-	*/
900
+	 *	retrieve data for Price Types List table
901
+	 *	@access public
902
+	 * 	@param  int  $per_page    how many prices displayed per page
903
+	 * 	@param  boolean $count   return the count or objects
904
+	 * 	@param  boolean $trashed   whether the current view is of the trash can - eww yuck!
905
+	 * 	@return mixed (int|array)  int = count || array of price objects
906
+	 */
907 907
 	public function get_price_types_overview_data( $per_page = 10, $count = FALSE, $trashed = FALSE ) {
908 908
 
909 909
 		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
@@ -958,9 +958,9 @@  discard block
 block discarded – undo
958 958
 
959 959
 	/**
960 960
 	 * 		_edit_price_type_details
961
-	*		@access protected
962
-	*		@return void
963
-	*/
961
+	 *		@access protected
962
+	 *		@return void
963
+	 */
964 964
 	protected function _edit_price_type_details() {
965 965
 
966 966
 		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
@@ -1015,9 +1015,9 @@  discard block
 block discarded – undo
1015 1015
 
1016 1016
 	/**
1017 1017
 	 * 		declare price type details page metaboxes
1018
-	*		@access protected
1019
-	*		@return void
1020
-	*/
1018
+	 *		@access protected
1019
+	 *		@return void
1020
+	 */
1021 1021
 	protected function _price_type_details_meta_boxes() {
1022 1022
 		add_meta_box( 'edit-price-details-mbox', __( 'Price Type Details', 'event_espresso' ), array( $this, '_edit_price_type_details_meta_box' ), $this->wp_page_slug, 'normal', 'high' );
1023 1023
 	}
@@ -1028,9 +1028,9 @@  discard block
 block discarded – undo
1028 1028
 
1029 1029
 	/**
1030 1030
 	 * 		_edit_price_type_details_meta_box
1031
-	*		@access public
1032
-	*		@return void
1033
-	*/
1031
+	 *		@access public
1032
+	 *		@return void
1033
+	 */
1034 1034
 	public function _edit_price_type_details_meta_box() {
1035 1035
 		echo EEH_Template::display_template( PRICING_TEMPLATE_PATH . 'pricing_type_details_main_meta_box.template.php', $this->_template_args, TRUE );
1036 1036
 	}
@@ -1040,9 +1040,9 @@  discard block
 block discarded – undo
1040 1040
 
1041 1041
 	/**
1042 1042
 	 * 		set_price_type_column_values
1043
-	*		@access protected
1044
-	*		@return void
1045
-	*/
1043
+	 *		@access protected
1044
+	 *		@return void
1045
+	 */
1046 1046
 	protected function set_price_type_column_values() {
1047 1047
 
1048 1048
 		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
@@ -1090,10 +1090,10 @@  discard block
 block discarded – undo
1090 1090
 
1091 1091
 	/**
1092 1092
 	 * 		_insert_or_update_price_type
1093
-	*		@param boolean 		$new_price_type - whether to insert or update
1094
-	*		@access protected
1095
-	*		@return void
1096
-	*/
1093
+	 *		@param boolean 		$new_price_type - whether to insert or update
1094
+	 *		@access protected
1095
+	 *		@return void
1096
+	 */
1097 1097
 	protected function _insert_or_update_price_type( $new_price_type = FALSE ) {
1098 1098
 
1099 1099
 //		echo '<h3>'. __CLASS__ . '->' . __FUNCTION__ . ' <br /><span style="font-size:10px;font-weight:normal;">' . __FILE__ . '<br />line no: ' . __LINE__ . '</span></h3>';
@@ -1134,10 +1134,10 @@  discard block
 block discarded – undo
1134 1134
 
1135 1135
 	/**
1136 1136
 	 * 		_trash_or_restore_price_type
1137
-	*		@param boolean 		$trash - whether to move item to trash (TRUE) or restore it (FALSE)
1138
-	*		@access protected
1139
-	*		@return void
1140
-	*/
1137
+	 *		@param boolean 		$trash - whether to move item to trash (TRUE) or restore it (FALSE)
1138
+	 *		@access protected
1139
+	 *		@return void
1140
+	 */
1141 1141
 	protected function _trash_or_restore_price_type( $trash = TRUE ) {
1142 1142
 
1143 1143
 		//echo '<h3>'. __CLASS__ . '->' . __FUNCTION__ . ' <br /><span style="font-size:10px;font-weight:normal;">' . __FILE__ . '<br />line no: ' . __LINE__ . '</span></h3>';
@@ -1191,9 +1191,9 @@  discard block
 block discarded – undo
1191 1191
 
1192 1192
 	/**
1193 1193
 	 * 		_delete_price_type
1194
-	*		@access protected
1195
-	*		@return void
1196
-	*/
1194
+	 *		@access protected
1195
+	 *		@return void
1196
+	 */
1197 1197
 	protected function _delete_price_type() {
1198 1198
 
1199 1199
 		//echo '<h3>'. __CLASS__ . '->' . __FUNCTION__ . ' <br /><span style="font-size:10px;font-weight:normal;">' . __FILE__ . '<br />line no: ' . __LINE__ . '</span></h3>';
@@ -1230,9 +1230,9 @@  discard block
 block discarded – undo
1230 1230
 
1231 1231
 	/**
1232 1232
 	 * 		_learn_more_about_pricing_link
1233
-	*		@access protected
1234
-	*		@return string
1235
-	*/
1233
+	 *		@access protected
1234
+	 *		@return string
1235
+	 */
1236 1236
 	protected function _learn_more_about_pricing_link() {
1237 1237
 		return '<a class="hidden" style="margin:0 20px; cursor:pointer; font-size:12px;" >' . __('learn more about how pricing works', 'event_espresso') . '</a>';
1238 1238
 	}
Please login to merge, or discard this patch.
Spacing   +190 added lines, -190 removed lines patch added patch discarded remove patch
@@ -31,8 +31,8 @@  discard block
 block discarded – undo
31 31
 	 * @param bool $routing
32 32
 	 * @return Pricing_Admin_Page
33 33
 	 */
34
-	public function __construct( $routing = TRUE ) {
35
-		parent::__construct( $routing );
34
+	public function __construct($routing = TRUE) {
35
+		parent::__construct($routing);
36 36
 	}
37 37
 
38 38
 
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
 
50 50
 
51 51
 	protected function _ajax_hooks() {
52
-		add_action('wp_ajax_espresso_update_prices_order', array( $this, 'update_price_order' ));
52
+		add_action('wp_ajax_espresso_update_prices_order', array($this, 'update_price_order'));
53 53
 	}
54 54
 
55 55
 
@@ -82,8 +82,8 @@  discard block
 block discarded – undo
82 82
 	*		@return void
83 83
 	*/
84 84
 	protected function _set_page_routes() {
85
-		$prc_id = ! empty( $this->_req_data['PRC_ID'] ) && ! is_array( $this->_req_data['PRC_ID'] ) ? $this->_req_data['PRC_ID'] : 0;
86
-		$prt_id =  ! empty( $this->_req_data['PRT_ID'] ) && ! is_array( $this->_req_data['PRT_ID'] ) ? $this->_req_data['PRT_ID'] : 0;
85
+		$prc_id = ! empty($this->_req_data['PRC_ID']) && ! is_array($this->_req_data['PRC_ID']) ? $this->_req_data['PRC_ID'] : 0;
86
+		$prt_id = ! empty($this->_req_data['PRT_ID']) && ! is_array($this->_req_data['PRT_ID']) ? $this->_req_data['PRT_ID'] : 0;
87 87
 		$this->_page_routes = array(
88 88
 			'default' => array(
89 89
 					'func' => '_price_overview_list_table',
@@ -91,38 +91,38 @@  discard block
 block discarded – undo
91 91
 				),
92 92
 			'add_new_price'	=> array(
93 93
 					'func' => '_edit_price_details',
94
-					'args' => array( 'new_price' => TRUE ),
94
+					'args' => array('new_price' => TRUE),
95 95
 					'capability' => 'ee_edit_default_prices'
96 96
 				),
97 97
 			'edit_price'	=> array(
98 98
 					'func' => '_edit_price_details',
99
-					'args' => array( 'new_price' => FALSE ),
99
+					'args' => array('new_price' => FALSE),
100 100
 					'capability' => 'ee_edit_default_price',
101 101
 					'obj_id' => $prc_id
102 102
 				),
103 103
 			'insert_price'	=> array(
104 104
 					'func' => '_insert_or_update_price',
105
-					'args' => array( 'new_price' => TRUE ),
105
+					'args' => array('new_price' => TRUE),
106 106
 					'noheader' => TRUE,
107 107
 					'capability' => 'ee_edit_default_prices',
108 108
 				),
109 109
 			'update_price'	=> array(
110 110
 					'func' => '_insert_or_update_price',
111
-					'args' => array( 'new_price' => FALSE ),
111
+					'args' => array('new_price' => FALSE),
112 112
 					'noheader' => TRUE,
113 113
 					'capability' => 'ee_edit_default_price',
114 114
 					'obj_id' => $prc_id
115 115
 				),
116 116
 			'trash_price'	=> array(
117 117
 					'func' => '_trash_or_restore_price',
118
-					'args' => array( 'trash' => TRUE ),
118
+					'args' => array('trash' => TRUE),
119 119
 					'noheader' => TRUE,
120 120
 					'capability' => 'ee_delete_default_price',
121 121
 					'obj_id' => $prc_id
122 122
 				),
123 123
 			'restore_price'	=> array(
124 124
 					'func' => '_trash_or_restore_price',
125
-					'args' => array( 'trash' => FALSE ),
125
+					'args' => array('trash' => FALSE),
126 126
 					'noheader' => TRUE,
127 127
 					'capability' => 'ee_delete_default_price',
128 128
 					'obj_id' => $prc_id
@@ -154,27 +154,27 @@  discard block
 block discarded – undo
154 154
 				),
155 155
 			'insert_price_type'	=> array(
156 156
 					'func' => '_insert_or_update_price_type',
157
-					'args' => array( 'new_price_type' => TRUE ),
157
+					'args' => array('new_price_type' => TRUE),
158 158
 					'noheader' => TRUE,
159 159
 					'capability' => 'ee_edit_default_price_types'
160 160
 				),
161 161
 			'update_price_type' => array(
162 162
 					'func' => '_insert_or_update_price_type',
163
-					'args' => array( 'new_price_type' => FALSE ),
163
+					'args' => array('new_price_type' => FALSE),
164 164
 					'noheader' => TRUE,
165 165
 					'capability' => 'ee_edit_default_price_type',
166 166
 					'obj_id' => $prt_id
167 167
 				),
168 168
 			'trash_price_type'	=> array(
169 169
 					'func' => '_trash_or_restore_price_type',
170
-					'args' => array( 'trash' => TRUE ),
170
+					'args' => array('trash' => TRUE),
171 171
 					'noheader' => TRUE,
172 172
 					'capability' => 'ee_delete_default_price_type',
173 173
 					'obj_id' => $prt_id
174 174
 				),
175 175
 			'restore_price_type'	=> array(
176 176
 					'func' => '_trash_or_restore_price_type',
177
-					'args' => array( 'trash' => FALSE ),
177
+					'args' => array('trash' => FALSE),
178 178
 					'noheader' => TRUE,
179 179
 					'capability' => 'ee_delete_default_price_type',
180 180
 					'obj_id' => $prt_id
@@ -214,7 +214,7 @@  discard block
 block discarded – undo
214 214
 							'filename' => 'pricing_default_pricing_views_bulk_actions_search'
215 215
 							)
216 216
 						),
217
-					'help_tour' => array( 'Pricing_Default_Prices_Help_Tour'),
217
+					'help_tour' => array('Pricing_Default_Prices_Help_Tour'),
218 218
 					'require_nonce' => FALSE
219 219
 				),
220 220
 			'add_new_price' => array(
@@ -230,24 +230,24 @@  discard block
 block discarded – undo
230 230
 							)
231 231
 						),
232 232
                     'help_tour' => array('Pricing_Add_New_Default_Price_Help_Tour'),
233
-					'metaboxes' => array( '_publish_post_box', '_espresso_news_post_box', '_price_details_meta_boxes' ),
233
+					'metaboxes' => array('_publish_post_box', '_espresso_news_post_box', '_price_details_meta_boxes'),
234 234
 					'require_nonce' => FALSE
235 235
 				),
236 236
 			'edit_price' => array(
237 237
 					'nav' => array(
238 238
 							'label' => __('Edit Default Price', 'event_espresso'),
239 239
 							'order' => 20,
240
-							'url' => isset($this->_req_data['id']) ? add_query_arg(array('id' => $this->_req_data['id'] ), $this->_current_page_view_url )  : $this->_admin_base_url,
240
+							'url' => isset($this->_req_data['id']) ? add_query_arg(array('id' => $this->_req_data['id']), $this->_current_page_view_url) : $this->_admin_base_url,
241 241
 							'persistent' => FALSE
242 242
 						),
243
-					'metaboxes' => array( '_publish_post_box', '_espresso_news_post_box', '_price_details_meta_boxes' ),
243
+					'metaboxes' => array('_publish_post_box', '_espresso_news_post_box', '_price_details_meta_boxes'),
244 244
                     'help_tabs' => array(
245 245
 						'edit_default_price_help_tab' => array(
246 246
 							'title' => __('Edit Default Price', 'event_espresso'),
247 247
 							'filename' => 'pricing_edit_default_price'
248 248
 							)
249 249
 						),
250
-					'help_tour' => array( 'Pricing_Edit_Default_Price_Help_Tour' ),
250
+					'help_tour' => array('Pricing_Edit_Default_Price_Help_Tour'),
251 251
 					'require_nonce' => FALSE
252 252
 				),
253 253
 			'price_types' => array(
@@ -270,7 +270,7 @@  discard block
 block discarded – undo
270 270
 							'filename' => 'pricing_price_types_views_bulk_actions_search'
271 271
 							),
272 272
 						),
273
-					'help_tour' => array( 'Pricing_Price_Types_Default_Help_Tour' ),
273
+					'help_tour' => array('Pricing_Price_Types_Default_Help_Tour'),
274 274
 					'metaboxes' => array('_espresso_news_post_box', '_espresso_links_post_box'),
275 275
 					'require_nonce' => FALSE
276 276
 				),
@@ -286,8 +286,8 @@  discard block
 block discarded – undo
286 286
 							'filename' => 'pricing_add_new_price_type'
287 287
 							)
288 288
 						),
289
-                    'help_tour' => array( 'Pricing_Add_New_Price_Type_Help_Tour' ),
290
-					'metaboxes' => array( '_publish_post_box', '_espresso_news_post_box', '_price_type_details_meta_boxes' ),
289
+                    'help_tour' => array('Pricing_Add_New_Price_Type_Help_Tour'),
290
+					'metaboxes' => array('_publish_post_box', '_espresso_news_post_box', '_price_type_details_meta_boxes'),
291 291
 					'require_nonce' => FALSE
292 292
 				),
293 293
 			'edit_price_type' => array(
@@ -302,8 +302,8 @@  discard block
 block discarded – undo
302 302
 							'filename' => 'pricing_edit_price_type'
303 303
 							)
304 304
 						),
305
-                    'help_tour' => array( 'Pricing_Edit_Price_Type_Help_Tour' ),
306
-					'metaboxes' => array( '_publish_post_box', '_espresso_news_post_box', '_price_type_details_meta_boxes' ),
305
+                    'help_tour' => array('Pricing_Edit_Price_Type_Help_Tour'),
306
+					'metaboxes' => array('_publish_post_box', '_espresso_news_post_box', '_price_type_details_meta_boxes'),
307 307
 
308 308
 					'require_nonce' => FALSE
309 309
 				)
@@ -340,7 +340,7 @@  discard block
 block discarded – undo
340 340
 	public function load_scripts_styles() {
341 341
 		//styles
342 342
 		wp_enqueue_style('espresso-ui-theme');
343
-		wp_register_style( 'espresso_PRICING', PRICING_ASSETS_URL . 'espresso_pricing_admin.css', array(), EVENT_ESPRESSO_VERSION );
343
+		wp_register_style('espresso_PRICING', PRICING_ASSETS_URL.'espresso_pricing_admin.css', array(), EVENT_ESPRESSO_VERSION);
344 344
 		wp_enqueue_style('espresso_PRICING');
345 345
 
346 346
 		//scripts
@@ -350,8 +350,8 @@  discard block
 block discarded – undo
350 350
 		//wp_enqueue_script('jquery-ui-dialog');
351 351
 		//wp_enqueue_script('jquery-ui-draggable');
352 352
 		//wp_enqueue_script('jquery-ui-datepicker');
353
-		wp_register_script( 'espresso_PRICING', PRICING_ASSETS_URL . 'espresso_pricing_admin.js', array('jquery'), EVENT_ESPRESSO_VERSION, TRUE );
354
-		wp_enqueue_script( 'espresso_PRICING' );
353
+		wp_register_script('espresso_PRICING', PRICING_ASSETS_URL.'espresso_pricing_admin.js', array('jquery'), EVENT_ESPRESSO_VERSION, TRUE);
354
+		wp_enqueue_script('espresso_PRICING');
355 355
 	}
356 356
 
357 357
 
@@ -359,7 +359,7 @@  discard block
 block discarded – undo
359 359
 
360 360
 
361 361
 	public function load_scripts_styles_default() {
362
-		wp_enqueue_script( 'espresso_ajax_table_sorting' );
362
+		wp_enqueue_script('espresso_ajax_table_sorting');
363 363
 	}
364 364
 
365 365
 
@@ -387,7 +387,7 @@  discard block
 block discarded – undo
387 387
 				)
388 388
 		);
389 389
 
390
-		if ( EE_Registry::instance()->CAP->current_user_can( 'ee_delete_default_prices', 'pricing_trash_price' ) ) {
390
+		if (EE_Registry::instance()->CAP->current_user_can('ee_delete_default_prices', 'pricing_trash_price')) {
391 391
 			$this->_views['trashed'] = array(
392 392
 					'slug' => 'trashed',
393 393
 					'label' => __('Trash', 'event_espresso'),
@@ -417,7 +417,7 @@  discard block
 block discarded – undo
417 417
 				)
418 418
 		);
419 419
 
420
-		if ( EE_Registry::instance()->CAP->current_user_can( 'ee_delete_default_price_types', 'pricing_trash_price_type' ) ) {
420
+		if (EE_Registry::instance()->CAP->current_user_can('ee_delete_default_price_types', 'pricing_trash_price_type')) {
421 421
 			 $this->_views['trashed'] = array(
422 422
 					'slug' => 'trashed',
423 423
 					'label' => __('Trash', 'event_espresso'),
@@ -456,18 +456,18 @@  discard block
 block discarded – undo
456 456
 	* 	@param  boolean $trashed   whether the current view is of the trash can - eww yuck!
457 457
 	* 	@return mixed (int|array)  int = count || array of price objects
458 458
 	*/
459
-	public function get_prices_overview_data( $per_page = 10, $count = FALSE, $trashed = FALSE ) {
459
+	public function get_prices_overview_data($per_page = 10, $count = FALSE, $trashed = FALSE) {
460 460
 
461
-		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
461
+		do_action('AHEE_log', __FILE__, __FUNCTION__, '');
462 462
 		// start with an empty array
463 463
 		$event_pricing = array();
464 464
 
465
-		require_once( PRICING_ADMIN . 'Prices_List_Table.class.php' );
466
-		require_once(EE_MODELS . 'EEM_Price.model.php');
465
+		require_once(PRICING_ADMIN.'Prices_List_Table.class.php');
466
+		require_once(EE_MODELS.'EEM_Price.model.php');
467 467
 		//$PRC = EEM_Price::instance();
468 468
 
469 469
 		$this->_req_data['orderby'] = empty($this->_req_data['orderby']) ? '' : $this->_req_data['orderby'];
470
-		$order = ( isset( $this->_req_data['order'] ) && ! empty( $this->_req_data['order'] )) ? $this->_req_data['order'] : 'ASC';
470
+		$order = (isset($this->_req_data['order']) && ! empty($this->_req_data['order'])) ? $this->_req_data['order'] : 'ASC';
471 471
 
472 472
 		switch ($this->_req_data['orderby']) {
473 473
 			case 'name':
@@ -480,27 +480,27 @@  discard block
 block discarded – undo
480 480
 				$orderby = array('PRC_amount'=>$order);
481 481
 				break;
482 482
 			default:
483
-				$orderby = array( 'PRC_order'=>$order, 'Price_Type.PRT_order'=>$order, 'PRC_ID'=>$order);
483
+				$orderby = array('PRC_order'=>$order, 'Price_Type.PRT_order'=>$order, 'PRC_ID'=>$order);
484 484
 		}
485 485
 
486
-		$current_page = isset( $this->_req_data['paged'] ) && !empty( $this->_req_data['paged'] ) ? $this->_req_data['paged'] : 1;
487
-		$per_page = isset( $this->_req_data['perpage'] ) && !empty( $this->_req_data['perpage'] ) ? $this->_req_data['perpage'] : $per_page;
486
+		$current_page = isset($this->_req_data['paged']) && ! empty($this->_req_data['paged']) ? $this->_req_data['paged'] : 1;
487
+		$per_page = isset($this->_req_data['perpage']) && ! empty($this->_req_data['perpage']) ? $this->_req_data['perpage'] : $per_page;
488 488
 
489 489
 		$_where = array(
490 490
 				'PRC_is_default' => 1,
491 491
 				'PRC_deleted' => $trashed
492 492
 				);
493 493
 
494
-		$offset = ($current_page-1)*$per_page;
495
-		$limit = array( $offset, $per_page );
494
+		$offset = ($current_page - 1) * $per_page;
495
+		$limit = array($offset, $per_page);
496 496
 
497
-		if ( isset( $this->_req_data['s'] ) ) {
498
-			$sstr = '%' . $this->_req_data['s'] . '%';
497
+		if (isset($this->_req_data['s'])) {
498
+			$sstr = '%'.$this->_req_data['s'].'%';
499 499
 			$_where['OR'] = array(
500
-				'PRC_name' => array('LIKE',$sstr ),
501
-				'PRC_desc' => array('LIKE',$sstr ),
502
-				'PRC_amount' => array( 'LIKE',$sstr ),
503
-				'Price_Type.PRT_name' => array( 'LIKE', $sstr )
500
+				'PRC_name' => array('LIKE', $sstr),
501
+				'PRC_desc' => array('LIKE', $sstr),
502
+				'PRC_amount' => array('LIKE', $sstr),
503
+				'Price_Type.PRT_name' => array('LIKE', $sstr)
504 504
 				);
505 505
 		}
506 506
 
@@ -511,9 +511,9 @@  discard block
 block discarded – undo
511 511
 			'group_by'=>'PRC_ID'
512 512
 			);
513 513
 
514
-		if($count){
515
-			return $trashed ? EEM_Price::instance()->count( array( $_where ) ) : EEM_Price::instance()->count_deleted_and_undeleted(array($_where));
516
-		}else{
514
+		if ($count) {
515
+			return $trashed ? EEM_Price::instance()->count(array($_where)) : EEM_Price::instance()->count_deleted_and_undeleted(array($_where));
516
+		} else {
517 517
 			return EEM_Price::instance()->get_all_deleted_and_undeleted($query_params);
518 518
 		}
519 519
 	}
@@ -529,49 +529,49 @@  discard block
 block discarded – undo
529 529
 	*		@return void
530 530
 	*/
531 531
 	protected function _edit_price_details() {
532
-		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
532
+		do_action('AHEE_log', __FILE__, __FUNCTION__, '');
533 533
 		// grab price ID
534
-		$PRC_ID = isset( $this->_req_data['id'] ) && ! empty( $this->_req_data['id'] ) ? absint( $this->_req_data['id'] ) : FALSE;
534
+		$PRC_ID = isset($this->_req_data['id']) && ! empty($this->_req_data['id']) ? absint($this->_req_data['id']) : FALSE;
535 535
 		// change page title based on request action
536
-		switch( $this->_req_action ) {
536
+		switch ($this->_req_action) {
537 537
 			case 'add_new_price' :
538
-				$this->_admin_page_title = esc_html__( 'Add New Price', 'event_espresso' );
538
+				$this->_admin_page_title = esc_html__('Add New Price', 'event_espresso');
539 539
 				break;
540 540
 			case 'edit_price' :
541
-				$this->_admin_page_title = esc_html__( 'Edit Price', 'event_espresso' );
541
+				$this->_admin_page_title = esc_html__('Edit Price', 'event_espresso');
542 542
 				break;
543 543
 			default :
544
-				$this->_admin_page_title = ucwords( str_replace( '_', ' ', $this->_req_action ));
544
+				$this->_admin_page_title = ucwords(str_replace('_', ' ', $this->_req_action));
545 545
 		}
546 546
 		// add PRC_ID to title if editing
547
-		$this->_admin_page_title = $PRC_ID ? $this->_admin_page_title . ' # ' . $PRC_ID : $this->_admin_page_title;
547
+		$this->_admin_page_title = $PRC_ID ? $this->_admin_page_title.' # '.$PRC_ID : $this->_admin_page_title;
548 548
 
549 549
 		// get prices
550
-		require_once(EE_MODELS . 'EEM_Price.model.php');
550
+		require_once(EE_MODELS.'EEM_Price.model.php');
551 551
 		$PRC = EEM_Price::instance();
552 552
 
553
-		if ( $PRC_ID ) {
554
-			$price = $PRC->get_one_by_ID( $PRC_ID );
553
+		if ($PRC_ID) {
554
+			$price = $PRC->get_one_by_ID($PRC_ID);
555 555
 			$additional_hidden_fields = array(
556
-					'PRC_ID' => array( 'type' => 'hidden', 'value' => $PRC_ID )
556
+					'PRC_ID' => array('type' => 'hidden', 'value' => $PRC_ID)
557 557
 				);
558
-			$this->_set_add_edit_form_tags( 'update_price', $additional_hidden_fields );
558
+			$this->_set_add_edit_form_tags('update_price', $additional_hidden_fields);
559 559
 		} else {
560 560
 			$price = $PRC->get_new_price();
561
-			$this->_set_add_edit_form_tags( 'insert_price' );
561
+			$this->_set_add_edit_form_tags('insert_price');
562 562
 		}
563 563
 
564 564
 		$this->_template_args['PRC_ID'] = $PRC_ID;
565 565
 		$this->_template_args['price'] = $price;
566 566
 
567 567
 		// get price types
568
-		require_once(EE_MODELS . 'EEM_Price_Type.model.php');
568
+		require_once(EE_MODELS.'EEM_Price_Type.model.php');
569 569
 		$PRT = EEM_Price_Type::instance();
570
-		$price_types = $PRT->get_all( array( array('PBT_ID' => array('!=', 1 ) ) ) );
570
+		$price_types = $PRT->get_all(array(array('PBT_ID' => array('!=', 1))));
571 571
 		$price_type_names = array();
572 572
 		if (empty($price_types)) {
573
-			$msg = __( 'You have no price types defined. Please add a price type before adding a price.', 'event_espresso' );
574
-			EE_Error::add_error( $msg, __FILE__, __FUNCTION__, __LINE__ );
573
+			$msg = __('You have no price types defined. Please add a price type before adding a price.', 'event_espresso');
574
+			EE_Error::add_error($msg, __FILE__, __FUNCTION__, __LINE__);
575 575
 			exit();
576 576
 		} else {
577 577
 			foreach ($price_types as $type) {
@@ -584,7 +584,7 @@  discard block
 block discarded – undo
584 584
 		$this->_template_args['price_types'] = $price_type_names;
585 585
 		$this->_template_args['learn_more_about_pricing_link'] = $this->_learn_more_about_pricing_link();
586 586
 
587
-		$this->_set_publish_post_box_vars( 'id', $PRC_ID );
587
+		$this->_set_publish_post_box_vars('id', $PRC_ID);
588 588
 		// the details template wrapper
589 589
 		$this->display_admin_page_with_sidebar();
590 590
 	}
@@ -600,7 +600,7 @@  discard block
 block discarded – undo
600 600
 	*		@return void
601 601
 	*/
602 602
 	protected function _price_details_meta_boxes() {
603
-		add_meta_box( 'edit-price-details-mbox', __( 'Default Price Details', 'event_espresso' ), array( $this, '_edit_price_details_meta_box' ), $this->wp_page_slug, 'normal', 'high' );
603
+		add_meta_box('edit-price-details-mbox', __('Default Price Details', 'event_espresso'), array($this, '_edit_price_details_meta_box'), $this->wp_page_slug, 'normal', 'high');
604 604
 	}
605 605
 
606 606
 
@@ -614,7 +614,7 @@  discard block
 block discarded – undo
614 614
 	*		@return void
615 615
 	*/
616 616
 	public function _edit_price_details_meta_box() {
617
-		echo EEH_Template::display_template( PRICING_TEMPLATE_PATH . 'pricing_details_main_meta_box.template.php', $this->_template_args, TRUE );
617
+		echo EEH_Template::display_template(PRICING_TEMPLATE_PATH.'pricing_details_main_meta_box.template.php', $this->_template_args, TRUE);
618 618
 	}
619 619
 
620 620
 
@@ -628,7 +628,7 @@  discard block
 block discarded – undo
628 628
 	*/
629 629
 	protected function set_price_column_values() {
630 630
 
631
-		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
631
+		do_action('AHEE_log', __FILE__, __FUNCTION__, '');
632 632
 
633 633
 		$set_column_values = array(
634 634
 				'PRT_ID' => absint($this->_req_data['PRT_ID']),
@@ -656,12 +656,12 @@  discard block
 block discarded – undo
656 656
 	*		@access protected
657 657
 	*		@return void
658 658
 	*/
659
-	protected function _insert_or_update_price( $insert = FALSE ) {
659
+	protected function _insert_or_update_price($insert = FALSE) {
660 660
 
661 661
 		//echo '<h3>'. __CLASS__ . '->' . __FUNCTION__ . ' <br /><span style="font-size:10px;font-weight:normal;">' . __FILE__ . '<br />line no: ' . __LINE__ . '</span></h3>';
662
-		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
662
+		do_action('AHEE_log', __FILE__, __FUNCTION__, '');
663 663
 
664
-		require_once(EE_MODELS . 'EEM_Price.model.php');
664
+		require_once(EE_MODELS.'EEM_Price.model.php');
665 665
 		$PRC = EEM_Price::instance();
666 666
 
667 667
 		// why be so pessimistic ???  : (
@@ -669,14 +669,14 @@  discard block
 block discarded – undo
669 669
 
670 670
 		$set_column_values = $this->set_price_column_values();
671 671
 		// is this a new Price ?
672
-		if ( $insert ) {
672
+		if ($insert) {
673 673
 			// run the insert
674
-			if ( $PRC_ID = $PRC->insert( $set_column_values )) {
674
+			if ($PRC_ID = $PRC->insert($set_column_values)) {
675 675
 				//make sure this new price modifier is attached to the ticket but ONLY if it is not a tax type
676 676
 				$PR = EEM_price::instance()->get_one_by_ID($PRC_ID);
677
-				if ( $PR->type_obj()->base_type() !== EEM_Price_Type::base_type_tax ) {
677
+				if ($PR->type_obj()->base_type() !== EEM_Price_Type::base_type_tax) {
678 678
 					$ticket = EEM_Ticket::instance()->get_one_by_ID(1);
679
-					$ticket->_add_relation_to( $PR, 'Price' );
679
+					$ticket->_add_relation_to($PR, 'Price');
680 680
 					$ticket->save();
681 681
 				}
682 682
 				$success = 1;
@@ -686,29 +686,29 @@  discard block
 block discarded – undo
686 686
 			}
687 687
 			$action_desc = 'created';
688 688
 		} else {
689
-			$PRC_ID = absint( $this->_req_data['PRC_ID'] );
689
+			$PRC_ID = absint($this->_req_data['PRC_ID']);
690 690
 			// run the update
691
-			$where_cols_n_values = array( 'PRC_ID' => $PRC_ID );
692
-			if ( $PRC->update( $set_column_values, array($where_cols_n_values))) {
691
+			$where_cols_n_values = array('PRC_ID' => $PRC_ID);
692
+			if ($PRC->update($set_column_values, array($where_cols_n_values))) {
693 693
 				$success = 1;
694 694
 			}
695 695
 
696 696
 			$PR = EEM_Price::instance()->get_one_by_ID($PRC_ID);
697
-			if ( $PR->type_obj()->base_type() !== EEM_Price_Type::base_type_tax ) {
697
+			if ($PR->type_obj()->base_type() !== EEM_Price_Type::base_type_tax) {
698 698
 
699 699
 				//if this is $PRC_ID == 1, then we need to update the default ticket attached to this price so the TKT_price value is updated.
700
-				if ( $PRC_ID === 1 ) {
700
+				if ($PRC_ID === 1) {
701 701
 					$ticket = $PR->get_first_related('Ticket');
702
-					if ( $ticket ) {
703
-						$ticket->set('TKT_price', $PR->get('PRC_amount') );
704
-						$ticket->set('TKT_name', $PR->get('PRC_name') );
702
+					if ($ticket) {
703
+						$ticket->set('TKT_price', $PR->get('PRC_amount'));
704
+						$ticket->set('TKT_name', $PR->get('PRC_name'));
705 705
 						$ticket->set('TKT_description', $PR->get('PRC_desc'));
706 706
 						$ticket->save();
707 707
 					}
708 708
 				} else {
709 709
 					//we make sure this price is attached to base ticket. but ONLY if its not a tax ticket type.
710 710
 					$ticket = EEM_Ticket::instance()->get_one_by_ID(1);
711
-					$ticket->_add_relation_to( $PRC_ID, 'Price' );
711
+					$ticket->_add_relation_to($PRC_ID, 'Price');
712 712
 					$ticket->save();
713 713
 				}
714 714
 			}
@@ -716,9 +716,9 @@  discard block
 block discarded – undo
716 716
 			$action_desc = 'updated';
717 717
 		}
718 718
 
719
-		$query_args = array( 'action' => 'edit_price', 'id' => $PRC_ID );
719
+		$query_args = array('action' => 'edit_price', 'id' => $PRC_ID);
720 720
 
721
-		$this->_redirect_after_action( $success, 'Prices', $action_desc, $query_args );
721
+		$this->_redirect_after_action($success, 'Prices', $action_desc, $query_args);
722 722
 
723 723
 	}
724 724
 
@@ -732,12 +732,12 @@  discard block
 block discarded – undo
732 732
 	*		@access protected
733 733
 	*		@return void
734 734
 	*/
735
-	protected function _trash_or_restore_price( $trash = TRUE ) {
735
+	protected function _trash_or_restore_price($trash = TRUE) {
736 736
 
737 737
 		//echo '<h3>'. __CLASS__ . '->' . __FUNCTION__ . ' <br /><span style="font-size:10px;font-weight:normal;">' . __FILE__ . '<br />line no: ' . __LINE__ . '</span></h3>';
738
-		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
738
+		do_action('AHEE_log', __FILE__, __FUNCTION__, '');
739 739
 
740
-		require_once(EE_MODELS . 'EEM_Price.model.php');
740
+		require_once(EE_MODELS.'EEM_Price.model.php');
741 741
 		$PRC = EEM_Price::instance();
742 742
 
743 743
 		$success = 1;
@@ -746,18 +746,18 @@  discard block
 block discarded – undo
746 746
 		//get base ticket for updating
747 747
 		$ticket = EEM_Ticket::instance()->get_one_by_ID(1);
748 748
 		//Checkboxes
749
-		if (!empty($this->_req_data['checkbox']) && is_array($this->_req_data['checkbox'])) {
749
+		if ( ! empty($this->_req_data['checkbox']) && is_array($this->_req_data['checkbox'])) {
750 750
 			// if array has more than one element than success message should be plural
751
-			$success = count( $this->_req_data['checkbox'] ) > 1 ? 2 : 1;
751
+			$success = count($this->_req_data['checkbox']) > 1 ? 2 : 1;
752 752
 			// cycle thru checkboxes
753
-			while (list( $PRC_ID, $value ) = each($this->_req_data['checkbox'])) {
754
-				if ( ! $PRC->update_by_ID(array('PRC_deleted' => $PRC_deleted), absint($PRC_ID) ) ) {
753
+			while (list($PRC_ID, $value) = each($this->_req_data['checkbox'])) {
754
+				if ( ! $PRC->update_by_ID(array('PRC_deleted' => $PRC_deleted), absint($PRC_ID))) {
755 755
 					$success = 0;
756 756
 				} else {
757 757
 					$PR = EEM_Price::instance()->get_one_by_ID($PRC_ID);
758
-					if ( $PR->type_obj()->base_type() !== EEM_Price_Type::base_type_tax ) {
758
+					if ($PR->type_obj()->base_type() !== EEM_Price_Type::base_type_tax) {
759 759
 						//if trashing then remove relations to base default ticket.  If restoring then add back to base default ticket
760
-						if ( $PRC_deleted ) {
760
+						if ($PRC_deleted) {
761 761
 							$ticket->_remove_relation_to($PRC_ID, 'Price');
762 762
 						} else {
763 763
 							$ticket->_add_relation_to($PRC_ID, 'Price');
@@ -769,14 +769,14 @@  discard block
 block discarded – undo
769 769
 
770 770
 		} else {
771 771
 			// grab single id and delete
772
-			$PRC_ID = isset( $this->_req_data['id'] ) ? absint($this->_req_data['id']) : 0;
773
-			if ( empty( $PRC_ID ) || ! $PRC->update_by_ID(array('PRC_deleted' => $PRC_deleted), $PRC_ID) ) {
772
+			$PRC_ID = isset($this->_req_data['id']) ? absint($this->_req_data['id']) : 0;
773
+			if (empty($PRC_ID) || ! $PRC->update_by_ID(array('PRC_deleted' => $PRC_deleted), $PRC_ID)) {
774 774
 				$success = 0;
775 775
 			} else {
776 776
 				$PR = EEM_Price::instance()->get_one_by_ID($PRC_ID);
777
-				if ( $PR->type_obj()->base_type() !== EEM_Price_Type::base_type_tax ) {
777
+				if ($PR->type_obj()->base_type() !== EEM_Price_Type::base_type_tax) {
778 778
 					//if trashing then remove relations to base default ticket.  If restoring then add back to base default ticket
779
-					if ( $PRC_deleted ) {
779
+					if ($PRC_deleted) {
780 780
 						$ticket->_remove_relation_to($PRC_ID, 'Price');
781 781
 					} else {
782 782
 						$ticket->_add_relation_to($PRC_ID, 'Price');
@@ -790,17 +790,17 @@  discard block
 block discarded – undo
790 790
 			'action' => 'default'
791 791
 			);
792 792
 
793
-		if ( $success ) {
794
-			if ( $trash ) {
793
+		if ($success) {
794
+			if ($trash) {
795 795
 				$msg = $success == 2 ? __('The Prices have been trashed.', 'event_espresso') : __('The Price has been trashed.', 'event_espresso');
796 796
 			} else {
797 797
 				$msg = $success == 2 ? __('The Prices have been restored.', 'event_espresso') : __('The Price has been restored.', 'event_espresso');
798 798
 			}
799 799
 
800
-			EE_Error::add_success( $msg );
800
+			EE_Error::add_success($msg);
801 801
 		}
802 802
 
803
-		$this->_redirect_after_action( FALSE, '', '', $query_args, TRUE );
803
+		$this->_redirect_after_action(FALSE, '', '', $query_args, TRUE);
804 804
 
805 805
 	}
806 806
 
@@ -817,19 +817,19 @@  discard block
 block discarded – undo
817 817
 	protected function _delete_price() {
818 818
 
819 819
 		//echo '<h3>'. __CLASS__ . '->' . __FUNCTION__ . ' <br /><span style="font-size:10px;font-weight:normal;">' . __FILE__ . '<br />line no: ' . __LINE__ . '</span></h3>';
820
-		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
820
+		do_action('AHEE_log', __FILE__, __FUNCTION__, '');
821 821
 
822
-		require_once(EE_MODELS . 'EEM_Price.model.php');
822
+		require_once(EE_MODELS.'EEM_Price.model.php');
823 823
 		$PRC = EEM_Price::instance();
824 824
 
825 825
 		$success = 1;
826 826
 		//Checkboxes
827
-		if (!empty($this->_req_data['checkbox']) && is_array($this->_req_data['checkbox'])) {
827
+		if ( ! empty($this->_req_data['checkbox']) && is_array($this->_req_data['checkbox'])) {
828 828
 			// if array has more than one element than success message should be plural
829
-			$success = count( $this->_req_data['checkbox'] ) > 1 ? 2 : 1;
829
+			$success = count($this->_req_data['checkbox']) > 1 ? 2 : 1;
830 830
 			// cycle thru bulk action checkboxes
831
-			while (list( $PRC_ID, $value ) = each($this->_req_data['checkbox'])) {
832
-				if (!$PRC->delete_permanently_by_ID(absint($PRC_ID))) {
831
+			while (list($PRC_ID, $value) = each($this->_req_data['checkbox'])) {
832
+				if ( ! $PRC->delete_permanently_by_ID(absint($PRC_ID))) {
833 833
 					$success = 0;
834 834
 				}
835 835
 			}
@@ -843,7 +843,7 @@  discard block
 block discarded – undo
843 843
 
844 844
 		}
845 845
 
846
-		$this->_redirect_after_action( $success, 'Prices', 'deleted', array() );
846
+		$this->_redirect_after_action($success, 'Prices', 'deleted', array());
847 847
 
848 848
 	}
849 849
 
@@ -851,16 +851,16 @@  discard block
 block discarded – undo
851 851
 
852 852
 
853 853
 	public function update_price_order() {
854
-		$success = __( 'Price order was updated successfully.', 'event_espresso' );
854
+		$success = __('Price order was updated successfully.', 'event_espresso');
855 855
 
856 856
 		// grab our row IDs
857
-		$row_ids = isset( $this->_req_data['row_ids'] ) && ! empty( $this->_req_data['row_ids'] ) ? explode( ',', rtrim( $this->_req_data['row_ids'], ',' )) : FALSE;
857
+		$row_ids = isset($this->_req_data['row_ids']) && ! empty($this->_req_data['row_ids']) ? explode(',', rtrim($this->_req_data['row_ids'], ',')) : FALSE;
858 858
 
859
-		if ( is_array( $row_ids )) {
860
-			for ( $i = 0; $i < count( $row_ids ); $i++ ) {
859
+		if (is_array($row_ids)) {
860
+			for ($i = 0; $i < count($row_ids); $i++) {
861 861
 				//Update the prices when re-ordering
862 862
 				$id = absint($row_ids[$i]);
863
-				if ( EEM_Price::instance()->update ( array( 'PRC_order' => $i+1 ), array(array( 'PRC_ID' => $id ) )) === FALSE ) {
863
+				if (EEM_Price::instance()->update(array('PRC_order' => $i + 1), array(array('PRC_ID' => $id))) === FALSE) {
864 864
 					$success = FALSE;
865 865
 				}
866 866
 			}
@@ -868,9 +868,9 @@  discard block
 block discarded – undo
868 868
 			$success = FALSE;
869 869
 		}
870 870
 
871
-		$errors = ! $success ? __( 'An error occurred. The price order was not updated.', 'event_espresso' ) : FALSE;
871
+		$errors = ! $success ? __('An error occurred. The price order was not updated.', 'event_espresso') : FALSE;
872 872
 
873
-		echo json_encode( array( 'return_data' => FALSE, 'success' => $success, 'errors' => $errors ));
873
+		echo json_encode(array('return_data' => FALSE, 'success' => $success, 'errors' => $errors));
874 874
 		die();
875 875
 	}
876 876
 
@@ -913,46 +913,46 @@  discard block
 block discarded – undo
913 913
 	* 	@param  boolean $trashed   whether the current view is of the trash can - eww yuck!
914 914
 	* 	@return mixed (int|array)  int = count || array of price objects
915 915
 	*/
916
-	public function get_price_types_overview_data( $per_page = 10, $count = FALSE, $trashed = FALSE ) {
916
+	public function get_price_types_overview_data($per_page = 10, $count = FALSE, $trashed = FALSE) {
917 917
 
918
-		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
918
+		do_action('AHEE_log', __FILE__, __FUNCTION__, '');
919 919
 		// start with an empty array
920 920
 
921
-		require_once( PRICING_ADMIN . 'Price_Types_List_Table.class.php' );
922
-		require_once( EE_MODELS . 'EEM_Price_Type.model.php' );
921
+		require_once(PRICING_ADMIN.'Price_Types_List_Table.class.php');
922
+		require_once(EE_MODELS.'EEM_Price_Type.model.php');
923 923
 
924 924
 		$this->_req_data['orderby'] = empty($this->_req_data['orderby']) ? '' : $this->_req_data['orderby'];
925
-		$order = ( isset( $this->_req_data['order'] ) && ! empty( $this->_req_data['order'] )) ? $this->_req_data['order'] : 'ASC';
925
+		$order = (isset($this->_req_data['order']) && ! empty($this->_req_data['order'])) ? $this->_req_data['order'] : 'ASC';
926 926
 		switch ($this->_req_data['orderby']) {
927 927
 			case 'name':
928
-				$orderby = array( 'PRT_name' => $order);
928
+				$orderby = array('PRT_name' => $order);
929 929
 				break;
930 930
 			default:
931
-				$orderby = array( 'PRT_order' => $order);
931
+				$orderby = array('PRT_order' => $order);
932 932
 		}
933 933
 
934 934
 
935
-		$current_page = isset( $this->_req_data['paged'] ) && !empty( $this->_req_data['paged'] ) ? $this->_req_data['paged'] : 1;
936
-		$per_page = isset( $this->_req_data['perpage'] ) && !empty( $this->_req_data['perpage'] ) ? $this->_req_data['perpage'] : $per_page;
935
+		$current_page = isset($this->_req_data['paged']) && ! empty($this->_req_data['paged']) ? $this->_req_data['paged'] : 1;
936
+		$per_page = isset($this->_req_data['perpage']) && ! empty($this->_req_data['perpage']) ? $this->_req_data['perpage'] : $per_page;
937 937
 
938
-		$offset = ($current_page-1)*$per_page;
939
-		$limit = array( $offset, $per_page );
938
+		$offset = ($current_page - 1) * $per_page;
939
+		$limit = array($offset, $per_page);
940 940
 
941
-		$_where = array('PRT_deleted'=>$trashed, 'PBT_ID' => array('!=', 1 ) );
941
+		$_where = array('PRT_deleted'=>$trashed, 'PBT_ID' => array('!=', 1));
942 942
 
943
-		if ( isset( $this->_req_data['s'] ) ) {
944
-			$sstr = '%' . $this->_req_data['s'] . '%';
943
+		if (isset($this->_req_data['s'])) {
944
+			$sstr = '%'.$this->_req_data['s'].'%';
945 945
 			$_where['OR'] = array(
946
-				'PRT_name' => array( 'LIKE', $sstr )
946
+				'PRT_name' => array('LIKE', $sstr)
947 947
 				);
948 948
 		}
949 949
 		$query_params = array(
950 950
 			$_where,
951 951
 			'order_by'=>$orderby,
952 952
 			'limit'=>$limit);
953
-		if($count){
953
+		if ($count) {
954 954
 			return EEM_Price_Type::instance()->count_deleted_and_undeleted($query_params);
955
-		}else{
955
+		} else {
956 956
 			return EEM_Price_Type::instance()->get_all_deleted_and_undeleted($query_params);
957 957
 		}
958 958
 
@@ -972,34 +972,34 @@  discard block
 block discarded – undo
972 972
 	*/
973 973
 	protected function _edit_price_type_details() {
974 974
 
975
-		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
975
+		do_action('AHEE_log', __FILE__, __FUNCTION__, '');
976 976
 
977 977
 
978 978
 		// grab price type ID
979
-		$PRT_ID = isset( $this->_req_data['id'] ) && ! empty( $this->_req_data['id'] ) ? absint( $this->_req_data['id'] ) : FALSE;
979
+		$PRT_ID = isset($this->_req_data['id']) && ! empty($this->_req_data['id']) ? absint($this->_req_data['id']) : FALSE;
980 980
 		// change page title based on request action
981
-		switch( $this->_req_action ) {
981
+		switch ($this->_req_action) {
982 982
 			case 'add_new_price_type' :
983
-				$this->_admin_page_title = esc_html__( 'Add New Price Type', 'event_espresso' );
983
+				$this->_admin_page_title = esc_html__('Add New Price Type', 'event_espresso');
984 984
 				break;
985 985
 			case 'edit_price_type' :
986
-				$this->_admin_page_title = esc_html__( 'Edit Price Type', 'event_espresso' );
986
+				$this->_admin_page_title = esc_html__('Edit Price Type', 'event_espresso');
987 987
 				break;
988 988
 			default :
989
-				$this->_admin_page_title = ucwords( str_replace( '_', ' ', $this->_req_action ));
989
+				$this->_admin_page_title = ucwords(str_replace('_', ' ', $this->_req_action));
990 990
 		}
991 991
 		// add PRT_ID to title if editing
992
-		$this->_admin_page_title = $PRT_ID ? $this->_admin_page_title . ' # ' . $PRT_ID : $this->_admin_page_title;
992
+		$this->_admin_page_title = $PRT_ID ? $this->_admin_page_title.' # '.$PRT_ID : $this->_admin_page_title;
993 993
 
994 994
 //		require_once(EE_MODELS . 'EEM_Price_Type.model.php');
995 995
 
996
-		if ( $PRT_ID ) {
997
-			$price_type = EEM_Price_Type::instance()->get_one_by_ID( $PRT_ID );
998
-			$additional_hidden_fields = array( 'PRT_ID' => array( 'type' => 'hidden', 'value' => $PRT_ID ));
999
-			$this->_set_add_edit_form_tags( 'update_price_type', $additional_hidden_fields );
996
+		if ($PRT_ID) {
997
+			$price_type = EEM_Price_Type::instance()->get_one_by_ID($PRT_ID);
998
+			$additional_hidden_fields = array('PRT_ID' => array('type' => 'hidden', 'value' => $PRT_ID));
999
+			$this->_set_add_edit_form_tags('update_price_type', $additional_hidden_fields);
1000 1000
 		} else {
1001 1001
 			$price_type = EEM_Price_Type::instance()->get_new_price_type();
1002
-			$this->_set_add_edit_form_tags( 'insert_price_type' );
1002
+			$this->_set_add_edit_form_tags('insert_price_type');
1003 1003
 		}
1004 1004
 
1005 1005
 		$this->_template_args['PRT_ID'] = $PRT_ID;
@@ -1008,19 +1008,19 @@  discard block
 block discarded – undo
1008 1008
 
1009 1009
 		$base_types = EEM_Price_Type::instance()->get_base_types();
1010 1010
 		$select_values = array();
1011
-		foreach ( $base_types as $ref => $text ) {
1012
-			if ( $ref == EEM_Price_Type::base_type_base_price ) {
1011
+		foreach ($base_types as $ref => $text) {
1012
+			if ($ref == EEM_Price_Type::base_type_base_price) {
1013 1013
 				//do not allow creation of base_type_base_prices because that's a system only base type.
1014 1014
 				continue;
1015 1015
 			}
1016
-			$values[] = array( 'id' => $ref, 'text' => $text );
1016
+			$values[] = array('id' => $ref, 'text' => $text);
1017 1017
 		}
1018 1018
 
1019 1019
 
1020 1020
 		$this->_template_args['base_type_select'] = EEH_Form_Fields::select_input('base_type', $values, $price_type->base_type(), 'id="price-type-base-type-slct"');
1021 1021
 		$this->_template_args['learn_more_about_pricing_link'] = $this->_learn_more_about_pricing_link();
1022
-		$redirect_URL = add_query_arg( array( 'action' => 'price_types'), $this->_admin_base_url );
1023
-		$this->_set_publish_post_box_vars( 'id', $PRT_ID, FALSE, $redirect_URL );
1022
+		$redirect_URL = add_query_arg(array('action' => 'price_types'), $this->_admin_base_url);
1023
+		$this->_set_publish_post_box_vars('id', $PRT_ID, FALSE, $redirect_URL);
1024 1024
 		// the details template wrapper
1025 1025
 		$this->display_admin_page_with_sidebar();
1026 1026
 
@@ -1037,7 +1037,7 @@  discard block
 block discarded – undo
1037 1037
 	*		@return void
1038 1038
 	*/
1039 1039
 	protected function _price_type_details_meta_boxes() {
1040
-		add_meta_box( 'edit-price-details-mbox', __( 'Price Type Details', 'event_espresso' ), array( $this, '_edit_price_type_details_meta_box' ), $this->wp_page_slug, 'normal', 'high' );
1040
+		add_meta_box('edit-price-details-mbox', __('Price Type Details', 'event_espresso'), array($this, '_edit_price_type_details_meta_box'), $this->wp_page_slug, 'normal', 'high');
1041 1041
 	}
1042 1042
 
1043 1043
 
@@ -1050,7 +1050,7 @@  discard block
 block discarded – undo
1050 1050
 	*		@return void
1051 1051
 	*/
1052 1052
 	public function _edit_price_type_details_meta_box() {
1053
-		echo EEH_Template::display_template( PRICING_TEMPLATE_PATH . 'pricing_type_details_main_meta_box.template.php', $this->_template_args, TRUE );
1053
+		echo EEH_Template::display_template(PRICING_TEMPLATE_PATH.'pricing_type_details_main_meta_box.template.php', $this->_template_args, TRUE);
1054 1054
 	}
1055 1055
 
1056 1056
 
@@ -1063,9 +1063,9 @@  discard block
 block discarded – undo
1063 1063
 	*/
1064 1064
 	protected function set_price_type_column_values() {
1065 1065
 
1066
-		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
1066
+		do_action('AHEE_log', __FILE__, __FUNCTION__, '');
1067 1067
 
1068
-		$base_type = !empty( $this->_req_data['base_type'] ) ? $this->_req_data['base_type'] : EEM_Price_Type::base_type_base_price;
1068
+		$base_type = ! empty($this->_req_data['base_type']) ? $this->_req_data['base_type'] : EEM_Price_Type::base_type_base_price;
1069 1069
 
1070 1070
 		switch ($base_type) {
1071 1071
 
@@ -1112,12 +1112,12 @@  discard block
 block discarded – undo
1112 1112
 	*		@access protected
1113 1113
 	*		@return void
1114 1114
 	*/
1115
-	protected function _insert_or_update_price_type( $new_price_type = FALSE ) {
1115
+	protected function _insert_or_update_price_type($new_price_type = FALSE) {
1116 1116
 
1117 1117
 //		echo '<h3>'. __CLASS__ . '->' . __FUNCTION__ . ' <br /><span style="font-size:10px;font-weight:normal;">' . __FILE__ . '<br />line no: ' . __LINE__ . '</span></h3>';
1118
-		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
1118
+		do_action('AHEE_log', __FILE__, __FUNCTION__, '');
1119 1119
 
1120
-		require_once(EE_MODELS . 'EEM_Price_Type.model.php');
1120
+		require_once(EE_MODELS.'EEM_Price_Type.model.php');
1121 1121
 		$PRT = EEM_Price_Type::instance();
1122 1122
 
1123 1123
 		// why be so pessimistic ???  : (
@@ -1125,24 +1125,24 @@  discard block
 block discarded – undo
1125 1125
 
1126 1126
 		$set_column_values = $this->set_price_type_column_values();
1127 1127
 		// is this a new Price ?
1128
-		if ( $new_price_type ) {
1128
+		if ($new_price_type) {
1129 1129
 			// run the insert
1130
-			if ( $PRT_ID = $PRT->insert( $set_column_values )) {
1130
+			if ($PRT_ID = $PRT->insert($set_column_values)) {
1131 1131
 				$success = 1;
1132 1132
 			}
1133 1133
 			$action_desc = 'created';
1134 1134
 		} else {
1135 1135
 			$PRT_ID = absint($this->_req_data['PRT_ID']);
1136 1136
 			// run the update
1137
-			$where_cols_n_values = array('PRT_ID' => $PRT_ID );
1138
-			if ( $PRT->update( $set_column_values, array( $where_cols_n_values ))) {
1137
+			$where_cols_n_values = array('PRT_ID' => $PRT_ID);
1138
+			if ($PRT->update($set_column_values, array($where_cols_n_values))) {
1139 1139
 				$success = 1;
1140 1140
 			}
1141 1141
 			$action_desc = 'updated';
1142 1142
 		}
1143 1143
 
1144
-		$query_args = array( 'action'=> 'edit_price_type', 'id' => $PRT_ID );
1145
-		$this->_redirect_after_action( $success, 'Price Type', $action_desc, $query_args );
1144
+		$query_args = array('action'=> 'edit_price_type', 'id' => $PRT_ID);
1145
+		$this->_redirect_after_action($success, 'Price Type', $action_desc, $query_args);
1146 1146
 
1147 1147
 	}
1148 1148
 
@@ -1156,49 +1156,49 @@  discard block
 block discarded – undo
1156 1156
 	*		@access protected
1157 1157
 	*		@return void
1158 1158
 	*/
1159
-	protected function _trash_or_restore_price_type( $trash = TRUE ) {
1159
+	protected function _trash_or_restore_price_type($trash = TRUE) {
1160 1160
 
1161 1161
 		//echo '<h3>'. __CLASS__ . '->' . __FUNCTION__ . ' <br /><span style="font-size:10px;font-weight:normal;">' . __FILE__ . '<br />line no: ' . __LINE__ . '</span></h3>';
1162
-		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
1162
+		do_action('AHEE_log', __FILE__, __FUNCTION__, '');
1163 1163
 
1164
-		require_once(EE_MODELS . 'EEM_Price_Type.model.php');
1164
+		require_once(EE_MODELS.'EEM_Price_Type.model.php');
1165 1165
 		$PRT = EEM_Price_Type::instance();
1166 1166
 
1167 1167
 		$success = 1;
1168 1168
 		$PRT_deleted = $trash ? TRUE : FALSE;
1169 1169
 		//Checkboxes
1170
-		if (!empty($this->_req_data['checkbox']) && is_array($this->_req_data['checkbox'])) {
1170
+		if ( ! empty($this->_req_data['checkbox']) && is_array($this->_req_data['checkbox'])) {
1171 1171
 			// if array has more than one element than success message should be plural
1172
-			$success = count( $this->_req_data['checkbox'] ) > 1 ? 2 : 1;
1173
-			$what = count( $this->_req_data['checkbox'] ) > 1 ? 'Price Types' : 'Price Type';
1172
+			$success = count($this->_req_data['checkbox']) > 1 ? 2 : 1;
1173
+			$what = count($this->_req_data['checkbox']) > 1 ? 'Price Types' : 'Price Type';
1174 1174
 			// cycle thru checkboxes
1175
-			while (list( $PRT_ID, $value ) = each($this->_req_data['checkbox'])) {
1176
-				if ( ! $PRT->update_by_ID(array('PRT_deleted' => $PRT_deleted), $PRT_ID ) ) {
1175
+			while (list($PRT_ID, $value) = each($this->_req_data['checkbox'])) {
1176
+				if ( ! $PRT->update_by_ID(array('PRT_deleted' => $PRT_deleted), $PRT_ID)) {
1177 1177
 					$success = 0;
1178 1178
 				}
1179 1179
 			}
1180 1180
 
1181 1181
 		} else {
1182 1182
 			// grab single id and delete
1183
-			$PRT_ID = isset( $this->_req_data['id'] ) ? absint($this->_req_data['id']) : 0;
1184
-			if ( empty( $PRT_ID ) || ! $PRT->update_by_ID(array('PRT_deleted' => $PRT_deleted), $PRT_ID )) {
1183
+			$PRT_ID = isset($this->_req_data['id']) ? absint($this->_req_data['id']) : 0;
1184
+			if (empty($PRT_ID) || ! $PRT->update_by_ID(array('PRT_deleted' => $PRT_deleted), $PRT_ID)) {
1185 1185
 				$success = 0;
1186 1186
 			}
1187 1187
 			$what = 'Price Type';
1188 1188
 
1189 1189
 		}
1190 1190
 
1191
-		$query_args = array( 'action' => 'price_types' );
1192
-		if ( $success ) {
1193
-			if ( $trash ) {
1191
+		$query_args = array('action' => 'price_types');
1192
+		if ($success) {
1193
+			if ($trash) {
1194 1194
 				$msg = $success > 1 ? __('The Price Types have been trashed.', 'event_espresso') : __('The Price Type has been trashed.', 'event_espresso');
1195 1195
 			} else {
1196 1196
 				$msg = $success > 1 ? __('The Price Types have been restored.', 'event_espresso') : __('The Price Type has been restored.', 'event_espresso');
1197 1197
 			}
1198
-			EE_Error::add_success( $msg );
1198
+			EE_Error::add_success($msg);
1199 1199
 		}
1200 1200
 
1201
-		$this->_redirect_after_action( FALSE, '', '', $query_args, TRUE );
1201
+		$this->_redirect_after_action(FALSE, '', '', $query_args, TRUE);
1202 1202
 
1203 1203
 	}
1204 1204
 
@@ -1215,19 +1215,19 @@  discard block
 block discarded – undo
1215 1215
 	protected function _delete_price_type() {
1216 1216
 
1217 1217
 		//echo '<h3>'. __CLASS__ . '->' . __FUNCTION__ . ' <br /><span style="font-size:10px;font-weight:normal;">' . __FILE__ . '<br />line no: ' . __LINE__ . '</span></h3>';
1218
-		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
1218
+		do_action('AHEE_log', __FILE__, __FUNCTION__, '');
1219 1219
 
1220 1220
 		$PRT = EEM_Price_Type::instance();
1221 1221
 
1222 1222
 		$success = 1;
1223 1223
 		//Checkboxes
1224
-		if (!empty($this->_req_data['checkbox'])) {
1224
+		if ( ! empty($this->_req_data['checkbox'])) {
1225 1225
 			// if array has more than one element than success message should be plural
1226
-			$success = count( $this->_req_data['checkbox'] ) > 1 ? 2 : 1;
1226
+			$success = count($this->_req_data['checkbox']) > 1 ? 2 : 1;
1227 1227
 			$what = $PRT->item_name($success);
1228 1228
 			// cycle thru bulk action checkboxes
1229
-			while (list( $PRT_ID, $value ) = each($this->_req_data['checkbox'])) {
1230
-				if (!$PRT->delete_permanently_by_ID($PRT_ID) ) {
1229
+			while (list($PRT_ID, $value) = each($this->_req_data['checkbox'])) {
1230
+				if ( ! $PRT->delete_permanently_by_ID($PRT_ID)) {
1231 1231
 					$success = 0;
1232 1232
 				}
1233 1233
 			}
@@ -1235,8 +1235,8 @@  discard block
 block discarded – undo
1235 1235
 		}
1236 1236
 
1237 1237
 
1238
-		$query_args = array( 'action'=> 'price_types' );
1239
-		$this->_redirect_after_action( $success, $what, 'deleted', $query_args );
1238
+		$query_args = array('action'=> 'price_types');
1239
+		$this->_redirect_after_action($success, $what, 'deleted', $query_args);
1240 1240
 
1241 1241
 	}
1242 1242
 
@@ -1252,7 +1252,7 @@  discard block
 block discarded – undo
1252 1252
 	*		@return string
1253 1253
 	*/
1254 1254
 	protected function _learn_more_about_pricing_link() {
1255
-		return '<a class="hidden" style="margin:0 20px; cursor:pointer; font-size:12px;" >' . __('learn more about how pricing works', 'event_espresso') . '</a>';
1255
+		return '<a class="hidden" style="margin:0 20px; cursor:pointer; font-size:12px;" >'.__('learn more about how pricing works', 'event_espresso').'</a>';
1256 1256
 	}
1257 1257
 
1258 1258
 
Please login to merge, or discard this patch.
Braces   +5 added lines, -3 removed lines patch added patch discarded remove patch
@@ -1,4 +1,6 @@  discard block
 block discarded – undo
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
  *
@@ -545,7 +547,7 @@  discard block
 block discarded – undo
545 547
 
546 548
 		if($count){
547 549
 			return $trashed ? EEM_Price::instance()->count( array( $_where ) ) : EEM_Price::instance()->count_deleted_and_undeleted(array($_where));
548
-		}else{
550
+		} else{
549 551
 			return EEM_Price::instance()->get_all_deleted_and_undeleted($query_params);
550 552
 		}
551 553
 	}
@@ -989,7 +991,7 @@  discard block
 block discarded – undo
989 991
 			'limit'=>$limit);
990 992
 		if($count){
991 993
 			return EEM_Price_Type::instance()->count_deleted_and_undeleted($query_params);
992
-		}else{
994
+		} else{
993 995
 			return EEM_Price_Type::instance()->get_all_deleted_and_undeleted($query_params);
994 996
 		}
995 997
 
Please login to merge, or discard this patch.
caffeinated/admin/new/pricing/Pricing_Admin_Page_Init.core.php 2 patches
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@  discard block
 block discarded – undo
23 23
 *
24 24
 * ------------------------------------------------------------------------
25 25
 */
26
-class Pricing_Admin_Page_Init extends EE_Admin_Page_Init  {
26
+class Pricing_Admin_Page_Init extends EE_Admin_Page_Init {
27 27
 
28 28
 
29 29
 
@@ -36,20 +36,20 @@  discard block
 block discarded – undo
36 36
 	 */
37 37
 	public function __construct() {
38 38
 
39
-		do_action( 'AHEE_log', __FILE__, __FUNCTION__, '' );
39
+		do_action('AHEE_log', __FILE__, __FUNCTION__, '');
40 40
 
41
-		define( 'PRICING_PG_SLUG', 'pricing' );
42
-		define( 'PRICING_LABEL', __('Pricing', 'event_espresso'));
43
-		define( 'PRICING_PG_NAME', ucwords( str_replace( '_', '', PRICING_PG_SLUG )));
44
-		define( 'PRICING_ADMIN', EE_CORE_CAF_ADMIN . 'new' . DS . PRICING_PG_SLUG . DS );
45
-		define( 'PRICING_ADMIN_URL', admin_url( 'admin.php?page=' . PRICING_PG_SLUG ));
46
-		define( 'PRICING_ASSETS_PATH', PRICING_ADMIN . 'assets' . DS );
47
-		define( 'PRICING_ASSETS_URL', EE_CORE_CAF_ADMIN_URL . 'new' . DS . PRICING_PG_SLUG .'/assets/' );
48
-		define( 'PRICING_TEMPLATE_PATH', PRICING_ADMIN . 'templates' . DS );
49
-		define( 'PRICING_TEMPLATE_URL', EE_CORE_CAF_ADMIN_URL . 'new' . DS . PRICING_PG_SLUG . DS . 'templates/' );
41
+		define('PRICING_PG_SLUG', 'pricing');
42
+		define('PRICING_LABEL', __('Pricing', 'event_espresso'));
43
+		define('PRICING_PG_NAME', ucwords(str_replace('_', '', PRICING_PG_SLUG)));
44
+		define('PRICING_ADMIN', EE_CORE_CAF_ADMIN.'new'.DS.PRICING_PG_SLUG.DS);
45
+		define('PRICING_ADMIN_URL', admin_url('admin.php?page='.PRICING_PG_SLUG));
46
+		define('PRICING_ASSETS_PATH', PRICING_ADMIN.'assets'.DS);
47
+		define('PRICING_ASSETS_URL', EE_CORE_CAF_ADMIN_URL.'new'.DS.PRICING_PG_SLUG.'/assets/');
48
+		define('PRICING_TEMPLATE_PATH', PRICING_ADMIN.'templates'.DS);
49
+		define('PRICING_TEMPLATE_URL', EE_CORE_CAF_ADMIN_URL.'new'.DS.PRICING_PG_SLUG.DS.'templates/');
50 50
 
51 51
 		parent::__construct();
52
-		$this->_folder_path = EE_CORE_CAF_ADMIN . 'new' . DS . $this->_folder_name . DS;
52
+		$this->_folder_path = EE_CORE_CAF_ADMIN.'new'.DS.$this->_folder_name.DS;
53 53
 
54 54
 	}
55 55
 
@@ -64,7 +64,7 @@  discard block
 block discarded – undo
64 64
 
65 65
 
66 66
 	protected function _set_menu_map() {
67
-		$this->_menu_map = new EE_Admin_Page_Sub_Menu( array(
67
+		$this->_menu_map = new EE_Admin_Page_Sub_Menu(array(
68 68
 			'menu_group' => 'management',
69 69
 			'menu_order' => 20,
70 70
 			'show_on_menu' => EE_Admin_Page_Menu_Map::BLOG_ADMIN_ONLY,
Please login to merge, or discard this patch.
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,4 +1,6 @@
 block discarded – undo
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
 *
Please login to merge, or discard this patch.
new/pricing/help_tours/Pricing_Add_New_Default_Price_Help_Tour.class.php 2 patches
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
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
 /**
@@ -78,25 +78,25 @@  discard block
 block discarded – undo
78 78
 
79 79
 
80 80
 	protected function _start() {
81
-		$content = '<h3>' . __('Add New Default Price', 'event_espresso') . '</h3>';
82
-		$content .= '<p>' . __('This tour of the add new default price page will go over different areas of the screen to help you understand what they are used for.', 'event_espresso') . '</p>';
81
+		$content = '<h3>'.__('Add New Default Price', 'event_espresso').'</h3>';
82
+		$content .= '<p>'.__('This tour of the add new default price page will go over different areas of the screen to help you understand what they are used for.', 'event_espresso').'</p>';
83 83
 		return $content;
84 84
 	}
85 85
 
86 86
 	protected function _price_type_stop() {
87
-		return '<p>' . __('Price Types are a way of categorizing a price, discount, tax, or surcharge and indicating how it gets applied to a running total when a transaction occurs.', 'event_espresso') . '</p>';
87
+		return '<p>'.__('Price Types are a way of categorizing a price, discount, tax, or surcharge and indicating how it gets applied to a running total when a transaction occurs.', 'event_espresso').'</p>';
88 88
 	}
89 89
 
90 90
 	protected function _price_name_stop() {
91
-		return '<p>' . __('The name of the price, discount, tax, or surcharge that will be seen by your customers.', 'event_espresso') . '</p>';
91
+		return '<p>'.__('The name of the price, discount, tax, or surcharge that will be seen by your customers.', 'event_espresso').'</p>';
92 92
 	}
93 93
 
94 94
 	protected function _price_description_stop() {
95
-		return '<p>' . __('View the price type (price, discount, tax or surcharge) description.', 'event_espresso') . '</p>';
95
+		return '<p>'.__('View the price type (price, discount, tax or surcharge) description.', 'event_espresso').'</p>';
96 96
 	}
97 97
 
98 98
 	protected function _price_amount_stop() {
99
-		return '<p>' . __('The ticket amount before any deductions.', 'event_espresso') . '</p>';
99
+		return '<p>'.__('The ticket amount before any deductions.', 'event_espresso').'</p>';
100 100
 	}
101 101
 
102 102
 }
103 103
\ No newline at end of file
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,6 +1,7 @@
 block discarded – undo
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
Please login to merge, or discard this patch.
admin/new/pricing/help_tours/Pricing_Add_New_Price_Type_Help_Tour.class.php 2 patches
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
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
 /**
@@ -78,25 +78,25 @@  discard block
 block discarded – undo
78 78
 
79 79
 
80 80
 	protected function _start() {
81
-		$content = '<h3>' . __('Add New Price Type', 'event_espresso') . '</h3>';
82
-		$content .= '<p>' . __('This tour of the Add New Price Type page will go over different areas of the screen to help you understand what they are used for.', 'event_espresso') . '</p>';
81
+		$content = '<h3>'.__('Add New Price Type', 'event_espresso').'</h3>';
82
+		$content .= '<p>'.__('This tour of the Add New Price Type page will go over different areas of the screen to help you understand what they are used for.', 'event_espresso').'</p>';
83 83
 		return $content;
84 84
 	}
85 85
 	
86 86
 	protected function _basic_type_stop() {
87
-		return '<p>' . __('Set a price type to be a discount, surcharge, or tax.', 'event_espresso') . '</p>';
87
+		return '<p>'.__('Set a price type to be a discount, surcharge, or tax.', 'event_espresso').'</p>';
88 88
 	}
89 89
 
90 90
 	protected function _price_type_name_stop() {
91
-		return '<p>' . __('The name of the price type.', 'event_espresso') . '</p>';
91
+		return '<p>'.__('The name of the price type.', 'event_espresso').'</p>';
92 92
 	}
93 93
 
94 94
 	protected function _percentage_dollar_amount_stop() {
95
-		return '<p>' . __('Set a price type to be percentage-based or a fixed amount.', 'event_espresso') . '</p>';
95
+		return '<p>'.__('Set a price type to be percentage-based or a fixed amount.', 'event_espresso').'</p>';
96 96
 	}
97 97
 
98 98
 	protected function _order_of_application_stop() {
99
-		return '<p>' . __('Set the order of application for a price type.', 'event_espresso') . '</p>';
99
+		return '<p>'.__('Set the order of application for a price type.', 'event_espresso').'</p>';
100 100
 	}
101 101
 
102 102
 }
103 103
\ No newline at end of file
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,6 +1,7 @@
 block discarded – undo
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
Please login to merge, or discard this patch.
admin/new/pricing/help_tours/Pricing_Default_Prices_Help_Tour.class.php 2 patches
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
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
 /**
@@ -99,33 +99,33 @@  discard block
 block discarded – undo
99 99
 
100 100
 
101 101
 	protected function _start() {
102
-		$content = '<h3>' . __('Default Pricing', 'event_espresso') . '</h3>';
103
-		$content .= '<p>' . __('This tour of the Default Pricing page will go over different areas of the screen to help you understand what they are used for.', 'event_espresso') . '</p>';
102
+		$content = '<h3>'.__('Default Pricing', 'event_espresso').'</h3>';
103
+		$content .= '<p>'.__('This tour of the Default Pricing page will go over different areas of the screen to help you understand what they are used for.', 'event_espresso').'</p>';
104 104
 		return $content;
105 105
 	}
106 106
 
107 107
 	protected function _name_column_stop() {
108
-		return '<p>' . __('The name of the price, discount, tax, or surcharge that will be seen by your customers. Can be sorted in ascending or descending order.', 'event_espresso') . '</p>';
108
+		return '<p>'.__('The name of the price, discount, tax, or surcharge that will be seen by your customers. Can be sorted in ascending or descending order.', 'event_espresso').'</p>';
109 109
 	}
110 110
 
111 111
 	protected function _type_column_stop() {
112
-		return '<p>' . __('Price Types are a way of categorizing a price, discount, tax, or surcharge and indicating how it gets applied to a running total when a transaction occurs. Can be sorted in ascending or descending order.', 'event_espresso') . '</p>';
112
+		return '<p>'.__('Price Types are a way of categorizing a price, discount, tax, or surcharge and indicating how it gets applied to a running total when a transaction occurs. Can be sorted in ascending or descending order.', 'event_espresso').'</p>';
113 113
 	}
114 114
 
115 115
 	protected function _description_column_stop() {
116
-		return '<p>' . __('View the price type (price, discount, tax or surcharge) description.', 'event_espresso') . '</p>';
116
+		return '<p>'.__('View the price type (price, discount, tax or surcharge) description.', 'event_espresso').'</p>';
117 117
 	}
118 118
 
119 119
 	protected function _amount_column_stop() {
120
-		return '<p>' . __('The ticket amount before any deductions. Can be sorted in ascending or descending order.', 'event_espresso') . '</p>';
120
+		return '<p>'.__('The ticket amount before any deductions. Can be sorted in ascending or descending order.', 'event_espresso').'</p>';
121 121
 	}
122 122
 
123 123
 	protected function _bulk_actions_stop() {
124
-		return '<p>' . __('Perform bulk actions to multiple price types.', 'event_espresso') . '</p>';
124
+		return '<p>'.__('Perform bulk actions to multiple price types.', 'event_espresso').'</p>';
125 125
 	}
126 126
 
127 127
 	protected function _search_stop() {
128
-		return '<p>' . __('Search through default pricing. The following sources will be searched: Price Name, Price Type, Price Description, and Price Amount.', 'event_espresso') . '</p>';
128
+		return '<p>'.__('Search through default pricing. The following sources will be searched: Price Name, Price Type, Price Description, and Price Amount.', 'event_espresso').'</p>';
129 129
 	}
130 130
 
131 131
 }
132 132
\ No newline at end of file
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,6 +1,7 @@
 block discarded – undo
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
Please login to merge, or discard this patch.
admin/new/pricing/help_tours/Pricing_Edit_Default_Price_Help_Tour.class.php 2 patches
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
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
 /**
@@ -78,25 +78,25 @@  discard block
 block discarded – undo
78 78
 
79 79
 
80 80
 	protected function _start() {
81
-		$content = '<h3>' . __('Edit Default Price', 'event_espresso') . '</h3>';
82
-		$content .= '<p>' . __('This tour of the Edit Default Price page will go over different areas of the screen to help you understand what they are used for.', 'event_espresso') . '</p>';
81
+		$content = '<h3>'.__('Edit Default Price', 'event_espresso').'</h3>';
82
+		$content .= '<p>'.__('This tour of the Edit Default Price page will go over different areas of the screen to help you understand what they are used for.', 'event_espresso').'</p>';
83 83
 		return $content;
84 84
 	}
85 85
 
86 86
 	protected function _price_type_stop() {
87
-		return '<p>' . __('Price Types are a way of categorizing a price, discount, tax, or surcharge and indicating how it gets applied to a running total when a transaction occurs.', 'event_espresso') . '</p>';
87
+		return '<p>'.__('Price Types are a way of categorizing a price, discount, tax, or surcharge and indicating how it gets applied to a running total when a transaction occurs.', 'event_espresso').'</p>';
88 88
 	}
89 89
 
90 90
 	protected function _price_name_stop() {
91
-		return '<p>' . __('The name of the price, discount, tax, or surcharge that will be seen by your customers.', 'event_espresso') . '</p>';
91
+		return '<p>'.__('The name of the price, discount, tax, or surcharge that will be seen by your customers.', 'event_espresso').'</p>';
92 92
 	}
93 93
 
94 94
 	protected function _price_description_stop() {
95
-		return '<p>' . __('View the price type (price, discount, tax or surcharge) description.', 'event_espresso') . '</p>';
95
+		return '<p>'.__('View the price type (price, discount, tax or surcharge) description.', 'event_espresso').'</p>';
96 96
 	}
97 97
 
98 98
 	protected function _price_amount_stop() {
99
-		return '<p>' . __('The ticket amount before any deductions.', 'event_espresso') . '</p>';
99
+		return '<p>'.__('The ticket amount before any deductions.', 'event_espresso').'</p>';
100 100
 	}
101 101
 
102 102
 }
103 103
\ No newline at end of file
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,6 +1,7 @@
 block discarded – undo
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
Please login to merge, or discard this patch.
admin/new/pricing/help_tours/Pricing_Edit_Price_Type_Help_Tour.class.php 2 patches
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
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
 /**
@@ -78,25 +78,25 @@  discard block
 block discarded – undo
78 78
 
79 79
 
80 80
 	protected function _start() {
81
-		$content = '<h3>' . __('Edit Price Type', 'event_espresso') . '</h3>';
82
-		$content .= '<p>' . __('This tour of the Edit Price Type page will go over different areas of the screen to help you understand what they are used for.', 'event_espresso') . '</p>';
81
+		$content = '<h3>'.__('Edit Price Type', 'event_espresso').'</h3>';
82
+		$content .= '<p>'.__('This tour of the Edit Price Type page will go over different areas of the screen to help you understand what they are used for.', 'event_espresso').'</p>';
83 83
 		return $content;
84 84
 	}
85 85
 
86 86
 	protected function _basic_type_stop() {
87
-		return '<p>' . __('Set a price type to be a discount, surcharge, or tax.', 'event_espresso') . '</p>';
87
+		return '<p>'.__('Set a price type to be a discount, surcharge, or tax.', 'event_espresso').'</p>';
88 88
 	}
89 89
 
90 90
 	protected function _price_type_name_stop() {
91
-		return '<p>' . __('The name of the price type.', 'event_espresso') . '</p>';
91
+		return '<p>'.__('The name of the price type.', 'event_espresso').'</p>';
92 92
 	}
93 93
 
94 94
 	protected function _percentage_dollar_amount_stop() {
95
-		return '<p>' . __('Set a price type to be percentage-based or a fixed amount.', 'event_espresso') . '</p>';
95
+		return '<p>'.__('Set a price type to be percentage-based or a fixed amount.', 'event_espresso').'</p>';
96 96
 	}
97 97
 
98 98
 	protected function _order_of_application_stop() {
99
-		return '<p>' . __('Set the order of application for a price type.', 'event_espresso') . '</p>';
99
+		return '<p>'.__('Set the order of application for a price type.', 'event_espresso').'</p>';
100 100
 	}
101 101
 
102 102
 }
103 103
\ No newline at end of file
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,6 +1,7 @@
 block discarded – undo
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
Please login to merge, or discard this patch.
new/pricing/help_tours/Pricing_Price_Types_Default_Help_Tour.class.php 2 patches
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@  discard block
 block discarded – undo
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
 /**
@@ -99,37 +99,37 @@  discard block
 block discarded – undo
99 99
 
100 100
 
101 101
 	protected function _start() {
102
-		$content = '<h3>' . __('Price Types', 'event_espresso') . '</h3>';
103
-		$content .= '<p>' . __('This tour of the Price Types page will go over different areas of the screen to help you understand what they are used for.', 'event_espresso') . '</p>';
102
+		$content = '<h3>'.__('Price Types', 'event_espresso').'</h3>';
103
+		$content .= '<p>'.__('This tour of the Price Types page will go over different areas of the screen to help you understand what they are used for.', 'event_espresso').'</p>';
104 104
 		return $content;
105 105
 	}
106 106
 
107 107
 	protected function _name_column_stop() {
108
-		return '<p>' . __('The name of the price type. Can be sorted in ascending or descending order.', 'event_espresso') . '</p>';
108
+		return '<p>'.__('The name of the price type. Can be sorted in ascending or descending order.', 'event_espresso').'</p>';
109 109
 	}
110 110
 
111 111
 	protected function _base_type_stop() {
112
-		return '<p>' . __('View if a price type is a discount, surcharge, or tax.', 'event_espresso') . '</p>';
112
+		return '<p>'.__('View if a price type is a discount, surcharge, or tax.', 'event_espresso').'</p>';
113 113
 	}
114 114
 
115 115
 	protected function _member_column_stop() {
116
-		return '<p>' . __('Here you can see if the discount/surcharge is percentage based or a flat monetary amount.', 'event_espresso') . '</p>';
116
+		return '<p>'.__('Here you can see if the discount/surcharge is percentage based or a flat monetary amount.', 'event_espresso').'</p>';
117 117
 	}
118 118
 
119 119
 	protected function _percent_column_stop() {
120
-		return '<p>' . __('View if the discount, surcharge, or tax is percentage-based or a fixed amount.', 'event_espresso') . '</p>';
120
+		return '<p>'.__('View if the discount, surcharge, or tax is percentage-based or a fixed amount.', 'event_espresso').'</p>';
121 121
 	}
122 122
 
123 123
 	protected function _order_column_stop() {
124
-		return '<p>' . __('View the order in which each discount, surcharge, or tax will be applied to the base ticket cost. Zero (0) means it will be applied first.', 'event_espresso') . '</p>';
124
+		return '<p>'.__('View the order in which each discount, surcharge, or tax will be applied to the base ticket cost. Zero (0) means it will be applied first.', 'event_espresso').'</p>';
125 125
 	}
126 126
 
127 127
 	protected function _bulk_actions_stop() {
128
-		return '<p>' . __('Perform bulk actions to multiple price types.', 'event_espresso') . '</p>';
128
+		return '<p>'.__('Perform bulk actions to multiple price types.', 'event_espresso').'</p>';
129 129
 	}
130 130
 
131 131
 	protected function _search_stop() {
132
-		return '<p>' . __('Search through price types. The following source will be searched: Price Type Name.', 'event_espresso') . '</p>';
132
+		return '<p>'.__('Search through price types. The following source will be searched: Price Type Name.', 'event_espresso').'</p>';
133 133
 	}
134 134
 
135 135
 }
136 136
\ No newline at end of file
Please login to merge, or discard this patch.
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,6 +1,7 @@
 block discarded – undo
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
Please login to merge, or discard this patch.
templates/event_tickets_datetime_price_modifier_selector.template.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -1,5 +1,5 @@
 block discarded – undo
1 1
 <?php echo $price_modifier_selector; ?>
2
-<?php if ( $disabled ) : ?>
2
+<?php if ($disabled) : ?>
3 3
 	<input type="hidden" name="<?php echo $main_name; ?>" value="<?php echo $selected_price_type_id; ?>">
4 4
 <?php endif; ?>
5 5
 
Please login to merge, or discard this patch.