Merge branch '12.0' of git@github.com:Dolibarr/dolibarr.git into 12.0
This commit is contained in:
commit
dd70d68b4c
@ -309,7 +309,7 @@ class InterfaceWorkflowManager extends DolibarrTriggers
|
|||||||
$diff_array = array_diff_assoc($qtyordred, $qtyshipped);
|
$diff_array = array_diff_assoc($qtyordred, $qtyshipped);
|
||||||
if (count($diff_array) == 0) {
|
if (count($diff_array) == 0) {
|
||||||
//No diff => mean everythings is shipped
|
//No diff => mean everythings is shipped
|
||||||
$ret = $object->setStatut(Commande::STATUS_CLOSED, $object->origin_id, $object->origin, 'ORDER_CLOSE');
|
$ret = $order->setStatut(Commande::STATUS_CLOSED, $object->origin_id, $object->origin, 'ORDER_CLOSE');
|
||||||
if ($ret < 0) {
|
if ($ret < 0) {
|
||||||
$this->error = $object->error; $this->errors = $object->errors;
|
$this->error = $object->error; $this->errors = $object->errors;
|
||||||
return $ret;
|
return $ret;
|
||||||
|
|||||||
@ -464,7 +464,7 @@ class CommandeFournisseur extends CommonOrder
|
|||||||
$sql .= " FROM ".MAIN_DB_PREFIX."commande_fournisseurdet as l";
|
$sql .= " FROM ".MAIN_DB_PREFIX."commande_fournisseurdet as l";
|
||||||
$sql .= ' LEFT JOIN '.MAIN_DB_PREFIX.'product as p ON l.fk_product = p.rowid';
|
$sql .= ' LEFT JOIN '.MAIN_DB_PREFIX.'product as p ON l.fk_product = p.rowid';
|
||||||
if (!empty($conf->global->PRODUCT_USE_SUPPLIER_PACKAGING))
|
if (!empty($conf->global->PRODUCT_USE_SUPPLIER_PACKAGING))
|
||||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."product_fournisseur_price as pfp ON l.fk_product = pfp.fk_product and l.ref = pfp.ref_fourn";
|
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."product_fournisseur_price as pfp ON l.fk_product = pfp.fk_product and l.ref = pfp.ref_fourn AND pfp.fk_soc = ".$this->socid;
|
||||||
$sql .= " WHERE l.fk_commande = ".$this->id;
|
$sql .= " WHERE l.fk_commande = ".$this->id;
|
||||||
if ($only_product) $sql .= ' AND p.fk_product_type = 0';
|
if ($only_product) $sql .= ' AND p.fk_product_type = 0';
|
||||||
$sql .= " ORDER BY l.rang, l.rowid";
|
$sql .= " ORDER BY l.rang, l.rowid";
|
||||||
|
|||||||
@ -81,6 +81,9 @@ if (($id > 0) || $ref)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context
|
||||||
|
$hookmanager->initHooks(array('holidaycard', 'globalcard'));
|
||||||
|
|
||||||
$cancreate = 0;
|
$cancreate = 0;
|
||||||
if (!empty($user->rights->holiday->write_all)) $cancreate = 1;
|
if (!empty($user->rights->holiday->write_all)) $cancreate = 1;
|
||||||
if (!empty($user->rights->holiday->write) && in_array($fuserid, $childids)) $cancreate = 1;
|
if (!empty($user->rights->holiday->write) && in_array($fuserid, $childids)) $cancreate = 1;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user