@@ -396,6 +396,18 @@ | |||||
this.isnorefresh = 'refresh'; | this.isnorefresh = 'refresh'; | ||||
this.userInfo = uni.getStorageSync("weapp_session_userInfo_data") | this.userInfo = uni.getStorageSync("weapp_session_userInfo_data") | ||||
console.log(this.userInfo.showPhoneStatus) | console.log(this.userInfo.showPhoneStatus) | ||||
if (this.isnorefresh == 'refresh') { | |||||
this.buildingID = uni.getStorageSync('buildingID').id; | |||||
this.nextPage = 1; | |||||
this.recordList = [] | |||||
// this.getMyCustom() | |||||
this.getFreeList() | |||||
this.getfindKeywordsList() | |||||
this.getFromSource(); | |||||
// this.isnorefresh = ''; | |||||
this.isRefresh = false; | |||||
this.getMyCustom() | |||||
} | |||||
}, | }, | ||||
onPullDownRefresh() { | onPullDownRefresh() { | ||||
@@ -417,18 +429,7 @@ | |||||
let newmenulist = uni.getStorageSync('weapp_session_Menu_data'); | let newmenulist = uni.getStorageSync('weapp_session_Menu_data'); | ||||
this.permissions.commonly1 = newmenulist.khgl_ck; | this.permissions.commonly1 = newmenulist.khgl_ck; | ||||
this.permissions.commonly2 = newmenulist.khgl_gj; | this.permissions.commonly2 = newmenulist.khgl_gj; | ||||
if (this.isnorefresh == 'refresh') { | |||||
this.buildingID = uni.getStorageSync('buildingID').id; | |||||
this.nextPage = 1; | |||||
this.recordList = [] | |||||
// this.getMyCustom() | |||||
this.getFreeList() | |||||
this.getfindKeywordsList() | |||||
this.getFromSource(); | |||||
// this.isnorefresh = ''; | |||||
this.isRefresh = false; | |||||
this.getMyCustom() | |||||
} | |||||
}, | }, | ||||
onReachBottom() { | onReachBottom() { | ||||
if (this.totalRecord == this.nextPage) { | if (this.totalRecord == this.nextPage) { | ||||
@@ -168,10 +168,21 @@ | |||||
var i = uni.getStorageSync('fendianindex') | var i = uni.getStorageSync('fendianindex') | ||||
this.buildingID = uni.getStorageSync('buildingID').id; | this.buildingID = uni.getStorageSync('buildingID').id; | ||||
this.clocktab(i) | this.clocktab(i) | ||||
this.leftIndex = 0 | |||||
this.infoinit() | |||||
// this.leftIndex = 0 | |||||
// this.infoinit() | |||||
let left = uni.getStorageSync('left'); | |||||
if(left!=undefined){ | |||||
this.leftIndex = left.split(',')[0] | |||||
this.getSecond(left.split(',')[1]) | |||||
this.infoinit(left.split(',')[1]) | |||||
}else{ | |||||
this.leftIndex = 0 | |||||
this.infoinit() | |||||
} | |||||
}, | }, | ||||
// onLoad() { | |||||
// this.infoinit() | |||||
// }, | |||||
methods: { | methods: { | ||||
// 跳转部分学习 | // 跳转部分学习 | ||||
quclicks(item) { | quclicks(item) { | ||||
@@ -249,7 +260,10 @@ | |||||
routerclick(item, index) { | routerclick(item, index) { | ||||
if (this.leftIndex === index) return | if (this.leftIndex === index) return | ||||
this.leftIndex = index | this.leftIndex = index | ||||
this.getSecond(this.equinoctial[index].marketingId) | |||||
uni.setStorageSync("left", index+','+item.marketingId); //写入缓存 | |||||
let mid = uni.getStorageSync('left').split(',')[1] | |||||
this.getSecond(mid) | |||||
// // return | // // return | ||||
// uni.navigateTo({ | // uni.navigateTo({ | ||||
// url: "/pages/learning/Equinoctiallearning?id=" + item.marketingId + "&biaoqian=" + item.name | // url: "/pages/learning/Equinoctiallearning?id=" + item.marketingId + "&biaoqian=" + item.name | ||||
@@ -263,7 +277,14 @@ | |||||
this.ceninit() | this.ceninit() | ||||
} else { | } else { | ||||
uni.setStorageSync("fendianindex", 1); //写入缓存 | uni.setStorageSync("fendianindex", 1); //写入缓存 | ||||
this.infoinit() | |||||
this.leftIndex = uni.getStorageSync('left').split(',')[0] | |||||
let mid = uni.getStorageSync('left').split(',')[1] | |||||
if(mid!=undefined){ | |||||
this.getSecond(mid) | |||||
}else{ | |||||
this.infoinit() | |||||
} | |||||
} | } | ||||
}, | }, | ||||
@@ -332,7 +353,7 @@ | |||||
}, | }, | ||||
infoinit() { | |||||
infoinit(mid) { | |||||
let obj = { | let obj = { | ||||
itemId: this.buildingID | itemId: this.buildingID | ||||
} | } | ||||
@@ -347,7 +368,11 @@ | |||||
success: (data) => { | success: (data) => { | ||||
if (data.data.code == 10000) { | if (data.data.code == 10000) { | ||||
this.equinoctial = data.data.data | this.equinoctial = data.data.data | ||||
this.getSecond(data.data.data[0].marketingId) | |||||
if(mid!=undefined){ | |||||
this.getSecond(mid) | |||||
}else{ | |||||
this.getSecond(data.data.data[0].marketingId) | |||||
} | |||||
} else { | } else { | ||||
uni.showToast({ | uni.showToast({ | ||||
title: data.data.message, | title: data.data.message, | ||||
@@ -1,7 +1,7 @@ | |||||
<template> | <template> | ||||
<view class="registerCode"> | <view class="registerCode"> | ||||
<view class="registerImg"> | <view class="registerImg"> | ||||
<image :src="qrCodeUrl+'/customer/getQrCode?page=pages/mine/registerForm&scene='+projectId" mode=""></image> | |||||
<image :src="qrCodeUrl+'/customer/getQrCode?appid='+appid+'&page=pages/mine/registerForm&scene='+projectId" mode=""></image> | |||||
</view> | </view> | ||||
<view class="registerBtn" @click="down"> | <view class="registerBtn" @click="down"> | ||||
保存图片到手机 | 保存图片到手机 | ||||
@@ -15,15 +15,18 @@ | |||||
data() { | data() { | ||||
return { | return { | ||||
qrCodeUrl: "", | qrCodeUrl: "", | ||||
projectId:"" | |||||
projectId:"", | |||||
appid:"", | |||||
}; | }; | ||||
}, | }, | ||||
onShow() { | onShow() { | ||||
this.projectId = uni.getStorageSync('buildingID').id; | this.projectId = uni.getStorageSync('buildingID').id; | ||||
this.appid = uni.getAccountInfoSync().miniProgram.appId; | |||||
this.qrCodeUrl = domain.baseUrl; | |||||
}, | }, | ||||
methods: { | methods: { | ||||
down() { | down() { | ||||
let url = this.qrCodeUrl+'/customer/getQrCode?page=pages/mine/registerForm&scene='+this.projectId | |||||
let url = this.qrCodeUrl+'/customer/getQrCode?appid='+this.appid+'&page=pages/mine/registerForm&scene='+this.projectId | |||||
console.log(url) | console.log(url) | ||||
uni.getImageInfo({ | uni.getImageInfo({ | ||||
src:url, | src:url, | ||||
@@ -34,7 +37,7 @@ | |||||
success: () => { | success: () => { | ||||
uni.showToast({ | uni.showToast({ | ||||
title: "保存成功", | title: "保存成功", | ||||
icon: "none" | |||||
icon: "none", | |||||
}) | }) | ||||
}, | }, | ||||
fail: () => { | fail: () => { | ||||
@@ -108,22 +111,6 @@ | |||||
} | } | ||||
}, | }, | ||||
onLoad() { | |||||
this.qrCodeUrl = domain.baseUrl | |||||
// let urlData = { | |||||
// page:'pages/mine/registerForm', | |||||
// scene:'556', | |||||
// width:300 | |||||
// } | |||||
// uni.request({ | |||||
// url:this.qrCodeUrl + '/customer/getQrCode', | |||||
// method:"POST", | |||||
// data:urlData, | |||||
// success(res) { | |||||
// console.log(res) | |||||
// } | |||||
// }) | |||||
} | |||||
} | } | ||||
</script> | </script> | ||||
@@ -33,7 +33,6 @@ | |||||
</view> | </view> | ||||
</view> | </view> | ||||
</view> | </view> | ||||
<view class="title" @click="Buildingselection()"> | <view class="title" @click="Buildingselection()"> | ||||
<view class="titletext">到访途径</view> | <view class="titletext">到访途径</view> | ||||
<view class="titletext2" | <view class="titletext2" | ||||
@@ -67,7 +66,6 @@ | |||||
<u-select :mask-close-able="false" v-model="Showhiddenunits" mode="single-column" :list="list" | <u-select :mask-close-able="false" v-model="Showhiddenunits" mode="single-column" :list="list" | ||||
@cancel="cancel" @confirm="confirm"></u-select> | @cancel="cancel" @confirm="confirm"></u-select> | ||||
</view> | </view> | ||||
</view> | </view> | ||||
</template> | </template> | ||||
@@ -106,7 +104,7 @@ | |||||
onLoad(options){ | onLoad(options){ | ||||
const sceneStr = decodeURIComponent(options.scene); | const sceneStr = decodeURIComponent(options.scene); | ||||
console.log(options) | console.log(options) | ||||
this.projectId = sceneStr | |||||
this.parames.projectId = sceneStr | |||||
}, | }, | ||||
watch:{ | watch:{ | ||||
parames:{ | parames:{ | ||||
@@ -122,27 +120,28 @@ | |||||
}, | }, | ||||
methods: { | methods: { | ||||
save() { | |||||
save() { | |||||
if (this.parames.name.length == 0) { | if (this.parames.name.length == 0) { | ||||
uni.showToast({ | |||||
uni.showToast({ | |||||
icon: "none", | icon: "none", | ||||
title: "姓名不能为空" | title: "姓名不能为空" | ||||
}) | }) | ||||
return; | return; | ||||
} | } | ||||
}, | }, | ||||
getPhoneNumber(e){ | |||||
console.log(e) | |||||
getPhoneNumber(e){ | |||||
this.qrCodeUrl = domain.baseUrl | this.qrCodeUrl = domain.baseUrl | ||||
if(e.detail.errMsg=="getPhoneNumber:ok"){ | if(e.detail.errMsg=="getPhoneNumber:ok"){ | ||||
let data = { | let data = { | ||||
code:e.detail.code, | code:e.detail.code, | ||||
appid:uni.getAccountInfoSync().miniProgram.appId, | |||||
} | } | ||||
uni.request({ | uni.request({ | ||||
url:this.qrCodeUrl + '/code/loginSessionKey', | url:this.qrCodeUrl + '/code/loginSessionKey', | ||||
method:"GET", | method:"GET", | ||||
data, | data, | ||||
success:(res)=> { | success:(res)=> { | ||||
console.log(res.data.data) | |||||
let phoneNum = JSON.parse(res.data.data).phone_info.phoneNumber | let phoneNum = JSON.parse(res.data.data).phone_info.phoneNumber | ||||
this.parames.phone = phoneNum | this.parames.phone = phoneNum | ||||
if(this.parames.phone!=null && this.parames.phone!=""){ | if(this.parames.phone!=null && this.parames.phone!=""){ | ||||
@@ -161,14 +160,19 @@ | |||||
'Access-Token': uni.getStorageSync('weapp_session_login_data').token | 'Access-Token': uni.getStorageSync('weapp_session_login_data').token | ||||
}, | }, | ||||
success: (addres) => { | success: (addres) => { | ||||
console.log(addres.data,111) | |||||
if(addres.data.code == 10000){ | if(addres.data.code == 10000){ | ||||
uni.reLaunch({ | uni.reLaunch({ | ||||
url:'/pages/mine/registerResult' | url:'/pages/mine/registerResult' | ||||
}) | }) | ||||
}else{ | |||||
uni.showToast({ | |||||
icon: "none", | |||||
title: addres.data.message | |||||
}) | |||||
} | } | ||||
} | } | ||||
}) | }) | ||||
} | } | ||||
} | } | ||||
@@ -177,7 +181,6 @@ | |||||
}else{ | }else{ | ||||
return; | return; | ||||
} | } | ||||
}, | }, | ||||
changeSex(sex) { | changeSex(sex) { | ||||
this.parames.sex = sex; | this.parames.sex = sex; | ||||
@@ -2,8 +2,8 @@ | |||||
// const base = 'http://8kdmng.natappfree.cc' ;// 佳豪 | // const base = 'http://8kdmng.natappfree.cc' ;// 佳豪 | ||||
// const base = 'http://192.168.31.134:9999' ;// 佳豪 | // const base = 'http://192.168.31.134:9999' ;// 佳豪 | ||||
// const base = 'http://192.168.31.167:9999' // 长龙 | // const base = 'http://192.168.31.167:9999' // 长龙 | ||||
const base = 'https://zanyong.hfju.com';// 正式 AI销管 | |||||
// const base = 'https://hxz.quhouse.com';// 正式 AI销讲助手 | |||||
// const base = 'https://zanyong.hfju.com';// 正式 AI销管 | |||||
const base = 'https://hxz.quhouse.com';// 正式 AI销讲助手 | |||||
// http.js使用 | // http.js使用 | ||||
const baseUrl = `${base}/autoSR/api`; | const baseUrl = `${base}/autoSR/api`; | ||||