Ver código fonte

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

wangchao 3 anos atrás
pai
commit
8ca80b9fa7

+ 4 - 4
components/code-elf-guide/code-elf-guide.vue

@@ -49,20 +49,20 @@
 			}
 		},
 		methods: {
-			launchFlag: function(){
+			launchFlag(){
 				/**
 				 * 向本地存储中设置launchFlag的值,即启动标识;
 				 */
 				uni.setStorage({
-						key: 'launchFlag',
-						data: true,
+					key: 'launchFlag',
+					data: true,
 				});
 				uni.switchTab({
 					url: '/pages/sale/information'
 				});
 				
 			},
-			swiperChange:function(e){
+			swiperChange(e){
 				this.currentSwiper=e.detail.current
 				if(e.detail.current==2){
 					this.show=true

+ 1 - 1
components/uview-ui/libs/util/province.js

@@ -1 +1 @@
-var provinceData=[{"label":"北京市","value":"11"},{"label":"天津市","value":"12"},{"label":"河北省","value":"13"},{"label":"山西省","value":"14"},{"label":"内蒙古自治区","value":"15"},{"label":"辽宁省","value":"21"},{"label":"吉林省","value":"22"},{"label":"黑龙江省","value":"23"},{"label":"上海市","value":"31"},{"label":"江苏省","value":"32"},{"label":"浙江省","value":"33"},{"label":"安徽省","value":"34"},{"label":"福建省","value":"35"},{"label":"江西省","value":"36"},{"label":"山东省","value":"37"},{"label":"河南省","value":"41"},{"label":"湖北省","value":"42"},{"label":"湖南省","value":"43"},{"label":"广东省","value":"44"},{"label":"广西壮族自治区","value":"45"},{"label":"海南省","value":"46"},{"label":"重庆市","value":"50"},{"label":"四川省","value":"51"},{"label":"贵州省","value":"52"},{"label":"云南省","value":"53"},{"label":"西藏自治区","value":"54"},{"label":"陕西省","value":"61"},{"label":"甘肃省","value":"62"},{"label":"青海省","value":"63"},{"label":"宁夏回族自治区","value":"64"},{"label":"新疆维吾尔自治区","value":"65"},{"label":"台湾","value":"66"},{"label":"香港","value":"67"},{"label":"澳门","value":"68"}];export default provinceData;
+var provinceData=[{"label":"北京市","value":"110000"},{"label":"天津市","value":"120000"},{"label":"河北省","value":"130000"},{"label":"山西省","value":"140000"},{"label":"内蒙古自治区","value":"150000"},{"label":"辽宁省","value":"210000"},{"label":"吉林省","value":"220000"},{"label":"黑龙江省","value":"230000"},{"label":"上海市","value":"310000"},{"label":"江苏省","value":"320000"},{"label":"浙江省","value":"330000"},{"label":"安徽省","value":"340000"},{"label":"福建省","value":"350000"},{"label":"江西省","value":"360000"},{"label":"山东省","value":"370000"},{"label":"河南省","value":"410000"},{"label":"湖北省","value":"420000"},{"label":"湖南省","value":"430000"},{"label":"广东省","value":"440000"},{"label":"广西壮族自治区","value":"450000"},{"label":"海南省","value":"460000"},{"label":"重庆市","value":"500000"},{"label":"四川省","value":"510000"},{"label":"贵州省","value":"520000"},{"label":"云南省","value":"530000"},{"label":"西藏自治区","value":"540000"},{"label":"陕西省","value":"610000"},{"label":"甘肃省","value":"620000"},{"label":"青海省","value":"630000"},{"label":"宁夏回族自治区","value":"640000"},{"label":"新疆维吾尔自治区","value":"650000"},{"label":"台湾省","value":"710000"},{"label":"香港特别行政区","value":"810000"},{"label":"澳门特别行政区","value":"820000"}];export default provinceData;

+ 3 - 1
pageA/product/trade.vue

@@ -44,7 +44,7 @@
 						<view class="title">{{minimumVolume}}</view>
 					</view>
 				</view>
-				<view class="c-row">
+				<view v-if='' class="c-row">
 					<text class="tit">今日基差(元/吨)</text>
 					<view class="con-list">
 						<view class="title">{{basisPrice}}</view>
@@ -136,6 +136,7 @@
 					receivePrivate:'',
 					receiveCity:'',
 					receiveArea:'',
+					procurementPlanType:'',
 					minimumVolume:0,
 					basisPrice:0,
 					pcFlag:0,
@@ -194,6 +195,7 @@
 				};
 			},
 			onLoad(options) {
+				this.procurementPlanType = options.procurementPlanType
 				this.receiveWarehouse=options.receiveWarehouse
 				this.receivePrivate=options.receivePrivate
 				this.receiveCity=options.receiveCity

+ 5 - 12
pageD/identity/companyIdentityThree.vue

@@ -371,18 +371,12 @@
 																				icon: 'none',
 																				duration: 2000
 																			})
-																			uni.navigateTo({
-																				url: `/pages/attestation/indexTwo`,
+																			uni.navigateBack({
+																				delta:3
 																			})
 																		}
 																	})
-															} else if (res.cancel) {
-																uni.showToast({
-																	title: '提交失败',
-																	icon: 'none',
-																	duration: 2000
-																})
-															}
+															} 
 														}
 													});
 												} else if (res.data.code == 200) {
@@ -396,9 +390,8 @@
 																	icon: 'none',
 																	duration: 2000
 																})
-																uni.navigateTo({
-																	url: `/pages/attestation/indexTwo`,
-
+																uni.navigateBack({
+																	delta:3
 																})
 															}
 														})

+ 5 - 29
pageD/identity/driverIdentityThree.vue

@@ -123,8 +123,8 @@
 																		icon: 'none',
 																		duration: 2000
 																	})
-																	uni.navigateTo({
-																		url: `/pages/attestation/indexThree`
+																	uni.navigateBack({
+																		delta:3
 																	})
 																} else if (res.data.code ==
 																	'ERROR002') {
@@ -132,25 +132,14 @@
 																		title: '提示',
 																		content: '司机身份证号重复,添加失败',
 																	});
-																	uni.navigateTo({
-																		url: `/pages/attestation/indexThree`
-																	})
 																} else if (res.data.code == 'ERROR003') {
 																	uni.showModal({
 																		title: '提示',
 																		content: '收款人身份证号重复,添加失败',
 																	});
-																	uni.navigateTo({
-																		url: `/pages/attestation/indexThree`
-																	})
+																	
 																}
 															})
-														} else if (res.cancel) {
-															uni.showToast({
-																title: '提交失败',
-																icon: 'none',
-																duration: 2000
-															})
 														}
 													}
 												});
@@ -162,34 +151,21 @@
 																icon: 'none',
 																duration: 2000
 															})
-															uni.navigateTo({
-																url: `/pages/attestation/indexThree`
+															uni.navigateBack({
+																delta:3
 															})
 														} else if (res.data.code =='ERROR002') {
 															uni.showModal({
 																title: '提示',
 																content: '司机身份证号重复,添加失败',
 															});
-															uni.navigateTo({
-																url: `/pages/attestation/indexThree`
-															})
 														} else if (res.data.code == 'ERROR003') {
 															uni.showModal({
 																title: '提示',
 																content: '收款人身份证号重复,添加失败',
 															});
-															uni.navigateTo({
-																url: `/pages/attestation/indexThree`
-															})
 														}
 													})
-												// } else if (res.cancel) {
-												// 	uni.showToast({
-												// 		title: '提交失败',
-												// 		icon: 'none',
-												// 		duration: 2000
-												// 	})
-												// }
 											}
 										}).catch(res => {
 											uni.showToast({

+ 8 - 6
pageD/myRelease/buyGrain.vue

@@ -205,16 +205,18 @@
 				typesType: ["现货", "期货"],
 				typesIndex: 0,
 				deptList: {
-					salePlanTypeKey: 0,
-					grainKey: 0,
-					gradeKey: 0,
-					packingTypeKey: 0,
-					freightPayerKey: 0,
+					// salePlanTypeKey: 0,
+					// grainKey: 0,
+					// gradeKey: 0,
+					// packingTypeKey: 0,
+					// freightPayerKey: 0,
 					priceType: "定价采购",
+					priceTypeKey: 2,
 					procurementPlanType: "现货",
+					procurementPlanTypeKey: 1,
 					grain: "",
 					grade: "",
-					outputYear: "",
+					// outputYear: "",
 					packingType: "",
 					freightPayer: "",
 				},

+ 6 - 5
pageD/myRelease/sellGrain.vue

@@ -202,12 +202,13 @@
 				typesIndex: 0,
 				deptList: {
 					salePlanType: '现货',
-					salePlanTypeKey: 0,
-					grainKey: 0,
-					gradeKey: 0,
-					packingTypeKey: 0,
-					freightPayerKey: -1,
+					salePlanTypeKey: 1,
+					// grainKey: 0,
+					// gradeKey: 0,
+					// packingTypeKey: 0,
+					// freightPayerKey: -1,
 					priceType: "定价销售",
+					priceTypeKey: 2,
 					 grain: "",
 					grade: "一等品",
 					packingType: "散装",

+ 12 - 11
pageD/warehousings/ex_warehouse.vue

@@ -425,7 +425,6 @@
 			},
 			warehouseChange1(e) {
 				var id = ''
-				
 				this.warehouseIndex1 = e.detail.value
 				this.WarehouseInOutInfo.binNumberKey = this.warehouseIndex1
 				this.WarehouseInOutInfo.binNumber = this.warehouse1[this.warehouseIndex1]
@@ -504,13 +503,12 @@
 						return
 					}
 				}
-				if (this.list.bulkDensity && this.list.bulkDensity < 1 || this.list.bulkDensity && this.list.bulkDensity >
-					40) {
+				if(this.list.bulkDensity&&this.list.bulkDensity<500||this.list.bulkDensity&&this.list.bulkDensity>1000){
 					this.$api.msg('容重输入错误')
 					return
 				}
-				if (this.list.bulkDensity && this.list.bulkDensity.indexOf('.') != -1) {
-					if (this.list.bulkDensity.split('.')[1].length > 2) {
+				if(this.list.bulkDensity&&this.list.bulkDensity.indexOf('.')!=-1){
+					if(this.list.bulkDensity.split('.')[1].length>2){
 						this.$api.msg('容重输入错误')
 						return
 					}
@@ -612,7 +610,7 @@
 					return
 				}
 				if (!this.WarehouseInOutInfo.binNumber) {
-					this.$api.msg('仓不能为空')
+					this.$api.msg('仓位号不能为空')
 					return
 				}
 				if (this.WarehouseInOutInfo.grossWeight > 100 || this.WarehouseInOutInfo.grossWeight < 1) {
@@ -661,13 +659,12 @@
 						return
 					}
 				}
-				if (this.list.bulkDensity && this.list.bulkDensity < 1 || this.list.bulkDensity && this.list.bulkDensity >
-					40) {
+				if(this.list.bulkDensity&&this.list.bulkDensity<500||this.list.bulkDensity&&this.list.bulkDensity>1000){
 					this.$api.msg('容重输入错误')
 					return
 				}
-				if (this.list.bulkDensity && this.list.bulkDensity.indexOf('.') != -1) {
-					if (this.list.bulkDensity.split('.')[1].length > 2) {
+				if(this.list.bulkDensity&&this.list.bulkDensity.indexOf('.')!=-1){
+					if(this.list.bulkDensity.split('.')[1].length>2){
 						this.$api.msg('容重输入错误')
 						return
 					}
@@ -721,7 +718,11 @@
 				this.WarehouseInOutInfo.warehouseInOutDetail = this.list
 				this.WarehouseInOutInfo.statusFlag = 3
 				this.WarehouseInOutInfo.pcFlag = 0
-				// this.WarehouseInOutInfo.baseId=0
+				for(let i = 0 ;i < this.warehouselist.length ; i++){
+					if(this.warehouselist[i].warehouseName == this.WarehouseInOutInfo.warehouseName){
+						this.WarehouseInOutInfo.baseId = this.warehouselist[i].id
+					}
+				}
 				this.WarehouseInOutInfo.taskType = "出库任务"
 				uni.showLoading({
 					title: "正在提交"

+ 9 - 5
pageD/warehousings/warehousings.vue

@@ -55,6 +55,7 @@
 					<text class="tit">仓库</text>
 					<view style="color: #ff0000; padding-left: 10rpx;">*</view>
 					<view class="con-list">
+						
 						<picker @change="warehouseChange" :value="warehouseIndex" :range="warehouse" class="con-list">
 							<view >
 								{{warehouseIndex>-1?warehouse[warehouseIndex]:'请选择仓库'}}
@@ -77,7 +78,7 @@
 				<view class="c-row b-b">
 					<text class="tit">入库类型 </text>
 					<picker @change="ruChange" :value="ruIndex" :range="ruType" class="con-list">
-						<view >
+						<view v-model="WarehouseInOutInfo.inOutType">
 							 {{ruIndex > -1?ruType[ruIndex]:'请选择入库类型'}} 
 						</view>
 					</picker>
@@ -210,6 +211,8 @@ import upload from '@/components/upload.vue';
 					pcFlag: 0,
 					contractNo: {},
 					carNo: {},
+					inOutType:'采购入库',
+					inOutTypeKey:1,
 				},
 				WarehouseInOutInfo1: {
 					contractNo: {},
@@ -218,7 +221,7 @@ import upload from '@/components/upload.vue';
 				pinIndex: -1,
 				pinTypes: '',
 				pinType: ['一等品', '二等品', '三等品', '等外'],
-				ruIndex: -1,
+				ruIndex: 0,
 				rutypes: '',
 				warehouse:[],
 				warehouseIndex:-1,
@@ -337,8 +340,9 @@ import upload from '@/components/upload.vue';
 					if(this.WarehouseInOutInfo.inOutTypeKey != null){
 						this.ruIndex = this.WarehouseInOutInfo.inOutTypeKey 
 					}
-					
-					this.WarehouseInOutInfo.deductionAmount = Math.abs(res.data.data.deductionAmount) 
+					if(this.WarehouseInOutInfo.deductionAmount!=null){
+						this.WarehouseInOutInfo.deductionAmount = Math.abs(res.data.data.deductionAmount) 
+					}
 				})
 				.catch(res => {
 					if(res.errmsg){
@@ -563,7 +567,7 @@ import upload from '@/components/upload.vue';
 					return
 				}
 				if(!this.WarehouseInOutInfo.binNumber){
-					this.$api.msg('仓不能为空')
+					this.$api.msg('仓位号不能为空')
 					return
 				}
 				if(this.WarehouseInOutInfo.grossWeight>100||this.WarehouseInOutInfo.grossWeight<1){

+ 7 - 1
pages/attestation/indexTwo.vue

@@ -111,7 +111,7 @@
 		computed: {
 			...mapState(['hasLogin', 'userInfo'])
 		},
-		onLoad() {
+		onshow() {
 			this.getList()
 		},
 		onPullDownRefresh() {
@@ -199,6 +199,12 @@
 								res.data.data.records[i].basis = "true"
 							}
 						}
+						var data = res.data.data.records
+						for(var i=0;i<data.length;i++){
+							if(data[i].compName.length > 10){
+								data[i].compName = data[i].compName.substring(0,10) + "..."
+							}
+						}
 						this.businessman = res.data.data.records
 
 					})

+ 6 - 6
pages/index/index.vue

@@ -19,7 +19,7 @@
 			this.loadExecution()
 		},
 		methods: {
-			loadExecution: function(){
+			loadExecution(){
 				/**
 				 * 获取本地存储中launchFlag的值
 				 * 若存在,说明不是首次启动,直接进入首页;
@@ -29,9 +29,13 @@
 					// 获取本地存储中launchFlag标识
 				    const value = uni.getStorageSync('launchFlag');
 				    if (value) {
+						uni.setStorage({
+							key: 'launchFlag',
+							data: true,
+						});
 						// launchFlag=true直接跳转到首页
 						uni.switchTab({
-							url: '/pages/tabBar/component/component'
+							url: '/pages/sale/information'
 						});
 				    } else {
 						// launchFlag!=true显示引导页
@@ -48,10 +52,6 @@
 					}); 
 					this.guidePages = true
 				}
-				return;
-				uni.switchTab({
-				    url: '/pages/tabBar/component/component'
-				});
 			}
 		}
 	}