| @@ 52-60 (lines=9) @@ | ||
| 49 | return $this; |
|
| 50 | } |
|
| 51 | ||
| 52 | public function whereEmpty($field) |
|
| 53 | { |
|
| 54 | return $this->where('$or', array( |
|
| 55 | array($field => null), |
|
| 56 | array($field => ''), |
|
| 57 | array($field => array()), |
|
| 58 | array($field => array('$exists' => false)) |
|
| 59 | )); |
|
| 60 | } |
|
| 61 | ||
| 62 | public function whereNotEmpty($field) |
|
| 63 | { |
|
| @@ 62-70 (lines=9) @@ | ||
| 59 | )); |
|
| 60 | } |
|
| 61 | ||
| 62 | public function whereNotEmpty($field) |
|
| 63 | { |
|
| 64 | return $this->where('$nor', array( |
|
| 65 | array($field => null), |
|
| 66 | array($field => ''), |
|
| 67 | array($field => array()), |
|
| 68 | array($field => array('$exists' => false)) |
|
| 69 | )); |
|
| 70 | } |
|
| 71 | ||
| 72 | public function whereGreater($field, $value) |
|
| 73 | { |
|