| 1 | <?php |
||
| 19 | abstract class UpdateElement extends Action |
||
| 20 | { |
||
| 21 | use SaveElementTrait, LookupElementTrait; |
||
| 22 | |||
| 23 | /** |
||
| 24 | * @var array |
||
| 25 | */ |
||
| 26 | public $validBodyParams = []; |
||
| 27 | |||
| 28 | /** |
||
| 29 | * Body params that should be set on the record. |
||
| 30 | * |
||
| 31 | * @return array |
||
| 32 | */ |
||
| 33 | protected function validBodyParams(): array |
||
| 37 | |||
| 38 | /** |
||
| 39 | * @inheritdoc |
||
| 40 | * @param ElementInterface $element |
||
| 41 | * @throws \Throwable |
||
| 42 | * @throws \craft\errors\ElementNotFoundException |
||
| 43 | * @throws \yii\base\Exception |
||
| 44 | */ |
||
| 45 | protected function performAction(ElementInterface $element): bool |
||
| 49 | } |
||
| 50 |