frontend: update recording components to display roomName instead of roomId
This commit is contained in:
parent
42db1b7bb6
commit
8ac5e2d46f
@ -115,7 +115,7 @@
|
|||||||
<th mat-header-cell *matHeaderCellDef class="room-header">Room</th>
|
<th mat-header-cell *matHeaderCellDef class="room-header">Room</th>
|
||||||
<td mat-cell *matCellDef="let recording" class="room-cell">
|
<td mat-cell *matCellDef="let recording" class="room-cell">
|
||||||
<div class="room-info">
|
<div class="room-info">
|
||||||
<!-- <span class="room-name">{{ recording.roomName }}</span> -->
|
<span class="room-name">{{ recording.roomName }}</span>
|
||||||
<span class="room-id">{{ recording.roomId }}</span>
|
<span class="room-id">{{ recording.roomId }}</span>
|
||||||
<!-- @if (recording.filename) {
|
<!-- @if (recording.filename) {
|
||||||
<span class="filename">{{ recording.filename }}</span>
|
<span class="filename">{{ recording.filename }}</span>
|
||||||
|
|||||||
@ -44,11 +44,16 @@ export class RoomRecordingsComponent implements OnInit {
|
|||||||
|
|
||||||
async ngOnInit() {
|
async ngOnInit() {
|
||||||
this.roomId = this.route.snapshot.paramMap.get('room-id')!;
|
this.roomId = this.route.snapshot.paramMap.get('room-id')!;
|
||||||
const parts = this.roomId.split('-');
|
|
||||||
this.roomName = parts.slice(0, -1).join('-');
|
|
||||||
|
|
||||||
this.canDeleteRecordings = this.recordingService.canDeleteRecordings();
|
this.canDeleteRecordings = this.recordingService.canDeleteRecordings();
|
||||||
await this.loadRecordings();
|
await this.loadRecordings();
|
||||||
|
|
||||||
|
// Set room name based on recordings or roomId
|
||||||
|
if (this.recordings()) {
|
||||||
|
this.roomName = this.recordings()[0].roomName;
|
||||||
|
} else {
|
||||||
|
const parts = this.roomId.split('-');
|
||||||
|
this.roomName = parts.slice(0, -1).join('-');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
async goBackToRoom() {
|
async goBackToRoom() {
|
||||||
|
|||||||
@ -45,7 +45,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="header-info">
|
<div class="header-info">
|
||||||
<div class="recording-info">
|
<div class="recording-info">
|
||||||
<h1 class="recording-title">{{ recording.roomId }}</h1>
|
<h1 class="recording-title">{{ recording.roomName }}</h1>
|
||||||
<div class="recording-metadata">
|
<div class="recording-metadata">
|
||||||
<span class="recording-date">
|
<span class="recording-date">
|
||||||
<mat-icon class="ov-action-icon">schedule</mat-icon>
|
<mat-icon class="ov-action-icon">schedule</mat-icon>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user