import{Aj as h,Bj as j,s as d,t as g}from"./chunk-EAIMSMGJ.js";import{g as u,h as y}from"./chunk-AIHAZUSZ.js";import{j as c,s as S}from"./chunk-KADRYNDC.js";import{b as p,c as I}from"./chunk-IOINCEV4.js";import{Gd as v,ka as l,na as f,sa as a,x as o,xa as n}from"./chunk-JSJB5BKT.js";import{e as m}from"./chunk-SZAW6ZBW.js";var x,A=m(()=>{f();g();v();y();I();j();S();x=(()=>{class s extends d{constructor(i,e,t,r){super(e,i),this.assetServices=t,this.messageService=r}getAzureRoles(i,e){return this.assetServices.GetRoleTemplates(i||null,e.clientId||null,e.tenantId||null,e.secretClientKey||null).pipe(l(t=>this.handleGetApiResult(t)),o(t=>this.returnWhenSuccessful(t,()=>t.data)))}getAzureGroups(i,e,t){return this.assetServices.GetGroups(t||!1,i||null,e.clientId||null,e.tenantId||null,e.secretClientKey||null,e.linkedCredentialId||null).pipe(l(r=>this.executeBasedOnResult(r,()=>void 0,()=>this.showErrorToast())),o(r=>this.returnWhenSuccessful(r,()=>r.data)))}showErrorToast(){this.messageService.add({key:"globalToast",severity:"error",summary:this.translatorService.translate("Failed"),detail:this.translatorService.translate("ConnectionFailed")})}static{this.\u0275fac=function(e){return new(e||s)(n(u),n(p),n(h),n(c))}}static{this.\u0275prov=a({token:s,factory:s.\u0275fac,providedIn:"root"})}}return s})()});export{x as a,A as b};
