问题反馈修改
This commit is contained in:
@@ -1,16 +1,28 @@
|
||||
<template>
|
||||
<view class="content">
|
||||
<uni-list :border="false">
|
||||
<uni-list-item :show-badge="item.chatCount > 0" badgeType="error" isDot badge-text="新消息" :title="item.title"
|
||||
:note="item.createTime" clickable v-for="(item, index) in store.data" :key="index" @click="jump(item)" />
|
||||
</uni-list>
|
||||
<view class="message-list">
|
||||
<view class="message-list-item" v-for="(item, index) in store.data" :key="index" @click="jump(item)">
|
||||
<view class="hide-txt message-list-item-title">{{ item.title }}</view>
|
||||
<view class="message-list-item-footer">
|
||||
<view class="mr20 message-list-item-footer-status message-list-item-footer-status-close" v-if="item.status === '0'">
|
||||
已关闭
|
||||
</view>
|
||||
<view class="mr20 message-list-item-footer-status message-list-item-footer-status-processing" v-else-if="item.status === '1'">
|
||||
待处理
|
||||
</view>
|
||||
<view class="mr20 message-list-item-footer-status message-list-item-footer-status-over" v-else-if="item.status === '2'">
|
||||
已解决
|
||||
</view>
|
||||
<view class="message-list-item-footer-time"> {{ item.createTime }}</view>
|
||||
<uni-badge class="uni-badge-left-margin" :text="item.chatCount"/>
|
||||
</view>
|
||||
</view>
|
||||
<Cn-empty v-if="store.empty"></Cn-empty>
|
||||
<uni-load-more v-if="store.data && store.data.length > 0" :status="store.status"></uni-load-more>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { queryFeedBackPage } from '../../common/api/feedback'
|
||||
import {queryFeedBackPage} from '../../common/api/feedback'
|
||||
import list from '../../common/js/list'
|
||||
|
||||
export default {
|
||||
@@ -29,15 +41,59 @@ export default {
|
||||
this.store.reload()
|
||||
},
|
||||
jump(item) {
|
||||
uni.navigateTo({ url: '/pages/message/feedbackDetail?id=' + item.id +'&chatCount=' + item.chatCount })
|
||||
}
|
||||
uni.navigateTo({url: '/pages/message/feedbackDetail?id=' + item.id + '&chatCount=' + item.chatCount})
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
.content {
|
||||
.message-list {
|
||||
padding-top: 20rpx;
|
||||
|
||||
.message-list-item {
|
||||
padding: 28rpx;
|
||||
background: #fff;
|
||||
border-bottom: 1rpx solid #ddd;
|
||||
&-title {
|
||||
font-size: 28rpx;
|
||||
color: #3b4144;
|
||||
}
|
||||
|
||||
.message-list-item-footer {
|
||||
margin-top: 8rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
&-time{
|
||||
margin-right: 20rpx;
|
||||
flex: 1;
|
||||
color: #999;
|
||||
font-size: 12px;
|
||||
}
|
||||
&-status {
|
||||
padding: 4rpx 12rpx;
|
||||
font-size: 24rpx;
|
||||
border-radius: 4rpx;
|
||||
&-over {
|
||||
background-color: #f0f9eb;
|
||||
border-color: #e1f3d8;
|
||||
color: #67c23a;
|
||||
}
|
||||
|
||||
&-close {
|
||||
background-color: #f4f4f5;
|
||||
border-color: #e9e9eb;
|
||||
color: #909399;
|
||||
}
|
||||
|
||||
&-processing {
|
||||
background-color: #fdf6ec;
|
||||
border-color: #faecd8;
|
||||
color: #e6a23c;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -45,9 +101,21 @@ export default {
|
||||
background-color: $uni-theme-white !important;
|
||||
}
|
||||
|
||||
/deep/ .uni-badge {
|
||||
background-color: unset !important;
|
||||
color: #dd524d !important;
|
||||
font-size: 28rpx !important;
|
||||
.list-footer {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
|
||||
&-status {
|
||||
flex: 1;
|
||||
color: #999;
|
||||
font-size: 24rpx;
|
||||
}
|
||||
}
|
||||
|
||||
///deep/ .uni-badge {
|
||||
// background-color: unset !important;
|
||||
// color: #dd524d !important;
|
||||
// font-size: 28rpx !important;
|
||||
//}
|
||||
</style>
|
||||
|
||||
@@ -6,25 +6,34 @@
|
||||
<view class="detail-content-title mb20">{{ pageData.title }}</view>
|
||||
<view> {{ pageData.createTime }}</view>
|
||||
<view class="mt10 mb10">{{ pageData.description }}</view>
|
||||
<uni-file-picker readonly v-model="imageValue" mode="grid" />
|
||||
<uni-file-picker readonly v-model="imageValue" mode="grid"/>
|
||||
</view>
|
||||
<view class="detail-content " style="margin-bottom:0">
|
||||
<view class="detail-content-title ">
|
||||
<view class="title">回复</view>
|
||||
<view class="title-btn" @click="open">新增</view>
|
||||
<view class="title">消息列表</view>
|
||||
<template v-if="pageData.status === '1'">
|
||||
<view class="title-btn mr10" @click="updateFeedBackStatus('2')">解决</view>
|
||||
<view class="title-btn mr10" @click="updateFeedBackStatus('0')">关闭</view>
|
||||
</template>
|
||||
<template v-if="pageData.status === '2'">
|
||||
<view class="title-btn mr10" @click="updateFeedBackStatus('0')">关闭</view>
|
||||
</template>
|
||||
<view class="title-btn" @click="open">回复</view>
|
||||
</view>
|
||||
</view>
|
||||
<uni-list>
|
||||
<uni-list-item :title="item.userName" :note="item.chatContent" :rightText="item.createTime"
|
||||
v-for="(item, index) in pageData.csFeedbackChatPOList" :key="index" />
|
||||
<Cn-empty v-if="pageData.csFeedbackChatPOList && pageData.csFeedbackChatPOList.length == 0"></Cn-empty>
|
||||
v-for="(item, index) in pageData.csFeedbackChatPOList" :key="index"/>
|
||||
<Cn-empty
|
||||
v-if="pageData.csFeedbackChatPOList && pageData.csFeedbackChatPOList.length == 0"></Cn-empty>
|
||||
</uni-list>
|
||||
<!-- 输入框示例 -->
|
||||
<uni-popup ref="inputDialog" type="dialog">
|
||||
<uni-popup-dialog ref="inputClose" type="info" mode="input" title="输入内容" value="对话框预置提示内容!"
|
||||
placeholder="请输入内容" @confirm="dialogInputConfirm">
|
||||
<uni-popup-dialog ref="inputClose" type="info" mode="input" title="输入内容"
|
||||
value="对话框预置提示内容!"
|
||||
placeholder="请输入内容" @confirm="dialogInputConfirm">
|
||||
<uni-easyinput type="textarea" :maxlength="250" autoHeight v-model="chatContent"
|
||||
placeholder="请输入内容"></uni-easyinput>
|
||||
placeholder="请输入内容"></uni-easyinput>
|
||||
</uni-popup-dialog>
|
||||
</uni-popup>
|
||||
</view>
|
||||
@@ -32,7 +41,8 @@
|
||||
</Cn-page>
|
||||
</template>
|
||||
<script>
|
||||
import { queryFeedBackDetail, AddFeedbackChat, updateChatStatus } from '../../common/api/feedback'
|
||||
import {queryFeedBackDetail, AddFeedbackChat, updateChatStatus, updateFeedBackStatus} from '../../common/api/feedback'
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
@@ -45,8 +55,7 @@ export default {
|
||||
"url": "/static/logo.png",
|
||||
}
|
||||
],
|
||||
pageData: {
|
||||
},
|
||||
pageData: {},
|
||||
pageOption: {}
|
||||
}
|
||||
},
|
||||
@@ -60,6 +69,14 @@ export default {
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
updateFeedBackStatus(status) {
|
||||
updateFeedBackStatus({
|
||||
id: this.pageOption.id,
|
||||
status: status
|
||||
}).then(res => {
|
||||
this.init()
|
||||
})
|
||||
},
|
||||
init() {
|
||||
this.loading = true
|
||||
queryFeedBackDetail(this.pageOption.id).then(res => {
|
||||
@@ -78,7 +95,7 @@ export default {
|
||||
})
|
||||
},
|
||||
dialogInputConfirm() {
|
||||
AddFeedbackChat({ chatContent: this.chatContent, id: this.pageOption.id }).then(res => {
|
||||
AddFeedbackChat({chatContent: this.chatContent, id: this.pageOption.id}).then(res => {
|
||||
console.log(res);
|
||||
this.$util.toast('回复成功')
|
||||
this.init()
|
||||
@@ -87,13 +104,17 @@ export default {
|
||||
},
|
||||
open() {
|
||||
this.$refs.inputDialog.open()
|
||||
}
|
||||
},
|
||||
over() {
|
||||
},
|
||||
close() {
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang='scss'>
|
||||
.detail {
|
||||
padding: 20rpx 0;
|
||||
padding: 0 0 20rpx;
|
||||
|
||||
.detail-content {
|
||||
padding: 20rpx 30rpx;
|
||||
|
||||
Reference in New Issue
Block a user