Code Duplication    Length = 32-32 lines in 2 locations

core/domain/services/graphql/enums/DatetimesConnectionOrderbyEnum.php 1 location

@@ 15-46 (lines=32) @@
12
 * @author  Manzoor Wani
13
 * @since   $VID:$
14
 */
15
class DatetimesConnectionOrderbyEnum extends EnumBase
16
{
17
18
    /**
19
     * DatetimesConnectionOrderbyEnum constructor.
20
     */
21
    public function __construct()
22
    {
23
        $this->setName('DatetimesConnectionOrderbyEnum');
24
        $this->setDescription(esc_html__('Field to order the connection by', 'event_espresso'));
25
        parent::__construct();
26
    }
27
28
29
    /**
30
     * @return array
31
     * @since $VID:$
32
     */
33
    protected function getValues()
34
    {
35
        return [
36
            'NAME'     => [
37
                'value'       => 'DTT_name',
38
                'description' => esc_html__('Order by name', 'event_espresso'),
39
            ],
40
            'START_DATE'     => [
41
                'value'       => 'DTT_EVT_start',
42
                'description' => esc_html__('Order by start date', 'event_espresso'),
43
            ],
44
        ];
45
    }
46
}
47

core/domain/services/graphql/enums/TicketsConnectionOrderbyEnum.php 1 location

@@ 15-46 (lines=32) @@
12
 * @author  Manzoor Wani
13
 * @since   $VID:$
14
 */
15
class TicketsConnectionOrderbyEnum extends EnumBase
16
{
17
18
    /**
19
     * TicketsConnectionOrderbyEnum constructor.
20
     */
21
    public function __construct()
22
    {
23
        $this->setName('TicketsConnectionOrderbyEnum');
24
        $this->setDescription(esc_html__('Field to order the connection by', 'event_espresso'));
25
        parent::__construct();
26
    }
27
28
29
    /**
30
     * @return array
31
     * @since $VID:$
32
     */
33
    protected function getValues()
34
    {
35
        return [
36
            'NAME'     => [
37
                'value'       => 'TKT_name',
38
                'description' => esc_html__('Order by name', 'event_espresso'),
39
            ],
40
            'START_DATE'     => [
41
                'value'       => 'TKT_start_date',
42
                'description' => esc_html__('Order by start date', 'event_espresso'),
43
            ],
44
        ];
45
    }
46
}
47