vendorModel) { $this->setVendorModel(new VendorModel(['db' => $this->_db])); } return $this->vendorModel; } public function setVendorModel($vendorModel) { $this->vendorModel = $vendorModel; return $this; } public function markInDispute($id) { return $this->_getTable()->updateByKey(['inDispute' => 'y'], $id); } public function updatePayment(array $data, $taxationId) { return $this->_getTable()->updateByKey($data, $taxationId); } protected function _getFromDbSelect($primaryKey) { $select = parent::_getFromDbSelect($primaryKey); $select->where('`t`.`vendorId` = ?', $this->getFilter('vendorId'), Qs_Db::INT_TYPE); return $select; } protected function _addDependenciesFromDb(array &$data) { $id = $data['id']; $data['naicsCodes'] = Qs_Array::get($this->getNaicsCodesMap([$id]), $id, []); return parent::_addDependenciesFromDb($data); } }