|
@@ -4,6 +4,7 @@ import com.github.pagehelper.Page;
|
|
|
import com.jpsoft.picc.modules.auth.dto.AcceptInsuranceDTO;
|
|
|
import com.jpsoft.picc.modules.auth.dto.InsuranceApplicationDTO;
|
|
|
import com.jpsoft.picc.modules.auth.dto.InsuranceJobsDTO;
|
|
|
+import com.jpsoft.picc.modules.auth.dto.InsurancePolicyRecordDTO;
|
|
|
import com.jpsoft.picc.modules.base.entity.*;
|
|
|
import com.jpsoft.picc.modules.base.service.*;
|
|
|
import com.jpsoft.picc.modules.business.entity.*;
|
|
@@ -107,8 +108,8 @@ public class InsurancePolicyController {
|
|
|
@ApiImplicitParams({
|
|
|
@ApiImplicitParam(name = "policyId",value = "每月投保单ID", required = true, paramType = "form",dataType = "String")
|
|
|
})
|
|
|
- public MessageResult<InsurancePolicyRecord> backReason(@RequestParam(value="policyId",defaultValue="") String policyId){
|
|
|
- MessageResult<InsurancePolicyRecord> msgResult = new MessageResult<>();
|
|
|
+ public MessageResult<InsurancePolicyRecordDTO> backReason(@RequestParam(value="policyId",defaultValue="") String policyId){
|
|
|
+ MessageResult<InsurancePolicyRecordDTO> msgResult = new MessageResult<>();
|
|
|
|
|
|
Map<String,Object> searchParams = new HashMap<>();
|
|
|
searchParams.put("policyId",policyId);
|
|
@@ -118,8 +119,13 @@ public class InsurancePolicyController {
|
|
|
|
|
|
Page<InsurancePolicyRecord> page = insurancePolicyRecordService.pageSearch(searchParams,1,100,sortList);
|
|
|
if(page.size() > 0){
|
|
|
+ InsurancePolicyRecordDTO insurancePolicyRecordDTO = new InsurancePolicyRecordDTO();
|
|
|
+ PojoUtils.map(page.getResult().get(0), insurancePolicyRecordDTO);
|
|
|
+ Company company = companyService.get(insurancePolicyRecordDTO.getCreateBy());
|
|
|
+ insurancePolicyRecordDTO.setCreateByName(company.getName());
|
|
|
+
|
|
|
msgResult.setResult(true);
|
|
|
- msgResult.setData(page.getResult().get(0));
|
|
|
+ msgResult.setData(insurancePolicyRecordDTO);
|
|
|
}else {
|
|
|
msgResult.setResult(false);
|
|
|
msgResult.setMessage("没有相关退回理由。");
|