var w=Object.defineProperty,v=Object.defineProperties;var P=Object.getOwnPropertyDescriptors;var n=Object.getOwnPropertySymbols;var c=Object.prototype.hasOwnProperty,u=Object.prototype.propertyIsEnumerable;var p=(e,a,t)=>a in e?w(e,a,{enumerable:!0,configurable:!0,writable:!0,value:t}):e[a]=t,d=(e,a)=>{for(var t in a||(a={}))c.call(a,t)&&p(e,t,a[t]);if(n)for(var t of n(a))u.call(a,t)&&p(e,t,a[t]);return e},m=(e,a)=>v(e,P(a));var f=(e,a)=>{var t={};for(var s in e)c.call(e,s)&&a.indexOf(s)<0&&(t[s]=e[s]);if(e!=null&&n)for(var s of n(e))a.indexOf(s)<0&&u.call(e,s)&&(t[s]=e[s]);return t};import{am as r}from"./index.js";const o="/v1/data/detect-task",H=e=>r.post({url:`${o}/`,data:e}),V=(e,a=!1)=>r.put({url:`${o}/`,data:e,params:{updateAllFields:a}}),$=e=>r.delete({url:`${o}/${e}`}),k=e=>r.get({url:`${o}/search`,params:e}),A=e=>r.get({url:`${o}/${e}`}),B=e=>r.post({url:`${o}/batch-delete`,data:e}),l={xs:{span:24},sm:{span:24},lg:{span:8}},F={span:24},i={model:"DetectTask",viewInPage:!1,properties:[{field:"id",label:"ID系统自动生成",defaultValue:void 0,form:{componentProps:{allowClear:!1,placeholder:"ID系统自动生成"},colProps:l,component:"InputNumber",rules:[{required:!0,message:"请输入ID系统自动生成！"}]},table:{}},{field:"name",label:"名称",defaultValue:void 0,form:{componentProps:{allowClear:!1,placeholder:"名称"},colProps:l,component:"Input",rules:[{required:!0,message:"请输入名称！"}]},table:{}},{field:"startTime",label:"开始时间",defaultValue:void 0,form:{colProps:l,component:"DatePicker",componentProps:{allowClear:!1,placeholder:"开始时间",format:"YYYY-MM-DD HH:mm:ss",valueFormat:"YYYY-MM-DD HH:mm:ss",showTime:!0},rules:[{required:!0,message:"请输入开始时间！"}]},table:{}},{field:"endTime",label:"结束时间",defaultValue:void 0,form:{colProps:l,component:"DatePicker",componentProps:{allowClear:!1,placeholder:"结束时间",format:"YYYY-MM-DD HH:mm:ss",valueFormat:"YYYY-MM-DD HH:mm:ss",showTime:!0},rules:[{required:!0,message:"请输入结束时间！"}]},table:{}},{field:"state",label:"状态(0.未开始",defaultValue:void 0,form:{componentProps:{allowClear:!1,placeholder:"状态(0.未开始"},colProps:l,component:"InputNumber",rules:[{required:!0,message:"请输入状态(0.未开始！"}]},table:{}},{field:"createTime",label:"CreateTime",defaultValue:void 0,form:{colProps:l,componentProps:{allowClear:!1,placeholder:["开始时间","结束时间"],format:"YYYY-MM-DD",valueFormat:"YYYY-MM-DD",showTime:!1},component:"RangePicker",rules:[{required:!0,message:"请输入CreateTime！"}]},table:{}},{field:"updateTime",label:"UpdateTime",defaultValue:void 0,form:{colProps:l,componentProps:{allowClear:!1,placeholder:["开始时间","结束时间"],format:"YYYY-MM-DD",valueFormat:"YYYY-MM-DD",showTime:!1},component:"RangePicker",rules:[{required:!0,message:"请输入UpdateTime！"}]},table:{}}]},D=["id","name","startTime","endTime","state","createTime","updateTime"],b=["name","startTime","endTime","state"],x=["name","startTime","endTime","state","createTime","updateTime"],h=["name","startTime","endTime","state","createTime","updateTime"],Y=new Map(D.map((e,a)=>[e,a])),y=i.properties.filter(e=>D.includes(e.field)).map(s=>{var{field:e,label:a,form:I}=s,t=f(I,[]);return m(d({field:e,label:a,defaultValue:void 0},t),{required:!1,rules:[{required:!1}]})}).sort((e,a)=>{const t=Y.get(e.field),s=Y.get(a.field);return t-s}),T=new Map(b.map((e,a)=>[e,a])),R=i.properties.filter(e=>b.includes(e.field)).map(({field:e,label:a,defaultValue:t,form:s})=>m(d({field:e,label:a,defaultValue:t},s),{colProps:F})).sort((e,a)=>{const t=T.get(e.field),s=T.get(a.field);return t-s}),M=new Map(x.map((e,a)=>[e,a])),N=i.properties.filter(e=>x.includes(e.field)).map(({field:e,label:a,table:t})=>d({dataIndex:e,title:a},t)).sort((e,a)=>{const t=M.get(e.dataIndex),s=M.get(a.dataIndex);return t-s}),g=new Map(h.map((e,a)=>[e,a])),S=i.properties.filter(e=>h.includes(e.field)).map(({field:e,label:a,table:t})=>d({dataIndex:e,title:a},t)).sort((e,a)=>{const t=g.get(e.dataIndex),s=g.get(a.dataIndex);return t-s});export{y as a,B as b,N as c,S as d,H as e,R as f,A as g,$ as r,k as s,V as u};
