up1
This commit is contained in:
@ -47,8 +47,17 @@
|
||||
<div class="img2_box">
|
||||
<img src="@/assets/image/02.png" alt="" />
|
||||
<div class="search">
|
||||
<el-input v-model="input" placeholder="请输入搜索关键字"></el-input>
|
||||
<el-button type="warning">一站搜</el-button>
|
||||
<el-input
|
||||
v-model.trim="input"
|
||||
placeholder="请输入搜索关键字"
|
||||
></el-input>
|
||||
<el-button type="warning" @click="toSearch">一站搜</el-button>
|
||||
<!-- <router-link
|
||||
target="_blank"
|
||||
:to="{ path: '/search', query: { val: input } }"
|
||||
>
|
||||
<el-button type="warning">一站搜</el-button>
|
||||
</router-link> -->
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -176,6 +185,15 @@ export default {
|
||||
...mapGetters(['avatar'])
|
||||
},
|
||||
methods: {
|
||||
toSearch() {
|
||||
if (!this.input.length) return this.msgError('请输入搜索关键字');
|
||||
this.$router.push({ path: '/search', query: { val: this.input } });
|
||||
// let routerJump = this.$router.resolve({
|
||||
// path: '/search',
|
||||
// query: { val: this.input }
|
||||
// });
|
||||
// window.open(routerJump.href, '_blank');
|
||||
},
|
||||
handlePage() {
|
||||
this.$router.push({ path: '/login' });
|
||||
},
|
||||
|
Reference in New Issue
Block a user