php - Prestashop 1.7 actionProductUpdate used only in ajaxProcessProductQuantity method -
i'm trying add new field (domain_name) in prestashop 1.7 admin product page, in information tab. field showing haven't succeed save when clicking save button. used actionproductupdate hook in module this:
public function hookactionproductupdate($params) { $id_product = (int) tools::getvalue('id_product'); if (!db::getinstance()->update( 'product', array( 'domain_name' => psql(tools::getvalue('domain_name')) ), ' id_product = ' . $id_product)) $this->context->controller->_errors[] = tools::displayerror('error: ') . mysql_error(); }
but didn't work, searched hook actionproductupdate in adminproductcontroller.php used on ajaxprocessproductquantity method. idea use in case?
any help? thanks.
Comments
Post a Comment