This commit is contained in:
Zeeshaun
2026-03-17 11:09:46 -05:00
parent bd1a9744ad
commit 6e7edcfe1b
332 changed files with 64174 additions and 0 deletions
@@ -0,0 +1,43 @@
import devEnvironment from "../../environments/environment.dev";
import prodEnvironment from "../../environments/environment.prod";
import uatEnvironment from "../../environments/environment.uat";
const getConfigurationFromWindowLocation = () => {
const hostname = window.location.hostname;
if (hostname.match('localhost') || hostname.match('qa')) {
return devEnvironment;
}
if (hostname.match('uat')) {
return uatEnvironment;
}
return prodEnvironment;
}
const config = getConfigurationFromWindowLocation();
/**
* Static class for access application specific configuration data.
*/
export default class Configuration {
static get Get() {
return config;
}
static PrefixSSRSApiURL(relativeUrl: string){
return config.baseUrls.SSRSReportBaseUrl + relativeUrl;
}
static PrefixRepoApiUrl(relativeUrl: string) {
return config.baseUrls.repoApi + relativeUrl;
}
static PrefixCoreUrl(relativeUrl: string) {
return config.baseUrls.core + relativeUrl;
}
static PrefixCollectionsUrl(relativeUrl: string) {
return config.baseUrls.collections + relativeUrl;
}
}