PluginProbe
LearnPress – WordPress LMS Plugin for Create and Sell Online Courses / 4.1.7.3
LearnPress – WordPress LMS Plugin for Create and Sell Online Courses v4.1.7.3
4.4.8 4.4.7 4.4.6 4.4.5 4.4.4 4.4.3 4.4.2 4.4.1 4.4.0 4.3.9.1 4.3.9 4.3.8 4.3.7 4.1.6.9 4.1.6.9.1 4.1.6.9.2 4.1.6.9.3 4.1.6.9.4 4.1.7 4.1.7.1 4.1.7.2 4.1.7.3 4.1.7.3.1 4.1.7.3.2 4.2.0 All 139 releases
learnpress / inc / filters / class-lp-filter.php

class-lp-filter.php in LearnPress – WordPress LMS Plugin for Create and Sell Online Courses 4.1.7.3, at inc/filters/class-lp-filter.php

128 lines 2.0 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Class LP_Filter
4 *
5 * @author tungnx
6 * @package LearnPress/Classes/Filters
7 * @version 4.0.2
8 */
9
10 /**
11 * Prevent loading this file directly
12 */
13 defined( 'ABSPATH' ) || exit();
14
15 class LP_Filter {
16 /**
17 * @var int set -1 for no limit
18 */
19 public $limit = 10;
20 /**
21 * @var int
22 */
23 public $max_limit = 100;
24 /**
25 * @var array query ON
26 */
27 public $sort_by = array();
28 /**
29 * @var string
30 */
31 public $group_by = '';
32 /**
33 * @var string
34 */
35 public $order_by = '';
36 /**
37 * @var string DESC|ASC
38 */
39 public $order = '';
40 /**
41 * @var string
42 */
43 public $key_word = '';
44 /**
45 * @var int
46 */
47 public $page = 1;
48 /**
49 * Name table query Or Query nested
50 * EX: FROM 'wp_posts'
51 * OR: FROM (SELECT * FROM 'wp_posts') AS P
52 *
53 * @var string
54 */
55 public $collection = '';
56 /**
57 * Alias collection
58 * EX: FROM 'wp_posts' AS p
59 * "p" is alias
60 *
61 * @var string
62 */
63 public $collection_alias = '';
64 /**
65 * @var array
66 */
67 public $fields = array();
68 /**
69 * For get only columns set on it
70 *
71 * @var array
72 */
73 public $only_fields = array();
74 /**
75 * Exclude columns set on fields
76 *
77 * @var array
78 */
79 public $exclude_fields = array();
80 /**
81 * @var array for purpose run query update.
82 */
83 public $set = array();
84 /**
85 * @var array
86 */
87 public $where = array();
88 /**
89 * @var array
90 */
91 public $join = array();
92 /**
93 * @var array
94 */
95 public $union = array();
96 /**
97 * @var bool set true to return total_rows only
98 */
99 public $query_count = false;
100 /**
101 * @var string Ex: ID, for query: COUNT(ID)
102 */
103 public $field_count = 'ID';
104 /**
105 * @var bool set true to return string query
106 */
107 public $return_string_query = false;
108 /**
109 * @var false set true to return string query to debug
110 */
111 public $debug_string_query = false;
112 /**
113 * @var string
114 */
115 public $query_type = 'get_results';
116 /**
117 * @var object stdclass
118 */
119 public $filter_extra;
120
121 public function __construct() {
122 $this->limit = apply_filters( 'lp/filter/limit', $this->limit );
123 $this->max_limit = apply_filters( 'lp/filter/max/limit', $this->max_limit );
124 }
125 }
126
127
128