| | |
| | | |
| | | @Override |
| | | public GetThingListMaterialRelationVO getThingListMaterialRelation(IdParam idParam) { |
| | | GetThingListMaterialRelationVO getThingListMaterialRelationVO = GenericConverter.convert( |
| | | getOne(Condition.getQueryWrapper(GenericConverter.convert(idParam, GdImplementListEntity.class))), GetThingListMaterialRelationVO.class); |
| | | GetThingListMaterialRelationVO getThingListMaterialRelationVO = new GetThingListMaterialRelationVO(); |
| | | |
| | | // 查询实施清单详情 |
| | | GdImplementListEntity gdImplement = getOne(Condition.getQueryWrapper(GenericConverter.convert(idParam, GdImplementListEntity.class))); |
| | | getThingListMaterialRelationVO.setImplementListId(gdImplement.getId()); |
| | | getThingListMaterialRelationVO.setProcessDefinitionId(gdImplement.getProcessDefinitionId()); |
| | | getThingListMaterialRelationVO.setProcessInstanceId(gdImplement.getProcessInstanceId()); |
| | | |
| | | List<GdThingListMaterialRelEntity> gdThingListMaterialRelEntityList = gdThingListMaterialRelService.list( |
| | | Wrappers.<GdThingListMaterialRelEntity>query() |
| | |
| | | if (null != param.getImplementListId()) { |
| | | |
| | | // 关联关系先删除,在新增 |
| | | boolean implementListId = gdThingListMaterialRelService.remove( |
| | | gdThingListMaterialRelService.remove( |
| | | new QueryWrapper<GdThingListMaterialRelEntity>() |
| | | .eq("implement_list_id", param.getImplementListId())); |
| | | |
| | | // 删除失败,返回false |
| | | if (!implementListId) { |
| | | return false; |
| | | } |
| | | |
| | | List<GdThingListMaterialRelEntity> gdThingListMaterialRelEntityList = getGdThingListMaterialRelEntities(param); |
| | | |