695593266@qq.com před 7 měsíci
rodič
revize
aaf364fcb6

+ 1 - 1
src/views/byProduct/components/byProduct-search.vue

@@ -31,7 +31,7 @@
 
       <el-col v-bind="styleResponsive ? { lg: 4, md: 10 } : { span: 4 }">
         <el-form-item label="工序名称:">
-          <el-select size="mini" v-model="where.taskId" filterable>
+          <el-select size="mini" v-model="where.taskId" filterable clearable>
             <el-option
               v-for="(item, index) in produceTaskList"
               :key="index"

+ 1 - 0
src/views/byProduct/index.vue

@@ -16,6 +16,7 @@
         @update:selection="handleSelectionChange"
         :height="tableHeight"
         @fullscreen-change="fullscreenChange"
+        :pageSize="20"
       >
         <template v-slot:toolbar>
           <el-button type="primary" size="mini" @click="handByProd"

+ 6 - 1
src/views/produce/components/feeding/details.vue

@@ -30,7 +30,11 @@
         </div>
 
         <div v-for="(it, idx) in item.orderInfoList" :key="idx">
-          <workOrderBom :item="it" :isDetails="true" :isReportWork="false"></workOrderBom>
+          <workOrderBom
+            :item="it"
+            :isDetails="true"
+            :isReportWork="false"
+          ></workOrderBom>
 
           <paramBom
             v-if="it.paramDetailList.length != 0"
@@ -181,6 +185,7 @@
         handler(obj) {
           console.log(obj, '1131313');
           if (obj && obj.taskId != -2) {
+            console.log(obj, '777777');
             this.getList(obj.taskId);
           }
         },

+ 61 - 38
src/views/produce/components/feeding/index.vue

@@ -821,49 +821,72 @@
           background: 'rgba(0, 0, 0, 0.7)'
         });
 
+        let newList = [];
         for (let item of this.List) {
-          await checkRepeatFeed({
+          newList.push({
             currentTaskDiagram: item.currentTaskDiagram,
             workOrderId: item.workOrderId
-          }).then((res) => {
-            if (res.data == 0) {
-              this.feedReport();
-            } else {
-              this.$confirm('已经有投料是否继续重复投料?', '提示', {
-                confirmButtonText: '确定',
-                cancelButtonText: '取消',
-                type: 'warning'
-              })
-                .then(() => {
-                  this.feedReport();
-                })
-                .catch(() => {
-                  this.loading.close();
-                });
-            }
-            // const totalNum = Number(item.formingNum);
-            // const reportNum = this.add(
-            //   item.workReportInfo.notFormedNum,
-            //   item.workReportInfo.formedNum
-            // );
-            // const totalReportNum = this.add(reportNum, Number(res));
-            // if (totalReportNum > totalNum) {
-            //   this.$confirm('报工数量大于生产数量, 是否继续报工?', '提示', {
-            //     confirmButtonText: '确定',
-            //     cancelButtonText: '取消',
-            //     type: 'warning'
-            //   })
-            //     .then(() => {
-            //       this.feedReport();
-            //     })
-            //     .catch(() => {
-            //       this.loading.close();
-            //     });
-            // } else {
-            //   this.feedReport();
-            // }
           });
         }
+
+        await checkRepeatFeed(newList).then((res) => {
+          if (res.data.length != 0) {
+            this.checkFeed(res.data);
+          }
+        });
+
+        // for (let item of this.List) {
+        //   await checkRepeatFeed({
+        //     currentTaskDiagram: item.currentTaskDiagram,
+        //     workOrderId: item.workOrderId
+        //   }).then((res) => {
+        //     if (res.data == 0) {
+        //       // this.feedReport();
+        //     } else {
+        //       this.$confirm('已经有投料是否继续重复投料?', '提示', {
+        //         confirmButtonText: '确定',
+        //         cancelButtonText: '取消',
+        //         type: 'warning'
+        //       })
+        //         .then(() => {
+        //           // this.feedReport();
+        //         })
+        //         .catch(() => {
+        //           this.loading.close();
+        //         });
+        //     }
+        //   });
+        // }
+      },
+
+      checkFeed(list) {
+        let wordCodeList = [];
+        for (let item of list) {
+          if (item.feedFormed != '0') {
+            wordCodeList.push(item.workOrderCode);
+          }
+        }
+
+        if (wordCodeList.length != 0) {
+          this.$confirm(
+            `工单号${wordCodeList.join(',')}已有投料,是否继续重复投料?`,
+            '提示',
+            {
+              confirmButtonText: '确定',
+              cancelButtonText: '取消',
+              type: 'warning',
+              center: true
+            }
+          )
+            .then(() => {
+              this.feedReport();
+            })
+            .catch(() => {
+              this.loading.close();
+            });
+        } else {
+          this.feedReport();
+        }
       },
 
       feedReport() {

+ 65 - 85
src/views/produce/components/jobBooking/index.vue

@@ -1608,6 +1608,7 @@
               if (!this.List[i].productRecycleList[j].warehouseId) {
                 const isRecycle = await this.checkRecycle();
                 if (!isRecycle) {
+                  this.loading.close();
                   return false;
                 }
               }
@@ -1704,97 +1705,46 @@
           return;
         }
 
+        let newList = [];
         for (let item of this.List) {
-          // if (item.currentTaskDiagram.isFirstTask == '1') {
-          await checkReportNumber({
+          newList.push({
             currentTaskDiagram: item.currentTaskDiagram,
             workOrderId: item.workOrderId
-          }).then((res) => {
-            const totalNum = Number(item.formingNum);
-            const reportNum = this.add(
-              item.workReportInfo.notFormedNum,
-              item.workReportInfo.formedNum
-            );
-            const totalReportNum = this.add(reportNum, Number(res));
-            if (totalReportNum > totalNum) {
-              this.$confirm('报工数量大于生产数量, 是否继续报工?', '提示', {
-                confirmButtonText: '确定',
-                cancelButtonText: '取消',
-                type: 'warning'
-              })
-                .then(() => {
-                  // this.$message({
-                  //   type: 'success',
-                  //   message: '删除成功!'
-                  // });
-                  // return true;
-                  // this.loadingBtn = true;
-                  // jobSave(this.List)
-                  //   .then((res) => {
-                  //     this.loadingBtn = false;
-                  //     this.loading.close();
-                  //     this.$message.success('报工成功');
-                  //     this.checked = false;
-                  //     this.executorIdList = [];
-                  //     this.teamId = '';
-                  //     this.getList(this.idsList);
-                  //     this.$emit('jobSuccess', 'Success');
-                  //   })
-                  //   .catch(() => {
-                  //     this.loadingBtn = false;
-                  //     this.loading.close();
-                  //   });
-                  this.jobBookReport();
-                })
-                .catch(() => {
-                  this.loading.close();
-                  // this.$message({
-                  //   type: 'info',
-                  //   message: '已取消删除'
-                  // });
-                  // return false;
-                });
-            } else {
-              this.jobBookReport();
-              // this.loadingBtn = true;
-              // jobSave(this.List)
-              //   .then((res) => {
-              //     this.loadingBtn = false;
-              //     this.loading.close();
-              //     this.$message.success('报工成功');
-              //     this.checked = false;
-              //     this.executorIdList = [];
-              //     this.teamId = '';
-              //     this.getList(this.idsList);
-              //     this.$emit('jobSuccess', 'Success');
-              //   })
-              //   .catch(() => {
-              //     this.loadingBtn = false;
-              //     this.loading.close();
-              //   });
-            }
           });
-          // } else {
-          //   this.jobBookReport();
-          //   // this.loadingBtn = true;
-          //   // jobSave(this.List)
-          //   //   .then((res) => {
-          //   //     this.loadingBtn = false;
-          //   //     this.loading.close();
-          //   //     this.$message.success('报工成功');
-          //   //     this.checked = false;
-          //   //     this.executorIdList = [];
-          //   //     this.teamId = '';
-          //   //     this.getList(this.idsList);
-          //   //     this.$emit('jobSuccess', 'Success');
-          //   //   })
-          //   //   .catch(() => {
-          //   //     this.loadingBtn = false;
-          //   //     this.loading.close();
-          //   //   });
-          // }
+          // await checkReportNumber({
+          //   currentTaskDiagram: item.currentTaskDiagram,
+          //   workOrderId: item.workOrderId
+          // }).then((res) => {
+          //   const totalNum = Number(item.formingNum);
+          //   const reportNum = this.add(
+          //     item.workReportInfo.notFormedNum,
+          //     item.workReportInfo.formedNum
+          //   );
+          //   const totalReportNum = this.add(reportNum, Number(res));
+          //   if (totalReportNum > totalNum) {
+          //     this.$confirm('报工数量大于生产数量, 是否继续报工?', '提示', {
+          //       confirmButtonText: '确定',
+          //       cancelButtonText: '取消',
+          //       type: 'warning'
+          //     })
+          //       .then(() => {
+          //         this.jobBookReport();
+          //       })
+          //       .catch(() => {
+          //         this.loading.close();
+          //       });
+          //   } else {
+          //     this.jobBookReport();
+          //   }
+          // });
         }
 
+        await checkReportNumber(newList).then((res) => {
+          if (res.length != 0) {
+            this.checkJobBook(res);
+          }
+        });
+
         // this.loadingBtn = true;
         // jobSave(this.List)
         //   .then((res) => {
@@ -1818,6 +1768,36 @@
         // });
       },
 
+      checkJobBook(list) {
+        let wordCodeList = [];
+        for (let item of list) {
+          if (item.reportFormed != '0') {
+            wordCodeList.push(item.workOrderCode);
+          }
+        }
+
+        if (wordCodeList.length != 0) {
+          this.$confirm(
+            `工单号${wordCodeList.join(',')}已有报工,是否继续重复报工?`,
+            '提示',
+            {
+              confirmButtonText: '确定',
+              cancelButtonText: '取消',
+              type: 'warning',
+              center: true
+            }
+          )
+            .then(() => {
+              this.jobBookReport();
+            })
+            .catch(() => {
+              this.loading.close();
+            });
+        } else {
+          this.jobBookReport();
+        }
+      },
+
       jobBookReport() {
         this.loadingBtn = true;
         jobSave(this.List)

+ 5 - 5
src/views/produce/components/warehousing/index.vue

@@ -735,11 +735,11 @@
           .finally(() => {
             this.isLoad = true;
 
-            if (this.clientEnvironmentId == 3) {
-              this.getTgWarehouse();
-            } else {
-              this.getQtWarehouse();
-            }
+            // if (this.clientEnvironmentId == 3) {
+            //   this.getTgWarehouse();
+            // } else {
+            //   this.getQtWarehouse();
+            // }
           });
       },
 

+ 0 - 4
src/views/unacceptedProduct/index.vue

@@ -347,8 +347,6 @@
           });
           this.disposeList = list;
         }
-
-        console.log(this.disposeList, 'disposeList');
       },
       async getQualityList(code) {
         let res = await getByCode(code);
@@ -359,8 +357,6 @@
           });
           this.qualityList = list;
         }
-
-        console.log(this.qualityList, 'qualityList');
       }
     }
   };

+ 18 - 0
src/views/warehousing/index.vue

@@ -158,6 +158,7 @@
             showOverflowTooltip: true
           },
           {
+            prop: 'totalCount',
             slot: 'totalCount',
             label: '总数量',
             align: 'center',
@@ -165,6 +166,7 @@
           },
 
           {
+            prop: 'totalPackage',
             slot: 'totalPackage',
             label: '总包装',
             align: 'center',
@@ -172,11 +174,26 @@
           },
 
           {
+            prop: 'totalWeight',
             slot: 'totalWeight',
             label: '总重量',
             align: 'center',
             showOverflowTooltip: true
           },
+
+          {
+            prop: 'produceRoutingName',
+            label: '工艺路线',
+            align: 'center',
+            showOverflowTooltip: true
+          },
+          {
+            prop: 'salesCode',
+            label: '销售订单编码',
+            align: 'center',
+            width: 110,
+            showOverflowTooltip: true
+          },
           {
             prop: 'type',
             label: '入库类型',
@@ -214,6 +231,7 @@
             minWidth: 110
           },
           {
+            prop: 'approvalStatus',
             slot: 'approvalStatus',
             label: '状态',
             align: 'center',

+ 2 - 2
vue.config.js

@@ -33,11 +33,11 @@ module.exports = {
       // 当我们的本地的请求 有/api的时候,就会代理我们的请求地址向另外一个服务器发出请求
       '/api': {
         // target: 'http://124.71.68.31:50001',
-        // target: 'http://192.168.1.125:18086',
+        target: 'http://192.168.1.125:18086',
         // target: 'http://192.168.1.251:18086',
         // target: 'http://192.168.1.251:18086',
         // target: 'http://192.168.1.125:18086',
-        target: 'http://192.168.1.116:18086', // 赵沙金
+        // target: 'http://192.168.1.116:18086', // 赵沙金
         // target: 'http://192.168.1.251:18086', // 开发环境
         // target: 'http://192.168.1.103:18086',192.168.1.116
         // target: 'http://192.168.1.144:18086',