create : Fixed bug - display data entry form selection only when it's necessary
authorBenjamin Renard <brenard@easter-eggs.com>
Thu, 18 Nov 2010 10:17:46 +0000 (11:17 +0100)
committerBenjamin Renard <brenard@easter-eggs.com>
Thu, 18 Nov 2010 10:18:34 +0000 (11:18 +0100)
public_html/create.php
public_html/templates/default/create.tpl

index 9fbbef5..498f82a 100644 (file)
@@ -49,7 +49,7 @@ if(LSsession :: startLSsession()) {
           $GLOBALS['Smarty'] -> assign('LSform_dataEntryForm',(string)$_REQUEST['LSform_dataEntryForm']);
         }
 
-        $GLOBALS['Smarty'] -> assign('listAvailableDataEntryForm',array_merge(array(''=>''),LSform :: listAvailableDataEntryForm($LSobject)));
+        $GLOBALS['Smarty'] -> assign('listAvailableDataEntryForm',LSform :: listAvailableDataEntryForm($LSobject));
         $GLOBALS['Smarty'] -> assign('DataEntryFormLabel',_('Data entry form'));
 
         if ($form->validate()) {
index ee2912e..e65cbac 100644 (file)
@@ -4,6 +4,7 @@
     {if !empty($listAvailableDataEntryForm)}
       <p class='LSform_listAvailableDataEntryForm'><label>{$DataEntryFormLabel}
       <select id='LSform_listAvailableDataEntryForm'>
+       <option value=''>--</option>
         {html_options options=$listAvailableDataEntryForm selected=$LSform_dataEntryForm}
       </select>
       </label>