Dixsie Wolmers | b53e086 | 2020-09-08 14:13:38 -0500 | [diff] [blame] | 1 | const TableRowExpandMixin = { |
| 2 | data() { |
| 3 | return { |
Derick Montague | 602e98a | 2020-10-21 16:20:00 -0500 | [diff] [blame] | 4 | expandRowLabel: this.$t('global.table.expandTableRow'), |
Dixsie Wolmers | b53e086 | 2020-09-08 14:13:38 -0500 | [diff] [blame] | 5 | }; |
| 6 | }, |
| 7 | methods: { |
| 8 | toggleRowDetails(row) { |
| 9 | row.toggleDetails(); |
| 10 | row.detailsShowing |
| 11 | ? (this.expandRowLabel = this.$t('global.table.expandTableRow')) |
| 12 | : (this.expandRowLabel = this.$t('global.table.collapseTableRow')); |
Derick Montague | 602e98a | 2020-10-21 16:20:00 -0500 | [diff] [blame] | 13 | }, |
| 14 | }, |
Dixsie Wolmers | b53e086 | 2020-09-08 14:13:38 -0500 | [diff] [blame] | 15 | }; |
| 16 | |
| 17 | export default TableRowExpandMixin; |