"use strict";require("../../common/libraries/request.js"),require("../../common/store/useWatermarkStore.js");const e=require("../../common/store/useWeAppAuthStore.js");require("../../common/store/useWorkStore.js");const o=require("./model.js"),r=require("../../gen/Apis.js"),s=require("../../common/libraries/apiLoading.js"),t=require("../../common/libraries/naviHelper.js");e.useWeAppAuthStore();const i={init(e){o.useModel.HouseWorkOrdersAcceptResultEnum.value={Processing2:{text:"是",value:"1"},Processing1:{text:"否",value:"0"}},o.useModel.formData.value={...e}},handleSubmit(){var e,i;let u=null==(i=null==(e=o.useModel)?void 0:e.formData)?void 0:i.value;return(null==u?void 0:u.is_completed)?"0"!==(null==u?void 0:u.is_completed)||(null==u?void 0:u.accept_remark)?void s.getApiLoading(r.Apis.WorkOrder.HouseWorkOrders.Accept,{...u,is_completed:"1"===(null==u?void 0:u.is_completed)}).then(e=>{t.showToastBack("提交成功！",1,!0),console.log(e)}):t.showToast("请先输入原因！"):t.showToast("请选择是否已经完工！")}};exports.method=i;
