commit
This commit is contained in:
@@ -0,0 +1,127 @@
|
||||
<!-- 搜索栏 -->
|
||||
<template>
|
||||
<div class="search-group">
|
||||
<el-select
|
||||
v-model="checkState"
|
||||
class="search-group-item"
|
||||
placeholder="请选择"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in jumpPage"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
></el-option>
|
||||
</el-select>
|
||||
|
||||
<div class="search-condition">
|
||||
<el-input
|
||||
@keyup.native.enter="search"
|
||||
v-model="checkContent">
|
||||
type="text"
|
||||
placeholder="请输入关键词"
|
||||
clearable
|
||||
></el-input>
|
||||
<el-button class="primary_button" type="primary" @click="search">搜索</el-button>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
name: 'SearchGroup',
|
||||
components: {},
|
||||
mixins: [],
|
||||
data() {
|
||||
return {
|
||||
// 当前查询状态
|
||||
checkState: 'All',
|
||||
// 查询内容
|
||||
checkContent: '',
|
||||
jumpPage: [
|
||||
{
|
||||
label: '全部',
|
||||
value: 'All'
|
||||
},
|
||||
{
|
||||
label: '国内标准法规',
|
||||
value: 'stand'
|
||||
},
|
||||
{
|
||||
label: '海外标准法规', // value没改
|
||||
value: 'bussstand'
|
||||
},
|
||||
// {
|
||||
// label: '国内外政策',
|
||||
// value: 'laws'
|
||||
// },
|
||||
{
|
||||
label: '企业标准',
|
||||
value: 'enterprise'
|
||||
}
|
||||
],
|
||||
}
|
||||
},
|
||||
computed: {},
|
||||
watch: {},
|
||||
methods: {
|
||||
search() {
|
||||
this.$router.push({
|
||||
name: 'StandardSearch',
|
||||
params: {
|
||||
selectKey: this.checkState,
|
||||
searchValue: this.checkContent || undefined
|
||||
}
|
||||
})
|
||||
},
|
||||
},
|
||||
mounted(){
|
||||
|
||||
},
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.search-group {
|
||||
display: flex;
|
||||
width: 100%;
|
||||
height: 40px;
|
||||
margin-bottom: 10px;
|
||||
.search-group-item {
|
||||
margin-right: 20px;
|
||||
border-radius: 5px;
|
||||
::v-deep {
|
||||
.el-input__inner {
|
||||
width: 18vm;
|
||||
height: 40px;
|
||||
color: #333333;
|
||||
font-size: 16px;
|
||||
border: 0;
|
||||
border-radius: 3px;
|
||||
background-color: #FFFFFF;
|
||||
}
|
||||
}
|
||||
}
|
||||
.search-condition {
|
||||
display: flex;
|
||||
flex: 1;
|
||||
::v-deep {
|
||||
.el-input__inner {
|
||||
height: 40px;
|
||||
font-size: 16px;
|
||||
color: #333333;
|
||||
border: 0;
|
||||
border-radius: 3px;
|
||||
background: #FFFFFF;
|
||||
}
|
||||
}
|
||||
}
|
||||
.primary_button {
|
||||
width: 7.2vw;
|
||||
height: 40px;
|
||||
border: 0;
|
||||
border-radius: 3px;
|
||||
background-color: #5ea9f6;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user