(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3691],{8828:function(e,t,s){(window.__NEXT_P=window.__NEXT_P||[]).push(["/systems/configure/[id]",function(){return s(82657)}])},18225:function(e,t,s){"use strict";var n=s(24246),i=s(96306);t.Z=e=>{let{alignment:t="center",...s}=e;return(0,n.jsx)(i.kCb,{boxSize:"full",align:"center",justify:t,children:(0,n.jsx)(i.$jN,{color:"primary",...s})})}},82657:function(e,t,s){"use strict";s.r(t);var n=s(24246),i=s(96306),r=s(86677),a=s(27378),l=s(16134),d=s(25980),u=s(18225),c=s(812),o=s(14048),f=s(77213),x=s(77830),h=s(58754),m=s(32885),y=s(1315),j=s(57865),g=s(72774),_=s(21103);t.default=()=>{let e=(0,r.useRouter)(),t=(0,l.T)(),s="";e.query.id&&(s=Array.isArray(e.query.id)?e.query.id[0]:e.query.id);let{data:p,isLoading:v}=(0,y.rn)(s),{error:w,isLoading:b}=(0,m.Rd)(),{tcf:C,plus:N}=(0,d.hz)(),Z=(0,l.C)(j.gU);(0,a.useEffect)(()=>{if(p){let e=C&&!!p.vendor_id&&(0,c.cj)(p.vendor_id)===c.c6.GVL;t((0,j.gQ)(e))}else(0,j.gQ)(!1)},[p,t,C]);let{tabData:E,activeKey:k,onTabChange:S}=(0,_.Z)({isCreate:!1});return(v||b)&&!w?(0,n.jsx)(f.Z,{title:"Systems",children:(0,n.jsx)(u.Z,{})}):p?(0,n.jsxs)(f.Z,{title:"System inventory",mainProps:{w:"calc(100vw - 240px)"},children:[(0,n.jsx)(h.Z,{heading:"System inventory",breadcrumbItems:[{title:"All systems",href:x.So},{title:(null==p?void 0:p.name)||""}]}),(0,n.jsx)(i.A5g,{activeKey:k,onChange:S,items:E,className:"w-full",tabBarExtraContent:N&&(0,n.jsxs)(i.wpx,{size:"small",className:"absolute right-2 top-2","data-testid":"integration-page-btn",onClick:()=>e.push(x.KH),children:[(0,n.jsx)(i.xvT,{children:"Integrations"}),(0,n.jsx)(o.A5,{marginLeft:2})]}),renderTabBar:(e,t)=>(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(t,{...e}),Z&&(0,n.jsx)(g.Z,{})]})})]}):(0,n.jsx)(f.Z,{title:"Systems",children:(0,n.jsxs)(i.xvT,{"data-testid":"system-not-found",children:["Could not find a system with id ",s]})})}}},function(e){e.O(0,[431,8765,9278,5163,699,5277,409,7045,401,9951,6416,3585,3700,2888,9774,179],function(){return e(e.s=8828)}),_N_E=e.O()}]);