| | |
| | | <h3 class="section-title">优惠券发放规则</h3> |
| | | <div class="form-item"> |
| | | <span class="label">下单数量每满</span> |
| | | <el-input-number v-model="form.orderCouponOrderCount" :min="0" controls-position="right"></el-input-number> |
| | | <el-input-number v-model="form.orderCouponOrderCount" :min="1" controls-position="right"></el-input-number> |
| | | <span class="label">单,至多</span> |
| | | <el-input-number v-model="form.orderCouponGiftCount" :min="0" controls-position="right"></el-input-number> |
| | | <el-input-number v-model="form.orderCouponGiftCount" :min="1" controls-position="right"></el-input-number> |
| | | <span class="label">次,平台赠送优惠券 </span> |
| | | <el-select v-model="form.orderCouponId" multiple style="width: 130px;" placeholder="优惠券"> |
| | | <el-select v-model="form.orderCouponId" style="width: 130px;" placeholder="优惠券"> |
| | | <el-option v-for="item in couponList" :key="item.id" :label="item.name" :value="item.id"></el-option> |
| | | </el-select> |
| | | <span class="label"><span class="red">(以行李已寄存门店为准,即便退单亦不收回,默认每次发放1张)</span></span> |
| | | </div> |
| | | <div class="form-item"> |
| | | <span class="label">会员注册每满</span> |
| | | <el-input-number v-model="form.registerCouponYears" :min="0" controls-position="right"></el-input-number> |
| | | <el-input-number v-model="form.registerCouponYears" :min="1" controls-position="right"></el-input-number> |
| | | <span class="label">年,至多</span> |
| | | <el-input-number v-model="form.registerCouponGiftCount" :min="0" controls-position="right"></el-input-number> |
| | | <el-input-number v-model="form.registerCouponGiftCount" :min="1" controls-position="right"></el-input-number> |
| | | <span class="label">次,平台赠送优惠券 </span> |
| | | <el-select v-model="form.registerCouponId" multiple style="width: 130px;" placeholder="优惠券"> |
| | | <el-select v-model="form.registerCouponId" style="width: 130px;" placeholder="优惠券"> |
| | | <el-option v-for="item in couponList" :key="item.id" :label="item.name" :value="item.id"></el-option> |
| | | </el-select> |
| | | <span class="label"><span class="red">(按注册时间,无论会员是否下单;默认每次发放1张)</span></span> |
| | | </div> |
| | | <div class="form-item"> |
| | | <span class="label">新注册会员送平台赠送优惠券</span> |
| | | <el-select v-model="form.registerGiftCouponIds" multiple style="width: 130px;" placeholder="优惠券"> |
| | | <el-select v-model="form.registerGiftCouponId" style="width: 130px;" placeholder="优惠券"> |
| | | <el-option v-for="item in couponList" :key="item.id" :label="item.name" :value="item.id"></el-option> |
| | | </el-select> |
| | | </div> |
| | |
| | | <h3 class="section-title">开票规则</h3> |
| | | <div class="form-item"> |
| | | <span class="label">超时</span> |
| | | <el-input-number v-model="form.invoiceMonthLimit" :min="0" controls-position="right"></el-input-number> |
| | | <el-input-number v-model="form.invoiceMonthLimit" :min="1" controls-position="right"></el-input-number> |
| | | <span class="label">个月的订单不允许开发票</span> |
| | | </div> |
| | | </div> |
| | |
| | | <el-table :data="driverRewardList" border style="width: 100%"> |
| | | <el-table-column prop="registerRewardAmount" label="注册奖励(元/单)"> |
| | | <template slot-scope="scope"> |
| | | <el-input-number v-model="scope.row.registerRewardAmount" :min="0" controls-position="right"></el-input-number> |
| | | <el-input-number v-model="scope.row.registerRewardAmount" :min="1" controls-position="right"></el-input-number> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="registerRewardOrderCount" label="注册奖励单数"> |
| | | <template slot-scope="scope"> |
| | | <el-input-number v-model="scope.row.registerRewardOrderCount" :min="0" controls-position="right"></el-input-number> |
| | | <el-input-number v-model="scope.row.registerRewardOrderCount" :min="1" controls-position="right"></el-input-number> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="platformRewardAmount" label="平台奖励(元/单)"> |
| | | <template slot-scope="scope"> |
| | | <el-input-number v-model="scope.row.platformRewardAmount" :min="0" controls-position="right"></el-input-number> |
| | | <el-input-number v-model="scope.row.platformRewardAmount" :min="1" controls-position="right"></el-input-number> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column prop="platformRewardOrderCount" label="平台奖励单数"> |
| | | <template slot-scope="scope"> |
| | | <el-input-number v-model="scope.row.platformRewardOrderCount" :min="0" controls-position="right"></el-input-number> |
| | | <el-input-number v-model="scope.row.platformRewardOrderCount" :min="1" controls-position="right"></el-input-number> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | orderCouponGiftCount: '', |
| | | registerCouponYears: '', |
| | | registerCouponGiftCount: '', |
| | | orderCouponId: [], |
| | | registerCouponId: [], |
| | | registerGiftCouponIds: [], |
| | | orderCouponId: null, |
| | | registerCouponId: null, |
| | | registerGiftCouponIds: null, |
| | | invoiceMonthLimit: '' |
| | | }, |
| | | couponList: [], |
| | |
| | | orderCouponGiftCount: res.orderCouponGiftCount || '', |
| | | registerCouponYears: res.registerCouponYears || '', |
| | | registerCouponGiftCount: res.registerCouponGiftCount || '', |
| | | orderCouponId: res.orderCouponId ? res.orderCouponId.split(',').map(item => Number(item)) : [], |
| | | registerCouponId: res.registerCouponId ? res.registerCouponId.split(',').map(item => Number(item)) : [], |
| | | registerGiftCouponIds: res.registerGiftCouponIds ? res.registerGiftCouponIds.split(',').map(item => Number(item)) : [], |
| | | orderCouponId: res.orderCouponId ? Number(res.orderCouponId) : null, |
| | | registerCouponId: res.registerCouponId ? Number(res.registerCouponId) : null, |
| | | registerGiftCouponIds: res.registerGiftCouponIds ? Number(res.registerGiftCouponIds) : '', |
| | | registerRewardAmount: res.registerRewardAmount || 0, |
| | | registerRewardOrderCount: res.registerRewardOrderCount || 0, |
| | | platformRewardAmount: res.platformRewardAmount || 0, |
| | |
| | | submitForm.platformRewardAmount = rewardData.platformRewardAmount |
| | | submitForm.platformRewardOrderCount = rewardData.platformRewardOrderCount |
| | | } |
| | | if (submitForm.orderCouponId && submitForm.orderCouponId.length > 0) { |
| | | submitForm.orderCouponId = submitForm.orderCouponId.join(',') |
| | | if (submitForm.orderCouponId) { |
| | | submitForm.orderCouponId = String(submitForm.orderCouponId) |
| | | } |
| | | if (submitForm.registerCouponId && submitForm.registerCouponId.length > 0) { |
| | | submitForm.registerCouponId = submitForm.registerCouponId.join(',') |
| | | if (submitForm.registerCouponId) { |
| | | submitForm.registerCouponId = String(submitForm.registerCouponId) |
| | | } |
| | | submitForm.registerGiftCouponIds = submitForm.registerGiftCouponIds.join(',') |
| | | // if (submitForm.registerGiftCouponIds) { |
| | | // submitForm.registerGiftCouponIds = submitForm.registerGiftCouponIds |
| | | // } |
| | | saveParams(submitForm).then(res => { |
| | | this.$tip.apiSuccess(res || '保存成功') |
| | | }).catch(e => { |