刘翔宇-旅管家 3 years ago
parent 2cbaa39e97
commit 3279a97a31

@ -218,6 +218,15 @@
} }
} }
,{
"path" : "pages/guide/feedbackinfo",
"style" :
{
"navigationBarTitleText": "意见建议详情",
"enablePullDownRefresh": false
}
}
], ],
"globalStyle": { "globalStyle": {
"navigationBarTextStyle": "black", "navigationBarTextStyle": "black",

@ -48,20 +48,20 @@
</view> </view>
</view> </view>
<view class="infoBox" style="padding-bottom:0;margin-bottom: 26rpx;"> <view class="infoBox" style="padding-bottom:0;margin-bottom: 26rpx;">
<view class="activityBox-row"> <view class="activityBox-row">
<view class="infoBox-title"> <view class="infoBox-title">
<text class="infoBox-titletxt">活动场次</text> <text class="infoBox-titletxt">活动场次</text>
</view> </view>
<view class="numbers"> <view class="numbers">
<u-radio-group placement="column" v-model="chooseNum" @change="numChange"> <u-radio-group placement="column" v-model="chooseNum" @change="numChange">
<u-radio activeColor="#EF9525" v-for="(item, index) in numbers" :key="index" <u-radio activeColor="#EF9525" v-for="(item, index) in numbers" :key="index"
:label="item.label" :disabled="item.disabled" :name="item.id"> :label="item.label" :disabled="item.disabled" :name="item.id">
</u-radio> </u-radio>
</u-radio-group> </u-radio-group>
</view> </view>
</view> </view>
</view> </view>
<view class="infoBox"> <view class="infoBox">
<view class="infoBox-title"> <view class="infoBox-title">
@ -114,9 +114,9 @@
topSwiperIndex: 0, topSwiperIndex: 0,
chooseNum: "", chooseNum: "",
numbers: [], numbers: [],
showNumbers: false, showNumbers: false,
teamType:"", teamType: "",
activity_number_id:"" activity_number_id: ""
} }
}, },
onLoad(options) { onLoad(options) {
@ -150,32 +150,34 @@
name: this.list.name, name: this.list.name,
address: this.list.address address: this.list.address
}) })
}, },
closeNum(){ closeNum() {
this.showNumbers=false this.showNumbers = false
this.chooseNum = "" this.chooseNum = ""
}, },
numChange(val) { numChange(val) {
console.log(val) console.log(val)
this.activity_number_id = val this.activity_number_id = val
console.log("book?type=" + this.teamType + "&activity_id=" + this.id + "&activity_number_id="+this.activity_number_id) console.log("book?type=" + this.teamType + "&activity_id=" + this.id + "&activity_number_id=" + this
// uni.navigateTo({ .activity_number_id)
// url: "book?type=" + this.teamType + "&activity_id=" + this.id + "&activity_number_id="+this.activity_number_id // uni.navigateTo({
// }) // url: "book?type=" + this.teamType + "&activity_id=" + this.id + "&activity_number_id="+this.activity_number_id
// })
}, },
tobook(type) { tobook(type) {
// this.showNumbers = true // this.showNumbers = true
this.teamType = type; this.teamType = type;
if(this.util.isNull(this.activity_number_id)){ if (this.util.isNull(this.activity_number_id)) {
uni.showToast({ uni.showToast({
icon: "none", icon: "none",
title: "请选择活动场次" title: "请选择活动场次"
}) })
return false; return false;
} }
uni.navigateTo({ uni.navigateTo({
url: "book?type=" + this.teamType + "&activity_id=" + this.id + "&activity_number_id="+this.activity_number_id url: "book?type=" + this.teamType + "&activity_id=" + this.id + "&activity_number_id=" + this
.activity_number_id
}) })
}, },
loadActiveInfo() { loadActiveInfo() {
@ -190,17 +192,20 @@
}, },
utilSuccess: function(res) { utilSuccess: function(res) {
res.isCanBook = that.$moment(nt).isBefore(res.end_plan); res.isCanBook = that.$moment(nt).isBefore(res.end_plan);
that.list = res; that.list = res;
let numberArr = [] let numberArr = []
let nowTime = that.getNowTime() let nowTime = that.getNowTime()
for(var m of res.numbers){ for (var m of res.numbers) {
m.label = m.name + "(" + that.timeFormat(m.start_time,"yyyy年MM月DD日") + " " + that.getHm(m.start_time)+"-"+that.getHm(m.end_time) + ")" m.label = m.name + "(" + that.timeFormat(m.start_time, "yyyy年MM月DD日") + " " + that
if(m.has_total==m.total&&m.total!=0 || that.compareDate(nowTime,m.end_plan)){ .getHm(m.start_time) + "-" + that.getHm(m.end_time) + ")"
m.disabled = true if (m.has_total == m.total && m.total != 0 || that.compareDate(nowTime, m
} .end_plan)) {
m.disabled = true
}
numberArr.push(m) numberArr.push(m);
if(that.chooseNum==""){
that.chooseNum=m.id;
}
} }
that.numbers = numberArr that.numbers = numberArr
wx.setStorage({ wx.setStorage({
@ -215,23 +220,23 @@
} }
}) })
}, },
// //
getNowTime(){ getNowTime() {
const date = new Date(); const date = new Date();
let year = date.getFullYear(); let year = date.getFullYear();
let month = date.getMonth() + 1; let month = date.getMonth() + 1;
let day = date.getDate(); let day = date.getDate();
let hours = date.getHours() let hours = date.getHours()
let minutes = date.getMinutes() let minutes = date.getMinutes()
let seconds =date.getSeconds() let seconds = date.getSeconds()
month = month > 9 ? month : '0' + month; month = month > 9 ? month : '0' + month;
day = day > 9 ? day : '0' + day; day = day > 9 ? day : '0' + day;
return `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`; return `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`;
}, },
compareDate(d1, d2) { compareDate(d1, d2) {
let reg = new RegExp('-', 'g') let reg = new RegExp('-', 'g')
return ((new Date(d1.replace(reg, '/'))) > (new Date(d2.replace(reg, '/')))) return ((new Date(d1.replace(reg, '/'))) > (new Date(d2.replace(reg, '/'))))
}, },
topSwiperTab(e) { topSwiperTab(e) {
var that = this; var that = this;
@ -296,18 +301,20 @@
box-sizing: border-box; box-sizing: border-box;
/* background: linear-gradient(0deg, #ffffff 85%, #E4C8A2); */ /* background: linear-gradient(0deg, #ffffff 85%, #E4C8A2); */
} }
.mpopup{
margin-top:0rpx; .mpopup {
min-height:200rpx margin-top: 0rpx;
min-height: 200rpx
} }
.mpopup-title{
padding:20rpx 0 .mpopup-title {
padding: 20rpx 0
} }
.numbers { .numbers {
/* min-height: 300rpx; */ /* min-height: 300rpx; */
padding: 31rpx 24rpx; padding: 31rpx 24rpx;
padding-bottom:13rpx; padding-bottom: 13rpx;
} }
.numbers .u-radio { .numbers .u-radio {
@ -326,4 +333,4 @@
.colortext { .colortext {
color: #D98012 color: #D98012
} }
</style> </style>

@ -63,22 +63,40 @@
method: "POST", method: "POST",
utilSuccess: function(res) { utilSuccess: function(res) {
console.log(res) console.log(res)
uni.showToast({ that.newsSubscription();
icon: "none",
title: "投诉建议成功",
complete() {
uni.reLaunch({
url: "/pages/success/success?from=feed"
})
}
})
}, },
utilFail: function(res) { utilFail: function(res) {
that.util.toast(res); that.util.toast(res);
} }
}) })
} },
newsSubscription() {
uni.getSetting({
withSubscriptions: true, //false
success(res) {
if (res.authSetting['scope.subscribeMessage']) {
uni.redirectTo({
url: '/pages/success/success?from=feed'
})
} else {
//
uni.requestSubscribeMessage({
tmplIds: ['gPP22-SXuJmK9ffJZTNOSdq56Q2RmD2Qdg8ntteAO-Y'],
success(res) {
uni.showToast({
title: '订阅成功'
})
uni.redirectTo({
url: '/pages/success/success?from=feed'
})
}
})
}
}
});
},
} }
} }
</script> </script>
@ -118,4 +136,4 @@
.bgbottom { .bgbottom {
height: 40rpx; height: 40rpx;
} }
</style> </style>

@ -0,0 +1,105 @@
<template>
<view class="box">
<view class="bgtop">
<image src="../../static/img/nav_top.png" style="width: 100%;height: 100%;"></image>
</view>
<view class="bgcenter" :style="{height:height+'px'}">
<view class="box-content">
反馈时间{{info.created_at||""}}
</view>
<view class="box-content" style="margin-top: 10px;">
反馈内容<rich-text :nodes="info.content"></rich-text>
</view>
<view class="box-content" style="margin-top: 40px;">
回复时间{{info.reply_time||""}}
</view>
<view class="box-content" style="margin-top: 10px;">
回复内容<rich-text :nodes="info.reply"></rich-text>
</view>
</view>
<view class="bgbottom">
<image src="../../static/img/nav_bottom.png" style="width: 100%;height: 100%;"></image>
</view>
</view>
</template>
<script>
export default {
data() {
return {
height: 0,
info: {}
}
},
onLoad(options) {
let that = this;
uni.getSystemInfo({
success: function(res) {
that.height = res.windowHeight - 60;
}
});
that.loadInfo(options.id);
},
methods: {
loadInfo(id) {
var that = this;
this.util.request({
api: "/api/mobile/other/tip-show",
data: {
id: id
},
utilSuccess: function(res) {
res.content = res.content.replace(/\<img/g,
"<img style='width:100%;height:auto;display:block'")
that.info = res;
},
utilFail: function(res) {
uni.showToast({
icon: "none",
title: res,
duration: 2000
})
}
})
}
}
}
</script>
<style>
.box {
padding: 20rpx;
box-sizing: border-box;
}
.bgtop {
height: 40rpx;
}
.bgcenter {
background: url("../../static/img/nav_middle.png") repeat-y;
background-size: 100% 100%;
padding: 15rpx 20rpx;
}
.time {
padding: 20rpx 0;
}
.newbox {
padding: 15rpx 20rpx;
color: #351C1B;
box-sizing: border-box;
}
.title {}
.time {
font-size: 24rpx;
}
.bgbottom {
height: 40rpx;
}
</style>

@ -127,22 +127,38 @@
data: this.form, data: this.form,
method: "POST", method: "POST",
utilSuccess: function(res) { utilSuccess: function(res) {
console.log(res) that.newsSubscription();
uni.showToast({
icon: "none",
title: "投诉建议成功",
complete() {
uni.reLaunch({
url: "/pages/success/success?from=feed"
})
}
})
}, },
utilFail: function(res) { utilFail: function(res) {
that.util.toast(res); that.util.toast(res);
} }
}) })
},
newsSubscription() {
uni.getSetting({
withSubscriptions: true, //false
success(res) {
if (res.authSetting['scope.subscribeMessage']) {
uni.redirectTo({
url: '/pages/success/success?from=feed'
})
} else {
//
uni.requestSubscribeMessage({
tmplIds: ['gPP22-SXuJmK9ffJZTNOSdq56Q2RmD2Qdg8ntteAO-Y'],
success(res) {
uni.showToast({
title: '订阅成功'
})
uni.redirectTo({
url: '/pages/success/success?from=feed'
})
}
})
}
}
});
} }
} }
} }

Loading…
Cancel
Save