Commit 9689b99a authored by 黄奎's avatar 黄奎

页面修改

parent 039a1c42
......@@ -271,6 +271,12 @@
},
deep: true
},
questionData: {
handler(newValue) {
this.data = this.questionData;
},
deep: true
},
}
};
......
......@@ -129,6 +129,12 @@
},
deep: true
},
questionData: {
handler(newValue) {
this.data = this.questionData;
},
deep: true
},
}
};
......
......@@ -120,6 +120,12 @@
},
deep: true
},
questionData: {
handler(newValue) {
this.data = this.questionData;
},
deep: true
},
}
};
......
......@@ -83,6 +83,12 @@
},
deep: true
},
questionData: {
handler(newValue) {
this.data = this.questionData;
},
deep: true
},
}
};
......
......@@ -252,6 +252,12 @@
},
deep: true
},
questionData: {
handler(newValue) {
this.data = this.questionData;
},
deep: true
},
}
};
......
......@@ -142,6 +142,12 @@
},
deep: true
},
questionData: {
handler(newValue) {
this.data = this.questionData;
},
deep: true
},
}
};
......
......@@ -46,11 +46,6 @@
</div>
</th>
</tr>
<!-- <tr>
<th colspan="3">
<UeEditor v-model="item.SubTitle" :config="config"></UeEditor>
</th>
</tr> -->
</thead>
<tbody v-if="(commonIndex==index)&&!isShow">
<tr>
......@@ -349,6 +344,12 @@
},
deep: true
},
questionData: {
handler(newValue) {
this.data = this.questionData;
},
deep: true
},
}
};
......
......@@ -11,7 +11,7 @@
<br />
答案
<br />
<UeEditor v-model="setOption.Answer" :config="config"></UeEditor>
<UeEditor v-model="setOption.Answer" :config="config" ref="UE_Answer"></UeEditor>
</div>
</template>
<script>
......@@ -40,7 +40,13 @@
mounted() {
},
watch: {
'setOption'(newVal, oldVal) {
if (newVal != oldVal) {
this.$refs.UE_Answer.reloadNewValue();
}
}
}
};
</script>
......@@ -194,6 +194,12 @@
},
deep: true
},
questionData: {
handler(newValue) {
this.data = this.questionData;
},
deep: true
},
}
};
......
......@@ -253,7 +253,7 @@
<template v-if="!gItem.isShowEdit">{{gIndex+1}}&nbsp;{{gItem.GroupName}}</template>
<template v-else>
<input style="width:160px;margin-right:10px;" v-model="gItem.GroupName" />
<input style="width:40px;" filled v-model="gItem.GSortNum" />
<input style="width:40px;" filled v-model="gItem.GScore" @change="changeGroupScore(gItem)" />
</template>
</strong>
<i class="iconfont icon-edit" title="编辑" style="font-size:18px;margin-right:5px;"
......@@ -269,7 +269,7 @@
<ul class="List-ul" v-if="gItem.DetailsList&&gItem.DetailsList.length>0">
<li class="" style="cursor:pointer;" :class="{'checkUl':dIndex==ComCheckIndex&&gIndex==ComOneIndex}"
v-for="(dItem,dIndex) in gItem.DetailsList" :key="dIndex" @click="ClickItem(dItem,gIndex,dIndex)">
{{dIndex+1}}<span class="exam_DetailList" v-html="dItem.ShowTitle"></span>
({{dIndex+1}}) <span class="exam_DetailList" v-html="dItem.ShowTitle"></span>
<span class="exam_ListSHow">
<i class="iconfont icon-shangyi2" @click.stop="MoveChildItem(gIndex,dIndex,0)"
style="margin-right:5px;" v-if="dIndex!=0"></i>
......@@ -523,6 +523,20 @@
}
},
methods: {
//大类改变分数
changeGroupScore(gItem) {
var subScore = 0;
if (gItem.GScore && gItem.GScore > 0) {
subScore = gItem.GScore;
}
if (gItem.DetailsList && gItem.DetailsList.length > 0) {
var avgScore = Number(subScore / gItem.DetailsList.length).toFixed(2);
gItem.DetailsList.forEach(sItem => {
sItem.Score = avgScore;
})
}
this.calcPaper();
},
//上移下移(IsUp:0上移,1下移)
MoveFatherItem(subIndex, IsUp) {
var currentItem = this.DataObj.GroupList[subIndex];
......@@ -657,6 +671,7 @@
QuestionTypeId: qItem.QuestionTypeId,
QuestionTypeKey: qItem.QuestionTypeKey,
GSortNum: 0,
GScore: 0, //分数
DetailsList: [], //问题列表
});
}
......@@ -774,12 +789,13 @@
},
//点击问题
ClickItem(questionItem, index, index2) {
this.ChooseItem={};
this.ChooseItem = {};
this.ComOneIndex = index;
this.ComCheckIndex = index2;
this.ChooseItem = questionItem;
this.ChooseItem.QuestionContentObj=questionItem.QuestionContentObj;
this.ChooseItem.QuestionContentObj = questionItem.QuestionContentObj;
this.$refs.UE_Title.reloadNewValue();
this.$refs.AnswerParse.reloadNewValue();
this.$forceUpdate();
},
//保存题目
......@@ -795,7 +811,7 @@
position: 'top'
})
this.$router.push({
path: '/exam/examManagement',
path: '/exam/examPaper',
query: {}
});
} else {
......
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