工作端小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

222 lines
5.7 KiB

<template>
<scroll-view class="content" scroll-y="true">
<image src="/static/img/workBac1.png" class="bacImg1"></image>
<image src="/static/img/workBac2.png" class="bacImg2"></image>
<view class="conItem" style="margin-top: 100rpx;">
<view class="conItem-title">房源</view>
<view class="conItem-cont">
<view class="conItem-cont-item" v-for="(item, index) in fyList" :key="index" @click="handelFyClick(item)">
<image :src="item.image" class="itemImg"></image>
<text class="itemText">{{ item.text }}</text>
</view>
</view>
</view>
<view class="conItem">
<view class="conItem-title">巡检</view>
<view class="conItem-cont">
<view class="conItem-cont-item" v-for="(item, index) in xjList" :key="index" @click="handelXjClick(item)">
<image :src="item.image" class="itemImg"></image>
<text class="itemText">{{ item.text }}</text>
</view>
</view>
</view>
<view class="conItem" style="display: none;">
<view class="conItem-title">水电</view>
<view class="conItem-cont">
<view class="conItem-cont-item" v-for="(item, index) in sdList" :key="index" @click="handelSdClick(item)">
<image :src="item.image" class="itemImg"></image>
<text class="itemText">{{ item.text }}</text>
</view>
</view>
</view>
<view class="conItem" style="display: none;">
<view class="conItem-title">报修</view>
<view class="conItem-cont">
<view class="conItem-cont-item" v-for="(item, index) in bxList" :key="index">
<image :src="item.image" class="itemImg"></image>
<text class="itemText">{{ item.text }}</text>
</view>
</view>
</view>
<view class="conItem" style="display: none;">
<view class="conItem-title">报事</view>
<view class="conItem-cont">
<view class="conItem-cont-item" v-for="(item, index) in bsList" :key="index" @click="handleBsClick(item)">
<image :src="item.image" class="itemImg"></image>
<text class="itemText">{{ item.text }}</text>
</view>
</view>
</view>
</scroll-view>
</template>
<script>
export default {
data () {
return {
fyList: [
// { image: '/static/img/看房.png', text: '看房确认' },
{ image: '/static/img/退房检查.png', text: '退房检查' },
{ image: '/static/img/释放.png', text: '释放房源检查' },
// { image: '/static/img/预约.png', text: '预约看房' },
{ image: '/static/img/强制清退.png', text: '强制清退' },
],
xjList: [
{ image: '/static/img/巡查.png', text: '巡检上报' },
{ image: '/static/img/记录.png', text: '巡检记录' },
],
// sdList: [
// { image: '/static/img/水费.png', text: '水量上报' },
// { image: '/static/img/电费.png', text: '电量上报' },
// ],
// bxList: [
// { image: '/static/img/上报.png', text: '上报' },
// { image: '/static/img/处理.png', text: '处理' },
// ],
// bsList: [
// { image: '/static/img/上报.png', text: '上报' },
// { image: '/static/img/处理.png', text: '处理' },
// ],
}
},
onLoad () {
if (!uni.getStorageSync('token')) {
uni.redirectTo({
url: '/pages/login/login',
})
}
},
methods: {
handelFyClick (item) {
if (item.text == "退房检查") {
uni.navigateTo({
url: '/pagesA/checkout/list/list'
})
} else if (item.text == "释放房源检查") {
uni.navigateTo({
url: '/pagesA/release/list/list'
})
}else if (item.text == "强制清退") {
uni.navigateTo({
url: '/pagesA/force/index/index'
})
}
},
handleBsClick (item) {
if (item.text === '处理') {
// 记录
uni.navigateTo({
url: '/pages/tabBar/bsPage/bsRecord'
})
} else {
// 上报
uni.navigateTo({
url: '/pages/tabBar/bsPage/bsReport'
})
}
},
handelXjClick (item) {
if (item.text === '巡检上报') {
// 列表
uni.navigateTo({
url: '/pagesA/xjPage/xj'
})
} else {
uni.navigateTo({
url: '/pagesA/xjPage/xjRecord'
})
}
},
handelSdClick (item) {
if(item.text === '水量上报'){
uni.navigateTo({
url: '/pagesA/sdPage/sfReport'
})
} else if(item.text === '电量上报'){
uni.navigateTo({
url: '/pagesA/sdPage/dfReport'
})
}
}
}
}
</script>
<style lang="scss" scoped>
.content {
width: 100%;
height: 100vh;
}
.conItem {
width: calc(100% - 40rpx);
border-radius: 10rpx;
margin-left: 20rpx;
background-color: rgba(255, 255, 255, 1);
box-shadow: 2rpx 2rpx 4rpx rgba(0, 0, 0, 0.2);
margin-bottom: 20rpx;
padding: 20rpx;
box-sizing: border-box;
}
.conItem-title {
color: rgb(64, 64, 64);
font-size: 30rpx;
text-align: left;
}
.conItem-cont {
display: flex;
flex-direction: row;
justify-content: flex-start;
flex-wrap: wrap;
margin-top: 20rpx;
}
.conItem-cont-item {
width: 23%;
display: flex;
justify-content: center;
align-items: center;
flex-direction: column;
margin-right: 2%;
margin-bottom: 20rpx;
.itemImg {
width: 80rpx;
height: 80rpx;
}
.itemText {
color: rgb(64, 64, 64);
font-size: 20rpx;
margin-top: 5rpx;
}
}
.conItem-cont-item:nth-child(4n) {
margin-right: 0;
}
.bacImg1 {
width: 100%;
height: 20%;
position: absolute;
top: 0;
z-index: -1;
}
.bacImg2 {
width: 100%;
height: 80%;
position: absolute;
top: 30%;
z-index: -1;
}
</style>