upd
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
import { Schema, model } from "mongoose";
|
||||
|
||||
const mailSchema = new Schema(
|
||||
{
|
||||
fullname: {
|
||||
type: String,
|
||||
required: true,
|
||||
},
|
||||
email: {
|
||||
type: String,
|
||||
required: true,
|
||||
},
|
||||
phone: {
|
||||
type: String,
|
||||
},
|
||||
request: {
|
||||
type: String,
|
||||
},
|
||||
referer: {
|
||||
type: String,
|
||||
},
|
||||
},
|
||||
{
|
||||
timestamps: true,
|
||||
toJSON: { virtuals: true },
|
||||
toObject: { virtuals: true },
|
||||
}
|
||||
);
|
||||
|
||||
const Mail = model("Mail", mailSchema);
|
||||
|
||||
export default Mail;
|
||||
Reference in New Issue
Block a user