"use strict";
const common_vendor = require("../../common/vendor.js");
require("../../common/libraries/request.js");
const common_store_useWeAppAuthStore = require("../../common/store/useWeAppAuthStore.js");
require("../../common/store/useWorkStore.js");
const pages_index_model = require("./model.js");
const common_libraries_userUserLogin = require("../../common/libraries/userUserLogin.js");
const pages_index_method = require("./method.js");
require("../../gen/Apis.js");
require("../../common/libraries/setTabBar.js");
require("../../common/libraries/apiLoading.js");
if (!Array) {
  const _easycom_hs_all_page_bg2 = common_vendor.resolveComponent("hs-all-page-bg");
  _easycom_hs_all_page_bg2();
}
const _easycom_hs_all_page_bg = () => "../../components/hs-all-page-bg/hs-all-page-bg.js";
if (!Math) {
  (_easycom_hs_all_page_bg + MyPageHeadTitle + MyPageBanner + MyClassification + MyNewsList + MyAiInput + MyTabs + MyModalServer + MyOfficialAccount)();
}
const MyNewsList = () => "./components/NewsList.js";
const MyPageHeadTitle = () => "./components/PageHeadTitle.js";
const MyPageBanner = () => "./components/PageBanner.js";
const MyClassification = () => "./components/Classification.js";
const MyAiInput = () => "./components/AiInput.js";
const MyModalServer = () => "./components/ModalServer.js";
const MyTabs = () => "./components/Tabs.js";
const MyOfficialAccount = () => "./components/OfficialAccount.js";
const _sfc_defineComponent = /* @__PURE__ */ common_vendor.defineComponent({
  __name: "index",
  setup(__props) {
    const auth = common_store_useWeAppAuthStore.useWeAppAuthStore();
    common_vendor.onLoad(async (e) => {
      var _a;
      await ((_a = common_vendor.getCurrentInstance()) == null ? void 0 : _a.appContext.config.globalProperties.$onLaunched);
      console.log("页面加载", auth == null ? void 0 : auth.data);
    });
    common_vendor.onPageScroll((e) => {
      pages_index_model.useModel.scrollTop.value = e.scrollTop;
    });
    common_vendor.onShow(async (e) => {
      var _a, _b, _c, _d, _e, _f, _g;
      await ((_a = common_vendor.getCurrentInstance()) == null ? void 0 : _a.appContext.config.globalProperties.$onLaunched);
      pages_index_model.useModel.user.value = (_b = auth == null ? void 0 : auth.data) == null ? void 0 : _b.user;
      pages_index_model.useModel.pageConfig.value = ((_e = (_d = (_c = auth == null ? void 0 : auth.data) == null ? void 0 : _c.config) == null ? void 0 : _d.companyConfig) == null ? void 0 : _e.config_value) || {};
      console.log("页面显示");
      if ((_f = common_libraries_userUserLogin.getUserLogin) == null ? void 0 : _f.getLoginStatus()) {
        (_g = pages_index_method.method) == null ? void 0 : _g.getCountBills();
      }
      if (auth == null ? void 0 : auth.data.house_register) {
        console.log("house_register", auth == null ? void 0 : auth.data.house_register);
        auth == null ? void 0 : auth.getIsHouseExist();
      } else {
        pages_index_model.useModel.countBills.value = 0;
      }
    });
    common_vendor.onShareAppMessage(() => {
      return {
        title: "",
        path: "/pages/index/index"
      };
    });
    common_vendor.onShareTimeline(() => {
      return {
        title: "",
        path: "/pages/index/index"
      };
    });
    return (_ctx, _cache) => {
      return {};
    };
  }
});
_sfc_defineComponent.__runtimeHooks = 7;
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_defineComponent, [["__file", "/Users/zsq/Sources/github/2025property-pay/pay-customer/src/pages/index/index.vue"]]);
wx.createPage(MiniProgramPage);
