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

Merge branch 'master' of http://47.100.3.209:3000/gongdecai/wangluohuoyun-app

zhongtianhaoyuan 2 éve
szülő
commit
42121f1e52
5 módosított fájl, 35 hozzáadás és 57 törlés
  1. 5 4
      App.vue
  2. 2 2
      config/index.js
  3. 6 9
      manifest.json
  4. 1 1
      pages/mine/index1.vue
  5. 21 41
      pages/order/confirmLoading.vue

+ 5 - 4
App.vue

@@ -81,6 +81,7 @@
 							var shippingNoteInfos = res.data[0]; //运单信息列表
 							console.log(shippingNoteInfos, "sdassss")
 							if (shippingNoteInfos) {
+								that.send()
 								let dateTtime = Number(shippingNoteInfos.interval + 60000)
 								console.log("开始定时", dateTtime)
 								that.timer = setTimeout(() => {
@@ -149,9 +150,7 @@
 				sdkwx.auth(this.appId, this.appSecurity, this.enterpriseSenderCode, this.environment, function(res) {
 					if (res.type == "onSuccess") {
 						//成功
-						if (res.data.length > 0) {
-							that.restart()
-						}
+						that.restart()
 						console.log("授权成功")
 						console.log(res)
 					} else if (res.type == "onFailure") {
@@ -166,6 +165,7 @@
 		},
 
 		onLaunch: function() {
+			console.log("onlaunch")
 			var that = this
 			// #ifdef APP-PLUS
 			// APPUpdate();
@@ -295,6 +295,7 @@
 			// #ifdef APP-PLUS
 			var that = this
 			//判断该用户是否需要开启持续定位
+			console.log("onlaunch11111111",uni.getStorageSync('userInfo'))
 			if (uni.getStorageSync('userInfo')) {
 				this.$request.baseRequest('get', '/orderInfo/getData', {
 					commonId: uni.getStorageSync('userInfo').id,
@@ -325,7 +326,7 @@
 							.unloadCity //到达地址文字描述,调用 start/stop/pause/restart 时必 填,调用 send 非必填
 						this.shippingNoteInfos[0].interval = "5000"
 						console.log("查看参数", this.shippingNoteInfos)
-						that.auth()
+						// that.auth()
 						that.$helper.fUN_AmapLocation.start({
 								// intervalTime: 1000 * 60,
 								intervalTime: 5000,

+ 2 - 2
config/index.js

@@ -1,8 +1,8 @@
 const dev = {
-	// baseUrlNew: 'https://api.changyuntong56.com',
+	baseUrlNew: 'https://api.changyuntong56.com',
 	// baseUrlNew: 'https://apitest.changyuntong56.com',
 	// baseUrlNew: 'https://apitest.eliangeyun.com',
-	baseUrlNew: 'http://192.168.110.9:8099',
+	// baseUrlNew: 'http://192.168.110.9:8099',
 	// baseUrlNew: 'http://192.168.110.82:8999',
 	// baseUrlNew: 'http://192.168.1.119:8999',
 	h5Appid: 'wxb66b599f7f61b46f',

+ 6 - 9
manifest.json

@@ -2,8 +2,8 @@
     "name" : "畅运通",
     "appid" : "__UNI__9C76CB6",
     "description" : "",
-    "versionName" : "1.1.1",
-    "versionCode" : 111,
+    "versionName" : "1.1.4",
+    "versionCode" : 114,
     "transformPx" : false,
     /* 5+App特有相关 */
     "app-plus" : {
@@ -22,8 +22,8 @@
         /* 模块配置 */
         "modules" : {
             "Geolocation" : {},
-            "iBeacon" : {},
-            "Maps" : {}
+            "Maps" : {},
+            "iBeacon" : {}
         },
         /* 应用发布信息 */
         "distribute" : {
@@ -54,8 +54,8 @@
                     "<uses-permission android:name=\"android.permission.WRITE_SETTINGS\"/>",
                     "<uses-permission android:name=\"android.permission.BLUETOOTH\"/>",
                     "<uses-permission android:name=\"android.permission.BLUETOOTH_ADMIN\"/>",
-					"<uses-permission android:name=\"android.permission.INSTALL_PACKAGES\"/>" ,
-					"<uses-permission android:name=\"android.permission.REQUEST_INSTALL_PACKAGES\"/>"
+                    "<uses-permission android:name=\"android.permission.INSTALL_PACKAGES\"/>",
+                    "<uses-permission android:name=\"android.permission.REQUEST_INSTALL_PACKAGES\"/>"
                 ]
             },
             /* ios打包配置 */
@@ -74,9 +74,6 @@
                         "__platform__" : [ "ios", "android" ],
                         "appkey_ios" : "450806e9eef29de257faad3a06ec7e9a",
                         "appkey_android" : "dc40c1be0513c1c8e01eb560318dbc68"
-                    },
-                    "system" : {
-                        "__platform__" : [ "ios", "android" ]
                     }
                 }
             },

+ 1 - 1
pages/mine/index1.vue

@@ -21,7 +21,7 @@
 				driverName:"尚师傅",//司机姓名
 				remark:"测试",//备注
 				shippingNoteInfos:[{
-					shippingNoteNumber:"CY20221015674637",//运单号
+					shippingNoteNumber:"CY20221027826293",//运单号
 					serialNumber:"0000",//分单号
 					startCountrySubdivisionCode:"210804",//起点位置行政区划代码,调 用 start/stop/pause/restart 时 必填,调用 send 非必填
 					endCountrySubdivisionCode:"370202",//到达位置行政区划代码,调 用 start/stop/pause/restart 时 必填,调用 send 非必填

+ 21 - 41
pages/order/confirmLoading.vue

@@ -168,22 +168,10 @@
 					driverName: "",
 					interval: "",
 				}],
-				timer: ""
+				timer: null
 			}
 		},
 		onLoad(options) {
-			
-			var isContains = true;//隐私权政策是否包含高德开平隐私权政策  true是包含
-			var isShow = true;//隐私权政策是否弹窗展示告知用户 true是展示 
-			sdkwx.updatePrivacyShow(isContains, isShow);
-			
-			var isAgree = true;//隐私权政策是否取得用户同意  true是用户同意
-			sdkwx.updatePrivacyAgree(isAgree);
-			//检查定位权限
-			sdkwx.checkLocationPermission(function(res){
-				console.log(res);
-			});
-			
 			let phoneType = uni.getSystemInfoSync().platform //判断手机类型
 			this.enterpriseSenderCode = config.def().enterpriseSenderCode
 			this.environment = config.def().environment
@@ -213,7 +201,6 @@
 		},
 		onShow() {
 			if (uni.getStorageSync('contractdata')) {
-				
 				this.id = uni.getStorageSync('contractdata').id
 				this.detailData.hyCarrierInfo.id = uni.getStorageSync('contractdata').carrierId
 				this.cyId = uni.getStorageSync('contractdata').carrierId
@@ -248,11 +235,9 @@
 				// var appSecurity = "24c593b7037347e08857a6ab05fd231b0509f5bb7cb741078f524f506ad32db8";//网络货运企业在省平台申请的接入安全码
 				// var enterpriseSenderCode = "23106960";//网络货运企业在省平台申请的企业发送代码
 				// var environment = "debug";//环境:“debug”接入测试环境,“release”接入正式环境。
-				
+				console.log("appid:" + this.appId + "安全码:" + this.appSecurity + "发送代码:" + this.enterpriseSenderCode)
 				let that = this
 				sdkwx.auth(this.appId, this.appSecurity, this.enterpriseSenderCode, this.environment, function(res) {
-					console.log("appid:" + that.appId + "安全码:" + that.appSecurity + "发送代码:" + that.enterpriseSenderCode+"测试环境"+that.environment)
-					console.log(res)
 					if (res.type == "onSuccess") {
 						//成功
 						that.start()
@@ -275,31 +260,23 @@
 				console.log(this.detailData, "行政区划分")
 				this.shippingNoteInfos[0].shippingNoteNumber = this.detailData.orderNo, //运单号
 					this.shippingNoteInfos[0].serialNumber = "0000", //分单号
-					this.shippingNoteInfos[0].startCountrySubdivisionCode = this.detailData.publishTaskInfo
-					.sendAdCode, //起点位置行政区划代码,调 用 start/stop/pause/restart 时 必填,调用 send 非必填
-					this.shippingNoteInfos[0].endCountrySubdivisionCode = this.detailData.publishTaskInfo
-					.unsendAdCode, //到达位置行政区划代码,调 用 start/stop/pause/restart 时 必填,调用 send 非必填
-					this.shippingNoteInfos[0].startLongitude = this.detailData
-					.loadingLatitude, //起点位置经度,调用 start/stop/pause/restart 时必 填,调用 send 非必填
-					this.shippingNoteInfos[0].startLatitude = this.detailData
-					.loadingLatitude, //起点位置纬度,调用 start/stop/pause/restart 时必 填,调用 send 非必填
-					this.shippingNoteInfos[0].endLongitude = this.detailData.publishTaskInfo
-					.unsendLongitude, //到达位置经度,调用 start/stop/pause/restart 时必 填,调用 send 非必填
-					this.shippingNoteInfos[0].endLatitude = this.detailData.publishTaskInfo
-					.unsendLatitude, //到达位置纬度,调用 start/stop/pause/restart 时必 填,调用 send 非必填
-					this.shippingNoteInfos[0].startLocationText = this.detailData
-					.sendCity, //起点地址文字描述,调用 start/stop/pause/restart 时必 填,调用 send 非必填
-					this.shippingNoteInfos[0].endLocationText = this.detailData
-					.unloadCity, //到达地址文字描述,调用 start/stop/pause/restart 时必 填,调用 send 非必填
-					this.shippingNoteInfos[0].vehicleNumber = this.detailData
-					.carNumber, //车牌号,SDK 回调返回,调 用 start/stop/pause/restart/必 填,send 时非必填
-					this.shippingNoteInfos[0].driverName = this.detailData
-					.driverName, //司机姓名,SDK 回调返回, 调用 start/stop/pause/restart/ 必填,send 时非必填
+					this.shippingNoteInfos[0].startCountrySubdivisionCode = this.detailData.publishTaskInfo.sendAdCode, //起点位置行政区划代码,调 用 start/stop/pause/restart 时 必填,调用 send 非必填
+					this.shippingNoteInfos[0].endCountrySubdivisionCode = this.detailData.publishTaskInfo.unsendAdCode, //到达位置行政区划代码,调 用 start/stop/pause/restart 时 必填,调用 send 非必填
+					this.shippingNoteInfos[0].startLongitude = this.detailData.loadingLatitude, //起点位置经度,调用 start/stop/pause/restart 时必 填,调用 send 非必填
+					this.shippingNoteInfos[0].startLatitude = this.detailData.loadingLatitude, //起点位置纬度,调用 start/stop/pause/restart 时必 填,调用 send 非必填
+					this.shippingNoteInfos[0].endLongitude = this.detailData.publishTaskInfo.unsendLongitude, //到达位置经度,调用 start/stop/pause/restart 时必 填,调用 send 非必填
+					this.shippingNoteInfos[0].endLatitude = this.detailData.publishTaskInfo.unsendLatitude, //到达位置纬度,调用 start/stop/pause/restart 时必 填,调用 send 非必填
+					this.shippingNoteInfos[0].startLocationText = this.detailData.sendCity, //起点地址文字描述,调用 start/stop/pause/restart 时必 填,调用 send 非必填
+					this.shippingNoteInfos[0].endLocationText = this.detailData.unloadCity, //到达地址文字描述,调用 start/stop/pause/restart 时必 填,调用 send 非必填
+					this.shippingNoteInfos[0].vehicleNumber = this.detailData.carNumber, //车牌号,SDK 回调返回,调 用 start/stop/pause/restart/必 填,send 时非必填
+					this.shippingNoteInfos[0].driverName = this.detailData.driverName, //司机姓名,SDK 回调返回, 调用 start/stop/pause/restart/ 必填,send 时非必填
 					this.shippingNoteInfos[0].interval = "5000" //请求时间间隔,SDK 回调返 回(单位 ms)
 
 				//}],//运单信息列表,一辆车运单数最大支持数为 10
 				var remark = "测试"; //备注
 				let that = this
+				console.log("start this.shippingNoteInfos")
+				console.log(this.shippingNoteInfos)
 				sdkwx.start(this.detailData.carNo, this.firstAuthentication.driverName, remark, this.shippingNoteInfos,
 					function(res) {
 						if (res.type == "onSuccess") {
@@ -311,10 +288,11 @@
 							if (shippingNoteInfos) {
 								let dateTtime = Number(shippingNoteInfos.interval + 1000)
 								console.log("开始定时", dateTtime)
-								that.timer = setTimeout(() => {
-									console.log("定时")
-									that.send()
-								}, dateTtime);
+								that.send()
+								// that.timer = setTimeout(() => {
+								// 	console.log("定时")
+								// 	that.send()
+								// }, dateTtime);
 							}
 						} else if (res.type == "onFailure") {
 							//失败
@@ -332,6 +310,8 @@
 			send() { //发送定位
 				var remark = ""; //备注
 				let that = this
+				console.log("send this.shippingNoteInfos")
+				console.log(this.shippingNoteInfos)
 				sdkwx.send(this.detailData.carNo, this.firstAuthentication.driverName, remark, this.shippingNoteInfos,
 					function(res) {
 						console.log('发送定位', res);