255], ]; } /** * {@inheritdoc} */ public function attributeLabels() { return [ 'id' => 'ID', 'title' => 'Title', 'company' => 'ID company', 'warehouse' => 'ID warehouse', 'stack' => 'ID stack', 'cell' => 'ID cell', 'tmc' => 'ID tmc', ]; } public function toFormTitle() { return $this->company . '.' . $this->getWarehouse()->number . '.' . $this->getStack()->number . '.' . $this->cell; } public function getCompany() { return $this->hasOne(Companies::class, ['id' => 'company']); } public function getWarehouse() { return Warehouse::findOne($this->warehouse); } public function getStack() { return Stack::findOne($this->stack); } public function getCell() { return $this->hasOne(Cell::class, ['id' => 'cell']); } public function getTmc() { return $this->hasOne(Tmc::class, ['id' => 'tmc']); } }