Files
qhmes/deploy-qhmes/frontend/js/OpenApiAuthModal-DmvuSZls.js
2026-05-15 11:34:12 +08:00

2 lines
5.8 KiB
Java

var q=Object.defineProperty,Q=Object.defineProperties;var U=Object.getOwnPropertyDescriptors;var N=Object.getOwnPropertySymbols;var X=Object.prototype.hasOwnProperty,Z=Object.prototype.propertyIsEnumerable;var D=(e,t,a)=>t in e?q(e,t,{enumerable:!0,configurable:!0,writable:!0,value:a}):e[t]=a,b=(e,t)=>{for(var a in t||(t={}))X.call(t,a)&&D(e,a,t[a]);if(N)for(var a of N(t))Z.call(t,a)&&D(e,a,t[a]);return e},P=(e,t)=>Q(e,U(t));var H=(e,t,a)=>new Promise((f,m)=>{var o=i=>{try{n(a.next(i))}catch(p){m(p)}},c=i=>{try{n(a.throw(i))}catch(p){m(p)}},n=i=>i.done?f(i.value):Promise.resolve(i.value).then(o,c);n((a=a.apply(e,t)).next())});import{d as J,g as x,f as d,u as s,h as S,w as ee,e as _,z as le,ah as k,aC as $,as as y,aG as I,aE as j,aF as r,aH as w,aD as V,ar as te,ag as ne,k as C,aJ as A,aK as E,n as z}from"./vue-vendor-C7Zq48Yl.js";import ae from"./OpenApiAuthForm-BcFFJCbk.js";import{b as oe,d as se,a as ie,c as ce,M as ue}from"./ModalHeader-keHdAHWH.js";import{aH as re,aI as de,T as fe,ar as me,o as B}from"./antd-vue-vendor-BPnV8VqP.js";import{av as pe,aA as ve,Y as he,F as ge,d as be}from"./index-BI6CMai0.js";import"./OpenApiAuth.api-CrTtn2s4.js";import"./JFormContainer-C7agzPPy.js";import"./useTimeout-DDl4l82I.js";import"./vxe-table-vendor-B88kchpX.js";import"./index-DeEq83Ov.js";const ke=J({name:"JModal",methods:{omit:B},components:{CloseOutlined:me,Tooltip:fe,FullscreenExitOutlined:de,FullscreenOutlined:re,ModalHeader:ue,ModalClose:ce,ModalFooter:ie,Modal:se},props:b({fullscreen:{type:Boolean,default:!1}},oe),emits:["visible-change","open-change","height-change","cancel","ok","register","update:visible","update:open","fullScreen"],setup(e,{emit:t,attrs:a,slots:f}){const{getIsMobile:m}=pe(),o=d(!1),c=d(null),n=d(e.fullscreen),i=d(!1),{t:p}=he(),F=d({height:e.maxHeight?e.maxHeight:"600px","overflow-y":"auto"}),g={setModalProps:Y,emitVisible:void 0},v=_(()=>{const l=b(b({},e),s(c));return m.value&&(l.fullscreen=!1),l}),u=_(()=>{const l=P(b(b({},a),s(v)),{open:s(o),wrapClassName:s(h)});return s(n)?B(l,["height","visible"]):B(l,["visible"])}),h=_(()=>{let l=le(v.value,"wrapClassName").value||"";return l=`${l} jeecg-modal-code-generate`,s(n)?`jeecg-full-screen-modal-code-generate ${l} `:s(l)}),R=_(()=>{const l=P(b({},s(v)),{visible:s(o),okButtonProps:void 0,cancelButtonProps:void 0,title:void 0});return P(b({},l),{wrapClassName:s(h)})}),O=x();O&&t("register",g,O.uid);function G(){return!s(v).title&&!f.title}function T(l){l==null||l.stopPropagation(),l==null||l.preventDefault(),n.value=!s(n)}function K(l){return H(this,null,function*(){if(l==null||l.stopPropagation(),e.closeFunc&&ge(e.closeFunc)){const M=yield e.closeFunc();o.value=!M;return}o.value=!1,t("cancel",l)})}function L(l){t("ok",l)}function W(l){e.fullscreen&&(l.stopPropagation(),T(l))}function Y(l){c.value=ve(s(c)||{},l),Reflect.has(l,"visible")&&(o.value=!!l.visible),Reflect.has(l,"open")&&(o.value=!!l.open),Reflect.has(l,"defaultFullscreen")&&(n.value=!!l.defaultFullscreen,m.value&&(n.value=!0))}return S(()=>{n.value=e.fullscreen,m.value&&(n.value=!0)}),S(()=>{o.value=!!e.visible}),S(()=>{o.value=!!e.open}),ee(()=>s(o),l=>{var M;t("visible-change",l),t("open-change",l),t("update:visible",l),t("update:open",l),O&&((M=g.emitVisible)==null||M.call(g,l,O.uid))},{immediate:!1}),{isNoTitle:G,getBindValue:u,fullScreenRef:n,handleFullScreen:T,fullScreen:i,t:p,handleCancel:K,handleOk:L,getProps:R,getMergeProps:v,handleTitleDbClick:W,bodyStyle:F}}}),Ce={key:0,class:"jeecg-basic-modal-close"};function Fe(e,t,a,f,m,o){const c=k("FullscreenExitOutlined"),n=k("Tooltip"),i=k("FullscreenOutlined"),p=k("CloseOutlined"),F=k("ModalHeader"),g=k("ModalFooter"),v=k("a-modal");return y(),$(v,I(e.getBindValue,{onCancel:e.handleCancel,"body-style":e.fullScreenRef?{}:e.bodyStyle}),j({default:r(()=>[w(e.$slots,"default",{},void 0,!0)]),_:2},[e.$slots.closeIcon?void 0:{name:"closeIcon",fn:r(()=>[e.canFullscreen?(y(),te("div",Ce,[e.fullScreenRef?(y(),$(n,{key:0,title:e.t("component.modal.restore"),placement:"bottom"},{default:r(()=>[C(c,{role:"full",onClick:e.handleFullScreen},null,8,["onClick"])]),_:1},8,["title"])):(y(),$(n,{key:1,title:e.t("component.modal.maximize"),placement:"bottom"},{default:r(()=>[C(i,{role:"close",onClick:e.handleFullScreen},null,8,["onClick"])]),_:1},8,["title"])),C(n,{title:e.t("component.modal.close"),placement:"bottom"},{default:r(()=>[C(p,{onClick:e.handleCancel},null,8,["onClick"])]),_:1},8,["title"])])):ne("",!0)]),key:"0"},e.isNoTitle?void 0:{name:"title",fn:r(()=>[C(F,{helpMessage:e.getProps.helpMessage,title:e.getMergeProps.title,onDblclick:e.handleTitleDbClick},null,8,["helpMessage","title","onDblclick"])]),key:"1"},e.$slots.footer?void 0:{name:"footer",fn:r(()=>[C(g,I(e.getBindValue,{onOk:e.handleOk,onCancel:e.handleCancel}),j({_:2},[V(Object.keys(e.$slots),u=>({name:u,fn:r(h=>[w(e.$slots,u,A(E(h||{})),void 0,!0)])}))]),1040,["onOk","onCancel"])]),key:"2"},V(Object.keys(e.omit(e.$slots,"default")),u=>({name:u,fn:r(h=>[w(e.$slots,u,A(E(h||{})),void 0,!0)])}))]),1040,["onCancel","body-style"])}const ye=be(ke,[["render",Fe],["__scopeId","data-v-05c8f4d0"]]),De=J({__name:"OpenApiAuthModal",emits:["register","success"],setup(e,{expose:t,emit:a}){const f=d(""),m=d(800),o=d(!1),c=d(!1),n=d(),i=a;function p(){f.value="新增",o.value=!0,z(()=>{n.value.add()})}function F(h){f.value=c.value?"详情":"编辑",o.value=!0,z(()=>{n.value.edit(h)})}function g(){n.value.submitForm()}function v(){u(),i("success")}function u(){o.value=!1}return t({add:p,edit:F,disableSubmit:c}),(h,R)=>(y(),$(ye,{title:f.value,width:m.value,maxHeight:200,visible:o.value,onOk:g,okButtonProps:{class:{"jee-hidden":c.value}},onCancel:u,cancelText:"关闭"},{default:r(()=>[C(ae,{ref_key:"registerForm",ref:n,onOk:v,title:f.value,formDisabled:c.value,formBpm:!1},null,8,["title","formDisabled"])]),_:1},8,["title","width","visible","okButtonProps"]))}});export{De as default};