mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ADF-2625] updating viewer on node editing (#3160)
* update viewer on metadata changes * add test and docs
This commit is contained in:
committed by
Eugenio Romano
parent
2b8f12fa57
commit
11d38efe2b
@@ -18,7 +18,7 @@
|
||||
import { Component, Input, OnChanges, OnInit, SimpleChanges, SimpleChange, ViewEncapsulation } from '@angular/core';
|
||||
import { MinimalNodeEntryEntity } from 'alfresco-js-api';
|
||||
import { Observable } from 'rxjs/Observable';
|
||||
import { CardViewItem, NodesApiService, LogService, CardViewUpdateService } from '@alfresco/adf-core';
|
||||
import { CardViewItem, NodesApiService, LogService, CardViewUpdateService, AlfrescoApiService } from '@alfresco/adf-core';
|
||||
import { ContentMetadataService } from '../../services/content-metadata.service';
|
||||
import { CardViewGroup } from '../../interfaces/content-metadata.interfaces';
|
||||
|
||||
@@ -56,7 +56,8 @@ export class ContentMetadataComponent implements OnChanges, OnInit {
|
||||
constructor(private contentMetadataService: ContentMetadataService,
|
||||
private cardViewUpdateService: CardViewUpdateService,
|
||||
private nodesApi: NodesApiService,
|
||||
private logService: LogService) {}
|
||||
private logService: LogService,
|
||||
private apiService: AlfrescoApiService) {}
|
||||
|
||||
ngOnInit() {
|
||||
this.cardViewUpdateService.itemUpdated$
|
||||
@@ -65,6 +66,7 @@ export class ContentMetadataComponent implements OnChanges, OnInit {
|
||||
(node) => {
|
||||
this.nodeHasBeenUpdated = true;
|
||||
this.node = node;
|
||||
this.apiService.nodeUpdated.next(node);
|
||||
},
|
||||
error => this.logService.error(error)
|
||||
);
|
||||
|
Reference in New Issue
Block a user