humuyu 3 rokov pred
rodič
commit
8e853feff6

+ 167 - 167
eladmin-system/src/main/java/me/zhengjie/application/admin/controller/AdminOrderController.java

@@ -11,6 +11,7 @@ import me.zhengjie.application.admin.controller.vo.NotaryOrderQueryRsp;
 import me.zhengjie.application.admin.controller.vo.PartyEntity;
 import me.zhengjie.application.admin.service.AdminOrderService;
 import me.zhengjie.application.bank.controller.vo.FileVo;
+import me.zhengjie.application.bank.controller.vo.OrderDetailDto;
 import me.zhengjie.base.AppBaseResponse;
 import me.zhengjie.base.AppResultData;
 import me.zhengjie.base.ResultCode;
@@ -39,171 +40,170 @@ import java.util.List;
 @RequiredArgsConstructor
 public class AdminOrderController {
 
-    private final AdminOrderService adminOrderService;
-
-    /**
-     * 公证订单 查询
-     *
-     * @return
-     */
-    @RequestMapping("/query")
-    public AppBaseResponse<List<NotaryOrderQueryRsp>> query(@RequestBody NotaryOrderQueryReq req) {
-        return adminOrderService.query(req);
-    }
-
-    /**
-     * 查询 客户经理信息
-     *
-     * @return
-     */
-    @RequestMapping("/customerInfo")
-    public AppBaseResponse<NotaryOrderQueryRsp> getCustomerInfo(@RequestBody HashMap<String,String> map) {
-        return adminOrderService.getCustomerInfo(map);
-    }
-
-    /**
-     * 查询订单详情
-     *
-     * @param map
-     * @return
-     */
-    @RequestMapping("/info")
-    public AppBaseResponse<AdminOrderVO> orderInfo(@RequestBody HashMap<String, String> map) {
-        AppBaseResponse response = new AppBaseResponse();
-        String businessNo = map.get("businessNo");
-        String contractNo = map.get("contractNo");
-        response.setData(new AppResultData<AdminOrderVO>(adminOrderService.info(businessNo, contractNo)));
-        return response;
-    }
-
-    
-    /**
-     * 查询订单详情
-     *
-     * @param map
-     * @return
-     */
-    @RequestMapping("/orderDetail")
-    public AppBaseResponse<AdminOrderVO> orderDetail(@RequestBody HashMap<String, String> map) {
-        AppBaseResponse response = new AppBaseResponse();
-        String businessNo = map.get("businessNo");
-        String contractNo = map.get("contractNo");
-        response.setData(new AppResultData<AdminOrderVO>(adminOrderService.info(businessNo, contractNo)));
-        return response;
-    }
-
-    
-    /**
-     * 公证订单 查询 当事人
-     *
-     * @return
-     */
-    @RequestMapping("/partys")
-    public AppBaseResponse<List<PartyEntity>> partys(@RequestBody HashMap<String,String> map) {
-        return adminOrderService.partys(map);
-    }
-
-    /**
-     * 订单问询人列表
-     *
-     * @return
-     */
-    @RequestMapping("/orderQueryUser")
-    public AppBaseResponse<List<PartyEntity>> orderQueryUser(@RequestBody HashMap<String, String> map) {
-        return adminOrderService.orderQueryUser(map);
-    }
-
-    /**
-     * 公证订单 退回
-     *
-     * @return
-     */
-    @RequestMapping("/orderReturn")
-    public AppBaseResponse orderReturn(@RequestBody NotaryOrderQueryReq req) {
-        return adminOrderService.orderReturn(req);
-    }
-
-    /**
-     * 公证订单 驳回
-     *
-     * @return
-     */
-    @AnonymousPostMapping("/orderReject")
-    public AppBaseResponse orderReject(@RequestBody NotaryOrderQueryReq req) {
-        return adminOrderService.orderReject(req);
-    }
-
-    /**
-     * 公证订单  当事人 通过
-     *
-     * @return
-     */
-    @RequestMapping("/partyPass")
-    public AppBaseResponse partyPass(@RequestBody NotaryOrderQueryReq req) {
-        return adminOrderService.partyPass(req);
-    }
-
-    /**
-     * 公证订单信息审核通过
-     * @param req
-     * @return
-     */
-    @AnonymousPostMapping("/checkInfoPass")
-    public AppBaseResponse checkInfoPass(@RequestBody NotaryOrderQueryReq req) {
-        return adminOrderService.checkInfoPass(req);
-    }
-
-
-
-    /**
-     * 公证订单 人体合身验证
-     * @param file
-     * @param idCard
-     * @param name
-     * @return
-     */
-    @ResponseBody
-    @RequestMapping("/auth")
-    public me.zhengjie.base.BaseResponse auth(@RequestParam MultipartFile file, @RequestParam String idCard, @RequestParam String name){
-        me.zhengjie.base.BaseResponse response = new me.zhengjie.base.BaseResponse();
-        byte[] fileByte = null;
-        try {
-            fileByte = file.getBytes();
-        } catch (IOException e) {
-            response.fail(ResultCode.LIVE_VIDEO_CONVERSION.code()+"","图像文件转码失败!");
-            return response;
-        }
-        String imageBase64 = Base64.getEncoder().encodeToString(fileByte);
-        String result = TencentUtil.FaceImageBody(idCard, name, imageBase64);
-        JSONObject object = JSON.parseObject(result);
-        Float sim = Float.parseFloat(object.getString("Sim"));
-        log.info("认证入参:" + idCard + "/" + name);
-        log.info("识别值:" + sim);
-        if (sim > 70) { // 大于70 认为是同一个人
-            response.success("认证成功");
-        } else {
-            response.fail(ResultCode.LIVE_VIDEO_INVALID.code()+"", ResultCode.LIVE_VIDEO_INVALID.message());
-        }
-        return response;
-    }
-    @RequestMapping("/preview")
-    public AppBaseResponse previewNotarization(@RequestBody NotaryOrderQueryReq req){
-        return adminOrderService.previewNotarization(req);
-    }
-
-    @AnonymousPostMapping("/bankCustomer")
-    public AppBaseResponse bankCustomer(@RequestBody NotaryOrderQueryReq req){
-        return adminOrderService.bankCustomer(req);
-    }
-
-    @AnonymousPostMapping("/uploadNotarization")
-    public AppBaseResponse uploadNotarization(@RequestBody FileVo file) {
-        return adminOrderService.uploadNotarization(file);
-    }
-
-    @AnonymousPostMapping("/getDocList")
-    public AppBaseResponse getDocList(@RequestBody NotaryOrderQueryReq req){
-        return adminOrderService.getDocList(req);
-    }
+	private final AdminOrderService adminOrderService;
+
+	/**
+	 * 公证订单 查询
+	 *
+	 * @return
+	 */
+	@RequestMapping("/query")
+	public AppBaseResponse<List<NotaryOrderQueryRsp>> query(@RequestBody NotaryOrderQueryReq req) {
+		return adminOrderService.query(req);
+	}
+
+	/**
+	 * 查询 客户经理信息
+	 *
+	 * @return
+	 */
+	@RequestMapping("/customerInfo")
+	public AppBaseResponse<NotaryOrderQueryRsp> getCustomerInfo(@RequestBody HashMap<String, String> map) {
+		return adminOrderService.getCustomerInfo(map);
+	}
+
+	/**
+	 * 查询订单详情
+	 *
+	 * @param map
+	 * @return
+	 */
+	@RequestMapping("/info")
+	public AppBaseResponse<AdminOrderVO> orderInfo(@RequestBody HashMap<String, String> map) {
+		AppBaseResponse response = new AppBaseResponse();
+		String businessNo = map.get("businessNo");
+		String contractNo = map.get("contractNo");
+		response.setData(new AppResultData<AdminOrderVO>(adminOrderService.info(businessNo, contractNo)));
+		return response;
+	}
+
+	/**
+	 * 查询订单详情
+	 *
+	 * @param map
+	 * @return
+	 */
+	@RequestMapping("/orderDetail")
+	public AppBaseResponse<OrderDetailDto> orderDetail(@RequestBody HashMap<String, String> map) {
+		AppBaseResponse<OrderDetailDto> response = new AppBaseResponse<>();
+		String businessNo = map.get("businessNo");
+		OrderDetailDto orderDetail = adminOrderService.getOrderDetail(businessNo);
+		response.setResult(orderDetail);
+		return response;
+	}
+
+	/**
+	 * 公证订单 查询 当事人
+	 *
+	 * @return
+	 */
+	@RequestMapping("/partys")
+	public AppBaseResponse<List<PartyEntity>> partys(@RequestBody HashMap<String, String> map) {
+		return adminOrderService.partys(map);
+	}
+
+	/**
+	 * 订单问询人列表
+	 *
+	 * @return
+	 */
+	@RequestMapping("/orderQueryUser")
+	public AppBaseResponse<List<PartyEntity>> orderQueryUser(@RequestBody HashMap<String, String> map) {
+		return adminOrderService.orderQueryUser(map);
+	}
+
+	/**
+	 * 公证订单 退回
+	 *
+	 * @return
+	 */
+	@RequestMapping("/orderReturn")
+	public AppBaseResponse orderReturn(@RequestBody NotaryOrderQueryReq req) {
+		return adminOrderService.orderReturn(req);
+	}
+
+	/**
+	 * 公证订单 驳回
+	 *
+	 * @return
+	 */
+	@AnonymousPostMapping("/orderReject")
+	public AppBaseResponse orderReject(@RequestBody NotaryOrderQueryReq req) {
+		return adminOrderService.orderReject(req);
+	}
+
+	/**
+	 * 公证订单 当事人 通过
+	 *
+	 * @return
+	 */
+	@RequestMapping("/partyPass")
+	public AppBaseResponse partyPass(@RequestBody NotaryOrderQueryReq req) {
+		return adminOrderService.partyPass(req);
+	}
+
+	/**
+	 * 公证订单信息审核通过
+	 * 
+	 * @param req
+	 * @return
+	 */
+	@AnonymousPostMapping("/checkInfoPass")
+	public AppBaseResponse checkInfoPass(@RequestBody NotaryOrderQueryReq req) {
+		return adminOrderService.checkInfoPass(req);
+	}
+
+	/**
+	 * 公证订单 人体合身验证
+	 * 
+	 * @param file
+	 * @param idCard
+	 * @param name
+	 * @return
+	 */
+	@ResponseBody
+	@RequestMapping("/auth")
+	public me.zhengjie.base.BaseResponse auth(@RequestParam MultipartFile file, @RequestParam String idCard,
+			@RequestParam String name) {
+		me.zhengjie.base.BaseResponse response = new me.zhengjie.base.BaseResponse();
+		byte[] fileByte = null;
+		try {
+			fileByte = file.getBytes();
+		} catch (IOException e) {
+			response.fail(ResultCode.LIVE_VIDEO_CONVERSION.code() + "", "图像文件转码失败!");
+			return response;
+		}
+		String imageBase64 = Base64.getEncoder().encodeToString(fileByte);
+		String result = TencentUtil.FaceImageBody(idCard, name, imageBase64);
+		JSONObject object = JSON.parseObject(result);
+		Float sim = Float.parseFloat(object.getString("Sim"));
+		log.info("认证入参:" + idCard + "/" + name);
+		log.info("识别值:" + sim);
+		if (sim > 70) { // 大于70 认为是同一个人
+			response.success("认证成功");
+		} else {
+			response.fail(ResultCode.LIVE_VIDEO_INVALID.code() + "", ResultCode.LIVE_VIDEO_INVALID.message());
+		}
+		return response;
+	}
+
+	@RequestMapping("/preview")
+	public AppBaseResponse previewNotarization(@RequestBody NotaryOrderQueryReq req) {
+		return adminOrderService.previewNotarization(req);
+	}
+
+	@AnonymousPostMapping("/bankCustomer")
+	public AppBaseResponse bankCustomer(@RequestBody NotaryOrderQueryReq req) {
+		return adminOrderService.bankCustomer(req);
+	}
+
+	@AnonymousPostMapping("/uploadNotarization")
+	public AppBaseResponse uploadNotarization(@RequestBody FileVo file) {
+		return adminOrderService.uploadNotarization(file);
+	}
+
+	@AnonymousPostMapping("/getDocList")
+	public AppBaseResponse getDocList(@RequestBody NotaryOrderQueryReq req) {
+		return adminOrderService.getDocList(req);
+	}
 }
-

+ 6 - 6
eladmin-system/src/main/java/me/zhengjie/application/admin/service/impl/AdminOrderServiceImpl.java

@@ -338,9 +338,9 @@ public class AdminOrderServiceImpl implements AdminOrderService {
 			return response;
 		}
 		// 检查面谈笔录是否提交
-
-		OrderFileEntity orderFile = orderFileRepository.getOrderFileWithCode(contractOrderEntity.getProdId(),
-				contractOrderEntity.getBusinessNo(), OrderFileConstant.TYPE_CODE_NOTE);
+		OrderFileEntity orderFile = null;
+//		OrderFileEntity orderFile = orderFileRepository.getOrderFileWithCode(contractOrderEntity.getProdId(),
+//				contractOrderEntity.getBusinessNo(), OrderFileConstant.TYPE_CODE_NOTE);
 
 		if (orderFile == null) {
 			response.fail(ResultCode.INTERVIEW_NOTE_UNSUBMIT);
@@ -680,7 +680,7 @@ public class AdminOrderServiceImpl implements AdminOrderService {
 		FileInfoEntity fileInfoEntity = fileInfoService.getById(file.getImageId());
 		OrderFileEntity notaryOrderFile = new OrderFileEntity();
 		notaryOrderFile.setBusinessNo(file.getBusinessNo());
-		notaryOrderFile.setContractId(file.getContractId());
+//		notaryOrderFile.setContractId(file.getContractId());
 		notaryOrderFile.setCode(code);
 		notaryOrderFile.setSignedPdfUrl(fileInfoEntity.getPath());
 		notaryOrderFile.setCreateTime(new Date());
@@ -711,8 +711,8 @@ public class AdminOrderServiceImpl implements AdminOrderService {
 			}
 		};
 
-
-		List<OrderFileEntity> orderFileList = orderFileRepository.getOrderFileListWithCodes(req.getBusinessNo(),"1,2,3,4,5,6".split(","));
+		List<OrderFileEntity> orderFileList = orderFileRepository.getOrderFileListWithCodes(req.getBusinessNo(),
+				"1,2,3,4,5,6".split(","));
 
 		List<Map<String, String>> fileList = new ArrayList<>();
 		for (OrderFileEntity orderFile : orderFileList) {