mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2026-02-07 16:41:48 +01:00
Merge remote-tracking branch 'origin/3.6' into 3.7
Conflicts: htdocs/comm/propal/class/propal.class.php htdocs/commande/class/commande.class.php htdocs/compta/facture/class/facture.class.php
This commit is contained in:
@@ -1048,10 +1048,10 @@ class Commande extends CommonOrder
|
||||
|
||||
// get extrafields from original line
|
||||
$object->fetch_optionals($object->id);
|
||||
|
||||
|
||||
$e = new ExtraFields($db);
|
||||
$element_extrafields = $e->fetch_name_optionals_label($this->element);
|
||||
|
||||
|
||||
foreach($object->array_options as $options_key => $value) {
|
||||
if(array_key_exists(str_replace('options_', '', $options_key), $element_extrafields)){
|
||||
$this->array_options[$options_key] = $value;
|
||||
@@ -2421,16 +2421,16 @@ class Commande extends CommonOrder
|
||||
$price = ($pu - $remise);
|
||||
}
|
||||
|
||||
// Update line
|
||||
$this->line=new OrderLine($this->db);
|
||||
//Fetch current line from the database and then clone the object and set it in $oldline property
|
||||
$line = new OrderLine($this->db);
|
||||
$line->fetch($rowid);
|
||||
|
||||
$staticline = clone $line;
|
||||
|
||||
$line->oldline = $staticline;
|
||||
$this->line = $line;
|
||||
$this->line->context = $this->context;
|
||||
|
||||
// Stock previous line records
|
||||
$staticline=new OrderLine($this->db);
|
||||
$staticline->fetch($rowid);
|
||||
$this->line->oldline = $staticline;
|
||||
|
||||
// Reorder if fk_parent_line change
|
||||
if (! empty($fk_parent_line) && ! empty($staticline->fk_parent_line) && $fk_parent_line != $staticline->fk_parent_line)
|
||||
{
|
||||
@@ -3356,10 +3356,12 @@ class OrderLine extends CommonOrderLine
|
||||
$this->date_end = $this->db->jdate($objp->date_end);
|
||||
|
||||
$this->db->free($result);
|
||||
|
||||
return 1;
|
||||
}
|
||||
else
|
||||
{
|
||||
dol_print_error($this->db);
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user