async fix
parent
ec89709ad4
commit
87b20cead9
|
@ -336,7 +336,7 @@ export async function UpdateStoreCalendarSettings(req: Request, res: Response) {
|
||||||
calendar_min_earliest_booking_time: calendarMinEarliestBookingTime,
|
calendar_min_earliest_booking_time: calendarMinEarliestBookingTime,
|
||||||
};
|
};
|
||||||
|
|
||||||
terminPlanerRequestChangeFutureBookingDays(store.store_id);
|
await terminPlanerRequestChangeFutureBookingDays(store.store_id);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (Object.keys(update).length === 0) {
|
if (Object.keys(update).length === 0) {
|
||||||
|
@ -347,12 +347,9 @@ export async function UpdateStoreCalendarSettings(req: Request, res: Response) {
|
||||||
where: {
|
where: {
|
||||||
store_id: store.store_id,
|
store_id: store.store_id,
|
||||||
},
|
},
|
||||||
})
|
});
|
||||||
.then(() => res.status(200).send({ msg: "success" }))
|
|
||||||
.catch((err) => {
|
res.status(200).send({ msg: "success" });
|
||||||
logger.error(err);
|
|
||||||
res.status(500).send({ err: "invalid request" });
|
|
||||||
});
|
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
logger.error(error);
|
logger.error(error);
|
||||||
res.status(500).send({ err: "invalid request" });
|
res.status(500).send({ err: "invalid request" });
|
||||||
|
|
|
@ -369,7 +369,7 @@ export async function UpdateEmployee(req: Request, res: Response) {
|
||||||
calendar_min_earliest_booking_time: calendarMinEarliestBookingTime,
|
calendar_min_earliest_booking_time: calendarMinEarliestBookingTime,
|
||||||
};
|
};
|
||||||
|
|
||||||
terminPlanerRequestChangeFutureBookingDays(store.store_id);
|
await terminPlanerRequestChangeFutureBookingDays(store.store_id);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (Object.keys(update).length === 0) {
|
if (Object.keys(update).length === 0) {
|
||||||
|
|
Loading…
Reference in New Issue