2
0
forked from Wavyzz/dolibarr

Merge branch '17.0' of git@github.com:Dolibarr/dolibarr.git into develop

This commit is contained in:
Laurent Destailleur
2022-12-27 12:05:13 +01:00
4 changed files with 7 additions and 6 deletions

View File

@@ -48,7 +48,7 @@ $thirdpartytmp = new Societe($db);
$modBarCodeProduct = '';
$modBarCodeThirdparty = '';
$maxperinit = 1000;
$maxperinit = empty($conf->global->BARCODE_INIT_MAX) ? 1000 : $conf->global->BARCODE_INIT_MAX;
// Security check (enable the most restrictive one)
//if ($user->socid > 0) accessforbidden();

View File

@@ -374,7 +374,7 @@ if ($cats < 0) {
dol_print_error($db, $object->error, $object->errors);
} elseif (count($cats) < 1) {
print '<tr class="oddeven">';
print '<td colspan="3" class="opacitymedium">'.$langs->trans("NoSubCat").'</td>';
print '<td colspan="3"><span class="opacitymedium">'.$langs->trans("NoSubCat").'</span></td>';
print '</tr>';
} else {
$categstatic = new Categorie($db);
@@ -461,7 +461,7 @@ if ($cats < 0) {
print '<tr class="nobordernopadding">';
print '<td>'.img_picto_common('', 'treemenu/branchbottom.gif').'</td>';
print '<td valign="middle">'.$langs->trans("NoCategoryYet").'</td>';
print '<td class="valignmiddle">'.$langs->trans("NoCategoryYet").'</td>';
print '<td>&nbsp;</td>';
print '</tr>';

View File

@@ -146,9 +146,10 @@ class FormTicket
* @param string $mode Mode ('create' or 'edit')
* @param int $public 1=If we show the form for the public interface
* @param Contact|null $with_contact [=NULL] Contact to link to this ticket if exists
* @param string $action [=''] Action in card
* @return void
*/
public function showForm($withdolfichehead = 0, $mode = 'edit', $public = 0, Contact $with_contact = null)
public function showForm($withdolfichehead = 0, $mode = 'edit', $public = 0, Contact $with_contact = null, $action = '')
{
global $conf, $langs, $user, $hookmanager;
@@ -636,7 +637,7 @@ class FormTicket
// Other attributes
$parameters = array();
$reshook = $hookmanager->executeHooks('formObjectOptions', $parameters, $ticketstat, $this->action); // Note that $action and $object may have been modified by hook
$reshook = $hookmanager->executeHooks('formObjectOptions', $parameters, $ticketstat, $action); // Note that $action and $object may have been modified by hook
if (empty($reshook)) {
print $ticketstat->showOptionals($extrafields, 'create');
}

View File

@@ -739,7 +739,7 @@ if ($action == 'create' || $action == 'presend') {
$formticket->withcancel = 1;
$formticket->showForm(1, 'create', 0);
$formticket->showForm(1, 'create', 0, null, $action);
/*} elseif ($action == 'edit' && $user->rights->ticket->write && $object->status < Ticket::STATUS_CLOSED) {
$formticket = new FormTicket($db);