...
|
...
|
@@ -2,7 +2,7 @@ |
|
|
<div class="filter-box">
|
|
|
<div class="filter" :class="{ 'filter-open': isVisible}">
|
|
|
<div class="filter-actions">
|
|
|
<a href="javascript:;" class="filter-action" @click="clearVals">清空</a>
|
|
|
<button class="button-ghost filter-action" @click="clearVals">清空</button>
|
|
|
<button class="button button-small filter-action" @click="okAction">确定</button>
|
|
|
</div>
|
|
|
<div class="filter-params">
|
...
|
...
|
@@ -62,7 +62,7 @@ |
|
|
},
|
|
|
|
|
|
okAction: function() {
|
|
|
this.$set('selected', Object.assign({}, this.selected,this.params));
|
|
|
this.$set('selected', Object.assign({}, this.selected, this.params));
|
|
|
bus.$emit('filter.change', {
|
|
|
val: this.selected,
|
|
|
ref: this._uid
|
...
|
...
|
@@ -82,11 +82,11 @@ |
|
|
this.$set(`params.${this.subType}`, item);
|
|
|
},
|
|
|
|
|
|
showLabel: function(key){
|
|
|
showLabel: function(key) {
|
|
|
const newSelected = this.params[key];
|
|
|
const oldSelected = this.selected[key];
|
|
|
|
|
|
if(newSelected) {
|
|
|
if (newSelected) {
|
|
|
return newSelected.name || '';
|
|
|
} else {
|
|
|
return oldSelected && oldSelected.name || '';
|
...
|
...
|
|