| Total Complexity | 5 |
| Total Lines | 68 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 12 | class Outlet extends BaseModel implements OutletInterface |
||
| 13 | { |
||
| 14 | /** @var string Адрес торговой точки */ |
||
| 15 | public $address = ''; |
||
| 16 | |||
| 17 | /** @var integer Количество ККТ */ |
||
| 18 | public $cashDeskCount = 0; |
||
| 19 | |||
| 20 | /** @var string Код торговой точки */ |
||
| 21 | public $code = ''; |
||
| 22 | |||
| 23 | /** @var string Идентификатор торговой точки */ |
||
| 24 | public $id = ''; |
||
| 25 | |||
| 26 | /** @var string Название торговой точки */ |
||
| 27 | public $name = ''; |
||
| 28 | |||
| 29 | /** @var string Признак наличия проблемы */ |
||
| 30 | public $problemIndicator = ''; |
||
| 31 | |||
| 32 | /** |
||
| 33 | * @inheritDoc |
||
| 34 | */ |
||
| 35 | public function getRuleList(): array |
||
| 36 | { |
||
| 37 | return [ |
||
| 38 | 'id' => ['required', ['lengthMax', 36]], |
||
| 39 | 'name' => ['required', ['lengthMax', 255]], |
||
| 40 | |||
| 41 | 'code' => [['lengthMax', 10]], |
||
| 42 | 'problemIndicator' => [['in', [ |
||
| 43 | Status::OK, |
||
| 44 | Status::PROBLEM, |
||
| 45 | Status::WARNING, |
||
| 46 | ]]], |
||
| 47 | ]; |
||
| 48 | } |
||
| 49 | |||
| 50 | /** |
||
| 51 | * @inheritDoc |
||
| 52 | */ |
||
| 53 | public function getId(): string |
||
| 54 | { |
||
| 55 | return $this->id; |
||
| 56 | } |
||
| 57 | |||
| 58 | /** |
||
| 59 | * @inheritDoc |
||
| 60 | */ |
||
| 61 | public function getName(): string |
||
| 62 | { |
||
| 63 | return $this->name; |
||
| 64 | } |
||
| 65 | |||
| 66 | /** |
||
| 67 | * @inheritDoc |
||
| 68 | */ |
||
| 69 | public function getAddress(): string |
||
| 72 | } |
||
| 73 | |||
| 74 | /** |
||
| 75 | * @inheritDoc |
||
| 76 | */ |
||
| 77 | protected function getPropertyInitMap(): array |
||
| 80 | } |
||
| 81 | } |