From ed9a99c55292d5a2690dcdafac91ddbe4c321cee Mon Sep 17 00:00:00 2001
From: jishenghua <752718920@qq.com>
Date: Fri, 24 May 2024 01:23:46 +0800
Subject: [PATCH] =?UTF-8?q?=E5=AE=8C=E5=96=84=E5=BA=93=E5=AD=98=E6=8A=A5?=
=?UTF-8?q?=E8=A1=A8=EF=BC=8C=E7=BB=99=E5=95=86=E5=93=81=E9=A1=B5=E9=9D=A2?=
=?UTF-8?q?=E5=A2=9E=E5=8A=A0=E4=BF=AE=E6=AD=A3=E6=88=90=E6=9C=AC?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../src/views/material/MaterialList.vue | 33 ++++++++++++++++++-
.../src/views/report/InOutStockReport.vue | 2 +-
jshERP-web/src/views/report/MaterialStock.vue | 2 +-
.../src/views/system/SystemConfigList.vue | 2 +-
4 files changed, 35 insertions(+), 4 deletions(-)
diff --git a/jshERP-web/src/views/material/MaterialList.vue b/jshERP-web/src/views/material/MaterialList.vue
index 785267cd..a44c7adf 100644
--- a/jshERP-web/src/views/material/MaterialList.vue
+++ b/jshERP-web/src/views/material/MaterialList.vue
@@ -99,6 +99,7 @@
导出
批量编辑
修正库存
+ 修正成本
@@ -293,7 +294,8 @@
importExcelUrl: "/material/importExcel",
exportXlsUrl: "/material/exportExcel",
batchSetStatusUrl: "/material/batchSetStatus",
- batchSetMaterialCurrentStockUrl: "/material/batchSetMaterialCurrentStock"
+ batchSetMaterialCurrentStockUrl: "/material/batchSetMaterialCurrentStock",
+ batchSetMaterialCurrentUnitPriceUrl: "/material/batchSetMaterialCurrentUnitPrice",
}
}
},
@@ -376,6 +378,35 @@
});
}
},
+ batchSetMaterialCurrentUnitPrice () {
+ if (this.selectedRowKeys.length <= 0) {
+ this.$message.warning('请选择一条记录!');
+ } else {
+ let ids = "";
+ for (let a = 0; a < this.selectedRowKeys.length; a++) {
+ ids += this.selectedRowKeys[a] + ",";
+ }
+ let that = this;
+ this.$confirm({
+ title: "确认操作",
+ content: "是否操作选中数据?",
+ onOk: function () {
+ that.loading = true;
+ postAction(that.url.batchSetMaterialCurrentUnitPriceUrl, {ids: ids}).then((res) => {
+ if(res.code === 200){
+ that.$message.info('修正成本成功!');
+ that.loadData();
+ that.onClearSelected();
+ } else {
+ that.$message.warning(res.data.message);
+ }
+ }).finally(() => {
+ that.loading = false;
+ });
+ }
+ });
+ }
+ },
batchEdit() {
if (this.selectedRowKeys.length <= 0) {
this.$message.warning('请选择一条记录!');
diff --git a/jshERP-web/src/views/report/InOutStockReport.vue b/jshERP-web/src/views/report/InOutStockReport.vue
index 23294557..6f655a94 100644
--- a/jshERP-web/src/views/report/InOutStockReport.vue
+++ b/jshERP-web/src/views/report/InOutStockReport.vue
@@ -159,7 +159,7 @@
{title: '型号', dataIndex: 'materialModel', width: 80, ellipsis:true},
{title: '扩展信息', dataIndex: 'materialOther', width: 80, ellipsis:true},
{title: '单位', dataIndex: 'unitName', width: 60, ellipsis:true},
- {title: '单价', dataIndex: 'unitPrice', sorter: (a, b) => a.unitPrice - b.unitPrice, width: 60},
+ {title: '成本价', dataIndex: 'unitPrice', sorter: (a, b) => a.unitPrice - b.unitPrice, width: 60},
{title: '上月结存数量', dataIndex: 'prevSum', sorter: (a, b) => a.prevSum - b.prevSum, width: 80},
{title: '入库数量', dataIndex: 'inSum', sorter: (a, b) => a.inSum - b.inSum, width: 60},
{title: '出库数量', dataIndex: 'outSum', sorter: (a, b) => a.outSum - b.outSum, width: 60},
diff --git a/jshERP-web/src/views/report/MaterialStock.vue b/jshERP-web/src/views/report/MaterialStock.vue
index 412fa4f2..5d056263 100644
--- a/jshERP-web/src/views/report/MaterialStock.vue
+++ b/jshERP-web/src/views/report/MaterialStock.vue
@@ -189,7 +189,7 @@
{title: '类别', dataIndex: 'categoryName', width: 60, ellipsis:true},
{title: '仓位货架', dataIndex: 'position', width: 60, ellipsis:true},
{title: '单位', dataIndex: 'unitName', width: 60, ellipsis:true},
- {title: '单价', dataIndex: 'purchaseDecimal', sorter: (a, b) => a.purchaseDecimal - b.purchaseDecimal, width: 60},
+ {title: '成本价', dataIndex: 'purchaseDecimal', sorter: (a, b) => a.purchaseDecimal - b.purchaseDecimal, width: 60},
{title: '初始库存', dataIndex: 'initialStock', width: 60},
{title: '库存', dataIndex: 'currentStock', sorter: (a, b) => a.currentStock - b.currentStock, width: 60,
scopedSlots: { customRender: 'customRenderStock' }
diff --git a/jshERP-web/src/views/system/SystemConfigList.vue b/jshERP-web/src/views/system/SystemConfigList.vue
index 36abc97f..f7484447 100644
--- a/jshERP-web/src/views/system/SystemConfigList.vue
+++ b/jshERP-web/src/views/system/SystemConfigList.vue
@@ -112,7 +112,7 @@
- (默认为关闭状态,代表成本价等于商品信息页面录入的采购价。开启之后将通过移动平均来计算成本价)
+ (默认为关闭状态,代表成本价等于商品信息页面录入的采购价。开启之后将通过移动平均来计算成本价,需到商品管理批量修正成本,请按实际业务谨慎操作)