diff --git a/subpages/demandCheck/images/satisfy-images/face1.png b/subpages/demandCheck/images/satisfy-images/face1.png
new file mode 100644
index 0000000..044aa15
Binary files /dev/null and b/subpages/demandCheck/images/satisfy-images/face1.png differ
diff --git a/subpages/demandCheck/images/satisfy-images/face1_light.png b/subpages/demandCheck/images/satisfy-images/face1_light.png
new file mode 100644
index 0000000..51e427f
Binary files /dev/null and b/subpages/demandCheck/images/satisfy-images/face1_light.png differ
diff --git a/subpages/demandCheck/images/satisfy-images/face2.png b/subpages/demandCheck/images/satisfy-images/face2.png
new file mode 100644
index 0000000..0733ff1
Binary files /dev/null and b/subpages/demandCheck/images/satisfy-images/face2.png differ
diff --git a/subpages/demandCheck/images/satisfy-images/face2_light.png b/subpages/demandCheck/images/satisfy-images/face2_light.png
new file mode 100644
index 0000000..071cf7a
Binary files /dev/null and b/subpages/demandCheck/images/satisfy-images/face2_light.png differ
diff --git a/subpages/demandCheck/images/satisfy-images/face3.png b/subpages/demandCheck/images/satisfy-images/face3.png
new file mode 100644
index 0000000..f85b027
Binary files /dev/null and b/subpages/demandCheck/images/satisfy-images/face3.png differ
diff --git a/subpages/demandCheck/images/satisfy-images/face3_light.png b/subpages/demandCheck/images/satisfy-images/face3_light.png
new file mode 100644
index 0000000..ec20e18
Binary files /dev/null and b/subpages/demandCheck/images/satisfy-images/face3_light.png differ
diff --git a/subpages/demandCheck/pages/dissatisfied/demandCheck/demandCheck.js b/subpages/demandCheck/pages/dissatisfied/demandCheck/demandCheck.js
index b697cb6..d686f8a 100644
--- a/subpages/demandCheck/pages/dissatisfied/demandCheck/demandCheck.js
+++ b/subpages/demandCheck/pages/dissatisfied/demandCheck/demandCheck.js
@@ -35,7 +35,8 @@ Page({
content: "", //内容
address: "", //地址
demandType:'chengguan',
- status: "processing"
+ status: "processing",
+ satisfaction:''
},
minDate: '2018-01-01 00:00:00',
@@ -90,6 +91,17 @@ Page({
categoryIds:'',
processData: [],
+
+ //满意度评价
+ selBad: false,
+ selGood: false,
+ selPerfect: false,
+ badurl: "../../../images/satisfy-images/face1.png",
+ badurl_light: "../../../images/satisfy-images/face1_light.png",
+ goodurl: "../../../images/satisfy-images/face2.png",
+ goodurl_light: "../../../images/satisfy-images/face2_light.png",
+ perfecturl: "../../../images/satisfy-images/face3.png",
+ perfecturl_light: "../../../images/satisfy-images/face3_light.png",
},
@@ -177,6 +189,7 @@ Page({
'fmData.responsibleName': res.data.responsibleName,
'fmData.responsibleMobile': res.data.responsibleMobile,
'fmData.status': res.data.status,
+ 'fmData.satisfaction': res.data.satisfaction!=null?res.data.satisfaction:'',
agencyName: res.data.gridName,
showTime: res.data.happenTime,
addressContent: res.data.address,
@@ -199,6 +212,22 @@ Page({
if (this.data.uploadRecord) {
this.downLoadAudio()
}
+ if(this.data.fmData.satisfaction==='bad'){
+
+ this.setData({
+ selBad: true
+ });
+ }else if(this.data.fmData.satisfaction==='good'){
+
+ this.setData({
+ selGood: true
+ });
+ }else if(this.data.fmData.satisfaction==='perfect'){
+
+ this.setData({
+ selPerfect: true
+ });
+ }
}).catch(err => {
console.log(err);
})
@@ -425,6 +454,50 @@ formatTimestamp(timestamp) {
}
})
},
+
+ comment(){
+ let that = this
+ wx.showModal({
+ title: '提示',
+ content: '确定要提交满意度吗?',
+ success(res) {
+ if (res.confirm) {
+ that.icEventOldComment()
+ } else if (res.cancel) {}
+ }
+ })
+ },
+
+ icEventOldComment() {
+ const parm = {}
+ parm.icEventId = this.data.optionsId
+ if (this.data.selBad) {
+ parm.satisfaction = "bad";
+ } else if (this.data.selGood) {
+ parm.satisfaction = "good";
+ } else if (this.data.selPerfect) {
+ parm.satisfaction = "perfect";
+ }
+
+ api.icEventOldComment(parm).then(res => {
+ if (res.code === 0) {
+ wx.showToast({
+ title: '评价成功',
+ icon: 'none',
+ success() {
+ setTimeout(() => {
+ wx.navigateBack({
+ delta: 1
+ })
+ }, 3000)
+ }
+ })
+ }
+ }).catch(err => {
+ console.log(err);
+ })
+ },
+
icEventOldDelete() {
api.icEventOldDelete([this.data.optionsId]).then(res => {
if (res.code === 0) {
@@ -1757,6 +1830,28 @@ formatTimestamp(timestamp) {
url: `/subpages/myTroubleshootDemand/pages/event/event?id=${this.data.optionsId}&categoryIds=${this.data.categoryIds}`,
})
},
+ clickSatisfy(e){
+ const type = e.currentTarget.dataset.satisfy;
+ if (type === "bad") {
+ this.setData({
+ selGood: false,
+ selPerfect: false,
+ selBad: true
+ })
+ } else if (type === "good") {
+ this.setData({
+ selGood: true,
+ selPerfect: false,
+ selBad: false
+ })
+ } else if (type === "perfect") {
+ this.setData({
+ selGood: false,
+ selPerfect: true,
+ selBad: false
+ })
+ }
+ },
previewImage(e) {
const currentUrl = e.currentTarget.dataset.url;
wx.previewImage({
diff --git a/subpages/demandCheck/pages/dissatisfied/demandCheck/demandCheck.wxml b/subpages/demandCheck/pages/dissatisfied/demandCheck/demandCheck.wxml
index 27412d9..5b9ed6e 100644
--- a/subpages/demandCheck/pages/dissatisfied/demandCheck/demandCheck.wxml
+++ b/subpages/demandCheck/pages/dissatisfied/demandCheck/demandCheck.wxml
@@ -192,6 +192,29 @@
+
+ 满意度评价
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
处理进展
@@ -298,9 +321,13 @@
-
+
+
+
+
+
diff --git a/subpages/demandCheck/pages/dissatisfied/demandCheck/demandCheck.wxss b/subpages/demandCheck/pages/dissatisfied/demandCheck/demandCheck.wxss
index b93a4eb..e088d0c 100644
--- a/subpages/demandCheck/pages/dissatisfied/demandCheck/demandCheck.wxss
+++ b/subpages/demandCheck/pages/dissatisfied/demandCheck/demandCheck.wxss
@@ -1144,6 +1144,23 @@ background: rgb(175, 1, 1);
border-radius: 5px; /* 圆角边框,可根据需要调整 */
}
+.satisfy_image-row{
+ display: flex;
+ flex-wrap: nowrap; /* 防止换行 */
+ overflow-x: auto; /* 当图片超出一行时,可以横向滚动 */
+ align-items: center;
+ margin-top: 50rpx;
+}
+.satisfy_image-row image {
+ flex: 0 0 auto; /* 防止图片缩放 */
+ margin: 0 15px; /* 控制图片之间的间距 */
+ width: 80px; /* 固定宽度,可根据需要调整 */
+ height: 80px; /* 固定高度,可根据需要调整 */
+ object-fit: cover; /* 保持图片比例 */
+ border: 2px solid #ccc; /* 添加边框,颜色为浅灰色 */
+ border-radius: 5px; /* 圆角边框,可根据需要调整 */
+}
+
.disabled {
pointer-events: none; /* 禁止点击 */
}
diff --git a/utils/api.js b/utils/api.js
index d50b01b..cff4c16 100644
--- a/utils/api.js
+++ b/utils/api.js
@@ -63,6 +63,7 @@ module.exports = {
updateMeasure,
userDemandCance,
icEventOldDelete,
+ icEventOldComment,
updateEvent,
submitResi,
getAllOrgCategoryCount,
@@ -359,6 +360,10 @@ function userDemandCance(parm) {
function icEventOldDelete(parm) {
return fly.post(`governance/icEventOld/delete`,parm)
}
+// 评价事件
+function icEventOldComment(parm) {
+ return fly.post(`governance/icEventOld/comment`,parm)
+}
// 更新事件
function updateEvent(parm) {
return fly.post(`governance/icEventOld/update`,parm)