Fix: Show sending method
Fix: Avoid long loop with bad date in dol_print_date
This commit is contained in:
parent
f9dde86da9
commit
5a4dc21369
@ -691,9 +691,13 @@ else
|
|||||||
// Sending method
|
// Sending method
|
||||||
print '<tr><td>'.$langs->trans("SendingMethod").'</td>';
|
print '<tr><td>'.$langs->trans("SendingMethod").'</td>';
|
||||||
print '<td colspan="3">';
|
print '<td colspan="3">';
|
||||||
// Get code using getLabelFromKey
|
if ($expedition->expedition_method_id > 0)
|
||||||
$code=$langs->getLabelFromKey($db,$expedition->expedition_method_id,'expedition_methode','rowid','code');
|
{
|
||||||
print $langs->trans("SendingMethod".strtoupper($code));
|
// Get code using getLabelFromKey
|
||||||
|
$code=$langs->getLabelFromKey($db,$expedition->expedition_method_id,'expedition_methode','rowid','code');
|
||||||
|
print $langs->trans("SendingMethod".strtoupper($code));
|
||||||
|
}
|
||||||
|
else print ' ';
|
||||||
print '</td>';
|
print '</td>';
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
|
|
||||||
|
|||||||
@ -412,7 +412,7 @@ function dol_print_date($time,$format='',$to_gmt=false,$outputlangs='')
|
|||||||
|| eregi('^([0-9][0-9][0-9][0-9])([0-9][0-9])([0-9][0-9])([0-9][0-9])([0-9][0-9])([0-9][0-9])$',$time,$reg))
|
|| eregi('^([0-9][0-9][0-9][0-9])([0-9][0-9])([0-9][0-9])([0-9][0-9])([0-9][0-9])([0-9][0-9])$',$time,$reg))
|
||||||
{
|
{
|
||||||
// This part of code should not be used.
|
// This part of code should not be used.
|
||||||
dolibarr_syslog("Functions.lib::dolibarr_print_date function call with deprecated parameter in page ".$_SERVER["PHP_SELF"], LOG_WARNING);
|
dolibarr_syslog("Functions.lib::dolibarr_print_date function call with deprecated value of time in page ".$_SERVER["PHP_SELF"], LOG_WARNING);
|
||||||
// Date has format 'YYYY-MM-DD' or 'YYYY-MM-DD HH:MM:SS' or 'YYYYMMDDHHMMSS'
|
// Date has format 'YYYY-MM-DD' or 'YYYY-MM-DD HH:MM:SS' or 'YYYYMMDDHHMMSS'
|
||||||
$syear = $reg[1];
|
$syear = $reg[1];
|
||||||
$smonth = $reg[2];
|
$smonth = $reg[2];
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user