| Total Complexity | 2 |
| Total Lines | 20 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 16 | class WithSurveyModel extends DActiveRecord |
||
| 17 | { |
||
| 18 | /** |
||
| 19 | * {@inheritdoc} |
||
| 20 | */ |
||
| 21 | public function rules() |
||
| 22 | { |
||
| 23 | return [ |
||
| 24 | [['survey_id'], 'required'], |
||
| 25 | [['survey_id'], 'integer'], |
||
| 26 | [['survey_id'], 'exist', 'skipOnError' => true, 'targetClass' => BaseSurvey::class, 'targetAttribute' => ['survey_id' => 'survey_id']], |
||
| 27 | ]; |
||
| 28 | } |
||
| 29 | |||
| 30 | /** |
||
| 31 | * {@inheritdoc} |
||
| 32 | */ |
||
| 33 | public function getSurvey() |
||
| 36 | } |
||
| 37 | |||
| 38 | } |