Use key value if translation not found

This commit is contained in:
Laurent Destailleur 2012-09-12 16:56:30 +02:00
parent 71c25bb939
commit a7ddbf8f10

View File

@ -863,11 +863,11 @@ if ($id)
$valuetoshow=$obj->$fieldlist[$field]; $valuetoshow=$obj->$fieldlist[$field];
if ($value == 'element') if ($value == 'element')
{ {
$valuetoshow = $elementList[$valuetoshow]; $valuetoshow = isset($elementList[$valuetoshow])?$elementList[$valuetoshow]:$valuetoshow;
} }
else if ($value == 'source') else if ($value == 'source')
{ {
$valuetoshow = $sourceList[$valuetoshow]; $valuetoshow = isset($sourceList[$valuetoshow])?$sourceList[$valuetoshow]:$valuetoshow;
} }
else if ($valuetoshow=='all') { else if ($valuetoshow=='all') {
$valuetoshow=$langs->trans('All'); $valuetoshow=$langs->trans('All');