Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
This commit is contained in:
commit
1d2371af34
9 changed files with 33 additions and 13 deletions
|
|
@ -270,9 +270,18 @@ if (empty($reshook)) {
|
|||
if (!$mesg) {
|
||||
$outputlangs = $langs;
|
||||
|
||||
$previousConf = getDolGlobalInt('TCPDF_THROW_ERRORS_INSTEAD_OF_DIE');
|
||||
$conf->global->TCPDF_THROW_ERRORS_INSTEAD_OF_DIE = 1;
|
||||
|
||||
// This generates and send PDF to output
|
||||
// TODO Move
|
||||
$result = doc_label_pdf_create($db, $arrayofrecords, $modellabel, $outputlangs, $diroutput, $template, dol_sanitizeFileName($outfile));
|
||||
try {
|
||||
$result = doc_label_pdf_create($db, $arrayofrecords, $modellabel, $outputlangs, $diroutput, $template, dol_sanitizeFileName($outfile));
|
||||
} catch (Exception $e) {
|
||||
$mesg = $langs->trans('ErrorGeneratingBarcode');
|
||||
}
|
||||
|
||||
$conf->global->TCPDF_THROW_ERRORS_INSTEAD_OF_DIE = $previousConf;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -548,7 +548,7 @@ if ($num == 0) {
|
|||
print '<tr><td colspan="8"><span class="opacitymedium">'.$langs->trans("None").'</span></td></tr>';
|
||||
}
|
||||
|
||||
$db->free($result);
|
||||
$db->free($resql);
|
||||
|
||||
$parameters = array('arrayfields' => $arrayfields, 'sql' => $sql);
|
||||
$reshook = $hookmanager->executeHooks('printFieldListFooter', $parameters, $object, $action); // Note that $action and $object may have been modified by hook
|
||||
|
|
|
|||
|
|
@ -466,7 +466,7 @@ if ($num == 0) {
|
|||
print '<tr><td colspan="5"><span class="opacitymedium">'.$langs->trans("None").'</span></td></tr>';
|
||||
}
|
||||
|
||||
$db->free($result);
|
||||
$db->free($resql);
|
||||
|
||||
$parameters = array('arrayfields' => $arrayfields, 'sql' => $sql);
|
||||
$reshook = $hookmanager->executeHooks('printFieldListFooter', $parameters, $object, $action); // Note that $action and $object may have been modified by hook
|
||||
|
|
|
|||
|
|
@ -96,7 +96,7 @@ if (isModEnabled('mrp') && $user->hasRight('mrp', 'read') && !getDolGlobalString
|
|||
if (isModEnabled('project') && !getDolGlobalString('MAIN_SEARCHFORM_PROJECT_DISABLED') && $user->hasRight('projet', 'lire')) {
|
||||
$arrayresult['searchintoprojects'] = array('position' => 40, 'shortcut' => 'Q', 'img' => 'object_project', 'label' => $langs->trans("SearchIntoProjects", $search_boxvalue), 'text' => img_picto('', 'object_project', 'class="pictofixedwidth"').' '.$langs->trans("SearchIntoProjects", $search_boxvalue), 'url' => DOL_URL_ROOT.'/projet/list.php'.($search_boxvalue ? '?search_all='.urlencode($search_boxvalue) : ''));
|
||||
}
|
||||
if (isModEnabled('project') && !getDolGlobalString('MAIN_SEARCHFORM_TASK_DISABLED') && $user->hasRight('projet', 'lire')) {
|
||||
if (isModEnabled('project') && !getDolGlobalString('MAIN_SEARCHFORM_TASK_DISABLED') && !getDolGlobalString('PROJECT_HIDE_TASKS') && $user->hasRight('projet', 'lire')) {
|
||||
$arrayresult['searchintotasks'] = array('position' => 45, 'img' => 'object_projecttask', 'label' => $langs->trans("SearchIntoTasks", $search_boxvalue), 'text' => img_picto('', 'object_projecttask', 'class="pictofixedwidth"').' '.$langs->trans("SearchIntoTasks", $search_boxvalue), 'url' => DOL_URL_ROOT.'/projet/tasks/list.php'.($search_boxvalue ? '?search_all='.urlencode($search_boxvalue) : ''));
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -551,14 +551,16 @@ function project_admin_prepare_head()
|
|||
$head[$h][2] = 'attributes';
|
||||
$h++;
|
||||
|
||||
$head[$h][0] = DOL_URL_ROOT.'/projet/admin/project_task_extrafields.php';
|
||||
$head[$h][1] = $langs->trans("ExtraFieldsProjectTask");
|
||||
$nbExtrafields = $extrafields->attributes['projet_task']['count'];
|
||||
if ($nbExtrafields > 0) {
|
||||
$head[$h][1] .= '<span class="badge marginleftonlyshort">'.$nbExtrafields.'</span>';
|
||||
if (empty($conf->global->PROJECT_HIDE_TASKS)) {
|
||||
$head[$h][0] = DOL_URL_ROOT . '/projet/admin/project_task_extrafields.php';
|
||||
$head[$h][1] = $langs->trans("ExtraFieldsProjectTask");
|
||||
$nbExtrafields = $extrafields->attributes['projet_task']['count'];
|
||||
if ($nbExtrafields > 0) {
|
||||
$head[$h][1] .= '<span class="badge marginleftonlyshort">' . $nbExtrafields . '</span>';
|
||||
}
|
||||
$head[$h][2] = 'attributes_task';
|
||||
$h++;
|
||||
}
|
||||
$head[$h][2] = 'attributes_task';
|
||||
$h++;
|
||||
|
||||
if (getDolGlobalString('PROJECT_USE_OPPORTUNITIES')) {
|
||||
$langs->load("members");
|
||||
|
|
|
|||
|
|
@ -324,7 +324,8 @@ ErrorFixThisHere=<a href="%s">Fix this here</a>
|
|||
ErrorTheUrlOfYourDolInstanceDoesNotMatchURLIntoOAuthSetup=Error: The URL of you current instance (%s) does not match the URL defined into your OAuth2 login setup (%s). Doing OAuth2 login in such a configuration is not allowed.
|
||||
ErrorMenuExistValue=A Menu already exist with this Title or URL
|
||||
ErrorSVGFilesNotAllowedAsLinksWithout=SVG files are not allowed as external links without the option %s
|
||||
ErrorTypeMenu=Impossible to add another menu for the same module on the navbar, not handle yet
|
||||
ErrorTypeMenu=Impossible to add another menu for the same module on the navbar, not handled yet
|
||||
ErrorGeneratingBarcode=Error while generating the barcode (probably invalid code shape)
|
||||
ErrorObjectNotFound = The object <b>%s</b> is not found, please check your url
|
||||
ErrorCountryCodeMustBe2Char=Country code must be a 2 character string
|
||||
ErrorABatchShouldNotContainsSpaces=A lot or serial number should not contains spaces
|
||||
|
|
|
|||
|
|
@ -322,6 +322,7 @@ ErrorFixThisHere= <a href="%s"> Corrigez ceci ici </a>
|
|||
ErrorTheUrlOfYourDolInstanceDoesNotMatchURLIntoOAuthSetup=Erreur : L'URL de votre instance actuelle (%s) ne correspond pas à l'URL définie dans votre configuration de connexion OAuth2 (%s). La connexion OAuth2 dans une telle configuration n'est pas autorisée.
|
||||
ErrorMenuExistValue=Un menu existe déjà avec ce titre ou cette URL
|
||||
ErrorSVGFilesNotAllowedAsLinksWithout=Les fichiers SVG ne sont pas autorisés en tant que liens externes sans l'option %s
|
||||
ErrorGeneratingBarcode=Erreur à la génération du code-barre (probablement une valeur invalide)
|
||||
ErrorTypeMenu=Impossible d'ajouter un autre menu pour le même module sur la barre de navigation, pas encore géré
|
||||
ErrorObjectNotFound = L'objet <b>%s</b> n'est pas trouvé, veuillez vérifier votre url
|
||||
ErrorCountryCodeMustBe2Char=Le code pays doit être une chaîne de 2 caractères
|
||||
|
|
|
|||
|
|
@ -365,7 +365,7 @@ $sql .= ' FROM ' . MAIN_DB_PREFIX . 'product as p';
|
|||
$sql .= ' LEFT JOIN ' . MAIN_DB_PREFIX . 'product_stock as s ON p.rowid = s.fk_product';
|
||||
$sql .= ' AND s.fk_entrepot IN (' . $db->sanitize($list_warehouse) . ')';
|
||||
|
||||
$list_warehouse_selected = ($fk_entrepot < 0) ? '0' : $fk_entrepot;
|
||||
$list_warehouse_selected = ($fk_entrepot < 0 || empty($fk_entrepot)) ? '0' : $fk_entrepot;
|
||||
$sql .= ' AND s.fk_entrepot IN (' . $db->sanitize($list_warehouse_selected) . ')';
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -1861,6 +1861,13 @@ if ($placeid > 0) {
|
|||
if ($line->product_label) {
|
||||
$htmlforlines .= $line->product_label;
|
||||
}
|
||||
if (!empty($line->batch)) {
|
||||
$tooltiptext .= '<br><b>'.$langs->trans("LotSerial").'</b> : '.$line->batch.'<br>';
|
||||
}
|
||||
if (!empty($line->fk_warehouse)) {
|
||||
$tooltiptext .= '<b>'.$langs->trans("Warehouse").'</b> : '.$line->fk_warehouse.'<br>';
|
||||
}
|
||||
|
||||
if ($line->product_label != $line->desc) {
|
||||
if ($line->product_label && $line->desc) {
|
||||
$htmlforlines .= '<br>';
|
||||
|
|
|
|||
Loading…
Reference in a new issue