"use strict";
const common_vendor = require("../../../common/vendor.js");
if (!Array) {
  const _easycom_hs_page_head_information2 = common_vendor.resolveComponent("hs-page-head-information");
  const _easycom_uni_icons2 = common_vendor.resolveComponent("uni-icons");
  const _easycom_cc_scroll_loading2 = common_vendor.resolveComponent("cc-scroll-loading");
  const _easycom_hs_footer2 = common_vendor.resolveComponent("hs-footer");
  (_easycom_hs_page_head_information2 + _easycom_uni_icons2 + _easycom_cc_scroll_loading2 + _easycom_hs_footer2)();
}
const _easycom_hs_page_head_information = () => "../../../components/hs-page-head-information/hs-page-head-information.js";
const _easycom_uni_icons = () => "../../../uni_modules/uni-icons/components/uni-icons/uni-icons.js";
const _easycom_cc_scroll_loading = () => "../../../common/components/cc-scroll-loading/cc-scroll-loading.js";
const _easycom_hs_footer = () => "../../../components/hs-footer/hs-footer.js";
if (!Math) {
  (_easycom_hs_page_head_information + _easycom_uni_icons + _easycom_cc_scroll_loading + _easycom_hs_footer)();
}
const _sfc_main = /* @__PURE__ */ common_vendor.defineComponent({
  __name: "index",
  setup(__props) {
    const metaData = { current_page: 1, last_page: 1, per_page: 10, total: 1 };
    const list = common_vendor.ref([{ checked: false }]);
    const handleToPage = () => {
      common_vendor.index.navigateTo({
        url: "/ME/me_invoice/add/index"
      });
    };
    const handleInvoice = () => {
      var _a;
      if ((_a = list == null ? void 0 : list.value[0]) == null ? void 0 : _a.checked) {
        common_vendor.index.showModal({
          title: "提示",
          content: "当前项目暂未开放！",
          success: function(res) {
            if (res.confirm) {
              console.log("用户点击确定");
            } else if (res.cancel) {
              console.log("用户点击取消");
            }
          }
        });
      } else {
        common_vendor.index.showToast({
          title: "请选择发票抬头",
          icon: "none"
        });
      }
    };
    const handleDeleteClick = () => {
      common_vendor.index.showModal({
        title: "提示",
        content: "演示发票抬头不能删除！",
        showCancel: false,
        confirmColor: "#0082FA",
        success: function(res) {
          if (res.confirm) {
            console.log("用户点击确定");
          } else if (res.cancel) {
            console.log("用户点击取消");
          }
        }
      });
    };
    return (_ctx, _cache) => {
      return {
        a: common_vendor.p({
          title: "365天后截止在线开票，届时请前往物业管理处索取发票!"
        }),
        b: common_vendor.f(list.value, (i, index, i0) => {
          return common_vendor.e({
            a: i.checked
          }, i.checked ? {
            b: "fde7887c-2-" + i0 + ",fde7887c-1",
            c: common_vendor.p({
              type: "checkbox-filled",
              size: "20",
              color: "#2A7EFB"
            })
          } : {
            d: "fde7887c-3-" + i0 + ",fde7887c-1",
            e: common_vendor.p({
              type: "circle",
              size: "20",
              color: "#666"
            })
          }, {
            f: common_vendor.o(($event) => i.checked = !i.checked, `item_${index}`),
            g: common_vendor.o(handleDeleteClick, `item_${index}`),
            h: common_vendor.o(handleToPage, `item_${index}`),
            i: `item_${index}`,
            j: common_vendor.n(`invoice_item ${i.checked ? "invoice_item_active" : ""}`)
          });
        }),
        c: common_vendor.p({
          meta: metaData
        }),
        d: common_vendor.o(($event) => handleToPage()),
        e: common_vendor.o(($event) => handleInvoice()),
        f: common_vendor.p({
          btnParimaryName: "开发票",
          btnOtherName: "添加发票抬头",
          btnOtherShow: true
        })
      };
    };
  }
});
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__file", "/Users/zsq/Sources/github/2025property-pay/pay-customer/src/ME/me_invoice/list/index.vue"]]);
wx.createPage(MiniProgramPage);
