Sup_File/models/FileSaveMongo.js
2018-06-05 02:04:54 +02:00

64 lines
1.1 KiB
JavaScript

var mongoose = require('mongoose');
var Schema = mongoose.Schema;
var FileSaveMongoShema = new Schema({
uid: {
type: String,
unique: false
},
fieldname: {
type: String,
unique: false
},
originalname: {
type: String,
unique: false
},
encoding: {
type: String,
unique: false
},
mimetype: {
type: String,
unique: false
},
id: {
type: String,
unique: false
},
filename: {
type: String,
unique: false
},
metadata: {
type: String,
unique: false
},
bucketName: {
type: String,
unique: false
},
chunkSize: {
type: String,
unique: false
},
size: {
type: String,
unique: false
},
md5: {
type: String,
unique: false
},
uploadDate: {
type: String,
unique: false
},
contentType: {
type: String,
unique: false
}
});
module.exports = mongoose.model('FileSaveMongo', FileSaveMongoShema, 'fs.files');