{% extends "layout/basic.html" %} {% block content %}

ZIP 替换题目

{% if messages and messages|length %}
{% for m in messages %}{{ m }} {% endfor %}
{% endif %}

此工具保留目标题目的 docId。课程、课程包、训练中已经引用的数字 ID 不需要改;默认也保留原 PID。

支持单题 ZIP,也支持包含多个 problem.yaml 的批量 ZIP。
左边写当前要保留的题目 ID / PID;右边可写 ZIP 内文件夹、ZIP 内 PID 或题目标题。右边不写时,若 ZIP 题目数与行数一致,会按顺序自动匹配。
题解是追加,不删除旧题解。旧提交记录不会清空,已投入使用的题请谨慎替换。
返回题库
{% if rows and rows|length %}

映射预览

{% for row in rows %} {% endfor %}
行 目标 当前题目 ZIP 源题 新题标题 文件 状态 说明
{{ row.lineNo }} {{ row.targetInput }} {% if row.targetDocId %}
docId={{ row.targetDocId }}{% endif %} {% if row.targetPid %}
{{ row.targetPid }}{% endif %}
{{ row.targetTitle|default('-') }} {% if row.sourceFolder %}{{ row.sourceFolder }}{% else %}-{% endif %} {% if row.sourcePid %}
{{ row.sourcePid }}{% endif %}
{{ row.sourceTitle|default('-') }} 数据 {{ row.testdataCount|default(0) }}
附件 {{ row.additionalCount|default(0) }}
题解 {{ row.solutionCount|default(0) }}
{{ row.status }} {{ row.message }}
{% if jobId and canExecute and not executed %}
{% endif %}
{% endif %}

ZIP 内题目

{% if zipProblems and zipProblems|length %}
    {% for item in zipProblems %}
  1. {{ item.folder }}
    {{ item.title|default('(无标题)') }} {% if item.pid %} / {{ item.pid }}{% endif %}
    数据 {{ item.testdataCount }},附件 {{ item.additionalCount }},题解 {{ item.solutionCount }}
  2. {% endfor %}
{% else %}

上传 ZIP 后这里会显示可映射的题目。

{% endif %}

示例

888
889 = problem-B02
B10 => B10-new
900    图上搜索

单题替换时只写 888 即可;批量 ZIP 推荐把当前题 ID 与 ZIP 文件夹一一写清楚。

{% endblock %}