getPk(); $row->getQuery()->where($pk, $row[$pk])->update(['weigh' => $row[$pk]]); }); } public function getPositionList() { return ['0' => __('Position 0'), '1' => __('Position 1')]; } public function getStatusList() { return ['0' => __('Status 0'), '1' => __('Status 1')]; } public function getPositionTextAttr($value, $data) { $value = $value ? $value : (isset($data['position']) ? $data['position'] : ''); $list = $this->getPositionList(); return isset($list[$value]) ? $list[$value] : ''; } public function getStatusTextAttr($value, $data) { $value = $value ? $value : (isset($data['status']) ? $data['status'] : ''); $list = $this->getStatusList(); return isset($list[$value]) ? $list[$value] : ''; } }