ThirdAppConfigModal-npupWvq6.js 3.4 KB

1
  1. var c=(t,m,o)=>new Promise((d,p)=>{var a=e=>{try{r(o.next(e))}catch(s){p(s)}},n=e=>{try{r(o.throw(e))}catch(s){p(s)}},r=e=>e.done?d(e.value):Promise.resolve(e.value).then(a,n);r((o=o.apply(t,m)).next())});import{d as h,f as g,ag as u,aB as I,ar as w,aD as C,k as B}from"./vue-vendor-Be68asQ6.js";import{B as b}from"./index-CETWS1o0.js";import"./index-D68l__AG.js";import{b as k,c as T}from"./ThirdApp.api-D8x0FjIV.js";import{B as y}from"./BasicForm-Cv-dsB-e.js";import{u as M}from"./useForm-kcRIHoe0.js";import{ac as F,a as _}from"./index-BFfnEkVs.js";import"./BasicModal-D4gc2R81.js";import"./antd-vue-vendor-DcqS7Wvq.js";import"./useTimeout-Ca5eqGu-.js";import"./vxe-table-vendor-DHF2TRpV.js";import"./useWindowSizeFn-BTSGGcie.js";import"./index-BZ_MXCtW.js";import"./index-BIPzXG41.js";import"./index-CXEQnmRq.js";import"./useIntersectionObserver-Bl62RIZ4.js";import"./componentMap-BUTAcOmo.js";import"./useFormItem-CtGMPcLp.js";import"./download-CjoX0_mR.js";import"./base64Conver-24EVOS6V.js";import"./index-D1703ozz.js";import"./index-Bi7PIj53.js";import"./useCountdown-B7iR27pS.js";import"./useFormItemSingle-nLM0QlcI.js";import"./JSelectUser-DCwPqRxp.js";import"./props-BPxWJPuD.js";import"./JSelectBiz-Be8KsC5j.js";import"./JAddInput-BBXQvvpq.js";import"./areaDataUtil-Cik-Rc_P.js";import"./index-BOEzG86y.js";import"./index-BNFwynfr.js";import"./bem-BvvqSl-N.js";import"./props-Cw7AfxGV.js";import"./useContextMenu-BDwmjIwb.js";import"./depart.api-CDwTvdwQ.js";import"./JSelectDept-DT6g7V5M.js";import"./JPopup-DKJW27Yk.js";import"./JEllipsis-C04xKxcI.js";import"./JUpload-cB_Qj2H2.js";import"./index-iuayQczx.js";import"./index-DJQB4_Pr.js";import"./JAreaLinkage-BNOKwn5l.js";import"./JCodeEditor-CSivhUhT.js";import"./htmlmixed-DNSd26j0.js";import"./vue-DbzutmLn.js";/* empty css */import"./EasyCronInput-wCv2YMHn.js";const v=[{label:"id",field:"id",component:"Input",show:!1},{label:"thirdType",field:"thirdType",component:"Input",show:!1},{label:"CorpId",field:"corpId",component:"Input",ifShow:({values:t})=>t.thirdType==="dingtalk",required:!0},{label:"Agentld",field:"agentId",component:"Input",required:!0},{label:"AppKey",field:"clientId",component:"Input",required:!0},{label:"AppSecret",field:"clientSecret",component:"Input",required:!0},{label:"启用",field:"status",component:"Switch",componentProps:{checkedChildren:"关闭",checkedValue:1,unCheckedChildren:"开启",unCheckedValue:0},defaultValue:1},{label:"租户id",field:"tenantId",component:"Input",show:!1}],A=h({name:"ThirdAppConfigModal",components:{BasicModal:b,BasicForm:y},setup(t,{emit:m}){const o=g("钉钉配置"),[d,{resetFields:p,setFieldsValue:a,validate:n}]=M({schemas:v,showActionButtonGroup:!1,labelCol:{span:24},wrapperCol:{span:24}}),[r,{setModalProps:e,closeModal:s}]=F(i=>c(null,null,function*(){e({confirmLoading:!0}),i.thirdType=="dingtalk"?o.value="钉钉配置":o.value="企业微信配置",yield p();let l=yield k({tenantId:i.tenantId,thirdType:i.thirdType});e({confirmLoading:!1}),l?yield a(l):yield a(i)}));function f(){return c(this,null,function*(){let i=yield n(),l=!1;i.id&&(l=!0),yield T(i,l),m("success"),s()})}return{title:o,registerForm:d,registerModal:r,handleSubmit:f}}});function S(t,m,o,d,p,a){const n=u("BasicForm"),r=u("BasicModal");return w(),I(r,{onRegister:t.registerModal,width:800,title:t.title,onOk:t.handleSubmit},{default:C(()=>[B(n,{onRegister:t.registerForm},null,8,["onRegister"])]),_:1},8,["onRegister","title","onOk"])}const Me=_(A,[["render",S]]);export{Me as default};