mirror of
https://gitlab.easter-eggs.com/ee/ldapsaisie.git
synced 2024-11-22 09:59:06 +01:00
LSformElement_select : Added error message on display an unrecognized value
This commit is contained in:
parent
90e471646d
commit
a85623dc23
2 changed files with 5 additions and 0 deletions
|
@ -55,6 +55,7 @@ class LSformElement_select extends LSformElement {
|
|||
LSsession :: addJSscript('LSformElement_select.js');
|
||||
}
|
||||
$params['possible_values'] = $this -> params['text_possible_values'];
|
||||
$params['unrecognized_value_label_format'] = _("%{value} (unrecognized value)");
|
||||
$return['html'] = $this -> fetchTemplate(NULL,$params);
|
||||
return $return;
|
||||
}
|
||||
|
|
|
@ -1,7 +1,11 @@
|
|||
<ul class='LSform' id='{$attr_name}'>
|
||||
{if $freeze}
|
||||
{foreach from=$values item=value}
|
||||
{if $possible_values.$value}
|
||||
<li>{$possible_values.$value}</li>
|
||||
{else}
|
||||
<li class='LSform-errors'>{getFData format=$unrecognized_value_label_format data=$value}</li>
|
||||
{/if}
|
||||
{foreachelse}
|
||||
<li>{$noValueTxt}</li>
|
||||
{/foreach}
|
||||
|
|
Loading…
Reference in a new issue