Commit 33a12c07 authored by chaiwei's avatar chaiwei

修改优化后提交

parent a66e0558
Pipeline #5830 canceled with stages
...@@ -92,6 +92,7 @@ export default { ...@@ -92,6 +92,7 @@ export default {
this.offsize = 1; this.offsize = 1;
this.pagesize = 10; this.pagesize = 10;
this.index = [1, 0, 0]; this.index = [1, 0, 0];
// window.localStorage.openId = "1234567"
if (window.localStorage.openId) { if (window.localStorage.openId) {
this.getUserInfo(window.localStorage.openId); this.getUserInfo(window.localStorage.openId);
} }
...@@ -120,6 +121,7 @@ export default { ...@@ -120,6 +121,7 @@ export default {
"/sign/info/hclc/query/by/openid?openId=" + "/sign/info/hclc/query/by/openid?openId=" +
openId; openId;
vm.hlsPopup.showLoading("请稍等"); vm.hlsPopup.showLoading("请稍等");
// vm.getData(); // vm.getData();
vm.$post(url).then(function(res) { vm.$post(url).then(function(res) {
vm.hlsPopup.hideLoading(); vm.hlsPopup.hideLoading();
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
<p style="margin-top:3px">{{item.file_sign_name}}</p> <p style="margin-top:3px">{{item.file_sign_name}}</p>
</div> </div>
<button <button
style="float:right;margin-top:5px;background-color:#09bb07;color:#ffffff;width:50px;border-radius:3px" style="float:right;margin-top:5px;background-color:#09bb07;color:#ffffff;width:70px;border-radius:3px"
@click="downloadContract(item.attachment_id)" @click="downloadContract(item.attachment_id)"
>下载</button> >下载</button>
</div> </div>
...@@ -51,6 +51,16 @@ export default { ...@@ -51,6 +51,16 @@ export default {
mounted() { mounted() {
// this._initLoad() // this._initLoad()
}, },
activated(){
this.wxConfig();
if (this.$route.params.itemData) {
window.localStorage.SignDownloadData = JSON.stringify(
this.$route.params.itemData.sign_file_list
);
}
// console.log(JSON.parse(window.localStorage.unSignData));
this.data = JSON.parse(window.localStorage.SignDownloadData);
},
methods: { methods: {
// createSign() { // createSign() {
// let url = "http://sign.hitachics.com/core/r/api/app/fileViewSvc?attachment_id=13435&apiName=download&sysName=HCL_UPLOAD_FILE&access_token="+window.localStorage.access_token_rl // let url = "http://sign.hitachics.com/core/r/api/app/fileViewSvc?attachment_id=13435&apiName=download&sysName=HCL_UPLOAD_FILE&access_token="+window.localStorage.access_token_rl
......
...@@ -62,11 +62,11 @@ ...@@ -62,11 +62,11 @@
<list-item :item-height="80" v-if="myIndex == 1"> <list-item :item-height="80" v-if="myIndex == 1">
<!-- <div :key="index" :proportion="[5,1]" :show-arrow="true"> --> <!-- <div :key="index" :proportion="[5,1]" :show-arrow="true"> -->
<item style="margin-top:10px" v-for="(item,index) in signData" :key="index"> <item style="margin-top:10px" v-for="(item,index) in signData" :key="index">
<img <!-- <img
slot="left-icon" slot="left-icon"
src="../../../assets/electronicContract/contract-icon.png" src="../../../assets/electronicContract/contract-icon.png"
class="left-icon" class="left-icon"
/> /> -->
<div slot="name" class="text" style="width: 70%;font-size: 12px;"> <div slot="name" class="text" style="width: 70%;font-size: 12px;">
<div <div
class="cont-type" class="cont-type"
......
...@@ -32,26 +32,36 @@ export default { ...@@ -32,26 +32,36 @@ export default {
}, },
components: {}, components: {},
created() { created() {
this.wxConfig(); if(this.$route.params.itemData){
if(this.$route.params.itemData){ // console.log('33333333333',this.$route.params.itemData.un_sign_file_list)
window.localStorage.unSignData = JSON.stringify(this.$route.params.itemData.un_sign_file_list); window.localStorage.unSignData = JSON.stringify(this.$route.params.itemData.un_sign_file_list);
} }
// console.log(JSON.parse(window.localStorage.unSignData));
this.data = JSON.parse(window.localStorage.unSignData); this.data = JSON.parse(window.localStorage.unSignData);
console.log("22222222222", this.data); this.wxConfig();
this.offsize = 1; this.offsize = 1;
this.pagesize = 10; this.pagesize = 10;
this.index = [1, 0, 0]; this.index = [1, 0, 0];
}, },
mounted() { mounted() {
// this._initLoad() // this._initLoad()
},
activated(){
if(this.$route.params.itemData){
// console.log('33333333333',this.$route.params.itemData.un_sign_file_list)
window.localStorage.unSignData = JSON.stringify(this.$route.params.itemData.un_sign_file_list);
}
this.data = JSON.parse(window.localStorage.unSignData);
}, },
methods: { methods: {
createSign() { createSign() {
let goUrl = this.data[0].sign_url let goUrl = this.data[0].sign_url
if (goUrl) { if (goUrl) {
// //
this.hlsPopup.showLoading("请稍等"); // this.hlsPopup.showLoading("请稍等");
window.open(goUrl, "_self"); window.open(goUrl, "_self");
// let url = window.open('http://www.baidu.com','_self'); // let url = window.open('http://www.baidu.com','_self');
...@@ -66,43 +76,43 @@ export default { ...@@ -66,43 +76,43 @@ export default {
// 打开模态框 // 打开模态框
}, },
load_count: function() { // load_count: function() {
let vm = this; // let vm = this;
let url = process.env.basePath + "contract_count"; // let url = process.env.basePath + "contract_count";
let param = {}; // let param = {};
// hlsPopup.showLoadingWithoutBackdrop(); // // hlsPopup.showLoadingWithoutBackdrop();
vm.$post(url, param).then(function(res) { // vm.$post(url, param).then(function(res) {
vm.info = res; // vm.info = res;
vm.changeData(); // vm.changeData();
}); // });
}, // },
loadMore: function() { // loadMore: function() {
let vm = this; // let vm = this;
vm.offsize = vm.offsize + 1; // vm.offsize = vm.offsize + 1;
let url = process.env.basePath + "app_get_contract_selected"; // let url = process.env.basePath + "app_get_contract_selected";
let param = { // let param = {
offsize: vm.offsize, // offsize: vm.offsize,
searchInput: vm.searchCondition.input // searchInput: vm.searchCondition.input
}; // };
vm.$post(url, param).then(function(res) { // vm.$post(url, param).then(function(res) {
let returnData = []; // let returnData = [];
returnData = res.getContract_list; // returnData = res.getContract_list;
if (returnData.length === 0) { // if (returnData.length === 0) {
vm.$refs.scroll.update(true); // vm.$refs.scroll.update(true);
} else if (returnData.length > 0 && returnData.length < vm.pagesize) { // } else if (returnData.length > 0 && returnData.length < vm.pagesize) {
vum.forEach(returnData, function(data, index, array) { // vum.forEach(returnData, function(data, index, array) {
vm.con_list.push(array[index]); // vm.con_list.push(array[index]);
}); // });
vm.$refs.scroll.update(true); // vm.$refs.scroll.update(true);
} else if (returnData.length === vm.pagesize) { // } else if (returnData.length === vm.pagesize) {
vum.forEach(returnData, function(data, index, array) { // vum.forEach(returnData, function(data, index, array) {
vm.con_list.push(array[index]); // vm.con_list.push(array[index]);
}); // });
vm.$refs.scroll.update(false); // vm.$refs.scroll.update(false);
} // }
}); // });
}, // },
// goContractMainten: function (list) { // goContractMainten: function (list) {
// this.$router.push({ // this.$router.push({
// name: 'ContractSign', // name: 'ContractSign',
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<h-view class="public-style companyRegister" title="企业用户注册"> <h-view class="public-style companyRegister" title="企业用户注册">
<h-content v-if="status != '成功'"> <h-content v-if="status != '成功'">
<list-item class="reg-content"> <list-item class="reg-content">
<div class="repre-type" v-if="faceAuthStatus != 'SUCCESS'"> <!-- <div class="repre-type" v-if="faceAuthStatus != 'SUCCESS'">
<input type="radio" name="agent" v-model="agentType" @change="isAgent" value="Y" /> <input type="radio" name="agent" v-model="agentType" @change="isAgent" value="Y" />
代理店 代理店
...@@ -16,8 +16,8 @@ ...@@ -16,8 +16,8 @@
@change="isAgent" @change="isAgent"
value="N" value="N"
/>非代理店 />非代理店
</div> </div>-->
<div class="repre-type" v-if="faceAuthStatus == 'SUCCESS'"> <!-- <div class="repre-type" v-if="faceAuthStatus == 'SUCCESS'">
代理店 代理店
<input type="radio" name="agent" v-model="agentType" @change="isAgent" value="Y" disabled/> <input type="radio" name="agent" v-model="agentType" @change="isAgent" value="Y" disabled/>
非代理店 非代理店
...@@ -29,8 +29,8 @@ ...@@ -29,8 +29,8 @@
value="N" value="N"
disabled disabled
/> />
</div> </div>-->
<div class="repre-type" v-if="faceAuthStatus != 'SUCCESS' && agentType == 'Y'"> <div class="repre-type" v-if="faceAuthStatus != 'SUCCESS'">
<span>经办人类型:</span> <span>经办人类型:</span>
<input <input
type="radio" type="radio"
...@@ -47,7 +47,7 @@ ...@@ -47,7 +47,7 @@
value="法定代表人" value="法定代表人"
/>法定代表人 />法定代表人
</div> </div>
<div class="repre-type" v-if="faceAuthStatus == 'SUCCESS' && agentType == 'Y'"> <div class="repre-type" v-if="faceAuthStatus == 'SUCCESS'">
<span>经办人类型:</span> <span>经办人类型:</span>
<input <input
type="radio" type="radio"
...@@ -260,25 +260,7 @@ ...@@ -260,25 +260,7 @@
<input type="text" class="edit" v-model="jbName" readonly /> <input type="text" class="edit" v-model="jbName" readonly />
</div> </div>
</div> </div>
<div class="info_list">
<div class="list_left" style="width:30%;">
<img
src="../../../assets/userRegister/phone.png"
alt
style="width:16px;height:16px;margin-right:5px;"
/>
手机号码:
</div>
<div class="list_right" style="width:70%;">
<input
type="text"
class="edit"
v-model="jbPhoneNumber"
@blur="goTop()"
placeholder="请输入手机号码"
/>
</div>
</div>
<div class="info_list" v-if="faceAuthStatus =='SUCCESS'"> <div class="info_list" v-if="faceAuthStatus =='SUCCESS'">
<div class="list_left" style="width:41%;"> <div class="list_left" style="width:41%;">
<img <img
...@@ -305,6 +287,25 @@ ...@@ -305,6 +287,25 @@
<input type="text" class="edit" v-model="jbIdNumber" readonly /> <input type="text" class="edit" v-model="jbIdNumber" readonly />
</div> </div>
</div> </div>
<div class="info_list">
<div class="list_left" style="width:30%;">
<img
src="../../../assets/userRegister/phone.png"
alt
style="width:16px;height:16px;margin-right:5px;"
/>
手机号码:
</div>
<div class="list_right" style="width:70%;">
<input
type="text"
class="edit"
v-model="jbPhoneNumber"
@blur="goTop()"
placeholder="请输入手机号码"
/>
</div>
</div>
<div style="margin: 10px 0 0 14px;color:#636363"> <div style="margin: 10px 0 0 14px;color:#636363">
<p>请上传身份证照片</p> <p>请上传身份证照片</p>
</div> </div>
...@@ -425,7 +426,7 @@ ...@@ -425,7 +426,7 @@
</h-content> </h-content>
<h-content v-if="status == '成功'"> <h-content v-if="status == '成功'">
<list-item class="reg-content"> <list-item class="reg-content">
<div class="repre-type"> <!-- <div class="repre-type">
<input <input
type="radio" type="radio"
name="agent" name="agent"
...@@ -443,8 +444,8 @@ ...@@ -443,8 +444,8 @@
value="N" value="N"
disabled disabled
/>非代理店 />非代理店
</div> </div>-->
<div class="repre-type" v-if="agentType == 'Y'"> <div class="repre-type">
<span>经办人类型:</span> <span>经办人类型:</span>
<input <input
type="radio" type="radio"
...@@ -586,31 +587,31 @@ ...@@ -586,31 +587,31 @@
<input type="text" class="edit" v-model="jbName" readonly /> <input type="text" class="edit" v-model="jbName" readonly />
</div> </div>
</div> </div>
<div class="info_list"> <div class="info_list">
<div class="list_left" style="width:30%;"> <div class="list_left" style="width:48%;">
<img <img
src="../../../assets/userRegister/phone.png" src="../../../assets/userRegister/idCard.png"
alt alt
style="width:16px;height:16px;margin-right:5px;" style="width:16px;height:16px;margin-right:5px;"
/> />
手机号码 经办人身份证号
</div> </div>
<div class="list_right" style="width:70%;"> <div class="list_right" style="width:52%;">
<input type="text" class="edit" v-model="jbPhoneNumber" readonly /> <input type="text" class="edit" v-model="jbIdNumber" readonly />
</div> </div>
</div> </div>
<div class="info_list"> <div class="info_list">
<div class="list_left" style="width:48%;"> <div class="list_left" style="width:30%;">
<img <img
src="../../../assets/userRegister/idCard.png" src="../../../assets/userRegister/phone.png"
alt alt
style="width:16px;height:16px;margin-right:5px;" style="width:16px;height:16px;margin-right:5px;"
/> />
经办人身份证号 手机号码
</div> </div>
<div class="list_right" style="width:52%;"> <div class="list_right" style="width:70%;">
<input type="text" class="edit" v-model="jbIdNumber" readonly /> <input type="text" class="edit" v-model="jbPhoneNumber" readonly />
</div> </div>
</div> </div>
<!-- <div style="margin: 10px 0 0 14px;color:#636363"> <!-- <div style="margin: 10px 0 0 14px;color:#636363">
...@@ -717,7 +718,7 @@ import { getUrlParam } from "@/scripts/utils"; ...@@ -717,7 +718,7 @@ import { getUrlParam } from "@/scripts/utils";
export default { export default {
data() { data() {
return { return {
agentType: "Y", // agentType: "Y",
staffType: "法定代表人", staffType: "法定代表人",
cardUp: require("../../../assets/userRegister/camear.png"), //身份证照片url cardUp: require("../../../assets/userRegister/camear.png"), //身份证照片url
busLic: require("../../../assets/userRegister/camear.png"), //营业执照照片url busLic: require("../../../assets/userRegister/camear.png"), //营业执照照片url
...@@ -780,13 +781,13 @@ export default { ...@@ -780,13 +781,13 @@ export default {
updated: function() {}, updated: function() {},
methods: { methods: {
// 是否是代理店 // 是否是代理店
isAgent() { // isAgent() {
console.log(this.agentType); // console.log(this.agentType);
// window.localStorage.agentType = this.agentType; // // window.localStorage.agentType = this.agentType;
if (this.agentType == "N") { // if (this.agentType == "N") {
this.staffType = "法定代表人"; // this.staffType = "法定代表人";
} // }
}, // },
// 调用微信接口的基础配置 // 调用微信接口的基础配置
wxConfig() { wxConfig() {
...@@ -827,9 +828,9 @@ export default { ...@@ -827,9 +828,9 @@ export default {
"hideOptionMenu" "hideOptionMenu"
] // 必填,需要使用的JS接口列表,所有JS接口列表见附录2 ] // 必填,需要使用的JS接口列表,所有JS接口列表见附录2
}); });
wx.ready(function () { wx.ready(function() {
wx.hideOptionMenu(); wx.hideOptionMenu();
}) });
}); });
}, },
// 法人和其他人切换状态 // 法人和其他人切换状态
...@@ -1062,7 +1063,7 @@ export default { ...@@ -1062,7 +1063,7 @@ export default {
legalName: vm.legalRepresentativeName, legalName: vm.legalRepresentativeName,
legalIdNo: vm.legalRepresentativeCardNumber, legalIdNo: vm.legalRepresentativeCardNumber,
agentType: "1", agentType: "1",
dealerFlag: vm.agentType, // dealerFlag: vm.agentType,
redirectUrl: redirectUrl:
"http://sign.hitachics.com/www/#/UserRegister/CompanyRegister?Regstatus=1" "http://sign.hitachics.com/www/#/UserRegister/CompanyRegister?Regstatus=1"
}; };
...@@ -1127,7 +1128,6 @@ export default { ...@@ -1127,7 +1128,6 @@ export default {
legalName: vm.legalRepresentativeName1, legalName: vm.legalRepresentativeName1,
legalIdNo: vm.legalRepresentativeCardNumber1, legalIdNo: vm.legalRepresentativeCardNumber1,
agentType: "2", agentType: "2",
dealerFlag: vm.agentType,
redirectUrl: redirectUrl:
"http://sign.hitachics.com/www/#/UserRegister/CompanyRegister?Regstatus=2" "http://sign.hitachics.com/www/#/UserRegister/CompanyRegister?Regstatus=2"
}; };
...@@ -1162,18 +1162,31 @@ export default { ...@@ -1162,18 +1162,31 @@ export default {
}, },
logout() { logout() {
let vm = this; let vm = this;
let url = process.env.rootPath + "/organizations/outerOrgans/delete"; hlsPopup.showConfirm({
let param = { title: "提示",
openId: window.localStorage.openId content: "请确认合同是否都已下载完成,注销后无法下载,请知悉,谢谢!",
}; onConfirm: function(index) {
vm.hlsPopup.showLoading("请稍等"); if (index === 1) {
vm.$post(url, param).then(function(res) { let url =
vm.hlsPopup.hideLoading(); process.env.rootPath + "/organizations/outerOrgans/delete";
if (res.code == 0) { let param = {
vm.$vux.toast.text(res.message, "middle"); openId: window.localStorage.openId
window.open("http://sign.hitachics.com/www/#/UserRegister", "_self"); };
} else { vm.hlsPopup.showLoading("请稍等");
vm.$vux.toast.text(res.message, "middle"); vm.$post(url, param).then(function(res) {
vm.hlsPopup.hideLoading();
if (res.code == 0) {
vm.$vux.toast.text(res.message, "middle");
window.open(
"http://sign.hitachics.com/www/#/UserRegister",
"_self"
);
} else {
vm.$vux.toast.text(res.message, "middle");
}
});
}
// console.log(index);
} }
}); });
}, },
......
...@@ -17,7 +17,12 @@ ...@@ -17,7 +17,12 @@
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 slot="content" v-model="personName" style="text-align: left;font-size:12px" readonly/> <input
slot="content"
v-model="personName"
style="text-align: left;font-size:12px"
readonly
/>
</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">
...@@ -45,7 +50,7 @@ ...@@ -45,7 +50,7 @@
v-model="phoneNumber" v-model="phoneNumber"
style="text-align: left;font-size:14px" style="text-align: left;font-size:14px"
placeholder="请输入电话号码" placeholder="请输入电话号码"
@blur = "goTop()" @blur="goTop()"
/> />
</item> </item>
<div style="margin: 40px 0 0 14px;color:#333333;font-size:14px"> <div style="margin: 40px 0 0 14px;color:#333333;font-size:14px">
...@@ -63,7 +68,7 @@ ...@@ -63,7 +68,7 @@
@change="uploadUpImg($event)" @change="uploadUpImg($event)"
ref="avatarInput" ref="avatarInput"
class="uppic" class="uppic"
/> --> />-->
<img :src="cardUp" alt class="pic" @click="addCardImage()" /> <img :src="cardUp" alt class="pic" @click="addCardImage()" />
</div> </div>
...@@ -89,15 +94,15 @@ ...@@ -89,15 +94,15 @@
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%;"
>下一步</button> >下一步</button>
</list-item> </list-item>
</h-content> </h-content>
<h-content v-else-if="status == 1"> <h-content v-if="status == 1">
<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 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
个人信息 class="personalInf-text"
</div> 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> </div>
<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">
...@@ -157,7 +162,7 @@ ...@@ -157,7 +162,7 @@
class="uppic" class="uppic"
disabled disabled
/>--> />-->
<img :src="cardUp1" alt class="pic" @click="previewImage()"/> <img :src="cardUp1" alt class="pic" @click="previewImage()" />
</div> </div>
<!-- <div style="border:1px solid #b2b2b2;width:50%;border-radius:5px;position:relative;"> <!-- <div style="border:1px solid #b2b2b2;width:50%;border-radius:5px;position:relative;">
...@@ -187,11 +192,11 @@ ...@@ -187,11 +192,11 @@
</template> </template>
<script> <script>
import {getUrlParam} from '@/scripts/utils' import { getUrlParam } from "@/scripts/utils";
export default { export default {
data() { data() {
return { return {
cardUp:require("../../../assets/userRegister/camear.png") , //身份证正面url cardUp: require("../../../assets/userRegister/camear.png"), //身份证正面url
identificationNumber: "", identificationNumber: "",
phoneNumber: "", phoneNumber: "",
personName: "", personName: "",
...@@ -200,9 +205,9 @@ export default { ...@@ -200,9 +205,9 @@ export default {
phoneNumber1: "", phoneNumber1: "",
personName1: "", personName1: "",
status: "", status: "",
serverId:"", serverId: "",
preview_url:"",//图片预览地址 preview_url: "", //图片预览地址
attchmentId:"",//附件预览id attchmentId: "" //附件预览id
}; };
}, },
components: {}, components: {},
...@@ -218,28 +223,28 @@ export default { ...@@ -218,28 +223,28 @@ export default {
this.personName1 = sessionStorage.personName this.personName1 = sessionStorage.personName
? sessionStorage.personName ? sessionStorage.personName
: ""; : "";
// console.log(this.getUrlParams('Regstatus')); // console.log(this.getUrlParams('Regstatus'));
var Request = new this.UrlSearch(); //实例化 var Request = new this.UrlSearch(); //实例化
this.status = Request.Regstatus; this.status = Request.Regstatus;
}, },
updated: function() {}, updated: function() {},
methods: { methods: {
// 调用微信接口的基础配置 // 调用微信接口的基础配置
wxConfig() { wxConfig() {
let clientUrl = ''; let clientUrl = "";
let u = navigator.userAgent; let u = navigator.userAgent;
let isAndroid = u.indexOf('Android') > -1 || u.indexOf('Linux') > -1; //g let isAndroid = u.indexOf("Android") > -1 || u.indexOf("Linux") > -1; //g
let isIOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/); //ios终端 let isIOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/); //ios终端
if (isAndroid) { if (isAndroid) {
//这个是安卓操作系统 //这个是安卓操作系统
console.log('机型:android'); console.log("机型:android");
clientUrl = location.href clientUrl = location.href;
} }
if (isIOS) { if (isIOS) {
  //这个是ios操作系统 //这个是ios操作系统
console.log('机型:ios'); console.log("机型:ios");
clientUrl = location.href.split('#')[0]; clientUrl = location.href.split("#")[0];
} }
// let clientUrl = encodeURIComponent(location.href) // let clientUrl = encodeURIComponent(location.href)
// let url = $config.rootPath + '/js/sdk/getWxConfig?wxCode=' + $config.wxCode + '&clientUrl=' + clientUrl // let url = $config.rootPath + '/js/sdk/getWxConfig?wxCode=' + $config.wxCode + '&clientUrl=' + clientUrl
...@@ -265,37 +270,36 @@ export default { ...@@ -265,37 +270,36 @@ export default {
"hideOptionMenu" "hideOptionMenu"
] // 必填,需要使用的JS接口列表,所有JS接口列表见附录2 ] // 必填,需要使用的JS接口列表,所有JS接口列表见附录2
}); });
wx.ready(function () { wx.ready(function() {
wx.hideOptionMenu(); wx.hideOptionMenu();
}) });
}); });
}, },
addCardImage: function() { addCardImage: function() {
console.log("11111111"); console.log("11111111");
let self = this; let self = this;
// if(!self.cardUp){ // if(!self.cardUp){
wx.chooseImage({ wx.chooseImage({
count: 1, //张数, 默认9 count: 1, //张数, 默认9
sizeType: ["compressed"], //建议压缩图 sizeType: ["compressed"], //建议压缩图
sourceType: ["album", "camera"], // 来源是相册、相机 sourceType: ["album", "camera"], // 来源是相册、相机
success: function(res) { success: function(res) {
self.cardUp = res.localIds[0]; self.cardUp = res.localIds[0];
self.uploadToWeixinServer(res.localIds[0]); self.uploadToWeixinServer(res.localIds[0]);
} }
}); });
// }else{ // }else{
// if(self.attchmentId){ // if(self.attchmentId){
// this.previewImage(); // this.previewImage();
// } // }
// }
// }
}, },
//预览图片 //预览图片
previewImage() { previewImage() {
hlsPopup.showBigPicture({ hlsPopup.showBigPicture({
imgUrl: window.sessionStorage.cardUp1 imgUrl: window.sessionStorage.cardUp1
}) });
}, },
uploadToWeixinServer(localId) { uploadToWeixinServer(localId) {
let self = this; let self = this;
...@@ -310,29 +314,32 @@ export default { ...@@ -310,29 +314,32 @@ export default {
} }
}); });
}, },
uploadToserver(serverId){ uploadToserver(serverId) {
console.log('mediaId',serverId); console.log("mediaId", serverId);
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 param = { let param = {
openId: window.localStorage.openId, openId: window.localStorage.openId,
mediaId: serverId, mediaId: serverId,
sourceType: "app_file_id_card", sourceType: "app_file_id_card",
fileName: new Date().getTime() + '.jpg' 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.personName = res['姓名']; vm.personName = res["姓名"];
vm.identificationNumber = res['公民身份号码']; vm.identificationNumber = res["公民身份号码"];
vm.attchmentId = res["attchmentId"]; vm.attchmentId = res["attchmentId"];
window.sessionStorage.cardUp1 = process.env.rootPath + "/app/fileViewSvc?attachment_id=" + vm.attchmentId + "&apiName=download&sysName=HCL_UPLOAD_FILE&access_token=" + window.localStorage.access_token_rl; window.sessionStorage.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() { next_step() {
let vm = this; let vm = this;
if ( if (
!vm.personName || !vm.personName ||
...@@ -342,16 +349,13 @@ export default { ...@@ -342,16 +349,13 @@ export default {
) { ) {
vm.hlsPopup.showLongCenter("必输字端不能为空!"); vm.hlsPopup.showLongCenter("必输字端不能为空!");
return; return;
} } else if (vm.hlsUtil.isCardID(vm.identificationNumber)) {
else if(vm.hlsUtil.isCardID(vm.identificationNumber)) {
vm.hlsPopup.showLongCenter("身份证号有误"); vm.hlsPopup.showLongCenter("身份证号有误");
return; return;
} } else if (!vm.hlsUtil.phoneNumber(vm.phoneNumber)) {
else if(!vm.hlsUtil.phoneNumber(vm.phoneNumber)) {
vm.hlsPopup.showLongCenter("手机号码有误!"); vm.hlsPopup.showLongCenter("手机号码有误!");
return; return;
} } else {
else {
sessionStorage.setItem("personName", vm.personName); sessionStorage.setItem("personName", vm.personName);
sessionStorage.setItem("identificationNumber", vm.identificationNumber); sessionStorage.setItem("identificationNumber", vm.identificationNumber);
sessionStorage.setItem("phoneNumber", vm.phoneNumber); sessionStorage.setItem("phoneNumber", vm.phoneNumber);
...@@ -362,86 +366,96 @@ export default { ...@@ -362,86 +366,96 @@ export default {
idNo: vm.identificationNumber, idNo: vm.identificationNumber,
name: vm.personName, name: vm.personName,
mobile: vm.phoneNumber, mobile: vm.phoneNumber,
redirectUrl:"http://sign.hitachics.com/www/#/UserRegister/PersonalRegister?Regstatus=1" redirectUrl:
"http://sign.hitachics.com/www/#/UserRegister/PersonalRegister?Regstatus=1"
}; };
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();
if(res.code == 0){ if (res.code == 0) {
vm.$vux.toast.text(res.message, "middle"); vm.$vux.toast.text(res.message, "middle");
if (res.url) { if (res.url) {
window.open(res.url, "_self"); window.open(res.url, "_self");
} }
}else{ } else {
vm.$vux.toast.text(res.message, "middle"); vm.$vux.toast.text(res.message, "middle");
} }
}); });
} }
}, },
// 获取url地址参数 // 获取url地址参数
UrlSearch() { UrlSearch() {
var name, value; var name, value;
// var str="http://sign.hitachics.com/www/#/UserRegister/PersonalRegister?Regstatus=1&status=true&serviceId=1151815015435601748&verifycode=4accf0d2106f9c7361be72093e1fb793&contextId=10074&passed=true"; //取得整个地址栏 // var str="http://sign.hitachics.com/www/#/UserRegister/PersonalRegister?Regstatus=1&status=true&serviceId=1151815015435601748&verifycode=4accf0d2106f9c7361be72093e1fb793&contextId=10074&passed=true"; //取得整个地址栏
var str = window.location.href; //取得整个地址栏 var str = window.location.href; //取得整个地址栏
// alert(str) // alert(str)
var num = str.indexOf("?"); var num = str.indexOf("?");
str = str.substr(num + 1); //取得所有参数 stringvar.substr(start [, length ] str = str.substr(num + 1); //取得所有参数 stringvar.substr(start [, length ]
var arr = str.split("&"); //各个参数放到数组里 var arr = str.split("&"); //各个参数放到数组里
for (var i = 0; i < arr.length; i++) { for (var i = 0; i < arr.length; i++) {
num = arr[i].indexOf("="); num = arr[i].indexOf("=");
if (num > 0) { if (num > 0) {
name = arr[i].substring(0, num); name = arr[i].substring(0, num);
value = arr[i].substr(num + 1); value = arr[i].substr(num + 1);
this[name] = value; this[name] = value;
}
} }
}
}, },
// 认证结果返回给接口 // 认证结果返回给接口
authResult(id,code,suc){ authResult(id, code, suc) {
let vm = this;
let url = "http://sign.hitachics.com/core/api/public/listen/auth/result";
let param = {
"contextId": id,
"verifycode": code,
"success":suc
};
vm.hlsPopup.showLoading("请稍等");
vm.$post(url, param).then(function(res) {
vm.hlsPopup.hideLoading();
});
},
// 注销
logout(){
let vm = this; let vm = this;
let url = process.env.rootPath + "/accounts/outerAccounts/delete"; let url = "http://sign.hitachics.com/core/api/public/listen/auth/result";
let param = { let param = {
openId: window.localStorage.openId, contextId: id,
verifycode: code,
success: suc
}; };
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();
if(res.code == 0){ });
vm.$vux.toast.text(res.message, 'middle') },
window.open("http://sign.hitachics.com/www/#/UserRegister", "_self"); // 注销
}else{ logout() {
vm.$vux.toast.text(res.message, 'middle') let vm = this;
hlsPopup.showConfirm({
title: "签名成功",
content: "请确认合同是否都已下载完成,注销后无法下载,请知悉,谢谢!",
onConfirm: function(index) {
if (index === 1) {
let url = process.env.rootPath + "/accounts/outerAccounts/delete";
let param = {
openId: window.localStorage.openId
};
vm.hlsPopup.showLoading("请稍等");
vm.$post(url, param).then(function(res) {
vm.hlsPopup.hideLoading();
if (res.code == 0) {
vm.$vux.toast.text(res.message, "middle");
window.open(
"http://sign.hitachics.com/www/#/UserRegister",
"_self"
);
} else {
vm.$vux.toast.text(res.message, "middle");
}
});
} }
}
}); });
}, },
// 键盘消失,页面回到顶部 // 键盘消失,页面回到顶部
goTop(){ goTop() {
setTimeout(function() { setTimeout(function() {
var scrollHeight = document.documentElement.scrollTop || document.body.scrollTop || 0; var scrollHeight =
console.log(scrollHeight); document.documentElement.scrollTop || document.body.scrollTop || 0;
window.scrollTo(0, Math.max(scrollHeight, 0)); console.log(scrollHeight);
window.scrollTo(0, Math.max(scrollHeight, 0));
}, 100); }, 100);
} }
}, },
created(){ created() {
this.wxConfig(); this.wxConfig();
// wx.hideOptionMenu(); // wx.hideOptionMenu();
var Request = new this.UrlSearch(); //实例化 var Request = new this.UrlSearch(); //实例化
...@@ -449,18 +463,21 @@ export default { ...@@ -449,18 +463,21 @@ export default {
var contextId = Request.contextId; var contextId = Request.contextId;
var verifycode = Request.verifycode; var verifycode = Request.verifycode;
var success = Request.passed; var success = Request.passed;
if(this.status == 1){ if (this.status == 1) {
this.authResult(contextId,verifycode,success); this.authResult(contextId, verifycode, success);
} }
var data = this.$route.params.userInfo; var data = this.$route.params.userInfo;
if(data){ if (data) {
this.cardUp = process.env.rootPath + "/app/fileViewSvc?attachment_id=" + data.attachmentId + "&apiName=download&sysName=HCL_UPLOAD_FILE&access_token=" + window.localStorage.access_token_rl; this.cardUp =
process.env.rootPath +
"/app/fileViewSvc?attachment_id=" +
data.attachmentId +
"&apiName=download&sysName=HCL_UPLOAD_FILE&access_token=" +
window.localStorage.access_token_rl;
this.identificationNumber = data.idNo; this.identificationNumber = data.idNo;
this.phoneNumber = data.mobile; this.phoneNumber = data.mobile;
this.personName = data.name; this.personName = data.name;
} }
} }
}; };
</script> </script>
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<h-view class="public-style companyRegister" title="企业用户注册"> <h-view class="public-style companyRegister" title="企业用户注册">
<h-content> <h-content>
<list-item class="reg-content"> <list-item class="reg-content">
<div class="repre-type"> <!-- <div class="repre-type">
代理店 代理店
<input <input
type="radio" type="radio"
...@@ -19,8 +19,8 @@ ...@@ -19,8 +19,8 @@
value="N" value="N"
disabled disabled
/> />
</div> </div>-->
<div class="repre-type" v-if="agentType == 'Y'"> <div class="repre-type">
<span>经办人类型:</span> <span>经办人类型:</span>
<input <input
type="radio" type="radio"
...@@ -296,8 +296,8 @@ export default { ...@@ -296,8 +296,8 @@ export default {
attachmentId: "", attachmentId: "",
orgAttachmentId: "", orgAttachmentId: "",
attachmentId1: "", attachmentId1: "",
orgAttachmentId1: "", orgAttachmentId1: ""
agentType: "" // agentType: ""
}; };
}, },
components: { components: {
...@@ -342,18 +342,31 @@ export default { ...@@ -342,18 +342,31 @@ export default {
}, },
logout() { logout() {
let vm = this; let vm = this;
let url = process.env.rootPath + "/organizations/outerOrgans/delete"; hlsPopup.showConfirm({
let param = { title: "提示",
openId: window.localStorage.openId content: "请确认合同是否都已下载完成,注销后无法下载,请知悉,谢谢!",
}; onConfirm: function(index) {
vm.hlsPopup.showLoading("请稍等"); if (index === 1) {
vm.$post(url, param).then(function(res) { let url =
vm.hlsPopup.hideLoading(); process.env.rootPath + "/organizations/outerOrgans/delete";
if (res.code == 0) { let param = {
vm.$vux.toast.text(res.message, "middle"); openId: window.localStorage.openId
window.open("http://sign.hitachics.com/www/#/UserRegister", "_self"); };
} else { vm.hlsPopup.showLoading("请稍等");
vm.$vux.toast.text(res.message, "middle"); vm.$post(url, param).then(function(res) {
vm.hlsPopup.hideLoading();
if (res.code == 0) {
vm.$vux.toast.text(res.message, "middle");
window.open(
"http://sign.hitachics.com/www/#/UserRegister",
"_self"
);
} else {
vm.$vux.toast.text(res.message, "middle");
}
});
}
console.log(index);
} }
}); });
}, },
...@@ -396,11 +409,11 @@ export default { ...@@ -396,11 +409,11 @@ export default {
"hideOptionMenu" "hideOptionMenu"
] // 必填,需要使用的JS接口列表,所有JS接口列表见附录2 ] // 必填,需要使用的JS接口列表,所有JS接口列表见附录2
}); });
wx.ready(function () { wx.ready(function() {
wx.hideOptionMenu(); wx.hideOptionMenu();
}) });
}); });
}, }
}, },
created() { created() {
this.wxConfig(); this.wxConfig();
...@@ -408,7 +421,7 @@ export default { ...@@ -408,7 +421,7 @@ export default {
var agentType = data.agentType; var agentType = data.agentType;
console.log(data); console.log(data);
if (agentType == 1) { if (agentType == 1) {
this.agentType = data.dealerFlag; // this.agentType = data.dealerFlag;
this.organizationName = data.name; this.organizationName = data.name;
this.socialCode = data.idNo; this.socialCode = data.idNo;
this.legalRepresentativeName = data.legalName; this.legalRepresentativeName = data.legalName;
...@@ -429,7 +442,7 @@ export default { ...@@ -429,7 +442,7 @@ export default {
"&apiName=download&sysName=HCL_UPLOAD_FILE&access_token=" + "&apiName=download&sysName=HCL_UPLOAD_FILE&access_token=" +
window.localStorage.access_token_rl; window.localStorage.access_token_rl;
} else if (agentType == 2) { } else if (agentType == 2) {
this.agentType = data.dealerFlag; // this.agentType = data.dealerFlag;
this.staffType = "组织其他员工"; this.staffType = "组织其他员工";
this.jbName = data.agentName; this.jbName = data.agentName;
this.jbPhoneNumber = data.mobile; this.jbPhoneNumber = data.mobile;
......
...@@ -93,25 +93,33 @@ export default { ...@@ -93,25 +93,33 @@ export default {
imgUrl: vm.cardUp imgUrl: vm.cardUp
}); });
}, },
// 注销
logout() { logout() {
let vm = this; let vm = this;
let url = process.env.rootPath + "/accounts/outerAccounts/delete"; hlsPopup.showConfirm({
let param = { title: "签名成功",
openId: window.localStorage.openId content: "请确认合同是否都已下载完成,注销后无法下载,请知悉,谢谢!",
}; onConfirm: function(index) {
vm.hlsPopup.showLoading("请稍等"); if (index === 1) {
vm.$post(url, param).then(function(res) { let url = process.env.rootPath + "/accounts/outerAccounts/delete";
vm.hlsPopup.hideLoading(); let param = {
if (res.code == 0) { openId: window.localStorage.openId
vm.$vux.toast.text(res.message, "middle"); };
window.open( vm.hlsPopup.showLoading("请稍等");
"http://sign.hitachics.com/www/#/UserRegister", vm.$post(url, param).then(function(res) {
"_self" vm.hlsPopup.hideLoading();
); if (res.code == 0) {
} else { vm.$vux.toast.text(res.message, "middle");
vm.$vux.toast.text(res.message, "middle"); window.open(
"http://sign.hitachics.com/www/#/UserRegister",
"_self"
);
} else {
vm.$vux.toast.text(res.message, "middle");
}
});
}
} }
// vm.$vux.toast.text(res.message, "middle");
}); });
}, },
// 调用微信接口的基础配置 // 调用微信接口的基础配置
......
...@@ -5,30 +5,36 @@ ...@@ -5,30 +5,36 @@
<!-- <header class="header"> <!-- <header class="header">
<input v-model="searchInput" placeholder="请输入功能名"> <input v-model="searchInput" placeholder="请输入功能名">
<img src="../assets/image/home/functionList@2x.png" @click="search"> <img src="../assets/image/home/functionList@2x.png" @click="search">
</header> --> </header>-->
<!-- <swipe :interval="5000" :showIndicators="false" class="swipe"> <!-- <swipe :interval="5000" :showIndicators="false" class="swipe">
<swipe-item v-for="img in imgList" :key="img.pictureUrl"> <swipe-item v-for="img in imgList" :key="img.pictureUrl">
<img :src="img.pictureUrl"> <img :src="img.pictureUrl">
</swipe-item> </swipe-item>
</swipe> --> </swipe>-->
<!-- <div class="function"> <!-- <div class="function">
<function-item <function-item
v-for="item in moduleSeparateList.slice(0,4)" :key="item.moduleId" :functionIcon="item.moduleIcon" v-for="item in moduleSeparateList.slice(0,4)" :key="item.moduleId" :functionIcon="item.moduleIcon"
:functionName="item.moduleName" :functionName="item.moduleName"
:data="item" @clickFunction="goModuleFunction"/> --> :data="item" @clickFunction="goModuleFunction"/>-->
<!--<function-item :functionIcon="require('../assets/image/home/allFunction@2x.png')" :functionName="'全部'" @clickFunction="goAllFunction"/>--> <!--<function-item :functionIcon="require('../assets/image/home/allFunction@2x.png')" :functionName="'全部'" @clickFunction="goAllFunction"/>-->
<!-- </div> --> <!-- </div> -->
</div> </div>
<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" style="width:33.3%" :key="item.functionId"
:data="item" class="function-item vue-1px" @clickFunction="goFunctionHome"/> :functionIcon="item.functionIcon"
<!-- <div class="function-item" @click="goAllFunction"> :functionName="item.functionName"
style="width:33.3%"
:data="item"
class="function-item vue-1px"
@clickFunction="goFunctionHome"
/>
<!-- <div class="function-item" @click="goAllFunction">
<img src="../assets/image/home/functionMore@2x.png"> <img src="../assets/image/home/functionMore@2x.png">
</div>--> </div>-->
</div> </div>
</div> </div>
<!-- <div class="important-message"> <!-- <div class="important-message">
...@@ -42,7 +48,7 @@ ...@@ -42,7 +48,7 @@
</ul> </ul>
<ul id="p2"/> <ul id="p2"/>
</div> </div>
</div> --> </div>-->
<!-- <div class="middle-box bottom-box"> <!-- <div class="middle-box bottom-box">
<header>为您推荐<span @click="moreRecommend">更多</span></header> <header>为您推荐<span @click="moreRecommend">更多</span></header>
<div class="function"> <div class="function">
...@@ -50,17 +56,17 @@ ...@@ -50,17 +56,17 @@
<img :src="item.recommendUrl"> <img :src="item.recommendUrl">
</div> </div>
</div> </div>
</div> --> </div>-->
</h-content> </h-content>
</h-view> </h-view>
</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: [],
...@@ -70,33 +76,37 @@ export default { ...@@ -70,33 +76,37 @@ export default {
area: {}, area: {},
box1: {}, box1: {},
box2: {}, box2: {},
searchInput: '', searchInput: "",
} subscribe: false
}, };
beforeCreate: function () {
}, },
created: function () { beforeCreate: function() {},
this.wxConfig(); created: function() {
// debugger; // debugger;
// window.localStorage.setItem('user_id', 2009) // window.localStorage.setItem('user_id', 2009)
// this.imgList = [...functionState.bannerList] // this.imgList = [...functionState.bannerList]
// this.recommendList = [...functionState.recommendList] // this.recommendList = [...functionState.recommendList]
this.moduleSeparateList = [...functionState.moduleSeparateList] this.moduleSeparateList = [...functionState.moduleSeparateList];
this.moduleSeparateList.forEach(item => { this.moduleSeparateList.forEach(item => {
this.functionList = this.functionList.concat(item.functions) this.functionList = this.functionList.concat(item.functions);
}) });
this.getToken().then(res => { this.getToken().then(res => {
this.wxConfig();
// if (window.localStorage.openId) {
// this.getWxUserInfo(window.localStorage.openId);
// }
// this.noticeQuery() // this.noticeQuery()
// 注意,此处用户个人信息是写死的user_id 后续项目实施中根据以下代码实时获取企业通讯录个人信息 // 注意,此处用户个人信息是写死的user_id 后续项目实施中根据以下代码实时获取企业通讯录个人信息
var code = getUrlParam('code'); var code = getUrlParam("code");
// code = '111'; // code = "111";
if(code){ if (code) {
this.getOpenId(code); this.getOpenId(code);
}
}) }
}, this.subscribe = window.localStorage.subscribe;
updated: function () { });
}, },
updated: function() {},
methods: { methods: {
// 获取中台token // 获取中台token
// hlsSupportToken () { // hlsSupportToken () {
...@@ -117,7 +127,7 @@ export default { ...@@ -117,7 +127,7 @@ export default {
// vm.messageList = res.notice_msg_list // vm.messageList = res.notice_msg_list
// }) // })
// }, // },
// 调用微信接口的基础配置 // 调用微信接口的基础配置
wxConfig() { wxConfig() {
let clientUrl = ""; let clientUrl = "";
let u = navigator.userAgent; let u = navigator.userAgent;
...@@ -156,9 +166,9 @@ export default { ...@@ -156,9 +166,9 @@ export default {
"hideOptionMenu" "hideOptionMenu"
] // 必填,需要使用的JS接口列表,所有JS接口列表见附录2 ] // 必填,需要使用的JS接口列表,所有JS接口列表见附录2
}); });
wx.ready(function () { wx.ready(function() {
wx.hideOptionMenu(); wx.hideOptionMenu();
}) });
}); });
}, },
// search () { // search () {
...@@ -189,7 +199,7 @@ export default { ...@@ -189,7 +199,7 @@ export default {
// }, // },
// }) // })
// }, // },
getToken () { getToken() {
let vm = this; let vm = this;
let url = process.env.loginPathRl + "admin"; let url = process.env.loginPathRl + "admin";
let param = {}; let param = {};
...@@ -197,225 +207,253 @@ export default { ...@@ -197,225 +207,253 @@ export default {
window.localStorage.setItem("access_token_rl", res.access_token); window.localStorage.setItem("access_token_rl", res.access_token);
}); });
}, },
goFunctionHome (data) { goFunctionHome(data) {
this.$router.push({ if (this.subscribe) {
name: data.functionState, this.$router.push({
}) name: data.functionState
});
} else {
hlsPopup.showPopup({
title: "提示",
content: "未关注公众号,请先关注后再进入!",
onConfirm() {}
});
}
}, },
// moreRecommend () { // moreRecommend () {
// console.log('go moreRecommend') // console.log('go moreRecommend')
// }, // },
getOpenId (code) { getOpenId(code) {
let vm = this let vm = this;
let url = process.env.basePathRl + "getOpenId"; let url = process.env.basePathRl + "getOpenId";
let param = { let param = {
"apiKey":"handexinxi", apiKey: "handexinxi",
"code": code code: code
} };
// window.localStorage.openId = "1234567" // window.localStorage.openId = "oBdoRwI9gj9Brbe9iqlDCg5G2dDc";
vm.hlsHttp.post(url,param).then(function (res) { // vm.getWxUserInfo(window.localStorage.openId);
vm.hlsHttp.post(url, param).then(function(res) {
if (res.resultCode == "00") { if (res.resultCode == "00") {
window.localStorage.openId = res.result; window.localStorage.openId = res.result;
if (window.localStorage.openId) {
vm.getWxUserInfo(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);
}
});
}
}
};
</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;
}
&:after {
.setBottomLine();
} }
}
.middle-box { span {
margin-top: 8px; font-size: 12px;
background: white; color: #878a8d;
position: absolute;
right: 15px;
}
}
.function {
display: flex;
flex-wrap: wrap;
header { .function-item {
height: 33px; width: 25%;
display: flex; height: 89px;
align-items: center; font-size: 12px;
line-height: 100%; // border: 1px solid rgba(169,169,169,0.1); /*no*/
color: #5D98F6; /deep/ img {
position: relative; height: 30px;
width: 30px;
margin: 23px 28px 9px 33px;
}
&:before { &:before {
content: ''; .setBottomLine();
width: 4px;
height: 15px;
margin-right: 9px;
margin-left: 10px;
background-image: linear-gradient(-180deg, #5D98F6 0%, #76BCEE 100%);
border-radius: 2px;
} }
&:after { &:after {
.setBottomLine() .setRightLine();
}
span {
font-size: 12px;
color: #878A8D;
position: absolute;
right: 15px;
} }
} }
.function{
display: flex;
flex-wrap: wrap;
.function-item { /*.function-item:last-child{
width: 25%;
height: 89px;
font-size: 12px;
// border: 1px solid rgba(169,169,169,0.1); /*no*/
/deep/ img {
height: 30px;
width: 30px;
margin: 23px 28px 9px 33px;
}
&:before {
.setBottomLine();
}
&:after {
.setRightLine();
}
}
/*.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;
...@@ -440,18 +478,18 @@ export default { ...@@ -440,18 +478,18 @@ export default {
} }
}*/ }*/
.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>
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