|
|
|
@ -47,19 +47,14 @@ |
|
|
|
|
</div> |
|
|
|
|
<div class="filter"> |
|
|
|
|
<dl v-if="curTab == 1"> |
|
|
|
|
<dt>学科类别</dt> |
|
|
|
|
<dt>学科专业</dt> |
|
|
|
|
<div class="vals"> |
|
|
|
|
<dd :class="{active: categoryId === ''}" |
|
|
|
|
@click="catetoryClick('')">全部</dd> |
|
|
|
|
<dd :class="{active: categoryId === 1}" |
|
|
|
|
style="margin-right: 20px" |
|
|
|
|
@click="catetoryClick(1)">不限</dd> |
|
|
|
|
<dd v-for="(item, i) in category" |
|
|
|
|
:key="i" |
|
|
|
|
:class="{active: categoryId === item.value}" |
|
|
|
|
@click="categoryClick(item, 1)">{{ item.label }}</dd> |
|
|
|
|
|
|
|
|
|
<!-- <div v-for="(item, i) in category" |
|
|
|
|
<div v-for="(item, i) in category" |
|
|
|
|
:key="i" |
|
|
|
|
:class="['category-item', {active: item.disciplineId == categoryId}]"> |
|
|
|
|
<span class="name" |
|
|
|
@ -70,8 +65,8 @@ |
|
|
|
|
:options="item.list" |
|
|
|
|
:props="{ checkStrictly: true }" |
|
|
|
|
placeholder="" |
|
|
|
|
@change="id => categoryChange(id, item, i)"></el-cascader> --> |
|
|
|
|
<!-- </div> --> |
|
|
|
|
@change="id => categoryChange(id, item, i)"></el-cascader> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
</dl> |
|
|
|
|
<dl v-if="curTab == 3"> |
|
|
|
@ -430,14 +425,6 @@ export default { |
|
|
|
|
e.val = [] |
|
|
|
|
}) |
|
|
|
|
}, |
|
|
|
|
categoryClick (item, i) { |
|
|
|
|
this.clearCategory() |
|
|
|
|
item.val = val |
|
|
|
|
this[i === 1 ? 'categoryId' : i === 2 ? 'professionalCategoryId' : 'professionalId'] = item.disciplineId |
|
|
|
|
this.professionalCategoryId = val[0] || '' |
|
|
|
|
this.professionalId = val[1] || '' |
|
|
|
|
this.initData() |
|
|
|
|
}, |
|
|
|
|
categoryChange (val, item, i) { |
|
|
|
|
const name = this.$refs['category' + i][0].getCheckedNodes()[0].pathLabels |
|
|
|
|
console.log("🚀 ~ file: index.vue:431 ~ categoryChange ~ val, item:", val, item, name) |
|
|
|
|