Completed
Branch yet-another-batch-of-ui-fixes (371f49)
by
unknown
30:27 queued 22:46
created
modules/gateways/Invoice/lib/invoice_functions.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -15,7 +15,7 @@  discard block
 block discarded – undo
15 15
 {
16 16
     $files = [];
17 17
     // read our template dir and build an array of files
18
-    $directory_handle = opendir(dirname($class_file) . '/lib/templates/css/');
18
+    $directory_handle = opendir(dirname($class_file).'/lib/templates/css/');
19 19
     //if we managed to open the directory
20 20
     if ($directory_handle) {
21 21
         /** @var RequestInterface $request */
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
         while (false !== ($fname = readdir($directory_handle))) {
35 35
             // if the file is not this file, and does not start with a '.' or '..',
36 36
             // then store it for later display
37
-            if (! in_array($fname, $skip, true)) {
37
+            if ( ! in_array($fname, $skip, true)) {
38 38
                 $files[] = $fname;
39 39
             }
40 40
         }
Please login to merge, or discard this patch.
Indentation   +33 added lines, -33 removed lines patch added patch discarded remove patch
@@ -13,36 +13,36 @@  discard block
 block discarded – undo
13 13
  */
14 14
 function espresso_invoice_template_files($class_file)
15 15
 {
16
-    $files = [];
17
-    // read our template dir and build an array of files
18
-    $directory_handle = opendir(dirname($class_file) . '/lib/templates/css/');
19
-    //if we managed to open the directory
20
-    if ($directory_handle) {
21
-        /** @var RequestInterface $request */
22
-        $request = LoaderFactory::getLoader()->getShared(RequestInterface::class);
23
-        $skip = [
24
-            '.',
25
-            '..',
26
-            '.DS_Store',
27
-            '.svn',
28
-            'images',
29
-            'index.php',
30
-            'print',
31
-            basename($request->getServerParam('PHP_SELF')),
32
-        ];
33
-        // loop through all of the files
34
-        while (false !== ($fname = readdir($directory_handle))) {
35
-            // if the file is not this file, and does not start with a '.' or '..',
36
-            // then store it for later display
37
-            if (! in_array($fname, $skip, true)) {
38
-                $files[] = $fname;
39
-            }
40
-        }
41
-        // close the directory
42
-        closedir($directory_handle);
43
-    }
16
+	$files = [];
17
+	// read our template dir and build an array of files
18
+	$directory_handle = opendir(dirname($class_file) . '/lib/templates/css/');
19
+	//if we managed to open the directory
20
+	if ($directory_handle) {
21
+		/** @var RequestInterface $request */
22
+		$request = LoaderFactory::getLoader()->getShared(RequestInterface::class);
23
+		$skip = [
24
+			'.',
25
+			'..',
26
+			'.DS_Store',
27
+			'.svn',
28
+			'images',
29
+			'index.php',
30
+			'print',
31
+			basename($request->getServerParam('PHP_SELF')),
32
+		];
33
+		// loop through all of the files
34
+		while (false !== ($fname = readdir($directory_handle))) {
35
+			// if the file is not this file, and does not start with a '.' or '..',
36
+			// then store it for later display
37
+			if (! in_array($fname, $skip, true)) {
38
+				$files[] = $fname;
39
+			}
40
+		}
41
+		// close the directory
42
+		closedir($directory_handle);
43
+	}
44 44
 
45
-    return $files;
45
+	return $files;
46 46
 }
47 47
 
48 48
 
@@ -56,8 +56,8 @@  discard block
 block discarded – undo
56 56
  */
57 57
 function espresso_invoice_is_selected($input_item, $selected = '')
58 58
 {
59
-    if ($input_item === $selected) {
60
-        return 'selected';
61
-    }
62
-    return '';
59
+	if ($input_item === $selected) {
60
+		return 'selected';
61
+	}
62
+	return '';
63 63
 }
64 64
\ No newline at end of file
Please login to merge, or discard this patch.
core/data_migration_scripts/EE_DMS_Core_4_12_0.dms.php 2 patches
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -7,12 +7,12 @@  discard block
 block discarded – undo
7 7
 // unfortunately, this needs to be done upon INCLUSION of this file,
8 8
 // instead of construction, because it only gets constructed on first page load
9 9
 // (all other times it gets resurrected from a wordpress option)
10
-$stages            = glob(EE_CORE . 'data_migration_scripts/4_12_0_stages/*');
10
+$stages            = glob(EE_CORE.'data_migration_scripts/4_12_0_stages/*');
11 11
 $class_to_filepath = [];
12 12
 foreach ($stages as $filepath) {
13 13
     $matches = [];
14 14
     preg_match('~4_12_0_stages/(.*).dmsstage.php~', $filepath, $matches);
15
-    $class_to_filepath[ $matches[1] ] = $filepath;
15
+    $class_to_filepath[$matches[1]] = $filepath;
16 16
 }
17 17
 // give addons a chance to autoload their stages too
18 18
 $class_to_filepath = apply_filters('FHEE__EE_DMS_4_12_0__autoloaded_stages', $class_to_filepath);
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
      */
72 72
     public function schema_changes_before_migration(): bool
73 73
     {
74
-        require_once EE_HELPERS . 'EEH_Activation.helper.php';
74
+        require_once EE_HELPERS.'EEH_Activation.helper.php';
75 75
 
76 76
         $table_name = 'esp_answer';
77 77
         $sql        = " ANS_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
Please login to merge, or discard this patch.
Indentation   +180 added lines, -180 removed lines patch added patch discarded remove patch
@@ -10,9 +10,9 @@  discard block
 block discarded – undo
10 10
 $stages            = glob(EE_CORE . 'data_migration_scripts/4_12_0_stages/*');
11 11
 $class_to_filepath = [];
12 12
 foreach ($stages as $filepath) {
13
-    $matches = [];
14
-    preg_match('~4_12_0_stages/(.*).dmsstage.php~', $filepath, $matches);
15
-    $class_to_filepath[ $matches[1] ] = $filepath;
13
+	$matches = [];
14
+	preg_match('~4_12_0_stages/(.*).dmsstage.php~', $filepath, $matches);
15
+	$class_to_filepath[ $matches[1] ] = $filepath;
16 16
 }
17 17
 // give addons a chance to autoload their stages too
18 18
 $class_to_filepath = apply_filters('FHEE__EE_DMS_4_12_0__autoloaded_stages', $class_to_filepath);
@@ -28,63 +28,63 @@  discard block
 block discarded – undo
28 28
  */
29 29
 class EE_DMS_Core_4_12_0 extends EE_Data_Migration_Script_Base
30 30
 {
31
-    /**
32
-     *
33
-     * @param EE_DMS_Core_4_11_0 $dms_4_11
34
-     * @param TableManager|null  $table_manager
35
-     * @param TableAnalysis|null $table_analysis
36
-     */
37
-    public function __construct(
38
-        EE_DMS_Core_4_11_0 $dms_4_11,
39
-        TableManager $table_manager = null,
40
-        TableAnalysis $table_analysis = null
41
-    ) {
42
-        $this->previous_dms      = $dms_4_11;
43
-        $this->_pretty_name      = esc_html__("Data Update to Event Espresso 4.12.0", "event_espresso");
44
-        $this->_priority         = 10;
45
-        $this->_migration_stages = [
46
-            new EE_DMS_4_12_0_Event_Venues(),
47
-        ];
48
-        parent::__construct($table_manager, $table_analysis);
49
-    }
50
-
51
-
52
-    /**
53
-     * Whether to migrate or not.
54
-     *
55
-     * @param array $version_array
56
-     * @return bool
57
-     */
58
-    public function can_migrate_from_version($version_array): bool
59
-    {
60
-        $version_string = $version_array['Core'];
61
-        return $version_string
62
-               && version_compare($version_string, '4.12.0.decaf', '<')
63
-               && version_compare($version_string, '4.11.0.decaf', '>=');
64
-    }
65
-
66
-
67
-    /**
68
-     * @return bool
69
-     * @throws EE_Error
70
-     * @throws ReflectionException
71
-     */
72
-    public function schema_changes_before_migration(): bool
73
-    {
74
-        require_once EE_HELPERS . 'EEH_Activation.helper.php';
75
-
76
-        $table_name = 'esp_answer';
77
-        $sql        = " ANS_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
31
+	/**
32
+	 *
33
+	 * @param EE_DMS_Core_4_11_0 $dms_4_11
34
+	 * @param TableManager|null  $table_manager
35
+	 * @param TableAnalysis|null $table_analysis
36
+	 */
37
+	public function __construct(
38
+		EE_DMS_Core_4_11_0 $dms_4_11,
39
+		TableManager $table_manager = null,
40
+		TableAnalysis $table_analysis = null
41
+	) {
42
+		$this->previous_dms      = $dms_4_11;
43
+		$this->_pretty_name      = esc_html__("Data Update to Event Espresso 4.12.0", "event_espresso");
44
+		$this->_priority         = 10;
45
+		$this->_migration_stages = [
46
+			new EE_DMS_4_12_0_Event_Venues(),
47
+		];
48
+		parent::__construct($table_manager, $table_analysis);
49
+	}
50
+
51
+
52
+	/**
53
+	 * Whether to migrate or not.
54
+	 *
55
+	 * @param array $version_array
56
+	 * @return bool
57
+	 */
58
+	public function can_migrate_from_version($version_array): bool
59
+	{
60
+		$version_string = $version_array['Core'];
61
+		return $version_string
62
+			   && version_compare($version_string, '4.12.0.decaf', '<')
63
+			   && version_compare($version_string, '4.11.0.decaf', '>=');
64
+	}
65
+
66
+
67
+	/**
68
+	 * @return bool
69
+	 * @throws EE_Error
70
+	 * @throws ReflectionException
71
+	 */
72
+	public function schema_changes_before_migration(): bool
73
+	{
74
+		require_once EE_HELPERS . 'EEH_Activation.helper.php';
75
+
76
+		$table_name = 'esp_answer';
77
+		$sql        = " ANS_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
78 78
 					REG_ID int(10) unsigned NOT NULL,
79 79
 					QST_ID int(10) unsigned NOT NULL,
80 80
 					ANS_value text NOT NULL,
81 81
 					PRIMARY KEY  (ANS_ID),
82 82
 					KEY REG_ID (REG_ID),
83 83
 					KEY QST_ID (QST_ID)";
84
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
84
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
85 85
 
86
-        $table_name = 'esp_attendee_meta';
87
-        $sql        = "ATTM_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
86
+		$table_name = 'esp_attendee_meta';
87
+		$sql        = "ATTM_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
88 88
 				ATT_ID bigint(20) unsigned NOT NULL,
89 89
 				ATT_fname varchar(45) NOT NULL,
90 90
 				ATT_lname varchar(45) NOT NULL,
@@ -101,10 +101,10 @@  discard block
 block discarded – undo
101 101
 				KEY ATT_email (ATT_email(191)),
102 102
 				KEY ATT_lname (ATT_lname),
103 103
 				KEY ATT_fname (ATT_fname)";
104
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB ');
104
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB ');
105 105
 
106
-        $table_name = 'esp_checkin';
107
-        $sql        = "CHK_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
106
+		$table_name = 'esp_checkin';
107
+		$sql        = "CHK_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
108 108
 				REG_ID int(10) unsigned NOT NULL,
109 109
 				DTT_ID int(10) unsigned NOT NULL,
110 110
 				CHK_in tinyint(1) unsigned NOT NULL DEFAULT 1,
@@ -112,10 +112,10 @@  discard block
 block discarded – undo
112 112
 				PRIMARY KEY  (CHK_ID),
113 113
 				KEY REG_ID (REG_ID),
114 114
 				KEY DTT_ID (DTT_ID)";
115
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
115
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
116 116
 
117
-        $table_name = 'esp_country';
118
-        $sql        = "CNT_ISO varchar(2) NOT NULL,
117
+		$table_name = 'esp_country';
118
+		$sql        = "CNT_ISO varchar(2) NOT NULL,
119 119
 				CNT_ISO3 varchar(3) NOT NULL,
120 120
 				RGN_ID tinyint(3) unsigned DEFAULT NULL,
121 121
 				CNT_name varchar(45) NOT NULL,
@@ -131,32 +131,32 @@  discard block
 block discarded – undo
131 131
 				CNT_is_EU tinyint(1) DEFAULT '0',
132 132
 				CNT_active tinyint(1) DEFAULT '0',
133 133
 				PRIMARY KEY  (CNT_ISO)";
134
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
134
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
135 135
 
136
-        $table_name = 'esp_currency';
137
-        $sql        = "CUR_code varchar(6) NOT NULL,
136
+		$table_name = 'esp_currency';
137
+		$sql        = "CUR_code varchar(6) NOT NULL,
138 138
 				CUR_single varchar(45) DEFAULT 'dollar',
139 139
 				CUR_plural varchar(45) DEFAULT 'dollars',
140 140
 				CUR_sign varchar(45) DEFAULT '$',
141 141
 				CUR_dec_plc varchar(1) NOT NULL DEFAULT '2',
142 142
 				CUR_active tinyint(1) DEFAULT '0',
143 143
 				PRIMARY KEY  (CUR_code)";
144
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
145
-
146
-        // note: although this table is no longer in use,
147
-        // it hasn't been removed because then queries to the model will have errors.
148
-        // but you should expect this table and its corresponding model to be removed in
149
-        // the next few months
150
-        $table_name = 'esp_currency_payment_method';
151
-        $sql        = "CPM_ID int(11) NOT NULL AUTO_INCREMENT,
144
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
145
+
146
+		// note: although this table is no longer in use,
147
+		// it hasn't been removed because then queries to the model will have errors.
148
+		// but you should expect this table and its corresponding model to be removed in
149
+		// the next few months
150
+		$table_name = 'esp_currency_payment_method';
151
+		$sql        = "CPM_ID int(11) NOT NULL AUTO_INCREMENT,
152 152
 				CUR_code varchar(6) NOT NULL,
153 153
 				PMD_ID int(11) NOT NULL,
154 154
 				PRIMARY KEY  (CPM_ID),
155 155
 				KEY PMD_ID (PMD_ID)";
156
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB ');
156
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB ');
157 157
 
158
-        $table_name = 'esp_datetime';
159
-        $sql        = "DTT_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
158
+		$table_name = 'esp_datetime';
159
+		$sql        = "DTT_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
160 160
 				EVT_ID bigint(20) unsigned NOT NULL,
161 161
 			    VNU_ID bigint(20) unsigned NOT NULL DEFAULT 0,
162 162
 				DTT_name varchar(255) NOT NULL DEFAULT '',
@@ -174,28 +174,28 @@  discard block
 block discarded – undo
174 174
 				KEY DTT_EVT_start (DTT_EVT_start),
175 175
 				KEY EVT_ID (EVT_ID),
176 176
 				KEY DTT_is_primary (DTT_is_primary)";
177
-        $this->_table_is_changed_in_this_version($table_name, $sql, 'ENGINE=InnoDB');
177
+		$this->_table_is_changed_in_this_version($table_name, $sql, 'ENGINE=InnoDB');
178 178
 
179
-        $table_name = "esp_datetime_ticket";
180
-        $sql        = "DTK_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
179
+		$table_name = "esp_datetime_ticket";
180
+		$sql        = "DTK_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
181 181
 				DTT_ID int(10) unsigned NOT NULL,
182 182
 				TKT_ID int(10) unsigned NOT NULL,
183 183
 				PRIMARY KEY  (DTK_ID),
184 184
 				KEY DTT_ID (DTT_ID),
185 185
 				KEY TKT_ID (TKT_ID)";
186
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
186
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
187 187
 
188
-        $table_name = 'esp_event_message_template';
189
-        $sql        = "EMT_ID bigint(20) unsigned NOT NULL AUTO_INCREMENT,
188
+		$table_name = 'esp_event_message_template';
189
+		$sql        = "EMT_ID bigint(20) unsigned NOT NULL AUTO_INCREMENT,
190 190
 				EVT_ID bigint(20) unsigned NOT NULL DEFAULT 0,
191 191
 				GRP_ID int(10) unsigned NOT NULL DEFAULT 0,
192 192
 				PRIMARY KEY  (EMT_ID),
193 193
 				KEY EVT_ID (EVT_ID),
194 194
 				KEY GRP_ID (GRP_ID)";
195
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
195
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
196 196
 
197
-        $table_name = 'esp_event_meta';
198
-        $sql        = "EVTM_ID int(10) NOT NULL AUTO_INCREMENT,
197
+		$table_name = 'esp_event_meta';
198
+		$sql        = "EVTM_ID int(10) NOT NULL AUTO_INCREMENT,
199 199
 				EVT_ID bigint(20) unsigned NOT NULL,
200 200
 			    VNU_ID bigint(20) unsigned NOT NULL DEFAULT 0,
201 201
 				EVT_display_desc tinyint(1) unsigned NOT NULL DEFAULT 1,
@@ -212,10 +212,10 @@  discard block
 block discarded – undo
212 212
 				FSC_UUID varchar(25) DEFAULT NULL,
213 213
 				PRIMARY KEY  (EVTM_ID),
214 214
 				KEY EVT_ID (EVT_ID)";
215
-        $this->_table_is_changed_in_this_version($table_name, $sql, 'ENGINE=InnoDB');
215
+		$this->_table_is_changed_in_this_version($table_name, $sql, 'ENGINE=InnoDB');
216 216
 
217
-        $table_name = 'esp_event_question_group';
218
-        $sql        = "EQG_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
217
+		$table_name = 'esp_event_question_group';
218
+		$sql        = "EQG_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
219 219
 				EVT_ID bigint(20) unsigned NOT NULL,
220 220
 				QSG_ID int(10) unsigned NOT NULL,
221 221
 				EQG_primary tinyint(1) unsigned NOT NULL DEFAULT 0,
@@ -223,28 +223,28 @@  discard block
 block discarded – undo
223 223
 				PRIMARY KEY  (EQG_ID),
224 224
 				KEY EVT_ID (EVT_ID),
225 225
 				KEY QSG_ID (QSG_ID)";
226
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
226
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
227 227
 
228
-        $table_name = 'esp_event_venue';
229
-        $sql        = "EVV_ID int(11) NOT NULL AUTO_INCREMENT,
228
+		$table_name = 'esp_event_venue';
229
+		$sql        = "EVV_ID int(11) NOT NULL AUTO_INCREMENT,
230 230
 				EVT_ID bigint(20) unsigned NOT NULL,
231 231
 				VNU_ID bigint(20) unsigned NOT NULL,
232 232
 				EVV_primary tinyint(1) unsigned NOT NULL DEFAULT 0,
233 233
 				PRIMARY KEY  (EVV_ID)";
234
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
234
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
235 235
 
236
-        $table_name = 'esp_extra_meta';
237
-        $sql        = "EXM_ID int(11) NOT NULL AUTO_INCREMENT,
236
+		$table_name = 'esp_extra_meta';
237
+		$sql        = "EXM_ID int(11) NOT NULL AUTO_INCREMENT,
238 238
 				OBJ_ID int(11) DEFAULT NULL,
239 239
 				EXM_type varchar(45) DEFAULT NULL,
240 240
 				EXM_key varchar(45) DEFAULT NULL,
241 241
 				EXM_value text,
242 242
 				PRIMARY KEY  (EXM_ID),
243 243
 				KEY EXM_type (EXM_type,OBJ_ID,EXM_key)";
244
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
244
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
245 245
 
246
-        $table_name = 'esp_extra_join';
247
-        $sql        = "EXJ_ID int(11) NOT NULL AUTO_INCREMENT,
246
+		$table_name = 'esp_extra_join';
247
+		$sql        = "EXJ_ID int(11) NOT NULL AUTO_INCREMENT,
248 248
 				EXJ_first_model_id varchar(6) NOT NULL,
249 249
 				EXJ_first_model_name varchar(20) NOT NULL,
250 250
 				EXJ_second_model_id varchar(6) NOT NULL,
@@ -252,10 +252,10 @@  discard block
 block discarded – undo
252 252
 				PRIMARY KEY  (EXJ_ID),
253 253
 				KEY first_model (EXJ_first_model_name,EXJ_first_model_id),
254 254
 				KEY second_model (EXJ_second_model_name,EXJ_second_model_id)";
255
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB ');
255
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB ');
256 256
 
257
-        $table_name = 'esp_form_element';
258
-        $sql        = "FIN_UUID varchar(25) NOT NULL,
257
+		$table_name = 'esp_form_element';
258
+		$sql        = "FIN_UUID varchar(25) NOT NULL,
259 259
 				FSC_UUID varchar(25) NOT NULL,
260 260
 				FIN_adminOnly tinyint(1) unsigned NOT NULL DEFAULT 0,
261 261
 				FIN_attributes text DEFAULT NULL,
@@ -272,10 +272,10 @@  discard block
 block discarded – undo
272 272
 				KEY FSC_UUID (FSC_UUID),
273 273
 				KEY FIN_order (FIN_order),
274 274
 				KEY FIN_status (FIN_status)";
275
-        $this->_table_is_new_in_this_version($table_name, $sql, 'ENGINE=InnoDB');
275
+		$this->_table_is_new_in_this_version($table_name, $sql, 'ENGINE=InnoDB');
276 276
 
277
-        $table_name = 'esp_form_section';
278
-        $sql        = "FSC_UUID varchar(25) NOT NULL,
277
+		$table_name = 'esp_form_section';
278
+		$sql        = "FSC_UUID varchar(25) NOT NULL,
279 279
 				FSC_appliesTo tinytext NOT NULL,
280 280
 				FSC_attributes text DEFAULT NULL,
281 281
 				FSC_belongsTo varchar(25) DEFAULT NULL,
@@ -287,10 +287,10 @@  discard block
 block discarded – undo
287 287
 				KEY FSC_belongsTo (FSC_belongsTo),
288 288
 				KEY FSC_order (FSC_order),
289 289
 				KEY FSC_status (FSC_status)";
290
-        $this->_table_is_new_in_this_version($table_name, $sql, 'ENGINE=InnoDB');
290
+		$this->_table_is_new_in_this_version($table_name, $sql, 'ENGINE=InnoDB');
291 291
 
292
-        $table_name = 'esp_form_submission';
293
-        $sql        = "FSB_UUID varchar(25) NOT NULL,
292
+		$table_name = 'esp_form_submission';
293
+		$sql        = "FSB_UUID varchar(25) NOT NULL,
294 294
                 FSC_UUID varchar(25) NOT NULL,
295 295
 				TXN_ID int(10) DEFAULT NULL,
296 296
 				FSB_data mediumtext DEFAULT NULL,
@@ -298,10 +298,10 @@  discard block
 block discarded – undo
298 298
 				PRIMARY KEY  (FSB_UUID),
299 299
 				KEY FSC_UUID (FSC_UUID),
300 300
 				KEY TXN_ID (TXN_ID)";
301
-        $this->_table_is_new_in_this_version($table_name, $sql, 'ENGINE=InnoDB');
301
+		$this->_table_is_new_in_this_version($table_name, $sql, 'ENGINE=InnoDB');
302 302
 
303
-        $table_name   = 'esp_line_item';
304
-        $sql          = "LIN_ID int(11) NOT NULL AUTO_INCREMENT,
303
+		$table_name   = 'esp_line_item';
304
+		$sql          = "LIN_ID int(11) NOT NULL AUTO_INCREMENT,
305 305
 				LIN_code varchar(245) NOT NULL DEFAULT '',
306 306
 				TXN_ID int(10) DEFAULT NULL,
307 307
 				LIN_name varchar(245) NOT NULL DEFAULT '',
@@ -323,10 +323,10 @@  discard block
 block discarded – undo
323 323
 				KEY txn_type_timestamp (TXN_ID,LIN_type,LIN_timestamp),
324 324
 				KEY txn_obj_id_obj_type (TXN_ID,OBJ_ID,OBJ_type),
325 325
 				KEY obj_id_obj_type (OBJ_ID,OBJ_type)";
326
-        $this->_table_is_changed_in_this_version($table_name, $sql, 'ENGINE=InnoDB');
326
+		$this->_table_is_changed_in_this_version($table_name, $sql, 'ENGINE=InnoDB');
327 327
 
328
-        $table_name = 'esp_log';
329
-        $sql        = "LOG_ID int(11) NOT NULL AUTO_INCREMENT,
328
+		$table_name = 'esp_log';
329
+		$sql        = "LOG_ID int(11) NOT NULL AUTO_INCREMENT,
330 330
 				LOG_time datetime DEFAULT NULL,
331 331
 				OBJ_ID varchar(45) DEFAULT NULL,
332 332
 				OBJ_type varchar(45) DEFAULT NULL,
@@ -337,10 +337,10 @@  discard block
 block discarded – undo
337 337
 				KEY LOG_time (LOG_time),
338 338
 				KEY OBJ (OBJ_type,OBJ_ID),
339 339
 				KEY LOG_type (LOG_type)";
340
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
340
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
341 341
 
342
-        $table_name = 'esp_message';
343
-        $sql        = "MSG_ID bigint(20) unsigned NOT NULL AUTO_INCREMENT,
342
+		$table_name = 'esp_message';
343
+		$sql        = "MSG_ID bigint(20) unsigned NOT NULL AUTO_INCREMENT,
344 344
 				GRP_ID int(10) unsigned NULL,
345 345
 				MSG_token varchar(255) NULL,
346 346
 				TXN_ID int(10) unsigned NULL,
@@ -372,20 +372,20 @@  discard block
 block discarded – undo
372 372
 				KEY STS_ID (STS_ID),
373 373
 				KEY MSG_created (MSG_created),
374 374
 				KEY MSG_modified (MSG_modified)";
375
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
375
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
376 376
 
377
-        $table_name = 'esp_message_template';
378
-        $sql        = "MTP_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
377
+		$table_name = 'esp_message_template';
378
+		$sql        = "MTP_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
379 379
 				GRP_ID int(10) unsigned NOT NULL,
380 380
 				MTP_context varchar(50) NOT NULL,
381 381
 				MTP_template_field varchar(30) NOT NULL,
382 382
 				MTP_content text NOT NULL,
383 383
 				PRIMARY KEY  (MTP_ID),
384 384
 				KEY GRP_ID (GRP_ID)";
385
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
385
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
386 386
 
387
-        $table_name = 'esp_message_template_group';
388
-        $sql        = "GRP_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
387
+		$table_name = 'esp_message_template_group';
388
+		$sql        = "GRP_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
389 389
 				MTP_user_id int(10) NOT NULL DEFAULT '1',
390 390
 				MTP_name varchar(245) NOT NULL DEFAULT '',
391 391
 				MTP_description varchar(245) NOT NULL DEFAULT '',
@@ -397,10 +397,10 @@  discard block
 block discarded – undo
397 397
 				MTP_is_active tinyint(1) NOT NULL DEFAULT '1',
398 398
 				PRIMARY KEY  (GRP_ID),
399 399
 				KEY MTP_user_id (MTP_user_id)";
400
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
400
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
401 401
 
402
-        $table_name = 'esp_payment';
403
-        $sql        = "PAY_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
402
+		$table_name = 'esp_payment';
403
+		$sql        = "PAY_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
404 404
 				TXN_ID int(10) unsigned DEFAULT NULL,
405 405
 				STS_ID varchar(3) DEFAULT NULL,
406 406
 				PAY_timestamp datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
@@ -417,10 +417,10 @@  discard block
 block discarded – undo
417 417
 				PRIMARY KEY  (PAY_ID),
418 418
 				KEY PAY_timestamp (PAY_timestamp),
419 419
 				KEY TXN_ID (TXN_ID)";
420
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB ');
420
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB ');
421 421
 
422
-        $table_name = 'esp_payment_method';
423
-        $sql        = "PMD_ID int(11) NOT NULL AUTO_INCREMENT,
422
+		$table_name = 'esp_payment_method';
423
+		$sql        = "PMD_ID int(11) NOT NULL AUTO_INCREMENT,
424 424
 				PMD_type varchar(124) DEFAULT NULL,
425 425
 				PMD_name varchar(255) DEFAULT NULL,
426 426
 				PMD_desc text,
@@ -436,10 +436,10 @@  discard block
 block discarded – undo
436 436
 				PRIMARY KEY  (PMD_ID),
437 437
 				UNIQUE KEY PMD_slug_UNIQUE (PMD_slug),
438 438
 				KEY PMD_type (PMD_type)";
439
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB ');
439
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB ');
440 440
 
441
-        $table_name = "esp_price";
442
-        $sql        = "PRC_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
441
+		$table_name = "esp_price";
442
+		$sql        = "PRC_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
443 443
 				PRT_ID tinyint(3) unsigned NOT NULL,
444 444
 				PRC_amount decimal(12,6) NOT NULL DEFAULT '0.00',
445 445
 				PRC_name varchar(245) NOT NULL,
@@ -452,10 +452,10 @@  discard block
 block discarded – undo
452 452
 				PRC_parent int(10) unsigned DEFAULT 0,
453 453
 				PRIMARY KEY  (PRC_ID),
454 454
 				KEY PRT_ID (PRT_ID)";
455
-        $this->_table_is_changed_in_this_version($table_name, $sql, 'ENGINE=InnoDB');
455
+		$this->_table_is_changed_in_this_version($table_name, $sql, 'ENGINE=InnoDB');
456 456
 
457
-        $table_name = "esp_price_type";
458
-        $sql        = "PRT_ID tinyint(3) unsigned NOT NULL AUTO_INCREMENT,
457
+		$table_name = "esp_price_type";
458
+		$sql        = "PRT_ID tinyint(3) unsigned NOT NULL AUTO_INCREMENT,
459 459
 				PRT_name varchar(45) NOT NULL,
460 460
 				PBT_ID tinyint(3) unsigned NOT NULL DEFAULT '1',
461 461
 				PRT_is_percent tinyint(1) NOT NULL DEFAULT '0',
@@ -464,27 +464,27 @@  discard block
 block discarded – undo
464 464
 				PRT_deleted tinyint(1) NOT NULL DEFAULT '0',
465 465
 				UNIQUE KEY PRT_name_UNIQUE (PRT_name),
466 466
 				PRIMARY KEY  (PRT_ID)";
467
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB ');
467
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB ');
468 468
 
469
-        $table_name = "esp_ticket_price";
470
-        $sql        = "TKP_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
469
+		$table_name = "esp_ticket_price";
470
+		$sql        = "TKP_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
471 471
 				TKT_ID int(10) unsigned NOT NULL,
472 472
 				PRC_ID int(10) unsigned NOT NULL,
473 473
 				PRIMARY KEY  (TKP_ID),
474 474
 				KEY TKT_ID (TKT_ID),
475 475
 				KEY PRC_ID (PRC_ID)";
476
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
476
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
477 477
 
478
-        $table_name = "esp_ticket_template";
479
-        $sql        = "TTM_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
478
+		$table_name = "esp_ticket_template";
479
+		$sql        = "TTM_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
480 480
 				TTM_name varchar(45) NOT NULL,
481 481
 				TTM_description text,
482 482
 				TTM_file varchar(45),
483 483
 				PRIMARY KEY  (TTM_ID)";
484
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
484
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
485 485
 
486
-        $table_name = 'esp_question';
487
-        $sql        = 'QST_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
486
+		$table_name = 'esp_question';
487
+		$sql        = 'QST_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
488 488
 				QST_display_text text NOT NULL,
489 489
 				QST_admin_label varchar(255) NOT NULL,
490 490
 				QST_system varchar(25) DEFAULT NULL,
@@ -498,10 +498,10 @@  discard block
 block discarded – undo
498 498
 				QST_deleted tinyint(2) unsigned NOT NULL DEFAULT 0,
499 499
 				PRIMARY KEY  (QST_ID),
500 500
 				KEY QST_order (QST_order)';
501
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
501
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
502 502
 
503
-        $table_name = 'esp_question_group';
504
-        $sql        = 'QSG_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
503
+		$table_name = 'esp_question_group';
504
+		$sql        = 'QSG_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
505 505
 				QSG_name varchar(255) NOT NULL,
506 506
 				QSG_identifier varchar(100) NOT NULL,
507 507
 				QSG_desc text NULL,
@@ -514,20 +514,20 @@  discard block
 block discarded – undo
514 514
 				PRIMARY KEY  (QSG_ID),
515 515
 				UNIQUE KEY QSG_identifier_UNIQUE (QSG_identifier),
516 516
 				KEY QSG_order (QSG_order)';
517
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
517
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
518 518
 
519
-        $table_name = 'esp_question_group_question';
520
-        $sql        = "QGQ_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
519
+		$table_name = 'esp_question_group_question';
520
+		$sql        = "QGQ_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
521 521
 				QSG_ID int(10) unsigned NOT NULL,
522 522
 				QST_ID int(10) unsigned NOT NULL,
523 523
 				QGQ_order int(10) unsigned NOT NULL DEFAULT 0,
524 524
 				PRIMARY KEY  (QGQ_ID),
525 525
 				KEY QST_ID (QST_ID),
526 526
 				KEY QSG_ID_order (QSG_ID,QGQ_order)";
527
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
527
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
528 528
 
529
-        $table_name = 'esp_question_option';
530
-        $sql        = "QSO_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
529
+		$table_name = 'esp_question_option';
530
+		$sql        = "QSO_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
531 531
 				QSO_value varchar(255) NOT NULL,
532 532
 				QSO_desc text NOT NULL,
533 533
 				QST_ID int(10) unsigned NOT NULL,
@@ -537,10 +537,10 @@  discard block
 block discarded – undo
537 537
 				PRIMARY KEY  (QSO_ID),
538 538
 				KEY QST_ID (QST_ID),
539 539
 				KEY QSO_order (QSO_order)";
540
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
540
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
541 541
 
542
-        $table_name = 'esp_registration';
543
-        $sql        = "REG_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
542
+		$table_name = 'esp_registration';
543
+		$sql        = "REG_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
544 544
 				EVT_ID bigint(20) unsigned NOT NULL,
545 545
 				ATT_ID bigint(20) unsigned NOT NULL,
546 546
 				TXN_ID int(10) unsigned NOT NULL,
@@ -564,20 +564,20 @@  discard block
 block discarded – undo
564 564
 				KEY TKT_ID (TKT_ID),
565 565
 				KEY EVT_ID (EVT_ID),
566 566
 				KEY STS_ID (STS_ID)";
567
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB ');
567
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB ');
568 568
 
569
-        $table_name = 'esp_registration_payment';
570
-        $sql        = "RPY_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
569
+		$table_name = 'esp_registration_payment';
570
+		$sql        = "RPY_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
571 571
 					  REG_ID int(10) unsigned NOT NULL,
572 572
 					  PAY_ID int(10) unsigned NULL,
573 573
 					  RPY_amount decimal(12,3) NOT NULL DEFAULT '0.00',
574 574
 					  PRIMARY KEY  (RPY_ID),
575 575
 					  KEY REG_ID (REG_ID),
576 576
 					  KEY PAY_ID (PAY_ID)";
577
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB ');
577
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB ');
578 578
 
579
-        $table_name = 'esp_state';
580
-        $sql        = "STA_ID smallint(5) unsigned NOT NULL AUTO_INCREMENT,
579
+		$table_name = 'esp_state';
580
+		$sql        = "STA_ID smallint(5) unsigned NOT NULL AUTO_INCREMENT,
581 581
 				CNT_ISO varchar(2) NOT NULL,
582 582
 				STA_abbrev varchar(24) NOT NULL,
583 583
 				STA_name varchar(100) NOT NULL,
@@ -585,10 +585,10 @@  discard block
 block discarded – undo
585 585
 				PRIMARY KEY  (STA_ID),
586 586
 				KEY STA_abbrev (STA_abbrev),
587 587
 				KEY CNT_ISO (CNT_ISO)";
588
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
588
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
589 589
 
590
-        $table_name = 'esp_status';
591
-        $sql        = "STS_ID varchar(3) NOT NULL,
590
+		$table_name = 'esp_status';
591
+		$sql        = "STS_ID varchar(3) NOT NULL,
592 592
 				STS_code varchar(45) NOT NULL,
593 593
 				STS_type varchar(45) NOT NULL,
594 594
 				STS_can_edit tinyint(1) NOT NULL DEFAULT 0,
@@ -596,10 +596,10 @@  discard block
 block discarded – undo
596 596
 				STS_open tinyint(1) NOT NULL DEFAULT 1,
597 597
 				UNIQUE KEY STS_ID_UNIQUE (STS_ID),
598 598
 				KEY STS_type (STS_type)";
599
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
599
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
600 600
 
601
-        $table_name = "esp_ticket";
602
-        $sql        = "TKT_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
601
+		$table_name = "esp_ticket";
602
+		$sql        = "TKT_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
603 603
 				TTM_ID int(10) unsigned NOT NULL,
604 604
 				TKT_name varchar(245) NOT NULL DEFAULT '',
605 605
 				TKT_description text NOT NULL,
@@ -624,10 +624,10 @@  discard block
 block discarded – undo
624 624
 				TKT_visibility smallint(6) unsigned NOT NULL DEFAULT 100,
625 625
 				PRIMARY KEY  (TKT_ID),
626 626
 				KEY TKT_start_date (TKT_start_date)";
627
-        $this->_table_is_changed_in_this_version($table_name, $sql, 'ENGINE=InnoDB');
627
+		$this->_table_is_changed_in_this_version($table_name, $sql, 'ENGINE=InnoDB');
628 628
 
629
-        $table_name = 'esp_transaction';
630
-        $sql        = "TXN_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
629
+		$table_name = 'esp_transaction';
630
+		$sql        = "TXN_ID int(10) unsigned NOT NULL AUTO_INCREMENT,
631 631
 				TXN_timestamp datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
632 632
 				TXN_total decimal(12,3) DEFAULT '0.00',
633 633
 				TXN_paid decimal(12,3) NOT NULL DEFAULT '0.00',
@@ -639,10 +639,10 @@  discard block
 block discarded – undo
639 639
 				PRIMARY KEY  (TXN_ID),
640 640
 				KEY TXN_timestamp (TXN_timestamp),
641 641
 				KEY STS_ID (STS_ID)";
642
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
642
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
643 643
 
644
-        $table_name = 'esp_venue_meta';
645
-        $sql        = "VNUM_ID int(11) NOT NULL AUTO_INCREMENT,
644
+		$table_name = 'esp_venue_meta';
645
+		$sql        = "VNUM_ID int(11) NOT NULL AUTO_INCREMENT,
646 646
 			VNU_ID bigint(20) unsigned NOT NULL DEFAULT 0,
647 647
 			VNU_address varchar(255) DEFAULT NULL,
648 648
 			VNU_address2 varchar(255) DEFAULT NULL,
@@ -661,18 +661,18 @@  discard block
 block discarded – undo
661 661
 			KEY VNU_ID (VNU_ID),
662 662
 			KEY STA_ID (STA_ID),
663 663
 			KEY CNT_ISO (CNT_ISO)";
664
-        $this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
664
+		$this->_table_has_not_changed_since_previous($table_name, $sql, 'ENGINE=InnoDB');
665 665
 
666
-        $this->previous_dms->insert_default_data();
667
-        return true;
668
-    }
666
+		$this->previous_dms->insert_default_data();
667
+		return true;
668
+	}
669 669
 
670 670
 
671
-    /**
672
-     * @return boolean
673
-     */
674
-    public function schema_changes_after_migration(): bool
675
-    {
676
-        return true;
677
-    }
671
+	/**
672
+	 * @return boolean
673
+	 */
674
+	public function schema_changes_after_migration(): bool
675
+	{
676
+		return true;
677
+	}
678 678
 }
Please login to merge, or discard this patch.
4_12_0_stages/EE_DMS_4_12_0_Event_Venues.dmsstage.php 2 patches
Indentation   +46 added lines, -46 removed lines patch added patch discarded remove patch
@@ -12,54 +12,54 @@
 block discarded – undo
12 12
  */
13 13
 class EE_DMS_4_12_0_Event_Venues extends EE_Data_Migration_Script_Stage_Table
14 14
 {
15
-    /**
16
-     * @var string
17
-     */
18
-    private $_event_meta;
15
+	/**
16
+	 * @var string
17
+	 */
18
+	private $_event_meta;
19 19
 
20 20
 
21
-    /**
22
-     * Just initializes the status of the migration
23
-     */
24
-    public function __construct()
25
-    {
26
-        global $wpdb;
27
-        $this->_pretty_name = esc_html__('Event Venue Relations', 'event_espresso');
28
-        $this->_old_table   = $wpdb->prefix . 'esp_event_venue';
29
-        $this->_event_meta  = $wpdb->prefix . 'esp_event_meta';
30
-        parent::__construct();
31
-    }
21
+	/**
22
+	 * Just initializes the status of the migration
23
+	 */
24
+	public function __construct()
25
+	{
26
+		global $wpdb;
27
+		$this->_pretty_name = esc_html__('Event Venue Relations', 'event_espresso');
28
+		$this->_old_table   = $wpdb->prefix . 'esp_event_venue';
29
+		$this->_event_meta  = $wpdb->prefix . 'esp_event_meta';
30
+		parent::__construct();
31
+	}
32 32
 
33 33
 
34
-    /**
35
-     * Copies Venue IDs from `wp_esp_event_venue` to `wp_esp_event_meta` for each Event
36
-     *
37
-     * @param array $old_row an associative array where keys are column names and values are their values.
38
-     * @return null
39
-     */
40
-    protected function _migrate_old_row($old_row): ?bool
41
-    {
42
-        $EVT_ID =
43
-            isset($old_row['EVT_ID'])
44
-                ? absint($old_row['EVT_ID'])
45
-                : 0;
46
-        $VNU_ID =
47
-            isset($old_row['VNU_ID'])
48
-                ? absint($old_row['VNU_ID'])
49
-                : 0;
50
-        if ($EVT_ID && $VNU_ID) {
51
-            global $wpdb;
52
-            // If the question group was also for primary attendees, we should just update that row.
53
-            // And we delete this row.
54
-            $result = $wpdb->update(
55
-                $this->_event_meta,
56
-                ['VNU_ID' => $VNU_ID],  // data
57
-                ['EVT_ID' => $EVT_ID],  // where
58
-                ['%d'],                 // data format
59
-                ['%d']                  // where format
60
-            );
61
-            return filter_var($result, FILTER_VALIDATE_BOOLEAN);
62
-        }
63
-        return false;
64
-    }
34
+	/**
35
+	 * Copies Venue IDs from `wp_esp_event_venue` to `wp_esp_event_meta` for each Event
36
+	 *
37
+	 * @param array $old_row an associative array where keys are column names and values are their values.
38
+	 * @return null
39
+	 */
40
+	protected function _migrate_old_row($old_row): ?bool
41
+	{
42
+		$EVT_ID =
43
+			isset($old_row['EVT_ID'])
44
+				? absint($old_row['EVT_ID'])
45
+				: 0;
46
+		$VNU_ID =
47
+			isset($old_row['VNU_ID'])
48
+				? absint($old_row['VNU_ID'])
49
+				: 0;
50
+		if ($EVT_ID && $VNU_ID) {
51
+			global $wpdb;
52
+			// If the question group was also for primary attendees, we should just update that row.
53
+			// And we delete this row.
54
+			$result = $wpdb->update(
55
+				$this->_event_meta,
56
+				['VNU_ID' => $VNU_ID],  // data
57
+				['EVT_ID' => $EVT_ID],  // where
58
+				['%d'],                 // data format
59
+				['%d']                  // where format
60
+			);
61
+			return filter_var($result, FILTER_VALIDATE_BOOLEAN);
62
+		}
63
+		return false;
64
+	}
65 65
 }
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -25,8 +25,8 @@  discard block
 block discarded – undo
25 25
     {
26 26
         global $wpdb;
27 27
         $this->_pretty_name = esc_html__('Event Venue Relations', 'event_espresso');
28
-        $this->_old_table   = $wpdb->prefix . 'esp_event_venue';
29
-        $this->_event_meta  = $wpdb->prefix . 'esp_event_meta';
28
+        $this->_old_table   = $wpdb->prefix.'esp_event_venue';
29
+        $this->_event_meta  = $wpdb->prefix.'esp_event_meta';
30 30
         parent::__construct();
31 31
     }
32 32
 
@@ -53,9 +53,9 @@  discard block
 block discarded – undo
53 53
             // And we delete this row.
54 54
             $result = $wpdb->update(
55 55
                 $this->_event_meta,
56
-                ['VNU_ID' => $VNU_ID],  // data
57
-                ['EVT_ID' => $EVT_ID],  // where
58
-                ['%d'],                 // data format
56
+                ['VNU_ID' => $VNU_ID], // data
57
+                ['EVT_ID' => $EVT_ID], // where
58
+                ['%d'], // data format
59 59
                 ['%d']                  // where format
60 60
             );
61 61
             return filter_var($result, FILTER_VALIDATE_BOOLEAN);
Please login to merge, or discard this patch.
core/db_models/EEM_Venue.model.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -192,7 +192,7 @@
 block discarded – undo
192 192
             'WP_User'           => new EE_Belongs_To_Relation(),
193 193
         );
194 194
         // this model is generally available for reading
195
-        $this->_cap_restriction_generators[ EEM_Base::caps_read ] = new EE_Restriction_Generator_Public();
195
+        $this->_cap_restriction_generators[EEM_Base::caps_read] = new EE_Restriction_Generator_Public();
196 196
         $this->model_chain_to_password = '';
197 197
         parent::__construct($timezone);
198 198
     }
Please login to merge, or discard this patch.
Indentation   +182 added lines, -182 removed lines patch added patch discarded remove patch
@@ -10,189 +10,189 @@
 block discarded – undo
10 10
  */
11 11
 class EEM_Venue extends EEM_CPT_Base
12 12
 {
13
-    // private instance of the Attendee object
14
-    protected static $_instance = null;
13
+	// private instance of the Attendee object
14
+	protected static $_instance = null;
15 15
 
16 16
 
17 17
 
18
-    protected function __construct($timezone = null)
19
-    {
20
-        $this->singular_item = esc_html__('Venue', 'event_espresso');
21
-        $this->plural_item = esc_html__('Venues', 'event_espresso');
22
-        $this->_tables = array(
23
-            'Venue_CPT'  => new EE_Primary_Table('posts', 'ID'),
24
-            'Venue_Meta' => new EE_Secondary_Table('esp_venue_meta', 'VNUM_ID', 'VNU_ID'),
25
-        );
26
-        $this->_fields = array(
27
-            'Venue_CPT'  => array(
28
-                'VNU_ID'         => new EE_Primary_Key_Int_Field('ID', esc_html__("Venue ID", "event_espresso")),
29
-                'VNU_name'       => new EE_Plain_Text_Field(
30
-                    'post_title',
31
-                    esc_html__("Venue Name", "event_espresso"),
32
-                    false,
33
-                    ''
34
-                ),
35
-                'VNU_desc'       => new EE_Post_Content_Field(
36
-                    'post_content',
37
-                    esc_html__("Venue Description", "event_espresso"),
38
-                    false,
39
-                    ''
40
-                ),
41
-                'VNU_identifier' => new EE_Slug_Field('post_name', esc_html__("Venue Identifier", "event_espresso"), false, ''),
42
-                'VNU_created'    => new EE_Datetime_Field(
43
-                    'post_date',
44
-                    esc_html__("Date Venue Created", "event_espresso"),
45
-                    false,
46
-                    EE_Datetime_Field::now
47
-                ),
48
-                'VNU_short_desc' => new EE_Plain_Text_Field(
49
-                    'post_excerpt',
50
-                    esc_html__("Short Description of Venue", "event_espresso"),
51
-                    true,
52
-                    ''
53
-                ),
54
-                'VNU_modified'   => new EE_Datetime_Field(
55
-                    'post_modified',
56
-                    esc_html__("Venue Modified Date", "event_espresso"),
57
-                    false,
58
-                    EE_Datetime_Field::now
59
-                ),
60
-                'VNU_wp_user'    => new EE_WP_User_Field(
61
-                    'post_author',
62
-                    esc_html__("Venue Creator ID", "event_espresso"),
63
-                    false
64
-                ),
65
-                'parent'         => new EE_Integer_Field(
66
-                    'post_parent',
67
-                    esc_html__("Venue Parent ID", "event_espresso"),
68
-                    false,
69
-                    0
70
-                ),
71
-                'VNU_order'      => new EE_Integer_Field('menu_order', esc_html__("Venue order", "event_espresso"), false, 1),
72
-                'post_type'      => new EE_WP_Post_Type_Field('espresso_venues'),
73
-                'password' => new EE_Password_Field(
74
-                    'post_password',
75
-                    esc_html__('Password', 'event_espresso'),
76
-                    false,
77
-                    '',
78
-                    array(
79
-                        'VNU_desc',
80
-                        'VNU_short_desc',
81
-                        'VNU_address',
82
-                        'VNU_address2',
83
-                        'VNU_city',
84
-                        'STA_ID',
85
-                        'CNT_ISO',
86
-                        'VNU_zip',
87
-                        'VNU_phone',
88
-                        'VNU_capacity',
89
-                        'VNU_url',
90
-                        'VNU_virtual_phone',
91
-                        'VNU_virtual_url',
92
-                        'VNU_google_map_link',
93
-                        'VNU_enable_for_gmap',
94
-                    )
95
-                )
96
-            ),
97
-            'Venue_Meta' => array(
98
-                'VNUM_ID'             => new EE_DB_Only_Int_Field(
99
-                    'VNUM_ID',
100
-                    esc_html__("ID of Venue Meta Row", "event_espresso"),
101
-                    false
102
-                ),
103
-                'VNU_ID_fk'           => new EE_DB_Only_Int_Field(
104
-                    'VNU_ID',
105
-                    esc_html__("Foreign Key to Venue Post ", "event_espresso"),
106
-                    false
107
-                ),
108
-                'VNU_address'         => new EE_Plain_Text_Field(
109
-                    'VNU_address',
110
-                    esc_html__("Venue Address line 1", "event_espresso"),
111
-                    true,
112
-                    ''
113
-                ),
114
-                'VNU_address2'        => new EE_Plain_Text_Field(
115
-                    'VNU_address2',
116
-                    esc_html__("Venue Address line 2", "event_espresso"),
117
-                    true,
118
-                    ''
119
-                ),
120
-                'VNU_city'            => new EE_Plain_Text_Field(
121
-                    'VNU_city',
122
-                    esc_html__("Venue City", "event_espresso"),
123
-                    true,
124
-                    ''
125
-                ),
126
-                'STA_ID'              => new EE_Foreign_Key_Int_Field(
127
-                    'STA_ID',
128
-                    esc_html__("State ID", "event_espresso"),
129
-                    true,
130
-                    null,
131
-                    'State'
132
-                ),
133
-                'CNT_ISO'             => new EE_Foreign_Key_String_Field(
134
-                    'CNT_ISO',
135
-                    esc_html__("Country Code", "event_espresso"),
136
-                    true,
137
-                    null,
138
-                    'Country'
139
-                ),
140
-                'VNU_zip'             => new EE_Plain_Text_Field(
141
-                    'VNU_zip',
142
-                    esc_html__("Venue Zip/Postal Code", "event_espresso"),
143
-                    true
144
-                ),
145
-                'VNU_phone'           => new EE_Plain_Text_Field(
146
-                    'VNU_phone',
147
-                    esc_html__("Venue Phone", "event_espresso"),
148
-                    true
149
-                ),
150
-                'VNU_capacity'        => new EE_Infinite_Integer_Field(
151
-                    'VNU_capacity',
152
-                    esc_html__("Venue Capacity", "event_espresso"),
153
-                    true,
154
-                    EE_INF
155
-                ),
156
-                'VNU_url'             => new EE_Plain_Text_Field(
157
-                    'VNU_url',
158
-                    esc_html__('Venue Website', 'event_espresso'),
159
-                    true
160
-                ),
161
-                'VNU_virtual_phone'   => new EE_Plain_Text_Field(
162
-                    'VNU_virtual_phone',
163
-                    esc_html__('Call in Number', 'event_espresso'),
164
-                    true
165
-                ),
166
-                'VNU_virtual_url'     => new EE_Plain_Text_Field(
167
-                    'VNU_virtual_url',
168
-                    esc_html__('Virtual URL', 'event_espresso'),
169
-                    true
170
-                ),
171
-                'VNU_google_map_link' => new EE_Plain_Text_Field(
172
-                    'VNU_google_map_link',
173
-                    esc_html__('Google Map Link', 'event_espresso'),
174
-                    true
175
-                ),
176
-                'VNU_enable_for_gmap' => new EE_Boolean_Field(
177
-                    'VNU_enable_for_gmap',
178
-                    esc_html__('Show Google Map?', 'event_espresso'),
179
-                    false,
180
-                    false
181
-                ),
182
-            ),
183
-        );
184
-        $this->_model_relations = array(
185
-            'Country'           => new EE_Belongs_To_Relation(),
186
-            'Event'             => new EE_Has_Many_Relation(),
187
-            'Datetime'          => new EE_Has_Many_Relation(),
188
-            'State'             => new EE_Belongs_To_Relation(),
189
-            'Term_Relationship' => new EE_Has_Many_Relation(),
190
-            'Term_Taxonomy'     => new EE_HABTM_Relation('Term_Relationship'),
191
-            'WP_User'           => new EE_Belongs_To_Relation(),
192
-        );
193
-        // this model is generally available for reading
194
-        $this->_cap_restriction_generators[ EEM_Base::caps_read ] = new EE_Restriction_Generator_Public();
195
-        $this->model_chain_to_password = '';
196
-        parent::__construct($timezone);
197
-    }
18
+	protected function __construct($timezone = null)
19
+	{
20
+		$this->singular_item = esc_html__('Venue', 'event_espresso');
21
+		$this->plural_item = esc_html__('Venues', 'event_espresso');
22
+		$this->_tables = array(
23
+			'Venue_CPT'  => new EE_Primary_Table('posts', 'ID'),
24
+			'Venue_Meta' => new EE_Secondary_Table('esp_venue_meta', 'VNUM_ID', 'VNU_ID'),
25
+		);
26
+		$this->_fields = array(
27
+			'Venue_CPT'  => array(
28
+				'VNU_ID'         => new EE_Primary_Key_Int_Field('ID', esc_html__("Venue ID", "event_espresso")),
29
+				'VNU_name'       => new EE_Plain_Text_Field(
30
+					'post_title',
31
+					esc_html__("Venue Name", "event_espresso"),
32
+					false,
33
+					''
34
+				),
35
+				'VNU_desc'       => new EE_Post_Content_Field(
36
+					'post_content',
37
+					esc_html__("Venue Description", "event_espresso"),
38
+					false,
39
+					''
40
+				),
41
+				'VNU_identifier' => new EE_Slug_Field('post_name', esc_html__("Venue Identifier", "event_espresso"), false, ''),
42
+				'VNU_created'    => new EE_Datetime_Field(
43
+					'post_date',
44
+					esc_html__("Date Venue Created", "event_espresso"),
45
+					false,
46
+					EE_Datetime_Field::now
47
+				),
48
+				'VNU_short_desc' => new EE_Plain_Text_Field(
49
+					'post_excerpt',
50
+					esc_html__("Short Description of Venue", "event_espresso"),
51
+					true,
52
+					''
53
+				),
54
+				'VNU_modified'   => new EE_Datetime_Field(
55
+					'post_modified',
56
+					esc_html__("Venue Modified Date", "event_espresso"),
57
+					false,
58
+					EE_Datetime_Field::now
59
+				),
60
+				'VNU_wp_user'    => new EE_WP_User_Field(
61
+					'post_author',
62
+					esc_html__("Venue Creator ID", "event_espresso"),
63
+					false
64
+				),
65
+				'parent'         => new EE_Integer_Field(
66
+					'post_parent',
67
+					esc_html__("Venue Parent ID", "event_espresso"),
68
+					false,
69
+					0
70
+				),
71
+				'VNU_order'      => new EE_Integer_Field('menu_order', esc_html__("Venue order", "event_espresso"), false, 1),
72
+				'post_type'      => new EE_WP_Post_Type_Field('espresso_venues'),
73
+				'password' => new EE_Password_Field(
74
+					'post_password',
75
+					esc_html__('Password', 'event_espresso'),
76
+					false,
77
+					'',
78
+					array(
79
+						'VNU_desc',
80
+						'VNU_short_desc',
81
+						'VNU_address',
82
+						'VNU_address2',
83
+						'VNU_city',
84
+						'STA_ID',
85
+						'CNT_ISO',
86
+						'VNU_zip',
87
+						'VNU_phone',
88
+						'VNU_capacity',
89
+						'VNU_url',
90
+						'VNU_virtual_phone',
91
+						'VNU_virtual_url',
92
+						'VNU_google_map_link',
93
+						'VNU_enable_for_gmap',
94
+					)
95
+				)
96
+			),
97
+			'Venue_Meta' => array(
98
+				'VNUM_ID'             => new EE_DB_Only_Int_Field(
99
+					'VNUM_ID',
100
+					esc_html__("ID of Venue Meta Row", "event_espresso"),
101
+					false
102
+				),
103
+				'VNU_ID_fk'           => new EE_DB_Only_Int_Field(
104
+					'VNU_ID',
105
+					esc_html__("Foreign Key to Venue Post ", "event_espresso"),
106
+					false
107
+				),
108
+				'VNU_address'         => new EE_Plain_Text_Field(
109
+					'VNU_address',
110
+					esc_html__("Venue Address line 1", "event_espresso"),
111
+					true,
112
+					''
113
+				),
114
+				'VNU_address2'        => new EE_Plain_Text_Field(
115
+					'VNU_address2',
116
+					esc_html__("Venue Address line 2", "event_espresso"),
117
+					true,
118
+					''
119
+				),
120
+				'VNU_city'            => new EE_Plain_Text_Field(
121
+					'VNU_city',
122
+					esc_html__("Venue City", "event_espresso"),
123
+					true,
124
+					''
125
+				),
126
+				'STA_ID'              => new EE_Foreign_Key_Int_Field(
127
+					'STA_ID',
128
+					esc_html__("State ID", "event_espresso"),
129
+					true,
130
+					null,
131
+					'State'
132
+				),
133
+				'CNT_ISO'             => new EE_Foreign_Key_String_Field(
134
+					'CNT_ISO',
135
+					esc_html__("Country Code", "event_espresso"),
136
+					true,
137
+					null,
138
+					'Country'
139
+				),
140
+				'VNU_zip'             => new EE_Plain_Text_Field(
141
+					'VNU_zip',
142
+					esc_html__("Venue Zip/Postal Code", "event_espresso"),
143
+					true
144
+				),
145
+				'VNU_phone'           => new EE_Plain_Text_Field(
146
+					'VNU_phone',
147
+					esc_html__("Venue Phone", "event_espresso"),
148
+					true
149
+				),
150
+				'VNU_capacity'        => new EE_Infinite_Integer_Field(
151
+					'VNU_capacity',
152
+					esc_html__("Venue Capacity", "event_espresso"),
153
+					true,
154
+					EE_INF
155
+				),
156
+				'VNU_url'             => new EE_Plain_Text_Field(
157
+					'VNU_url',
158
+					esc_html__('Venue Website', 'event_espresso'),
159
+					true
160
+				),
161
+				'VNU_virtual_phone'   => new EE_Plain_Text_Field(
162
+					'VNU_virtual_phone',
163
+					esc_html__('Call in Number', 'event_espresso'),
164
+					true
165
+				),
166
+				'VNU_virtual_url'     => new EE_Plain_Text_Field(
167
+					'VNU_virtual_url',
168
+					esc_html__('Virtual URL', 'event_espresso'),
169
+					true
170
+				),
171
+				'VNU_google_map_link' => new EE_Plain_Text_Field(
172
+					'VNU_google_map_link',
173
+					esc_html__('Google Map Link', 'event_espresso'),
174
+					true
175
+				),
176
+				'VNU_enable_for_gmap' => new EE_Boolean_Field(
177
+					'VNU_enable_for_gmap',
178
+					esc_html__('Show Google Map?', 'event_espresso'),
179
+					false,
180
+					false
181
+				),
182
+			),
183
+		);
184
+		$this->_model_relations = array(
185
+			'Country'           => new EE_Belongs_To_Relation(),
186
+			'Event'             => new EE_Has_Many_Relation(),
187
+			'Datetime'          => new EE_Has_Many_Relation(),
188
+			'State'             => new EE_Belongs_To_Relation(),
189
+			'Term_Relationship' => new EE_Has_Many_Relation(),
190
+			'Term_Taxonomy'     => new EE_HABTM_Relation('Term_Relationship'),
191
+			'WP_User'           => new EE_Belongs_To_Relation(),
192
+		);
193
+		// this model is generally available for reading
194
+		$this->_cap_restriction_generators[ EEM_Base::caps_read ] = new EE_Restriction_Generator_Public();
195
+		$this->model_chain_to_password = '';
196
+		parent::__construct($timezone);
197
+	}
198 198
 }
Please login to merge, or discard this patch.
core/domain/services/graphql/types/Event.php 2 patches
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
      */
33 33
     public function __construct(EEM_Event $event_model)
34 34
     {
35
-        $this->setName($this->namespace . 'Event');
35
+        $this->setName($this->namespace.'Event');
36 36
         $this->setIsCustomPostType(true);
37 37
         parent::__construct($event_model);
38 38
     }
@@ -82,7 +82,7 @@  discard block
 block discarded – undo
82 82
             ),
83 83
             new GraphQLField(
84 84
                 'defaultRegStatus',
85
-                $this->namespace . 'RegistrationStatusEnum',
85
+                $this->namespace.'RegistrationStatusEnum',
86 86
                 'default_registration_status',
87 87
                 esc_html__('Default Event Registration Status', 'event_espresso')
88 88
             ),
@@ -215,7 +215,7 @@  discard block
 block discarded – undo
215 215
                 null,
216 216
                 esc_html__('Event venue ID', 'event_espresso'),
217 217
                 null,
218
-                function (EE_Event $source) {
218
+                function(EE_Event $source) {
219 219
                     $venue_ID = $source->venue_ID();
220 220
                     return $venue_ID
221 221
                     // Since venue is a CPT, $type will be 'post'
Please login to merge, or discard this patch.
Indentation   +218 added lines, -218 removed lines patch added patch discarded remove patch
@@ -24,227 +24,227 @@
 block discarded – undo
24 24
  */
25 25
 class Event extends TypeBase
26 26
 {
27
-    /**
28
-     * Event constructor.
29
-     *
30
-     * @param EEM_Event $event_model
31
-     */
32
-    public function __construct(EEM_Event $event_model)
33
-    {
34
-        $this->setName($this->namespace . 'Event');
35
-        $this->setIsCustomPostType(true);
36
-        parent::__construct($event_model);
37
-    }
27
+	/**
28
+	 * Event constructor.
29
+	 *
30
+	 * @param EEM_Event $event_model
31
+	 */
32
+	public function __construct(EEM_Event $event_model)
33
+	{
34
+		$this->setName($this->namespace . 'Event');
35
+		$this->setIsCustomPostType(true);
36
+		parent::__construct($event_model);
37
+	}
38 38
 
39 39
 
40
-    /**
41
-     * @return GraphQLFieldInterface[]
42
-     */
43
-    public function getFields(): array
44
-    {
45
-        $fields = [
46
-            new GraphQLField(
47
-                'allowDonations',
48
-                'Boolean',
49
-                'donations',
50
-                esc_html__('Accept Donations?', 'event_espresso')
51
-            ),
52
-            new GraphQLField(
53
-                'allowOverflow',
54
-                'Boolean',
55
-                'allow_overflow',
56
-                esc_html__('Enable Wait List for Event', 'event_espresso')
57
-            ),
58
-            new GraphQLField(
59
-                'altRegPage',
60
-                'String',
61
-                'external_url',
62
-                esc_html__('URL of Event Page if hosted elsewhere', 'event_espresso')
63
-            ),
64
-            new GraphQLOutputField(
65
-                'cacheId',
66
-                ['non_null' => 'String'],
67
-                null,
68
-                esc_html__('The cache ID of the object.', 'event_espresso')
69
-            ),
70
-            new GraphQLField(
71
-                'created',
72
-                'String',
73
-                'created',
74
-                esc_html__('Date/Time Event Created', 'event_espresso')
75
-            ),
76
-            new GraphQLOutputField(
77
-                'dbId',
78
-                ['non_null' => 'Int'],
79
-                'ID',
80
-                esc_html__('The event ID.', 'event_espresso')
81
-            ),
82
-            new GraphQLField(
83
-                'defaultRegStatus',
84
-                $this->namespace . 'RegistrationStatusEnum',
85
-                'default_registration_status',
86
-                esc_html__('Default Event Registration Status', 'event_espresso')
87
-            ),
88
-            new GraphQLField(
89
-                'description',
90
-                'String',
91
-                'description',
92
-                esc_html__('Event Description', 'event_espresso')
93
-            ),
94
-            new GraphQLField(
95
-                'displayDescription',
96
-                'Boolean',
97
-                'display_description',
98
-                esc_html__('Display Description Flag', 'event_espresso')
99
-            ),
100
-            new GraphQLField(
101
-                'displayTicketSelector',
102
-                'Boolean',
103
-                'display_ticket_selector',
104
-                esc_html__('Display Ticket Selector Flag', 'event_espresso')
105
-            ),
106
-            new GraphQLOutputField(
107
-                'isActive',
108
-                'Boolean',
109
-                'is_active',
110
-                esc_html__('Flag indicating event is active', 'event_espresso')
111
-            ),
112
-            new GraphQLOutputField(
113
-                'isCancelled',
114
-                'Boolean',
115
-                'is_cancelled',
116
-                esc_html__('Flag indicating whether the event is marked as cancelled', 'event_espresso')
117
-            ),
118
-            new GraphQLOutputField(
119
-                'isExpired',
120
-                'Boolean',
121
-                'is_expired',
122
-                esc_html__('Flag indicating event is expired or not', 'event_espresso')
123
-            ),
124
-            new GraphQLOutputField(
125
-                'isInactive',
126
-                'Boolean',
127
-                'is_inactive',
128
-                esc_html__('Flag indicating event is inactive', 'event_espresso')
129
-            ),
130
-            new GraphQLOutputField(
131
-                'isPostponed',
132
-                'Boolean',
133
-                'is_postponed',
134
-                esc_html__('Flag indicating whether the event is marked as postponed', 'event_espresso')
135
-            ),
136
-            new GraphQLOutputField(
137
-                'isSoldOut',
138
-                'Boolean',
139
-                'is_sold_out',
140
-                esc_html__(
141
-                    'Flag indicating whether the tickets sold for the event, met or exceed the registration limit',
142
-                    'event_espresso'
143
-                )
144
-            ),
145
-            new GraphQLOutputField(
146
-                'isUpcoming',
147
-                'Boolean',
148
-                'is_upcoming',
149
-                esc_html__('Whether the event is upcoming', 'event_espresso')
150
-            ),
151
-            new GraphQLInputField(
152
-                'manager',
153
-                'String',
154
-                null,
155
-                esc_html__('Globally unique event ID for the event manager', 'event_espresso')
156
-            ),
157
-            new GraphQLOutputField(
158
-                'manager',
159
-                'User',
160
-                null,
161
-                esc_html__('Event Manager', 'event_espresso')
162
-            ),
163
-            new GraphQLField(
164
-                'maxRegistrations',
165
-                'Int',
166
-                'additional_limit',
167
-                esc_html__('Limit of Additional Registrations on Same Transaction', 'event_espresso')
168
-            ),
169
-            new GraphQLField(
170
-                'memberOnly',
171
-                'Boolean',
172
-                'member_only',
173
-                esc_html__('Member-Only Event Flag', 'event_espresso')
174
-            ),
175
-            new GraphQLField(
176
-                'name',
177
-                'String',
178
-                'name',
179
-                esc_html__('Event Name', 'event_espresso')
180
-            ),
181
-            new GraphQLField(
182
-                'order',
183
-                'Int',
184
-                'order',
185
-                esc_html__('Event Menu Order', 'event_espresso')
186
-            ),
187
-            new GraphQLField(
188
-                'phoneNumber',
189
-                'String',
190
-                'phone',
191
-                esc_html__('Event Phone Number', 'event_espresso')
192
-            ),
193
-            new GraphQLField(
194
-                'shortDescription',
195
-                'String',
196
-                'short_description',
197
-                esc_html__('Event Short Description', 'event_espresso')
198
-            ),
199
-            new GraphQLField(
200
-                'timezoneString',
201
-                'String',
202
-                'timezone_string',
203
-                esc_html__('Timezone (name) for Event times', 'event_espresso')
204
-            ),
205
-            new GraphQLField(
206
-                'visibleOn',
207
-                'String',
208
-                'visible_on',
209
-                esc_html__('Event Visible Date', 'event_espresso')
210
-            ),
211
-            new GraphQLField(
212
-                'venue',
213
-                'String',
214
-                null,
215
-                esc_html__('Event venue ID', 'event_espresso'),
216
-                null,
217
-                function (EE_Event $source) {
218
-                    $venue_ID = $source->venue_ID();
219
-                    return $venue_ID
220
-                    // Since venue is a CPT, $type will be 'post'
221
-                    ? Relay::toGlobalId('post', $venue_ID)
222
-                    : null;
223
-                }
224
-            ),
225
-        ];
40
+	/**
41
+	 * @return GraphQLFieldInterface[]
42
+	 */
43
+	public function getFields(): array
44
+	{
45
+		$fields = [
46
+			new GraphQLField(
47
+				'allowDonations',
48
+				'Boolean',
49
+				'donations',
50
+				esc_html__('Accept Donations?', 'event_espresso')
51
+			),
52
+			new GraphQLField(
53
+				'allowOverflow',
54
+				'Boolean',
55
+				'allow_overflow',
56
+				esc_html__('Enable Wait List for Event', 'event_espresso')
57
+			),
58
+			new GraphQLField(
59
+				'altRegPage',
60
+				'String',
61
+				'external_url',
62
+				esc_html__('URL of Event Page if hosted elsewhere', 'event_espresso')
63
+			),
64
+			new GraphQLOutputField(
65
+				'cacheId',
66
+				['non_null' => 'String'],
67
+				null,
68
+				esc_html__('The cache ID of the object.', 'event_espresso')
69
+			),
70
+			new GraphQLField(
71
+				'created',
72
+				'String',
73
+				'created',
74
+				esc_html__('Date/Time Event Created', 'event_espresso')
75
+			),
76
+			new GraphQLOutputField(
77
+				'dbId',
78
+				['non_null' => 'Int'],
79
+				'ID',
80
+				esc_html__('The event ID.', 'event_espresso')
81
+			),
82
+			new GraphQLField(
83
+				'defaultRegStatus',
84
+				$this->namespace . 'RegistrationStatusEnum',
85
+				'default_registration_status',
86
+				esc_html__('Default Event Registration Status', 'event_espresso')
87
+			),
88
+			new GraphQLField(
89
+				'description',
90
+				'String',
91
+				'description',
92
+				esc_html__('Event Description', 'event_espresso')
93
+			),
94
+			new GraphQLField(
95
+				'displayDescription',
96
+				'Boolean',
97
+				'display_description',
98
+				esc_html__('Display Description Flag', 'event_espresso')
99
+			),
100
+			new GraphQLField(
101
+				'displayTicketSelector',
102
+				'Boolean',
103
+				'display_ticket_selector',
104
+				esc_html__('Display Ticket Selector Flag', 'event_espresso')
105
+			),
106
+			new GraphQLOutputField(
107
+				'isActive',
108
+				'Boolean',
109
+				'is_active',
110
+				esc_html__('Flag indicating event is active', 'event_espresso')
111
+			),
112
+			new GraphQLOutputField(
113
+				'isCancelled',
114
+				'Boolean',
115
+				'is_cancelled',
116
+				esc_html__('Flag indicating whether the event is marked as cancelled', 'event_espresso')
117
+			),
118
+			new GraphQLOutputField(
119
+				'isExpired',
120
+				'Boolean',
121
+				'is_expired',
122
+				esc_html__('Flag indicating event is expired or not', 'event_espresso')
123
+			),
124
+			new GraphQLOutputField(
125
+				'isInactive',
126
+				'Boolean',
127
+				'is_inactive',
128
+				esc_html__('Flag indicating event is inactive', 'event_espresso')
129
+			),
130
+			new GraphQLOutputField(
131
+				'isPostponed',
132
+				'Boolean',
133
+				'is_postponed',
134
+				esc_html__('Flag indicating whether the event is marked as postponed', 'event_espresso')
135
+			),
136
+			new GraphQLOutputField(
137
+				'isSoldOut',
138
+				'Boolean',
139
+				'is_sold_out',
140
+				esc_html__(
141
+					'Flag indicating whether the tickets sold for the event, met or exceed the registration limit',
142
+					'event_espresso'
143
+				)
144
+			),
145
+			new GraphQLOutputField(
146
+				'isUpcoming',
147
+				'Boolean',
148
+				'is_upcoming',
149
+				esc_html__('Whether the event is upcoming', 'event_espresso')
150
+			),
151
+			new GraphQLInputField(
152
+				'manager',
153
+				'String',
154
+				null,
155
+				esc_html__('Globally unique event ID for the event manager', 'event_espresso')
156
+			),
157
+			new GraphQLOutputField(
158
+				'manager',
159
+				'User',
160
+				null,
161
+				esc_html__('Event Manager', 'event_espresso')
162
+			),
163
+			new GraphQLField(
164
+				'maxRegistrations',
165
+				'Int',
166
+				'additional_limit',
167
+				esc_html__('Limit of Additional Registrations on Same Transaction', 'event_espresso')
168
+			),
169
+			new GraphQLField(
170
+				'memberOnly',
171
+				'Boolean',
172
+				'member_only',
173
+				esc_html__('Member-Only Event Flag', 'event_espresso')
174
+			),
175
+			new GraphQLField(
176
+				'name',
177
+				'String',
178
+				'name',
179
+				esc_html__('Event Name', 'event_espresso')
180
+			),
181
+			new GraphQLField(
182
+				'order',
183
+				'Int',
184
+				'order',
185
+				esc_html__('Event Menu Order', 'event_espresso')
186
+			),
187
+			new GraphQLField(
188
+				'phoneNumber',
189
+				'String',
190
+				'phone',
191
+				esc_html__('Event Phone Number', 'event_espresso')
192
+			),
193
+			new GraphQLField(
194
+				'shortDescription',
195
+				'String',
196
+				'short_description',
197
+				esc_html__('Event Short Description', 'event_espresso')
198
+			),
199
+			new GraphQLField(
200
+				'timezoneString',
201
+				'String',
202
+				'timezone_string',
203
+				esc_html__('Timezone (name) for Event times', 'event_espresso')
204
+			),
205
+			new GraphQLField(
206
+				'visibleOn',
207
+				'String',
208
+				'visible_on',
209
+				esc_html__('Event Visible Date', 'event_espresso')
210
+			),
211
+			new GraphQLField(
212
+				'venue',
213
+				'String',
214
+				null,
215
+				esc_html__('Event venue ID', 'event_espresso'),
216
+				null,
217
+				function (EE_Event $source) {
218
+					$venue_ID = $source->venue_ID();
219
+					return $venue_ID
220
+					// Since venue is a CPT, $type will be 'post'
221
+					? Relay::toGlobalId('post', $venue_ID)
222
+					: null;
223
+				}
224
+			),
225
+		];
226 226
 
227
-        return apply_filters(
228
-            'FHEE__EventEspresso_core_domain_services_graphql_types__event_fields',
229
-            $fields,
230
-            $this->name,
231
-            $this->model
232
-        );
233
-    }
227
+		return apply_filters(
228
+			'FHEE__EventEspresso_core_domain_services_graphql_types__event_fields',
229
+			$fields,
230
+			$this->name,
231
+			$this->model
232
+		);
233
+	}
234 234
 
235 235
 
236
-    /**
237
-     * Extends the existing WP GraphQL mutations.
238
-     *
239
-     * @since $VID:$
240
-     */
241
-    public function extendMutations()
242
-    {
243
-        add_action(
244
-            'graphql_post_object_mutation_update_additional_data',
245
-            EventUpdate::mutateFields($this->model, $this),
246
-            10,
247
-            6
248
-        );
249
-    }
236
+	/**
237
+	 * Extends the existing WP GraphQL mutations.
238
+	 *
239
+	 * @since $VID:$
240
+	 */
241
+	public function extendMutations()
242
+	{
243
+		add_action(
244
+			'graphql_post_object_mutation_update_additional_data',
245
+			EventUpdate::mutateFields($this->model, $this),
246
+			10,
247
+			6
248
+		);
249
+	}
250 250
 }
Please login to merge, or discard this patch.
core/domain/services/graphql/connections/RootQueryStatesConnection.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -38,8 +38,8 @@
 block discarded – undo
38 38
     {
39 39
         return [
40 40
             'fromType'           => 'RootQuery',
41
-            'toType'             => $this->namespace . 'State',
42
-            'fromFieldName'      => lcfirst($this->namespace) . 'States',
41
+            'toType'             => $this->namespace.'State',
42
+            'fromFieldName'      => lcfirst($this->namespace).'States',
43 43
             'connectionTypeName' => "{$this->namespace}RootQueryStatesConnection",
44 44
             'connectionArgs'     => self::get_connection_args(),
45 45
             'resolve'            => [$this, 'resolveConnection'],
Please login to merge, or discard this patch.
Indentation   +85 added lines, -85 removed lines patch added patch discarded remove patch
@@ -18,95 +18,95 @@
 block discarded – undo
18 18
  */
19 19
 class RootQueryStatesConnection extends AbstractRootQueryConnection
20 20
 {
21
-    /**
22
-     * StateConnection constructor.
23
-     *
24
-     * @param EEM_State               $model
25
-     */
26
-    public function __construct(EEM_State $model)
27
-    {
28
-        parent::__construct($model);
29
-    }
21
+	/**
22
+	 * StateConnection constructor.
23
+	 *
24
+	 * @param EEM_State               $model
25
+	 */
26
+	public function __construct(EEM_State $model)
27
+	{
28
+		parent::__construct($model);
29
+	}
30 30
 
31 31
 
32
-    /**
33
-     * @return array
34
-     */
35
-    public function config(): array
36
-    {
37
-        return [
38
-            'fromType'           => 'RootQuery',
39
-            'toType'             => $this->namespace . 'State',
40
-            'fromFieldName'      => lcfirst($this->namespace) . 'States',
41
-            'connectionTypeName' => "{$this->namespace}RootQueryStatesConnection",
42
-            'connectionArgs'     => self::get_connection_args(),
43
-            'resolve'            => [$this, 'resolveConnection'],
44
-        ];
45
-    }
32
+	/**
33
+	 * @return array
34
+	 */
35
+	public function config(): array
36
+	{
37
+		return [
38
+			'fromType'           => 'RootQuery',
39
+			'toType'             => $this->namespace . 'State',
40
+			'fromFieldName'      => lcfirst($this->namespace) . 'States',
41
+			'connectionTypeName' => "{$this->namespace}RootQueryStatesConnection",
42
+			'connectionArgs'     => self::get_connection_args(),
43
+			'resolve'            => [$this, 'resolveConnection'],
44
+		];
45
+	}
46 46
 
47 47
 
48
-    /**
49
-     * @param $entity
50
-     * @param $args
51
-     * @param $context
52
-     * @param $info
53
-     * @return StateConnectionResolver
54
-     * @throws Exception
55
-     */
56
-    public function getConnectionResolver($entity, $args, $context, $info): AbstractConnectionResolver
57
-    {
58
-        return new StateConnectionResolver($entity, $args, $context, $info);
59
-    }
48
+	/**
49
+	 * @param $entity
50
+	 * @param $args
51
+	 * @param $context
52
+	 * @param $info
53
+	 * @return StateConnectionResolver
54
+	 * @throws Exception
55
+	 */
56
+	public function getConnectionResolver($entity, $args, $context, $info): AbstractConnectionResolver
57
+	{
58
+		return new StateConnectionResolver($entity, $args, $context, $info);
59
+	}
60 60
 
61
-    /**
62
-     * Given an optional array of args, this returns the args to be used in the connection
63
-     *
64
-     * @param array $args The args to modify the defaults
65
-     * @return array
66
-     */
67
-    // phpcs:ignore PSR1.Methods.CamelCapsMethodName.NotCamelCaps
68
-    public static function get_connection_args(array $args = []): array
69
-    {
70
-        $newArgs = [
71
-            'orderby'      => [
72
-                'type'        => ['list_of' => 'EspressoCountriesConnectionOrderbyInput'],
73
-                'description' => esc_html__('What parameter to use to order the objects by.', 'event_espresso'),
74
-            ],
75
-            'in' => [
76
-                'type'        => ['list_of' => 'ID'],
77
-                'description' => esc_html__(
78
-                    'Limit the result to the set of given state IDs.',
79
-                    'event_espresso'
80
-                ),
81
-            ],
82
-            'countryIsoIn' => [
83
-                'type'        => ['list_of' => 'String'],
84
-                'description' => esc_html__(
85
-                    'Limit the result to the set of given country ISOs.',
86
-                    'event_espresso'
87
-                ),
88
-            ],
89
-            'search' => [
90
-                'type'        => 'String',
91
-                'description' => esc_html__('The search keywords', 'event_espresso'),
92
-            ],
93
-            'activeOnly' => [
94
-                'type'        => 'Boolean',
95
-                'description' => esc_html__(
96
-                    'Limit the result to the active states.',
97
-                    'event_espresso'
98
-                ),
99
-            ],
100
-        ];
61
+	/**
62
+	 * Given an optional array of args, this returns the args to be used in the connection
63
+	 *
64
+	 * @param array $args The args to modify the defaults
65
+	 * @return array
66
+	 */
67
+	// phpcs:ignore PSR1.Methods.CamelCapsMethodName.NotCamelCaps
68
+	public static function get_connection_args(array $args = []): array
69
+	{
70
+		$newArgs = [
71
+			'orderby'      => [
72
+				'type'        => ['list_of' => 'EspressoCountriesConnectionOrderbyInput'],
73
+				'description' => esc_html__('What parameter to use to order the objects by.', 'event_espresso'),
74
+			],
75
+			'in' => [
76
+				'type'        => ['list_of' => 'ID'],
77
+				'description' => esc_html__(
78
+					'Limit the result to the set of given state IDs.',
79
+					'event_espresso'
80
+				),
81
+			],
82
+			'countryIsoIn' => [
83
+				'type'        => ['list_of' => 'String'],
84
+				'description' => esc_html__(
85
+					'Limit the result to the set of given country ISOs.',
86
+					'event_espresso'
87
+				),
88
+			],
89
+			'search' => [
90
+				'type'        => 'String',
91
+				'description' => esc_html__('The search keywords', 'event_espresso'),
92
+			],
93
+			'activeOnly' => [
94
+				'type'        => 'Boolean',
95
+				'description' => esc_html__(
96
+					'Limit the result to the active states.',
97
+					'event_espresso'
98
+				),
99
+			],
100
+		];
101 101
 
102
-        $newArgs = apply_filters(
103
-            'FHEE__EventEspresso_core_domain_services_graphql_connections__state_args',
104
-            $newArgs,
105
-            $args
106
-        );
107
-        return array_merge(
108
-            $newArgs,
109
-            $args
110
-        );
111
-    }
102
+		$newArgs = apply_filters(
103
+			'FHEE__EventEspresso_core_domain_services_graphql_connections__state_args',
104
+			$newArgs,
105
+			$args
106
+		);
107
+		return array_merge(
108
+			$newArgs,
109
+			$args
110
+		);
111
+	}
112 112
 }
Please login to merge, or discard this patch.
core/domain/services/graphql/connections/RootQueryCountriesConnection.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -38,8 +38,8 @@
 block discarded – undo
38 38
     {
39 39
         return [
40 40
             'fromType'           => 'RootQuery',
41
-            'toType'             => $this->namespace . 'Country',
42
-            'fromFieldName'      => lcfirst($this->namespace . 'Countries'),
41
+            'toType'             => $this->namespace.'Country',
42
+            'fromFieldName'      => lcfirst($this->namespace.'Countries'),
43 43
             'connectionTypeName' => "{$this->namespace}RootQueryCountriesConnection",
44 44
             'connectionArgs'     => RootQueryCountriesConnection::get_connection_args(),
45 45
             'resolve'            => [$this, 'resolveConnection'],
Please login to merge, or discard this patch.
Indentation   +95 added lines, -95 removed lines patch added patch discarded remove patch
@@ -18,105 +18,105 @@
 block discarded – undo
18 18
  */
19 19
 class RootQueryCountriesConnection extends AbstractRootQueryConnection
20 20
 {
21
-    /**
22
-     * CountryConnection constructor.
23
-     *
24
-     * @param EEM_Country               $model
25
-     */
26
-    public function __construct(EEM_Country $model)
27
-    {
28
-        parent::__construct($model);
29
-    }
21
+	/**
22
+	 * CountryConnection constructor.
23
+	 *
24
+	 * @param EEM_Country               $model
25
+	 */
26
+	public function __construct(EEM_Country $model)
27
+	{
28
+		parent::__construct($model);
29
+	}
30 30
 
31 31
 
32
-    /**
33
-     * @return array
34
-     */
35
-    public function config(): array
36
-    {
37
-        return [
38
-            'fromType'           => 'RootQuery',
39
-            'toType'             => $this->namespace . 'Country',
40
-            'fromFieldName'      => lcfirst($this->namespace . 'Countries'),
41
-            'connectionTypeName' => "{$this->namespace}RootQueryCountriesConnection",
42
-            'connectionArgs'     => RootQueryCountriesConnection::get_connection_args(),
43
-            'resolve'            => [$this, 'resolveConnection'],
44
-        ];
45
-    }
32
+	/**
33
+	 * @return array
34
+	 */
35
+	public function config(): array
36
+	{
37
+		return [
38
+			'fromType'           => 'RootQuery',
39
+			'toType'             => $this->namespace . 'Country',
40
+			'fromFieldName'      => lcfirst($this->namespace . 'Countries'),
41
+			'connectionTypeName' => "{$this->namespace}RootQueryCountriesConnection",
42
+			'connectionArgs'     => RootQueryCountriesConnection::get_connection_args(),
43
+			'resolve'            => [$this, 'resolveConnection'],
44
+		];
45
+	}
46 46
 
47 47
 
48
-    /**
49
-     * @param $entity
50
-     * @param $args
51
-     * @param $context
52
-     * @param $info
53
-     * @return CountryConnectionResolver
54
-     * @throws Exception
55
-     */
56
-    public function getConnectionResolver($entity, $args, $context, $info): AbstractConnectionResolver
57
-    {
58
-        return new CountryConnectionResolver($entity, $args, $context, $info);
59
-    }
48
+	/**
49
+	 * @param $entity
50
+	 * @param $args
51
+	 * @param $context
52
+	 * @param $info
53
+	 * @return CountryConnectionResolver
54
+	 * @throws Exception
55
+	 */
56
+	public function getConnectionResolver($entity, $args, $context, $info): AbstractConnectionResolver
57
+	{
58
+		return new CountryConnectionResolver($entity, $args, $context, $info);
59
+	}
60 60
 
61
-    /**
62
-     * Given an optional array of args, this returns the args to be used in the connection
63
-     *
64
-     * @param array $args The args to modify the defaults
65
-     * @return array
66
-     */
67
-    // phpcs:ignore PSR1.Methods.CamelCapsMethodName.NotCamelCaps
68
-    public static function get_connection_args(array $args = []): array
69
-    {
70
-        $newArgs = [
71
-            'orderby'      => [
72
-                'type'        => ['list_of' => 'EspressoCountriesConnectionOrderbyInput'],
73
-                'description' => esc_html__('What parameter to use to order the objects by.', 'event_espresso'),
74
-            ],
75
-            'in' => [
76
-                'type'        => ['list_of' => 'ID'],
77
-                'description' => esc_html__(
78
-                    'Limit the result to the set of given country IDs.',
79
-                    'event_espresso'
80
-                ),
81
-            ],
82
-            'isoIn' => [
83
-                'type'        => ['list_of' => 'String'],
84
-                'description' => esc_html__(
85
-                    'Limit the result to the set of given country ISOs.',
86
-                    'event_espresso'
87
-                ),
88
-            ],
89
-            'iso3In' => [
90
-                'type'        => ['list_of' => 'String'],
91
-                'description' => esc_html__(
92
-                    'Limit the result to the set of given country ISO3s.',
93
-                    'event_espresso'
94
-                ),
95
-            ],
96
-            'search' => [
97
-                'type'        => 'String',
98
-                'description' => esc_html__(
99
-                    'Limit the result to the given search query.',
100
-                    'event_espresso'
101
-                ),
102
-            ],
103
-            'activeOnly' => [
104
-                'type'        => 'Boolean',
105
-                'description' => esc_html__(
106
-                    'Limit the result to the active countries.',
107
-                    'event_espresso'
108
-                ),
109
-            ],
110
-        ];
61
+	/**
62
+	 * Given an optional array of args, this returns the args to be used in the connection
63
+	 *
64
+	 * @param array $args The args to modify the defaults
65
+	 * @return array
66
+	 */
67
+	// phpcs:ignore PSR1.Methods.CamelCapsMethodName.NotCamelCaps
68
+	public static function get_connection_args(array $args = []): array
69
+	{
70
+		$newArgs = [
71
+			'orderby'      => [
72
+				'type'        => ['list_of' => 'EspressoCountriesConnectionOrderbyInput'],
73
+				'description' => esc_html__('What parameter to use to order the objects by.', 'event_espresso'),
74
+			],
75
+			'in' => [
76
+				'type'        => ['list_of' => 'ID'],
77
+				'description' => esc_html__(
78
+					'Limit the result to the set of given country IDs.',
79
+					'event_espresso'
80
+				),
81
+			],
82
+			'isoIn' => [
83
+				'type'        => ['list_of' => 'String'],
84
+				'description' => esc_html__(
85
+					'Limit the result to the set of given country ISOs.',
86
+					'event_espresso'
87
+				),
88
+			],
89
+			'iso3In' => [
90
+				'type'        => ['list_of' => 'String'],
91
+				'description' => esc_html__(
92
+					'Limit the result to the set of given country ISO3s.',
93
+					'event_espresso'
94
+				),
95
+			],
96
+			'search' => [
97
+				'type'        => 'String',
98
+				'description' => esc_html__(
99
+					'Limit the result to the given search query.',
100
+					'event_espresso'
101
+				),
102
+			],
103
+			'activeOnly' => [
104
+				'type'        => 'Boolean',
105
+				'description' => esc_html__(
106
+					'Limit the result to the active countries.',
107
+					'event_espresso'
108
+				),
109
+			],
110
+		];
111 111
 
112
-        $newArgs = apply_filters(
113
-            'FHEE__EventEspresso_core_domain_services_graphql_connections__country_args',
114
-            $newArgs,
115
-            $args
116
-        );
117
-        return array_merge(
118
-            $newArgs,
119
-            $args
120
-        );
121
-    }
112
+		$newArgs = apply_filters(
113
+			'FHEE__EventEspresso_core_domain_services_graphql_connections__country_args',
114
+			$newArgs,
115
+			$args
116
+		);
117
+		return array_merge(
118
+			$newArgs,
119
+			$args
120
+		);
121
+	}
122 122
 }
Please login to merge, or discard this patch.
core/domain/services/graphql/inputs/StatesConnectionOrderbyInput.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -22,7 +22,7 @@  discard block
 block discarded – undo
22 22
      */
23 23
     public function __construct()
24 24
     {
25
-        $this->setName($this->namespace . 'StatesConnectionOrderbyInput');
25
+        $this->setName($this->namespace.'StatesConnectionOrderbyInput');
26 26
         $this->setDescription(esc_html__('Options for ordering the connection', 'event_espresso'));
27 27
         parent::__construct();
28 28
     }
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
         return [
37 37
             new GraphQLField(
38 38
                 'field',
39
-                ['non_null' => $this->namespace . 'StatesConnectionOrderbyEnum']
39
+                ['non_null' => $this->namespace.'StatesConnectionOrderbyEnum']
40 40
             ),
41 41
             new GraphQLField(
42 42
                 'order',
Please login to merge, or discard this patch.
Indentation   +25 added lines, -25 removed lines patch added patch discarded remove patch
@@ -16,31 +16,31 @@
 block discarded – undo
16 16
  */
17 17
 class StatesConnectionOrderbyInput extends InputBase
18 18
 {
19
-    /**
20
-     * StatesConnectionOrderbyInput constructor.
21
-     */
22
-    public function __construct()
23
-    {
24
-        $this->setName($this->namespace . 'StatesConnectionOrderbyInput');
25
-        $this->setDescription(esc_html__('Options for ordering the connection', 'event_espresso'));
26
-        parent::__construct();
27
-    }
19
+	/**
20
+	 * StatesConnectionOrderbyInput constructor.
21
+	 */
22
+	public function __construct()
23
+	{
24
+		$this->setName($this->namespace . 'StatesConnectionOrderbyInput');
25
+		$this->setDescription(esc_html__('Options for ordering the connection', 'event_espresso'));
26
+		parent::__construct();
27
+	}
28 28
 
29 29
 
30
-    /**
31
-     * @return GraphQLFieldInterface[]
32
-     */
33
-    protected function getFields(): array
34
-    {
35
-        return [
36
-            new GraphQLField(
37
-                'field',
38
-                ['non_null' => $this->namespace . 'StatesConnectionOrderbyEnum']
39
-            ),
40
-            new GraphQLField(
41
-                'order',
42
-                'OrderEnum'
43
-            ),
44
-        ];
45
-    }
30
+	/**
31
+	 * @return GraphQLFieldInterface[]
32
+	 */
33
+	protected function getFields(): array
34
+	{
35
+		return [
36
+			new GraphQLField(
37
+				'field',
38
+				['non_null' => $this->namespace . 'StatesConnectionOrderbyEnum']
39
+			),
40
+			new GraphQLField(
41
+				'order',
42
+				'OrderEnum'
43
+			),
44
+		];
45
+	}
46 46
 }
Please login to merge, or discard this patch.
core/domain/services/graphql/inputs/CountriesConnectionOrderbyInput.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -22,7 +22,7 @@  discard block
 block discarded – undo
22 22
      */
23 23
     public function __construct()
24 24
     {
25
-        $this->setName($this->namespace . 'CountriesConnectionOrderbyInput');
25
+        $this->setName($this->namespace.'CountriesConnectionOrderbyInput');
26 26
         $this->setDescription(esc_html__('Options for ordering the connection', 'event_espresso'));
27 27
         parent::__construct();
28 28
     }
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
         return [
37 37
             new GraphQLField(
38 38
                 'field',
39
-                ['non_null' => $this->namespace . 'CountriesConnectionOrderbyEnum']
39
+                ['non_null' => $this->namespace.'CountriesConnectionOrderbyEnum']
40 40
             ),
41 41
             new GraphQLField(
42 42
                 'order',
Please login to merge, or discard this patch.
Indentation   +25 added lines, -25 removed lines patch added patch discarded remove patch
@@ -16,31 +16,31 @@
 block discarded – undo
16 16
  */
17 17
 class CountriesConnectionOrderbyInput extends InputBase
18 18
 {
19
-    /**
20
-     * CountriesConnectionOrderbyInput constructor.
21
-     */
22
-    public function __construct()
23
-    {
24
-        $this->setName($this->namespace . 'CountriesConnectionOrderbyInput');
25
-        $this->setDescription(esc_html__('Options for ordering the connection', 'event_espresso'));
26
-        parent::__construct();
27
-    }
19
+	/**
20
+	 * CountriesConnectionOrderbyInput constructor.
21
+	 */
22
+	public function __construct()
23
+	{
24
+		$this->setName($this->namespace . 'CountriesConnectionOrderbyInput');
25
+		$this->setDescription(esc_html__('Options for ordering the connection', 'event_espresso'));
26
+		parent::__construct();
27
+	}
28 28
 
29 29
 
30
-    /**
31
-     * @return GraphQLFieldInterface[]
32
-     */
33
-    protected function getFields(): array
34
-    {
35
-        return [
36
-            new GraphQLField(
37
-                'field',
38
-                ['non_null' => $this->namespace . 'CountriesConnectionOrderbyEnum']
39
-            ),
40
-            new GraphQLField(
41
-                'order',
42
-                'OrderEnum'
43
-            ),
44
-        ];
45
-    }
30
+	/**
31
+	 * @return GraphQLFieldInterface[]
32
+	 */
33
+	protected function getFields(): array
34
+	{
35
+		return [
36
+			new GraphQLField(
37
+				'field',
38
+				['non_null' => $this->namespace . 'CountriesConnectionOrderbyEnum']
39
+			),
40
+			new GraphQLField(
41
+				'order',
42
+				'OrderEnum'
43
+			),
44
+		];
45
+	}
46 46
 }
Please login to merge, or discard this patch.