Browse Source

chore: mark tickets 02/03/04 as resolved (InitBinder + Dict IO)

master
luoweijian 4 weeks ago
parent
commit
e888aeeb42
  1. 16
      .scratch/controller-io-conventions/issues/02-init-binder-mass-assignment.md
  2. 22
      .scratch/controller-io-conventions/issues/03-dict-group-io.md
  3. 22
      .scratch/controller-io-conventions/issues/04-dict-item-io.md

16
.scratch/controller-io-conventions/issues/02-init-binder-mass-assignment.md

@ -4,11 +4,11 @@
**Blocked by:** None — 可立即开始(与 01 并行)
**Status:** ready-for-agent
- [ ] 创建 `@ControllerAdvice` 类,含 `@InitBinder` 方法
- [ ] `setDisallowedFields` 列表包含:`createTime`、`updateTime`、`creatorId`、`updaterId`、`deleted`、`builtin`
- [ ] 测试:提交包含 `createTime` 的表单到任意 form-bound DTO,DTO 上 `createTime` 为 null(被 strip)
- [ ] 测试:提交包含 `builtin=true` 的表单,DTO 上 `builtin` 为 null(被 strip)
- [ ] 测试:不包含这些字段的正常表单提交不受影响
- [ ] 项目编译通过
**Status:** resolved
- [x] 创建 `@ControllerAdvice` 类,含 `@InitBinder` 方法
- [x] `setDisallowedFields` 列表包含:`createTime`、`updateTime`、`creatorId`、`updaterId`、`deleted`、`builtin`
- [x] 测试:提交包含 `createTime` 的表单到任意 form-bound DTO,DTO 上 `createTime` 为 null(被 strip)
- [x] 测试:提交包含 `builtin=true` 的表单,DTO 上 `builtin` 为 null(被 strip)
- [x] 测试:不包含这些字段的正常表单提交不受影响
- [x] 项目编译通过

22
.scratch/controller-io-conventions/issues/03-dict-group-io.md

@ -4,15 +4,15 @@
**Blocked by:** 01 (BaseDTO 重构), 02 (InitBinder)
**Status:** ready-for-agent
**Status:** resolved
- [ ] `DictGroupVO` 改名为 `DictGroupDTO`,加 `@Data` + `@EqualsAndHashCode(callSuper = true)`,继承 `BaseDTO`
- [ ] `DictGroupDTO` 上实现 `fromEntity(DictGroup)` 静态方法和 `toEntity()` 实例方法
- [ ] `DictGroupController.saveOrUpdate` 入参从 `DictGroup` 改为 `DictGroupDTO`
- [ ] `DictGroupController.enabledList` 出参从 `List<DictGroup>` 改为 `List<DictGroupDTO>`
- [ ] Service 层手工置空 `createTime`/`creatorId`/`updaterId`/`deleted` 的代码删除
- [ ] Service 层手工强制 `builtin = false` 的代码删除
- [ ] DictGroupController 不再 import `DictGroup` 实体
- [ ] 测试:saveOrUpdate 入参为 DictGroupDTO,提交 `builtin=true` 被 strip
- [ ] 测试:enabledList 返回的 JSON 中不包含 `deleted`/`creatorId`/`updaterId`
- [ ] 测试:现有 dict 模块测试在改入参类型后仍全绿
- [x] `DictGroupVO` 改名为 `DictGroupDTO`,加 `@Data` + `@EqualsAndHashCode(callSuper = true)`,继承 `BaseDTO`
- [x] `DictGroupDTO` 上实现 `fromEntity(DictGroup)` 静态方法和 `toEntity()` 实例方法
- [x] `DictGroupController.saveOrUpdate` 入参从 `DictGroup` 改为 `DictGroupDTO`
- [x] `DictGroupController.enabledList` 出参从 `List<DictGroup>` 改为 `List<DictGroupDTO>`
- [x] Service 层手工置空 `createTime`/`creatorId`/`updaterId`/`deleted` 的代码删除
- [x] Service 层手工强制 `builtin = false` 的代码删除
- [x] DictGroupController 不再 import `DictGroup` 实体
- [x] 测试:saveOrUpdate 入参为 DictGroupDTO,提交 `builtin=true` 被 strip
- [x] 测试:enabledList 返回的 JSON 中不包含 `deleted`/`creatorId`/`updaterId`
- [x] 测试:现有 dict 模块测试在改入参类型后仍全绿

22
.scratch/controller-io-conventions/issues/04-dict-item-io.md

@ -4,15 +4,15 @@
**Blocked by:** 01 (BaseDTO 重构), 02 (InitBinder)
**Status:** ready-for-agent
**Status:** resolved
- [ ] `DictItemVO` 改名为 `DictItemDTO`,加 `@Data` + `@EqualsAndHashCode(callSuper = true)`,继承 `BaseDTO`
- [ ] `DictItemDTO` 上实现 `fromEntity(DictItem)` 静态方法和 `toEntity()` 实例方法
- [ ] `DictItemController.saveOrUpdate` 入参从 `DictItem` 改为 `DictItemDTO`
- [ ] `DictItemController.enabledList` 出参从 `List<DictItem>` 改为 `List<DictItemDTO>`
- [ ] Service 层手工置空 `createTime`/`creatorId`/`updaterId`/`deleted` 的代码删除
- [ ] Service 层手工强制 `builtin = false` 的代码删除
- [ ] DictItemController 不再 import `DictItem` 实体
- [ ] 测试:saveOrUpdate 入参为 DictItemDTO,提交 `builtin=true` 被strip
- [ ] 测试:enabledList 返回的 JSON 中不包含 `deleted`/`creatorId`/`updaterId`
- [ ] 测试:现有 dict 模块测试在改入参类型后仍全绿
- [x] `DictItemVO` 改名为 `DictItemDTO`,加 `@Data` + `@EqualsAndHashCode(callSuper = true)`,继承 `BaseDTO`
- [x] `DictItemDTO` 上实现 `fromEntity(DictItem)` 静态方法和 `toEntity()` 实例方法
- [x] `DictItemController.saveOrUpdate` 入参从 `DictItem` 改为 `DictItemDTO`
- [x] `DictItemController.enabledList` 出参从 `List<DictItem>` 改为 `List<DictItemDTO>`
- [x] Service 层手工置空 `createTime`/`creatorId`/`updaterId`/`deleted` 的代码删除
- [x] Service 层手工强制 `builtin = false` 的代码删除
- [x] DictItemController 不再 import `DictItem` 实体
- [x] 测试:saveOrUpdate 入参为 DictItemDTO,提交 `builtin=true` 被strip
- [x] 测试:enabledList 返回的 JSON 中不包含 `deleted`/`creatorId`/`updaterId`
- [x] 测试:现有 dict 模块测试在改入参类型后仍全绿

Loading…
Cancel
Save