Merge remote-tracking branch 'origin/dev_xd' into dev_xd
commit
dedd2dc535
|
@ -201,17 +201,19 @@ public class WxController extends BaseController {
|
|||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* ocr信息识别
|
||||
* @param url
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/cardOCR/front")
|
||||
public AjaxResult getFront(String url) {
|
||||
url = "https://xiangguan.sxyanzhu.com"+url;
|
||||
return AjaxResult.success(OcrService.getFront(url));
|
||||
}
|
||||
|
||||
@GetMapping("/cardOCR/back")
|
||||
public AjaxResult getBack(String url) {
|
||||
url = "https://xiangguan.sxyanzhu.com"+url;
|
||||
return AjaxResult.success(OcrService.getBack(url));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -17,6 +17,7 @@ import com.yanzhu.manage.service.IProProjectInfoSubdeptsUsersService;
|
|||
import com.yanzhu.manage.service.IUniService;
|
||||
import com.yanzhu.manage.utils.WxQrCodeUtils;
|
||||
import com.yanzhu.manage.utils.pdf.FileUtil;
|
||||
import com.yanzhu.manage.utils.pdf.PdfImageSignetUtil;
|
||||
import com.yanzhu.manage.utils.pdf.PoiUtil;
|
||||
import com.yanzhu.security.utils.DictUtils;
|
||||
import com.yanzhu.system.api.RemoteFlowService;
|
||||
|
@ -854,6 +855,9 @@ public class ProProjectInfoSubdeptsUsersServiceImpl implements IProProjectInfoSu
|
|||
@Override
|
||||
public void approveSubDeptsUserGroSign(Long id){
|
||||
ProProjectInfoSubdeptsUsers proProjectInfoSubdeptsUsers = proProjectInfoSubdeptsUsersMapper.selectProProjectInfoSubdeptsUsersById(id);
|
||||
ProProjectInfoSubdeptsUsers myProUser = proProjectInfoSubdeptsUsersMapper.selectProProjectInfoSubdeptsUsersByParamId(proProjectInfoSubdeptsUsers.getProjectId(),SecurityUtils.getUserId());
|
||||
String filePath = proProjectInfoSubdeptsUsers.getEduFilePath().replace(ProfileConfig.profile, ProfileConfig.profilePath);
|
||||
PdfImageSignetUtil.imageWaterMark(filePath, filePath, myProUser.gets().replace(Constants.RESOURCE_PREFIX, AppConfig.getProfile()),SignetTypeEnum.USER.getCode());
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -50,6 +50,22 @@ export function findMyTask(data) {
|
|||
})
|
||||
}
|
||||
|
||||
// 获取身份证正面信息
|
||||
export function findCardOcrFront(url){
|
||||
return request({
|
||||
url: '/wxApi/cardOCR/front?url='+url,
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
|
||||
// 获取身份证反面信息
|
||||
export function findCardOcrBack(url){
|
||||
return request({
|
||||
url: '/wxApi/cardOCR/back?url='+url,
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
|
||||
// 查询用户部门信息
|
||||
export function findMyDeptList(){
|
||||
return request({
|
||||
|
|
|
@ -27,7 +27,9 @@ import {
|
|||
submitUserSignets
|
||||
} from '../../api/busEdu'
|
||||
import {
|
||||
findDictCache
|
||||
findDictCache,
|
||||
findCardOcrBack,
|
||||
findCardOcrFront,
|
||||
} from '../../api/publics'
|
||||
import {
|
||||
securityFileUpload,
|
||||
|
@ -929,6 +931,23 @@ Page({
|
|||
this.setData({
|
||||
"form.subDeptInfos.legalPersonCardImgPos": file
|
||||
});
|
||||
file.forEach(async (item, idx) => {
|
||||
let obj = await this.syncUploadImage(item);
|
||||
findCardOcrFront(obj.data.data.url).then(res =>{
|
||||
if(res.code==200){
|
||||
this.setData({
|
||||
"form.subDeptInfos.legalPerson": res.data.name,
|
||||
"form.subDeptInfos.legalPersonCard": res.data.cardId
|
||||
})
|
||||
if(!res.data.name || !res.data.cardId){
|
||||
this.setData({
|
||||
"form.subDeptInfos.legalPersonCardImgPos": []
|
||||
});
|
||||
app.toast("身份证正面照识别失败!请重新上传");
|
||||
}
|
||||
}
|
||||
});
|
||||
})
|
||||
},
|
||||
|
||||
/**
|
||||
|
@ -993,6 +1012,23 @@ Page({
|
|||
this.setData({
|
||||
"form.leaderCardImgPos": file
|
||||
});
|
||||
file.forEach(async (item, idx) => {
|
||||
let obj = await this.syncUploadImage(item);
|
||||
findCardOcrFront(obj.data.data.url).then(res =>{
|
||||
if(res.code==200){
|
||||
this.setData({
|
||||
"form.subDeptLeaderName": res.data.name,
|
||||
"form.subDeptLeaderCode": res.data.cardId
|
||||
})
|
||||
if(!res.data.name || !res.data.cardId){
|
||||
this.setData({
|
||||
"form.leaderCardImgPos": []
|
||||
});
|
||||
app.toast("身份证正面照识别失败!请重新上传");
|
||||
}
|
||||
}
|
||||
});
|
||||
})
|
||||
},
|
||||
|
||||
/**
|
||||
|
@ -1119,6 +1155,26 @@ Page({
|
|||
this.setData({
|
||||
"form.cardImgPos": file
|
||||
});
|
||||
console.log("filefilefilefile",file)
|
||||
file.forEach(async (item, idx) => {
|
||||
let obj = await this.syncUploadImage(item);
|
||||
findCardOcrFront(obj.data.data.url).then(res =>{
|
||||
if(res.code==200){
|
||||
this.setData({
|
||||
"form.userName": res.data.name,
|
||||
"form.cardCode": res.data.cardId,
|
||||
"form.nativePlace": res.data.native,
|
||||
"form.address": res.data.address
|
||||
})
|
||||
if(!res.data.name || !res.data.cardId){
|
||||
this.setData({
|
||||
"form.cardImgPos": []
|
||||
});
|
||||
app.toast("身份证正面照识别失败!请重新上传");
|
||||
}
|
||||
}
|
||||
});
|
||||
})
|
||||
},
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue