"use strict";
const common_vendor = require("../../common/vendor.js");
const common_libraries_day = require("../../common/libraries/day.js");
const gen_Enums = require("../../gen/Enums.js");
const WORKORDER_list_method = require("./method.js");
const WORKORDER_list_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_hs_tabs2 = common_vendor.resolveComponent("hs-tabs");
  const _easycom_hs_enum_tag2 = common_vendor.resolveComponent("hs-enum-tag");
  const _easycom_hs_level2 = common_vendor.resolveComponent("hs-level");
  const _easycom_up_icon2 = common_vendor.resolveComponent("up-icon");
  const _easycom_hs_up_rate2 = common_vendor.resolveComponent("hs-up-rate");
  const _easycom_cc_scroll_loading2 = common_vendor.resolveComponent("cc-scroll-loading");
  (_easycom_hs_tabs2 + _easycom_hs_enum_tag2 + _easycom_hs_level2 + _easycom_up_icon2 + _easycom_hs_up_rate2 + _easycom_cc_scroll_loading2)();
}
const _easycom_hs_tabs = () => "../../components/hs-tabs/hs-tabs.js";
const _easycom_hs_enum_tag = () => "../../components/hs-enum-tag/hs-enum-tag.js";
const _easycom_hs_level = () => "../../components/hs-level/hs-level.js";
const _easycom_up_icon = () => "../../node-modules/uview-plus/components/u-icon/u-icon.js";
const _easycom_hs_up_rate = () => "../../components/hs-up-rate/hs-up-rate.js";
const _easycom_cc_scroll_loading = () => "../../common/components/cc-scroll-loading/cc-scroll-loading.js";
if (!Math) {
  (_easycom_hs_tabs + _easycom_hs_enum_tag + _easycom_hs_level + _easycom_up_icon + _easycom_hs_up_rate + _easycom_cc_scroll_loading)();
}
const _sfc_main = /* @__PURE__ */ common_vendor.defineComponent({
  __name: "index",
  setup(__props) {
    const tablist = [
      { label: "处理中", value: "Processing" },
      { label: "待支付", value: "PendingPayment" },
      { label: "待验收", value: "PendingAcceptance" },
      { label: "已完成", value: "Completed" },
      { label: "已关闭", value: "Closed" }
    ];
    common_vendor.onShow(() => {
      var _a;
      WORKORDER_list_model.useModel.formData.value.page = 1;
      WORKORDER_list_model.useModel.listData.value = [];
      (_a = WORKORDER_list_method.method) == null ? void 0 : _a.getList();
    });
    return (_ctx, _cache) => {
      var _a, _b, _c, _d, _e, _f, _g, _h;
      return {
        a: common_vendor.o((_a = common_vendor.unref(WORKORDER_list_method.method)) == null ? void 0 : _a.handleChangeTabs),
        b: common_vendor.p({
          list: tablist,
          current: (_c = (_b = common_vendor.unref(WORKORDER_list_model.useModel)) == null ? void 0 : _b.currentTabs) == null ? void 0 : _c.value
        }),
        c: common_vendor.f((_e = (_d = common_vendor.unref(WORKORDER_list_model.useModel)) == null ? void 0 : _d.listData) == null ? void 0 : _e.value, (i, index, i0) => {
          var _a2, _b2, _c2, _d2, _e2;
          return common_vendor.e({
            a: "16520412-2-" + i0 + ",16520412-1",
            b: common_vendor.p({
              value: i == null ? void 0 : i.type,
              Enums: common_vendor.unref(gen_Enums.HouseWorkOrdersTypeEnum)
            }),
            c: i == null ? void 0 : i.location
          }, (i == null ? void 0 : i.location) ? {
            d: "16520412-3-" + i0 + ",16520412-1",
            e: common_vendor.p({
              value: i == null ? void 0 : i.location,
              Enums: common_vendor.unref(gen_Enums.HouseWorkOrdersLocationEnum)
            })
          } : {}, {
            f: (i == null ? void 0 : i.type) === "Repair" || (i == null ? void 0 : i.type) === "Incident" || (i == null ? void 0 : i.type) === "Complaint"
          }, (i == null ? void 0 : i.type) === "Repair" || (i == null ? void 0 : i.type) === "Incident" || (i == null ? void 0 : i.type) === "Complaint" ? common_vendor.e({
            g: (i == null ? void 0 : i.status) === "Processing"
          }, (i == null ? void 0 : i.status) === "Processing" ? {
            h: "16520412-4-" + i0 + ",16520412-1",
            i: common_vendor.p({
              level: i == null ? void 0 : i.level
            })
          } : {}) : {}, {
            j: "16520412-5-" + i0 + ",16520412-1",
            k: common_vendor.p({
              value: i == null ? void 0 : i.status,
              Enums: common_vendor.unref(gen_Enums.HouseWorkOrdersStatusEnum)
            }),
            l: common_vendor.n(`btn_status status_${i == null ? void 0 : i.status}`),
            m: common_vendor.t(((_a2 = i == null ? void 0 : i.asset_house) == null ? void 0 : _a2.full_name) || ((_b2 = i == null ? void 0 : i.asset_project) == null ? void 0 : _b2.name)),
            n: common_vendor.t(i == null ? void 0 : i.content),
            o: (i == null ? void 0 : i.status) === "Processing"
          }, (i == null ? void 0 : i.status) === "Processing" ? common_vendor.e({
            p: (i == null ? void 0 : i.status) !== "Completed" && (i == null ? void 0 : i.status) !== "Closed" && (i == null ? void 0 : i.location) === "MyHome"
          }, (i == null ? void 0 : i.status) !== "Completed" && (i == null ? void 0 : i.status) !== "Closed" && (i == null ? void 0 : i.location) === "MyHome" ? {
            q: "16520412-6-" + i0 + ",16520412-1",
            r: common_vendor.p({
              name: "clock",
              color: ((_c2 = common_vendor.unref(common_libraries_day.getTimeStatus)(i == null ? void 0 : i.expect_end_time)) == null ? void 0 : _c2.color) || "#000",
              size: "14"
            }),
            s: common_vendor.t((_d2 = common_vendor.unref(common_libraries_day.getTimeStatus)(i == null ? void 0 : i.expect_end_time)) == null ? void 0 : _d2.label),
            t: common_vendor.n(`todo_done_card_footer status_${(_e2 = common_vendor.unref(common_libraries_day.getTimeStatus)(i == null ? void 0 : i.expect_end_time)) == null ? void 0 : _e2.status}`)
          } : {}) : {}, {
            v: (i == null ? void 0 : i.status) === "Completed" && (i == null ? void 0 : i.accept_time)
          }, (i == null ? void 0 : i.status) === "Completed" && (i == null ? void 0 : i.accept_time) ? {
            w: common_vendor.t(i == null ? void 0 : i.accept_time)
          } : {}, {
            x: i == null ? void 0 : i.evaluation_score
          }, (i == null ? void 0 : i.evaluation_score) ? {
            y: "16520412-7-" + i0 + ",16520412-1",
            z: common_vendor.p({
              valueModel: i == null ? void 0 : i.evaluation_score
            })
          } : {}, {
            A: common_vendor.o(($event) => {
              var _a3;
              return (_a3 = common_vendor.unref(WORKORDER_list_method.method)) == null ? void 0 : _a3.handleToDetail(i);
            }, `items_${index}`),
            B: (i == null ? void 0 : i.type) === "SecurityInspection"
          }, (i == null ? void 0 : i.type) === "SecurityInspection" ? {
            C: common_vendor.o(($event) => {
              var _a3;
              return (_a3 = common_vendor.unref(WORKORDER_list_method.method)) == null ? void 0 : _a3.handleUpdateSetp(i);
            }, `items_${index}`)
          } : common_vendor.e({
            D: (i == null ? void 0 : i.status) !== "Completed" && (i == null ? void 0 : i.status) !== "Closed"
          }, (i == null ? void 0 : i.status) !== "Completed" && (i == null ? void 0 : i.status) !== "Closed" ? common_vendor.e({
            E: (i == null ? void 0 : i.type) !== "RenovationInspection" && (i == null ? void 0 : i.type) !== "RenovationAcceptance"
          }, (i == null ? void 0 : i.type) !== "RenovationInspection" && (i == null ? void 0 : i.type) !== "RenovationAcceptance" ? {
            F: common_vendor.o(($event) => {
              var _a3;
              return (_a3 = common_vendor.unref(WORKORDER_list_method.method)) == null ? void 0 : _a3.handleCopyPhone(i);
            }, `items_${index}`)
          } : {}, {
            G: (i == null ? void 0 : i.status) === "Processing"
          }, (i == null ? void 0 : i.status) === "Processing" ? {
            H: common_vendor.o(($event) => {
              var _a3;
              return (_a3 = common_vendor.unref(WORKORDER_list_method.method)) == null ? void 0 : _a3.handleUpdateSetp(i);
            }, `items_${index}`)
          } : {}, {
            I: (i == null ? void 0 : i.status) === "PendingPayment"
          }, (i == null ? void 0 : i.status) === "PendingPayment" ? {
            J: common_vendor.o(($event) => {
              var _a3;
              return (_a3 = common_vendor.unref(WORKORDER_list_method.method)) == null ? void 0 : _a3.handlePendingPaymentQrCode(i);
            }, `items_${index}`)
          } : {}) : {}), {
            K: `items_${index}`
          });
        }),
        d: common_vendor.o((_f = common_vendor.unref(WORKORDER_list_method.method)) == null ? void 0 : _f.handleLoad),
        e: common_vendor.p({
          meta: (_h = (_g = common_vendor.unref(WORKORDER_list_model.useModel)) == null ? void 0 : _g.metaData) == null ? void 0 : _h.value
        })
      };
    };
  }
});
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__file", "/Users/zsq/Sources/github/2025property-pay/pay-employee/src/WORKORDER/list/index.vue"]]);
wx.createPage(MiniProgramPage);
