frontend: Rename expirationDate to autoDeletionDate in room-related components and services for consistency
This commit is contained in:
parent
84d68ba31b
commit
b300425a2e
@ -54,7 +54,7 @@
|
|||||||
<div matListItemLine class="item-details">
|
<div matListItemLine class="item-details">
|
||||||
<div>
|
<div>
|
||||||
<mat-icon class="icon">auto_delete</mat-icon>
|
<mat-icon class="icon">auto_delete</mat-icon>
|
||||||
<p>Expires: {{ item.expirationDate | date: 'dd/MM/yyyy' }}</p>
|
<p>Expires: {{ item.autoDeletionDate | date: 'dd/MM/yyyy' }}</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
@ -74,7 +74,7 @@ export class RoomCreatorComponent implements OnInit {
|
|||||||
// TODO: Fix expiration date
|
// TODO: Fix expiration date
|
||||||
const options: MeetRoomOptions = {
|
const options: MeetRoomOptions = {
|
||||||
roomIdPrefix,
|
roomIdPrefix,
|
||||||
expirationDate: Date.now() + 3600 * 1000 // 1 hour
|
autoDeletionDate: Date.now() + 3600 * 1000 // 1 hour
|
||||||
};
|
};
|
||||||
|
|
||||||
const room: MeetRoom = await this.httpService.createRoom(options);
|
const room: MeetRoom = await this.httpService.createRoom(options);
|
||||||
|
|||||||
@ -21,7 +21,7 @@ export class RoomService {
|
|||||||
// TODO: Improve expiration date
|
// TODO: Improve expiration date
|
||||||
const options: MeetRoomOptions = {
|
const options: MeetRoomOptions = {
|
||||||
roomIdPrefix: 'TestRoom-',
|
roomIdPrefix: 'TestRoom-',
|
||||||
expirationDate: Date.now() + 1000 * 60 * 60 // 1 hour from now
|
autoDeletionDate: Date.now() + 1000 * 60 * 60 // 1 hour from now
|
||||||
};
|
};
|
||||||
this.log.d('Creating room', options);
|
this.log.d('Creating room', options);
|
||||||
return this.httpService.createRoom(options);
|
return this.httpService.createRoom(options);
|
||||||
|
|||||||
@ -18,7 +18,7 @@ export const renderHomePage = async (req, res) => {
|
|||||||
export const createRoom = async (req, res) => {
|
export const createRoom = async (req, res) => {
|
||||||
try {
|
try {
|
||||||
// Extract values from request body
|
// Extract values from request body
|
||||||
const { roomIdPrefix, expirationDate } = req.body
|
const { roomIdPrefix, autoDeletionDate } = req.body
|
||||||
|
|
||||||
// Request to create a new room
|
// Request to create a new room
|
||||||
const response = await fetch(`${process.env.OPENVIDU_MEET_URL}/rooms`, {
|
const response = await fetch(`${process.env.OPENVIDU_MEET_URL}/rooms`, {
|
||||||
@ -26,7 +26,7 @@ export const createRoom = async (req, res) => {
|
|||||||
headers: { 'Content-Type': 'application/json' },
|
headers: { 'Content-Type': 'application/json' },
|
||||||
body: JSON.stringify({
|
body: JSON.stringify({
|
||||||
roomIdPrefix,
|
roomIdPrefix,
|
||||||
expirationDate: new Date(expirationDate).getTime()
|
autoDeletionDate: new Date(autoDeletionDate).getTime()
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|||||||
@ -127,7 +127,7 @@
|
|||||||
>
|
>
|
||||||
<input
|
<input
|
||||||
type="date"
|
type="date"
|
||||||
name="expirationDate"
|
name="autoDeletionDate"
|
||||||
id="expiration-date"
|
id="expiration-date"
|
||||||
class="form-control"
|
class="form-control"
|
||||||
required
|
required
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user