diff --git a/fuintBackend/fuint-application/src/main/java/com/fuint/business/commission/service/impl/StaffCommissionServiceImpl.java b/fuintBackend/fuint-application/src/main/java/com/fuint/business/commission/service/impl/StaffCommissionServiceImpl.java index ec2af7de5..e4ab8de1d 100644 --- a/fuintBackend/fuint-application/src/main/java/com/fuint/business/commission/service/impl/StaffCommissionServiceImpl.java +++ b/fuintBackend/fuint-application/src/main/java/com/fuint/business/commission/service/impl/StaffCommissionServiceImpl.java @@ -17,10 +17,13 @@ import com.fuint.business.member.service.ILJDutyService; import com.fuint.business.member.service.ILJStaffService; import com.fuint.business.order.entity.AllOrderInfo; import com.fuint.business.order.mapper.AllOrderInfoMapper; +import com.fuint.business.order.service.AllOrderInfoService; +import com.fuint.business.order.vo.AllOrderInfoUniVo; import com.fuint.common.dto.AccountInfo; import com.fuint.common.util.TokenUtil; import com.fuint.system.role.entity.TDuty; import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.context.annotation.Lazy; import org.springframework.stereotype.Service; import java.text.SimpleDateFormat; @@ -38,6 +41,9 @@ public class StaffCommissionServiceImpl extends ServiceImpl selectCommissionList(Page page, StaffCommission commission) { @@ -123,6 +129,7 @@ public class StaffCommissionServiceImpl extends ServiceImpl() .eq(AllOrderInfo::getOrderNo, orderNo)); + AllOrderInfo allOrderInfo1 = allOrderInfoService.selectAllOrderInfoByOrderNo(orderNo); commissionRecordService.addRecord(allOrderInfo.getId()); // if (ObjectUtil.isNotEmpty(staffId)) { // LJStaff staff = staffService.selectStaffById(staffId); 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 b41c9917f..60093e4dc 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 @@ -536,7 +536,7 @@ public class CardValueRecordServiceImpl extends ServiceImpl
储值卡:¥{{ chooseVipUser.cardBalance || 0 }}
-
囤油卡:¥{{ - item.fuelAmount - }} +
+ 囤油卡:¥{{item.fuelAmount}}
@@ -582,7 +581,7 @@ import { getCheckTheStatusOfYourPaymentApi, rechargeCard } from "@/api/cashier/cardSet"; -import {getReturnCode, printOilOrderReport} from '@/api/print' +import {getReturnCode, printOilOrderReport,printCardValueReport,printFuelDieselReport} from '../../../api/print' import {addLJGoods, scanAppletQrCode} from "@/api/cashier/oilorder"; import {cashierOrderByOrderNo} from '@/api/cashier/cashierorder' import {addHangBill} from "../../../api/cashier/hangbill"; @@ -1051,8 +1050,10 @@ export default { } }); let this_ = this + console.log(this.payForm,1054) // let timer = setInterval(async () => { + let flag = false await getCheckTheStatusOfYourPaymentApi(id).then(async response => { if (response.data != null) { const payStatus = response.data.payStatus @@ -1064,8 +1065,9 @@ export default { this_.isQuery = false; this_.rechargeBalCard = true // await this_.printLocally1() - await this_.cardValueReport() - await this_.getMemberAfter(); + flag = true + // await this_.cardValueReport() + // await this_.getMemberAfter(); clearInterval(timer); } else if (payStatus === "payFail") { this_.isPaySuccess = false; @@ -1073,8 +1075,9 @@ export default { clearInterval(timer); } } - await this_.getMemberAfter(); + // await this_.getMemberAfter(); }) + if (flag) await this_.cardValueReport() }, 1000); let timer2 = setInterval(function () { @@ -1119,7 +1122,9 @@ export default { this.$message.error('请选择输入充值本金'); return } + console.log(selectCard,1122) this.payForm.rechargeBalance = selectCard.rechargeBalance + this.payForm.lockupPrice = selectCard.lockupPrice this.payForm.realyPayBills = selectCard.rechargeBalance this.payForm.selectCardId = selectCard.id this.payForm.cardType = selectCard.cardType @@ -1208,6 +1213,70 @@ export default { console.log(res, 1121) }) }, + // 用户余额/礼品卡充值打印 + cardValueReport(){ + // 支付方式 + const payTypeMap = { + 'CASH': '现金', + 'WECHAT': '微信', + 'ALIPAY': '支付宝', + 'UNIONPAY': '银联二维码', + 'after_pay': '挂账', + 'fule_card': '囤油卡', + 'card_value': '储值卡', + 'car_card_value': '车队卡', + }; + + if (this.payForm.cardType==0 || this.payForm.cardType==2){ + console.log(1226) + let payTypeText = payTypeMap[this.payForm.paymentType] + let actualPay = this.payForm.paymentType == 'CASH' ? this.payForm.authCode:this.payForm.realyPayBills + + let a = { + // 充值金额 + realyPayBills:this.payForm.realyPayBills, + //赠送金额 + giftBalance:this.payForm.giftBalance, + // 到账金额 + getAmount:Number(this.payForm.giftBalance) + Number(this.payForm.realyPayBills), + payType:payTypeText, + + // 实付款 + actualPay: actualPay, + // 找零 + seekZero:this.payForm.seekZero.toFixed(2), + } + printCardValueReport(a).then(res => { + console.log(res,1245) + }) + } + + if (this.payForm.cardType==1){ + let payTypeText1 = payTypeMap[this.payForm.paymentType] + console.log(this.payForm,1256) + let b = { + // 充值油品 + oilType:this.payForm.oilName, + // 充值升数 + incomeLitres:(this.payForm.rechargeBalance / this.payForm.lockupPrice).toFixed(2), + // 订单金额 + realyPayBills:this.payForm.rechargeBalance, + // 锁价金额 + lockupPrice:this.payForm.lockupPrice, + // 支付方式 + payType:payTypeText1, + // 实付款 + + // 找零 + seekZero:this.payForm.seekZero.toFixed(2), + } + + console.log(b,1271) + printFuelDieselReport(b).then(res=>{ + console.log(res,1273) + }) + } + }, //表单重置 resetting1() { this.realAmount = 0.00 diff --git a/fuintCashierWeb/src/views/cashier/NewComponents/newHomeComponents/memberRecharge.vue b/fuintCashierWeb/src/views/cashier/NewComponents/newHomeComponents/memberRecharge.vue index 92e3c7b64..fd0a139fd 100644 --- a/fuintCashierWeb/src/views/cashier/NewComponents/newHomeComponents/memberRecharge.vue +++ b/fuintCashierWeb/src/views/cashier/NewComponents/newHomeComponents/memberRecharge.vue @@ -60,13 +60,20 @@ export default { }, methods:{ chooseFuel(data){ + console.log(data,63) this.$set(this.selectCard,'id',data.id) this.$set(this.selectCard,'points',data.points) this.$set(this.selectCard,'rechargeBalance',data.rechargeBalance) + this.$set(this.selectCard,'lockupPrice',data.lockPrice) }, changeFuelId(){ this.$set(this.selectCard,'id',null) this.$set(this.selectCard,'points',null) + this.oilList.forEach(item => { + if (this.selectCard.oilNumberId==item.id){ + this.$set(this.selectCard,'oilName',item.oilName) + } + }) this.getFuelCards() }, getOilList(){ @@ -75,6 +82,7 @@ export default { this.oilList = res.data.records if (this.oilList&&this.oilList.length>0){ this.$set(this.selectCard,'oilNumberId',this.oilList[0].id) + this.$set(this.selectCard,'oilName',this.oilList[0].oilName) this.getFuelCards() }