"use strict";const e=require("../../../common/vendor.js"),a=require("../../../common/libraries/apiLoading.js"),l=require("../../../gen/Apis.js"),d=require("./model.js"),i=()=>{var e,i;a.getApiLoading(l.Apis.Emergency.EmergencyEvents.List,null==(i=null==(e=d.useModel)?void 0:e.formData)?void 0:i.value).then(e=>{d.useModel.listData.value=[...d.useModel.listData.value,...null==e?void 0:e.data],d.useModel.metaData.value=null==e?void 0:e.meta})},o=()=>{d.useModel.formData.value.page=1,d.useModel.listData.value=[],i()},n={getList:i,handleChangeTabs(e,a){o()},handleLoad(e){d.useModel.formData.value.page=null==e?void 0:e.page,i()},handleAdd(){e.index.navigateTo({url:"/ME/emergency/add/index"})},onSearch(){o()},handleDetail(a){e.index.navigateTo({url:`/ME/emergency/show/index?id=${null==a?void 0:a.id}`})}};exports.method=n;
