From f7eddb2103d10f6f63bd4e72142f32af0d337260 Mon Sep 17 00:00:00 2001 From: chenkainan Date: Tue, 4 Mar 2025 15:27:07 +0800 Subject: [PATCH] =?UTF-8?q?=E6=89=93=E5=8C=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- index.html | 2 + manifest.json | 2 +- pages/index/index.vue | 51 +++++++++++++++++++ unpackage/dist/build/web/index.html | 2 +- .../{index.32e9e603.js => index.6ac4c6c0.js} | 2 +- .../static/js/pages-index-index.07e77446.js | 1 - .../static/js/pages-index-index.cf89c900.js | 1 + 7 files changed, 57 insertions(+), 4 deletions(-) rename unpackage/dist/build/web/static/js/{index.32e9e603.js => index.6ac4c6c0.js} (99%) delete mode 100644 unpackage/dist/build/web/static/js/pages-index-index.07e77446.js create mode 100644 unpackage/dist/build/web/static/js/pages-index-index.cf89c900.js diff --git a/index.html b/index.html index 470262f..c13c0de 100644 --- a/index.html +++ b/index.html @@ -10,6 +10,8 @@ (coverSupport ? ', viewport-fit=cover' : '') + '" />') 苏州市导游协会 + + diff --git a/manifest.json b/manifest.json index 6f117ab..47395eb 100644 --- a/manifest.json +++ b/manifest.json @@ -99,7 +99,7 @@ "key" : "4QQBZ-35LWQ-7725U-45ZGA-MIB5E-ZXBEA" }, "tencent" : { - "key" : "YVOBZ-MWJ3Z-34IXK-7J2GL-O33US-QLF5X" + "key" : "XCJBZ-XJVL5-JCYID-IYEOP-AM7I2-2CF7E" } } } diff --git a/pages/index/index.vue b/pages/index/index.vue index ed23293..121689f 100644 --- a/pages/index/index.vue +++ b/pages/index/index.vue @@ -85,6 +85,13 @@ isChecked: false }], isAllChecked: false, + // 打卡中心点经纬度 + fenceCenter: { + latitude: 31.266909, + longitude: 120.633401 + }, + // 打卡点半径(单位:米) + fenceRadius: 500 } }, onLoad() { @@ -100,6 +107,7 @@ if (navigator.geolocation) { navigator.geolocation.getCurrentPosition( (position) => { + // 获取到定位信息说明浏览器支持定位 const coords = position.coords; console.log('纬度: ', coords.latitude); console.log('经度: ', coords.longitude); @@ -108,6 +116,9 @@ console.log('高度精度: ', coords.altitudeAccuracy); console.log('移动方向: ', coords.heading); console.log('移动速度: ', coords.speed); + const [gcj02Lng, gcj02Lat] = this.wgs84ToGcj02(coords.longitude, coords.latitude); + console.log('转换后的 GCJ - 02 经度:', gcj02Lng); + console.log('转换后的 GCJ - 02 纬度:', gcj02Lat); }, (error) => { let locationStatus = '' @@ -141,6 +152,46 @@ }) } }, + // WGS84坐标转换为GCJ-02坐标 + // 判断是否在中国范围内 + outOfChina(lng, lat) { + return (lng < 72.004 || lng > 137.8347) || (lat < 0.8293 || lat > 55.8271); + }, + // 转换纬度 + transformLat(x, y) { + let ret = -100.0 + 2.0 * x + 3.0 * y + 0.2 * y * y + 0.1 * x * y + 0.2 * Math.sqrt(Math.abs(x)); + ret += (20.0 * Math.sin(6.0 * x * Math.PI) + 20.0 * Math.sin(2.0 * x * Math.PI)) * 2.0 / 3.0; + ret += (20.0 * Math.sin(y * Math.PI) + 40.0 * Math.sin(y / 3.0 * Math.PI)) * 2.0 / 3.0; + ret += (160.0 * Math.sin(y / 12.0 * Math.PI) + 320 * Math.sin(y * Math.PI / 30.0)) * 2.0 / 3.0; + return ret; + }, + // 转换经度 + transformLng(x, y) { + let ret = 300.0 + x + 2.0 * y + 0.1 * x * x + 0.1 * x * y + 0.1 * Math.sqrt(Math.abs(x)); + ret += (20.0 * Math.sin(6.0 * x * Math.PI) + 20.0 * Math.sin(2.0 * x * Math.PI)) * 2.0 / 3.0; + ret += (20.0 * Math.sin(x * Math.PI) + 40.0 * Math.sin(x / 3.0 * Math.PI)) * 2.0 / 3.0; + ret += (150.0 * Math.sin(x / 12.0 * Math.PI) + 300.0 * Math.sin(x / 30.0 * Math.PI)) * 2.0 / 3.0; + return ret; + }, + // WGS84 转换为 GCJ02 + wgs84ToGcj02(lng, lat) { + const a = 6378245.0; // 地球长半轴 + const ee = 0.00669342162296594323; // 扁率 + if (this.outOfChina(lng, lat)) { + return [lng, lat]; + } + let dLat = this.transformLat(lng - 105.0, lat - 35.0); + let dLng = this.transformLng(lng - 105.0, lat - 35.0); + const radLat = lat / 180.0 * Math.PI; + let magic = Math.sin(radLat); + magic = 1 - ee * magic * magic; + const sqrtMagic = Math.sqrt(magic); + dLat = (dLat * 180.0) / ((a * (1 - ee)) / (magic * sqrtMagic) * Math.PI); + dLng = (dLng * 180.0) / (a / sqrtMagic * Math.cos(radLat) * Math.PI); + const mgLat = lat + dLat; + const mgLng = lng + dLng; + return [mgLng, mgLat]; + }, goHX() { uni.switchTab({ url: '/pages/verification/index' diff --git a/unpackage/dist/build/web/index.html b/unpackage/dist/build/web/index.html index 56f8502..cac3f58 100644 --- a/unpackage/dist/build/web/index.html +++ b/unpackage/dist/build/web/index.html @@ -1,2 +1,2 @@ daoyou
\ No newline at end of file + document.write('')
\ No newline at end of file diff --git a/unpackage/dist/build/web/static/js/index.32e9e603.js b/unpackage/dist/build/web/static/js/index.6ac4c6c0.js similarity index 99% rename from unpackage/dist/build/web/static/js/index.32e9e603.js rename to unpackage/dist/build/web/static/js/index.6ac4c6c0.js index 72e5379..75223ce 100644 --- a/unpackage/dist/build/web/static/js/index.32e9e603.js +++ b/unpackage/dist/build/web/static/js/index.6ac4c6c0.js @@ -1 +1 @@ -(function(n){function i(i){for(var e,t,p=i[0],u=i[1],d=i[2],s=0,l=[];s'),i=new RegExp("section","g"),n=n.replace(i,"div"),i=new RegExp("↵","g"),n=n.replace(i,"
"),n},r.default.prototype.getUrlPara=function(n){var i=n.split("?"),o=i[1];return!!o&&o.split("&")},r.default.prototype.idChinaName=function(n){return/^[\u4E00-\u9FA5]{2,4}$/.test(n)},r.default.prototype.idCardNumber=function(n){return/^\d{17}(\d{1}|[X|x])$/.test(n)},r.default.prototype.IsTel=function(n){return/^1\d{10}$/.test(n)},r.default.prototype.IsTelMacau=function(n){return/^\d{8}$/.test(n)},r.default.prototype.IsCode=function(n){return/^\d{6}$/.test(n)},r.default.prototype.IsMail=function(n){return/^\w+@[a-z0-9]+\.[a-z]+$/i.test(n)},r.default.prototype.showImg=function(n){if(n)return-1!=n.indexOf("https://")||-1!=n.indexOf("http://")?n:"https://guide.sz-trip.com"+n},r.default.prototype.getLocation=function(){uni.startLocationUpdate({success:function(n){uni.onLocationChange((function(n){uni.setStorageSync("location",{lat:n.latitude,lon:n.longitude})}))}})},r.default.prototype.getHeadImg=function(n){return r.default.prototype.Post({type:n},"/api/public_service/getKumgangHeadImgList").then((function(n){return n.data[0].image}))},r.default.prototype.gotoPath=function(n){uni.navigateTo({url:n})},r.default.prototype.goBack=function(){console.log(getCurrentPages());var n=getCurrentPages(),i=n[n.length-1];"subPackages/techan/techanList"!=i.route&&getCurrentPages().length>1?uni.navigateBack({}):uni.switchTab({url:"/pages/index/index"})},r.default.prototype.openLocation=function(n,i){uni.openLocation({latitude:Number(n),longitude:Number(i),success:function(){console.log("success")}})},r.default.prototype.clickPhone=function(n){uni.makePhoneCall({phoneNumber:n})},r.default.prototype.ShowDateDay=function(n){var i="";switch(n){case 0:i="周日";break;case 1:i="周一";break;case 2:i="周二";break;case 3:i="周三";break;case 4:i="周四";break;case 5:i="周五";break;case 6:i="周六";break}return i},r.default.prototype.encryptPhone=function(n){return n.replace(/(\d{3})\d{4}(\d{4})/,"$1****$2")}},"9f4f":function(n,i,o){"use strict";var e=o("f5bd").default,r=e(o("9b1b"));o("3dde"),o("a8b2"),o("1480"),o("6e4a"),o("4e18"),o("9337");var a=e(o("9b8e")),t=e(o("caf0")),p=e(o("bd88"));o("32bf"),o("6be1");var u=e(o("ec4d"));a.default.prototype.vconsole=new u.default,a.default.config.productionTip=!1,t.default.mpType="app";var d=new a.default((0,r.default)({store:p.default},t.default));d.$mount()},b349:function(n,i,o){"use strict";o.d(i,"b",(function(){return e})),o.d(i,"c",(function(){return r})),o.d(i,"a",(function(){}));var e=function(){var n=this.$createElement,i=this._self._c||n;return i("App",{attrs:{keepAliveInclude:this.keepAliveInclude}})},r=[]},bd88:function(n,i,o){"use strict";o("6a54");var e=o("f5bd").default;Object.defineProperty(i,"__esModule",{value:!0}),i.default=void 0;var r=e(o("9b8e")),a=e(o("8f59")),t=e(o("fa68"));r.default.use(a.default);var p=new a.default.Store({modules:{user:t.default}});i.default=p},caf0:function(n,i,o){"use strict";o.r(i);var e=o("b349"),r=o("3e24");for(var a in r)["default"].indexOf(a)<0&&function(n){o.d(i,n,(function(){return r[n]}))}(a);o("1426");var t=o("828b"),p=Object(t["a"])(r["default"],e["b"],e["c"],!1,null,null,null,!1,e["a"],void 0);i["default"]=p.exports},fa68:function(n,i,o){"use strict";o("6a54"),Object.defineProperty(i,"__esModule",{value:!0}),i.default=void 0,o("d4b5");var e={state:{location:{lat:"",lon:""},userInfo:{token:""},toPath:"",products:"",linkProducts:"",coupon:"",eshoppingCart:[],sshoppingCart:[],meetRoomReserve:{date:null,coupon:null,people:null},lingoIds:[],scenicIds:[]},mutations:{changeUserInfo:function(n,i){n.userInfo=i,uni.setStorageSync("userInfo",JSON.stringify(i))},changeLoationInfo:function(n,i){uni.setStorageSync("locationInfo",JSON.stringify(i)),n.location=i},changeLoginPath:function(n){var i=getCurrentPages(),o=i[i.length-1];n.toPath=o.$page.fullPath,"/pages/login/login"!=n.toPath&&uni.navigateTo({url:"/pages/login/login"})},changeOrderInfo:function(n,i){n.products=i},changelinkProducts:function(n,i){n.linkProducts=i},choseCoupon:function(n,i){n.coupon=i},changeOrderECart:function(n,i){n.eshoppingCart=i},changeOrderSCart:function(n,i){n.sshoppingCart=i},changeMeetRoomReserve:function(n,i){n.meetRoomReserve=i},changeLingoIds:function(n,i){n.lingoIds=i},changeScenicIds:function(n,i){n.scenicIds=i}}};i.default=e}}); \ No newline at end of file +(function(n){function i(i){for(var e,t,p=i[0],u=i[1],d=i[2],s=0,l=[];s'),i=new RegExp("section","g"),n=n.replace(i,"div"),i=new RegExp("↵","g"),n=n.replace(i,"
"),n},r.default.prototype.getUrlPara=function(n){var i=n.split("?"),o=i[1];return!!o&&o.split("&")},r.default.prototype.idChinaName=function(n){return/^[\u4E00-\u9FA5]{2,4}$/.test(n)},r.default.prototype.idCardNumber=function(n){return/^\d{17}(\d{1}|[X|x])$/.test(n)},r.default.prototype.IsTel=function(n){return/^1\d{10}$/.test(n)},r.default.prototype.IsTelMacau=function(n){return/^\d{8}$/.test(n)},r.default.prototype.IsCode=function(n){return/^\d{6}$/.test(n)},r.default.prototype.IsMail=function(n){return/^\w+@[a-z0-9]+\.[a-z]+$/i.test(n)},r.default.prototype.showImg=function(n){if(n)return-1!=n.indexOf("https://")||-1!=n.indexOf("http://")?n:"https://guide.sz-trip.com"+n},r.default.prototype.getLocation=function(){uni.startLocationUpdate({success:function(n){uni.onLocationChange((function(n){uni.setStorageSync("location",{lat:n.latitude,lon:n.longitude})}))}})},r.default.prototype.getHeadImg=function(n){return r.default.prototype.Post({type:n},"/api/public_service/getKumgangHeadImgList").then((function(n){return n.data[0].image}))},r.default.prototype.gotoPath=function(n){uni.navigateTo({url:n})},r.default.prototype.goBack=function(){console.log(getCurrentPages());var n=getCurrentPages(),i=n[n.length-1];"subPackages/techan/techanList"!=i.route&&getCurrentPages().length>1?uni.navigateBack({}):uni.switchTab({url:"/pages/index/index"})},r.default.prototype.openLocation=function(n,i){uni.openLocation({latitude:Number(n),longitude:Number(i),success:function(){console.log("success")}})},r.default.prototype.clickPhone=function(n){uni.makePhoneCall({phoneNumber:n})},r.default.prototype.ShowDateDay=function(n){var i="";switch(n){case 0:i="周日";break;case 1:i="周一";break;case 2:i="周二";break;case 3:i="周三";break;case 4:i="周四";break;case 5:i="周五";break;case 6:i="周六";break}return i},r.default.prototype.encryptPhone=function(n){return n.replace(/(\d{3})\d{4}(\d{4})/,"$1****$2")}},"9f4f":function(n,i,o){"use strict";var e=o("f5bd").default,r=e(o("9b1b"));o("3dde"),o("a8b2"),o("1480"),o("6e4a"),o("4e18"),o("9337");var a=e(o("9b8e")),t=e(o("caf0")),p=e(o("bd88"));o("32bf"),o("6be1");var u=e(o("ec4d"));a.default.prototype.vconsole=new u.default,a.default.config.productionTip=!1,t.default.mpType="app";var d=new a.default((0,r.default)({store:p.default},t.default));d.$mount()},b349:function(n,i,o){"use strict";o.d(i,"b",(function(){return e})),o.d(i,"c",(function(){return r})),o.d(i,"a",(function(){}));var e=function(){var n=this.$createElement,i=this._self._c||n;return i("App",{attrs:{keepAliveInclude:this.keepAliveInclude}})},r=[]},bd88:function(n,i,o){"use strict";o("6a54");var e=o("f5bd").default;Object.defineProperty(i,"__esModule",{value:!0}),i.default=void 0;var r=e(o("9b8e")),a=e(o("8f59")),t=e(o("fa68"));r.default.use(a.default);var p=new a.default.Store({modules:{user:t.default}});i.default=p},caf0:function(n,i,o){"use strict";o.r(i);var e=o("b349"),r=o("3e24");for(var a in r)["default"].indexOf(a)<0&&function(n){o.d(i,n,(function(){return r[n]}))}(a);o("1426");var t=o("828b"),p=Object(t["a"])(r["default"],e["b"],e["c"],!1,null,null,null,!1,e["a"],void 0);i["default"]=p.exports},fa68:function(n,i,o){"use strict";o("6a54"),Object.defineProperty(i,"__esModule",{value:!0}),i.default=void 0,o("d4b5");var e={state:{location:{lat:"",lon:""},userInfo:{token:""},toPath:"",products:"",linkProducts:"",coupon:"",eshoppingCart:[],sshoppingCart:[],meetRoomReserve:{date:null,coupon:null,people:null},lingoIds:[],scenicIds:[]},mutations:{changeUserInfo:function(n,i){n.userInfo=i,uni.setStorageSync("userInfo",JSON.stringify(i))},changeLoationInfo:function(n,i){uni.setStorageSync("locationInfo",JSON.stringify(i)),n.location=i},changeLoginPath:function(n){var i=getCurrentPages(),o=i[i.length-1];n.toPath=o.$page.fullPath,"/pages/login/login"!=n.toPath&&uni.navigateTo({url:"/pages/login/login"})},changeOrderInfo:function(n,i){n.products=i},changelinkProducts:function(n,i){n.linkProducts=i},choseCoupon:function(n,i){n.coupon=i},changeOrderECart:function(n,i){n.eshoppingCart=i},changeOrderSCart:function(n,i){n.sshoppingCart=i},changeMeetRoomReserve:function(n,i){n.meetRoomReserve=i},changeLingoIds:function(n,i){n.lingoIds=i},changeScenicIds:function(n,i){n.scenicIds=i}}};i.default=e}}); \ No newline at end of file diff --git a/unpackage/dist/build/web/static/js/pages-index-index.07e77446.js b/unpackage/dist/build/web/static/js/pages-index-index.07e77446.js deleted file mode 100644 index 01f17ce..0000000 --- a/unpackage/dist/build/web/static/js/pages-index-index.07e77446.js +++ /dev/null @@ -1 +0,0 @@ -(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-index-index"],{1664:function(t,e,i){var n=i("e3e9");n.__esModule&&(n=n.default),"string"===typeof n&&(n=[[t.i,n,""]]),n.locals&&(t.exports=n.locals);var s=i("967d").default;s("0e0be182",n,!0,{sourceMap:!1,shadowMode:!1})},"2fc9":function(t,e,i){"use strict";var n=i("1664"),s=i.n(n);s.a},"7ba3":function(t,e,i){"use strict";i.r(e);var n=i("84bb"),s=i("df0f");for(var a in s)["default"].indexOf(a)<0&&function(t){i.d(e,t,(function(){return s[t]}))}(a);i("2fc9");var o=i("828b"),c=Object(o["a"])(s["default"],n["b"],n["c"],!1,null,"3357c128",null,!1,n["a"],void 0);e["default"]=c.exports},"84bb":function(t,e,i){"use strict";i.d(e,"b",(function(){return n})),i.d(e,"c",(function(){return s})),i.d(e,"a",(function(){}));var n=function(){var t=this,e=t.$createElement,i=t._self._c||e;return i("v-uni-view",{staticClass:"content"},[i("v-uni-image",{staticClass:"topImg",attrs:{src:"https://static.ticket.sz-trip.com/tourGuide/images/index/topImg.png"}}),i("v-uni-view",{staticClass:"title",staticStyle:{"margin-top":"40rpx"}},[t._v("·快捷入口")]),i("v-uni-view",{staticClass:"flex-between"},[i("v-uni-view",{staticClass:"nav-item flex-around",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.goHX()}}},[t._v("立即核销"),i("v-uni-image",{attrs:{src:"https://static.ticket.sz-trip.com/tourGuide/images/index/hexiao.png",mode:""}})],1),i("v-uni-view",{staticClass:"nav-item flex-around",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.gotoPath("/subPackages/order/orderList")}}},[t._v("查看订单"),i("v-uni-image",{attrs:{src:"https://static.ticket.sz-trip.com/tourGuide/images/index/dingdan.png",mode:""}})],1)],1),i("v-uni-view",{staticClass:"title"},[t._v("·我的排班")]),i("v-uni-view",{staticClass:"type-box"},t._l(t.typeList,(function(e,n){return i("v-uni-view",{key:n,class:["type-item",{"type-active":n==t.typeIndex}],on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.typeIndex=n,t.getList()}}},[t._v(t._s(e.title)),n==t.typeIndex?i("v-uni-view",{staticClass:"type-line"}):t._e()],1)})),1),i("calendarVue",{attrs:{isShowLunar:!0},on:{changeDate:function(e){arguments[0]=e=t.$handleEvent(e),t.getDate.apply(void 0,arguments)}}}),t._l(t.typeIndex?t.sessionLists:t.sessionList,(function(e,n){return i("v-uni-view",{key:n,staticClass:"session-item flex-between"},[t._v(t._s(e.title)),i("v-uni-switch",{attrs:{checked:e.isChecked,color:"#96684F"},on:{change:function(i){arguments[0]=i=t.$handleEvent(i),t.switchChange(e,n)}}})],1)}))],2)},s=[]},dc8b:function(t,e,i){"use strict";i("6a54");var n=i("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,i("bf0f"),i("2797");var s=n(i("918a")),a={components:{calendarVue:s.default},data:function(){return{typeList:[{title:"导游服务",id:""},{title:"线路产品",id:""}],typeIndex:0,selectDay:"",sessionList:[{title:"上午场",isChecked:!1},{title:"下午场",isChecked:!1},{title:"全天场",isChecked:!1}],sessionLists:[{title:"当天状态",isChecked:!1}],isAllChecked:!1}},onLoad:function(){this.selectDay=this.getNowTime(new Date),this.getList()},onShow:function(){this.checkLocation()},methods:{checkLocation:function(){navigator.geolocation?navigator.geolocation.getCurrentPosition((function(t){var e=t.coords;console.log("纬度: ",e.latitude),console.log("经度: ",e.longitude),console.log("高度: ",e.altitude),console.log("坐标精度: ",e.accuracy),console.log("高度精度: ",e.altitudeAccuracy),console.log("移动方向: ",e.heading),console.log("移动速度: ",e.speed)}),(function(t){var e="";switch(t.code){case 1:e="定位未开启,用户拒绝了定位请求";break;case 2:e="定位信息不可用";break;case 3:e="定位请求超时";break;case 4:e="定位出现未知错误";break}console.log(t),uni.showToast({title:e,icon:"none"})})):(console.log("浏览器不支持地理定位功能"),uni.showToast({title:"浏览器不支持地理定位功能",icon:"none"}))},goHX:function(){uni.switchTab({url:"/pages/verification/index"})},switchChange:function(t,e){t.isChecked=!t.isChecked;var i=this.typeIndex?"/api/Merchants/updateGuideSched":"/api/Merchants/updateGuideSchedService";this.Post({date:this.selectDay,online_type:t.isChecked?1:0,date_half:this.typeIndex?"":e+1,classify:this.typeIndex?2:""},i).then((function(t){}))},getDate:function(t){console.log("传递过来的日期",t),this.selectDay=t,this.sessionList.forEach((function(t){return t.isChecked=!1})),this.sessionLists[0].isChecked=!1,this.getList()},changeWork:function(t){},getList:function(){var t=this;this.Post({start_date:this.selectDay,end_date:this.selectDay,classify:this.typeIndex?2:3},"/api/Merchants/getGuideSchedList").then((function(e){if(e.data&&e.data.length>0){var i=e.data[0];t.typeIndex?t.sessionLists[0].isChecked=!!i.online_type:(t.sessionList[0].isChecked=!!i.morning_type,t.sessionList[1].isChecked=!!i.afternoon_type,t.sessionList[2].isChecked=!!i.day_type)}}))},getNowTime:function(t,e){var i=t,n=i.getFullYear(),s=i.getMonth()+1,a=i.getDate(),o=i.getHours()<10?"0"+i.getHours():i.getHours(),c=i.getMinutes()<10?"0"+i.getMinutes():i.getMinutes(),d=i.getSeconds()<10?"0"+i.getSeconds():i.getSeconds();if(s>=1&&s<=9&&(s="0"+s),a>=0&&a<=9&&(a="0"+a),1==e)if("ios"==uni.getSystemInfoSync().platform)var r=n+"/"+s+"/"+a+" "+o+":"+c+":"+d;else r=n+"-"+s+"-"+a+" "+o+":"+c+":"+d;else r=n+"/"+s+"/"+a;return r}}};e.default=a},df0f:function(t,e,i){"use strict";i.r(e);var n=i("dc8b"),s=i.n(n);for(var a in n)["default"].indexOf(a)<0&&function(t){i.d(e,t,(function(){return n[t]}))}(a);e["default"]=s.a},e3e9:function(t,e,i){var n=i("c86c");e=n(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 这里是uni-app内置的常用样式变量\n *\n * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量\n * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App\n *\n */\n/**\n * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能\n *\n * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\n */\n/* 颜色变量 */\n/* 行为相关颜色 */\n/* 文字基本颜色 */\n/* 背景颜色 */\n/* 边框颜色 */\n/* 尺寸变量 */\n/* 文字尺寸 */\n/* 图片尺寸 */\n/* Border Radius */\n/* 水平间距 */\n/* 垂直间距 */\n/* 透明度 */\n/* 文章场景相关 */.content[data-v-3357c128]{background:#fff;min-height:100vh;padding:%?40?% %?26?% %?200?%}.topImg[data-v-3357c128]{width:%?299.33?%;height:%?70?%;display:flex;margin:auto}.title[data-v-3357c128]{font-weight:700;font-size:%?35?%;color:#000;margin:%?68?% 0 %?34?%}.rule[data-v-3357c128]{font-weight:500;font-size:%?31?%;color:#96684f;text-align:right}.nav-item[data-v-3357c128]{font-weight:500;font-size:%?32?%;color:#000;width:%?338?%;height:%?118?%;background:#f5f5f5;border-radius:%?20?%;padding:0 %?15?%}.nav-item uni-image[data-v-3357c128]{width:%?80.67?%;height:%?80.67?%}.type-box[data-v-3357c128]{display:flex}.type-box .type-item[data-v-3357c128]{margin-right:%?44?%;font-weight:500;font-size:%?32?%;color:#000}.type-box .type-active[data-v-3357c128]{color:#96684f}.type-box .type-line[data-v-3357c128]{width:%?117?%;height:%?6?%;background:#96684f;border-radius:%?3?%;margin:%?4?% auto 0}.session-item[data-v-3357c128]{width:%?697?%;height:%?93?%;background:#f5f5f5;border-radius:%?47?%;margin:%?28?% auto 0;font-family:PingFang SC;font-weight:500;font-size:%?32?%;color:#000;padding:0 %?28?%}',""]),t.exports=e}}]); \ No newline at end of file diff --git a/unpackage/dist/build/web/static/js/pages-index-index.cf89c900.js b/unpackage/dist/build/web/static/js/pages-index-index.cf89c900.js new file mode 100644 index 0000000..510e2a9 --- /dev/null +++ b/unpackage/dist/build/web/static/js/pages-index-index.cf89c900.js @@ -0,0 +1 @@ +(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-index-index"],{"0bec":function(t,e,n){var i=n("c86c");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/**\n * 这里是uni-app内置的常用样式变量\n *\n * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量\n * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App\n *\n */\n/**\n * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能\n *\n * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件\n */\n/* 颜色变量 */\n/* 行为相关颜色 */\n/* 文字基本颜色 */\n/* 背景颜色 */\n/* 边框颜色 */\n/* 尺寸变量 */\n/* 文字尺寸 */\n/* 图片尺寸 */\n/* Border Radius */\n/* 水平间距 */\n/* 垂直间距 */\n/* 透明度 */\n/* 文章场景相关 */.content[data-v-4ce31f72]{background:#fff;min-height:100vh;padding:%?40?% %?26?% %?200?%}.topImg[data-v-4ce31f72]{width:%?299.33?%;height:%?70?%;display:flex;margin:auto}.title[data-v-4ce31f72]{font-weight:700;font-size:%?35?%;color:#000;margin:%?68?% 0 %?34?%}.rule[data-v-4ce31f72]{font-weight:500;font-size:%?31?%;color:#96684f;text-align:right}.nav-item[data-v-4ce31f72]{font-weight:500;font-size:%?32?%;color:#000;width:%?338?%;height:%?118?%;background:#f5f5f5;border-radius:%?20?%;padding:0 %?15?%}.nav-item uni-image[data-v-4ce31f72]{width:%?80.67?%;height:%?80.67?%}.type-box[data-v-4ce31f72]{display:flex}.type-box .type-item[data-v-4ce31f72]{margin-right:%?44?%;font-weight:500;font-size:%?32?%;color:#000}.type-box .type-active[data-v-4ce31f72]{color:#96684f}.type-box .type-line[data-v-4ce31f72]{width:%?117?%;height:%?6?%;background:#96684f;border-radius:%?3?%;margin:%?4?% auto 0}.session-item[data-v-4ce31f72]{width:%?697?%;height:%?93?%;background:#f5f5f5;border-radius:%?47?%;margin:%?28?% auto 0;font-family:PingFang SC;font-weight:500;font-size:%?32?%;color:#000;padding:0 %?28?%}',""]),t.exports=e},4672:function(t,e,n){"use strict";n.d(e,"b",(function(){return i})),n.d(e,"c",(function(){return a})),n.d(e,"a",(function(){}));var i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("v-uni-view",{staticClass:"content"},[n("v-uni-image",{staticClass:"topImg",attrs:{src:"https://static.ticket.sz-trip.com/tourGuide/images/index/topImg.png"}}),n("v-uni-view",{staticClass:"title",staticStyle:{"margin-top":"40rpx"}},[t._v("·快捷入口")]),n("v-uni-view",{staticClass:"flex-between"},[n("v-uni-view",{staticClass:"nav-item flex-around",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.goHX()}}},[t._v("立即核销"),n("v-uni-image",{attrs:{src:"https://static.ticket.sz-trip.com/tourGuide/images/index/hexiao.png",mode:""}})],1),n("v-uni-view",{staticClass:"nav-item flex-around",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.gotoPath("/subPackages/order/orderList")}}},[t._v("查看订单"),n("v-uni-image",{attrs:{src:"https://static.ticket.sz-trip.com/tourGuide/images/index/dingdan.png",mode:""}})],1)],1),n("v-uni-view",{staticClass:"title"},[t._v("·我的排班")]),n("v-uni-view",{staticClass:"type-box"},t._l(t.typeList,(function(e,i){return n("v-uni-view",{key:i,class:["type-item",{"type-active":i==t.typeIndex}],on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.typeIndex=i,t.getList()}}},[t._v(t._s(e.title)),i==t.typeIndex?n("v-uni-view",{staticClass:"type-line"}):t._e()],1)})),1),n("calendarVue",{attrs:{isShowLunar:!0},on:{changeDate:function(e){arguments[0]=e=t.$handleEvent(e),t.getDate.apply(void 0,arguments)}}}),t._l(t.typeIndex?t.sessionLists:t.sessionList,(function(e,i){return n("v-uni-view",{key:i,staticClass:"session-item flex-between"},[t._v(t._s(e.title)),n("v-uni-switch",{attrs:{checked:e.isChecked,color:"#96684F"},on:{change:function(n){arguments[0]=n=t.$handleEvent(n),t.switchChange(e,i)}}})],1)}))],2)},a=[]},"6f64":function(t,e,n){var i=n("0bec");i.__esModule&&(i=i.default),"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var a=n("967d").default;a("7204244e",i,!0,{sourceMap:!1,shadowMode:!1})},"7ba3":function(t,e,n){"use strict";n.r(e);var i=n("4672"),a=n("df0f");for(var s in a)["default"].indexOf(s)<0&&function(t){n.d(e,t,(function(){return a[t]}))}(s);n("b121");var o=n("828b"),c=Object(o["a"])(a["default"],i["b"],i["c"],!1,null,"4ce31f72",null,!1,i["a"],void 0);e["default"]=c.exports},b121:function(t,e,n){"use strict";var i=n("6f64"),a=n.n(i);a.a},dc8b:function(t,e,n){"use strict";n("6a54");var i=n("f5bd").default;Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,n("bf0f"),n("2797");var a=i(n("5de6")),s=i(n("918a")),o={components:{calendarVue:s.default},data:function(){return{typeList:[{title:"导游服务",id:""},{title:"线路产品",id:""}],typeIndex:0,selectDay:"",sessionList:[{title:"上午场",isChecked:!1},{title:"下午场",isChecked:!1},{title:"全天场",isChecked:!1}],sessionLists:[{title:"当天状态",isChecked:!1}],isAllChecked:!1,fenceCenter:{latitude:31.266909,longitude:120.633401},fenceRadius:500}},onLoad:function(){this.selectDay=this.getNowTime(new Date),this.getList()},onShow:function(){this.checkLocation()},methods:{checkLocation:function(){var t=this;navigator.geolocation?navigator.geolocation.getCurrentPosition((function(e){var n=e.coords;console.log("纬度: ",n.latitude),console.log("经度: ",n.longitude),console.log("高度: ",n.altitude),console.log("坐标精度: ",n.accuracy),console.log("高度精度: ",n.altitudeAccuracy),console.log("移动方向: ",n.heading),console.log("移动速度: ",n.speed);var i=t.wgs84ToGcj02(n.longitude,n.latitude),s=(0,a.default)(i,2),o=s[0],c=s[1];console.log("转换后的 GCJ - 02 经度:",o),console.log("转换后的 GCJ - 02 纬度:",c)}),(function(t){var e="";switch(t.code){case 1:e="定位未开启,用户拒绝了定位请求";break;case 2:e="定位信息不可用";break;case 3:e="定位请求超时";break;case 4:e="定位出现未知错误";break}console.log(t),uni.showToast({title:e,icon:"none"})})):(console.log("浏览器不支持地理定位功能"),uni.showToast({title:"浏览器不支持地理定位功能",icon:"none"}))},outOfChina:function(t,e){return t<72.004||t>137.8347||e<.8293||e>55.8271},transformLat:function(t,e){var n=2*t-100+3*e+.2*e*e+.1*t*e+.2*Math.sqrt(Math.abs(t));return n+=2*(20*Math.sin(6*t*Math.PI)+20*Math.sin(2*t*Math.PI))/3,n+=2*(20*Math.sin(e*Math.PI)+40*Math.sin(e/3*Math.PI))/3,n+=2*(160*Math.sin(e/12*Math.PI)+320*Math.sin(e*Math.PI/30))/3,n},transformLng:function(t,e){var n=300+t+2*e+.1*t*t+.1*t*e+.1*Math.sqrt(Math.abs(t));return n+=2*(20*Math.sin(6*t*Math.PI)+20*Math.sin(2*t*Math.PI))/3,n+=2*(20*Math.sin(t*Math.PI)+40*Math.sin(t/3*Math.PI))/3,n+=2*(150*Math.sin(t/12*Math.PI)+300*Math.sin(t/30*Math.PI))/3,n},wgs84ToGcj02:function(t,e){var n=6378245,i=.006693421622965943;if(this.outOfChina(t,e))return[t,e];var a=this.transformLat(t-105,e-35),s=this.transformLng(t-105,e-35),o=e/180*Math.PI,c=Math.sin(o);c=1-i*c*c;var r=Math.sqrt(c);a=180*a/(n*(1-i)/(c*r)*Math.PI),s=180*s/(n/r*Math.cos(o)*Math.PI);var d=e+a,u=t+s;return[u,d]},goHX:function(){uni.switchTab({url:"/pages/verification/index"})},switchChange:function(t,e){t.isChecked=!t.isChecked;var n=this.typeIndex?"/api/Merchants/updateGuideSched":"/api/Merchants/updateGuideSchedService";this.Post({date:this.selectDay,online_type:t.isChecked?1:0,date_half:this.typeIndex?"":e+1,classify:this.typeIndex?2:""},n).then((function(t){}))},getDate:function(t){console.log("传递过来的日期",t),this.selectDay=t,this.sessionList.forEach((function(t){return t.isChecked=!1})),this.sessionLists[0].isChecked=!1,this.getList()},changeWork:function(t){},getList:function(){var t=this;this.Post({start_date:this.selectDay,end_date:this.selectDay,classify:this.typeIndex?2:3},"/api/Merchants/getGuideSchedList").then((function(e){if(e.data&&e.data.length>0){var n=e.data[0];t.typeIndex?t.sessionLists[0].isChecked=!!n.online_type:(t.sessionList[0].isChecked=!!n.morning_type,t.sessionList[1].isChecked=!!n.afternoon_type,t.sessionList[2].isChecked=!!n.day_type)}}))},getNowTime:function(t,e){var n=t,i=n.getFullYear(),a=n.getMonth()+1,s=n.getDate(),o=n.getHours()<10?"0"+n.getHours():n.getHours(),c=n.getMinutes()<10?"0"+n.getMinutes():n.getMinutes(),r=n.getSeconds()<10?"0"+n.getSeconds():n.getSeconds();if(a>=1&&a<=9&&(a="0"+a),s>=0&&s<=9&&(s="0"+s),1==e)if("ios"==uni.getSystemInfoSync().platform)var d=i+"/"+a+"/"+s+" "+o+":"+c+":"+r;else d=i+"-"+a+"-"+s+" "+o+":"+c+":"+r;else d=i+"/"+a+"/"+s;return d}}};e.default=o},df0f:function(t,e,n){"use strict";n.r(e);var i=n("dc8b"),a=n.n(i);for(var s in i)["default"].indexOf(s)<0&&function(t){n.d(e,t,(function(){return i[t]}))}(s);e["default"]=a.a}}]); \ No newline at end of file