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.2KB

  1. import{E as b}from"./index-29b4120c.js";import{p as D,d as x}from"./flowConfiguration-e3261cd3.js";import{y as A,r as c,a as v,$ as u,o as G,b as n,c as g,L as N,h as t,u as r,f as l,j as S,e as i,k as M,s as $}from"./index-dd5fae99.js";import{g as d,a as B}from"./getIsShowRegionTree-21a24141.js";const T=["onClick"];const L=M({name:"flowConfiguration"}),H=Object.assign(L,{setup(O){const{proxy:p}=$(),I=A(),h=c(),w=v([{label:"序号",type:"index",width:"80"},{label:"流程名称",key:"formName",prop:"formName"},{label:"状态",key:"isStop",prop:"isStop",width:"80",render:e=>[u("span",{class:["dot mr-4",`bg-${e.isStop?"danger":"success"}`]}),u("span",{class:e.isStop?"text-danger":"text-success"},e.isStop?"禁用":"启用")]},{label:"操作",slot:"action",width:"120",fixed:"right"}]),f=c([]),m=c(),s=async()=>{const e=await D({regionCode:m.value*1});f.value=e.data.records},P=e=>{const o=e.isStop?"启用":"禁用";p.$messageBox.confirm(`是否${o}该流程?`,"提示!",{type:"warning"}).then(async()=>{await x({formId:e.formId,processDefId:e.processDefId,state:e.isStop}),p.$message.success(`${o}成功!`),s()})},E=e=>{console.log(e),m.value=e.regionLevel===3?e.regionCode:void 0,s()};return G(()=>{d(["SUPER_ADMIN","REGION_MANAGER"])||s()}),(e,o)=>{const _=n("el-col"),y=n("table-list"),C=n("el-card"),R=n("el-row");return g(),N(R,null,{default:t(()=>[r(d)(["SUPER_ADMIN","REGION_MANAGER"])?(g(),N(_,{key:0,style:{"padding-right":"16px"},span:4},{default:t(()=>[l(b,{params:r(B)({SUPER_ADMIN:!1,REGION_MANAGER:!1}),onGetTree:E},null,8,["params"])]),_:1})):S("",!0),l(_,{span:r(d)(["SUPER_ADMIN","REGION_MANAGER"])?20:24},{default:t(()=>[i("div",null,[l(C,{shadow:"never"},{header:t(()=>o[0]||(o[0]=[i("div",{class:"flex justify-between items-center"},[i("span",null,"流程列表")],-1)])),default:t(()=>[l(y,{ref_key:"tableListRef",ref:h,column:w,data:f.value,pagination:!1,onGetTableData:s},{action:t(({scope:a})=>[i("a",{onClick:k=>r(I).push({name:"configEdit",query:{formId:a.row.formId,formName:a.row.formName,regionCode:a.row.regionCode,processDefId:a.row.processDefId}})},"编辑",8,T),S("",!0)]),_:1},8,["column","data"])]),_:1})])]),_:1},8,["span"])]),_:1})}}});export{H as default};