浏览代码

Merge branch 'dev' of http://47.100.3.209:3000/gdc/yiliangyiyun-pc into dev

# Conflicts:
#	src/views/houseSelfCollect/inspectionManagementNew.vue
zhongtianhaoyuan 3 年之前
父节点
当前提交
f22eccef76

+ 66 - 3
src/views/houseSelfCollect/inspectionManagementNew.vue

@@ -781,7 +781,21 @@
                     titleNo:'',
                     titleNoOther:'',
                   }
-                })
+                  if(this.serviceManagementType==3){
+                    var count=''
+                    if(this.warehouseCount<10){
+                      count='000'+(this.warehouseCount+1)
+                    }
+                    if(this.warehouseCount<100&&this.warehouseCount>=10){
+                      count='00'+(this.warehouseCount+1)
+                    }
+                    if(this.warehouseCount<1000&&this.warehouseCount>=100){
+                      count='0'+(this.warehouseCount+1)
+                    }
+                    this.deptBudgetList.qualityNo='SGRK'+this.getTime()+this.warehouseNo+count
+                  }
+                  
+              })
             })
             this.dialogTableVisible = true;
           }
@@ -853,6 +867,19 @@
                 titleNo:'',
                 titleNoOther:'',
               }
+               if(this.serviceManagementType==3){
+                    var count=''
+                    if(this.warehouseCount<10){
+                      count='000'+(this.warehouseCount+1)
+                    }
+                    if(this.warehouseCount<100&&this.warehouseCount>=10){
+                      count='00'+(this.warehouseCount+1)
+                    }
+                    if(this.warehouseCount<1000&&this.warehouseCount>=100){
+                      count='0'+(this.warehouseCount+1)
+                    }
+                    this.deptBudgetList.qualityNo='SGRK'+this.getTime()+this.warehouseNo+count
+                  }
               this.getList()
             })
         }
@@ -998,6 +1025,19 @@
           titleNo:'',
           titleNoOther:'',
         }
+        if(this.serviceManagementType==3){
+          var count=''
+          if(this.warehouseCount<10){
+            count='000'+(this.warehouseCount+1)
+          }
+          if(this.warehouseCount<100&&this.warehouseCount>=10){
+            count='00'+(this.warehouseCount+1)
+          }
+           if(this.warehouseCount<1000&&this.warehouseCount>=100){
+            count='0'+(this.warehouseCount+1)
+          }
+          this.deptBudgetList.qualityNo='SGRK'+this.getTime()+this.warehouseNo+count
+        }
       },
       statustypechangelist(status){
         this.statusType=status
@@ -1132,6 +1172,24 @@
             })
             return
         }
+        }
+         if(this.serviceManagementType==3){
+          
+          if (!this.deptBudgetList.customerName) {
+            this.$message({
+              message: '客户不能为空',
+              type: 'warning',
+            })
+            return
+          }
+          
+          if (!this.outType) {
+            this.$message({
+              message: '请选择运输方式!',
+              type: 'warning',
+            })
+            return
+          }
         }
         this.deptBudgetList.warehouseInOutDetail.grade=this.deptBudgetList.grade
         if (!this.deptBudgetList.grade) {
@@ -1639,6 +1697,7 @@
                       if (this.reader) {
                         this.reader.cancel()
                       }
+                      this.warehouseCount+=1
                       this.$message.success('添加成功')
                       this.getList()
                       // this.$router.push({
@@ -1657,14 +1716,18 @@
                               // this.printData.qrCodeUrl = res
                               // })
                         this.deptBudgetList = response2
-                        this.deptBudgetList.customerName=this.customerName
-                        this.deptBudgetList.customerPhone=this.customerPhone
+                        if(this.serviceManagementType==1){
+                          this.deptBudgetList.customerName=this.customerName
+                          this.deptBudgetList.customerPhone=this.customerPhone
+                        }
                         if (response.compName == '黑龙江秋收有限公司') {
                     		 this.deptBudgetList.compName = '黑龙江中天昊元贸易有限公司'
                     			}
                       })
                     })
                     .catch((response) => {
+                      console.log(response)
+                      // this.$message.warning(response)
                     })
                     
                     // this.$message.success('保存成功')

+ 39 - 16
src/views/outboundManagement/weighingManagementNew.vue

@@ -237,8 +237,8 @@
 					<div>
 						<el-button v-if='tpyeNo == 1' @click='add' type="primary">新增</el-button>
             			<el-button v-if='tpyeNo == 1' @click='deletelist' type="danger">删除</el-button>
-						<el-button v-if='tpyeNo == 2' @click='statustypechangelist(1)' :type="statusType==1?'primary':''">未称毛重</el-button>
-          				<el-button v-if='tpyeNo == 2' @click='statustypechangelist(2)' :type="statusType==2?'primary':''">已称毛重</el-button>
+						<el-button v-if='tpyeNo == 2' @click='statustypechangelist(5)' :type="statusType==5?'primary':''">未称毛重</el-button>
+          				<el-button v-if='tpyeNo == 2' @click='statustypechangelist(3)' :type="statusType==3?'primary':''">已称毛重</el-button>
 					</div>
 					<div><el-button @click='record' type="primary">记录</el-button></div>
 				</div>
@@ -743,6 +743,10 @@
 			.then(() => {
 				this.weighingList.inOutFlag = 1
               	this.weighingList.statusFlag = 3
+				this.weighingList.grossWeight=this.weighingList.grossWeight/1000
+				this.weighingList.tare=this.weighingList.tare/1000
+				this.weighingList.netWeight=this.weighingList.netWeight/1000
+				this.weighingList.buckleMiscellaneous=this.weighingList.buckleMiscellaneous/1000
 				if (this.tpyeNo == 1) {
 					this.weighingList.relationId = this.relationId
 					this.weighingList.warehouseId = this.warehouseId
@@ -763,6 +767,10 @@
 								message: '提交成功',
 							})
 							this.getList()
+							this.weighingList.grossWeight=this.weighingList.grossWeight*1000
+							this.weighingList.tare=this.weighingList.tare*1000
+							this.weighingList.netWeight=this.weighingList.netWeight*1000
+							this.weighingList.buckleMiscellaneous=this.weighingList.buckleMiscellaneous*1000
 								this.inspect=JSON.parse(JSON.stringify(this.weighingList))
 								this.isShowPrint=true
 								this.weighingList= {
@@ -794,20 +802,29 @@
 						})
 						.catch((response) => {})
 					}else{
+						this.weighingList.relationId = this.relationId
+						this.weighingList.warehouseId = this.warehouseId
+						this.weighingList.baseId=this.warehouseId
+						console.log(this.weighingList)
 						tareAdd(this.weighingList)
 						.toPromise()
 						.then((response) => {
-						this.$notify.success({
-							title: '成功',
-							message: '提交成功',
-						})
+						
 						addstorageputList(this.weighingList)
 						.toPromise()
 						.then((response) => {
 							if (this.reader) {
 								this.reader.cancel()
 							}
+							this.$notify.success({
+							title: '成功',
+							message: '提交成功',
+						})
 							this.isShowPrint=true
+							this.weighingList.grossWeight=this.weighingList.grossWeight*1000
+							this.weighingList.tare=this.weighingList.tare*1000
+							this.weighingList.netWeight=this.weighingList.netWeight*1000
+							this.weighingList.buckleMiscellaneous=this.weighingList.buckleMiscellaneous*1000
 							this.inspect=JSON.parse(JSON.stringify(this.weighingList))
 							this.weighingList= {
 								grossWeight: 0,
@@ -845,20 +862,26 @@
 					grossWeight(this.weighingList)
 						.toPromise()
 						.then((response) => {
-							this.$notify.success({
-								title: '成功',
-								message: '提交成功',
-							})
+							
 							addstorageputList(this.weighingList)
 							.toPromise()
 							.then((response) => {
 								if (this.reader) {
 									this.reader.cancel()
 								}
+								this.$notify.success({
+								title: '成功',
+								message: '提交成功',
+							})
+							this.weighingList.grossWeight=this.weighingList.grossWeight*1000
+							this.weighingList.tare=this.weighingList.tare*1000
+							this.weighingList.netWeight=this.weighingList.netWeight*1000
+							this.weighingList.buckleMiscellaneous=this.weighingList.buckleMiscellaneous*1000
 								this.inspect=JSON.parse(JSON.stringify(this.weighingList))
 								this.isShowPrint=true
 								this.weighingList= {
 									grossWeight: 0,
+									selfLoading:0,
 									tare: 0,
 									tips:'',
 										// contractNo:'',
@@ -891,12 +914,12 @@
 		},
 		carNoTypeChange() {
 			this.carjudge = !this.carjudge
-			if (!this.carjudge) {
-			this.deptBudgetList.selfLoading = '0'
-			this.carChange1 = '手动填写'
-			} else {
-			this.deptBudgetList.selfLoading = '1'
+			if (this.carjudge) {
+			this.weighingList.selfLoading = '1'
 			this.carChange1 = '识别下拉'
+			} else {
+			this.weighingList.selfLoading = '0'
+			this.carChange1 = '手动填写'
 			}
 		},
 		tabClick(val){
@@ -1192,7 +1215,7 @@
 					for (let i = 0; i < response.length; i++) {
 						if (_wareHouse && response[i].warehouseName == _wareHouse.value) {
 							this.warehouseName = response[i].warehouseName
-							this.warehouseId = response[i].warehouseId
+							this.warehouseId = response[i].id
 							this.positionInfos=response[i].positionInfos
 							this.warehouseCount = response[i].count
 							this.warehouseNo = response[i].commonWarehouseNo

+ 0 - 4
src/views/warehouse/warehouseManagementRecord.vue

@@ -677,10 +677,6 @@
 				
 			// },
       batchPrint() {
-<<<<<<< HEAD
-      
-=======
->>>>>>> origin
         this.printList = []
         if (this.modification.length == 0) {
           this.$message.error("请勾选要打印的条目!")