update preview date
This commit is contained in:
@@ -22,25 +22,25 @@ export const ConfigConstants: Record<
|
||||
MID_DAY_BREAK_TIME_START: {
|
||||
name: 'Mid Day Break Time Start',
|
||||
key: 'MID_DAY_BREAK_TIME_START',
|
||||
value: new Date(new Date().setHours(12, 0, 0, 0)).toISOString(),
|
||||
value: new Date(new Date().setUTCHours(12, 0, 0, 0)).toISOString(),
|
||||
visible: true,
|
||||
},
|
||||
MID_DAY_BREAK_TIME_END: {
|
||||
name: 'Mid Day Break Time End',
|
||||
key: 'MID_DAY_BREAK_TIME_END',
|
||||
value: new Date(new Date().setHours(13, 0, 0, 0)).toISOString(),
|
||||
value: new Date(new Date().setUTCHours(13, 0, 0, 0)).toISOString(),
|
||||
visible: true,
|
||||
},
|
||||
SLOT_START_TIME: {
|
||||
name: 'Slot Start Time',
|
||||
key: 'SLOT_START_TIME',
|
||||
value: new Date(new Date().setHours(8, 0, 0, 0)).toISOString(),
|
||||
value: new Date(new Date().setUTCHours(8, 0, 0, 0)).toISOString(),
|
||||
visible: true,
|
||||
},
|
||||
SLOT_END_TIME: {
|
||||
name: 'Slot End Time',
|
||||
key: 'SLOT_END_TIME',
|
||||
value: new Date(new Date().setHours(22, 0, 0, 0)).toISOString(),
|
||||
value: new Date(new Date().setUTCHours(22, 0, 0, 0)).toISOString(),
|
||||
visible: true,
|
||||
},
|
||||
}
|
||||
|
||||
@@ -32,6 +32,9 @@ export class AppConfigService implements OnModuleInit {
|
||||
where: { key },
|
||||
})
|
||||
}
|
||||
async getConfigValue(key: string) {
|
||||
return (await this.getConfig(key))?.value
|
||||
}
|
||||
|
||||
async getVisibleConfigs() {
|
||||
return await this.prisma.config.findMany({
|
||||
|
||||
Reference in New Issue
Block a user