"use strict";
const common_vendor = require("../../../common/vendor.js");
const common_libraries_userUserLogin = require("../../../common/libraries/userUserLogin.js");
const pages_index_model = require("../model.js");
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");
const _sfc_main = /* @__PURE__ */ common_vendor.defineComponent({
  __name: "ShowData",
  setup(__props) {
    const userLoginStatus = common_vendor.ref(false);
    const toPage = (url) => {
      var _a;
      common_vendor.index.navigateTo({
        url: !((_a = common_libraries_userUserLogin.getUser) == null ? void 0 : _a.getLoginStatus()) ? "/pages/login" : url || ""
      });
    };
    common_vendor.onMounted(async () => {
      var _a, _b, _c, _d;
      await ((_a = common_vendor.getCurrentInstance()) == null ? void 0 : _a.appContext.config.globalProperties.$onLaunched);
      userLoginStatus.value = (_b = common_libraries_userUserLogin.getUser) == null ? void 0 : _b.getLoginStatus();
      console.log("useModel?.userData?.value", (_d = (_c = pages_index_model.useModel) == null ? void 0 : _c.userData) == null ? void 0 : _d.value);
    });
    common_vendor.onShow(async () => {
      var _a, _b, _c, _d;
      await ((_a = common_vendor.getCurrentInstance()) == null ? void 0 : _a.appContext.config.globalProperties.$onLaunched);
      userLoginStatus.value = (_b = common_libraries_userUserLogin.getUser) == null ? void 0 : _b.getLoginStatus();
      console.log("useModel?.userData?.value", (_d = (_c = pages_index_model.useModel) == null ? void 0 : _c.userData) == null ? void 0 : _d.value);
    });
    return (_ctx, _cache) => {
      var _a, _b, _c, _d, _e, _f;
      return {
        a: common_vendor.t(userLoginStatus.value ? ((_c = (_b = (_a = common_vendor.unref(pages_index_model.useModel)) == null ? void 0 : _a.userData) == null ? void 0 : _b.value) == null ? void 0 : _c.arrearage_house_num) || "0" : "-"),
        b: common_vendor.o(($event) => toPage("/BILL/outstanding_fee/index/index")),
        c: common_vendor.t(userLoginStatus.value ? ((_f = (_e = (_d = common_vendor.unref(pages_index_model.useModel)) == null ? void 0 : _d.userData) == null ? void 0 : _e.value) == null ? void 0 : _f.work_order_num) || "0" : "-"),
        d: common_vendor.o(($event) => toPage("/WORKORDER/list/index"))
      };
    };
  }
});
const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__scopeId", "data-v-e5fbd9da"], ["__file", "/Users/zsq/Sources/github/2025property-pay/pay-employee/src/pages/index/components/ShowData.vue"]]);
wx.createComponent(Component);
