This commit is contained in:
2022-08-31 11:03:20 +08:00
commit 069f64ed21
144 changed files with 25876 additions and 0 deletions

53
src/components/NavBar.vue Normal file
View File

@@ -0,0 +1,53 @@
<template>
<header>
<span @click="goBack" class="icon-back"></span>
<span class="fxcol">{{title}}</span>
<div class="icon-home" @click="goHome"></div>
</header>
</template>
<script>
export default {
name: 'NavBar',
props: {
title: String,
path: String,
inner: {
type: Boolean,
default: false
},
inner2: {
type: Boolean,
default: false
}
},
methods: {
goBack () {
if (this.inner) {
this.$router.back()
} else if (this.inner2) {
this.$emit('goIn')
} else {
this.$router.push('/home')
}
},
goHome () {
this.$store.dispatch('setKeepAlive', [])
this.$router.push('/home')
}
}
}
</script>
<style lang="stylus">
@import '~@style/mixin'
.icon-back
flex 0 0 .42rem
height .86rem
_bis('../images/back.png',.42rem)
.icon-home
cursor pointer
flex 0 0 .4rem
height .86rem
_bis('../images/home.png', .4rem)
</style>