Commit 8ec8b467 by wangchunyang

配置相关功能开发

parent 29b22942
......@@ -565,7 +565,7 @@ export default {
const api = apiMap[tab]
if (!api) return
this.loading[tab] = true
const payload = Object.assign({}, this.pagers[tab], { params: this.filters[tab] })
const payload = Object.assign({}, this.pagers[tab], this.filters[tab])
api(payload).then(ret => {
if (ret.data && ret.data.errcode === 0) {
const data = ret.data.data || {}
......@@ -604,22 +604,16 @@ export default {
const modal = this.modals[tab]
modal.visible = true
modal.isEdit = false
modal.form = this.getDefaultForm(tab)
this.$nextTick(() => {
if (this.$refs[tab + 'Form']) {
this.$refs[tab + 'Form'].resetFields()
}
modal.form = this.getDefaultForm(tab)
})
},
openEditModal (tab, row) {
const modal = this.modals[tab]
modal.visible = true
modal.isEdit = true
modal.form = Object.assign({}, this.getDefaultForm(tab), row)
this.$nextTick(() => {
if (this.$refs[tab + 'Form']) {
this.$refs[tab + 'Form'].resetFields()
}
modal.form = Object.assign({}, this.getDefaultForm(tab), row)
})
},
getDefaultForm (tab) {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论