import{d as l,cC as u,c2 as m,i as d,z as i,o as f,c as p,h as w,cD as k,$ as _}from"./index-D3rICic-.js";import{_ as v}from"./workflow.vue_vue_type_script_setup_true_lang-CDR_Hxib.js";import"./DescriptionsItem-LhWljJnV.js";import"./Grid-CRDcRyPk.js";import"./index-2ay5PpNs.js";const C=l({name:"workflow_form_add",__name:"index",setup(S){const a=u(),t=m();d(()=>{a.clear(),a.setType(0)});const e=i({workflowName:`WF-${new Date().getTime()}`,workflowStatus:1,blockStrategy:1,description:void 0,executorTimeout:60}),r=async()=>{var o;const{error:s}=await k(e.value);s||((o=window.$message)==null||o.info(_("common.addSuccess")),t.push("/workflow/task"))},n=()=>{t.push("/workflow/task")};return(s,o)=>(f(),p(w(v),{modelValue:e.value,"onUpdate:modelValue":o[0]||(o[0]=c=>e.value=c),onSave:r,onCancel:n},null,8,["modelValue"]))}});export{C as default};
