vxe-table 3.21.8 → 3.21.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/locale/lang/ar-EG.js +9 -9
- package/es/locale/lang/de-DE.js +8 -8
- package/es/locale/lang/en-US.js +8 -8
- package/es/locale/lang/es-ES.js +10 -10
- package/es/locale/lang/fr-FR.js +10 -10
- package/es/locale/lang/hu-HU.js +9 -9
- package/es/locale/lang/hy-AM.js +1 -1
- package/es/locale/lang/id-ID.js +10 -10
- package/es/locale/lang/it-IT.js +10 -10
- package/es/locale/lang/ja-JP.js +10 -10
- package/es/locale/lang/ko-KR.js +9 -9
- package/es/locale/lang/ms-MY.js +10 -10
- package/es/locale/lang/nb-NO.js +9 -9
- package/es/locale/lang/pt-BR.js +10 -10
- package/es/locale/lang/ru-RU.js +10 -10
- package/es/locale/lang/th-TH.js +9 -9
- package/es/locale/lang/ug-CN.js +9 -9
- package/es/locale/lang/uk-UA.js +10 -10
- package/es/locale/lang/uz-UZ.js +10 -10
- package/es/locale/lang/vi-VN.js +10 -10
- package/es/style.css +1 -1
- package/es/table/render/index.js +166 -24
- package/es/table/src/body.js +13 -13
- package/es/table/src/methods.js +53 -0
- package/es/table/src/util.js +1 -0
- package/es/ui/index.js +1 -1
- package/es/ui/src/log.js +1 -1
- package/lib/index.umd.js +290 -42
- package/lib/index.umd.min.js +1 -1
- package/lib/locale/lang/ar-EG.js +9 -9
- package/lib/locale/lang/ar-EG.min.js +1 -1
- package/lib/locale/lang/ar-EG.umd.js +9 -9
- package/lib/locale/lang/de-DE.js +8 -8
- package/lib/locale/lang/de-DE.min.js +1 -1
- package/lib/locale/lang/de-DE.umd.js +8 -8
- package/lib/locale/lang/en-US.js +8 -8
- package/lib/locale/lang/en-US.min.js +1 -1
- package/lib/locale/lang/en-US.umd.js +8 -8
- package/lib/locale/lang/es-ES.js +10 -10
- package/lib/locale/lang/es-ES.min.js +1 -1
- package/lib/locale/lang/es-ES.umd.js +10 -10
- package/lib/locale/lang/fr-FR.js +10 -10
- package/lib/locale/lang/fr-FR.min.js +1 -1
- package/lib/locale/lang/fr-FR.umd.js +10 -10
- package/lib/locale/lang/hu-HU.js +9 -9
- package/lib/locale/lang/hu-HU.min.js +1 -1
- package/lib/locale/lang/hu-HU.umd.js +9 -9
- package/lib/locale/lang/hy-AM.js +1 -1
- package/lib/locale/lang/hy-AM.min.js +1 -1
- package/lib/locale/lang/hy-AM.umd.js +1 -1
- package/lib/locale/lang/id-ID.js +10 -10
- package/lib/locale/lang/id-ID.min.js +1 -1
- package/lib/locale/lang/id-ID.umd.js +10 -10
- package/lib/locale/lang/it-IT.js +10 -10
- package/lib/locale/lang/it-IT.min.js +1 -1
- package/lib/locale/lang/it-IT.umd.js +10 -10
- package/lib/locale/lang/ja-JP.js +10 -10
- package/lib/locale/lang/ja-JP.min.js +1 -1
- package/lib/locale/lang/ja-JP.umd.js +10 -10
- package/lib/locale/lang/ko-KR.js +9 -9
- package/lib/locale/lang/ko-KR.min.js +1 -1
- package/lib/locale/lang/ko-KR.umd.js +9 -9
- package/lib/locale/lang/ms-MY.js +10 -10
- package/lib/locale/lang/ms-MY.min.js +1 -1
- package/lib/locale/lang/ms-MY.umd.js +10 -10
- package/lib/locale/lang/nb-NO.js +9 -9
- package/lib/locale/lang/nb-NO.min.js +1 -1
- package/lib/locale/lang/nb-NO.umd.js +9 -9
- package/lib/locale/lang/pt-BR.js +10 -10
- package/lib/locale/lang/pt-BR.min.js +1 -1
- package/lib/locale/lang/pt-BR.umd.js +10 -10
- package/lib/locale/lang/ru-RU.js +10 -10
- package/lib/locale/lang/ru-RU.min.js +1 -1
- package/lib/locale/lang/ru-RU.umd.js +10 -10
- package/lib/locale/lang/th-TH.js +9 -9
- package/lib/locale/lang/th-TH.min.js +1 -1
- package/lib/locale/lang/th-TH.umd.js +9 -9
- package/lib/locale/lang/ug-CN.js +9 -9
- package/lib/locale/lang/ug-CN.min.js +1 -1
- package/lib/locale/lang/ug-CN.umd.js +9 -9
- package/lib/locale/lang/uk-UA.js +10 -10
- package/lib/locale/lang/uk-UA.min.js +1 -1
- package/lib/locale/lang/uk-UA.umd.js +10 -10
- package/lib/locale/lang/uz-UZ.js +10 -10
- package/lib/locale/lang/uz-UZ.min.js +1 -1
- package/lib/locale/lang/uz-UZ.umd.js +10 -10
- package/lib/locale/lang/vi-VN.js +10 -10
- package/lib/locale/lang/vi-VN.min.js +1 -1
- package/lib/locale/lang/vi-VN.umd.js +10 -10
- package/lib/style.css +1 -1
- package/lib/table/render/index.js +272 -25
- package/lib/table/render/index.min.js +1 -1
- package/lib/table/src/body.js +13 -13
- package/lib/table/src/body.min.js +1 -1
- package/lib/table/src/methods.js +2 -2
- package/lib/table/src/methods.min.js +1 -1
- package/lib/table/src/util.js +1 -0
- package/lib/table/src/util.min.js +1 -1
- package/lib/ui/index.js +1 -1
- package/lib/ui/index.min.js +1 -1
- package/lib/ui/src/log.js +1 -1
- package/lib/ui/src/log.min.js +1 -1
- package/package.json +2 -2
- package/packages/locale/lang/ar-EG.ts +9 -9
- package/packages/locale/lang/de-DE.ts +8 -8
- package/packages/locale/lang/en-US.ts +8 -8
- package/packages/locale/lang/es-ES.ts +10 -10
- package/packages/locale/lang/fr-FR.ts +10 -10
- package/packages/locale/lang/hu-HU.ts +9 -9
- package/packages/locale/lang/hy-AM.ts +1 -1
- package/packages/locale/lang/id-ID.ts +10 -10
- package/packages/locale/lang/it-IT.ts +10 -10
- package/packages/locale/lang/ja-JP.ts +10 -10
- package/packages/locale/lang/ko-KR.ts +9 -9
- package/packages/locale/lang/ms-MY.ts +10 -10
- package/packages/locale/lang/nb-NO.ts +9 -9
- package/packages/locale/lang/pt-BR.ts +10 -10
- package/packages/locale/lang/ru-RU.ts +10 -10
- package/packages/locale/lang/th-TH.ts +9 -9
- package/packages/locale/lang/ug-CN.ts +9 -9
- package/packages/locale/lang/uk-UA.ts +10 -10
- package/packages/locale/lang/uz-UZ.ts +10 -10
- package/packages/locale/lang/vi-VN.ts +10 -10
- package/packages/table/render/index.ts +166 -24
- package/packages/table/src/body.ts +15 -15
- package/packages/table/src/methods.ts +56 -0
- package/packages/table/src/util.ts +2 -0
- /package/es/{iconfont.1780726754772.ttf → iconfont.1780911698543.ttf} +0 -0
- /package/es/{iconfont.1780726754772.woff → iconfont.1780911698543.woff} +0 -0
- /package/es/{iconfont.1780726754772.woff2 → iconfont.1780911698543.woff2} +0 -0
- /package/lib/{iconfont.1780726754772.ttf → iconfont.1780911698543.ttf} +0 -0
- /package/lib/{iconfont.1780726754772.woff → iconfont.1780911698543.woff} +0 -0
- /package/lib/{iconfont.1780726754772.woff2 → iconfont.1780911698543.woff2} +0 -0
|
@@ -64,7 +64,7 @@ export default {
|
|
|
64
64
|
table: {
|
|
65
65
|
emptyText: 'Ainda não há dados',
|
|
66
66
|
allTitle: 'Selecione tudo/Cancelar',
|
|
67
|
-
seqTitle: 'Número
|
|
67
|
+
seqTitle: 'Número',
|
|
68
68
|
actionTitle: 'operar',
|
|
69
69
|
confirmFilter: 'filtro',
|
|
70
70
|
resetFilter: 'Reiniciar',
|
|
@@ -167,14 +167,14 @@ export default {
|
|
|
167
167
|
setting: {
|
|
168
168
|
colSort: 'Organizar',
|
|
169
169
|
sortHelpTip: '点击图标开始拖动',
|
|
170
|
-
colTitle: '
|
|
171
|
-
colResizable: '
|
|
172
|
-
colVisible: '
|
|
173
|
-
colFixed: '
|
|
174
|
-
colFixedMax: '
|
|
175
|
-
fixedLeft: '
|
|
176
|
-
fixedUnset: '
|
|
177
|
-
fixedRight: '
|
|
170
|
+
colTitle: 'Title',
|
|
171
|
+
colResizable: 'Width (pixels)',
|
|
172
|
+
colVisible: 'Visible',
|
|
173
|
+
colFixed: 'Freeze',
|
|
174
|
+
colFixedMax: 'Freeze (up to {0} columns)',
|
|
175
|
+
fixedLeft: 'Left',
|
|
176
|
+
fixedUnset: 'Not set',
|
|
177
|
+
fixedRight: 'Right',
|
|
178
178
|
moveUp: '上移',
|
|
179
179
|
moveDn: '下移',
|
|
180
180
|
putTop: '置顶',
|
|
@@ -508,7 +508,7 @@ export default {
|
|
|
508
508
|
fontBold: 'Audacioso'
|
|
509
509
|
},
|
|
510
510
|
subtableProp: {
|
|
511
|
-
seqTitle: 'Número
|
|
511
|
+
seqTitle: 'Número',
|
|
512
512
|
showSeq: 'Mostre número de série',
|
|
513
513
|
showCheckbox: 'Várias opções são permitidas',
|
|
514
514
|
errSubDrag: 'O subtable não suporta esse controle, use outros controles',
|
|
@@ -64,7 +64,7 @@ export default {
|
|
|
64
64
|
table: {
|
|
65
65
|
emptyText: 'Нет данных пока',
|
|
66
66
|
allTitle: 'Выберите все/отменить',
|
|
67
|
-
seqTitle: '
|
|
67
|
+
seqTitle: '#',
|
|
68
68
|
actionTitle: 'работать',
|
|
69
69
|
confirmFilter: 'фильтр',
|
|
70
70
|
resetFilter: 'Перезагрузить',
|
|
@@ -167,14 +167,14 @@ export default {
|
|
|
167
167
|
setting: {
|
|
168
168
|
colSort: 'Сортировка',
|
|
169
169
|
sortHelpTip: '点击图标开始拖动',
|
|
170
|
-
colTitle: '
|
|
171
|
-
colResizable: '
|
|
172
|
-
colVisible: '
|
|
173
|
-
colFixed: '
|
|
174
|
-
colFixedMax: '
|
|
175
|
-
fixedLeft: '
|
|
176
|
-
fixedUnset: '
|
|
177
|
-
fixedRight: '
|
|
170
|
+
colTitle: 'Title',
|
|
171
|
+
colResizable: 'Width (pixels)',
|
|
172
|
+
colVisible: 'Visible',
|
|
173
|
+
colFixed: 'Freeze',
|
|
174
|
+
colFixedMax: 'Freeze (up to {0} columns)',
|
|
175
|
+
fixedLeft: 'Left',
|
|
176
|
+
fixedUnset: 'Not set',
|
|
177
|
+
fixedRight: 'Right',
|
|
178
178
|
moveUp: '上移',
|
|
179
179
|
moveDn: '下移',
|
|
180
180
|
putTop: '置顶',
|
|
@@ -508,7 +508,7 @@ export default {
|
|
|
508
508
|
fontBold: 'Смелый'
|
|
509
509
|
},
|
|
510
510
|
subtableProp: {
|
|
511
|
-
seqTitle: 'Серийный
|
|
511
|
+
seqTitle: 'Серийный',
|
|
512
512
|
showSeq: 'Показать серийный номер',
|
|
513
513
|
showCheckbox: 'Разрешено несколько вариантов',
|
|
514
514
|
errSubDrag: 'Подтабл не поддерживает это управление, используйте другие элементы управления',
|
|
@@ -64,7 +64,7 @@ export default {
|
|
|
64
64
|
table: {
|
|
65
65
|
emptyText: 'ยังไม่มีข้อมูล',
|
|
66
66
|
allTitle: 'เลือกทั้งหมด/ยกเลิก',
|
|
67
|
-
seqTitle: '
|
|
67
|
+
seqTitle: '#',
|
|
68
68
|
actionTitle: 'ดำเนินงาน',
|
|
69
69
|
confirmFilter: 'กรอง',
|
|
70
70
|
resetFilter: 'รีเซ็ต',
|
|
@@ -167,14 +167,14 @@ export default {
|
|
|
167
167
|
setting: {
|
|
168
168
|
colSort: 'เรียงลำดับ',
|
|
169
169
|
sortHelpTip: '点击图标开始拖动',
|
|
170
|
-
colTitle: '
|
|
171
|
-
colResizable: '
|
|
172
|
-
colVisible: '
|
|
173
|
-
colFixed: '
|
|
174
|
-
colFixedMax: '
|
|
175
|
-
fixedLeft: '
|
|
176
|
-
fixedUnset: '
|
|
177
|
-
fixedRight: '
|
|
170
|
+
colTitle: 'Title',
|
|
171
|
+
colResizable: 'Width (pixels)',
|
|
172
|
+
colVisible: 'Visible',
|
|
173
|
+
colFixed: 'Freeze',
|
|
174
|
+
colFixedMax: 'Freeze (up to {0} columns)',
|
|
175
|
+
fixedLeft: 'Left',
|
|
176
|
+
fixedUnset: 'Not set',
|
|
177
|
+
fixedRight: 'Right',
|
|
178
178
|
moveUp: '上移',
|
|
179
179
|
moveDn: '下移',
|
|
180
180
|
putTop: '置顶',
|
|
@@ -64,7 +64,7 @@ export default {
|
|
|
64
64
|
table: {
|
|
65
65
|
emptyText: 'ھازىرچە ئۇچۇر يوق',
|
|
66
66
|
allTitle: 'ھەممىنى تاللاش/قالدۇرۇش',
|
|
67
|
-
seqTitle: '
|
|
67
|
+
seqTitle: '#',
|
|
68
68
|
actionTitle: 'مەشخۇلات',
|
|
69
69
|
confirmFilter: 'تاسقاش',
|
|
70
70
|
resetFilter: 'ئەسلىگە كەلتۈرۈش',
|
|
@@ -167,14 +167,14 @@ export default {
|
|
|
167
167
|
setting: {
|
|
168
168
|
colSort: 'تەرتىپلەش',
|
|
169
169
|
sortHelpTip: '点击图标开始拖动',
|
|
170
|
-
colTitle: '
|
|
171
|
-
colResizable: '
|
|
172
|
-
colVisible: '
|
|
173
|
-
colFixed: '
|
|
174
|
-
colFixedMax: '
|
|
175
|
-
fixedLeft: '
|
|
176
|
-
fixedUnset: '
|
|
177
|
-
fixedRight: '
|
|
170
|
+
colTitle: 'Title',
|
|
171
|
+
colResizable: 'Width (pixels)',
|
|
172
|
+
colVisible: 'Visible',
|
|
173
|
+
colFixed: 'Freeze',
|
|
174
|
+
colFixedMax: 'Freeze (up to {0} columns)',
|
|
175
|
+
fixedLeft: 'Left',
|
|
176
|
+
fixedUnset: 'Not set',
|
|
177
|
+
fixedRight: 'Right',
|
|
178
178
|
moveUp: '上移',
|
|
179
179
|
moveDn: '下移',
|
|
180
180
|
putTop: '置顶',
|
|
@@ -64,7 +64,7 @@ export default {
|
|
|
64
64
|
table: {
|
|
65
65
|
emptyText: 'Ще немає даних',
|
|
66
66
|
allTitle: 'Виберіть усі/Скасувати',
|
|
67
|
-
seqTitle: '
|
|
67
|
+
seqTitle: '#',
|
|
68
68
|
actionTitle: 'діяти',
|
|
69
69
|
confirmFilter: 'фільтрувати',
|
|
70
70
|
resetFilter: 'Скинути',
|
|
@@ -167,14 +167,14 @@ export default {
|
|
|
167
167
|
setting: {
|
|
168
168
|
colSort: 'Сортувати',
|
|
169
169
|
sortHelpTip: '点击图标开始拖动',
|
|
170
|
-
colTitle: '
|
|
171
|
-
colResizable: '
|
|
172
|
-
colVisible: '
|
|
173
|
-
colFixed: '
|
|
174
|
-
colFixedMax: '
|
|
175
|
-
fixedLeft: '
|
|
176
|
-
fixedUnset: '
|
|
177
|
-
fixedRight: '
|
|
170
|
+
colTitle: 'Title',
|
|
171
|
+
colResizable: 'Width (pixels)',
|
|
172
|
+
colVisible: 'Visible',
|
|
173
|
+
colFixed: 'Freeze',
|
|
174
|
+
colFixedMax: 'Freeze (up to {0} columns)',
|
|
175
|
+
fixedLeft: 'Left',
|
|
176
|
+
fixedUnset: 'Not set',
|
|
177
|
+
fixedRight: 'Right',
|
|
178
178
|
moveUp: '上移',
|
|
179
179
|
moveDn: '下移',
|
|
180
180
|
putTop: '置顶',
|
|
@@ -508,7 +508,7 @@ export default {
|
|
|
508
508
|
fontBold: 'Сміливий'
|
|
509
509
|
},
|
|
510
510
|
subtableProp: {
|
|
511
|
-
seqTitle: 'Серійний
|
|
511
|
+
seqTitle: 'Серійний',
|
|
512
512
|
showSeq: 'Покажіть серійний номер',
|
|
513
513
|
showCheckbox: 'Дозволено кілька варіантів',
|
|
514
514
|
errSubDrag: 'Підкладка не підтримує цей контроль, будь ласка, використовуйте інші елементи управління',
|
|
@@ -64,7 +64,7 @@ export default {
|
|
|
64
64
|
table: {
|
|
65
65
|
emptyText: "Hali ma'lumot yo'q",
|
|
66
66
|
allTitle: 'Hamma / Bekor qilish-ni tanlang',
|
|
67
|
-
seqTitle: '
|
|
67
|
+
seqTitle: '#',
|
|
68
68
|
actionTitle: 'ishlamoq',
|
|
69
69
|
confirmFilter: 'filtrlamoq',
|
|
70
70
|
resetFilter: "Qayta o'rnatmoq",
|
|
@@ -167,14 +167,14 @@ export default {
|
|
|
167
167
|
setting: {
|
|
168
168
|
colSort: 'Tartib',
|
|
169
169
|
sortHelpTip: '点击图标开始拖动',
|
|
170
|
-
colTitle: '
|
|
171
|
-
colResizable: '
|
|
172
|
-
colVisible:
|
|
173
|
-
colFixed: '
|
|
174
|
-
colFixedMax: '
|
|
175
|
-
fixedLeft: '
|
|
176
|
-
fixedUnset:
|
|
177
|
-
fixedRight:
|
|
170
|
+
colTitle: 'Title',
|
|
171
|
+
colResizable: 'Width (pixels)',
|
|
172
|
+
colVisible: 'Visible',
|
|
173
|
+
colFixed: 'Freeze',
|
|
174
|
+
colFixedMax: 'Freeze (up to {0} columns)',
|
|
175
|
+
fixedLeft: 'Left',
|
|
176
|
+
fixedUnset: 'Not set',
|
|
177
|
+
fixedRight: 'Right',
|
|
178
178
|
moveUp: '上移',
|
|
179
179
|
moveDn: '下移',
|
|
180
180
|
putTop: '置顶',
|
|
@@ -508,7 +508,7 @@ export default {
|
|
|
508
508
|
fontBold: 'Jasur'
|
|
509
509
|
},
|
|
510
510
|
subtableProp: {
|
|
511
|
-
seqTitle: '
|
|
511
|
+
seqTitle: '序号',
|
|
512
512
|
showSeq: "Seriya raqamini ko'rsating",
|
|
513
513
|
showCheckbox: 'Bir nechta tanlovga ruxsat beriladi',
|
|
514
514
|
errSubDrag: "So'rg'lantiriladigan bu nazoratni qo'llab-quvvatlamaydi, iltimos, boshqa boshqaruvlardan foydalaning",
|
|
@@ -64,7 +64,7 @@ export default {
|
|
|
64
64
|
table: {
|
|
65
65
|
emptyText: 'Chưa có dữ liệu',
|
|
66
66
|
allTitle: 'Chọn tất cả/Hủy',
|
|
67
|
-
seqTitle: 'Số
|
|
67
|
+
seqTitle: 'Số',
|
|
68
68
|
actionTitle: 'vận hành',
|
|
69
69
|
confirmFilter: 'lọc',
|
|
70
70
|
resetFilter: 'Cài lại',
|
|
@@ -167,14 +167,14 @@ export default {
|
|
|
167
167
|
setting: {
|
|
168
168
|
colSort: 'Loại',
|
|
169
169
|
sortHelpTip: '点击图标开始拖动',
|
|
170
|
-
colTitle: 'Tiêu đề
|
|
171
|
-
colResizable: '
|
|
172
|
-
colVisible: '
|
|
173
|
-
colFixed: '
|
|
174
|
-
colFixedMax: '
|
|
175
|
-
fixedLeft: '
|
|
176
|
-
fixedUnset: 'Không
|
|
177
|
-
fixedRight: '
|
|
170
|
+
colTitle: 'Tiêu đề',
|
|
171
|
+
colResizable: 'Width (pixels)',
|
|
172
|
+
colVisible: 'Chiều rộng (pixels)',
|
|
173
|
+
colFixed: 'Sử dụn',
|
|
174
|
+
colFixedMax: 'Sử dụng (lên đến {0})',
|
|
175
|
+
fixedLeft: 'Trái',
|
|
176
|
+
fixedUnset: 'Không',
|
|
177
|
+
fixedRight: 'Đúng',
|
|
178
178
|
moveUp: '上移',
|
|
179
179
|
moveDn: '下移',
|
|
180
180
|
putTop: '置顶',
|
|
@@ -508,7 +508,7 @@ export default {
|
|
|
508
508
|
fontBold: 'In đậm'
|
|
509
509
|
},
|
|
510
510
|
subtableProp: {
|
|
511
|
-
seqTitle: 'Số
|
|
511
|
+
seqTitle: 'Số',
|
|
512
512
|
showSeq: 'Hiển thị số sê -ri',
|
|
513
513
|
showCheckbox: 'Nhiều lựa chọn được cho phép',
|
|
514
514
|
errSubDrag: 'Subtable không hỗ trợ điều khiển này, vui lòng sử dụng các điều khiển khác',
|
|
@@ -908,7 +908,24 @@ renderer.mixin({
|
|
|
908
908
|
renderTableEdit: nativeSelectEditRender,
|
|
909
909
|
renderTableDefault: nativeSelectEditRender,
|
|
910
910
|
renderTableCell (h, renderOpts, params) {
|
|
911
|
-
|
|
911
|
+
const { options, optionGroups } = renderOpts
|
|
912
|
+
const { $table, row, column } = params
|
|
913
|
+
const opSize = options ? options.length : null
|
|
914
|
+
const ogSize = optionGroups ? optionGroups.length : null
|
|
915
|
+
const { cellResult } = $table.effectCellData(row, column, {
|
|
916
|
+
key: 'render_table_cell',
|
|
917
|
+
isChanged ({ oldValue, cellValue }) {
|
|
918
|
+
return oldValue && oldValue[0] === cellValue && oldValue[1] === opSize && oldValue[2] === ogSize
|
|
919
|
+
},
|
|
920
|
+
setValue ({ cellValue }) {
|
|
921
|
+
return [cellValue, opSize, ogSize]
|
|
922
|
+
},
|
|
923
|
+
getResult ({ cellValue }) {
|
|
924
|
+
return handleSelectCellValue(cellValue, renderOpts)
|
|
925
|
+
}
|
|
926
|
+
})
|
|
927
|
+
// const cellResult = getSelectCellValue(renderOpts, params)
|
|
928
|
+
return getCellLabelVNs(h, renderOpts, params, cellResult)
|
|
912
929
|
},
|
|
913
930
|
renderTableFilter (h, renderOpts, params) {
|
|
914
931
|
const { column } = params
|
|
@@ -1023,15 +1040,20 @@ renderer.mixin({
|
|
|
1023
1040
|
tableAutoFocus: 'input',
|
|
1024
1041
|
renderTableEdit: defaultEditRender,
|
|
1025
1042
|
renderTableCell (h, renderOpts, params) {
|
|
1026
|
-
const
|
|
1027
|
-
const { row, column } = params
|
|
1028
|
-
|
|
1029
|
-
|
|
1030
|
-
|
|
1031
|
-
|
|
1043
|
+
const props = renderOpts.props || {}
|
|
1044
|
+
const { $table, row, column } = params
|
|
1045
|
+
const { cellResult } = $table.effectCellData(row, column, {
|
|
1046
|
+
key: 'render_table_cell',
|
|
1047
|
+
getResult ({ cellValue }) {
|
|
1048
|
+
if (cellValue) {
|
|
1049
|
+
if (props.type !== 'time') {
|
|
1050
|
+
return getLabelFormatDate(cellValue, props)
|
|
1051
|
+
}
|
|
1052
|
+
}
|
|
1053
|
+
return cellValue
|
|
1032
1054
|
}
|
|
1033
|
-
}
|
|
1034
|
-
return getCellLabelVNs(h, renderOpts, params,
|
|
1055
|
+
})
|
|
1056
|
+
return getCellLabelVNs(h, renderOpts, params, cellResult)
|
|
1035
1057
|
},
|
|
1036
1058
|
tableCellFormatter: handleFormatDatePicker,
|
|
1037
1059
|
renderTableDefault: defaultEditRender,
|
|
@@ -1082,6 +1104,40 @@ renderer.mixin({
|
|
|
1082
1104
|
})
|
|
1083
1105
|
]
|
|
1084
1106
|
},
|
|
1107
|
+
renderTableDefault (h, renderOpts, params) {
|
|
1108
|
+
const { startField, endField } = renderOpts
|
|
1109
|
+
const { row, column } = params
|
|
1110
|
+
const { model } = column
|
|
1111
|
+
const cellValue = getCellValue(row, column)
|
|
1112
|
+
const seProps: Record<string, any> = {}
|
|
1113
|
+
const seOs: Record<string, any> = {}
|
|
1114
|
+
if (startField && endField) {
|
|
1115
|
+
seProps.startValue = XEUtils.get(row, startField)
|
|
1116
|
+
seProps.endValue = XEUtils.get(row, endField)
|
|
1117
|
+
seOs['update:startValue'] = (value: any) => {
|
|
1118
|
+
if (startField) {
|
|
1119
|
+
XEUtils.set(row, startField, value)
|
|
1120
|
+
}
|
|
1121
|
+
}
|
|
1122
|
+
seOs['update:endValue'] = (value: any) => {
|
|
1123
|
+
if (endField) {
|
|
1124
|
+
XEUtils.set(row, endField, value)
|
|
1125
|
+
}
|
|
1126
|
+
}
|
|
1127
|
+
}
|
|
1128
|
+
return [
|
|
1129
|
+
h(getDefaultComponent(renderOpts), {
|
|
1130
|
+
props: getCellEditProps(renderOpts, params, cellValue, seProps),
|
|
1131
|
+
on: getComponentOns(renderOpts, params, {
|
|
1132
|
+
model (cellValue) {
|
|
1133
|
+
model.update = true
|
|
1134
|
+
model.value = cellValue
|
|
1135
|
+
setCellValue(row, column, cellValue)
|
|
1136
|
+
}
|
|
1137
|
+
}, seOs)
|
|
1138
|
+
})
|
|
1139
|
+
]
|
|
1140
|
+
},
|
|
1085
1141
|
renderTableCell (h, renderOpts, params) {
|
|
1086
1142
|
const { startField, endField } = renderOpts
|
|
1087
1143
|
const { row, column } = params
|
|
@@ -1112,6 +1168,7 @@ renderer.mixin({
|
|
|
1112
1168
|
},
|
|
1113
1169
|
VxeTextarea: {
|
|
1114
1170
|
tableAutoFocus: 'textarea',
|
|
1171
|
+
renderTableDefault: defaultEditRender,
|
|
1115
1172
|
renderTableEdit: defaultEditRender
|
|
1116
1173
|
},
|
|
1117
1174
|
VxeButton: {
|
|
@@ -1136,7 +1193,24 @@ renderer.mixin({
|
|
|
1136
1193
|
renderTableEdit: defaultSelectEditRender,
|
|
1137
1194
|
renderTableDefault: defaultSelectEditRender,
|
|
1138
1195
|
renderTableCell (h, renderOpts, params) {
|
|
1139
|
-
|
|
1196
|
+
const { options, optionGroups } = renderOpts
|
|
1197
|
+
const { $table, row, column } = params
|
|
1198
|
+
const opSize = options ? options.length : null
|
|
1199
|
+
const ogSize = optionGroups ? optionGroups.length : null
|
|
1200
|
+
const { cellResult } = $table.effectCellData(row, column, {
|
|
1201
|
+
key: 'render_table_cell',
|
|
1202
|
+
isChanged ({ oldValue, cellValue }) {
|
|
1203
|
+
return oldValue && oldValue[0] === cellValue && oldValue[1] === opSize && oldValue[2] === ogSize
|
|
1204
|
+
},
|
|
1205
|
+
setValue ({ cellValue }) {
|
|
1206
|
+
return [cellValue, opSize, ogSize]
|
|
1207
|
+
},
|
|
1208
|
+
getResult ({ cellValue }) {
|
|
1209
|
+
return handleSelectCellValue(cellValue, renderOpts)
|
|
1210
|
+
}
|
|
1211
|
+
})
|
|
1212
|
+
// const cellResult = getSelectCellValue(renderOpts, params)
|
|
1213
|
+
return getCellLabelVNs(h, renderOpts, params, cellResult)
|
|
1140
1214
|
},
|
|
1141
1215
|
createTableFilterOptions: defaultFilterOptions,
|
|
1142
1216
|
renderTableFilter (h, renderOpts, params) {
|
|
@@ -1211,7 +1285,24 @@ renderer.mixin({
|
|
|
1211
1285
|
},
|
|
1212
1286
|
FormatSelect: {
|
|
1213
1287
|
renderTableDefault (h, renderOpts, params) {
|
|
1214
|
-
|
|
1288
|
+
const { options, optionGroups } = renderOpts
|
|
1289
|
+
const { $table, row, column } = params
|
|
1290
|
+
const opSize = options ? options.length : null
|
|
1291
|
+
const ogSize = optionGroups ? optionGroups.length : null
|
|
1292
|
+
const { cellResult } = $table.effectCellData(row, column, {
|
|
1293
|
+
key: 'render_table_cell',
|
|
1294
|
+
isChanged ({ oldValue, cellValue }) {
|
|
1295
|
+
return oldValue && oldValue[0] === cellValue && oldValue[1] === opSize && oldValue[2] === ogSize
|
|
1296
|
+
},
|
|
1297
|
+
setValue ({ cellValue }) {
|
|
1298
|
+
return [cellValue, opSize, ogSize]
|
|
1299
|
+
},
|
|
1300
|
+
getResult ({ cellValue }) {
|
|
1301
|
+
return handleSelectCellValue(cellValue, renderOpts)
|
|
1302
|
+
}
|
|
1303
|
+
})
|
|
1304
|
+
// const cellResult = getSelectCellValue(renderOpts, params)
|
|
1305
|
+
return getCellLabelVNs(h, renderOpts, params, cellResult)
|
|
1215
1306
|
},
|
|
1216
1307
|
tableCellFormatter: handleFormatSelect,
|
|
1217
1308
|
tableCellCopyMethod: handleFormatSelect,
|
|
@@ -1223,18 +1314,24 @@ renderer.mixin({
|
|
|
1223
1314
|
tableAutoFocus: 'input',
|
|
1224
1315
|
renderTableEdit: defaultTableOrTreeSelectEditRender,
|
|
1225
1316
|
renderTableCell (h, renderOpts, params) {
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1317
|
+
const { options, optionGroups } = renderOpts
|
|
1318
|
+
const { $table, row, column } = params
|
|
1319
|
+
const opSize = options ? options.length : null
|
|
1320
|
+
const ogSize = optionGroups ? optionGroups.length : null
|
|
1321
|
+
const { cellResult } = $table.effectCellData(row, column, {
|
|
1322
|
+
key: 'render_table_cell',
|
|
1323
|
+
isChanged ({ oldValue, cellValue }) {
|
|
1324
|
+
return oldValue && oldValue[0] === cellValue && oldValue[1] === opSize && oldValue[2] === ogSize
|
|
1325
|
+
},
|
|
1326
|
+
setValue ({ cellValue }) {
|
|
1327
|
+
return [cellValue, opSize, ogSize]
|
|
1328
|
+
},
|
|
1329
|
+
getResult ({ cellValue }) {
|
|
1330
|
+
return handleTreeSelectCellValue(cellValue, renderOpts)
|
|
1331
|
+
}
|
|
1332
|
+
})
|
|
1333
|
+
// const cellResult = getTreeSelectCellValue(renderOpts, params)
|
|
1334
|
+
return getCellLabelVNs(h, renderOpts, params, cellResult)
|
|
1238
1335
|
},
|
|
1239
1336
|
tableCellFormatter: handleFormatTreeSelect,
|
|
1240
1337
|
tableCellCopyMethod: handleFormatTreeSelect,
|
|
@@ -1252,7 +1349,52 @@ renderer.mixin({
|
|
|
1252
1349
|
},
|
|
1253
1350
|
FormatTreeSelect: {
|
|
1254
1351
|
renderTableDefault (h, renderOpts, params) {
|
|
1255
|
-
|
|
1352
|
+
const { options, optionGroups } = renderOpts
|
|
1353
|
+
const { $table, row, column } = params
|
|
1354
|
+
const opSize = options ? options.length : null
|
|
1355
|
+
const ogSize = optionGroups ? optionGroups.length : null
|
|
1356
|
+
const { cellResult } = $table.effectCellData(row, column, {
|
|
1357
|
+
key: 'render_table_cell',
|
|
1358
|
+
isChanged ({ oldValue, cellValue }) {
|
|
1359
|
+
return oldValue && oldValue[0] === cellValue && oldValue[1] === opSize && oldValue[2] === ogSize
|
|
1360
|
+
},
|
|
1361
|
+
setValue ({ cellValue }) {
|
|
1362
|
+
return [cellValue, opSize, ogSize]
|
|
1363
|
+
},
|
|
1364
|
+
getResult ({ cellValue }) {
|
|
1365
|
+
return handleTreeSelectCellValue(cellValue, renderOpts)
|
|
1366
|
+
}
|
|
1367
|
+
})
|
|
1368
|
+
// const cellResult = getTreeSelectCellValue(renderOpts, params)
|
|
1369
|
+
return getCellLabelVNs(h, renderOpts, params, cellResult)
|
|
1370
|
+
},
|
|
1371
|
+
tableCellFormatter: handleFormatTreeSelect,
|
|
1372
|
+
tableCellCopyMethod: handleFormatTreeSelect,
|
|
1373
|
+
tableCellPasteMethod: handleSetTreeSelectValue,
|
|
1374
|
+
tableExportMethod: handleExportTreeSelectMethod
|
|
1375
|
+
},
|
|
1376
|
+
VxeTableSelect: {
|
|
1377
|
+
tableAutoFocus: 'input',
|
|
1378
|
+
renderTableEdit: defaultTableOrTreeSelectEditRender,
|
|
1379
|
+
renderTableCell (h, renderOpts, params) {
|
|
1380
|
+
const { options, optionGroups } = renderOpts
|
|
1381
|
+
const { $table, row, column } = params
|
|
1382
|
+
const opSize = options ? options.length : null
|
|
1383
|
+
const ogSize = optionGroups ? optionGroups.length : null
|
|
1384
|
+
const { cellResult } = $table.effectCellData(row, column, {
|
|
1385
|
+
key: 'render_table_cell',
|
|
1386
|
+
isChanged ({ oldValue, cellValue }) {
|
|
1387
|
+
return oldValue && oldValue[0] === cellValue && oldValue[1] === opSize && oldValue[2] === ogSize
|
|
1388
|
+
},
|
|
1389
|
+
setValue ({ cellValue }) {
|
|
1390
|
+
return [cellValue, opSize, ogSize]
|
|
1391
|
+
},
|
|
1392
|
+
getResult ({ cellValue }) {
|
|
1393
|
+
return handleTreeSelectCellValue(cellValue, renderOpts)
|
|
1394
|
+
}
|
|
1395
|
+
})
|
|
1396
|
+
// const cellResult = getTreeSelectCellValue(renderOpts, params)
|
|
1397
|
+
return getCellLabelVNs(h, renderOpts, params, cellResult)
|
|
1256
1398
|
},
|
|
1257
1399
|
tableCellFormatter: handleFormatTreeSelect,
|
|
1258
1400
|
tableCellCopyMethod: handleFormatTreeSelect,
|
|
@@ -363,11 +363,25 @@ function renderTdColumn (
|
|
|
363
363
|
}, column.renderCell(h, cellParams))
|
|
364
364
|
)
|
|
365
365
|
}
|
|
366
|
+
tdVNs.push(
|
|
367
|
+
h('div', {
|
|
368
|
+
key: 'tc',
|
|
369
|
+
class: ['vxe-cell', {
|
|
370
|
+
'c--title': showTitle,
|
|
371
|
+
'c--tooltip': showTooltip,
|
|
372
|
+
'c--ellipsis': showEllipsis
|
|
373
|
+
}],
|
|
374
|
+
style: tcStyle,
|
|
375
|
+
attrs: {
|
|
376
|
+
title: showTitle ? $xeTable.getCellLabel(row, column) : null
|
|
377
|
+
}
|
|
378
|
+
}, clVNs)
|
|
379
|
+
)
|
|
366
380
|
if (showValidTip && errorValidItem) {
|
|
367
381
|
const errRule = errorValidItem.rule
|
|
368
382
|
const validSlot = slots ? slots.valid : null
|
|
369
383
|
const validParams = { ...cellParams, ...errorValidItem, rule: errorValidItem }
|
|
370
|
-
|
|
384
|
+
tdVNs.push(
|
|
371
385
|
h('div', {
|
|
372
386
|
key: 'tcv',
|
|
373
387
|
class: ['vxe-cell--valid-error-tip', getClass(validOpts.className, errorValidItem)],
|
|
@@ -391,20 +405,6 @@ function renderTdColumn (
|
|
|
391
405
|
])
|
|
392
406
|
)
|
|
393
407
|
}
|
|
394
|
-
tdVNs.push(
|
|
395
|
-
h('div', {
|
|
396
|
-
key: 'tc',
|
|
397
|
-
class: ['vxe-cell', {
|
|
398
|
-
'c--title': showTitle,
|
|
399
|
-
'c--tooltip': showTooltip,
|
|
400
|
-
'c--ellipsis': showEllipsis
|
|
401
|
-
}],
|
|
402
|
-
style: tcStyle,
|
|
403
|
-
attrs: {
|
|
404
|
-
title: showTitle ? $xeTable.getCellLabel(row, column) : null
|
|
405
|
-
}
|
|
406
|
-
}, clVNs)
|
|
407
|
-
)
|
|
408
408
|
}
|
|
409
409
|
|
|
410
410
|
let showAreaRowStatus = false
|
|
@@ -3596,6 +3596,7 @@ function loadTableData ($xeTable: VxeTableConstructor & VxeTablePrivateMethods,
|
|
|
3596
3596
|
internalData.removeRowMaps = {}
|
|
3597
3597
|
reactData.removeRowFlag++
|
|
3598
3598
|
internalData.fullCellHeightMaps = {}
|
|
3599
|
+
internalData.fullCellStoreMaps = {}
|
|
3599
3600
|
const sYLoad = updateScrollYStatus($xeTable, fullData)
|
|
3600
3601
|
// 全量数据
|
|
3601
3602
|
internalData.tableFullData = fullData
|
|
@@ -5560,6 +5561,61 @@ const tableMethods: any = {
|
|
|
5560
5561
|
}
|
|
5561
5562
|
return $xeTable.$nextTick()
|
|
5562
5563
|
},
|
|
5564
|
+
effectCellData (row: any, column: VxeTableDefines.ColumnInfo, options: VxeTableDefines.CellCacheHandleOptions) {
|
|
5565
|
+
const $xeTable = this as VxeTableConstructor & VxeTablePrivateMethods
|
|
5566
|
+
const internalData = $xeTable as unknown as TableInternalData
|
|
5567
|
+
|
|
5568
|
+
const { fullCellStoreMaps } = internalData
|
|
5569
|
+
const editOpts = $xeTable.computeEditOpts
|
|
5570
|
+
const { key, isChanged, setValue, getResult } = options
|
|
5571
|
+
const rowid = getRowid($xeTable, row)
|
|
5572
|
+
const colid = column.id
|
|
5573
|
+
let rowStore = fullCellStoreMaps[rowid]
|
|
5574
|
+
const cellValue = XEUtils.get(row, column.field)
|
|
5575
|
+
const restParams: VxeTableDefines.CellCacheHandleParams = {
|
|
5576
|
+
$table: $xeTable,
|
|
5577
|
+
row,
|
|
5578
|
+
rowid,
|
|
5579
|
+
column,
|
|
5580
|
+
colid,
|
|
5581
|
+
cellValue,
|
|
5582
|
+
oldValue: null
|
|
5583
|
+
}
|
|
5584
|
+
|
|
5585
|
+
if (editOpts.cache === false && key === 'render_table_cell') {
|
|
5586
|
+
const rest = restParams as VxeTableDefines.CellCacheResultObj
|
|
5587
|
+
rest.cellResult = getResult ? getResult(restParams) : cellValue
|
|
5588
|
+
return rest
|
|
5589
|
+
}
|
|
5590
|
+
|
|
5591
|
+
if (!rowStore) {
|
|
5592
|
+
rowStore = {}
|
|
5593
|
+
fullCellStoreMaps[rowid] = rowStore
|
|
5594
|
+
}
|
|
5595
|
+
let cellStore = rowStore[colid]
|
|
5596
|
+
if (!cellStore) {
|
|
5597
|
+
cellStore = {
|
|
5598
|
+
value: undefined,
|
|
5599
|
+
result: {}
|
|
5600
|
+
}
|
|
5601
|
+
rowStore[colid] = cellStore
|
|
5602
|
+
}
|
|
5603
|
+
const restData = rowStore[colid]
|
|
5604
|
+
const oldValue = restData.value
|
|
5605
|
+
restParams.oldValue = oldValue
|
|
5606
|
+
if (isChanged ? !isChanged(restParams) : oldValue !== cellValue) {
|
|
5607
|
+
restData.value = setValue ? setValue(restParams) : cellValue
|
|
5608
|
+
restData.result = {}
|
|
5609
|
+
}
|
|
5610
|
+
const storeData = restData.result
|
|
5611
|
+
if (XEUtils.isUndefined(storeData[key])) {
|
|
5612
|
+
storeData[key] = getResult ? getResult(restParams) : cellValue
|
|
5613
|
+
}
|
|
5614
|
+
const cellResult = storeData[key]
|
|
5615
|
+
const rest = restParams as VxeTableDefines.CellCacheResultObj
|
|
5616
|
+
rest.cellResult = cellResult
|
|
5617
|
+
return rest
|
|
5618
|
+
},
|
|
5563
5619
|
getCellElement (row: any, fieldOrColumn: any) {
|
|
5564
5620
|
const $xeTable = this as VxeTableConstructor & VxeTablePrivateMethods
|
|
5565
5621
|
const internalData = $xeTable as unknown as TableInternalData
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|