This commit is contained in:
xiaozhiyong
2023-05-30 10:07:12 +08:00
parent 81556f26a0
commit 6b0e5e7399
11 changed files with 921 additions and 114 deletions

View File

@@ -1,7 +1,7 @@
<template>
<view>
<view class="company_body">
<!-- <view class="header_seach_seach">
<!--<view class="header_seach_seach">
<uni-easyinput @confirm="seachFn"
style="height: 100%; flex: 1; margin: 0 auto; background-color: #FFFFFF; border-radius:12rpx ;"
prefixIcon="search" v-model="getData.params.siteName" placeholder="油站名称" >
@@ -30,13 +30,6 @@
sysRoleList: [],
timer: null,
authList: [],
// getData: {
// pageSize: 15,
// currentPage: 1,
// params: {
// siteName: ""
// },
// },
}
},
onLoad(options) {
@@ -47,37 +40,25 @@
onShow() {
this.getAuthList()
},
// onReachBottom() {
// this.getData.currentPage += 1
// this.getAuthList()
// },
methods: {
seleFn(item) {
clearTimeout(this.timer)
this.$set(item, 'isChecked', !item.isChecked)
uni.$emit('yunSiteAuth', item)
this.timer = setTimeout(() => {
uni.navigateBack()
}, 200)
},
seachFn() {
// this.getData.currentPage = 1
this.getDriversList()
},
getAuthList() {
serve.getSiteCloudRoles().then(res => {
if (res.code !== 20000) return
let data = res.data.map(item => {
item['isChecked'] = false
return item
})
data.forEach(item => {
this.sysRoleList.forEach(secItem => {
if (secItem.id === item.id) {
@@ -85,10 +66,6 @@
}
})
})
// if (this.getData.currentPage !== 1) {
// this.authList = this.authList.concat(data);
// return
// }
this.authList = data
})
},

View File

@@ -43,20 +43,10 @@
// // this.oilCompanyInfoList = JSON.parse(decodeURI(options.item))
// }
},
onShow() {
// this.getDriversList()
},
// onReachBottom() {
// // this.getData.currentPage += 1
// this.getDriversList()
// },
methods: {
seleFn(item) {
clearTimeout(this.timer)
this.$set(item,'isChecked',!item.isChecked)
uni.$emit('yunSiteServiceStation', item)
this.timer = setTimeout(() => {
uni.navigateBack()
@@ -70,31 +60,15 @@
})
return
}
// this.getData.currentPage = 1
this.getDriversList()
},
getDriversList() {
getDriversList() {
serve.getSiteChannelList(this.getData).then(res => {
if (res.code !== 20000) return
if (res.code !== 20000) return
let data = res.data.map(item => {
item['isChecked'] = false
return item
})
// data.forEach(item => {
// this.oilCompanyInfoList.forEach(secItem =>{
// if(secItem.id === item.id) {
// item['isChecked'] = true
// }
// })
// })
// if (this.getData.currentPage !== 1) {
// this.stationList = this.stationList.concat(data);
// return
// }
})
this.stationList = data
})
},