From d0aef87a516f6711e1299ee1ce771b092a0674fb Mon Sep 17 00:00:00 2001
From: zzyuan <781948537@qq.com>
Date: Tue, 5 Aug 2025 09:15:23 +0800
Subject: [PATCH] =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E9=97=AE=E9=A2=98=E4=BF=AE?=
=?UTF-8?q?=E6=94=B9?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/views/foodManage/index.vue | 4 ++--
.../purchaseManage/productionPlan/index.vue | 18 +++++++++++++++---
.../purchaseManage/purchaseInspection/edit.vue | 2 +-
3 files changed, 18 insertions(+), 6 deletions(-)
diff --git a/src/views/foodManage/index.vue b/src/views/foodManage/index.vue
index 0c117259..28aeb7af 100644
--- a/src/views/foodManage/index.vue
+++ b/src/views/foodManage/index.vue
@@ -432,7 +432,7 @@ export default {
{
type: "category",
inverse: true,
- offset: 100,
+ offset: 60,
axisLabel: {
show: true,
align: "left",
@@ -537,7 +537,7 @@ export default {
{
type: "category",
inverse: true,
- offset: -20,
+ offset: -10,
axisTick: "none",
axisLine: "none",
show: true,
diff --git a/src/views/foodManage/purchaseManage/productionPlan/index.vue b/src/views/foodManage/purchaseManage/productionPlan/index.vue
index 0fd78564..664baabb 100644
--- a/src/views/foodManage/purchaseManage/productionPlan/index.vue
+++ b/src/views/foodManage/purchaseManage/productionPlan/index.vue
@@ -189,7 +189,7 @@
数量(kg)
- 取整
+ 取整
(scope.row.purchaseNum=v.replace(/[^\d.]/g, '').replace(/^(\d*\.\d{2}).*$/, '$1'))"/>
@@ -288,10 +288,9 @@ export default {
let arr = response.rows;
arr.forEach(item=>{
if(item.itemName=='material_conversion_rounding_method'){
- this.material_conversion_rounding_method = item.itemValue
+ this.material_conversion_rounding_method = item.itemValue||0
}
})
- console.log(this.material_conversion_rounding_method)
});
},
//区域树
@@ -450,6 +449,19 @@ export default {
this.end = parseInt(end.getTime() / 1000)
return [start, end]
},
+ roundingNum(){
+ console.log(this.material_conversion_rounding_method)
+ console.log(this.dialogTableList)
+ this.dialogTableList.forEach(item=>{
+ if(this.material_conversion_rounding_method==0){//向上取整
+ this.$set(item,"purchaseNum",Math.ceil(item.purchaseNum))
+ }else if(this.material_conversion_rounding_method==1){//向下取整
+ this.$set(item,"purchaseNum",Math.floor(item.purchaseNum))
+ }else if(this.material_conversion_rounding_method==2){//四舍五入
+ this.$set(item,"purchaseNum",Math.round(item.purchaseNum))
+ }
+ })
+ },
//日期
formatDate(date) {
// 格式化为 YYYY-MM-DD
diff --git a/src/views/foodManage/purchaseManage/purchaseInspection/edit.vue b/src/views/foodManage/purchaseManage/purchaseInspection/edit.vue
index 41c8f82b..3c5f9586 100644
--- a/src/views/foodManage/purchaseManage/purchaseInspection/edit.vue
+++ b/src/views/foodManage/purchaseManage/purchaseInspection/edit.vue
@@ -233,7 +233,7 @@
-
+
{{ (scope.row.orderAmount/100).toFixed(2) }}