添加工单台选择小区页面
This commit is contained in:
parent
39a0160f95
commit
93026479d3
@ -15,6 +15,13 @@
|
||||
|
||||
.searchBox_add {
|
||||
margin: 10rpx 20rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.top-image{
|
||||
width: 50rpx;
|
||||
height: 50rpx;
|
||||
}
|
||||
|
||||
.emptyCommunity {
|
||||
|
||||
@ -1,8 +1,9 @@
|
||||
<template>
|
||||
<view class="container">
|
||||
<view class="searchBox" :style="{ height: localHeight + 'px', paddingTop: top + 'px' }">
|
||||
<view class="searchBox_add">
|
||||
<view class="emptyCommunity" @click="addCommunity">
|
||||
<view class="searchBox_add" @click="addCommunity">
|
||||
<image class="top-image" src="http://localhost:8080/workOrder_community.png" mode="aspectFill"></image>
|
||||
<view class="emptyCommunity">
|
||||
{{ communityVal }}
|
||||
</view>
|
||||
</view>
|
||||
@ -52,7 +53,7 @@ export default {
|
||||
const orderDispatchPermission = uni.getStorageSync('order_dispatch_permission');
|
||||
this.showWorkOrderSection = !(workOrderPermission === false && orderDispatchPermission === false);
|
||||
},
|
||||
async onShow(){
|
||||
async onShow() {
|
||||
this.communityVal = uni.getStorageSync('changeCommData').name;
|
||||
const params = {
|
||||
community_id: uni.getStorageSync('changeCommData').id,
|
||||
@ -62,7 +63,7 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
addCommunity() {
|
||||
NavgateTo("/packages/community/myCommunity/index");
|
||||
NavgateTo("/packages/workOrderDashboard/myCommunity/index");
|
||||
},
|
||||
|
||||
// 跳转到工单台
|
||||
|
||||
98
packages/workOrderDashboard/myCommunity/index.css
Normal file
98
packages/workOrderDashboard/myCommunity/index.css
Normal file
@ -0,0 +1,98 @@
|
||||
page {
|
||||
background-color: #f6f7fb;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.container {
|
||||
min-height: 100vh;
|
||||
}
|
||||
|
||||
image {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.empty {
|
||||
font-size: 28rpx;
|
||||
color: #999999;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
margin-top: 180rpx;
|
||||
}
|
||||
|
||||
.empty image {
|
||||
width: 340rpx;
|
||||
height: 240rpx;
|
||||
}
|
||||
|
||||
.addBtn {
|
||||
width: 600rpx;
|
||||
height: 90rpx;
|
||||
background: linear-gradient(91deg, #FF7658 0%, #FF370B 100%);
|
||||
border-radius: 100rpx 100rpx 100rpx 100rpx;
|
||||
font-size: 36rpx;
|
||||
color: #FFFFFF;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
position: fixed;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
bottom: 100rpx;
|
||||
}
|
||||
|
||||
|
||||
.communityList {
|
||||
padding: 0 20rpx;
|
||||
background-color: #fff;
|
||||
margin-top: 20rpx;
|
||||
}
|
||||
|
||||
.communityItem {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
border-bottom: 1rpx solid #EBEBEB;
|
||||
padding: 30rpx 0;
|
||||
}
|
||||
.communityItem_left{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
}
|
||||
.communityItem_left_img {
|
||||
width: 160rpx;
|
||||
height: 140rpx;
|
||||
border-radius: 20rpx;
|
||||
overflow: hidden;
|
||||
margin-right: 30rpx;
|
||||
}
|
||||
.communityItem_left_msg{
|
||||
flex: 1;
|
||||
}
|
||||
.communityItem_left_msg_tit {
|
||||
font-size: 30rpx;
|
||||
color: #222222;
|
||||
}
|
||||
|
||||
.communityItem_left_msg_tit span {
|
||||
color: #FF370B;
|
||||
}
|
||||
|
||||
.communityItem_left_msg_msg {
|
||||
font-size: 26rpx;
|
||||
color: #999999;
|
||||
}
|
||||
|
||||
.communityItem_right{
|
||||
width: 34rpx;
|
||||
height: 34rpx;
|
||||
margin-left: 80rpx;
|
||||
}
|
||||
|
||||
/* 最后一个 communityItem */
|
||||
.communityItem:last-child {
|
||||
border-bottom: none;
|
||||
}
|
||||
100
packages/workOrderDashboard/myCommunity/index.vue
Normal file
100
packages/workOrderDashboard/myCommunity/index.vue
Normal file
@ -0,0 +1,100 @@
|
||||
<template>
|
||||
<view class="container">
|
||||
<view class="empty" v-if="communityList.length == 0">
|
||||
<image src="https://wechat-img-file.oss-cn-beijing.aliyuncs.com/property-img-file/com_newEmpty.png"
|
||||
alt="" />
|
||||
没有添加任何房产
|
||||
|
||||
</view>
|
||||
|
||||
<div class="communityList">
|
||||
<div class="communityItem" v-for="item in communityList" :key="item.community_id"
|
||||
@click="choseCommunity(item)">
|
||||
<div class="communityItem_left">
|
||||
<div class="communityItem_left_img">
|
||||
<image :src="item.pic" mode="aspectFill"></image>
|
||||
</div>
|
||||
<div class="communityItem_left_msg">
|
||||
<div class="communityItem_left_msg_tit">{{ item.name }}<span>( {{ item.room_owner_list.length }}
|
||||
)</span></div>
|
||||
<div class="communityItem_left_msg_msg">{{ item.addr }}</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="communityItem_right">
|
||||
<image src="https://wechat-img-file.oss-cn-beijing.aliyuncs.com/property-img-file/com_check1.png"
|
||||
v-if="item.community_id != currentCommunity.id"></image>
|
||||
<image src="https://wechat-img-file.oss-cn-beijing.aliyuncs.com/property-img-file/com_check2.png"
|
||||
v-if="item.community_id == currentCommunity.id"></image>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- <div class="addBtn" @click="addCommunity">添加我的房产</div> -->
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {
|
||||
request,
|
||||
NavgateTo,
|
||||
isPhone,
|
||||
picUrl
|
||||
} from '../../../utils';
|
||||
import {
|
||||
apiArr
|
||||
} from '../../../api/community';
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
communityList: [],
|
||||
page_num: 1,
|
||||
page_size: 10,
|
||||
currentCommunity: {}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
addCommunity() {
|
||||
NavgateTo("/packages/community/addCommunity/index")
|
||||
},
|
||||
async getList() {
|
||||
await request(apiArr.commInfo, "POST", {
|
||||
user_id: uni.getStorageSync('userId'),
|
||||
longitude: uni.getStorageSync('location').lng,
|
||||
latitude: uni.getStorageSync('location').lat,
|
||||
page_num: this.page_num,
|
||||
page_size: this.page_size
|
||||
}).then(res => {
|
||||
res.rows.forEach(item => {
|
||||
item.pic = item.pic.startsWith('http') ? item.pic : picUrl + item.pic
|
||||
});
|
||||
this.communityList = res.rows.filter(item => item.front_end_display !== 1)
|
||||
})
|
||||
},
|
||||
// toUpview(item) {
|
||||
// uni.setStorageSync('changeCommData', { id: item.community_id, name: item.name });
|
||||
// NavgateTo("/packages/community/index/index")
|
||||
// },
|
||||
|
||||
choseCommunity(e) {
|
||||
this.currentCommunity = e
|
||||
uni.setStorageSync('changeCommData', { id: e.community_id, name: e.name });
|
||||
uni.setStorageSync('currentCommunityAddr',e.addr);
|
||||
uni.setStorageSync("isShowNav", e.room_owner_list[0].type)
|
||||
NavgateTo("1")
|
||||
},
|
||||
},
|
||||
|
||||
onLoad(options) {
|
||||
this.currentCommunity = uni.getStorageSync('changeCommData')
|
||||
console.log(this.currentCommunity, 'currentCommunity');
|
||||
this.getList();
|
||||
|
||||
},
|
||||
|
||||
onReachBottom() { },
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
@import url("./index.css");
|
||||
</style>
|
||||
@ -102,6 +102,13 @@
|
||||
"navigationBarTitleText": "",
|
||||
"navigationBarBackgroundColor": "#fff"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "myCommunity/index",
|
||||
"style": {
|
||||
"navigationBarTitleText": "选择小区",
|
||||
"navigationBarBackgroundColor": "#fff"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user