实付款
¥0.00
@@ -3167,15 +3167,15 @@
})
this.goodsActualPay = this.goodsAmount - this.goodsDiscount;
},
- getOilCoupon(){
+ async getOilCoupon() {
let type = 0;
// if (this.consumeAmount==0){
- if (this.consumeRefuelMoney>0){
+ if (this.consumeRefuelMoney > 0) {
type = 1;
- }else {
- if (this.consumeAmount>0){
+ } else {
+ if (this.consumeAmount > 0) {
type = 0;
- }else {
+ } else {
type = 2;
}
}
@@ -3192,12 +3192,12 @@
this.paymentActive.mtUserLevel = this.member.gradeId
this.paymentActive.userId = this.member.id
let _this = this
- this.oilOrder.forEach(item => {
+ for (const item of this.oilOrder) {
_this.paymentActive.amount = item.amount
_this.paymentActive.oilId = item.oilName
_this.paymentActive.storeId = item.storeId
- getPaymentActive(_this.paymentActive).then(async res => {
+ await getPaymentActive(_this.paymentActive).then(async res => {
item.activeId = res.data.activeId
item.type = res.data.type
let discount = { type: "", discount: 0, oilName: item.oilName, gunName: item.gunName }
@@ -3236,7 +3236,7 @@
}
}
// }
- console.log(_this.oilDiscount, 111)
+ console.log(_this.oilDiscount, _this.couponAmount, _this.fullReduction, 3239)
this.countAmountFull()
if (this.isOilStorageCard) {
await this.countAmountFull()
@@ -3248,7 +3248,7 @@
await this.countAmountFull()
}
})
- })
+ }
},
// 调用优惠券接口
getCoupon(){
@@ -3877,6 +3877,7 @@
},
// 囤油卡变化后总金额的变化
changeRefuelMoney(){
+ this.isOilStorageCard = false
getRecord({mtUserId:this.member.id}).then(res => {
this.oilCardAmount = 0
let oilAmount = 0
@@ -3889,7 +3890,7 @@
if (item.oilName==i.oilType){
item.lockupPrice = i.lockupPrice
amount = item.lockupPrice * item.liters
- this.isOilStorageCard = true
+ if (amount>0) this.isOilStorageCard = true
flag = false
}else {
flag = true
@@ -3899,6 +3900,7 @@
if (flag) amount = item.amount
oilAmount += amount
})
+ console.log("3903", this.isOilStorageCard)
if (oilAmount>0) this.oilCardAmount = this.oilAmount - oilAmount
this.countAmountFull()
})
From a73308f067a1449de5f99d463ef2e7594f9d560c Mon Sep 17 00:00:00 2001
From: cun-nan <19819293608@163.com>
Date: Thu, 6 Jun 2024 11:49:38 +0800
Subject: [PATCH 2/3] bug
---
.../fuint/api/fuyou/service/impl/FyPayServiceImpl.java | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/fuintBackend/fuint-application/src/main/java/com/fuint/api/fuyou/service/impl/FyPayServiceImpl.java b/fuintBackend/fuint-application/src/main/java/com/fuint/api/fuyou/service/impl/FyPayServiceImpl.java
index 404acf702..2dfd96ae0 100644
--- a/fuintBackend/fuint-application/src/main/java/com/fuint/api/fuyou/service/impl/FyPayServiceImpl.java
+++ b/fuintBackend/fuint-application/src/main/java/com/fuint/api/fuyou/service/impl/FyPayServiceImpl.java
@@ -434,7 +434,9 @@ public class FyPayServiceImpl implements FyPayService {
}
if (!reqMap.get("trans_stat").equals("USERPAYING")) {
- this.insertAllOrderInfo(receiveParameter, payStatus,discountAmount);
+ String payChannel = "cashier";
+ if (ObjectUtil.isNotEmpty(map1.get("payChannel"))) payChannel = map1.get("payChannel");
+ this.insertAllOrderInfo(receiveParameter, payStatus,discountAmount,payChannel);
}
if (ObjectUtil.isNotEmpty(merchantConfig)) {
@@ -569,7 +571,7 @@ public class FyPayServiceImpl implements FyPayService {
/**
* 添加所有订单信息
*/
- private void insertAllOrderInfo(ReceiveParameter receiveParameter, String payStatus,Double discountAmount) {
+ private void insertAllOrderInfo(ReceiveParameter receiveParameter, String payStatus,Double discountAmount,String payChannel) {
AllOrderInfo allOrderInfo = new AllOrderInfo();
allOrderInfo.setOrderNo(receiveParameter.getOrderNo());
allOrderInfo.setType(receiveParameter.getType());
@@ -578,7 +580,7 @@ public class FyPayServiceImpl implements FyPayService {
allOrderInfo.setPayMoney(receiveParameter.getGoodsMoney());
allOrderInfo.setPayType(receiveParameter.getPayType());
allOrderInfo.setUserId(receiveParameter.getUserId());
- allOrderInfo.setPayChannel("cashier");
+ allOrderInfo.setPayChannel(payChannel);
allOrderInfo.setStatus(payStatus);
allOrderInfo.setDiscountAmount(discountAmount);
if (payStatus.equals("paid")) {
@@ -749,7 +751,7 @@ public class FyPayServiceImpl implements FyPayService {
BeanUtils.copyProperties(receiveParameterPos, receiveParameter);
Double discountAmount = 0.0;
if (ObjectUtil.isNotEmpty(oilOrder)) discountAmount = oilOrder.getDiscountAmount();
- this.insertAllOrderInfo(receiveParameter, receiveParameterPos.getPayType(),discountAmount);
+ this.insertAllOrderInfo(receiveParameter, receiveParameterPos.getPayType(),discountAmount,"POS");
if (reqMap.get("trans_stat").equals("SUCCESS")) {
payStatus = "paid";
if (!ObjectUtil.isEmpty(oilOrder)) {
From 5a794a225dac75e6a8aac43c1431923fa1fd8b1f Mon Sep 17 00:00:00 2001
From: "DESKTOP-369JRHT\\12997" <9>
Date: Thu, 6 Jun 2024 11:50:31 +0800
Subject: [PATCH 3/3] no message
---
.../cardValue/dto/CardValueRecordDTO.java | 1 +
.../impl/CardValueRecordServiceImpl.java | 1 +
.../business/printer/template/Handover.java | 4 +-
.../printer/template/PrintIntegralReport.java | 10 ++-
.../userManager/mapper/xml/LJUserMapper.xml | 2 +-
.../service/impl/LJUserServiceImpl.java | 2 +-
.../MemberRecharge/MemberRecharge.vue | 69 +++++++++++++++++--
7 files changed, 73 insertions(+), 16 deletions(-)
diff --git a/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/cardValue/dto/CardValueRecordDTO.java b/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/cardValue/dto/CardValueRecordDTO.java
index 8a7f1d902..a1b0a0634 100644
--- a/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/cardValue/dto/CardValueRecordDTO.java
+++ b/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/cardValue/dto/CardValueRecordDTO.java
@@ -27,6 +27,7 @@ public class CardValueRecordDTO extends CardValueRecord {
private String appltType;
private String paymentType;
private String payStatus;
+ private String payChannel;
private String types;
@JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
private Date expireTime;
diff --git a/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/cardValue/service/impl/CardValueRecordServiceImpl.java b/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/cardValue/service/impl/CardValueRecordServiceImpl.java
index 84c56b507..c253559a6 100644
--- a/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/cardValue/service/impl/CardValueRecordServiceImpl.java
+++ b/fuintBackend/fuint-application/src/main/java/com/fuint/business/marketingActivity/cardValue/service/impl/CardValueRecordServiceImpl.java
@@ -434,6 +434,7 @@ public class CardValueRecordServiceImpl extends ServiceImpl
支付方式 | 金额 |
");
if (ObjectUtil.isNotEmpty(paymentAggregationAll)) {
for (Map stringObjectMap : paymentAggregationAll) {
- sb.append(""+calculatePaymentMethod(stringObjectMap.get("payType").toString()).toString()+" | ");
+
+
+ sb.append("
"+calculatePaymentMethod(stringObjectMap.get("payType").toString())+" | ");
sb.append(""+Optional.ofNullable(stringObjectMap.get("paidAmount")).orElse("0").toString()+" |
");
}
}
diff --git a/fuintBackend/fuint-application/src/main/java/com/fuint/business/printer/template/PrintIntegralReport.java b/fuintBackend/fuint-application/src/main/java/com/fuint/business/printer/template/PrintIntegralReport.java
index 216678f3a..1f1427e2b 100644
--- a/fuintBackend/fuint-application/src/main/java/com/fuint/business/printer/template/PrintIntegralReport.java
+++ b/fuintBackend/fuint-application/src/main/java/com/fuint/business/printer/template/PrintIntegralReport.java
@@ -22,7 +22,7 @@ public class PrintIntegralReport {
AccountInfo nowAccountInfo = TokenUtil.getNowAccountInfo();
- sb.append("订单统计\r\n");
+ sb.append("积分兑换\r\n");
sb.append("打印时间:"+formattedDateTime +"\r\n");
sb.append("店铺名称:"+nowAccountInfo.getStoreName() +"\r\n");
@@ -30,10 +30,10 @@ public class PrintIntegralReport {
if (ObjectUtil.isNotEmpty(handover.get("shoppingCart"))) {
sb.append("商品名称 | 商品数量 | 价格 |
");
- List
");
@@ -45,12 +45,10 @@ public class PrintIntegralReport {
if (ObjectUtil.isNotEmpty(handover.get("allPoints"))) {
sb.append("总积分:"+handover.get("allPoints")+"\r\n");
sb.append("--------------------------------\r\n");
-
}
if (ObjectUtil.isNotEmpty(handover.get("allAmout"))) {
sb.append("总价格:¥"+handover.get("allAmout")+"\r\n");
sb.append("--------------------------------\r\n");
-
}
sb.append("谢谢惠顾,欢迎下次光临!");
diff --git a/fuintBackend/fuint-application/src/main/java/com/fuint/business/userManager/mapper/xml/LJUserMapper.xml b/fuintBackend/fuint-application/src/main/java/com/fuint/business/userManager/mapper/xml/LJUserMapper.xml
index cb0f0c19f..c575d2646 100644
--- a/fuintBackend/fuint-application/src/main/java/com/fuint/business/userManager/mapper/xml/LJUserMapper.xml
+++ b/fuintBackend/fuint-application/src/main/java/com/fuint/business/userManager/mapper/xml/LJUserMapper.xml
@@ -9,7 +9,7 @@
left join mt_invitation mi on mu.id = mi.userId
- select mu.*,mub.grade_id,mub.card_balance,mub.points,mub.consume_num,mub.growth_value,mub.refuel_money,
+ select mu.*,mub.id balanceId,mub.grade_id,mub.card_balance,mub.points,mub.consume_num,mub.growth_value,mub.refuel_money,
mub.second_card,mub.fixing_level,mub.create_time balCreateTime
FROM mt_user mu
LEFT JOIN mt_user_balance mub ON mu.id = mub.mt_user_id
diff --git a/fuintBackend/fuint-application/src/main/java/com/fuint/business/userManager/service/impl/LJUserServiceImpl.java b/fuintBackend/fuint-application/src/main/java/com/fuint/business/userManager/service/impl/LJUserServiceImpl.java
index 8fa662989..f9da85ae0 100644
--- a/fuintBackend/fuint-application/src/main/java/com/fuint/business/userManager/service/impl/LJUserServiceImpl.java
+++ b/fuintBackend/fuint-application/src/main/java/com/fuint/business/userManager/service/impl/LJUserServiceImpl.java
@@ -175,7 +175,7 @@ public class LJUserServiceImpl extends ServiceImpl impleme
*/
@Override
public LJUserVo selectUserById(int id,Integer storeId) {
- if (storeId==null){
+ if (ObjectUtil.isEmpty(storeId)){
AccountInfo nowAccountInfo = TokenUtil.getNowAccountInfo();
storeId = nowAccountInfo.getStoreId();
}
diff --git a/pos-uni/pagesHome/MemberRecharge/MemberRecharge.vue b/pos-uni/pagesHome/MemberRecharge/MemberRecharge.vue
index ff49c4505..0fc587036 100644
--- a/pos-uni/pagesHome/MemberRecharge/MemberRecharge.vue
+++ b/pos-uni/pagesHome/MemberRecharge/MemberRecharge.vue
@@ -127,11 +127,11 @@
listindex: 0,
memberId: 0,
numList: [
- "50元",
- "100元",
- "300元",
- "500元",
- "1000元",
+ // "50元",
+ // "100元",
+ // "300元",
+ // "500元",
+ // "1000元",
"自定义金额",
],
isChooseUser: false,
@@ -173,6 +173,29 @@
methods: {
// 自定义金额
custom() {
+
+
+ if (this.numList.length > 0) {
+ // const changeList = this.cardValueList
+ this.numList.forEach(change => {
+ if (data >= change.rechargeBalance) {
+ this.order.points = change.points
+ this.order.bidBalance = change.bidBalance
+ this.order.giftBalance = change.giftBalance
+ this.order.growthValue = change.growthValue
+ this.order.rechargeBalance = change.rechargeBalance
+
+ this.order.royaltyType = change.royaltyType
+ this.order.percentageCommissions = change.percentageCommissions
+ this.order.amountCommission = change.amountCommission
+ this.order.cardValueId = change.id
+ }
+ })
+ }
+
+
+ this.order.rechargType = 1
+
console.log(this.value);
this.order.amount = this.value
this.realyPayBills = this.order.amount
@@ -189,11 +212,25 @@
}
}).then((res) => {
this.numList = res.data.records
+ this.numList.sort((a, b) => a.rechargeBalance - b.rechargeBalance);
this.order.amount = this.numList[0].rechargeBalance
this.order.rechargeBalance = this.numList[0].rechargeBalance
this.order.points = this.numList[0].points
this.realyPayBills = this.numList[0].rechargeBalance
+
+
+ this.order.bidBalance = this.numList[0].bidBalance
+ this.order.points = this.numList[0].points
+ this.order.giftBalance = this.numList[0].giftBalance
+ this.order.growthValue = this.numList[0].growthValue
+ this.order.cardValueId = this.numList[0].id
+ // this.order.amount = null
+ this.order.royaltyType = this.numList[0].royaltyType
+ this.order.rechargType = 0
+ this.order.percentageCommissions = this.numList[0].percentageCommissions
+ this.order.amountCommission = this.numList[0].amountCommission
+
})
},
getmemberId(num, payType) {
@@ -216,12 +253,24 @@
},
getindex(index, data) {
this.listindex = index
+ this.order.rechargType = 0
if (data) {
this.order.amount = data.rechargeBalance
this.order.rechargeBalance = data.rechargeBalance
this.order.points = data.points
this.realyPayBills = data.rechargeBalance
- this.order.rechargeBalance = data.rechargeBalance
+
+ this.order.bidBalance = file.bidBalance
+ this.order.points = file.points
+ this.order.giftBalance = file.giftBalance
+ this.order.growthValue = file.growthValue
+ this.order.cardValueId = file.id
+ // this.order.amount = null
+ this.order.royaltyType = file.royaltyType
+ this.order.percentageCommissions = file.percentageCommissions
+ this.order.amountCommission = file.amountCommission
+
+
} else {
this.order.amount = this.value
this.realyPayBills = this.value
@@ -273,9 +322,15 @@
this.order.authCode = this.authCode
this.order.realyPayBills = this.realyPayBills
this.order.actualPayment = actualPayment
+ // cardValueId
+ // growthValue
+ // rechargeType
+ // royaltyType
+ this.order.makeChange = 0
+ // url: 'business/marketingActivi ty/cardFuelRecord/prepaidFuelTopUp',
request({
- url: 'business/marketingActivity/cardFuelRecord/prepaidFuelTopUp',
+ url: 'business/marketingActivity/cardValueRecord/prepaidCardTopUp',
method: 'post',
data: this.order
}).then((res) => {