{extend name="public/base" /} {block name="body"}
{foreach name="formData" item="vo" key="k"} {php}$name = "params[".$k."]";{/php} {switch name="$vo.type"} {case value="text"} {:form_input($name,'text',['label'=>$vo.title,'tip'=>$vo.tip],$vo.value)} {/case} {case value="textarea"} {:form_textarea($name,['label'=>$vo.title,'tip'=>$vo.tip],$vo.value)} {/case} {case value="password"} {:form_input($name,'password',['label'=>$vo.title,'tip'=>$vo.tip],$vo.value)} {/case} {case value="radio"} {:form_radio($name,$vo.content,['label'=>$vo.title,'tip'=>$vo.tip],$vo.value)} {/case} {case value="select"} {:form_select($name,$vo.content,['label'=>$vo.title,'verify'=>$vo.rule,'tip'=>$vo.tip,'search'=>1] ,[],$vo.value)} {/case} {case value="image"} {:form_upload($name,$vo.value,['label'=>$vo.title,'tip'=>$vo.tip,'verify'=>$vo.rule,'type'=>'radio','num'=>'1','mime'=>'image'])} {/case} {case value="images"} {:form_upload($name,$vo.value,['label'=>$vo.title,'tip'=>$vo.tip,'verify'=>$vo.rule,'type'=>'checkbox','num'=>$vo.num,'mime'=>'image'])} {/case} {case value="file"} {:form_upload($name,$vo.value,['label'=>$vo.title,'tip'=>$vo.tip,'verify'=>$vo.rule,'type'=>'radio','num'=>$vo.num,'mime'=>'*'])} {/case} {case value="files"} {:form_upload($name,$vo.value,['label'=>$vo.title,'tip'=>$vo.tip,'verify'=>$vo.rule,'type'=>'checkbox','num'=>$vo.num,'mime'=>'*'])} {/case} {case value="editor"} {:form_editor($name,$name,2,['label'=>$vo.title,'tip'=>$vo.tip,'verify'=>$vo.rule])} {/case} {case value="array"} {:form_arrays($name,['label'=>$vo.title,'tip'=>$vo.tip,'verify'=>$vo.rule],$vo.value?$vo.value:$vo.content)} {/case} {/switch} {/foreach}
{/block} {block name="js"} {/block}