Completed
Branch dev (08e10f)
by
unknown
12:20 queued 10:12
created
core/domain/entities/admin/GraphQLData/GraphQLDataInterface.php 1 patch
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -12,10 +12,10 @@
 block discarded – undo
12 12
  */
13 13
 interface GraphQLDataInterface
14 14
 {
15
-    /**
16
-     * @param array $where_params
17
-     * @return array|null
18
-     * @since $VID:$
19
-     */
20
-    public function getData(array $where_params = []);
15
+	/**
16
+	 * @param array $where_params
17
+	 * @return array|null
18
+	 * @since $VID:$
19
+	 */
20
+	public function getData(array $where_params = []);
21 21
 }
Please login to merge, or discard this patch.
core/domain/values/assets/BrowserAsset.php 2 patches
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -110,7 +110,7 @@  discard block
 block discarded – undo
110 110
             if (is_int($key) && $this->validateAttribute($value)) {
111 111
                 $this->attributes[] = $value;
112 112
             } else if ($this->validateAttribute($key)) {
113
-                $this->attributes[ $key ] = $value;
113
+                $this->attributes[$key] = $value;
114 114
             }
115 115
         }
116 116
     }
@@ -124,8 +124,8 @@  discard block
 block discarded – undo
124 124
      */
125 125
     private function validateAttribute($attribute)
126 126
     {
127
-        $allowed = BrowserAsset::$allowed_attributes[ $this->type() ];
128
-        if (! in_array($attribute, $allowed, true)) {
127
+        $allowed = BrowserAsset::$allowed_attributes[$this->type()];
128
+        if ( ! in_array($attribute, $allowed, true)) {
129 129
             throw new DomainException(
130 130
                 sprintf(
131 131
                     esc_html__('Invalid attribute! The only allowed attributes are: "%1$s"', 'event_espresso'),
@@ -180,7 +180,7 @@  discard block
 block discarded – undo
180 180
      */
181 181
     private function setSource($source)
182 182
     {
183
-        if (! is_string($source)) {
183
+        if ( ! is_string($source)) {
184 184
             throw new InvalidDataTypeException(
185 185
                 '$source',
186 186
                 $source,
@@ -216,7 +216,7 @@  discard block
 block discarded – undo
216 216
         if (empty($version) && ! $this->isBuiltDistributionSource()) {
217 217
             $version = $this->domain->version();
218 218
         }
219
-        if (! is_string($version)) {
219
+        if ( ! is_string($version)) {
220 220
             throw new InvalidDataTypeException(
221 221
                 '$version',
222 222
                 $version,
Please login to merge, or discard this patch.
Indentation   +230 added lines, -230 removed lines patch added patch discarded remove patch
@@ -17,234 +17,234 @@
 block discarded – undo
17 17
 abstract class BrowserAsset extends Asset
18 18
 {
19 19
 
20
-    /**
21
-     * @var array $attributes
22
-     */
23
-    private $attributes = [];
24
-
25
-    /**
26
-     * @var array $allowed_attributes
27
-     */
28
-    private static $allowed_attributes = [
29
-        Asset::TYPE_CSS => [
30
-            'crossorigin',
31
-            'media',
32
-            'referrerpolicy',
33
-            'sizes',
34
-            'type',
35
-        ],
36
-        Asset::TYPE_JS => [
37
-            'async',
38
-            'charset',
39
-            'crossorigin',
40
-            'defer',
41
-            'type',
42
-        ]
43
-    ];
44
-
45
-    /**
46
-     * @var array $dependencies
47
-     */
48
-    private $dependencies;
49
-
50
-    /**
51
-     * @var string $source
52
-     */
53
-    private $source;
54
-
55
-    /**
56
-     * @var string $version
57
-     */
58
-    private $version;
59
-
60
-
61
-    /**
62
-     * Asset constructor.
63
-     *
64
-     * @param string          $type
65
-     * @param string          $handle
66
-     * @param string          $source
67
-     * @param array           $dependencies
68
-     * @param DomainInterface $domain
69
-     * @param string          $version
70
-     * @throws DomainException
71
-     * @throws InvalidDataTypeException
72
-     */
73
-    public function __construct($type, $handle, $source, array $dependencies, DomainInterface $domain, $version = '')
74
-    {
75
-        parent::__construct($type, $handle, $domain);
76
-        $this->setSource($source);
77
-        $this->setDependencies($dependencies);
78
-        $this->setVersion($version, false);
79
-    }
80
-
81
-
82
-    /**
83
-     * @since 4.9.62.p
84
-     */
85
-    abstract public function enqueueAsset();
86
-
87
-
88
-    /**
89
-     * @return array
90
-     */
91
-    public function getAttributes()
92
-    {
93
-        return $this->attributes;
94
-    }
95
-
96
-
97
-    /**
98
-     * @param array $attributes
99
-     * @throws DomainException
100
-     * @since $VID:$
101
-     */
102
-    public function addAttributes(array $attributes)
103
-    {
104
-        if (empty($attributes)) {
105
-            throw new DomainException(
106
-                esc_html__('The attributes array needs at least one value.', 'event_espresso')
107
-            );
108
-        }
109
-        foreach ($attributes as $key => $value) {
110
-            if (is_int($key) && $this->validateAttribute($value)) {
111
-                $this->attributes[] = $value;
112
-            } else if ($this->validateAttribute($key)) {
113
-                $this->attributes[ $key ] = $value;
114
-            }
115
-        }
116
-    }
117
-
118
-
119
-    /**
120
-     * @param string $attribute
121
-     * @return bool
122
-     * @throws DomainException
123
-     * @since $VID:$
124
-     */
125
-    private function validateAttribute($attribute)
126
-    {
127
-        $allowed = BrowserAsset::$allowed_attributes[ $this->type() ];
128
-        if (! in_array($attribute, $allowed, true)) {
129
-            throw new DomainException(
130
-                sprintf(
131
-                    esc_html__('Invalid attribute! The only allowed attributes are: "%1$s"', 'event_espresso'),
132
-                    implode('", "', $allowed)
133
-                )
134
-            );
135
-        }
136
-        return true;
137
-    }
138
-
139
-
140
-    /**
141
-     * @return array
142
-     */
143
-    public function dependencies()
144
-    {
145
-        return $this->dependencies;
146
-    }
147
-
148
-
149
-    /**
150
-     * @param array $dependencies
151
-     */
152
-    public function addDependencies(array $dependencies)
153
-    {
154
-        $this->dependencies = array_merge($this->dependencies, $dependencies);
155
-    }
156
-
157
-
158
-    /**
159
-     * @param array $dependencies
160
-     */
161
-    protected function setDependencies(array $dependencies)
162
-    {
163
-        $this->dependencies = $dependencies;
164
-    }
165
-
166
-
167
-    /**
168
-     * @since 4.9.62.p
169
-     * @return bool
170
-     */
171
-    public function hasDependencies()
172
-    {
173
-        return count($this->dependencies) > 0;
174
-    }
175
-
176
-
177
-    /**
178
-     * @return string
179
-     */
180
-    public function source()
181
-    {
182
-        return $this->source;
183
-    }
184
-
185
-
186
-    /**
187
-     * @param string $source
188
-     * @throws InvalidDataTypeException
189
-     */
190
-    private function setSource($source)
191
-    {
192
-        if (! is_string($source)) {
193
-            throw new InvalidDataTypeException(
194
-                '$source',
195
-                $source,
196
-                'string'
197
-            );
198
-        }
199
-        $this->source = $source;
200
-    }
201
-
202
-
203
-    /**
204
-     * @return string
205
-     * @throws InvalidDataTypeException
206
-     * @throws DomainException
207
-     */
208
-    public function version()
209
-    {
210
-        return $this->version;
211
-    }
212
-
213
-
214
-    /**
215
-     * @param string $version
216
-     * @param bool   $fluent
217
-     * @return BrowserAsset|null
218
-     * @throws DomainException
219
-     * @throws InvalidDataTypeException
220
-     */
221
-    public function setVersion($version, $fluent = true)
222
-    {
223
-        // if version is NOT set and this asset was NOT built for distribution,
224
-        // then set the version equal to the EE core plugin version
225
-        if (empty($version) && ! $this->isBuiltDistributionSource()) {
226
-            $version = $this->domain->version();
227
-        }
228
-        if (! is_string($version)) {
229
-            throw new InvalidDataTypeException(
230
-                '$version',
231
-                $version,
232
-                'string'
233
-            );
234
-        }
235
-        $this->version = $version;
236
-        if ($fluent) {
237
-            return $this;
238
-        }
239
-        return null;
240
-    }
241
-
242
-
243
-    /**
244
-     * @return bool
245
-     */
246
-    public function isBuiltDistributionSource() {
247
-        return substr($this->source, -8) === Asset::FILE_EXTENSION_DISTRIBUTION_JS
248
-               || substr($this->source, -9) === Asset::FILE_EXTENSION_DISTRIBUTION_CSS;
249
-    }
20
+	/**
21
+	 * @var array $attributes
22
+	 */
23
+	private $attributes = [];
24
+
25
+	/**
26
+	 * @var array $allowed_attributes
27
+	 */
28
+	private static $allowed_attributes = [
29
+		Asset::TYPE_CSS => [
30
+			'crossorigin',
31
+			'media',
32
+			'referrerpolicy',
33
+			'sizes',
34
+			'type',
35
+		],
36
+		Asset::TYPE_JS => [
37
+			'async',
38
+			'charset',
39
+			'crossorigin',
40
+			'defer',
41
+			'type',
42
+		]
43
+	];
44
+
45
+	/**
46
+	 * @var array $dependencies
47
+	 */
48
+	private $dependencies;
49
+
50
+	/**
51
+	 * @var string $source
52
+	 */
53
+	private $source;
54
+
55
+	/**
56
+	 * @var string $version
57
+	 */
58
+	private $version;
59
+
60
+
61
+	/**
62
+	 * Asset constructor.
63
+	 *
64
+	 * @param string          $type
65
+	 * @param string          $handle
66
+	 * @param string          $source
67
+	 * @param array           $dependencies
68
+	 * @param DomainInterface $domain
69
+	 * @param string          $version
70
+	 * @throws DomainException
71
+	 * @throws InvalidDataTypeException
72
+	 */
73
+	public function __construct($type, $handle, $source, array $dependencies, DomainInterface $domain, $version = '')
74
+	{
75
+		parent::__construct($type, $handle, $domain);
76
+		$this->setSource($source);
77
+		$this->setDependencies($dependencies);
78
+		$this->setVersion($version, false);
79
+	}
80
+
81
+
82
+	/**
83
+	 * @since 4.9.62.p
84
+	 */
85
+	abstract public function enqueueAsset();
86
+
87
+
88
+	/**
89
+	 * @return array
90
+	 */
91
+	public function getAttributes()
92
+	{
93
+		return $this->attributes;
94
+	}
95
+
96
+
97
+	/**
98
+	 * @param array $attributes
99
+	 * @throws DomainException
100
+	 * @since $VID:$
101
+	 */
102
+	public function addAttributes(array $attributes)
103
+	{
104
+		if (empty($attributes)) {
105
+			throw new DomainException(
106
+				esc_html__('The attributes array needs at least one value.', 'event_espresso')
107
+			);
108
+		}
109
+		foreach ($attributes as $key => $value) {
110
+			if (is_int($key) && $this->validateAttribute($value)) {
111
+				$this->attributes[] = $value;
112
+			} else if ($this->validateAttribute($key)) {
113
+				$this->attributes[ $key ] = $value;
114
+			}
115
+		}
116
+	}
117
+
118
+
119
+	/**
120
+	 * @param string $attribute
121
+	 * @return bool
122
+	 * @throws DomainException
123
+	 * @since $VID:$
124
+	 */
125
+	private function validateAttribute($attribute)
126
+	{
127
+		$allowed = BrowserAsset::$allowed_attributes[ $this->type() ];
128
+		if (! in_array($attribute, $allowed, true)) {
129
+			throw new DomainException(
130
+				sprintf(
131
+					esc_html__('Invalid attribute! The only allowed attributes are: "%1$s"', 'event_espresso'),
132
+					implode('", "', $allowed)
133
+				)
134
+			);
135
+		}
136
+		return true;
137
+	}
138
+
139
+
140
+	/**
141
+	 * @return array
142
+	 */
143
+	public function dependencies()
144
+	{
145
+		return $this->dependencies;
146
+	}
147
+
148
+
149
+	/**
150
+	 * @param array $dependencies
151
+	 */
152
+	public function addDependencies(array $dependencies)
153
+	{
154
+		$this->dependencies = array_merge($this->dependencies, $dependencies);
155
+	}
156
+
157
+
158
+	/**
159
+	 * @param array $dependencies
160
+	 */
161
+	protected function setDependencies(array $dependencies)
162
+	{
163
+		$this->dependencies = $dependencies;
164
+	}
165
+
166
+
167
+	/**
168
+	 * @since 4.9.62.p
169
+	 * @return bool
170
+	 */
171
+	public function hasDependencies()
172
+	{
173
+		return count($this->dependencies) > 0;
174
+	}
175
+
176
+
177
+	/**
178
+	 * @return string
179
+	 */
180
+	public function source()
181
+	{
182
+		return $this->source;
183
+	}
184
+
185
+
186
+	/**
187
+	 * @param string $source
188
+	 * @throws InvalidDataTypeException
189
+	 */
190
+	private function setSource($source)
191
+	{
192
+		if (! is_string($source)) {
193
+			throw new InvalidDataTypeException(
194
+				'$source',
195
+				$source,
196
+				'string'
197
+			);
198
+		}
199
+		$this->source = $source;
200
+	}
201
+
202
+
203
+	/**
204
+	 * @return string
205
+	 * @throws InvalidDataTypeException
206
+	 * @throws DomainException
207
+	 */
208
+	public function version()
209
+	{
210
+		return $this->version;
211
+	}
212
+
213
+
214
+	/**
215
+	 * @param string $version
216
+	 * @param bool   $fluent
217
+	 * @return BrowserAsset|null
218
+	 * @throws DomainException
219
+	 * @throws InvalidDataTypeException
220
+	 */
221
+	public function setVersion($version, $fluent = true)
222
+	{
223
+		// if version is NOT set and this asset was NOT built for distribution,
224
+		// then set the version equal to the EE core plugin version
225
+		if (empty($version) && ! $this->isBuiltDistributionSource()) {
226
+			$version = $this->domain->version();
227
+		}
228
+		if (! is_string($version)) {
229
+			throw new InvalidDataTypeException(
230
+				'$version',
231
+				$version,
232
+				'string'
233
+			);
234
+		}
235
+		$this->version = $version;
236
+		if ($fluent) {
237
+			return $this;
238
+		}
239
+		return null;
240
+	}
241
+
242
+
243
+	/**
244
+	 * @return bool
245
+	 */
246
+	public function isBuiltDistributionSource() {
247
+		return substr($this->source, -8) === Asset::FILE_EXTENSION_DISTRIBUTION_JS
248
+			   || substr($this->source, -9) === Asset::FILE_EXTENSION_DISTRIBUTION_CSS;
249
+	}
250 250
 }
Please login to merge, or discard this patch.
core/domain/services/graphql/enums/RegistrationStatusEnum.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@
 block discarded – undo
21 21
      */
22 22
     public function __construct()
23 23
     {
24
-        $this->setName($this->namespace . 'RegistrationStatusEnum');
24
+        $this->setName($this->namespace.'RegistrationStatusEnum');
25 25
         $this->setDescription(esc_html__('Registration status', 'event_espresso'));
26 26
         parent::__construct();
27 27
     }
Please login to merge, or discard this patch.
Indentation   +38 added lines, -38 removed lines patch added patch discarded remove patch
@@ -16,44 +16,44 @@
 block discarded – undo
16 16
 class RegistrationStatusEnum extends EnumBase
17 17
 {
18 18
 
19
-    /**
20
-     * RegistrationStatusEnum constructor.
21
-     */
22
-    public function __construct()
23
-    {
24
-        $this->setName($this->namespace . 'RegistrationStatusEnum');
25
-        $this->setDescription(esc_html__('Registration status', 'event_espresso'));
26
-        parent::__construct();
27
-    }
19
+	/**
20
+	 * RegistrationStatusEnum constructor.
21
+	 */
22
+	public function __construct()
23
+	{
24
+		$this->setName($this->namespace . 'RegistrationStatusEnum');
25
+		$this->setDescription(esc_html__('Registration status', 'event_espresso'));
26
+		parent::__construct();
27
+	}
28 28
 
29 29
 
30
-    /**
31
-     * @return array
32
-     */
33
-    protected function getValues(): array
34
-    {
35
-        return [
36
-            'APPROVED'        => [
37
-                'value' => EEM_Registration::status_id_approved,
38
-            ],
39
-            'CANCELLED'       => [
40
-                'value' => EEM_Registration::status_id_cancelled,
41
-            ],
42
-            'DECLINED'        => [
43
-                'value' => EEM_Registration::status_id_declined,
44
-            ],
45
-            'INCOMPLETE'      => [
46
-                'value' => EEM_Registration::status_id_incomplete,
47
-            ],
48
-            'PENDING_PAYMENT' => [
49
-                'value' => EEM_Registration::status_id_pending_payment,
50
-            ],
51
-            'UNAPPROVED'      => [
52
-                'value' => EEM_Registration::status_id_not_approved,
53
-            ],
54
-            'WAIT_LIST'       => [
55
-                'value' => EEM_Registration::status_id_wait_list,
56
-            ],
57
-        ];
58
-    }
30
+	/**
31
+	 * @return array
32
+	 */
33
+	protected function getValues(): array
34
+	{
35
+		return [
36
+			'APPROVED'        => [
37
+				'value' => EEM_Registration::status_id_approved,
38
+			],
39
+			'CANCELLED'       => [
40
+				'value' => EEM_Registration::status_id_cancelled,
41
+			],
42
+			'DECLINED'        => [
43
+				'value' => EEM_Registration::status_id_declined,
44
+			],
45
+			'INCOMPLETE'      => [
46
+				'value' => EEM_Registration::status_id_incomplete,
47
+			],
48
+			'PENDING_PAYMENT' => [
49
+				'value' => EEM_Registration::status_id_pending_payment,
50
+			],
51
+			'UNAPPROVED'      => [
52
+				'value' => EEM_Registration::status_id_not_approved,
53
+			],
54
+			'WAIT_LIST'       => [
55
+				'value' => EEM_Registration::status_id_wait_list,
56
+			],
57
+		];
58
+	}
59 59
 }
Please login to merge, or discard this patch.
core/domain/services/graphql/enums/AttendeesConnectionOrderbyEnum.php 2 patches
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
      */
21 21
     public function __construct()
22 22
     {
23
-        $this->setName($this->namespace . 'AttendeesConnectionOrderbyEnum');
23
+        $this->setName($this->namespace.'AttendeesConnectionOrderbyEnum');
24 24
         $this->setDescription(esc_html__('Field to order the connection by', 'event_espresso'));
25 25
         parent::__construct();
26 26
     }
Please login to merge, or discard this patch.
Indentation   +29 added lines, -29 removed lines patch added patch discarded remove patch
@@ -15,35 +15,35 @@
 block discarded – undo
15 15
 class AttendeesConnectionOrderbyEnum extends EnumBase
16 16
 {
17 17
 
18
-    /**
19
-     * AttendeesConnectionOrderbyEnum constructor.
20
-     */
21
-    public function __construct()
22
-    {
23
-        $this->setName($this->namespace . 'AttendeesConnectionOrderbyEnum');
24
-        $this->setDescription(esc_html__('Field to order the connection by', 'event_espresso'));
25
-        parent::__construct();
26
-    }
18
+	/**
19
+	 * AttendeesConnectionOrderbyEnum constructor.
20
+	 */
21
+	public function __construct()
22
+	{
23
+		$this->setName($this->namespace . 'AttendeesConnectionOrderbyEnum');
24
+		$this->setDescription(esc_html__('Field to order the connection by', 'event_espresso'));
25
+		parent::__construct();
26
+	}
27 27
 
28 28
 
29
-    /**
30
-     * @return array
31
-     */
32
-    protected function getValues(): array
33
-    {
34
-        return [
35
-            'ID'     => [
36
-                'value'       => 'ATT_ID',
37
-                'description' => esc_html__('Order by ID', 'event_espresso'),
38
-            ],
39
-            'LAST_NAME'     => [
40
-                'value'       => 'ATT_lname',
41
-                'description' => esc_html__('Order by last name', 'event_espresso'),
42
-            ],
43
-            'FIRST_NAME'     => [
44
-                'value'       => 'ATT_fname',
45
-                'description' => esc_html__('Order by first name', 'event_espresso'),
46
-            ],
47
-        ];
48
-    }
29
+	/**
30
+	 * @return array
31
+	 */
32
+	protected function getValues(): array
33
+	{
34
+		return [
35
+			'ID'     => [
36
+				'value'       => 'ATT_ID',
37
+				'description' => esc_html__('Order by ID', 'event_espresso'),
38
+			],
39
+			'LAST_NAME'     => [
40
+				'value'       => 'ATT_lname',
41
+				'description' => esc_html__('Order by last name', 'event_espresso'),
42
+			],
43
+			'FIRST_NAME'     => [
44
+				'value'       => 'ATT_fname',
45
+				'description' => esc_html__('Order by first name', 'event_espresso'),
46
+			],
47
+		];
48
+	}
49 49
 }
Please login to merge, or discard this patch.
core/domain/services/graphql/connections/RootQueryAttendeesConnection.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 . 'Attendee',
42
-            'fromFieldName'      => lcfirst($this->namespace) . 'Attendees',
41
+            'toType'             => $this->namespace.'Attendee',
42
+            'fromFieldName'      => lcfirst($this->namespace).'Attendees',
43 43
             'connectionTypeName' => "{$this->namespace}RootQueryAttendeesConnection",
44 44
             'connectionArgs'     => self::get_connection_args(),
45 45
             'resolve'            => [$this, 'resolveConnection'],
Please login to merge, or discard this patch.
Indentation   +118 added lines, -118 removed lines patch added patch discarded remove patch
@@ -20,128 +20,128 @@
 block discarded – undo
20 20
 {
21 21
 
22 22
 
23
-    /**
24
-     * AttendeeConnection constructor.
25
-     *
26
-     * @param EEM_Attendee               $model
27
-     */
28
-    public function __construct(EEM_Attendee $model)
29
-    {
30
-        parent::__construct($model);
31
-    }
23
+	/**
24
+	 * AttendeeConnection constructor.
25
+	 *
26
+	 * @param EEM_Attendee               $model
27
+	 */
28
+	public function __construct(EEM_Attendee $model)
29
+	{
30
+		parent::__construct($model);
31
+	}
32 32
 
33 33
 
34
-    /**
35
-     * @return array
36
-     */
37
-    public function config(): array
38
-    {
39
-        return [
40
-            'fromType'           => 'RootQuery',
41
-            'toType'             => $this->namespace . 'Attendee',
42
-            'fromFieldName'      => lcfirst($this->namespace) . 'Attendees',
43
-            'connectionTypeName' => "{$this->namespace}RootQueryAttendeesConnection",
44
-            'connectionArgs'     => self::get_connection_args(),
45
-            'resolve'            => [$this, 'resolveConnection'],
46
-        ];
47
-    }
34
+	/**
35
+	 * @return array
36
+	 */
37
+	public function config(): array
38
+	{
39
+		return [
40
+			'fromType'           => 'RootQuery',
41
+			'toType'             => $this->namespace . 'Attendee',
42
+			'fromFieldName'      => lcfirst($this->namespace) . 'Attendees',
43
+			'connectionTypeName' => "{$this->namespace}RootQueryAttendeesConnection",
44
+			'connectionArgs'     => self::get_connection_args(),
45
+			'resolve'            => [$this, 'resolveConnection'],
46
+		];
47
+	}
48 48
 
49 49
 
50
-    /**
51
-     * @param $entity
52
-     * @param $args
53
-     * @param $context
54
-     * @param $info
55
-     * @return AttendeeConnectionResolver
56
-     * @throws Exception
57
-     */
58
-    public function getConnectionResolver($entity, $args, $context, $info): AbstractConnectionResolver
59
-    {
60
-        return new AttendeeConnectionResolver($entity, $args, $context, $info);
61
-    }
50
+	/**
51
+	 * @param $entity
52
+	 * @param $args
53
+	 * @param $context
54
+	 * @param $info
55
+	 * @return AttendeeConnectionResolver
56
+	 * @throws Exception
57
+	 */
58
+	public function getConnectionResolver($entity, $args, $context, $info): AbstractConnectionResolver
59
+	{
60
+		return new AttendeeConnectionResolver($entity, $args, $context, $info);
61
+	}
62 62
 
63
-    /**
64
-     * Given an optional array of args, this returns the args to be used in the connection
65
-     *
66
-     * @param array $args The args to modify the defaults
67
-     * @return array
68
-     */
69
-    // phpcs:ignore PSR1.Methods.CamelCapsMethodName.NotCamelCaps
70
-    public static function get_connection_args(array $args = []): array
71
-    {
72
-        $newArgs = [
73
-            'datetime' => [
74
-                'type'        => 'ID',
75
-                'description' => esc_html__(
76
-                    'Globally unique datetime ID to get the attendees for.',
77
-                    'event_espresso'
78
-                ),
79
-            ],
80
-            'datetimeIn' => [
81
-                'type'        => ['list_of' => 'ID'],
82
-                'description' => esc_html__(
83
-                    'Globally unique datetime IDs to get the attendees for.',
84
-                    'event_espresso'
85
-                ),
86
-            ],
87
-            'event' => [
88
-                'type'        => 'ID',
89
-                'description' => esc_html__(
90
-                    'Globally unique event ID to get the attendees for.',
91
-                    'event_espresso'
92
-                ),
93
-            ],
94
-            'eventIn' => [
95
-                'type'        => ['list_of' => 'ID'],
96
-                'description' => esc_html__(
97
-                    'Globally unique event IDs to get the attendees for.',
98
-                    'event_espresso'
99
-                ),
100
-            ],
101
-            'orderby'      => [
102
-                'type'        => ['list_of' => 'EspressoAttendeesConnectionOrderbyInput'],
103
-                'description' => esc_html__('What parameter to use to order the objects by.', 'event_espresso'),
104
-            ],
105
-            'regTicket' => [
106
-                'type'        => 'ID',
107
-                'description' => esc_html__(
108
-                    'Globally unique registration ticket ID to get the attendees for.',
109
-                    'event_espresso'
110
-                ),
111
-            ],
112
-            'regTicketIn' => [
113
-                'type'        => ['list_of' => 'ID'],
114
-                'description' => esc_html__(
115
-                    'Globally unique registration ticket IDs to get the attendees for.',
116
-                    'event_espresso'
117
-                ),
118
-            ],
119
-            'regTicketId' => [
120
-                'type'        => 'Int',
121
-                'description' => esc_html__('Registration ticket ID to get the attendees for.', 'event_espresso'),
122
-            ],
123
-            'regTicketIdIn' => [
124
-                'type'        => ['list_of' => 'Int'],
125
-                'description' => esc_html__('Registration ticket IDs to get the attendees for.', 'event_espresso'),
126
-            ],
127
-            'regStatus' => [
128
-                'type'        => 'EspressoRegistrationStatusEnum',
129
-                'description' => esc_html__('Limit attendees to registration status.', 'event_espresso'),
130
-            ],
131
-            'search' => [
132
-                'type'        => 'String',
133
-                'description' => esc_html__('The search keywords', 'event_espresso'),
134
-            ],
135
-        ];
63
+	/**
64
+	 * Given an optional array of args, this returns the args to be used in the connection
65
+	 *
66
+	 * @param array $args The args to modify the defaults
67
+	 * @return array
68
+	 */
69
+	// phpcs:ignore PSR1.Methods.CamelCapsMethodName.NotCamelCaps
70
+	public static function get_connection_args(array $args = []): array
71
+	{
72
+		$newArgs = [
73
+			'datetime' => [
74
+				'type'        => 'ID',
75
+				'description' => esc_html__(
76
+					'Globally unique datetime ID to get the attendees for.',
77
+					'event_espresso'
78
+				),
79
+			],
80
+			'datetimeIn' => [
81
+				'type'        => ['list_of' => 'ID'],
82
+				'description' => esc_html__(
83
+					'Globally unique datetime IDs to get the attendees for.',
84
+					'event_espresso'
85
+				),
86
+			],
87
+			'event' => [
88
+				'type'        => 'ID',
89
+				'description' => esc_html__(
90
+					'Globally unique event ID to get the attendees for.',
91
+					'event_espresso'
92
+				),
93
+			],
94
+			'eventIn' => [
95
+				'type'        => ['list_of' => 'ID'],
96
+				'description' => esc_html__(
97
+					'Globally unique event IDs to get the attendees for.',
98
+					'event_espresso'
99
+				),
100
+			],
101
+			'orderby'      => [
102
+				'type'        => ['list_of' => 'EspressoAttendeesConnectionOrderbyInput'],
103
+				'description' => esc_html__('What parameter to use to order the objects by.', 'event_espresso'),
104
+			],
105
+			'regTicket' => [
106
+				'type'        => 'ID',
107
+				'description' => esc_html__(
108
+					'Globally unique registration ticket ID to get the attendees for.',
109
+					'event_espresso'
110
+				),
111
+			],
112
+			'regTicketIn' => [
113
+				'type'        => ['list_of' => 'ID'],
114
+				'description' => esc_html__(
115
+					'Globally unique registration ticket IDs to get the attendees for.',
116
+					'event_espresso'
117
+				),
118
+			],
119
+			'regTicketId' => [
120
+				'type'        => 'Int',
121
+				'description' => esc_html__('Registration ticket ID to get the attendees for.', 'event_espresso'),
122
+			],
123
+			'regTicketIdIn' => [
124
+				'type'        => ['list_of' => 'Int'],
125
+				'description' => esc_html__('Registration ticket IDs to get the attendees for.', 'event_espresso'),
126
+			],
127
+			'regStatus' => [
128
+				'type'        => 'EspressoRegistrationStatusEnum',
129
+				'description' => esc_html__('Limit attendees to registration status.', 'event_espresso'),
130
+			],
131
+			'search' => [
132
+				'type'        => 'String',
133
+				'description' => esc_html__('The search keywords', 'event_espresso'),
134
+			],
135
+		];
136 136
 
137
-        $newArgs = apply_filters(
138
-            'FHEE__EventEspresso_core_domain_services_graphql_connections__attendee_args',
139
-            $newArgs,
140
-            $args
141
-        );
142
-        return array_merge(
143
-            $newArgs,
144
-            $args
145
-        );
146
-    }
137
+		$newArgs = apply_filters(
138
+			'FHEE__EventEspresso_core_domain_services_graphql_connections__attendee_args',
139
+			$newArgs,
140
+			$args
141
+		);
142
+		return array_merge(
143
+			$newArgs,
144
+			$args
145
+		);
146
+	}
147 147
 }
Please login to merge, or discard this patch.
core/domain/services/graphql/inputs/AttendeesConnectionOrderbyInput.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@  discard block
 block discarded – undo
24 24
      */
25 25
     public function __construct()
26 26
     {
27
-        $this->setName($this->namespace . 'AttendeesConnectionOrderbyInput');
27
+        $this->setName($this->namespace.'AttendeesConnectionOrderbyInput');
28 28
         $this->setDescription(esc_html__('Options for ordering the connection', 'event_espresso'));
29 29
         parent::__construct();
30 30
     }
@@ -39,7 +39,7 @@  discard block
 block discarded – undo
39 39
         return [
40 40
             new GraphQLField(
41 41
                 'field',
42
-                ['non_null' => $this->namespace . 'AttendeesConnectionOrderbyEnum']
42
+                ['non_null' => $this->namespace.'AttendeesConnectionOrderbyEnum']
43 43
             ),
44 44
             new GraphQLField(
45 45
                 'order',
Please login to merge, or discard this patch.
Indentation   +25 added lines, -25 removed lines patch added patch discarded remove patch
@@ -17,31 +17,31 @@
 block discarded – undo
17 17
 class AttendeesConnectionOrderbyInput extends InputBase
18 18
 {
19 19
 
20
-    /**
21
-     * AttendeesConnectionOrderbyInput constructor.
22
-     */
23
-    public function __construct()
24
-    {
25
-        $this->setName($this->namespace . 'AttendeesConnectionOrderbyInput');
26
-        $this->setDescription(esc_html__('Options for ordering the connection', 'event_espresso'));
27
-        parent::__construct();
28
-    }
20
+	/**
21
+	 * AttendeesConnectionOrderbyInput constructor.
22
+	 */
23
+	public function __construct()
24
+	{
25
+		$this->setName($this->namespace . 'AttendeesConnectionOrderbyInput');
26
+		$this->setDescription(esc_html__('Options for ordering the connection', 'event_espresso'));
27
+		parent::__construct();
28
+	}
29 29
 
30 30
 
31
-    /**
32
-     * @return GraphQLFieldInterface[]
33
-     */
34
-    protected function getFields(): array
35
-    {
36
-        return [
37
-            new GraphQLField(
38
-                'field',
39
-                ['non_null' => $this->namespace . 'AttendeesConnectionOrderbyEnum']
40
-            ),
41
-            new GraphQLField(
42
-                'order',
43
-                'OrderEnum'
44
-            ),
45
-        ];
46
-    }
31
+	/**
32
+	 * @return GraphQLFieldInterface[]
33
+	 */
34
+	protected function getFields(): array
35
+	{
36
+		return [
37
+			new GraphQLField(
38
+				'field',
39
+				['non_null' => $this->namespace . 'AttendeesConnectionOrderbyEnum']
40
+			),
41
+			new GraphQLField(
42
+				'order',
43
+				'OrderEnum'
44
+			),
45
+		];
46
+	}
47 47
 }
Please login to merge, or discard this patch.
core/domain/entities/admin/GraphQLData/Prices.php 2 patches
Indentation   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -13,15 +13,15 @@  discard block
 block discarded – undo
13 13
 class Prices extends GraphQLData
14 14
 {
15 15
 
16
-    /**
17
-     * @param array $where_params
18
-     * @return array|null
19
-     * @since $VID:$
20
-     */
21
-    public function getData(array $where_params = [])
22
-    {
23
-        $field_key = lcfirst($this->namespace) . 'Prices';
24
-        $query = <<<QUERY
16
+	/**
17
+	 * @param array $where_params
18
+	 * @return array|null
19
+	 * @since $VID:$
20
+	 */
21
+	public function getData(array $where_params = [])
22
+	{
23
+		$field_key = lcfirst($this->namespace) . 'Prices';
24
+		$query = <<<QUERY
25 25
         query GET_PRICES(\$where: {$this->namespace}RootQueryPricesConnectionWhereArgs, \$first: Int, \$last: Int ) {
26 26
             {$field_key}(where: \$where, first: \$first, last: \$last) {
27 27
                 nodes {
@@ -45,14 +45,14 @@  discard block
 block discarded – undo
45 45
             }
46 46
         }
47 47
 QUERY;
48
-        $this->setParams([
49
-            'operation_name' => 'GET_PRICES',
50
-            'variables'      => [
51
-                'first' => 100,
52
-            ],
53
-            'query'          => $query,
54
-        ]);
48
+		$this->setParams([
49
+			'operation_name' => 'GET_PRICES',
50
+			'variables'      => [
51
+				'first' => 100,
52
+			],
53
+			'query'          => $query,
54
+		]);
55 55
 
56
-        return $this->getQueryResponse($field_key, $where_params);
57
-    }
56
+		return $this->getQueryResponse($field_key, $where_params);
57
+	}
58 58
 }
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
      */
21 21
     public function getData(array $where_params = [])
22 22
     {
23
-        $field_key = lcfirst($this->namespace) . 'Prices';
23
+        $field_key = lcfirst($this->namespace).'Prices';
24 24
         $query = <<<QUERY
25 25
         query GET_PRICES(\$where: {$this->namespace}RootQueryPricesConnectionWhereArgs, \$first: Int, \$last: Int ) {
26 26
             {$field_key}(where: \$where, first: \$first, last: \$last) {
Please login to merge, or discard this patch.
core/domain/entities/admin/GraphQLData/Tickets.php 2 patches
Indentation   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -13,15 +13,15 @@  discard block
 block discarded – undo
13 13
 class Tickets extends GraphQLData
14 14
 {
15 15
 
16
-    /**
17
-     * @param array $where_params
18
-     * @return array|null
19
-     * @since $VID:$
20
-     */
21
-    public function getData(array $where_params = [])
22
-    {
23
-        $field_key = lcfirst($this->namespace) . 'Tickets';
24
-        $query = <<<QUERY
16
+	/**
17
+	 * @param array $where_params
18
+	 * @return array|null
19
+	 * @since $VID:$
20
+	 */
21
+	public function getData(array $where_params = [])
22
+	{
23
+		$field_key = lcfirst($this->namespace) . 'Tickets';
24
+		$query = <<<QUERY
25 25
         query GET_TICKETS(\$where: {$this->namespace}RootQueryTicketsConnectionWhereArgs, \$first: Int, \$last: Int ) {
26 26
             {$field_key}(where: \$where, first: \$first, last: \$last) {
27 27
                 nodes {
@@ -57,14 +57,14 @@  discard block
 block discarded – undo
57 57
             }
58 58
         }
59 59
 QUERY;
60
-        $this->setParams([
61
-            'operation_name' => 'GET_TICKETS',
62
-            'variables'      => [
63
-                'first' => 100,
64
-            ],
65
-            'query'          => $query,
66
-        ]);
60
+		$this->setParams([
61
+			'operation_name' => 'GET_TICKETS',
62
+			'variables'      => [
63
+				'first' => 100,
64
+			],
65
+			'query'          => $query,
66
+		]);
67 67
 
68
-        return $this->getQueryResponse($field_key, $where_params);
69
-    }
68
+		return $this->getQueryResponse($field_key, $where_params);
69
+	}
70 70
 }
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
      */
21 21
     public function getData(array $where_params = [])
22 22
     {
23
-        $field_key = lcfirst($this->namespace) . 'Tickets';
23
+        $field_key = lcfirst($this->namespace).'Tickets';
24 24
         $query = <<<QUERY
25 25
         query GET_TICKETS(\$where: {$this->namespace}RootQueryTicketsConnectionWhereArgs, \$first: Int, \$last: Int ) {
26 26
             {$field_key}(where: \$where, first: \$first, last: \$last) {
Please login to merge, or discard this patch.
core/domain/entities/admin/GraphQLData/PriceTypes.php 2 patches
Indentation   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -13,15 +13,15 @@  discard block
 block discarded – undo
13 13
 class PriceTypes extends GraphQLData
14 14
 {
15 15
 
16
-    /**
17
-     * @param array $where_params
18
-     * @return array|null
19
-     * @since $VID:$
20
-     */
21
-    public function getData(array $where_params = [])
22
-    {
23
-        $field_key = lcfirst($this->namespace) . 'PriceTypes';
24
-        $query = <<<QUERY
16
+	/**
17
+	 * @param array $where_params
18
+	 * @return array|null
19
+	 * @since $VID:$
20
+	 */
21
+	public function getData(array $where_params = [])
22
+	{
23
+		$field_key = lcfirst($this->namespace) . 'PriceTypes';
24
+		$query = <<<QUERY
25 25
         query GET_PRICE_TYPES(\$first: Int, \$last: Int ) {
26 26
             {$field_key}(first: \$first, last: \$last) {
27 27
                 nodes {
@@ -42,14 +42,14 @@  discard block
 block discarded – undo
42 42
             }
43 43
         }
44 44
 QUERY;
45
-        $this->setParams([
46
-            'operation_name' => 'GET_PRICE_TYPES',
47
-            'variables'      => [
48
-                'first' => 100,
49
-            ],
50
-            'query'          => $query,
51
-        ]);
45
+		$this->setParams([
46
+			'operation_name' => 'GET_PRICE_TYPES',
47
+			'variables'      => [
48
+				'first' => 100,
49
+			],
50
+			'query'          => $query,
51
+		]);
52 52
 
53
-        return $this->getQueryResponse($field_key, $where_params);
54
-    }
53
+		return $this->getQueryResponse($field_key, $where_params);
54
+	}
55 55
 }
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -20,7 +20,7 @@
 block discarded – undo
20 20
      */
21 21
     public function getData(array $where_params = [])
22 22
     {
23
-        $field_key = lcfirst($this->namespace) . 'PriceTypes';
23
+        $field_key = lcfirst($this->namespace).'PriceTypes';
24 24
         $query = <<<QUERY
25 25
         query GET_PRICE_TYPES(\$first: Int, \$last: Int ) {
26 26
             {$field_key}(first: \$first, last: \$last) {
Please login to merge, or discard this patch.