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