@@ -21,7 +21,7 @@ |
||
21 | 21 | */ |
22 | 22 | public function __construct() |
23 | 23 | { |
24 | - $this->setName($this->namespace . 'PriceBaseTypeEnum'); |
|
24 | + $this->setName($this->namespace.'PriceBaseTypeEnum'); |
|
25 | 25 | $this->setDescription(esc_html__('Price Base type ID', 'event_espresso')); |
26 | 26 | parent::__construct(); |
27 | 27 | } |
@@ -15,35 +15,35 @@ |
||
15 | 15 | */ |
16 | 16 | class PriceBaseTypeEnum extends EnumBase |
17 | 17 | { |
18 | - /** |
|
19 | - * PriceBaseTypeEnum constructor. |
|
20 | - */ |
|
21 | - public function __construct() |
|
22 | - { |
|
23 | - $this->setName($this->namespace . 'PriceBaseTypeEnum'); |
|
24 | - $this->setDescription(esc_html__('Price Base type ID', 'event_espresso')); |
|
25 | - parent::__construct(); |
|
26 | - } |
|
18 | + /** |
|
19 | + * PriceBaseTypeEnum constructor. |
|
20 | + */ |
|
21 | + public function __construct() |
|
22 | + { |
|
23 | + $this->setName($this->namespace . 'PriceBaseTypeEnum'); |
|
24 | + $this->setDescription(esc_html__('Price Base type ID', 'event_espresso')); |
|
25 | + parent::__construct(); |
|
26 | + } |
|
27 | 27 | |
28 | 28 | |
29 | - /** |
|
30 | - * @return array |
|
31 | - */ |
|
32 | - protected function getValues(): array |
|
33 | - { |
|
34 | - return [ |
|
35 | - 'BASE_PRICE' => [ |
|
36 | - 'value' => EEM_Price_Type::base_type_base_price, |
|
37 | - ], |
|
38 | - 'DISCOUNT' => [ |
|
39 | - 'value' => EEM_Price_Type::base_type_discount, |
|
40 | - ], |
|
41 | - 'SURCHARGE' => [ |
|
42 | - 'value' => EEM_Price_Type::base_type_surcharge, |
|
43 | - ], |
|
44 | - 'TAX' => [ |
|
45 | - 'value' => EEM_Price_Type::base_type_tax, |
|
46 | - ], |
|
47 | - ]; |
|
48 | - } |
|
29 | + /** |
|
30 | + * @return array |
|
31 | + */ |
|
32 | + protected function getValues(): array |
|
33 | + { |
|
34 | + return [ |
|
35 | + 'BASE_PRICE' => [ |
|
36 | + 'value' => EEM_Price_Type::base_type_base_price, |
|
37 | + ], |
|
38 | + 'DISCOUNT' => [ |
|
39 | + 'value' => EEM_Price_Type::base_type_discount, |
|
40 | + ], |
|
41 | + 'SURCHARGE' => [ |
|
42 | + 'value' => EEM_Price_Type::base_type_surcharge, |
|
43 | + ], |
|
44 | + 'TAX' => [ |
|
45 | + 'value' => EEM_Price_Type::base_type_tax, |
|
46 | + ], |
|
47 | + ]; |
|
48 | + } |
|
49 | 49 | } |
@@ -24,7 +24,7 @@ discard block |
||
24 | 24 | */ |
25 | 25 | public function __construct() |
26 | 26 | { |
27 | - $this->setName($this->namespace . 'DatetimesConnectionOrderbyInput'); |
|
27 | + $this->setName($this->namespace.'DatetimesConnectionOrderbyInput'); |
|
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 |
||
39 | 39 | return [ |
40 | 40 | new GraphQLField( |
41 | 41 | 'field', |
42 | - ['non_null' => $this->namespace . 'DatetimesConnectionOrderbyEnum'] |
|
42 | + ['non_null' => $this->namespace.'DatetimesConnectionOrderbyEnum'] |
|
43 | 43 | ), |
44 | 44 | new GraphQLField( |
45 | 45 | 'order', |
@@ -16,31 +16,31 @@ |
||
16 | 16 | */ |
17 | 17 | class DatetimesConnectionOrderbyInput extends InputBase |
18 | 18 | { |
19 | - /** |
|
20 | - * DatetimesConnectionOrderbyInput constructor. |
|
21 | - */ |
|
22 | - public function __construct() |
|
23 | - { |
|
24 | - $this->setName($this->namespace . 'DatetimesConnectionOrderbyInput'); |
|
25 | - $this->setDescription(esc_html__('Options for ordering the connection', 'event_espresso')); |
|
26 | - parent::__construct(); |
|
27 | - } |
|
19 | + /** |
|
20 | + * DatetimesConnectionOrderbyInput constructor. |
|
21 | + */ |
|
22 | + public function __construct() |
|
23 | + { |
|
24 | + $this->setName($this->namespace . 'DatetimesConnectionOrderbyInput'); |
|
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 . 'DatetimesConnectionOrderbyEnum'] |
|
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 . 'DatetimesConnectionOrderbyEnum'] |
|
39 | + ), |
|
40 | + new GraphQLField( |
|
41 | + 'order', |
|
42 | + 'OrderEnum' |
|
43 | + ), |
|
44 | + ]; |
|
45 | + } |
|
46 | 46 | } |
@@ -24,7 +24,7 @@ discard block |
||
24 | 24 | */ |
25 | 25 | public function __construct() |
26 | 26 | { |
27 | - $this->setName($this->namespace . 'TicketsConnectionOrderbyInput'); |
|
27 | + $this->setName($this->namespace.'TicketsConnectionOrderbyInput'); |
|
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 |
||
39 | 39 | return [ |
40 | 40 | new GraphQLField( |
41 | 41 | 'field', |
42 | - ['non_null' => $this->namespace . 'TicketsConnectionOrderbyEnum'] |
|
42 | + ['non_null' => $this->namespace.'TicketsConnectionOrderbyEnum'] |
|
43 | 43 | ), |
44 | 44 | new GraphQLField( |
45 | 45 | 'order', |
@@ -16,31 +16,31 @@ |
||
16 | 16 | */ |
17 | 17 | class TicketsConnectionOrderbyInput extends InputBase |
18 | 18 | { |
19 | - /** |
|
20 | - * TicketsConnectionOrderbyInput constructor. |
|
21 | - */ |
|
22 | - public function __construct() |
|
23 | - { |
|
24 | - $this->setName($this->namespace . 'TicketsConnectionOrderbyInput'); |
|
25 | - $this->setDescription(esc_html__('Options for ordering the connection', 'event_espresso')); |
|
26 | - parent::__construct(); |
|
27 | - } |
|
19 | + /** |
|
20 | + * TicketsConnectionOrderbyInput constructor. |
|
21 | + */ |
|
22 | + public function __construct() |
|
23 | + { |
|
24 | + $this->setName($this->namespace . 'TicketsConnectionOrderbyInput'); |
|
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 . 'TicketsConnectionOrderbyEnum'] |
|
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 . 'TicketsConnectionOrderbyEnum'] |
|
39 | + ), |
|
40 | + new GraphQLField( |
|
41 | + 'order', |
|
42 | + 'OrderEnum' |
|
43 | + ), |
|
44 | + ]; |
|
45 | + } |
|
46 | 46 | } |
@@ -38,8 +38,8 @@ |
||
38 | 38 | { |
39 | 39 | return [ |
40 | 40 | 'fromType' => 'RootQuery', |
41 | - 'toType' => $this->namespace . 'Price', |
|
42 | - 'fromFieldName' => lcfirst($this->namespace) . 'Prices', |
|
41 | + 'toType' => $this->namespace.'Price', |
|
42 | + 'fromFieldName' => lcfirst($this->namespace).'Prices', |
|
43 | 43 | 'connectionTypeName' => "{$this->namespace}RootQueryPricesConnection", |
44 | 44 | 'connectionArgs' => TicketPricesConnection::get_connection_args(), |
45 | 45 | 'resolve' => [$this, 'resolveConnection'], |
@@ -18,43 +18,43 @@ |
||
18 | 18 | */ |
19 | 19 | class RootQueryPricesConnection extends AbstractRootQueryConnection |
20 | 20 | { |
21 | - /** |
|
22 | - * PriceConnection constructor. |
|
23 | - * |
|
24 | - * @param EEM_Price $model |
|
25 | - */ |
|
26 | - public function __construct(EEM_Price $model) |
|
27 | - { |
|
28 | - parent::__construct($model); |
|
29 | - } |
|
21 | + /** |
|
22 | + * PriceConnection constructor. |
|
23 | + * |
|
24 | + * @param EEM_Price $model |
|
25 | + */ |
|
26 | + public function __construct(EEM_Price $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 . 'Price', |
|
40 | - 'fromFieldName' => lcfirst($this->namespace) . 'Prices', |
|
41 | - 'connectionTypeName' => "{$this->namespace}RootQueryPricesConnection", |
|
42 | - 'connectionArgs' => TicketPricesConnection::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 . 'Price', |
|
40 | + 'fromFieldName' => lcfirst($this->namespace) . 'Prices', |
|
41 | + 'connectionTypeName' => "{$this->namespace}RootQueryPricesConnection", |
|
42 | + 'connectionArgs' => TicketPricesConnection::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 PriceConnectionResolver |
|
54 | - * @throws Exception |
|
55 | - */ |
|
56 | - public function getConnectionResolver($entity, $args, $context, $info): AbstractConnectionResolver |
|
57 | - { |
|
58 | - return new PriceConnectionResolver($entity, $args, $context, $info); |
|
59 | - } |
|
48 | + /** |
|
49 | + * @param $entity |
|
50 | + * @param $args |
|
51 | + * @param $context |
|
52 | + * @param $info |
|
53 | + * @return PriceConnectionResolver |
|
54 | + * @throws Exception |
|
55 | + */ |
|
56 | + public function getConnectionResolver($entity, $args, $context, $info): AbstractConnectionResolver |
|
57 | + { |
|
58 | + return new PriceConnectionResolver($entity, $args, $context, $info); |
|
59 | + } |
|
60 | 60 | } |
@@ -38,8 +38,8 @@ |
||
38 | 38 | { |
39 | 39 | return [ |
40 | 40 | 'fromType' => 'RootQuery', |
41 | - 'toType' => $this->namespace . 'Datetime', |
|
42 | - 'fromFieldName' => lcfirst($this->namespace . 'Datetimes'), |
|
41 | + 'toType' => $this->namespace.'Datetime', |
|
42 | + 'fromFieldName' => lcfirst($this->namespace.'Datetimes'), |
|
43 | 43 | 'connectionTypeName' => "{$this->namespace}RootQueryDatetimesConnection", |
44 | 44 | 'connectionArgs' => EventDatetimesConnection::get_connection_args(), |
45 | 45 | 'resolve' => [$this, 'resolveConnection'], |
@@ -18,43 +18,43 @@ |
||
18 | 18 | */ |
19 | 19 | class RootQueryDatetimesConnection extends AbstractRootQueryConnection |
20 | 20 | { |
21 | - /** |
|
22 | - * DatetimeConnection constructor. |
|
23 | - * |
|
24 | - * @param EEM_Datetime $model |
|
25 | - */ |
|
26 | - public function __construct(EEM_Datetime $model) |
|
27 | - { |
|
28 | - parent::__construct($model); |
|
29 | - } |
|
21 | + /** |
|
22 | + * DatetimeConnection constructor. |
|
23 | + * |
|
24 | + * @param EEM_Datetime $model |
|
25 | + */ |
|
26 | + public function __construct(EEM_Datetime $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 . 'Datetime', |
|
40 | - 'fromFieldName' => lcfirst($this->namespace . 'Datetimes'), |
|
41 | - 'connectionTypeName' => "{$this->namespace}RootQueryDatetimesConnection", |
|
42 | - 'connectionArgs' => EventDatetimesConnection::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 . 'Datetime', |
|
40 | + 'fromFieldName' => lcfirst($this->namespace . 'Datetimes'), |
|
41 | + 'connectionTypeName' => "{$this->namespace}RootQueryDatetimesConnection", |
|
42 | + 'connectionArgs' => EventDatetimesConnection::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 DatetimeConnectionResolver |
|
54 | - * @throws Exception |
|
55 | - */ |
|
56 | - public function getConnectionResolver($entity, $args, $context, $info): AbstractConnectionResolver |
|
57 | - { |
|
58 | - return new DatetimeConnectionResolver($entity, $args, $context, $info); |
|
59 | - } |
|
48 | + /** |
|
49 | + * @param $entity |
|
50 | + * @param $args |
|
51 | + * @param $context |
|
52 | + * @param $info |
|
53 | + * @return DatetimeConnectionResolver |
|
54 | + * @throws Exception |
|
55 | + */ |
|
56 | + public function getConnectionResolver($entity, $args, $context, $info): AbstractConnectionResolver |
|
57 | + { |
|
58 | + return new DatetimeConnectionResolver($entity, $args, $context, $info); |
|
59 | + } |
|
60 | 60 | } |
@@ -38,8 +38,8 @@ |
||
38 | 38 | { |
39 | 39 | return [ |
40 | 40 | 'fromType' => 'RootQuery', |
41 | - 'toType' => $this->namespace . 'Ticket', |
|
42 | - 'fromFieldName' => lcfirst($this->namespace) . 'Tickets', |
|
41 | + 'toType' => $this->namespace.'Ticket', |
|
42 | + 'fromFieldName' => lcfirst($this->namespace).'Tickets', |
|
43 | 43 | 'connectionTypeName' => "{$this->namespace}RootQueryTicketsConnection", |
44 | 44 | 'connectionArgs' => DatetimeTicketsConnection::get_connection_args(), |
45 | 45 | 'resolve' => [$this, 'resolveConnection'], |
@@ -18,43 +18,43 @@ |
||
18 | 18 | */ |
19 | 19 | class RootQueryTicketsConnection extends AbstractRootQueryConnection |
20 | 20 | { |
21 | - /** |
|
22 | - * TicketConnection constructor. |
|
23 | - * |
|
24 | - * @param EEM_Ticket $model |
|
25 | - */ |
|
26 | - public function __construct(EEM_Ticket $model) |
|
27 | - { |
|
28 | - parent::__construct($model); |
|
29 | - } |
|
21 | + /** |
|
22 | + * TicketConnection constructor. |
|
23 | + * |
|
24 | + * @param EEM_Ticket $model |
|
25 | + */ |
|
26 | + public function __construct(EEM_Ticket $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 . 'Ticket', |
|
40 | - 'fromFieldName' => lcfirst($this->namespace) . 'Tickets', |
|
41 | - 'connectionTypeName' => "{$this->namespace}RootQueryTicketsConnection", |
|
42 | - 'connectionArgs' => DatetimeTicketsConnection::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 . 'Ticket', |
|
40 | + 'fromFieldName' => lcfirst($this->namespace) . 'Tickets', |
|
41 | + 'connectionTypeName' => "{$this->namespace}RootQueryTicketsConnection", |
|
42 | + 'connectionArgs' => DatetimeTicketsConnection::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 TicketConnectionResolver |
|
54 | - * @throws Exception |
|
55 | - */ |
|
56 | - public function getConnectionResolver($entity, $args, $context, $info): AbstractConnectionResolver |
|
57 | - { |
|
58 | - return new TicketConnectionResolver($entity, $args, $context, $info); |
|
59 | - } |
|
48 | + /** |
|
49 | + * @param $entity |
|
50 | + * @param $args |
|
51 | + * @param $context |
|
52 | + * @param $info |
|
53 | + * @return TicketConnectionResolver |
|
54 | + * @throws Exception |
|
55 | + */ |
|
56 | + public function getConnectionResolver($entity, $args, $context, $info): AbstractConnectionResolver |
|
57 | + { |
|
58 | + return new TicketConnectionResolver($entity, $args, $context, $info); |
|
59 | + } |
|
60 | 60 | } |
@@ -21,7 +21,7 @@ |
||
21 | 21 | */ |
22 | 22 | public function __construct() |
23 | 23 | { |
24 | - $this->setName($this->namespace . 'TicketStatusEnum'); |
|
24 | + $this->setName($this->namespace.'TicketStatusEnum'); |
|
25 | 25 | $this->setDescription(esc_html__('Whether the ticket is On Sale, Pending, or Expired', 'event_espresso')); |
26 | 26 | parent::__construct(); |
27 | 27 | } |
@@ -15,38 +15,38 @@ |
||
15 | 15 | */ |
16 | 16 | class TicketStatusEnum extends EnumBase |
17 | 17 | { |
18 | - /** |
|
19 | - * TicketStatusEnum constructor. |
|
20 | - */ |
|
21 | - public function __construct() |
|
22 | - { |
|
23 | - $this->setName($this->namespace . 'TicketStatusEnum'); |
|
24 | - $this->setDescription(esc_html__('Whether the ticket is On Sale, Pending, or Expired', 'event_espresso')); |
|
25 | - parent::__construct(); |
|
26 | - } |
|
18 | + /** |
|
19 | + * TicketStatusEnum constructor. |
|
20 | + */ |
|
21 | + public function __construct() |
|
22 | + { |
|
23 | + $this->setName($this->namespace . 'TicketStatusEnum'); |
|
24 | + $this->setDescription(esc_html__('Whether the ticket is On Sale, Pending, or Expired', 'event_espresso')); |
|
25 | + parent::__construct(); |
|
26 | + } |
|
27 | 27 | |
28 | 28 | |
29 | - /** |
|
30 | - * @return array |
|
31 | - */ |
|
32 | - protected function getValues(): array |
|
33 | - { |
|
34 | - return [ |
|
35 | - 'SOLD_OUT' => [ |
|
36 | - 'value' => EE_Ticket::sold_out, |
|
37 | - ], |
|
38 | - 'EXPIRED' => [ |
|
39 | - 'value' => EE_Ticket::expired, |
|
40 | - ], |
|
41 | - 'ARCHIVED' => [ |
|
42 | - 'value' => EE_Ticket::archived, |
|
43 | - ], |
|
44 | - 'PENDING' => [ |
|
45 | - 'value' => EE_Ticket::pending, |
|
46 | - ], |
|
47 | - 'ONSALE' => [ |
|
48 | - 'value' => EE_Ticket::onsale, |
|
49 | - ], |
|
50 | - ]; |
|
51 | - } |
|
29 | + /** |
|
30 | + * @return array |
|
31 | + */ |
|
32 | + protected function getValues(): array |
|
33 | + { |
|
34 | + return [ |
|
35 | + 'SOLD_OUT' => [ |
|
36 | + 'value' => EE_Ticket::sold_out, |
|
37 | + ], |
|
38 | + 'EXPIRED' => [ |
|
39 | + 'value' => EE_Ticket::expired, |
|
40 | + ], |
|
41 | + 'ARCHIVED' => [ |
|
42 | + 'value' => EE_Ticket::archived, |
|
43 | + ], |
|
44 | + 'PENDING' => [ |
|
45 | + 'value' => EE_Ticket::pending, |
|
46 | + ], |
|
47 | + 'ONSALE' => [ |
|
48 | + 'value' => EE_Ticket::onsale, |
|
49 | + ], |
|
50 | + ]; |
|
51 | + } |
|
52 | 52 | } |
@@ -21,7 +21,7 @@ |
||
21 | 21 | */ |
22 | 22 | public function __construct() |
23 | 23 | { |
24 | - $this->setName($this->namespace . 'DatetimeStatusEnum'); |
|
24 | + $this->setName($this->namespace.'DatetimeStatusEnum'); |
|
25 | 25 | $this->setDescription(esc_html__('Datetime status', 'event_espresso')); |
26 | 26 | parent::__construct(); |
27 | 27 | } |
@@ -15,44 +15,44 @@ |
||
15 | 15 | */ |
16 | 16 | class DatetimeStatusEnum extends EnumBase |
17 | 17 | { |
18 | - /** |
|
19 | - * DatetimeStatusEnum constructor. |
|
20 | - */ |
|
21 | - public function __construct() |
|
22 | - { |
|
23 | - $this->setName($this->namespace . 'DatetimeStatusEnum'); |
|
24 | - $this->setDescription(esc_html__('Datetime status', 'event_espresso')); |
|
25 | - parent::__construct(); |
|
26 | - } |
|
18 | + /** |
|
19 | + * DatetimeStatusEnum constructor. |
|
20 | + */ |
|
21 | + public function __construct() |
|
22 | + { |
|
23 | + $this->setName($this->namespace . 'DatetimeStatusEnum'); |
|
24 | + $this->setDescription(esc_html__('Datetime status', 'event_espresso')); |
|
25 | + parent::__construct(); |
|
26 | + } |
|
27 | 27 | |
28 | 28 | |
29 | - /** |
|
30 | - * @return array |
|
31 | - */ |
|
32 | - protected function getValues(): array |
|
33 | - { |
|
34 | - return [ |
|
35 | - 'SOLD_OUT' => [ |
|
36 | - 'value' => EE_Datetime::sold_out, |
|
37 | - ], |
|
38 | - 'ACTIVE' => [ |
|
39 | - 'value' => EE_Datetime::active, |
|
40 | - ], |
|
41 | - 'UPCOMING' => [ |
|
42 | - 'value' => EE_Datetime::upcoming, |
|
43 | - ], |
|
44 | - 'POSTPONED' => [ |
|
45 | - 'value' => EE_Datetime::postponed, |
|
46 | - ], |
|
47 | - 'CANCELLED' => [ |
|
48 | - 'value' => EE_Datetime::cancelled, |
|
49 | - ], |
|
50 | - 'EXPIRED' => [ |
|
51 | - 'value' => EE_Datetime::expired, |
|
52 | - ], |
|
53 | - 'INACTIVE' => [ |
|
54 | - 'value' => EE_Datetime::inactive, |
|
55 | - ], |
|
56 | - ]; |
|
57 | - } |
|
29 | + /** |
|
30 | + * @return array |
|
31 | + */ |
|
32 | + protected function getValues(): array |
|
33 | + { |
|
34 | + return [ |
|
35 | + 'SOLD_OUT' => [ |
|
36 | + 'value' => EE_Datetime::sold_out, |
|
37 | + ], |
|
38 | + 'ACTIVE' => [ |
|
39 | + 'value' => EE_Datetime::active, |
|
40 | + ], |
|
41 | + 'UPCOMING' => [ |
|
42 | + 'value' => EE_Datetime::upcoming, |
|
43 | + ], |
|
44 | + 'POSTPONED' => [ |
|
45 | + 'value' => EE_Datetime::postponed, |
|
46 | + ], |
|
47 | + 'CANCELLED' => [ |
|
48 | + 'value' => EE_Datetime::cancelled, |
|
49 | + ], |
|
50 | + 'EXPIRED' => [ |
|
51 | + 'value' => EE_Datetime::expired, |
|
52 | + ], |
|
53 | + 'INACTIVE' => [ |
|
54 | + 'value' => EE_Datetime::inactive, |
|
55 | + ], |
|
56 | + ]; |
|
57 | + } |
|
58 | 58 | } |
@@ -29,10 +29,10 @@ |
||
29 | 29 | isset($input_settings['validation_error_message']) |
30 | 30 | ? $input_settings['validation_error_message'] |
31 | 31 | : null, |
32 | - '#' . str_replace('email_confirm', 'email', $input_settings['html_id']) |
|
32 | + '#'.str_replace('email_confirm', 'email', $input_settings['html_id']) |
|
33 | 33 | ) |
34 | 34 | ); |
35 | 35 | parent::__construct($input_settings); |
36 | - $this->set_html_class($this->html_class() . ' email'); |
|
36 | + $this->set_html_class($this->html_class().' email'); |
|
37 | 37 | } |
38 | 38 | } |
@@ -10,29 +10,29 @@ |
||
10 | 10 | */ |
11 | 11 | class EE_Email_Confirm_Input extends EE_Form_Input_Base |
12 | 12 | { |
13 | - /** |
|
14 | - * @param array $input_settings |
|
15 | - */ |
|
16 | - public function __construct($input_settings = array()) |
|
17 | - { |
|
18 | - $this->_set_display_strategy(new EE_Text_Input_Display_Strategy('email')); |
|
19 | - $this->_set_normalization_strategy(new EE_Text_Normalization()); |
|
20 | - $this->_add_validation_strategy( |
|
21 | - new EE_Email_Validation_Strategy( |
|
22 | - isset($input_settings['validation_error_message']) |
|
23 | - ? $input_settings['validation_error_message'] |
|
24 | - : null |
|
25 | - ) |
|
26 | - ); |
|
27 | - $this->_add_validation_strategy( |
|
28 | - new EE_Equal_To_Validation_Strategy( |
|
29 | - isset($input_settings['validation_error_message']) |
|
30 | - ? $input_settings['validation_error_message'] |
|
31 | - : null, |
|
32 | - '#' . str_replace('email_confirm', 'email', $input_settings['html_id']) |
|
33 | - ) |
|
34 | - ); |
|
35 | - parent::__construct($input_settings); |
|
36 | - $this->set_html_class($this->html_class() . ' email'); |
|
37 | - } |
|
13 | + /** |
|
14 | + * @param array $input_settings |
|
15 | + */ |
|
16 | + public function __construct($input_settings = array()) |
|
17 | + { |
|
18 | + $this->_set_display_strategy(new EE_Text_Input_Display_Strategy('email')); |
|
19 | + $this->_set_normalization_strategy(new EE_Text_Normalization()); |
|
20 | + $this->_add_validation_strategy( |
|
21 | + new EE_Email_Validation_Strategy( |
|
22 | + isset($input_settings['validation_error_message']) |
|
23 | + ? $input_settings['validation_error_message'] |
|
24 | + : null |
|
25 | + ) |
|
26 | + ); |
|
27 | + $this->_add_validation_strategy( |
|
28 | + new EE_Equal_To_Validation_Strategy( |
|
29 | + isset($input_settings['validation_error_message']) |
|
30 | + ? $input_settings['validation_error_message'] |
|
31 | + : null, |
|
32 | + '#' . str_replace('email_confirm', 'email', $input_settings['html_id']) |
|
33 | + ) |
|
34 | + ); |
|
35 | + parent::__construct($input_settings); |
|
36 | + $this->set_html_class($this->html_class() . ' email'); |
|
37 | + } |
|
38 | 38 | } |