1 | <?php |
||
22 | class TrashBehavior extends AttributeBehavior |
||
23 | { |
||
24 | /** |
||
25 | * @var string The name of the table where data stored. |
||
26 | * Defaults to "removed". |
||
27 | */ |
||
28 | public $trashAttribute = 'removed'; |
||
29 | /** |
||
30 | * @var mixed The value to set for removed model. |
||
31 | * Default is 1. |
||
32 | */ |
||
33 | public $removedFlag=1; |
||
34 | /** |
||
35 | * @var mixed The value to set for restored model. |
||
36 | * Default is 0. |
||
37 | */ |
||
38 | public $restoredFlag=0; |
||
39 | |||
40 | /** |
||
41 | * @var callable the value that will be assigned to the attributes. This should be a valid |
||
42 | * PHP callable whose return value will be assigned to the current attribute(s). |
||
43 | */ |
||
44 | public $value; |
||
45 | |||
46 | /** |
||
47 | * @inheritdoc |
||
48 | */ |
||
49 | public function init() |
||
59 | |||
60 | public function events(){ |
||
65 | |||
66 | public function checkNewRecord($events){ |
||
74 | |||
75 | protected function getValue($event) |
||
96 | |||
97 | public function restore() |
||
106 | |||
107 | public function getIsRemoved(){ |
||
110 | |||
111 | public function trashAttribute(){ |
||
116 | |||
117 | public function fullTrashAttribute($removed=false){ |
||
120 | } |
||
121 |
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.