| @@ 7-30 (lines=24) @@ | ||
| 4 | ||
| 5 | use hipanel\helpers\Url; |
|
| 6 | ||
| 7 | class Update extends Create |
|
| 8 | { |
|
| 9 | protected function loadPage() |
|
| 10 | { |
|
| 11 | $I = $this->tester; |
|
| 12 | ||
| 13 | $I->needPage(Url::to(['@plan/update', 'id' => $this->id])); |
|
| 14 | } |
|
| 15 | ||
| 16 | protected function savePlan() |
|
| 17 | { |
|
| 18 | $I = $this->tester; |
|
| 19 | ||
| 20 | $I->click('Save'); |
|
| 21 | $I->closeNotification("Plan was successfully updated"); |
|
| 22 | } |
|
| 23 | ||
| 24 | public function updatePlan($id) |
|
| 25 | { |
|
| 26 | $this->id = $id; |
|
| 27 | ||
| 28 | return $this->createPlan(); |
|
| 29 | } |
|
| 30 | } |
|
| 31 | ||
| @@ 7-30 (lines=24) @@ | ||
| 4 | ||
| 5 | use yii\helpers\Url; |
|
| 6 | ||
| 7 | class UpdateGrouping extends CreateGrouping |
|
| 8 | { |
|
| 9 | protected function loadPage() |
|
| 10 | { |
|
| 11 | $I = $this->tester; |
|
| 12 | ||
| 13 | $I->needPage(Url::to(['@plan/update', 'id' => $this->id])); |
|
| 14 | } |
|
| 15 | ||
| 16 | protected function savePlan() |
|
| 17 | { |
|
| 18 | $I = $this->tester; |
|
| 19 | ||
| 20 | $I->click('Save'); |
|
| 21 | $I->closeNotification("Plan was successfully updated"); |
|
| 22 | } |
|
| 23 | ||
| 24 | public function updatePlan($id) |
|
| 25 | { |
|
| 26 | $this->id = $id; |
|
| 27 | ||
| 28 | return $this->createPlan(); |
|
| 29 | } |
|
| 30 | } |
|
| 31 | ||