Explorar el Código

Merge branch 'master' of http://git.zthymaoyi.com/gdc/yiliangyiyun-app

# Conflicts:
#	pages/dataReport/costbreakdown.vue
achao hace 2 años
padre
commit
b82830a402
Se han modificado 3 ficheros con 50 adiciones y 40 borrados
  1. 2 2
      config/index.js
  2. 9 8
      pages.json
  3. 39 30
      pages/erp/exWarehousing/exWarehousing.vue

+ 2 - 2
config/index.js

@@ -8,9 +8,9 @@ const dev = {
 	// baseUrlNew: 'http://192.168.110.82:8099/',
 	 // baseUrlNew: 'http://192.168.110.82:8090/',
 	// baseUrlNew: 'http://192.168.110.202:8090/',
-	baseUrlNew: 'http://192.168.110.138:8090/',
+	// baseUrlNew: 'http://192.168.110.138:8090/',
 	// 上传图片的
-	// baseUrlNew: 'https://api2.eliangeyun.com/',
+	baseUrlNew: 'https://api2.eliangeyun.com/',
 	h5Appid: 'wxb66b599f7f61b46f',
 	debug: false
 }

+ 9 - 8
pages.json

@@ -712,15 +712,16 @@
 				// "navigationStyle": "custom"
 			}
 
-		}, {
-			"path": "pages/business/businessNew",
-			"style": {
-				"navigationStyle": "custom",
-				"navigationBarTitleText": "交易",
-				"enablePullDownRefresh": true
-			}
-
 		},
+		// {
+		// 	"path": "pages/business/businessNew",
+		// 	"style": {
+		// 		"navigationStyle": "custom",
+		// 		"navigationBarTitleText": "交易",
+		// 		"enablePullDownRefresh": true
+		// 	}
+
+		// },
 
 		{
 			"path": "pages/release/release",

+ 39 - 30
pages/erp/exWarehousing/exWarehousing.vue

@@ -503,37 +503,35 @@
 							this.detailData.inOutTypeKey = 6
 						}
 					}
-					//查询所有的合同  进行获取车牌号
-					this.$api.doRequest('get', '/warehouseBaseInfo/selectContractNoList', {
-						flag: 5,
-						compId: helper.erpWarehouse.compId,
+					this.$api.doRequest('get', '/contractManagementInfo/getOutContract', {
+						contractNo:this.detailData.contractNo,compId:uni.getStorageSync('pcUserInfo').compId
 					}).then(res => {
+
 						if (res.data.code == 200) {
 							this.contractList = res.data.data
-							for (let i = 0; i < res.data.data.length; i++) {
 								// "MYCGYMHLJ2021102401"
-								if (res.data.data[i].contractNo == this.detailData.contractNo) {
 									if (this.detailData.inOutType == '销售出库') {
-										this.detailData.tips = '买方' + res.data.data[i].buyer
+										this.detailData.tips = '买方' + res.data.data.buyer
 									} else if (this.detailData.inOutType == '移库出库') {
 										this.detailData.tips = '入货库' + this.inOutNoList[0].receiveWarehouse
 									}
-									this.contractType = res.data.data[i].contractType //获取合同类型   用于判断输入车牌号
+									if(this.detailData.inOutType != '移库出库'){
+										this.contractType = res.data.data.contractType //获取合同类型   用于判断输入车牌号
+									}
+									
 									//如果查到该合同
 									// res.data.data[i].deliverType  = !res.data.data[i].deliverType?'1':res.data.data[i].deliverType  
-									if (res.data.data[i].deliverType == '1') { //判断自运1,他运2合同
+									if (res.data.data.deliverType == '1') { //判断自运1,他运2合同
 										that.showCar = true
 									} else {
 										that.showCar = false
 									}
-									if (res.data.data[i].tranCarInfoList) {
-										for(var num = 0 ; num < res.data.data[i].tranCarInfoList.length; num++){
-										   res.data.data[i].tranCarInfoList[num].carNo1 = res.data.data[i].tranCarInfoList[num].carNo + '('+res.data.data[i].tranCarInfoList[num].tranCarNo+')'
+									if (res.data.data.tranCarInfoList) {
+										for(var num = 0 ; num < res.data.data.tranCarInfoList.length; num++){
+										   res.data.data.tranCarInfoList[num].carNo1 = res.data.data.tranCarInfoList[num].carNo + '('+res.data.data.tranCarInfoList[num].tranCarNo+')'
 										}
-										this.carList = res.data.data[i].tranCarInfoList //车牌号下拉列表
+										this.carList = res.data.data.tranCarInfoList //车牌号下拉列表
 									}
-								}
-							}
 							uni.hideLoading()
 						}
 					})
@@ -552,8 +550,14 @@
 				// })
 			},
 			inOutChange(e) {
+				console.log(e)
 				this.detailData.inOutTaskNo = this.inOutNoList[e[0]].inOutTaskNo
 				this.detailData.inOutType  = this.inOutNoList[e[0]].inOutType
+				this.detailData.goodsName = this.inOutNoList[e[0]].goodsName
+				this.detailData.goodsNameKey = this.inOutNoList[e[0]].goodsNameKey
+				this.detailData.grade = this.inOutNoList[e[0]].grade
+				// this.detailData.inOutType = this.inOutNoList[e[0]].inOutType
+				this.weightbills.goodsName = this.inOutNoList[e[0]].goodsName
 				// this.contractType = this.inOutNoList[e[0]].contractType //获取合同类型   用于判断输入车牌号
 				this.detailData.agent = this.inOutNoList[e[0]].agent
 				if (this.inOutNoList[e[0]].contractNo) {
@@ -561,34 +565,36 @@
 				} else {
 					this.detailData.contractNo = this.inOutNoList[e[0]].moveTaskNo
 				}
-				for(let i = 0 ; i<this.contractList.length ; i++){
-					if (this.contractList[i].contractNo == this.detailData.contractNo) {
-						this.contractType = this.contractList[i].contractType //获取合同类型   用于判断输入车牌号
+				this.$api.doRequest('get', '/contractManagementInfo/getOutContract', {
+					contractNo:this.detailData.contractNo,compId:uni.getStorageSync('pcUserInfo').compId
+				}).then(res => {
+					this.contractList=res.data.data
+					if(this.detailData.inOutType != '移库出库'){
+						this.contractType = this.contractList.contractType //获取合同类型   用于判断输入车牌号
 					}
-					
-					if (this.contractList[i].deliverType == '1') { //判断自运1,他运2合同
+					if (this.contractList.deliverType == '1') { //判断自运1,他运2合同
 						this.showCar = true
 					} else {
 						this.showCar = false
 					}
-				}
-				this.detailData.goodsName = this.inOutNoList[e[0]].goodsName
-				this.detailData.goodsNameKey = this.inOutNoList[e[0]].goodsNameKey
-				this.detailData.grade = this.inOutNoList[e[0]].grade
-				this.detailData.inOutType = this.inOutNoList[e[0]].inOutType
-				this.weightbills.goodsName = this.inOutNoList[e[0]].goodsName
+					if (res.data.data.tranCarInfoList) {
+						for(var num = 0 ; num < res.data.data.tranCarInfoList.length; num++){
+						   res.data.data.tranCarInfoList[num].carNo1 = res.data.data.tranCarInfoList[num].carNo + '('+res.data.data.tranCarInfoList[num].tranCarNo+')'
+						}
+						this.carList = res.data.data.tranCarInfoList //车牌号下拉列表
+					}
 				if (this.detailData.inOutType == '销售出库') {
 					this.weightbills.buyer = this.inOutNoList[e[0]].buyer
 					if(uni.getStorageSync('compName1')){
 						this.weightbills.seller = uni.getStorageSync('compName1').company
 					}
-					if (this.detailData.tips = '买方' + this.contractNoList[e[0]].buyer) {
-						this.detailData.tips = '买方' + this.contractNoList[e[0]].buyer +
+					if (this.detailData.tips = '买方' + this.contractList.buyer) {
+						this.detailData.tips = '买方' + this.contractList.buyer +
 							'( ' +
-							this.contractNoList[e[0]].unitContractPrice +
+							this.contractList.unitContractPrice +
 							'元/吨)'
 					} else {
-						this.detailData.tips = '买方' + this.contractNoList[e[0]].buyer
+						this.detailData.tips = '买方' + this.contractList.buyer
 					}
 				} else if (this.detailData.inOutType == '移库出库') {
 					this.weightbills.buyer = this.inOutNoList[e[0]].receiveWarehouse
@@ -597,6 +603,9 @@
 					}
 					this.detailData.tips = '入货库' + this.inOutNoList[e[0]].receiveWarehouse
 				}
+				})
+				
+				
 			},
 			toUpperCase(val) {
 				this.detailData.boxNo = val.detail.value.toUpperCase()