LSform : Move JSconfig from LSldapObject :: getForm() to LSform :: display()

This commit is contained in:
Benjamin Renard 2010-11-17 14:44:52 +01:00
parent b16f14dffc
commit 58474332e4
2 changed files with 7 additions and 3 deletions

View file

@ -130,6 +130,13 @@ class LSform {
$GLOBALS['Smarty'] -> assign('LSform_header',$LSform_header);
$GLOBALS['Smarty'] -> assign('LSform_fields',$fields);
$JSconfig = array (
'ajaxSubmit' => ((isset($this -> config['LSform']['ajaxSubmit']))?$this -> config['LSform']['ajaxSubmit']:1)
);
LSsession :: addJSconfigParam('LSform_'.$this -> idForm,$JSconfig);
if($this -> can_validate) {
$GLOBALS['Smarty'] -> assign('LSform_submittxt',$this -> submit);
}

View file

@ -213,9 +213,6 @@ class LSldapObject {
}
}
}
LSsession :: addJSconfigParam('LSform_'.$idForm,array(
'ajaxSubmit' => ((isset($this -> config['LSform']['ajaxSubmit']))?$this -> config['LSform']['ajaxSubmit']:1)
));
return $LSform;
}