diff --git a/common/http.interceptor.js b/common/http.interceptor.js index 02a1480..14b0395 100644 --- a/common/http.interceptor.js +++ b/common/http.interceptor.js @@ -5,7 +5,7 @@ const install = (Vue, vm) => { Vue.prototype.$u.http.setConfig({ // baseUrl: 'http://61.174.243.28:15861', // baseUrl: 'http://192.168.2.46:8080', - // baseUrl: 'http://124.221.246.124:2289', + // baseUrl: 'https://che.chuangtewl.com/prod-api', // baseUrl: 'https://dianche.chuantewulian.cn/prod-api', baseUrl: 'https://dche.ccttiot.com/prod-api', loadingText: '努力加载中~', diff --git a/page_vip/buyCard.vue b/page_vip/buyCard.vue new file mode 100644 index 0000000..cf60c34 --- /dev/null +++ b/page_vip/buyCard.vue @@ -0,0 +1,415 @@ +<template> + <view class="page"> + <u-navbar title="购买骑行卡" :border-bottom="false" :background="bgc" title-color='#000' title-size='36' + height='45'></u-navbar> + + <view class="cont"> + <view class="card1"> + <view class="txt1"> + 购卡后预计每月可省 <span> 18.1</span>元 + </view> + <view class="txt2"> + 我的骑行卡 <image src="https://lxnapi.ccttiot.com/bike/img/static/uC5tdSEpQIUUbFDToiso" mode=""></image> + </view> + </view> + <view class="card2"> + <view class="card3" style="margin-top: 85rpx;"> + <view class="top"> + <view class="tit1"> + 电单车15天5次卡 + </view> + <view class="tit2"> + 5.25 <span style="font-size: 28rpx;">元</span> + </view> + </view> + <view class="middle"> + <view class="tit3"> + 电单车15天5次卡 + </view> + <view class="tit4"> + 5.25元 + </view> + </view> + <view class="bot"> + <view class="bot_left"> + <view class="txt3"> + 低至1.05元/次 + </view> + <view class="txt4"> + 已优惠 <span style="color: red;">9.75</span>元 + </view> + </view> + </view> + </view> + </view> + <view class="card3"> + <view class="top"> + <view class="tit1"> + 电单车15天5次卡 + </view> + <view class="tit2"> + 5.25<span style="font-size: 28rpx;">元</span> + </view> + </view> + <view class="middle"> + <view class="tit3"> + 电单车15天5次卡 + </view> + <view class="tit4"> + 5.25元 + </view> + </view> + <view class="bot"> + <view class="bot_left"> + <view class="txt3"> + 低至1.05元/次 + </view> + <view class="txt4"> + 已优惠 <span style="color: red;">9.75</span>元 + </view> + </view> + <view class="btn"> + 购买 + </view> + </view> + </view> + + </view> + <u-mask :show="show" :z-index='100' /> + <view class="buy_box" v-if="false"> + <view class="taocan"> + <view class="top"> + <view class="tit1"> + 电单车15天5次卡 + </view> + <view class="tit2"> + 5.25<span style="font-size: 28rpx;">元</span> + </view> + </view> + <view class="bot"> + <view class="bot_left"> + <view class="txt4"> + 每单最高抵3元 + </view> + <view class="txt3"> + 低至1.05元/次 + </view> + + </view> + </view> + </view> + <view class="tit_txt"> + 每次骑行最高可抵扣 <span>3元</span> + </view> + <view class="text"> + 只能用于抵扣骑行费用,不能抵扣调度费、预约费等费 + 用。如您正常的骑行费用超过最高抵扣金额,需另支付 + 差额。 + </view> + <view class="tit_txt"> + 全国可用 + </view> + <view class="text"> + 不包括景区等特殊区域 + </view> + <view class="btns_box"> + <view class="btn1"> + 取消 + </view> + <view class="btn2"> + 立即支付 + </view> + </view> + </view> + </view> +</template> + +<script> + export default { + data() { + return { + bgc: { + backgroundColor: '#fff' + }, + sn: '', + istrue: false, + show:false + } + }, + + methods: { + + } + } +</script> + +<style lang="scss"> + page { + background-color: #fff; + } + + .page { + width: 750rpx; + .buy_box { + padding: 0 46rpx; + position: fixed; + bottom: 0; + width: 750rpx; + height: 780rpx !important; + background: #FDFDFD; + border-radius: 0rpx 0rpx 0rpx 0rpx; + z-index: 101; + position: relative; + + .tit_txt { + padding-top: 114rpx; /* 使用 padding-top 或者增加 overflow: hidden 来防止 margin 合并 */ + font-weight: 600; + font-size: 28rpx; + color: #3D3D3D; + overflow: hidden; /* 防止 margin 合并 */ + + span { + color: #64B6A7; + } + } + + .text { + margin-top: 16rpx; + font-weight: 400; + font-size: 28rpx; + color: #3D3D3D; + } + + .taocan { + padding: 46rpx 40rpx; + position: absolute; + top: -140rpx; + left: 36rpx; + width: 680rpx; + height: 204rpx; + background: #fff; + border-radius: 20rpx; + z-index: 102; + box-shadow: 0rpx 10rpx 64rpx 0rpx rgba(0, 0, 0, 0.08), 0rpx 10rpx 64rpx 0rpx rgba(0, 0, 0, 0.08); + + .top { + display: flex; + align-items: center; + justify-content: space-between; + + .tit1 { + font-weight: 500; + font-size: 32rpx; + color: #2F3240; + } + + .tit2 { + font-weight: 500; + font-size: 40rpx; + color: #E46666; + } + } + + .bot_left { + margin-top: 20rpx; + display: flex; + align-items: center; + justify-content: space-between; + + .txt3 { + padding: 4rpx 12rpx; + background: linear-gradient(90deg, rgba(228, 102, 102, 0.42) 0%, rgba(228, 102, 102, 0) 100%); + border-radius: 6rpx; + font-weight: 400; + font-size: 24rpx; + color: #E46666; + } + + .txt4 { + font-weight: 500; + font-size: 24rpx; + color: #808080; + } + } + } + + .btns_box { + display: flex; + flex-wrap: nowrap; + padding-top: 30rpx; + // align-items: center; + justify-content: space-around; + position: absolute; + bottom: 0; + left: 0; + width: 750rpx; + height: 184rpx; + background: #FFFFFF; + box-shadow: 0rpx 10rpx 64rpx 0rpx rgba(0, 0, 0, 0.08), 0rpx 10rpx 64rpx 0rpx rgba(0, 0, 0, 0.08); + z-index: 200; + .btn1{ + display: flex; + align-items: center; + justify-content: center; + width: 338rpx; + height: 90rpx; + border-radius: 45rpx 45rpx 45rpx 45rpx; + border: 2rpx solid #808080; + font-weight: 500; + font-size: 36rpx; + color: #808080; + } + .btn2{ + display: flex; + align-items: center; + justify-content: center; + width: 338rpx; + height: 90rpx; + background: #64B6A7; + border-radius: 45rpx 45rpx 45rpx 45rpx; + font-weight: 500; + font-size: 36rpx; + color: #FFFFFF; + } + } + } + + + + .cont { + display: flex; + flex-wrap: wrap; + justify-content: center; + + .card1{ + display: flex; + flex-wrap: nowrap; + justify-content: space-between; + align-items: center; + padding: 28rpx; + width: 680rpx; + height: 106rpx; + background: rgba(100,182,167,0.25); + box-shadow: 0rpx 10rpx 64rpx 0rpx rgba(0,0,0,0.08); + border-radius: 20rpx 20rpx 20rpx 20rpx; + .txt1{ + font-weight: 600; + font-size: 32rpx; + color: #3D3D3D; + span{ + color: #E46666; + + } + } + .txt2{ + font-weight: 400; + font-size: 24rpx; + color: #2F3240; + image{ + margin-left: 16rpx; + width: 8rpx; + height: 16rpx; + } + } + } + .card3{ + margin-top: 16rpx; + padding: 46rpx 40rpx; + width: 680rpx; + height: 238rpx; + background: #FFFFFF; + box-shadow: 0rpx 10rpx 64rpx 0rpx rgba(0,0,0,0.08); + border-radius: 20rpx 20rpx 20rpx 20rpx; + .top{ + display: flex; + flex-wrap: nowrap; + align-items: center; + justify-content: space-between; + .tit1{ + font-weight: 500; + font-size: 32rpx; + color: #2F3240; + } + .tit2{ + font-weight: 500; + font-size: 40rpx; + color: #E46666; + } + } + .middle{ + margin-top: 10rpx; + display: flex; + flex-wrap: nowrap; + align-items: center; + justify-content: space-between; + .tit3{ + font-weight: 500; + font-size: 24rpx; + color: #808080; + } + .tit4{ + font-weight: 400; + font-size: 24rpx; + color: #808080; + text-decoration: line-through; + } + } + .bot{ + margin-top: 10rpx; + display: flex; + flex-wrap: nowrap; + align-items: center; + justify-content: space-between; + .bot_left{ + display: flex; + flex-wrap: nowrap; + align-items: center; + .txt3{ + padding: 4rpx 12rpx; + background: linear-gradient( 90deg, rgba(228,102,102,0.42) 0%, rgba(228,102,102,0) 100%); + border-radius: 6rpx 6rpx 6rpx 6rpx; + font-weight: 400; + font-size: 24rpx; + color: #E46666; + } + .txt4{ + margin-left: 16rpx; + padding: 4rpx 8rpx; + border-radius: 6rpx 6rpx 6rpx 6rpx; + border: 1rpx solid #808080; + font-weight: 400; + font-size: 24rpx; + color: #808080; + } + } + .btn{ + display: flex; + flex-wrap: nowrap; + align-items: center; + justify-content: center; + width: 144rpx; + height: 52rpx; + background: #E46666; + border-radius: 26rpx 26rpx 26rpx 26rpx; + font-weight: 500; + font-size: 28rpx; + color: #FFFFFF; + } + + } + } + .card2{ + margin-top: 16rpx; + width: 680rpx; + height: 322rpx; + background-image: url('https://lxnapi.ccttiot.com/bike/img/static/uyD3iyP4A54oU4oWgKTO'); + background-size: cover; + /* 背景图片等比缩放以覆盖整个容器 */ + background-position: center; + /* 背景图片居中显示 */ + background-repeat: no-repeat; + } + + } + } +</style> \ No newline at end of file diff --git a/page_vip/checkCard.vue b/page_vip/checkCard.vue new file mode 100644 index 0000000..f32a730 --- /dev/null +++ b/page_vip/checkCard.vue @@ -0,0 +1,56 @@ +<template> + <view class="page"> + <u-navbar title="我的骑行卡" :border-bottom="false" :background="bgc" title-color='#000' title-size='36' + height='45'></u-navbar> + + <view class="cont"> + <view class="card1"> + + </view> + </view> + </view> +</template> + +<script> + export default { + data() { + return { + bgc: { + backgroundColor: '#fff' + }, + sn: '', + istrue: false + } + }, + + methods: { + + } + } +</script> + +<style lang="scss"> + page { + background-color: #fff; + } + + .page { + width: 750rpx; + + .cont { + display: flex; + justify-content: center; + flex-wrap: wrap; + .card1{ + padding: 44rpx 48rpx; + width: 680rpx; + height: 142rpx; + background: #FFFFFF; + box-shadow: 0rpx 10rpx 64rpx 0rpx rgba(0,0,0,0.08); + } + + } + + + } +</style> \ No newline at end of file diff --git a/pages.json b/pages.json index 42ce1e2..a99b59d 100644 --- a/pages.json +++ b/pages.json @@ -214,6 +214,15 @@ "enablePullDownRefresh": false, "navigationStyle": "custom" } + }, + { + "path" : "checkCard", + "style" : + { + "navigationBarTitleText": "上传", + "enablePullDownRefresh": false, + "navigationStyle": "custom" + } } diff --git a/pages/index/index.vue b/pages/index/index.vue index 4701b25..e896f0d 100644 --- a/pages/index/index.vue +++ b/pages/index/index.vue @@ -1506,106 +1506,111 @@ }, deviceInfo(num) { if (uni.getStorageSync('token')) { - - this.$u.get('/app/device/info?sn=' + this.sn).then((res) => { - if (res.code === 200) { - this.isqrcode = true - this.deviceInfos = res.data; - if (!this.orderinfo.sn) { - this.mac = res.data.mac - } - if (num == 0) { - this.showdevice = true; - this.type = 0; - if (this.areaInfo.areaId != res.data.areaId) { - this.getArea() + + if(this.sn){ + this.$u.get('/app/device/info?sn=' + this.sn).then((res) => { + if (res.code === 200) { + this.isqrcode = true + this.deviceInfos = res.data; + if (!this.orderinfo.sn) { + this.mac = res.data.mac } - // this.routePlanning(res.data.latitude, res.data.longitude) - // setTimeout(() => { - - // // this.deviceIndex = 1; - // }, 600) - } else { - // if (this.deviceInfos.onlineStatus == 0) { - // wx.showToast({ - // title: '车辆离线中,请使用其他车辆', - // icon: 'none', - // duration: 4000 - // }); - // } else - if (this.deviceInfos.status == 0) { - uni.showToast({ - title: '车辆未上架,请使用其他车辆', - icon: 'none', - duration: 4000 - }); - } else if (this.deviceInfos.status == 2) { - uni.showToast({ - title: '车辆预约中,请使用其他车辆', - icon: 'none', - duration: 4000 - }); - } else if (this.deviceInfos.status == 3) { - uni.showToast({ - title: '车辆骑行中,请使用其他车辆', - icon: 'none', - duration: 4000 - }); - } else if (this.deviceInfos.status == 4) { - uni.showToast({ - title: '车辆临时锁车中,请使用其他车辆', - icon: 'none', - duration: 4000 - }); - } else if (this.deviceInfos.status == 6) { - uni.showToast({ - title: '车辆调度中,请使用其他车辆', - icon: 'none', - duration: 4000 - }); - } else if (this.deviceInfos.status == 8) { - uni.showToast({ - title: '车辆下线中,请使用其他车辆', - icon: 'none', - duration: 4000 - }); - } else if (this.deviceInfos.status == 9) { - uni.showToast({ - title: '车辆已废弃,请使用其他车辆', - icon: 'none', - duration: 4000 - }); - } else if (this.deviceInfos.status == 7) { - uni.showToast({ - title: '车辆未上线,请使用其他车辆', - icon: 'none', - duration: 4000 - }); - } else if (this.deviceInfos.status == 1) { - + if (num == 0) { + this.showdevice = true; + this.type = 0; if (this.areaInfo.areaId != res.data.areaId) { this.getArea() } // this.routePlanning(res.data.latitude, res.data.longitude) - setTimeout(() => { - this.showdevice = true - this.type = 1; - this.deviceIndex = 1; - }, 600) - + // setTimeout(() => { + + // // this.deviceIndex = 1; + // }, 600) + } else { + // if (this.deviceInfos.onlineStatus == 0) { + // wx.showToast({ + // title: '车辆离线中,请使用其他车辆', + // icon: 'none', + // duration: 4000 + // }); + // } else + if (this.deviceInfos.status == 0) { + uni.showToast({ + title: '车辆未上架,请使用其他车辆', + icon: 'none', + duration: 4000 + }); + } else if (this.deviceInfos.status == 2) { + uni.showToast({ + title: '车辆预约中,请使用其他车辆', + icon: 'none', + duration: 4000 + }); + } else if (this.deviceInfos.status == 3) { + uni.showToast({ + title: '车辆骑行中,请使用其他车辆', + icon: 'none', + duration: 4000 + }); + } else if (this.deviceInfos.status == 4) { + uni.showToast({ + title: '车辆临时锁车中,请使用其他车辆', + icon: 'none', + duration: 4000 + }); + } else if (this.deviceInfos.status == 6) { + uni.showToast({ + title: '车辆调度中,请使用其他车辆', + icon: 'none', + duration: 4000 + }); + } else if (this.deviceInfos.status == 8) { + uni.showToast({ + title: '车辆下线中,请使用其他车辆', + icon: 'none', + duration: 4000 + }); + } else if (this.deviceInfos.status == 9) { + uni.showToast({ + title: '车辆已废弃,请使用其他车辆', + icon: 'none', + duration: 4000 + }); + } else if (this.deviceInfos.status == 7) { + uni.showToast({ + title: '车辆未上线,请使用其他车辆', + icon: 'none', + duration: 4000 + }); + } else if (this.deviceInfos.status == 1) { + + if (this.areaInfo.areaId != res.data.areaId) { + this.getArea() + } + // this.routePlanning(res.data.latitude, res.data.longitude) + setTimeout(() => { + this.showdevice = true + this.type = 1; + this.deviceIndex = 1; + }, 600) + + } } + } else { + this.showdevice = false; + this.deviceIndex = 0; + this.type = 0; + uni.showToast({ + title: res.msg, + icon: 'none', + duration: 2000 + }); } - } else { - this.showdevice = false; - this.deviceIndex = 0; - this.type = 0; - uni.showToast({ - title: res.msg, - icon: 'none', - duration: 2000 - }); - } - }); + }); + + + } + } else { console.log('判断2'); wx.login({ @@ -1625,120 +1630,124 @@ if (res.code == 200) { uni.setStorageSync('token', res.token); this.getinfo() - this.$u.get('/app/device/info?sn=' + this.sn) - .then(( - res) => { - if (res.code === 200) { - this.isqrcode = true - this.deviceInfos = res.data; - - if (num == 0) { - // this.routePlanning(res.data.latitude, - // res.data.longitude) - this.showdevice = true; - this.type = 0; - } else { - // if (this.deviceInfos - // .onlineStatus == - // 0) { - // uni.showToast({ - // title: '车辆离线中,请使用其他车辆', - // icon: 'none', - // duration: 4000 - // }); - // } else - if (this.deviceInfos - .status == - 0) { - uni.showToast({ - title: '车辆未上架,请使用其他车辆', - icon: 'none', - duration: 4000 - }); - } else if (this.deviceInfos - .status == - 2) { - uni.showToast({ - title: '车辆预约中,请使用其他车辆', - icon: 'none', - duration: 4000 - }); - } else if (this.deviceInfos - .status == - 3) { - uni.showToast({ - title: '车辆骑行中,请使用其他车辆', - icon: 'none', - duration: 4000 - }); - } else if (this.deviceInfos - .status == - 4) { - uni.showToast({ - title: '车辆临时锁车中,请使用其他车辆', - icon: 'none', - duration: 4000 - }); - } else if (this.deviceInfos.status == - 6) { - uni.showToast({ - title: '车辆调度中,请使用其他车辆', - icon: 'none', - duration: 4000 - }); - } else if (this.deviceInfos - .status == - 8) { - uni.showToast({ - title: '车辆下线中,请使用其他车辆', - icon: 'none', - duration: 4000 - }); - } else if (this.deviceInfos - .status == - 9) { - uni.showToast({ - title: '车辆已废弃,请使用其他车辆', - icon: 'none', - duration: 4000 - }); - } else if (this.deviceInfos - .status == - 7) { - uni.showToast({ - title: '车辆未上线,请使用其他车辆', - icon: 'none', - duration: 4000 - }); - } else if (this.deviceInfos - .status == - 1) { - // this.routePlanning(res.data - // .latitude, res.data - // .longitude) - if (this.areaInfo != res.data - .areaId) { - this.getArea() + if(this.sn){ + this.$u.get('/app/device/info?sn=' + this.sn) + .then(( + res) => { + if (res.code === 200) { + this.isqrcode = true + this.deviceInfos = res.data; + + if (num == 0) { + // this.routePlanning(res.data.latitude, + // res.data.longitude) + this.showdevice = true; + this.type = 0; + } else { + // if (this.deviceInfos + // .onlineStatus == + // 0) { + // uni.showToast({ + // title: '车辆离线中,请使用其他车辆', + // icon: 'none', + // duration: 4000 + // }); + // } else + if (this.deviceInfos + .status == + 0) { + uni.showToast({ + title: '车辆未上架,请使用其他车辆', + icon: 'none', + duration: 4000 + }); + } else if (this.deviceInfos + .status == + 2) { + uni.showToast({ + title: '车辆预约中,请使用其他车辆', + icon: 'none', + duration: 4000 + }); + } else if (this.deviceInfos + .status == + 3) { + uni.showToast({ + title: '车辆骑行中,请使用其他车辆', + icon: 'none', + duration: 4000 + }); + } else if (this.deviceInfos + .status == + 4) { + uni.showToast({ + title: '车辆临时锁车中,请使用其他车辆', + icon: 'none', + duration: 4000 + }); + } else if (this.deviceInfos.status == + 6) { + uni.showToast({ + title: '车辆调度中,请使用其他车辆', + icon: 'none', + duration: 4000 + }); + } else if (this.deviceInfos + .status == + 8) { + uni.showToast({ + title: '车辆下线中,请使用其他车辆', + icon: 'none', + duration: 4000 + }); + } else if (this.deviceInfos + .status == + 9) { + uni.showToast({ + title: '车辆已废弃,请使用其他车辆', + icon: 'none', + duration: 4000 + }); + } else if (this.deviceInfos + .status == + 7) { + uni.showToast({ + title: '车辆未上线,请使用其他车辆', + icon: 'none', + duration: 4000 + }); + } else if (this.deviceInfos + .status == + 1) { + // this.routePlanning(res.data + // .latitude, res.data + // .longitude) + if (this.areaInfo != res.data + .areaId) { + this.getArea() + } + // this.routePlanning(res.data.latitude, res.data.longitude) + setTimeout(() => { + this.showdevice = true + this.type = 1; + this.deviceIndex = 1; + }, 600) } - // this.routePlanning(res.data.latitude, res.data.longitude) - setTimeout(() => { - this.showdevice = true - this.type = 1; - this.deviceIndex = 1; - }, 600) } + } else { + this.showdevice = false; + this.deviceIndex = 0; + this.type = 0; + uni.showToast({ + title: res.msg, + icon: 'none', + duration: 2000 + }); } - } else { - this.showdevice = false; - this.deviceIndex = 0; - this.type = 0; - uni.showToast({ - title: res.msg, - icon: 'none', - duration: 2000 - }); - } - }); + }); + + } + } else if (res.code == 501) { uni.showToast({ title: res.msg, diff --git a/pages/my.vue b/pages/my.vue index 612b45b..00df3d6 100644 --- a/pages/my.vue +++ b/pages/my.vue @@ -126,7 +126,7 @@ </view> </view> - <view class="card_li" @click="topage(9)" v-if="info.role==3"> + <view class="card_li" @click="topage(9)" v-if="info.role==3||info.role==9"> <view class="card_left"> <image src="https://lxnapi.ccttiot.com/bike/img/static/unIGXFEhvTgtXVcfPH33" mode=""> </image> @@ -229,14 +229,14 @@ <view class="iconfont icon-xiangyou1" ></view> </view> </view> - <view class="type_cont" v-if="info.role==3||info.role==2"> - <view class="type_li" @click="topage(8)" v-if="info.role==3||info.role==2"> + <view class="type_cont" v-if="info.role==3||info.role==2||info.role==9"> + <view class="type_li" @click="topage(8)" v-if="info.role==3||info.role==2||info.role==9"> <image src="https://lxnapi.ccttiot.com/bike/img/static/uyA3Cjjryy4Z9fCjs15Z" mode=""></image> 运维人员 <view class="iconfont icon-xiangyou1" ></view> </view> - <view class="type_li" style="margin-top: 70rpx;" @click="topage(9)" v-if="info.role==3"> + <view class="type_li" style="margin-top: 70rpx;" @click="topage(9)" v-if="info.role==3||info.role==9"> <image src="https://lxnapi.ccttiot.com/bike/img/static/uC0nQVG6EK7OCYefw1Ws" mode=""></image> 管理人员 <view class="iconfont icon-xiangyou1" ></view> diff --git a/pages_admin/admin_worke.vue b/pages_admin/admin_worke.vue index 2f9be70..a38e3cf 100644 --- a/pages_admin/admin_worke.vue +++ b/pages_admin/admin_worke.vue @@ -48,7 +48,7 @@ 车辆绑定 </view> </view> - <view class="cont" @click="topage(6)" > + <view class="cont" @click="topage(6)" v-if="userinfo.role==9"> <image src="https://lxnapi.ccttiot.com/bike/img/static/u47okd0YdEQBsyhLlQIt" mode="" style="width: 50rpx;height: 50rpx;"></image> <view class="text"> 账户明细 @@ -79,7 +79,8 @@ areaInfo:{}, list: [], show: false, - info:{} + info:{}, + userinfo:{} } }, @@ -91,6 +92,7 @@ if(uni.getStorageSync('adminAreaid')){ this.areaId = uni.getStorageSync('adminAreaid') this.getArea() + this.getinfo() this.getareaList() this.getareaInfo() } @@ -102,6 +104,21 @@ }, }, methods: { + getinfo() { + this.$u.get("/getAppInfo").then((res) => { + + if (res.code == 200) { + + this.userinfo = res.user + + } else { + // setTimeout(() => { + // this.getinfo() + // }, 200) + + } + }); + }, getareaInfo() { this.$u.get('/appVerify/getDept').then((res) => { if (res.code == 200) { diff --git a/pages_admin/worke/AccountDetails.vue b/pages_admin/worke/AccountDetails.vue index 8f802a2..eec65dd 100644 --- a/pages_admin/worke/AccountDetails.vue +++ b/pages_admin/worke/AccountDetails.vue @@ -114,7 +114,8 @@ Quantity: 0, border: false, isThrottled: false, - moneyInfo:{} + moneyInfo:{}, + ownerInfo:{} } }, onLoad(e) { @@ -124,7 +125,8 @@ onShow() { if (uni.getStorageSync('adminAreaid')) { this.areaId = uni.getStorageSync('adminAreaid') - this.getlist() + + this.getowner() } this.getareaInfo() }, @@ -134,6 +136,17 @@ this.getlist(); }, methods: { + getowner(){ + this.$u.get('/appVerify/ownerType' ).then((res) => { + if (res.code == 200) { + this.ownerInfo=res.data + console.log(this.ownerInfo,'ownerTypownerTypownerTypownerTyp'); + this.getlist() + } + }).catch(error => { + console.error("Error fetching area data:", error); + }); + }, ckinpt() { if (parseFloat(this.amount) > parseFloat(this.info.withdrawableAmount)) { @@ -298,8 +311,13 @@ let data = { pageNum: this.pageNum, pageSize: this.pageSize, - areaId: this.areaId + ownerId: this.ownerInfo.ownerId, + ownerType: this.ownerInfo.ownerType, + }; + if( this.ownerInfo.ownerId==1){ + data.areaId=this.areaId + } this.$u.get('/appVerify/flowList?', data).then((res) => { if (res.code == 200) { // 确保合并新获取的数据