From 6f6988b8b2b2fefc18929f929a45c80d2b5ebeeb Mon Sep 17 00:00:00 2001 From: wangh <9483> Date: Mon, 19 Feb 2024 16:38:03 +0800 Subject: [PATCH] no message --- fuintAdmin/src/api/oilConfig/oilInventory.js | 9 +++++ .../views/oilConfig/oilInventory/order.vue | 36 +++++++++++++++---- .../src/views/oilConfig/oilTank/list.vue | 4 --- fuintAdmin_zt/src/views/Site/index.vue | 6 +++- .../mapper/xml/MtPurchaseMapper.xml | 4 +-- .../service/impl/AllOrderInfoServiceImpl.java | 2 +- .../OilInventoryOrderController.java | 5 +++ .../service/OilInventoryOrderService.java | 2 ++ .../impl/OilInventoryOrderServiceImpl.java | 36 ++++++++++++++++++- .../store/service/impl/StoreServiceImpl.java | 16 +++++++-- .../business/store/task/storeConfigTask.java | 1 - .../com/fuint/system/dept/entity/SysDept.java | 2 ++ .../cashier/orderComponents/order_Cashier.vue | 10 ++++++ 13 files changed, 115 insertions(+), 18 deletions(-) diff --git a/fuintAdmin/src/api/oilConfig/oilInventory.js b/fuintAdmin/src/api/oilConfig/oilInventory.js index b7c0b3e58..877b17bf2 100644 --- a/fuintAdmin/src/api/oilConfig/oilInventory.js +++ b/fuintAdmin/src/api/oilConfig/oilInventory.js @@ -100,6 +100,15 @@ export function selectList2Api(data) { }) } +// 查询油罐信息 +export function getPurchaseByTankIdApi(data) { + return request({ + url: 'business/petrolStationManagement/oilInventoryOrder/getPurchaseByTankId', + method: 'get', + params: data + }) +} + // 删除有关信息 export function delInventoryOrderApi(data) { return request({ diff --git a/fuintAdmin/src/views/oilConfig/oilInventory/order.vue b/fuintAdmin/src/views/oilConfig/oilInventory/order.vue index 518bc904d..9d13dd593 100644 --- a/fuintAdmin/src/views/oilConfig/oilInventory/order.vue +++ b/fuintAdmin/src/views/oilConfig/oilInventory/order.vue @@ -120,7 +120,7 @@ - + @@ -221,7 +221,12 @@ import { updateInventoryOrderApi, updateInventoryApi, selectList2Api, - insertBatchInventoryOrderApi, getInventoryByIdApi, disposeBatchApi, delInventoryOrderApi, abolitionInventoryApi + insertBatchInventoryOrderApi, + getInventoryByIdApi, + disposeBatchApi, + delInventoryOrderApi, + abolitionInventoryApi, + getPurchaseByTankIdApi } from "@/api/oilConfig/oilInventory"; import {getOilNameListApi} from "@/api/oilPrice"; import {selectTankByNumberApi} from "@/api/oilConfig/oilGuns"; @@ -455,12 +460,15 @@ export default { // this.selectSuppliers() }, // 添加油罐到订单列表 - addOrder () { + async addOrder () { + let this_ = this // 油罐列表清除数据 this_.tankList = [] this_.tankForm = {} - this.multipleSelection.forEach(mul=>{ + for (const mul of this.multipleSelection) { + + // this.multipleSelection.forEach(mul=>{ let isDuplicate = false if (this.orderList.length > 0) { isDuplicate = this.orderList.some(order => order.tankId === mul.id); @@ -474,6 +482,12 @@ export default { this.multipleSelection = [] return; } + let getPurchaseByTankIdData + // 根据油罐id查询数据 + await getPurchaseByTankIdApi({tankId:mul.id}).then(res=>{ + getPurchaseByTankIdData = res.data + }) + let now = { tankId: mul.id, @@ -482,10 +496,20 @@ export default { numberName: mul.oilNumber, inventoryVolume:mul.storedQuantity, currentAveragePrice: mul.discountedPrice, - currentInventoryVolume: mul.storedQuantity + currentInventoryVolume: mul.storedQuantity, + + theTotalPurchasePrice:getPurchaseByTankIdData.theTotalPurchasePrice, // 采购总价 + theAmountOfOilPurchased:getPurchaseByTankIdData.theAmountOfOilPurchased, // 采购油量 + purchaseUnitPrice:getPurchaseByTankIdData.purchaseUnitPrice, // 采购单价 + totalOilVolumeSold:getPurchaseByTankIdData.totalOilVolumeSold, // 销售总油量 + theTotalSalePrice:getPurchaseByTankIdData.theTotalSalePrice, // 销售总价 + totalPrice:getPurchaseByTankIdData.purchaseUnitPrice*getPurchaseByTankIdData.totalOilVolumeSold // 当前剩余油量总价 } + + this_.orderList.push(now) - }) + // }) + } this.multipleSelection = [] this_.open = false diff --git a/fuintAdmin/src/views/oilConfig/oilTank/list.vue b/fuintAdmin/src/views/oilConfig/oilTank/list.vue index 80e37e7b8..0d97c4ad5 100644 --- a/fuintAdmin/src/views/oilConfig/oilTank/list.vue +++ b/fuintAdmin/src/views/oilConfig/oilTank/list.vue @@ -245,8 +245,6 @@ export default { numberId: null, createTime: null, updateTime: null, - createBy: '', - updateBy: '', unit:'' }, disableInput: false, // 默认不禁用 @@ -429,8 +427,6 @@ export default { numberId: null, createTime: null, updateTime: null, - createBy: '', - updateBy: '', unit:'' } }, diff --git a/fuintAdmin_zt/src/views/Site/index.vue b/fuintAdmin_zt/src/views/Site/index.vue index d62ec793e..986d11fcb 100644 --- a/fuintAdmin_zt/src/views/Site/index.vue +++ b/fuintAdmin_zt/src/views/Site/index.vue @@ -209,6 +209,7 @@ @@ -280,6 +281,7 @@ @@ -1340,7 +1344,7 @@ export default { .el-tree-node.is-current > .el-tree-node__content { - background-color: rgb(64, 158, 255) !important; + background-color: rgb(201, 227, 255) !important; } .app-container{ diff --git a/fuintBackend/fuint-application/src/main/java/com/fuint/business/convenienceSore/mapper/xml/MtPurchaseMapper.xml b/fuintBackend/fuint-application/src/main/java/com/fuint/business/convenienceSore/mapper/xml/MtPurchaseMapper.xml index 1f002beab..ec3842504 100644 --- a/fuintBackend/fuint-application/src/main/java/com/fuint/business/convenienceSore/mapper/xml/MtPurchaseMapper.xml +++ b/fuintBackend/fuint-application/src/main/java/com/fuint/business/convenienceSore/mapper/xml/MtPurchaseMapper.xml @@ -151,9 +151,9 @@ and mg.supplier_id = #{mtPurchase.supplierId} - GROUP BY create_time DESC + GROUP BY mp.id - ORDER BY + ORDER BY mp.create_time DESC