修改兄弟组件传值
This commit is contained in:
@@ -94,10 +94,6 @@
|
||||
export default {
|
||||
name: 'index',
|
||||
props: {
|
||||
searchList: {
|
||||
type: Array,
|
||||
default: []
|
||||
},
|
||||
url: {
|
||||
type: Object,
|
||||
default: {}
|
||||
@@ -111,6 +107,7 @@
|
||||
return {
|
||||
queryParam: {},
|
||||
toggleSearchStatus:false,
|
||||
searchList:[],
|
||||
}
|
||||
},
|
||||
mounted() {
|
||||
|
||||
@@ -111,9 +111,11 @@
|
||||
this.tableAll = event.target.checked
|
||||
this.checkboxList = []
|
||||
if (this.tableAll) {
|
||||
this.jsonBody.forEach(res => {
|
||||
this.checkboxList.push(res.id)
|
||||
})
|
||||
if (this.jsonBody.length > 0){
|
||||
this.jsonBody.forEach(res => {
|
||||
this.checkboxList.push(res.id)
|
||||
})
|
||||
}
|
||||
}
|
||||
},
|
||||
getTableList(search) {
|
||||
@@ -122,7 +124,7 @@
|
||||
}
|
||||
getAction(this.url.tableList, params).then((res) => {
|
||||
if (res.success) {
|
||||
this.jsonBody = res.result
|
||||
this.jsonBody = res.result || []
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user