Merge branch '11.0' of git@github.com:Dolibarr/dolibarr.git into 12.0
Conflicts: htdocs/expedition/class/expedition.class.php
This commit is contained in:
commit
8045cff888
@ -8,6 +8,7 @@ ALL:
|
|||||||
Check "@CHANGE"
|
Check "@CHANGE"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
PrestaShopWebservice:
|
PrestaShopWebservice:
|
||||||
---------------------
|
---------------------
|
||||||
Replace
|
Replace
|
||||||
@ -27,6 +28,19 @@ With
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
DEBUGBAR:
|
||||||
|
---------
|
||||||
|
|
||||||
|
Move
|
||||||
|
this.options = {
|
||||||
|
bodyMarginBottom: true,
|
||||||
|
bodyMarginBottomHeight: parseInt($('body').css('margin-bottom')),
|
||||||
|
};
|
||||||
|
few line lower in the
|
||||||
|
initialize: function() {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
ESCPOS:
|
ESCPOS:
|
||||||
-------
|
-------
|
||||||
Replace
|
Replace
|
||||||
|
|||||||
@ -412,8 +412,8 @@ else
|
|||||||
$nbtotalofrecords = '';
|
$nbtotalofrecords = '';
|
||||||
if (empty($conf->global->MAIN_DISABLE_FULL_SCANLIST))
|
if (empty($conf->global->MAIN_DISABLE_FULL_SCANLIST))
|
||||||
{
|
{
|
||||||
$result = $db->query($sql);
|
$resql = $db->query($sql);
|
||||||
$nbtotalofrecords = $db->num_rows($result);
|
$nbtotalofrecords = $db->num_rows($resql);
|
||||||
if (($page * $limit) > $nbtotalofrecords) // if total resultset is smaller then paging size (filtering), goto and load page 0
|
if (($page * $limit) > $nbtotalofrecords) // if total resultset is smaller then paging size (filtering), goto and load page 0
|
||||||
{
|
{
|
||||||
$page = 0;
|
$page = 0;
|
||||||
@ -423,14 +423,14 @@ if (empty($conf->global->MAIN_DISABLE_FULL_SCANLIST))
|
|||||||
|
|
||||||
$sql .= $db->plimit($limit + 1, $offset);
|
$sql .= $db->plimit($limit + 1, $offset);
|
||||||
|
|
||||||
$result = $db->query($sql);
|
$resql = $db->query($sql);
|
||||||
if (!$result)
|
if (! $resql)
|
||||||
{
|
{
|
||||||
dol_print_error($db);
|
dol_print_error($db);
|
||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
$num = $db->num_rows($result);
|
$num = $db->num_rows($resql);
|
||||||
|
|
||||||
$arrayofselected = is_array($toselect) ? $toselect : array();
|
$arrayofselected = is_array($toselect) ? $toselect : array();
|
||||||
|
|
||||||
@ -786,7 +786,7 @@ $i = 0;
|
|||||||
$totalarray = array();
|
$totalarray = array();
|
||||||
while ($i < min($num, $limit))
|
while ($i < min($num, $limit))
|
||||||
{
|
{
|
||||||
$obj = $db->fetch_object($result);
|
$obj = $db->fetch_object($resql);
|
||||||
|
|
||||||
$arraysocialnetworks = (array) json_decode($obj->socialnetworks, true);
|
$arraysocialnetworks = (array) json_decode($obj->socialnetworks, true);
|
||||||
$contactstatic->lastname = $obj->lastname;
|
$contactstatic->lastname = $obj->lastname;
|
||||||
@ -986,7 +986,7 @@ while ($i < min($num, $limit))
|
|||||||
$i++;
|
$i++;
|
||||||
}
|
}
|
||||||
|
|
||||||
$db->free($result);
|
$db->free($resql);
|
||||||
|
|
||||||
$parameters = array('arrayfields'=>$arrayfields, 'sql'=>$sql);
|
$parameters = array('arrayfields'=>$arrayfields, 'sql'=>$sql);
|
||||||
$reshook = $hookmanager->executeHooks('printFieldListFooter', $parameters); // Note that $action and $object may have been modified by hook
|
$reshook = $hookmanager->executeHooks('printFieldListFooter', $parameters); // Note that $action and $object may have been modified by hook
|
||||||
|
|||||||
@ -1859,7 +1859,6 @@ function pdf_getlineunit($object, $i, $outputlangs, $hidedetails = 0, $hookmanag
|
|||||||
}
|
}
|
||||||
if (empty($reshook))
|
if (empty($reshook))
|
||||||
{
|
{
|
||||||
if ($object->lines[$i]->special_code == 3) return '';
|
|
||||||
if (empty($hidedetails) || $hidedetails > 1) $result .= $langs->transnoentitiesnoconv($object->lines[$i]->getLabelOfUnit('short'));
|
if (empty($hidedetails) || $hidedetails > 1) $result .= $langs->transnoentitiesnoconv($object->lines[$i]->getLabelOfUnit('short'));
|
||||||
}
|
}
|
||||||
return $result;
|
return $result;
|
||||||
|
|||||||
@ -292,6 +292,7 @@ class Expedition extends CommonObject
|
|||||||
$this->db->begin();
|
$this->db->begin();
|
||||||
|
|
||||||
$sql = "INSERT INTO ".MAIN_DB_PREFIX."expedition (";
|
$sql = "INSERT INTO ".MAIN_DB_PREFIX."expedition (";
|
||||||
|
|
||||||
$sql .= "ref";
|
$sql .= "ref";
|
||||||
$sql .= ", entity";
|
$sql .= ", entity";
|
||||||
$sql .= ", ref_customer";
|
$sql .= ", ref_customer";
|
||||||
@ -331,10 +332,10 @@ class Expedition extends CommonObject
|
|||||||
$sql .= ", ".($this->fk_delivery_address > 0 ? $this->fk_delivery_address : "null");
|
$sql .= ", ".($this->fk_delivery_address > 0 ? $this->fk_delivery_address : "null");
|
||||||
$sql .= ", ".($this->shipping_method_id > 0 ? $this->shipping_method_id : "null");
|
$sql .= ", ".($this->shipping_method_id > 0 ? $this->shipping_method_id : "null");
|
||||||
$sql .= ", '".$this->db->escape($this->tracking_number)."'";
|
$sql .= ", '".$this->db->escape($this->tracking_number)."'";
|
||||||
$sql .= ", ".$this->weight;
|
$sql.= ", ".(is_numeric($this->weight)?$this->weight:'NULL');
|
||||||
$sql .= ", ".$this->sizeS; // TODO Should use this->trueDepth
|
$sql.= ", ".(is_numeric($this->sizeS)?$this->sizeS:'NULL'); // TODO Should use this->trueDepth
|
||||||
$sql .= ", ".$this->sizeW; // TODO Should use this->trueWidth
|
$sql.= ", ".(is_numeric($this->sizeW)?$this->sizeW:'NULL'); // TODO Should use this->trueWidth
|
||||||
$sql .= ", ".$this->sizeH; // TODO Should use this->trueHeight
|
$sql.= ", ".(is_numeric($this->sizeH)?$this->sizeH:'NULL'); // TODO Should use this->trueHeight
|
||||||
$sql .= ", ".($this->weight_units != '' ? (int) $this->weight_units : 'NULL');
|
$sql .= ", ".($this->weight_units != '' ? (int) $this->weight_units : 'NULL');
|
||||||
$sql .= ", ".($this->size_units != '' ? (int) $this->size_units : 'NULL');
|
$sql .= ", ".($this->size_units != '' ? (int) $this->size_units : 'NULL');
|
||||||
$sql .= ", ".(!empty($this->note_private) ? "'".$this->db->escape($this->note_private)."'" : "null");
|
$sql .= ", ".(!empty($this->note_private) ? "'".$this->db->escape($this->note_private)."'" : "null");
|
||||||
|
|||||||
@ -332,9 +332,11 @@ class CommandeFournisseur extends CommonOrder
|
|||||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."c_paiement as p ON c.fk_mode_reglement = p.id";
|
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."c_paiement as p ON c.fk_mode_reglement = p.id";
|
||||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."c_input_method as cm ON cm.rowid = c.fk_input_method";
|
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."c_input_method as cm ON cm.rowid = c.fk_input_method";
|
||||||
$sql .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_incoterms as i ON c.fk_incoterms = i.rowid';
|
$sql .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_incoterms as i ON c.fk_incoterms = i.rowid';
|
||||||
$sql .= " WHERE c.entity IN (".getEntity('supplier_order').")";
|
|
||||||
|
if (empty($id)) $sql .= " WHERE c.entity IN (".getEntity('supplier_order').")";
|
||||||
|
else $sql .= " WHERE c.rowid=".$id;
|
||||||
|
|
||||||
if ($ref) $sql .= " AND c.ref='".$this->db->escape($ref)."'";
|
if ($ref) $sql .= " AND c.ref='".$this->db->escape($ref)."'";
|
||||||
else $sql .= " AND c.rowid=".$id;
|
|
||||||
|
|
||||||
dol_syslog(get_class($this)."::fetch", LOG_DEBUG);
|
dol_syslog(get_class($this)."::fetch", LOG_DEBUG);
|
||||||
$resql = $this->db->query($sql);
|
$resql = $this->db->query($sql);
|
||||||
|
|||||||
@ -409,12 +409,11 @@ if (typeof(PhpDebugBar) == 'undefined') {
|
|||||||
|
|
||||||
className: "phpdebugbar " + csscls('minimized'),
|
className: "phpdebugbar " + csscls('minimized'),
|
||||||
|
|
||||||
options: {
|
|
||||||
bodyMarginBottom: true,
|
|
||||||
bodyMarginBottomHeight: parseInt($('body').css('margin-bottom'))
|
|
||||||
},
|
|
||||||
|
|
||||||
initialize: function() {
|
initialize: function() {
|
||||||
|
this.options = {
|
||||||
|
bodyMarginBottom: true,
|
||||||
|
bodyMarginBottomHeight: parseInt($('body').css('margin-bottom')),
|
||||||
|
};
|
||||||
this.controls = {};
|
this.controls = {};
|
||||||
this.dataMap = {};
|
this.dataMap = {};
|
||||||
this.datasets = {};
|
this.datasets = {};
|
||||||
|
|||||||
@ -204,7 +204,7 @@ if ($id > 0 || !empty($ref))
|
|||||||
print_liste_field_titre("Company", $_SERVER["PHP_SELF"], "s.nom", "", $option, '', $sortfield, $sortorder);
|
print_liste_field_titre("Company", $_SERVER["PHP_SELF"], "s.nom", "", $option, '', $sortfield, $sortorder);
|
||||||
print_liste_field_titre("DatePropal", $_SERVER["PHP_SELF"], "p.datep", "", $option, 'align="center"', $sortfield, $sortorder);
|
print_liste_field_titre("DatePropal", $_SERVER["PHP_SELF"], "p.datep", "", $option, 'align="center"', $sortfield, $sortorder);
|
||||||
print_liste_field_titre("Qty", $_SERVER["PHP_SELF"], "d.qty", "", $option, 'align="center"', $sortfield, $sortorder);
|
print_liste_field_titre("Qty", $_SERVER["PHP_SELF"], "d.qty", "", $option, 'align="center"', $sortfield, $sortorder);
|
||||||
print_liste_field_titre("AmountHT", $_SERVER["PHP_SELF"], "p.total", "", $option, 'align="right"', $sortfield, $sortorder);
|
print_liste_field_titre("AmountHT", $_SERVER["PHP_SELF"], "d.total_ht", "", $option, 'align="right"', $sortfield, $sortorder);
|
||||||
print_liste_field_titre("Status", $_SERVER["PHP_SELF"], "p.fk_statut", "", $option, 'align="right"', $sortfield, $sortorder);
|
print_liste_field_titre("Status", $_SERVER["PHP_SELF"], "p.fk_statut", "", $option, 'align="right"', $sortfield, $sortorder);
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user