Category.js 680 Bytes
Newer Older
kusang96's avatar
kusang96 committed
1
2
3
4
import mongoose from 'mongoose'

const { Array } = mongoose.Schema.Types

이재연's avatar
0115    
이재연 committed
5
const CategoriesSchema = new mongoose.Schema ({
kusang96's avatar
kusang96 committed
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
    "DRESS": {
        type: Array,
        required: true
    },
    "OUTER": {
        type: Array,
        required: true
    },
    "TOP": {
        type: Array,
        required: true
    },
    "PANTS": {
        type: Array,
        required: true
    },
    "SKIRT": {
        type: Array,
        required: true
    },
    "TRAINING": {
        type: Array,
        required: true
    },
    "SHOES": {
        type: Array,
        required: true
    },
})

이재연's avatar
0115    
이재연 committed
36
export default mongoose.models.Categories || mongoose.model('Categories', CategoriesSchema)