<@_sysConfig code=code>
    <#assign a=object/>
</@_sysConfig>
<form method="post" autocomplete="off" action="sysConfig/save?callbackType=${closeCurrent!'closeCurrent'}&navTabId=sysConfig/list" class="pageForm required-validate" onsubmit="return validateCallback(this, navTabAjaxDone);">
    <input type="hidden" name="_csrf" value="<@_csrfToken admin=true/>"/>
    <div class="formBar">
        <ul>
    <#if code?has_content>
        <@_sysAuthorized roleIds=admin.roles url='sysConfigData/edit'>
            <li><a class="button" href="sysConfigData/edit.html?code=${code!}" target="navTab" rel="sysConfigData/edit"><i class="icon-edit icon-large"></i> <@t.page 'config_data.edit'/></a></li>
        </@_sysAuthorized>
    </#if>
        <#if site.parentId?has_content>
            <li><button type="button" class="buttonDisabled"><@t.page 'site.parent_maintain'/></button></li>
        <#else>
            <li><button type="submit" class="buttonActive"><@t.page 'button.save'/></button></li>
        </#if>
            <li><button type="button" class="button close"><@t.page 'button.close'/></button></li>
        </ul>
    </div>
    <div class="pageFormContent" layoutH>
        <dl class="nowrap">
            <dt><@t.page 'code'/>:</dt>
            <dd>
                <input name="configCode" type="hidden" value="${code!}"/>
                <#if a?has_content&&!a.customed>
                    <input class="required" readonly="readonly" name="code" type="text" value="${(a.code)!}"/>
                <#else>
                    <input class="required" name="code" type="text" maxlength="20" size="20" value="${(a.code)!}"/>
                </#if>
            </dd>
        </dl>
        <dl class="nowrap">
            <dt><@t.page 'description'/>:</dt>
            <dd>
                <#if a?has_content&&!a.customed>
                    <textarea class="required" readonly="readonly" name="description" maxlength="150" cols="80" rows="3">${(a.description)!}</textarea>
                <#else>
                    <textarea class="required" name="description" maxlength="150" cols="80" rows="3">${(a.description)!}</textarea>
                </#if>
            </dd>
        </dl>
<#if a?has_content>
    <@_sysConfigFieldList code=code customed=true>
        <#assign extendList=list>
    </@_sysConfigFieldList>
</#if>
        <fieldset>
            <legend><@t.page 'extend_field'/>(<@t.page 'metadata.default_value_description'/>)</legend>
            <#include "../include_page/extends.html"/>
            <@extends 'extendList' extendList![]/>
        </fieldset>
    </div>
</form>