对接 投诉详情 投诉列表 选择处理人员 api
This commit is contained in:
@@ -6,13 +6,14 @@
|
||||
<view class="line"></view>
|
||||
<text>投诉状态</text>
|
||||
</view>
|
||||
<view class="status" v-if="info.status === 0"> <text>待处理</text> </view>
|
||||
<view class="status alwary" v-if="info.status === 1">
|
||||
<view class="status" v-if="complainInfo.status === '0'"> <text>待处理</text> </view>
|
||||
<view class="status alwary" v-if="complainInfo.status === '2'">
|
||||
<text>已完成</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="subDescrition" v-if="info.status === 1">
|
||||
<text>已完成处理,已联系工作人员粘贴标语提醒,并派人定时巡视。</text>
|
||||
<view class="subDescrition" v-if="complainInfo.status === '2'">
|
||||
<!-- <text>已完成处理,已联系工作人员粘贴标语提醒,并派人定时巡视。</text> -->
|
||||
<text>{{ complainInfo.handleContent }}</text>
|
||||
</view>
|
||||
<view class="items flex items-center justify-between">
|
||||
<view class="title flex items-center">
|
||||
@@ -24,28 +25,30 @@
|
||||
<view class="item">
|
||||
<view class="label"> 投诉类型 </view>
|
||||
<view class="value flex items-center justify-between">
|
||||
<view class=""> 社区服务 </view>
|
||||
<view class="">
|
||||
<text>{{ complainInfo.typeName }}</text>
|
||||
</view>
|
||||
<uni-icons type="right" size="14" color="#000000"></uni-icons>
|
||||
</view>
|
||||
</view>
|
||||
<view class="item">
|
||||
<view class="label"> 问题描述 </view>
|
||||
<view class="value">
|
||||
<text
|
||||
>投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容投诉内容
|
||||
</text>
|
||||
<text>{{ complainInfo.problemDes }} </text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="item">
|
||||
<view class="label"> 投诉人姓名 </view>
|
||||
<view class="value">
|
||||
<text>匿名 </text>
|
||||
<text>
|
||||
{{ complainInfo.complaintName }}
|
||||
</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="item">
|
||||
<view class="label"> 手机号码 </view>
|
||||
<view class="value">
|
||||
<text>无 </text>
|
||||
<text> {{ complainInfo.phone }}</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="photobox">
|
||||
@@ -54,7 +57,7 @@
|
||||
</view>
|
||||
<view class="imgbox">
|
||||
<image
|
||||
v-for="(item, index) in info.imgs"
|
||||
v-for="(item, index) in showImages"
|
||||
:key="index"
|
||||
:src="item"
|
||||
class="img"
|
||||
@@ -65,7 +68,7 @@
|
||||
</view>
|
||||
|
||||
<!-- submit -->
|
||||
<view v-if="info.status === 0" class="action_btn" @tap="handleSelecthouse">
|
||||
<view v-if="complainInfo.status === '0'" class="action_btn" @tap="handleSelecthouse">
|
||||
<text>处理</text>
|
||||
</view>
|
||||
</view>
|
||||
@@ -73,7 +76,10 @@
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { ref } from 'vue'
|
||||
import { onMounted, ref } from 'vue'
|
||||
import { onLoad, onShow } from '@dcloudio/uni-app'
|
||||
import { getComplainMain } from '@/api/complain.js'
|
||||
|
||||
const info = ref({
|
||||
status: 0, //0待解决 1已完成
|
||||
imgs: [
|
||||
@@ -84,10 +90,55 @@ const info = ref({
|
||||
'https://picsum.photos/61'
|
||||
]
|
||||
})
|
||||
|
||||
/** 投诉详情id */
|
||||
const complainId = ref('')
|
||||
/** 投诉详情内容 */
|
||||
const complainInfo = ref({
|
||||
id: '',
|
||||
typeId: null,
|
||||
typeName: '',
|
||||
problemDes: '',
|
||||
complaintName: '',
|
||||
phone: '',
|
||||
villageId: null,
|
||||
problemImageUrl: '',
|
||||
status: '0',
|
||||
createTime: null,
|
||||
handleId: '',
|
||||
handleName: '',
|
||||
handleContent: ''
|
||||
})
|
||||
const showImages = ref([])
|
||||
// 接受列表传递过来的id
|
||||
onLoad(options => {
|
||||
if (options && options.id && options.id.trim()) {
|
||||
complainId.value = options.id
|
||||
}
|
||||
})
|
||||
|
||||
// 查询 投诉详情
|
||||
function init() {
|
||||
if (complainId.value) {
|
||||
getComplainMain(complainId.value).then(res => {
|
||||
complainInfo.value = res.data
|
||||
showImages.value = res.data.problemImageUrl
|
||||
.split(',')
|
||||
.filter(item => item.includes('http'))
|
||||
.map(item => item.split('?')[0])
|
||||
})
|
||||
}
|
||||
}
|
||||
onShow(() => {
|
||||
init()
|
||||
})
|
||||
|
||||
function handleSelecthouse() {
|
||||
uni.navigateTo({
|
||||
url: '/pageSubPack/complaint/handle'
|
||||
})
|
||||
if (complainId.value) {
|
||||
uni.navigateTo({
|
||||
url: '/pageSubPack/complaint/handle?handleId=' + complainId.value
|
||||
})
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -176,6 +227,7 @@ function handleSelecthouse() {
|
||||
.img {
|
||||
width: 132rpx;
|
||||
height: 132rpx;
|
||||
border: 1rpx solid #efefef;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user