From 284b5d41c1284dc6da25bb062de10c6d4998f186 Mon Sep 17 00:00:00 2001
From: 廖井涛 <2265517004@qq.com>
Date: 星期五, 21 二月 2025 10:44:12 +0800
Subject: [PATCH] Merge branch 'master' of http://bore.pub:10439/r/ERP_override
---
north-glass-erp/northglass-erp/src/views/pp/report/ProcessCardProgress.vue | 37 ++++++++++++++++++++++++++++++-------
1 files changed, 30 insertions(+), 7 deletions(-)
diff --git a/north-glass-erp/northglass-erp/src/views/pp/report/ProcessCardProgress.vue b/north-glass-erp/northglass-erp/src/views/pp/report/ProcessCardProgress.vue
index 8e65a26..29a12ed 100644
--- a/north-glass-erp/northglass-erp/src/views/pp/report/ProcessCardProgress.vue
+++ b/north-glass-erp/northglass-erp/src/views/pp/report/ProcessCardProgress.vue
@@ -52,17 +52,19 @@
let column = [1,3,8]
//鐐瑰嚮鏌ヨ
const getWorkOrder = () => {
+ gridOptions.columns = gridOptions.columns.slice(0, 11); //娓呴櫎鍔ㄦ�佺敓鎴愮殑鍒楅噸鏂版煡璇�
request.post(`/report/processCardProgress/${form.orderId}`, column).then((res) => {
if (res.code == 200) {
if (res.data.data.length === 0) {
ElMessage.warning(t('report.noDataFoundForThisOrder'))
return
}
+
// 鍔ㄦ�佹坊鍔犲垪
res.data.title.forEach((item, index) => {
let column = {
slots: { default: 'quantitySum' },
- width: 90,
+ width: 150,
title: item.process,
field: `dynamicColumn${index}` // 涓哄姩鎬佸垪娣诲姞鍞竴鐨� field
}
@@ -71,6 +73,7 @@
res.data.data.forEach(item => {
item.reportWorkQuantity = JSON.parse(item.reportWorkQuantity)
item.reportWorkQuantityCount = JSON.parse(item.reportWorkQuantityCount)
+ item.reportWorkTime = JSON.parse(item.reportWorkTime)
})
mergeCells.value = res.data.mergeCell
xGrid.value.loadData(res.data.data)
@@ -92,14 +95,34 @@
const quantitySum = ( row,column )=>{
const reportWorkQuantity = row.reportWorkQuantity[column.title] || 0
const reportWorkQuantityCount = row.reportWorkQuantityCount[column.title] || 0
- if(reportWorkQuantity===reportWorkQuantityCount){
- return reportWorkQuantity
+ const reportWorkTime = row.reportWorkTime[column.title] || 0
+ if (reportWorkTime===0){
+ if(reportWorkQuantity===reportWorkQuantityCount){
+ return reportWorkQuantity
+ }
+
+ return (reportWorkQuantity
+ +'('
+ +reportWorkQuantityCount
+ +')' )
+ }
+ else {
+ if(reportWorkQuantity===reportWorkQuantityCount){
+ return (reportWorkQuantity+'['
+ +reportWorkTime
+ +']')
+ }
+
+ return (reportWorkQuantity
+ +'('
+ +reportWorkQuantityCount
+ +')'
+ +'['
+ +reportWorkTime
+ +']'
+ )
}
- return (reportWorkQuantity
- +'('
- +reportWorkQuantityCount
- +')' )
//return
}
--
Gitblit v1.8.0