Commit 7ba806a2 authored by 徐俊's avatar 徐俊

xujun

parent a9d7feff
...@@ -44,8 +44,9 @@ export default { ...@@ -44,8 +44,9 @@ export default {
}, },
methods: { methods: {
onSearch(value) { onSearch(value) {
if (value == '') if (value == '') {
return return
}
let pars = { SystemCodeOrName: value } let pars = { SystemCodeOrName: value }
this.$api.parameter.getParameterListBySystemCode(pars).then(({ data = {} }) => { this.$api.parameter.getParameterListBySystemCode(pars).then(({ data = {} }) => {
this.selectArray = [] this.selectArray = []
...@@ -63,7 +64,6 @@ export default { ...@@ -63,7 +64,6 @@ export default {
// return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0; // return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0;
// }, // },
handleChange(value) { handleChange(value) {
console.log(value)
this.$emit("input", value); this.$emit("input", value);
var newArr = this.selectArray.filter(x => x.key == value); var newArr = this.selectArray.filter(x => x.key == value);
if (value && !!newArr && newArr.length > 0) { if (value && !!newArr && newArr.length > 0) {
...@@ -92,8 +92,9 @@ export default { ...@@ -92,8 +92,9 @@ export default {
watch: { watch: {
value: { value: {
handler (value) { handler (value) {
if (!!!value) if (!!!value) {
this.selected = null this.selected = null
}
else else
this.selected = value + '' this.selected = value + ''
this.$emit("input", this.selected) this.$emit("input", this.selected)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment