投诉页面优化,商家入驻bug修改

version/0412
mujinxia 11 months ago
parent d025845720
commit 7aca99aea7
  1. 66
      pages/news1/MerchantSettlement.vue
  2. 73
      pages/news1/feedback.vue

@ -342,61 +342,101 @@ export default {
}) })
.finally() .finally()
}, },
onShowToast(t) {
uni.showToast({
title: t,
icon: 'none',
duration: 2000
})
},
sureSubmit() { sureSubmit() {
let tip_title = null let tip_title = null
if (!this.form.store_name) { if (!this.form.store_name) {
tip_title = '请输入主体公司名称!' this.onShowToast('请输入主体公司名称!')
return
} }
if (!this.form.store_cat) { if (!this.form.store_cat) {
tip_title = '请选择主营类目体类目!' tip_title = '请选择主营类目体类目!'
this.onShowToast(tip_title)
return
} }
if (!this.form.store_address) { if (!this.form.store_address) {
tip_title = '请选择公司地址!' tip_title = '请选择公司地址!'
this.onShowToast(tip_title)
return
} }
if (!this.form.store_brand) { if (!this.form.store_brand) {
tip_title = '请输入合作品牌!' tip_title = '请输入合作品牌!'
this.onShowToast(tip_title)
return
} }
if (!this.brand_name) { if (!this.brand_name) {
tip_title = '请选择代理入驻!' tip_title = '请选择代理入驻!'
this.onShowToast(tip_title)
return
} }
if (!this.authorize_name) { if (!this.authorize_name) {
tip_title = '请选择一二级授权!' tip_title = '请选择一二级授权!'
} }
if (!this.rate_name) { if (!this.rate_name) {
tip_title = '请选择可否含税!' tip_title = '请选择可否含税!'
this.onShowToast(tip_title)
return
} }
if (!this.form.user_name) { if (!this.form.user_name) {
tip_title = '请输入联系人姓名!' tip_title = '请输入联系人姓名!'
this.onShowToast(tip_title)
return
} }
if (!this.form.user_position) { if (!this.form.user_position) {
tip_title = '请选择联系人职位!' tip_title = '请选择联系人职位!'
this.onShowToast(tip_title)
return
} }
if (!this.form.user_mobile) { if (!this.form.user_mobile) {
tip_title = '请输入联系人手机号!' tip_title = '请输入联系人手机号!'
this.onShowToast(tip_title)
return
} }
if (this.form.user_mobile && (!/^\+?\d[\d -]{8,12}\d/.test(this.form.user_mobile))) { if (this.form.user_mobile && (!/^\+?\d[\d -]{8,12}\d/.test(this.form.user_mobile))) {
tip_title = '手机号格式不正确!' tip_title = '手机号格式不正确!'
this.onShowToast(tip_title)
return
} }
if (!this.form.user_wx) { if (!this.form.user_wx) {
tip_title = '请输入联系人微信!' tip_title = '请输入联系人微信!'
this.onShowToast(tip_title)
return
} }
if (!this.form.user_email) { if (!this.form.user_email) {
tip_title = '请输入联系人邮箱!' tip_title = '请输入联系人邮箱!'
this.onShowToast(tip_title)
return
} }
if (!this.form.store_model) { if (!this.form.store_model) {
tip_title = '请选择仓库模式!' tip_title = '请选择仓库模式!'
this.onShowToast(tip_title)
return
} }
if (!this.send_name) { if (!this.send_name) {
tip_title = '请选择周末是否发货!' tip_title = '请选择周末是否发货!'
this.onShowToast(tip_title)
return
} }
if (!this.factory_name) { if (!this.factory_name) {
tip_title = '请选择是否自有工厂!' tip_title = '请选择是否自有工厂!'
this.onShowToast(tip_title)
return
} }
if (!this.offline_name) { if (!this.offline_name) {
tip_title = '请选择是否有线下渠道' tip_title = '请选择是否有线下渠道'
this.onShowToast(tip_title)
return
} }
if (!this.shop_name) { if (!this.shop_name) {
tip_title = '请选择是否有电商店铺!' tip_title = '请选择是否有电商店铺!'
this.onShowToast(tip_title)
return
} }
let plat_form = [] let plat_form = []
this.btnList.map(item => { this.btnList.map(item => {
@ -407,19 +447,21 @@ export default {
this.form.store_type = plat_form this.form.store_type = plat_form
if (plat_form.length == 0 && this.form.has_online_shop == 1) { if (plat_form.length == 0 && this.form.has_online_shop == 1) {
tip_title = '请选择电商平台!' tip_title = '请选择电商平台!'
} this.onShowToast(tip_title)
if (tip_title != null) {
uni.showToast({
title: tip_title,
icon: 'none',
duration: 2000
})
return return
} }
help.joinStore(this.form) help.joinStore(this.form)
.then(res => { .then(res => {
if (res.status) { if (res.status) {
this.popShow = true this.popShow = true
this.form = this.$options.data().form
this.send_name = ''
this.factory_name = ''
this.offline_name = ''
this.shop_name = ''
this.btnList.map(item => {
item.active = false
})
} else { } else {
uni.showToast({ uni.showToast({
title: '入驻失败', title: '入驻失败',
@ -429,14 +471,6 @@ export default {
} }
}) })
.finally(() => { .finally(() => {
this.form = this.$options.data().form
this.send_name = ''
this.factory_name = ''
this.offline_name = ''
this.shop_name = ''
this.btnList.map(item => {
item.active = false
})
}) })
}, },
} }

@ -66,7 +66,7 @@
提交 提交
</view> </view>
</view> </view>
<view class="section2" v-if="OrderType == 1"> <view class="section2" v-if="OrderType == 1 && feedBackList.length > 0">
<view class="feedShow" v-for="(item, index) in feedBackList" :key="index"> <view class="feedShow" v-for="(item, index) in feedBackList" :key="index">
<view class="feedbackItem"> <view class="feedbackItem">
<view class="feedbackContent"> <view class="feedbackContent">
@ -110,10 +110,9 @@
</u-collapse> </u-collapse>
</view> </view>
</view> </view>
</view> </view>
</view> </view>
<view class="section2" v-if="OrderType == 2"> <view class="section2" v-if="OrderType == 2 && feedBackList.length > 0">
<view class="feedShow" style="padding: 0;" v-for="(item, index) in feedBackList" :key="index"> <view class="feedShow" style="padding: 0;" v-for="(item, index) in feedBackList" :key="index">
<view class="feedbackResult"> <view class="feedbackResult">
<u-collapse> <u-collapse>
@ -127,35 +126,15 @@
</u-form-item> </u-form-item>
</u-form> </u-form>
</u-collapse-item> </u-collapse-item>
</u-collapse> </u-collapse>
</view> </view>
<!-- <view class="feedbackItem">
<view class="feedbackResult">
<u-collapse>
<u-collapse-item :open="false" title="处理结果">
<u-form :model="item" ref="item">
<u-form-item label="处理时间" label-width="150" prop="time">
{{ item.replay_at }}
</u-form-item>
<u-form-item label="反馈内容" label-width="150" prop="feedback">
{{ item.content }}
</u-form-item>
</u-form>
</u-collapse-item>
</u-collapse>
</view> -->
<!-- </view> -->
</view> </view>
<!-- <view class="empty"> </view>
<image src="/static/news1/feedbackempty.png" mode="widthFix"></image> <view class="empty" v-if="OrderType == 2">
<image class="emptyImg" :src="$picUrl + '/static/news1/feedbackempty.png'" mode="widthFix"></image>
<view class="emptytext"> <view class="emptytext">
还没有反馈内容 还没有反馈内容
</view> </view>
</view> -->
</view> </view>
</view> </view>
</template> </template>
@ -233,6 +212,22 @@ export default {
}, },
submit() { submit() {
const that = this const that = this
if (that.form.comment == '') {
uni.showToast({
title: '请填写投诉内容!',
icon: 'none',
duration: 2000
})
return
}
if (this.form.phone && (!/^\+?\d[\d -]{8,12}\d/.test(this.form.phone))) {
uni.showToast({
title: '手机号格式不正确!',
icon: 'none',
duration: 2000
})
return
}
let params = { let params = {
shop_id: that.shop_id, shop_id: that.shop_id,
type: that.form.type, type: that.form.type,
@ -243,6 +238,8 @@ export default {
feedback.add(params) feedback.add(params)
.then(res => { .then(res => {
that.$toast(res.message) that.$toast(res.message)
that.shop_id = ''
that.form = that.$options.data().form
}) })
.catch(reject) .catch(reject)
}) })
@ -253,6 +250,7 @@ export default {
*/ */
onOrderTab(type) { onOrderTab(type) {
this.OrderType = type; this.OrderType = type;
this.feedBackList = []
if (type != 0) { if (type != 0) {
this.getFeedBack(type) this.getFeedBack(type)
} }
@ -265,7 +263,7 @@ export default {
is_my: 0, is_my: 0,
page: that.page page: that.page
} }
// params.is_my = type == 1 ? 0 : 1 params.is_my = type == 1 ? 0 : 1
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
feedback.list(params) feedback.list(params)
.then(res => { .then(res => {
@ -505,7 +503,7 @@ page {
.feedbackContent { .feedbackContent {
padding: 0 30rpx 30rpx; padding: 0 30rpx 30rpx;
border-bottom: 1px solid #A0A0A0; border-bottom: 1px solid #eee;
.fbTitle { .fbTitle {
position: relative; position: relative;
@ -574,14 +572,18 @@ page {
} }
.empty { }
text-align: center;
position: relative;
top: 150rpx;
image { .empty {
width: 100%;
display: flex;
align-items: center;
justify-content: center;
flex-direction: column;
height: calc(100vh - 102rpx);
.emptyImg {
width: 210rpx; width: 210rpx;
height: auto;
} }
.emptytext { .emptytext {
@ -589,9 +591,8 @@ page {
font-family: PingFang SC, PingFang SC; font-family: PingFang SC, PingFang SC;
font-weight: 500; font-weight: 500;
color: #717171; color: #717171;
margin-top: 36rpx;
} }
}
} }
</style> </style>

Loading…
Cancel
Save