liuhairui vor 9 Monaten
Ursprung
Commit
6fd33bc6b9

+ 8 - 6
src/view/performance/caiqiebaogong.vue

@@ -196,10 +196,10 @@
 				</el-dialog>
 				
 				  <!-- 退还 -->
-					<el-dialog v-model="res_bomdialogFormVisible" :before-close="res_bomcloseDialog" title="报工领用" width="100%" top="2%" destroy-on-close>
+					<el-dialog v-model="res_bomdialogFormVisible" :before-close="res_bomcloseDialog" title="报工退还" width="100%" top="2%" destroy-on-close>
 						<div class="dialog-footer">
-						<el-button @click="res_bomcloseDialog">取消</el-button>
-						<el-button type="primary" @click="res_bomenterDialog">确定</el-button>
+						<el-button @click="res_bomcloseDialog" style="height: 40px;font-size: 20px;">关 闭</el-button>
+						<el-button type="primary" @click="res_bomenterDialog" style="height: 40px;font-size: 20px;">退 还</el-button>
 						</div>
 						<div style="width: 100%; height: 60px; padding: 0px; margin: 10px 0px 0px 0px; display: flex; align-items: center;">
 						<el-form-item label="订单编号 :" prop="currentProcess" style="margin-right: 20px; padding: 0px">
@@ -781,8 +781,8 @@ const resbom_tableColumns = ref(
 		// { label: '款式', prop: '款式', width: '100' },
 		{ label: '物料名称', prop: '物料名称', width: '160' },
 		{ label: '计划用料', prop: '计划用料', width: '105' },
-		{ label: '定额用料', prop: '定额用料', width: '110' },
-		{ label: '门封', prop: '门封', width: '110' },
+		{ label: '定额用料', prop: '定额用料', width: '100' },
+		{ label: '门封', prop: '门封', width: '80' },
 		{ label: '裁床实际用料', prop: '裁床实际用料', width: '115' },
 		{ label: '裁床领用面料', prop: '裁床领用面料', width: '115' },
 		{ label: '裁床退回仓库面料', prop: '裁床退回仓库面料', width: '150' },
@@ -882,7 +882,9 @@ const res_bomenterDialog = async() => {
 	    number: item.退还  ? item.退还 : "",
 	    rq: currentDate,
 	    name: "退还",
-		sys_id: _username.value
+		sys_id: _username.value,
+		receipt_number:danhao.value,
+		recipient:_username.value
 	  }
 	});
 	console.log(formattedData);

+ 41 - 9
src/view/yunyin/shengchanguanli/gongdanziliao.vue

@@ -215,16 +215,17 @@
                           :cell-class-name="planUsageCellClass"
                           highlight-current-row="true"
                           @row-dblclick="mlupdateCompanyFunc"
+						  :summary-method="mlgetSummaries" 
                           style="width: 100%;height: 36vh" border tooltip-effect="dark" :data="mltableData" row-key="ID" @selection-change="handleSelectionChange">
 <!--                  <el-table-column type="selection" width="30" />-->
-                  <el-table-column align="left" label="面料" prop="面料"  width="240"/>
-                  <el-table-column align="left" label="面料编号" prop="面料编号"  width="100"/>
-                  <el-table-column align="left" label="颜色" prop="颜色"  width="100"/>
-                  <el-table-column align="left" label="入库数量" prop="入库数量"  width="210"/>
-                  <el-table-column align="left" label="领用数量" prop="领用数量"  width="100" />
-                  <el-table-column align="left" label="库存数量" prop="库存数量"  width="120"/>
-                  <el-table-column align="left" label="建档时间" prop="建档时间"  width="160"/>
-                  <el-table-column align="left" label="更新时间" prop="更新时间"  width="160"/>
+                  <el-table-column align="left" label="订单编号" prop="订单编号"  width="110"/>
+                  <el-table-column align="left" label="生产款号" prop="生产款号"  width="130"/>
+                  <el-table-column align="left" label="客户编号" prop="客户编号"  width="100"/>
+                  <el-table-column align="left" label="款式" prop="款式"  width="150"/>
+                  <el-table-column align="left" label="物料名称" prop="物料名称"  width="170" />
+                  <el-table-column align="left" label="库存总量" prop="库存总量"  width="120"/>
+                  <el-table-column align="left" label="面料结余" prop="面料结余"  width="160"/>
+                  <el-table-column align="left" label="投料单位" prop="投料单位"  width="100"/>
                 </el-table>
               </el-tab-pane>
             </el-tabs>
@@ -1096,7 +1097,7 @@ import * as XLSX from 'xlsx';
 import jsPDF from 'jspdf';
 import {Datalist,WorkOrderList,WorkOrderAdd,PrintListData,
 printDetailAdd,PrintDetailDel,orderDataDel,getWorkOrder,
-getSuborder,PrintDataEdit,WorkOrderEdit,gdAnnexAdd,upload,OrderAttachments,getPonumber,FabricEdit,orderBomList,FabricDetail} from '@/api/mes/job'
+getSuborder,PrintDataEdit,WorkOrderEdit,gdAnnexAdd,upload,OrderAttachments,getPonumber,FabricEdit,orderBomList,FabricDetail,fabricList} from '@/api/mes/job'
 import PrintPage from './components/print.vue'
 import luckyexcelPage from './components/luckyexcel.vue'
 import AddGongYi from './components/addGongYi.vue'  
@@ -2365,6 +2366,9 @@ const tableRowClick = async (row) => {
 		const orderBomListdata = await orderBomList({order:_Gd_gdbh.value});
 		bomtableData.value = orderBomListdata.data
 		bomtableData.splice(0,orderBomListdata.data.length,...orderBomListdata.data);//bom表格数据
+		
+		const fabricListdata = await fabricList({order:_Gd_gdbh.value});
+		mltableData.splice(0,fabricListdata.data.length,...fabricListdata.data);//bom表格数据
 		//颜色资料
         if(PrintListDatas.data.列表.length === 0 ){
           ystableData.length = 0
@@ -2591,6 +2595,34 @@ const fj_delclick = async () => {
     return sums;  
 };  
 
+// 面料合计
+// const mlgetSummaries = (param) => {  
+//     const { columns, data } = param;  
+//     const sums = {};  
+// 	//选择你希望合计的列
+//     const summableLabels = ["库存总量"];
+//     columns.forEach((column, index) => {  
+//         if (index === 0) {  
+//             sums[index] = '总数量合计';  
+//             return;  
+//         }  
+//         if (summableLabels.includes(column.label)) {  
+//             const values = data.map(item => Number(item[column.property]));  
+//             if (!values.every(value => isNaN(value))) {  
+//                 sums[index] = values.reduce((prev, curr) => {  
+//                     const value = Number(curr);  
+//                     if (!isNaN(value)) {  
+//                         return prev + value; 
+//                     }  
+//                     return prev;  
+//                 }, 0);  
+//             } else {  
+//                  sums[index] = 'N/A';  
+//             }  
+//         }  
+//     });  
+//     return sums;  
+// };