1
This commit is contained in:
parent
872cfdc423
commit
dea17c543e
@ -2,6 +2,7 @@ package com.fuint.business.cashierGoods.controller;
|
||||
|
||||
|
||||
import com.fuint.business.cashierGoods.entity.MtGoods;
|
||||
import com.fuint.business.cashierGoods.entity.MtGoodsVo;
|
||||
import com.fuint.business.cashierGoods.service.CashRegisterGoodsService;
|
||||
import com.fuint.common.service.GoodsService;
|
||||
import com.fuint.common.util.TokenUtil;
|
||||
@ -42,8 +43,8 @@ public class CashRegisterGoodsController extends BaseController {
|
||||
public ResponseObject list(HttpServletRequest request) throws BusinessCheckException {
|
||||
|
||||
HashMap<String, Object> map = new HashMap<>();
|
||||
map.put("store_id", TokenUtil.getNowAccountInfo().getStoreId());
|
||||
List<MtGoods> mtGoods = cashRegisterGoodsService.selectListByMap(map);
|
||||
map.put("god.store_id", TokenUtil.getNowAccountInfo().getStoreId());
|
||||
List<MtGoodsVo> mtGoods = cashRegisterGoodsService.selectListByMap(map);
|
||||
|
||||
return getSuccessResult(mtGoods);
|
||||
}
|
||||
|
@ -0,0 +1,9 @@
|
||||
package com.fuint.business.cashierGoods.entity;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
@Data
|
||||
public class MtGoodsVo extends MtGoods {
|
||||
|
||||
private String supplierName;
|
||||
}
|
@ -2,13 +2,19 @@ package com.fuint.business.cashierGoods.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.fuint.business.cashierGoods.entity.MtGoods;
|
||||
import com.fuint.business.cashierGoods.entity.MtGoodsVo;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
// 如何集成mybatis plus 通用mapper
|
||||
@Mapper
|
||||
public interface CashRegisterGoodsMapper extends BaseMapper<MtGoods> {
|
||||
|
||||
|
||||
List<MtGoodsVo> selectListByMap(@Param("map") Map<String, Object> columnMap);
|
||||
|
||||
|
||||
}
|
||||
|
@ -312,5 +312,19 @@
|
||||
where
|
||||
store_id = #{storeId}
|
||||
</select>
|
||||
<select id="selectListByMap" resultType="com.fuint.business.cashierGoods.entity.MtGoodsVo" parameterType="map">
|
||||
SELECT
|
||||
god.*,sup.name AS supplierName
|
||||
FROM
|
||||
mt_goods god
|
||||
left JOIN supplier sup on god.supplier_id = sup.id
|
||||
<where>
|
||||
<foreach collection="map" item="value" index="key" open="" close="" separator=" AND ">
|
||||
<if test="value != null and value != ''">
|
||||
${key} = #{value}
|
||||
</if>
|
||||
</foreach>
|
||||
</where>
|
||||
</select>
|
||||
</mapper>
|
||||
|
||||
|
@ -1,6 +1,7 @@
|
||||
package com.fuint.business.cashierGoods.service;
|
||||
|
||||
import com.fuint.business.cashierGoods.entity.MtGoods;
|
||||
import com.fuint.business.cashierGoods.entity.MtGoodsVo;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
@ -9,7 +10,7 @@ public interface CashRegisterGoodsService {
|
||||
|
||||
|
||||
// 通用mapper条件查询
|
||||
List<MtGoods> selectListByMap(Map<String, Object> columnMap);
|
||||
List<MtGoodsVo> selectListByMap(Map<String, Object> columnMap);
|
||||
|
||||
|
||||
|
||||
|
@ -2,6 +2,7 @@ package com.fuint.business.cashierGoods.service.impl;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.fuint.business.cashierGoods.entity.MtGoods;
|
||||
import com.fuint.business.cashierGoods.entity.MtGoodsVo;
|
||||
import com.fuint.business.cashierGoods.mapper.CashRegisterGoodsMapper;
|
||||
import com.fuint.business.cashierGoods.service.CashRegisterGoodsService;
|
||||
import org.springframework.stereotype.Service;
|
||||
@ -12,11 +13,11 @@ import java.util.Map;
|
||||
@Service
|
||||
public class CashRegisterGoodsServiceImpl extends ServiceImpl<CashRegisterGoodsMapper, MtGoods> implements CashRegisterGoodsService {
|
||||
|
||||
|
||||
//supplier
|
||||
@Override
|
||||
public List<MtGoods> selectListByMap(Map<String, Object> columnMap) {
|
||||
public List<MtGoodsVo> selectListByMap(Map<String, Object> columnMap) {
|
||||
|
||||
List<MtGoods> mtGoods = super.baseMapper.selectByMap(columnMap);
|
||||
List<MtGoodsVo> mtGoods = super.baseMapper.selectListByMap(columnMap);
|
||||
|
||||
return mtGoods;
|
||||
}
|
||||
|
@ -131,7 +131,7 @@
|
||||
<div class="price_">¥{{ realAmount }}</div>
|
||||
<div class="price_prefer">优惠合计:¥{{ disTotal }}</div>
|
||||
</div>
|
||||
<div class="anniu" @click="settlement()">立即结算</div>
|
||||
<div class="anniu" @click="settlement()" :class="{ disabled: !isClickable }">立即结算</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@ -314,29 +314,29 @@
|
||||
<el-button type="primary" @click="ScanCodePayment = false">关闭</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
<el-dialog
|
||||
title="现金支付"
|
||||
:visible.sync="cashPayment"
|
||||
width="439px"
|
||||
center
|
||||
>
|
||||
<div class="tc-box">
|
||||
<div class="title_">应收款: <span style="color: #F44522">¥98.00</span></div>
|
||||
<el-form :model="ruleForm" :rules="rules" ref="ruleForm" label-width="100px" class="demo-ruleForm">
|
||||
<el-form-item label="收款金额" prop="name">
|
||||
<el-input v-model="ruleForm.name">
|
||||
<template slot="append">元</template>
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
<div class="t-size">
|
||||
应找零:<span style="color: #F44522">¥20.00</span>
|
||||
</div>
|
||||
</el-form>
|
||||
</div>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="cashPayment = false">确定收款</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
<!-- <el-dialog-->
|
||||
<!-- title="现金支付"-->
|
||||
<!-- :visible.sync="cashPayment"-->
|
||||
<!-- width="439px"-->
|
||||
<!-- center-->
|
||||
<!-- >-->
|
||||
<!-- <div class="tc-box">-->
|
||||
<!-- <div class="title_">应收款: <span style="color: #F44522">¥{{realAmount}}</span></div>-->
|
||||
<!-- <el-form :model="ruleForm2" :rules="rules2" ref="ruleForm2" label-width="100px" class="demo-ruleForm">-->
|
||||
<!-- <el-form-item label="收款金额" prop="number">-->
|
||||
<!-- <el-input v-model="ruleForm2.number">-->
|
||||
<!-- <template slot="append">元</template>-->
|
||||
<!-- </el-input>-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <div class="t-size">-->
|
||||
<!-- 应找零:<span style="color: #F44522">¥{{getChangeShould}}</span>-->
|
||||
<!-- </div>-->
|
||||
<!-- </el-form>-->
|
||||
<!-- </div>-->
|
||||
<!-- <span slot="footer" class="dialog-footer">-->
|
||||
<!-- <el-button type="primary" @click="cashPaymentClick()">确定收款</el-button>-->
|
||||
<!-- </span>-->
|
||||
<!-- </el-dialog>-->
|
||||
<el-dialog
|
||||
title="挂单"
|
||||
:visible.sync="hangingAnOrder"
|
||||
@ -445,7 +445,8 @@
|
||||
</el-dialog>
|
||||
|
||||
<!-- 确认充值-->
|
||||
<el-dialog :close-on-click-modal="false" title="确认充值" :visible.sync="openConfirm" width="500px" append-to-body>
|
||||
<el-dialog :close-on-click-modal="false" title="确认支付订单" :visible.sync="openConfirm" width="500px" append-to-body
|
||||
@close="onDialogClose">
|
||||
<div v-if="isPay"
|
||||
v-loading="loading">
|
||||
|
||||
@ -458,7 +459,7 @@
|
||||
<div v-if="payForm.paymentType !== 'CASH' ">
|
||||
<div>
|
||||
<el-input v-model="payForm.authCode"
|
||||
v-focus ref="getFocus"
|
||||
ref="getFocus"
|
||||
autofocus
|
||||
@keydown.enter.native="collection1"
|
||||
placeholder="扫描或输入付款码、支持微信、支付宝、云闪付">
|
||||
@ -484,18 +485,18 @@
|
||||
</div>
|
||||
<div v-else>
|
||||
<div>
|
||||
<el-input v-model="payForm.authCode"
|
||||
v-focus ref="getFocus"
|
||||
<el-input v-model.number="payForm.authCode"
|
||||
oninput="value=value.replace(/[^0-9]/g, '').slice(0, 10)"
|
||||
type="number"
|
||||
ref="getFocus"
|
||||
autofocus maxlength="10"
|
||||
@input="changeSeekZero1"
|
||||
@keydown.enter.native="collection1"
|
||||
oninput="value=value.replace(/^\D*(\d*(?:\.\d{0,2})?).*$/g, '$1')"
|
||||
placeholder="请输入收款金额">
|
||||
</el-input>
|
||||
</div>
|
||||
<div style="text-align: right;margin: 10px 0">
|
||||
<span>应找零</span>
|
||||
<span style="color: red;font-size: 18px"> ¥{{ payForm.seekZero }}</span>
|
||||
<span style="color: red;font-size: 18px"> ¥{{ getChangeShould }}</span>
|
||||
</div>
|
||||
</div>
|
||||
<el-divider></el-divider>
|
||||
@ -558,13 +559,15 @@ import {
|
||||
getCheckTheStatusOfYourPaymentApi,
|
||||
rechargeCard
|
||||
} from "@/api/cashier/cardSet";
|
||||
import {getReturnCode} from "@/api/print";
|
||||
import { getReturnCode, printOilOrderReport } from '@/api/print'
|
||||
import {addLJGoods, scanAppletQrCode} from "@/api/cashier/oilorder";
|
||||
import { cashierOrderByOrderNo } from '@/api/cashier/cashierorder'
|
||||
|
||||
export default {
|
||||
dicts: ['CardCoupon_type'],
|
||||
data() {
|
||||
return {
|
||||
isClickable: false, // 默认不可点击
|
||||
payForm: {
|
||||
realyPayBills: 0.00,
|
||||
paymentType: 'ALIPAY',
|
||||
@ -690,6 +693,19 @@ export default {
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
//监听会员 是否获取
|
||||
chooseVipUser: {
|
||||
handler(newVal) {
|
||||
console.log("会员发生变化", newVal);
|
||||
// 判断对象 是否含有 name 属性
|
||||
if (this.chooseVipUser.hasOwnProperty("name")){
|
||||
this.isClickable = true
|
||||
}else {
|
||||
this.isClickable = false
|
||||
}
|
||||
|
||||
},
|
||||
},
|
||||
//监听选择的活动
|
||||
chooseActId: {
|
||||
handler(newVal) {
|
||||
@ -777,6 +793,9 @@ export default {
|
||||
},
|
||||
|
||||
computed: {
|
||||
getChangeShould(){
|
||||
return this.payForm.authCode-this.realAmount
|
||||
},
|
||||
getGoodsItem() {
|
||||
if (this.oilGunClearing.amount && this.oilGunClearing.amount !== undefined) {
|
||||
// 保留两位小数
|
||||
@ -809,6 +828,12 @@ export default {
|
||||
|
||||
},
|
||||
methods: {
|
||||
|
||||
//结算弹窗 监听关闭 清除表单
|
||||
onDialogClose(){
|
||||
this.payForm.authCode=null
|
||||
},
|
||||
|
||||
sendCouponClick() {
|
||||
//this.sendCoupon this.chooseVipUser.id
|
||||
this.sendCoupon.mtUserId = this.chooseVipUser.id
|
||||
@ -886,10 +911,10 @@ export default {
|
||||
},
|
||||
// 关闭支付窗口
|
||||
handClose1() {
|
||||
this.isPay = true,
|
||||
this.isPay = true,
|
||||
this.isPaySuccess = false,
|
||||
this.isQuery = true
|
||||
this.openConfirm = false
|
||||
this.openConfirm = false
|
||||
|
||||
this.payForm.authCode = null
|
||||
|
||||
@ -919,8 +944,8 @@ export default {
|
||||
}
|
||||
},
|
||||
async collection1() {
|
||||
// 这里是收银台结算 下面是会员充值
|
||||
if (this.flag == 3) {
|
||||
console.log(919)
|
||||
this.collection()
|
||||
return
|
||||
}
|
||||
@ -1037,6 +1062,212 @@ export default {
|
||||
this.isPay = true
|
||||
//this.getCode(this.realyPayBills, this.flag)
|
||||
},
|
||||
// 打印商品支付后的订单
|
||||
oilOrderReport () {
|
||||
//现在油品只有一个了
|
||||
let oilOrderR = [
|
||||
{
|
||||
oilName : this.oilGunClearing.name,
|
||||
amount : this.oilGunClearing.amount,
|
||||
}
|
||||
]
|
||||
|
||||
let goodsOrderR = []
|
||||
this.goodsOrder.forEach(order=>{
|
||||
let o = {
|
||||
oilName : order.name,
|
||||
unit : order.num+order.unit,
|
||||
// amount : order.memberPrice.toString()
|
||||
amount : order.retailPrice.toString()
|
||||
|
||||
}
|
||||
goodsOrderR.push(o)
|
||||
})
|
||||
// 支付方式
|
||||
const payTypeMap = {
|
||||
'CASH': '现金',
|
||||
'WECHAT': '微信',
|
||||
'ALIPAY': '支付宝',
|
||||
'UNIONPAY': '银联二维码',
|
||||
'credit': '挂账',
|
||||
'oilCard': '囤油卡',
|
||||
'balance': '储值卡'
|
||||
};
|
||||
let payTypeText = payTypeMap[this.payType] || '小程序码';
|
||||
|
||||
let f ={
|
||||
oilOrder:oilOrderR,
|
||||
goodsOrder:goodsOrderR,
|
||||
payType:payTypeText,
|
||||
unitName:this.form1.unitName, // 挂账单位
|
||||
|
||||
// consumeAmount:this.consumeAmount,
|
||||
creditAmount: (this.oilAmount+(+this.goodsAmount)).toFixed(2),//挂账金额
|
||||
// 优惠合计
|
||||
discount:(this.oilDiscount + this.goodsDiscount + this.fullReduction + this.couponAmount).toFixed(2), // 油惠合计
|
||||
// 储值卡付款
|
||||
consumeAmount:this.consumeAmount,
|
||||
// 屯油卡付款
|
||||
consumeRefuelMoney:this.consumeRefuelMoney.toFixed(2),
|
||||
// 实付款
|
||||
actualPay : ((+this.oilActualPay)+(+this.goodsActualPay)).toFixed(2),
|
||||
// 找零
|
||||
seekZero:this.seekZero.toFixed(2),
|
||||
}
|
||||
printOilOrderReport(f).then(res=>{
|
||||
|
||||
})
|
||||
},
|
||||
//表单重置
|
||||
resetting1(){
|
||||
let _this = this;
|
||||
this.authCode = "";
|
||||
if (_this.isPaySuccess == true){
|
||||
// _this.isPay = false;
|
||||
_this.oilAmount = 0;
|
||||
_this.oilActualPay = 0;
|
||||
_this.oilDiscount = 0;
|
||||
_this.goodsAmount = 0;
|
||||
_this.goodsActualPay = 0;
|
||||
_this.goodsDiscount = 0;
|
||||
_this.consumeAmount = 0;
|
||||
_this.consumeRefuelMoney = 0;
|
||||
_this.oilTotal = 0;
|
||||
_this.goodsTotal = 0;
|
||||
_this.oilCardAmount = 0;
|
||||
_this.isMember = false;
|
||||
_this.isSure = false;
|
||||
_this.oilOrder = []
|
||||
_this.goodsOrder = []
|
||||
_this.amount = 0
|
||||
_this.seekZero = 0;
|
||||
_this.fullReduction = 0;
|
||||
_this.fullReduceDiscount = []
|
||||
_this.checkAll1 = false
|
||||
_this.gradeDiscount = []
|
||||
_this.checkAll2 = false
|
||||
_this.checkAll3 = false
|
||||
_this.checkAll4 = false
|
||||
_this.checkAll5 = false
|
||||
};
|
||||
this.userNo = ""
|
||||
this.map = {
|
||||
allAmount:0,
|
||||
// 用户支付条码信息
|
||||
authCode:'',
|
||||
// 油品订单
|
||||
oilOrder:"",
|
||||
// 商品订单
|
||||
goodsOrder:"",
|
||||
// 支付方式
|
||||
payType:"WECHAT",
|
||||
// 油品订单金额
|
||||
oilAmount:0,
|
||||
// 商品订单金额
|
||||
goodsAmount:0,
|
||||
// 油品实付金额
|
||||
oilActualPay:0,
|
||||
// 商品实付金额
|
||||
goodsActualPay:0,
|
||||
// 付款用户
|
||||
payUser:"",
|
||||
// 油品优惠金额
|
||||
oilDiscount:0,
|
||||
// 商品优惠金额
|
||||
goodsDiscount:0,
|
||||
// 优惠券id
|
||||
couponId:"",
|
||||
// 提成金额
|
||||
commissionAmount:0,
|
||||
// 使用积分数量
|
||||
usePoint:0,
|
||||
// 积分金额
|
||||
pointAmount:0,
|
||||
// 终端
|
||||
terminal:"PC",
|
||||
// 商品数量
|
||||
goodsNum:0,
|
||||
// 会员消费金额(储值卡需要减少的金额)
|
||||
consumeAmount:0,
|
||||
typeIdex:'',
|
||||
|
||||
};
|
||||
this.payType = "WECHAT"
|
||||
},
|
||||
// 查询订单支付状态
|
||||
queryPayStatus(){
|
||||
let _this = this;
|
||||
let timer = setInterval(function (){
|
||||
// "234520231228115544f073f4"
|
||||
cashierOrderByOrderNo({orderNo:_this.orderNo}).then( response => {
|
||||
if (response.data){
|
||||
if (response.data.status == "paid"){
|
||||
_this.isPay = true;
|
||||
_this.isPaySuccess = true;
|
||||
_this.isQuery = false;
|
||||
_this.amount = 0
|
||||
|
||||
_this.loading = false;
|
||||
// _this.printLocally()
|
||||
_this.oilOrderReport()
|
||||
|
||||
_this.resetting1();
|
||||
|
||||
if (response.data.oilOrderAmount>0){
|
||||
// for (let i =0;i<_this.oilPreferentialData.length;i++){
|
||||
// _this.oilPreferentialData[i].oilPreferential.storeId = response.data.storeId
|
||||
// _this.oilPreferentialData[i].oilPreferential.orderAmount = response.data.oilOrderAmount
|
||||
// _this.oilPreferentialData[i].oilPreferential.userId = response.data.userId
|
||||
// _this.oilPreferentialData[i].oilPreferential.oilId = response.data.oils
|
||||
// _this.oilPreferentialData[i].oilPreferential.mtUserLevel = _this.member.gradeId
|
||||
// _this.oilPreferentialData[i].oilPreferential.cardFavorableId = _this.oilPreferentialData[_this.oilPreferentialData.length-1].cardFavorableId
|
||||
// usePaymentActive(_this.oilPreferentialData[i].oilPreferential).then(res => {})
|
||||
// }
|
||||
}
|
||||
clearInterval(timer);
|
||||
}
|
||||
if (response.data.status == "payFail"){
|
||||
_this.isPaySuccess = false;
|
||||
// _this.isPay = true;
|
||||
_this.isQuery = false;
|
||||
|
||||
_this.loading = false;
|
||||
clearInterval(timer);
|
||||
}
|
||||
if (response.data.status == "unpaid"){
|
||||
_this.isQuery = true;
|
||||
_this.dialogVisiblejLoading = true
|
||||
}
|
||||
}
|
||||
// _this.resetting1();
|
||||
})
|
||||
},1000)
|
||||
|
||||
// 如果是为支付状态15后打开去订单页查询的接口
|
||||
// if (_this.isQuery){
|
||||
// setTimeout(function () {
|
||||
// },10000)
|
||||
// }
|
||||
|
||||
let timer2 = setInterval(function () {
|
||||
if (!_this.isQuery || !_this.dialogVisiblej) {
|
||||
_this.loading = false;
|
||||
// _this.isPay = true;
|
||||
// _this.countdown()
|
||||
clearInterval(timer);
|
||||
clearTimeout(timer3);
|
||||
|
||||
}
|
||||
}, 1000)
|
||||
|
||||
var timer3 = setTimeout(function () {
|
||||
clearInterval(timer2);
|
||||
clearInterval(timer);
|
||||
_this.loading = false;
|
||||
_this.isPay = true;
|
||||
this.isPaySuccess = false;
|
||||
}, 15000)
|
||||
},
|
||||
// 确定收款
|
||||
async collection() {
|
||||
if (this.payForm.payType == "CASH") {
|
||||
@ -1086,8 +1317,13 @@ export default {
|
||||
|
||||
let isPaySuccess = false;
|
||||
console.log(_this.payForm, 1089)
|
||||
// 调用 支付接口 并产生 订单 返回订单号
|
||||
await addLJGoods(_this.payForm).then(async response => {
|
||||
_this.orderNo = response.data.orderNo;
|
||||
|
||||
//支付成功 后需要打印小票
|
||||
console.log("支付成功", response)
|
||||
|
||||
if (response.data.oilOrder != null) {
|
||||
if (response.data.oilOrder.orderStatus == "paid") {
|
||||
|
||||
@ -1095,10 +1331,7 @@ export default {
|
||||
isPaySuccess = true
|
||||
_this.isPay = true;
|
||||
_this.loading = false;
|
||||
|
||||
_this.printLocally()
|
||||
_this.oilOrderReport()
|
||||
|
||||
_this.resetting1()
|
||||
return;
|
||||
}
|
||||
@ -1109,9 +1342,7 @@ export default {
|
||||
isPaySuccess = true
|
||||
_this.isPay = true;
|
||||
_this.loading = false;
|
||||
_this.printLocally()
|
||||
_this.oilOrderReport()
|
||||
|
||||
_this.resetting1()
|
||||
return;
|
||||
}
|
||||
@ -1133,7 +1364,6 @@ export default {
|
||||
this.loading = true;
|
||||
if (!isPaySuccess) {
|
||||
await _this.queryPayStatus();
|
||||
|
||||
_this.resetting1();
|
||||
}
|
||||
},
|
||||
@ -1152,13 +1382,14 @@ export default {
|
||||
oils: this.oilGunClearing.oilNameId,
|
||||
oilGunNum: this.oilGunClearing.id,
|
||||
tankId: this.oilGunClearing.tankId,
|
||||
activeId: null,
|
||||
activeType: null,
|
||||
activeId: this.chooseAct.hasOwnProperty('actId') ? this.chooseAct.activeId : null,
|
||||
activeType: this.chooseAct.hasOwnProperty('type') ? this.chooseAct.activeType : null,
|
||||
})
|
||||
}else {
|
||||
this.payForm.oilOrder = null
|
||||
}
|
||||
|
||||
|
||||
//商品 集合
|
||||
this.payForm.goodsOrder = JSON.stringify(this.goodsList)
|
||||
//支付方式
|
||||
@ -1175,8 +1406,12 @@ export default {
|
||||
this.payForm.oilGunId = this.oilGunClearing.id
|
||||
//活动营销优惠金额
|
||||
this.payForm.activeAmount = this.chooseAct.disAmount || 0.0
|
||||
|
||||
//优惠卷类型
|
||||
this.payForm.couponType = this.chooseCoupon.type
|
||||
this.payForm.couponType = this.chooseCoupon.hasOwnProperty('type') ? this.chooseCoupon.type : null
|
||||
//优惠券id
|
||||
this.payForm.couponId = this.chooseCoupon.hasOwnProperty('couponId') ? this.chooseCoupon.id : null
|
||||
|
||||
//付款用户
|
||||
this.payForm.payUser = this.chooseVipUser.mobile
|
||||
//油品优惠金额
|
||||
@ -1184,12 +1419,6 @@ export default {
|
||||
//商品优惠金额
|
||||
this.payForm.goodsDiscount = 0;
|
||||
|
||||
// this.payForm.usePoint=0;
|
||||
// this.payForm.pointAmount=0;
|
||||
// this.payForm.balanceAmount=0;
|
||||
// this.payForm.oilCardAmount=0;
|
||||
// //员工id
|
||||
// this.payForm.staffId = this.$store.getters.userId;
|
||||
//会员消费金额 (储值卡需要减少的金额)
|
||||
this.payForm.consumeAmount = this.realAmount;
|
||||
//会员id
|
||||
@ -1203,16 +1432,18 @@ export default {
|
||||
this.payForm.goodsNum = this.getGoodsListNum
|
||||
//油品 + 商品 的实付总额
|
||||
this.payForm.allAmount = this.realAmount
|
||||
//支付码 如果是现金 传现金 金额
|
||||
if (this.payForm.payType == "CASH") {
|
||||
this.authCode = this.realAmount
|
||||
}
|
||||
|
||||
this.payForm.realyPayBills = this.realAmount
|
||||
this.flag = 3
|
||||
|
||||
this.payForm.paymentType = this.payType
|
||||
|
||||
console.log('支付类型', this.payForm.paymentType)
|
||||
|
||||
//支付弹窗 相关
|
||||
this.payForm.realyPayBills= this.realAmount
|
||||
this.isPay = true;
|
||||
this.openConfirm = true;
|
||||
this.isPay = true
|
||||
console.log(this.payForm,1210)
|
||||
this.flag = 3
|
||||
|
||||
},
|
||||
// 网络下发之后获取条码
|
||||
getCode(amount, flag) {
|
||||
@ -1636,6 +1867,7 @@ export default {
|
||||
* @param value
|
||||
*/
|
||||
setindex(value) {
|
||||
console.log('支付方式',value);
|
||||
this.payType = value
|
||||
//支付方式发生变化,查询可用优惠券和优惠活动
|
||||
this.getActivity()
|
||||
@ -1779,6 +2011,12 @@ export default {
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
|
||||
.disabled {
|
||||
pointer-events: none; // 禁用鼠标事件
|
||||
opacity: 0.6; // 半透明效果表示禁用
|
||||
}
|
||||
|
||||
input {
|
||||
width: 100%;
|
||||
border: none;
|
||||
|
Loading…
Reference in New Issue
Block a user