mirror of
https://github.com/Litlyx/litlyx
synced 2025-12-10 15:58:38 +01:00
refactoring dashboard
This commit is contained in:
16
shared_global/schema/RegisterSchema.ts
Normal file
16
shared_global/schema/RegisterSchema.ts
Normal file
@@ -0,0 +1,16 @@
|
||||
import { model, Schema, Types } from 'mongoose';
|
||||
|
||||
export type TRegister = {
|
||||
email: string,
|
||||
password: string,
|
||||
created_at: Date
|
||||
}
|
||||
|
||||
const RegisterSchema = new Schema<TRegister>({
|
||||
email: { type: String },
|
||||
password: { type: String },
|
||||
created_at: { type: Date, default: () => Date.now() }
|
||||
});
|
||||
|
||||
export const RegisterModel = model<TRegister>('registers', RegisterSchema);
|
||||
|
||||
Reference in New Issue
Block a user