| 1 | <?php |
||
| 16 | class Delete extends BaseAction |
||
| 17 | { |
||
| 18 | /** |
||
| 19 | * Method name for hard delete model |
||
| 20 | */ |
||
| 21 | const METHOD_HARD = 'delete'; |
||
| 22 | |||
| 23 | /** |
||
| 24 | * Method name for soft delete model |
||
| 25 | */ |
||
| 26 | const METHOD_SOFT = 'softDelete'; |
||
| 27 | |||
| 28 | /** |
||
| 29 | * @var string method name for delete model. |
||
| 30 | */ |
||
| 31 | public $methodName = self::METHOD_HARD; |
||
| 32 | |||
| 33 | /** |
||
| 34 | * Deletes model |
||
| 35 | * @param mixed $id ID of the model to be deleted |
||
| 36 | * @return mixed |
||
| 37 | */ |
||
| 38 | 6 | public function run($id) |
|
| 48 | } |
||
| 49 |