liuhairui 9 ماه پیش
والد
کامیت
385f58933d
2فایلهای تغییر یافته به همراه73 افزوده شده و 111 حذف شده
  1. 28 20
      src/view/inventory/ruku.vue
  2. 45 91
      src/view/performance/chukubaogong.vue

+ 28 - 20
src/view/inventory/ruku.vue

@@ -1,7 +1,6 @@
 <template>
   <div>
     <layout>
-		<!-- <h1 style="margin: 0%;margin-bottom: 6px;">入库</h1> -->
 		<el-row :gutter="24" style="margin-bottom: 6px;">
 			  <el-input v-model="add_searchInfo" placeholder="请扫描订单编号或输入生产款号模糊查询"  @input="handleInput"
 				@keyup.enter="add_onSubmit" id="searchInput"  style="width: 340px;height: 50px;margin-left: 10px;">
@@ -47,9 +46,9 @@
   <!-- 选择入库弹窗 -->
   <el-dialog v-model="res_bomdialogFormVisible" :before-close="res_bomcloseDialog"  width="100%" style="height: 100%;margin: 0%;padding: 0px 10px 0px 10px;"  destroy-on-close>
 	<div class="dialog-footer" style="margin: 0px;">
-		<el-input v-model="add_lysearchInfo" placeholder="请扫描订单编号进行操作"
+		<!-- <el-input v-model="add_lysearchInfo" placeholder="请扫描订单编号进行操作"
 			@keyup.enter="add_lyonSubmit" id="ly_searchInput" style="width: 340px;height: 50px;margin-left: 10px;">
-		</el-input>
+		</el-input> -->
 		<el-button type="primary" @click="res_bomcloseDialog"  style="width: 100px;height: 50px;margin-left: 10px;">关 闭</el-button>
 		<el-button type="primary" @click="res_bomenterDialog"  style="width: 100px;height: 50px;">一键入库</el-button>
 	</div>
@@ -112,9 +111,9 @@
   </el-dialog>
   
   <!--单号记录 -->
-  <el-dialog v-model="pickingaddvisible" :before-close="()=> pickingaddvisible = false" style="width: 100%; margin: 0% auto; height: 100%;" :title="'出库、入库、退还记录'" destroy-on-close>
+  <el-dialog v-model="pickingaddvisible" :before-close="()=> pickingaddvisible = false" style="width: 100%; margin: 0% auto; height: 100%;" :title="''" destroy-on-close>
 	   <div class="dialog-footer" style="bottom: 10px; right: 10px; width: 100%;">
-		 <el-button  type="primary" @click="ckth_closeDialog" style="width: 80px;height: 40px;display: inline-block;">关 闭</el-button>
+		 <el-button  type="primary" @click="Close_RecordDialog" style="width: 80px;height: 40px;display: inline-block;">关 闭</el-button>
 		 <h3 style="color: red;display: inline-block;margin-left: 20px;">双击表格行查看入库单明细</h3>
 	   </div>
 	   <br>
@@ -360,19 +359,19 @@ const ddhformData = reactive({
 });
 const resbom_tableColumns = ref(
     [
-		{ label: '批次号', prop: '批次号', width: '90' },
+		{ label: '批次号', prop: '批次号', width: '80' },
 		{ label: '关联号', prop: '关联号', width: '80' },
 		{ label: '物料编号', prop: '物料编号', width: '160' },
-		{ label: '物料名称', prop: '物料名称', width: '100' },
-		{ label: '计划用料', prop: '计划用料', width: '100' },
-		{ label: '计划门幅', prop: 'BOM_计划门幅', width: '100' },
-		{ label: '定额用料', prop: '定额用料', width: '100' },
-		{ label: '定额门幅', prop: 'BOM_定额门幅', width: '100' },
+		{ label: '物料名称', prop: '物料名称', width: '90' },
+		{ label: '计划用料', prop: '计划用料', width: '90' },
+		{ label: '计划门幅', prop: 'BOM_计划门幅', width: '90' },
+		{ label: '定额用料', prop: '定额用料', width: '90' },
+		{ label: '定额门幅', prop: 'BOM_定额门幅', width: '90' },
 		{ label: '实际门幅', prop: '实际门幅', width: '100' },
 		{ label: '领用', prop: '领用', width: '100' },
-		{ label: '入仓总量', prop: '入仓总量', width: '100' },
-		{ label: '库存数量', prop: '库存数量', width: '100' },
-		{ label: '领用数量', prop: '领用数量', width: '100' },
+		{ label: '入仓总量', prop: '入仓总量', width: '90' },
+		{ label: '库存数量', prop: '库存数量', width: '90' },
+		{ label: '领用数量', prop: '领用数量', width: '90' },
 		{ label: '颜色', prop: 'BOM_颜色', width: '100' },
 		{ label: '关联订单', prop: '关联订单', width: '110' },
 		{ label: '单位', prop: '单位', width: '100' },
@@ -384,8 +383,9 @@ const Reporting_onSubmit = async ()=>{
 	if(_orderid.value === '' || _orderid.value === null){
 		ElMessage({type: 'warning',message: '请扫描订单后,再操作此功能'})
 	}else{
-		add_lysearchInfo.value = add_searchInfo.value
+		//打开选择入库弹窗
 		res_bomdialogFormVisible.value = true
+		//获取单据编号接口
 		const gitReceiptNumberdata = await gitReceiptNumber({number:'RK'});
 		danhao.value = gitReceiptNumberdata.data.number
 		chukuren.value = userStore.userInfo.nickName
@@ -488,13 +488,17 @@ const res_bomenterDialog = async () => {
 
 // 取消
 const res_bomcloseDialog = () => {
+	_orderid.value =  '';
+	add_searchInfo.value = '';
+	restableData.splice(0, restableData.length);
 	res_bomdialogFormVisible.value = false;
+	//自动获取光标
+	getMachineMacdata();
 }
 
 
 
 //=============出库退还记录==================
-const cktableData = reactive([])
 const thtableData = reactive([])
 const rukutableData = reactive([])
 
@@ -503,24 +507,28 @@ const pickingaddvisible = ref(false)//弹窗
 const add_prinkformData = reactive({});
 //详情记录
 const details_onSubmit = async ()=>{
-	cktableData.splice(0,cktableData.length);
 	thtableData.splice(0,thtableData.length);
 	rukutableData.splice(0,rukutableData.length);
+	if(_orderid.value === ''){
+		ElMessage({type: 'warning',message: '请选择要查看的订单编号或款号,再操作此功能'})
+		return;
+	}
 	pickingaddvisible.value = true
 	const FabricDetaillist = await FabricDetail({order:_orderid.value});
 	const ruku_FabricDetaillist = await FabricDetail({order:_orderid.value,search:'入库'});
 	console.log(FabricDetaillist)
 	console.log(ruku_FabricDetaillist)
 	rukutableData.splice(0,ruku_FabricDetaillist.length,...ruku_FabricDetaillist.data['入库记录']);
-	cktableData.splice(0,FabricDetaillist.length,...FabricDetaillist.data['出库记录']);
 	thtableData.splice(0,FabricDetaillist.length,...FabricDetaillist.data['退还记录']);
 }
-//领料取消
-const ckth_closeDialog = async ()=>{
+
+//入库记录取消
+const Close_RecordDialog = async ()=>{
 	pickingaddvisible.value = false
 	//自动聚焦光标input
 	getMachineMacdata();
 }
+
 const dh = ref('')
 const type = ref('')
 const details_pickingaddvisible = ref(false)

+ 45 - 91
src/view/performance/chukubaogong.vue

@@ -85,7 +85,7 @@
 				<el-table-column :label="item.label" :width="item.width">
 				  <template #default="{ row, column, $index }">
 					<!-- 判断该列是否需要输入框 -->
-					<div v-if="['出库','实际门幅'].includes(item.prop)">
+					<div v-if="['出库数量'].includes(item.prop)">
 					  <el-input
 						v-model="row[item.prop]"
 						:clearable="false"
@@ -101,14 +101,15 @@
 				</el-table-column>
 			  </template>
 			</el-table>
-		  
+			
+			<br>
 			<div style="display: flex; justify-content: space-around; align-items: center; margin-bottom: 10px;">
-		    <p style="font-size: 18px;">出库人: 
-			<el-input v-model="chukuren" style="width: 200px;" disabled/>
-			</p>
-		    <p style="font-size: 18px;">领用人: 
-		      <el-input v-model="linguser" style="width: 200px;" />
-		    </p>
+				<p style="font-size: 18px;">出库人: 
+					<el-input v-model="chukuren" style="width: 200px;" disabled/>
+				</p>
+				<p style="font-size: 18px;">领用人: 
+					<el-input v-model="linguser" style="width: 200px;" />
+				</p>
 		  </div>
 		</div>
 	</el-dialog>
@@ -122,23 +123,28 @@
 		 <br>
 		  <div>
 			  <el-tabs v-model="activeName" @tab-click="handleClick">
-				<el-tab-pane label="入库记录"  @click="showTable('出库记录')"  name="first">
-				  <el-table ref="multipleTable"
-							:row-style="{ height: '30px' }" :header-cell-style="{ padding: '0px' }"
-							:cell-style="{ padding: '0px' }" :header-row-style="{ height: '20px' }"
-							:show-overflow-tooltip="true" highlight-current-row="true"
-							@row-click="rukutableclick" @row-dblclick="chukuupdateCompanyFunc"
-							style="width: 100%;height: 36vh" border :summary-method="getSummaries" tooltip-effect="dark" :data="rukutableData" row-key="ID" >
-					<el-table-column align="left" sortable label="入库单号" prop="单号"  width="140"/>
-					<el-table-column align="left" sortable label="订单编号" prop="订单编号"  width="140"/>
-					<el-table-column align="left" sortable label="款号" prop="款号"  width="180"/>
-					<el-table-column align="left" sortable label="数量" prop="数量"  width="105"/>
-					<el-table-column align="left" sortable label="出库人员" prop="出库人员"  width="160"/>
-					<el-table-column align="left" sortable label="出库时间" prop="出库时间"  width="160"/>
-				  </el-table>
-				</el-tab-pane>
+				  
+	            <!--   <el-tab-pane label="出库记录" name="first">
+	                <el-table ref="multipleTable"
+	                          :row-style="{ height: '30px' }"
+	                          :cell-style="{ padding: '0px' }" :header-row-style="{ height: '20px' }"
+	                          :header-cell-style="{ padding: '0px' }"
+	                          :show-overflow-tooltip="true"
+	                          highlight-current-row="true"
+	                          @row-click="tableclick"
+	                          @row-dblclick="chukuupdateCompanyFunc"
+	                          style="width: 100%;height: 36vh" border
+	                          :summary-method="getSummaries" tooltip-effect="dark" :data="cktableData" row-key="ID" >
+	                  <el-table-column align="left" sortable label="出库单号" prop="单号"  width="140"/>                
+	                  <el-table-column align="left" sortable label="订单编号" prop="订单编号"  width="140"/>
+	                  <el-table-column align="left" sortable label="款号" prop="款号"  width="180"/>
+	                  <el-table-column align="left" sortable label="数量" prop="数量"  width="105"/>
+	                  <el-table-column align="left" sortable label="出库人员" prop="出库人员"  width="160"/>
+	                  <el-table-column align="left" sortable label="出库时间" prop="出库时间"  width="160"/>
+	                </el-table>
+	              </el-tab-pane> -->
   
-				<el-tab-pane label="退还记录" @click="showTable('退还记录')" name="second">
+				<el-tab-pane label="退还记录" name="second">
 				  <el-table ref="multipleTable"
 							:row-style="{ height: '30px' }":header-cell-style="{ padding: '0px' }"
 							:cell-style="{ padding: '0px' }" :header-row-style="{ height: '20px' }"
@@ -153,48 +159,12 @@
 					<el-table-column align="left" sortable label="退还机台" prop="退还机台"  width="160"/>
 				  </el-table>
 				</el-tab-pane>
+				
 			 </el-tabs>
 		  </div>
 	</el-dialog>
   
-	<!--单号详情记录 -->
-	<el-dialog v-model="details_pickingaddvisible" :before-close="()=> details_pickingaddvisible = false" style="width: 100%; margin: 0% auto; height: 100%;" :title="单据详情"
-	  destroy-on-close>
-		 <div class="dialog-footer" style="bottom: 10px; right: 10px; width: 100%;">
-		   <el-button  type="primary" @click="details_ckth_closeDialog" style="width: 80px;height: 40px;">关 闭</el-button>
-		   <el-button type="danger"  @click="deldetail_delclick" style="width: 80px;height: 40px;"	v-if="del_details=== true" :disabled="details_Selection === '' "  class="bt"   >删除</el-button>
-		 </div>
-		 <br>
-		  <div>
-				  <el-table ref="multipleTable"
-							:row-style="{ height: '30px' }" :header-cell-style="{ padding: '0px' }"
-							:cell-style="{ padding: '0px' }" :header-row-style="{ height: '20px' }"
-							:show-overflow-tooltip="true" highlight-current-row="true"
-							@row-click="tableclick" @row-dblclick="ysupdateCompanyFunc"
-							@selection-change="detailSelectionChange" style="width: 100%;height: 65vh" border
-							:summary-method="getSummaries" tooltip-effect="dark" :data="ruku_detailstableData" row-key="ID" >
-					<el-table-column   align="center" type="selection" width="40"/>
-					<el-table-column align="left"  label="订单编号" prop="订单编号"  width="110"/>
-					<el-table-column align="left"  label="生产款号" prop="生产款号"  width="140"/>
-					<el-table-column align="left"  label="物料名称" prop="物料名称"  width="140"/>
-					<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="100"/>
-					<el-table-column align="left"  label="定额门幅" prop="定额门幅"  width="100"/>
-					<el-table-column align="left"  label="裁床实际用料" prop="裁床实际用料"  width="110"/>
-					<el-table-column align="left"  label="裁床领用面料" prop="裁床领用面料"  width="110"/>
-					<el-table-column align="left"  label="裁床退还数量" prop="裁床退还数量"  width="110"/>
-					<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="100"/>
-					<el-table-column align="left"  label="投料单位" prop="投料单位"  width="90"/>
-					<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="140"/>
-					<el-table-column align="left"  label="客户" prop="客户编号"  width="80"/>
-				  </el-table>
-		  </div>
-	</el-dialog>
+
 	
   </template>
   <script>
@@ -217,7 +187,7 @@
   // 全量引入格式化工具 请按需保留
   import { Layout, LayoutSider, LayoutContent } from '@arco-design/web-vue';
   import {ref, reactive} from 'vue'
-  import {getSpotList,getSpotTab,getInputDetail,outReport,
+  import {getSpotList,getSpotTab,getInputDetail,
   InputOrderSearch,outReport,orderBomList,FabricDetail,gitReceiptNumber,FabricDetaillist,FabricDetaildel} from '@/api/mes/job'
   import { ElMessage, ElMessageBox,ElUpload, ElButton } from 'element-plus';
   import { useUserStore } from '@/pinia/modules/user'
@@ -361,19 +331,19 @@
   });
   const resbom_tableColumns = ref(
 	  [
-		  { label: '批次号', prop: '批次号', width: '90' },
+		  { label: '批次号', prop: '批次号', width: '80' },
 		  { label: '关联号', prop: '关联号', width: '80' },
 		  { label: '物料编号', prop: '物料编号', width: '160' },
-		  { label: '物料名称', prop: '物料名称', width: '100' },
-		  { label: '计划用料', prop: '计划用料', width: '100' },
-		  { label: '计划门幅', prop: 'BOM_计划门幅', width: '100' },
-		  { label: '定额用料', prop: '定额用料', width: '100' },
-		  { label: '定额门幅', prop: 'BOM_定额门幅', width: '100' },
+		  { label: '物料名称', prop: '物料名称', width: '90' },
+		  { label: '计划用料', prop: '计划用料', width: '90' },
+		  { label: '计划门幅', prop: 'BOM_计划门幅', width: '90' },
+		  { label: '定额用料', prop: '定额用料', width: '90' },
+		  { label: '定额门幅', prop: 'BOM_定额门幅', width: '90' },
 		  { label: '实际门幅', prop: '实际门幅', width: '100' },
 		  { label: '领用', prop: '领用', width: '100' },
-		  { label: '入仓总量', prop: '入仓总量', width: '100' },
-		  { label: '库存数量', prop: '库存数量', width: '100' },
-		  { label: '领用数量', prop: '领用数量', width: '100' },
+		  { label: '入仓总量', prop: '入仓总量', width: '90' },
+		  { label: '库存数量', prop: '库存数量', width: '90' },
+		  { label: '出库数量', prop: '出库数量', width: '90' },
 		  { label: '颜色', prop: 'BOM_颜色', width: '100' },
 		  { label: '关联订单', prop: '关联订单', width: '110' },
 		  { label: '单位', prop: '单位', width: '100' },
@@ -446,7 +416,7 @@
 	}
   }
   const scfjfpxsCellClass = ({row, column, rowIndex, columnIndex}) =>{
-	if (column.label === '领用' ||column.label === '实际门幅') {
+	if (column.label === '出库数量') {
 	  return 'background-plan-usage-low';
 	}
   }
@@ -461,7 +431,7 @@
 		  款号: ddhformData.sckh,
 		  物料编码: resbomtableData.value[0]['物料编号'],
 		  物料名称: resbomtableData.value[0]['物料名称'],
-		  number: resbomtableData.value[0]['领用'],
+		  number: resbomtableData.value[0]['出库数量'],
 		  name: "出库",
 		  sys_id: userStore.userInfo.nickName,
 		  receipt_number: danhao.value,
@@ -497,22 +467,16 @@
   //=============出库退还记录==================
   const cktableData = reactive([])
   const thtableData = reactive([])
-  const rukutableData = reactive([])
   
   const pickingaddvisible = ref(false)//弹窗
-  // const detailData = reactive({})
   const add_prinkformData = reactive({});
   //详情记录
   const details_onSubmit = async ()=>{
 	  cktableData.splice(0,cktableData.length);
 	  thtableData.splice(0,thtableData.length);
-	  rukutableData.splice(0,rukutableData.length);
 	  pickingaddvisible.value = true
 	  const FabricDetaillist = await FabricDetail({order:_orderid.value});
-	  const ruku_FabricDetaillist = await FabricDetail({order:_orderid.value,search:''});
 	  console.log(FabricDetaillist)
-	  console.log(ruku_FabricDetaillist)
-	  rukutableData.splice(0,ruku_FabricDetaillist.length,...ruku_FabricDetaillist.data['入库记录']);
 	  cktableData.splice(0,FabricDetaillist.length,...FabricDetaillist.data['出库记录']);
 	  thtableData.splice(0,FabricDetaillist.length,...FabricDetaillist.data['退还记录']);
   }
@@ -525,18 +489,9 @@
   const dh = ref('')
   const type = ref('')
   const details_pickingaddvisible = ref(false)
-  const ruku_detailstableData = reactive([])
   const chuku_detailstableData = reactive([])
   const th_detailstableData = reactive([])
-  const rukuupdateCompanyFunc = async (row)=>{
-	  dh.value = row.单号
-	  type.value = 'rk'
-	  details_pickingaddvisible.value = true
-	  ruku_detailstableData.splice(0,ruku_detailstableData.length);
-	  const FabricDetaillistdata = await FabricDetaillist({order:row.单号,search:''});
-	  ruku_detailstableData.splice(0,FabricDetaillistdata.length,...FabricDetaillistdata.data['入库记录']);
-	  console.log(FabricDetaillistdata)
-  }
+
   const thupdateCompanyFunc = async (row)=>{
 	  dh.value = row.单号
 	  type.value = 'th'
@@ -587,7 +542,6 @@
 		return; // 如果删除失败,直接返回
 	  }
 	  // 重新获取BOM列表数据
-	  ruku_detailstableData.splice(0,ruku_detailstableData.length);
 	  const FabricDetaillistdata = await FabricDetaillist({order:dh.value,search:''});
 	  ruku_detailstableData.splice(0,FabricDetaillistdata.length,...FabricDetaillistdata.data['入库记录']);
 	} catch (error) {