UNPKG

50.5 kBSource Map (JSON)View Raw
1{"version":3,"file":"soushians-config.js.map","sources":["ng://@soushians/config/lib/models/config.model.ts","ng://@soushians/config/lib/models/get-configs-api.model.ts","ng://@soushians/config/lib/models/edit-config-api.model.ts","ng://@soushians/config/lib/config.config.ts","ng://@soushians/config/lib/actions/config.action.ts","ng://@soushians/config/lib/reducers/config-list.reducer.ts","ng://@soushians/config/lib/reducers/index.ts","ng://@soushians/config/lib/services/configuration.service.ts","ng://@soushians/config/lib/services/config.service.ts","ng://@soushians/config/lib/smart-components/configs/configs.component.ts","ng://@soushians/config/lib/dumb-components/authentication-module-config/authentication-module-config.component.ts","ng://@soushians/config/lib/dumb-components/app-config/app-config.component.ts","ng://@soushians/config/lib/dumb-components/user-module-config/user-module-config.component.ts","ng://@soushians/config/lib/dumb-components/layout-config/layout-module-config.component.ts","ng://@soushians/config/lib/smart-components/dynamic-config-component-selector/dynamic-config-component-selector.component.ts","ng://@soushians/config/lib/smart-components/config-edit/config-edit.component.ts","ng://@soushians/config/lib/smart-components/config-module-container/config-module-container.component.ts","ng://@soushians/config/lib/effects/load-config.effects.ts","ng://@soushians/config/lib/config.routing-module.ts","ng://@soushians/config/lib/config.module.ts"],"sourcesContent":["export class ConfigModel<T> {\r\n\t_id: string;\r\n\tName: string;\r\n\tConfig: T;\r\n}","import { Injectable } from \"@angular/core\";\r\nimport { HttpRequestBaseModel } from \"@soushians/shared\";\r\nimport { FormGroup, FormControl, Validators } from \"@angular/forms\";\r\nimport { ConfigModel } from \"./config.model\";\r\n\r\nexport namespace GetConfigsApiModel {\r\n\texport class Request implements HttpRequestBaseModel<Request> {\r\n\t\tconstructor(initValue: GetConfigsApiModel.Request = {} as GetConfigsApiModel.Request) {\r\n\t\t\tObject.keys(initValue).forEach(key => ((this as any)[key] = (initValue as any)[key]));\r\n\t\t}\r\n\r\n\t\tgetRequestBody() {\r\n\t\t\treturn {};\r\n\t\t}\r\n\t}\r\n\r\n\texport class Response {\r\n\t\tResult: ConfigModel<any>[];\r\n\t\tconstructor() {}\r\n\t}\r\n}\r\n","import { Injectable } from \"@angular/core\";\r\nimport { HttpRequestBaseModel } from \"@soushians/shared\";\r\nimport { FormGroup, FormControl, Validators } from \"@angular/forms\";\r\nimport { ConfigModel } from \"../models\";\r\n\r\nexport namespace EditConfigApiModel {\r\n\texport class Request implements HttpRequestBaseModel<Request> {\r\n\t\tName: string;\r\n\t\tConfig: {};\r\n\t\tconstructor(initValue = {} as EditConfigApiModel.Request) {\r\n\t\t\tObject.keys(initValue).forEach(key => ((this as any)[key] = (initValue as any)[key]));\r\n\t\t}\r\n\r\n\t\tgetRequestBody() {\r\n\t\t\treturn {\r\n\t\t\t\tName: this.Name,\r\n\t\t\t\tConfig: this.Config\r\n\t\t\t};\r\n\t\t}\r\n\t\tstatic get formGroup() {\r\n\t\t\treturn new FormGroup({\r\n\t\t\t\tName: new FormControl(\"\", [ Validators.required ]),\r\n\t\t\t\tConfig: new FormGroup({})\r\n\t\t\t});\r\n\t\t}\r\n\t}\r\n\r\n\texport class Response {\r\n\t\tResult: ConfigModel<any>;\r\n\t\tconstructor() {}\r\n\t}\r\n}\r\n","import { InjectionToken } from \"@angular/core\";\r\n\r\nexport interface ConfigModuleConfig {\r\n\tenv?: {\r\n\t\tproduction: boolean;\r\n\t\tfrontend_server: string;\r\n\t};\r\n}\r\n\r\nexport const MODULE_DEFAULT_CONFIG: ConfigModuleConfig = {\r\n\tenv: {\r\n\t\tproduction: false,\r\n\t\tfrontend_server: \"config/module/front_end/did/not/set\"\r\n\t}\r\n};\r\n\r\nexport const MODULE_CONFIG_TOKEN = new InjectionToken<ConfigModuleConfig>(\"UserModuleConfig\");\r\n","import { Action } from \"@ngrx/store\";\r\nimport { ConfigModel, GetConfigsApiModel } from \"../models\";\r\n\r\nexport enum ConfigActionTypes {\r\n\tGET_CONFIGS = \"[CONFIG] get config\",\r\n\tCONFIG_LOADED_SUCCEED = \"[CONFIG] load config succeed\",\r\n\tUPDATE_CONFIG = \"[CONFIG] update config\",\r\n\tCONFIG_LOADED_FAILED = \"[CONFIG] load config failed\"\r\n}\r\n\r\nexport class GetConfigAction implements Action {\r\n\treadonly type = ConfigActionTypes.GET_CONFIGS;\r\n}\r\n\r\nexport class ConfigLoadedSucceedAction implements Action {\r\n\treadonly type = ConfigActionTypes.CONFIG_LOADED_SUCCEED;\r\n\r\n\tconstructor(public payload: ConfigModel<any>[]) {}\r\n}\r\nexport class UpdateConfigAction implements Action {\r\n\treadonly type = ConfigActionTypes.UPDATE_CONFIG;\r\n\tconstructor(public payload: ConfigModel<any>) {}\r\n}\r\n\r\nexport class ConfigLoadedFailedAction implements Action {\r\n\treadonly type = ConfigActionTypes.CONFIG_LOADED_FAILED;\r\n}\r\nexport type Actions = GetConfigAction | ConfigLoadedSucceedAction | ConfigLoadedFailedAction | UpdateConfigAction;\r\n","import * as config from \"../actions/config.action\";\r\n\r\nexport interface State {\r\n\tdata: any[];\r\n}\r\n\r\nconst initialState: State = {\r\n\tdata: []\r\n};\r\n\r\nexport function Reducer(state = initialState, action: config.Actions): State {\r\n\tswitch (action.type) {\r\n\t\tcase config.ConfigActionTypes.CONFIG_LOADED_SUCCEED:\r\n\t\t\treturn {\r\n\t\t\t\t...state,\r\n\t\t\t\tdata: action.payload\r\n\t\t\t};\r\n\t\tcase config.ConfigActionTypes.UPDATE_CONFIG:\r\n\t\t\treturn {\r\n\t\t\t\t...state,\r\n\t\t\t\tdata: state.data.map(config => {\r\n\t\t\t\t\tif (config._id == action.payload._id) config.Config = action.payload.Config;\r\n\t\t\t\t\treturn config;\r\n\t\t\t\t})\r\n\t\t\t};\r\n\t\tdefault:\r\n\t\t\treturn state;\r\n\t}\r\n}\r\n\r\nexport const getConfigs = (state: State) => state.data;\r\nexport const getAppConfig = (state: State) => state.data.find(config => config.Name == \"app_config\");\r\nexport const getAuthenticationModuleConfig = (state: State) =>\r\n\tstate.data.find(config => config.Name == \"authentication_module_config\");\r\nexport const getUserModuleConfig = (state: State) => state.data.find(config => config.Name == \"user_module_config\");\r\nexport const getConfigModuleConfig = (state: State) =>\r\n\tstate.data.find(config => config.Name == \"config_module_config\") as any;\r\nexport const getFormModuleConfig = (state: State) =>\r\n\tstate.data.find(config => config.Name == \"form_module_config\") as any;\r\nexport const getSocketModuleConfig = (state: State) =>\r\n\tstate.data.find(config => config.Name == \"socket_module_config\") as any;\r\n","import { createSelector, createFeatureSelector, MemoizedSelector } from \"@ngrx/store\";\r\n\r\nimport * as configList from \"./config-list.reducer\";\r\nimport { ConfigLoadedFailedAction, ConfigLoadedSucceedAction } from \"../actions\";\r\nexport interface ConfigState {\r\n\tlist: configList.State;\r\n}\r\nexport const ConfigReducers = {\r\n\tlist: configList.Reducer\r\n};\r\n\r\nexport interface FeatureState {\r\n\t\"configs\": ConfigState;\r\n}\r\n\r\n//#region selectors\r\n\r\nexport const selectConfigState = createFeatureSelector<ConfigState>(\"config\");\r\n\r\n//#endregion\r\n\r\nexport const getConfigListState = createSelector(selectConfigState, (state: ConfigState) => state.list);\r\nexport const getConfigs = createSelector(getConfigListState, configList.getConfigs);\r\nexport const getAppConfig = createSelector(getConfigListState, configList.getAppConfig);\r\nexport const getAuthenticationModuleConfig = createSelector(\r\n\tgetConfigListState,\r\n\tconfigList.getAuthenticationModuleConfig\r\n);\r\nexport const getUserModuleConfig = createSelector(getConfigListState, configList.getUserModuleConfig);\r\nexport const getConfigModuleConfig = createSelector(getConfigListState, configList.getConfigModuleConfig);\r\nexport const getFormModuleConfig = createSelector(getConfigListState, configList.getFormModuleConfig);\r\nexport const getSocketModuleConfig = createSelector(getConfigListState, configList.getSocketModuleConfig);\r\n","import { Injectable, Inject } from \"@angular/core\";\r\nimport { Store } from \"@ngrx/store\";\r\nimport { Observable } from \"rxjs/Observable\";\r\n\r\nimport { ConfigModuleConfig, MODULE_CONFIG_TOKEN, MODULE_DEFAULT_CONFIG } from \"../config.config\";\r\nimport { getConfigModuleConfig } from \"../reducers\";\r\nimport { BehaviorSubject } from \"rxjs/BehaviorSubject\";\r\n\r\n@Injectable({\r\n\tprovidedIn: \"root\"\r\n})\r\nexport class ConfigurationService {\r\n\tprivate _config: ConfigModuleConfig;\r\n\tget config() {\r\n\t\treturn this._config;\r\n\t}\r\n\tconfig$ = new BehaviorSubject(this._config);\r\n\r\n\tconstructor(@Inject(MODULE_CONFIG_TOKEN) configFile: ConfigModuleConfig, private store: Store<any>) {\r\n\t\tthis._config = Object.assign({}, MODULE_DEFAULT_CONFIG, configFile);\r\n\t\tthis.config$.next(this._config);\r\n\t\tthis.store.select(getConfigModuleConfig).subscribe(configConfig => {\r\n\t\t\tif (!configConfig) return;\r\n\t\t\tthis._config = Object.assign({}, this._config, configConfig.Config);\r\n\t\t\tthis.config$.next(this._config);\r\n\t\t});\r\n\t}\r\n}\r\n","import { Injectable } from \"@angular/core\";\r\nimport { HttpClient } from \"@angular/common/http\";\r\nimport { Observable } from \"rxjs\";\r\nimport { Store } from \"@ngrx/store\";\r\n\r\nimport { EditConfigApiModel, GetConfigsApiModel, ConfigModel } from \"../models\";\r\n\r\nimport { ConfigState } from \"../reducers\";\r\nimport { GetConfigAction } from \"../actions\";\r\nimport { ConfigurationService } from \"./configuration.service\";\r\nimport { take, map, catchError } from \"rxjs/operators\";\r\n\r\n@Injectable({\r\n\tprovidedIn: \"root\"\r\n})\r\nexport class ConfigService {\r\n\tresponseCache: any;\r\n\r\n\tconstructor(\r\n\t\tprivate http: HttpClient,\r\n\t\tprivate store: Store<ConfigState>,\r\n\t\tprivate configurationService: ConfigurationService\r\n\t) {\r\n\t\tsetTimeout(() => {\r\n\t\t\tthis.store.dispatch(new GetConfigAction());\r\n\t\t}, 999);\r\n\t}\r\n\r\n\tgetConfigs(): Observable<ConfigModel<any>[]> {\r\n\t\treturn this.http\r\n\t\t\t.get(`${this.configurationService.config.env.frontend_server}/api/config`)\r\n\t\t\t.pipe(\r\n\t\t\t\ttake(1),\r\n\t\t\t\tmap((response: GetConfigsApiModel.Response) => response.Result),\r\n\t\t\t\tcatchError(err => Observable.throw(err))\r\n\t\t\t);\r\n\t}\r\n\tgetConfigByName(name: string): Observable<any> {\r\n\t\treturn this.http.get(`${this.configurationService.config.env.frontend_server}/api/config/${name}`).pipe(\r\n\t\t\tmap(response => response),\r\n\t\t\tcatchError(err => {\r\n\t\t\t\treturn Observable.throw(err);\r\n\t\t\t})\r\n\t\t);\r\n\t}\r\n\teditConfig(body: EditConfigApiModel.Request): Observable<any> {\r\n\t\tconst model = new EditConfigApiModel.Request(body);\r\n\r\n\t\treturn this.http\r\n\t\t\t.put(\r\n\t\t\t\t`${this.configurationService.config.env.frontend_server}/api/config/${model.Name}`,\r\n\t\t\t\tmodel.getRequestBody()\r\n\t\t\t)\r\n\t\t\t.pipe(\r\n\t\t\t\tmap(response => response),\r\n\t\t\t\tcatchError(err => {\r\n\t\t\t\t\treturn Observable.throw(err);\r\n\t\t\t\t})\r\n\t\t\t);\r\n\t}\r\n\r\n\tgetLayoutConfigs(): Observable<any> {\r\n\t\treturn this.http.get(`${this.configurationService.config.env.frontend_server}/api/layout-config`).pipe(\r\n\t\t\tmap((response: any) => response),\r\n\t\t\tcatchError(err => {\r\n\t\t\t\treturn Observable.throw(err);\r\n\t\t\t})\r\n\t\t);\r\n\t}\r\n}\r\n","import { Component, OnInit } from \"@angular/core\";\r\nimport { Observable } from \"rxjs/Observable\";\r\nimport { Store } from \"@ngrx/store\";\r\n\r\nimport { ConfigModel } from \"../../models\";\r\nimport { getConfigs, FeatureState } from \"../../reducers\";\r\n\r\n@Component({\r\n\tselector: \"configs\",\r\n\ttemplateUrl: \"./configs.component.html\",\r\n\tstyleUrls: [ \"./configs.component.scss\" ]\r\n})\r\nexport class ConfigsComponent {\r\n\tconfigs: Observable<ConfigModel<any>[]>;\r\n\tconstructor(private store: Store<FeatureState>) {\r\n\t\tthis.configs = this.store.select(getConfigs);\r\n\t}\r\n}\r\n","import { NgModule, Component, OnInit, Output, EventEmitter, Input, Injector } from \"@angular/core\";\r\nimport { FormGroup, Validators, FormControl } from \"@angular/forms\";\r\nimport { Store } from \"@ngrx/store\";\r\n\r\n@Component({\r\n\tselector: \"config-authentication-module-config\",\r\n\ttemplateUrl: \"./authentication-module-config.component.html\"\r\n})\r\nexport class AuthenticationModuleConfigComponent {\r\n\tformGroup: FormGroup = new FormGroup({\r\n\t\tendpoints: new FormGroup({\r\n\t\t\tsignIn: new FormControl(\"\", [Validators.required]),\r\n\t\t\tsignOut: new FormControl(\"\", [Validators.required]),\r\n\t\t\twhoAmI: new FormControl(\"\", [Validators.required]),\r\n\t\t\tcaptchaUrl: new FormControl(\"\", [Validators.required])\r\n\t\t}),\r\n\t\tforms: new FormGroup({\r\n\t\t\tsignIn: new FormControl(\"\", [Validators.required])\r\n\t\t})\r\n\t});\r\n\t@Input()\r\n\tset configFormGroup(configFormGroup: FormGroup) {\r\n\t\tthis.formGroup.patchValue(configFormGroup.value);\r\n\t\tconfigFormGroup.valueChanges.subscribe(data => {\r\n\t\t\tthis.formGroup.patchValue(data);\r\n\t\t});\r\n\t}\r\n\t@Output() configChanged = new EventEmitter();\r\n\tconstructor(private injector: Injector) {\r\n\t\tthis.configFormGroup = this.injector.get(\"configFormGroup\");\r\n\t}\r\n\tsetFormId(formId: string, formName: string) {\r\n\t\tthis.formGroup.patchValue({ [formName]: formId });\r\n\t}\r\n}\r\n","import { NgModule, Component, OnInit, Output, EventEmitter, Input, Injector } from \"@angular/core\";\r\nimport { FormGroup, Validators, FormControl } from \"@angular/forms\";\r\nimport { Store } from \"@ngrx/store\";\r\n\r\n@Component({\r\n\tselector: \"config-app-config\",\r\n\ttemplateUrl: \"./app-config.component.html\"\r\n})\r\nexport class ConfigAppConfigComponent {\r\n\tformGroup: FormGroup = new FormGroup({ AppTitle: new FormControl(\"\", [ Validators.required ]) });\r\n\t@Input()\r\n\tset configFormGroup(configFormGroup: FormGroup) {\r\n\t\tthis.formGroup.patchValue(configFormGroup.value);\r\n\t\tconfigFormGroup.valueChanges.subscribe(data => {\r\n\t\t\tthis.formGroup.patchValue(data);\r\n\t\t});\r\n\t}\r\n\t@Output() configChanged = new EventEmitter();\r\n\tconstructor(private injector: Injector) {\r\n\t\tthis.configFormGroup = this.injector.get(\"configFormGroup\");\r\n\t}\r\n}\r\n","import { NgModule, Component, OnInit, Output, EventEmitter, Input, Injector } from \"@angular/core\";\r\nimport { FormGroup, Validators, FormControl, FormArray } from \"@angular/forms\";\r\nimport { ActivatedRoute } from \"@angular/router\";\r\n\r\n@Component({\r\n\tselector: \"config-user-module-config\",\r\n\ttemplateUrl: \"./user-module-config.component.html\"\r\n})\r\nexport class UserModuleConfigComponent {\r\n\tformGroup: FormGroup = new FormGroup({\r\n\t\tendpoints: new FormGroup({\r\n\t\t\tchangePassword: new FormControl(\"\", [ Validators.required ]),\r\n\t\t\teditProfile: new FormControl(\"\", [ Validators.required ]),\r\n\t\t\tgetUserInfo: new FormControl(\"\", [ Validators.required ]),\r\n\t\t\twhoAmI: new FormControl(\"\", [ Validators.required ])\r\n\t\t}),\r\n\t\tforms: new FormGroup({\r\n\t\t\tprofile_edit: new FormControl(\"\", [ Validators.required ])\r\n\t\t}),\r\n\t\tdashboardLinks: new FormArray([])\r\n\t});\r\n\t_configFormGroup: FormGroup;\r\n\t@Input()\r\n\tset configFormGroup(configFormGroup: FormGroup) {\r\n\t\tthis._configFormGroup = configFormGroup;\r\n\t\t(configFormGroup.controls.dashboardLinks as FormArray).controls.forEach(control => {\r\n\t\t\t(this.formGroup.controls.dashboardLinks as FormArray).push(\r\n\t\t\t\tnew FormGroup({\r\n\t\t\t\t\troute: new FormControl(\"\", [ Validators.required ]),\r\n\t\t\t\t\ticon: new FormControl(\"\", [ Validators.required ]),\r\n\t\t\t\t\ttitle: new FormControl(\"\", [ Validators.required ])\r\n\t\t\t\t})\r\n\t\t\t);\r\n\t\t});\r\n\r\n\t\tthis.formGroup.patchValue(configFormGroup.value);\r\n\t\tconfigFormGroup.valueChanges.subscribe(data => {\r\n\t\t\tthis.formGroup.patchValue(data);\r\n\t\t});\r\n\t}\r\n\tget configFormGroup() {\r\n\t\treturn this._configFormGroup;\r\n\t}\r\n\t@Output() configChanged = new EventEmitter();\r\n\tconstructor(private injector: Injector) {\r\n\t\tthis.configFormGroup = this.injector.get(\"configFormGroup\");\r\n\t}\r\n\taddMenu() {\r\n\t\tvar menuItem = new FormGroup({\r\n\t\t\troute: new FormControl(\"\", [ Validators.required ]),\r\n\t\t\ticon: new FormControl(\"\", [ Validators.required ]),\r\n\t\t\ttitle: new FormControl(\"\", [ Validators.required ])\r\n\t\t});\r\n\r\n\t\t(this.formGroup.get(\"dashboardLinks\") as FormArray).push(menuItem);\r\n\t\t(this.configFormGroup.get(\"dashboardLinks\") as FormArray).push(menuItem);\r\n\t}\r\n}\r\n","import { Component, Output, EventEmitter, Input, Injector } from \"@angular/core\";\r\nimport { FormGroup, Validators, FormControl, FormArray } from \"@angular/forms\";\r\nimport { Observable } from \"rxjs\";\r\nimport { map, filter } from \"rxjs/operators\";\r\nimport { Store } from \"@ngrx/store\";\r\n\r\nimport { FeatureState, getAppConfig } from \"../../reducers\";\r\n\r\n@Component({\r\n\ttemplateUrl: \"./layout-module-config.component.html\"\r\n})\r\nexport class LayoutModuleConfigComponent {\r\n\t@Output(\"configChanged\") configChanged = new EventEmitter();\r\n\t_configFormGroup: FormGroup;\r\n\t@Input()\r\n\tset configFormGroup(configFormGroup: FormGroup) {\r\n\t\tthis._configFormGroup = configFormGroup;\r\n\t\t(configFormGroup.controls.menuItems as FormArray).controls.forEach(control => {\r\n\t\t\t(this.formGroup.controls.menuItems as FormArray).push(\r\n\t\t\t\tnew FormGroup({\r\n\t\t\t\t\troute: new FormControl(\"\", [Validators.required]),\r\n\t\t\t\t\ticon: new FormControl(\"\", [Validators.required]),\r\n\t\t\t\t\t// roles: new FormArray(control.value.roles.map((i) => new FormControl(\"Admin\"))),\r\n\t\t\t\t\troles: new FormControl(),\r\n\t\t\t\t\ttitle: new FormControl(\"\", [Validators.required])\r\n\t\t\t\t})\r\n\t\t\t);\r\n\t\t});\r\n\r\n\t\tthis.formGroup.patchValue(configFormGroup.value);\r\n\t\tconfigFormGroup.valueChanges.subscribe(data => this.formGroup.patchValue(data));\r\n\t}\r\n\tget configFormGroup() {\r\n\t\treturn this._configFormGroup;\r\n\t}\r\n\r\n\tsideNavModes: string[];\r\n\tlayoutModes: string[];\r\n\tformGroup = new FormGroup({\r\n\t\tlayoutMode: new FormControl(\"\", [Validators.required]),\r\n\t\tshowLeftNavBar: new FormControl(\"\", [Validators.required]),\r\n\t\tmainSideNavMode: new FormControl(\"\", [Validators.required]),\r\n\t\tshowMainSidenav: new FormControl(\"\", [Validators.required]),\r\n\t\tstickyLeftNavBar: new FormControl(\"\", [Validators.required]),\r\n\t\tshowSecondSideNav: new FormControl(\"\", [Validators.required]),\r\n\t\tsecondSideNavMode: new FormControl(\"\", [Validators.required]),\r\n\t\tmenuItems: new FormArray([])\r\n\t});\r\n\troleItems$: Observable<string[]>;\r\n\r\n\tconstructor(private injector: Injector, private store: Store<FeatureState>) {\r\n\t\tthis.sideNavModes = [\"over\", \"push\", \"side\"];\r\n\t\tthis.layoutModes = [\"with-margin\", \"without-margin\", \"default\"];\r\n\t\tthis.configFormGroup = this.injector.get(\"configFormGroup\");\r\n\t\tthis.roleItems$ = this.store\r\n\t\t\t.select(getAppConfig)\r\n\t\t\t.pipe(filter(config => config != null), map(appconfig => appconfig.Config.Roles));\r\n\t\t// this.configChanged.\r\n\t\t// this.formGroup.valueChanges.subscribe(value => {\r\n\t\t// \tdebugger;\r\n\t\t// \tthis.configChanged.emit(value);\r\n\t\t// });\r\n\t}\r\n\taddMenu() {\r\n\t\tconst menuItem = new FormGroup({\r\n\t\t\troute: new FormControl(\"\", [Validators.required]),\r\n\t\t\ticon: new FormControl(\"\", [Validators.required]),\r\n\t\t\troles: new FormControl(),\r\n\t\t\ttitle: new FormControl(\"\", [Validators.required])\r\n\t\t});\r\n\r\n\t\t(this.formGroup.get(\"menuItems\") as FormArray).push(menuItem);\r\n\t\t(this.configFormGroup.get(\"menuItems\") as FormArray).push(menuItem);\r\n\t}\r\n\tremoveMenu(item: any) {\r\n\t\tdebugger;\r\n\t\tconst index = (this.formGroup.get(\"menuItems\") as FormArray).controls.indexOf(item);\r\n\t\t(this.formGroup.get(\"menuItems\") as FormArray).removeAt(index);\r\n\t}\r\n}\r\n","import {\r\n\tComponent,\r\n\tOnInit,\r\n\tInput,\r\n\tAfterViewInit,\r\n\tComponentFactoryResolver,\r\n\tViewChild,\r\n\tViewContainerRef,\r\n\tReflectiveInjector,\r\n\tOnDestroy,\r\n\tOutput,\r\n\tEventEmitter\r\n} from \"@angular/core\";\r\nimport { Observable } from \"rxjs/Observable\";\r\n\r\nimport { PartialConfig } from \"../../models\";\r\nimport { AuthenticationModuleConfigComponent } from \"../../dumb-components/authentication-module-config/authentication-module-config.component\";\r\nimport { ConfigAppConfigComponent } from \"../../dumb-components/app-config/app-config.component\";\r\nimport { UserModuleConfigComponent } from \"../../dumb-components/user-module-config/user-module-config.component\";\r\nimport { LayoutModuleConfigComponent } from \"../../dumb-components/layout-config/layout-module-config.component\";\r\n\r\n@Component({\r\n\tselector: \"dynamic-config-component-selector\",\r\n\ttemplateUrl: \"./dynamic-config-component-selector.component.html\",\r\n\tstyleUrls: [ \"./dynamic-config-component-selector.component.scss\" ],\r\n\tentryComponents: [\r\n\t\tAuthenticationModuleConfigComponent,\r\n\t\tConfigAppConfigComponent,\r\n\t\tUserModuleConfigComponent,\r\n\t\tLayoutModuleConfigComponent\r\n\t]\r\n})\r\nexport class DynamicConfigComponentSelectorComponent implements AfterViewInit {\r\n\ttypeMapToDiagram: any = {\r\n\t\tauthentication_module_config: AuthenticationModuleConfigComponent,\r\n\t\tapp_config: ConfigAppConfigComponent,\r\n\t\tuser_module_config: UserModuleConfigComponent,\r\n\t\tlayout_config: LayoutModuleConfigComponent\r\n\t};\r\n\t@ViewChild(\"dynamicComponentContainer\", { read: ViewContainerRef })\r\n\tdynamicComponentContainer: ViewContainerRef;\r\n\t@Output() configChanged = new EventEmitter();\r\n\tget config() {\r\n\t\tif (!this.currentComponent) return {};\r\n\t\treturn this.currentComponent.instance.formGroup.value;\r\n\t}\r\n\tcurrentComponent: any = null;\r\n\t@Input()\r\n\tset data(data: PartialConfig) {\r\n\t\tif (!data || Object.keys(data).length == 0) return;\r\n\t\tif (!(data.type in this.typeMapToDiagram)) {\r\n\t\t\tif (this.currentComponent) this.currentComponent.destroy();\r\n\t\t\treturn;\r\n\t\t}\r\n\t\tlet _component: any = this.typeMapToDiagram[data.type];\r\n\t\tlet inputProviders = Object.keys(data.inputs).map(inputName => {\r\n\t\t\treturn { provide: inputName, useValue: (data.inputs as any)[inputName] };\r\n\t\t});\r\n\t\tlet resolvedInputs = ReflectiveInjector.resolve(inputProviders);\r\n\r\n\t\tlet injector = ReflectiveInjector.fromResolvedProviders(\r\n\t\t\tresolvedInputs,\r\n\t\t\tthis.dynamicComponentContainer.parentInjector\r\n\t\t);\r\n\t\tlet factory = this.resolver.resolveComponentFactory(_component);\r\n\r\n\t\tlet component = factory.create(injector);\r\n\t\t// (<any>component.instance).configChanged.add.subscribe((data: any) => {\r\n\t\t// \tthis.configChanged.emit(data);\r\n\t\t// });\r\n\t\tthis.dynamicComponentContainer.insert(component.hostView);\r\n\r\n\t\tif (this.currentComponent) {\r\n\t\t\tthis.currentComponent.destroy();\r\n\t\t}\r\n\r\n\t\tthis.currentComponent = component;\r\n\t}\r\n\tconstructor(private resolver: ComponentFactoryResolver) {}\r\n\tngAfterViewInit() {}\r\n}\r\n","import { NgModule, Component, OnInit, Output, EventEmitter, Input, ViewChild, ViewContainerRef } from \"@angular/core\";\r\nimport { Store } from \"@ngrx/store\";\r\nimport { ActivatedRoute } from \"@angular/router\";\r\nimport { FormGroup, FormBuilder, FormControl } from \"@angular/forms\";\r\n\r\nimport { EditConfigApiModel, PartialConfig } from \"../../models\";\r\nimport { ConfigService } from \"../../services/config.service\";\r\nimport { DynamicConfigComponentSelectorComponent } from \"../dynamic-config-component-selector\";\r\n\r\n@Component({\r\n\tselector: \"config-config-edit\",\r\n\ttemplateUrl: \"./config-edit.component.html\",\r\n\tstyleUrls: [\"./config-edit.component.css\"]\r\n})\r\nexport class ConfigEditComponent implements OnInit {\r\n\tconfigInforamation: any;\r\n\tformGroup: FormGroup = EditConfigApiModel.Request.formGroup;\r\n\tpartialConfigModel: PartialConfig;\r\n\t@ViewChild(\"dynConfig\") dynConfig: DynamicConfigComponentSelectorComponent;\r\n\tconstructor(private configService: ConfigService, private formBuilder: FormBuilder, private route: ActivatedRoute) {\r\n\t\tthis.route.params.subscribe(params => {\r\n\t\t\tconst configName: string = params[\"name\"];\r\n\t\t\tthis.configService.getConfigByName(configName).subscribe(data => {\r\n\t\t\t\tdebugger;\r\n\t\t\t\tthis.partialConfigModel = {\r\n\t\t\t\t\ttype: data.Result.Name,\r\n\t\t\t\t\tinputs: {\r\n\t\t\t\t\t\tconfigFormGroup: this.formGroup.controls.Config as FormGroup\r\n\t\t\t\t\t}\r\n\t\t\t\t};\r\n\t\t\t\tthis.formGroup.patchValue({\r\n\t\t\t\t\t_id: data.Result._id,\r\n\t\t\t\t\tName: data.Result.Name\r\n\t\t\t\t});\r\n\t\t\t\tObject.keys(data.Result.Config).forEach(key => {\r\n\t\t\t\t\tthis.addControl(this.formGroup.controls.Config as FormGroup, key, data.Result.Config[key]);\r\n\t\t\t\t});\r\n\t\t\t});\r\n\t\t});\r\n\t}\r\n\r\n\taddControl(formGroup: FormGroup, key: string, value: any) {\r\n\t\tif (value instanceof Array) {\r\n\t\t\tformGroup.addControl(key, this.formBuilder.array(value));\r\n\t\t} else if (value instanceof Object) {\r\n\t\t\tformGroup.addControl(key, this.formBuilder.group(value));\r\n\t\t} else {\r\n\t\t\tformGroup.addControl(key, new FormControl(value));\r\n\t\t}\r\n\t}\r\n\r\n\tngOnInit() { }\r\n\tconfigChanged(event: any) {\r\n\t\tconsole.log(\"-\");\r\n\t}\r\n\tedit() {\r\n\t\tthis.formGroup.controls.Config.patchValue(this.dynConfig.config);\r\n\t\tif (!this.formGroup.valid) return;\r\n\t\tthis.configService.editConfig(this.formGroup.value).subscribe(config => { });\r\n\t}\r\n}\r\n","import { Component, OnInit } from \"@angular/core\";\r\nimport { Observable } from \"rxjs/Observable\";\r\nimport { Store } from \"@ngrx/store\";\r\n\r\n@Component({\r\n\tselector: \"config-module-container\",\r\n\ttemplateUrl: \"./config-module-container.component.html\"\r\n})\r\nexport class ConfigModuleContainerComponent implements OnInit {\r\n\tconstructor() {}\r\n\r\n\tngOnInit() {}\r\n}\r\n","import { Injectable } from \"@angular/core\";\r\nimport { Observable } from \"rxjs/Observable\";\r\nimport { Action } from \"@ngrx/store\";\r\nimport { Actions, Effect } from \"@ngrx/effects\";\r\nimport { of } from \"rxjs/observable/of\";\r\n\r\nimport { ConfigActionTypes, ConfigLoadedSucceedAction, ConfigLoadedFailedAction } from \"../actions\";\r\nimport { ConfigService } from \"../services/config.service\";\r\nimport { GetConfigsApiModel } from \"../models\";\r\nimport { map, switchMap, catchError } from \"rxjs/operators\";\r\n\r\n@Injectable()\r\nexport class LoadConfigEffects {\r\n\tconstructor(private actions$: Actions<any>, private configService: ConfigService) {}\r\n\r\n\t@Effect()\r\n\tgetConfigs$ = this.actions$\r\n\t\t.ofType(ConfigActionTypes.GET_CONFIGS)\r\n\t\t.pipe(\r\n\t\t\tmap(action => action.payload),\r\n\t\t\tswitchMap((data: GetConfigsApiModel.Request) => this.configService.getConfigs()),\r\n\t\t\tmap(configs => new ConfigLoadedSucceedAction(configs)),\r\n\t\t\tcatchError(() => of(new ConfigLoadedFailedAction()))\r\n\t\t);\r\n}\r\n","import { ModuleWithProviders } from \"@angular/core\";\r\nimport { RouterModule, Routes } from \"@angular/router\";\r\n\r\nimport { ConfigModuleContainerComponent } from \"./smart-components/config-module-container/config-module-container.component\";\r\nimport { ConfigsComponent } from \"./smart-components/configs/configs.component\";\r\nimport { ConfigEditComponent } from \"./smart-components/config-edit/config-edit.component\";\r\n\r\nconst routes: Routes = [\r\n\t{\r\n\t\tpath: \"configs\",\r\n\t\tcomponent: ConfigModuleContainerComponent,\r\n\t\tchildren: [\r\n\t\t\t{\r\n\t\t\t\tpath: \"\",\r\n\t\t\t\tcomponent: ConfigsComponent\r\n\t\t\t},\r\n\t\t\t{\r\n\t\t\t\tpath: \"edit/:name\",\r\n\t\t\t\tcomponent: ConfigEditComponent\r\n\t\t\t}\r\n\t\t]\r\n\t}\r\n];\r\n\r\nexport const RoutingModule: ModuleWithProviders = RouterModule.forChild(routes);\r\n","import { NgModule, ModuleWithProviders } from \"@angular/core\";\r\nimport { StoreModule } from \"@ngrx/store\";\r\nimport { CommonModule } from \"@angular/common\";\r\nimport { RouterModule } from \"@angular/router\";\r\nimport { FormsModule, ReactiveFormsModule } from \"@angular/forms\";\r\nimport { HttpClientModule } from \"@angular/common/http\";\r\nimport { FlexLayoutModule } from \"@angular/flex-layout\";\r\nimport { BrowserAnimationsModule } from \"@angular/platform-browser/animations\";\r\nimport {\r\n\tMatIconModule,\r\n\tMatButtonModule,\r\n\tMatCardModule,\r\n\tMatSnackBarModule,\r\n\tMatSidenavModule,\r\n\tMatExpansionModule,\r\n\tMatSelectModule,\r\n\tMatFormFieldModule,\r\n\tMatListModule,\r\n\tMatMenuModule,\r\n\tMatRadioModule,\r\n\tMatInputModule,\r\n\tMatToolbarModule,\r\n\tMatDatepickerModule,\r\n\tMatProgressBarModule,\r\n\tMatSlideToggleModule\r\n} from \"@angular/material\";\r\nimport { EffectsModule } from \"@ngrx/effects\";\r\n\r\nimport { ConfigModuleConfig, MODULE_CONFIG_TOKEN } from \"./config.config\";\r\nimport { ConfigsComponent } from \"./smart-components/configs/configs.component\";\r\nimport { ConfigEditComponent } from \"./smart-components/config-edit/config-edit.component\";\r\nimport { ConfigAppConfigComponent } from \"./dumb-components/app-config/app-config.component\";\r\nimport { UserModuleConfigComponent } from \"./dumb-components/user-module-config/user-module-config.component\";\r\nimport { LayoutModuleConfigComponent } from \"./dumb-components/layout-config/layout-module-config.component\";\r\nimport { ConfigModuleContainerComponent } from \"./smart-components/config-module-container/config-module-container.component\";\r\nimport { AuthenticationModuleConfigComponent } from \"./dumb-components/authentication-module-config/authentication-module-config.component\";\r\nimport { DynamicConfigComponentSelectorComponent } from \"./smart-components/dynamic-config-component-selector/dynamic-config-component-selector.component\";\r\nimport { LoadConfigEffects } from \"./effects/load-config.effects\";\r\nimport { ConfigReducers } from \"./reducers/index\";\r\nimport { RoutingModule } from \"./config.routing-module\";\r\n\r\n@NgModule({\r\n\timports: [\r\n\t\tCommonModule,\r\n\t\tRouterModule,\r\n\t\tFormsModule,\r\n\t\tReactiveFormsModule,\r\n\t\tHttpClientModule,\r\n\t\tFlexLayoutModule,\r\n\t\tMatIconModule,\r\n\t\tMatButtonModule,\r\n\t\tMatCardModule,\r\n\t\tMatSnackBarModule,\r\n\t\tMatSidenavModule,\r\n\t\tMatExpansionModule,\r\n\t\tMatSelectModule,\r\n\t\tMatFormFieldModule,\r\n\t\tMatListModule,\r\n\t\tMatMenuModule,\r\n\t\tMatRadioModule,\r\n\t\tMatInputModule,\r\n\t\tMatSlideToggleModule,\r\n\t\tMatToolbarModule,\r\n\t\tMatDatepickerModule,\r\n\t\tMatProgressBarModule,\r\n\t\tBrowserAnimationsModule\r\n\t],\r\n\tdeclarations: [\r\n\t\tConfigsComponent,\r\n\t\tConfigEditComponent,\r\n\t\tConfigAppConfigComponent,\r\n\t\tUserModuleConfigComponent,\r\n\t\tLayoutModuleConfigComponent,\r\n\t\tConfigModuleContainerComponent,\r\n\t\tAuthenticationModuleConfigComponent,\r\n\t\tDynamicConfigComponentSelectorComponent\r\n\t],\r\n\tproviders: []\r\n})\r\nexport class NgsConfigModule {\r\n\tstatic forRoot(config: ConfigModuleConfig): ModuleWithProviders {\r\n\t\treturn {\r\n\t\t\tngModule: RootNgsConfigModule,\r\n\t\t\tproviders: [ { provide: MODULE_CONFIG_TOKEN, useValue: config } ]\r\n\t\t};\r\n\t}\r\n}\r\n\r\n@NgModule({\r\n\timports: [\r\n\t\tNgsConfigModule,\r\n\t\tStoreModule.forFeature(\"config\", ConfigReducers),\r\n\t\tEffectsModule.forFeature([ LoadConfigEffects ]),\r\n\t\tRoutingModule\r\n\t],\r\n\texports: [ NgsConfigModule ]\r\n})\r\nexport class RootNgsConfigModule {}\r\n"],"names":["config.ConfigActionTypes","configList.Reducer","getConfigs","configList.getConfigs","getAppConfig","configList.getAppConfig","getAuthenticationModuleConfig","configList.getAuthenticationModuleConfig","getUserModuleConfig","configList.getUserModuleConfig","getConfigModuleConfig","configList.getConfigModuleConfig","getFormModuleConfig","configList.getFormModuleConfig","getSocketModuleConfig","configList.getSocketModuleConfig"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAAA;;;AAAA;;;sBAAA;IAIC;;;;;;ACCD,IAAiB,kBAAkB;AAAnC,WAAiB,kBAAkB;IAClC,IAAA;QACC,iBAAY,SAAwE;YAAxE,0BAAA,EAAA,8BAAwC,EAAgC,CAAA;YAApF,iBAEC;YADA,MAAM,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC,OAAO,CAAC,UAAA,GAAG,IAAI,QAAC,mBAAC,KAAW,GAAE,GAAG,CAAC,GAAG,mBAAC,SAAgB,GAAE,GAAG,CAAC,IAAC,CAAC,CAAC;SACtF;;;;QAED,gCAAc;;;QAAd;YACC,OAAO,EAAE,CAAC;SACV;sBAbH;QAcE,CAAA;IARY,0BAAO;IAUpB,IAAA;QAEC;SAAgB;uBAlBlB;QAmBE,CAAA;IAHY,2BAAQ;GAXL,kBAAkB,KAAlB,kBAAkB,QAelC;;;;;;AClBD,IAGiB,kBAAkB;AAAnC,WAAiB,kBAAkB;IAClC,IAAA;QAGC,iBAAY,SAA4C;YAA5C,0BAAA,EAAA,8BAAY,EAAgC,CAAA;YAAxD,iBAEC;YADA,MAAM,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC,OAAO,CAAC,UAAA,GAAG,IAAI,QAAC,mBAAC,KAAW,GAA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