Forráskód Böngészése

合并解决冲突

gjy 1 éve
szülő
commit
0163a3e67c

+ 4 - 4
config/index.js

@@ -1,13 +1,13 @@
 const dev = {
 	baseUrl: 'https://www.zthymaoyi.com',
-	// baseUrl: 'http://localhost:8080/',
+	// baseUrl: 'http://localhost:8090/',
 	// baseUrlNew: 'http://192.168.110.67:9100/',
-	// baseUrlNew: 'http://192.168.1.118:8090/',
+	// baseUrlNew: 'http://192.168.110.9:8099/',
 	// baseUrlNew: 'http://192.168.110.9:9888/',
 	// baseUrlNew: 'http://192.168.110.138:8090/',
 	// baseUrlNew: 'http://192.168.110.67:9888/',
-	// baseUrlNew: 'http://192.168.110.9:9888/',
-	baseUrlNew: 'http://192.168.110.82:8090/',
+	baseUrlNew: 'http://192.168.110.82:8090/',  
+	// baseUrlNew: 'http://192.168.110.82:8090/',
 	// baseUrlNew: 'http://192.168.110.82:8090/',
 	// baseUrlNew: 'http://192.168.110.202:8090/',
 	// baseUrlNew: 'http://192.168.110.138:8090/',

+ 2 - 2
manifest.json

@@ -2,8 +2,8 @@
     "name" : "易粮易运",
     "appid" : "__UNI__7297DA2",
     "description" : "易粮易运——为天下粮食人服务的App",
-    "versionName" : "2.1.173",
-    "versionCode" : 21173,
+    "versionName" : "2.1.176",
+    "versionCode" : 21176,
     "transformPx" : false,
     /* SDK配置 */
     "quickapp" : {},

+ 19 - 4
pages/erp/exWarehousing/exWarehousing.vue

@@ -18,14 +18,19 @@
 				<input v-model='detailData.contractNo' style="width: 200px;" class="right-bottom" placeholder="暂未获取到合同编号" disabled=""></input>
 			</view>
 			<view class="row">
-				<view class="left">提示</view>
-				<view class="right">{{detailData.tips}}</view>
+				<view class="left" style="width: 100px;">提示</view>
+				<view class="right" style="text-align: right;">{{detailData.tips}}</view>
 			</view>
 			<view class="row">
 				<view class="left">货名</view>
 				<view class="right">{{detailData.goodsName ? detailData.goodsName : "选择合同,自动获取"}}
 				</view>
 			</view>
+			<view class="row row-bottom" v-if="detailData.inOutType == '销售出库'">
+				<view class="left">价格(元/吨)</view>
+				<input type="digit"  v-model='detailData.cost' class="right-bottom"
+					placeholder="输入价格"></input>
+			</view>
 			<!-- <view class="row">
 				<view class="left">类型</view>
 				<view @click='show1=true'>{{detailData.type}}</view>
@@ -111,7 +116,7 @@
 				<view @click='slectCarNo' v-if="isPC">{{detailData.carNo}}</view> -->
 				<view class="left">车牌号</view>
 				<!-- 他运合同车牌号输入 -->
-				<input v-model='detailData.carNo' @click.stop="handleShowKeyboard":disabled="true"  class="right-bottom" placeholder="请输入车牌号" v-if="!showCar"></input>
+				<!-- <input v-model='detailData.carNo' @click.stop="handleShowKeyboard":disabled="true"  class="right-bottom" placeholder="请输入车牌号" v-if="!showCar"></input> -->
 				<view v-show="showCar" @click="carno = true" v-if="detailData.inOutType == '移库出库'|| (showCar&&contractType=='1')"><!-- showCar = true时为自运  carjudge为切换状态 contractType==1 为销售合同-->
 					<view v-if="detailData.tranCarNo">
 						{{detailData.carNo?detailData.carNo +'('+detailData.tranCarNo+')':"请选择车牌号"}}
@@ -329,6 +334,7 @@
 					grossWeight: "",
 					tare: "",
 					tips: '',
+					cost:'',
 					carNo:'',
 					selfLoading:"0",
 					goodsName:"",
@@ -512,6 +518,9 @@
 								// "MYCGYMHLJ2021102401"
 									if (this.detailData.inOutType == '销售出库') {
 										this.detailData.tips = '买方' + res.data.data.buyer
+										if(res.data.data.unitContractPrice){
+											this.detailData.cost=res.data.data.unitContractPrice
+										}
 									} else if (this.detailData.inOutType == '移库出库') {
 										this.detailData.tips = '入货库' + this.inOutNoList[0].receiveWarehouse
 									}
@@ -588,13 +597,15 @@
 					if(uni.getStorageSync('compName1')){
 						this.weightbills.seller = uni.getStorageSync('compName1').company
 					}
-					if (this.detailData.tips = '买方' + this.contractList.buyer) {
+					if (this.contractList.unitContractPrice) {
 						this.detailData.tips = '买方' + this.contractList.buyer +
 							'( ' +
 							this.contractList.unitContractPrice +
 							'元/吨)'
+						this.detailData.cost=this.contractList.unitContractPrice
 					} else {
 						this.detailData.tips = '买方' + this.contractList.buyer
+						this.detailData.cost=''
 					}
 				} else if (this.detailData.inOutType == '移库出库') {
 					this.weightbills.buyer = this.inOutNoList[e[0]].receiveWarehouse
@@ -833,6 +844,10 @@
 					this.$api.msg('品级不能为空')
 					return
 				}
+				if (!this.detailData.cost && this.detailData.inOutType == '销售出库'&& num == 2) {
+					this.$api.msg('价格不能为空')
+					return
+				}
 				if (this.detailData.agent == "请选择经办人") {
 					this.$api.msg('经办人不能为空')
 					return

+ 1 - 1
pages/erp/receivingfeedback/details.vue

@@ -251,7 +251,7 @@
 					<view class="left">卸车日期</view>
 					<view>
 						<view v-if="item.status == '未装车' || item.status == '已送达'">{{item.receiveDateEnd}}</view>
-						<view @click='train(index)'>{{item.receiveDateEnd?item.receiveDateEnd:'请选择日期'}}</view>
+						<view v-else @click='train(index)'>{{item.receiveDateEnd?item.receiveDateEnd:'请选择日期'}}</view>
 						<u-picker v-model="item.show2" mode="time"  @cancel='datecancel()' @confirm='dateChange2($event,index)' :params="params">
 						</u-picker>
 					</view>

+ 325 - 597
pages/erpbusiness/add_quality_testing.vue

@@ -315,9 +315,8 @@
 							name="input" type="digit"></input> -->
 					</view>
 				</view>
-				<view class="c-row ">
-					<view v-show='gridList.goodsName!="大豆"' class="title">容重(克/升)</view>
-					<view v-show='gridList.goodsName=="大豆"' class="title">蛋白</view>
+				<view class="c-row" v-if="gridList.goodsName!='大豆'">
+					<view class="title">容重(克/升)</view>
 					<view class="con-list">
 						<MyNumberInput :myvalue="gridList.bulkDensity" :Isedit="Isedit" :IsShow="MykeywordShow"
 							:myevent="'bulkDensity'" @setValue="mykeywordset" v-if="InputEvent=='bulkDensity'"
@@ -327,7 +326,18 @@
 						<!-- 	<input v-model='gridList.bulkDensity' placeholder="请输入容重" name="input" type="digit" @input="obtainPrice"></input> -->
 					</view>
 				</view>
-				<view class="c-row ">
+				<view class="c-row" v-else>
+					<view class="title">蛋白</view>
+					<view class="con-list">
+						<MyNumberInput :myvalue="gridList.protein" :Isedit="Isedit" :IsShow="MykeywordShow"
+							:myevent="'protein'" @setValue="mykeywordset" v-if="InputEvent=='protein'"
+							@Cancelword="Cancelword" @goNext="goNext('protein')"></MyNumberInput>
+						<input v-else v-model='gridList.protein' placeholder="请输入蛋白"
+							@click="SetInputKey('protein')" name="input" type="digit" @input="obtainPrice"></input>
+					</view>
+				</view>
+				
+				<view class="c-row " v-if="gridList.goodsName != '大豆'">
 					<view class="title">不完善粒(%)</view>
 					<view class="con-list">
 						<MyNumberInput :myvalue="gridList.imperfectGrain" :Isedit="Isedit" :IsShow="MykeywordShow"
@@ -337,6 +347,16 @@
 							placeholder="请输入不完整粒占比" name="input" type="digit"></input>
 					</view>
 				</view>
+				<view class="c-row" v-else>
+					<view class="title">完整粒率(%)</view>
+					<view class="con-list">
+						<MyNumberInput :myvalue="gridList.completeGrain" :Isedit="Isedit" :IsShow="MykeywordShow"
+							:myevent="'completeGrain'" @setValue="mykeywordset" v-if="InputEvent=='completeGrain'"
+							@Cancelword="Cancelword" @goNext="goNext('impurity')"></MyNumberInput>
+						<input v-else v-model='gridList.completeGrain' 
+							placeholder="请输入完善粒率占比" name="input" type="digit"></input>
+					</view>
+				</view>
 				<view class="c-row ">
 					<view class="title">杂质(%)</view>
 					<view class="con-list">
@@ -367,8 +387,37 @@
 							placeholder="请输入热损伤占比" name="input" type="digit"></input>
 					</view>
 				</view>
-
-
+				<view class="c-row" v-if="gridList.goodsName == '大豆'">
+					<view class="title">转基因</view>
+					<view class="con-list">
+						<MyNumberInput :myvalue="gridList.transgene" :Isedit="Isedit" :IsShow="MykeywordShow"
+							:myevent="'transgene'" @setValue="mykeywordset" v-if="InputEvent=='transgene'"
+							@Cancelword="Cancelword" @goNext="goNext('transgene')"></MyNumberInput>
+							<view @click="transgeneShow=true">
+								{{gridList.transgene}}
+							</view>
+							<!-- 转基因 -->
+							<u-picker :range="transgeneList" range-key="value" @confirm='transgeneClick($event)' v-model="transgeneShow"
+								mode="selector">
+							</u-picker>
+					</view>
+				</view>
+				<view class="c-row" v-if="gridList.goodsName == '大豆'">
+					<view class="title">色泽/气味</view>
+					<view class="con-list">
+						<MyNumberInput :myvalue="gridList.colorLustre" :Isedit="Isedit" :IsShow="MykeywordShow"
+							:myevent="'colorLustre'" @setValue="mykeywordset" v-if="InputEvent=='colorLustre'"
+							@Cancelword="Cancelword" @goNext="goNext('colorLustre')"></MyNumberInput>
+						<!-- <input v-else v-model='gridList.colorLustre' @click="SetInputKey('colorLustre')"
+							placeholder="请选择色泽/气味是否正常" name="input" type="digit"></input> -->
+							<div @click="colorLustreShow = true">{{gridList.colorLustre}}</div>
+							
+							<!-- 转基因 -->
+							<u-picker :range="colorLustreList" range-key="value" @confirm='colorLustreClick($event)' v-model="colorLustreShow"
+								mode="selector">
+							</u-picker>
+					</view>
+				</view>
 				<view v-show="utils.getCurrectRoles('acquisitionQuality.initial')&&typevalue==3" class="c-row">
 					<view class="title">水分增价(元/吨)</view>
 					<view class="con-list">
@@ -457,11 +506,13 @@
 				<view class="but_css" @click="close">返回</view>
 			</view>
 		</u-popup>
+		
 	</view>
 </template>
 
 <script>
-	const Equ_List = ['waterContent', 'bulkDensity', 'imperfectGrain', 'impurity', 'mildewGrain', 'jiaorenli'];
+	var that;
+	const Equ_List = ['waterContent', 'bulkDensity', 'imperfectGrain', 'impurity', 'mildewGrain', 'jiaorenli','protein','completeGrain'];
 	import dragButton from "@/components/drag-button/drag-button.vue";
 	import keyboard from "@/components/master-keyboard/master-keyboard.vue";
 	import MyNumberInput from "@/components/MyNumberInput.vue";
@@ -479,7 +530,9 @@
 		},
 		data() {
 			return {
-				redstatus:false,
+				isQY: false,
+				isZJ: false,
+				redstatus: false,
 				isShowPrint: false,
 				isShowAlert: false,
 				disabled1: false,
@@ -523,7 +576,7 @@
 					name: '他运',
 					value: '他运'
 				}],
-				printId:'',
+				printId: '',
 				typevalue: '3',
 				coverTransform: 'translateY(0px)',
 				coverTransition: '0s',
@@ -549,7 +602,6 @@
 				username: "请更改昵称",
 				contractFlag: 10,
 				gridList: {
-
 					outType: '汽运',
 					natureOfGrainPurchase: '贸易粮',
 					type: '',
@@ -744,7 +796,11 @@
 				],
 				cangid: '',
 
-				inType: "" //入库类型
+				inType: "" ,//入库类型
+				transgeneShow:false,
+				transgeneList:[{value:'非转基因'},{value:'转基因'}],
+				colorLustreShow : false,
+				colorLustreList:[{value:'正常'},{value:'异常'}]
 			}
 		},
 		// #ifndef MP
@@ -778,6 +834,8 @@
 			}
 		},
 		onLoad(options) {
+			that = this
+			console.log(that)
 			console.log(this.cangid)
 			this.commonWarehouseNo = options.commonWarehouseNo
 			this.warehouseCount = Number(options.warehouseCount) + 1
@@ -851,9 +909,11 @@
 			console.log(this.gridList)
 			this.gridListInit = this.gridList
 		},
-		onShow() {
-			if (this.utils.getCurrectRoles('acquisitionQuality.initial') && !this.utils.getCurrectRoles(
-					'acquisitionQuality.qview')) {
+		async onShow() {
+			this.isQY = this.utils.getCurrectRoles('acquisitionQuality.qview')
+			this.isZJ = this.utils.getCurrectRoles('acquisitionQuality.initial')
+
+			if (this.isZJ && !this.isQY) {
 				this.typevalue = '1'
 				this.contractFlag = 7
 			} else {
@@ -870,10 +930,11 @@
 				this.flag = 2
 
 			}
-			this.$api.doRequest('get', '/inOutWarehouseTask/selectInOutWarehouseNo', {
+			await this.$api.doRequest('get', '/inOutWarehouseTask/selectInOutWarehouseNo', {
 				flag: this.flag,
 				warehouseName: this.gridList.warehouseName
 			}).then(res => {
+				console.log(1)
 				console.log(res)
 				for (let i = 0; i < res.data.data.length; i++) {
 					this.$set(res.data.data[i],'inOutTaskNo1',res.data.data[i].inOutTaskNo+(res.data.data[i].taskFlag?'('+res.data.data[i].taskFlag+')':''))
@@ -885,10 +946,11 @@
 				name: '他运',
 				value: '他运'
 			}]
-			this.$api.doRequest('get', '/inOutWarehouseTask/getContractNo', {
+			await this.$api.doRequest('get', '/inOutWarehouseTask/getContractNo', {
 				warehouseName: this.gridList.warehouseName
 			}).then(res => {
 				uni.hideLoading();
+				console.log(2)
 				// console.log(res)
 				if (res.data.data.contractManagementInfoList) {
 					for (let i = 0; i < res.data.data.contractManagementInfoList.length; i++) {
@@ -921,42 +983,47 @@
 
 				this.gridList.customerNumberCard = _customerInfo.customerNumberCard
 				var that = this
-				setTimeout(()=>{
-				},1000)
+				setTimeout(() => {}, 1000)
 				console.log(this.gridList.goodsName)
-				if(!this.gridList.goodsName){
+				if (!this.gridList.goodsName) {
 					this.gridList.goodsName = uni.getStorageSync('goodsName')
 				}
-					if(this.gridList.goodsName){
-						uni.showLoading({
-							title: '加载中',
-							mask: true
-						})
-						this.$api.doRequest('get', '/qualityInspectionManagement/getQualityInspectionManagementMap', {
+				if (this.gridList.goodsName) {
+					uni.showLoading({
+						title: '加载中',
+						mask: true
+					})
+					await this.$api.doRequest('get',
+						'/qualityInspectionManagement/getQualityInspectionManagementMap', {
 							goodsName: this.gridList.goodsName,
 							compId: uni.getStorageSync('pcUserInfo').compId,
 							customerNumberCard: this.gridList.customerNumberCard,
 							warehouseName: this.gridList.warehouseName
 						}).then(res => {
-							uni.hideLoading();
-							if(res.data.data.A+res.data.data.B+res.data.data.C*50>res.data.data.D-50){
-								that.redstatus=true
-							}else{
-								that.redstatus=false
-							}
-							var a=res.data.data.A>0?'已完成'+Number(res.data.data.A).toFixed(2)+'吨,':''
-							var b=res.data.data.B>0?'进行中'+Number(res.data.data.B).toFixed(2)+'吨,':''
-							var c=res.data.data.C>0?'未称重'+Number(res.data.data.C)+'车':''
-									  
-							that.gridList.volumeofbusiness=a+b+c
-							console.log(that.gridList.volumeofbusiness)
-							that.$forceUpdate()
-						})
-					}
-				
+						uni.hideLoading();
+						if (res.data.data.A + res.data.data.B + res.data.data.C * 50 > res.data.data.D - 50) {
+							that.redstatus = true
+						} else {
+							that.redstatus = false
+						}
+						var a = res.data.data.A > 0 ? '已完成' + Number(res.data.data.A).toFixed(2) + '吨,' : ''
+						var b = res.data.data.B > 0 ? '进行中' + Number(res.data.data.B).toFixed(2) + '吨,' : ''
+						var c = res.data.data.C > 0 ? '未称重' + Number(res.data.data.C) + '车' : ''
+
+						that.gridList.volumeofbusiness = a + b + c
+						console.log(that.gridList.volumeofbusiness)
+						that.$forceUpdate()
+					})
+				}
 			}
 		},
 		methods: {
+			colorLustreClick(e){
+				this.gridList.colorLustre = this.colorLustreList[e[0]].value
+			},
+			transgeneClick(e){
+				this.gridList.transgene = this.transgeneList[e[0]].value
+			},
 			Cancelword() {
 				this.bottomHeight = '10rpx';
 				this.MykeywordShow = false;
@@ -1078,10 +1145,11 @@
 			obtainPrice() { //根据容重获取价格
 				if (this.gridList.goodsName && this.cangid && this.gridList.bulkDensity) {
 					// if (!this.gridList.dryGrainPrice || this.gridList.dryGrainPrice == 0) {
+						let quality = this.gridList.goodsName=='大豆'?this.gridList.protein:this.gridList.bulkDensity
 					this.$api.doRequest('get', '/purchasePrice/tidalGrainPrice', {
 						warehouseId: this.cangid,
 						goodsName: this.gridList.goodsName,
-						bulkDensity: this.gridList.bulkDensity
+						bulkDensity: quality
 					}).then(res => {
 						if (res.data.data != 0) {
 							this.gridList.dryGrainPrice = res.data.data
@@ -1169,7 +1237,7 @@
 				console.log(this.gridList, 111111111111)
 			},
 			outtypepicker(e, status) {
-				console.log(e,status)
+				console.log(e, status)
 				if (status == 0) {
 					this.gridList.outType = this.multiSelector[e[0]].name
 				} else {
@@ -1339,6 +1407,17 @@
 					this.gridList.gradeKey = this.gradeList[1].key
 					// this.gridList.grade = this.contractNolist.grade
 					this.gridList.inOutType = this.contractNolist.inOutType
+					if(this.gridList.goodsName == "大豆"){ //货名为大豆是设置默认
+						this.gridList.transgene= "非转基因"
+						this.gridList.reTransgene= "非转基因"
+						this.gridList.colorLustre = "正常"
+						this.gridList.reColorLustre = "正常"
+					}else{
+						delete this.gridList.transgene
+						delete this.gridList.reTransgene
+						delete this.gridList.colorLustre
+						delete this.gridList.reColorLustre
+					}
 
 					if (this.gridList.inOutType == '采购入库') {
 						this.warehouseTradeCount = '000' + this.warehouseTradeCount
@@ -1423,28 +1502,32 @@
 						this.tranCarInfoList = []
 					}
 					this.fleetNameList = this.contractNolist.tranCarInfoList1
-					if(this.gridList.goodsName&&this.gridList.customerNumberCard){
+					if (this.gridList.goodsName && this.gridList.customerNumberCard) {
 						uni.showLoading({
-						title: '加载中',
-						mask: true
-					})
-					let that  = this
-					this.$api.doRequest('get', '/qualityInspectionManagement/getQualityInspectionManagementMap', {
-							goodsName: this.gridList.goodsName,
-							compId: uni.getStorageSync('pcUserInfo').compId,
-							customerNumberCard: this.gridList.customerNumberCard
-						}).then(res => {
-							uni.hideLoading(); 
-							if(res.data.data.A+res.data.data.B+res.data.data.C*50>res.data.data.D-50){
-								that.redstatus=true
-							}else{
-								that.redstatus=false
+							title: '加载中',
+							mask: true
+						})
+						let that = this
+						this.$api.doRequest('get',
+							'/qualityInspectionManagement/getQualityInspectionManagementMap', {
+								goodsName: this.gridList.goodsName,
+								compId: uni.getStorageSync('pcUserInfo').compId,
+								customerNumberCard: this.gridList.customerNumberCard
+							}).then(res => {
+							uni.hideLoading();
+							if (res.data.data.A + res.data.data.B + res.data.data.C * 50 > res.data.data
+								.D - 50) {
+								that.redstatus = true
+							} else {
+								that.redstatus = false
 							}
-							var a=res.data.data.A>0?'已完成'+Number(res.data.data.A).toFixed(2)+'吨,':''
-							var b=res.data.data.B>0?'进行中'+Number(res.data.data.B).toFixed(2)+'吨,':''
-							var c=res.data.data.C>0?'未称重'+Number(res.data.data.C)+'车':''
-									  
-							that.gridList.volumeofbusiness=a+b+c
+							var a = res.data.data.A > 0 ? '已完成' + Number(res.data.data.A).toFixed(2) +
+								'吨,' : ''
+							var b = res.data.data.B > 0 ? '进行中' + Number(res.data.data.B).toFixed(2) +
+								'吨,' : ''
+							var c = res.data.data.C > 0 ? '未称重' + Number(res.data.data.C) + '车' : ''
+
+							that.gridList.volumeofbusiness = a + b + c
 							console.log(that.gridList.volumeofbusiness)
 							that.$forceUpdate()
 						})
@@ -1469,7 +1552,7 @@
 						})
 					})
 				}
-				
+
 			},
 			close() {
 				this.isShowPrint = false
@@ -1495,24 +1578,10 @@
 			handleClick(e) {
 				this.gridList.carNumber = e.value //键盘输入值
 			},
-			// confirmInfo() {
-			// 	this.isShowAlert = true	
-			// },
-			// alertBtn() {
-			// 	this.$api.doRequest('get', '/qualityInspectionManagement/api/editQualityInspection', {
-			// 		id: this.id,
-			// 		flag:2
-			// 	}).then(res => {
-			// 		if(res.data.code=="200"){
-			// 			this.$api.msg('提交成功!')
-			// 		}else{
-			// 			this.$api.msg('提交失败')
-			// 		}
-			// 	})
-			// },
 			cancelClick() {
 				this.isShowAlert = false
 			},
+
 			waterContentChange() {
 				var that = this
 				if (this.gridList.goodsName) {
@@ -1549,9 +1618,9 @@
 					this.gridList.waterContent &&
 					this.gridList.grade
 				) {
-					
+
 					uni.showLoading({
-						title:"加载中"
+						title: "加载中"
 					})
 					this.$api.doRequest('get', '/purchasePrice/tidalGrainPrice', {
 						warehouseId: this.cangid,
@@ -1611,8 +1680,161 @@
 				}
 				return year + '' + mouth + '' + datetime
 			},
+			async addQualityInspection(type) {
+				if (type == 1) {
+					await this.$api.doRequest('post', '/qualityInspectionManagement/api/addQualityInspection', this
+							.gridList)
+						.then(res => {
+							console.log(res)
+							this.printId = res.data.data
+							uni.hideLoading()
+							if (res.data.code == 200) {
+								console.log("addQualityInspection")
+								this.$api.msg('提交成功')
+								this.gridList.warehouseId = this.cangid
+								this.gridList.compId = uni.getStorageSync(
+									'pcUserInfo').compId
+								uni.setStorageSync("quality_print", this.gridList)
+								if (this.isZJ) {
+									this.isShowPrint = true
+								} else {
+									uni.navigateBack({})
+								}
+
+								console.log('that.gridList', this.gridList)
+								// uni.navigateBack({})
+							} else {
+								this.$api.msg('提交失败')
+							}
+						})
+					return
+				}
+				if (type == 2) {
+					await this.$api.doRequest('post', '/qualityInspectionManagement/api/addQualityInspection', this
+							.gridList)
+						.then(res => {
+							console.log("addQualityInspection")
+							this.printId = res.data.data
+							uni.hideLoading()
+							if (res.data.code == 200) {
+								this.$api.msg('提交成功')
+								this.gridList.warehouseId = this.cangid
+								this.gridList.compId = uni.getStorageSync('pcUserInfo').compId
+								uni.setStorageSync("quality_print", this.gridList)
+								if (this.isZJ) {
+									this.isShowPrint = true
+								} else {
+									uni.navigateBack({})
+								}
+								uni.setStorageSync(
+									'checkcustomer', {}
+								)
+								console.log('that.gridList', this.gridList)
+								// uni.navigateBack({})
+							} else {
+								this.$api.msg('提交失败')
+							}
+						})
+				}
+
+			},
+			async inOutWarehouse(type) {
+				if (type == 1) {
+					await this.$api.doRequest('post', '/warehouseInOutInfo/InOutWarehouse', this.gridList)
+						.then(res => {
+							console.log("InOutWarehouse")
+							this.gridList.warehouseInOutId = res.data.data
+						})
+					return
+				}
+				if (type == 2) {
+					await this.$api.doRequest('post', '/warehouseInOutInfo/InOutWarehouse', this.gridList)
+						.then(res => {
+							console.log("InOutWarehouse")
+							if (this.isQY) {
+								if (!this.isZJ) {
+									this.gridList.statusFlag = 7
+								} else {
+									this.gridList.statusFlag = 0
+								}
+							}
+							this.gridList.warehouseInOutId = res.data.data
+							this.addQualityInspection(2)
+						})
+					return
+				}
+
+			},
+			async cumulant(type) {
+				if (type == 1) {
+					await this.$api.doRequest('get', '/paymentManagement/cumulant', {
+							compId: uni.getStorageSync('pcUserInfo').compId,
+							customerNumberCard: this.gridList.customerNumberCard,
+							goodsName: this.gridList.goodsName,
+						})
+						.then(response => {
+							console.log("cumulant")
+							if (response.data.code == 200) {
+								for (let i = 0; i < this.purchasePriceList.length; i++) {
+									if (this.gridList.goodsName == this.purchasePriceList[i].goodsName) {
+										let count = (this.purchasePriceList[i].saleLimit - response.data.data /
+												1000)
+											.toFixed(2)
+										console.log(count, this.purchasePriceList[i].saleLimit, response.data.data)
+
+										if (Number(count) <= 0) {
+											count = 0
+											this.$api.msg('该客户累计销售' + this.gridList.goodsName + (response.data
+												.data /
+												1000).toFixed(2) + '吨,还可售粮' + count + '吨', )
+											uni.hideLoading()
+											break;
+										}
+
+										this.gridList.inOutFlag = 2
+										this.inOutWarehouse(2)
+									}
+								}
+							}
+						})
+					return
+				}
+
+			},
+			async getGoodsName() {
+				let that = this
+				await this.$api.doRequest('get', '/qualityInspectionManagement/api/goodsName', {
+					warehouseId: this.cangid
+				}).then(res => {
+					if (res.data.code != 200 && that.typevalue == 3) {
+						uni.showModal({
+							content: res.data.message,
+							showCancel: false
+						})
+						return;
+					}
+					uni.showModal({
+						content: "确定提交质检信息?",
+						showCancel: true,
+						confirmText: '提交',
+						success: function(res) {
+							if (res.confirm) {
+								that.gridList.serviceManagementType = that.typevalue
+								if (that.typevalue == 3) {
+									that.cumulant(1)
+									return
+								}
+								that.gridList.inOutFlag = 2
+								that.inOutWarehouse(1)
+								that.addQualityInspection(1)
+							}
+						}
+					})
+				})
+			},
 			submit() {
-				debugger
+				console.log(this.isQY, "isQY")
+				console.log(this.isZJ, "isZJ")
 				if (this.typevalue == 3) {
 					if (this.outType) {
 						this.gridList.outType = this.outType
@@ -1638,11 +1860,6 @@
 					return
 				}
 				if (this.utils.getCurrectRoles('acquisitionQuality.initial')) {
-
-					// if (!this.gridList.qualityNo) {
-					// 	this.$api.msg('编号不能为空')
-					// 	return
-					// }
 					if (!this.gridList.binNumber) {
 						this.$api.msg('仓位不能为空')
 						return
@@ -1653,22 +1870,6 @@
 							return
 						}
 					}
-					// if (this.gridList.waterPriceIncrease>10||this.gridList.waterPriceIncrease<0) {
-					// 	this.$api.msg('水分增价输入错误')
-					// 	return
-					// }
-					// if (this.gridList.waterPriceDeduction>10||this.gridList.waterPriceDeduction<0) {
-					// 	this.$api.msg('水分扣价输入错误')
-					// 	return
-					// }
-					// if (this.gridList.qualityPriceIncrease>10||this.gridList.qualityPriceIncrease<0) {
-					// 	this.$api.msg('质量增价输入错误')
-					// 	return
-					// }
-					// if (this.gridList.qualityPriceDeduction>10||this.gridList.qualityPriceDeduction<0) {
-					// 	this.$api.msg('质量扣价输入错误')
-					// 	return
-					// }
 					if (!this.gridList.type) {
 						this.$api.msg('类型不能为空')
 						return
@@ -1699,8 +1900,9 @@
 								this.$api.msg('容重不能为空')
 								return
 							}
-						} else {
-							if (!this.gridList.bulkDensity) {
+						} 
+						if(this.gridList.goodsName == "大豆"){
+							if (!this.gridList.protein) {
 								this.$api.msg('蛋白不能为空')
 								return
 							}
@@ -1716,7 +1918,7 @@
 						}
 					}
 				}
-				if (this.utils.getCurrectRoles('acquisitionQuality.qview')) {
+				if (this.isQY) {
 					if (this.typevalue == 3) {
 						if (!this.gridList.customerName) {
 							this.$api.msg('客户不能为空')
@@ -1736,516 +1938,42 @@
 						return
 					}
 				}
-				var text = ''
-				if (this.utils.getCurrectRoles('acquisitionQuality.qview') && !this.utils.getCurrectRoles(
-						'acquisitionQuality.initial')) {
-					text = "确定提交钎样信息?"
-					this.gridList.brazer = 1
+				// 钎样提交
+				if (this.isQY && !this.isZJ) {
+					that.gridList.serviceManagementType = that.typevalue
 					uni.showModal({
-						content: text,
+						content: "确定提交钎样信息?",
 						showCancel: true,
 						confirmText: '提交',
 						success: function(res) {
 							if (res.confirm) {
-								that.gridList.serviceManagementType = that.typevalue
 								if (that.typevalue == 3) {
-									
 									uni.showLoading({
-										title:"加载中"
+										title: "加载中"
 									})
-									that.$api.doRequest('get', '/paymentManagement/cumulant', {
-											compId: uni.getStorageSync('pcUserInfo').compId,
-											customerNumberCard: that.gridList.customerNumberCard,
-											goodsName: that.gridList.goodsName,
-										})
-										.then(response => {
-											if (response.data.code == 200) {
-												for (let i = 0; i < that.purchasePriceList.length; i++) {
-													if (
-														that.gridList.goodsName == that.purchasePriceList[
-															i]
-														.goodsName
-													) {
-														let count = (that.purchasePriceList[i].saleLimit -
-															response.data.data / 1000).toFixed(2)
-														console.log(count, that.purchasePriceList[i]
-															.saleLimit,
-															response.data.data)
-
-														if (Number(count) <= 0) {
-															count = 0
-															that.$api.msg('该客户累计销售' + that.gridList
-																.goodsName +
-																(
-																	response.data.data / 1000).toFixed(
-																	2) +
-																'吨,还可售粮' +
-																count + '吨', )
-																uni.hideLoading()
-
-														} else {
-															that.gridList.inOutFlag = 2
-															that.$api.doRequest('post',
-																	'/warehouseInOutInfo/InOutWarehouse',
-																	that.gridList)
-																.then(res => {
-																	if (that.utils.getCurrectRoles(
-																			'acquisitionQuality.qview'
-																		)) {
-																		if (!that.utils
-																			.getCurrectRoles(
-																				'acquisitionQuality.initial'
-																			)) {
-																			that.gridList.statusFlag =
-																				7
-																		} else {
-																			that.gridList.statusFlag =
-																				0
-																		}
-																	}
-																	that.gridList.warehouseInOutId =
-																		res
-																		.data.data
-																	that.$api.doRequest('post',
-																			'/qualityInspectionManagement/api/addQualityInspection',
-																			that.gridList)
-																		.then(res => {
-																			that.printId=res.data.data
-																			uni.hideLoading()
-																			if (res.data.code ==
-																				200) {
-																				that.$api.msg(
-																					'提交成功')
-																				that.gridList
-																					.warehouseId =
-																					that
-																					.cangid
-																				that.gridList
-																					.compId =
-																					uni
-																					.getStorageSync(
-																						'pcUserInfo'
-																					)
-																					.compId
-																				uni.setStorageSync(
-																					"quality_print",
-																					that
-																					.gridList)
-																				if (that.utils
-																					.getCurrectRoles(
-																						'acquisitionQuality.initial'
-																					)) {
-																					that.isShowPrint =
-																						true
-																				} else {
-																					uni.navigateBack({})
-																				}
-																				uni.setStorageSync('checkcustomer',{})
-																				console.log(
-																					'that.gridList',
-																					that
-																					.gridList)
-																				// uni.navigateBack({})
-																			} else {
-																				that.$api.msg(
-																					'提交失败')
-																			}
-																		})
-																})
-														}
-													}
-												}
-											}
-										})
-								} else {
-									uni.showLoading({
-										title:"加载中"
-									})
-									that.gridList.inOutFlag = 2
-									that.$api.doRequest('post',
-											'/warehouseInOutInfo/InOutWarehouse',
-											that.gridList)
-										.then(res => {
-
-											that.gridList.warehouseInOutId = res.data.data
-											that.$api.doRequest('post',
-													'/qualityInspectionManagement/api/addQualityInspection',
-													that.gridList)
-												.then(res => {
-													console.log(res)
-													that.printId=res.data.data
-													uni.hideLoading()
-													if (res.data.code == 200) {
-														that.$api.msg('提交成功')
-														that.gridList.warehouseId = that.cangid
-														that.gridList.compId = uni.getStorageSync(
-															'pcUserInfo').compId
-														uni.setStorageSync("quality_print", that
-															.gridList)
-														if (that.utils.getCurrectRoles(
-																'acquisitionQuality.initial')) {
-															that.isShowPrint = true
-														} else {
-															uni.navigateBack({})
-														}
-
-														console.log('that.gridList', that.gridList)
-														// uni.navigateBack({})
-													} else {
-														that.$api.msg('提交失败')
-													}
-												})
-										})
+									that.cumulant(1)
+									return
 								}
-
+								uni.showLoading({
+									title: "加载中"
+								})
+								that.gridList.inOutFlag = 2
+								that.inOutWarehouse(1)
+								that.addQualityInspection(1)
 							}
+
 						}
 					})
 				} else {
-					text = "确定提交质检信息?"
 					this.gridList.brazer = 0
-					this.$api.doRequest('get', '/qualityInspectionManagement/api/goodsName', {
-						warehouseId: this.cangid
-					}).then(res => {
-						if (res.data.code != 200 && that.typevalue == 3) {
-							uni.showModal({
-								content: res.data.message,
-								showCancel: false
-							})
-							return;
-						} else {
-							uni.showModal({
-								content: text,
-								showCancel: true,
-								confirmText: '提交',
-								success: function(res) {
-									if (res.confirm) {
-										that.gridList.serviceManagementType = that.typevalue
-										if (that.typevalue == 3) {
-											that.$api.doRequest('get', '/paymentManagement/cumulant', {
-													compId: uni.getStorageSync('pcUserInfo')
-														.compId,
-													customerNumberCard: that.gridList
-														.customerNumberCard,
-													goodsName: that.gridList.goodsName,
-												})
-												.then(response => {
-													if (response.data.code == 200) {
-														for (let i = 0; i < that.purchasePriceList
-															.length; i++) {
-															if (
-																that.gridList.goodsName == that
-																.purchasePriceList[i]
-																.goodsName
-															) {
-																let count = (that
-																		.purchasePriceList[i]
-																		.saleLimit -
-																		response.data.data / 1000)
-																	.toFixed(2)
-																console.log(count, that
-																	.purchasePriceList[i]
-																	.saleLimit,
-																	response.data.data)
-
-																if (Number(count) <= 0) {
-																	count = 0
-																	that.$api.msg('该客户累计销售' + that
-																		.gridList.goodsName +
-																		(
-																			response.data
-																			.data / 1000)
-																		.toFixed(2) +
-																		'吨,还可售粮' +
-																		count + '吨', )
-
-																} else {
-																	that.gridList.inOutFlag = 2
-																	that.$api.doRequest('post',
-																			'/warehouseInOutInfo/InOutWarehouse',
-																			that.gridList)
-																		.then(res => {
-																			if (that.utils
-																				.getCurrectRoles(
-																					'acquisitionQuality.qview'
-																				)) {
-																				if (!that.utils
-																					.getCurrectRoles(
-																						'acquisitionQuality.initial'
-																					)) {
-																					that.gridList
-																						.statusFlag =
-																						7
-																				} else {
-																					that.gridList
-																						.statusFlag =
-																						0
-																				}
-																			}
-																			that.gridList.warehouseInOutId =
-																			res.data.data
-																			that.$api.doRequest(
-																				'post',
-																				'/qualityInspectionManagement/api/addQualityInspection',
-																				that.gridList)
-																				.then(res => {
-																					that.printId=res.data.data
-																					if (res
-																						.data
-																						.code ==
-																						200
-																					) {
-																						that.$api
-																							.msg(
-																								'提交成功'
-																							)
-																						that.gridList
-																							.warehouseId =
-																							that
-																							.cangid
-																						that.gridList
-																							.compId =
-																							uni
-																							.getStorageSync(
-																								'pcUserInfo'
-																							)
-																							.compId
-																						uni.setStorageSync(
-																							"quality_print",
-																							that
-																							.gridList
-																						)
-																						if (that
-																							.utils
-																							.getCurrectRoles(
-																								'acquisitionQuality.initial'
-																							)
-																						) {
-																							that.isShowPrint =
-																								true
-																						} else {
-																							uni.navigateBack({})
-																						}
-
-																						console
-																							.log(
-																								'that.gridList',
-																								that
-																								.gridList
-																							)
-																						// uni.navigateBack({})
-																					} else {
-																						that.$api
-																							.msg(
-																								'提交失败'
-																							)
-																					}
-																				})
-																		})
-																}
-															}
-														}
-													}
-												})
-										} else {
-
-											that.gridList.inOutFlag = 2
-											that.$api.doRequest('post',
-													'/warehouseInOutInfo/InOutWarehouse',
-													that.gridList)
-												.then(res => {
-
-													that.gridList.warehouseInOutId = res.data.data
-													that.$api.doRequest('post',
-															'/qualityInspectionManagement/api/addQualityInspection',
-															that.gridList)
-														.then(res => {
-															that.printId=res.data.data
-															if (res.data.code == 200) {
-																that.$api.msg('提交成功')
-																that.gridList.warehouseId =
-																	that.cangid
-																that.gridList.compId = uni
-																	.getStorageSync(
-																		'pcUserInfo').compId
-																uni.setStorageSync(
-																	"quality_print", that
-																	.gridList)
-																if (that.utils.getCurrectRoles(
-																		'acquisitionQuality.initial'
-																	)) {
-																	that.isShowPrint = true
-																} else {
-																	uni.navigateBack({})
-																}
-
-																console.log('that.gridList',
-																	that.gridList)
-																// uni.navigateBack({})
-															} else {
-																that.$api.msg('提交失败')
-															}
-														})
-												})
-										}
-
-									}
-								}
-							})
-						}
-					})
+					this.getGoodsName()
 				}
 
-				// if (!this.gridList.storageTagNo) {
-				// 	this.$api.msg('囤位号不能为空')
-				// 	return
-				// }
-				// if (this.gridList.storageTagNo&&this.gridList.storageTagNo.length > 10) {
-				// 	this.$api.msg('囤位号不能为空')
-				// 	return
-				// }
+				// // 质检提交
+				// if (!this.isQY && this.isZJ) {
 
-				// if (this.gridList.buckleWeightRatio < 0 || this.gridList.buckleWeightRatio > 2) {
-				// 	this.$api.msg('扣重比输入错误')
-				// 	return
-				// }
-				// if (
-				// 	String(this.gridList.buckleWeightRatio).indexOf('.') != -1 &&
-				// 	String(this.gridList.buckleWeightRatio).length -
-				// 	(String(this.gridList.buckleWeightRatio).indexOf('.') + 1) > 2) {
-				// 	this.$api.msg('扣重比输入错误')
-				// 	return
 				// }
 
-				// uni.showModal({
-				// 	content: text,
-				// 	showCancel: true,
-				// 	confirmText: '提交',
-				// 	success: function(res) {
-				// 		if (res.confirm) {
-				// 			that.gridList.serviceManagementType = that.typevalue
-				// 			if (that.typevalue == 3) {
-				// 				that.$api.doRequest('get', '/paymentManagement/cumulant', {
-				// 						compId: uni.getStorageSync('pcUserInfo').compId,
-				// 						customerNumberCard: that.gridList.customerNumberCard,
-				// 						goodsName: that.gridList.goodsName,
-				// 					})
-				// 					.then(response => {
-				// 						if (response.data.code == 200) {
-				// 							for (let i = 0; i < that.purchasePriceList.length; i++) {
-				// 								if (
-				// 									that.gridList.goodsName == that.purchasePriceList[i]
-				// 									.goodsName
-				// 								) {
-				// 									let count = (that.purchasePriceList[i].saleLimit -
-				// 										response.data.data / 1000).toFixed(2)
-				// 									console.log(count, that.purchasePriceList[i].saleLimit,
-				// 										response.data.data)
-
-				// 									if (Number(count) <= 0) {
-				// 										count = 0
-				// 										that.$api.msg('该客户累计销售' + that.gridList.goodsName +
-				// 											(
-				// 												response.data.data / 1000).toFixed(2) +
-				// 											'吨,还可售粮' +
-				// 											count + '吨', )
-
-				// 									} else {
-				// 										that.gridList.inOutFlag = 2
-				// 										that.$api.doRequest('post',
-				// 												'/warehouseInOutInfo/InOutWarehouse',
-				// 												that.gridList)
-				// 											.then(res => {
-				// 												if (that.utils.getCurrectRoles(
-				// 														'acquisitionQuality.qview')) {
-				// 													if (!that.utils.getCurrectRoles(
-				// 															'acquisitionQuality.initial'
-				// 															)) {
-				// 														that.gridList.statusFlag = 7
-				// 													} else {
-				// 														that.gridList.statusFlag = 0
-				// 													}
-				// 												}
-				// 												that.gridList.warehouseInOutId = res
-				// 													.data.data
-				// 												that.$api.doRequest('post',
-				// 														'/qualityInspectionManagement/api/addQualityInspection',
-				// 														that.gridList)
-				// 													.then(res => {
-				// 														if (res.data.code == 200) {
-				// 															that.$api.msg('提交成功')
-				// 															that.gridList
-				// 																.warehouseId = that
-				// 																.cangid
-				// 															that.gridList.compId =
-				// 																uni.getStorageSync(
-				// 																	'pcUserInfo')
-				// 																.compId
-				// 															uni.setStorageSync(
-				// 																"quality_print",
-				// 																that.gridList)
-				// 															if (that.utils
-				// 																.getCurrectRoles(
-				// 																	'acquisitionQuality.initial'
-				// 																	)) {
-				// 																that.isShowPrint =
-				// 																	true
-				// 															} else {
-				// 																uni.navigateBack({})
-				// 															}
-
-				// 															console.log(
-				// 																'that.gridList',
-				// 																that.gridList)
-				// 															// uni.navigateBack({})
-				// 														} else {
-				// 															that.$api.msg('提交失败')
-				// 														}
-				// 													})
-				// 											})
-				// 									}
-				// 								}
-				// 							}
-				// 						}
-				// 					})
-				// 			} else {
-
-				// 				that.gridList.inOutFlag = 2
-				// 				that.$api.doRequest('post',
-				// 						'/warehouseInOutInfo/InOutWarehouse',
-				// 						that.gridList)
-				// 					.then(res => {
-
-				// 						that.gridList.warehouseInOutId = res.data.data
-				// 						that.$api.doRequest('post',
-				// 								'/qualityInspectionManagement/api/addQualityInspection',
-				// 								that.gridList)
-				// 							.then(res => {
-				// 								if (res.data.code == 200) {
-				// 									that.$api.msg('提交成功')
-				// 									that.gridList.warehouseId = that.cangid
-				// 									that.gridList.compId = uni.getStorageSync(
-				// 										'pcUserInfo').compId
-				// 									uni.setStorageSync("quality_print", that.gridList)
-				// 									if (that.utils.getCurrectRoles(
-				// 											'acquisitionQuality.initial')) {
-				// 										that.isShowPrint = true
-				// 									} else {
-				// 										uni.navigateBack({})
-				// 									}
-
-				// 									console.log('that.gridList', that.gridList)
-				// 									// uni.navigateBack({})
-				// 								} else {
-				// 									that.$api.msg('提交失败')
-				// 								}
-				// 							})
-				// 					})
-				// 			}
-
-				// 		}
-				// 	}
-				// })
 			},
 			gradepicker(e) {
 				console.log(e)

+ 88 - 12
pages/erpbusiness/edit_quality_testing.vue

@@ -298,9 +298,8 @@
 							name="input"></input>
 					</view>
 				</view>
-				<view class="c-row ">
-					<view v-if='gridList.goodsName!="大豆"' class="title">容重(克/升)</view>
-					<view v-else class="title">蛋白</view>
+				<view class="c-row " v-if='gridList.goodsName!="大豆"'>
+					<view  class="title">容重(克/升)</view>
 					<view class="con-list">
 						<MyNumberInput :myvalue="gridList.bulkDensity" :Isedit="Isedit" :IsShow="MykeywordShow"
 							:myevent="'bulkDensity'"
@@ -318,7 +317,26 @@
 								name="input"></input>
 					</view>
 				</view>
-				<view class="c-row ">
+				<view class="c-row" v-else>
+					<view class="title">蛋白</view>
+					<view class="con-list">
+						<MyNumberInput :myvalue="gridList.protein" :Isedit="Isedit" :IsShow="MykeywordShow"
+							:myevent="'protein'"
+							@setValue="mykeywordset"  v-if="InputEvent=='protein'" 
+							@Cancelword="Cancelword" 
+							@goNext="goNext('protein')"></MyNumberInput>
+						<input v-else  @click="SetInputKey('protein')" :disabled='flag==1' type="digit" v-model='gridList.protein' placeholder="请输入蛋白"
+							name="input"  @input="obtainPrice"></input>
+						<MyNumberInput :myvalue="gridList.reProtein" :Isedit="Isedit" :IsShow="MykeywordShow"
+							:myevent="'reProtein'"
+							@setValue="mykeywordset"  v-if="InputEvent=='reProtein'" 
+							@Cancelword="Cancelword" 
+							@goNext="goNext('reProtein')"></MyNumberInput>
+						<input @click="SetInputKey('reProtein')" v-if="flag==1&&InputEvent!='reProtein'||flag==2&&InputEvent!='reProtein'" type="digit" v-model='gridList.reProtein' placeholder="请输入蛋白" 
+								name="input"></input>
+					</view>
+				</view>
+				<view class="c-row " v-if='gridList.goodsName!="大豆"'>
 					<view class="title">不完善粒(%)</view>
 					<view class="con-list">
 						<MyNumberInput :myvalue="gridList.imperfectGrain" :Isedit="Isedit" :IsShow="MykeywordShow"
@@ -337,6 +355,25 @@
 								name="input"></input>
 					</view>
 				</view>
+				<view class="c-row" v-else>
+					<view class="title">完整粒率(%)</view>
+					<view class="con-list">
+						<MyNumberInput :myvalue="gridList.completeGrain" :Isedit="Isedit" :IsShow="MykeywordShow"
+							:myevent="'completeGrain'"
+							@setValue="mykeywordset"  v-if="InputEvent=='completeGrain'" 
+							@Cancelword="Cancelword" 
+							@goNext="goNext('completeGrain')"></MyNumberInput>
+						<input v-else  @click="SetInputKey('completeGrain')" :disabled='flag==1' type="digit" v-model='gridList.completeGrain' placeholder="请输入完整粒率占比"
+							name="input"></input>
+						<MyNumberInput :myvalue="gridList.reCompleteGrain" :Isedit="Isedit" :IsShow="MykeywordShow"
+							:myevent="'reCompleteGrain'"
+							@setValue="mykeywordset"  v-if="InputEvent=='reCompleteGrain'" 
+							@Cancelword="Cancelword" 
+							@goNext="goNext('reCompleteGrain')"></MyNumberInput>
+						<input  @click="SetInputKey('reCompleteGrain')" v-if="flag==1&&InputEvent!='reCompleteGrain'||flag==2&&InputEvent!='reCompleteGrain'" type="digit" v-model='gridList.reCompleteGrain' placeholder="请输入完整粒率占比"
+								name="input"></input>
+					</view>
+				</view>
 				<view class="c-row ">
 					<view class="title">杂质(%)</view>
 					<view class="con-list">
@@ -395,6 +432,35 @@
 						<!-- <input v-model='gridList.jiaorenli' @click.stop="handleShowKeyboard1":disabled="true" placeholder="请输入热损伤占比" name="input"></input> -->
 					</view>
 				</view>
+				<view class="c-row" v-if="gridList.goodsName == '大豆'">
+					<view class="title">转基因</view>
+					<view class="con-list">
+							<view @click="transgeneShow=true">{{gridList.transgene}}</view>
+							<!-- 转基因 -->
+							<u-picker :range="transgeneList" range-key="value" @confirm='transgeneClick($event)' v-model="transgeneShow"
+								mode="selector">
+							</u-picker>
+							<view @click="transgeneShow=true">{{gridList.reTransgene?gridList.reTransgene:"请选择是否转基因"}}</view>
+							<!-- 转基因 -->
+							<u-picker :range="transgeneList" range-key="value" @confirm='transgeneClick1($event)' v-model="transgeneShow"
+								mode="selector">
+							</u-picker>
+					</view>
+				</view>
+				<view class="c-row" v-if="gridList.goodsName == '大豆'">
+					<view class="title">色泽/气味</view>
+					<view class="con-list">
+							<div >{{gridList.colorLustre}}</div>
+							<u-picker :range="colorLustreList" range-key="value" @confirm='colorLustreClick($event)' v-model="colorLustreShow"
+								mode="selector">
+							</u-picker>
+							
+							<div @click="colorLustreShow = true">{{gridList.reColorLustre?gridList.reColorLustre:"请选择色泽/气味是否正常"}}</div>
+							<u-picker :range="colorLustreList" range-key="value" @confirm='colorLustreClick1($event)' v-model="colorLustreShow"
+								mode="selector">
+							</u-picker>
+					</view>
+				</view>
 				<view v-show="utils.getCurrectRoles('acquisitionQuality.initial')"
 					class="c-row">
 					<view class="title">水分增价(元/吨)</view>
@@ -600,6 +666,10 @@
 				tidalGrainPrice:0,
 				isShowAlert: false,
 				content: '确认初检信息后,初检员不需要再次确认质检信息,是否确定提交?',
+				transgeneShow:false,
+				transgeneList:[{value:'非转基因'},{value:'转基因'}],
+				colorLustreShow : false,
+				colorLustreList:[{value:'正常'},{value:'异常'}]
 			}
 		},
 		// #ifndef MP
@@ -776,9 +846,8 @@
 					that.carModeList = res.data.data
 				}
 			})
-			
-			this.gridList.grade = this.gradeList[0].value
-			this.gridList.gradeKey = this.gradeList[0].key
+			this.gridList.grade = this.gradeList[2].value
+			this.gridList.gradeKey = this.gradeList[2].key
 		},
 		onShow() {
 			this.multiSelector1=[{name:'他运',value:'他运'}]
@@ -826,6 +895,18 @@
 			}
 		},
 		methods: {
+			colorLustreClick(e){
+				this.gridList.colorLustre = this.colorLustreList[e[0]].value
+			},
+			colorLustreClick1(e){
+				this.gridList.reColorLustre = this.colorLustreList[e[0]].value
+			},
+			transgeneClick(e){
+				this.gridList.transgene = this.transgeneList[e[0]].value
+			},
+			transgeneClick1(e){
+				this.gridList.reTransgene = this.transgeneList[e[0]].value
+			},
 			Cancelword(){
 				this.bottomHeight = '10rpx';
 				this.MykeywordShow =false;
@@ -1339,11 +1420,6 @@
 							this.$api.msg('容重不能为空')
 							return
 						}
-					}else{
-						if (!this.gridList.bulkDensity) {
-							this.$api.msg('蛋白不能为空')
-							return
-						}
 					}
 					if (!this.gridList.jiaorenli) {
 						this.$api.msg('热损伤不能为空')

+ 30 - 2
pages/erpbusiness/examine_quality_testing.vue

@@ -186,7 +186,7 @@
 					</view> -->
 
 				</view>
-				<view class="c-row ">
+				<view class="c-row " v-if="gridList.goodsName !='大豆'">
 					<view class="title">容重(克/升)</view>
 					<view class="con-list">
 						<view>{{gridList.bulkDensity}}</view>
@@ -194,13 +194,27 @@
 						
 					</view>
 				</view>
-				<view class="c-row ">
+				<view class="c-row " v-else>
+					<view class="title">蛋白</view>
+					<view class="con-list">
+						<view>{{gridList.protein}}</view>
+						<view>{{gridList.reProtein}}</view>
+					</view>
+				</view>
+				<view class="c-row " v-if="gridList.goodsName !='大豆'">
 					<view class="title">不完善粒(%)</view>
 					<view class="con-list">
 						<view>{{gridList.imperfectGrain}}</view>
 						<view>{{gridList.reImperfectGrain}}</view>
 					</view>
 				</view>
+				<view class="c-row " v-else>
+					<view class="title">完整粒率(%)</view>
+					<view class="con-list">
+						<view>{{gridList.completeGrain}}</view>
+						<view>{{gridList.reCompleteGrain}}</view>
+					</view>
+				</view>
 				<view class="c-row ">
 					<view class="title">杂质(%)</view>
 					<view class="con-list">
@@ -222,6 +236,20 @@
 						<view>{{gridList.reJiaorenli}}</view>
 					</view>
 				</view>
+				<view class="c-row ">
+					<view class="title">转基因</view>
+					<view class="con-list">
+						<view>{{gridList.transgene}}</view>
+						<view>{{gridList.reTransgene}}</view>
+					</view>
+				</view>
+				<view class="c-row ">
+					<view class="title">色泽/气味</view>
+					<view class="con-list">
+						<view>{{gridList.colorLustre}}</view>
+						<view>{{gridList.reColorLustre}}</view>
+					</view>
+				</view>
 				<view class="c-row">
 					<view class="title">水分增价(元/吨)</view>
 					<view class="con-list">

+ 2 - 1
pages/erpbusiness/quality_testing.vue

@@ -308,7 +308,7 @@
 		},
 		methods: {
 			print(item){
-				
+				console.log("wwwwwwwwww",item.protein)
 				uni.setStorageSync("quality_print", item)
 				uni.navigateTo({
 					url: '/pages/erpbusiness/bleConnect'
@@ -385,6 +385,7 @@
 							//采购信息
 							if (data.length > 0) {
 								if (flag) {
+									
 									that.gridList = data
 								} else {
 									that.gridList = that.gridList.concat(data)

+ 37 - 16
pages/erpbusiness/sendCommand.vue

@@ -157,9 +157,7 @@
 			//    })	
 		},
 		methods: {
-
 			clearBlue() {
-
 				let tmp = this.Bluetooth;
 				uni.closeBLEConnection({
 					deviceId: tmp.BLEInformation.deviceId
@@ -218,10 +216,7 @@
 					command.rowSpace(100);
 					command.setText("编号错误"+that.gridList.qualityNo);
 				}
-
-
 				command.setPrint();
-
 				// 标题
 				command.bold(1); //加粗
 				command.setFontSize(16); //字体大小
@@ -317,16 +312,34 @@
 				command.setLeftMargin(30)
 				command.setText("类型:" + that.gridList.type);
 				command.setPrint();
+				//蛋白
+				if(that.gridList.goodsName == '大豆'){
+					command.setSelectJustification(0); //居左
+					command.setLeftMargin(30)
+					command.setText('蛋白:' + that.gridList.protein);
+					command.setPrint();
+				}
 				//容量
-				command.setSelectJustification(0); //居左
-				command.setLeftMargin(30)
-				command.setText("容量(克/升):" + that.gridList.bulkDensity);
-				command.setPrint();
+				if(that.gridList.goodsName != '大豆'){
+					command.setSelectJustification(0); //居左
+					command.setLeftMargin(30)
+					command.setText("容量(克/升):" + that.gridList.bulkDensity);
+					command.setPrint();
+				}
+				//完整粒率(%)
+				if(that.gridList.goodsName == '大豆'){
+					command.setSelectJustification(0); //居左
+					command.setLeftMargin(30)
+					command.setText('完整粒率(%):' + that.gridList.completeGrain);
+					command.setPrint();
+				}
 				//不完善粒
-				command.setSelectJustification(0); //居左
-				command.setLeftMargin(30)
-				command.setText("不完善粒(%):" + that.gridList.imperfectGrain);
-				command.setPrint();
+				if(that.gridList.goodsName != '大豆'){
+					command.setSelectJustification(0); //居左
+					command.setLeftMargin(30)
+					command.setText("不完善粒(%):" +that.gridList.imperfectGrain);
+					command.setPrint();
+				}
 				//等级
 				command.setSelectJustification(0); //居左
 				command.setLeftMargin(30)
@@ -366,6 +379,17 @@
 				// command.setLeftMargin(30)
 				// command.setText("购粮性质:" + that.gridList.natureOfGrainPurchase);
 				// command.setPrint();
+				if(that.gridList.goodsName == '大豆'){
+					command.setSelectJustification(0); //居左
+					command.setLeftMargin(30)
+					command.setText('转基因:' + that.gridList.transgene);
+					command.setPrint();
+					
+					command.setSelectJustification(0); //居左
+					command.setLeftMargin(30)
+					command.setText('色泽/气味:' + that.gridList.colorLustre);
+					command.setPrint();
+				}
 				//仓位号
 				command.setSelectJustification(0); //居左
 				command.setLeftMargin(30)
@@ -396,10 +420,7 @@
 				command.setPrintAndFeedRow(10);
 				that.isReceiptSend = true;
 				that.prepareSend(command.getData());
-
-
 			},
-
 			//准备发送,根据每次发送字节数来处理分包数量
 			prepareSend(buff) {
 				console.log(buff);

+ 5 - 2
pages/reimbursement/request_funds.vue

@@ -199,9 +199,12 @@
 				],
 				typeList:[
 					{value: "杂费"},
-					{value: "电费"},
-					{value: "费"},
+					{value: "电费"},
+					{value: "伙食费"},
 					{value: "人工费"},
+					{value: "物质采买"},
+					{value: "燃料费"},
+					{value: "加油费"},
 				],
 				namelist:[
 					{name: "黑龙江中天昊元贸易有限公司"},

+ 33 - 19
pages/task/audit/Issueandreceipt_task_approval.vue

@@ -309,7 +309,7 @@
 								</view>
 								<view class="flex audit_img">
 									<view v-for="(items,indexs) in item.fileUrl" class="url_css">
-										<image :src="items" mode="" class="url_img" @click="openDocument(items)">
+										<image :src="items" mode="aspectFill" class="url_img" @click="openDocument(items)">
 										</image>
 									</view>
 								</view>
@@ -353,12 +353,14 @@
 				</view>
 				<view class="upload_css">
 					上传附件
-					<upload class="upload" ref="upload" :action="action" :max-size="maxSize" :max-count="2"
+					<upload class="upload" :width="150" ref="upload" :action="action" :max-size="maxSize" :max-count="99"
 						:size-type="['compressed']" @on-success="getImgUrl" @on-error="onError" @on-remove="onRemove"
 						@on-uploaded="isAdd = true" :before-upload="filterFileType" @on-progress="onProgress"></upload>
 				</view>
+				<view class="audit_btn">
 				<view @click='close()' class="cancel">取消</view>
 				<view @click='passSubmit()' class="confirm">确定</view>
+				</view>
 			</view>
 		</view>
 		<u-toast ref="uToast" />
@@ -1276,8 +1278,7 @@
 			}
 		}
 	}
-
-	.shade {
+.shade {
 		position: fixed;
 		top: 0;
 		left: 0;
@@ -1285,7 +1286,8 @@
 		width: 100%;
 		background: rgba(0, 0, 0, 0.4);
 		z-index: 3;
-
+		overflow-y: scroll;
+	
 		.wrap {
 			position: absolute;
 			left: 0;
@@ -1295,9 +1297,11 @@
 			margin: auto;
 			background: #fff;
 			width: calc(100% - 198rpx);
-			height: 820rpx;
+			height: 770rpx;
+			overflow-y: scroll;
+			// overflow: hidden;
 			border-radius: 20rpx;
-
+	
 			.alert-top {
 				padding: 33rpx;
 				display: flex;
@@ -1305,42 +1309,52 @@
 				align-items: center;
 				position: relative;
 			}
-
+	
 			.title {
 				font-size: 32rpx;
 				font-weight: 600;
 				color: #333333;
 			}
-
+	
 			.close {
 				position: absolute;
 				right: 33rpx;
 			}
-
+	
 			.upload_css {
 				margin-left: 20rpx;
+	
+				.upload {
+					// width: 80px;
+					// height: 80px;
+				}
 			}
 		}
 	}
-
+	
+	.audit_btn {
+		display: flex;
+		top: 0px;
+	}
+	
 	.cancel,
 	.confirm {
-		position: absolute;
-		display: inline-block;
+		// position: absolute;
+		// display: inline-block;
 		width: 50%;
 		text-align: center;
-		bottom: 0;
+		// bottom: 0;
 		padding: 10px;
 		border-top: 1px solid #eee;
 		font-size: 34rpx;
+		margin: auto;
 	}
-
+	
 	.cancel {
 		left: 0;
 		border-right: 1px solid #eee;
 		color: #AFB3BF;
 	}
-
 	.confirm {
 		right: 0;
 		color: #22C572;
@@ -1469,14 +1483,14 @@
 					flex-wrap: wrap;
 
 					.url_css {
-						border: 1px solid #999999;
+						// border: 1px solid #999999;
 						border-radius: 10px;
 						margin-top: 10px;
 						margin-right: 10px;
 
 						.url_img {
-							width: 80px;
-							height: 80px;
+							width: 66px;
+							height: 66px;
 							border-radius: 10px;
 						}
 					}

+ 4 - 4
pages/task/audit/Issueandreceipt_task_details.vue

@@ -286,7 +286,7 @@
 								</view>
 								<view v-if='item.fileUrl' class="flex audit_img">
 									<view v-for="(items,indexs) in item.fileUrl" class="url_css">
-										<image :src="items" mode="" class="url_img" @click="openDocument(items)">
+										<image :src="items" mode="aspectFill" class="url_img" @click="openDocument(items)">
 										</image>
 									</view>
 								</view>
@@ -774,13 +774,13 @@
 				.audit_img {
 					flex-wrap: wrap;
 					.url_css {
-						border: 1px solid #999999;
+						// border: 1px solid #999999;
 						border-radius: 10px;
 						margin-top: 10px;
 						margin-right: 10px;
 						.url_img {
-							width: 80px;
-							height: 80px;
+							width: 66px;
+							height: 66px;
 							border-radius: 10px;
 						}
 					}

+ 32 - 16
pages/task/audit/acquisitioncontract.vue

@@ -273,7 +273,7 @@
 							</view>
 							<view class="flex audit_img">
 								<view v-for="(items,indexs) in item.fileUrl" class="url_css">
-									<image :src="items" mode="" class="url_img" @click="auditFile(items)">
+									<image :src="items" mode="aspectFill" class="url_img" @click="auditFile(items)">
 									</image>
 								</view>
 							</view>
@@ -322,12 +322,14 @@
 				</view>
 				<view class="upload_css">
 					上传附件
-					<upload class="upload" ref="upload" :action="action" :max-size="maxSize" :max-count="2"
+					<upload class="upload" :width="150" ref="upload" :action="action" :max-size="maxSize" :max-count="99"
 						:size-type="['compressed']" @on-success="getImgUrl" @on-error="onError" @on-remove="onRemove"
 						@on-uploaded="isAdd = true" :before-upload="filterFileType" @on-progress="onProgress"></upload>
 				</view>
+				<view class="audit_btn">
 				<view @click='close()' class="cancel">取消</view>
 				<view @click='passSubmit()' class="confirm">确定</view>
+				</view>
 			</view>
 		</view>
 
@@ -897,7 +899,8 @@
 		width: 100%;
 		background: rgba(0, 0, 0, 0.4);
 		z-index: 3;
-
+		overflow-y: scroll;
+	
 		.wrap {
 			position: absolute;
 			left: 0;
@@ -907,9 +910,11 @@
 			margin: auto;
 			background: #fff;
 			width: calc(100% - 198rpx);
-			height: 820rpx;
+			height: 770rpx;
+			overflow-y: scroll;
+			// overflow: hidden;
 			border-radius: 20rpx;
-
+	
 			.alert-top {
 				padding: 33rpx;
 				display: flex;
@@ -917,41 +922,52 @@
 				align-items: center;
 				position: relative;
 			}
-
+	
 			.title {
 				font-size: 32rpx;
 				font-weight: 600;
 				color: #333333;
 			}
-
+	
 			.close {
 				position: absolute;
 				right: 33rpx;
 			}
+	
 			.upload_css {
 				margin-left: 20rpx;
+	
+				.upload {
+					// width: 80px;
+					// height: 80px;
+				}
 			}
 		}
 	}
-
+	
+	.audit_btn {
+		display: flex;
+		top: 0px;
+	}
+	
 	.cancel,
 	.confirm {
-		position: absolute;
-		display: inline-block;
+		// position: absolute;
+		// display: inline-block;
 		width: 50%;
 		text-align: center;
-		bottom: 0;
+		// bottom: 0;
 		padding: 10px;
 		border-top: 1px solid #eee;
 		font-size: 34rpx;
+		margin: auto;
 	}
-
+	
 	.cancel {
 		left: 0;
 		border-right: 1px solid #eee;
 		color: #AFB3BF;
 	}
-
 	.confirm {
 		right: 0;
 		color: #22C572;
@@ -1095,14 +1111,14 @@
 					margin: 0 20rpx;
 				
 					.url_css {
-						border: 1px solid #999999;
+						// border: 1px solid #999999;
 						border-radius: 10px;
 						margin-top: 10px;
 						margin-right: 10px;
 				
 						.url_img {
-							width: 80px;
-							height: 80px;
+							width: 66px;
+							height: 66px;
 							border-radius: 10px;
 						}
 					}

+ 29 - 18
pages/task/audit/charge_against_revenue.vue

@@ -269,17 +269,19 @@
 					<view class="right-bottom">
 						{{auditMind.length}}/1000个字
 					</view>
-					<u-input :clearable='false' class="" v-model='auditMind' placeholder="请在此输入审核意见" type="textarea" height="250"
+					<u-input :clearable='false' class="" v-model='auditMind' placeholder="请在此输入审核意见" type="textarea" height="240"
 						maxlength="1000" />
 				</view>
 				<view class="upload_css">
 					上传附件
-					<upload class="upload" ref="upload" :action="action" :max-size="maxSize" :max-count="2"
+					<upload class="upload" :width="150" ref="upload" :action="action" :max-size="maxSize" :max-count="99"
 						:size-type="['compressed']" @on-success="getImgUrl" @on-error="onError" @on-remove="onRemove"
 						@on-uploaded="isAdd = true" :before-upload="filterFileType" @on-progress="onProgress"></upload>
 				</view>
+				<view class="audit_btn">
 				<view @click='close()' class="cancel">取消</view>
 				<view @click='passSubmit()' class="confirm">确定</view>
+				</view>
 			</view>
 		</view>
 		<u-toast ref="uToast" />
@@ -1182,7 +1184,8 @@
 		width: 100%;
 		background: rgba(0, 0, 0, 0.4);
 		z-index: 3;
-
+		overflow-y: scroll;
+	
 		.wrap {
 			position: absolute;
 			left: 0;
@@ -1192,10 +1195,11 @@
 			margin: auto;
 			background: #fff;
 			width: calc(100% - 198rpx);
-			height: 840rpx;
+			height: 780rpx;
+			overflow-y: scroll;
+			// overflow: hidden;
 			border-radius: 20rpx;
-			// overflow: scroll;
-
+	
 			.alert-top {
 				padding: 33rpx;
 				display: flex;
@@ -1203,46 +1207,53 @@
 				align-items: center;
 				position: relative;
 			}
-
+	
 			.title {
 				font-size: 32rpx;
 				font-weight: 600;
 				color: #333333;
 			}
-
+	
 			.close {
 				position: absolute;
 				right: 33rpx;
 			}
+	
 			.upload_css {
 				margin-left: 20rpx;
+	
+				.upload {
+					// width: 80px;
+					// height: 80px;
+				}
 			}
 		}
 	}
-
+	
+	.audit_btn {
+		display: flex;
+		top: 0px;
+	}
+	
 	.cancel,
 	.confirm {
-		position: absolute;
-		display: inline-block;
+		// position: absolute;
+		// display: inline-block;
 		width: 50%;
 		text-align: center;
-		bottom: 0;
+		// bottom: 0;
 		padding: 10px;
 		border-top: 1px solid #eee;
 		font-size: 34rpx;
+		margin: auto;
 	}
-
+	
 	.cancel {
 		left: 0;
 		border-right: 1px solid #eee;
 		color: #AFB3BF;
 	}
 
-	.confirm {
-		right: 0;
-		color: #22C572;
-	}
-
 	.u-textarea-style {
 		margin: 20rpx;
 		background: #F9F9FA;

+ 30 - 14
pages/task/audit/purchasecontract.vue

@@ -296,7 +296,7 @@
 							</view>
 							<view class="flex audit_img">
 								<view v-for="(items,indexs) in item.fileUrl" class="url_css">
-									<image :src="items"  imageMode='aspectFill' class="url_img" @click="auditFile(items)"></image>
+									<image :src="items" mode='aspectFill'  imageMode='aspectFill' class="url_img" @click="auditFile(items)"></image>
 								</view>
 							</view>
 						</view>
@@ -343,12 +343,14 @@
 				</view>
 				<view class="upload_css">
 					上传附件
-					<upload class="upload" ref="upload" :action="action" :max-size="maxSize" :max-count="2"
+					<upload class="upload" :width="150" ref="upload" :action="action" :max-size="maxSize" :max-count="99"
 						:size-type="['compressed']" @on-success="getImgUrl" @on-error="onError" @on-remove="onRemove"
 						@on-uploaded="isAdd = true" :before-upload="filterFileType" @on-progress="onProgress"></upload>
 				</view>
+				<view class="audit_btn">
 				<view @click='close()' class="cancel">取消</view>
 				<view @click='passSubmit()' class="confirm">确定</view>
+				</view>
 			</view>
 		</view>
 		<view @click='imgShow=false' v-if="imgShow" class="shade">
@@ -878,7 +880,8 @@
 		width: 100%;
 		background: rgba(0, 0, 0, 0.4);
 		z-index: 3;
-
+		overflow-y: scroll;
+	
 		.wrap {
 			position: absolute;
 			left: 0;
@@ -888,9 +891,11 @@
 			margin: auto;
 			background: #fff;
 			width: calc(100% - 198rpx);
-			height: 820rpx;
+			height: 770rpx;
+			overflow-y: scroll;
+			// overflow: hidden;
 			border-radius: 20rpx;
-
+	
 			.alert-top {
 				padding: 33rpx;
 				display: flex;
@@ -898,35 +903,46 @@
 				align-items: center;
 				position: relative;
 			}
-
+	
 			.title {
 				font-size: 32rpx;
 				font-weight: 600;
 				color: #333333;
 			}
-
+	
 			.close {
 				position: absolute;
 				right: 33rpx;
 			}
+	
 			.upload_css {
 				margin-left: 20rpx;
+	
+				.upload {
+					// width: 80px;
+					// height: 80px;
+				}
 			}
 		}
 	}
+	.audit_btn {
+		display: flex;
+		top: 0px;
+	}
 
 	.cancel,
 	.confirm {
-		position: absolute;
-		display: inline-block;
+		// position: absolute;
+		// display: inline-block;
 		width: 50%;
 		text-align: center;
-		bottom: 0;
+		// bottom: 0;
 		padding: 10px;
 		border-top: 1px solid #eee;
 		font-size: 34rpx;
+		margin: auto;
 	}
-
+	
 	.cancel {
 		left: 0;
 		border-right: 1px solid #eee;
@@ -1077,14 +1093,14 @@
 					margin: 0 20rpx;
 				
 					.url_css {
-						border: 1px solid #999999;
+						// border: 1px solid #999999;
 						border-radius: 10px;
 						margin-top: 10px;
 						margin-right: 10px;
 				
 						.url_img {
-							width: 80px;
-							height: 80px;
+							width: 66px;
+							height: 66px;
 							border-radius: 10px;
 						}
 					}

+ 32 - 15
pages/task/audit/salecontract.vue

@@ -311,7 +311,7 @@
 						</view>
 						<view class="flex audit_img">
 							<view v-for="(items,indexs) in item.fileUrl" class="url_css">
-								<image :src="items" mode="" class="url_img" @click="auditFile(items)"></image>
+								<image :src="items" mode="aspectFill" class="url_img" @click="auditFile(items)"></image>
 							</view>
 						</view>
 					</view>
@@ -358,12 +358,14 @@
 				</view>
 				<view class="upload_css">
 					上传附件
-					<upload class="upload" ref="upload" :action="action" :max-size="maxSize" :max-count="2"
+					<upload class="upload" :width="150" ref="upload" :action="action" :max-size="maxSize" :max-count="99"
 						:size-type="['compressed']" @on-success="getImgUrl" @on-error="onError" @on-remove="onRemove"
 						@on-uploaded="isAdd = true" :before-upload="filterFileType" @on-progress="onProgress"></upload>
 				</view>
+				<view class="audit_btn">
 				<view @click='close()' class="cancel">取消</view>
 				<view @click='passSubmit()' class="confirm">确定</view>
+				</view>
 			</view>
 		</view>
 		<view @click='imgShow=false' v-if="imgShow" class="shade">
@@ -940,7 +942,8 @@
 		width: 100%;
 		background: rgba(0, 0, 0, 0.4);
 		z-index: 3;
-
+		overflow-y: scroll;
+	
 		.wrap {
 			position: absolute;
 			left: 0;
@@ -950,9 +953,11 @@
 			margin: auto;
 			background: #fff;
 			width: calc(100% - 198rpx);
-			height: 820rpx;
+			height: 770rpx;
+			overflow-y: scroll;
+			// overflow: hidden;
 			border-radius: 20rpx;
-
+	
 			.alert-top {
 				padding: 33rpx;
 				display: flex;
@@ -960,35 +965,47 @@
 				align-items: center;
 				position: relative;
 			}
-
+	
 			.title {
 				font-size: 32rpx;
 				font-weight: 600;
 				color: #333333;
 			}
-
+	
 			.close {
 				position: absolute;
 				right: 33rpx;
 			}
+	
 			.upload_css {
 				margin-left: 20rpx;
+	
+				.upload {
+					// width: 80px;
+					// height: 80px;
+				}
 			}
 		}
 	}
-
+	
+	.audit_btn {
+		display: flex;
+		top: 0px;
+	}
+	
 	.cancel,
 	.confirm {
-		position: absolute;
-		display: inline-block;
+		// position: absolute;
+		// display: inline-block;
 		width: 50%;
 		text-align: center;
-		bottom: 0;
+		// bottom: 0;
 		padding: 10px;
 		border-top: 1px solid #eee;
 		font-size: 34rpx;
+		margin: auto;
 	}
-
+	
 	.cancel {
 		left: 0;
 		border-right: 1px solid #eee;
@@ -1143,14 +1160,14 @@
 					margin: 0 20rpx;
 				
 					.url_css {
-						border: 1px solid #999999;
+						// border: 1px solid #999999;
 						border-radius: 10px;
 						margin-top: 10px;
 						margin-right: 10px;
 				
 						.url_img {
-							width: 80px;
-							height: 80px;
+							width: 66px;
+							height: 66px;
 							border-radius: 10px;
 						}
 					}

+ 5 - 3
pages/user/contractLook/inventoryCost.vue

@@ -69,7 +69,8 @@
 				parameter: {
 					startDate: "",
 					endDate: '',
-					warehouseName: ''
+					warehouseName: '',
+					warehouseId: ''
 				},
 				show: false,
 				mode: 'range',
@@ -124,8 +125,8 @@
 			},
 			goposition(item) {
 				uni.navigateTo({
-					url: '/pages/user/contractLook/position?warehouse=' + item.warehouseName + '&warehouseType=' +
-						item.warehouseType
+					url: '/pages/user/contractLook/position?warehouse=' + item.warehouseName + '&warehouseId=' +
+						item.warehouseId
 				})
 			},
 			cancelClick() {
@@ -205,6 +206,7 @@
 							for (let i = 0; i < results.length; i++) {
 								let _obj = {}
 								_obj.warehouseName = results[i][0].warehouseName
+								_obj.warehouseId = results[i][0].warehouseId
 								// 大于两条添加合计行
 								if (results[i].length > 1) {
 									let _price = 0

+ 20 - 25
pages/user/contractLook/position.vue

@@ -1,7 +1,7 @@
 <template>
 	<view class="content">
 		<view class="big_title">{{warehousename}}</view>
-		<view @click='goposition(item)' class="cost-list" v-for="(item,index) in costList">
+		<view class="cost-list" v-for="(item,index) in costList">
 			<view style="display: flex;justify-content: space-between;">
 				<view class="title">仓位号:{{item.binNumber}}</view>
 			</view>
@@ -12,11 +12,11 @@
 					<view class="font">储量(吨)</view>
 					<view class="font">价值(元)</view>
 				</view>
-				<view class="goods-table-content" v-for="(item1,index1) in item.warehouseNumViewList">
-					<view class="font" :class="item.warehouseNumViewList.length>1&&index1==item.warehouseNumViewList.length-1?'active':''">
+				<view class="goods-table-content" v-for="(item1,index1) in item.warehousePositionStorageInfoList">
+					<view class="font" :class="item.warehousePositionStorageInfoList.length>1&&index1==item.warehousePositionStorageInfoList.length-1?'active':''">
 						{{item1.goodsName}}
 					</view>
-					<view class="font" :class="item.warehouseNumViewList.length>1&&index1==item.warehouseNumViewList.length-1?'active':''">
+					<view class="font" :class="item.warehousePositionStorageInfoList.length>1&&index1==item.warehousePositionStorageInfoList.length-1?'active':''">
 						{{item1.storage}}
 					</view>
 					<view class="font">{{item1.cost}}</view>
@@ -65,6 +65,7 @@
 				isShowAlert: false,
 				content: '当前登录身份已失效,请重新登录!',
 				warehousename:'',
+				warehouseId: '',
 				parameter: {
 					startDate: "",
 					endDate: '',
@@ -89,6 +90,7 @@
 		},
 		onLoad: function(option) {
 			this.warehousename=option.warehouse
+			this.warehouseId=option.warehouseId
 			this.init()
 		},
 		computed: {
@@ -100,11 +102,11 @@
 					url: '/pages/public/login'
 				})
 			},
-			goposition(item){
-				uni.navigateTo({
-					url: '/pages/user/contractLook/position?warehouse='+item.warehouseName+'&warehouseType='+item.warehouseType
-				})
-			},
+			// goposition(item){
+			// 	uni.navigateTo({
+			// 		url: '/pages/user/contractLook/position?warehouse='+item.warehouseName+'&warehouseType='+item.warehouseType
+			// 	})
+			// },
 			cancelClick() {
 				this.isShowAlert = false
 			},
@@ -168,36 +170,29 @@
 					uni.showLoading({
 						title: '正在加载'
 					})
-					this.$api.doRequest('get', '/warehouseBaseInfo/selectWarehouseViewinfo', {
-						compId: uni.getStorageSync('pcUserInfo').compId,
-						warehouseType: 1,
-						warehouseName:this.warehousename
+					this.$api.doRequest('get', '/warehouseBaseInfo/getWarehouse', {
+						id:this.warehouseId
 					}).then(res => {
 						uni.hideLoading()
 						if (res.data.data) {
-							const results = res.data.data.warehouseViewList
-
+							const results = res.data.data.warehousePositionInfoList
 							for (let i = 0; i < results.length; i++) {
-								if(results[i].warehouseNumViewList.length>1){
+								if(results[i].warehousePositionStorageInfoList&&results[i].warehousePositionStorageInfoList.length>1){
 									let _price = 0
-									console.log(results[i].warehouseNumViewList)
-									for (let q = 0; q < results[i].warehouseNumViewList.length; q++) {
-										console.log(results[i].warehouseNumViewList[q])
-										_price +=Number(results[i].warehouseNumViewList[q].storage)
+									for (let q = 0; q < results[i].warehousePositionStorageInfoList.length; q++) {
+										_price +=Number(results[i].warehousePositionStorageInfoList[q].storage)
 									}
 									_price = _price.toFixed(2)
-									results[i].warehouseNumViewList.push({
+									results[i].warehousePositionStorageInfoList.push({
 										'goodsName': '合计',
 										'storage': _price
 									})
 								}
+								this.costList =results
 							}
-							this.costList =results
-						}
-
+						}				
 					})
 				}
-
 			},
 			makeGroupData(array, fn) {
 				const groups = {};

+ 4 - 3
pages/user/newReport.vue

@@ -181,12 +181,13 @@
 					</view>
 				</view>
 				<view class="btn">
-					<view class="btn-in" :class='btnIndex==1?"btn-active":""' @click="changeWeight(1)">
-						折算纯重
-					</view>
 					<view class="btn-in" :class='btnIndex==2?"btn-active":""' @click="changeWeight(2)">
 						实际重量
 					</view>
+					<view class="btn-in" :class='btnIndex==1?"btn-active":""' @click="changeWeight(1)">
+						折算纯重
+					</view>
+
 
 
 				</view>