Skip to content
Permalink
Browse files
Update club.js
  • Loading branch information
warangm committed Nov 4, 2022
1 parent 467ceba commit 09ca28a95576b9df80f3f2314491f6dcf8b263be
Showing 1 changed file with 51 additions and 23 deletions.
@@ -1,28 +1,56 @@
const mongoose = require('mongoose');
const addclubSchema=new mongoose.Schema({
name:{
type:String,
required:true
import mongoose from "mongoose";


const ClubSchema = new mongoose.Schema({
name: {
type: String,
required: true,
},
type: {
type: String,
required: true,
},
email:{
type:String,
required:true
des: {
type: String
},
campus: {
type: String,
required: true
},
picture: {
type: [String]
},
photo:{
type:String
roles: {
type:[String]
},
admin: {
type: String,
required: true
},
location:{
type:String,
required:true
tStaff: {
type: Number
},

type:{
type:String,
required:true
rating: {
type: Number,
min: 1,
max:5
},
president_mail:{
type:String,
required:true
}
})
module.exports=mongoose.model('club',addclubSchema)
featured: {
type: Boolean,
default: false
},
events: {
type: [String]
},

register:{
type: [{
id: { type: String },
name: { type: String }
}]
}

});


export default mongoose.model('Club',ClubSchema)

0 comments on commit 09ca28a

Please sign in to comment.