feat: 新增开放接口,支持通过模板名称和项目名称生成文案

- 新增 HtmlUtils 工具类,支持 HTML 转纯文本
- 新增 selectTtCodeByCodeName 方法,支持按名称查询源码
- 新增 /office/copyTemplate/open/generate 开放接口
  无需登录,参数:templateName(模板名称)、codeName(项目名称)
  返回:填充占位符后的完整文案内容

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
王鹏
2026-04-10 19:28:15 +08:00
parent 6940541216
commit eb6339c9a7
6 changed files with 175 additions and 1 deletions

View File

@@ -43,6 +43,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<include refid="selectTtCodeVo"/>
where code_id = #{codeId}
</select>
<select id="selectTtCodeByCodeName" parameterType="String" resultMap="TtCodeResult">
<include refid="selectTtCodeVo"/>
where code_name = #{codeName} limit 1
</select>
<insert id="insertTtCode" parameterType="TtCode">
insert into tt_code