mirror of
http://112.124.100.131/GFRS/ebiz-h5.git
synced 2025-12-22 00:06:45 +08:00
Merge branch 'feature/增加机构名称简称' into feature/开门红
# Conflicts: # src/assets/js/utils/request.js
This commit is contained in:
@@ -22,9 +22,11 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"axios": "^0.19.0",
|
"axios": "^0.19.0",
|
||||||
"core-js": "^2.6.5",
|
"core-js": "^2.6.5",
|
||||||
|
"crypto-js": "^4.0.0",
|
||||||
"echarts": "^4.2.1",
|
"echarts": "^4.2.1",
|
||||||
"fastclick": "^1.0.6",
|
"fastclick": "^1.0.6",
|
||||||
"js-base64": "^2.5.1",
|
"js-base64": "^2.5.1",
|
||||||
|
"js-md5": "^0.7.3",
|
||||||
"nprogress": "^0.2.0",
|
"nprogress": "^0.2.0",
|
||||||
"pdfh5": "^1.2.13",
|
"pdfh5": "^1.2.13",
|
||||||
"vant": "2.2.0",
|
"vant": "2.2.0",
|
||||||
|
|||||||
@@ -25,6 +25,15 @@ export function saveOrUpdateInfo(data) {
|
|||||||
data
|
data
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function getTokenForUserModel(data) {
|
||||||
|
return request({
|
||||||
|
url: getUrl('/agent/enter/getTokenForAgent', 1),
|
||||||
|
method: 'get',
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
// //查询二次分享数据
|
// //查询二次分享数据
|
||||||
// export function getTokenForUserModel(data) {
|
// export function getTokenForUserModel(data) {
|
||||||
// console.log('查询二次分享', data)
|
// console.log('查询二次分享', data)
|
||||||
|
|||||||
@@ -29,13 +29,13 @@ export function history(data) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// //历史报案详情接口
|
// //历史报案详情接口
|
||||||
// export function historyDetail(data) {
|
export function historyDetail(data) {
|
||||||
// return request({
|
return request({
|
||||||
// url: getUrl(`/claim/claimReport/historyDetail`, 1),
|
url: getUrl(`/claim/claimReport/historyDetail`, 1),
|
||||||
// method: 'post',
|
method: 'get',
|
||||||
// data
|
data
|
||||||
// })
|
})
|
||||||
// }
|
}
|
||||||
|
|
||||||
//理赔申请
|
//理赔申请
|
||||||
export function apply(data) {
|
export function apply(data) {
|
||||||
|
|||||||
@@ -62,3 +62,31 @@ export function wxShare(data) {
|
|||||||
data
|
data
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//验证代理人访问
|
||||||
|
export function checkEnterPower(data) {
|
||||||
|
return request({
|
||||||
|
url: getUrl('/customer/agent/checkEnterPower', 1),
|
||||||
|
method: 'post',
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 获取验证码
|
||||||
|
export function getAuthCode(data) {
|
||||||
|
return request({
|
||||||
|
url: getUrl('/customer/authcode/loginedSend', 1),
|
||||||
|
method: 'post',
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 获取代理人信息
|
||||||
|
export function getCheckModelAgentInfo(data) {
|
||||||
|
return request({
|
||||||
|
// url: getUrl('/agent/agent/info', 0),
|
||||||
|
url: getUrl('/customer/agent/info', 1),
|
||||||
|
method: 'post',
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|||||||
@@ -56,3 +56,31 @@ export function queryPrivacy(data) {
|
|||||||
data
|
data
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//获取隐私政策
|
||||||
|
export function queryPrivacyNot(data) {
|
||||||
|
return request({
|
||||||
|
// url: getUrl('/agent/income/info', 0),
|
||||||
|
url: getUrl('/customer/privacy/queryPrivacy', 1),
|
||||||
|
method: 'post',
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
//注销用户
|
||||||
|
export function logoutAgent(data) {
|
||||||
|
return request({
|
||||||
|
url: getUrl('/customer/account/logoutAgent', 1),
|
||||||
|
method: 'post',
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
//登录用户
|
||||||
|
export function loginTest(data) {
|
||||||
|
return request({
|
||||||
|
url: getUrl('/customer/account/login', 1),
|
||||||
|
method: 'post',
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
@@ -1,4 +1,5 @@
|
|||||||
import utilsAge from '@/assets/js/utils/age'
|
import utilsAge from '@/assets/js/utils/age'
|
||||||
|
import CacheUtils from '@/assets/js/utils/cacheUtils'
|
||||||
/**
|
/**
|
||||||
* @desc 扩展对象继承
|
* @desc 扩展对象继承
|
||||||
* @param {Object} out 一个或多个对象
|
* @param {Object} out 一个或多个对象
|
||||||
@@ -179,7 +180,7 @@ export default {
|
|||||||
* @return {*} rs
|
* @return {*} rs
|
||||||
*/
|
*/
|
||||||
getStorage(name) {
|
getStorage(name) {
|
||||||
return this._string2json(window.localStorage[name])
|
return this._string2json(CacheUtils.getLocItem(name))
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -187,7 +188,7 @@ export default {
|
|||||||
* @param {String} name 名称
|
* @param {String} name 名称
|
||||||
*/
|
*/
|
||||||
setStorage(name, value) {
|
setStorage(name, value) {
|
||||||
window.localStorage[name] = this._json2string(value)
|
CacheUtils.setLocItem(name,this._json2string(value))
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -195,7 +196,7 @@ export default {
|
|||||||
* @param {String} name 名称
|
* @param {String} name 名称
|
||||||
*/
|
*/
|
||||||
delStorage(name) {
|
delStorage(name) {
|
||||||
window.localStorage.removeItem(name)
|
CacheUtils.removeLocItem(name)
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -532,7 +533,8 @@ export default {
|
|||||||
insuredDTO = res.orderDTO.insuredDTOs[0]
|
insuredDTO = res.orderDTO.insuredDTOs[0]
|
||||||
}
|
}
|
||||||
let age = utilsAge.getAge(appntDTO.birthday, new Date())
|
let age = utilsAge.getAge(appntDTO.birthday, new Date())
|
||||||
localStorage.saleInsuredInfo = JSON.stringify({
|
CacheUtils.setLocItem('saleInsuredInfo',
|
||||||
|
JSON.stringify({
|
||||||
workcompany: appntDTO.workcompany,
|
workcompany: appntDTO.workcompany,
|
||||||
birthday: appntDTO.birthday,
|
birthday: appntDTO.birthday,
|
||||||
name: appntDTO.name,
|
name: appntDTO.name,
|
||||||
@@ -551,10 +553,12 @@ export default {
|
|||||||
certiexpiredate: appntDTO.certiexpiredate,
|
certiexpiredate: appntDTO.certiexpiredate,
|
||||||
nativeplace: appntDTO.nativeplace
|
nativeplace: appntDTO.nativeplace
|
||||||
})
|
})
|
||||||
|
)
|
||||||
|
|
||||||
if (insuredDTO) {
|
if (insuredDTO) {
|
||||||
let insuredPersonAge = utilsAge.getAge(insuredDTO.birthday, new Date())
|
let insuredPersonAge = utilsAge.getAge(insuredDTO.birthday, new Date())
|
||||||
localStorage.saleInsuredPersonInfo = JSON.stringify({
|
CacheUtils.setLocItem('saleInsuredPersonInfo',
|
||||||
|
JSON.stringify({
|
||||||
birthday: insuredDTO.birthday,
|
birthday: insuredDTO.birthday,
|
||||||
name: insuredDTO.name,
|
name: insuredDTO.name,
|
||||||
sex: insuredDTO.sex,
|
sex: insuredDTO.sex,
|
||||||
@@ -571,7 +575,7 @@ export default {
|
|||||||
lifeGrade: insuredDTO.lifeGrade,
|
lifeGrade: insuredDTO.lifeGrade,
|
||||||
mobile: insuredDTO.mobile
|
mobile: insuredDTO.mobile
|
||||||
})
|
})
|
||||||
|
)
|
||||||
let [chooseProductCodes, mainRiskCodes, addRiskCodes] = [[], [], []]
|
let [chooseProductCodes, mainRiskCodes, addRiskCodes] = [[], [], []]
|
||||||
if (insuredDTO.riskDTOLst && insuredDTO.riskDTOLst.length > 0) {
|
if (insuredDTO.riskDTOLst && insuredDTO.riskDTOLst.length > 0) {
|
||||||
insuredDTO.riskDTOLst.forEach(item => {
|
insuredDTO.riskDTOLst.forEach(item => {
|
||||||
@@ -583,15 +587,15 @@ export default {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
localStorage.mainRiskCodes = JSON.stringify(mainRiskCodes)
|
CacheUtils.setLocItem('mainRiskCodes',JSON.stringify(mainRiskCodes))
|
||||||
localStorage.oldAddRiskCodes = JSON.stringify(addRiskCodes)
|
CacheUtils.setLocItem('oldAddRiskCodes',JSON.stringify(addRiskCodes))
|
||||||
localStorage.chooseProductCodes = JSON.stringify(chooseProductCodes)
|
CacheUtils.setLocItem('chooseProductCodes',JSON.stringify(chooseProductCodes))
|
||||||
} else {
|
} else {
|
||||||
localStorage.mainRiskCodes = ''
|
CacheUtils.setLocItem('mainRiskCodes','')
|
||||||
localStorage.oldAddRiskCodes = ''
|
CacheUtils.setLocItem('oldAddRiskCodes','')
|
||||||
localStorage.chooseProductCodes = ''
|
CacheUtils.setLocItem('chooseProductCodes','')
|
||||||
if (!isProposal) {
|
if (!isProposal) {
|
||||||
localStorage.saleInsuredPersonInfo = ''
|
CacheUtils.setLocItem('saleInsuredPersonInfo','')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -1,3 +1,4 @@
|
|||||||
|
import CacheUtils from '@/assets/js/utils/cacheUtils'
|
||||||
/**
|
/**
|
||||||
* @desc 扩展对象继承
|
* @desc 扩展对象继承
|
||||||
* @param {Object} out 一个或多个对象
|
* @param {Object} out 一个或多个对象
|
||||||
@@ -117,7 +118,7 @@ export default {
|
|||||||
* @return {*} rs
|
* @return {*} rs
|
||||||
*/
|
*/
|
||||||
getStorage(name) {
|
getStorage(name) {
|
||||||
return this._string2json(window.localStorage[name])
|
return this._string2json(CacheUtils.getLocItem(name))
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -125,7 +126,7 @@ export default {
|
|||||||
* @param {String} name 名称
|
* @param {String} name 名称
|
||||||
*/
|
*/
|
||||||
setStorage(name, value) {
|
setStorage(name, value) {
|
||||||
window.localStorage[name] = this._json2string(value)
|
CacheUtils.setLocItem(name,this._json2string(value))
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -133,7 +134,7 @@ export default {
|
|||||||
* @param {String} name 名称
|
* @param {String} name 名称
|
||||||
*/
|
*/
|
||||||
delStorage(name) {
|
delStorage(name) {
|
||||||
window.localStorage.removeItem(name)
|
CacheUtils.removeLocItem(name)
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
59
src/assets/js/utils/cacheUtils.js
Normal file
59
src/assets/js/utils/cacheUtils.js
Normal file
@@ -0,0 +1,59 @@
|
|||||||
|
import AESTools from '@/assets/js/utils/cryptoJsUtil'
|
||||||
|
import configApp from '@/config'
|
||||||
|
import cacheKeys from './needCacheKey'
|
||||||
|
export default {
|
||||||
|
setLocItem: function(key, value) {
|
||||||
|
const exist = cacheKeys.encodeKeys.find(item => {
|
||||||
|
return item === key
|
||||||
|
})
|
||||||
|
//设置localStorage 值
|
||||||
|
if (cacheKeys.isAll || exist) {
|
||||||
|
window.localStorage.setItem(key, AESTools.AESCacheEncrypt(value, configApp.CACHE_ENCRYP))
|
||||||
|
} else {
|
||||||
|
window.localStorage.setItem(key, value)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
getLocItem: function(key) {
|
||||||
|
// 获取localStorage 中值
|
||||||
|
let value = window.localStorage.getItem(key)
|
||||||
|
if (value && value != '') {
|
||||||
|
const exist = cacheKeys.encodeKeys.find(item => {
|
||||||
|
return item === key
|
||||||
|
})
|
||||||
|
if (cacheKeys.isAll || exist) {
|
||||||
|
return AESTools.AESCacheDecrypt(value, configApp.CACHE_ENCRYP)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
},
|
||||||
|
removeLocItem: function(key) {
|
||||||
|
// 获取localStorage 中值
|
||||||
|
window.localStorage.removeItem(key)
|
||||||
|
},
|
||||||
|
setSessionItem: function(key, value) {
|
||||||
|
//设置sessionStorage 值
|
||||||
|
const exist = cacheKeys.encodeKeys.find(item => {
|
||||||
|
return item === key
|
||||||
|
})
|
||||||
|
//设置localStorage 值
|
||||||
|
if (cacheKeys.isAll || exist) {
|
||||||
|
window.sessionStorage.setItem(key, AESTools.AESCacheEncrypt(value, configApp.CACHE_ENCRYP))
|
||||||
|
} else {
|
||||||
|
window.sessionStorage.setItem(key, value)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
getSessionItem: function(key) {
|
||||||
|
//设置sessionStorage 值
|
||||||
|
let value = window.sessionStorage.getItem(key)
|
||||||
|
if (value && value != '') {
|
||||||
|
const exist = cacheKeys.encodeKeys.find(item => {
|
||||||
|
return item === key
|
||||||
|
})
|
||||||
|
//设置localStorage 值
|
||||||
|
if (cacheKeys.isAll || exist) {
|
||||||
|
return AESTools.AESCacheDecrypt(value, configApp.CACHE_ENCRYP)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return value
|
||||||
|
}
|
||||||
|
}
|
||||||
47
src/assets/js/utils/cryptoJsUtil.js
Normal file
47
src/assets/js/utils/cryptoJsUtil.js
Normal file
@@ -0,0 +1,47 @@
|
|||||||
|
import CryptoJS from 'crypto-js'
|
||||||
|
export default {
|
||||||
|
AESEncrypt: function (data, keys) {//加密
|
||||||
|
var key = CryptoJS.enc.Hex.parse(keys)
|
||||||
|
var iv = CryptoJS.enc.Utf8.parse('0123456789ABCDEF');//偏移量
|
||||||
|
var encrypted = CryptoJS.AES.encrypt(data, key,
|
||||||
|
{
|
||||||
|
iv: iv,
|
||||||
|
mode: CryptoJS.mode.CBC,
|
||||||
|
padding: CryptoJS.pad.Pkcs7
|
||||||
|
});
|
||||||
|
return encrypted.toString();
|
||||||
|
},
|
||||||
|
AESDecrypt: function (encrypted, keys) {//解密
|
||||||
|
var key = CryptoJS.enc.Hex.parse(keys)
|
||||||
|
var iv = CryptoJS.enc.Utf8.parse('0123456789ABCDEF');
|
||||||
|
var decrypted = CryptoJS.AES.decrypt( encrypted, key,
|
||||||
|
{
|
||||||
|
iv: iv,
|
||||||
|
mode: CryptoJS.mode.CBC,
|
||||||
|
padding: CryptoJS.pad.Pkcs7
|
||||||
|
});
|
||||||
|
return CryptoJS.enc.Utf8.stringify(decrypted)
|
||||||
|
},
|
||||||
|
AESCacheEncrypt: function (data, keys) {//加密 緩存
|
||||||
|
var key = CryptoJS.enc.Hex.parse(keys)
|
||||||
|
var iv = CryptoJS.enc.Utf8.parse('0123456789ABCDEF');//偏移量
|
||||||
|
var encrypted = CryptoJS.AES.encrypt(data, key,
|
||||||
|
{
|
||||||
|
iv: iv,
|
||||||
|
mode: CryptoJS.mode.CBC,
|
||||||
|
padding: CryptoJS.pad.Pkcs7
|
||||||
|
});
|
||||||
|
return encrypted.toString();
|
||||||
|
},
|
||||||
|
AESCacheDecrypt: function (encrypted, keys) {//解密 緩存
|
||||||
|
var key = CryptoJS.enc.Hex.parse(keys)
|
||||||
|
var iv = CryptoJS.enc.Utf8.parse('0123456789ABCDEF');
|
||||||
|
var decrypted = CryptoJS.AES.decrypt( encrypted, key,
|
||||||
|
{
|
||||||
|
iv: iv,
|
||||||
|
mode: CryptoJS.mode.CBC,
|
||||||
|
padding: CryptoJS.pad.Pkcs7
|
||||||
|
});
|
||||||
|
return CryptoJS.enc.Utf8.stringify(decrypted)
|
||||||
|
}
|
||||||
|
}
|
||||||
9
src/assets/js/utils/needCacheKey.js
Normal file
9
src/assets/js/utils/needCacheKey.js
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
export default {
|
||||||
|
isAll: false,
|
||||||
|
encodeKeys: [
|
||||||
|
'saleInsuredInfo',
|
||||||
|
'saleInsuredPersonInfo',
|
||||||
|
'appntDTO',
|
||||||
|
'proposalAppnt'
|
||||||
|
]
|
||||||
|
}
|
||||||
30
src/assets/js/utils/orgShortName.js
Normal file
30
src/assets/js/utils/orgShortName.js
Normal file
@@ -0,0 +1,30 @@
|
|||||||
|
export const orgShortNames = [
|
||||||
|
{ name: '北海', code: '86450501' },
|
||||||
|
{ name: '广西八营', code: '86450168' },
|
||||||
|
{ name: '广西二营', code: '86450162' },
|
||||||
|
{ name: '广西六营', code: '86450166' },
|
||||||
|
{ name: '广西七营', code: '86450167' },
|
||||||
|
{ name: '广西三营', code: '86450163' },
|
||||||
|
{ name: '广西四营', code: '86450164' },
|
||||||
|
{ name: '广西五营', code: '86450165' },
|
||||||
|
{ name: '贵港', code: '86450801' },
|
||||||
|
{ name: '贵港一营', code: '86450861' },
|
||||||
|
{ name: '桂林二本', code: '86450302' },
|
||||||
|
{ name: '桂林一本', code: '86450301' },
|
||||||
|
{ name: '桂林一营', code: '86450361' },
|
||||||
|
{ name: '柳州一本', code: '86450201' },
|
||||||
|
{ name: '柳州二本', code: '86450202' },
|
||||||
|
{ name: '柳州四营', code: '86450264' },
|
||||||
|
{ name: '柳州一营', code: '86450261' },
|
||||||
|
{ name: '柳州鹿寨', code: '86450203' },
|
||||||
|
{ name: '南宁民族', code: '86450103' },
|
||||||
|
{ name: '精英项目', code: '86450102' },
|
||||||
|
{ name: '南宁青秀', code: '86450101' },
|
||||||
|
{ name: '南宁一营', code: '86450181' },
|
||||||
|
{ name: '梧州', code: '86450401' },
|
||||||
|
{ name: '梧州一营', code: '86450461' },
|
||||||
|
{ name: '玉林二营', code: '86450962' },
|
||||||
|
{ name: '玉林', code: '86450901' },
|
||||||
|
{ name: '玉林三营', code: '86450963' },
|
||||||
|
{ name: '玉林一营', code: '86450961' }
|
||||||
|
]
|
||||||
@@ -1,5 +1,6 @@
|
|||||||
//权限控制
|
//权限控制
|
||||||
import router from '@/router'
|
import router from '@/router'
|
||||||
|
import CacheUtils from '@/assets/js/utils/cacheUtils'
|
||||||
// import NProgress from 'nprogress' // Progress 进度条
|
// import NProgress from 'nprogress' // Progress 进度条
|
||||||
// import 'nprogress/nprogress.css' // Progress 进度条样式
|
// import 'nprogress/nprogress.css' // Progress 进度条样式
|
||||||
export function permission() {
|
export function permission() {
|
||||||
@@ -11,9 +12,9 @@ export function permission() {
|
|||||||
document.title = title
|
document.title = title
|
||||||
}
|
}
|
||||||
//判断是否登录
|
//判断是否登录
|
||||||
let token = localStorage.token
|
let token = CacheUtils.getLocItem('token')
|
||||||
if (!token) {
|
if (!token) {
|
||||||
localStorage.token = ''
|
CacheUtils.setLocItem('token','')
|
||||||
//无token,判断是否需要登录
|
//无token,判断是否需要登录
|
||||||
if (to.meta.auth) {
|
if (to.meta.auth) {
|
||||||
if (window.WebViewJavascriptBridge) {
|
if (window.WebViewJavascriptBridge) {
|
||||||
|
|||||||
@@ -1,6 +1,11 @@
|
|||||||
import axios from 'axios'
|
import axios from 'axios'
|
||||||
|
import AESTools from '@/assets/js/utils/cryptoJsUtil'
|
||||||
|
import configApp from '@/config'
|
||||||
import { Dialog, Toast } from 'vant'
|
import { Dialog, Toast } from 'vant'
|
||||||
import BusinessCommon from '@/assets/js/business-common.js'
|
import MD5 from 'js-md5'
|
||||||
|
import CacheUtils from '@/assets/js/utils/cacheUtils'
|
||||||
|
import BusinessCommon from '@/assets/js/business-common'
|
||||||
|
|
||||||
let proposal = [
|
let proposal = [
|
||||||
'/proposal/proposal/list',
|
'/proposal/proposal/list',
|
||||||
'/proposal/proposal/toInsurance',
|
'/proposal/proposal/toInsurance',
|
||||||
@@ -106,7 +111,7 @@ const service = axios.create({
|
|||||||
// request拦截器
|
// request拦截器
|
||||||
service.interceptors.request.use(
|
service.interceptors.request.use(
|
||||||
async config => {
|
async config => {
|
||||||
let relativePath = config.url && config.url.split('v1')[1]
|
let relativePath = config.url && config.url.split(configApp.API_VERSION)[1]
|
||||||
if (whiteList.includes(relativePath)) {
|
if (whiteList.includes(relativePath)) {
|
||||||
Toast.loading({
|
Toast.loading({
|
||||||
duration: 0, // 持续展示 toast
|
duration: 0, // 持续展示 toast
|
||||||
@@ -115,27 +120,37 @@ service.interceptors.request.use(
|
|||||||
message: '加载中……'
|
message: '加载中……'
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
let token = window.localStorage.getItem('token')
|
|
||||||
/**
|
/**
|
||||||
* 在HomeProduct页面获取代理人信息时, 客户端可能还未将token存储在本地
|
* 请求拦截处理(待添加 判断走统一网关处理)
|
||||||
* 此时如果token为空, 调用客户端方法获取token并放入localstorage中
|
|
||||||
*/
|
*/
|
||||||
console.log('localstorage token: ', token)
|
if (config.url && /api\/$/.test(config.url.split(configApp.API_VERSION)[0]) && configApp.API_VERSION == 'v2') {
|
||||||
if (relativePath === '/customer/agent/info' && !token) {
|
if (!config.data || config.data == null) {
|
||||||
|
config.data = {}
|
||||||
|
}
|
||||||
|
if (!!config.data && config.data != null) {
|
||||||
|
let encrypt = AESTools.AESEncrypt(JSON.stringify(config.data), configApp.REQ_PWD)
|
||||||
|
config.data = { data: encrypt }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// token 不存在初始化处理
|
||||||
|
let token = CacheUtils.getLocItem('token')
|
||||||
|
if (!token) {
|
||||||
// 设备类型
|
// 设备类型
|
||||||
const target = BusinessCommon.device()
|
const target = BusinessCommon.device()
|
||||||
// 安卓or苹果
|
// 安卓or苹果(非浏览器)
|
||||||
if (target.isAndroid || target.isIphone) {
|
if (!target.isWeixin && !target.isChrome) {
|
||||||
// eslint-disable-next-line no-undef
|
// eslint-disable-next-line no-undef
|
||||||
const res = await EWebBridge.webCallAppInJs('getToken')
|
const res = await EWebBridge.webCallAppInJs('getToken')
|
||||||
console.log('调用客户端获取token: ', res)
|
CacheUtils.setLocItem('token', JSON.parse(res).token)
|
||||||
const token = JSON.parse(res).token
|
|
||||||
window.localStorage.setItem('token', token)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
config.headers['token'] = token
|
|
||||||
// config.headers['token'] = `f0003a753d1d492083248f723ab1b6e9`//TEST测试专用
|
config.headers['token'] = CacheUtils.getLocItem('token')
|
||||||
|
// 添加请时间戳
|
||||||
|
let timeStr = new Date().getTime() + ''
|
||||||
|
config.headers['timeStr'] = timeStr
|
||||||
|
config.headers['signature'] = MD5(timeStr + CacheUtils.getLocItem('token'))
|
||||||
return config
|
return config
|
||||||
},
|
},
|
||||||
error => {
|
error => {
|
||||||
@@ -147,8 +162,18 @@ service.interceptors.request.use(
|
|||||||
// respone拦截器
|
// respone拦截器
|
||||||
service.interceptors.response.use(
|
service.interceptors.response.use(
|
||||||
response => {
|
response => {
|
||||||
const res = response.data
|
let res = response.data
|
||||||
console.log(res, 'res')
|
if (
|
||||||
|
configApp.API_VERSION == 'v2' &&
|
||||||
|
response.config.url &&
|
||||||
|
response.headers['content-type'].match(/application\/json/) &&
|
||||||
|
/api\/$/.test(response.config.url.split(configApp.API_VERSION)[0])
|
||||||
|
) {
|
||||||
|
if (res.response) {
|
||||||
|
// 正常情況返回必有response 节点
|
||||||
|
res = JSON.parse(AESTools.AESDecrypt(res.response, configApp.REQ_PWD))
|
||||||
|
}
|
||||||
|
}
|
||||||
Toast.clear()
|
Toast.clear()
|
||||||
if (res.code != 0) {
|
if (res.code != 0) {
|
||||||
if (res.code == 10001 || res.code == 10002) {
|
if (res.code == 10001 || res.code == 10002) {
|
||||||
@@ -166,7 +191,7 @@ service.interceptors.response.use(
|
|||||||
}
|
}
|
||||||
return Promise.reject(res)
|
return Promise.reject(res)
|
||||||
} else {
|
} else {
|
||||||
return response.data.content
|
return res.content
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
error => {
|
error => {
|
||||||
|
|||||||
@@ -1,6 +1,9 @@
|
|||||||
import axios from 'axios'
|
import axios from 'axios'
|
||||||
import { Dialog, Toast } from 'vant'
|
import { Dialog, Toast } from 'vant'
|
||||||
|
import CacheUtils from '@/assets/js/utils/cacheUtils'
|
||||||
|
import configApp from "@/config";
|
||||||
|
import AESTools from "@/assets/js/utils/cryptoJsUtil";
|
||||||
|
import MD5 from 'js-md5';
|
||||||
let sale = ['/sale/order/orderDetail'] //在线投保
|
let sale = ['/sale/order/orderDetail'] //在线投保
|
||||||
|
|
||||||
// 卡单
|
// 卡单
|
||||||
@@ -15,18 +18,32 @@ const service = axios.create({
|
|||||||
// request拦截器
|
// request拦截器
|
||||||
service.interceptors.request.use(
|
service.interceptors.request.use(
|
||||||
config => {
|
config => {
|
||||||
let relativePath = config.url && config.url.split('v1')[1]
|
let relativePath = config.url && config.url.split(configApp.API_VERSION)[1]
|
||||||
if (whiteList.includes(relativePath)) {
|
if (whiteList.includes(relativePath)) {
|
||||||
// Toast.loading({
|
Toast.loading({
|
||||||
// duration: 0, // 持续展示 toast
|
duration: 0, // 持续展示 toast
|
||||||
// forbidClick: true, // 禁用背景点击
|
forbidClick: true, // 禁用背景点击
|
||||||
// loadingType: 'spinner',
|
loadingType: 'spinner',
|
||||||
// message: '加载中……'
|
message: '加载中……'
|
||||||
// })
|
})
|
||||||
}
|
}
|
||||||
|
/**
|
||||||
config.headers['token'] = window.localStorage.getItem('token')
|
* 请求拦截处理(待添加 判断走统一网关处理)
|
||||||
// config.headers['token'] = ``
|
*/
|
||||||
|
if(config.url && /api\/$/.test(config.url.split(configApp.API_VERSION)[0]) && configApp.API_VERSION == 'v2'){
|
||||||
|
if(!config.data || config.data == null){
|
||||||
|
config.data = {}
|
||||||
|
}
|
||||||
|
if(!!config.data && config.data != null){
|
||||||
|
let encrypt = AESTools.AESEncrypt(JSON.stringify(config.data),configApp.REQ_PWD)
|
||||||
|
config.data = {"data": encrypt }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
config.headers['token'] = CacheUtils.getLocItem('token')
|
||||||
|
// 添加请时间戳
|
||||||
|
let timeStr = new Date().getTime() + '';
|
||||||
|
config.headers['timeStr'] = timeStr;
|
||||||
|
config.headers['signature'] = MD5(timeStr + CacheUtils.getLocItem('token'));
|
||||||
return config
|
return config
|
||||||
},
|
},
|
||||||
error => {
|
error => {
|
||||||
@@ -38,9 +55,15 @@ service.interceptors.request.use(
|
|||||||
// respone拦截器
|
// respone拦截器
|
||||||
service.interceptors.response.use(
|
service.interceptors.response.use(
|
||||||
response => {
|
response => {
|
||||||
const res = response.data
|
console.log(response)
|
||||||
console.log(res, 'res')
|
console.log('----------------')
|
||||||
|
let res = response.data
|
||||||
|
if( configApp.API_VERSION == 'v2' && response.config.url && response.headers['content-type'].match(/application\/json/) && /api\/$/.test(response.config.url.split(configApp.API_VERSION)[0])){
|
||||||
|
if(res.response){// 正常情況返回必有response 节点
|
||||||
|
res = JSON.parse(AESTools.AESDecrypt(res.response,configApp.REQ_PWD))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Toast.clear()
|
||||||
if (res.code != 0) {
|
if (res.code != 0) {
|
||||||
if (res.code == 10001 || res.code == 10002) {
|
if (res.code == 10001 || res.code == 10002) {
|
||||||
Dialog.confirm({
|
Dialog.confirm({
|
||||||
@@ -57,10 +80,11 @@ service.interceptors.response.use(
|
|||||||
}
|
}
|
||||||
return Promise.reject(res)
|
return Promise.reject(res)
|
||||||
} else {
|
} else {
|
||||||
return response.data.content
|
return res.content
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
error => {
|
error => {
|
||||||
|
Toast.clear()
|
||||||
console.log('err' + error) // for debug
|
console.log('err' + error) // for debug
|
||||||
//Toast.fail(error.message)
|
//Toast.fail(error.message)
|
||||||
return Promise.reject(error)
|
return Promise.reject(error)
|
||||||
|
|||||||
188
src/assets/js/utils/requestEncryot_back.js
Normal file
188
src/assets/js/utils/requestEncryot_back.js
Normal file
@@ -0,0 +1,188 @@
|
|||||||
|
import axios from 'axios'
|
||||||
|
import AESTools from '@/assets/js/utils/cryptoJsUtil'
|
||||||
|
import configApp from '@/config'
|
||||||
|
import { Dialog, Toast } from 'vant'
|
||||||
|
import CacheUtils from '@/assets/js/utils/cacheUtils'
|
||||||
|
let proposal = [
|
||||||
|
'/proposal/proposal/list',
|
||||||
|
'/proposal/proposal/toInsurance',
|
||||||
|
'/proposal/proposal/info',
|
||||||
|
'/proposal/proposal/demo',
|
||||||
|
'/proposal/proposal/saveOrUpdateProposal',
|
||||||
|
'/proposal/proposal/updateInsured',
|
||||||
|
'/proposal/file/getFile',
|
||||||
|
'/proposal/proposal/deleteProposal'
|
||||||
|
] //建议书
|
||||||
|
let sale = [
|
||||||
|
'/sale/order/orderList',
|
||||||
|
'/sale/order/saveOrUpdateOrderInfo',
|
||||||
|
'/sale/order/orderList',
|
||||||
|
'/sale/order/deleteOrderInfo',
|
||||||
|
'/sale/product/getDetail',
|
||||||
|
'/sale/order/saveOrUpdateOrderInfo',
|
||||||
|
'/sale/order/orderDetail',
|
||||||
|
'/customer/authcode/loginedSend',
|
||||||
|
'/uploadImage',
|
||||||
|
// '/customer/recognition',
|
||||||
|
'/sale/insure/underWrite',
|
||||||
|
'/sale/insure/acceptInsurance',
|
||||||
|
'/app/code/getCodeValue',
|
||||||
|
'/customer/token',
|
||||||
|
'/media/ebizSignInfo/sign',
|
||||||
|
'/sale/receiptSign/submit',
|
||||||
|
'/sale/order/orderDetail',
|
||||||
|
'/sale/record/check',
|
||||||
|
'/ppf/sign',
|
||||||
|
'/ppf/check',
|
||||||
|
'/sale/insure/selfToHuman',
|
||||||
|
'/sale/insure/orderPayStatusQuery'
|
||||||
|
] //在线投保
|
||||||
|
let agentEnter = [
|
||||||
|
'/agent/enter/share',
|
||||||
|
'/agent/enter/query',
|
||||||
|
'/agent/enter/saveOrUpdateInfo',
|
||||||
|
'/agent/enter/queryAll',
|
||||||
|
'/agent/enter/getImpart',
|
||||||
|
'/agent/agreement/query',
|
||||||
|
'/agent/agreement/signAgreement',
|
||||||
|
'/agent/enter/query',
|
||||||
|
'/agent/examineApprove/dispose' //入司增员审批
|
||||||
|
] //入司
|
||||||
|
let claims = [
|
||||||
|
`/claim/claimApply/progress`,
|
||||||
|
`/claim/claimApply/progressDetail`,
|
||||||
|
`/claim/claimReport/history`,
|
||||||
|
`/claim/claimApply/apply`,
|
||||||
|
`/edor/customer/customerList`,
|
||||||
|
`/edor/customer/customerInfo`,
|
||||||
|
`/claim/claimApply/query`,
|
||||||
|
`/claim/claimApply/delete`
|
||||||
|
]
|
||||||
|
let survey = [
|
||||||
|
//'/customer/question/getQuestionnaire', // 代理人下问卷查询 --ok
|
||||||
|
'/customer/question/getQuestion', // 问卷题库查询
|
||||||
|
'/customer/question/submit', // 问卷提交
|
||||||
|
//'/customer/question/shareSubmit', //问卷分享 --ok
|
||||||
|
//'/customer/question/getTableId', // id 查询 -- ok
|
||||||
|
'/customer/question/getAgentInfo' // 代理人详情
|
||||||
|
]
|
||||||
|
let manpower = [
|
||||||
|
'/customer/answer/queryList' //DISC性格分析
|
||||||
|
]
|
||||||
|
|
||||||
|
//保全
|
||||||
|
let preserve = [
|
||||||
|
'/edor/customer/customerList', //客户搜索
|
||||||
|
'/edor/policy/policyList', //保单列表
|
||||||
|
'/edor/edor/queryEdorList' //保全进度查询
|
||||||
|
]
|
||||||
|
|
||||||
|
let productStore = [
|
||||||
|
'/customer/shop/getShopList', //获取商城列表/详情
|
||||||
|
'/customer/shop/getShareList' //查询分享轨迹(转发记录)
|
||||||
|
]
|
||||||
|
|
||||||
|
// 卡单
|
||||||
|
let cardList = []
|
||||||
|
|
||||||
|
// 续期
|
||||||
|
let renewalManage = [
|
||||||
|
'/renewal/getRenewalList' //续期列表查询
|
||||||
|
]
|
||||||
|
|
||||||
|
let whiteList = [
|
||||||
|
'/customer/agent/getCustomersList',
|
||||||
|
...proposal,
|
||||||
|
...sale,
|
||||||
|
...agentEnter,
|
||||||
|
...claims,
|
||||||
|
...survey,
|
||||||
|
...manpower,
|
||||||
|
...productStore,
|
||||||
|
...preserve,
|
||||||
|
...renewalManage
|
||||||
|
]
|
||||||
|
|
||||||
|
// 创建axios实例
|
||||||
|
const service = axios.create({
|
||||||
|
timeout: 66666666 // 请求超时时间
|
||||||
|
})
|
||||||
|
|
||||||
|
// request拦截器
|
||||||
|
service.interceptors.request.use(
|
||||||
|
config => {
|
||||||
|
let relativePath = config.url && config.url.split('v1')[1]
|
||||||
|
console.log(config.url.split('v1')[0])
|
||||||
|
if (whiteList.includes(relativePath)) {
|
||||||
|
Toast.loading({
|
||||||
|
duration: 0, // 持续展示 toast
|
||||||
|
forbidClick: true, // 禁用背景点击
|
||||||
|
loadingType: 'spinner',
|
||||||
|
message: '加载中……'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 请求拦截处理(待添加 判断走统一网关处理)
|
||||||
|
*/
|
||||||
|
if(config.url && config.method == 'post' && /api\/$/.test(config.url.split('v1')[0])){
|
||||||
|
if(!config.data || config.data == null){
|
||||||
|
config.data = {}
|
||||||
|
}
|
||||||
|
if(!!config.data && config.data != null){
|
||||||
|
let encrypt = AESTools.AESEncrypt(JSON.stringify(config.data),configApp.REQ_PWD)
|
||||||
|
console.log("[调用请求加密服务][请求地址:"+config.url+"][加密前报文:]",JSON.stringify(config.data))
|
||||||
|
config.data = {"data": encrypt }
|
||||||
|
console.log("[调用请求加密服务][请求地址:"+config.url+"][加密后报文:]",config.data)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
config.headers['token'] = CacheUtils.getLocItem('token')
|
||||||
|
// config.headers['token'] = `f0003a753d1d492083248f723ab1b6e9`//TEST测试专用
|
||||||
|
return config
|
||||||
|
},
|
||||||
|
error => {
|
||||||
|
// Do something with request error
|
||||||
|
Promise.reject(error)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
|
||||||
|
// respone拦截器
|
||||||
|
service.interceptors.response.use(
|
||||||
|
response => {
|
||||||
|
console.log(response)
|
||||||
|
let res = response.data
|
||||||
|
if(response.config.url && response.config.method == 'post' && /api\/$/.test(response.config.url.split('v1')[0])){
|
||||||
|
if(res.response){
|
||||||
|
console.log("[调用请求加密服务][请求地址:"+response.config.url+"][解密前报文:]",JSON.stringify(res.response))
|
||||||
|
res = AESTools.AESDecrypt(JSON.stringify(res.response),configApp.REQ_PWD)
|
||||||
|
console.log("[调用请求加密服务][请求地址:"+response.config.url+"][解密后报文:]",JSON.stringify(res))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Toast.clear()
|
||||||
|
if (res.code != 0) {
|
||||||
|
if (res.code == 10001 || res.code == 10002) {
|
||||||
|
Dialog.confirm({
|
||||||
|
confirmButtonText: '重新登录',
|
||||||
|
message: '你已被登出,可以取消继续留在该页面,或者重新登录'
|
||||||
|
}).then(() => {
|
||||||
|
//eslint-disable-next-line
|
||||||
|
EWebBridge.webCallAppInJs('bridge', {
|
||||||
|
flag: 'login'
|
||||||
|
})
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
//Toast.fail(res.msg)
|
||||||
|
}
|
||||||
|
return Promise.reject(res)
|
||||||
|
} else {
|
||||||
|
return response.data.content
|
||||||
|
}
|
||||||
|
},
|
||||||
|
error => {
|
||||||
|
Toast.clear()
|
||||||
|
console.log('err' + error) // for debug
|
||||||
|
//Toast.fail(error.message)
|
||||||
|
return Promise.reject(error)
|
||||||
|
}
|
||||||
|
)
|
||||||
|
|
||||||
|
export default service
|
||||||
262
src/components/common/CheckAgent.vue
Normal file
262
src/components/common/CheckAgent.vue
Normal file
@@ -0,0 +1,262 @@
|
|||||||
|
<template>
|
||||||
|
<!-- 短信验证 -->
|
||||||
|
<van-dialog
|
||||||
|
v-model="checkModel.show"
|
||||||
|
title="提示"
|
||||||
|
show-cancel-button
|
||||||
|
@confirm="checkModelConfirm"
|
||||||
|
@cancel="checkModelCancel"
|
||||||
|
:before-close="checkModelBeforeClose"
|
||||||
|
>
|
||||||
|
<van-tabs v-model="active" @click="clickTable">
|
||||||
|
<van-tab>
|
||||||
|
<template #title>密码校验</template>
|
||||||
|
<div class="p10 fs14">
|
||||||
|
<p>为保护客户隐私数据安全,请您授权访问。请在下面输入框输入登录密码后完成后续操作。</p>
|
||||||
|
<van-field
|
||||||
|
minlength="6"
|
||||||
|
class="pt5 mt10"
|
||||||
|
style="border-top:1px solid #eaeaea;border-bottom:1px solid #eaeaea"
|
||||||
|
v-model="checkModel.pwd"
|
||||||
|
clearable
|
||||||
|
type="password"
|
||||||
|
label="密码:"
|
||||||
|
name="密码"
|
||||||
|
label-width="3em"
|
||||||
|
placeholder="请输入密码"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
</van-tab>
|
||||||
|
<van-tab :disabled="isShowSms">
|
||||||
|
<template #title>短信校验</template>
|
||||||
|
<div>
|
||||||
|
<p class="p10 fs14">
|
||||||
|
为保护客户隐私数据安全,请您授权访问。短信验证码已发送至您手机号{{ checkModel.mobile | encryCheckModelMobile }},请您输入验证码以完成后续操作。
|
||||||
|
</p>
|
||||||
|
<van-cell-group class="flex align-items-c pr5 mb15">
|
||||||
|
<van-field maxlength="6" placeholder="请输入短信验证码" v-model="checkModel.authCode" clearable label-width="0" />
|
||||||
|
<van-button
|
||||||
|
type="danger"
|
||||||
|
plain
|
||||||
|
size="small"
|
||||||
|
class="w160 p0"
|
||||||
|
@click="checkModelGetCode"
|
||||||
|
:disabled="checkModel.codeDisabled"
|
||||||
|
v-no-more-click="2000"
|
||||||
|
>{{ checkModel.codeDisabled ? `${checkModel.countDown}s后重新获取` : '获取验证码' }}</van-button
|
||||||
|
>
|
||||||
|
</van-cell-group>
|
||||||
|
</div>
|
||||||
|
</van-tab>
|
||||||
|
</van-tabs>
|
||||||
|
</van-dialog>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import { Search, Cell, IndexBar, IndexAnchor, Popup, Button, Tag, Dialog, Field, Tab, Tabs } from 'vant'
|
||||||
|
import { checkEnterPower, getAuthCode, getCheckModelAgentInfo } from '@/api/ebiz/common/common'
|
||||||
|
export default {
|
||||||
|
name: 'CheckAgent',
|
||||||
|
props: {},
|
||||||
|
components: {
|
||||||
|
[Tab.name]: Tab,
|
||||||
|
[Tabs.name]: Tabs,
|
||||||
|
[Search.name]: Search,
|
||||||
|
[Cell.name]: Cell,
|
||||||
|
[IndexBar.name]: IndexBar,
|
||||||
|
[IndexAnchor.name]: IndexAnchor,
|
||||||
|
[Popup.name]: Popup,
|
||||||
|
[Button.name]: Button,
|
||||||
|
[Field.name]: Field,
|
||||||
|
[Dialog.name]: Dialog,
|
||||||
|
[Tag.name]: Tag
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
active: 0,
|
||||||
|
isShowSms: true,
|
||||||
|
checkModel: {
|
||||||
|
pwd: null,
|
||||||
|
show: false,
|
||||||
|
authCode: '',
|
||||||
|
smsId: '',
|
||||||
|
mobile: '',
|
||||||
|
timeId: null, // 计时器ID
|
||||||
|
countDown: 60, // 倒计时
|
||||||
|
codeDisabled: false // 获取验证码按钮是否禁用
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
this.checkModelEnterValidate()
|
||||||
|
},
|
||||||
|
filters: {
|
||||||
|
// 电话号码加密
|
||||||
|
encryCheckModelMobile(code) {
|
||||||
|
return code.replace(/^(\d{3})\d{4}(\d{4})$/, '$1****$2')
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
clickTable() {
|
||||||
|
console.log('active', this.active)
|
||||||
|
},
|
||||||
|
// 校验是否显示弹窗
|
||||||
|
async checkModelEnterValidate() {
|
||||||
|
let checkModelResult = await checkEnterPower({ operateType: 'isEnter' })
|
||||||
|
if (checkModelResult.result == 0) {
|
||||||
|
if (checkModelResult.enterFlag == '0') {
|
||||||
|
// 已校验过 触发成功事件
|
||||||
|
let that = this
|
||||||
|
this.$emit('checModelSuccessMethod', that.checkModel.show)
|
||||||
|
} else {
|
||||||
|
this.checkModelFilter()
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
this.$toast(checkModelResult.resultMessage)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
//弹窗关闭提示
|
||||||
|
checkModelBeforeClose(action, done) {
|
||||||
|
if (action === 'confirm' && !this.checkModel.show) {
|
||||||
|
setTimeout(done, 1000)
|
||||||
|
} else {
|
||||||
|
done(false)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 内外勤处理
|
||||||
|
async checkModelFilter() {
|
||||||
|
const agentInfoRes = await getCheckModelAgentInfo({})
|
||||||
|
if (agentInfoRes.result == 0) {
|
||||||
|
if (/^[0-9][0-9]*$/.test(agentInfoRes.branchType)) {
|
||||||
|
// 内勤 并且手机号码正确
|
||||||
|
this.checkModel.mobile = agentInfoRes.phoneNo
|
||||||
|
this.checkModel.show = true
|
||||||
|
this.isShowSms = false
|
||||||
|
} else {
|
||||||
|
// 已校验过 触发成功事件
|
||||||
|
this.checkModel.show = true
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
this.$toast(agentInfoRes.resultMessage)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 提交处理
|
||||||
|
async checkModelConfirm() {
|
||||||
|
let that = this
|
||||||
|
let reqParam = { operateType: 'validateSms', smsId: that.checkModel.smsId, code: that.checkModel.authCode }
|
||||||
|
if (this.active == 0) {
|
||||||
|
if (!this.checkModel.pwd || this.checkModel.pwd == '') {
|
||||||
|
this.checkModel.show = true
|
||||||
|
return this.$toast('请输入密码')
|
||||||
|
}
|
||||||
|
if (this.checkModel.pwd.length < 6) {
|
||||||
|
this.checkModel.pwd = ''
|
||||||
|
this.checkModel.show = true
|
||||||
|
return this.$toast('密码格式错误,请重新输入')
|
||||||
|
}
|
||||||
|
reqParam = {
|
||||||
|
operateType: 'validatePwd',
|
||||||
|
pwd: this.$MD5(this.checkModel.pwd)
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if (!this.checkModel.codeDisabled) {
|
||||||
|
this.checkModel.show = true
|
||||||
|
return this.$toast('请先获取验证码')
|
||||||
|
}
|
||||||
|
if (!this.checkModel.authCode || this.checkModel.authCode == '') {
|
||||||
|
this.checkModel.show = true
|
||||||
|
return this.$toast('请输入短信验证码')
|
||||||
|
}
|
||||||
|
if (this.checkModel.authCode.length !== 6) {
|
||||||
|
this.checkModel.show = true
|
||||||
|
return this.$toast('验证码格式错误')
|
||||||
|
}
|
||||||
|
reqParam = {
|
||||||
|
operateType: 'validateSms',
|
||||||
|
smsId: that.checkModel.smsId,
|
||||||
|
code: that.checkModel.authCode
|
||||||
|
}
|
||||||
|
}
|
||||||
|
let checkModelResult = await checkEnterPower(reqParam)
|
||||||
|
if (checkModelResult.result == 0) {
|
||||||
|
// 校验通过过 触发成功事件
|
||||||
|
this.checkModel.show = false
|
||||||
|
let that = this
|
||||||
|
this.$emit('checModelSuccessMethod', that.checkModel.show)
|
||||||
|
} else {
|
||||||
|
this.checkModel.show = true
|
||||||
|
this.checkModel.codeDisabled = true
|
||||||
|
window.clearInterval(this.checkModel.timeId)
|
||||||
|
this.$toast(checkModelResult.resultMessage)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 跳转首页
|
||||||
|
checkModelCancel() {
|
||||||
|
// 跳转首页
|
||||||
|
this.$jump({
|
||||||
|
flag: 'home'
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// 获取验证码
|
||||||
|
checkModelGetCode() {
|
||||||
|
this.checkModel.codeDisabled = true
|
||||||
|
let data = {
|
||||||
|
operateType: 'agentValidateEnter',
|
||||||
|
type: 'H5',
|
||||||
|
operateCode: this.checkModel.mobile,
|
||||||
|
system: 'agentApp',
|
||||||
|
operateCodeType: '0'
|
||||||
|
}
|
||||||
|
//获取验证码
|
||||||
|
getAuthCode(data).then(res => {
|
||||||
|
if (res.result == 0) {
|
||||||
|
this.checkModel.smsId = res.sessionId
|
||||||
|
this.checkModel.smsCode = null
|
||||||
|
//倒计时
|
||||||
|
this.checkModel.timeId = setInterval(() => {
|
||||||
|
this.checkModel.countDown--
|
||||||
|
if (this.checkModel.countDown <= 0) {
|
||||||
|
window.clearInterval(this.checkModel.timeId)
|
||||||
|
this.checkModel.codeDisabled = false
|
||||||
|
this.checkModel.countDown = 60
|
||||||
|
}
|
||||||
|
}, 1000)
|
||||||
|
} else {
|
||||||
|
this.$toast(res.resultMessage)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.index-bar {
|
||||||
|
display: flex;
|
||||||
|
overflow-x: auto;
|
||||||
|
overflow-y: hidden;
|
||||||
|
white-space: nowrap;
|
||||||
|
font-size: 15px;
|
||||||
|
margin-top: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.index-bar li {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.index-bar::-webkit-scrollbar {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
li {
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
.index-bar span,
|
||||||
|
.index-bar van-icon {
|
||||||
|
align-items: flex-center;
|
||||||
|
}
|
||||||
|
.active {
|
||||||
|
color: #e9332e;
|
||||||
|
}
|
||||||
|
.activeline {
|
||||||
|
background: #e9332e;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -3,8 +3,8 @@
|
|||||||
<div class="user-info flex p15 bg-head align-items-e">
|
<div class="user-info flex p15 bg-head align-items-e">
|
||||||
<img class="w40" src="../../../assets/images/bnf_avatar.png" />
|
<img class="w40" src="../../../assets/images/bnf_avatar.png" />
|
||||||
<div class="add-list flex1 ml10">
|
<div class="add-list flex1 ml10">
|
||||||
<p class="fs16 font-bold">{{ userInfo.name }}</p>
|
<p class="fs16 font-bold">{{ userInfo.encryptionName }}</p>
|
||||||
<div class="">工号 | {{ userInfo.jobNo }}</div>
|
<div class="">工号 | {{ userInfo.encryptionJobNo }}</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -5,19 +5,22 @@
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
let apiDomain, imgDomain, assetsUrl, mainUrl, payUrl, zssqUrl // 保融支付的收银台服务地址
|
let apiDomain, imgDomain, assetsUrl, mainUrl, payUrl, zssqUrl ,REQ_PWD, CACHE_ENCRYP, API_VERSION// 保融支付的收银台服务地址
|
||||||
|
|
||||||
// 可以多个接口域名,按需添加
|
// 可以多个接口域名,按需添加
|
||||||
console.log('环境:', process.env.VUE_APP_FLAG)
|
console.log('环境:', process.env.VUE_APP_FLAG)
|
||||||
switch (process.env.VUE_APP_FLAG) {
|
switch (process.env.VUE_APP_FLAG) {
|
||||||
case 'dev':
|
case 'dev':
|
||||||
apiDomain = 'http://139.199.50.151:7000/api/v1' // 国富api ///api/v1
|
apiDomain = 'http://139.199.50.151:7000/api/v2' // 国富api ///api/v1
|
||||||
imgDomain = 'http://211.159.248.123:7012/updown' // dev
|
imgDomain = 'http://211.159.248.123:7012/updown' // dev
|
||||||
// 静态服务资源
|
// 静态服务资源
|
||||||
assetsUrl = 'http://139.199.50.151:8000/app/'
|
assetsUrl = 'http://139.199.50.151:8000/app/'
|
||||||
mainUrl = 'http://139.199.50.151'
|
mainUrl = 'http://139.199.50.151'
|
||||||
payUrl = 'https://funduat.e-guofu.com/s3-modules-gateway/embed/gateway.action'
|
payUrl = 'https://funduat.e-guofu.com/s3-modules-gateway/embed/gateway.action'
|
||||||
zssqUrl = 'http://139.199.50.151/html/test/index.html#/'
|
zssqUrl = 'http://139.199.50.151/html/test/index.html#/'
|
||||||
|
REQ_PWD = '41424344454631323334353637383930'
|
||||||
|
CACHE_ENCRYP = '41424344454631323334353637383930'
|
||||||
|
API_VERSION = 'v2'
|
||||||
break
|
break
|
||||||
case 'uat':
|
case 'uat':
|
||||||
apiDomain = 'http://115.159.235.59:7000/api/v1' // 国富api
|
apiDomain = 'http://115.159.235.59:7000/api/v1' // 国富api
|
||||||
@@ -27,14 +30,20 @@ switch (process.env.VUE_APP_FLAG) {
|
|||||||
mainUrl = 'http://115.159.235.59'
|
mainUrl = 'http://115.159.235.59'
|
||||||
payUrl = 'https://funduat.e-guofu.com/s3-modules-gateway/embed/gateway.action'
|
payUrl = 'https://funduat.e-guofu.com/s3-modules-gateway/embed/gateway.action'
|
||||||
zssqUrl = ''
|
zssqUrl = ''
|
||||||
|
REQ_PWD = '41424344454631323334353637383930'
|
||||||
|
CACHE_ENCRYP = '41424344454631323334353637383930'
|
||||||
|
API_VERSION = 'v2'
|
||||||
break
|
break
|
||||||
case 'prd':
|
case 'prd':
|
||||||
apiDomain = 'https://iagentsales.e-guofu.com/api/v1'
|
apiDomain = 'https://iagentsales.e-guofu.com/api/v2'
|
||||||
imgDomain = 'https://iagentsales-ud.e-guofu.com:8553/updown'
|
imgDomain = 'https://iagentsales-ud.e-guofu.com:8553/updown'
|
||||||
assetsUrl = 'https://iagentsales-sr.e-guofu.com:8443/'
|
assetsUrl = 'https://iagentsales-sr.e-guofu.com:8443/'
|
||||||
mainUrl = 'https://iagentsales.e-guofu.com'
|
mainUrl = 'https://iagentsales.e-guofu.com'
|
||||||
payUrl = 'https://uns3.e-guofu.com/s3-modules-gateway/embed/gateway.action'
|
payUrl = 'https://uns3.e-guofu.com/s3-modules-gateway/embed/gateway.action'
|
||||||
zssqUrl = ''
|
zssqUrl = ''
|
||||||
|
REQ_PWD = '41424344454631323334353637383930'
|
||||||
|
CACHE_ENCRYP = '41424344454631323334353637383930'
|
||||||
|
API_VERSION = 'v2'
|
||||||
break
|
break
|
||||||
case 'dat':
|
case 'dat':
|
||||||
apiDomain = ''
|
apiDomain = ''
|
||||||
@@ -44,6 +53,9 @@ switch (process.env.VUE_APP_FLAG) {
|
|||||||
mainUrl = ''
|
mainUrl = ''
|
||||||
payUrl = ''
|
payUrl = ''
|
||||||
zssqUrl = ''
|
zssqUrl = ''
|
||||||
|
REQ_PWD = '41424344454631323334353637383930'
|
||||||
|
CACHE_ENCRYP = '41424344454631323334353637383930'
|
||||||
|
API_VERSION = 'v2'
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
@@ -61,5 +73,8 @@ export default {
|
|||||||
assetsUrl,
|
assetsUrl,
|
||||||
mainUrl,
|
mainUrl,
|
||||||
payUrl,
|
payUrl,
|
||||||
zssqUrl //知识社区地址
|
zssqUrl, //知识社区地址
|
||||||
|
REQ_PWD, //报文加密密码
|
||||||
|
CACHE_ENCRYP, //缓存加密密码
|
||||||
|
API_VERSION //渠道版本
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -184,5 +184,15 @@ export default {
|
|||||||
let str = ''
|
let str = ''
|
||||||
str = (moneyStr + '').replace(/\d{1,3}(?=(\d{3})+$)/g, '$&,') + '元'
|
str = (moneyStr + '').replace(/\d{1,3}(?=(\d{3})+$)/g, '$&,') + '元'
|
||||||
return str
|
return str
|
||||||
|
},
|
||||||
|
// 手机号码脱敏
|
||||||
|
dataMaskingMobile(mobile) {
|
||||||
|
let str = ''
|
||||||
|
if (mobile && mobile.trim().length == 11) {
|
||||||
|
str = mobile.trim().replace(/^(\S{3})(\S*)(\S{4})$/, function(all, u1, u2, u3) {
|
||||||
|
return u1 + new Array(u2.length + 1).join('*') + u3
|
||||||
|
})
|
||||||
|
}
|
||||||
|
return str
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,6 +11,10 @@ import config from '@/config'
|
|||||||
import noMoreClick from '@/directive/noMoreClick'
|
import noMoreClick from '@/directive/noMoreClick'
|
||||||
import vueHashCalendar from 'vue-hash-calendar'
|
import vueHashCalendar from 'vue-hash-calendar'
|
||||||
import 'vue-hash-calendar/lib/vue-hash-calendar.css'
|
import 'vue-hash-calendar/lib/vue-hash-calendar.css'
|
||||||
|
import md5 from 'js-md5';
|
||||||
|
import cryptoJs from 'crypto-js'
|
||||||
|
import cacheUtils from '@/assets/js/utils/cacheUtils'
|
||||||
|
|
||||||
|
|
||||||
import { Cell, CellGroup, DatetimePicker, Popup, Picker, Col, Row, Tab, Tabs, NavBar, Toast, Button, Dialog, Icon, Lazyload } from 'vant'
|
import { Cell, CellGroup, DatetimePicker, Popup, Picker, Col, Row, Tab, Tabs, NavBar, Toast, Button, Dialog, Icon, Lazyload } from 'vant'
|
||||||
Vue.use(Cell)
|
Vue.use(Cell)
|
||||||
@@ -35,6 +39,9 @@ Vue.use(Lazyload, {
|
|||||||
Vue.prototype.$assetsUrl = config.assetsUrl
|
Vue.prototype.$assetsUrl = config.assetsUrl
|
||||||
Vue.prototype.$mainUrl = config.mainUrl
|
Vue.prototype.$mainUrl = config.mainUrl
|
||||||
Vue.prototype.$zssqUrl = config.zssqUrl
|
Vue.prototype.$zssqUrl = config.zssqUrl
|
||||||
|
Vue.prototype.$MD5 = md5
|
||||||
|
Vue.prototype.$CryptoJs = cryptoJs
|
||||||
|
Vue.prototype.$CacheUtils = cacheUtils
|
||||||
|
|
||||||
// 全局 防重复点击
|
// 全局 防重复点击
|
||||||
Vue.directive('no-more-click', noMoreClick)
|
Vue.directive('no-more-click', noMoreClick)
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
//定义相关组件
|
//定义相关组件
|
||||||
const home = () => import('@/views/app/Home')
|
const home = () => import('@/views/app/Home')
|
||||||
const login = () => import('@/views/app/Login')
|
const loginss = () => import('@/views/app/Login')
|
||||||
const notFound = () => import('@/views/app/404')
|
const notFound = () => import('@/views/app/404')
|
||||||
const functionList = () => import('@/views/app/FunctionList')
|
const functionList = () => import('@/views/app/FunctionList')
|
||||||
|
|
||||||
@@ -15,9 +15,9 @@ let arr = [
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: '/login',
|
path: '/loginss',
|
||||||
name: 'login',
|
name: 'loginss',
|
||||||
component: login,
|
component: loginss,
|
||||||
meta: {
|
meta: {
|
||||||
title: '登录页'
|
title: '登录页'
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,6 +4,7 @@ const userSetting = () => import('@/views/ebiz/my/UserSetting')
|
|||||||
const userInfo = () => import('@/views/ebiz/my/UserInfo')
|
const userInfo = () => import('@/views/ebiz/my/UserInfo')
|
||||||
const userIncome = () => import('@/views/ebiz/my/UserIncome')
|
const userIncome = () => import('@/views/ebiz/my/UserIncome')
|
||||||
const PrivacyPolicy = () => import('@/views/ebiz/my/PrivacyPolicy')
|
const PrivacyPolicy = () => import('@/views/ebiz/my/PrivacyPolicy')
|
||||||
|
const LogoutAgent = () => import('@/views/ebiz/my/LogoutAgent')
|
||||||
|
|
||||||
export default [
|
export default [
|
||||||
{
|
{
|
||||||
@@ -51,5 +52,15 @@ export default [
|
|||||||
title: '金掌桂隐私政策',
|
title: '金掌桂隐私政策',
|
||||||
index: 1
|
index: 1
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
//隐私政策
|
||||||
|
path: '/my/logoutAgent',
|
||||||
|
name: 'LogoutAgent',
|
||||||
|
component: LogoutAgent,
|
||||||
|
meta: {
|
||||||
|
title: '注销账户',
|
||||||
|
index: 1
|
||||||
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@@ -2,16 +2,18 @@
|
|||||||
<div class="login-container ph10">
|
<div class="login-container ph10">
|
||||||
<h3 class="text-center pv30">欢迎登录</h3>
|
<h3 class="text-center pv30">欢迎登录</h3>
|
||||||
<van-cell-group cl>
|
<van-cell-group cl>
|
||||||
<van-field v-model="username" clearable label="用户名" placeholder="请输入用户名" left-icon="contact" />
|
<van-field v-model="username" clearable label="用户名" placeholder="请输入用户名" left-icon="contact"/>
|
||||||
<van-field v-model="password" type="password" label="密码" placeholder="请输入密码" left-icon="bag-o" />
|
<van-field v-model="password" type="password" label="密码" placeholder="请输入密码" left-icon="bag-o"/>
|
||||||
</van-cell-group>
|
</van-cell-group>
|
||||||
<van-button type="info" size="large" class="mt30" @click="login" :loading="loading" loading-text="登录中...">登录</van-button>
|
<van-button type="info" size="large" class="mt30" @click="login" :loading="loading" loading-text="登录中...">登录
|
||||||
|
</van-button>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { Field, CellGroup } from 'vant'
|
import {CellGroup, Field} from 'vant'
|
||||||
import { login } from '@/api/app/user'
|
import {loginTest} from '@/api/ebiz/my/my.js'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'login',
|
name: 'login',
|
||||||
components: {
|
components: {
|
||||||
@@ -33,16 +35,30 @@ export default {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
this.loading = true
|
this.loading = true
|
||||||
//登录
|
let that = this;
|
||||||
login()
|
let reqData = {
|
||||||
.then(res => {
|
password: this.$MD5(that.password),
|
||||||
localStorage.token = res.token
|
system: "agentApp",
|
||||||
|
graphCode: "",
|
||||||
|
graphId: "",
|
||||||
|
name: this.username,
|
||||||
|
loginflag: "agentPassword",
|
||||||
|
}
|
||||||
|
|
||||||
|
loginTest(reqData).then(res => {
|
||||||
|
this.loading = false
|
||||||
|
if (res.result == 0) {
|
||||||
|
console.log(res)
|
||||||
|
this.$CacheUtils.setLocItem("token",res.token)
|
||||||
this.$router.push({ path: this.redirect || '/' })
|
this.$router.push({ path: this.redirect || '/' })
|
||||||
})
|
}else {
|
||||||
.catch(err => {
|
this.$toast(res.resultMessage)
|
||||||
|
}
|
||||||
|
}) .catch(err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
this.loading = false
|
this.loading = false
|
||||||
})
|
})
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -7,6 +7,7 @@ import { saveOrUpdateOrderInfo, getAuthCode, getOrderDetail } from '@/api/ebiz/s
|
|||||||
import getAreaName from '@/assets/js/utils/get-area-name'
|
import getAreaName from '@/assets/js/utils/get-area-name'
|
||||||
// import idNoCheck from '@/assets/js/utils/idNoCheck'
|
// import idNoCheck from '@/assets/js/utils/idNoCheck'
|
||||||
import { idToData } from './verification'
|
import { idToData } from './verification'
|
||||||
|
import CacheUtils from '@/assets/js/utils/cacheUtils'
|
||||||
let relationToInsured = [
|
let relationToInsured = [
|
||||||
{
|
{
|
||||||
id: 2,
|
id: 2,
|
||||||
@@ -37,14 +38,14 @@ export function selectComp(that, index, type = '') {
|
|||||||
} else if (index == 3) {
|
} else if (index == 3) {
|
||||||
if (type == '1') {
|
if (type == '1') {
|
||||||
//投保人
|
//投保人
|
||||||
localStorage.scanFromInsured = 'true'
|
CacheUtils.setLocItem('scanFromInsured','true')
|
||||||
} else if (type == '2') {
|
} else if (type == '2') {
|
||||||
//被保险人
|
//被保险人
|
||||||
localStorage.scanFromInsured = 'false'
|
CacheUtils.setLocItem('scanFromInsured','false')
|
||||||
}
|
}
|
||||||
;[that.isScan, title] = [true, '身份证扫描']
|
;[that.isScan, title] = [true, '身份证扫描']
|
||||||
} else if (index == 4) {
|
} else if (index == 4) {
|
||||||
localStorage.scanFromInsured = 0
|
CacheUtils.setLocItem('scanFromInsured','0')
|
||||||
;[that.bankisScan, title] = [true, '银行卡扫描']
|
;[that.bankisScan, title] = [true, '银行卡扫描']
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -248,7 +249,7 @@ export function onConfirm(that, value, type) {
|
|||||||
if (value.id == 1) {
|
if (value.id == 1) {
|
||||||
//获取订单详情
|
//获取订单详情
|
||||||
getOrderDetail({
|
getOrderDetail({
|
||||||
orderNo: localStorage.orderNo
|
orderNo: CacheUtils.getLocItem('orderNo')
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
if (res.result == 0) {
|
if (res.result == 0) {
|
||||||
that.isAppnt = true
|
that.isAppnt = true
|
||||||
@@ -349,7 +350,7 @@ export function onConfirm(that, value, type) {
|
|||||||
if (value.id == 1) {
|
if (value.id == 1) {
|
||||||
//获取投保人数据
|
//获取投保人数据
|
||||||
getOrderDetail({
|
getOrderDetail({
|
||||||
orderNo: localStorage.orderNo
|
orderNo: CacheUtils.getLocItem('orderNo')
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
if (res.result == 0) {
|
if (res.result == 0) {
|
||||||
that.isInsured = true
|
that.isInsured = true
|
||||||
@@ -690,14 +691,14 @@ export function nextStep(that, type) {
|
|||||||
//信息变更
|
//信息变更
|
||||||
export function infoUpdate(that, type) {
|
export function infoUpdate(that, type) {
|
||||||
//local 里面是否存有险种信息
|
//local 里面是否存有险种信息
|
||||||
let chooseProductCodes = localStorage.chooseProductCodes && JSON.parse(localStorage.chooseProductCodes)
|
let chooseProductCodes = CacheUtils.getLocItem('chooseProductCodes') && JSON.parse(CacheUtils.getLocItem('chooseProductCodes'))
|
||||||
if (chooseProductCodes && chooseProductCodes.length) {
|
if (chooseProductCodes && chooseProductCodes.length) {
|
||||||
let flag
|
let flag
|
||||||
switch (type) {
|
switch (type) {
|
||||||
case '1':
|
case '1':
|
||||||
{
|
{
|
||||||
//取出local中的投被保险人信息
|
//取出local中的投被保险人信息
|
||||||
let saleInsuredInfo = JSON.parse(localStorage.saleInsuredInfo)
|
let saleInsuredInfo = JSON.parse(CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
//如果 性别, 出生日期, 有无社保, 职业 发生变化
|
//如果 性别, 出生日期, 有无社保, 职业 发生变化
|
||||||
if (that.userInfo.sex != saleInsuredInfo.sex || that.userInfo.birthday != saleInsuredInfo.birthday) {
|
if (that.userInfo.sex != saleInsuredInfo.sex || that.userInfo.birthday != saleInsuredInfo.birthday) {
|
||||||
flag = true
|
flag = true
|
||||||
@@ -707,7 +708,7 @@ export function infoUpdate(that, type) {
|
|||||||
case '2':
|
case '2':
|
||||||
{
|
{
|
||||||
//取出local中的被保险人信息
|
//取出local中的被保险人信息
|
||||||
let saleInsuredPersonInfo = JSON.parse(localStorage.saleInsuredPersonInfo)
|
let saleInsuredPersonInfo = JSON.parse(CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
//如果 性别, 出生日期, 有无社保, 职业 发生变化
|
//如果 性别, 出生日期, 有无社保, 职业 发生变化
|
||||||
if (
|
if (
|
||||||
that.userInfo.sex != saleInsuredPersonInfo.sex ||
|
that.userInfo.sex != saleInsuredPersonInfo.sex ||
|
||||||
@@ -732,7 +733,7 @@ export function infoUpdate(that, type) {
|
|||||||
confirmButtonColor: '#FFFFFF'
|
confirmButtonColor: '#FFFFFF'
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
localStorage.from = 'anotherChanged'
|
CacheUtils.setLocItem('from','anotherChanged')
|
||||||
type == '1' ? that.save('isShow=1') : that.save()
|
type == '1' ? that.save('isShow=1') : that.save()
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
@@ -755,7 +756,7 @@ export function save(that, type, str) {
|
|||||||
orderType: type == '1' ? 'APPNT_ORDER' : 'INSURED_ORDER',
|
orderType: type == '1' ? 'APPNT_ORDER' : 'INSURED_ORDER',
|
||||||
orderDTO: {
|
orderDTO: {
|
||||||
orderInfoDTO: {
|
orderInfoDTO: {
|
||||||
orderNo: localStorage.orderNo
|
orderNo: CacheUtils.getLocItem('orderNo')
|
||||||
},
|
},
|
||||||
smsCodeDTO: {
|
smsCodeDTO: {
|
||||||
smsId: that.sessionId,
|
smsId: that.sessionId,
|
||||||
@@ -771,7 +772,7 @@ export function save(that, type, str) {
|
|||||||
type == '1' ? (params.orderDTO.appntDTO = that.userInfo) : (params.orderDTO.insuredDTOs = [that.userInfo])
|
type == '1' ? (params.orderDTO.appntDTO = that.userInfo) : (params.orderDTO.insuredDTOs = [that.userInfo])
|
||||||
saveOrUpdateOrderInfo(params).then(res => {
|
saveOrUpdateOrderInfo(params).then(res => {
|
||||||
if (res.result == 0) {
|
if (res.result == 0) {
|
||||||
type == '1' ? (localStorage.orderNo = res.orderNo) : (localStorage.isFrom = 'sale')
|
type == '1' ? (CacheUtils.setLocItem('orderNo', res.orderNo)) : (CacheUtils.setLocItem('isFrom', 'sale'))
|
||||||
//清理计时器
|
//清理计时器
|
||||||
window.clearInterval(that.timeId)
|
window.clearInterval(that.timeId)
|
||||||
that.timeId = null
|
that.timeId = null
|
||||||
|
|||||||
@@ -53,7 +53,7 @@ import OccupationPicker from '@/components/ebiz/occipation/OccupationPicker'
|
|||||||
import CustomerPicker from '@/components/ebiz/customer/CustomerPicker'
|
import CustomerPicker from '@/components/ebiz/customer/CustomerPicker'
|
||||||
import DataDictionary from '@/assets/js/utils/data-dictionary'
|
import DataDictionary from '@/assets/js/utils/data-dictionary'
|
||||||
import areaList from '@/assets/js/utils/area'
|
import areaList from '@/assets/js/utils/area'
|
||||||
import { getTokenForAgent, agentInfowxSubmit } from '@/api/ebiz/agentEenter/agentEenter'
|
import { getTokenForAgent, agentInfowxSubmit, getTokenForUserModel } from '@/api/ebiz/agentEenter/agentEenter'
|
||||||
import utilsAge from '@/assets/js/utils/age'
|
import utilsAge from '@/assets/js/utils/age'
|
||||||
import getAreaName from '@/assets/js/utils/get-area-name'
|
import getAreaName from '@/assets/js/utils/get-area-name'
|
||||||
import IdentityCardScan from '@/components/ebiz/sale/IdentityCardScan'
|
import IdentityCardScan from '@/components/ebiz/sale/IdentityCardScan'
|
||||||
@@ -65,6 +65,7 @@ import axios from 'axios'
|
|||||||
import index from '@/config/index'
|
import index from '@/config/index'
|
||||||
import { getAuthCode } from '@/api/ebiz/sale/sale'
|
import { getAuthCode } from '@/api/ebiz/sale/sale'
|
||||||
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'insuredInfo',
|
name: 'insuredInfo',
|
||||||
components: {
|
components: {
|
||||||
@@ -152,27 +153,15 @@ export default {
|
|||||||
loadingType: 'spinner',
|
loadingType: 'spinner',
|
||||||
message: '加载中……'
|
message: '加载中……'
|
||||||
})
|
})
|
||||||
axios
|
getTokenForUserModel({
|
||||||
.get(index.apiDomain + `/agent/enter/getTokenForAgent`, {
|
token: this.$CacheUtils.getLocItem('token')
|
||||||
params: {
|
}).then(function(response) {
|
||||||
token: localStorage.token
|
|
||||||
},
|
|
||||||
headers: {
|
|
||||||
token: localStorage.token
|
|
||||||
}
|
|
||||||
})
|
|
||||||
.then(function(response) {
|
|
||||||
self.$toast.clear()
|
self.$toast.clear()
|
||||||
console.log('response', response)
|
console.log('response', response)
|
||||||
if (response.data.code == '0') {
|
if (response.result == '0') {
|
||||||
console.log('response.data.content', response.data.content)
|
self.recommender = response
|
||||||
if (response.data.content.result == '0') {
|
|
||||||
self.recommender = response.data.content
|
|
||||||
} else {
|
} else {
|
||||||
this.$toast.fail(response.data.content.resultMessage)
|
this.$toast.fail(response.resultMessage)
|
||||||
}
|
|
||||||
} else {
|
|
||||||
this.$toast.fail(response.data.message)
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.catch(function(error) {
|
.catch(function(error) {
|
||||||
|
|||||||
@@ -117,7 +117,7 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { List, Tab, Tabs, Tag, Row, Col, Dialog, Sticky } from 'vant'
|
import { List, Tab, Tabs, Tag, Row, Col, Dialog, Sticky } from 'vant'
|
||||||
import { progress } from '@/api/ebiz/claims/claims'
|
import { progress, deleteClaim } from '@/api/ebiz/claims/claims'
|
||||||
import axios from 'axios'
|
import axios from 'axios'
|
||||||
import index from '@/config/index'
|
import index from '@/config/index'
|
||||||
|
|
||||||
@@ -209,14 +209,8 @@ export default {
|
|||||||
cancelButtonColor: '#4FC6B3',
|
cancelButtonColor: '#4FC6B3',
|
||||||
confirmButtonColor: '#FFFFFF'
|
confirmButtonColor: '#FFFFFF'
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
axios
|
deleteClaim({
|
||||||
.get(index.apiDomain + `/claim/claimApply/delete`, {
|
|
||||||
params: {
|
|
||||||
businessNo: businessNo
|
businessNo: businessNo
|
||||||
},
|
|
||||||
headers: {
|
|
||||||
token: localStorage.token
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
.then(res => {
|
.then(res => {
|
||||||
let data = {
|
let data = {
|
||||||
|
|||||||
@@ -65,7 +65,7 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { Search, List, Tag, Row, Col } from 'vant'
|
import { Search, List, Tag, Row, Col } from 'vant'
|
||||||
import { history } from '@/api/ebiz/claims/claims'
|
import { history, historyDetail } from '@/api/ebiz/claims/claims'
|
||||||
// import { getPolicyList } from '@/api/ebiz/serve/serve'
|
// import { getPolicyList } from '@/api/ebiz/serve/serve'
|
||||||
import axios from 'axios'
|
import axios from 'axios'
|
||||||
import index from '@/config/index'
|
import index from '@/config/index'
|
||||||
@@ -140,14 +140,8 @@ export default {
|
|||||||
},
|
},
|
||||||
// 点击选择去被保人信息
|
// 点击选择去被保人信息
|
||||||
goToDetail(data) {
|
goToDetail(data) {
|
||||||
axios
|
historyDetail({
|
||||||
.get(index.apiDomain + `/claim/claimReport/historyDetail`, {
|
insuredNo: that.insuredNo
|
||||||
params: {
|
|
||||||
insuredNo: this.insuredNo
|
|
||||||
},
|
|
||||||
headers: {
|
|
||||||
token: localStorage.token
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
.then(res => {
|
.then(res => {
|
||||||
console.log(res)
|
console.log(res)
|
||||||
|
|||||||
@@ -37,8 +37,8 @@ export default {
|
|||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
//获取投保人信息
|
//获取投保人信息
|
||||||
if (localStorage.saleInsuredPersonInfo) {
|
if (this.$CacheUtils.getLocItem('saleInsuredPersonInfo')) {
|
||||||
this.saleInsuredPersonInfo = JSON.parse(localStorage.saleInsuredPersonInfo)
|
this.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
}
|
}
|
||||||
|
|
||||||
this.filterAddRisk()
|
this.filterAddRisk()
|
||||||
@@ -80,20 +80,20 @@ export default {
|
|||||||
let ruleExpression = localStorage.ruleExpression ? JSON.parse(localStorage.ruleExpression) : {}
|
let ruleExpression = localStorage.ruleExpression ? JSON.parse(localStorage.ruleExpression) : {}
|
||||||
ruleExpression[resultData.productCode] = resultData.productTrialInfoDTO.ruleExpression
|
ruleExpression[resultData.productCode] = resultData.productTrialInfoDTO.ruleExpression
|
||||||
localStorage.ruleExpression = JSON.stringify(ruleExpression)
|
localStorage.ruleExpression = JSON.stringify(ruleExpression)
|
||||||
|
let ttThis = this;
|
||||||
for (let item of ruleExpression[resultData.productCode]) {
|
for (let item of ruleExpression[resultData.productCode]) {
|
||||||
let config = JSON.parse(item.ruleExpression)
|
let config = JSON.parse(item.ruleExpression)
|
||||||
switch (config.eventType) {
|
switch (config.eventType) {
|
||||||
case 'loadFormat':
|
case 'loadFormat':
|
||||||
let initFn = new Function(...config.funPar, config.funBody.join(''))
|
let initFn = new Function(...config.funPar, config.funBody.join(''))
|
||||||
let str = initFn(resultData)
|
let str = initFn.call(ttThis,resultData)
|
||||||
if (str) {
|
if (str) {
|
||||||
return this.$toast(str)
|
return this.$toast(str)
|
||||||
}
|
}
|
||||||
break
|
break
|
||||||
case 'checkMainRisk':
|
case 'checkMainRisk':
|
||||||
let checkMainRiskFn = new Function(...config.funPar, config.funBody.join(''))
|
let checkMainRiskFn = new Function(...config.funPar, config.funBody.join(''))
|
||||||
let checkMainRiskStr = checkMainRiskFn()
|
let checkMainRiskStr = checkMainRiskFn.call(ttThis)
|
||||||
if (checkMainRiskStr) {
|
if (checkMainRiskStr) {
|
||||||
return this.$toast(checkMainRiskStr)
|
return this.$toast(checkMainRiskStr)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -403,12 +403,12 @@ export default {
|
|||||||
// 获取是否从建议书过来的
|
// 获取是否从建议书过来的
|
||||||
this.isFrom = localStorage.isFrom
|
this.isFrom = localStorage.isFrom
|
||||||
//获取投保人信息
|
//获取投保人信息
|
||||||
if (localStorage.saleInsuredInfo) {
|
if (this.$CacheUtils.getLocItem('saleInsuredInfo')) {
|
||||||
this.saleInsuredInfo = JSON.parse(localStorage.saleInsuredInfo)
|
this.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
}
|
}
|
||||||
//获取被保险人信息
|
//获取被保险人信息
|
||||||
if (localStorage.saleInsuredPersonInfo) {
|
if (this.$CacheUtils.getLocItem('saleInsuredPersonInfo')) {
|
||||||
this.saleInsuredPersonInfo = JSON.parse(localStorage.saleInsuredPersonInfo)
|
this.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
}
|
}
|
||||||
//构建提交数据、渲染险种
|
//构建提交数据、渲染险种
|
||||||
this.chooseProducts = JSON.parse(localStorage.chooseProducts)
|
this.chooseProducts = JSON.parse(localStorage.chooseProducts)
|
||||||
@@ -1324,7 +1324,7 @@ export default {
|
|||||||
occupationName,
|
occupationName,
|
||||||
platformType: 'app',
|
platformType: 'app',
|
||||||
productCode: item.productCode,
|
productCode: item.productCode,
|
||||||
medical: JSON.parse(localStorage.getItem('saleInsuredPersonInfo')).medical
|
medical: JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).medical
|
||||||
})
|
})
|
||||||
params.trialInfos.push(trialInfo)
|
params.trialInfos.push(trialInfo)
|
||||||
})
|
})
|
||||||
@@ -1647,7 +1647,7 @@ export default {
|
|||||||
//建议书
|
//建议书
|
||||||
if (localStorage.isFrom == 'proposal' && resultData.content.id) {
|
if (localStorage.isFrom == 'proposal' && resultData.content.id) {
|
||||||
this.saleInsuredPersonInfo.insuredId = resultData.content.id
|
this.saleInsuredPersonInfo.insuredId = resultData.content.id
|
||||||
localStorage.saleInsuredPersonInfo = JSON.stringify(this.saleInsuredPersonInfo)
|
this.$CacheUtils.setLocItem('saleInsuredPersonInfo', JSON.stringify(this.saleInsuredPersonInfo))
|
||||||
}
|
}
|
||||||
this.$jump({
|
this.$jump({
|
||||||
flag: 'goBack',
|
flag: 'goBack',
|
||||||
|
|||||||
@@ -201,7 +201,7 @@ export default {
|
|||||||
return this.$toast('抱歉,您没有该产品的销售权限!')
|
return this.$toast('抱歉,您没有该产品的销售权限!')
|
||||||
}
|
}
|
||||||
|
|
||||||
let flagCompany = await riskRules.checkCompany(resultData.productCode, JSON.parse(localStorage.saleInsuredInfo).workcompany, this)
|
let flagCompany = await riskRules.checkCompany(resultData.productCode, JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo')).workcompany, this)
|
||||||
if (flagCompany && localStorage.isFrom != 'proposal') {
|
if (flagCompany && localStorage.isFrom != 'proposal') {
|
||||||
//校验该投保人的工作单位是否能够投保该产品
|
//校验该投保人的工作单位是否能够投保该产品
|
||||||
return this.$toast('该投保人工作单位不能投保该产品')
|
return this.$toast('该投保人工作单位不能投保该产品')
|
||||||
|
|||||||
@@ -151,7 +151,7 @@ export default {
|
|||||||
let resultData
|
let resultData
|
||||||
let isProposal = localStorage.isFrom == 'proposal' ? true : false
|
let isProposal = localStorage.isFrom == 'proposal' ? true : false
|
||||||
if (isProposal) {
|
if (isProposal) {
|
||||||
let saleInsuredPersonInfo = localStorage.saleInsuredPersonInfo && JSON.parse(localStorage.saleInsuredPersonInfo)
|
let saleInsuredPersonInfo = this.$CacheUtils.getLocItem('saleInsuredPersonInfo') && JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
console.log(saleInsuredPersonInfo)
|
console.log(saleInsuredPersonInfo)
|
||||||
|
|
||||||
let insuredId
|
let insuredId
|
||||||
@@ -182,7 +182,7 @@ export default {
|
|||||||
if (resultData.result == 0) {
|
if (resultData.result == 0) {
|
||||||
let riskDTOLst
|
let riskDTOLst
|
||||||
if (isProposal) {
|
if (isProposal) {
|
||||||
localStorage.saleInsuredInfo = JSON.stringify(resultData.content[0].appntDTO) //存储投保人信息
|
this.$CacheUtils.setLocItem('saleInsuredInfo',JSON.stringify(resultData.content[0].appntDTO))//存储投保人信息
|
||||||
this.appntDTO = resultData.content[0].appntDTO
|
this.appntDTO = resultData.content[0].appntDTO
|
||||||
resultData = resultData.content[0]
|
resultData = resultData.content[0]
|
||||||
riskDTOLst = resultData.insuredDTOs && resultData.insuredDTOs[0] && resultData.insuredDTOs[0].riskDTOLst
|
riskDTOLst = resultData.insuredDTOs && resultData.insuredDTOs[0] && resultData.insuredDTOs[0].riskDTOLst
|
||||||
@@ -195,7 +195,7 @@ export default {
|
|||||||
//险种数据格式化
|
//险种数据格式化
|
||||||
riskDTOLst = resultData.orderDTO.insuredDTOs[0].riskDTOLst
|
riskDTOLst = resultData.orderDTO.insuredDTOs[0].riskDTOLst
|
||||||
}
|
}
|
||||||
localStorage.appntDTO = JSON.stringify(this.appntDTO)
|
this.$CacheUtils.setLocItem('appntDTO',JSON.stringify(this.appntDTO))
|
||||||
|
|
||||||
if (!riskDTOLst) riskDTOLst = []
|
if (!riskDTOLst) riskDTOLst = []
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
import { productCheck } from '@/api/ebiz/common/common'
|
import { productCheck } from '@/api/ebiz/common/common'
|
||||||
import { getCompany } from '@/api/ebiz/sale/sale'
|
import { getCompany } from '@/api/ebiz/sale/sale'
|
||||||
|
import CacheUtils from '@/assets/js/utils/cacheUtils'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
//投、被保险人年龄对险种的限制
|
//投、被保险人年龄对险种的限制
|
||||||
@@ -70,11 +71,11 @@ export default {
|
|||||||
},
|
},
|
||||||
//获取被保险人信息
|
//获取被保险人信息
|
||||||
getSaleInsuredPersonInfo() {
|
getSaleInsuredPersonInfo() {
|
||||||
return localStorage.saleInsuredPersonInfo && JSON.parse(localStorage.saleInsuredPersonInfo)
|
return CacheUtils.getLocItem('saleInsuredPersonInfo') && JSON.parse(CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
},
|
},
|
||||||
//获取投保人信息
|
//获取投保人信息
|
||||||
getSaleInsuredInfo() {
|
getSaleInsuredInfo() {
|
||||||
return localStorage.saleInsuredInfo && JSON.parse(localStorage.saleInsuredInfo)
|
return CacheUtils.getLocItem('saleInsuredInfo') && JSON.parse(CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
},
|
},
|
||||||
|
|
||||||
//获取产品售卖权限列表
|
//获取产品售卖权限列表
|
||||||
|
|||||||
@@ -84,21 +84,27 @@
|
|||||||
<li @click="close">取消</li>
|
<li @click="close">取消</li>
|
||||||
</ul>
|
</ul>
|
||||||
</van-popup>
|
</van-popup>
|
||||||
|
<check-agent @checModelSuccessMethod="initThisPage" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { Search, Cell, IndexBar, IndexAnchor, Popup, Button, Tag } from 'vant'
|
import { Search, Cell, IndexBar, IndexAnchor, Popup, Button, Tag, Dialog, Field } from 'vant'
|
||||||
import { getCustomersList } from '@/api/ebiz/customer/customer'
|
import { getCustomersList } from '@/api/ebiz/customer/customer'
|
||||||
|
import CheckAgent from '@/components/common/CheckAgent'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'login',
|
name: 'login',
|
||||||
components: {
|
components: {
|
||||||
|
[CheckAgent.name]: CheckAgent,
|
||||||
[Search.name]: Search,
|
[Search.name]: Search,
|
||||||
[Cell.name]: Cell,
|
[Cell.name]: Cell,
|
||||||
[IndexBar.name]: IndexBar,
|
[IndexBar.name]: IndexBar,
|
||||||
[IndexAnchor.name]: IndexAnchor,
|
[IndexAnchor.name]: IndexAnchor,
|
||||||
[Popup.name]: Popup,
|
[Popup.name]: Popup,
|
||||||
[Button.name]: Button,
|
[Button.name]: Button,
|
||||||
|
[Field.name]: Field,
|
||||||
|
[Dialog.name]: Dialog,
|
||||||
[Tag.name]: Tag
|
[Tag.name]: Tag
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
@@ -149,13 +155,7 @@ export default {
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {},
|
||||||
this.getCustomerList() //客户列表查询
|
|
||||||
setTimeout(() => {
|
|
||||||
this.filterBtn() // 初始化显示按钮
|
|
||||||
window.appCallBack = this.appCallBack //app回调
|
|
||||||
}, 1000)
|
|
||||||
},
|
|
||||||
filters: {
|
filters: {
|
||||||
toCustomer(value) {
|
toCustomer(value) {
|
||||||
if (value == 0) {
|
if (value == 0) {
|
||||||
@@ -166,6 +166,14 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
initThisPage(showFlag) {
|
||||||
|
console.log(showFlag)
|
||||||
|
setTimeout(() => {
|
||||||
|
this.filterBtn() // 初始化显示按钮
|
||||||
|
window.appCallBack = this.appCallBack //app回调
|
||||||
|
}, 1000)
|
||||||
|
this.getCustomerList() //客户列表查询
|
||||||
|
},
|
||||||
filterBtn() {
|
filterBtn() {
|
||||||
// 筛选按钮的显示
|
// 筛选按钮的显示
|
||||||
EWebBridge.webCallAppInJs('webview_right_button', {
|
EWebBridge.webCallAppInJs('webview_right_button', {
|
||||||
|
|||||||
@@ -25,6 +25,7 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { Tab, Tabs } from 'vant'
|
import { Tab, Tabs } from 'vant'
|
||||||
|
import { orgShortNames } from '@/assets/js/utils/orgShortName'
|
||||||
export default {
|
export default {
|
||||||
name: 'Organization',
|
name: 'Organization',
|
||||||
components: {
|
components: {
|
||||||
@@ -82,6 +83,13 @@ export default {
|
|||||||
return item
|
return item
|
||||||
})
|
})
|
||||||
this.values = data
|
this.values = data
|
||||||
|
for (let org of this.values) {
|
||||||
|
for (let shortName of orgShortNames) {
|
||||||
|
if (org.code === shortName.code) {
|
||||||
|
org.name = shortName.name
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
calculate() {
|
calculate() {
|
||||||
let allPrice = this.values.reduce((prevVal, currVal) => {
|
let allPrice = this.values.reduce((prevVal, currVal) => {
|
||||||
|
|||||||
@@ -132,9 +132,9 @@ export default {
|
|||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
showText: true,
|
showText: true,
|
||||||
YearColumns: ['2020', '2019'],
|
YearColumns: [],
|
||||||
minDate: new Date(2019, 0, 1),
|
minDate: new Date(2019, 0, 1),
|
||||||
maxDate: new Date(2020, 10, 1),
|
maxDate: new Date(),
|
||||||
currentMonthDate: new Date(),
|
currentMonthDate: new Date(),
|
||||||
currentYearDate: new Date(),
|
currentYearDate: new Date(),
|
||||||
currentDate: new Date(),
|
currentDate: new Date(),
|
||||||
@@ -271,7 +271,6 @@ export default {
|
|||||||
// 日
|
// 日
|
||||||
this.dateType = 'd'
|
this.dateType = 'd'
|
||||||
this.dateVal = this.dateFormat(this.currentDate)
|
this.dateVal = this.dateFormat(this.currentDate)
|
||||||
console.log(this.dateVal)
|
|
||||||
// 左侧时间实时赋值
|
// 左侧时间实时赋值
|
||||||
this.timeVal = this.dateVal
|
this.timeVal = this.dateVal
|
||||||
} else if (this.curTab == 2) {
|
} else if (this.curTab == 2) {
|
||||||
@@ -336,7 +335,6 @@ export default {
|
|||||||
branchOfficeApi(data)
|
branchOfficeApi(data)
|
||||||
.then(res => {
|
.then(res => {
|
||||||
if (res.result == 0) {
|
if (res.result == 0) {
|
||||||
console.log(res.content.list)
|
|
||||||
$this.tableData = res.content.list
|
$this.tableData = res.content.list
|
||||||
|
|
||||||
$this.ysjsTotal = 0
|
$this.ysjsTotal = 0
|
||||||
@@ -356,7 +354,6 @@ export default {
|
|||||||
$this.cbbfTotal = Number($this.cbbfTotal) + Number(val.cbbf)
|
$this.cbbfTotal = Number($this.cbbfTotal) + Number(val.cbbf)
|
||||||
$this.bzbfTotal = Number($this.bzbfTotal) + Number(val.bzbf)
|
$this.bzbfTotal = Number($this.bzbfTotal) + Number(val.bzbf)
|
||||||
})
|
})
|
||||||
console.log($this.tableData)
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.catch(err => {})
|
.catch(err => {})
|
||||||
@@ -379,6 +376,10 @@ export default {
|
|||||||
mounted() {
|
mounted() {
|
||||||
// this.timeVal=this.$route.query.timeVal||""
|
// this.timeVal=this.$route.query.timeVal||""
|
||||||
// this.showText=this.$route.query.showText
|
// this.showText=this.$route.query.showText
|
||||||
|
let currentYear = new Date().getFullYear()
|
||||||
|
for (let year = 2019; year <= currentYear; year++) {
|
||||||
|
this.YearColumns.unshift(year)
|
||||||
|
}
|
||||||
|
|
||||||
this.getCurrentDate()
|
this.getCurrentDate()
|
||||||
setInterval(this.getCurrentDate, 1000 * 60)
|
setInterval(this.getCurrentDate, 1000 * 60)
|
||||||
|
|||||||
@@ -4,20 +4,26 @@
|
|||||||
<van-cell-group>
|
<van-cell-group>
|
||||||
<NavItem v-for="(item, index) of navList" :key="index" :config="item" />
|
<NavItem v-for="(item, index) of navList" :key="index" :config="item" />
|
||||||
</van-cell-group>
|
</van-cell-group>
|
||||||
|
<check-agent @checModelSuccessMethod="initThisPage" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import UserInfoHeader from '@/components/ebiz/manpower/UserInfoHeader'
|
import UserInfoHeader from '@/components/ebiz/manpower/UserInfoHeader'
|
||||||
import NavItem from '@/components/ebiz/manpower/NavItem'
|
import NavItem from '@/components/ebiz/manpower/NavItem'
|
||||||
|
import { CellGroup, Cell, Button, Dialog, Field } from 'vant'
|
||||||
import { CellGroup } from 'vant'
|
import CheckAgent from '@/components/common/CheckAgent'
|
||||||
export default {
|
export default {
|
||||||
name: 'Navigation',
|
name: 'Navigation',
|
||||||
components: {
|
components: {
|
||||||
|
[CheckAgent.name]: CheckAgent,
|
||||||
[UserInfoHeader.name]: UserInfoHeader,
|
[UserInfoHeader.name]: UserInfoHeader,
|
||||||
[NavItem.name]: NavItem,
|
[NavItem.name]: NavItem,
|
||||||
[CellGroup.name]: CellGroup
|
[CellGroup.name]: CellGroup,
|
||||||
|
[Cell.name]: Cell,
|
||||||
|
[Button.name]: Button,
|
||||||
|
[Field.name]: Field,
|
||||||
|
[Dialog.name]: Dialog
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@@ -46,7 +52,12 @@ export default {
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {}
|
mounted() {},
|
||||||
|
methods: {
|
||||||
|
initThisPage(showFlag) {
|
||||||
|
console.log(showFlag)
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped></style>
|
<style lang="scss" scoped></style>
|
||||||
|
|||||||
@@ -4,6 +4,7 @@
|
|||||||
<van-cell-group>
|
<van-cell-group>
|
||||||
<NavItem v-for="(item, index) of navList" :key="index" :config="item" />
|
<NavItem v-for="(item, index) of navList" :key="index" :config="item" />
|
||||||
</van-cell-group>
|
</van-cell-group>
|
||||||
|
<check-agent @checModelSuccessMethod="initThisPage" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -11,16 +12,21 @@
|
|||||||
import UserInfoHeader from '@/components/ebiz/manpower/UserInfoHeader'
|
import UserInfoHeader from '@/components/ebiz/manpower/UserInfoHeader'
|
||||||
import NavItem from '@/components/ebiz/manpower/NavItem'
|
import NavItem from '@/components/ebiz/manpower/NavItem'
|
||||||
import record from '@/assets/images/u73803.png'
|
import record from '@/assets/images/u73803.png'
|
||||||
import { CellGroup } from 'vant'
|
import { CellGroup, Cell, Button, Dialog, Field } from 'vant'
|
||||||
|
|
||||||
import { getTokenForUserModel } from '@/api/ebiz/manpower/manpower'
|
import { getTokenForUserModel } from '@/api/ebiz/manpower/manpower'
|
||||||
|
import CheckAgent from '@/components/common/CheckAgent'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'Navigation',
|
name: 'Navigation',
|
||||||
components: {
|
components: {
|
||||||
|
[CheckAgent.name]: CheckAgent,
|
||||||
[UserInfoHeader.name]: UserInfoHeader,
|
[UserInfoHeader.name]: UserInfoHeader,
|
||||||
[NavItem.name]: NavItem,
|
[NavItem.name]: NavItem,
|
||||||
[CellGroup.name]: CellGroup
|
[CellGroup.name]: CellGroup,
|
||||||
|
[Cell.name]: Cell,
|
||||||
|
[Button.name]: Button,
|
||||||
|
[Field.name]: Field,
|
||||||
|
[Dialog.name]: Dialog
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@@ -47,8 +53,6 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.getInfo()
|
|
||||||
|
|
||||||
// 拦截原生按钮
|
// 拦截原生按钮
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
// eslint-disable-next-line no-undef
|
// eslint-disable-next-line no-undef
|
||||||
@@ -60,6 +64,10 @@ export default {
|
|||||||
window.appCallBack = this.appCallBack
|
window.appCallBack = this.appCallBack
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
initThisPage(showFlag) {
|
||||||
|
console.log(showFlag)
|
||||||
|
this.getInfo()
|
||||||
|
},
|
||||||
appCallBack(data) {
|
appCallBack(data) {
|
||||||
if (data.trigger == 'left_button_click') {
|
if (data.trigger == 'left_button_click') {
|
||||||
this.$jump({
|
this.$jump({
|
||||||
|
|||||||
241
src/views/ebiz/my/LogoutAgent.vue
Normal file
241
src/views/ebiz/my/LogoutAgent.vue
Normal file
@@ -0,0 +1,241 @@
|
|||||||
|
<template>
|
||||||
|
<div class="insured-info-container">
|
||||||
|
<van-cell-group>
|
||||||
|
<van-field
|
||||||
|
v-if="clickMobileDisabled"
|
||||||
|
:value="logoutDTO.mobile | dataMaskingMobile"
|
||||||
|
clearable
|
||||||
|
required
|
||||||
|
label="电话号码"
|
||||||
|
name="联系电话"
|
||||||
|
placeholder="请输入"
|
||||||
|
v-validate="'required|mobile'"
|
||||||
|
:disabled="true"
|
||||||
|
/>
|
||||||
|
<van-field
|
||||||
|
v-if="clickMobileDisabled"
|
||||||
|
v-model="logoutDTO.smsCode"
|
||||||
|
required
|
||||||
|
center
|
||||||
|
label="验证码"
|
||||||
|
clearable
|
||||||
|
placeholder="请输入短信验证码"
|
||||||
|
@input="validateNext"
|
||||||
|
>
|
||||||
|
<van-button type="danger" slot="button" size="small" @click="getCode" :disabled="codeDisabled" v-no-more-click="1000">
|
||||||
|
{{ codeDisabled ? `${countDown}s后重新获取` : '获取验证码' }}
|
||||||
|
</van-button>
|
||||||
|
</van-field>
|
||||||
|
<van-field v-model="logoutDTO.pwd" clearable required type="password" label="密码" name="密码" placeholder="请输入密码" @input="validateNext" />
|
||||||
|
<van-field
|
||||||
|
v-model="logoutDTO.confirmPwd"
|
||||||
|
clearable
|
||||||
|
required
|
||||||
|
type="password"
|
||||||
|
label="确认密码"
|
||||||
|
name="确认密码"
|
||||||
|
placeholder="请输入密码"
|
||||||
|
@input="validateNext"
|
||||||
|
/>
|
||||||
|
</van-cell-group>
|
||||||
|
<van-button type="danger" size="large" class="logout_button mt30" :disabled="checkNextDisabled" @click="logoutAgent">注销账户 </van-button>
|
||||||
|
|
||||||
|
<van-dialog v-model="show" title="提示" @confirm="logoutAgentInfo" show-cancel-button>
|
||||||
|
是否注销用户
|
||||||
|
</van-dialog>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import { Field, CellGroup, Popup, Picker, Checkbox, Area, Dialog } from 'vant'
|
||||||
|
import { getAgentInfo, logoutAgent } from '@/api/ebiz/my/my.js'
|
||||||
|
import { getAuthCode } from '@/api/ebiz/sale/sale'
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: 'logoutAgent',
|
||||||
|
components: {
|
||||||
|
[CellGroup.name]: CellGroup,
|
||||||
|
[Field.name]: Field,
|
||||||
|
[Popup.name]: Popup,
|
||||||
|
[Picker.name]: Picker,
|
||||||
|
[Checkbox.name]: Checkbox,
|
||||||
|
[Area.name]: Area,
|
||||||
|
[Dialog.name]: Dialog
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
logoutDTO: {
|
||||||
|
smsId: null,
|
||||||
|
smsCode: null,
|
||||||
|
mobile: null,
|
||||||
|
pwd: null,
|
||||||
|
confirmPwd: null
|
||||||
|
},
|
||||||
|
show: false,
|
||||||
|
timeId: null, // 计时器ID
|
||||||
|
countDown: 60, // 倒计时
|
||||||
|
codeDisabled: true, // 获取验证码按钮是否禁用
|
||||||
|
branchType: null,
|
||||||
|
checkNextDisabled: true, // 禁用修改
|
||||||
|
clickMobileDisabled: false // 手机号是否存在
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async mounted() {
|
||||||
|
this.codeDisabled = false
|
||||||
|
// 获取代理人信息
|
||||||
|
const res = await getAgentInfo({ '89': '890' })
|
||||||
|
if (res.result == 0) {
|
||||||
|
if (/^[0-9][0-9]*$/.test(res.branchType)) {
|
||||||
|
// 内勤 手机号格式正确
|
||||||
|
this.logoutDTO.mobile = res.phoneNo
|
||||||
|
this.codeDisabled = false
|
||||||
|
this.clickMobileDisabled = true
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
return this.$toast(res.resultMessage)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
if (this.$CacheUtils.getLocItem('businessNo') && this.$CacheUtils.getLocItem('claimsClear')) {
|
||||||
|
this.init()
|
||||||
|
this.$CacheUtils.getLocItem('claimsClear', '')
|
||||||
|
} else {
|
||||||
|
this.$CacheUtils.setLocItem('businessNo', '')
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
methods: {
|
||||||
|
init() {},
|
||||||
|
//获取验证码
|
||||||
|
getCode() {
|
||||||
|
if (!this.logoutDTO.mobile || this.logoutDTO.mobile == '') {
|
||||||
|
return this.$toast('代理人信息异常请联系管理员')
|
||||||
|
}
|
||||||
|
this.codeDisabled = true
|
||||||
|
let data = {
|
||||||
|
operateType: 'appntInfoEntry',
|
||||||
|
type: 'H5',
|
||||||
|
operateCode: this.logoutDTO.mobile,
|
||||||
|
system: 'agentApp',
|
||||||
|
operateCodeType: '0'
|
||||||
|
}
|
||||||
|
//获取验证码
|
||||||
|
getAuthCode(data).then(res => {
|
||||||
|
if (res.result == 0) {
|
||||||
|
this.logoutDTO.smsId = res.sessionId
|
||||||
|
this.logoutDTO.smsCode = null
|
||||||
|
//倒计时
|
||||||
|
this.timeId = setInterval(() => {
|
||||||
|
this.countDown--
|
||||||
|
if (this.countDown <= 0) {
|
||||||
|
window.clearInterval(this.timeId)
|
||||||
|
this.codeDisabled = false
|
||||||
|
this.countDown = 60
|
||||||
|
}
|
||||||
|
}, 1000)
|
||||||
|
} else {
|
||||||
|
this.$toast(res.resultMessage)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//操作下一步按钮状态
|
||||||
|
validateNext() {
|
||||||
|
if (this.clickMobileDisabled) {
|
||||||
|
if (!this.logoutDTO.smsCode || this.logoutDTO.smsCode == '') {
|
||||||
|
this.checkNextDisabled = true
|
||||||
|
return
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 2、判断密码是否一致
|
||||||
|
if (!this.logoutDTO.pwd || this.logoutDTO.pwd == '') {
|
||||||
|
this.checkNextDisabled = true
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (!this.logoutDTO.confirmPwd || this.logoutDTO.confirmPwd == '') {
|
||||||
|
this.checkNextDisabled = true
|
||||||
|
return
|
||||||
|
}
|
||||||
|
if (this.logoutDTO.pwd.length < 6 || this.logoutDTO.confirmPwd.length < 6) {
|
||||||
|
this.checkNextDisabled = true
|
||||||
|
return
|
||||||
|
}
|
||||||
|
this.checkNextDisabled = false
|
||||||
|
return
|
||||||
|
},
|
||||||
|
// 注销
|
||||||
|
logoutAgent() {
|
||||||
|
// 1、判断计时器
|
||||||
|
if (this.clickMobileDisabled) {
|
||||||
|
if (!this.codeDisabled) {
|
||||||
|
return this.$toast('请先获取验证码')
|
||||||
|
}
|
||||||
|
//
|
||||||
|
if (!this.logoutDTO.smsCode || this.logoutDTO.smsCode == '') {
|
||||||
|
return this.$toast('请输入短信验证码')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 2、判断密码是否一致
|
||||||
|
if (!this.logoutDTO.pwd || this.logoutDTO.pwd == '') {
|
||||||
|
return this.$toast('请输入密码')
|
||||||
|
}
|
||||||
|
if (!this.logoutDTO.confirmPwd || this.logoutDTO.confirmPwd == '') {
|
||||||
|
return this.$toast('请输入确认密码')
|
||||||
|
}
|
||||||
|
if (!(this.logoutDTO.pwd == this.logoutDTO.confirmPwd)) {
|
||||||
|
return this.$toast('两次输入密码不一致')
|
||||||
|
}
|
||||||
|
|
||||||
|
this.logoutAgentInfo()
|
||||||
|
},
|
||||||
|
logoutAgentInfo() {
|
||||||
|
let req = {
|
||||||
|
smsId: this.logoutDTO.smsId,
|
||||||
|
smsCode: this.logoutDTO.smsCode,
|
||||||
|
mobile: this.logoutDTO.mobile,
|
||||||
|
password: this.$MD5(this.logoutDTO.pwd),
|
||||||
|
confirmPwd: this.$MD5(this.logoutDTO.confirmPwd)
|
||||||
|
}
|
||||||
|
// 调用注销接口
|
||||||
|
logoutAgent(req).then(res => {
|
||||||
|
this.show = false
|
||||||
|
if (res.result == 0) {
|
||||||
|
this.$toast('用户注销成功')
|
||||||
|
// 跳转登陆页面
|
||||||
|
this.$CacheUtils.removeLocItem('token')
|
||||||
|
// eslint-disable-next-line no-undef
|
||||||
|
EWebBridge.webCallAppInJs('bridge', { flag: 'login' })
|
||||||
|
} else {
|
||||||
|
this.$toast(res.resultMessage)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.insured-info-container {
|
||||||
|
/deep/ .van-checkbox {
|
||||||
|
margin-left: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
/deep/ .van-radio {
|
||||||
|
margin-left: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
/deep/ .bankCard {
|
||||||
|
width: 120px;
|
||||||
|
height: 20px;
|
||||||
|
line-height: 20px;
|
||||||
|
border-radius: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.van-cell {
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.logout_button {
|
||||||
|
width: 80%;
|
||||||
|
margin-left: 10%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -5,7 +5,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { queryPrivacy } from '@/api/ebiz/my/my'
|
import { queryPrivacyNot } from '@/api/ebiz/my/my'
|
||||||
export default {
|
export default {
|
||||||
name: 'PrivacyPolicy',
|
name: 'PrivacyPolicy',
|
||||||
data() {
|
data() {
|
||||||
@@ -23,7 +23,7 @@ export default {
|
|||||||
methods: {
|
methods: {
|
||||||
//获取隐私条款内容
|
//获取隐私条款内容
|
||||||
getPrivacy() {
|
getPrivacy() {
|
||||||
queryPrivacy({
|
queryPrivacyNot({
|
||||||
type: 0
|
type: 0
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
if (res.result == '0') {
|
if (res.result == '0') {
|
||||||
|
|||||||
@@ -3,8 +3,8 @@
|
|||||||
<van-collapse v-model="activeNames" class="active">
|
<van-collapse v-model="activeNames" class="active">
|
||||||
<!-- <van-collapse-item name="1" class="pb10 pt10"> -->
|
<!-- <van-collapse-item name="1" class="pb10 pt10"> -->
|
||||||
<van-cell-group class="pl15 mt10">
|
<van-cell-group class="pl15 mt10">
|
||||||
<van-cell title="业务员工号" :value="userInfo.jobNo" />
|
<van-cell title="业务员工号" :value="userInfo.encryptionJobNo" />
|
||||||
<van-cell title="业务员姓名" :value="userInfo.name" />
|
<van-cell title="业务员姓名" :value="userInfo.encryptionName" />
|
||||||
<van-cell title="性别" :value="userInfo.sex === '1' ? '女' : '男'" />
|
<van-cell title="性别" :value="userInfo.sex === '1' ? '女' : '男'" />
|
||||||
<van-cell title="证件类型" :value="userInfo.cardType" />
|
<van-cell title="证件类型" :value="userInfo.cardType" />
|
||||||
<van-cell title="证件号码" :value="userInfo.cardNoStart" />
|
<van-cell title="证件号码" :value="userInfo.cardNoStart" />
|
||||||
|
|||||||
@@ -1,4 +1,6 @@
|
|||||||
// import utilsAge from '@/assets/js/utils/age'
|
// import utilsAge from '@/assets/js/utils/age'
|
||||||
|
import CacheUtils from '@/assets/js/utils/cacheUtils'
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @desc 扩展对象继承
|
* @desc 扩展对象继承
|
||||||
* @param {Object} out 一个或多个对象
|
* @param {Object} out 一个或多个对象
|
||||||
@@ -179,7 +181,7 @@ export default {
|
|||||||
* @return {*} rs
|
* @return {*} rs
|
||||||
*/
|
*/
|
||||||
getStorage(name) {
|
getStorage(name) {
|
||||||
return this._string2json(window.localStorage[name])
|
return this._string2json(CacheUtils.getLocItem(name))
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -187,7 +189,7 @@ export default {
|
|||||||
* @param {String} name 名称
|
* @param {String} name 名称
|
||||||
*/
|
*/
|
||||||
setStorage(name, value) {
|
setStorage(name, value) {
|
||||||
window.localStorage[name] = this._json2string(value)
|
CacheUtils.setLocItem(name,this._json2string(value))
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -195,7 +197,7 @@ export default {
|
|||||||
* @param {String} name 名称
|
* @param {String} name 名称
|
||||||
*/
|
*/
|
||||||
delStorage(name) {
|
delStorage(name) {
|
||||||
window.localStorage.removeItem(name)
|
CacheUtils.removeLocItem(name)
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -134,6 +134,7 @@ import product from '@/assets/images/goodStart/product.png'
|
|||||||
import { getAgentInfo } from '@/api/ebiz/my/my'
|
import { getAgentInfo } from '@/api/ebiz/my/my'
|
||||||
import { getCongratulationList } from '@/api/ebiz/congratulation/congratulation.js'
|
import { getCongratulationList } from '@/api/ebiz/congratulation/congratulation.js'
|
||||||
import dateUtil from '@/assets/js/utils/date-utils.js'
|
import dateUtil from '@/assets/js/utils/date-utils.js'
|
||||||
|
import { orgShortNames } from '@/assets/js/utils/orgShortName'
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
[Loading.name]: Loading
|
[Loading.name]: Loading
|
||||||
@@ -171,8 +172,22 @@ export default {
|
|||||||
let data = await getCongratulationList({ date: currMonth, queryType: 'm', type: 'kmh' })
|
let data = await getCongratulationList({ date: currMonth, queryType: 'm', type: 'kmh' })
|
||||||
if (this.isInner) {
|
if (this.isInner) {
|
||||||
this.organizationData = data.content
|
this.organizationData = data.content
|
||||||
|
for (let org of this.organizationData) {
|
||||||
|
for (let shortName of orgShortNames) {
|
||||||
|
if (org.code === shortName.code) {
|
||||||
|
org.name = shortName.name
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
this.performanceData = data.content.list
|
this.performanceData = data.content.list
|
||||||
|
for (let org of this.performanceData) {
|
||||||
|
for (let shortName of orgShortNames) {
|
||||||
|
if (org.code === shortName.code) {
|
||||||
|
org.name = shortName.name
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.isTableDataLoad = true
|
this.isTableDataLoad = true
|
||||||
|
|||||||
@@ -116,7 +116,7 @@ export default {
|
|||||||
if (res.result == '0') {
|
if (res.result == '0') {
|
||||||
this.chooseList = res.content[0].insuredDTOs
|
this.chooseList = res.content[0].insuredDTOs
|
||||||
console.log(res.content[0].appntDTO, 'zzz')
|
console.log(res.content[0].appntDTO, 'zzz')
|
||||||
localStorage.proposalAppnt = JSON.stringify(res.content[0].appntDTO)
|
this.$CacheUtils.setLocItem('proposalAppnt', JSON.stringify(res.content[0].appntDTO))
|
||||||
this.proposalInfo = res.content[0]
|
this.proposalInfo = res.content[0]
|
||||||
if (this.chooseList != null) {
|
if (this.chooseList != null) {
|
||||||
this.chooseList.forEach(v => {
|
this.chooseList.forEach(v => {
|
||||||
@@ -324,7 +324,7 @@ export default {
|
|||||||
relationToAppnt: person.relation,
|
relationToAppnt: person.relation,
|
||||||
relationName: person.relationName
|
relationName: person.relationName
|
||||||
}
|
}
|
||||||
localStorage.saleInsuredPersonInfo = JSON.stringify(saleInsuredPersonInfo) //存储被保险人信息
|
this.$CacheUtils.setLocItem('saleInsuredPersonInfo', JSON.stringify(saleInsuredPersonInfo)) //存储被保险人信息
|
||||||
localStorage.chooseProductCodes = '' //置空所选险种
|
localStorage.chooseProductCodes = '' //置空所选险种
|
||||||
|
|
||||||
this.$jump({
|
this.$jump({
|
||||||
@@ -341,7 +341,7 @@ export default {
|
|||||||
edit(item) {
|
edit(item) {
|
||||||
item.birthday = item.birthdayLabel
|
item.birthday = item.birthdayLabel
|
||||||
item.age = item.insuredAge
|
item.age = item.insuredAge
|
||||||
localStorage.saleInsuredPersonInfo = JSON.stringify(item) //存储被保险人信息
|
this.$CacheUtils.setLocItem('saleInsuredPersonInfo', JSON.stringify(item)) //存储被保险人信息
|
||||||
localStorage.isFrom = 'proposal'
|
localStorage.isFrom = 'proposal'
|
||||||
this.$jump({
|
this.$jump({
|
||||||
flag: 'h5',
|
flag: 'h5',
|
||||||
|
|||||||
@@ -146,14 +146,14 @@ export default {
|
|||||||
methods: {
|
methods: {
|
||||||
init() {
|
init() {
|
||||||
window.appCallBack = this.appCallBack
|
window.appCallBack = this.appCallBack
|
||||||
this.localInfo = JSON.parse(localStorage.saleInsuredPersonInfo)
|
this.localInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
let { relationToAppnt, relationName } = this.localInfo
|
let { relationToAppnt, relationName } = this.localInfo
|
||||||
this.insured.relationToAppnt = relationToAppnt
|
this.insured.relationToAppnt = relationToAppnt
|
||||||
this.insured.relationLabel = relationName
|
this.insured.relationLabel = relationName
|
||||||
if (this.insured.relationToAppnt == '1') {
|
if (this.insured.relationToAppnt == '1') {
|
||||||
//如果是投被同人 就将投保人信息存入被保险人信息
|
//如果是投被同人 就将投保人信息存入被保险人信息
|
||||||
this.disabled = true
|
this.disabled = true
|
||||||
this.insured = Object.assign(this.insured, JSON.parse(localStorage.proposalAppnt))
|
this.insured = Object.assign(this.insured, JSON.parse(this.$CacheUtils.getLocItem('proposalAppnt')))
|
||||||
this.insured.age = getAge.getAge(this.insured.birthday, new Date())
|
this.insured.age = getAge.getAge(this.insured.birthday, new Date())
|
||||||
this.insured.medical = localStorage.orderNoSocialSecurity === '1' ? '1' : '0'
|
this.insured.medical = localStorage.orderNoSocialSecurity === '1' ? '1' : '0'
|
||||||
}
|
}
|
||||||
@@ -237,7 +237,7 @@ export default {
|
|||||||
//localStorage.setItem('proposalMedical', this.insured.medical == '0' ? '1' : '0')
|
//localStorage.setItem('proposalMedical', this.insured.medical == '0' ? '1' : '0')
|
||||||
localStorage.proposalMedical = this.insured.medical == '0' ? '1' : '0'
|
localStorage.proposalMedical = this.insured.medical == '0' ? '1' : '0'
|
||||||
this.insured.age = String(this.insured.age)
|
this.insured.age = String(this.insured.age)
|
||||||
let cacheSex = JSON.parse(localStorage.proposalAppnt).sex
|
let cacheSex = JSON.parse(this.$CacheUtils.getLocItem('proposalAppnt')).sex
|
||||||
let localSex = this.insured.sex
|
let localSex = this.insured.sex
|
||||||
let relation = this.localInfo.relationToAppnt
|
let relation = this.localInfo.relationToAppnt
|
||||||
let resultSex = checkSex(cacheSex, localSex, relation)
|
let resultSex = checkSex(cacheSex, localSex, relation)
|
||||||
@@ -266,7 +266,7 @@ export default {
|
|||||||
if (fromSelect) {
|
if (fromSelect) {
|
||||||
//表示从产品列表返回
|
//表示从产品列表返回
|
||||||
//先进行比对 当前信息是否有更改 如果更改
|
//先进行比对 当前信息是否有更改 如果更改
|
||||||
let locaInsured = JSON.parse(localStorage.saleInsuredPersonInfo)
|
let locaInsured = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
let { name, sex, birthday, occupationCode, medical } = this.insured
|
let { name, sex, birthday, occupationCode, medical } = this.insured
|
||||||
if (
|
if (
|
||||||
locaInsured.name == name &&
|
locaInsured.name == name &&
|
||||||
@@ -313,9 +313,9 @@ export default {
|
|||||||
mainPath() {
|
mainPath() {
|
||||||
localStorage.isFrom = 'proposal'
|
localStorage.isFrom = 'proposal'
|
||||||
let insuredInfo = {}
|
let insuredInfo = {}
|
||||||
let cacheInfo = JSON.parse(localStorage.saleInsuredPersonInfo)
|
let cacheInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
insuredInfo = Object.assign(cacheInfo, this.insured)
|
insuredInfo = Object.assign(cacheInfo, this.insured)
|
||||||
localStorage.saleInsuredPersonInfo = JSON.stringify(insuredInfo)
|
this.$CacheUtils.setLocItem('saleInsuredPersonInfo', JSON.stringify(insuredInfo))
|
||||||
this.$jump({
|
this.$jump({
|
||||||
flag: 'h5',
|
flag: 'h5',
|
||||||
extra: {
|
extra: {
|
||||||
|
|||||||
@@ -77,6 +77,9 @@
|
|||||||
</div>
|
</div>
|
||||||
</van-list>
|
</van-list>
|
||||||
<van-button type="danger" @click="addProposal" class="bottom-btn fs16">点我新增</van-button>
|
<van-button type="danger" @click="addProposal" class="bottom-btn fs16">点我新增</van-button>
|
||||||
|
|
||||||
|
<check-agent @checModelSuccessMethod="initThisPage" />
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -85,10 +88,12 @@ import { Tabs, Tab, Tag, Dialog, List, Sticky, Toast } from 'vant'
|
|||||||
import { getList, toInsurance, deleteProposal } from '@/api/ebiz/proposal/proposal.js'
|
import { getList, toInsurance, deleteProposal } from '@/api/ebiz/proposal/proposal.js'
|
||||||
import { formatRiskList } from '@/assets/js/utils/formatRiskList.js'
|
import { formatRiskList } from '@/assets/js/utils/formatRiskList.js'
|
||||||
import riskRules from '../common/risk-rules.js'
|
import riskRules from '../common/risk-rules.js'
|
||||||
|
import CheckAgent from '@/components/common/CheckAgent'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'proposalList',
|
name: 'proposalList',
|
||||||
components: {
|
components: {
|
||||||
|
[CheckAgent.name]: CheckAgent,
|
||||||
[Tabs.name]: Tabs,
|
[Tabs.name]: Tabs,
|
||||||
[Tab.name]: Tab,
|
[Tab.name]: Tab,
|
||||||
[Tag.name]: Tag,
|
[Tag.name]: Tag,
|
||||||
@@ -109,8 +114,13 @@ export default {
|
|||||||
isSuccess: false
|
isSuccess: false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {},
|
||||||
// document.body.style.backgroundColor = '#F5F5F5'
|
mounted() {},
|
||||||
|
methods: {
|
||||||
|
initThisPage(showFlag) {
|
||||||
|
if (showFlag) {
|
||||||
|
return
|
||||||
|
}
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
// eslint-disable-next-line no-undef
|
// eslint-disable-next-line no-undef
|
||||||
EWebBridge.webCallAppInJs('webview_left_button', {
|
EWebBridge.webCallAppInJs('webview_left_button', {
|
||||||
@@ -118,11 +128,8 @@ export default {
|
|||||||
})
|
})
|
||||||
}, 100)
|
}, 100)
|
||||||
window.appCallBack = this.appCallBack
|
window.appCallBack = this.appCallBack
|
||||||
},
|
|
||||||
mounted() {
|
|
||||||
this.loadMore()
|
this.loadMore()
|
||||||
},
|
},
|
||||||
methods: {
|
|
||||||
appCallBack(data) {
|
appCallBack(data) {
|
||||||
if (data.trigger == 'left_button_click') {
|
if (data.trigger == 'left_button_click') {
|
||||||
this.$jump({
|
this.$jump({
|
||||||
|
|||||||
@@ -280,7 +280,7 @@ export default {
|
|||||||
this.filterData(dataDictionary.sex, 'sex', appntDTO)
|
this.filterData(dataDictionary.sex, 'sex', appntDTO)
|
||||||
this.filterData(dataDictionary.idType, 'idType', appntDTO)
|
this.filterData(dataDictionary.idType, 'idType', appntDTO)
|
||||||
that.appntDTO = appntDTO
|
that.appntDTO = appntDTO
|
||||||
window.localStorage.setItem('saleInsuredInfo', JSON.stringify(appntDTO))
|
this.$CacheUtils.setLocItem('saleInsuredInfo', JSON.stringify(appntDTO))
|
||||||
// 被保险人信息
|
// 被保险人信息
|
||||||
res.content.insuredDTOs.map(insured => {
|
res.content.insuredDTOs.map(insured => {
|
||||||
insured.riskDTOLst.map(risk => {
|
insured.riskDTOLst.map(risk => {
|
||||||
@@ -388,7 +388,7 @@ export default {
|
|||||||
window.localStorage.setItem('contNo', this.OrderInfoDTO.contNo)
|
window.localStorage.setItem('contNo', this.OrderInfoDTO.contNo)
|
||||||
window.localStorage.setItem('orderNo', this.OrderInfoDTO.orderNo)
|
window.localStorage.setItem('orderNo', this.OrderInfoDTO.orderNo)
|
||||||
window.localStorage.setItem('orderStatus', this.OrderInfoDTO.orderStatus)
|
window.localStorage.setItem('orderStatus', this.OrderInfoDTO.orderStatus)
|
||||||
window.localStorage.setItem('saleInsuredInfo', JSON.stringify(this.appntDTO))
|
this.$CacheUtils.setLocItem('saleInsuredInfo', JSON.stringify(this.appntDTO))
|
||||||
this.$jump({
|
this.$jump({
|
||||||
flag: 'h5',
|
flag: 'h5',
|
||||||
extra: {
|
extra: {
|
||||||
|
|||||||
@@ -540,17 +540,19 @@ export default {
|
|||||||
this.$toast(res.resultMessage)
|
this.$toast(res.resultMessage)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
let that = this
|
||||||
|
|
||||||
// 获取投被保险人是否同一个人
|
// 获取投被保险人是否同一个人
|
||||||
if (localStorage.saleInsuredPersonInfo) {
|
if (this.$CacheUtils.getLocItem('saleInsuredPersonInfo')) {
|
||||||
this.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
// 获取被保险人信息
|
// 获取被保险人信息
|
||||||
this.saleInsuredPersonInfo = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo'))
|
that.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
}
|
}
|
||||||
if (localStorage.saleInsuredInfo) {
|
if (this.$CacheUtils.getLocItem('saleInsuredInfo')) {
|
||||||
// 获取投保人信息
|
// 获取投保人信息
|
||||||
this.saleInsuredInfo = JSON.parse(window.localStorage.getItem('saleInsuredInfo'))
|
that.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
// 默认是投保人名字
|
// 默认是投保人名字
|
||||||
this.name = this.saleInsuredInfo.name
|
that.name = this.saleInsuredInfo.name
|
||||||
}
|
}
|
||||||
|
|
||||||
// 是否显示自动垫交
|
// 是否显示自动垫交
|
||||||
|
|||||||
@@ -346,7 +346,7 @@ export default {
|
|||||||
isInsured: false, //是投保人本人,
|
isInsured: false, //是投保人本人,
|
||||||
Insured: false, //投保人本人按钮是否置灰
|
Insured: false, //投保人本人按钮是否置灰
|
||||||
idLimit: false, //证件起止日期是否只读
|
idLimit: false, //证件起止日期是否只读
|
||||||
saleInsuredPersonInfo: JSON.parse(localStorage.saleInsuredPersonInfo) //被保人信息
|
saleInsuredPersonInfo: JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')) //被保人信息
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
@@ -682,7 +682,7 @@ export default {
|
|||||||
// 计算年龄
|
// 计算年龄
|
||||||
let age = utilsAge.getAge(this.userInfo.birthday, new Date())
|
let age = utilsAge.getAge(this.userInfo.birthday, new Date())
|
||||||
let relationToAppnt = this.saleInsuredPersonInfo.relationToAppnt
|
let relationToAppnt = this.saleInsuredPersonInfo.relationToAppnt
|
||||||
let insuredDetail = JSON.parse(localStorage.saleInsuredInfo)
|
let insuredDetail = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
// let insuredDetail = JSON.parse(localStorage.insuredDetail)
|
// let insuredDetail = JSON.parse(localStorage.insuredDetail)
|
||||||
// let relationToAppnt = localStorage.relationToAppnt
|
// let relationToAppnt = localStorage.relationToAppnt
|
||||||
// //被保人不是已婚
|
// //被保人不是已婚
|
||||||
@@ -733,7 +733,7 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
let insuredInfo = JSON.parse(localStorage.saleInsuredPersonInfo)
|
let insuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
// 受益人与被保险人关系为父母时,受益人年龄必须大于被保险人年龄
|
// 受益人与被保险人关系为父母时,受益人年龄必须大于被保险人年龄
|
||||||
if (this.userInfo.relationToInsured == '3') {
|
if (this.userInfo.relationToInsured == '3') {
|
||||||
if (age < insuredInfo.age) {
|
if (age < insuredInfo.age) {
|
||||||
@@ -964,7 +964,7 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
this.isInsured = true
|
this.isInsured = true
|
||||||
let insuredDetail = JSON.parse(localStorage.saleInsuredInfo)
|
let insuredDetail = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
this.userInfo.name = insuredDetail.name //姓名
|
this.userInfo.name = insuredDetail.name //姓名
|
||||||
this.nameLimit = Boolean(insuredDetail.name)
|
this.nameLimit = Boolean(insuredDetail.name)
|
||||||
this.userInfo.sex = insuredDetail.sex //性别
|
this.userInfo.sex = insuredDetail.sex //性别
|
||||||
|
|||||||
@@ -418,10 +418,10 @@ export default {
|
|||||||
}
|
}
|
||||||
let that = this
|
let that = this
|
||||||
// 投被保险人是否同人
|
// 投被保险人是否同人
|
||||||
if (localStorage.saleInsuredPersonInfo) {
|
if (this.$CacheUtils.getLocItem('saleInsuredPersonInfo')) {
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
// 获取被保险人信息
|
// 获取被保险人信息
|
||||||
that.saleInsuredPersonInfo = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo'))
|
that.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
}
|
}
|
||||||
// 获取订单号
|
// 获取订单号
|
||||||
that.orderNo = window.localStorage.getItem('orderNo')
|
that.orderNo = window.localStorage.getItem('orderNo')
|
||||||
@@ -431,8 +431,8 @@ export default {
|
|||||||
that.idType = DataDictionary.idType
|
that.idType = DataDictionary.idType
|
||||||
|
|
||||||
// 获取投保人信息
|
// 获取投保人信息
|
||||||
if (localStorage.saleInsuredInfo) {
|
if (this.$CacheUtils.getLocItem('saleInsuredInfo')) {
|
||||||
that.saleInsuredInfo = JSON.parse(window.localStorage.getItem('saleInsuredInfo'))
|
that.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
}
|
}
|
||||||
// document.body.style.backgroundColor = '#fff'
|
// document.body.style.backgroundColor = '#fff'
|
||||||
// 身份证正面
|
// 身份证正面
|
||||||
|
|||||||
@@ -84,16 +84,16 @@ export default {
|
|||||||
that.detailJump = window.localStorage.getItem('detailJump')
|
that.detailJump = window.localStorage.getItem('detailJump')
|
||||||
that.signVal = window.localStorage.getItem('sign-val')
|
that.signVal = window.localStorage.getItem('sign-val')
|
||||||
// 获取投保人信息
|
// 获取投保人信息
|
||||||
that.saleInsuredInfo = JSON.parse(window.localStorage.getItem('saleInsuredInfo'))
|
that.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
if (this.isWeixin) {
|
if (this.isWeixin) {
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this.detailJump != '1') {
|
if (this.detailJump != '1') {
|
||||||
// 投被保险人是否同人
|
// 投被保险人是否同人
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
// 获取被保险人信息
|
// 获取被保险人信息
|
||||||
// that.saleInsuredPersonInfo = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo'))
|
// that.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
}
|
}
|
||||||
// if (this.detailJump != '1') {
|
// if (this.detailJump != '1') {
|
||||||
// this.getOrderDetail()
|
// this.getOrderDetail()
|
||||||
|
|||||||
@@ -72,7 +72,7 @@ export default {
|
|||||||
// '&saleInsuredPersonInfo=' +
|
// '&saleInsuredPersonInfo=' +
|
||||||
// localStorage.saleInsuredPersonInfo +
|
// localStorage.saleInsuredPersonInfo +
|
||||||
// '&relationToAppnt=' +
|
// '&relationToAppnt=' +
|
||||||
// JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
// JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
},
|
},
|
||||||
routerInfo: {
|
routerInfo: {
|
||||||
path:
|
path:
|
||||||
@@ -81,11 +81,11 @@ export default {
|
|||||||
'&token=' +
|
'&token=' +
|
||||||
localStorage.token +
|
localStorage.token +
|
||||||
'&saleInsuredInfo=' +
|
'&saleInsuredInfo=' +
|
||||||
localStorage.saleInsuredInfo +
|
this.$CacheUtils.getLocItem('saleInsuredInfo') +
|
||||||
'&saleInsuredPersonInfo=' +
|
'&saleInsuredPersonInfo=' +
|
||||||
localStorage.saleInsuredPersonInfo +
|
this.$CacheUtils.getLocItem('saleInsuredPersonInfo') +
|
||||||
'&relationToAppnt=' +
|
'&relationToAppnt=' +
|
||||||
JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -97,7 +97,7 @@ export default {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
this.insuredPerson = JSON.parse(localStorage.saleInsuredPersonInfo).name
|
this.insuredPerson = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).name
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
@@ -163,7 +163,7 @@ export default {
|
|||||||
appntDTO: {},
|
appntDTO: {},
|
||||||
insuredDTOs: [
|
insuredDTOs: [
|
||||||
{
|
{
|
||||||
insuredId: JSON.parse(localStorage.saleInsuredPersonInfo).insuredId,
|
insuredId: JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).insuredId,
|
||||||
bnfDTOs: this.bnfFlag == '0' ? [] : this.beneficiaries
|
bnfDTOs: this.bnfFlag == '0' ? [] : this.beneficiaries
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
|||||||
@@ -84,16 +84,16 @@ export default {
|
|||||||
that.detailJump = window.localStorage.getItem('detailJump')
|
that.detailJump = window.localStorage.getItem('detailJump')
|
||||||
that.signVal = window.localStorage.getItem('sign-val')
|
that.signVal = window.localStorage.getItem('sign-val')
|
||||||
// 获取投保人信息
|
// 获取投保人信息
|
||||||
that.saleInsuredInfo = JSON.parse(window.localStorage.getItem('saleInsuredInfo'))
|
that.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
if (this.isWeixin) {
|
if (this.isWeixin) {
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this.detailJump != '1') {
|
if (this.detailJump != '1') {
|
||||||
// 投被保险人是否同人
|
// 投被保险人是否同人
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
// 获取被保险人信息
|
// 获取被保险人信息
|
||||||
// that.saleInsuredPersonInfo = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo'))
|
// that.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
}
|
}
|
||||||
// if (this.detailJump != '1') {
|
// if (this.detailJump != '1') {
|
||||||
// this.getOrderDetail()
|
// this.getOrderDetail()
|
||||||
|
|||||||
@@ -284,11 +284,11 @@ export default {
|
|||||||
'&token=' +
|
'&token=' +
|
||||||
localStorage.token +
|
localStorage.token +
|
||||||
'&saleInsuredInfo=' +
|
'&saleInsuredInfo=' +
|
||||||
localStorage.saleInsuredInfo +
|
this.$CacheUtils.getLocItem('saleInsuredInfo') +
|
||||||
'&saleInsuredPersonInfo=' +
|
'&saleInsuredPersonInfo=' +
|
||||||
localStorage.saleInsuredPersonInfo +
|
this.$CacheUtils.getLocItem('saleInsuredPersonInfo') +
|
||||||
'&relationToAppnt=' +
|
'&relationToAppnt=' +
|
||||||
JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt +
|
JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt +
|
||||||
'&signInvalid=' +
|
'&signInvalid=' +
|
||||||
sessionStorage.getItem('signInvalid') +
|
sessionStorage.getItem('signInvalid') +
|
||||||
'&airSign=1' +
|
'&airSign=1' +
|
||||||
|
|||||||
@@ -85,16 +85,16 @@ export default {
|
|||||||
that.detailJump = window.localStorage.getItem('detailJump')
|
that.detailJump = window.localStorage.getItem('detailJump')
|
||||||
that.signVal = window.localStorage.getItem('sign-val')
|
that.signVal = window.localStorage.getItem('sign-val')
|
||||||
// 获取投保人信息
|
// 获取投保人信息
|
||||||
that.saleInsuredInfo = JSON.parse(window.localStorage.getItem('saleInsuredInfo'))
|
that.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
if (this.isWeixin) {
|
if (this.isWeixin) {
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this.detailJump != '1') {
|
if (this.detailJump != '1') {
|
||||||
// 投被保险人是否同人
|
// 投被保险人是否同人
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
// 获取被保险人信息
|
// 获取被保险人信息
|
||||||
// that.saleInsuredPersonInfo = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo'))
|
// that.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
}
|
}
|
||||||
// if (this.detailJump != '1') {
|
// if (this.detailJump != '1') {
|
||||||
// this.getOrderDetail()
|
// this.getOrderDetail()
|
||||||
|
|||||||
@@ -579,7 +579,7 @@ export default {
|
|||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
localStorage.setItem('salePageFlag', this.salePageFlag)
|
localStorage.setItem('salePageFlag', this.salePageFlag)
|
||||||
localStorage.setItem('saleInsuredInfo', '')
|
this.$CacheUtils.setLocItem('saleInsuredInfo', '')
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
@@ -1199,11 +1199,11 @@ export default {
|
|||||||
//local 里面是否存有险种信息
|
//local 里面是否存有险种信息
|
||||||
let chooseProductCodes = localStorage.chooseProductCodes && JSON.parse(localStorage.chooseProductCodes)
|
let chooseProductCodes = localStorage.chooseProductCodes && JSON.parse(localStorage.chooseProductCodes)
|
||||||
// if (chooseProductCodes && chooseProductCodes.length) {
|
// if (chooseProductCodes && chooseProductCodes.length) {
|
||||||
if (localStorage.saleInsuredInfo) {
|
if (this.$CacheUtils.getLocItem('saleInsuredInfo')) {
|
||||||
console.log('haha')
|
console.log('haha')
|
||||||
//获取险种列表
|
//获取险种列表
|
||||||
//取出local中的投保人信息
|
//取出local中的投保人信息
|
||||||
let saleInsuredInfo = JSON.parse(localStorage.saleInsuredInfo)
|
let saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
//如果 姓名, 性别, 出生日期, 有无社保, 职业 ,婚姻情况,发生变化
|
//如果 姓名, 性别, 出生日期, 有无社保, 职业 ,婚姻情况,发生变化
|
||||||
if (this.userInfo.sex != saleInsuredInfo.sex || this.userInfo.birthday != saleInsuredInfo.birthday) {
|
if (this.userInfo.sex != saleInsuredInfo.sex || this.userInfo.birthday != saleInsuredInfo.birthday) {
|
||||||
console.log('hehe')
|
console.log('hehe')
|
||||||
|
|||||||
@@ -1208,14 +1208,14 @@ export default {
|
|||||||
// return this.$toast('亲,被保险人与投保人关系为配偶,投保人或被保险人婚姻状况必须为已婚哦~')
|
// return this.$toast('亲,被保险人与投保人关系为配偶,投保人或被保险人婚姻状况必须为已婚哦~')
|
||||||
// }
|
// }
|
||||||
let insuredSex = this.userInfo.sex
|
let insuredSex = this.userInfo.sex
|
||||||
let appntSex = JSON.parse(localStorage.saleInsuredInfo).sex
|
let appntSex = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo')).sex
|
||||||
//投被保险人性别相同
|
//投被保险人性别相同
|
||||||
if (insuredSex == appntSex) {
|
if (insuredSex == appntSex) {
|
||||||
return this.$toast('额~配偶关系性别不能相同哦~')
|
return this.$toast('额~配偶关系性别不能相同哦~')
|
||||||
}
|
}
|
||||||
} else if (this.userInfo.relationToAppnt == '4') {
|
} else if (this.userInfo.relationToAppnt == '4') {
|
||||||
//投被保人关系是子女
|
//投被保人关系是子女
|
||||||
if (age > JSON.parse(localStorage.saleInsuredInfo).age) {
|
if (age > JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo')).age) {
|
||||||
await this.$dialog.confirm({
|
await this.$dialog.confirm({
|
||||||
title: '提示',
|
title: '提示',
|
||||||
message: '亲,请确认被保险人与投保人关系哦~',
|
message: '亲,请确认被保险人与投保人关系哦~',
|
||||||
@@ -1225,7 +1225,7 @@ export default {
|
|||||||
}
|
}
|
||||||
} else if (this.userInfo.relationToAppnt == '3') {
|
} else if (this.userInfo.relationToAppnt == '3') {
|
||||||
//投被保人关系是父母
|
//投被保人关系是父母
|
||||||
if (age < JSON.parse(localStorage.saleInsuredInfo).age) {
|
if (age < JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo')).age) {
|
||||||
await this.$dialog.confirm({
|
await this.$dialog.confirm({
|
||||||
title: '提示',
|
title: '提示',
|
||||||
message: '亲,请确认被保险人与投保人关系哦~',
|
message: '亲,请确认被保险人与投保人关系哦~',
|
||||||
@@ -1448,10 +1448,10 @@ export default {
|
|||||||
infoUpdate() {
|
infoUpdate() {
|
||||||
//local 里面是否存有险种信息
|
//local 里面是否存有险种信息
|
||||||
let chooseProductCodes = localStorage.chooseProductCodesNew && JSON.parse(localStorage.chooseProductCodesNew)
|
let chooseProductCodes = localStorage.chooseProductCodesNew && JSON.parse(localStorage.chooseProductCodesNew)
|
||||||
if (localStorage.saleInsuredPersonInfo) {
|
if (this.$CacheUtils.getLocItem('saleInsuredPersonInfo')) {
|
||||||
//获取险种列表
|
//获取险种列表
|
||||||
//取出local中的被保险人信息
|
//取出local中的被保险人信息
|
||||||
let saleInsuredPersonInfo = JSON.parse(localStorage.saleInsuredPersonInfo)
|
let saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
//如果 性别, 出生日期, 有无社保, 职业 发生变化
|
//如果 性别, 出生日期, 有无社保, 职业 发生变化
|
||||||
console.log(this.userInfo, '这是userInfo')
|
console.log(this.userInfo, '这是userInfo')
|
||||||
console.log(saleInsuredPersonInfo, '这是saleInsuredPersonInfo')
|
console.log(saleInsuredPersonInfo, '这是saleInsuredPersonInfo')
|
||||||
|
|||||||
@@ -142,18 +142,24 @@
|
|||||||
</van-list>
|
</van-list>
|
||||||
|
|
||||||
<van-button type="danger" class="bottom-btn" @click="add" v-no-more-click="1000">点我新增</van-button>
|
<van-button type="danger" class="bottom-btn" @click="add" v-no-more-click="1000">点我新增</van-button>
|
||||||
|
|
||||||
|
<!-- 短信验证 -->
|
||||||
|
<check-agent @checModelSuccessMethod="initThisPage" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { Search, Tabs, Tab, List, Tag, Sticky, Toast, Dialog } from 'vant'
|
import { Search, Tabs, Tab, List, Tag, Sticky, Toast, Dialog, Field } from 'vant'
|
||||||
import { orderList, deleteOrderInfo, revokeOrder } from '@/api/ebiz/sale/sale'
|
import { orderList, deleteOrderInfo, revokeOrder } from '@/api/ebiz/sale/sale'
|
||||||
import { formatRiskList } from '@/assets/js/utils/formatRiskList.js'
|
import { formatRiskList } from '@/assets/js/utils/formatRiskList.js'
|
||||||
import dataDictionary from '@/assets/js/utils/data-dictionary' //根据数据字典找到用户等级
|
import dataDictionary from '@/assets/js/utils/data-dictionary' //根据数据字典找到用户等级
|
||||||
|
import CheckAgent from '@/components/common/CheckAgent'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'saleList',
|
name: 'saleList',
|
||||||
components: {
|
components: {
|
||||||
|
[CheckAgent.name]: CheckAgent,
|
||||||
|
[Field.name]: Field,
|
||||||
[Search.name]: Search,
|
[Search.name]: Search,
|
||||||
[Tabs.name]: Tabs,
|
[Tabs.name]: Tabs,
|
||||||
[Tab.name]: Tab,
|
[Tab.name]: Tab,
|
||||||
@@ -164,6 +170,7 @@ export default {
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
showFlag: true,
|
||||||
searchName: '',
|
searchName: '',
|
||||||
active: 'uncommit', //uncommit 表示未提交 commit表示已提交
|
active: 'uncommit', //uncommit 表示未提交 commit表示已提交
|
||||||
saleList: [],
|
saleList: [],
|
||||||
@@ -192,9 +199,15 @@ export default {
|
|||||||
})
|
})
|
||||||
}, 100)
|
}, 100)
|
||||||
window.appCallBack = this.appCallBack
|
window.appCallBack = this.appCallBack
|
||||||
this.loadMore()
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
initThisPage(showFlag) {
|
||||||
|
this.showFlag = showFlag
|
||||||
|
if (this.showFlag) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
this.loadMore()
|
||||||
|
},
|
||||||
appCallBack(data) {
|
appCallBack(data) {
|
||||||
if (data.trigger == 'left_button_click') {
|
if (data.trigger == 'left_button_click') {
|
||||||
this.$jump({
|
this.$jump({
|
||||||
@@ -204,6 +217,9 @@ export default {
|
|||||||
},
|
},
|
||||||
//分页用
|
//分页用
|
||||||
loadMore() {
|
loadMore() {
|
||||||
|
if (this.showFlag) {
|
||||||
|
return
|
||||||
|
}
|
||||||
let pageInfo = {
|
let pageInfo = {
|
||||||
pageNum: this.currentPage,
|
pageNum: this.currentPage,
|
||||||
pageSize: this.pageSize,
|
pageSize: this.pageSize,
|
||||||
|
|||||||
@@ -181,8 +181,8 @@ export default {
|
|||||||
console.log('this.is ====', this.isExistAdditionalRisk)
|
console.log('this.is ====', this.isExistAdditionalRisk)
|
||||||
this.relationToAppnt = res.orderDTO.insuredDTOs[0].relationToAppnt
|
this.relationToAppnt = res.orderDTO.insuredDTOs[0].relationToAppnt
|
||||||
this.$utils.intLocalStorage(res)
|
this.$utils.intLocalStorage(res)
|
||||||
this.saleInsuredInfo = JSON.parse(window.localStorage.getItem('saleInsuredInfo'))
|
this.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
this.saleInsuredPersonInfo = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo'))
|
this.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
//如果返回参数存在曾经提交的告知信息,获取曾经提交的告知信息
|
//如果返回参数存在曾经提交的告知信息,获取曾经提交的告知信息
|
||||||
let insuredFinanceImpartDTO = res.orderDTO.appntDTO.financeImpartDTO //投保人财务告知集合
|
let insuredFinanceImpartDTO = res.orderDTO.appntDTO.financeImpartDTO //投保人财务告知集合
|
||||||
let insuredImpartDTO = res.orderDTO.appntDTO.impartDTO //投保人健康告知集合
|
let insuredImpartDTO = res.orderDTO.appntDTO.impartDTO //投保人健康告知集合
|
||||||
|
|||||||
@@ -372,7 +372,7 @@ export default {
|
|||||||
if (this.$route.query.airSign) {
|
if (this.$route.query.airSign) {
|
||||||
sessionStorage.setItem('airSign', this.$route.query.airSign)
|
sessionStorage.setItem('airSign', this.$route.query.airSign)
|
||||||
}
|
}
|
||||||
// window.localStorage.setItem('saleInsuredInfo', this.$route.query.saleInsuredInfo)
|
// this.$CacheUtils.setLocItem('saleInsuredInfo', this.$route.query.saleInsuredInfo)
|
||||||
// window.localStorage.setItem('saleInsuredPersonInfo', this.$route.query.saleInsuredPersonInfo)
|
// window.localStorage.setItem('saleInsuredPersonInfo', this.$route.query.saleInsuredPersonInfo)
|
||||||
window.localStorage.setItem('token', this.$route.query.token)
|
window.localStorage.setItem('token', this.$route.query.token)
|
||||||
window.localStorage.setItem('orderNo', this.$route.query.orderNo)
|
window.localStorage.setItem('orderNo', this.$route.query.orderNo)
|
||||||
@@ -425,10 +425,10 @@ export default {
|
|||||||
|
|
||||||
if (sessionStorage.shareCode == '1') {
|
if (sessionStorage.shareCode == '1') {
|
||||||
console.log('进来被保险人')
|
console.log('进来被保险人')
|
||||||
this.tipsName = JSON.parse(localStorage.saleInsuredPersonInfo).name
|
this.tipsName = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).name
|
||||||
} else {
|
} else {
|
||||||
console.log('进来投保人')
|
console.log('进来投保人')
|
||||||
this.tipsName = JSON.parse(localStorage.saleInsuredInfo).name
|
this.tipsName = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo')).name
|
||||||
// console.log('localStorage.saleInsuredInfo', localStorage.saleInsuredInfo)
|
// console.log('localStorage.saleInsuredInfo', localStorage.saleInsuredInfo)
|
||||||
// console.log('localStorage.saleInsuredInfo.name', localStorage.saleInsuredInfo.name)
|
// console.log('localStorage.saleInsuredInfo.name', localStorage.saleInsuredInfo.name)
|
||||||
// console.log('this.tipName', this.tipsName)
|
// console.log('this.tipName', this.tipsName)
|
||||||
@@ -466,7 +466,7 @@ export default {
|
|||||||
let data = {}
|
let data = {}
|
||||||
this.authCode = null
|
this.authCode = null
|
||||||
if ('appnt' == this.operaFlag) {
|
if ('appnt' == this.operaFlag) {
|
||||||
let appntData = JSON.parse(localStorage.saleInsuredInfo)
|
let appntData = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
data = {
|
data = {
|
||||||
name: appntData.name,
|
name: appntData.name,
|
||||||
idType: appntData.idType,
|
idType: appntData.idType,
|
||||||
@@ -476,7 +476,7 @@ export default {
|
|||||||
this.customerMobile = appntData.mobile
|
this.customerMobile = appntData.mobile
|
||||||
this.encyCustomerMobile = this.customerMobile.replace(/^(\d{3})\d{4}(\d{4})$/, '$1****$2')
|
this.encyCustomerMobile = this.customerMobile.replace(/^(\d{3})\d{4}(\d{4})$/, '$1****$2')
|
||||||
} else if ('insured' == this.operaFlag) {
|
} else if ('insured' == this.operaFlag) {
|
||||||
let insuredData = JSON.parse(localStorage.saleInsuredPersonInfo)
|
let insuredData = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
data = {
|
data = {
|
||||||
name: insuredData.name,
|
name: insuredData.name,
|
||||||
idType: insuredData.idType,
|
idType: insuredData.idType,
|
||||||
@@ -578,15 +578,15 @@ export default {
|
|||||||
if (val == '0' || val == '2') {
|
if (val == '0' || val == '2') {
|
||||||
//idtype不为身份证跳过人脸识别
|
//idtype不为身份证跳过人脸识别
|
||||||
// if (JSON.parse(this.$route.query.saleInsuredInfo).idType != '1' || JSON.parse(this.$route.query.saleInsuredInfo).age < '18') {
|
// if (JSON.parse(this.$route.query.saleInsuredInfo).idType != '1' || JSON.parse(this.$route.query.saleInsuredInfo).age < '18') {
|
||||||
if (JSON.parse(localStorage.saleInsuredInfo).idType != '1') {
|
if (JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo')).idType != '1') {
|
||||||
that.goUrl()
|
that.goUrl()
|
||||||
} else {
|
} else {
|
||||||
if (this.faceAuthCount.appnt < this.smsAuthNum) {
|
if (this.faceAuthCount.appnt < this.smsAuthNum) {
|
||||||
// this.idcardData.typeface = !this.idcardData.typeface
|
// this.idcardData.typeface = !this.idcardData.typeface
|
||||||
// this.idcardData.idcardName = JSON.parse(this.$route.query.saleInsuredInfo).name
|
// this.idcardData.idcardName = JSON.parse(this.$route.query.saleInsuredInfo).name
|
||||||
// this.idcardData.idcardNumber = JSON.parse(this.$route.query.saleInsuredInfo).idNo
|
// this.idcardData.idcardNumber = JSON.parse(this.$route.query.saleInsuredInfo).idNo
|
||||||
this.idcardData.realName = JSON.parse(localStorage.saleInsuredInfo).name
|
this.idcardData.realName = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo')).name
|
||||||
this.idcardData.idno = JSON.parse(localStorage.saleInsuredInfo).idNo
|
this.idcardData.idno = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo')).idNo
|
||||||
this.recognition()
|
this.recognition()
|
||||||
} else {
|
} else {
|
||||||
this.operaFlag = 'appnt'
|
this.operaFlag = 'appnt'
|
||||||
@@ -596,7 +596,7 @@ export default {
|
|||||||
} else {
|
} else {
|
||||||
window.localStorage.setItem('sign-val', val)
|
window.localStorage.setItem('sign-val', val)
|
||||||
window.localStorage.setItem('sign-insured', JSON.stringify(that.insuredSign))
|
window.localStorage.setItem('sign-insured', JSON.stringify(that.insuredSign))
|
||||||
if (JSON.parse(localStorage.saleInsuredPersonInfo).idType != '1' || JSON.parse(localStorage.saleInsuredPersonInfo).age < '18') {
|
if (JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).idType != '1' || JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).age < '18') {
|
||||||
// if (JSON.parse(this.$route.query.saleInsuredPersonInfo).idType != '1') {
|
// if (JSON.parse(this.$route.query.saleInsuredPersonInfo).idType != '1') {
|
||||||
that.insuredUrl()
|
that.insuredUrl()
|
||||||
} else {
|
} else {
|
||||||
@@ -604,8 +604,8 @@ export default {
|
|||||||
// this.idcardData.typeface = !this.idcardData.typeface
|
// this.idcardData.typeface = !this.idcardData.typeface
|
||||||
// this.idcardData.idcardName = JSON.parse(this.$route.query.saleInsuredPersonInfo).name
|
// this.idcardData.idcardName = JSON.parse(this.$route.query.saleInsuredPersonInfo).name
|
||||||
// this.idcardData.idcardNumber = JSON.parse(this.$route.query.saleInsuredPersonInfo).idNo
|
// this.idcardData.idcardNumber = JSON.parse(this.$route.query.saleInsuredPersonInfo).idNo
|
||||||
this.idcardData.realName = JSON.parse(localStorage.saleInsuredPersonInfo).name
|
this.idcardData.realName = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).name
|
||||||
this.idcardData.idno = JSON.parse(localStorage.saleInsuredPersonInfo).idNo
|
this.idcardData.idno = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).idNo
|
||||||
this.recognition()
|
this.recognition()
|
||||||
} else {
|
} else {
|
||||||
this.operaFlag = 'insured'
|
this.operaFlag = 'insured'
|
||||||
@@ -766,11 +766,11 @@ export default {
|
|||||||
'&token=' +
|
'&token=' +
|
||||||
localStorage.token +
|
localStorage.token +
|
||||||
'&saleInsuredInfo=' +
|
'&saleInsuredInfo=' +
|
||||||
localStorage.saleInsuredInfo +
|
this.$CacheUtils.getLocItem('saleInsuredInfo') +
|
||||||
'&saleInsuredPersonInfo=' +
|
'&saleInsuredPersonInfo=' +
|
||||||
localStorage.saleInsuredPersonInfo +
|
this.$CacheUtils.getLocItem('saleInsuredPersonInfo') +
|
||||||
'&relationToAppnt=' +
|
'&relationToAppnt=' +
|
||||||
JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt +
|
JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt +
|
||||||
'&shareCode=' +
|
'&shareCode=' +
|
||||||
code +
|
code +
|
||||||
'&signInvalid=' +
|
'&signInvalid=' +
|
||||||
@@ -793,9 +793,9 @@ export default {
|
|||||||
// '&saleInsuredInfo=' +
|
// '&saleInsuredInfo=' +
|
||||||
// encodeURI(localStorage.saleInsuredInfo) +
|
// encodeURI(localStorage.saleInsuredInfo) +
|
||||||
// '&saleInsuredPersonInfo=' +
|
// '&saleInsuredPersonInfo=' +
|
||||||
// encodeURI(localStorage.saleInsuredPersonInfo) +
|
// encodeURI(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')) +
|
||||||
'&relationToAppnt=' +
|
'&relationToAppnt=' +
|
||||||
JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt +
|
JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt +
|
||||||
'&shareCode=' +
|
'&shareCode=' +
|
||||||
code +
|
code +
|
||||||
'&signInvalid=' +
|
'&signInvalid=' +
|
||||||
@@ -821,9 +821,9 @@ export default {
|
|||||||
// '&saleInsuredInfo=' +
|
// '&saleInsuredInfo=' +
|
||||||
// encodeURI(localStorage.saleInsuredInfo) +
|
// encodeURI(localStorage.saleInsuredInfo) +
|
||||||
// '&saleInsuredPersonInfo=' +
|
// '&saleInsuredPersonInfo=' +
|
||||||
// encodeURI(localStorage.saleInsuredPersonInfo) +
|
// encodeURI(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')) +
|
||||||
'&relationToAppnt=' +
|
'&relationToAppnt=' +
|
||||||
JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt +
|
JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt +
|
||||||
'&shareCode=' +
|
'&shareCode=' +
|
||||||
code +
|
code +
|
||||||
'&signInvalid=' +
|
'&signInvalid=' +
|
||||||
@@ -1045,9 +1045,9 @@ export default {
|
|||||||
this.$toast.clear()
|
this.$toast.clear()
|
||||||
this.$utils.intLocalStorage(res)
|
this.$utils.intLocalStorage(res)
|
||||||
// 获取被保险人信息recmd
|
// 获取被保险人信息recmd
|
||||||
this.saleInsuredPersonInfo = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo'))
|
this.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
// 获取投保人信息
|
// 获取投保人信息
|
||||||
this.saleInsuredInfo = JSON.parse(window.localStorage.getItem('saleInsuredInfo'))
|
this.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
this.relationToAppnt = this.saleInsuredPersonInfo.relationToAppnt //将缓存中的与被保险人关系赋值给页面
|
this.relationToAppnt = this.saleInsuredPersonInfo.relationToAppnt //将缓存中的与被保险人关系赋值给页面
|
||||||
|
|
||||||
that.recmd = res.orderDTO.recmdDTO
|
that.recmd = res.orderDTO.recmdDTO
|
||||||
@@ -1303,11 +1303,11 @@ export default {
|
|||||||
showCancelButton: false
|
showCancelButton: false
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
// 获取投被保险人是否同一个人
|
// 获取投被保险人是否同一个人
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
})
|
})
|
||||||
} else if (window.localStorage.getItem('jumpFromSign') == '1' || window.localStorage.getItem('attachmentShow') == '1') {
|
} else if (window.localStorage.getItem('jumpFromSign') == '1' || window.localStorage.getItem('attachmentShow') == '1') {
|
||||||
// 获取投被保险人是否同一个人
|
// 获取投被保险人是否同一个人
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
components: {
|
components: {
|
||||||
|
|||||||
@@ -313,8 +313,8 @@ export default {
|
|||||||
sessionStorage.setItem('airSign', this.$route.query.airSign)
|
sessionStorage.setItem('airSign', this.$route.query.airSign)
|
||||||
}
|
}
|
||||||
|
|
||||||
window.localStorage.setItem('saleInsuredInfo', this.$route.query.saleInsuredInfo)
|
this.$CacheUtils.setLocItem('saleInsuredInfo', this.$route.query.saleInsuredInfo)
|
||||||
window.localStorage.setItem('saleInsuredPersonInfo', this.$route.query.saleInsuredPersonInfo)
|
this.$CacheUtils.setLocItem('saleInsuredPersonInfo', this.$route.query.saleInsuredPersonInfo)
|
||||||
window.localStorage.setItem('token', this.$route.query.token)
|
window.localStorage.setItem('token', this.$route.query.token)
|
||||||
window.localStorage.setItem('orderNo', this.$route.query.orderNo)
|
window.localStorage.setItem('orderNo', this.$route.query.orderNo)
|
||||||
window.localStorage.setItem('relationToAppnt', this.$route.query.relationToAppnt)
|
window.localStorage.setItem('relationToAppnt', this.$route.query.relationToAppnt)
|
||||||
@@ -600,11 +600,11 @@ export default {
|
|||||||
'&token=' +
|
'&token=' +
|
||||||
localStorage.token +
|
localStorage.token +
|
||||||
'&saleInsuredInfo=' +
|
'&saleInsuredInfo=' +
|
||||||
localStorage.saleInsuredInfo +
|
this.$CacheUtils.getLocItem('saleInsuredInfo') +
|
||||||
'&saleInsuredPersonInfo=' +
|
'&saleInsuredPersonInfo=' +
|
||||||
localStorage.saleInsuredPersonInfo +
|
this.$CacheUtils.getLocItem('saleInsuredPersonInfo') +
|
||||||
'&relationToAppnt=' +
|
'&relationToAppnt=' +
|
||||||
JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt +
|
JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt +
|
||||||
'&shareCode=' +
|
'&shareCode=' +
|
||||||
code +
|
code +
|
||||||
'&signInvalid=' +
|
'&signInvalid=' +
|
||||||
@@ -622,11 +622,11 @@ export default {
|
|||||||
'&token=' +
|
'&token=' +
|
||||||
localStorage.token +
|
localStorage.token +
|
||||||
'&saleInsuredInfo=' +
|
'&saleInsuredInfo=' +
|
||||||
encodeURI(localStorage.saleInsuredInfo) +
|
encodeURI(this.$CacheUtils.getLocItem('saleInsuredInfo')) +
|
||||||
'&saleInsuredPersonInfo=' +
|
'&saleInsuredPersonInfo=' +
|
||||||
encodeURI(localStorage.saleInsuredPersonInfo) +
|
encodeURI(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')) +
|
||||||
'&relationToAppnt=' +
|
'&relationToAppnt=' +
|
||||||
JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt +
|
JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt +
|
||||||
'&shareCode=' +
|
'&shareCode=' +
|
||||||
code +
|
code +
|
||||||
'&signInvalid=' +
|
'&signInvalid=' +
|
||||||
@@ -752,9 +752,9 @@ export default {
|
|||||||
this.$toast.clear()
|
this.$toast.clear()
|
||||||
this.$utils.intLocalStorage(res)
|
this.$utils.intLocalStorage(res)
|
||||||
// 获取被保险人信息recmd
|
// 获取被保险人信息recmd
|
||||||
this.saleInsuredPersonInfo = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo'))
|
this.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
// 获取投保人信息
|
// 获取投保人信息
|
||||||
this.saleInsuredInfo = JSON.parse(window.localStorage.getItem('saleInsuredInfo'))
|
this.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
this.relationToAppnt = this.saleInsuredPersonInfo.relationToAppnt //将缓存中的与被保险人关系赋值给页面
|
this.relationToAppnt = this.saleInsuredPersonInfo.relationToAppnt //将缓存中的与被保险人关系赋值给页面
|
||||||
that.recmd = res.orderDTO.recmdDTO
|
that.recmd = res.orderDTO.recmdDTO
|
||||||
that.orderInfo = res.orderDTO.orderInfoDTO
|
that.orderInfo = res.orderDTO.orderInfoDTO
|
||||||
@@ -875,11 +875,11 @@ export default {
|
|||||||
showCancelButton: false
|
showCancelButton: false
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
// 获取投被保险人是否同一个人
|
// 获取投被保险人是否同一个人
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
})
|
})
|
||||||
} else if (window.localStorage.getItem('jumpFromSign') == '1' || window.localStorage.getItem('attachmentShow') == '1') {
|
} else if (window.localStorage.getItem('jumpFromSign') == '1' || window.localStorage.getItem('attachmentShow') == '1') {
|
||||||
// 获取投被保险人是否同一个人
|
// 获取投被保险人是否同一个人
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
components: {
|
components: {
|
||||||
|
|||||||
@@ -417,11 +417,11 @@ export default {
|
|||||||
'&token=' +
|
'&token=' +
|
||||||
localStorage.token +
|
localStorage.token +
|
||||||
'&saleInsuredInfo=' +
|
'&saleInsuredInfo=' +
|
||||||
localStorage.saleInsuredInfo +
|
this.$CacheUtils.getLocItem('saleInsuredInfo') +
|
||||||
'&saleInsuredPersonInfo=' +
|
'&saleInsuredPersonInfo=' +
|
||||||
localStorage.saleInsuredPersonInfo +
|
this.$CacheUtils.getLocItem('saleInsuredPersonInfo') +
|
||||||
'&relationToAppnt=' +
|
'&relationToAppnt=' +
|
||||||
JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt +
|
JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt +
|
||||||
'&attachmentShow=' +
|
'&attachmentShow=' +
|
||||||
window.localStorage.getItem('attachmentShow') +
|
window.localStorage.getItem('attachmentShow') +
|
||||||
'&signInvalid=' +
|
'&signInvalid=' +
|
||||||
@@ -488,11 +488,11 @@ export default {
|
|||||||
'&token=' +
|
'&token=' +
|
||||||
localStorage.token +
|
localStorage.token +
|
||||||
'&saleInsuredInfo=' +
|
'&saleInsuredInfo=' +
|
||||||
localStorage.saleInsuredInfo +
|
this.$CacheUtils.getLocItem('saleInsuredInfo') +
|
||||||
'&saleInsuredPersonInfo=' +
|
'&saleInsuredPersonInfo=' +
|
||||||
localStorage.saleInsuredPersonInfo +
|
this.$CacheUtils.getLocItem('saleInsuredPersonInfo') +
|
||||||
'&relationToAppnt=' +
|
'&relationToAppnt=' +
|
||||||
JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt +
|
JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt +
|
||||||
'&attachmentShow=' +
|
'&attachmentShow=' +
|
||||||
window.localStorage.getItem('attachmentShow') +
|
window.localStorage.getItem('attachmentShow') +
|
||||||
'&signInvalid=' +
|
'&signInvalid=' +
|
||||||
@@ -859,12 +859,12 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 获取投保人信息
|
// 获取投保人信息
|
||||||
that.saleInsuredInfo = JSON.parse(window.localStorage.getItem('saleInsuredInfo'))
|
that.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
// 在微信
|
// 在微信
|
||||||
if (this.isWeixin) {
|
if (this.isWeixin) {
|
||||||
// 在微信且不是回执签收
|
// 在微信且不是回执签收
|
||||||
if (this.detailJump != '1') {
|
if (this.detailJump != '1') {
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
let imgBase64Data = sessionStorage.getItem('imgBase64Data')
|
let imgBase64Data = sessionStorage.getItem('imgBase64Data')
|
||||||
let wxSigned = sessionStorage.getItem('wxSigned')
|
let wxSigned = sessionStorage.getItem('wxSigned')
|
||||||
let signInfo = JSON.parse(localStorage.getItem('signInfo'))
|
let signInfo = JSON.parse(localStorage.getItem('signInfo'))
|
||||||
@@ -941,9 +941,9 @@ export default {
|
|||||||
|
|
||||||
if (this.detailJump != '1') {
|
if (this.detailJump != '1') {
|
||||||
// 投被保险人是否同人
|
// 投被保险人是否同人
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
// 获取被保险人信息
|
// 获取被保险人信息
|
||||||
that.saleInsuredPersonInfo = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo'))
|
that.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
this.timeOut()
|
this.timeOut()
|
||||||
this.getOrderDetail()
|
this.getOrderDetail()
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -261,11 +261,11 @@ export default {
|
|||||||
'&token=' +
|
'&token=' +
|
||||||
localStorage.token +
|
localStorage.token +
|
||||||
'&saleInsuredInfo=' +
|
'&saleInsuredInfo=' +
|
||||||
localStorage.saleInsuredInfo +
|
this.$CacheUtils.getLocItem('saleInsuredInfo') +
|
||||||
'&saleInsuredPersonInfo=' +
|
'&saleInsuredPersonInfo=' +
|
||||||
localStorage.saleInsuredPersonInfo +
|
this.$CacheUtils.getLocItem('saleInsuredPersonInfo') +
|
||||||
'&relationToAppnt=' +
|
'&relationToAppnt=' +
|
||||||
JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt +
|
JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt +
|
||||||
'&attachmentShow=' +
|
'&attachmentShow=' +
|
||||||
window.localStorage.getItem('attachmentShow')
|
window.localStorage.getItem('attachmentShow')
|
||||||
}
|
}
|
||||||
@@ -326,11 +326,11 @@ export default {
|
|||||||
'&token=' +
|
'&token=' +
|
||||||
localStorage.token +
|
localStorage.token +
|
||||||
'&saleInsuredInfo=' +
|
'&saleInsuredInfo=' +
|
||||||
localStorage.saleInsuredInfo +
|
this.$CacheUtils.getLocItem('saleInsuredInfo') +
|
||||||
'&saleInsuredPersonInfo=' +
|
'&saleInsuredPersonInfo=' +
|
||||||
localStorage.saleInsuredPersonInfo +
|
this.$CacheUtils.getLocItem('saleInsuredPersonInfo') +
|
||||||
'&relationToAppnt=' +
|
'&relationToAppnt=' +
|
||||||
JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt +
|
JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt +
|
||||||
'&attachmentShow=' +
|
'&attachmentShow=' +
|
||||||
window.localStorage.getItem('attachmentShow')
|
window.localStorage.getItem('attachmentShow')
|
||||||
}
|
}
|
||||||
@@ -533,16 +533,16 @@ export default {
|
|||||||
that.signVal = window.localStorage.getItem('sign-val')
|
that.signVal = window.localStorage.getItem('sign-val')
|
||||||
|
|
||||||
// 获取投保人信息
|
// 获取投保人信息
|
||||||
that.saleInsuredInfo = JSON.parse(window.localStorage.getItem('saleInsuredInfo'))
|
that.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
if (this.isWeixin) {
|
if (this.isWeixin) {
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this.detailJump != '1') {
|
if (this.detailJump != '1') {
|
||||||
// 投被保险人是否同人
|
// 投被保险人是否同人
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
// 获取被保险人信息
|
// 获取被保险人信息
|
||||||
that.saleInsuredPersonInfo = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo'))
|
that.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
|
|||||||
@@ -88,16 +88,16 @@ export default {
|
|||||||
that.signVal = window.localStorage.getItem('sign-val')
|
that.signVal = window.localStorage.getItem('sign-val')
|
||||||
|
|
||||||
// 获取投保人信息
|
// 获取投保人信息
|
||||||
that.saleInsuredInfo = JSON.parse(window.localStorage.getItem('saleInsuredInfo'))
|
that.saleInsuredInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
if (this.isWeixin) {
|
if (this.isWeixin) {
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this.detailJump != '1') {
|
if (this.detailJump != '1') {
|
||||||
// 投被保险人是否同人
|
// 投被保险人是否同人
|
||||||
that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt
|
that.relationToAppnt = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo')).relationToAppnt
|
||||||
// 获取被保险人信息
|
// 获取被保险人信息
|
||||||
that.saleInsuredPersonInfo = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo'))
|
that.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
}
|
}
|
||||||
// if (this.detailJump != '1') {
|
// if (this.detailJump != '1') {
|
||||||
// this.getOrderDetail()
|
// this.getOrderDetail()
|
||||||
|
|||||||
@@ -81,7 +81,7 @@ export default {
|
|||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
if (this.isWeixin) {
|
if (this.isWeixin) {
|
||||||
window.localStorage.setItem('saleInsuredInfo', this.$route.query.saleInsuredInfo)
|
this.$CacheUtils.setLocItem('saleInsuredInfo', this.$route.query.saleInsuredInfo)
|
||||||
window.localStorage.setItem('token', this.$route.query.token)
|
window.localStorage.setItem('token', this.$route.query.token)
|
||||||
window.localStorage.setItem('policyNo', this.$route.query.policyNo)
|
window.localStorage.setItem('policyNo', this.$route.query.policyNo)
|
||||||
this.idcardData.idcardName = JSON.parse(this.$route.query.saleInsuredInfo).name
|
this.idcardData.idcardName = JSON.parse(this.$route.query.saleInsuredInfo).name
|
||||||
@@ -316,7 +316,7 @@ export default {
|
|||||||
window.localStorage.setItem('contNo', this.OrderInfoDTO.contNo)
|
window.localStorage.setItem('contNo', this.OrderInfoDTO.contNo)
|
||||||
window.localStorage.setItem('orderNo', this.OrderInfoDTO.orderNo)
|
window.localStorage.setItem('orderNo', this.OrderInfoDTO.orderNo)
|
||||||
window.localStorage.setItem('orderStatus', this.OrderInfoDTO.orderStatus)
|
window.localStorage.setItem('orderStatus', this.OrderInfoDTO.orderStatus)
|
||||||
window.localStorage.setItem('saleInsuredInfo', JSON.stringify(this.appntDTO))
|
this.$CacheUtils.setLocItem('saleInsuredInfo', JSON.stringify(this.appntDTO))
|
||||||
this.$jump({
|
this.$jump({
|
||||||
flag: 'h5',
|
flag: 'h5',
|
||||||
extra: {
|
extra: {
|
||||||
|
|||||||
@@ -276,7 +276,7 @@ export default {
|
|||||||
this.filterData(dataDictionary.sex, 'sex', appntDTO)
|
this.filterData(dataDictionary.sex, 'sex', appntDTO)
|
||||||
this.filterData(dataDictionary.idType, 'idType', appntDTO)
|
this.filterData(dataDictionary.idType, 'idType', appntDTO)
|
||||||
that.appntDTO = appntDTO
|
that.appntDTO = appntDTO
|
||||||
window.localStorage.setItem('saleInsuredInfo', JSON.stringify(appntDTO))
|
this.$CacheUtils.setLocItem('saleInsuredInfo', JSON.stringify(appntDTO))
|
||||||
// 被保险人信息
|
// 被保险人信息
|
||||||
res.content.insuredDTOs.map(insured => {
|
res.content.insuredDTOs.map(insured => {
|
||||||
insured.riskDTOLst.map(risk => {
|
insured.riskDTOLst.map(risk => {
|
||||||
@@ -333,7 +333,7 @@ export default {
|
|||||||
},
|
},
|
||||||
appCallBack(data) {
|
appCallBack(data) {
|
||||||
if (data.trigger == 'right_button_click') {
|
if (data.trigger == 'right_button_click') {
|
||||||
console.log(localStorage.saleInsuredInfo)
|
console.log(this.$CacheUtils.getLocItem('saleInsuredInfo'))
|
||||||
EWebBridge.webCallAppInJs('bridge', {
|
EWebBridge.webCallAppInJs('bridge', {
|
||||||
flag: 'share',
|
flag: 'share',
|
||||||
extra: {
|
extra: {
|
||||||
@@ -346,7 +346,7 @@ export default {
|
|||||||
'&token=' +
|
'&token=' +
|
||||||
localStorage.token +
|
localStorage.token +
|
||||||
'&saleInsuredInfo=' +
|
'&saleInsuredInfo=' +
|
||||||
encodeURI(localStorage.saleInsuredInfo),
|
encodeURI(this.$CacheUtils.getLocItem('saleInsuredInfo')),
|
||||||
// url: 'http://47.96.143.111/#/proposal/exhibition?proposalNo=' + localStorage.orderNo + '&token=' + localStorage.token,
|
// url: 'http://47.96.143.111/#/proposal/exhibition?proposalNo=' + localStorage.orderNo + '&token=' + localStorage.token,
|
||||||
img: this.$assetsUrl + 'images/logo.png'
|
img: this.$assetsUrl + 'images/logo.png'
|
||||||
}
|
}
|
||||||
@@ -407,7 +407,7 @@ export default {
|
|||||||
window.localStorage.setItem('contNo', this.OrderInfoDTO.contNo)
|
window.localStorage.setItem('contNo', this.OrderInfoDTO.contNo)
|
||||||
window.localStorage.setItem('orderNo', this.OrderInfoDTO.orderNo)
|
window.localStorage.setItem('orderNo', this.OrderInfoDTO.orderNo)
|
||||||
window.localStorage.setItem('orderStatus', this.OrderInfoDTO.orderStatus)
|
window.localStorage.setItem('orderStatus', this.OrderInfoDTO.orderStatus)
|
||||||
window.localStorage.setItem('saleInsuredInfo', JSON.stringify(this.appntDTO))
|
this.$CacheUtils.setLocItem('saleInsuredInfo', JSON.stringify(this.appntDTO))
|
||||||
this.$jump({
|
this.$jump({
|
||||||
flag: 'h5',
|
flag: 'h5',
|
||||||
extra: {
|
extra: {
|
||||||
|
|||||||
175
src/views/example/EncryotBack.vue
Normal file
175
src/views/example/EncryotBack.vue
Normal file
@@ -0,0 +1,175 @@
|
|||||||
|
<template>
|
||||||
|
<div class="insured-info-container">
|
||||||
|
<van-cell-group>
|
||||||
|
<van-field
|
||||||
|
v-model="logoutDTO.mobile"
|
||||||
|
clearable
|
||||||
|
required
|
||||||
|
label="电话号码"
|
||||||
|
name="联系电话"
|
||||||
|
placeholder="请输入"
|
||||||
|
v-validate="'required|mobile'"
|
||||||
|
:disabled="false"
|
||||||
|
/>
|
||||||
|
<van-field v-model="logoutDTO.smsCode" required center label="验证码" clearable placeholder="请输入短信验证码">
|
||||||
|
<van-button type="danger" slot="button" size="small" @click="getCode" :disabled="codeDisabled" v-no-more-click="1000">
|
||||||
|
{{ codeDisabled ? `${countDown}s后重新获取` : '获取验证码' }}
|
||||||
|
</van-button>
|
||||||
|
</van-field>
|
||||||
|
<van-field v-model="logoutDTO.pwd" clearable required type="password" label="密码" name="密码" placeholder="请输入密码" />
|
||||||
|
<van-field v-model="logoutDTO.confirmPwd" clearable required type="password" label="确认密码" name="确认密码" placeholder="请输入密码" />
|
||||||
|
</van-cell-group>
|
||||||
|
<van-button type="danger" size="large" class="logout_button mt30" @click="logoutAgent">注销账户</van-button>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import { Field, CellGroup, Popup, Picker, Checkbox, Area } from 'vant'
|
||||||
|
import { getAgentInfo } from '@/api/ebiz/my/my.js'
|
||||||
|
import { getAuthCode } from '@/api/ebiz/sale/sale'
|
||||||
|
import AESTools from '@/assets/js/utils/cryptoJsUtil'
|
||||||
|
export default {
|
||||||
|
name: 'logoutAgent',
|
||||||
|
components: {
|
||||||
|
[CellGroup.name]: CellGroup,
|
||||||
|
[Field.name]: Field,
|
||||||
|
[Popup.name]: Popup,
|
||||||
|
[Picker.name]: Picker,
|
||||||
|
[Checkbox.name]: Checkbox,
|
||||||
|
[Area.name]: Area
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
logoutDTO: {
|
||||||
|
smsId: null,
|
||||||
|
smsCode: null,
|
||||||
|
mobile: null,
|
||||||
|
pwd: null,
|
||||||
|
confirmPwd: null
|
||||||
|
},
|
||||||
|
timeId: null, // 计时器ID
|
||||||
|
countDown: 60, // 倒计时
|
||||||
|
codeDisabled: true, // 获取验证码按钮是否禁用
|
||||||
|
branchType: null
|
||||||
|
}
|
||||||
|
},
|
||||||
|
async mounted() {
|
||||||
|
// 获取代理人信息
|
||||||
|
this.$CacheUtils.setLocItem('cacheTest', JSON.stringify(this.logoutDTO))
|
||||||
|
console.log(this.$CacheUtils.getLocItem('cacheTest'))
|
||||||
|
this.$CacheUtils.setSessionItem('cacheTest1', 'nsjdfi')
|
||||||
|
console.log(this.$CacheUtils.getSessionItem('cacheTest1'))
|
||||||
|
const res = await getAgentInfo({ '89': '890' })
|
||||||
|
console.log(res)
|
||||||
|
if (res.result == 0) {
|
||||||
|
this.branchType = /^N{1}/.test(res.branchType) ? '1' : '0' //res.branchType 以N打头的是内勤 其他是外勤
|
||||||
|
if (this.branchType == '0') {
|
||||||
|
this.logoutDTO.mobile = res.phoneNo
|
||||||
|
this.codeDisabled = false
|
||||||
|
} else {
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
return this.$toast(res.resultMessage)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
if (this.$CacheUtils.getLocItem('businessNo') && this.$CacheUtils.getLocItem('claimsClear')) {
|
||||||
|
this.init()
|
||||||
|
this.$CacheUtils.setLocItem('claimsClear', '')
|
||||||
|
} else {
|
||||||
|
this.$CacheUtils.setLocItem('businessNo', '')
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
methods: {
|
||||||
|
init() {},
|
||||||
|
//获取验证码
|
||||||
|
getCode() {
|
||||||
|
if (this.reportMobile == '') {
|
||||||
|
return this.$toast('请填写联系电话')
|
||||||
|
}
|
||||||
|
this.codeDisabled = true
|
||||||
|
let data = {
|
||||||
|
operateType: 'appntInfoEntry',
|
||||||
|
type: 'H5',
|
||||||
|
operateCode: this.reportMobile,
|
||||||
|
system: 'agentApp',
|
||||||
|
operateCodeType: '0'
|
||||||
|
}
|
||||||
|
//获取验证码
|
||||||
|
getAuthCode(data).then(res => {
|
||||||
|
//倒计时
|
||||||
|
this.timeId = setInterval(() => {
|
||||||
|
this.countDown--
|
||||||
|
if (this.countDown <= 0) {
|
||||||
|
window.clearInterval(this.timeId)
|
||||||
|
this.codeDisabled = false
|
||||||
|
this.countDown = 60
|
||||||
|
}
|
||||||
|
}, 1000)
|
||||||
|
if (res.result == 0) {
|
||||||
|
this.logoutDTO.smsId = res.sessionId
|
||||||
|
this.logoutDTO.smsCode = null
|
||||||
|
} else {
|
||||||
|
this.$toast(res.resultMessage)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
// 注销
|
||||||
|
logoutAgent() {
|
||||||
|
let jj = AESTools.AESEncrypt('中国分红我都i阿萨79热9去 =-0987654321)(*&……%¥#@!·,》?》《?你啊', '41424344454631323334353637383930')
|
||||||
|
console.log('jj', jj)
|
||||||
|
let mm = AESTools.AESDecrypt(jj, '41424344454631323334353637383930')
|
||||||
|
console.log('mm', mm)
|
||||||
|
|
||||||
|
//console.log(this.$MD5(this.logoutDTO.pwd))
|
||||||
|
|
||||||
|
/* // 1、判断计时器
|
||||||
|
if(!codeDisabled){
|
||||||
|
return this.$toast('请先获取验证码')
|
||||||
|
}
|
||||||
|
//
|
||||||
|
if(!this.logoutDTO.smsCode || this.logoutDTO.pwd == ''){
|
||||||
|
return this.$toast('请输入短信验证码')
|
||||||
|
}
|
||||||
|
// 2、判断密码是否一致
|
||||||
|
if(!this.logoutDTO.pwd || this.logoutDTO.pwd == ''){
|
||||||
|
return this.$toast('请输入密码')
|
||||||
|
}
|
||||||
|
if(!this.logoutDTO.confirmPwd || this.logoutDTO.confirmPwd == ''){
|
||||||
|
return this.$toast('请输入确认密码')
|
||||||
|
}
|
||||||
|
if(!(this.logoutDTO.pwd == this.logoutDTO.confirmPwd)){
|
||||||
|
return this.$toast('两次输入密码不一致')
|
||||||
|
}
|
||||||
|
*/
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.insured-info-container {
|
||||||
|
/deep/ .van-checkbox {
|
||||||
|
margin-left: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
/deep/ .van-radio {
|
||||||
|
margin-left: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
/deep/ .bankCard {
|
||||||
|
width: 120px;
|
||||||
|
height: 20px;
|
||||||
|
line-height: 20px;
|
||||||
|
border-radius: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.van-cell {
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
.logout_button {
|
||||||
|
width: 80%;
|
||||||
|
margin-left: 10%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
Reference in New Issue
Block a user