test
parent
b8c3695686
commit
f42f232d8b
|
@ -10,7 +10,6 @@ import {
|
|||
CALENDAR_MAX_FUTURE_BOOKING_DAYS,
|
||||
CALENDAR_MAX_SERVICE_DURATION,
|
||||
CALENDAR_MIN_EARLIEST_BOOKING_TIME,
|
||||
CALENDAR_PRIMARY_CALENDAR_ID,
|
||||
CALENDAR_USING_PRIMARY_CALENDAR,
|
||||
Roles,
|
||||
} from "../utils/constants";
|
||||
|
@ -84,7 +83,6 @@ export async function SignUp(req: Request, res: Response) {
|
|||
name: username,
|
||||
calendar_max_future_booking_days: CALENDAR_MAX_FUTURE_BOOKING_DAYS,
|
||||
calendar_min_earliest_booking_time: CALENDAR_MIN_EARLIEST_BOOKING_TIME,
|
||||
calendar_primary_calendar_id: CALENDAR_PRIMARY_CALENDAR_ID,
|
||||
calendar_using_primary_calendar: CALENDAR_USING_PRIMARY_CALENDAR,
|
||||
calendar_max_service_duration: CALENDAR_MAX_SERVICE_DURATION,
|
||||
})
|
||||
|
|
|
@ -7,7 +7,7 @@ interface StoreAttributes {
|
|||
name: string;
|
||||
calendar_max_future_booking_days: number;
|
||||
calendar_min_earliest_booking_time: number;
|
||||
calendar_primary_calendar_id: string;
|
||||
calendar_primary_calendar_id?: string;
|
||||
calendar_using_primary_calendar: boolean;
|
||||
calendar_max_service_duration: number;
|
||||
}
|
||||
|
@ -49,7 +49,7 @@ Store.init(
|
|||
},
|
||||
calendar_primary_calendar_id: {
|
||||
type: DataTypes.STRING,
|
||||
allowNull: false,
|
||||
// allowNull defaults to true
|
||||
},
|
||||
calendar_using_primary_calendar: {
|
||||
type: DataTypes.BOOLEAN,
|
||||
|
|
|
@ -58,9 +58,11 @@ User.init(
|
|||
},
|
||||
calendar_max_future_booking_days: {
|
||||
type: DataTypes.INTEGER,
|
||||
allowNull: false,
|
||||
},
|
||||
calendar_min_earliest_booking_time: {
|
||||
type: DataTypes.INTEGER,
|
||||
allowNull: false,
|
||||
},
|
||||
calendar_primary_calendar_id: {
|
||||
type: DataTypes.STRING,
|
||||
|
|
|
@ -58,9 +58,9 @@ router.get(
|
|||
|
||||
axios
|
||||
.post(process.env.TERMIN_PLANNER_URL as string, {
|
||||
user_id: userSession.user_id,
|
||||
userId: userSession.user_id,
|
||||
accessToken: accessToken,
|
||||
refresh_token: refreshToken,
|
||||
refreshToken: refreshToken,
|
||||
pass: process.env.TERMIN_PLANNER_AUTHORIZATION_PASSWORD as string,
|
||||
})
|
||||
.then((response) => {
|
||||
|
|
|
@ -36,7 +36,7 @@ export const STORE_SERVICE_ACTIVITY_DURATION_MAX =
|
|||
|
||||
export const CALENDAR_MAX_FUTURE_BOOKING_DAYS = 14;
|
||||
export const CALENDAR_MIN_EARLIEST_BOOKING_TIME = 1;
|
||||
export const CALENDAR_PRIMARY_CALENDAR_ID = "";
|
||||
//export const CALENDAR_PRIMARY_CALENDAR_ID = "";
|
||||
export const CALENDAR_USING_PRIMARY_CALENDAR = false;
|
||||
export const CALENDAR_MAX_SERVICE_DURATION = 1440; // 24 hours in minutes
|
||||
|
||||
|
|
Loading…
Reference in New Issue