上一批只落了实体与 oapi 出参,管理端 save 入参与编辑回显没接上, 导致 front 录入的 6 个字段被 Jackson 静默丢弃。 - SvcModels.SvcItemSaveRequest 补 7 字段(含 @Size 校验,与实体列长一致) - SvcModels.SvcItemEditVo 补 7 字段 + of() 映射 - ServiceItemService.adminSave 补 7 行赋值(空串归一 null) - 新增 SvcItemPromiseFieldsTest:反序列化字段名对齐 + EditVo 映射(3 例) - .gitignore 排除 local-debug/(本地探针,不入库)
This commit is contained in:
@@ -199,6 +199,14 @@ public class ServiceItemService {
|
||||
item.setFormCode(emptyToNull(req.getFormCode()));
|
||||
item.setFlowGuid(emptyToNull(req.getFlowGuid()));
|
||||
item.setApplyUrl(applyUrl);
|
||||
// 服务承诺(P1-1):空串归一为 null,避免库里出现 "" 与 null 两种空值
|
||||
item.setCoopDepts(emptyToNull(req.getCoopDepts()));
|
||||
item.setHandlerName(emptyToNull(req.getHandlerName()));
|
||||
item.setHandleTimeDesc(emptyToNull(req.getHandleTimeDesc()));
|
||||
item.setRunCount(req.getRunCount());
|
||||
item.setExpressFlag(req.getExpressFlag());
|
||||
item.setFeeDesc(emptyToNull(req.getFeeDesc()));
|
||||
item.setFeeBasis(emptyToNull(req.getFeeBasis()));
|
||||
item.setSortNo(req.getSortNo() == null ? 0 : req.getSortNo());
|
||||
item = itemRepository.save(item);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user