nuevos items
This commit is contained in:
parent
0a7cc3c1db
commit
594b59227d
|
@ -505,8 +505,8 @@ export class AppController {
|
|||
|
||||
@Post('reservation/createReservation')
|
||||
createReservation(
|
||||
@Body('start_time') start_time: string,
|
||||
@Body('finish_time') finish_time: string,
|
||||
@Body('date') date: string,
|
||||
@Body('time') time: string,
|
||||
@Body('status') status: string,
|
||||
@Body('date_entry') date_entry: Date,
|
||||
@Body('user_id') user_id: string,
|
||||
|
@ -515,8 +515,8 @@ export class AppController {
|
|||
@Body('communty_id') communty_id: string,
|
||||
) {
|
||||
return this.appService.createReservation(
|
||||
start_time,
|
||||
finish_time,
|
||||
date,
|
||||
time,
|
||||
status,
|
||||
date_entry,
|
||||
user_id,
|
||||
|
|
|
@ -613,12 +613,12 @@ export class AppService {
|
|||
// ====================== RESERVATIONS ===============================
|
||||
|
||||
//POST parameter from API
|
||||
createReservation(start_time: string, finish_time: string, status: string,
|
||||
createReservation(date: string, time: string, status: string,
|
||||
date_entry: Date, user_id: string, common_area_id: string,
|
||||
common_area_name: string, communty_id: string) {
|
||||
const pattern = { cmd: 'createReservation' };
|
||||
const payload = {
|
||||
start_time: start_time, finish_time: finish_time, status: status,
|
||||
date: date, time: time, status: status,
|
||||
date_entry: date_entry, user_id: user_id, common_area_id: common_area_id,
|
||||
common_area_name: common_area_name, communty_id: communty_id
|
||||
};
|
||||
|
|
|
@ -6,10 +6,10 @@ export type ReservationDocument = Reservation & Document;
|
|||
@Schema({ collection: 'reservations' })
|
||||
export class Reservation {
|
||||
@Prop()
|
||||
start_time: string;
|
||||
date: string;
|
||||
|
||||
@Prop()
|
||||
finish_time: string;
|
||||
time: string;
|
||||
|
||||
@Prop()
|
||||
status: string;
|
||||
|
|
Loading…
Reference in New Issue