parent
232f34a064
commit
4bcb532d2d
|
@ -515,6 +515,19 @@ export default {
|
||||||
},
|
},
|
||||||
permissionRoutes() {
|
permissionRoutes() {
|
||||||
return this.$store.getters.permission_routes
|
return this.$store.getters.permission_routes
|
||||||
|
},
|
||||||
|
keyUp() {
|
||||||
|
if (this.currentTable < 1) {
|
||||||
|
return this.currentTable
|
||||||
|
}
|
||||||
|
return this.currentTable - 1
|
||||||
|
},
|
||||||
|
keyDow() {
|
||||||
|
const maxDown = this.getterDataRecords.length - 1
|
||||||
|
if (maxDown === this.currentTable) {
|
||||||
|
return this.currentTable
|
||||||
|
}
|
||||||
|
return this.currentTable + 1
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
|
@ -548,16 +561,19 @@ export default {
|
||||||
setCurrent(row) {
|
setCurrent(row) {
|
||||||
this.$refs.multipleTable.setCurrentRow(row)
|
this.$refs.multipleTable.setCurrentRow(row)
|
||||||
},
|
},
|
||||||
setCurrentParent(row) {
|
logArrayElements(element, index, array) {
|
||||||
this.$refs.Parent.setCurrentRow(row)
|
if (index === this.currentTable) {
|
||||||
|
this.handleRowClick(this.getterDataRecords[index])
|
||||||
|
return this.setCurrent(this.getterDataRecords[index])
|
||||||
|
}
|
||||||
},
|
},
|
||||||
theAction(event) {
|
theAction(event) {
|
||||||
switch (event.srcKey) {
|
switch (event.srcKey) {
|
||||||
case 'up':
|
case 'up':
|
||||||
this.currentTable = this.currentTable - 1
|
this.currentTable = this.keyUp
|
||||||
break
|
break
|
||||||
case 'down':
|
case 'down':
|
||||||
this.currentTable = this.currentTable + 1
|
this.currentTable = this.keyDow
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
this.handleRowClick(this.getterDataRecords[this.currentTable])
|
this.handleRowClick(this.getterDataRecords[this.currentTable])
|
||||||
|
|
Loading…
Reference in New Issue