diff --git a/api/api.js b/api/api.js index 3e38a6c..71a0435 100644 --- a/api/api.js +++ b/api/api.js @@ -247,6 +247,14 @@ const config = { auth: true, showLoading : true, }, + // 提交反馈接口 + submitFeedback: { + url: '/api/info/submitFeedback', + method: 'POST', + auth: true, + limit : 3000, + showLoading : true, + }, //小程序-登录相关接口 diff --git a/config.js b/config.js index 9a6313c..0c3a700 100644 --- a/config.js +++ b/config.js @@ -5,7 +5,7 @@ import utils from './utils/utils.js' // 当前环境 -const type = 'prod' +const type = 'dev' // 环境配置 diff --git a/pages_mine/mine/help.vue b/pages_mine/mine/help.vue index e1101bf..a0d4376 100644 --- a/pages_mine/mine/help.vue +++ b/pages_mine/mine/help.vue @@ -16,7 +16,7 @@ 问题截图 - * + @@ -47,7 +47,7 @@ --> - 确认 + 确认 @@ -78,6 +78,32 @@ }) }) }, + submitFeedback(){ + + if(!this.value){ + uni.showToast({ + title: '请输入你的问题和意见', + icon:'none' + }) + return + } + + this.$api('submitFeedback', { + content : this.value, + image : this.fileList.map((item) => item.url).join(","), + }, res => { + if(res.code == 200){ + uni.showToast({ + title: res.message, + icon:'none' + }) + + setTimeout(() => { + uni.navigateBack(-1) + }, 2000) + } + }) + }, } } @@ -105,12 +131,12 @@ .help-button { display: flex; justify-content: center; - font-size: 24rpx; + font-size: 26rpx; flex-shrink: 0; margin-top: 60rpx; view { - padding: 14rpx 120rpx; + padding: 25rpx 260rpx; border-radius: 38rpx; }