"use strict";
const common_vendor = require("../../../common/vendor.js");
const gen_Enums = require("../../../gen/Enums.js");
const BILL_record_payment_method = require("./method.js");
const BILL_record_payment_model = require("./model.js");
require("../../../common/libraries/apiLoading.js");
require("../../../gen/Apis.js");
require("../../../common/libraries/request.js");
require("../../../common/store/useWeAppAuthStore.js");
require("../../../common/store/useWatermarkStore.js");
require("../../../common/store/useWorkStore.js");
if (!Array) {
  const _easycom_uni_icons2 = common_vendor.resolveComponent("uni-icons");
  const _easycom_hs_enum_tag2 = common_vendor.resolveComponent("hs-enum-tag");
  const _easycom_cc_scroll_loading2 = common_vendor.resolveComponent("cc-scroll-loading");
  (_easycom_uni_icons2 + _easycom_hs_enum_tag2 + _easycom_cc_scroll_loading2)();
}
const _easycom_uni_icons = () => "../../../uni_modules/uni-icons/components/uni-icons/uni-icons.js";
const _easycom_hs_enum_tag = () => "../../../components/hs-enum-tag/hs-enum-tag.js";
const _easycom_cc_scroll_loading = () => "../../../common/components/cc-scroll-loading/cc-scroll-loading.js";
if (!Math) {
  (_easycom_uni_icons + _easycom_hs_enum_tag + _easycom_cc_scroll_loading)();
}
const _sfc_main = /* @__PURE__ */ common_vendor.defineComponent({
  __name: "index",
  setup(__props) {
    const billsShow = common_vendor.ref(false);
    common_vendor.onLoad((e) => {
      var _a;
      console.log(e, "e");
      BILL_record_payment_model.useModel.formData.value.asset_houses_id = e == null ? void 0 : e.asset_houses_id;
      (_a = BILL_record_payment_method.method) == null ? void 0 : _a.getHouseBills();
    });
    return (_ctx, _cache) => {
      var _a, _b, _c, _d, _e;
      return {
        a: common_vendor.f((_b = (_a = common_vendor.unref(BILL_record_payment_model.useModel)) == null ? void 0 : _a.listData) == null ? void 0 : _b.value, (i, index, i0) => {
          return common_vendor.e({
            a: common_vendor.t((i == null ? void 0 : i.display_text) || "-"),
            b: common_vendor.t(i == null ? void 0 : i.total_paid_amount_monthly),
            c: "410f6c84-1-" + i0 + ",410f6c84-0",
            d: common_vendor.o(($event) => billsShow.value = !billsShow.value, `items_${index}`)
          }, billsShow.value ? {
            e: common_vendor.f(i == null ? void 0 : i.bills, (k, idx, i1) => {
              return {
                a: "410f6c84-2-" + i0 + "-" + i1 + ",410f6c84-0",
                b: common_vendor.p({
                  value: k == null ? void 0 : k.type,
                  Enums: common_vendor.unref(gen_Enums.HouseBillsTypeEnum)
                }),
                c: common_vendor.t(k == null ? void 0 : k.total_payable_amount),
                d: `bills_${index}_${idx}`
              };
            })
          } : {}, {
            f: `items_${index}`
          });
        }),
        b: common_vendor.p({
          type: "down",
          size: "15",
          color: "#666"
        }),
        c: billsShow.value,
        d: common_vendor.o((_c = common_vendor.unref(BILL_record_payment_method.method)) == null ? void 0 : _c.loadMore),
        e: common_vendor.p({
          meta: (_e = (_d = common_vendor.unref(BILL_record_payment_model.useModel)) == null ? void 0 : _d.metaData) == null ? void 0 : _e.value
        })
      };
    };
  }
});
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__file", "/Users/zsq/Sources/github/2025property-pay/pay-employee/src/BILL/record/payment/index.vue"]]);
wx.createPage(MiniProgramPage);
