我想大声告诉你2017-05-02 09:20:04
If the outermost List can be changed to an array, it can be defined in the following way
const childChildSchema = new mongoose.Schema({
PlayerID: Number,
Msg: String,
Time: Date
});
const childSchema = new mongoose.Schema({
PlayerID: Number,
ReadLast: Date,
List:[childChildSchema]
});
const parentSchema = new mongoose.Schema({
ID: Number,
List: [childSchema]
});