提交 2dc09731 authored 作者: lihuihui's avatar lihuihui
...@@ -51,6 +51,7 @@ export default { ...@@ -51,6 +51,7 @@ export default {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
justify-content: space-between; justify-content: space-between;
overflow: hidden;
} }
.course-item-pic { .course-item-pic {
width: 2.4rem; width: 2.4rem;
......
...@@ -46,6 +46,7 @@ export default { ...@@ -46,6 +46,7 @@ export default {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
justify-content: space-between; justify-content: space-between;
overflow: hidden;
} }
.course-item-pic { .course-item-pic {
width: 2.4rem; width: 2.4rem;
......
...@@ -11,7 +11,7 @@ import './assets/rem/rem.js' ...@@ -11,7 +11,7 @@ import './assets/rem/rem.js'
import MetaInfo from 'vue-meta-info' import MetaInfo from 'vue-meta-info'
import modules from './modules' import modules from './modules'
import createBefore from './components/beforeEnter' // import createBefore from './components/beforeEnter'
// vant // vant
import Vant from 'vant' import Vant from 'vant'
...@@ -45,10 +45,11 @@ Vue.prototype.VueEvent = new Vue() ...@@ -45,10 +45,11 @@ Vue.prototype.VueEvent = new Vue()
Vue.prototype.wx = window.wx.miniProgram Vue.prototype.wx = window.wx.miniProgram
/* 创建实例之前,通过导航守卫,处理部分逻辑,如:是否直接进入系统 */ /* 创建实例之前,通过导航守卫,处理部分逻辑,如:是否直接进入系统 */
const before = createBefore() // const before = createBefore()
/* 导航守卫 */ /* 导航守卫 */
router.beforeEach((to, from, next) => { router.beforeEach((to, from, next) => {
before.update(to, from, next) // before.update(to, from, next)
next()
}) })
window.G.$instance_vue = new Vue({ window.G.$instance_vue = new Vue({
store, store,
......
...@@ -59,7 +59,16 @@ export default { ...@@ -59,7 +59,16 @@ export default {
this.showMore = !this.showMore this.showMore = !this.showMore
}, },
viewMore() { viewMore() {
this.$router.push({ name: 'courseTagItem', params: { id: this.data.id } }) if (this.isWeapp) {
wx.miniProgram.navigateTo({
url: `/pages/web/index?src=${window.location.origin}/course/tag/${this.data.id}`
})
} else {
this.$router.push({
name: 'courseTagItem',
params: { id: this.data.id }
})
}
}, },
// 去知识点考试页面 // 去知识点考试页面
toExamPage() { toExamPage() {
......
...@@ -105,6 +105,9 @@ export default { ...@@ -105,6 +105,9 @@ export default {
this.$router.replace({ query: { tab: name, keywords: this.searchValue } }) this.$router.replace({ query: { tab: name, keywords: this.searchValue } })
}, },
onSearch() { onSearch() {
if (!this.searchValue.trim()) {
return
}
this.$router.replace({ this.$router.replace({
query: { tab: this.tabActive, keywords: this.searchValue } query: { tab: this.tabActive, keywords: this.searchValue }
}) })
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论