I would like to keep track of which dashboard user ("admin") added the new product to the database.
The solution I was thinking about is simply adding another insertunder admin > model > catalog > product.tplin function addProduct()that adds the user id to the user column added before oc_product.
$userID =
public function addProduct($data) {
$this->event->trigger('pre.admin.product.add', $data);
$this->db->query("INSERT INTO " . DB_PREFIX . "product SET addedby = $userID, .......");
.......
}
The only problem that I am facing right now is how to call / get the current registered administrator ID inside this file (model / catalog / product.tpl).
This is how I think about it, if this idea is completely wrong, write some of the best solutions.