File: /var/www/html/wordpress/wp-content/plugins/bit-integrations/assets/bi.932.154.js
import{u as h,e as d,r as o,f as j,j as e}from"./main-685.js";import{$ as b,e as y,f as _,_ as a,k as w}from"./bi.878.0.js";import{S as C}from"./bi.674.13.js";import"./bi.451.455.js";import{S as v,I as F,s as N}from"./bi.776.3.js";import{h as k,c}from"./bi.577.975.js";import{S as E}from"./bi.511.976.js";import"./bi.327.9.js";import"./bi.601.11.js";import"./bi.825.14.js";function B({allIntegURL:l}){const f=h(),[n,L]=d(b),[t,i]=d(y),[g,r]=o.useState(!1),[p,x]=o.useState({}),[u,s]=o.useState({show:!1}),m=j(_),I=()=>{if(!c(t)){s({show:!0,msg:a("Please map mandatory fields","bit-integrations")});return}if(!t.selectedTag){w.error(a("Please select a Tag","bit-integrations"));return}N({flow:n,allIntegURL:l,conf:t,navigate:f,edit:1,setIsLoading:r,setSnackbar:s})};return e.jsxs("div",{style:{width:900},children:[e.jsx(C,{snack:u,setSnackbar:s}),e.jsxs("div",{className:"flx mt-3",children:[e.jsx("b",{className:"wdt-200 d-in-b",children:a("Integration Name:","bit-integrations")}),e.jsx("input",{className:"btcd-paper-inp w-5",onChange:S=>k(S,t,i),name:"name",value:t.name,type:"text",placeholder:a("Integration Name...","bit-integrations")})]}),e.jsx("br",{}),e.jsx(v,{entity:n.triggered_entity,setSnackbar:s}),e.jsx(E,{formID:n.triggered_entity_id,formFields:m,systemeIOConf:t,setSystemeIOConf:i,loading:p,setLoading:x,setIsLoading:r,setSnackbar:s}),e.jsx(F,{edit:!0,saveConfig:I,disabled:!c(t),isLoading:g,dataConf:t,setDataConf:i,formFields:m}),e.jsx("br",{})]})}export{B as default};