private function processSellerExtensions() { if (!$this->object) { return; } if (Module::isInstalled('agilemultipleseller')) { $approved = intval(Tools::getValue('approved')); if (intval(Configuration::get('AGILE_MS_PRODUCT_APPROVAL')) != 1) { $approved = 1; } $sql = 'UPDATE ' . _DB_PREFIX_ . 'product_owner SET approved=' . $approved . ' WHERE id_product=' . (int) $this->object->id; Db::getInstance()->Execute($sql); } if (Module::isInstalled('agilesellerlistoptions')) { require_once _PS_ROOT_DIR_ . '/modules/agilesellerlistoptions/agilesellerlistoptions.php'; $aslo_module = new AgileSellerListOptions(); $aslo_module->processProductExtenstions(array('product' => $this->object)); } }
public function update($null_values = false) { $res = parent::update($null_values); if (Module::isInstalled('agilesellerlistoptions') and $res) { require_once _PS_ROOT_DIR_ . "/modules/agilesellerlistoptions/agilesellerlistoptions.php"; $aslo = new AgileSellerListOptions(); $aslo->processProductExtenstions(array('product' => $this)); } return $res; }