You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
72 lines
1.9 KiB
72 lines
1.9 KiB
//认证api
|
|
|
|
import request from '@/utils/request'
|
|
|
|
// api地址
|
|
const api = {
|
|
// 扫描证书上传接口
|
|
listLibrary: 'Paymentlist/entuiprise/listLibrary',
|
|
// 扫描证书上传接口
|
|
cerscan_url: 'Paymentlist/entuiprise/v1/user/cer-scan',
|
|
// 行业类目
|
|
industry:"slb/userself/v1/industry/0",
|
|
// 获取身份,认证费用
|
|
identity : "Paymentlist/CertificationFeeSetting/selectCertificationFees",
|
|
// 推荐中介服务机构
|
|
certiaudit : "Paymentlist/certiaudit/certificationIntermediaryLists",
|
|
// 保存协议
|
|
save_user: "Paymentlist/entuiprise/saveUserAgreement",
|
|
// 认证接口
|
|
verify_url: "Paymentlist/entuiprise/mannAgeDate"
|
|
}
|
|
|
|
/**
|
|
* 扫描证书上传
|
|
*/
|
|
export const cerscan = (data) => {
|
|
return request.post(api.cerscan_url, data )
|
|
}
|
|
|
|
// 行业列表
|
|
export function getIndustry(param, option) {
|
|
return request.get(api.industry, param, option)
|
|
}
|
|
|
|
export function getIdentity(param, option) {
|
|
return request.get(api.identity, param, option)
|
|
}
|
|
|
|
export function getCertiaudit(param, option) {
|
|
return request.get(api.certiaudit, param, option)
|
|
}
|
|
|
|
// do upload
|
|
export const upload = files => {
|
|
// 文件上传大小, 2M
|
|
const maxSize = 1024 * 1024 * 2
|
|
// 执行上传
|
|
return new Promise((resolve, reject) => {
|
|
request.urlFileUpload({ files, maxSize })
|
|
.then(result => resolve(result.map(item => item.data.fileInfo.file_id), result))
|
|
.catch(reject)
|
|
})
|
|
}
|
|
|
|
export function getUploadUrl() {
|
|
return api.cerscan_url
|
|
}
|
|
|
|
// 验证提交
|
|
export function verifySubmit(data){
|
|
let option={}
|
|
return request.post(api.verify_url,data,option)
|
|
}
|
|
// 保存协议
|
|
export function preservation(agreement) {
|
|
return request.get(api.save_user, {userId: agreement.userId, agreementIds: agreement.agreementIds})
|
|
}
|
|
// 获取用户认证信息
|
|
export function listLibrary(agreementId){
|
|
return request.post(api.listLibrary + '?AuId=' + agreementId,{})
|
|
}
|
|
|
|
|