Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.

2 řádky
2.5KB

  1. var h=(S,r,a)=>new Promise((u,l)=>{var c=o=>{try{t(a.next(o))}catch(n){l(n)}},i=o=>{try{t(a.throw(o))}catch(n){l(n)}},t=o=>o.done?u(o.value):Promise.resolve(o.value).then(c,i);t((a=a.apply(S,r)).next())});import{E as A}from"./index.642e7e4c.js";import{p as v,d as G}from"./flowConfiguration.65ccb757.js";import{d as M,A as B,r as I,b as T,a3 as E,o as $,c as p,e as C,I as R,i as s,u as f,h as m,k,g as _,x as O}from"./index.3fb2f955.js";import{g as N,a as P}from"./getIsShowRegionTree.b965db88.js";const L=_("div",{class:"flex justify-between items-center"},[_("span",null,"\u6D41\u7A0B\u5217\u8868")],-1),U=["onClick"];const V=M({name:"flowConfiguration"}),Q=Object.assign(V,{setup(S){const{proxy:r}=O(),a=B(),u=I(),l=T([{label:"\u5E8F\u53F7",type:"index",width:"80"},{label:"\u6D41\u7A0B\u540D\u79F0",key:"formName",prop:"formName"},{label:"\u72B6\u6001",key:"isStop",prop:"isStop",width:"80",render:e=>[E("span",{class:["dot mr-4",`bg-${e.isStop?"danger":"success"}`]}),E("span",{class:e.isStop?"text-danger":"text-success"},e.isStop?"\u7981\u7528":"\u542F\u7528")]},{label:"\u64CD\u4F5C",slot:"action",width:"120",fixed:"right"}]),c=I([]),i=I(),t=()=>h(this,null,function*(){const e=yield v({regionCode:i.value*1});c.value=e.data.records}),o=e=>{const g=e.isStop?"\u542F\u7528":"\u7981\u7528";r.$messageBox.confirm(`\u662F\u5426${g}\u8BE5\u6D41\u7A0B?`,"\u63D0\u793A\uFF01",{type:"warning"}).then(()=>h(this,null,function*(){yield G({formId:e.formId,processDefId:e.processDefId,state:e.isStop}),r.$message.success(`${g}\u6210\u529F\uFF01`),t()}))},n=e=>{i.value=e.regionLevel===3?e.regionCode:void 0,t()};return $(()=>{N(["SUPER_ADMIN","REGION_MANAGER"])||t()}),(e,g)=>{const w=p("el-col"),y=p("table-list"),b=p("el-card"),D=p("el-row");return C(),R(D,null,{default:s(()=>[f(N)(["SUPER_ADMIN","REGION_MANAGER"])?(C(),R(w,{key:0,style:{"padding-right":"16px"},span:4},{default:s(()=>[m(A,{params:f(P)({SUPER_ADMIN:!1,REGION_MANAGER:!1}),onGetTree:n},null,8,["params"])]),_:1})):k("",!0),m(w,{span:f(N)(["SUPER_ADMIN","REGION_MANAGER"])?20:24},{default:s(()=>[_("div",null,[m(b,{shadow:"never"},{header:s(()=>[L]),default:s(()=>[m(y,{ref_key:"tableListRef",ref:u,column:l,data:c.value,pagination:!1,onGetTableData:t},{action:s(({scope:d})=>[_("a",{onClick:x=>f(a).push({name:"configEdit",query:{formId:d.row.formId,formName:d.row.formName,regionCode:d.row.regionCode,processDefId:d.row.processDefId}})},"\u7F16\u8F91",8,U),k("",!0)]),_:1},8,["column","data"])]),_:1})])]),_:1},8,["span"])]),_:1})}}});export{Q as default};