@Test public void testGetProjectResult() throws Exception { }
public CommonResult getProjectResult(ProjectParam projectParam){ JSONObject returnJson = new JSONObject(); Integer collectionId = projectParam.getCollectionId(); Integer projectId = projectParam.getProjectId(); Integer projectType = projectParam.getProjectType(); HashMap result; if(projectType == 1) result = inspectionMapper.getResultByCIdAndPId(collectionId, projectId); else if(projectType == 2) result = examinationMapper.getResultByCIdAndPId(collectionId, projectId); else return CommonResult.fail(ResultCode.E_801); returnJson.put("result", result); return CommonResult.success(returnJson); }
ProjectCollectionManagementServiceImpl implements ProjectCollectionManagementService { public CommonResult getProjectResult(ProjectParam projectParam){ JSONObject returnJson = new JSONObject(); Integer collectionId = projectParam.getCollectionId(); Integer projectId = projectParam.getProjectId(); Integer projectType = projectParam.getProjectType(); HashMap result; if(projectType == 1) result = inspectionMapper.getResultByCIdAndPId(collectionId, projectId); else if(projectType == 2) result = examinationMapper.getResultByCIdAndPId(collectionId, projectId); else return CommonResult.fail(ResultCode.E_801); returnJson.put("result", result); return CommonResult.success(returnJson); } }
ProjectCollectionManagementServiceImpl implements ProjectCollectionManagementService { public CommonResult getProjectResult(ProjectParam projectParam){ JSONObject returnJson = new JSONObject(); Integer collectionId = projectParam.getCollectionId(); Integer projectId = projectParam.getProjectId(); Integer projectType = projectParam.getProjectType(); HashMap result; if(projectType == 1) result = inspectionMapper.getResultByCIdAndPId(collectionId, projectId); else if(projectType == 2) result = examinationMapper.getResultByCIdAndPId(collectionId, projectId); else return CommonResult.fail(ResultCode.E_801); returnJson.put("result", result); return CommonResult.success(returnJson); }  }
ProjectCollectionManagementServiceImpl implements ProjectCollectionManagementService { public CommonResult getProjectResult(ProjectParam projectParam){ JSONObject returnJson = new JSONObject(); Integer collectionId = projectParam.getCollectionId(); Integer projectId = projectParam.getProjectId(); Integer projectType = projectParam.getProjectType(); HashMap result; if(projectType == 1) result = inspectionMapper.getResultByCIdAndPId(collectionId, projectId); else if(projectType == 2) result = examinationMapper.getResultByCIdAndPId(collectionId, projectId); else return CommonResult.fail(ResultCode.E_801); returnJson.put("result", result); return CommonResult.success(returnJson); }  @Override CommonResult listCollections(Integer caseId, Integer type); @Override CommonResult applyNewCollection(Integer collectionType); @Override CommonResult savePresentCollection(CollectionParam collectionParam); @Override CommonResult submitPresentCollection(CollectionParam collectionParam); CommonResult chooseByType(CollectionParam collectionParam, int operation); CommonResult saveInspection(CollectionParam collectionParam, int operation); CommonResult saveExamination(CollectionParam collectionParam, int operation); CommonResult saveTreatment(CollectionParam collectionParam, int operation); int insertInspectionProject(Integer collectionId, Integer projectId, ItemParam itemParam); int insertExaminationProject(Integer collectionId, Integer projectId, ItemParam itemParam); CommonResult insertTransactionLog(CollectionParam collectionParam, ProjectParam projectParam,
                                             ItemParam itemParam, Integer creatorRoleId); CommonResult cancelSubmittedCollection(Integer collectionId, Integer type); CommonResult deleteCollection(Integer collectionId, Integer type); CommonResult getProjectResult(ProjectParam projectParam); }
ProjectCollectionManagementServiceImpl implements ProjectCollectionManagementService { public CommonResult getProjectResult(ProjectParam projectParam){ JSONObject returnJson = new JSONObject(); Integer collectionId = projectParam.getCollectionId(); Integer projectId = projectParam.getProjectId(); Integer projectType = projectParam.getProjectType(); HashMap result; if(projectType == 1) result = inspectionMapper.getResultByCIdAndPId(collectionId, projectId); else if(projectType == 2) result = examinationMapper.getResultByCIdAndPId(collectionId, projectId); else return CommonResult.fail(ResultCode.E_801); returnJson.put("result", result); return CommonResult.success(returnJson); }  @Override CommonResult listCollections(Integer caseId, Integer type); @Override CommonResult applyNewCollection(Integer collectionType); @Override CommonResult savePresentCollection(CollectionParam collectionParam); @Override CommonResult submitPresentCollection(CollectionParam collectionParam); CommonResult chooseByType(CollectionParam collectionParam, int operation); CommonResult saveInspection(CollectionParam collectionParam, int operation); CommonResult saveExamination(CollectionParam collectionParam, int operation); CommonResult saveTreatment(CollectionParam collectionParam, int operation); int insertInspectionProject(Integer collectionId, Integer projectId, ItemParam itemParam); int insertExaminationProject(Integer collectionId, Integer projectId, ItemParam itemParam); CommonResult insertTransactionLog(CollectionParam collectionParam, ProjectParam projectParam,
                                             ItemParam itemParam, Integer creatorRoleId); CommonResult cancelSubmittedCollection(Integer collectionId, Integer type); CommonResult deleteCollection(Integer collectionId, Integer type); CommonResult getProjectResult(ProjectParam projectParam);  }