{extend name="common/base"/} {block name="style"} {/block} {block name="body"}
{notempty name="fields"} {volist name="fields" id="field"} {php}$fname = $field['name'] ?? ''; $fval = $config[$fname] ?? ($field['default'] ?? ''); $ftype = $field['type'] ?? 'text'; $passwordValue = !empty($field['preserve_empty']) ? '' : $fval; $placeholder = $field['placeholder'] ?? ''; $savedValue = $config[$fname] ?? ''; if ($ftype === 'password' && !empty($field['configured_placeholder']) && is_scalar($savedValue) && trim((string)$savedValue) !== '') $placeholder = $field['configured_placeholder']; $dependsOn = $field['depends_on'] ?? []; $dependsField = is_array($dependsOn) ? (string)($dependsOn['field'] ?? '') : ''; $dependsValue = is_array($dependsOn) ? (string)($dependsOn['value'] ?? '') : ''; $dependsField = htmlspecialchars($dependsField, ENT_QUOTES, 'UTF-8'); $dependsValue = htmlspecialchars($dependsValue, ENT_QUOTES, 'UTF-8');{/php} {if $ftype == 'help_area'}

{$field.title|default='帮助说明'}

{$field.rendered|raw}
{else /}
{if $ftype == 'textarea'}
{tips tips="$field.tips|default=''" /}
{elseif $ftype == 'switch' /}
{tips tips="$field.tips|default=''" /}
{elseif $ftype == 'number' /}
{tips tips="$field.tips|default=''" /}
{elseif $ftype == 'radio' /}
{volist name="field.options" id="opt"} {/volist} {tips tips="$field.tips|default=''" /}
{elseif $ftype == 'select' /}
{tips tips="$field.tips|default=''" /}
{elseif $ftype == 'password' /}
{tips tips="$field.tips|default=''" /}
{else /}
{tips tips="$field.tips|default=''" /}
{/if}
{/if}
{/volist} {/notempty} {empty name="fields"}
此插件没有配置项
{/empty}
{/block} {block name="script"} {/block}