"use strict";const e=require("../../common/vendor.js"),o=require("../../common/libraries/userUserLogin.js");if(require("../../common/libraries/request.js"),require("../../common/store/useWeAppAuthStore.js"),require("../../gen/Apis.js"),require("../../common/store/useWatermarkStore.js"),require("../../common/store/useWorkStore.js"),require("../../common/libraries/apiLoading.js"),!Array){e.resolveComponent("hs-footer")()}Math;const r=e.defineComponent({__name:"index",setup(r){const n=e.ref(!1);return e.onShow(async()=>{var r,i,s;if(await(null==(r=e.getCurrentInstance())?void 0:r.appContext.config.globalProperties.$onLaunched),null==(i=o.getUser)?void 0:i.getLoginStatus()){const o=e.index.getEnterOptionsSync();console.log(o,"getQrcode");let r=null==o?void 0:o.query;if(null==r?void 0:r.scene){let o=null==(s=null==r?void 0:r.scene)?void 0:s.split("_");"1"===o[0]&&e.index.redirectTo({url:`/INDEX/release_items/index?id=${o[1]}`}),"2"===o[0]&&e.index.redirectTo({url:`/INDEX/pass/index?source=2&id=${o[1]}`}),"3"===o[0]&&e.index.redirectTo({url:`/INDEX/patrol_task_list/index?id=${o[1]}`}),"4"===o[0]&&e.index.redirectTo({url:`/INDEX/pass/index?source=4&customers_id=${o[1]}&asset_houses_id=${o[2]}`})}else n.value=!0}else e.index.showModal({title:"提示",content:"检测到您还未登录，是否去登录？",confirmText:"去登录",cancelText:"返回首页",confirmColor:"#0082FA",success:function(o){o.confirm?(e.index.navigateTo({url:"/pages/login?source=transfer"}),console.log("用户点击确定")):o.cancel&&(e.index.switchTab({url:"/pages/index/index"}),console.log("用户点击取消"))}})}),(o,r)=>e.e({a:!n.value},n.value?{b:e.p({btnParimaryName:"返回首页"})}:{})}});wx.createPage(r);
