Update compiler and task schema

parent 972d2b44
......@@ -11,6 +11,9 @@ const CompilerSchema = new mongoose.Schema({
type: String,
required: true
},
languageTheme: {
type: String
},
isProject: {
type: Boolean,
required: true
......
......@@ -67,16 +67,26 @@ const TaskSchema = new mongoose.Schema({
error: {type: Boolean, default: true}
},
compilers: {
type: [{
compiler: {
type: Map,
of: {
patternFile: {
type: mongoose.Schema.Types.ObjectId
},
sampleFile: {
type: mongoose.Schema.Types.ObjectId
},
compileFile: {
type: mongoose.Schema.Types.ObjectId
},
arguments: {
type: String,
required: true
},
arguments: {
type: String
compileProjectFileName: {
type: String,
}
}],
default: []
},
default: {}
},
cpuTimeLimit: {
type: Number,
......@@ -86,19 +96,6 @@ const TaskSchema = new mongoose.Schema({
type: String,
default: '64K'
},
compileFile: {
type: mongoose.Schema.Types.ObjectId,
refs: 'fs'
},
compileProjectFileName: {
type: String,
},
patternFile: {
type: mongoose.Schema.Types.ObjectId
},
sampleFile: {
type: mongoose.Schema.Types.ObjectId
},
testingType: {
type: String,
default: defines.TESTER_TYPE.TEXT_COMPARE
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment