Browse Source

Fix index

master
hewenyang 7 years ago
parent
commit
c9c9fd001c
  1. 2
      models/judge_state.js
  2. 2
      modules/submission.js

2
models/judge_state.js

@ -82,7 +82,7 @@ let model = db.define('judge_state', {
fields: ['task_id'],
},
{
fields: ['is_public', 'id']
fields: ['id', 'is_public', 'type_info', 'type']
}
]
});

2
modules/submission.js

@ -50,7 +50,7 @@ app.get('/submissions', async (req, res) => {
else if (req.query.submitter) where.user_id = -1;
if (!req.query.contest) {
where.type = { $ne: 1 };
where.type = { $eq: 0 };
} else {
const contestId = Number(req.query.contest);
const contest = await Contest.fromID(contestId);

Loading…
Cancel
Save