1 | <?php |
||
14 | class LogSearchHelper extends SearchHelperBase |
||
15 | { |
||
16 | /** |
||
17 | * LogSearchHelper constructor. |
||
18 | * |
||
19 | * @param PdoDatabase $database |
||
20 | */ |
||
21 | protected function __construct(PdoDatabase $database) |
||
25 | |||
26 | /** |
||
27 | * Initiates a search for requests |
||
28 | * |
||
29 | * @param PdoDatabase $database |
||
30 | * |
||
31 | * @return LogSearchHelper |
||
32 | */ |
||
33 | public static function get(PdoDatabase $database) |
||
39 | |||
40 | /** |
||
41 | * Filters the results by user |
||
42 | * |
||
43 | * @param int $userId |
||
44 | * |
||
45 | * @return $this |
||
46 | */ |
||
47 | public function byUser($userId) |
||
54 | |||
55 | /** |
||
56 | * Filters the results by log action |
||
57 | * |
||
58 | * @param string $action |
||
59 | * |
||
60 | * @return $this |
||
61 | */ |
||
62 | public function byAction($action) |
||
69 | |||
70 | /** |
||
71 | * Filters the results by object type |
||
72 | * |
||
73 | * @param string $objectType |
||
74 | * |
||
75 | * @return $this |
||
76 | */ |
||
77 | public function byObjectType($objectType) |
||
84 | |||
85 | /** |
||
86 | * Filters the results by object type |
||
87 | * |
||
88 | * @param integer $objectId |
||
89 | * |
||
90 | * @return $this |
||
91 | */ |
||
92 | public function byObjectId($objectId) |
||
99 | } |