bug fixed
This commit is contained in:
parent
0766bb6134
commit
a14148389b
|
@ -5,7 +5,8 @@ import {
|
||||||
Output,
|
Output,
|
||||||
EventEmitter,
|
EventEmitter,
|
||||||
ViewChildren,
|
ViewChildren,
|
||||||
ChangeDetectorRef
|
ChangeDetectorRef,
|
||||||
|
ChangeDetectionStrategy
|
||||||
} from '@angular/core';
|
} from '@angular/core';
|
||||||
import {
|
import {
|
||||||
RoomInfo,
|
RoomInfo,
|
||||||
|
@ -18,7 +19,7 @@ import { VersionInfo2Response } from '@ucap-webmessenger/api-public';
|
||||||
import { LoginResponse } from '@ucap-webmessenger/protocol-authentication';
|
import { LoginResponse } from '@ucap-webmessenger/protocol-authentication';
|
||||||
import { TranslatePipe } from 'projects/ucap-webmessenger-ui/src/lib/pipes/translate.pipe';
|
import { TranslatePipe } from 'projects/ucap-webmessenger-ui/src/lib/pipes/translate.pipe';
|
||||||
import {
|
import {
|
||||||
TranslateService as uiTranslateService,
|
TranslateService as UcapUiTranslateService,
|
||||||
StringUtil
|
StringUtil
|
||||||
} from '@ucap-webmessenger/ui';
|
} from '@ucap-webmessenger/ui';
|
||||||
import { TranslateService } from '@ngx-translate/core';
|
import { TranslateService } from '@ngx-translate/core';
|
||||||
|
@ -27,7 +28,8 @@ import { EventType } from '@ucap-webmessenger/protocol-event';
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'ucap-room-list-item',
|
selector: 'ucap-room-list-item',
|
||||||
templateUrl: './list-item.component.html',
|
templateUrl: './list-item.component.html',
|
||||||
styleUrls: ['./list-item.component.scss']
|
styleUrls: ['./list-item.component.scss'],
|
||||||
|
changeDetection: ChangeDetectionStrategy.OnPush
|
||||||
})
|
})
|
||||||
export class ListItemComponent implements OnInit {
|
export class ListItemComponent implements OnInit {
|
||||||
@Input()
|
@Input()
|
||||||
|
@ -58,7 +60,7 @@ export class ListItemComponent implements OnInit {
|
||||||
|
|
||||||
constructor(
|
constructor(
|
||||||
private logger: NGXLogger,
|
private logger: NGXLogger,
|
||||||
private uiTranslateService: uiTranslateService,
|
private ucapUiTranslateService: UcapUiTranslateService,
|
||||||
private translateService: TranslateService,
|
private translateService: TranslateService,
|
||||||
private changeDetectorRef: ChangeDetectorRef
|
private changeDetectorRef: ChangeDetectorRef
|
||||||
) {}
|
) {}
|
||||||
|
@ -125,7 +127,7 @@ export class ListItemComponent implements OnInit {
|
||||||
|
|
||||||
getRoomNameByRoomUser(roomUserInfos: (RoomUserInfo | UserInfoShort)[]) {
|
getRoomNameByRoomUser(roomUserInfos: (RoomUserInfo | UserInfoShort)[]) {
|
||||||
let roomName = new TranslatePipe(
|
let roomName = new TranslatePipe(
|
||||||
this.uiTranslateService,
|
this.ucapUiTranslateService,
|
||||||
this.changeDetectorRef
|
this.changeDetectorRef
|
||||||
).transform(roomUserInfos, 'name', ',');
|
).transform(roomUserInfos, 'name', ',');
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user