{% extends "admin_layout.html" %} {% block active_nav %}templates{% endblock %} {% block title %}编辑模板 · 管理后台{% endblock %} {% block content %}

📄 编辑模板

{% if templates_readonly %}

🔒 线上模板只读:本模板不可修改/还原。请在本地源码版直接编辑内置模板 app/{{ module }}/templates/{{ name }},git push 发布后自动生效。

{{ content }}
返回列表 {% else %}

模板路径:{{ module }}/{{ name }} · {% if source == 'override' %}当前为管理员自定义(覆盖中) {% else %}当前为内置/代码默认{% endif %}
{% if format_placeholders %} 本模板运行时占位符(保留不要删,删掉保存会被拒绝):{% for p in format_placeholders %}{{ '{' }}{{ p }}{{ '}' }}{% if not loop.last %}、{% endif %}{% endfor %}
⚠️ 正文里的 JSON/CSS 示例若出现单个 { 或 },必须写成 {{ '{' }}{{ '{' }} / {{ '}' }}{{ '}' }},否则保存会被拒绝。 {% else %} 占位符 {{ '{{key}}' }} 会在运行时被替换;不要删掉不认识的占位符,否则对应内容会丢失。 {% endif %}

返回列表
{% if source == 'override' %}
{% endif %} {% endif %}
{% endblock %}