From 8265412eef286cc6027c8ec6085d6b059b7ab457 Mon Sep 17 00:00:00 2001 From: Liuyi <candymxq888@outlook.com> Date: 星期五, 29 十一月 2024 17:30:18 +0800 Subject: [PATCH] 添加参数修改,设备详情 --- unpackage/dist/dev/mp-weixin/app.js | 106 +++++++--------------------------------------------- 1 files changed, 15 insertions(+), 91 deletions(-) diff --git a/unpackage/dist/dev/mp-weixin/app.js b/unpackage/dist/dev/mp-weixin/app.js index 7cb5c61..42bba60 100644 --- a/unpackage/dist/dev/mp-weixin/app.js +++ b/unpackage/dist/dev/mp-weixin/app.js @@ -1,8 +1,8 @@ "use strict"; Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" }); const common_vendor = require("./common/vendor.js"); -const api_index = require("./api/index.js"); if (!Math) { + "./pages/login/index.js"; "./pages/index/index.js"; "./pages/addCard/index.js"; "./pages/userInfo/index.js"; @@ -26,110 +26,34 @@ "./pages/scanRecharge/index.js"; "./pages/scanSuccess/index.js"; "./pages/counterRecharge/index.js"; - "./pages/pointsMall/index.js"; + "./pages/wxScanWater/index.js"; + "./pagesAdmin/adminPlatform/home.js"; + "./pagesAdmin/adminPlatform/facility.js"; + "./pagesAdmin/adminPlatform/facilityDetail.js"; + "./pagesAdmin/adminPlatform/inspect.js"; + "./pagesAdmin/adminPlatform/params.js"; + "./pagesPoints/pointsMall/index.js"; + "./pagesPoints/pointsMall/pointsGetRecord/index.js"; + "./pagesPoints/pointsMall/pointsExchangeRecord/index.js"; + "./pagesPoints/pointsMall/pointsGoodsDetail/index.js"; + "./pagesPoints/pointsMall/pointsrule/index.js"; } const _sfc_main = { __name: "App", setup(__props) { - function wxLogin() { - if (!common_vendor.index.getStorageSync("openId")) { - common_vendor.wx$1.login({ - success: async (res1) => { - common_vendor.index.setStorageSync("code", res1.code); - await api_index.wxLoginApi({ code: res1.code }).then((res2) => { - common_vendor.index.setStorageSync("openId", res2.data.userId); - common_vendor.index.setStorageSync("token", res2.data.token); - }); - }, - fail: (e) => { - common_vendor.index.showToast({ - title: "登录失败,请退出重试!", - duration: 2e3 - }); - console.log(e); - } - }); - } - } - let userLocation = { - lat: "", - lon: "" - }; - function getUserLocation() { - common_vendor.index.authorize({ - scope: "scope.userLocation", - success() { - console.log("成功授权位置信息1"); - storageLocation(); - }, - fail() { - console.log("用户拒绝授权位置信息,再次提示用户授权"); - showToast(); - } - }); - function storageLocation() { - common_vendor.index.getLocation({ - type: "gcj02", - isHighAccuracy: true, - success: (res) => { - userLocation.lat = res.latitude; - userLocation.lon = res.longitude; - common_vendor.index.setStorageSync("userLocation", JSON.stringify(userLocation)); - }, - fail: () => { - showToast(); - } - }); - } - function showToast() { - common_vendor.index.showModal({ - title: "请求授权当前位置", - content: "我们需要获取地理位置信息,为您获取附近站点信息!", - confirmText: "前往设置", - success: (res) => { - if (res.confirm) { - common_vendor.index.openSetting({ - success: (res1) => { - if (res1.authSetting["scope.userLocation"]) { - console.log("用户二次授权成功"); - storageLocation(); - } else { - showToast(); - console.log("用户拒绝授权"); - } - } - }); - } else { - common_vendor.index.showToast({ - title: "请先授权!", - duration: 2e3, - icon: "none" - }); - showToast(); - } - } - }); - } - } common_vendor.onLaunch(async () => { - await wxLogin(); - await getUserLocation(); - }); - common_vendor.onShow(() => { - console.log("App Show"); - }); - common_vendor.onHide(() => { - console.log("App Hide"); + console.log("进入APP.vue"); }); return () => { }; } }; const navbar = () => "./components/navbar/navbar.js"; +const pointNavbar = () => "./components/pointNavbar/pointNavbar.js"; const DaTree = () => "./components/da-tree/index.js"; function createApp() { const app = common_vendor.createSSRApp(_sfc_main); - app.component("navbar", navbar).component("DaTree", DaTree); + app.component("navbar", navbar).component("pointNavbar", pointNavbar).component("DaTree", DaTree); return { app }; -- Gitblit v1.9.3