Merge branch '13.0' of git@github.com:Dolibarr/dolibarr.git into develop
Conflicts: htdocs/bom/bom_card.php
This commit is contained in:
commit
5660159a6d
@ -264,7 +264,7 @@ if (!$error && $xml)
|
||||
$out .= "</tr>\n";
|
||||
}
|
||||
} else {
|
||||
$out .= '<tr class="oddeven"><td colspan="3" class="opacitymedium">'.$langs->trans("None").'</td></tr>';
|
||||
$out .= '<tr class="oddeven"><td colspan="4" class="opacitymedium">'.$langs->trans("None").'</td></tr>';
|
||||
}
|
||||
$out .= '</table>';
|
||||
$out .= '</div>';
|
||||
@ -317,7 +317,7 @@ if (!$error && $xml)
|
||||
$out .= '<td class="right"></td>'."\n";
|
||||
$out .= "</tr>\n";
|
||||
} else {
|
||||
$out .= '<tr class="oddeven"><td colspan="6" class="opacitymedium">'.$langs->trans("None").'</td></tr>';
|
||||
$out .= '<tr class="oddeven"><td colspan="7" class="opacitymedium">'.$langs->trans("None").'</td></tr>';
|
||||
}
|
||||
$out .= '</table>';
|
||||
$out .= '</div>';
|
||||
@ -370,12 +370,11 @@ if (!$error && $xml)
|
||||
$out .= '<td class="right"></td>'."\n";
|
||||
$out .= "</tr>\n";
|
||||
} else {
|
||||
$out .= '<tr class="oddeven"><td colspan="5" class="opacitymedium">'.$langs->trans("None").'</td></tr>';
|
||||
$out .= '<tr class="oddeven"><td colspan="6" class="opacitymedium">'.$langs->trans("None").'</td></tr>';
|
||||
}
|
||||
$out .= '</table>';
|
||||
$out .= '</div>';
|
||||
|
||||
|
||||
// Show warning
|
||||
if (empty($tmpfilelist) && empty($tmpfilelist2) && empty($tmpfilelist3))
|
||||
{
|
||||
|
||||
@ -134,10 +134,10 @@ if (empty($reshook))
|
||||
|
||||
// Set if we used free entry or predefined product
|
||||
$idprod = (int) GETPOST('idprod', 'int');
|
||||
$qty = GETPOST('qty', 'int');
|
||||
$qty_frozen = GETPOST('qty_frozen', 'int');
|
||||
$qty = price2num(GETPOST('qty', 'alpha'), 'MS');
|
||||
$qty_frozen = price2num(GETPOST('qty_frozen', 'alpha'), 'MS');
|
||||
$disable_stock_change = GETPOST('disable_stock_change', 'int');
|
||||
$efficiency = GETPOST('efficiency', 'int');
|
||||
$efficiency = price2num(GETPOST('efficiency', 'alpha'));
|
||||
|
||||
if ($qty == '') {
|
||||
setEventMessages($langs->trans('ErrorFieldRequired', $langs->transnoentitiesnoconv('Qty')), null, 'errors');
|
||||
@ -155,8 +155,6 @@ if (empty($reshook))
|
||||
|
||||
if (!$error)
|
||||
{
|
||||
$lastposition = 0;
|
||||
|
||||
$bomline = new BOMLine($db);
|
||||
$bomline->fk_bom = $id;
|
||||
$bomline->fk_product = $idprod;
|
||||
@ -196,9 +194,9 @@ if (empty($reshook))
|
||||
|
||||
// Set if we used free entry or predefined product
|
||||
$qty = price2num(GETPOST('qty', 'alpha'), 'MS');
|
||||
$qty_frozen = GETPOST('qty_frozen', 'int');
|
||||
$qty_frozen = price2num(GETPOST('qty_frozen', 'alpha'), 'MS');
|
||||
$disable_stock_change = GETPOST('disable_stock_change', 'int');
|
||||
$efficiency = price2num(GETPOST('efficiency', 'int'));
|
||||
$efficiency = price2num(GETPOST('efficiency', 'alpha'));
|
||||
|
||||
if ($qty == '') {
|
||||
setEventMessages($langs->trans('ErrorFieldRequired', $langs->transnoentitiesnoconv('Qty')), null, 'errors');
|
||||
|
||||
@ -56,7 +56,10 @@ foreach ($object->fields as $key => $val)
|
||||
if (!empty($val['picto'])) { print img_picto('', $val['picto']); }
|
||||
if (in_array($val['type'], array('int', 'integer'))) $value = GETPOST($key, 'int');
|
||||
elseif ($val['type'] == 'text' || $val['type'] == 'html') $value = GETPOST($key, 'restricthtml');
|
||||
else $value = GETPOST($key, 'alpha');
|
||||
elseif ($val['type'] == 'date') $value = dol_mktime(12, 0, 0, GETPOST($key.'month', 'int'), GETPOST($key.'day', 'int'), GETPOST($key.'year', 'int'));
|
||||
elseif ($val['type'] == 'datetime') $value = dol_mktime(GETPOST($key.'hour', 'int'), GETPOST($key.'min', 'int'), 0, GETPOST($key.'month', 'int'), GETPOST($key.'day', 'int'), GETPOST($key.'year', 'int'));
|
||||
elseif ($val['type'] == 'boolean') $value = (GETPOST($key) == 'on' ? 1 : 0);
|
||||
else $value = GETPOST($key, 'alphanohtml');
|
||||
if ($val['noteditable']) print $object->showOutputField($val, $key, $value, '', '', '', 0);
|
||||
else print $object->showInputField($val, $key, $value, '', '', '', 0);
|
||||
print '</td>';
|
||||
|
||||
@ -820,6 +820,7 @@ IMG;
|
||||
// Export to PDF using LibreOffice
|
||||
if ($conf->global->MAIN_ODT_AS_PDF == 'libreoffice')
|
||||
{
|
||||
// Install prerequisites: apt install soffice libreoffice-common libreoffice-writer
|
||||
// using windows libreoffice that must be in path
|
||||
// using linux/mac libreoffice that must be in path
|
||||
// Note PHP Config "fastcgi.impersonate=0" must set to 0 - Default is 1
|
||||
@ -856,7 +857,7 @@ IMG;
|
||||
}
|
||||
else
|
||||
{
|
||||
// deprecated old method
|
||||
// deprecated old method using odt2pdf.sh (native, jodconverter, ...)
|
||||
$tmpname=preg_replace('/\.odt/i', '', $name);
|
||||
|
||||
if (!empty($conf->global->MAIN_DOL_SCRIPTS_ROOT))
|
||||
|
||||
Loading…
Reference in New Issue
Block a user