small fix plan-editor
This commit is contained in:
parent
88340e3580
commit
453cde406e
|
@ -210,14 +210,17 @@ export class PlanEditorComponent extends BaseEditor<PlanEditorModel, Plan> imple
|
|||
super.ngOnInit();
|
||||
if (this.isNew === false && this.step === 0) this.nextStep();
|
||||
|
||||
this.formAnnotationService.init(this.item.id, AnnotationEntityType.Plan);
|
||||
this.formAnnotationService.getAnnotationCountObservable().pipe(takeUntil(this._destroyed)).subscribe((annotationsPerAnchor: Map<string, number>) => {
|
||||
this.annotationsPerAnchor = annotationsPerAnchor;
|
||||
});
|
||||
|
||||
this.formAnnotationService.getOpenAnnotationSubjectObservable().pipe(takeUntil(this._destroyed)).subscribe((anchorId: string) => {
|
||||
if (anchorId && anchorId == this.item.id?.toString()) this.showAnnotations(anchorId);
|
||||
});
|
||||
if(this.item?.id){
|
||||
this.formAnnotationService.init(this.item.id, AnnotationEntityType.Plan);
|
||||
this.formAnnotationService.getAnnotationCountObservable().pipe(takeUntil(this._destroyed)).subscribe((annotationsPerAnchor: Map<string, number>) => {
|
||||
this.annotationsPerAnchor = annotationsPerAnchor;
|
||||
});
|
||||
|
||||
this.formAnnotationService.getOpenAnnotationSubjectObservable().pipe(takeUntil(this._destroyed)).subscribe((anchorId: string) => {
|
||||
if (anchorId && anchorId == this.item.id?.toString()) this.showAnnotations(anchorId);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
ngAfterViewInit(): void {
|
||||
|
|
Loading…
Reference in New Issue