@@ 61-73 (lines=13) @@ | ||
58 | * |
|
59 | * @return self |
|
60 | */ |
|
61 | public function whereInfix($field, $operator = '=', $condition = false) |
|
62 | { |
|
63 | $numArgs = func_num_args(); |
|
64 | if ($numArgs > 2) { |
|
65 | $this->where->addCondition($field, $condition, $operator); |
|
66 | } elseif ($numArgs == 2) { |
|
67 | $this->where->addCondition($field, $operator, '='); |
|
68 | } else { |
|
69 | $this->where->addCondition($field); |
|
70 | } |
|
71 | ||
72 | return $this; |
|
73 | } |
|
74 | ||
75 | /** |
|
76 | * Adds a where or condition to the query with infix style arguments. |
|
@@ 84-96 (lines=13) @@ | ||
81 | * |
|
82 | * @return self |
|
83 | */ |
|
84 | public function orWhereInfix($field, $operator = '=', $condition = false) |
|
85 | { |
|
86 | $numArgs = func_num_args(); |
|
87 | if ($numArgs > 2) { |
|
88 | $this->where->addOrCondition($field, $condition, $operator); |
|
89 | } elseif ($numArgs == 2) { |
|
90 | $this->where->addOrCondition($field, $operator, '='); |
|
91 | } else { |
|
92 | $this->where->addOrCondition($field); |
|
93 | } |
|
94 | ||
95 | return $this; |
|
96 | } |
|
97 | ||
98 | /** |
|
99 | * Adds a where not condition to the query. |