普法考试
This commit is contained in:
@@ -4,14 +4,14 @@
|
|||||||
<u-tabs :list="tabs" font-size="32" bg-color="#f3f5f7" inactive-color="#999999"
|
<u-tabs :list="tabs" font-size="32" bg-color="#f3f5f7" inactive-color="#999999"
|
||||||
:active-item-style="{color: '#222222'}" :is-scroll="true" :current="currIndex" @change="(i) => (currIndex = i)"> </u-tabs>
|
:active-item-style="{color: '#222222'}" :is-scroll="true" :current="currIndex" @change="(i) => (currIndex = i)"> </u-tabs>
|
||||||
</div>
|
</div>
|
||||||
<AppOnlineClass ref="OnlineClass" v-show="currIndex == 0"></AppOnlineClass>
|
<OnlineClass ref="OnlineClass" v-show="currIndex == 0"></OnlineClass>
|
||||||
<AppGeneralLawExam ref="GeneralLawExam" v-show="currIndex == 1"></AppGeneralLawExam>
|
<GeneralLawExam ref="GeneralLawExam" @LinkToTest="LinkToTest" v-show="currIndex == 1"></GeneralLawExam>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import AppOnlineClass from './components/AppOnlineClass.vue'
|
import OnlineClass from './components/OnlineClass.vue'
|
||||||
import AppGeneralLawExam from './components/AppGeneralLawExam.vue'
|
import GeneralLawExam from './components/GeneralLawExam.vue'
|
||||||
export default {
|
export default {
|
||||||
name: 'AppLegalLearning',
|
name: 'AppLegalLearning',
|
||||||
appName: '法治学习',
|
appName: '法治学习',
|
||||||
@@ -31,8 +31,8 @@ export default {
|
|||||||
onShow() {
|
onShow() {
|
||||||
},
|
},
|
||||||
components: {
|
components: {
|
||||||
AppOnlineClass,
|
OnlineClass,
|
||||||
AppGeneralLawExam
|
GeneralLawExam
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
currIndex: {
|
currIndex: {
|
||||||
@@ -44,6 +44,11 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
LinkToTest() {
|
||||||
|
uni.navigateTo({url: "./testForm"})
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="AppGeneralLawExam">
|
<div class="GeneralLawExam">
|
||||||
<div class="search_box">
|
<div class="search_box">
|
||||||
<u-search placeholder="请输入需要搜索的考试" bg-color="#FFF" v-model="keyword" :show-action="false"></u-search>
|
<u-search placeholder="请输入需要搜索的考试" bg-color="#FFF" v-model="keyword" :show-action="false"></u-search>
|
||||||
</div>
|
</div>
|
||||||
@@ -21,7 +21,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="grade">98</div>
|
<div class="grade">98</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="card_bottom col_blue" @click="toTest">参加考试</div>
|
<div class="card_bottom col_blue" @click="toTest()">参加考试</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -40,13 +40,10 @@ export default {
|
|||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
getList() {
|
getList() {
|
||||||
console.log('111');
|
console.log('普法考试列表');
|
||||||
},
|
},
|
||||||
toTest() {
|
toTest() {
|
||||||
console.log('tiaozhuan');
|
this.$emit('LinkToTest')
|
||||||
uni.navigateTo({
|
|
||||||
url: './test'
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onReachBottom() {
|
onReachBottom() {
|
||||||
@@ -57,7 +54,7 @@ export default {
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" socped>
|
<style lang="scss" socped>
|
||||||
.AppGeneralLawExam {
|
.GeneralLawExam {
|
||||||
.search_box {
|
.search_box {
|
||||||
margin: 24px 0;
|
margin: 24px 0;
|
||||||
padding: 0 32px;
|
padding: 0 32px;
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="AppOnlineClass">
|
<div class="OnlineClass">
|
||||||
在线课堂
|
在线课堂
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@@ -17,18 +17,18 @@ export default {
|
|||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
getList() {
|
getList() {
|
||||||
console.log('222');
|
console.log('在线课堂列表');
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
// onReachBottom() {
|
onReachBottom() {
|
||||||
// this.current ++;
|
this.current ++;
|
||||||
// this.getList()
|
this.getList()
|
||||||
// },
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" socped>
|
<style lang="scss" socped>
|
||||||
.AppOnlineClass {
|
.OnlineClass {
|
||||||
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
@@ -1,31 +0,0 @@
|
|||||||
<template>
|
|
||||||
<div class="question">
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
export default {
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
|
|
||||||
}
|
|
||||||
},
|
|
||||||
onLoad() {
|
|
||||||
|
|
||||||
},
|
|
||||||
|
|
||||||
methods: {
|
|
||||||
|
|
||||||
},
|
|
||||||
onReachBottom() {
|
|
||||||
|
|
||||||
},
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
|
||||||
.question {
|
|
||||||
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
@@ -1,26 +0,0 @@
|
|||||||
<template>
|
|
||||||
<div class="test">
|
|
||||||
哈哈
|
|
||||||
<!-- <Question></Question> -->
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import Question from "./question.vue";
|
|
||||||
export default {
|
|
||||||
data() {
|
|
||||||
return {
|
|
||||||
|
|
||||||
}
|
|
||||||
},
|
|
||||||
components: {
|
|
||||||
Question
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
|
||||||
.test {
|
|
||||||
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
70
src/mods/conv/AppLegalLearning/testForm.vue
Normal file
70
src/mods/conv/AppLegalLearning/testForm.vue
Normal file
@@ -0,0 +1,70 @@
|
|||||||
|
<template>
|
||||||
|
<div class="testForm">
|
||||||
|
答题
|
||||||
|
<div v-for="(item,index) in questionList" :key="index">
|
||||||
|
<div v-if="activeIndex === index">
|
||||||
|
<div>{{ item.subject }}</div>
|
||||||
|
<div @click="next">下一题</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
activeIndex: 0,
|
||||||
|
questionList: [
|
||||||
|
{
|
||||||
|
index: 0,
|
||||||
|
subject: "第1题",
|
||||||
|
answer: "答案",
|
||||||
|
jiexi: '解析'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
index: 1,
|
||||||
|
subject: "第2题",
|
||||||
|
answer: "答案",
|
||||||
|
jiexi: '解析'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
index: 2,
|
||||||
|
subject: "第3题",
|
||||||
|
answer: "答案",
|
||||||
|
jiexi: '解析'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
index: 3,
|
||||||
|
subject: "第4题",
|
||||||
|
answer: "答案",
|
||||||
|
jiexi: '解析'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
index: 4,
|
||||||
|
subject: "第5题",
|
||||||
|
answer: "答案",
|
||||||
|
jiexi: '解析'
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
getList() {
|
||||||
|
console.log('题目列表');
|
||||||
|
},
|
||||||
|
next() {
|
||||||
|
this.activeIndex ++;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
onReachBottom() {
|
||||||
|
this.current ++;
|
||||||
|
},
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.testForm {
|
||||||
|
|
||||||
|
}
|
||||||
|
</style>
|
||||||
Reference in New Issue
Block a user