Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop
This commit is contained in:
commit
56c8ee8978
@ -6444,6 +6444,11 @@ class Form
|
||||
else $morehtmlstatus=$hookmanager->resPrint;
|
||||
if ($morehtmlstatus) $ret.='<div class="statusref">'.$morehtmlstatus.'</div>';
|
||||
|
||||
$parameters = array();
|
||||
$reshook = $hookmanager->executeHooks('moreHtmlRef', $parameters, $object); // Note that $action and $object may have been modified by hook
|
||||
if (empty($reshook)) $morehtmlref.=$hookmanager->resPrint;
|
||||
elseif ($reshook > 0) $morehtmlref=$hookmanager->resPrint;
|
||||
|
||||
// Left part of banner
|
||||
if ($morehtmlleft)
|
||||
{
|
||||
|
||||
@ -1298,6 +1298,7 @@ function dol_banner_tab($object, $paramid, $morehtml='', $shownav=1, $fieldid='r
|
||||
|
||||
$maxvisiblephotos=1;
|
||||
$showimage=1;
|
||||
$entity=(empty($object->entity)?$conf->entity:$object->entity);
|
||||
$showbarcode=empty($conf->barcode->enabled)?0:($object->barcode?1:0);
|
||||
if (! empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->barcode->lire_advance)) $showbarcode=0;
|
||||
$modulepart='unknown';
|
||||
@ -1324,10 +1325,10 @@ function dol_banner_tab($object, $paramid, $morehtml='', $shownav=1, $fieldid='r
|
||||
if ($object->element == 'product')
|
||||
{
|
||||
$width=80; $cssclass='photoref';
|
||||
$showimage=$object->is_photo_available($conf->product->multidir_output[$object->entity]);
|
||||
$showimage=$object->is_photo_available($conf->product->multidir_output[$entity]);
|
||||
$maxvisiblephotos=(isset($conf->global->PRODUCT_MAX_VISIBLE_PHOTO)?$conf->global->PRODUCT_MAX_VISIBLE_PHOTO:5);
|
||||
if ($conf->browser->phone) $maxvisiblephotos=1;
|
||||
if ($showimage) $morehtmlleft.='<div class="floatleft inline-block valignmiddle divphotoref">'.$object->show_photos('product', $conf->product->multidir_output[$object->entity],'small',$maxvisiblephotos,0,0,0,$width,0).'</div>';
|
||||
if ($showimage) $morehtmlleft.='<div class="floatleft inline-block valignmiddle divphotoref">'.$object->show_photos('product', $conf->product->multidir_output[$entity],'small',$maxvisiblephotos,0,0,0,$width,0).'</div>';
|
||||
else
|
||||
{
|
||||
if (!empty($conf->global->PRODUCT_NODISPLAYIFNOPHOTO)) {
|
||||
@ -1343,10 +1344,10 @@ function dol_banner_tab($object, $paramid, $morehtml='', $shownav=1, $fieldid='r
|
||||
elseif ($object->element == 'ticketsup')
|
||||
{
|
||||
$width=80; $cssclass='photoref';
|
||||
$showimage=$object->is_photo_available($conf->ticketsup->dir_output.'/'.$object->track_id);
|
||||
$showimage=$object->is_photo_available($conf->ticketsup->multidir_output[$entity].'/'.$object->track_id);
|
||||
$maxvisiblephotos=(isset($conf->global->TICKETSUP_MAX_VISIBLE_PHOTO)?$conf->global->TICKETSUP_MAX_VISIBLE_PHOTO:2);
|
||||
if ($conf->browser->phone) $maxvisiblephotos=1;
|
||||
if ($showimage) $morehtmlleft.='<div class="floatleft inline-block valignmiddle divphotoref">'.$object->show_photos('ticketsup', $conf->ticketsup->dir_output,'small',$maxvisiblephotos,0,0,0,$width,0).'</div>';
|
||||
if ($showimage) $morehtmlleft.='<div class="floatleft inline-block valignmiddle divphotoref">'.$object->show_photos('ticketsup', $conf->ticketsup->multidir_output[$entity],'small',$maxvisiblephotos,0,0,0,$width,0).'</div>';
|
||||
else
|
||||
{
|
||||
if (!empty($conf->global->TICKETSUP_NODISPLAYIFNOPHOTO)) {
|
||||
@ -1370,7 +1371,7 @@ function dol_banner_tab($object, $paramid, $morehtml='', $shownav=1, $fieldid='r
|
||||
if (in_array($modulepart, array('propal', 'commande', 'facture', 'ficheinter', 'contract', 'supplier_order', 'supplier_proposal', 'supplier_invoice', 'expensereport')) && class_exists("Imagick"))
|
||||
{
|
||||
$objectref = dol_sanitizeFileName($object->ref);
|
||||
$dir_output = $conf->$modulepart->dir_output . "/";
|
||||
$dir_output = $conf->$modulepart->multidir_output[$entity] . "/";
|
||||
if (in_array($modulepart, array('invoice_supplier', 'supplier_invoice')))
|
||||
{
|
||||
$subdir = get_exdir($object->id, 2, 0, 0, $object, $modulepart).$objectref; // the objectref dir is not include into get_exdir when used with level=2, so we add it here
|
||||
|
||||
@ -736,7 +736,7 @@ if ($id > 0 || ! empty($ref)) {
|
||||
// List of lines already dispatched
|
||||
$sql = "SELECT p.ref, p.label,";
|
||||
$sql .= " e.rowid as warehouse_id, e.ref as entrepot,";
|
||||
$sql .= " cfd.rowid as dispatchlineid, cfd.fk_product, cfd.qty, cfd.eatby, cfd.sellby, cfd.batch, cfd.comment, cfd.status";
|
||||
$sql .= " cfd.rowid as dispatchlineid, cfd.fk_product, cfd.qty, cfd.eatby, cfd.sellby, cfd.batch, cfd.comment, cfd.status, cfd.datec";
|
||||
$sql .= " FROM " . MAIN_DB_PREFIX . "product as p,";
|
||||
$sql .= " " . MAIN_DB_PREFIX . "commande_fournisseur_dispatch as cfd";
|
||||
$sql .= " LEFT JOIN " . MAIN_DB_PREFIX . "entrepot as e ON cfd.fk_entrepot = e.rowid";
|
||||
@ -770,6 +770,7 @@ if ($id > 0 || ! empty($ref)) {
|
||||
print '<td>' . $langs->trans("Comment") . '</td>';
|
||||
if (! empty($conf->global->SUPPLIER_ORDER_USE_DISPATCH_STATUS))
|
||||
print '<td align="center" colspan="2">' . $langs->trans("Status") . '</td>';
|
||||
print '<td>' . $langs->trans("Date") . '</td>';
|
||||
print "</tr>\n";
|
||||
|
||||
$var = false;
|
||||
@ -841,7 +842,9 @@ if ($id > 0 || ! empty($ref)) {
|
||||
}
|
||||
print '</td>';
|
||||
}
|
||||
|
||||
// date
|
||||
print '<td>' . dol_print_date($objp->datec) . '</td>';
|
||||
|
||||
print "</tr>\n";
|
||||
|
||||
$i ++;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user