17 lines
313 B
JavaScript
17 lines
313 B
JavaScript
const mongoose = require('mongoose');
|
|
|
|
const birthdaySchema = new mongoose.Schema({
|
|
id: {
|
|
type: String,
|
|
unique: true,
|
|
},
|
|
day: Number,
|
|
month: Number,
|
|
nickname: {
|
|
type: String,
|
|
default: '',
|
|
},
|
|
});
|
|
|
|
module.exports=mongoose.model('birthdays', birthdaySchema);
|
|
|