ccj 3 năm trước cách đây
mục cha
commit
cb1f17e735

+ 12 - 14
App.vue

@@ -113,34 +113,32 @@
 				}).show();
 				var userInfo = uni.getStorageSync("userInfo")
 				var that = this
-				this.$api.doRequest('get', '/salePlanInfo/getTips', {
-					phone: userInfo.phone
-				}).then(res => {
+				this.$api.doRequest('get', '/notice/query/noticeNumber').then(res => {
 					if (res.data.data) {
 						let name = 'myTip';
-						let value = res.data.data.myTip;
+						let value = res.data.data.task;
 						that.$store.commit('$uStore', {
 							name,
 							value
 						});
-						if (value != 0) {
+						if(value != 0&&value){
 							uni.setTabBarBadge({
-								index: 4,
-								text: value + ""
+								index:4,
+								text:value+""
 							})
 						}
 						name = 'taskTip';
-						value = res.data.data.taskTip;
-						that.$store.commit('$uStore', {
-							name,
-							value
-						});
-						name = 'contractTip';
-						value = res.data.data.contractTip;
+						value = res.data.data.task;
 						that.$store.commit('$uStore', {
 							name,
 							value
 						});
+						// name = 'contractTip';
+						// value = res.data.data.contractTip;
+						// that.$store.commit('$uStore', {
+						// 	name,
+						// 	value
+						// });
 					}
 				})
 				//其它逻辑  

+ 1 - 1
config/index.js

@@ -1,7 +1,7 @@
 const dev = {
 	baseUrl: 'https://www.zthymaoyi.com',
 	// baseUrlNew: 'http://192.168.1.120:8090/',
-	// baseUrlNew: 'http://192.168.1.102:9100/',
+	// baseUrlNew: 'http://192.168.1.109:9100/',
 	baseUrlNew: 'http://api1.eliangeyun.com/',
 	h5Appid: 'wxb66b599f7f61b46f',
 	debug: false

+ 2 - 2
manifest.json

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

+ 7 - 4
pageD/identity/companyIdentityThree.vue

@@ -3,14 +3,14 @@
 		<view>
 			<!-- 上传银行卡正面 -->
 			<upload class="upload" ref="upload" :action="action" :max-size="maxSize" :max-count="1"
-				:size-type="['compressed']" @on-success="getImgUrl" @on-error="onError" @on-remove="onRemove"
+				:size-type="['compressed']" @on-success="getImgUrl"  @on-remove="onRemove"
 				@on-uploaded="isAdd = true" :before-upload="filterFileType" :options="uploadOptions"
-				:custom="uploadCustom" @on-progress="onProgress"></upload>
+				:custom="uploadCustom"></upload>
 			<!-- 上传银行卡反面 -->
 			<upload class="upload" ref="upload" :action="action" :max-size="maxSize" :max-count="1"
-				:size-type="['compressed']" @on-success="getImgUrl1" @on-error="onError" @on-remove="onRemove"
+				:size-type="['compressed']" @on-success="getImgUrl1"  @on-remove="onRemove"
 				@on-uploaded="isAdd = true" :before-upload="filterFileType" :options="uploadOptions1"
-				:custom="uploadCustom" @on-progress="onProgress"></upload>
+				:custom="uploadCustom" ></upload>
 		</view>
 		<view class="c-row b-b">
 			<text class="tit">银行卡号</text>
@@ -356,6 +356,7 @@
 									phone: that.identityAuthenticationInfo.customerPhone,
 									verifyCode: that.verifyCode
 								}).then(res => {
+									console.log("loginVerifyCode:",res)
 									if (res.data.code == 200) {
 										if (that.userInfo) {
 											that.identityAuthenticationInfo.commonId = that.userInfo.id
@@ -370,6 +371,7 @@
 												'/identityAuthenticationInfo/selectPhone', that
 												.identityAuthenticationInfos)
 											.then(res => {
+												console.log("selectPhone:",res)
 												if (res.data.code == '11018') {
 													uni.showModal({
 														title: '提示',
@@ -401,6 +403,7 @@
 															'/identityAuthenticationInfo/api/addIdentityAuthenticationInfo',
 															that.identityAuthenticationInfo)
 														.then(res => {
+															console.log("addIdentityAuthenticationInfo:",res)
 															if (res.data.code == 200) {
 																uni.showToast({
 																	title: '提交成功',

+ 4 - 4
pageD/identity/companyIdentityTwo.vue

@@ -3,14 +3,14 @@
 		<view>
 			<!-- 个人身份证正面 -->
 			<upload class="upload" ref="upload" :action="action" :max-size="maxSize" :max-count="1"
-				:size-type="['compressed']" @on-success="getImgUrl1" @on-error="onError" @on-remove="onRemove"
+				:size-type="['compressed']" @on-success="getImgUrl1"  @on-remove="onRemove"
 				@on-uploaded="isAdd = true" :before-upload="filterFileType" :options="uploadOptions1"
-				:custom="uploadCustom1" @on-progress="onProgress"></upload>
+				:custom="uploadCustom1" ></upload>
 			<!-- 个人身份证反面 -->
 			<upload class="upload" ref="upload" :action="action" :max-size="maxSize" :max-count="1"
-				:size-type="['compressed']" @on-success="getImgUrl2" @on-error="onError" @on-remove="onRemove"
+				:size-type="['compressed']" @on-success="getImgUrl2"  @on-remove="onRemove"
 				@on-uploaded="isAdd = true" :before-upload="filterFileType" :options="uploadOptions2"
-				:custom="uploadCustom1" @on-progress="onProgress"></upload>
+				:custom="uploadCustom1" ></upload>
 		</view>
 		<view class="c-row b-b">
 			<text class="tit">姓名</text>

+ 12 - 14
pages/business/business.vue

@@ -150,34 +150,32 @@
 			// 	})
 			// }, 500);
 			
-			this.$api.doRequest('get', '/salePlanInfo/getTips', {
-				phone: userInfo.phone
-			}).then(res => {
+			this.$api.doRequest('get', '/notice/query/noticeNumber').then(res => {
 				if (res.data.data) {
 					let name = 'myTip';
-					let value = res.data.data.myTip;
+					let value = res.data.data.task;
 					that.$store.commit('$uStore', {
 						name,
 						value
 					});
-					if (value != 0) {
+					if(value != 0&&value){
 						uni.setTabBarBadge({
-							index: 4,
-							text: value + ""
+							index:4,
+							text:value+""
 						})
 					}
 					name = 'taskTip';
-					value = res.data.data.taskTip;
-					that.$store.commit('$uStore', {
-						name,
-						value
-					});
-					name = 'contractTip';
-					value = res.data.data.contractTip;
+					value = res.data.data.task;
 					that.$store.commit('$uStore', {
 						name,
 						value
 					});
+					// name = 'contractTip';
+					// value = res.data.data.contractTip;
+					// that.$store.commit('$uStore', {
+					// 	name,
+					// 	value
+					// });
 				}
 			})
 		},

+ 1 - 1
pages/grain_pulse/home.vue

@@ -131,7 +131,7 @@
 			uni.getStorage({
 				key: 'setLocaltion',
 				success: (res) => {
-					console.log(res.data)
+					console.log("setLocaltion",res.data)
 					this.position = res.data
 					// uni.removeStorage({
 					// 	key: 'setLocaltion'

+ 27 - 3
pages/grain_pulse/position/position.vue

@@ -13,7 +13,7 @@
 				当前定位
 			</view>
 			<view class="header2-content">
-				<view class="left Medium">
+				<view class="left Medium" @click="selectPosition">
 					<u-icon name="arrow-down"></u-icon>
 					<view class="">{{address}}</view>
 					<view class="" v-if="isposition">{{text}}</view>
@@ -78,7 +78,8 @@
 				},
 				positionType: {
 					type: ""
-				}
+				},
+				location:{}
 			}
 		},
 		onShow() {
@@ -193,12 +194,15 @@
 						console.log('当前位置的纬度:' + res.latitude);
 						//拼接当前定位回显地址
 						// #ifdef APP-PLUS
+						that.location = res
 						let _address = res.address
 						// that.city = _address.city
 						that.seach.longitude = res.longitude
 						that.seach.latitude = res.latitude
 						that.address = _address.province + _address.city + _address.district + _address
 							.poiName
+						that.searchAddress(_address.poiName)
+						that.addressName = _address.poiName
 						console.log(that.address)
 						// #endif
 					},
@@ -221,6 +225,7 @@
 							console.log('当前位置的经度:' + res.longitude);
 							console.log('当前位置的纬度:' + res.latitude);
 							// #ifdef APP-PLUS
+							that.location = res
 							let _address = res.address
 							that.city = _address.city
 							that.seach.longitude = res.longitude
@@ -228,6 +233,8 @@
 							that.address = _address.province + _address.city + _address
 								.district +
 								_address.poiName
+							that.searchAddress(_address.poiName)
+							that.addressName = _address.poiName
 							// #endif
 						}
 					});
@@ -308,7 +315,7 @@
 					url: 'https://restapi.amap.com/v5/place/text',
 					data: parameters,
 					success: (res) => {
-						console.log(res.data);
+						console.log("searchAddress",res.data);
 						this.searchList = res.data.pois
 						this.getStringColorReplace(res.data.pois, val)
 					}
@@ -320,6 +327,23 @@
 					url: "../selectCity/selectCity"
 				})
 			},
+			selectPosition(){
+				// uni.setStorage({
+				// 	key: 'setPosition',
+				// 	data: this.location,
+				// 	success: (res) => {
+				// 		uni.setStorage({
+				// 			key: 'setLocaltion',
+				// 			data: this.location,
+				// 			success: (res) => {
+				// 				uni.navigateBack({
+									
+				// 				})
+				// 			},
+				// 		})
+				// 	}
+				// })
+			},
 			toHome(item) {
 				uni.setStorage({
 					key: 'setPosition',

+ 13 - 0
pages/grain_pulse/release.vue

@@ -169,10 +169,14 @@
 									confirmText: '确定',
 									success: function(res) {
 										if (res.confirm) {
+											uni.showLoading({
+												title:"正在提交"
+											})
 											that.$api.doRequest('post',
 													'/settledCompanyDynamics/api/addSettledCompanyDynamics',
 													that.release)
 												.then(res => {
+													console.log("addSettledCompanyDynamics",res)
 													if (res.data.code == 200) {
 														uni.showToast({
 															title: '发布成功!',
@@ -185,6 +189,15 @@
 															}
 														})
 													}
+													uni.hideLoading()
+												})
+												.catch(res => {
+													uni.showToast({
+														title: '系统异常,请联系管理员',
+														icon: 'none',
+														duration: 2000
+													})
+													uni.hideLoading()
 												})
 										}
 									}

+ 33 - 45
pages/sale/information.vue

@@ -179,34 +179,52 @@
 			this.loadData()
 			var userInfo = uni.getStorageSync("userInfo")
 			var that = this
-			this.$api.doRequest('get', '/salePlanInfo/getTips', {
-				phone: userInfo.phone
-			}).then(res => {
+			this.$api.doRequest('get', '/commonUser/api/checkSession').then(res => {
+				console.log("checkSession",res)
+				if (res.data.data == "INVALID") {
+					uni.showModal({
+						title: '登录提示',
+						content: 'Session过期需要重新登录,是否立即登录?',
+						showCancel: true,
+						confirmText: '登录',
+						success: (e) => {
+							if (e.confirm) {
+								uni.navigateTo({
+									url: '/pages/public/login'
+								})
+							}
+						},
+						fail: () => {},
+						complete: () => {}
+					})
+				}
+			})
+			this.$api.doRequest('get', '/notice/query/noticeNumber').then(res => {
 				if (res.data.data) {
 					let name = 'myTip';
-					let value = res.data.data.myTip;
+					let value = res.data.data.task;
 					that.$store.commit('$uStore', {
 						name,
 						value
 					});
-					if (value != 0) {
+					if(value != 0&&value){
 						uni.setTabBarBadge({
-							index: 4,
-							text: value + ""
+							index:4,
+							text:value+""
 						})
 					}
 					name = 'taskTip';
-					value = res.data.data.taskTip;
-					that.$store.commit('$uStore', {
-						name,
-						value
-					});
-					name = 'contractTip';
-					value = res.data.data.contractTip;
+					value = res.data.data.task;
 					that.$store.commit('$uStore', {
 						name,
 						value
 					});
+					// name = 'contractTip';
+					// value = res.data.data.contractTip;
+					// that.$store.commit('$uStore', {
+					// 	name,
+					// 	value
+					// });
 				}
 			})
 		},
@@ -266,37 +284,7 @@
 			this.loadStatus = 'more'
 			this.loadData()
 			var userInfo = uni.getStorageSync("userInfo")
-			var that = this
-			this.$api.doRequest('get', '/salePlanInfo/getTips', {
-				phone: userInfo.phone
-			}).then(res => {
-				if (res.data.data) {
-					let name = 'myTip';
-					let value = res.data.data.myTip;
-					that.$store.commit('$uStore', {
-						name,
-						value
-					});
-					if (value != 0) {
-						uni.setTabBarBadge({
-							index: 4,
-							text: value + ""
-						})
-					}
-					name = 'taskTip';
-					value = res.data.data.taskTip;
-					that.$store.commit('$uStore', {
-						name,
-						value
-					});
-					name = 'contractTip';
-					value = res.data.data.contractTip;
-					that.$store.commit('$uStore', {
-						name,
-						value
-					});
-				}
-			})
+			
 		},
 		onPageScroll(e) {
 			this.scrollTop = e.scrollTop;

+ 4 - 2
pages/task/my_task.vue

@@ -232,15 +232,17 @@
 						}
 						uni.hideLoading()
 					} else {
+						uni.hideLoading()
 						uni.showToast({
-							title: res.data.message,
+							title: "系统异常,请联系管理员",
 							icon: 'none',
 							duration: 2000
 						})
 					}
 				}).catch(res => {
+					uni.hideLoading()
 					uni.showToast({
-						title: res.data.message,
+						title: "Session失效,请重新登录",
 						icon: 'none',
 						duration: 2000
 					})

+ 10 - 10
pages/tran/tran.vue

@@ -129,32 +129,32 @@
 				var userInfo = uni.getStorageSync("userInfo")
 				var that = this
 				console.log("userInfo",userInfo)
-				this.$api.doRequest('get', '/salePlanInfo/getTips', {phone:userInfo.phone}).then(res => {
+				this.$api.doRequest('get', '/notice/query/noticeNumber').then(res => {
 					if (res.data.data) {
 						let name = 'myTip';
-						let value = res.data.data.myTip;
+						let value = res.data.data.task;
 						that.$store.commit('$uStore', {
 							name,
 							value
 						});
-						if(value != 0){
+						if(value != 0&&value){
 							uni.setTabBarBadge({
 								index:4,
 								text:value+""
 							})
 						}
 						name = 'taskTip';
-						value = res.data.data.taskTip;
-						that.$store.commit('$uStore', {
-							name,
-							value
-						});
-						name = 'contractTip';
-						value = res.data.data.contractTip;
+						value = res.data.data.task;
 						that.$store.commit('$uStore', {
 							name,
 							value
 						});
+						// name = 'contractTip';
+						// value = res.data.data.contractTip;
+						// that.$store.commit('$uStore', {
+						// 	name,
+						// 	value
+						// });
 					}
 				})
 			},

+ 10 - 9
pages/user/user.vue

@@ -215,15 +215,16 @@
 				this.username = this.userInfo.userName
 				this.userphone = this.userInfo.phone
 				var that = this
-				this.$api.doRequest('get', '/notice/query/noticeNumber', {phone:this.userInfo.phone}).then(res => {
+				this.$api.doRequest('get', '/notice/query/noticeNumber').then(res => {
+					console.log("noticeNumber",res)
 					if (res.data.data) {
 						let name = 'myTip';
-						let value = res.data.data.myTip;
+						let value = res.data.data.task;
 						that.$store.commit('$uStore', {
 							name,
 							value
 						});
-						if(value != 0){
+						if(value != 0&&value){
 							uni.setTabBarBadge({
 								index:4,
 								text:value+""
@@ -235,12 +236,12 @@
 							name,
 							value
 						});
-						name = 'contractTip';
-						value = res.data.data.contractTip;
-						that.$store.commit('$uStore', {
-							name,
-							value
-						});
+						// name = 'contractTip';
+						// value = res.data.data.contractTip;
+						// that.$store.commit('$uStore', {
+						// 	name,
+						// 	value
+						// });
 					}
 				})
 			}else{

+ 11 - 11
websocket_sdk.js

@@ -285,37 +285,37 @@ export default class Websocket {
 				})
 			}
 			uni.request({
-			    url: baseUrlNew + '/salePlanInfo/getTips',
+			    url: baseUrlNew + '/notice/query/noticeNumber',
 			    data: {
-			    	phone: userInfo.phone
+			    	
 			    },
 			    method: 'GET',
 			    success: (res) => {			
 					if (res.data.data) {
 			    		let name = 'myTip';
-			    		let value = res.data.data.myTip;
+			    		let value = res.data.data.task;
 			    		store.commit('$uStore', {
 			    			name,
 			    			value
 			    		});
-						if(value != 0){
+						if(value != 0&&value){
 							uni.setTabBarBadge({
 								index:4,
 								text:value+""
 							})
 						}
 			    		name = 'taskTip';
-			    		value = res.data.data.taskTip;
-			    		store.commit('$uStore', {
-			    			name,
-			    			value
-			    		});
-			    		name = 'contractTip';
-			    		value = res.data.data.contractTip;
+			    		value = res.data.data.task;
 			    		store.commit('$uStore', {
 			    			name,
 			    			value
 			    		});
+			    		// name = 'contractTip';
+			    		// value = res.data.data.contractTip;
+			    		// store.commit('$uStore', {
+			    		// 	name,
+			    		// 	value
+			    		// });
 			    	}
 			    }
 			})