<extend name="Public/base"/> <block name="body"> <div class="cf main-place top_nav_list navtab_list"> <h3 class="page_title">{$meta_title}</h3> <p class="description_text"></p> </div> <div class="tab-content tabcon1711 tabcon17112"> <form action="{:U()}" method="post" class="form-horizontal form_info_ml"> <table border="0" cellspacing="0" cellpadding="0"> <tbody> <tr> <td class="l noticeinfo">配置标识</td> <td class="r table_radio"> <input type="text" class="" name="name" value="{$info.name|default=''}" placeholder="请输入配置标识"> <span class="notice-text">用于C函数调用,只能使用英文且不能重复</span> </td> </tr> <tr> <td class="l noticeinfo">配置标题</td> <td class="r table_radio"> <input type="text" class="" name="title" value="{$info.title|default=''}" placeholder="请输入配置标题"> <span class="notice-text">用于后台显示的配置标题</span> </td> </tr> <tr> <td class="l noticeinfo">排序</td> <td class="r table_radio"> <input type="text" class="" name="sort" value="{$info.sort|default=0}" placeholder="请输入排序"> <span class="notice-text">用于分组显示的顺序</span> </td> </tr> <tr> <td class="l noticeinfo">配置类型</td> <td class="r table_radio"> <span class="form_select"><select name="type"> <volist name="Think.config.CONFIG_TYPE_LIST" id="type"> <option value="{$key}">{$type}</option> </volist> </select></span> <span class="notice-text">系统会根据不同类型解析配置值</span> </td> </tr> <tr> <td class="l noticeinfo">配置分类</td> <td class="r table_radio"> <span class="form_select"><select name="category" id="category"> <option value="0">不分类</option> <volist name="Think.config.CONFIG_CATEGORY_LIST" id="category"> <option value="{$key}">{$category}</option> </volist> </select></span> <span class="notice-text">配置分类 用于批量设置 不分类则不会显示在系统设置中</span> </td> </tr> <tr> <td class="l noticeinfo">配置分组</td> <td class="r table_radio"> <span class="form_select"><select name="group" id="group"> <option value="0">不分组</option> <volist name="Think.config.CONFIG_GROUP_LIST" id="group"> <option value="{$key}">{$group}</option> </volist> </select></span> <span class="notice-text">配置分组 用于批量设置 不分组则不会显示在系统设置中</span> </td> </tr> <tr> <td class="l noticeinfo">配置值</td> <td class="r table_radio"> <textarea name="value">{$info.value|default=''}</textarea> <span class="notice-text">配置值</span> </td> </tr> <tr> <td class="l noticeinfo">配置项</td> <td class="r table_radio"> <textarea name="extra">{$info.extra|default=''}</textarea> <span class="notice-text">如果是枚举型 需要配置该项</span> </td> </tr> <tr> <td class="l noticeinfo">说明</td> <td class="r table_radio"> <textarea name="remark">{$info.remark|default=''}</textarea> <span class="notice-text">配置详细说明</span> </td> </tr> </tbody> </table> <div class="form-item"> <input type="hidden" name="id" value="{$info.id|default=''}"> <button class="submit_btn ajax-post mlspacing" id="submit" type="submit" target-form="form-horizontal">确 定</button> <button class="submit_btn " onclick="javascript:history.back(-1);return false;">返 回</button> </div> </form> </div> <div class="common_settings"> <span class="plus_icon"><span><img src="__IMG__/zwmimages/icon_jia.png"></span></span> <form class="addShortcutIcon"> <input type="hidden" name="title" value="{$m_title}"> <input type="hidden" name="url" value="{$m_url}"> </form> <a class="ajax-post add-butn <notempty name='commonset'>addSIsetted</notempty>" href="javascript:;" target-form="addShortcutIcon" url="{:U('Think/addShortcutIcon')}"><img src="__IMG__/zwmimages/icon_jia.png"><span><notempty name='commonset'>已添加<else />添加至常用设置</notempty></span></a> </div> </block> <block name="script"> <script type="text/javascript"> //导航高亮 highlight_subnav('{:U('Config/index')}'); $(function () { Think.setValue("type", {$info.type|default=0}); Think.setValue("category", {$info.category|default=0}); $("#category").change(); Think.setValue("group", {$info.group|default=0}); }) $("#category").change(function(){ $.ajax({ type:"POST", dataType:"json", async:false, data:{category:$("#category").val()}, url:"{:U('Ajax/getConfigCategory')}", success:function (data) { $("#group").empty(); var str = "<option value='0'>不分类</option>"; for(var i in data){ str += "<option value="+i+">"+data[i]+"</option>"; } $("#group").append(str); } }) }) </script> </block>