[ACA-1821] configurable base path for shared urls (#651)

This commit is contained in:
Denys Vuika
2018-09-21 13:12:43 +01:00
committed by GitHub
parent 79a7e79d31
commit 83fec5db18
2 changed files with 6 additions and 1 deletions

View File

@@ -114,12 +114,16 @@ export class AppComponent implements OnInit {
const languagePicker = this.config.get<boolean>('languagePicker');
this.store.dispatch(new SetLanguagePickerAction(languagePicker));
const baseShareUrl =
this.config.get<string>('baseShareUrl') ||
this.config.get<string>('ecmHost');
const state: AppState = {
...INITIAL_APP_STATE,
appName: this.config.get<string>('application.name'),
headerColor: this.config.get<string>('headerColor'),
logoPath: this.config.get<string>('application.logo'),
sharedUrl: this.config.get<string>('ecmHost') + '/#/preview/s/'
sharedUrl: `${baseShareUrl}/#/preview/s/`
};
this.store.dispatch(new SetInitialStateAction(state));