社区、管理员列表调用
parent
14cae43bb6
commit
3a13f8feef
|
@ -1,5 +1,5 @@
|
|||
<template>
|
||||
<view class="status-box" :style="{marginBottom: marginBottom}">
|
||||
<view class="status-box-all" :style="{marginBottom: marginBottom}">
|
||||
<!-- 网络、电量栏 start -->
|
||||
<view :style="{height: statusBarHeight+'px',background: backgroudColor}"></view>
|
||||
<!-- 网络、电量栏 end -->
|
||||
|
@ -142,7 +142,7 @@
|
|||
.disjcac{display: flex;justify-content: center;align-items: center;}
|
||||
.clips1{display: -webkit-box;-webkit-box-orient: vertical;-webkit-line-clamp: 1;overflow: hidden;text-overflow: ellipsis;word-wrap: break-word;word-break:break-all;}
|
||||
.clips2{display: -webkit-box;-webkit-box-orient: vertical;-webkit-line-clamp: 2;overflow: hidden;text-overflow: ellipsis;word-wrap: break-word;word-break:break-all;}
|
||||
.status-box{position: sticky;top: 0;left: 0;right: 0;z-index: 10;}
|
||||
.status-box-all{position: sticky;top: 0;left: 0;right: 0;z-index: 10;}
|
||||
.status-nav{width: 100%;position: relative;}
|
||||
.left-box {position: absolute;padding: 0 20rpx;}
|
||||
.right-box {position: absolute;right: 0; padding: 0 20rpx;}
|
||||
|
|
|
@ -3,18 +3,18 @@
|
|||
<view class="disac fon36 pad-sx30">调查情况</view>
|
||||
<view class="disjcac">
|
||||
<view class="disjbac radius30 width100 pad-sx20 pad-zy30" style="border: 2rpx solid #d9d9d9;box-sizing: border-box;">
|
||||
<textarea class="col9 fon30" style="height: 272rpx;" placeholder="请输入调查结果"></textarea>
|
||||
<textarea class="col9 fon30" v-model="findings" style="height: 272rpx;" placeholder="请输入调查结果"></textarea>
|
||||
</view>
|
||||
</view>
|
||||
<view class="disac fon36 pad-sx30">处理结果</view>
|
||||
<view class="disjcac">
|
||||
<view class="disjbac radius30 width100 pad-sx20 pad-zy30" style="border: 2rpx solid #d9d9d9;box-sizing: border-box;">
|
||||
<textarea class="col9 fon30" style="height: 272rpx;" placeholder="请输入处理结果"></textarea>
|
||||
<textarea class="col9 fon30" v-model="results" style="height: 272rpx;" placeholder="请输入处理结果"></textarea>
|
||||
</view>
|
||||
</view>
|
||||
<view class="disjbac mar-s70">
|
||||
<view class="enter-btn disjcac" style="width: 45%;margin: 0;">立即提交</view>
|
||||
<view class="enter-btn disjcac" style="width: 45%;margin: 0;color: #000000;background-color: #e5e5e5;border-color: #d9d9d9;">无效</view>
|
||||
<view @tap="submitEv(id,1)" class="enter-btn disjcac" style="width: 45%;margin: 0;">立即提交</view>
|
||||
<view @tap="submitEv(id,0)" class="enter-btn disjcac" style="width: 45%;margin: 0;color: #000000;background-color: #e5e5e5;border-color: #d9d9d9;">无效</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
@ -23,11 +23,53 @@
|
|||
export default {
|
||||
data() {
|
||||
return {
|
||||
|
||||
findings:'', //调查结果
|
||||
results:'', //处理结果
|
||||
flag:true,
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
// 提交或取消
|
||||
submitEv(id,type){
|
||||
if(this.checkEmpty() && this.flag){
|
||||
this.flag = false;
|
||||
let params = {
|
||||
opinion_id:id,
|
||||
desc:this.findings,
|
||||
result:this.results,
|
||||
invalid:type
|
||||
}
|
||||
this.$requst.post('/api/opinion/worker-handle',params).then(res => {
|
||||
if(res.code==0){
|
||||
this.$toolAll.tools.showToast('提交成功');
|
||||
// 返回
|
||||
uni.navigateBack({
|
||||
delta:2
|
||||
})
|
||||
} else {
|
||||
this.$toolAll.tools.showToast(res.msg);
|
||||
}
|
||||
uni.hideLoading();
|
||||
this.isLoading = true;
|
||||
setTimeout(()=>{
|
||||
this.flag = true;
|
||||
},2000)
|
||||
})
|
||||
}
|
||||
},
|
||||
|
||||
// 验证表单
|
||||
checkEmpty(){
|
||||
let result = false;
|
||||
if(!this.findings) {
|
||||
this.$toolAll.tools.showToast('请填写调查结果');
|
||||
} else if(!this.results) {
|
||||
this.$toolAll.tools.showToast('请填写处理结果');
|
||||
} else {
|
||||
result = true;
|
||||
}
|
||||
return result;
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
|
|
@ -6,16 +6,16 @@
|
|||
<view @tap="switchEv(0)" class="pad-sx20 disjcac radius20" :style="switchIndex==0?'background-color:#39d091;color:#FFFFFF;':''" style="width: 288rpx;">待办理</view>
|
||||
<view @tap="switchEv(1)" class="pad-sx20 disjcac radius20" :style="switchIndex==1?'background-color:#39d091;color:#FFFFFF;':''" style="width: 288rpx;">已办理</view>
|
||||
</view>
|
||||
<view class="mar-s20 radius20 fon24 bacf posir" v-for="(item,index) in 50" :key="index">
|
||||
<view class="mar-s20 radius20 fon24 bacf posir" v-for="(item,index) in communityList" :key="index">
|
||||
<view class="pad-sx20 pad-zy50 status-box" :style="{backgroundColor:['#f8bf00','#39d091'][switchIndex]}">{{['待办理','已办理'][switchIndex]}}</view>
|
||||
<view class="pad20 bbot line-h46 pad-x40">
|
||||
<view class="fon30">LH20220729130234</view>
|
||||
<view class="">用户名:匿名提交</view>
|
||||
<view class="fon30">{{item.coding}}</view>
|
||||
<view class="">用户名:{{item.is_anonymous==1?'匿名提交':item.u_name}}</view>
|
||||
<view class="">金牛社区A村</view>
|
||||
<view class="">反馈问题:我就是想问下我们村的路多久能修好?</view>
|
||||
<view class="">反馈问题:{{item.description}}</view>
|
||||
</view>
|
||||
<view class="dis fon30 disjcac" v-if="switchIndex==0">
|
||||
<view @tap="handleEv(0)" class="pad-sx30 disac">
|
||||
<view @tap="handleEv(item.id)" class="pad-sx30 disac">
|
||||
<image class="mar-y20" src="/static/icon/icon-handle.png" mode="" style="width: 34rpx;height: 34rpx;"></image>
|
||||
立即办理
|
||||
</view>
|
||||
|
@ -35,15 +35,66 @@
|
|||
data() {
|
||||
return {
|
||||
switchIndex:0,
|
||||
newtop:uni.getSystemInfoSync().statusBarHeight
|
||||
newtop:uni.getSystemInfoSync().statusBarHeight,
|
||||
communityList:[], //数据列表
|
||||
type:['doing','done','all'], //办理状态
|
||||
page:1, //页数
|
||||
size:15, //条数
|
||||
total:0, //总数
|
||||
noMore:false, // 没有更多
|
||||
isLoading:false,
|
||||
}
|
||||
},
|
||||
onShow() {
|
||||
// 查询列表
|
||||
this.getListEv();
|
||||
},
|
||||
onReachBottom() {
|
||||
if(!this.noMore){
|
||||
this.page++;
|
||||
// 查询列表
|
||||
this.getListEv();
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
// 切换事件
|
||||
switchEv(index){
|
||||
console.log(index);
|
||||
this.switchIndex = index;
|
||||
if(index !== this.switchIndex){
|
||||
this.switchIndex = index;
|
||||
// 重置数据
|
||||
this.communityList= [];
|
||||
this.page = 1;
|
||||
// 查询列表
|
||||
this.getListEv();
|
||||
}
|
||||
},
|
||||
|
||||
// 查询列表
|
||||
getListEv(){
|
||||
uni.showLoading({
|
||||
title:'加载中'
|
||||
})
|
||||
let params = {
|
||||
page:this.page,
|
||||
size:this.size,
|
||||
type:this.type[this.switchIndex]
|
||||
}
|
||||
this.$requst.get('opinion/community-list',params).then(res => {
|
||||
if(res.code==0){
|
||||
console.log(res,'社区工单列表');
|
||||
this.total = res.data.total;
|
||||
this.communityList = this.communityList.concat(res.data.list)
|
||||
if(this.communityList.length == this.total){
|
||||
this.noMore =true;
|
||||
}
|
||||
} else {
|
||||
this.$toolAll.tools.showToast(res.msg);
|
||||
}
|
||||
uni.hideLoading();
|
||||
this.isLoading = true;
|
||||
})
|
||||
},
|
||||
|
||||
// 前往详情页面
|
||||
handleEv(id){
|
||||
uni.navigateTo({
|
||||
|
|
|
@ -86,7 +86,7 @@
|
|||
<view class="disjcac enter-btn" style="margin: 0;" @tap="handleEv">立即办理</view>
|
||||
</view>
|
||||
<view class="disjcac pad-sx50" v-if="ifManager==1">
|
||||
<view class="disjcac enter-btn" style="margin: 0;background-color: #f71200;border-color: #f71200;" @tap="handleEv">督办复审</view>
|
||||
<view class="disjcac enter-btn" style="margin: 0;background-color: #f71200;border-color: #f71200;" @tap="reexamineEv">督办复审</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
@ -99,11 +99,16 @@
|
|||
data() {
|
||||
return {
|
||||
audioText:'',
|
||||
ifManager:0//是否是管理员
|
||||
detail:{}, //工单详情
|
||||
ifManager:0, // 是否是管理员
|
||||
id:0, //工单id
|
||||
}
|
||||
},
|
||||
onLoad(op) {
|
||||
if(op.manager) this.ifManager = op.manager;
|
||||
if(op.id) this.id = op.id;
|
||||
// 查询详情
|
||||
this.getDetailEv();
|
||||
},
|
||||
onHide() {
|
||||
innerAudioContext.stop();
|
||||
|
@ -116,7 +121,39 @@
|
|||
innerAudioContext.play();
|
||||
}
|
||||
},
|
||||
// 前往立即办理页面
|
||||
|
||||
// 查询工单详情
|
||||
getDetailEv(){
|
||||
this.$requst.post('user/opinionInfo',{id:this.id}).then(res => {
|
||||
if(res.code==0){
|
||||
console.log(res,'社区工单详情');
|
||||
this.detail = res.data;
|
||||
} else {
|
||||
this.$toolAll.tools.showToast(res.msg);
|
||||
}
|
||||
uni.hideLoading();
|
||||
this.isLoading = true;
|
||||
})
|
||||
},
|
||||
|
||||
// 督办复审
|
||||
reexamineEv(){
|
||||
this.$requst.post('/api/administrator/examine',{id:this.id}).then(res => {
|
||||
if(res.code==0){
|
||||
console.log(res,'督办复审');
|
||||
// 返回
|
||||
uni.navigateBack({
|
||||
delta:1
|
||||
})
|
||||
} else {
|
||||
this.$toolAll.tools.showToast(res.msg);
|
||||
}
|
||||
uni.hideLoading();
|
||||
this.isLoading = true;
|
||||
})
|
||||
},
|
||||
|
||||
// 前往立即办理
|
||||
handleEv(id){
|
||||
uni.navigateTo({
|
||||
url:`/pagesA/community/handle/handle?id=${id}`
|
||||
|
|
|
@ -1,30 +1,30 @@
|
|||
<template>
|
||||
<view>
|
||||
<view v-if="isLoading">
|
||||
<statusContainer titlet="民意审核" :ifReturn="false">
|
||||
<view slot="content">
|
||||
<view class="bacf disja pad-sx20 fon30" :style="{top:newtop+42+'px'}" style="margin: -20rpx -20rpx 0 -20rpx;position: sticky;z-index: 10;">
|
||||
<view @tap="switchEv(0)" class="pad-sx20 disjcac radius20" :style="switchIndex==0?'background-color:#39d091;color:#FFFFFF;':''" style="width: 288rpx;">已处理</view>
|
||||
<view @tap="switchEv(1)" class="pad-sx20 disjcac radius20" :style="switchIndex==1?'background-color:#39d091;color:#FFFFFF;':''" style="width: 288rpx;">未处理</view>
|
||||
</view>
|
||||
<view class="mar-s20 radius20 fon24 bacf posir" v-for="(item,index) in 50" :key="index">
|
||||
<view class="mar-s20 radius20 fon24 bacf posir" v-for="(item,index) in reviewedList" :key="index">
|
||||
<view class="pad-sx20 pad-zy50 status-box" :style="{backgroundColor:['#39d091','#f8bf00','#f41500'][switchIndex]}">{{['已处理','待处理','已督办'][switchIndex]}}</view>
|
||||
<view class="pad20 bbot line-h46 pad-x40">
|
||||
<view class="fon30">LH20220729130234</view>
|
||||
<view class="">用户名:匿名提交</view>
|
||||
<view class="">金牛社区A村</view>
|
||||
<view class="">反馈问题:我就是想问下我们村的路多久能修好?</view>
|
||||
<view class="fon30">{{item.coding}}</view>
|
||||
<view class="">用户名:{{item.is_anonymous==1?'匿名提交':item.u_name}}</view>
|
||||
<view class="">{{item.state_text}}</view>
|
||||
<view class="">反馈问题:{{item.description}}</view>
|
||||
</view>
|
||||
<view class="dis fon30" v-if="switchIndex==0">
|
||||
<view @tap="goDetail(0)" class="width50 pad-sx30 disjcac border-r">
|
||||
<view @tap="goDetail(item.id)" class="width50 pad-sx30 disjcac border-r">
|
||||
<image class="mar-y20" src="/static/icon/icon-check.png" mode="" style="width: 34rpx;height: 34rpx;"></image>查看处理详情
|
||||
</view>
|
||||
<view class="width50 pad-sx30 disjcac">
|
||||
<view @tap="reexamineEv(item.id)" class="width50 pad-sx30 disjcac">
|
||||
<image class="mar-y20" src="/static/icon/icon-revie.png" mode="" style="width: 34rpx;height: 34rpx;"></image>
|
||||
督办复审
|
||||
</view>
|
||||
</view>
|
||||
<view class="dis fon30 disjcac" v-if="switchIndex==1">
|
||||
<view @tap="goDetail(0)" class="pad-sx30 disac">
|
||||
<view @tap="goDetail(item.id)" class="pad-sx30 disac">
|
||||
<image class="mar-y20" src="/static/icon/icon-check.png" mode="" style="width: 34rpx;height: 34rpx;"></image>
|
||||
查看处理详情
|
||||
</view>
|
||||
|
@ -44,13 +44,89 @@
|
|||
data() {
|
||||
return {
|
||||
switchIndex:0,
|
||||
newtop:uni.getSystemInfoSync().statusBarHeight
|
||||
newtop:uni.getSystemInfoSync().statusBarHeight,
|
||||
reviewedList:[], //数据列表
|
||||
type:[1,0], // 办理状态
|
||||
page:1, //页数
|
||||
size:15, //条数
|
||||
total:0, //总数
|
||||
noMore:false, // 没有更多
|
||||
isLoading:false,
|
||||
}
|
||||
},
|
||||
onShow() {
|
||||
// 查询列表
|
||||
this.getListEv();
|
||||
},
|
||||
onReachBottom() {
|
||||
if(!this.noMore){
|
||||
this.page++;
|
||||
// 查询列表
|
||||
this.getListEv();
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
// 切换事件
|
||||
switchEv(index){
|
||||
this.switchIndex = index;
|
||||
if(index!==this.switchIndex){
|
||||
this.switchIndex = index;
|
||||
// 重置数据
|
||||
this.reviewedList= [];
|
||||
this.page = 0;
|
||||
// 查询列表
|
||||
this.getListEv();
|
||||
}
|
||||
},
|
||||
// 查询列表
|
||||
getListEv(){
|
||||
uni.showLoading({
|
||||
title:'加载中'
|
||||
})
|
||||
let params = {
|
||||
page:this.page,
|
||||
size:this.size,
|
||||
state:this.type[this.switchIndex]
|
||||
}
|
||||
this.$requst.post('administrator/reviewedList',params).then(res => {
|
||||
if(res.code==0){
|
||||
console.log(res,'处理情况列表');
|
||||
this.total = res.data.total;
|
||||
let reviewedArr = [];
|
||||
res.data.list.forEach(item=>{
|
||||
let obj = {
|
||||
id:item.id,
|
||||
coding:item.coding,
|
||||
state_text:item.state_text,
|
||||
u_name:item.u_name,
|
||||
u_phone:item.u_phone,
|
||||
description:item.description,
|
||||
is_anonymous:item.is_anonymous,
|
||||
}
|
||||
reviewedArr.push(obj);
|
||||
})
|
||||
this.reviewedList = this.reviewedList.concat(reviewedArr)
|
||||
if(this.reviewedList.length == this.total){
|
||||
this.noMore =true;
|
||||
}
|
||||
} else {
|
||||
this.$toolAll.tools.showToast(res.msg);
|
||||
}
|
||||
uni.hideLoading();
|
||||
this.isLoading = true;
|
||||
})
|
||||
},
|
||||
// 督办复审
|
||||
reexamineEv(id){
|
||||
this.$requst.post('administrator/examine',{id:id}).then(res => {
|
||||
if(res.code==0){
|
||||
console.log(res,'督办复审');
|
||||
this.$toolAll.tools.showToast('审核成功');
|
||||
} else {
|
||||
this.$toolAll.tools.showToast(res.msg);
|
||||
}
|
||||
uni.hideLoading();
|
||||
this.isLoading = true;
|
||||
})
|
||||
},
|
||||
// 前往详情页
|
||||
goDetail(id){
|
||||
|
|
Loading…
Reference in New Issue