|
@@ -3,7 +3,7 @@
|
3
|
3
|
<label class="common-screen-label" :style="labelWidth ? 'width:auto;margin-left:20px' : ''"
|
4
|
4
|
v-if="hasLabel">{{ label_name }}</label>
|
5
|
5
|
<el-input :style="width ? 'width:' + width : ''" :placeholder="placeholder || `请输入${label_name}`" v-model="input_keyword" clearable size="small" class="common-input-select" @input="onInput" @change="onChange">
|
6
|
|
- <el-button slot="append" icon="el-icon-search" @click="onChange" />
|
|
6
|
+ <el-button slot="append" icon="el-icon-search" @click="onClickBtn" />
|
7
|
7
|
</el-input>
|
8
|
8
|
</div>
|
9
|
9
|
</template>
|
|
@@ -45,10 +45,17 @@ export default {
|
45
|
45
|
},
|
46
|
46
|
},
|
47
|
47
|
methods: {
|
48
|
|
- onInput() {
|
|
48
|
+ async onInput(val) {
|
|
49
|
+ this.input_keyword = val
|
|
50
|
+ await this.$nextTick()
|
49
|
51
|
this.$emit('onInput', this.input_keyword)
|
50
|
52
|
},
|
51
|
|
- onChange() {
|
|
53
|
+ async onChange(val) {
|
|
54
|
+ this.input_keyword = val
|
|
55
|
+ await this.$nextTick()
|
|
56
|
+ this.$emit('change', this.input_keyword)
|
|
57
|
+ },
|
|
58
|
+ onClickBtn() {
|
52
|
59
|
this.$emit('change', this.input_keyword)
|
53
|
60
|
},
|
54
|
61
|
}
|