提交 3a50aada authored 作者: lihuihui's avatar lihuihui

修改bug

上级 84d5b50f
module.exports = { module.exports = {
domain: 'dev.ezijing.com', domain: 'dev.ezijing.com',
url: 'https://x-learning2.ezijing.com/api', url: 'https://x-learning.ezijing.com/api',
webpack: { webpack: {
externals: { externals: {
CKEDITOR: 'window.CKEDITOR', CKEDITOR: 'window.CKEDITOR',
...@@ -33,6 +33,6 @@ module.exports = { ...@@ -33,6 +33,6 @@ module.exports = {
}, },
ProvidePlugin: {}, ProvidePlugin: {},
others: { others: {
loginUrl: 'https://login2.ezijing.com/xlearn/login/index' loginUrl: 'https://login.ezijing.com/xlearn/login/index'
} }
} }
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
<router-link to="/">{{ title }}</router-link> <router-link to="/">{{ title }}</router-link>
</div> </div>
<div class="tool"> <div class="tool">
<app-search-bar :value="$route.query.keywords" @search="handleSearch" /> <!-- <app-search-bar :value="$route.query.keywords" @search="handleSearch" /> -->
<nav class="nav"> <nav class="nav">
<!-- <router-link to="/">首页</router-link> --> <!-- <router-link to="/">首页</router-link> -->
<router-link to="/my">我的</router-link> <router-link to="/my">我的</router-link>
......
...@@ -13,9 +13,9 @@ ...@@ -13,9 +13,9 @@
<el-tab-pane lazy label="按章节学习"> <el-tab-pane lazy label="按章节学习">
<course-chapter :courseId="courseId" :data="detail.chapters"></course-chapter> <course-chapter :courseId="courseId" :data="detail.chapters"></course-chapter>
</el-tab-pane> </el-tab-pane>
<el-tab-pane lazy label="按考点学习"> <!-- <el-tab-pane lazy label="按考点学习">
<course-tag :courseId="courseId" @on-click="onTagClick"></course-tag> <course-tag :courseId="courseId" @on-click="onTagClick"></course-tag>
</el-tab-pane> </el-tab-pane> -->
</el-tabs> </el-tabs>
</div> </div>
</template> </template>
......
...@@ -13,9 +13,9 @@ ...@@ -13,9 +13,9 @@
<el-tab-pane lazy label="按章节练习"> <el-tab-pane lazy label="按章节练习">
<course-chapter :courseId="courseId" :data="detail.chapters"></course-chapter> <course-chapter :courseId="courseId" :data="detail.chapters"></course-chapter>
</el-tab-pane> </el-tab-pane>
<el-tab-pane lazy label="按考点练习"> <!-- <el-tab-pane lazy label="按考点练习">
<course-tag :courseId="courseId" @on-click="onTagClick"></course-tag> <course-tag :courseId="courseId" @on-click="onTagClick"></course-tag>
</el-tab-pane> </el-tab-pane> -->
</el-tabs> </el-tabs>
</div> </div>
</template> </template>
......
...@@ -46,8 +46,7 @@ export default { ...@@ -46,8 +46,7 @@ export default {
}, },
computed: { computed: {
isClass() { isClass() {
return (ids, cId) => { return (id, cId) => {
const id = parseInt(ids)
const findItems = this.data.answers[id] const findItems = this.data.answers[id]
const scoreItems = this.data.score_items const scoreItems = this.data.score_items
? this.data.score_items[id] ? this.data.score_items[id]
......
...@@ -84,8 +84,16 @@ export default { ...@@ -84,8 +84,16 @@ export default {
.getExamQuestion(param) .getExamQuestion(param)
.then(response => { .then(response => {
const data = JSON.parse(response.data) const data = JSON.parse(response.data)
let numCount = 0
for (const item in data.sheet.score_items) {
for (const cItem in data.sheet.score_items[item]) {
if (data.sheet.score_items[item][cItem].is_right) {
numCount++
}
}
}
this.accuracy = parseInt(data.sheet.score) this.accuracy = parseInt(data.sheet.score)
this.accuracText = parseInt(data.sheet.score / data.sheet.questions.total_question_count * 100) this.accuracText = parseInt(numCount / data.sheet.questions.total_question_count * 100)
this.data = data this.data = data
this.accuracScore = parseInt(data.sheet.questions.total_score) this.accuracScore = parseInt(data.sheet.questions.total_score)
}) })
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论