Bläddra i källkod

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

wangchao 3 år sedan
förälder
incheckning
5ea83adb98

+ 1 - 1
config/index.js

@@ -1,6 +1,6 @@
 const dev = {
 	baseUrl: 'https://www.zthymaoyi.com',
-	baseUrlNew: 'http://api1.eliangeyun.com/',
+	baseUrlNew: 'http://192.168.1.117:8090/',
 	// baseUrlNew: 'http://192.168.1.119:9100/',
 	// baseUrlNew: 'http://api1.eliangeyun.com/',
 	h5Appid: 'wxb66b599f7f61b46f',

+ 11 - 0
pages/erpbusiness/acquisitionInspection/tareDetail.vue

@@ -49,6 +49,16 @@
 				<view class="left">净重(公斤)</view>
 				<input class="right-bottom" disabled placeholder="自动计算" v-model="detailData.netWeight"></input>
 			</view>
+			<view  class="row row-bottom">
+				<view class="left">应收卸车过磅费(元)</view>
+				<input disabled class="right-bottom" placeholder="未获取到卸车过磅费金额"
+					v-model="detailData.receivableWeighingFee"></input>
+			</view>
+			<view class="row row-bottom" style="border: 0;">
+				<view class="left">实收卸车过磅费(元)</view>
+				<input disabled class="right-bottom" placeholder="输入卸车过磅费"
+					v-model="detailData.actualWeighingFee"></input>
+			</view>
 		</view>
 		<u-button type="primary" class="submit" @click="submit">提交</u-button>
 		<u-toast ref="uToast" />
@@ -79,6 +89,7 @@
 		},
 		onLoad(options) {
 			this.detailData = JSON.parse(options.detailData)
+			console.log(this.detailData)
 			if (!this.detailData.buckleMiscellaneous) {
 				this.detailData.buckleMiscellaneous = 0
 			}

+ 13 - 1
pages/erpbusiness/add_quality_testing.vue

@@ -102,7 +102,10 @@
 		</view>
 		<view style='padding-bottom:300rpx;'>
 			<view class='wrap'>
-				<view class='title_b'>化验信息</view>
+				<view style='margin-right:10px;' class='flex justify-between align-item-center'>
+					<view class='title_b'>化验信息</view>
+					<view class='flex justify-between align-item-center'>补录:<u-switch activeColor="#22C572" v-model="value" @change="change"></u-switch></view>
+				</view>
 
 				<view class="c-row ">
 					<view class="title">等级</view>
@@ -216,6 +219,7 @@
 				show2: false,
 				goodsList: [],
 				currentPage: 1,
+				value:false,
 				gridBorder: false,
 				headUrl: "../../static/img/myimg/YongHu@3x.png",
 				userphone: "",
@@ -362,6 +366,14 @@
 			})
 		},
 		methods: {
+			change(e){
+				if(e){
+					this.gridList.supplementaryRecording=1
+				}else{
+					this.gridList.supplementaryRecording=0
+				}
+				
+			},
 			print(){
 				uni.navigateTo({
 					url: '/pages/erpbusiness/bleConnect'

+ 20 - 9
pages/erpbusiness/bleConnect.vue

@@ -33,8 +33,17 @@
 		},
 		computed: mapState(['sysinfo', 'Bluetooth']),
 		onLoad() {
-			// console.log(this.Bluetooth)
+			
+			
 			
+		},
+		onShow() {
+			// if(this.Bluetooth){
+			// 	uni.navigateTo({
+			// 		url: '/pages/erpbusiness/sendCommand'
+			// 	})
+			// }
+		console.log(this.Bluetooth)
 		},
 		onUnload() {
 			//停止搜索蓝牙设备
@@ -153,9 +162,9 @@
 			//校验权限
 			checkPemission() {
 				let that = this
-				let {
+				let 
 					BLEInformation
-				} = that.Bluetooth;
+				 = that.Bluetooth;
 				let platform = BLEInformation.platform;
 				that.getBluetoothDevices();
 			},
@@ -215,9 +224,9 @@
 				let {
 					title
 				} = e.currentTarget.dataset;
-				let {
+				let 
 					BLEInformation
-				} = that.Bluetooth;
+				 = that.Bluetooth;
 				this.stopSearch();
 				
 				that.serviceId = 0;
@@ -235,6 +244,7 @@
 						console.log('createBLEConnection success:', res)
 						BLEInformation.deviceId = title;
 						that.$store.commit('BLEInformationSet', BLEInformation);
+						// console.log(this.Bluetooth,)
 						uni.hideLoading()
 						that.getSeviceId()
 					},
@@ -247,9 +257,9 @@
 			//获取蓝牙设备所有服务(service)。
 			getSeviceId() {
 				let that = this;
-				let {
+				let 
 					BLEInformation
-				} = that.Bluetooth;
+				 = that.Bluetooth;
 				console.log('BLEInformation.deviceId:',BLEInformation.deviceId)
 				// uni.getBLEDeviceServices
 				let t=setTimeout(()=>{
@@ -277,9 +287,9 @@
 					readCharacter: read,
 					notifyCharacter: notify
 				} = that;
-				let {
+				let 
 					BLEInformation
-				} = that.Bluetooth;
+				 = that.Bluetooth;
 				// uni.getBLEDeviceCharacteristics
 				plus.bluetooth.getBLEDeviceCharacteristics({
 					deviceId: BLEInformation.deviceId,
@@ -329,6 +339,7 @@
 								that.getCharacteristics()
 							}
 						} else {
+							that.$store.commit('BLEInformationSet', BLEInformation);
 							that.openControl()
 						}
 					},

+ 25 - 4
pages/erpbusiness/edit_quality_testing.vue

@@ -71,7 +71,7 @@
 			</view>
 			<view class="c-row ">
 				<view class="title">货名</view>
-				<view class="con-list">
+				<view  class="con-list">
 					 <!-- <view v-if="flag != '0'">
 						{{gridList.goodsName}}
 					</view> -->
@@ -103,13 +103,21 @@
 				<view style="margin: 0px 0px 30rpx 10rpx;">复检备注</view>
 					<textarea class='textarea-style' v-model='gridList.reMemo' placeholder="请输入复检备注" maxlength="300"></textarea>
 			</view>
-			
+			<view class="c-row" v-if="flag==1&&gridList.warehouseName=='鲅鱼圈金信库'">
+				<view class="title">车型</view>
+				<view class="con-list">
+					<view @click='carstatus = true'>{{gridList.carModel?gridList.carModel:'请选择车型'}}</view>
+				<u-picker :range="carModeList" range-key="constValue" @confirm='carPicker($event)' v-model="carstatus" mode="selector" >
+				</u-picker>
+				</view>
+				
+			</view>
 		</view>
 		<view style='padding-bottom:300rpx;'>
 			<view class='wrap'>
 				<view style='margin-right:10px;' class='flex justify-between align-item-center'>
 					<view class='title_b'>化验信息</view>
-					<u-switch v-if='flag!=1' v-model="value" @change="change"></u-switch>
+					<view class='flex justify-between align-item-center'>补录:<u-switch activeColor="#22C572" v-if='flag==0' v-model="value" @change="change"></u-switch></view>
 				</view>
 				<view class="c-row ">
 					<view class="title">等级</view>
@@ -212,6 +220,7 @@
 				selector: [],
 				show1: false,
 				goodsName:false,
+				carstatus:false,
 				inputContent: '',
 				coverTransform: 'translateY(0px)',
 				coverTransition: '0s',
@@ -235,7 +244,8 @@
 					type: '潮粮',
 					tidalGrainPrice: '',
 					dryGrainPrice: '',
-					carNumber:''
+					carNumber:'',
+					carModel:'',
 				},
 				managementType: '',
 				warehouseName: '',
@@ -244,6 +254,7 @@
 				companyId: 1,
 				current: 4,
 				value:false,
+				carModeList:[],
 				gradeList: [{
 						key: 1,
 						value: '一等品'
@@ -325,6 +336,13 @@
 					})
 				}
 			})
+			this.$api.doRequest('get', 'commonSysParameter/getInfo', {
+				constId: 'QUA1'
+			}).then(res => {
+				if (res.data.data) {
+					that.carModeList=res.data.data
+				}
+			})
 			//质检货名下拉
 			this.$api.doRequest('get', '/qualityInspectionManagement/api/goodsName', {
 				 warehouseId: this.cangid
@@ -356,6 +374,9 @@
 			hidden(){
 				this.$refs.keyboard.open(false)
 			},
+			carPicker(e){
+				this.gridList.carModel=this.carModeList[e[0]].constValue
+			},
 			handleShowKeyboard(){
 				if(this.flag==0){
 					if(this.$refs.keyboard.open){

+ 12 - 0
store/bluetooth/index.js

@@ -0,0 +1,12 @@
+let sysinfo = uni.getSystemInfoSync();
+const Bluetooth = {
+	state: {
+		//蓝牙信息
+		
+	},
+	mutations:{
+		
+	}
+}
+
+export default Bluetooth;

+ 5 - 1
store/index.js

@@ -47,6 +47,7 @@ const store = new Vuex.Store({
 		sysinfo: uni.getSystemInfoSync(),//系统信息
 		enter:{},
 		hasLogin: false,
+		BLEInformation: {},
 		// 如果上面从本地获取的lifeData对象下有对应的属性,就赋值给state中对应的变量
 		pushRes:lifeData.pushRes?lifeData.pushRes: {},
 		//期货数据获取
@@ -128,7 +129,10 @@ const store = new Vuex.Store({
 			state.userInfo = provider;
 			uni.setStorageSync('userInfo', provider)
 		},
-		
+		BLEInformationSet(state, info){
+			console.log(info)
+			state.BLEInformation = info;
+		},
 		logout(state) {
 			state.hasLogin = false;
 			state.userInfo = {};