mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[AAE-10777] Move services from Core in Content the right place (#8242)
Clean core services and directive
This commit is contained in:
@@ -15,11 +15,17 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { AlfrescoApiService, LogService, CommentModel, CommentsService, PeopleContentService } from '@alfresco/adf-core';
|
||||
import {
|
||||
AlfrescoApiService,
|
||||
LogService,
|
||||
CommentModel,
|
||||
CommentsService
|
||||
} from '@alfresco/adf-core';
|
||||
import { CommentEntry, CommentsApi, Comment } from '@alfresco/js-api';
|
||||
import { Injectable } from '@angular/core';
|
||||
import { Observable, from, throwError } from 'rxjs';
|
||||
import { map, catchError } from 'rxjs/operators';
|
||||
import { ContentService } from '../../common/services/content.service';
|
||||
|
||||
@Injectable({
|
||||
providedIn: 'root'
|
||||
@@ -35,7 +41,7 @@ export class NodeCommentsService implements CommentsService {
|
||||
constructor(
|
||||
private apiService: AlfrescoApiService,
|
||||
private logService: LogService,
|
||||
private peopleContentService: PeopleContentService
|
||||
private contentService: ContentService
|
||||
) {}
|
||||
|
||||
/**
|
||||
@@ -101,7 +107,7 @@ export class NodeCommentsService implements CommentsService {
|
||||
return throwError(error || 'Server error');
|
||||
}
|
||||
|
||||
getUserImage(user: string): string {
|
||||
return this.peopleContentService.getUserProfileImage(user);
|
||||
getUserImage(avatarId: string): string {
|
||||
return this.contentService.getContentUrl(avatarId);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user