"use strict";
const common_vendor = require("../../../common/vendor.js");
const common_libraries_day = require("../../../common/libraries/day.js");
const INDEX_task_show_method = require("./method.js");
const INDEX_task_show_model = require("./model.js");
const gen_Enums = require("../../../gen/Enums.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_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_footer2 = common_vendor.resolveComponent("hs-footer");
  (_easycom_hs_enum_tag2 + _easycom_hs_level2 + _easycom_up_icon2 + _easycom_hs_footer2)();
}
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_footer = () => "../../../components/hs-footer/hs-footer.js";
if (!Math) {
  (_easycom_hs_enum_tag + _easycom_hs_level + _easycom_up_icon + MyProcessLogs + _easycom_hs_footer)();
}
const MyProcessLogs = () => "./components/ProcessLogs.js";
const _sfc_main = /* @__PURE__ */ common_vendor.defineComponent({
  __name: "index",
  setup(__props) {
    common_vendor.onLoad((e) => {
      var _a, _b;
      INDEX_task_show_model.useModel.dataShow.value = {};
      (_a = INDEX_task_show_method.method) == null ? void 0 : _a.getShow(e == null ? void 0 : e.id);
      (_b = INDEX_task_show_method.method) == null ? void 0 : _b.getHouseWorkLogs(e == null ? void 0 : e.id);
    });
    common_vendor.onShow(() => {
      var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k;
      if ((_c = (_b = (_a = INDEX_task_show_model.useModel) == null ? void 0 : _a.dataShow) == null ? void 0 : _b.value) == null ? void 0 : _c.id) {
        (_g = INDEX_task_show_method.method) == null ? void 0 : _g.getShow((_f = (_e = (_d = INDEX_task_show_model.useModel) == null ? void 0 : _d.dataShow) == null ? void 0 : _e.value) == null ? void 0 : _f.id);
        (_k = INDEX_task_show_method.method) == null ? void 0 : _k.getHouseWorkLogs((_j = (_i = (_h = INDEX_task_show_model.useModel) == null ? void 0 : _h.dataShow) == null ? void 0 : _i.value) == null ? void 0 : _j.id);
      }
    });
    common_vendor.onUnload(() => {
      INDEX_task_show_model.useModel.logsData.value = [];
    });
    return (_ctx, _cache) => {
      var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _A, _B, _C, _D, _E, _F, _G, _H, _I, _J, _K, _L, _M, _N, _O, _P, _Q, _R, _S, _T, _U, _V, _W, _X, _Y, _Z, __, _$, _aa, _ba, _ca, _da, _ea, _fa, _ga, _ha, _ia, _ja, _ka, _la, _ma, _na, _oa, _pa, _qa, _ra, _sa, _ta, _ua, _va, _wa, _xa, _ya, _za, _Aa, _Ba, _Ca, _Da, _Ea, _Fa, _Ga, _Ha, _Ia, _Ja, _Ka, _La, _Ma, _Na, _Oa, _Pa, _Qa, _Ra, _Sa, _Ta, _Ua, _Va, _Wa, _Xa, _Ya, _Za, __a, _$a, _ab, _bb, _cb, _db, _eb, _fb, _gb, _hb, _ib, _jb, _kb, _lb, _mb, _nb, _ob, _pb, _qb, _rb, _sb, _tb, _ub, _vb, _wb, _xb, _yb;
      return common_vendor.e({
        a: common_vendor.p({
          value: (_c = (_b = (_a = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _a.dataShow) == null ? void 0 : _b.value) == null ? void 0 : _c.type,
          Enums: common_vendor.unref(gen_Enums.HouseWorkOrdersTypeEnum)
        }),
        b: (_f = (_e = (_d = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _d.dataShow) == null ? void 0 : _e.value) == null ? void 0 : _f.location
      }, ((_i = (_h = (_g = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _g.dataShow) == null ? void 0 : _h.value) == null ? void 0 : _i.location) ? {
        c: common_vendor.p({
          value: (_l = (_k = (_j = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _j.dataShow) == null ? void 0 : _k.value) == null ? void 0 : _l.location,
          Enums: common_vendor.unref(gen_Enums.HouseWorkOrdersLocationEnum)
        })
      } : {}, {
        d: ((_o = (_n = (_m = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _m.dataShow) == null ? void 0 : _n.value) == null ? void 0 : _o.status) == "Processing"
      }, ((_r = (_q = (_p = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _p.dataShow) == null ? void 0 : _q.value) == null ? void 0 : _r.status) == "Processing" ? {
        e: common_vendor.p({
          level: (_u = (_t = (_s = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _s.dataShow) == null ? void 0 : _t.value) == null ? void 0 : _u.level
        })
      } : {}, {
        f: common_vendor.p({
          value: (_x = (_w = (_v = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _v.dataShow) == null ? void 0 : _w.value) == null ? void 0 : _x.status,
          Enums: common_vendor.unref(gen_Enums.HouseWorkOrdersStatusEnum)
        }),
        g: common_vendor.n(`btn_status status_${(_A = (_z = (_y = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _y.dataShow) == null ? void 0 : _z.value) == null ? void 0 : _A.status}`),
        h: ((_D = (_C = (_B = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _B.dataShow) == null ? void 0 : _C.value) == null ? void 0 : _D.expect_end_time) && ((_G = (_F = (_E = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _E.dataShow) == null ? void 0 : _F.value) == null ? void 0 : _G.status) === "Pending" && ((_J = (_I = (_H = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _H.dataShow) == null ? void 0 : _I.value) == null ? void 0 : _J.location) === "MyHome"
      }, ((_M = (_L = (_K = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _K.dataShow) == null ? void 0 : _L.value) == null ? void 0 : _M.expect_end_time) && ((_P = (_O = (_N = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _N.dataShow) == null ? void 0 : _O.value) == null ? void 0 : _P.status) === "Pending" && ((_S = (_R = (_Q = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _Q.dataShow) == null ? void 0 : _R.value) == null ? void 0 : _S.location) === "MyHome" ? {
        i: common_vendor.p({
          name: "clock",
          color: ((_W = common_vendor.unref(common_libraries_day.getTimeStatus)((_V = (_U = (_T = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _T.dataShow) == null ? void 0 : _U.value) == null ? void 0 : _V.expect_end_time)) == null ? void 0 : _W.color) || "#000",
          size: "14"
        }),
        j: common_vendor.t((__ = common_vendor.unref(common_libraries_day.getTimeStatus)((_Z = (_Y = (_X = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _X.dataShow) == null ? void 0 : _Y.value) == null ? void 0 : _Z.expect_end_time)) == null ? void 0 : __.label),
        k: common_vendor.n(`time_status status_${(_ca = common_vendor.unref(common_libraries_day.getTimeStatus)((_ba = (_aa = (_$ = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _$.dataShow) == null ? void 0 : _aa.value) == null ? void 0 : _ba.expect_end_time)) == null ? void 0 : _ca.status}`)
      } : {}, {
        l: ((_fa = (_ea = (_da = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _da.dataShow) == null ? void 0 : _ea.value) == null ? void 0 : _fa.type) === "Repair" || ((_ia = (_ha = (_ga = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _ga.dataShow) == null ? void 0 : _ha.value) == null ? void 0 : _ia.type) === "Incident"
      }, ((_la = (_ka = (_ja = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _ja.dataShow) == null ? void 0 : _ka.value) == null ? void 0 : _la.type) === "Repair" || ((_oa = (_na = (_ma = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _ma.dataShow) == null ? void 0 : _na.value) == null ? void 0 : _oa.type) === "Incident" ? {
        m: common_vendor.t(((_sa = (_ra = (_qa = (_pa = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _pa.dataShow) == null ? void 0 : _qa.value) == null ? void 0 : _ra.asset_house) == null ? void 0 : _sa.full_name) || ((_wa = (_va = (_ua = (_ta = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _ta.dataShow) == null ? void 0 : _ua.value) == null ? void 0 : _va.asset_project) == null ? void 0 : _wa.name)),
        n: common_vendor.t((_za = (_ya = (_xa = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _xa.dataShow) == null ? void 0 : _ya.value) == null ? void 0 : _za.title)
      } : {}, {
        o: common_vendor.t((_Ca = (_Ba = (_Aa = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _Aa.dataShow) == null ? void 0 : _Ba.value) == null ? void 0 : _Ca.content),
        p: common_vendor.f((_Fa = (_Ea = (_Da = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _Da.dataShow) == null ? void 0 : _Ea.value) == null ? void 0 : _Fa.attachments, (k, idx, i0) => {
          return {
            a: k == null ? void 0 : k.url,
            b: `img_${idx}`,
            c: common_vendor.o(($event) => {
              var _a2;
              return (_a2 = common_vendor.unref(INDEX_task_show_method.method)) == null ? void 0 : _a2.handlePreviewImage(idx);
            }, `img_${idx}`)
          };
        }),
        q: common_vendor.t((_Ia = (_Ha = (_Ga = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _Ga.dataShow) == null ? void 0 : _Ha.value) == null ? void 0 : _Ia.code),
        r: ((_La = (_Ka = (_Ja = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _Ja.dataShow) == null ? void 0 : _Ka.value) == null ? void 0 : _La.type) !== "RenovationInspection" && ((_Oa = (_Na = (_Ma = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _Ma.dataShow) == null ? void 0 : _Na.value) == null ? void 0 : _Oa.type) !== "RenovationAcceptance"
      }, ((_Ra = (_Qa = (_Pa = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _Pa.dataShow) == null ? void 0 : _Qa.value) == null ? void 0 : _Ra.type) !== "RenovationInspection" && ((_Ua = (_Ta = (_Sa = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _Sa.dataShow) == null ? void 0 : _Ta.value) == null ? void 0 : _Ua.type) !== "RenovationAcceptance" ? {
        s: common_vendor.t(((_Ya = (_Xa = (_Wa = (_Va = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _Va.dataShow) == null ? void 0 : _Wa.value) == null ? void 0 : _Xa.customer) == null ? void 0 : _Ya.name) || ((_ab = (_$a = (__a = (_Za = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _Za.dataShow) == null ? void 0 : __a.value) == null ? void 0 : _$a.company_employee) == null ? void 0 : _ab.name))
      } : {}, {
        t: (_db = (_cb = (_bb = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _bb.dataShow) == null ? void 0 : _cb.value) == null ? void 0 : _db.reporter_name
      }, ((_gb = (_fb = (_eb = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _eb.dataShow) == null ? void 0 : _fb.value) == null ? void 0 : _gb.reporter_name) ? {
        v: common_vendor.t((_jb = (_ib = (_hb = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _hb.dataShow) == null ? void 0 : _ib.value) == null ? void 0 : _jb.reporter_name),
        w: common_vendor.t((_mb = (_lb = (_kb = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _kb.dataShow) == null ? void 0 : _lb.value) == null ? void 0 : _mb.reporter_phone)
      } : {}, {
        x: common_vendor.t((_pb = (_ob = (_nb = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _nb.dataShow) == null ? void 0 : _ob.value) == null ? void 0 : _pb.created_at),
        y: ((_sb = (_rb = (_qb = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _qb.dataShow) == null ? void 0 : _rb.value) == null ? void 0 : _sb.status) === "Pending"
      }, ((_vb = (_ub = (_tb = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _tb.dataShow) == null ? void 0 : _ub.value) == null ? void 0 : _vb.status) === "Pending" ? {
        z: common_vendor.o(($event) => {
          var _a2;
          return (_a2 = common_vendor.unref(INDEX_task_show_method.method)) == null ? void 0 : _a2.toPageUpdate("领取工单");
        }),
        A: common_vendor.o(($event) => {
          var _a2;
          return (_a2 = common_vendor.unref(INDEX_task_show_method.method)) == null ? void 0 : _a2.toPageUpdate("指派工单");
        }),
        B: common_vendor.p({
          btnParimaryName: "领取工单",
          btnOtherShow: (_yb = (_xb = (_wb = common_vendor.unref(INDEX_task_show_model.useModel)) == null ? void 0 : _wb.assignPermissionData) == null ? void 0 : _xb.value) == null ? void 0 : _yb.permission,
          btnOtherName: "指派工单"
        })
      } : {});
    };
  }
});
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__file", "/Users/zsq/Sources/github/2025property-pay/pay-employee/src/INDEX/task/show/index.vue"]]);
wx.createPage(MiniProgramPage);
