PluginProbe
AcyMailing – An Ultimate Newsletter Plugin and Marketing Automation Solution for WordPress / 10.0.1
AcyMailing – An Ultimate Newsletter Plugin and Marketing Automation Solution for WordPress v10.0.1
11.1.1 11.1.0 11.0.5 11.0.4 11.0.3 11.0.2 11.0.1 11.0.0 10.11.1 10.11.0 10.10.2 10.10.1 10.10.0 10.9.1 trunk 10.0.0 10.0.1 10.1.0 10.1.1 10.1.2 10.1.3 10.1.4 10.2.0 10.2.1 10.2.2 All 62 releases
acymailing / back / Types / OperatorType.php

OperatorType.php in AcyMailing – An Ultimate Newsletter Plugin and Marketing Automation Solution for WordPress 10.0.1, at back/Types/OperatorType.php

41 lines 1.5 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2
3 namespace AcyMailing\Types;
4
5 use AcyMailing\Core\AcymObject;
6
7 class OperatorType extends AcymObject
8 {
9 public $values = [];
10 public $attributes = [];
11
12 public function __construct()
13 {
14 parent::__construct();
15
16 $this->values[] = acym_selectOption('=', '=');
17 $this->values[] = acym_selectOption('!=', '!=');
18 $this->values[] = acym_selectOption('>', '>');
19 $this->values[] = acym_selectOption('<', '<');
20 $this->values[] = acym_selectOption('>=', '>=');
21 $this->values[] = acym_selectOption('<=', '<=');
22 $this->values[] = acym_selectOption('BEGINS', 'ACYM_BEGINS_WITH');
23 $this->values[] = acym_selectOption('END', 'ACYM_ENDS_WITH');
24 $this->values[] = acym_selectOption('CONTAINS', 'ACYM_CONTAINS');
25 $this->values[] = acym_selectOption('NOTCONTAINS', 'ACYM_NOT_CONTAINS');
26 $this->values[] = acym_selectOption('LIKE', 'LIKE');
27 $this->values[] = acym_selectOption('NOT LIKE', 'NOT LIKE');
28 $this->values[] = acym_selectOption('REGEXP', 'REGEXP');
29 $this->values[] = acym_selectOption('NOT REGEXP', 'NOT REGEXP');
30 $this->values[] = acym_selectOption('IS NULL', 'IS NULL');
31 $this->values[] = acym_selectOption('IS NOT NULL', 'IS NOT NULL');
32 }
33
34 public function display($name, $valueSelected = '', $class = 'acym__select')
35 {
36 if (empty($this->attributes['class'])) $this->attributes['class'] = $class;
37
38 return acym_select($this->values, $name, $valueSelected, $this->attributes);
39 }
40 }
41