Commit 6dc985aa authored by 5359's avatar 5359

添加功能模块

parent 699e94ab
...@@ -3,95 +3,56 @@ ...@@ -3,95 +3,56 @@
<h-content> <h-content>
<list-item class="personalInf" style="padding:20px;height:100%"> <list-item class="personalInf" style="padding:20px;height:100%">
<div style="height:40px;border-bottom:1px solid #d0d0d0"> <div style="height:40px;border-bottom:1px solid #d0d0d0">
<div <div class="personalInf-text" style=" width: 150px;line-height: 30px;text-align: center;
class="personalInf-text"
style=" width: 150px;line-height: 30px;text-align: center;
border-radius: 5px; border-radius: 5px;
background-color: #ddd;font-size:16px;font-weight:700;color:#11111187" background-color: #ddd;font-size:16px;font-weight:700;color:#11111187">签约信息
>签约信息
</div> </div>
</div> </div>
<item style="border-bottom:1px solid #d0d0d0;font-size:14px"> <item style="border-bottom:1px solid #d0d0d0;font-size:14px">
<section slot="name" style="font-size:14px"> <section slot="name" style="font-size:14px">
<img <img src="../../../assets/userRegister/bankIcon@2x.png"
src="../../../assets/userRegister/bankIcon@2x.png" style="float:left;width:20px;height:20px;margin: 2px 5px 0 0;">银行卡号:
style="float:left;width:20px;height:20px;margin: 2px 5px 0 0;"
/>银行卡号:
</section> </section>
<input <input slot="content" v-model="bankCardNumber" style="text-align: left;font-size:14px" placeholder="请输入银行卡号">
slot="content"
v-model="bankCardNumber"
style="text-align: left;font-size:14px"
placeholder="请输入银行卡号"
/>
</item> </item>
<item style="border-bottom:1px solid #d0d0d0"> <item style="border-bottom:1px solid #d0d0d0">
<section slot="name" style="font-size:14px"> <section slot="name" style="font-size:14px">
<img <img src="../../../assets/userRegister/people-name.png"
src="../../../assets/userRegister/people-name.png" style="float:left;width:20px;height:20px;margin: 2px 5px 0 0;">账户名称:
style="float:left;width:20px;height:20px;margin: 2px 5px 0 0;"
/>账户名称:
</section> </section>
<input <input slot="content" v-model="bankAccName" style="text-align: left;font-size:14px" placeholder="请输入账户名称">
slot="content"
v-model="bankAccName"
style="text-align: left;font-size:14px"
placeholder="请输入账户名称"
/>
</item> </item>
<item style="border-bottom:1px solid #d0d0d0"> <item style="border-bottom:1px solid #d0d0d0">
<section slot="name" style="font-size:14px"> <section slot="name" style="font-size:14px">
<img <img src="../../../assets/userRegister/idCard.png"
src="../../../assets/userRegister/idCard.png" style="float:left;width:20px;height:20px;margin: 2px 5px 0 0;">证件号码:
style="float:left;width:20px;height:20px;margin: 2px 5px 0 0;"
/>证件号码:
</section> </section>
<input <input slot="content" v-model="certNo" style="text-align: left;font-size:14px" placeholder="请输入证件号码"
slot="content" @blur="goTop()">
v-model="certNo"
style="text-align: left;font-size:14px"
placeholder="请输入证件号码"
@blur="goTop()"
/>
</item> </item>
<item style="border-bottom:1px solid #d0d0d0"> <item style="border-bottom:1px solid #d0d0d0">
<section slot="name" style="font-size:14px"> <section slot="name" style="font-size:14px">
<img <img src="../../../assets/userRegister/phone.png"
src="../../../assets/userRegister/phone.png" style="float:left;width:20px;height:20px;margin: 2px 5px 0 0;">预留手机:
style="float:left;width:20px;height:20px;margin: 2px 5px 0 0;"
/>预留手机:
</section> </section>
<input <input slot="content" v-model="phoneNumber" style="text-align: left;font-size:14px" placeholder="请输入电话号码"
slot="content" @blur="goTop()">
v-model="phoneNumber"
style="text-align: left;font-size:14px"
placeholder="请输入电话号码"
@blur="goTop()"
/>
</item> </item>
<item style="border-bottom:1px solid #d0d0d0"> <item style="border-bottom:1px solid #d0d0d0">
<section slot="name" style="font-size:14px"> <section slot="name" style="font-size:14px">
<img <img src="../../../assets/userRegister/indentifyCode.png"
src="../../../assets/userRegister/indentifyCode.png" style="float:left;width:20px;height:20px;margin: 2px 5px 0 0;">验证码:
style="float:left;width:20px;height:20px;margin: 2px 5px 0 0;"
/>验证码:
</section> </section>
<input <input slot="content" v-model="authCode" style="text-align: left;font-size:14px;margin-left: 0.13rem"
slot="content" placeholder="请输入验证码" @blur="goTop()">
v-model="authCode"
style="text-align: left;font-size:14px;margin-left: 0.13rem"
placeholder="请输入验证码"
@blur="goTop()"
/>
<div> <div>
<button v-if="!showTimer" <button v-if="!showTimer"
@click="getSignCode()" style="width:1.7rem;height:30px;border-radius:15px;background-color:#09bb07;color:#FFFFFF;margin:8px 0 0 -60px;position:relative;left:30%"
style="width:1.7rem;height:30px;border-radius:15px;background-color:#09bb07;color:#FFFFFF;margin:8px 0 0 -60px;position:relative;left:30%" @click="getSignCode()">
>
<div style="font-size: 11px">获取验证码</div> <div style="font-size: 11px">获取验证码</div>
</button> </button>
<button v-if="showTimer" <button v-if="showTimer"
style="width:1.7rem;height:30px;border-radius:15px;background-color:#888c8f;color:#FFFFFF;margin:8px 0 0 -60px;position:relative;left:30%"> style="width:1.7rem;height:30px;border-radius:15px;background-color:#888c8f;color:#FFFFFF;margin:8px 0 0 -60px;position:relative;left:30%">
<div style="font-size: 11px">{{ timerCount }}{{ text }}</div> <div style="font-size: 11px">{{ timerCount }}{{ text }}</div>
</button> </button>
</div> </div>
...@@ -103,9 +64,8 @@ ...@@ -103,9 +64,8 @@
</div> </div>
<div style="height:100px;margin-top:30px"> <div style="height:100px;margin-top:30px">
<div <div
style="border:1px solid #b2b2b2;width:70%;height:100%;margin:0 auto;border-radius:5px;position:relative;" style="border:1px solid #b2b2b2;width:70%;height:100%;margin:0 auto;border-radius:5px;position:relative;">
> <img :src="cardUp" alt class="pic" @click="addCardImage(0)">
<img :src="cardUp" alt class="pic" @click="addCardImage(0)"/>
</div> </div>
</div> </div>
<p style="margin-top:10px;text-align:center;font-size:14px"> <p style="margin-top:10px;text-align:center;font-size:14px">
...@@ -118,9 +78,8 @@ ...@@ -118,9 +78,8 @@
</div> </div>
<div style="height:100px;margin-top:30px"> <div style="height:100px;margin-top:30px">
<div <div
style="border:1px solid #b2b2b2;width:70%;height:100%;margin:0 auto;border-radius:5px;position:relative;" style="border:1px solid #b2b2b2;width:70%;height:100%;margin:0 auto;border-radius:5px;position:relative;">
> <img :src="cardUp1" alt class="pic" @click="addCardImage(1)">
<img :src="cardUp1" alt class="pic" @click="addCardImage(1)"/>
</div> </div>
</div> </div>
<p style="margin-top:10px;text-align:center;font-size:14px"> <p style="margin-top:10px;text-align:center;font-size:14px">
...@@ -129,342 +88,337 @@ ...@@ -129,342 +88,337 @@
</div> </div>
</div> </div>
<button <button
@click="next_step()"
style="width:120px;height:30px;border-radius:15px;background-color:#09bb07;color:#FFFFFF;margin:70px 0 0 -60px;position:relative;left:50%;" style="width:120px;height:30px;border-radius:15px;background-color:#09bb07;color:#FFFFFF;margin:70px 0 0 -60px;position:relative;left:50%;"
>签约 @click="next_step()">签约
</button> </button>
<p/> <p />
</list-item> </list-item>
</h-content> </h-content>
</h-view> </h-view>
</template> </template>
<script> <script>
import {getUrlParam} from "@/scripts/utils"; import { getUrlParam } from '@/scripts/utils'
export default { export default {
data() { components: {},
return { data () {
cardUp: require("../../../assets/userRegister/camear.png"), //身份证正面url return {
bankCardNumber: "", cardUp: require('../../../assets/userRegister/camear.png'), // 身份证正面url
bankAccName: "", bankCardNumber: '',
certNo: "", bankAccName: '',
phoneNumber: "", certNo: '',
authCode: "", phoneNumber: '',
phoneNumberFlag: false, authCode: '',
showTimer: false, phoneNumberFlag: false,
timerCount: 60, showTimer: false,
timer: 60000, timerCount: 60,
captchaKey: "", timer: 60000,
signId: "", captchaKey: '',
signStatus: 0, signId: '',
text: '秒后失效', signStatus: 0,
cardUp1: require("../../../assets/userRegister/camear.png"), //身份证正面url text: '秒后失效',
preview_url: "", //图片预览地址 cardUp1: require('../../../assets/userRegister/camear.png'), // 身份证正面url
attchmentId: "", //附件预览id preview_url: '', // 图片预览地址
attchmentId1: "" //附件预览id attchmentId: '', // 附件预览id
}; attchmentId1: '', // 附件预览id
}, }
components: {}, },
activated: function () { activated: function () {
// this.getUserInfo(); // this.getUserInfo();
}, },
updated: function () { updated: function () {
},
created () {
this.wxConfig()
// wx.hideOptionMenu();
// var data = this.$route.params.userInfo;
// this.getUserInfo();
},
methods: {
// 调用微信接口的基础配置
wxConfig () {
let clientUrl = ''
let u = navigator.userAgent
let isAndroid = u.indexOf('Android') > -1 || u.indexOf('Linux') > -1 // g
let isIOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/) // ios终端
if (isAndroid) {
// 这个是安卓操作系统
console.log('机型:android')
clientUrl = location.href
}
if (isIOS) {
// 这个是ios操作系统
console.log('机型:ios')
clientUrl = location.href.split('#')[0]
}
// let clientUrl = encodeURIComponent(location.href)
// let url = $config.rootPath + '/js/sdk/getWxConfig?wxCode=' + $config.wxCode + '&clientUrl=' + clientUrl
let url = process.env.basePathRl + 'getSignature'
let param = {
apiKey: 'handexinxi',
url: clientUrl,
}
hlsHttp.post(url, param).then(function (res) {
wx.config({
beta: true,
debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来,若要查看传入的参数,可以在pc端打开,参数信息会通过log打出,仅在pc端时才会打印。
appId: res.result.appId, // 必填,公众号的唯一标识
timestamp: res.result.timestamp, // 必填,生成签名的时间戳
nonceStr: res.result.nonceStr, // 必填,生成签名的随机串
signature: res.result.signature, // 必填,签名,见附录1
jsApiList: [
'chooseImage',
'previewImage',
'downloadImage',
'getLocalImgData',
'uploadImage',
'hideOptionMenu',
], // 必填,需要使用的JS接口列表,所有JS接口列表见附录2
})
wx.ready(function () {
wx.hideOptionMenu()
})
})
}, },
methods: { addCardImage: function (cardType) {
// 调用微信接口的基础配置 let self = this
wxConfig() { // if(!self.cardUp){
let clientUrl = ""; wx.chooseImage({
let u = navigator.userAgent; count: 1, // 张数, 默认9
let isAndroid = u.indexOf("Android") > -1 || u.indexOf("Linux") > -1; //g sizeType: ['compressed'], // 建议压缩图
let isIOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/); //ios终端 sourceType: ['album', 'camera'], // 来源是相册、相机
if (isAndroid) { success: function (res) {
//这个是安卓操作系统 if (cardType == 0) {
console.log("机型:android"); self.cardUp = res.localIds[0]
clientUrl = location.href; } else {
} self.cardUp1 = res.localIds[0]
if (isIOS) {
//这个是ios操作系统
console.log("机型:ios");
clientUrl = location.href.split("#")[0];
}
// let clientUrl = encodeURIComponent(location.href)
// let url = $config.rootPath + '/js/sdk/getWxConfig?wxCode=' + $config.wxCode + '&clientUrl=' + clientUrl
let url = process.env.basePathRl + "getSignature";
let param = {
apiKey: "handexinxi",
url: clientUrl
};
hlsHttp.post(url, param).then(function (res) {
wx.config({
beta: true,
debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来,若要查看传入的参数,可以在pc端打开,参数信息会通过log打出,仅在pc端时才会打印。
appId: res.result.appId, // 必填,公众号的唯一标识
timestamp: res.result.timestamp, // 必填,生成签名的时间戳
nonceStr: res.result.nonceStr, // 必填,生成签名的随机串
signature: res.result.signature, // 必填,签名,见附录1
jsApiList: [
"chooseImage",
"previewImage",
"downloadImage",
"getLocalImgData",
"uploadImage",
"hideOptionMenu"
] // 必填,需要使用的JS接口列表,所有JS接口列表见附录2
});
wx.ready(function () {
wx.hideOptionMenu();
});
});
},
addCardImage: function (cardType) {
let self = this;
// if(!self.cardUp){
wx.chooseImage({
count: 1, //张数, 默认9
sizeType: ["compressed"], //建议压缩图
sourceType: ["album", "camera"], // 来源是相册、相机
success: function (res) {
if (cardType == 0) {
self.cardUp = res.localIds[0];
} else {
self.cardUp1 = res.localIds[0];
}
self.uploadToWeixinServer(res.localIds[0], cardType);
} }
}); self.uploadToWeixinServer(res.localIds[0], cardType)
// }else{ },
// if(self.attchmentId){ })
// this.previewImage(); // }else{
// } // if(self.attchmentId){
// this.previewImage();
// }
// } // }
}, },
//预览图片 // 预览图片
previewImage() { previewImage () {
hlsPopup.showBigPicture({ hlsPopup.showBigPicture({
imgUrl: vm.cardUp, imgUrl: vm.cardUp,
imgUrl1: vm.cardUp1 imgUrl1: vm.cardUp1,
}); })
}, },
uploadToWeixinServer(localId, cardType) { uploadToWeixinServer (localId, cardType) {
let self = this; let self = this
wx.uploadImage({ wx.uploadImage({
localId: localId, localId: localId,
isShowProgressTips: 1, // 默认为1,显示进度提示 isShowProgressTips: 1, // 默认为1,显示进度提示
success: function (res) { success: function (res) {
//res.serverId 返回图片的微信服务器端ID // res.serverId 返回图片的微信服务器端ID
console.log("上传图片后返回的信息", res); console.log('上传图片后返回的信息', res)
self.serverId = res.serverId; self.serverId = res.serverId
self.uploadToserver(res.serverId, cardType); self.uploadToserver(res.serverId, cardType)
} },
}); })
}, },
uploadToserver(serverId, cardType) { uploadToserver (serverId, cardType) {
let vm = this; let vm = this
let url = process.env.rootPath + "/auth/upload/image/hls/from/wx"; let url = process.env.rootPath + '/auth/upload/image/hls/from/wx'
let sourceType = ""; let sourceType = ''
if (cardType == 0) {
sourceType = 'app_file_id_bank'
} else {
sourceType = 'app_file_id_card'
}
let param = {
openId: window.localStorage.openId,
mediaId: serverId,
sourceType: sourceType,
fileName: new Date().getTime() + '.jpg',
}
vm.hlsPopup.showLoading('请稍等')
vm.$post(url, param).then(function (res) {
vm.hlsPopup.hideLoading()
vm.attchmentId = res['attchmentId']
if (cardType == 0) { if (cardType == 0) {
sourceType = "app_file_id_bank"; vm.bankCardNumber = res['bank_card_number']
vm.cardUp =
process.env.rootPath +
'/app/fileViewSvc?attachment_id=' +
vm.attchmentId +
'&apiName=download&sysName=HCL_UPLOAD_FILE&access_token=' +
window.localStorage.access_token_rl
} else { } else {
sourceType = "app_file_id_card"; vm.bankAccName = res['姓名']
vm.certNo = res['公民身份号码']
vm.cardUp1 =
process.env.rootPath +
'/app/fileViewSvc?attachment_id=' +
vm.attchmentId +
'&apiName=download&sysName=HCL_UPLOAD_FILE&access_token=' +
window.localStorage.access_token_rl
} }
})
},
// 下一步
next_step () {
let vm = this
if (
!vm.bankCardNumber ||
!vm.bankAccName ||
!vm.phoneNumber ||
!vm.certNo ||
!vm.authCode
) {
vm.hlsPopup.showLongCenter('必输字端不能为空!')
} else if (vm.hlsUtil.isCardID(vm.certNo)) {
vm.hlsPopup.showLongCenter('身份证号有误')
} else if (!vm.hlsUtil.phoneNumber(vm.phoneNumber)) {
vm.hlsPopup.showLongCenter('手机号码有误!')
} else {
// alert("验证通过");
let url = process.env.rootPath + '/china/pay/send/sign'
let param = { let param = {
openId: window.localStorage.openId, signId: vm.signId,
mediaId: serverId, auth_code: vm.authCode,
sourceType: sourceType, }
fileName: new Date().getTime() + ".jpg" vm.hlsPopup.showLoading('请稍等')
};
vm.hlsPopup.showLoading("请稍等");
vm.$post(url, param).then(function (res) { vm.$post(url, param).then(function (res) {
vm.hlsPopup.hideLoading(); vm.hlsPopup.hideLoading()
vm.attchmentId = res["attchmentId"]; if (res.respCode == '0000') {
if (cardType == 0) { vm.hlsPopup.showSuccess(res.respMsg)
vm.bankCardNumber = res["bank_card_number"];
vm.cardUp =
process.env.rootPath +
"/app/fileViewSvc?attachment_id=" +
vm.attchmentId +
"&apiName=download&sysName=HCL_UPLOAD_FILE&access_token=" +
window.localStorage.access_token_rl;
} else { } else {
vm.bankAccName = res["姓名"]; vm.hlsPopup.showLongCenter(res.respMsg)
vm.certNo = res["公民身份号码"];
vm.cardUp1 =
process.env.rootPath +
"/app/fileViewSvc?attachment_id=" +
vm.attchmentId +
"&apiName=download&sysName=HCL_UPLOAD_FILE&access_token=" +
window.localStorage.access_token_rl;
} }
})
}
},
}); // 键盘消失,页面回到顶部
}, goTop () {
// 下一步 setTimeout(function () {
next_step() { var scrollHeight =
let vm = this; document.documentElement.scrollTop || document.body.scrollTop || 0
console.log(scrollHeight)
window.scrollTo(0, Math.max(scrollHeight, 0))
}, 100)
},
// 获取验证码
getSignCode () {
let vm = this
if (!vm.bankCardNumber) {
vm.hlsPopup.showLongCenter('请输入银行卡号!')
return
}
if (!vm.bankAccName) {
vm.hlsPopup.showLongCenter('请输入账户名称!')
return
}
if (!vm.certNo) {
vm.hlsPopup.showLongCenter('请输入证件号码!')
return
}
if (!vm.phoneNumber) {
vm.hlsPopup.showLongCenter('请输入手机号!')
return
}
if (!vm.showTimer) {
if ( if (
!vm.bankCardNumber || hlsUtil.phoneNumber(vm.phoneNumber) ||
!vm.bankAccName || hlsUtil.phoneNumber86(vm.phoneNumber)
!vm.phoneNumber ||
!vm.certNo ||
!vm.authCode
) { ) {
vm.hlsPopup.showLongCenter("必输字端不能为空!"); vm.phoneNumberFlag = true
return; vm.getVerifiedCode()
} else if (vm.hlsUtil.isCardID(vm.certNo)) {
vm.hlsPopup.showLongCenter("身份证号有误");
return;
} else if (!vm.hlsUtil.phoneNumber(vm.phoneNumber)) {
vm.hlsPopup.showLongCenter("手机号码有误!");
return;
} else { } else {
// alert("验证通过"); hlsPopup.showLongCenter('手机号不存在,请重新输入!')
let url = process.env.rootPath + "/china/pay/send/sign"; vm.phoneNumber = ''
let param = {
signId: vm.signId,
auth_code: vm.authCode
};
vm.hlsPopup.showLoading("请稍等");
vm.$post(url, param).then(function (res) {
vm.hlsPopup.hideLoading();
if (res.respCode == "0000") {
vm.hlsPopup.showSuccess(res.respMsg)
} else {
vm.hlsPopup.showLongCenter(res.respMsg)
}
});
}
},
// 键盘消失,页面回到顶部
goTop() {
setTimeout(function () {
var scrollHeight =
document.documentElement.scrollTop || document.body.scrollTop || 0;
console.log(scrollHeight);
window.scrollTo(0, Math.max(scrollHeight, 0));
}, 100);
},
// 获取验证码
getSignCode() {
let vm = this
if (!vm.bankCardNumber) {
vm.hlsPopup.showLongCenter('请输入银行卡号!')
return
}
if (!vm.bankAccName) {
vm.hlsPopup.showLongCenter('请输入账户名称!')
return
}
if (!vm.certNo) {
vm.hlsPopup.showLongCenter('请输入证件号码!')
return
}
if (!vm.phoneNumber) {
vm.hlsPopup.showLongCenter('请输入手机号!')
return
}
if (!vm.showTimer) {
if (
hlsUtil.phoneNumber(vm.phoneNumber) ||
hlsUtil.phoneNumber86(vm.phoneNumber)
) {
vm.phoneNumberFlag = true
vm.getVerifiedCode()
} else {
hlsPopup.showLongCenter('手机号不存在,请重新输入!')
vm.phoneNumber = ''
}
} }
}, }
// 前端生成验证码发送请求到后端进行判断 },
getVerifiedCode() { // 前端生成验证码发送请求到后端进行判断
let vm = this getVerifiedCode () {
let url = process.env.rootPath + '/china/pay/send/sign/message' let vm = this
let param = { let url = process.env.rootPath + '/china/pay/send/sign/message'
card_no: vm.bankCardNumber, let param = {
acc_name: vm.bankAccName, card_no: vm.bankCardNumber,
cert_no: vm.certNo, acc_name: vm.bankAccName,
mobile_no: vm.phoneNumber cert_no: vm.certNo,
mobile_no: vm.phoneNumber,
}
vm.hlsPopup.showLoading('请稍候')
vm.hlsHttp.post(url, param).then(function (res) {
vm.signId = ''
vm.signStatus = 0
vm.hlsPopup.hideLoading()
if (res.respCode === '0000') {
vm.signId = res.signId
vm.signStatus = 1
vm.hlsPopup.showSuccess('验证码已发送')
vm.showTimer = true
vm.text = '秒后失效'
let counter = setInterval(function () {
if (vm.timerCount > 0) {
vm.timerCount = vm.timerCount - 1
}
}, 1000)
setTimeout(function () {
vm.text = '获取验证码'
vm.showTimer = false
clearInterval(counter)
vm.showTimer = false
vm.timerCount = vm.timer / 1000
}, vm.timer)
} else {
vm.hlsPopup.showLongCenter('验证码发送失败!' + res.respMsg)
} }
vm.hlsPopup.showLoading('请稍候') })
vm.hlsHttp.post(url, param).then(function (res) {
vm.signId = "";
vm.signStatus = 0;
vm.hlsPopup.hideLoading()
if (res.respCode === '0000') {
vm.signId = res.signId;
vm.signStatus = 1;
vm.hlsPopup.showSuccess('验证码已发送')
vm.showTimer = true
vm.text = '秒后失效'
let counter = setInterval(function () {
if (vm.timerCount > 0) {
vm.timerCount = vm.timerCount - 1
}
}, 1000)
setTimeout(function () {
vm.text = '获取验证码'
vm.showTimer = false
clearInterval(counter)
vm.showTimer = false
vm.timerCount = vm.timer / 1000
}, vm.timer)
} else {
vm.hlsPopup.showLongCenter('验证码发送失败!' + res.respMsg)
}
})
},
}, },
created() { },
this.wxConfig(); }
// wx.hideOptionMenu();
// var data = this.$route.params.userInfo;
//this.getUserInfo();
}
};
</script> </script>
<style lang="less" type="text/less" scoped> <style lang="less" type="text/less" scoped>
@import "../../../styles/vue-1px.less"; @import "../../../styles/vue-1px.less";
.personalRegister { .personalRegister {
font-size: 12px !important; font-size: 12px !important;
.personalInfo { .personalInfo {
width: 100%; width: 100%;
height: 100% !important; height: 100% !important;
} }
.uppic { .uppic {
height: 100%; height: 100%;
width: 100%; width: 100%;
margin: 0 auto; margin: 0 auto;
opacity: 0; opacity: 0;
z-index: 1000; z-index: 1000;
position: absolute; position: absolute;
}
.pic {
width: 100%;
height: 100%;
position: absolute;
}
} }
.pic {
width: 100%;
height: 100%;
position: absolute;
}
}
// iPhoneX适配 // iPhoneX适配
@media (device-width: 375px) and (device-height: 812px) and (-webkit-min-device-pixel-ratio: 3) { @media (device-width: 375px) and (device-height: 812px) and (-webkit-min-device-pixel-ratio: 3) {
.platform-ios { .platform-ios {
#home { #home {
}
} }
} }
}
// iPhoneX Max适配 // iPhoneX Max适配
@media (device-width: 414px) and (device-height: 896px) { @media (device-width: 414px) and (device-height: 896px) {
.platform-ios {
.platform-ios { .platform-ios {
.platform-ios { #home {
#home {
}
} }
} }
} }
}
</style> </style>
<template>
<h-view class="public-style personalRegister" title="银联电子签约">
<h-content>
<list-item class="personalInf" style="padding:20px;height:100%">
<div style="height:40px;border-bottom:1px solid #d0d0d0">
<div class="personalInf-text" style=" width: 150px;line-height: 30px;text-align: center;
border-radius: 5px;
background-color: #ddd;font-size:16px;font-weight:700;color:#11111187">签约信息
</div>
</div>
<item style="border-bottom:1px solid #d0d0d0;font-size:14px">
<section slot="name" style="font-size:14px">
<img src="../../../assets/userRegister/bankIcon@2x.png"
style="float:left;width:20px;height:20px;margin: 2px 5px 0 0;">银行卡号:
</section>
<input slot="content" v-model="bankCardNumber" style="text-align: left;font-size:14px" placeholder="请输入银行卡号">
</item>
<item style="border-bottom:1px solid #d0d0d0">
<section slot="name" style="font-size:14px">
<img src="../../../assets/userRegister/people-name.png"
style="float:left;width:20px;height:20px;margin: 2px 5px 0 0;">账户名称:
</section>
<input slot="content" v-model="bankAccName" style="text-align: left;font-size:14px" placeholder="请输入账户名称">
</item>
<item style="border-bottom:1px solid #d0d0d0">
<section slot="name" style="font-size:14px">
<img src="../../../assets/userRegister/idCard.png"
style="float:left;width:20px;height:20px;margin: 2px 5px 0 0;">证件号码:
</section>
<input slot="content" v-model="certNo" style="text-align: left;font-size:14px" placeholder="请输入证件号码"
@blur="goTop()">
</item>
<item style="border-bottom:1px solid #d0d0d0">
<section slot="name" style="font-size:14px">
<img src="../../../assets/userRegister/phone.png"
style="float:left;width:20px;height:20px;margin: 2px 5px 0 0;">预留手机:
</section>
<input slot="content" v-model="phoneNumber" style="text-align: left;font-size:14px" placeholder="请输入电话号码"
@blur="goTop()">
</item>
<item style="border-bottom:1px solid #d0d0d0">
<section slot="name" style="font-size:14px">
<img src="../../../assets/userRegister/indentifyCode.png"
style="float:left;width:20px;height:20px;margin: 2px 5px 0 0;">验证码:
</section>
<input slot="content" v-model="authCode" style="text-align: left;font-size:14px;margin-left: 0.13rem"
placeholder="请输入验证码" @blur="goTop()">
<div>
<button v-if="!showTimer"
style="width:1.7rem;height:30px;border-radius:15px;background-color:#09bb07;color:#FFFFFF;margin:8px 0 0 -60px;position:relative;left:30%"
@click="getSignCode()">
<div style="font-size: 11px">获取验证码</div>
</button>
<button v-if="showTimer"
style="width:1.7rem;height:30px;border-radius:15px;background-color:#888c8f;color:#FFFFFF;margin:8px 0 0 -60px;position:relative;left:30%">
<div style="font-size: 11px">{{ timerCount }}{{ text }}</div>
</button>
</div>
</item>
<div>
<div style="width:50%;float: left;">
<div style="margin: 40px 0 0 14px;color:#333333;font-size:14px">
<div>请上传银行卡照片</div>
</div>
<div style="height:100px;margin-top:30px">
<div
style="border:1px solid #b2b2b2;width:70%;height:100%;margin:0 auto;border-radius:5px;position:relative;">
<img :src="cardUp" alt class="pic" @click="addCardImage(0)">
</div>
</div>
<p style="margin-top:10px;text-align:center;font-size:14px">
银行卡正面
</p>
</div>
<div style="width:50%;float: left;">
<div style="margin: 40px 0 0 14px;color:#333333;font-size:14px">
<p>请上传身份证照片</p>
</div>
<div style="height:100px;margin-top:30px">
<div
style="border:1px solid #b2b2b2;width:70%;height:100%;margin:0 auto;border-radius:5px;position:relative;">
<img :src="cardUp1" alt class="pic" @click="addCardImage(1)">
</div>
</div>
<p style="margin-top:10px;text-align:center;font-size:14px">
身份证正面
</p>
</div>
</div>
<button
style="width:120px;height:30px;border-radius:15px;background-color:#09bb07;color:#FFFFFF;margin:70px 0 0 -60px;position:relative;left:50%;"
@click="next_step()">签约
</button>
<p />
</list-item>
</h-content>
</h-view>
</template>
<script>
import { getUrlParam } from '@/scripts/utils'
export default {
components: {},
data () {
return {
cardUp: require('../../../assets/userRegister/camear.png'), // 身份证正面url
bankCardNumber: '',
bankAccName: '',
certNo: '',
phoneNumber: '',
authCode: '',
phoneNumberFlag: false,
showTimer: false,
timerCount: 60,
timer: 60000,
captchaKey: '',
signId: '',
signStatus: 0,
text: '秒后失效',
cardUp1: require('../../../assets/userRegister/camear.png'), // 身份证正面url
preview_url: '', // 图片预览地址
attchmentId: '', // 附件预览id
attchmentId1: '', // 附件预览id
}
},
activated: function () {
// this.getUserInfo();
},
updated: function () {
},
created () {
this.wxConfig()
// wx.hideOptionMenu();
// var data = this.$route.params.userInfo;
// this.getUserInfo();
},
methods: {
// 调用微信接口的基础配置
wxConfig () {
let clientUrl = ''
let u = navigator.userAgent
let isAndroid = u.indexOf('Android') > -1 || u.indexOf('Linux') > -1 // g
let isIOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/) // ios终端
if (isAndroid) {
// 这个是安卓操作系统
console.log('机型:android')
clientUrl = location.href
}
if (isIOS) {
// 这个是ios操作系统
console.log('机型:ios')
clientUrl = location.href.split('#')[0]
}
// let clientUrl = encodeURIComponent(location.href)
// let url = $config.rootPath + '/js/sdk/getWxConfig?wxCode=' + $config.wxCode + '&clientUrl=' + clientUrl
let url = process.env.basePathRl + 'getSignature'
let param = {
apiKey: 'handexinxi',
url: clientUrl,
}
hlsHttp.post(url, param).then(function (res) {
wx.config({
beta: true,
debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来,若要查看传入的参数,可以在pc端打开,参数信息会通过log打出,仅在pc端时才会打印。
appId: res.result.appId, // 必填,公众号的唯一标识
timestamp: res.result.timestamp, // 必填,生成签名的时间戳
nonceStr: res.result.nonceStr, // 必填,生成签名的随机串
signature: res.result.signature, // 必填,签名,见附录1
jsApiList: [
'chooseImage',
'previewImage',
'downloadImage',
'getLocalImgData',
'uploadImage',
'hideOptionMenu',
], // 必填,需要使用的JS接口列表,所有JS接口列表见附录2
})
wx.ready(function () {
wx.hideOptionMenu()
})
})
},
addCardImage: function (cardType) {
let self = this
// if(!self.cardUp){
wx.chooseImage({
count: 1, // 张数, 默认9
sizeType: ['compressed'], // 建议压缩图
sourceType: ['album', 'camera'], // 来源是相册、相机
success: function (res) {
if (cardType == 0) {
self.cardUp = res.localIds[0]
} else {
self.cardUp1 = res.localIds[0]
}
self.uploadToWeixinServer(res.localIds[0], cardType)
},
})
// }else{
// if(self.attchmentId){
// this.previewImage();
// }
// }
},
// 预览图片
previewImage () {
hlsPopup.showBigPicture({
imgUrl: vm.cardUp,
imgUrl1: vm.cardUp1,
})
},
uploadToWeixinServer (localId, cardType) {
let self = this
wx.uploadImage({
localId: localId,
isShowProgressTips: 1, // 默认为1,显示进度提示
success: function (res) {
// res.serverId 返回图片的微信服务器端ID
console.log('上传图片后返回的信息', res)
self.serverId = res.serverId
self.uploadToserver(res.serverId, cardType)
},
})
},
uploadToserver (serverId, cardType) {
let vm = this
let url = process.env.rootPath + '/auth/upload/image/hls/from/wx'
let sourceType = ''
if (cardType == 0) {
sourceType = 'app_file_id_bank'
} else {
sourceType = 'app_file_id_card'
}
let param = {
openId: window.localStorage.openId,
mediaId: serverId,
sourceType: sourceType,
fileName: new Date().getTime() + '.jpg',
}
vm.hlsPopup.showLoading('请稍等')
vm.$post(url, param).then(function (res) {
vm.hlsPopup.hideLoading()
vm.attchmentId = res['attchmentId']
if (cardType == 0) {
vm.bankCardNumber = res['bank_card_number']
vm.cardUp =
process.env.rootPath +
'/app/fileViewSvc?attachment_id=' +
vm.attchmentId +
'&apiName=download&sysName=HCL_UPLOAD_FILE&access_token=' +
window.localStorage.access_token_rl
} else {
vm.bankAccName = res['姓名']
vm.certNo = res['公民身份号码']
vm.cardUp1 =
process.env.rootPath +
'/app/fileViewSvc?attachment_id=' +
vm.attchmentId +
'&apiName=download&sysName=HCL_UPLOAD_FILE&access_token=' +
window.localStorage.access_token_rl
}
})
},
// 下一步
next_step () {
let vm = this
if (
!vm.bankCardNumber ||
!vm.bankAccName ||
!vm.phoneNumber ||
!vm.certNo ||
!vm.authCode
) {
vm.hlsPopup.showLongCenter('必输字端不能为空!')
} else if (vm.hlsUtil.isCardID(vm.certNo)) {
vm.hlsPopup.showLongCenter('身份证号有误')
} else if (!vm.hlsUtil.phoneNumber(vm.phoneNumber)) {
vm.hlsPopup.showLongCenter('手机号码有误!')
} else {
// alert("验证通过");
let url = process.env.rootPath + '/china/pay/send/sign'
let param = {
signId: vm.signId,
auth_code: vm.authCode,
}
vm.hlsPopup.showLoading('请稍等')
vm.$post(url, param).then(function (res) {
vm.hlsPopup.hideLoading()
if (res.respCode == '0000') {
vm.hlsPopup.showSuccess(res.respMsg)
} else {
vm.hlsPopup.showLongCenter(res.respMsg)
}
})
}
},
// 键盘消失,页面回到顶部
goTop () {
setTimeout(function () {
var scrollHeight =
document.documentElement.scrollTop || document.body.scrollTop || 0
console.log(scrollHeight)
window.scrollTo(0, Math.max(scrollHeight, 0))
}, 100)
},
// 获取验证码
getSignCode () {
let vm = this
if (!vm.bankCardNumber) {
vm.hlsPopup.showLongCenter('请输入银行卡号!')
return
}
if (!vm.bankAccName) {
vm.hlsPopup.showLongCenter('请输入账户名称!')
return
}
if (!vm.certNo) {
vm.hlsPopup.showLongCenter('请输入证件号码!')
return
}
if (!vm.phoneNumber) {
vm.hlsPopup.showLongCenter('请输入手机号!')
return
}
if (!vm.showTimer) {
if (
hlsUtil.phoneNumber(vm.phoneNumber) ||
hlsUtil.phoneNumber86(vm.phoneNumber)
) {
vm.phoneNumberFlag = true
vm.getVerifiedCode()
} else {
hlsPopup.showLongCenter('手机号不存在,请重新输入!')
vm.phoneNumber = ''
}
}
},
// 前端生成验证码发送请求到后端进行判断
getVerifiedCode () {
let vm = this
let url = process.env.rootPath + '/china/pay/send/sign/message'
let param = {
card_no: vm.bankCardNumber,
acc_name: vm.bankAccName,
cert_no: vm.certNo,
mobile_no: vm.phoneNumber,
}
vm.hlsPopup.showLoading('请稍候')
vm.hlsHttp.post(url, param).then(function (res) {
vm.signId = ''
vm.signStatus = 0
vm.hlsPopup.hideLoading()
if (res.respCode === '0000') {
vm.signId = res.signId
vm.signStatus = 1
vm.hlsPopup.showSuccess('验证码已发送')
vm.showTimer = true
vm.text = '秒后失效'
let counter = setInterval(function () {
if (vm.timerCount > 0) {
vm.timerCount = vm.timerCount - 1
}
}, 1000)
setTimeout(function () {
vm.text = '获取验证码'
vm.showTimer = false
clearInterval(counter)
vm.showTimer = false
vm.timerCount = vm.timer / 1000
}, vm.timer)
} else {
vm.hlsPopup.showLongCenter('验证码发送失败!' + res.respMsg)
}
})
},
},
}
</script>
<style lang="less" type="text/less" scoped>
@import "../../../styles/vue-1px.less";
.personalRegister {
font-size: 12px !important;
.personalInfo {
width: 100%;
height: 100% !important;
}
.uppic {
height: 100%;
width: 100%;
margin: 0 auto;
opacity: 0;
z-index: 1000;
position: absolute;
}
.pic {
width: 100%;
height: 100%;
position: absolute;
}
}
// iPhoneX适配
@media (device-width: 375px) and (device-height: 812px) and (-webkit-min-device-pixel-ratio: 3) {
.platform-ios {
#home {
}
}
}
// iPhoneX Max适配
@media (device-width: 414px) and (device-height: 896px) {
.platform-ios {
.platform-ios {
#home {
}
}
}
}
</style>
export default { export default {
bannerList: [{ bannerList: [{
pictureUrl: require('../assets/image/home/bannerWrap@2x.png'), pictureUrl: require('../assets/image/home/bannerWrap@2x.png'),
}, },
{ {
pictureUrl: require('../assets/image/home/bannerWrap2@2x.png'), pictureUrl: require('../assets/image/home/bannerWrap2@2x.png'),
}, },
], ],
recommendList: [ // 为你推荐图片数组 recommendList: [ // 为你推荐图片数组
{ {
recommendUrl: require('../assets/image/home/recommendOne@2x.png'), recommendUrl: require('../assets/image/home/recommendOne@2x.png'),
}, },
{ {
recommendUrl: require('../assets/image/home/recommendTwo@2x.png'), recommendUrl: require('../assets/image/home/recommendTwo@2x.png'),
}, },
], ],
moduleSeparateList: [ moduleSeparateList: [
// { // {
// 'moduleId': 1, // 'moduleId': 1,
// 'moduleCode': 'PARTNER', // 'moduleCode': 'PARTNER',
// 'moduleName': '商业伙伴', // 'moduleName': '商业伙伴',
// 'moduleIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/partner@2x.png', // 'moduleIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/partner@2x.png',
// 'roleId': 1, // 'roleId': 1,
// 'roleCode': 'ADMIN', // 'roleCode': 'ADMIN',
// 'roleName': '管理员', // 'roleName': '管理员',
// 'functions': [{ // 'functions': [{
// 'functionId': 1, // 'functionId': 1,
// 'functionCode': '110', // 'functionCode': '110',
// 'functionName': '客户创建', // 'functionName': '客户创建',
// 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/customerCreate@2x.png', // 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/customerCreate@2x.png',
// 'functionState': 'UploadImg', // 'functionState': 'UploadImg',
// 'prodFlag': 'Y', // 'prodFlag': 'Y',
// 'enableFlag': 'Y', // 'enableFlag': 'Y',
// 'functionType': 'local', // 'functionType': 'local',
// 'target': null, // 'target': null,
// 'applicationFlag': 'N', // 'applicationFlag': 'N',
// 'appCode': 'HLS_APP', // 'appCode': 'HLS_APP',
// }, // },
// { // {
// 'functionId': 2, // 'functionId': 2,
// 'functionCode': '120', // 'functionCode': '120',
// 'functionName': '客户维护', // 'functionName': '客户维护',
// 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/customerMaintain@2x.png', // 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/customerMaintain@2x.png',
// 'functionState': 'UploadImage', // 'functionState': 'UploadImage',
// 'prodFlag': 'Y', // 'prodFlag': 'Y',
// 'enableFlag': 'Y', // 'enableFlag': 'Y',
// 'functionType': 'local', // 'functionType': 'local',
// 'target': null, // 'target': null,
// 'applicationFlag': 'N', // 'applicationFlag': 'N',
// 'appCode': 'HLS_APP', // 'appCode': 'HLS_APP',
// }, // },
// ], // ],
// }, // },
// {
// 'moduleId': 2,
// 'moduleCode': 'PROJECT',
// 'moduleName': '项目申请',
// 'moduleIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/project@2x.png',
// 'roleId': 1,
// 'roleCode': 'ADMIN',
// 'roleName': '管理员',
// 'functions': [{
// 'functionId': 3,
// 'functionCode': '210',
// 'functionName': '融资试算',
// 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/finaning-main@2x.png',
// 'functionState': 'CalculationEnter',
// 'prodFlag': 'Y',
// 'enableFlag': 'Y',
// 'functionType': 'local',
// 'target': null,
// 'applicationFlag': 'N',
// 'appCode': 'HLS_APP',
// },
// {
// 'functionId': 4,
// 'functionCode': '100',
// 'functionName': '租赁申请',
// 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/applyCreate@2x.png',
// 'functionState': 'PrjCreate',
// 'prodFlag': 'Y',
// 'enableFlag': 'Y',
// 'functionType': 'local',
// 'target': null,
// 'applicationFlag': 'N',
// 'appCode': 'HLS_APP',
// },
// {
// 'functionId': 5,
// 'functionCode': '130',
// 'functionName': '申请维护',
// 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/applyMaintain@2x.png',
// 'functionState': 'PrjMaintenList',
// 'prodFlag': 'Y',
// 'enableFlag': 'Y',
// 'functionType': 'local',
// 'target': null,
// 'applicationFlag': 'N',
// 'appCode': 'HLS_APP',
// },
// ],
// },
// {
// 'moduleId': 3,
// 'moduleCode': 'CONTRACT',
// 'moduleName': '合同模块',
// 'moduleIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/contract@2x.png',
// 'roleId': 1,
// 'roleCode': 'ADMIN',
// 'roleName': '管理员',
// 'functions': [{
// 'functionId': 6,
// 'functionCode': '400',
// 'functionName': '合同维护',
// 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/contractMaintain@2x.png',
// 'functionState': 'ContractMaintenList',
// 'prodFlag': 'Y',
// 'enableFlag': 'Y',
// 'functionType': 'local',
// 'target': null,
// 'applicationFlag': 'N',
// 'appCode': 'HLS_APP',
// },
// {
// 'functionId': 7,
// 'functionCode': '410',
// 'functionName': '合同签约',
// 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/contractSign@2x.png',
// 'functionState': 'ContractSignList',
// 'prodFlag': 'Y',
// 'enableFlag': 'Y',
// 'functionType': 'local',
// 'target': null,
// 'applicationFlag': 'N',
// 'appCode': 'HLS_APP',
// },
// {
// 'functionId': 44,
// 'functionCode': '420',
// 'functionName': '电子签章',
// 'functionIcon': require('@/assets/home-manager/esign.jpg'),
// 'functionState': 'Esign',
// 'prodFlag': 'Y',
// 'enableFlag': 'Y',
// 'functionType': 'local',
// 'target': null,
// 'applicationFlag': 'N',
// 'appCode': 'HLS_APP',
// },
// ],
// },
{
'moduleId': 4,
'moduleCode': 'PERSONAL',
'moduleName': '个人办公',
'moduleIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/personWork@2x.png',
'roleId': 1,
'roleCode': 'ADMIN',
'roleName': '管理员',
'functions': [
// { // {
// 'moduleId': 2, // 'functionId': 8,
// 'moduleCode': 'PROJECT', // 'functionCode': '160',
// 'moduleName': '项目申请', // 'functionName': '工作流',
// 'moduleIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/project@2x.png', // 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/workflow@2x.png',
// 'roleId': 1, // 'functionState': 'WorkflowList',
// 'roleCode': 'ADMIN', // 'prodFlag': 'Y',
// 'roleName': '管理员', // 'enableFlag': 'Y',
// 'functions': [{ // 'functionType': 'local',
// 'functionId': 3, // 'target': null,
// 'functionCode': '210', // 'applicationFlag': 'N',
// 'functionName': '融资试算', // 'appCode': 'HLS_APP',
// 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/finaning-main@2x.png',
// 'functionState': 'CalculationEnter',
// 'prodFlag': 'Y',
// 'enableFlag': 'Y',
// 'functionType': 'local',
// 'target': null,
// 'applicationFlag': 'N',
// 'appCode': 'HLS_APP',
// },
// {
// 'functionId': 4,
// 'functionCode': '100',
// 'functionName': '租赁申请',
// 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/applyCreate@2x.png',
// 'functionState': 'PrjCreate',
// 'prodFlag': 'Y',
// 'enableFlag': 'Y',
// 'functionType': 'local',
// 'target': null,
// 'applicationFlag': 'N',
// 'appCode': 'HLS_APP',
// },
// {
// 'functionId': 5,
// 'functionCode': '130',
// 'functionName': '申请维护',
// 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/applyMaintain@2x.png',
// 'functionState': 'PrjMaintenList',
// 'prodFlag': 'Y',
// 'enableFlag': 'Y',
// 'functionType': 'local',
// 'target': null,
// 'applicationFlag': 'N',
// 'appCode': 'HLS_APP',
// },
// ],
// }, // },
// { // {
// 'moduleId': 3, // 'functionId': 9,
// 'moduleCode': 'CONTRACT', // 'functionCode': '170',
// 'moduleName': '合同模块', // 'functionName': 'OCR',
// 'moduleIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/contract@2x.png', // 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/ocr.png',
// 'roleId': 1, // 'functionState': 'OcrIdentify',
// 'roleCode': 'ADMIN', // 'prodFlag': 'Y',
// 'roleName': '管理员', // 'enableFlag': 'Y',
// 'functions': [{ // 'functionType': 'local',
// 'functionId': 6, // 'target': null,
// 'functionCode': '400', // 'applicationFlag': 'N',
// 'functionName': '合同维护', // 'appCode': 'HLS_APP',
// 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/contractMaintain@2x.png',
// 'functionState': 'ContractMaintenList',
// 'prodFlag': 'Y',
// 'enableFlag': 'Y',
// 'functionType': 'local',
// 'target': null,
// 'applicationFlag': 'N',
// 'appCode': 'HLS_APP',
// },
// {
// 'functionId': 7,
// 'functionCode': '410',
// 'functionName': '合同签约',
// 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/contractSign@2x.png',
// 'functionState': 'ContractSignList',
// 'prodFlag': 'Y',
// 'enableFlag': 'Y',
// 'functionType': 'local',
// 'target': null,
// 'applicationFlag': 'N',
// 'appCode': 'HLS_APP',
// },
// {
// 'functionId': 44,
// 'functionCode': '420',
// 'functionName': '电子签章',
// 'functionIcon': require('@/assets/home-manager/esign.jpg'),
// 'functionState': 'Esign',
// 'prodFlag': 'Y',
// 'enableFlag': 'Y',
// 'functionType': 'local',
// 'target': null,
// 'applicationFlag': 'N',
// 'appCode': 'HLS_APP',
// },
// ],
// }, // },
{ /* {
'moduleId': 4,
'moduleCode': 'PERSONAL',
'moduleName': '个人办公',
'moduleIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/personWork@2x.png',
'roleId': 1,
'roleCode': 'ADMIN',
'roleName': '管理员',
'functions': [
// {
// 'functionId': 8,
// 'functionCode': '160',
// 'functionName': '工作流',
// 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/workflow@2x.png',
// 'functionState': 'WorkflowList',
// 'prodFlag': 'Y',
// 'enableFlag': 'Y',
// 'functionType': 'local',
// 'target': null,
// 'applicationFlag': 'N',
// 'appCode': 'HLS_APP',
// },
// {
// 'functionId': 9,
// 'functionCode': '170',
// 'functionName': 'OCR',
// 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/ocr.png',
// 'functionState': 'OcrIdentify',
// 'prodFlag': 'Y',
// 'enableFlag': 'Y',
// 'functionType': 'local',
// 'target': null,
// 'applicationFlag': 'N',
// 'appCode': 'HLS_APP',
// },
/* {
'functionId': 43, 'functionId': 43,
'functionCode': '220', 'functionCode': '220',
'functionName': 'Time', 'functionName': 'Time',
...@@ -198,113 +198,126 @@ export default { ...@@ -198,113 +198,126 @@ export default {
'applicationFlag': 'N', 'applicationFlag': 'N',
'appCode': 'HLS_APP', 'appCode': 'HLS_APP',
}, */ }, */
// { // {
// 'functionId': 45, // 'functionId': 45,
// 'functionCode': '240', // 'functionCode': '240',
// 'functionName': '报表', // 'functionName': '报表',
// 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/chats@2x.png', // 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/chats@2x.png',
// 'functionState': 'Reports', // 'functionState': 'Reports',
// 'prodFlag': 'Y', // 'prodFlag': 'Y',
// 'enableFlag': 'Y', // 'enableFlag': 'Y',
// 'functionType': 'local', // 'functionType': 'local',
// 'target': null, // 'target': null,
// 'applicationFlag': 'N', // 'applicationFlag': 'N',
// 'appCode': 'HLS_APP', // 'appCode': 'HLS_APP',
// }, // },
// { // {
// 'functionId': 46, // 'functionId': 46,
// 'functionCode': '250', // 'functionCode': '250',
// 'functionName': '启信宝', // 'functionName': '启信宝',
// 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/qixinbao.png', // 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/qixinbao.png',
// 'functionState': 'QiXinBao', // 'functionState': 'QiXinBao',
// 'prodFlag': 'Y', // 'prodFlag': 'Y',
// 'enableFlag': 'Y', // 'enableFlag': 'Y',
// 'functionType': 'local', // 'functionType': 'local',
// 'target': null, // 'target': null,
// 'applicationFlag': 'N', // 'applicationFlag': 'N',
// 'appCode': 'HLS_APP', // 'appCode': 'HLS_APP',
// }, // },
// { // {
// 'functionId': 47, // 'functionId': 47,
// 'functionCode': '260', // 'functionCode': '260',
// 'functionName': '风报', // 'functionName': '风报',
// 'functionIcon': require('@/assets/home-manager/riskTorm.jpg'), // 'functionIcon': require('@/assets/home-manager/riskTorm.jpg'),
// 'functionState': 'RiskHome', // 'functionState': 'RiskHome',
// 'prodFlag': 'Y', // 'prodFlag': 'Y',
// 'enableFlag': 'Y', // 'enableFlag': 'Y',
// 'functionType': 'local', // 'functionType': 'local',
// 'target': null, // 'target': null,
// 'applicationFlag': 'N', // 'applicationFlag': 'N',
// 'appCode': 'HLS_APP', // 'appCode': 'HLS_APP',
// }, // },
// { // {
// 'functionId': 48, // 'functionId': 48,
// 'functionCode': '270', // 'functionCode': '270',
// 'functionName': '小易', // 'functionName': '小易',
// 'functionIcon': require('@/assets/home-manager/robot.png'), // 'functionIcon': require('@/assets/home-manager/robot.png'),
// 'functionState': 'Robot', // 'functionState': 'Robot',
// 'prodFlag': 'Y', // 'prodFlag': 'Y',
// 'enableFlag': 'Y', // 'enableFlag': 'Y',
// 'functionType': 'local', // 'functionType': 'local',
// 'target': null, // 'target': null,
// 'applicationFlag': 'N', // 'applicationFlag': 'N',
// 'appCode': 'HLS_APP', // 'appCode': 'HLS_APP',
// }, // },
{ {
'functionId': 49, 'functionId': 49,
'functionCode': '430', 'functionCode': '430',
'functionName': '用户注册', 'functionName': '用户注册',
'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/customerMaintain@2x.png', 'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/customerMaintain@2x.png',
'functionState': 'UserRegister', 'functionState': 'UserRegister',
'prodFlag': 'Y', 'prodFlag': 'Y',
'enableFlag': 'Y', 'enableFlag': 'Y',
'functionType': 'local', 'functionType': 'local',
'target': null, 'target': null,
'applicationFlag': 'N', 'applicationFlag': 'N',
'appCode': 'HLS_APP', 'appCode': 'HLS_APP',
},
{
'functionId': 50,
'functionCode': '450',
'functionName': '电子签约',
'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/contractSign@2x.png',
'functionState': 'ElectronicContract',
'prodFlag': 'Y',
'enableFlag': 'Y',
'functionType': 'local',
'target': null,
'applicationFlag': 'N',
'appCode': 'HLS_APP',
},
{
'functionId': 55,
'functionCode': '460',
'functionName': '电子合同下载',
'functionIcon': require('@/assets/home-manager/esign.jpg'),
'functionState': 'ContractDownload',
'prodFlag': 'Y',
'enableFlag': 'Y',
'functionType': 'local',
'target': null,
'applicationFlag': 'N',
'appCode': 'HLS_APP',
},
{
'functionId': 66,
'functionCode': '470',
'functionName': '银联电子签约',
'functionIcon': require('@/assets/home-manager/chinapay_logo.png'),
'functionState': 'ChinaUnionPay',
'prodFlag': 'Y',
'enableFlag': 'Y',
'functionType': 'local',
'target': null,
'applicationFlag': 'N',
'appCode': 'HLS_APP',
}
],
}, },
/* { {
'functionId': 50,
'functionCode': '450',
'functionName': '电子签约',
'functionIcon': 'http://hlsapp.hand-china.com/file/hel_dev/function/contractSign@2x.png',
'functionState': 'ElectronicContract',
'prodFlag': 'Y',
'enableFlag': 'Y',
'functionType': 'local',
'target': null,
'applicationFlag': 'N',
'appCode': 'HLS_APP',
},
{
'functionId': 55,
'functionCode': '460',
'functionName': '电子合同下载',
'functionIcon': require('@/assets/home-manager/esign.jpg'),
'functionState': 'ContractDownload',
'prodFlag': 'Y',
'enableFlag': 'Y',
'functionType': 'local',
'target': null,
'applicationFlag': 'N',
'appCode': 'HLS_APP',
},
{
'functionId': 66,
'functionCode': '470',
'functionName': '银联电子签约',
'functionIcon': require('@/assets/home-manager/chinapay_logo.png'),
'functionState': 'ChinaUnionPay',
'prodFlag': 'Y',
'enableFlag': 'Y',
'functionType': 'local',
'target': null,
'applicationFlag': 'N',
'appCode': 'HLS_APP',
},
{
'functionId': 66,
'functionCode': '500',
'functionName': '招行聚合支付',
'functionIcon': require('@/assets/home-manager/cmbpay_logo.png'),
'functionState': 'cmbPolyPay',
'prodFlag': 'Y',
'enableFlag': 'Y',
'functionType': 'local',
'target': null,
'applicationFlag': 'N',
'appCode': 'HLS_APP',
},
],
},
/* {
'moduleId': 5, 'moduleId': 5,
'moduleCode': 'PAYMENT', 'moduleCode': 'PAYMENT',
'moduleName': '付款管理', 'moduleName': '付款管理',
...@@ -354,5 +367,5 @@ export default { ...@@ -354,5 +367,5 @@ export default {
}, },
], ],
}, */ }, */
], ],
} }
...@@ -22,16 +22,9 @@ ...@@ -22,16 +22,9 @@
<div class="middle-box"> <div class="middle-box">
<header>常用应用</header> <header>常用应用</header>
<div class="function"> <div class="function">
<function-item <function-item v-for="item in functionList" :key="item.functionId" :functionIcon="item.functionIcon"
v-for="item in functionList" :functionName="item.functionName" :data="item" style="width:33.3%" class="function-item vue-1px"
:key="item.functionId" @clickFunction="goFunctionHome" />
:functionIcon="item.functionIcon"
:functionName="item.functionName"
style="width:33.3%"
:data="item"
class="function-item vue-1px"
@clickFunction="goFunctionHome"
/>
<!-- <div class="function-item" @click="goAllFunction"> <!-- <div class="function-item" @click="goAllFunction">
<img src="../assets/image/home/functionMore@2x.png"> <img src="../assets/image/home/functionMore@2x.png">
</div>--> </div>-->
...@@ -62,407 +55,406 @@ ...@@ -62,407 +55,406 @@
</template> </template>
<script> <script>
import functionState from "./functionState"; import functionState from './functionState'
import {getUrlParam} from "@/scripts/utils"; import { getUrlParam } from '@/scripts/utils'
export default { export default {
data() { data () {
return { return {
imgList: [], imgList: [],
recommendList: [], recommendList: [],
moduleSeparateList: [], moduleSeparateList: [],
functionList: [], // 全部应用 functionList: [], // 全部应用
messageList: [], messageList: [],
area: {}, area: {},
box1: {}, box1: {},
box2: {}, box2: {},
searchInput: "", searchInput: '',
subscribe: false subscribe: false,
}; }
}, },
beforeCreate: function () { beforeCreate: function () {
},
created: function () {
// debugger;
// window.localStorage.setItem('user_id', 2009)
// this.imgList = [...functionState.bannerList]
// this.recommendList = [...functionState.recommendList]
this.moduleSeparateList = [...functionState.moduleSeparateList]
this.moduleSeparateList.forEach(item => {
this.functionList = this.functionList.concat(item.functions)
})
this.getToken().then(res => {
this.wxConfig()
// if (window.localStorage.openId) {
// this.getWxUserInfo(window.localStorage.openId);
// }
// this.noticeQuery()
// 注意,此处用户个人信息是写死的user_id 后续项目实施中根据以下代码实时获取企业通讯录个人信息
var code = getUrlParam('code')
// code = "111";
if (code) {
this.getOpenId(code)
}
this.subscribe = window.localStorage.subscribe
})
},
updated: function () {
},
methods: {
// 调用微信接口的基础配置
wxConfig () {
let clientUrl = ''
let u = navigator.userAgent
let isAndroid = u.indexOf('Android') > -1 || u.indexOf('Linux') > -1 // g
let isIOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/) // ios终端
if (isAndroid) {
// 这个是安卓操作系统
console.log('机型:android')
clientUrl = location.href
}
if (isIOS) {
// 这个是ios操作系统
console.log('机型:ios')
clientUrl = location.href.split('#')[0]
}
// let url = $config.rootPath + '/js/sdk/getWxConfig?wxCode=' + $config.wxCode + '&clientUrl=' + clientUrl
let url = process.env.basePathRl + 'getSignature'
let param = {
apiKey: 'handexinxi',
url: clientUrl,
}
hlsHttp.post(url, param).then(function (res) {
wx.config({
beta: true,
debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来,若要查看传入的参数,可以在pc端打开,参数信息会通过log打出,仅在pc端时才会打印。
appId: res.result.appId, // 必填,公众号的唯一标识
timestamp: res.result.timestamp, // 必填,生成签名的时间戳
nonceStr: res.result.nonceStr, // 必填,生成签名的随机串
signature: res.result.signature, // 必填,签名,见附录1
jsApiList: [
'chooseImage',
'previewImage',
'downloadImage',
'getLocalImgData',
'uploadImage',
'hideOptionMenu',
], // 必填,需要使用的JS接口列表,所有JS接口列表见附录2
})
wx.ready(function () {
wx.hideOptionMenu()
})
})
}, },
created: function () { // search () {
// debugger; // let vm = this
// window.localStorage.setItem('user_id', 2009) // let flag = 'N'
// this.imgList = [...functionState.bannerList] // if (vm.searchInput) {
// this.recommendList = [...functionState.recommendList] // for (let i of vm.allFunctionList) {
this.moduleSeparateList = [...functionState.moduleSeparateList]; // if (vm.searchInput === i.functionName) {
this.moduleSeparateList.forEach(item => { // vm.$router.push({
this.functionList = this.functionList.concat(item.functions); // name: i.functionState,
}); // })
this.getToken().then(res => { // flag = 'Y'
this.wxConfig(); // break
// if (window.localStorage.openId) { // }
// this.getWxUserInfo(window.localStorage.openId); // }
// } // } else {
// this.noticeQuery() // vm.hlsPopup.showLongCenter('请输入功能名称')
// 注意,此处用户个人信息是写死的user_id 后续项目实施中根据以下代码实时获取企业通讯录个人信息 // }
var code = getUrlParam("code"); // if (flag === 'N') {
// code = "111"; // vm.hlsPopup.showLongCenter('没有此功能')
if (code) { // }
this.getOpenId(code); // },
// goModuleFunction (data) {
} // this.$router.push({
this.subscribe = window.localStorage.subscribe; // name: 'ModuleFunction',
}); // params: {
// moduleFunctionList: data,
// },
// })
// },
getToken () {
let vm = this
let url = process.env.loginPathRl + 'admin'
let param = {}
return vm.hlsHttp.post(url, param).then(function (res) {
window.localStorage.setItem('access_token_rl', res.access_token)
})
}, },
updated: function () { goFunctionHome (data) {
// if (this.subscribe) {
// this.$router.push({
// name: data.functionState
// });
// } else {
// hlsPopup.showPopup({
// title: "提示",
// content: "未关注公众号,请先关注后再进入!",
// onConfirm() {}
// });
// }
if (!this.subscribe) {
hlsPopup.showPopup({
title: '提示',
content: '未关注公众号,请先关注后再进入!',
onConfirm: function () {
},
})
} else {
window.localStorage.authFlag == 'Y' || data.functionState == 'UserRegister' || data.functionState == 'ChinaUnionPay' /* || data.functionState == 'CmbPolyPay' */ ? this.$router.push({ name: data.functionState }) : hlsPopup.showPopup({
title: '提示',
content: '当前用户未完成注册,请先注册!',
onConfirm: function () {
},
})
}
}, },
methods: { // moreRecommend () {
// 调用微信接口的基础配置 // console.log('go moreRecommend')
wxConfig() { // },
let clientUrl = ""; getOpenId (code) {
let u = navigator.userAgent; let vm = this
let isAndroid = u.indexOf("Android") > -1 || u.indexOf("Linux") > -1; //g let url = process.env.basePathRl + 'getOpenId'
let isIOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/); //ios终端 let param = {
if (isAndroid) { apiKey: 'handexinxi',
//这个是安卓操作系统 code: code,
console.log("机型:android"); }
clientUrl = location.href; // window.localStorage.openId = "oBdoRwP0WSbegPOoe9WTEMPkKsWQ";
// vm.getWxUserInfo(window.localStorage.openId);
vm.hlsHttp.post(url, param).then(function (res) {
if (res.resultCode == '00') {
window.localStorage.openId = res.result
if (window.localStorage.openId) {
vm.getWxUserInfo(window.localStorage.openId)
vm.getUserInfo(window.localStorage.openId)
}
} }
if (isIOS) { })
//这个是ios操作系统 },
console.log("机型:ios"); getWxUserInfo (id) {
clientUrl = location.href.split("#")[0]; let vm = this
let url = process.env.basePathRl + 'getWxUserInfo'
let params = {
apiKey: 'handexinxi',
openid: id,
// openid: "oBdoRwI9gj9Brbe9iqlDCg5G2dDc"
}
// window.localStorage.openId = "1234567"
vm.hlsHttp.post(url, params).then(function (res) {
if (res.resultCode == '00') {
vm.subscribe = window.localStorage.subscribe = res.result.subscribe
// console.log("vvvv", res.result.subscribe);
} }
// let url = $config.rootPath + '/js/sdk/getWxConfig?wxCode=' + $config.wxCode + '&clientUrl=' + clientUrl })
let url = process.env.basePathRl + "getSignature"; },
let param = { getUserInfo: function (openId) {
apiKey: "handexinxi", let vm = this,
url: clientUrl url = process.env.rootPath + '/sign/info/hclc/query/by/openid?openId=' + openId
}; vm.$post(url).then(function (res) {
hlsHttp.post(url, param).then(function (res) { if (res.rows.length > 0) {
wx.config({ var results = res.rows[0]
beta: true, vm.authFlag = window.localStorage.authFlag = results.authFlag
debug: false, // 开启调试模式,调用的所有api的返回值会在客户端alert出来,若要查看传入的参数,可以在pc端打开,参数信息会通过log打出,仅在pc端时才会打印。
appId: res.result.appId, // 必填,公众号的唯一标识
timestamp: res.result.timestamp, // 必填,生成签名的时间戳
nonceStr: res.result.nonceStr, // 必填,生成签名的随机串
signature: res.result.signature, // 必填,签名,见附录1
jsApiList: [
"chooseImage",
"previewImage",
"downloadImage",
"getLocalImgData",
"uploadImage",
"hideOptionMenu"
] // 必填,需要使用的JS接口列表,所有JS接口列表见附录2
});
wx.ready(function () {
wx.hideOptionMenu();
});
});
},
// search () {
// let vm = this
// let flag = 'N'
// if (vm.searchInput) {
// for (let i of vm.allFunctionList) {
// if (vm.searchInput === i.functionName) {
// vm.$router.push({
// name: i.functionState,
// })
// flag = 'Y'
// break
// }
// }
// } else {
// vm.hlsPopup.showLongCenter('请输入功能名称')
// }
// if (flag === 'N') {
// vm.hlsPopup.showLongCenter('没有此功能')
// }
// },
// goModuleFunction (data) {
// this.$router.push({
// name: 'ModuleFunction',
// params: {
// moduleFunctionList: data,
// },
// })
// },
getToken() {
let vm = this;
let url = process.env.loginPathRl + "admin";
let param = {};
return vm.hlsHttp.post(url, param).then(function (res) {
window.localStorage.setItem("access_token_rl", res.access_token);
});
},
goFunctionHome(data) {
// if (this.subscribe) {
// this.$router.push({
// name: data.functionState
// });
// } else {
// hlsPopup.showPopup({
// title: "提示",
// content: "未关注公众号,请先关注后再进入!",
// onConfirm() {}
// });
// }
if (!this.subscribe) {
hlsPopup.showPopup({
title: "提示",
content: "未关注公众号,请先关注后再进入!",
onConfirm: function () {
}
})
} else {
"Y" == window.localStorage.authFlag || "UserRegister" == data.functionState|| "ChinaUnionPay" == data.functionState ? this.$router.push({name: data.functionState}) : hlsPopup.showPopup({
title: "提示",
content: "当前用户未完成注册,请先注册!",
onConfirm: function () {
}
})
} }
}, })
// moreRecommend () { },
// console.log('go moreRecommend') },
// }, }
getOpenId(code) {
let vm = this;
let url = process.env.basePathRl + "getOpenId";
let param = {
apiKey: "handexinxi",
code: code
};
// window.localStorage.openId = "oBdoRwP0WSbegPOoe9WTEMPkKsWQ";
// vm.getWxUserInfo(window.localStorage.openId);
vm.hlsHttp.post(url, param).then(function (res) {
if (res.resultCode == "00") {
window.localStorage.openId = res.result;
if (window.localStorage.openId) {
vm.getWxUserInfo(window.localStorage.openId);
vm.getUserInfo(window.localStorage.openId)
}
}
});
},
getWxUserInfo(id) {
let vm = this;
let url = process.env.basePathRl + "getWxUserInfo";
let params = {
apiKey: "handexinxi",
openid: id
// openid: "oBdoRwI9gj9Brbe9iqlDCg5G2dDc"
};
// window.localStorage.openId = "1234567"
vm.hlsHttp.post(url, params).then(function (res) {
if (res.resultCode == "00") {
vm.subscribe = window.localStorage.subscribe = res.result.subscribe;
// console.log("vvvv", res.result.subscribe);
}
});
},
getUserInfo: function (openId) {
let vm = this,
url = process.env.rootPath + "/sign/info/hclc/query/by/openid?openId=" + openId;
vm.$post(url).then(function (res) {
if (res.rows.length > 0) {
var results = res.rows[0];
vm.authFlag = window.localStorage.authFlag = results.authFlag;
}
})
}
}
};
</script> </script>
<style lang="less" scoped type="text/less"> <style lang="less" scoped type="text/less">
@import "../styles/vue-1px"; @import "../styles/vue-1px";
#home { #home {
.top-box { .top-box {
// height: 264px; // height: 264px;
width: 100%;
overflow: hidden;
position: relative;
.header {
width: 100%; width: 100%;
overflow: hidden; height: 40px;
position: relative; position: absolute;
top: 0;
z-index: 100;
.header { input {
width: 100%; width: calc(~"100% - 53px");
height: 40px; height: 26px;
margin: 10px 0 0 10px;
background: white;
// border: 1px solid white;
border-radius: 15px;
text-align: center;
color: #b6b6b6;
font-size: 12px;
}
img {
width: 21px;
height: 21px;
position: absolute; position: absolute;
top: 0; top: 12px;
z-index: 100; right: 10px;
}
}
input { .hls-swipe {
width: calc(~"100% - 53px"); height: 175px;
height: 26px; width: 100%;
margin: 10px 0 0 10px; overflow: hidden;
background: white; }
// border: 1px solid white;
border-radius: 15px;
text-align: center;
color: #b6b6b6;
font-size: 12px;
}
img { .function {
width: 21px; height: 117px;
height: 21px; width: 100%;
position: absolute; position: absolute;
top: 12px; bottom: 0;
right: 10px; background: url("../assets/image/home/moduleBg@2x.png");
} background-size: 100%;
padding-top: 43px;
display: flex;
justify-content: space-between;
&:before {
content: "";
} }
.hls-swipe { &:after {
height: 175px; content: "";
width: 100%;
overflow: hidden;
} }
.function { .function-item {
height: 117px; text-align: center;
width: 100%; }
position: absolute; }
bottom: 0; }
background: url("../assets/image/home/moduleBg@2x.png");
background-size: 100%;
padding-top: 43px;
display: flex;
justify-content: space-between;
&:before { .middle-box {
content: ""; margin-top: 8px;
} background: white;
&:after { header {
content: ""; height: 33px;
} display: flex;
align-items: center;
line-height: 100%;
color: #5d98f6;
position: relative;
.function-item { &:before {
text-align: center; content: "";
} width: 4px;
height: 15px;
margin-right: 9px;
margin-left: 10px;
background-image: linear-gradient(-180deg, #5d98f6 0%, #76bcee 100%);
border-radius: 2px;
} }
}
.middle-box { &:after {
margin-top: 8px; .setBottomLine();
background: white; }
header { span {
height: 33px; font-size: 12px;
display: flex; color: #878a8d;
align-items: center; position: absolute;
line-height: 100%; right: 15px;
color: #5d98f6; }
position: relative; }
.function {
display: flex;
flex-wrap: wrap;
&:before { .function-item {
content: ""; width: 25%;
width: 4px; height: 100px;
height: 15px; font-size: 12px;
margin-right: 9px; // border: 1px solid rgba(169,169,169,0.1); /*no*/
margin-left: 10px; /deep/ img {
background-image: linear-gradient(-180deg, #5d98f6 0%, #76bcee 100%); height: 40px;
border-radius: 2px; width: 40px;
margin: 23px 28px 9px 33px;
} }
&:after { &:before {
.setBottomLine(); .setBottomLine();
} }
span { &:after {
font-size: 12px; .setRightLine();
color: #878a8d;
position: absolute;
right: 15px;
} }
} }
.function {
display: flex;
flex-wrap: wrap;
.function-item {
width: 25%;
height: 100px;
font-size: 12px;
// border: 1px solid rgba(169,169,169,0.1); /*no*/
/deep/ img {
height: 40px;
width: 40px;
margin: 23px 28px 9px 33px;
}
&:before {
.setBottomLine();
}
&:after {
.setRightLine();
}
}
/*.function-item:last-child{ /*.function-item:last-child{
/deep/ img{ /deep/ img{
height: 27px; height: 27px;
width: 27px; width: 27px;
margin: 31px 34px; margin: 31px 34px;
} }
}*/ }*/
}
} }
}
.important-message { .important-message {
width: 100%; width: 100%;
height: 42px; height: 42px;
margin-top: 8px; margin-top: 8px;
background-color: #ffffff; background-color: #ffffff;
display: flex;
justify-content: flex-start;
align-items: center;
.important-message-title {
-webkit-flex: 0 0 20%;
flex: 0 0 20%;
max-width: 20%;
color: #e84a55;
font-size: 14px;
//margin-left: 3.2%;
height: 100%;
display: flex; display: flex;
justify-content: flex-start; justify-content: center;
align-items: center; align-items: center;
.important-message-title { }
-webkit-flex: 0 0 20%;
flex: 0 0 20%;
max-width: 20%;
color: #e84a55;
font-size: 14px;
//margin-left: 3.2%;
height: 100%;
display: flex;
justify-content: center;
align-items: center;
}
.important-message-title-icon { .important-message-title-icon {
height: 100%; height: 100%;
margin-left: 1%; margin-left: 1%;
display: flex; display: flex;
justify-content: flex-start; justify-content: flex-start;
align-items: center; align-items: center;
img { img {
width: 13px; width: 13px;
height: 12px; height: 12px;
}
} }
}
#scroll { #scroll {
height: 42px; height: 42px;
overflow: hidden; overflow: hidden;
margin-left: 5%; margin-left: 5%;
} }
#scroll li { #scroll li {
height: 42px; height: 42px;
color: #565656; color: #565656;
font-size: 13px; font-size: 13px;
line-height: 18px; line-height: 18px;
overflow: hidden; overflow: hidden;
white-space: nowrap; white-space: nowrap;
text-overflow: ellipsis; text-overflow: ellipsis;
/*word-wrap: break-word; /*word-wrap: break-word;
word-break: break-all; word-break: break-all;
white-space: normal;*/ white-space: normal;*/
display: flex; display: flex;
align-items: center; align-items: center;
margin-right: 10px; margin-right: 10px;
}
} }
}
/*.message-box{ /*.message-box{
margin-top: 16px; margin-top: 16px;
height: 42px; height: 42px;
line-height: 42px; line-height: 42px;
...@@ -487,18 +479,18 @@ ...@@ -487,18 +479,18 @@
} }
}*/ }*/
.bottom-box { .bottom-box {
.recommend { .recommend {
flex: 1; flex: 1;
border: 1px solid rgba(169, 169, 169, 0.1); /*no*/ border: 1px solid rgba(169, 169, 169, 0.1); /*no*/
border-top: none; border-top: none;
img { img {
height: 100%; height: 100%;
width: 100%; width: 100%;
margin: 0; margin: 0;
}
} }
} }
} }
}
</style> </style>
...@@ -5,7 +5,6 @@ import ModuleFunction from '@/pages/homeManager/module-function' ...@@ -5,7 +5,6 @@ import ModuleFunction from '@/pages/homeManager/module-function'
// test工具类 // test工具类
import HlsPopup from '@/pages/hlsPopup' import HlsPopup from '@/pages/hlsPopup'
// 合同 // 合同
import ContractMaintenList from '@/pages/applications/contractMainten/contract-mainten-list' import ContractMaintenList from '@/pages/applications/contractMainten/contract-mainten-list'
import ContractMainten from '@/pages/applications/contractMainten/contract-mainten' import ContractMainten from '@/pages/applications/contractMainten/contract-mainten'
...@@ -13,7 +12,6 @@ import ContractSignList from '@/pages/applications/contractSign/contract-sign-li ...@@ -13,7 +12,6 @@ import ContractSignList from '@/pages/applications/contractSign/contract-sign-li
import ContractSign from '@/pages/applications/contractSign/contract-sign' import ContractSign from '@/pages/applications/contractSign/contract-sign'
import EsignPicture from '@/pages/applications/contractSign/esignPicture' import EsignPicture from '@/pages/applications/contractSign/esignPicture'
// 电子签章 // 电子签章
import Esign from '@/pages/applications/esign/Esign' import Esign from '@/pages/applications/esign/Esign'
import BankVerified from '@/pages/applications/esign/BankVerified' import BankVerified from '@/pages/applications/esign/BankVerified'
...@@ -26,15 +24,13 @@ import UserRegister from '@/pages/applications/userRegisters/userRegister' ...@@ -26,15 +24,13 @@ import UserRegister from '@/pages/applications/userRegisters/userRegister'
// 企业注册 // 企业注册
import CompanyRegister from '@/pages/applications/userRegisters/companyRegister' import CompanyRegister from '@/pages/applications/userRegisters/companyRegister'
import ReadonlyCompanyReg from '@/pages/applications/userRegisters/readonlyCompanyReg' import ReadonlyCompanyReg from '@/pages/applications/userRegisters/readonlyCompanyReg'
//授权经办人 // 授权经办人
import AuthorizedAgent from '@/pages/applications/userRegisters/authorizedAgent' import AuthorizedAgent from '@/pages/applications/userRegisters/authorizedAgent'
// 个人注册 // 个人注册
import PersonalRegister from '@/pages/applications/userRegisters/personalRegister' import PersonalRegister from '@/pages/applications/userRegisters/personalRegister'
import ReadonlyPersonalReg from '@/pages/applications/userRegisters/readonlyPersonalReg' import ReadonlyPersonalReg from '@/pages/applications/userRegisters/readonlyPersonalReg'
Vue.use(Router)
// 电子签约 // 电子签约
import ElectronicContract from '@/pages/applications/electronicContract/electronicContract' import ElectronicContract from '@/pages/applications/electronicContract/electronicContract'
import ElectronicContractList from '@/pages/applications/electronicContract/electronicContractList' import ElectronicContractList from '@/pages/applications/electronicContract/electronicContractList'
...@@ -44,187 +40,196 @@ import ContractDownloadList from '@/pages/applications/contractDownload/contract ...@@ -44,187 +40,196 @@ import ContractDownloadList from '@/pages/applications/contractDownload/contract
// 图片上传微信服务器 // 图片上传微信服务器
import UploadImg from '@/pages/applications/userRegisters/uploadImg' import UploadImg from '@/pages/applications/userRegisters/uploadImg'
import UploadImage from '@/pages/applications/userRegisters/uploadImage' import UploadImage from '@/pages/applications/userRegisters/uploadImage'
//银联电子签约 // 银联电子签约
import ChinaUnionPay from '@/pages/applications/chinaUnionPay/chinaUnionPay' import ChinaUnionPay from '@/pages/applications/chinaUnionPay/chinaUnionPay'
// 银联电子签约
import CmbPolyPay from '@/pages/applications/cmbPolyPay/cmbPolyPay'
Vue.use(Router)
// 全局跳转路由方法 // 全局跳转路由方法
Router.prototype.pushPage = function(param, bool) { Router.prototype.pushPage = function (param, bool) {
debugger debugger
let key = true let key = true
if (bool === undefined) { if (bool === undefined) {
key = true key = true
} else if (bool === true || bool === false) { } else if (bool === true || bool === false) {
key = bool key = bool
} }
this.currentRoute.meta.nextReload = key this.currentRoute.meta.nextReload = key
this.push(param) this.push(param)
} }
export default new Router({ export default new Router({
routes: [{ routes: [{
path: '/', path: '/',
redirect: to => { redirect: to => {
return { name: 'Home' } return { name: 'Home' }
}, },
}, },
{ path: '/home', component: Home, name: 'Home', meta: { keepAlive: false, nextReload: true } }, { path: '/home', component: Home, name: 'Home', meta: { keepAlive: false, nextReload: true } },
{ path: '/ModuleFunction', component: ModuleFunction, name: 'ModuleFunction', meta: { keepAlive: true } }, { path: '/ModuleFunction', component: ModuleFunction, name: 'ModuleFunction', meta: { keepAlive: true } },
// test工具类 // test工具类
{ path: '/hls-popup', component: HlsPopup, name: 'HlsPopup', meta: { keepAlive: false, nextReload: '' } }, { path: '/hls-popup', component: HlsPopup, name: 'HlsPopup', meta: { keepAlive: false, nextReload: '' } },
// 合同维护与签约 // 合同维护与签约
{ {
path: '/ContractMaintenList', path: '/ContractMaintenList',
component: ContractMaintenList, component: ContractMaintenList,
name: 'ContractMaintenList', name: 'ContractMaintenList',
meta: { keepAlive: false, nextReload: '' }, meta: { keepAlive: false, nextReload: '' },
}, },
{ {
path: '/ContractMainten', path: '/ContractMainten',
component: ContractMainten, component: ContractMainten,
name: 'ContractMainten', name: 'ContractMainten',
meta: { keepAlive: false, nextReload: '' }, meta: { keepAlive: false, nextReload: '' },
}, },
{ {
path: '/ContractSignList', path: '/ContractSignList',
component: ContractSignList, component: ContractSignList,
name: 'ContractSignList', name: 'ContractSignList',
meta: { keepAlive: false, nextReload: '' }, meta: { keepAlive: false, nextReload: '' },
}, },
{ {
path: '/ContractSign', path: '/ContractSign',
component: ContractSign, component: ContractSign,
name: 'ContractSign', name: 'ContractSign',
meta: { keepAlive: false, nextReload: '' }, meta: { keepAlive: false, nextReload: '' },
}, },
{ path: '/EsignPicture', component: EsignPicture, name: 'EsignPicture', meta: { keepAlive: false } }, { path: '/EsignPicture', component: EsignPicture, name: 'EsignPicture', meta: { keepAlive: false } },
{ path: '/Esign', component: Esign, name: 'Esign', meta: { keepAlive: false } }, { path: '/Esign', component: Esign, name: 'Esign', meta: { keepAlive: false } },
{ path: '/BankVerified', component: BankVerified, name: 'BankVerified', meta: { keepAlive: true } }, { path: '/BankVerified', component: BankVerified, name: 'BankVerified', meta: { keepAlive: true } },
{ path: '/PersonAccount', component: PersonAccount, name: 'PersonAccount', meta: { keepAlive: true } }, { path: '/PersonAccount', component: PersonAccount, name: 'PersonAccount', meta: { keepAlive: true } },
{ path: '/SignPdf', component: SignPdf, name: 'SignPdf', meta: { keepAlive: true } }, { path: '/SignPdf', component: SignPdf, name: 'SignPdf', meta: { keepAlive: true } },
{ path: '/ViewPicture', component: ViewPicture, name: 'ViewPicture', meta: { keepAlive: true } }, { path: '/ViewPicture', component: ViewPicture, name: 'ViewPicture', meta: { keepAlive: true } },
{ {
path: '/UserRegister', path: '/UserRegister',
component: UserRegister, component: UserRegister,
name: 'UserRegister', name: 'UserRegister',
meta: { meta: {
keepAlive: false keepAlive: false,
} },
}, },
{ {
path: '/UserRegister/PersonalRegister', path: '/UserRegister/PersonalRegister',
component: PersonalRegister, component: PersonalRegister,
name: 'PersonalRegister', name: 'PersonalRegister',
meta: { meta: {
keepAlive: false keepAlive: false,
}, },
}, },
{ {
path: '/UserRegister/ReadonlyPersonalReg', path: '/UserRegister/ReadonlyPersonalReg',
component: ReadonlyPersonalReg, component: ReadonlyPersonalReg,
name: 'ReadonlyPersonalReg', name: 'ReadonlyPersonalReg',
meta: { meta: {
keepAlive: true keepAlive: true,
}, },
}, },
{ {
path: '/UserRegister/CompanyRegister', path: '/UserRegister/CompanyRegister',
component: CompanyRegister, component: CompanyRegister,
name: 'CompanyRegister', name: 'CompanyRegister',
meta: { meta: {
keepAlive: false keepAlive: false,
}, },
}, },
{ {
path: '/UserRegister/ReadonlyCompanyReg', path: '/UserRegister/ReadonlyCompanyReg',
component: ReadonlyCompanyReg, component: ReadonlyCompanyReg,
name: 'ReadonlyCompanyReg', name: 'ReadonlyCompanyReg',
meta: { meta: {
keepAlive: true keepAlive: true,
}, },
}, },
// 微信上传图片 // 微信上传图片
{ {
path: '/UploadImg', path: '/UploadImg',
component: UploadImg, component: UploadImg,
name: 'UploadImg', name: 'UploadImg',
meta: { meta: {
keepAlive: true keepAlive: true,
}, },
},
{
path: '/UploadImage',
component: UploadImage,
name: 'UploadImage',
meta: {
keepAlive: true
},
},
// 电子签约
{
path: '/ElectronicContract',
component: ElectronicContract,
name: 'ElectronicContract',
meta: {
keepAlive: false
},
},
{
path: '/ElectronicContract/ElectronicContractList',
component: ElectronicContractList,
name: 'ElectronicContractList',
meta: {
keepAlive: true
},
},
// 电子合同下载
{
path: '/ContractDownload',
component: ContractDownload,
name: 'ContractDownload',
meta: {
keepAlive: false
},
},
// 电子合同下载
{
path: '/ContractDownload/ContractDownloadList',
component: ContractDownloadList,
name: 'ContractDownloadList',
meta: {
keepAlive: false
},
},
// 授权经办人
{
path: '/AuthorizedAgent',
component: AuthorizedAgent,
name: 'AuthorizedAgent',
meta: {
keepAlive: false
},
},
// 银联电子签约
{
path: '/ChinaUnionPay',
component: ChinaUnionPay,
name: 'ChinaUnionPay',
meta: {
keepAlive: false
},
},
], },
scrollBehavior(to, from, savedPosition) { {
if (to.hash) { path: '/UploadImage',
return { component: UploadImage,
selector: to.hash, name: 'UploadImage',
} meta: {
} keepAlive: true,
},
},
// 电子签约
{
path: '/ElectronicContract',
component: ElectronicContract,
name: 'ElectronicContract',
meta: {
keepAlive: false,
}, },
},
{
path: '/ElectronicContract/ElectronicContractList',
component: ElectronicContractList,
name: 'ElectronicContractList',
meta: {
keepAlive: true,
},
},
// 电子合同下载
{
path: '/ContractDownload',
component: ContractDownload,
name: 'ContractDownload',
meta: {
keepAlive: false,
},
},
// 电子合同下载
{
path: '/ContractDownload/ContractDownloadList',
component: ContractDownloadList,
name: 'ContractDownloadList',
meta: {
keepAlive: false,
},
},
// 授权经办人
{
path: '/AuthorizedAgent',
component: AuthorizedAgent,
name: 'AuthorizedAgent',
meta: {
keepAlive: false,
},
},
// 银联电子签约
{
path: '/ChinaUnionPay',
component: ChinaUnionPay,
name: 'ChinaUnionPay',
meta: {
keepAlive: false,
},
},
// 招行聚合支付
{
path: '/CmbPolyPay',
component: CmbPolyPay,
name: 'CmbPolyPay',
meta: {
keepAlive: false,
},
},
],
scrollBehavior (to, from, savedPosition) {
if (to.hash) {
return {
selector: to.hash,
}
}
},
}) })
File added
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment