forked from hangshuo652/aurak
fix: 修复10个TS类型错误 - ForbiddenException导入、sort字段、user.name、question.content、lines类型、status比较
This commit is contained in:
@@ -196,9 +196,9 @@ export class QuestionBankService {
|
||||
if (bank.status === QuestionBankStatus.PUBLISHED) {
|
||||
return bank;
|
||||
}
|
||||
if (bank.status !== QuestionBankStatus.PUBLISHED && bank.status !== QuestionBankStatus.REJECTED) {
|
||||
if (bank.status !== QuestionBankStatus.REJECTED) {
|
||||
throw new ForbiddenException(
|
||||
'Only PUBLISHED or REJECTED status can be re-published',
|
||||
'Only REJECTED status can be re-published',
|
||||
);
|
||||
}
|
||||
bank.status = QuestionBankStatus.PUBLISHED;
|
||||
@@ -424,7 +424,6 @@ export class QuestionBankService {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (selected.length < count) {
|
||||
const remaining = allItems.filter((i) => !usedIds.has(i.id));
|
||||
|
||||
Reference in New Issue
Block a user