"use strict"; const common_vendor = require("../../../common/vendor.js"); const gen_Enums = require("../../../gen/Enums.js"); const pages_me_model = require("../model.js"); const pages_me_method = require("../method.js"); const common_libraries_apiLoading = require("../../../common/libraries/apiLoading.js"); const gen_Apis = require("../../../gen/Apis.js"); const common_libraries_naviHelper = require("../../../common/libraries/naviHelper.js"); require("../../../common/libraries/request.js"); require("../../../common/store/useWeAppAuthStore.js"); require("../../../common/libraries/setTabBar.js"); require("../../../common/store/useWorkStore.js"); if (!Array) { const _easycom_hs_enum_tag2 = common_vendor.resolveComponent("hs-enum-tag"); const _easycom_hs_button2 = common_vendor.resolveComponent("hs-button"); const _easycom_cc_scroll_loading2 = common_vendor.resolveComponent("cc-scroll-loading"); const _easycom_hs_popup_custom2 = common_vendor.resolveComponent("hs-popup-custom"); (_easycom_hs_enum_tag2 + _easycom_hs_button2 + _easycom_cc_scroll_loading2 + _easycom_hs_popup_custom2)(); } const _easycom_hs_enum_tag = () => "../../../components/hs-enum-tag/hs-enum-tag.js"; const _easycom_hs_button = () => "../../../components/hs-button/hs-button.js"; const _easycom_cc_scroll_loading = () => "../../../common/components/cc-scroll-loading/cc-scroll-loading.js"; const _easycom_hs_popup_custom = () => "../../../components/hs-popup-custom/hs-popup-custom.js"; if (!Math) { (_easycom_hs_enum_tag + _easycom_hs_button + _easycom_cc_scroll_loading + _easycom_hs_popup_custom)(); } const _sfc_main = /* @__PURE__ */ common_vendor.defineComponent({ __name: "ToBeDone", setup(__props) { const show = common_vendor.ref(false); const rejectReason = common_vendor.ref({ id: "", reason: "" }); const handleClosePopup = () => { show.value = false; }; const handleAuditShow = (e) => { show.value = true; rejectReason.value.id = e == null ? void 0 : e.id; rejectReason.value.reason = ""; }; const handleSubmit = () => { var _a; if (!((_a = rejectReason.value) == null ? void 0 : _a.reason)) { return common_libraries_naviHelper.showToast("请输入理由!"); } common_libraries_apiLoading.getApiLoading(gen_Apis.Apis.Archive.HouseRegisters.Audit, { ...rejectReason.value, status: "Rejected" }).then((res) => { var _a2; common_libraries_naviHelper.showToast("提交成功!"); show.value = false; (_a2 = pages_me_method.method) == null ? void 0 : _a2.handleSrarch(); console.log(res); }); }; return (_ctx, _cache) => { var _a, _b; return { a: common_vendor.f((_b = (_a = common_vendor.unref(pages_me_model.useModel)) == null ? void 0 : _a.dataList) == null ? void 0 : _b.value, (i, index, i0) => { var _a2; return common_vendor.e({ a: common_vendor.t((_a2 = i == null ? void 0 : i.asset_house) == null ? void 0 : _a2.full_name), b: "50b26e1a-1-" + i0 + ",50b26e1a-0", c: common_vendor.p({ value: i == null ? void 0 : i.approval_owner_status, Enums: common_vendor.unref(gen_Enums.HouseRegistersStatusEnum) }), d: common_vendor.n(`status_tab status_${i == null ? void 0 : i.approval_owner_status}`), e: common_vendor.f(i == null ? void 0 : i.customer_info, (k, idx, i1) => { return { a: common_vendor.t(k == null ? void 0 : k.name), b: common_vendor.t(k == null ? void 0 : k.phone), c: "50b26e1a-2-" + i0 + "-" + i1 + ",50b26e1a-0", d: common_vendor.p({ value: k == null ? void 0 : k.residential_relation, Enums: common_vendor.unref(gen_Enums.HouseOccupantsResidentialRelationEnum) }), e: `f_item_${index}_${idx}` }; }), f: common_vendor.t(i == null ? void 0 : i.created_at), g: (i == null ? void 0 : i.approval_owner_status) === "Pending" }, (i == null ? void 0 : i.approval_owner_status) === "Pending" ? { h: common_vendor.o(($event) => handleAuditShow(i), `item_${index}`), i: "50b26e1a-3-" + i0 + ",50b26e1a-0", j: common_vendor.p({ label: "驳回", size: "sm", type: "display" }), k: common_vendor.o(($event) => { var _a3; return (_a3 = common_vendor.unref(pages_me_method.method)) == null ? void 0 : _a3.handleAudit(i); }, `item_${index}`), l: "50b26e1a-4-" + i0 + ",50b26e1a-0", m: common_vendor.p({ label: "审核通过", size: "sm", type: "primary" }) } : {}, { n: `item_${index}` }); }), b: common_vendor.o(common_vendor.unref(pages_me_method.method).handleLoadMore), c: common_vendor.p({ meta: common_vendor.unref(pages_me_model.useModel).meta.value }), d: rejectReason.value.reason, e: common_vendor.o(($event) => rejectReason.value.reason = $event.detail.value), f: common_vendor.o(handleClosePopup), g: common_vendor.p({ label: "取消", size: "md", type: "display" }), h: common_vendor.o(handleSubmit), i: common_vendor.p({ label: "提交", size: "md", type: "primary" }), j: common_vendor.p({ show: show.value, mode: "center", title: "审核驳回" }) }; }; } }); const Component = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__scopeId", "data-v-50b26e1a"], ["__file", "/Users/zsq/Sources/github/2025property-pay/pay-customer/src/pages/me/components/ToBeDone.vue"]]); wx.createComponent(Component);