|
|
|
@ -20,7 +20,8 @@ |
|
|
|
|
</view> |
|
|
|
|
<view class="width100 line1 mart5"></view> |
|
|
|
|
<view class="width90"> |
|
|
|
|
<button class="flright backcorf06 fcorfff font15 agent_btn mart10" @click="generateCode(agent.id)" |
|
|
|
|
<button class="flright backcorf06 fcorfff font15 agent_btn mart10" |
|
|
|
|
@click="generateCode(agent.id,agent.highCoupon.couponSource)" |
|
|
|
|
v-if="typeId == 1 && typeid == 1">生成油码</button> |
|
|
|
|
<button class="flright backcorf06 fcorfff font15 agent_btn mart10" @click="jumpCouponDes(agent.id)" |
|
|
|
|
v-if="typeId == 2 && typeid == 1">查看详情</button> |
|
|
|
@ -28,7 +29,8 @@ |
|
|
|
|
v-if="typeId == 2 && agent.remark !=null && typeid == 1"> |
|
|
|
|
备注:{{agent.remark}}</view> |
|
|
|
|
|
|
|
|
|
<button class="flright backcorf06 fcorfff font15 agent_btn mart10" @click="generateCode(agent.id)" |
|
|
|
|
<button class="flright backcorf06 fcorfff font15 agent_btn mart10" |
|
|
|
|
@click="generateCode(agent.id,agent.highCoupon.couponSource)" |
|
|
|
|
v-if="typeId == 1 && typeid == 2">生成兑换码</button> |
|
|
|
|
<button class="flright backcorf06 fcorfff font15 agent_btn mart10" @click="jumpCouponDes(agent.id)" |
|
|
|
|
v-if="typeId == 2 && (typeid == 2 || typeid == 3) ">查看详情</button> |
|
|
|
@ -40,12 +42,14 @@ |
|
|
|
|
|
|
|
|
|
<!-- /弹窗 --> |
|
|
|
|
<view :hidden="userFeedbackHidden" class="popup_content"> |
|
|
|
|
<view class="popup_title">填写备注</view> |
|
|
|
|
<view class="popup_title">填写信息</view> |
|
|
|
|
<input class="width90 pop_input font14 mart20 marb10" maxlength="11" v-model="feedPhone" placeholder="输入手机号" |
|
|
|
|
type="number" v-if="couponSource == 4" /> |
|
|
|
|
<view class="popup_textarea_item"> |
|
|
|
|
<textarea class="popup_textarea" placeholder='请填写您的备注信息...' v-model="feedbackContent"> |
|
|
|
|
</textarea> |
|
|
|
|
<view @click="submitFeedback()"> |
|
|
|
|
<button class="popup_button">提交备注</button> |
|
|
|
|
<button class="popup_button mart20 fontlet">提交</button> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
|
</view> |
|
|
|
@ -56,7 +60,8 @@ |
|
|
|
|
<script> |
|
|
|
|
import { |
|
|
|
|
getCodeListByAgentCoupon, |
|
|
|
|
generateCode |
|
|
|
|
generateCode, |
|
|
|
|
pushGzSinopec |
|
|
|
|
} from "../../../Utils/Api.js"; |
|
|
|
|
let app = getApp(); |
|
|
|
|
export default { |
|
|
|
@ -74,6 +79,8 @@ |
|
|
|
|
image_url: app.globalData.imgUrl, |
|
|
|
|
userFeedbackHidden: true, // 默认隐藏 |
|
|
|
|
feedbackContent: '', // 用户备注信息 |
|
|
|
|
feedPhone: '', //推送手机 |
|
|
|
|
couponSource: '', //类型 |
|
|
|
|
couId: '', |
|
|
|
|
typeid: '' |
|
|
|
|
} |
|
|
|
@ -190,25 +197,59 @@ |
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
//生成二维码 |
|
|
|
|
generateCode(item) { |
|
|
|
|
generateCode(item, item1) { |
|
|
|
|
this.userFeedbackHidden = false; |
|
|
|
|
this.couId = item; |
|
|
|
|
this.couponSource = item1; |
|
|
|
|
}, |
|
|
|
|
hideDiv() { // 隐藏输入弹出框 |
|
|
|
|
this.userFeedbackHidden = true; |
|
|
|
|
}, |
|
|
|
|
// 提交备注 |
|
|
|
|
submitFeedback() { |
|
|
|
|
if (this.feedPhone == '' && this.couponSource == 4) { |
|
|
|
|
uni.showToast({ |
|
|
|
|
title: '请填写推送手机号', |
|
|
|
|
icon: 'none', |
|
|
|
|
duration: 2000 |
|
|
|
|
}) |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
if (this.feedbackContent == '') { |
|
|
|
|
uni.showToast({ |
|
|
|
|
title: '请填写备注信息', |
|
|
|
|
icon: 'none', |
|
|
|
|
duration: 2000 |
|
|
|
|
}) |
|
|
|
|
} else { |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
uni.showLoading({ |
|
|
|
|
title: '生成中...' |
|
|
|
|
}) |
|
|
|
|
if (this.couponSource == 4) { |
|
|
|
|
let datas = { |
|
|
|
|
couponAgentCodeId: this.couId, |
|
|
|
|
remark: this.feedbackContent, |
|
|
|
|
phone: this.feedPhone |
|
|
|
|
} |
|
|
|
|
pushGzSinopec(datas).then(res => { |
|
|
|
|
uni.hideLoading() |
|
|
|
|
if (res.return_code == '000000') { |
|
|
|
|
this.userFeedbackHidden = true; |
|
|
|
|
uni.navigateTo({ |
|
|
|
|
url: '../../goods/coupons-info-details/coupons-info-details?id=' + this |
|
|
|
|
.couId |
|
|
|
|
}) |
|
|
|
|
} else { |
|
|
|
|
uni.showToast({ |
|
|
|
|
title: res.return_msg, |
|
|
|
|
icon: 'none', |
|
|
|
|
duration: 2000 |
|
|
|
|
}) |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
} else { |
|
|
|
|
let datas = { |
|
|
|
|
couponAgentCodeId: this.couId, |
|
|
|
|
remark: this.feedbackContent |
|
|
|
@ -230,6 +271,8 @@ |
|
|
|
|
} |
|
|
|
|
}); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
//查看详情 |
|
|
|
@ -317,10 +360,10 @@ |
|
|
|
|
|
|
|
|
|
.popup_content { |
|
|
|
|
position: fixed; |
|
|
|
|
top: 50%; |
|
|
|
|
top: 40%; |
|
|
|
|
left: 50%; |
|
|
|
|
width: 520upx; |
|
|
|
|
height: 550upx; |
|
|
|
|
height: 600upx; |
|
|
|
|
margin-left: -270upx; |
|
|
|
|
margin-top: -270upx; |
|
|
|
|
border: 10px solid white; |
|
|
|
@ -337,9 +380,16 @@ |
|
|
|
|
font-size: 40rpx; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
.pop_input { |
|
|
|
|
// border-bottom: 1px solid #F1F1F1; |
|
|
|
|
height: 50rpx; |
|
|
|
|
line-height: 50rpx; |
|
|
|
|
padding-left: 20rpx; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
.popup_textarea_item { |
|
|
|
|
padding-top: 20rpx; |
|
|
|
|
height: 240rpx; |
|
|
|
|
height: 200rpx; |
|
|
|
|
width: 90%; |
|
|
|
|
background-color: #F1F1F1; |
|
|
|
|
margin-top: 30rpx; |
|
|
|
@ -348,6 +398,7 @@ |
|
|
|
|
|
|
|
|
|
.popup_textarea { |
|
|
|
|
width: 410upx; |
|
|
|
|
height: 200rpx; |
|
|
|
|
font-size: 26upx; |
|
|
|
|
margin-left: 20upx; |
|
|
|
|
} |
|
|
|
|