no message
This commit is contained in:
parent
ad182388af
commit
4a88628bb7
@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<x-table-select v-model="value" v-bind="item.options" style="width: 100%;">
|
<x-table-select v-model="value" v-bind="item.options" style="width: 100%;">
|
||||||
<template #header="{data, form, submit}">
|
<template #header="{data, form, submit}">
|
||||||
<el-form :inline="true" :model="data" v-if="form && form.length>0">
|
<el-form :inline="true" :model="data" v-if="form && form.length>0" @keyup.enter="submit">
|
||||||
<el-form-item style="margin-bottom:0px;" v-for="(i,index) in form" :key="index">
|
<el-form-item style="margin-bottom:0px;" v-for="(i,index) in form" :key="index">
|
||||||
<el-input v-model="data[i.name]" :placeholder="i.placeholder"></el-input>
|
<el-input v-model="data[i.name]" :placeholder="i.placeholder"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
@ -43,7 +43,6 @@ export default {
|
|||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
loading: false,
|
loading: false,
|
||||||
keyword: null,
|
|
||||||
defaultValue: [],
|
defaultValue: [],
|
||||||
tableData: [],
|
tableData: [],
|
||||||
limit: config.limit,
|
limit: config.limit,
|
||||||
@ -54,7 +53,6 @@ export default {
|
|||||||
value: config.props.value,
|
value: config.props.value,
|
||||||
page: config.request.page,
|
page: config.request.page,
|
||||||
limit: config.request.limit,
|
limit: config.request.limit,
|
||||||
keyword: config.request.keyword,
|
|
||||||
field: config.props.field,
|
field: config.props.field,
|
||||||
},
|
},
|
||||||
formData: {},
|
formData: {},
|
||||||
@ -89,7 +87,6 @@ export default {
|
|||||||
visibleChange(visible) {
|
visibleChange(visible) {
|
||||||
if (visible) {
|
if (visible) {
|
||||||
this.currentPage = 1
|
this.currentPage = 1
|
||||||
this.keyword = null
|
|
||||||
this.formData = {}
|
this.formData = {}
|
||||||
this.getData()
|
this.getData()
|
||||||
} else {
|
} else {
|
||||||
@ -102,7 +99,6 @@ export default {
|
|||||||
var reqData = {
|
var reqData = {
|
||||||
[this.defaultProps.page]: this.currentPage,
|
[this.defaultProps.page]: this.currentPage,
|
||||||
[this.defaultProps.limit]: this.limit,
|
[this.defaultProps.limit]: this.limit,
|
||||||
[this.defaultProps.keyword]: this.keyword
|
|
||||||
}
|
}
|
||||||
Object.assign(reqData, this.params, this.formData)
|
Object.assign(reqData, this.params, this.formData)
|
||||||
var res = await this.$http.get(this.api, reqData, { cacheparameters: 1 });
|
var res = await this.$http.get(this.api, reqData, { cacheparameters: 1 });
|
||||||
@ -135,7 +131,6 @@ export default {
|
|||||||
//插糟表单提交
|
//插糟表单提交
|
||||||
formSubmit() {
|
formSubmit() {
|
||||||
this.currentPage = 1
|
this.currentPage = 1
|
||||||
this.keyword = null
|
|
||||||
this.getData()
|
this.getData()
|
||||||
},
|
},
|
||||||
//分页刷新表格
|
//分页刷新表格
|
||||||
@ -235,12 +230,7 @@ export default {
|
|||||||
findRowByKey(value) {
|
findRowByKey(value) {
|
||||||
return this.tableData.find(item => item[this.defaultProps.value] === value)
|
return this.tableData.find(item => item[this.defaultProps.value] === value)
|
||||||
},
|
},
|
||||||
filterMethod(keyword) {
|
filterMethod() {
|
||||||
if (!keyword) {
|
|
||||||
this.keyword = null;
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
this.keyword = keyword;
|
|
||||||
this.getData()
|
this.getData()
|
||||||
},
|
},
|
||||||
// 触发select隐藏
|
// 触发select隐藏
|
||||||
|
Loading…
Reference in New Issue
Block a user