|
@@ -133,6 +133,9 @@
|
|
placeholder="请选择"
|
|
placeholder="请选择"
|
|
style="width: 200px"
|
|
style="width: 200px"
|
|
filterable
|
|
filterable
|
|
|
|
+ @visible-change="
|
|
|
|
+ visible => cardOptionOpened(visible, attachment)
|
|
|
|
+ "
|
|
@change="cardChange(attachment)"
|
|
@change="cardChange(attachment)"
|
|
>
|
|
>
|
|
<el-option
|
|
<el-option
|
|
@@ -496,6 +499,16 @@ export default {
|
|
attachment.cardTitle = card.title;
|
|
attachment.cardTitle = card.title;
|
|
}
|
|
}
|
|
},
|
|
},
|
|
|
|
+ cardOptionOpened(visible, attachment) {
|
|
|
|
+ if (!visible) return;
|
|
|
|
+
|
|
|
|
+ const selectedCardIds = this.paperAttachments.map(item => item.cardId);
|
|
|
|
+ this.cards = this.cards.map(card => {
|
|
|
|
+ card.disabled =
|
|
|
|
+ card.id !== attachment.cardId && selectedCardIds.includes(card.id);
|
|
|
|
+ return card;
|
|
|
|
+ });
|
|
|
|
+ },
|
|
toCreateCard(attachment) {
|
|
toCreateCard(attachment) {
|
|
if (!this.examTask.cardRuleId) {
|
|
if (!this.examTask.cardRuleId) {
|
|
this.$message.error("题卡规则缺失!");
|
|
this.$message.error("题卡规则缺失!");
|
|
@@ -508,8 +521,8 @@ export default {
|
|
schoolName: this.$ls.get("schoolName"),
|
|
schoolName: this.$ls.get("schoolName"),
|
|
makeMethod: "SELF",
|
|
makeMethod: "SELF",
|
|
cardRuleId: this.examTask.cardRuleId,
|
|
cardRuleId: this.examTask.cardRuleId,
|
|
- type: attachment.cardType,
|
|
|
|
- createMethod: attachment.createMethod
|
|
|
|
|
|
+ type: "CUSTOM",
|
|
|
|
+ createMethod: "STANDARD"
|
|
});
|
|
});
|
|
this.$refs.ModifyCard.open();
|
|
this.$refs.ModifyCard.open();
|
|
},
|
|
},
|