Files
qhmes/web-dist/js/AppPortal-Dsgkafhy.js
2026-06-16 18:19:57 +08:00

2 lines
6.2 KiB
Java
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
import N from"./LeftPortalSession-qGxexREf.js";import Q from"./chat-Crh_UHOs.js";import{u as U,d as z,au as E}from"./index-X7Y8jykP.js";import{e as b,h as S,C as T,z as g,Q as s,f as j,J as w,r as i,y as G,H as x,c as h,G as J,T as V}from"./vue-vendor-DNhG1Cve.js";import"./ailogo-D9r5yA-q.js";import"./logo-BQy4JOf8.js";import"./chatMessage-DisgslK5.js";import"./chatText-BThjKjwf.js";import"./emoji-mart-vue-fast-R0uJEDq-.js";import"./style-D_IZwlkj.js";import"./ImageViewer-DC0qDdlD.js";import"./useAppInject-DPZGPcR3.js";import"./JeecgToolExec-BHDyoRDJ.js";import"./ChartRender-BJHDCEwg.js";import"./BasicTable-C6eG0bgK.js";import"./BasicTable.vue_vue_type_style_index_0_lang-B9DxrWas.js";import"./BasicForm-ClUSoD_-.js";import"./helper-DcLcf4v6.js";import"./index-BzChaRPg.js";import"./BasicForm.vue_vue_type_style_index_0_lang-B29PWQy0.js";import"./index-DO7ZhK45.js";import"./index-ByCwbQDV.js";import"./index-Upeu4GGa.js";import"./index-C4wWpZeQ.js";import"./useTimeout-D5AmIBZw.js";import"./index-M9QP6cvf.js";import"./Skeleton-CimgOdM7.js";import"./useScrollTo-0FPEw5-K.js";import"./useIntersectionObserver-BGOgyKyu.js";import"./index-saD4h7VJ.js";import"./useBreakpoint-DXhPW7nV.js";import"./useEventListener-BRXjwk7A.js";import"./breakpointEnum-BhAg6bcX.js";import"./uniqBy--vsL0WVB.js";import"./index-BDvqZ5j4.js";import"./BasicModal-xH56XuRZ.js";import"./ModalHeader-Sr8KwhJJ.js";import"./useWindowSizeFn-C-0M9_Ul.js";import"./index-CuWaQdlK.js";import"./useForm-D61zovon.js";import"./injectionKey-DPVn4AgL.js";import"./index-DSsDi_fL.js";import"./Group-UHkub2tu.js";import"./Checkbox-Dbxs4we4.js";import"./index-BuONesFs.js";import"./FormOutlined-Y84itqS0.js";import"./useTableContext-CncNVXgp.js";import"./index-DTjkSGYl.js";import"./eagerComputed-BTlOruLW.js";import"./fromPairs-Dx9PT-t0.js";import"./useMaxLevel-DE205ncc.js";import"./index-CfNJyBRj.js";import"./dropdown-jkliuVyN.js";import"./index-DfHu-LAS.js";import"./Group-DBzJABA_.js";import"./RadioButton-DRBix2Fq.js";import"./index-C7ckZv9Z.js";import"./DirectoryTree-nk_YTTIy.js";import"./FolderOpenOutlined-SzIPA7z0.js";import"./index-Cl-8Hzo4.js";import"./scrollTo-D49dA-9c.js";import"./operationUnit-vCu2co3e.js";import"./index-C69VKHba.js";import"./index-DklMb9Qc.js";import"./UpOutlined-B1UMbtrP.js";import"./index-DsixALRt.js";import"./dayjs-jnKD3YGS.js";import"./index-aCD42OrZ.js";import"./quarterOfYear-BU2sPnff.js";import"./index-J2mOtM3w.js";import"./dayjs-ALi1pEeb.js";import"./clickOutside-DHfwTU6R.js";import"./onMountedOrActivated-DhSdLlqP.js";import"./throttle-De_jAmBh.js";import"./uuid-CODpppBC.js";import"./sortable.esm-DJNoJSdJ.js";import"./RedoOutlined-Cq2g4Slp.js";import"./index-CeNCCWzL.js";import"./TableAction.vue_vue_type_style_index_0_lang-BIWZ0bGo.js";import"./index-fAAIzD3j.js";import"./TableImg.vue_vue_type_style_index_0_lang-65ZOQtFn.js";import"./index-DfX9t4DO.js";import"./isNumeric-DjvBa-1E.js";import"./useTable-DbHE4FHE.js";import"./LineMulti-0TfPtS_j.js";import"./useECharts-BKJWOWs-.js";import"./echarts-O0zoDaFZ.js";import"./BarMulti--ZxpkIeN.js";import"./Pie-BfX96_-a.js";import"./BarAndLine-Cy2lhk5K.js";import"./Gauge-CBy9T31s.js";import"./install-65EkHmmZ.js";import"./SingleLine-B5ta_7LT.js";import"./knowledge-DLJt8V8a.js";import"./ThinkText-Dnh5CAci.js";import"./CardTemplate-C-Ne-n7_.js";import"./index-DcKuz4s3.js";import"./index-BwqG9R3y.js";import"./presetQuestion-CMGxrUpr.js";const W={class:"content"},Z={key:1,class:"emptyArea"},$={class:"welcome-text"},q=b({__name:"AppPortal",setup(F){const A=i(null),n=i(),u=i(!0),R=()=>{u.value=!u.value},a=i(""),m=i(),l=i(),f=i(),c=i({}),D=h(()=>c.value[a.value]||{}),y=i(),C=i(),_=U(),k=h(()=>{var e,r;return((e=_.getUserInfo)==null?void 0:e.realname)||((r=_.getUserInfo)==null?void 0:r.username)||""}),I=h(()=>k.value?`你好,${k.value}。准备好开始了吗?`:"你好准备好开始了吗"),v=i(!1),M=(e=10,r=16)=>{var p="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz".split(""),t=[],o;if(r=r||p.length,e)for(o=0;o<e;o++)t[o]=p[0|Math.random()*r];else{var d;for(t[8]=t[13]=t[18]=t[23]="-",t[14]="4",o=0;o<36;o++)t[o]||(d=0|Math.random()*16,t[o]=p[o==19?d&3|8:d])}return t.join("")};function B(e){v.value=!1,C.value.addSession(e,a.value)}function L(){y.value&&y.value.open()}function P(e){a.value=M(32),l.value=e,f.value=l.value.name,v.value=!0}function H(e,r){v.value=!1,a.value=e,f.value=r;let p={conversationId:e,sessionType:"portal"};z.get({url:"/airag/chat/messages",params:p},{isTransformResponse:!1}).then(t=>{var o;t.success?t.result&&t.result.messages?(m.value=t.result.messages,(o=t.result)!=null&&o.appData?l.value=t.result.appData:l.value=null,t.result.flowInputs&&(c.value[e]=t.result.flowInputs)):Array.isArray(t.result)?m.value=t.result:m.value=[]:m.value=[]})}return S(()=>a.value,e=>{e&&(m.value=[],c.value[e]=c.value[e]||{})}),S(()=>n.value,()=>{n.value.offsetHeight&&(n.value={height:`${n.value.offsetHeight} px`})}),(e,r)=>{var p,t;return g(),T("div",{ref_key:"portalRef",ref:n,class:"portal-container",style:V(A.value)},[s("div",{class:w(["leftArea",[u.value?"expand":"shrink"]])},[s("div",W,[j(N,{ref_key:"leftPortalRef",ref:C,onAppClick:P,onTaskClick:H},null,512)]),s("div",{class:"toggle-btn",onClick:R},[...r[0]||(r[0]=[s("span",{class:"icon"},[s("svg",{viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[s("path",{d:"M5.64645 3.14645C5.45118 3.34171 5.45118 3.65829 5.64645 3.85355L9.79289 8L5.64645 12.1464C5.45118 12.3417 5.45118 12.6583 5.64645 12.8536C5.84171 13.0488 6.15829 13.0488 6.35355 12.8536L10.8536 8.35355C11.0488 8.15829 11.0488 7.84171 10.8536 7.64645L6.35355 3.14645C6.15829 2.95118 5.84171 2.95118 5.64645 3.14645Z",fill:"currentColor"})])],-1)])])],2),s("div",{class:w(["rightArea",[u.value?"expand":"shrink"]])},[a.value?(g(),G(Q,{key:a.value,url:"/airag/chat/send",uuid:a.value,historyData:m.value,type:"view",formState:l.value,prologue:(p=l.value)==null?void 0:p.prologue,presetQuestion:(t=l.value)==null?void 0:t.presetQuestion,onReloadMessageTitle:B,chatTitle:f.value,conversationSettings:D.value,onEditSettings:L,sessionType:"portal",ref:"chatRef"},null,8,["uuid","historyData","formState","prologue","presetQuestion","chatTitle","conversationSettings"])):x("",!0),v.value?(g(),T("div",Z,[s("div",$,J(I.value),1)])):x("",!0)],2)],4)}}}),je=E(q,[["__scopeId","data-v-f4e3d4f1"]]);export{je as default};