|
|
@@ -1,5 +1,5 @@
|
|
|
<template>
|
|
|
- <div class="kind-category" @mouseleave="hideChildrenLayout()">
|
|
|
+ <div class="kind-category" ref="kindCategory" @mouseleave="hideChildrenLayout()">
|
|
|
<ul class="kind-main list-unstyled">
|
|
|
<li v-for="kind in kindsToShow" class="kind-main-item" :class="{active: kind.id==activeKindId}"
|
|
|
@mouseenter="showChildrenLayout(kind)">
|
|
|
@@ -66,6 +66,15 @@
|
|
|
this.activeKindId = null
|
|
|
}
|
|
|
},
|
|
|
+ watch: {
|
|
|
+ '$route.path': {
|
|
|
+ handler: function (path) {
|
|
|
+ if (path !== '/') {
|
|
|
+ this.$refs.kindCategory.style.display = 'none'
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
// mounted () {
|
|
|
// this.$http.get(`/api/product/kind/0/children_all`)
|
|
|
// .then(response => {
|