|
@@ -3,9 +3,15 @@ const Schema = require('mongoose').Schema;
|
|
const metaPlugin = require('naf-framework-mongoose/lib/model/meta-plugin');
|
|
const metaPlugin = require('naf-framework-mongoose/lib/model/meta-plugin');
|
|
const { Secret } = require('naf-framework-mongoose/lib/model/schema');
|
|
const { Secret } = require('naf-framework-mongoose/lib/model/schema');
|
|
|
|
|
|
|
|
+// 资料路径详情
|
|
|
|
+const urlInfo = new Schema({
|
|
|
|
+ uri: { type: String, required: false, maxLength: 200 }, // 路径
|
|
|
|
+ name: { type: String, required: false, maxLength: 200 }, // 名称
|
|
|
|
+});
|
|
|
|
+
|
|
// 资料信息
|
|
// 资料信息
|
|
const FileInfo = new Schema({
|
|
const FileInfo = new Schema({
|
|
- url: { type: String, required: false, maxLength: 200 }, // 资料地址
|
|
|
|
|
|
+ url: { type: [ urlInfo ], select: true }, // 资料路径
|
|
filename: { type: String, required: false, maxLength: 200 }, // 资料名称
|
|
filename: { type: String, required: false, maxLength: 200 }, // 资料名称
|
|
type: { type: String, required: false, maxLength: 200 }, // 资料类别
|
|
type: { type: String, required: false, maxLength: 200 }, // 资料类别
|
|
});
|
|
});
|