Browse Source

人房页面增加车辆查询,工作隐藏掉网格巡查跟满意度

master
mk 9 months ago
parent
commit
41ce77eb87
  1. 7
      pages/index/index.vue
  2. 257
      pages/resiAndHouse/resiAndHouse.vue
  3. 37
      pages/work2/work2.vue
  4. 7
      utils/api.js

7
pages/index/index.vue

@ -45,10 +45,6 @@
</view>
</view>
<view class="electron">
<view class="door">
<image src="/static/images/index/Door.png" class="img_door"></image>
<text class="door-text" @tap="door">扫电子门牌</text>
</view>
<view class="electron_card">
<image src="/static/images/index/IDCard.png" class="img_door"></image>
<text class="card_text" @tap="IDCard">识别身份证</text>
@ -362,6 +358,7 @@ export default {
this.setData({
loadMoreType: res.data.list.length === this.pageSize ? 'more' : 'none',
tableData: this.tableData.concat(res.data.list)
});
console.log(this.tableData);
if (this.tableData.length == 0) {
@ -1571,7 +1568,7 @@ page {
}
.electron_card {
display: flex;
width: 335rpx;
width: 100%;
height: 100rpx;
background-color: #ffffff;
border-radius: 20rpx;

257
pages/resiAndHouse/resiAndHouse.vue

@ -7,9 +7,7 @@
<image src="/static/images/work2/Header.png" class="back" @tap="back" mode="" />
<text lines="1" class="header_text_1" :style="' top: ' + statusHeight + 'px;width: 50rpx;height: 50rpx;'">{{ agencyName }}</text>
</view>
<!-- <view class="box_15" style="height: {{navigationHeight}}px; top: {{statusHeight}}px;">
<text lines="1" class="text_1" style=" top: {{statusHeight}}px;width: 50rpx;height: 50rpx;">{{agencyName}}</text>
</view> -->
<view class="text-wrapper_30">
<view @tap="handelClickSearchType" data-type="resi">
<text lines="1" :class="'text_3 ' + (selectVale === 'resi' ? 'font_bold' : '')">查居民</text>
@ -19,7 +17,7 @@
<text lines="1" :class="'text_3 ' + (selectVale === 'house' ? 'font_bold' : '')">查房屋</text>
<image src="/static/images/work/select.png" mode="" v-if="selectVale == 'house'" />
</view>
<view>
<view @tap="handelClickSearchType" data-type="car">
<text lines="1" :class="'text_3 ' + (selectVale === 'car' ? 'font_bold' : '')">查车辆</text>
<image src="/static/images/work/select.png" mode="" v-if="selectVale == 'car'" />
</view>
@ -28,7 +26,7 @@
<image src="/static/images/work/search.png" mode="" class="search_img" />
<input
type="text"
:placeholder="selectVale === 'resi' ? '姓名/手机/身份证' : '小区/楼栋/单元'"
:placeholder="selectVale === 'resi' ? '姓名/手机/身份证' :selectVale === 'house'? '小区/楼栋/单元':'车牌号/车主姓名/手机号'"
@input="handelBlurKeyWord"
@blur="handelBlurKeyWord"
:value="keyWord"
@ -54,11 +52,7 @@
<view class="group_2" v-if="selectVale === 'resi'">
<view class="section_2">
<view class="box_16">
<text lines="1" class="text_4">{{ cascaderName }}</text>
<view class="image-text_9">
<image src="/static/images/swapHorizontal.png" class="image_8"></image>
<text lines="1" class="text_5" @tap="handelClickShowTree">切换</text>
</view>
<jia-cascader :itemList="angencyList" @completeChange="completeGrid" @inputChange="changeResiCascader" :border="false" :clearIcon="false"></jia-cascader>
</view>
<view class="box_17">
<view class="tabs">
@ -300,31 +294,53 @@
</view>
<view v-if="selectVale === 'house' && selectedOptions" @tap="toAddHouse" class="btoBtn">新增房屋</view>
</view>
<view class="group_2" v-if="selectVale === 'car'" style="height: calc(100vh - 269px);">
<view class="section_2">
<view class="box_16">
<text lines="1" class="text_4">{{ cascaderName }}</text>
<view class="image-text_9">
<image src="/static/images/swapHorizontal.png" class="image_8"></image>
<text lines="1" class="text_5" @tap="handelClickShowTree">切换</text>
</view>
</view>
<scroll-view class="scroll" style="height: calc(100vh - 335px);" :scroll-y="true" :lower-threshold="lowerThreshold" @scrolltolower="onScrollToLower">
<view class="form_item" :wx:key="index" :data-resiId="item.resiId" v-for="(item, index) in carList" :key="index">
<view class="updata1">
<view class="box_18" style="width: auto;">
<view style="display: flex; align-items: center; max-width: 390rpx; overflow: hidden">
<view style="display: flex">
<text lines="1" class="text_16">{{ item.carNumber }}</text>
</view>
</view>
<view class="text-wrapper_9" style="position: none;width: auto;">
<view style="color: #afafaf;font-size:14px ;"><text v-if="item.carColor">{{ item.carColor }}·</text>{{item.carBrand}}</view>
</view>
</view>
<view class="text-wrapper_13">
<text lines="1" class="text_27">车主</text>
<text lines="1" class="text_28"></text>
<text lines="1" class="text_29">{{ item.carOwnerName }}</text>
</view>
<view class="text-wrapper_12">
<text lines="1" class="text_25">电话</text>
<text lines="1" class="text_26">{{ item.carOwnerMobile || '--' }}</text>
</view>
<view class="text-wrapper_14">
<text lines="1" class="text_30">地址</text>
<text lines="1" class="text_31">{{ item.orgNamePath || '' }}</text>
</view>
</view>
</view>
<!-- <load-more loadVisible="{{loadMoreVisible}}" loadType="{{loadMoreType}}"></load-more> -->
<!-- <no-data isShow="{{nodata}}" wx:if="{{nodata}}"></no-data> -->
<view class="loadVisible">{{ loadMoreType == 'more' ? '加载中...' : '暂无数据' }}</view>
</scroll-view>
</view>
</view>
<custom-tab-bar></custom-tab-bar>
<van-popup :show="showAngenCascader" round position="bottom">
<van-cascader
:field-names="fieldName"
v-if="showAngenCascader"
:value="searchOrgIdPath"
title="请选择"
:options="angencyJmList"
@close="onClose"
@change="onChangeJm"
@finish="onFinishJm"
/>
</van-popup>
<van-popup :show="showFw" round position="bottom">
<van-cascader
v-if="showFw"
:field-names="fieldName"
:value="cascaderFwValue"
title="请选择所在地区"
:options="angencyFwList"
@close="onCloseFw"
@change="onChangeFw"
@finish="onFinishFw"
/>
</van-popup>
</view>
</template>
@ -333,7 +349,7 @@ import customTabBar from '../../components/custom-tab-bar/index.vue';
import loadMore from '../../components/loadMore/loadMore';
import noData from '../../components/noData/nodata';
const app = getApp();
import api, { getAllOrgCategoryCount, getResidentBaseInfo, getTopTree, getNextTree, houseSearch, allOrgHouseInfo, getCommunityHouse } from '../../utils/api';
import api, { getResidentBaseInfo, getNextTree, houseSearch, allOrgHouseInfo, getCommunityHouse } from '../../utils/api';
export default {
components: {
customTabBar,
@ -381,9 +397,6 @@ export default {
//
angencyFwList: [],
//
showAngenCascader: false,
agencyName: '',
fieldName: {
@ -393,7 +406,6 @@ export default {
},
cascaderNameFw: null,
showFw: false,
params: {
agencyId: '',
@ -448,7 +460,8 @@ export default {
selectedOptions: '',
loadLeve: '',
resiSearch: '',
houseSearch: ''
houseSearch: '',
carList:[]
};
},
/**
@ -524,6 +537,59 @@ export default {
*/
onShareAppMessage() {},
methods: {
completeGrid(e) {
},
async carInfoPage(){
try {
this.setData({
loadMoreVisible: true,
nodata: false,
loadMoreType: 'more'
});
let parm = {
agencyId:'',
orgIdPath:'',//
keyword:this.keyWord,
pageSize:this.pageSize,
pageNo:this.pageNo
}
let { data, code, msg } = await api.carInfoPage(parm);
if (code == 0) {
this.setData({
loadMoreType: data.list.length === this.pageSize ? 'more' : 'none',
carList: this.carList.concat(...data.list)
});
if (this.carList.length == 0) {
this.setData({
loadMoreVisible: false,
nodata: true
});
}
} else {
this.setData({
loadMoreVisible: false,
nodata: true,
loadMoreType: 'none'
});
}
} catch (err) {
this.setData({
loadMoreVisible: false,
nodata: true,
loadMoreType: 'none'
});
}
},
changeResiCascader(e){
this.searchOrgIdPath = e.value;
this.setData({
pageNo: 1,
tableData: []
});
this.getTableData();
this.getAllOrgCategoryCount();
},
handelClickedit(e) {
console.log(e);
uni.navigateTo({
@ -615,31 +681,37 @@ export default {
},
getTopTreeData() {
getTopTree().then((res) => {
const arr = res.data.children.map((item) => {
return {
...item,
children: []
};
});
api.getAgencygridtree().then((res) => {
this.setData({
angencyFwList: [
{
...res.data,
children: arr
}
],
angencyJmList: [
{
...res.data,
children: arr
}
]
angencyList: this.convertLabelToText([res.data])
});
console.log(this.angencyFwList);
});
},
convertLabelToText(tree) {
return tree.map(node => {
const newNode = {
...node
};
// label text
if (newNode.agencyName !== undefined) {
newNode.text = newNode.agencyName;
delete newNode.agencyName;
}
if (newNode.subAgencyList && newNode.subAgencyList.length > 0) {
newNode.children = newNode.subAgencyList
delete newNode.subAgencyList;
}
if (newNode.agencyId) {
newNode.value = newNode.agencyId
delete newNode.agencyId;
}
if (newNode.children && newNode.children.length > 0) {
newNode.children = this.convertLabelToText(newNode.children);
}
return newNode;
});
},
getTreeFun(id, arr, data) {
return arr.map((item) => {
if (id == item.id) {
@ -749,38 +821,6 @@ export default {
}
},
onCloseFw() {
this.setData({
showFw: false
});
},
onFinishFw(e) {
const { selectedOptions, value } = e.detail;
const level = selectedOptions[selectedOptions.length - 1].level;
this.setData({
cascaderNameFw: e.detail.selectedOptions.map((item) => item.label).join(' '),
showFw: false,
cascaderFwValue: value,
params: {
...this.params,
orgId: value,
level: level == 'grid' ? 'grid' : 'agency',
agencyId: app.globalData.user.agencyId
},
params1: {
pageNo: 1,
...this.params1,
searchOrgIdPath: value,
// orgId: value,
level
},
tableFwData: [],
selectedOptions
});
this.getTableFwData();
},
handelClickSearchType(e) {
this.setData({
selectVale: e.currentTarget.dataset.type
@ -798,21 +838,14 @@ export default {
tableFwData: []
});
this.getUnitoption(this.angencyFwList);
}
},
handelClickShowTree() {
this.setData({
showAngenCascader: true
});
},
handelClickShowTreeFw() {
} else if (e.currentTarget.dataset.type === 'car') {
this.setData({
showFw: true
pageNo: 1,
carList: []
});
this.carInfoPage();
}
},
async handelClickSearch() {
if (this.selectVale === 'resi') {
this.setData({
@ -821,7 +854,7 @@ export default {
});
this.getTableData();
this.getAllOrgCategoryCount();
} else {
} else if(this.selectVale === 'house'){
if (this.keyWord) {
this.setData({
houseListSearchFlag: true,
@ -837,6 +870,12 @@ export default {
tableFwData: []
});
this.getTableFwData();
}else{
this.setData({
pageNo: 1,
carList:[]
});
this.carInfoPage()
}
},
@ -891,11 +930,6 @@ export default {
});
},
onClose() {
this.setData({
showAngenCascader: false
});
},
onScrollToLower(e) {
if (this.loadMoreType === 'more') {
@ -956,9 +990,6 @@ export default {
});
}
} catch (err) {
console.log('CatchClause', err);
console.log('CatchClause', err);
console.log(err);
this.setData({
loadMoreVisible: false,
nodata: true,

37
pages/work2/work2.vue

@ -56,34 +56,14 @@
<image src="/static/images/work2/rep_record.png" class="image_13-2" @tap="onMyTroubleshootDemand"></image>
<text lines="1" class="text_4-0">诉求办理</text>
</view>
<view>
<image src="/static/images/work2/satisfaction.png" class="image_13-2" @tap="onHistoryQuery"></image>
<text lines="1" class="text_5-0">满意度调查</text>
</view>
</view>
</view>
<!-- <view class="section_1-0">
<view class="text-wrapper_7-0">
<text lines="1" class="text_2-0">安检管理</text>
</view>
<view class="content_1" bind:tap="onData">
<view>
<image src="/images/work2/slices.png" class="image_15">
</image>
<text lines="1" class="text_13" >安检巡查</text>
</view>
</view>
</view> -->
<view class="section_1-0">
<view class="text-wrapper_7-0">
<text lines="1" class="text_2-0">基层治理</text>
</view>
<view class="content_1">
<!-- <view>
<image src="/static/images/work2/slices.png" class="image_12-0" @tap="onData"></image>
<text lines="1" class="text_3-0" @tap="onData">安检巡查</text>
</view> -->
<view style="display: flex; justify-items: center">
<image src="/static/images/work2/12345.png" class="image_13-21" style="margin-left: 25px" @tap="onHotlineCompletion"></image>
<text lines="1" class="text_4-0">热线接办</text>
@ -170,11 +150,6 @@ export default {
});
},
onHistoryQuery() {
uni.navigateTo({
url: '../../subpages/communitySelfInsp/pages/historyQuery/historyQuery'
});
},
onFollowUpList() {
uni.navigateTo({
@ -210,18 +185,6 @@ export default {
});
},
onData() {
// wx.switchTab({
uni.navigateTo({
url: '/subpages/securityCheck/pages/securityCheck'
});
},
// onAddHouse(){
// wx.navigateTo({
// url: '../../subpages/addhouse/pages/addhouse/addhouse',
// })
// },
onHotlineCompletion() {
let token = uni.getStorageSync('token');
console.log(token, 'jhgjgjjhbj');

7
utils/api.js

@ -91,7 +91,8 @@ module.exports = {
hotResidentSearch,
hotHouseSearch,
carInfoSave,
statisticEventInfo
statisticEventInfo,
carInfoPage
};
// 获取公钥
@ -488,3 +489,7 @@ function carInfoSave(data) {
function statisticEventInfo(parm) {
return fly.get(`governance/icEventSpecialSubject/statisticEventInfo`, parm);
}
// 获取车辆列表
function carInfoPage(data) {
return fly.get(`epmetuser/carInfo/page`,data);
}
Loading…
Cancel
Save