| | |
| | | :key="item[labelKey]" |
| | | :index="item[pathKey]"> |
| | | <template slot="title"> |
| | | <i :class="item[iconKey]"></i> |
| | | <i :class="item[iconKey]" style="margin-right: 10px"></i> |
| | | <span slot="title" |
| | | :class="{'el-menu--display':collapse && first}">{{ generateTitle(item) }}</span> |
| | | </template> |
| | |
| | | :class="{'is-active':vaildActive(child)}" |
| | | :index="child[pathKey],cindex" |
| | | @click="open(child)"> |
| | | <i :class="child[iconKey]"></i> |
| | | <i :class="child[iconKey]" style="margin-right: 10px"></i> |
| | | <span slot="title">{{ generateTitle(child) }}</span> |
| | | </el-menu-item> |
| | | <sidebar-item v-else |
| | |
| | | } |
| | | }, |
| | | open(item) { |
| | | const query = { |
| | | ...item.query, |
| | | id:item.id |
| | | } |
| | | if (this.screen <= 1) this.$store.commit("SET_COLLAPSE"); |
| | | if (this.validIsOpen(item)) { |
| | | window.open(item[this.pathKey]); |
| | |
| | | name: item[this.labelKey], |
| | | src: item[this.pathKey] |
| | | }, item.meta), |
| | | query: item.query |
| | | query: query |
| | | }); |
| | | } |
| | | } |