Skip to content

GET /dm-store/productLine/detail/:id

触发按钮:getDetail

入参

传递对象:Long

字段类型必填多选校验规则说明
idLong-路径中的业务 id

出参

传递对象:ResultData<PartMainVo><单个 PartMainVo 对象>

json
{
  "id": "",
  "partNo": "",
  "partCode": "",
  "partName": "",
  "spec": "",
  "...": "..."
}

前端校验规则

权限校验
├── 编辑按钮权限
│   └── code: 'information:productLine:edit:popup'
├── 表单校验
│   ├── productLineCode
│   │   └── required: true, trigger: blur
│   └── productLineName
│       └── required: true, trigger: blur
└── 提交拦截校验
    └── approvalAction
        └── this.$refs.form.validate 未通过时拦截提交

后端逻辑

业务流程:按ID查询产品线 -> 形成详情结果 -> 返回产品线详情

└── 查询产品线详情
    ├── 查询产品线记录:getById :227
    │   └── 条件
    │       └── id
    └── 输出产品线详情

后端校验规则

数据存在性校验
└── 校验产品线是否存在:findProductLineById :227-230
    └── 不存在则抛出 ExceptionCode.EX100007

涉及数据库表

库名.表名mapper.statement描述
store.product_lineProductLineMapper.selectById按 id 查询productLine详情