| Total Complexity | 2 |
| Total Lines | 54 |
| Duplicated Lines | 0 % |
| Coverage | 52.94% |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 11 | class Proposal extends Model |
||
| 12 | { |
||
| 13 | /** @var int */ |
||
| 14 | protected $id; |
||
| 15 | |||
| 16 | /** @var int */ |
||
| 17 | protected $applicationId; |
||
| 18 | |||
| 19 | /** @var string */ |
||
| 20 | protected $key; |
||
| 21 | |||
| 22 | /** @var string */ |
||
| 23 | protected $section; |
||
| 24 | |||
| 25 | /** @var string */ |
||
| 26 | protected $locale; |
||
| 27 | |||
| 28 | /** @var string */ |
||
| 29 | protected $value; |
||
| 30 | |||
| 31 | /** @var string */ |
||
| 32 | protected $canDelete; |
||
| 33 | |||
| 34 | /** |
||
| 35 | * parse |
||
| 36 | * |
||
| 37 | * @param array $data |
||
| 38 | */ |
||
| 39 | 2 | public function parse(array $data) |
|
| 40 | { |
||
| 41 | 2 | $this->id = (int)$data['id']; |
|
| 42 | 2 | $this->applicationId = (int)$data['application_id']; |
|
| 43 | 2 | $this->key = (string)$data['key']; |
|
| 44 | 2 | $this->section = (string)$data['section']; |
|
| 45 | 2 | $this->locale = (string)$data['locale']; |
|
| 46 | 2 | $this->value = (string)$data['value']; |
|
| 47 | 2 | $this->canDelete = (string)$data['can_delete']; |
|
| 48 | 2 | } |
|
| 49 | |||
| 50 | /** |
||
| 51 | * toArray |
||
| 52 | * |
||
| 53 | * @return array |
||
| 54 | */ |
||
| 55 | public function toArray(): array |
||
| 65 | ]; |
||
| 66 | } |
||
| 68 | } |