新增阿里云对接方法
This commit is contained in:
@@ -1,13 +1,17 @@
|
||||
package com.cool.store.controller;
|
||||
|
||||
import com.cool.store.enums.ErrorCodeEnum;
|
||||
import com.cool.store.exception.ServiceException;
|
||||
import com.cool.store.request.BaseUserInfoRequest;
|
||||
import com.cool.store.request.PartnerBaseInfoRequest;
|
||||
import com.cool.store.request.PartnerClerkInfoRequest;
|
||||
import com.cool.store.request.PartnerIntentInfoRequest;
|
||||
import com.cool.store.response.ResponseResult;
|
||||
import com.cool.store.service.AliyunService;
|
||||
import com.cool.store.service.HyPartnerIntentInfoService;
|
||||
import com.cool.store.service.PartnerUserInfoService;
|
||||
import com.cool.store.vo.*;
|
||||
import com.cool.store.vo.cuser.IdentityCardInfoVO;
|
||||
import com.github.pagehelper.PageInfo;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
@@ -34,7 +38,10 @@ public class PartnerController {
|
||||
private PartnerUserInfoService partnerUserInfoService;
|
||||
|
||||
@Resource
|
||||
HyPartnerIntentInfoService hyPartnerIntentInfoService;
|
||||
private HyPartnerIntentInfoService hyPartnerIntentInfoService;
|
||||
|
||||
@Resource
|
||||
private AliyunService aliyunService;
|
||||
|
||||
@PostMapping(path = "/applyBaseInfo")
|
||||
@ApiOperation("提交基本信息")
|
||||
@@ -195,4 +202,16 @@ public class PartnerController {
|
||||
return ResponseResult.success();
|
||||
}
|
||||
|
||||
|
||||
@GetMapping(path = "/getIdentityCardInfo")
|
||||
@ApiOperation("根据身份证正面解析获取数据")
|
||||
public ResponseResult<IdentityCardInfoVO> getIdentityCardInfo(@RequestParam(value = "faceImageUrl")String faceImageUrl){
|
||||
try {
|
||||
IdentityCardInfoVO identityCardInfo = aliyunService.getIdentityCardInfo(faceImageUrl);
|
||||
return ResponseResult.success(identityCardInfo);
|
||||
} catch (Exception e) {
|
||||
throw new ServiceException(ErrorCodeEnum.IDENTITY_CARD_PARSE_FAIL);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user