static.assets.Queue.e4258f28.js Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of redismq-server Show documentation
Show all versions of redismq-server Show documentation
redismq server and console
The newest version!
/* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css */import{m as T,i as pe,n as r,p as b,q as ce,s as me,t as ge,v as be,x as fe,y as Fe,o as m,b as C,e as l,w as t,F as k,z as $,f as p,A as De,B as ye,d as U,C as _e,D as ve,G as xe,H as L,I as Ce,J as ke,K as Ee,L as qe,M as we,N as Be,O as P}from"./index.4cd85549.js";/* empty css */const D={success(){T({message:"\u64CD\u4F5C\u6210\u529F",type:"success"})},error(){T({message:"\u64CD\u4F5C\u5931\u8D25",type:"fail"})},error(h){T({message:h,type:"fail",center:!0,showClose:!0})}},Ve={class:"block"},Me={class:"queue-table"},Ue=pe({__name:"Queue",setup(h){const{proxy:i}=xe();let f=r(!1);r("add");const E=r([]),z=r([]),Q=r([{id:""},{key:""},{tag:""},{consumeTime:""}]),S=b([{prop:"id",label:"\u6D88\u606Fid"},{prop:"key",label:"\u6D88\u606F\u952E"},{prop:"tag",label:"\u6807\u7B7E"},{prop:"consumeTime",label:"\u6D88\u8D39\u65F6\u95F4"}]),R=b([{prop:"queueName",label:"\u865A\u62DF\u961F\u5217\u540D\u79F0"},{prop:"size",label:"\u5B9E\u65F6\u6D88\u606F\u6570\u91CF"}]),I=b([{prop:"queueName",label:"\u961F\u5217\u540D\u79F0"},{prop:"retryMax",label:"\u6D88\u8D39\u5931\u8D25\u91CD\u8BD5\u6B21\u6570"},{prop:"retryInterval",label:"\u91CD\u8BD5\u65F6\u95F4\u95F4\u9694"},{prop:"ackMode",label:"ack\u6A21\u5F0F"},{prop:"concurrency",label:"\u5E76\u53D1\u6D88\u8D39\u8005"},{prop:"maxConcurrency",label:"\u6700\u5927\u5E76\u53D1\u6D88\u8D39\u8005"},{prop:"virtual",label:"\u865A\u62DF\u961F\u5217\u6570\u91CF"},{prop:"queueMaxSize",label:"\u961F\u5217\u5BB9\u91CF"}]),s=b({queue:"",tag:"",body:"",consumeTime:0}),q=r(),y=r(!1),w=r(!1),B=r(!1);r([]),r([]);const H=async()=>{const a={...s};a.consumeTime=new Date(a.consumeTime).getTime();let e;o.delayState?e=await ue(a):e=await ee(a),console.log("sdasd "+e),e===!1?D.error("\u6D88\u606F\u4F53\u683C\u5F0F\u9519\u8BEF,\u8BF7\u8F93\u5165\u666E\u901A\u5B57\u7B26\u4E32\u6216\u6B63\u786E\u7684json"):(D.success(),i.$refs.sendMessageFormRef.resetFields(),y.value=!1)},G=(a,e)=>{a.props.name=="queue"?o.delayState=!1:o.delayState=!0,_(o)},j=()=>{i.$refs.sendMessageFormRef.resetFields()},J=a=>{o.page=a,_(o)},K=a=>{c.page=a,V(c)},O=(a,e)=>{q.value=e.body,B.value=!0},W=(a,e)=>{f.value=!0,console.log(e),X({queueName:e.queueName,virtual:e.virtual})},X=async a=>{let e=await i.$api.mq.vQueueList(a);z.value=e,console.log(e)},Y=(a,e)=>{y.value=!0,s.queue=e.queueName},Z=(a,e)=>{w.value=!0,c.virtualQueueName=e.queueName,V(c)},ee=async a=>await i.$api.mq.sendMessage(a),ue=async a=>await i.$api.mq.sendTimingMessage(a),V=async a=>{let e=await i.$api.mq.pageMessage(a);Q.value=e.list,a.total=e.total},ae=async a=>{await i.$api.mq.deleteMessage(a),V(c)},le=async a=>{const e={vQueue:a};await i.$api.mq.publishPullMessage(e),D.success()},te=async a=>{const e={queue:a};await i.$api.mq.deleteQueue(e),_(o)},oe=async(a,e)=>{le(e.queueName)},se=async(a,e)=>{L.confirm("\u4F60\u786E\u5B9A\u5220\u9664\u6D88\u606F\u961F\u5217\u5417?",{confirmButtonText:"\u786E\u5B9A",cancelButtonText:"\u53D6\u6D88"}).then(()=>{te(e.queueName),D.success()}).catch(()=>{})},c=b({page:1,size:10,total:0,virtualQueueName:""}),o=b({page:1,size:10,delayState:!1,total:0}),ne=(a,e)=>{L.confirm("\u4F60\u786E\u5B9A\u5220\u9664\u6D88\u606F\u5417?",{confirmButtonText:"\u786E\u5B9A",cancelButtonText:"\u53D6\u6D88"}).then(()=>{ae(e),D.success()}).catch(()=>{})};ce(()=>{_(o)});const _=async a=>{let e=await i.$api.mq.queueList(a);console.log(a),e.list.forEach(n=>{n.ackMode=n.ackMode=="maual"?"\u624B\u52A8":"\u81EA\u52A8",n.retryInterval=n.retryInterval+"ms"}),console.log(e.total),o.total=e.total,E.value=e.list,console.log("abc"+E.value)};return(a,e)=>{const n=Ce,d=ke,M=Ee,v=qe,F=we,re=me,ie=Be,x=ge,A=be,N=fe,de=Fe;return m(),C(k,null,[l(x,{class:"queue-dialog",modelValue:_e(f),"onUpdate:modelValue":e[9]||(e[9]=u=>ve(f)?f.value=u:f=u),style:{width:"70%",height:"50%"}},{footer:t(()=>[]),default:t(()=>[l(M,{data:z.value},{default:t(()=>[(m(!0),C(k,null,$(R,u=>(m(),P(n,{key:u.prop,label:u.label,prop:u.prop},null,8,["label","prop"]))),128)),l(n,{fixed:"right",width:"300px",label:"\u64CD\u4F5C"},{default:t(u=>[l(d,{size:"small",onClick:g=>Z(u.$index,u.row)},{default:t(()=>[p("\u961F\u5217\u6D88\u606F")]),_:2},1032,["onClick"]),l(d,{size:"small",onClick:g=>Y(u.$index,u.row)},{default:t(()=>[p("\u53D1\u9001\u6D88\u606F")]),_:2},1032,["onClick"]),l(d,{type:"danger",size:"small",onClick:g=>oe(u.$index,u.row)},{default:t(()=>[p("\u62C9\u53D6\u6D88\u606F")]),_:2},1032,["onClick"])]),_:1})]),_:1},8,["data"]),l(x,{modelValue:y.value,"onUpdate:modelValue":e[4]||(e[4]=u=>y.value=u),width:"70%",title:"\u53D1\u9001\u6D88\u606F","append-to-body":"",onClose:e[5]||(e[5]=u=>j())},{default:t(()=>[l(ie,{ref:"sendMessageFormRef",model:s,"label-width":"120px"},{default:t(()=>[l(F,{label:"\u865A\u62DF\u961F\u5217",prop:"queue",required:""},{default:t(()=>[l(v,{modelValue:s.queue,"onUpdate:modelValue":e[0]||(e[0]=u=>s.queue=u)},null,8,["modelValue"])]),_:1}),l(F,{label:"\u6807\u7B7E",prop:"tag"},{default:t(()=>[l(v,{modelValue:s.tag,"onUpdate:modelValue":e[1]||(e[1]=u=>s.tag=u)},null,8,["modelValue"])]),_:1}),l(F,{label:"\u6D88\u606F\u4F53",prop:"body",required:""},{default:t(()=>[l(v,{modelValue:s.body,"onUpdate:modelValue":e[2]||(e[2]=u=>s.body=u),type:"textarea",autosize:{minRows:4}},null,8,["modelValue"])]),_:1}),De(l(F,{label:"\u6D88\u8D39\u65F6\u95F4",prop:"consumeTime"},{default:t(()=>[U("div",Ve,[l(re,{modelValue:s.consumeTime,"onUpdate:modelValue":e[3]||(e[3]=u=>s.consumeTime=u),type:"datetime",placeholder:"\u8BF7\u9009\u62E9\u6D88\u8D39\u65F6\u95F4"},null,8,["modelValue"])])]),_:1},512),[[ye,o.delayState]]),l(F,null,{default:t(()=>[l(d,{type:"primary",onClick:H},{default:t(()=>[p("\u53D1\u9001")]),_:1})]),_:1})]),_:1},8,["model"])]),_:1},8,["modelValue"]),l(x,{modelValue:w.value,"onUpdate:modelValue":e[8]||(e[8]=u=>w.value=u),width:"70%",title:"\u6D88\u606F\u5217\u8868","append-to-body":""},{default:t(()=>[l(M,{data:Q.value},{default:t(()=>[(m(!0),C(k,null,$(S,u=>(m(),P(n,{key:u.prop,label:u.label,prop:u.prop},null,8,["label","prop"]))),128)),l(n,{fixed:"right",width:"200px",label:"\u64CD\u4F5C"},{default:t(u=>[l(d,{size:"small",color:"#009688",onClick:g=>O(u.$index,u.row)},{default:t(()=>[p("\u67E5\u770B")]),_:2},1032,["onClick"]),l(d,{type:"danger",size:"small",onClick:g=>ne(u.$index,u.row)},{default:t(()=>[p("\u5220\u9664")]),_:2},1032,["onClick"])]),_:1})]),_:1},8,["data"]),l(A,{background:"",layout:"prev, pager, next",total:c.total,"current-page":c.page,"onUpdate:currentPage":K},null,8,["total","current-page"]),l(x,{modelValue:B.value,"onUpdate:modelValue":e[7]||(e[7]=u=>B.value=u),width:"80%",title:"\u6D88\u606F\u8BE6\u60C5","append-to-body":""},{default:t(()=>[l(v,{modelValue:q.value,"onUpdate:modelValue":e[6]||(e[6]=u=>q.value=u),autosize:{minRows:4,maxRows:20},type:"textarea",placeholder:"Please input",disabled:""},null,8,["modelValue"])]),_:1},8,["modelValue"])]),_:1},8,["modelValue"])]),_:1},8,["modelValue"]),l(de,{type:"card",class:"demo-tabs",onTabClick:G},{default:t(()=>[l(N,{label:"\u666E\u901A\u961F\u5217",name:"queue"}),l(N,{label:"\u5EF6\u65F6\u961F\u5217",name:"delayQueue"})]),_:1}),U("div",Me,[l(M,{data:E.value,style:{width:"100%"},height:"700px",border:"","header-cell-style":{background:"#fff !important",color:"#000 !important","text-align":"center","font-size":"15px","font-weight":"700"},"row-cell-style":{"text-align":"center"},"cell-style":{"text-align":"center"}},{default:t(()=>[(m(!0),C(k,null,$(I,u=>(m(),P(n,{key:u.prop,label:u.label,prop:u.prop},null,8,["label","prop"]))),128)),l(n,{fixed:"right",width:"200px",label:"\u64CD\u4F5C"},{default:t(u=>[l(d,{size:"default",onClick:g=>W(u.$index,u.row)},{default:t(()=>[p("\u8BE6\u60C5")]),_:2},1032,["onClick"]),l(d,{type:"danger",size:"default",onClick:g=>se(u.$index,u.row)},{default:t(()=>[p("\u5220\u9664")]),_:2},1032,["onClick"])]),_:1})]),_:1},8,["data"]),l(A,{background:"",layout:"prev, pager, next",total:o.total,"current-page":o.page,"onUpdate:currentPage":J},null,8,["total","current-page"])])],64)}}});export{Ue as default};
© 2015 - 2025 Weber Informatics LLC | Privacy Policy