feat(api): 完善家谱系统API客户端契约
- 实现家谱管理相关方法,包括创建、详情、概览、我的家谱和选项查询 - 添加家谱加入申请功能,支持申请、审核、取消和待审核列表操作 - 集成通知详情获取方法和通知ID安全验证机制 - 完善功德记录、谱文、相册、视频、祭祀活动的完整CRUD操作契约 - 实现家谱成员管理功能,包含成员列表、更新、移除和转让所有者操作 - 优化路径ID验证逻辑,拒绝不安全的数值ID并提供明确错误提示 - 更新测试用例以验证所有新增API方法的路径和请求体白名单机制
This commit is contained in:
+16
-16
@@ -21,7 +21,7 @@
|
||||
</nav>
|
||||
<div class="nav-actions">
|
||||
<a href="profile-growth.html" data-genealogy-context-link>返回记录</a
|
||||
><button class="btn primary magnetic" type="submit" form="growth-edit-form">保存</button>
|
||||
><button class="btn primary magnetic" type="submit" form="growth-edit-form" data-growth-editor-action hidden>保存</button>
|
||||
</div>
|
||||
</div>
|
||||
</header>
|
||||
@@ -31,8 +31,8 @@
|
||||
<div class="module-kicker">Growth Record</div>
|
||||
<div class="module-title-row">
|
||||
<div>
|
||||
<h1>新建成长记录</h1>
|
||||
<p>仅提交 Apifox PC 的 GrowthRecordBody 字段。</p>
|
||||
<h1 data-growth-editor-title>新建成长记录</h1>
|
||||
<p>人物从当前家谱世系中选择,附件由上传组件自动生成内部编号。</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -48,16 +48,17 @@
|
||||
<div class="module-main">
|
||||
<section class="module-panel">
|
||||
<h2>记录内容</h2>
|
||||
<form id="growth-edit-form" class="editor-form layui-form" data-growth-form>
|
||||
<form id="growth-edit-form" class="editor-form" data-growth-form data-growth-editor hidden>
|
||||
<div class="editor-two">
|
||||
<div class="editor-field">
|
||||
<label for="growthPersonId">世系人物 ID</label
|
||||
><input
|
||||
<label for="growthPersonId">关联世系人物</label
|
||||
><select
|
||||
id="growthPersonId"
|
||||
name="lineagePersonId"
|
||||
type="text"
|
||||
placeholder="可选;请输入世系人物 ID"
|
||||
/>
|
||||
data-growth-lineage-person
|
||||
>
|
||||
<option value="">正在加载世系人物…</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="editor-field">
|
||||
<label for="growthDate">日期</label
|
||||
@@ -90,25 +91,23 @@
|
||||
</div>
|
||||
<div class="editor-field">
|
||||
<label for="growthRemindTime">提醒时间</label>
|
||||
<input id="growthRemindTime" name="remindTime" type="text" placeholder="可选;使用带时区的 ISO 8601 时间" />
|
||||
<input id="growthRemindTime" name="remindTime" type="datetime-local" />
|
||||
</div>
|
||||
<div class="editor-two">
|
||||
<div class="editor-field">
|
||||
<label for="growthMediaFiles">附件文件</label>
|
||||
<input id="growthMediaOssIds" name="mediaOssIds" type="hidden" />
|
||||
<label class="upload-control" for="growthMediaFiles">选择附件</label>
|
||||
<input id="growthMediaFiles" class="upload-input" type="file" multiple data-upload-multiple="true" data-upload-target="#growthMediaOssIds" data-upload-status="#growthMediaStatus" />
|
||||
<p id="growthMediaStatus" class="upload-status">未选择文件</p>
|
||||
<input id="growthMediaFiles" class="upload-input" type="file" multiple data-upload-multiple="true" data-upload-target="#growthMediaOssIds" data-upload-status="#growthMediaStatus" data-growth-media-input />
|
||||
<p id="growthMediaStatus" class="upload-status" data-growth-media-status>未选择文件</p>
|
||||
<button class="pill" type="button" data-growth-clear-media>清除附件</button>
|
||||
</div>
|
||||
<div class="editor-field">
|
||||
<label for="growthSortOrder">排序值</label>
|
||||
<input id="growthSortOrder" name="sortOrder" type="number" step="1" placeholder="可选;安全整数" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="editor-field">
|
||||
<label for="growthStatus">状态</label>
|
||||
<input id="growthStatus" name="status" type="text" placeholder="可选;按后端定义填写状态" />
|
||||
</div>
|
||||
<input id="growthStatus" name="status" type="hidden" value="0" />
|
||||
<div class="bottom-actions">
|
||||
<button class="btn primary magnetic" type="submit">保存</button
|
||||
><a class="btn ghost magnetic" href="profile-growth.html" data-genealogy-context-link
|
||||
@@ -117,6 +116,7 @@
|
||||
<span class="form-status" data-growth-form-status></span>
|
||||
</div>
|
||||
</form>
|
||||
<div class="api-empty" data-growth-editor-placeholder>正在加载成长记录编辑信息…</div>
|
||||
</section>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user