Fix injections in module

pull/8051/head
Oliver Günther 5 years ago
parent 8e3ba17ae5
commit 4c90567c80
No known key found for this signature in database
GPG Key ID: A3A8BDAD7C0C552C
  1. 0
      frontend/src/app/init-vendors.ts
  2. 6
      frontend/src/app/modules/ifc_models/openproject-ifc-models.module.ts
  3. 3
      frontend/src/app/modules/ifc_models/pages/viewer/bim-view.service.ts
  4. 3
      frontend/src/app/modules/ifc_models/pages/viewer/ifc-models-data.service.ts
  5. 2
      frontend/src/main.ts
  6. 13
      frontend/src/tsconfig.app.json

@ -38,6 +38,8 @@ import {BimViewToggleButtonComponent} from "core-app/modules/ifc_models/toolbar/
import {BimViewToggleDropdownDirective} from "core-app/modules/ifc_models/toolbar/view-toggle/bim-view-toggle-dropdown.directive";
import {BimManageIfcModelsButtonComponent} from "core-app/modules/ifc_models/toolbar/manage-ifc-models-button/bim-manage-ifc-models-button.component";
import {IFCViewerService} from "core-app/modules/ifc_models/ifc-viewer/ifc-viewer.service";
import {BimViewService} from "core-app/modules/ifc_models/pages/viewer/bim-view.service";
import {IfcModelsDataService} from "core-app/modules/ifc_models/pages/viewer/ifc-models-data.service";
@NgModule({
imports: [
@ -48,7 +50,9 @@ import {IFCViewerService} from "core-app/modules/ifc_models/ifc-viewer/ifc-viewe
})
],
providers: [
IFCViewerService
IFCViewerService,
BimViewService,
IfcModelsDataService
],
declarations: [
// Pages

@ -31,7 +31,6 @@ import {I18nService} from 'core-app/modules/common/i18n/i18n.service';
import {Observable} from "rxjs";
import {StateService, TransitionService} from "@uirouter/core";
import {input} from "reactivestates";
import {OpenprojectIFCModelsModule} from "core-app/modules/ifc_models/openproject-ifc-models.module";
import {takeUntil} from "rxjs/operators";
@ -41,7 +40,7 @@ export const bimSplitViewIdentifier = 'split';
export type BimViewState = 'list'|'viewer'|'split';
@Injectable({providedIn: OpenprojectIFCModelsModule})
@Injectable()
export class BimViewService implements OnDestroy {
private _state = input<BimViewState>();

@ -1,5 +1,4 @@
import {Injectable} from "@angular/core";
import {OpenprojectIFCModelsModule} from "core-app/modules/ifc_models/openproject-ifc-models.module";
import {PathHelperService} from "core-app/modules/common/path-helper/path-helper.service";
import {GonService} from "core-app/modules/common/gon/gon.service";
import {CurrentProjectService} from "core-components/projects/current-project.service";
@ -10,7 +9,7 @@ export interface IfcModelDefinition {
saoEnabled:boolean;
}
@Injectable({ providedIn: OpenprojectIFCModelsModule })
@Injectable()
export class IfcModelsDataService {
constructor(readonly paths:PathHelperService,

@ -11,7 +11,7 @@ import {platformBrowserDynamic} from '@angular/platform-browser-dynamic';
import {SentryReporter} from "core-app/sentry/sentry-reporter";
window.ErrorReporter = new SentryReporter();
require('./app/init-vendors');
require('core-app/init-vendors');
require('./app/init-globals');

@ -5,9 +5,14 @@
"baseUrl": "./",
"types": []
},
"exclude": [
"test.ts",
"test/*",
"**/*.spec.ts"
"files": [
"main.ts",
"polyfills.ts",
"app/init-globals.ts",
"app/init-vendors"
],
"include": [
"**/*.d.ts",
"app/globals/**/*.ts"
]
}

Loading…
Cancel
Save