aloha-vue 1.2.131 → 1.2.133
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/docs/src/views/PageTable/PageTableComplex/PageTableComplex.js +2 -0
- package/docs/src/views/PageTable/PageTableComplex/PageTableComplex.pug +2 -0
- package/docs/src/views/PageTable/PageTableComplex/PageTableComplexExample/PageTableComplexExample.pug +1 -0
- package/docs/src/views/PageTable/PageTableComplex/PageTableComplexSlotRowActions/PageTableComplexSlotRowActions.js +540 -0
- package/docs/src/views/PageTable/PageTableComplex/PageTableComplexSlotRowActions/PageTableComplexSlotRowActions.pug +85 -0
- package/docs/src/views/PageTable/PageTableComplex/PageTableComplexSlotRowActions/PageTableComplexSlotRowActions.vue +2 -0
- package/docs/src/views/PageTable/PageTableComplex/PageTableComplexSlotRowActions/compositionAPI/HtmlAPI.js +40 -0
- package/docs/src/views/PageTable/PageTableComplex/PageTableComplexSlotRowActions/compositionAPI/JsAPI.js +30 -0
- package/package.json +1 -1
- package/src/AAlert/AAlert.js +1 -1
- package/src/ADropdown/ADropdown.js +1 -1
- package/src/ADropdown/ADropdownAction/ADropdownAction.js +1 -1
- package/src/AFilters/AFilterCenter/AFilterCenter.js +1 -1
- package/src/AFilters/AFiltersHorizontal/AFiltersHorizontal.js +1 -1
- package/src/AFilters/AFiltersMain/AFiltersMain.js +1 -1
- package/src/AFormElement/AFormElementBtnClear/AFormElementBtnClear.js +1 -1
- package/src/AMenu/AMenuBreadcrumbs.js +1 -1
- package/src/AMenu/AMenuPanelLink/AMenuPanelLink.js +1 -1
- package/src/AMenu/AMenuSearchGroup.js +1 -1
- package/src/AMenu/AMenuSearchPanel.js +1 -1
- package/src/AMenu2/AMenuBreadcrumbs/AMenuBreadcrumbs.js +1 -1
- package/src/AMenu2/AMenuPanelGroup/AMenuPanelGroup.js +1 -1
- package/src/AMenu2/AMenuSearchPanel/AMenuSearchPanel.js +1 -1
- package/src/APagination/APagination.js +1 -1
- package/src/APopup/APopup.js +1 -1
- package/src/ATable/ATable.js +15 -8
- package/src/ATable/ATableHeader/ATableHeader.js +1 -1
- package/src/ATable/ATableHeaderThAction/ATableHeaderThAction.js +9 -3
- package/src/ATable/ATableHeaderThAction/ATableHeaderThActionItem/ATableHeaderThActionItem.js +1 -1
- package/src/ATable/ATableHeaderThAction/compositionAPI/StylesThTdAction.js +23 -0
- package/src/ATable/ATableTdAction/ATableTdAction.js +16 -0
- package/src/ATable/compositionAPI/ColumnsAPI.js +3 -3
- package/src/ATable/compositionAPI/ScrollControlAPI.js +3 -2
- package/src/ATable/compositionAPI/SimpleTableAPI.js +14 -4
- package/src/ATable/compositionAPI/StickyAPI.js +2 -2
- package/src/ATable/compositionAPI/VariablesAPI.js +1 -6
- package/src/ui/ACheckbox/ACheckbox.js +1 -1
- package/src/ui/ACheckboxRadioGroups/ACheckboxRadioGroups.js +1 -1
- package/src/ui/ADatepicker/ADatepicker.js +1 -1
- package/src/ui/ADatepickerRange/ADatepickerRange.js +1 -1
- package/src/ui/AFieldset/AFieldset.js +1 -1
- package/src/ui/AForm/AForm.js +1 -1
- package/src/ui/AGroup/AGroup.js +1 -1
- package/src/ui/AInput/AInput.js +1 -1
- package/src/ui/AInputFile/AInputFile.js +1 -1
- package/src/ui/AInputNumber/AInputNumber.js +1 -1
- package/src/ui/AInputNumberRange/AInputNumberRange.js +1 -1
- package/src/ui/AOneCheckbox/AOneCheckbox.js +1 -1
- package/src/ui/ARadio/ARadio.js +1 -1
- package/src/ui/ASelect/ASelect.js +1 -1
- package/src/ui/ASwitch/ASwitch.js +1 -1
- package/src/ui/ATemplate/ATemplate.js +1 -1
- package/src/ui/ATextarea/ATextarea.js +1 -1
- package/src/ui/ATinymce/ATinymce.js +1 -1
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import AlohaPage from "../../../global/components/AlohaPage/AlohaPage.vue";
|
|
2
2
|
import ATranslation from "../../../../../src/ATranslation/ATranslation";
|
|
3
3
|
import PageTableComplexExample from "./PageTableComplexExample/PageTableComplexExample.vue";
|
|
4
|
+
import PageTableComplexSlotRowActions from "./PageTableComplexSlotRowActions/PageTableComplexSlotRowActions.vue";
|
|
4
5
|
|
|
5
6
|
import PageTitleAPI from "./compositionAPI/PageTitleAPI";
|
|
6
7
|
|
|
@@ -10,6 +11,7 @@ export default {
|
|
|
10
11
|
AlohaPage,
|
|
11
12
|
ATranslation,
|
|
12
13
|
PageTableComplexExample,
|
|
14
|
+
PageTableComplexSlotRowActions,
|
|
13
15
|
},
|
|
14
16
|
setup() {
|
|
15
17
|
const {
|
|
@@ -0,0 +1,540 @@
|
|
|
1
|
+
import AButton from "../../../../../../src/AButton/AButton";
|
|
2
|
+
import AIcon from "../../../../../../src/AIcon/AIcon";
|
|
3
|
+
import AlohaExample from "../../../../global/components/AlohaExample/AlohaExample.vue";
|
|
4
|
+
import ASwitch from "../../../../../../src/ui/ASwitch/ASwitch";
|
|
5
|
+
import ATable from "../../../../../../src/ATable/ATable";
|
|
6
|
+
|
|
7
|
+
import HtmlAPI from "./compositionAPI/HtmlAPI";
|
|
8
|
+
import JsAPI from "./compositionAPI/JsAPI";
|
|
9
|
+
|
|
10
|
+
import {
|
|
11
|
+
cloneDeep,
|
|
12
|
+
times,
|
|
13
|
+
} from "lodash-es";
|
|
14
|
+
|
|
15
|
+
export default {
|
|
16
|
+
name: "PageTableComplexSlotRowActions",
|
|
17
|
+
components: {
|
|
18
|
+
AButton,
|
|
19
|
+
AIcon,
|
|
20
|
+
AlohaExample,
|
|
21
|
+
ASwitch,
|
|
22
|
+
ATable,
|
|
23
|
+
},
|
|
24
|
+
setup() {
|
|
25
|
+
const {
|
|
26
|
+
codeHtml,
|
|
27
|
+
} = HtmlAPI();
|
|
28
|
+
|
|
29
|
+
const {
|
|
30
|
+
codeJs,
|
|
31
|
+
} = JsAPI();
|
|
32
|
+
|
|
33
|
+
return {
|
|
34
|
+
codeHtml,
|
|
35
|
+
codeJs,
|
|
36
|
+
};
|
|
37
|
+
},
|
|
38
|
+
data() {
|
|
39
|
+
return {
|
|
40
|
+
modelView: undefined,
|
|
41
|
+
modelLoading: false,
|
|
42
|
+
modelColumnsVisible: {
|
|
43
|
+
aloha: true,
|
|
44
|
+
},
|
|
45
|
+
modelColumnsOrdering: ["sdf", "ddsadsa", "aloha"],
|
|
46
|
+
columns: [
|
|
47
|
+
{
|
|
48
|
+
label: "_A_TABLE_COLUMN_1_",
|
|
49
|
+
id: "aloha",
|
|
50
|
+
keyLabel: "aloha",
|
|
51
|
+
sortId: "aloha",
|
|
52
|
+
locked: true,
|
|
53
|
+
grow: 2,
|
|
54
|
+
footerSlot: "footerAloha",
|
|
55
|
+
class: "a_text_right",
|
|
56
|
+
icon: "Close",
|
|
57
|
+
isRender: true,
|
|
58
|
+
title: "Aloha",
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
label: "_A_TABLE_COLUMN_2_",
|
|
62
|
+
id: "slot",
|
|
63
|
+
slot: "slot1",
|
|
64
|
+
title: "bbbbbbbbbb",
|
|
65
|
+
// hide: true,
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
label: "Alohafreidsfdsfdsfsdfdsfdsfdsfsd",
|
|
69
|
+
id: "number",
|
|
70
|
+
keyLabel: "number",
|
|
71
|
+
sortId: "number",
|
|
72
|
+
grow: 0,
|
|
73
|
+
footerKeyLabel: "number",
|
|
74
|
+
class: "a_justify_content_end",
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
label: "Hola",
|
|
78
|
+
id: "hola",
|
|
79
|
+
keyLabel: "hola",
|
|
80
|
+
sortId: "hola",
|
|
81
|
+
footerKeyLabel: "hola",
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
label: "Default",
|
|
85
|
+
id: "default",
|
|
86
|
+
keyLabel: "default",
|
|
87
|
+
defaultValue: "-",
|
|
88
|
+
footerKeyLabel: "default",
|
|
89
|
+
footerDefaultValue: "-",
|
|
90
|
+
},
|
|
91
|
+
{
|
|
92
|
+
label: "Hola2",
|
|
93
|
+
id: "hola2",
|
|
94
|
+
keyLabel: "hola",
|
|
95
|
+
sortId: "hola",
|
|
96
|
+
hide: true,
|
|
97
|
+
footerKeyLabel: "hola",
|
|
98
|
+
},
|
|
99
|
+
{
|
|
100
|
+
label: "Obj",
|
|
101
|
+
id: "obj",
|
|
102
|
+
keyLabel: "obj.aloha",
|
|
103
|
+
sortId: "obj.aloha",
|
|
104
|
+
slot: "get",
|
|
105
|
+
filter: "boolean",
|
|
106
|
+
footerKeyLabel: "obj.aloha",
|
|
107
|
+
width: 220,
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
label: "Test",
|
|
111
|
+
id: "test",
|
|
112
|
+
keyLabelSafeHtml: "test",
|
|
113
|
+
sortId: "test",
|
|
114
|
+
width: 200,
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
label: "Obj2",
|
|
118
|
+
id: "obj2",
|
|
119
|
+
keyLabel: "obj.aloha",
|
|
120
|
+
sortId: "obj.aloha",
|
|
121
|
+
footerKeyLabel: "obj.aloha",
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
label: "Obj3",
|
|
125
|
+
id: "obj3",
|
|
126
|
+
keyLabel: "obj.aloha",
|
|
127
|
+
footerKeyLabel: "obj.aloha",
|
|
128
|
+
},
|
|
129
|
+
{
|
|
130
|
+
label: "Obj4",
|
|
131
|
+
id: "obj4",
|
|
132
|
+
keyLabel: "obj.aloha",
|
|
133
|
+
footerKeyLabel: "obj.aloha",
|
|
134
|
+
},
|
|
135
|
+
{
|
|
136
|
+
label: "Geld",
|
|
137
|
+
id: "geld",
|
|
138
|
+
keyLabel: "geld",
|
|
139
|
+
footerKeyLabel: "geld",
|
|
140
|
+
},
|
|
141
|
+
|
|
142
|
+
{
|
|
143
|
+
label: "Slot2",
|
|
144
|
+
id: "slot2",
|
|
145
|
+
slot: "slot1",
|
|
146
|
+
hide: true,
|
|
147
|
+
},
|
|
148
|
+
{
|
|
149
|
+
label: "safeHtml",
|
|
150
|
+
id: "safeHtml",
|
|
151
|
+
keyLabelSafeHtml: "test",
|
|
152
|
+
sortId: "test",
|
|
153
|
+
width: 200,
|
|
154
|
+
},
|
|
155
|
+
{
|
|
156
|
+
label: "html",
|
|
157
|
+
id: "html",
|
|
158
|
+
keyLabelHtml: "test",
|
|
159
|
+
sortId: "test",
|
|
160
|
+
width: 200,
|
|
161
|
+
},
|
|
162
|
+
],
|
|
163
|
+
rowsFooter: [
|
|
164
|
+
{
|
|
165
|
+
index: 1,
|
|
166
|
+
},
|
|
167
|
+
{
|
|
168
|
+
index: 2,
|
|
169
|
+
},
|
|
170
|
+
],
|
|
171
|
+
data: [],
|
|
172
|
+
isLoadingOptions: false,
|
|
173
|
+
rowActions: [
|
|
174
|
+
{
|
|
175
|
+
type: "divider",
|
|
176
|
+
},
|
|
177
|
+
{
|
|
178
|
+
type: "divider",
|
|
179
|
+
},
|
|
180
|
+
{
|
|
181
|
+
type: "button",
|
|
182
|
+
text: "Click me",
|
|
183
|
+
title: "Click me title",
|
|
184
|
+
isHidden: false,
|
|
185
|
+
callback: this.clickMe,
|
|
186
|
+
class: "aloha a_dropdown__item",
|
|
187
|
+
disabled: false,
|
|
188
|
+
extraCallback: ({ row }) => ({
|
|
189
|
+
aloha: row.aloha,
|
|
190
|
+
}),
|
|
191
|
+
},
|
|
192
|
+
{
|
|
193
|
+
type: "divider",
|
|
194
|
+
},
|
|
195
|
+
{
|
|
196
|
+
type: "divider",
|
|
197
|
+
},
|
|
198
|
+
{
|
|
199
|
+
type: "divider",
|
|
200
|
+
},
|
|
201
|
+
{
|
|
202
|
+
type: "divider",
|
|
203
|
+
},
|
|
204
|
+
{
|
|
205
|
+
type: "button",
|
|
206
|
+
textCallback: ({ row, rowIndex }) => `${ rowIndex } Click ${ row.aloha }`,
|
|
207
|
+
titleCallback: ({ row, rowIndex }) => `${ rowIndex } Click ${ row.aloha } title`,
|
|
208
|
+
isHiddenCallback: ({ row, rowIndex }) => !!(rowIndex > 2 && row.aloha),
|
|
209
|
+
disabledCallback: ({ row, rowIndex }) => !(rowIndex > 2 && row.aloha),
|
|
210
|
+
callback: this.clickMe,
|
|
211
|
+
},
|
|
212
|
+
{
|
|
213
|
+
iconLeft: "Export",
|
|
214
|
+
type: "link",
|
|
215
|
+
hrefCallback: ({ row }) => `dokumente/${ row.number }/download/`,
|
|
216
|
+
text: "Dokument herunterladen",
|
|
217
|
+
target: "_blank",
|
|
218
|
+
},
|
|
219
|
+
{
|
|
220
|
+
type: "divider",
|
|
221
|
+
},
|
|
222
|
+
{
|
|
223
|
+
type: "divider",
|
|
224
|
+
},
|
|
225
|
+
],
|
|
226
|
+
multipleActions: [
|
|
227
|
+
{
|
|
228
|
+
type: "divider",
|
|
229
|
+
},
|
|
230
|
+
{
|
|
231
|
+
type: "divider",
|
|
232
|
+
},
|
|
233
|
+
{
|
|
234
|
+
type: "button",
|
|
235
|
+
text: "Aloha1",
|
|
236
|
+
title: "Aloha1 Title",
|
|
237
|
+
isHidden: false,
|
|
238
|
+
callback: this.clickMe,
|
|
239
|
+
disabled: false,
|
|
240
|
+
icon: "Plus",
|
|
241
|
+
isConfirm: true,
|
|
242
|
+
isAllRowsSelected: true,
|
|
243
|
+
},
|
|
244
|
+
{
|
|
245
|
+
type: "divider",
|
|
246
|
+
},
|
|
247
|
+
{
|
|
248
|
+
type: "divider",
|
|
249
|
+
},
|
|
250
|
+
{
|
|
251
|
+
type: "divider",
|
|
252
|
+
},
|
|
253
|
+
{
|
|
254
|
+
type: "divider",
|
|
255
|
+
},
|
|
256
|
+
{
|
|
257
|
+
type: "button",
|
|
258
|
+
text: "Aloha1 modal",
|
|
259
|
+
title: "Aloha1 Title",
|
|
260
|
+
callback: this.clickMeModal,
|
|
261
|
+
disabled: false,
|
|
262
|
+
icon: "Plus",
|
|
263
|
+
isHidden: false,
|
|
264
|
+
isHiddenCallback: this.isHiddenMultiple,
|
|
265
|
+
},
|
|
266
|
+
{
|
|
267
|
+
type: "divider",
|
|
268
|
+
},
|
|
269
|
+
{
|
|
270
|
+
type: "divider",
|
|
271
|
+
},
|
|
272
|
+
],
|
|
273
|
+
tableActions: [
|
|
274
|
+
{
|
|
275
|
+
text: "Aloha1",
|
|
276
|
+
title: "Aloha1 Title",
|
|
277
|
+
isHidden: false,
|
|
278
|
+
callback: this.clickMe,
|
|
279
|
+
type: "button",
|
|
280
|
+
classButton: "a_btn a_btn_primary",
|
|
281
|
+
iconLeft: "Plus",
|
|
282
|
+
id: "aloha_1"
|
|
283
|
+
},
|
|
284
|
+
{
|
|
285
|
+
type: "divider",
|
|
286
|
+
},
|
|
287
|
+
{
|
|
288
|
+
text: "Aloha2",
|
|
289
|
+
title: "Aloha2 Title",
|
|
290
|
+
callback: this.clickMe,
|
|
291
|
+
disabled: false,
|
|
292
|
+
classButton: "a_btn a_btn_secondary",
|
|
293
|
+
id: "aloha_2",
|
|
294
|
+
type: "button",
|
|
295
|
+
},
|
|
296
|
+
{
|
|
297
|
+
type: "divider",
|
|
298
|
+
},
|
|
299
|
+
{
|
|
300
|
+
text: "Aloha link to",
|
|
301
|
+
title: "Aloha link Title",
|
|
302
|
+
disabled: false,
|
|
303
|
+
classButton: "a_btn a_btn_secondary",
|
|
304
|
+
type: "link",
|
|
305
|
+
iconRight: "Plus",
|
|
306
|
+
to: "/spinner",
|
|
307
|
+
},
|
|
308
|
+
{
|
|
309
|
+
text: "Aloha link href",
|
|
310
|
+
title: "Aloha link Title",
|
|
311
|
+
disabled: false,
|
|
312
|
+
classButton: "a_btn a_btn_secondary",
|
|
313
|
+
type: "link",
|
|
314
|
+
href: "/spinner",
|
|
315
|
+
iconLeft: "Plus",
|
|
316
|
+
},
|
|
317
|
+
{
|
|
318
|
+
type: "divider",
|
|
319
|
+
},
|
|
320
|
+
{
|
|
321
|
+
text: "Aloha link Title",
|
|
322
|
+
disabled: false,
|
|
323
|
+
classButton: "a_btn a_btn_secondary",
|
|
324
|
+
type: "link",
|
|
325
|
+
href: "/spinner",
|
|
326
|
+
iconLeft: "Plus",
|
|
327
|
+
},
|
|
328
|
+
],
|
|
329
|
+
modelQuickSearch: "",
|
|
330
|
+
modelFilters: {
|
|
331
|
+
group_switch: true,
|
|
332
|
+
},
|
|
333
|
+
views: [
|
|
334
|
+
{
|
|
335
|
+
id: "aloha1",
|
|
336
|
+
type: "table",
|
|
337
|
+
label: "Tabelle",
|
|
338
|
+
icon: "Table",
|
|
339
|
+
usePagination: true,
|
|
340
|
+
},
|
|
341
|
+
{
|
|
342
|
+
id: "aloha2",
|
|
343
|
+
type: "map",
|
|
344
|
+
label: "Karte",
|
|
345
|
+
icon: "GlobeEuropeAfrica",
|
|
346
|
+
},
|
|
347
|
+
],
|
|
348
|
+
filters: [
|
|
349
|
+
{
|
|
350
|
+
type: "text",
|
|
351
|
+
id: "suche",
|
|
352
|
+
label: "Suche",
|
|
353
|
+
main: true,
|
|
354
|
+
},
|
|
355
|
+
{
|
|
356
|
+
type: "text",
|
|
357
|
+
id: "au_kbezbeobachter",
|
|
358
|
+
label: "Beobachter",
|
|
359
|
+
},
|
|
360
|
+
{
|
|
361
|
+
type: "switch",
|
|
362
|
+
id: "au_termin_sichtbar",
|
|
363
|
+
label: "Sichtbar",
|
|
364
|
+
alwaysVisible: true,
|
|
365
|
+
},
|
|
366
|
+
{
|
|
367
|
+
type: "date",
|
|
368
|
+
id: "datum",
|
|
369
|
+
label: "Datum",
|
|
370
|
+
alwaysVisible: true,
|
|
371
|
+
},
|
|
372
|
+
{
|
|
373
|
+
type: "oneCheckbox",
|
|
374
|
+
id: "au_ende",
|
|
375
|
+
label: "Bearbeitungsende",
|
|
376
|
+
alwaysVisible: true,
|
|
377
|
+
},
|
|
378
|
+
{
|
|
379
|
+
type: "group",
|
|
380
|
+
id: "group1",
|
|
381
|
+
label: "Group",
|
|
382
|
+
alwaysVisible: true,
|
|
383
|
+
classColumns: "a_d_flex a_flex_wrap",
|
|
384
|
+
children: [
|
|
385
|
+
{
|
|
386
|
+
type: "multiselect",
|
|
387
|
+
id: "dsdsfs",
|
|
388
|
+
classColumn: "a_flex_fill",
|
|
389
|
+
label: "Group",
|
|
390
|
+
labelClass: "a_sr_only",
|
|
391
|
+
data: [
|
|
392
|
+
{
|
|
393
|
+
id: "1",
|
|
394
|
+
bez: "Aloha 1",
|
|
395
|
+
},
|
|
396
|
+
{
|
|
397
|
+
id: "2",
|
|
398
|
+
bez: "Aloha 2",
|
|
399
|
+
},
|
|
400
|
+
{
|
|
401
|
+
id: "3",
|
|
402
|
+
bez: "Aloha 3",
|
|
403
|
+
},
|
|
404
|
+
],
|
|
405
|
+
keyLabel: "bez",
|
|
406
|
+
keyId: "id",
|
|
407
|
+
search: true,
|
|
408
|
+
alwaysVisible: true,
|
|
409
|
+
slotName: "termin",
|
|
410
|
+
},
|
|
411
|
+
{
|
|
412
|
+
type: "switch",
|
|
413
|
+
label: "Group switch",
|
|
414
|
+
id: "group_switch",
|
|
415
|
+
classColumn: "a_ml_2",
|
|
416
|
+
labelClass: "a_sr_only",
|
|
417
|
+
hideFilterCenter: true,
|
|
418
|
+
trueLabel: "Eins",
|
|
419
|
+
falseLabel: "Alle",
|
|
420
|
+
title: "Alohadsfdsfdsf sdfsdfdsffds"
|
|
421
|
+
},
|
|
422
|
+
],
|
|
423
|
+
},
|
|
424
|
+
{
|
|
425
|
+
type: "multiselect",
|
|
426
|
+
id: "terminberechnung",
|
|
427
|
+
label: "Termin",
|
|
428
|
+
data: [
|
|
429
|
+
{
|
|
430
|
+
id: "1",
|
|
431
|
+
bez: "Aloha 1",
|
|
432
|
+
},
|
|
433
|
+
{
|
|
434
|
+
id: "2",
|
|
435
|
+
bez: "Aloha 2",
|
|
436
|
+
},
|
|
437
|
+
{
|
|
438
|
+
id: "3",
|
|
439
|
+
bez: "Aloha 3",
|
|
440
|
+
},
|
|
441
|
+
],
|
|
442
|
+
hasNotClose: true,
|
|
443
|
+
// url: "katalog/?fields=id&fields=bez&key=syterminberechnung",
|
|
444
|
+
keyLabel: "bez",
|
|
445
|
+
keyId: "id",
|
|
446
|
+
search: true,
|
|
447
|
+
alwaysVisible: true,
|
|
448
|
+
slotName: "termin",
|
|
449
|
+
},
|
|
450
|
+
],
|
|
451
|
+
};
|
|
452
|
+
},
|
|
453
|
+
created() {
|
|
454
|
+
this.setData();
|
|
455
|
+
setTimeout(() => {
|
|
456
|
+
this.$refs.aloha.updateRow({ row: {
|
|
457
|
+
id: 1,
|
|
458
|
+
number: 1,
|
|
459
|
+
aloha: `test`,
|
|
460
|
+
hola: `hola test`,
|
|
461
|
+
geld: undefined,
|
|
462
|
+
obj: {
|
|
463
|
+
aloha: "dffdg",
|
|
464
|
+
},
|
|
465
|
+
test: "<div>aloha123</div>",
|
|
466
|
+
}, rowIndex: 1 });
|
|
467
|
+
}, 1000);
|
|
468
|
+
},
|
|
469
|
+
methods: {
|
|
470
|
+
changeColumnsOrdering({ modelColumnsOrdering }) {
|
|
471
|
+
this.modelColumnsOrdering = modelColumnsOrdering;
|
|
472
|
+
this.isLoadingOptions = true;
|
|
473
|
+
setTimeout(() => {
|
|
474
|
+
this.isLoadingOptions = false;
|
|
475
|
+
}, 1000);
|
|
476
|
+
},
|
|
477
|
+
|
|
478
|
+
setData() {
|
|
479
|
+
const DATA = [];
|
|
480
|
+
times(100, item => {
|
|
481
|
+
DATA.push({
|
|
482
|
+
id: item,
|
|
483
|
+
number: +item,
|
|
484
|
+
aloha: `aloha1111dfdsfdsfdsfaasasadadsadasdsadsa1111111${ item }`,
|
|
485
|
+
hola: `hola ${ item }`,
|
|
486
|
+
geld: `${ item } €`,
|
|
487
|
+
obj: {
|
|
488
|
+
aloha: `ertet ${ 100 - item }`,
|
|
489
|
+
},
|
|
490
|
+
test: "<div>aloha</div><div>aloha</div><div>aloha</div><div>aloha</div><div>aloha</div><div>aloha</div><div>aloha</div>",
|
|
491
|
+
});
|
|
492
|
+
});
|
|
493
|
+
this.data = DATA;
|
|
494
|
+
},
|
|
495
|
+
|
|
496
|
+
clickMe(arg) {
|
|
497
|
+
console.log("arg", arg);
|
|
498
|
+
},
|
|
499
|
+
|
|
500
|
+
clickMeModal({ rows, close }) {
|
|
501
|
+
console.log("rows", rows,);
|
|
502
|
+
setTimeout(() => {
|
|
503
|
+
close();
|
|
504
|
+
}, 5000);
|
|
505
|
+
},
|
|
506
|
+
|
|
507
|
+
updateModelFiltersLocal({ model }) {
|
|
508
|
+
console.log("modelFiltersLocal", model);
|
|
509
|
+
return model;
|
|
510
|
+
},
|
|
511
|
+
|
|
512
|
+
togglePreview({ row, rowIndex, typeToggle }) {
|
|
513
|
+
console.log("row: ", row);
|
|
514
|
+
console.log("rowIndex: ", rowIndex);
|
|
515
|
+
console.log("typeToggle: ", typeToggle);
|
|
516
|
+
},
|
|
517
|
+
|
|
518
|
+
isHiddenMultiple({ row }) {
|
|
519
|
+
return row.number % 2 === 0;
|
|
520
|
+
},
|
|
521
|
+
|
|
522
|
+
updateModelFilters({ _modelFilters } = {}) {
|
|
523
|
+
this.modelFilters = cloneDeep(_modelFilters);
|
|
524
|
+
},
|
|
525
|
+
|
|
526
|
+
updateView({ _modelView, view }) {
|
|
527
|
+
this.modelView = _modelView;
|
|
528
|
+
console.log("view", view);
|
|
529
|
+
},
|
|
530
|
+
|
|
531
|
+
changeModelColumnsVisible(model) {
|
|
532
|
+
this.modelColumnsVisible = model;
|
|
533
|
+
},
|
|
534
|
+
|
|
535
|
+
initTable({ columnsOrdering = {}, columnsVisible = {} } = {}) {
|
|
536
|
+
this.modelColumnsOrdering = columnsOrdering.model;
|
|
537
|
+
this.modelColumnsVisible = columnsVisible.model;
|
|
538
|
+
},
|
|
539
|
+
},
|
|
540
|
+
};
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
aloha-example(
|
|
2
|
+
:code-html="codeHtml"
|
|
3
|
+
:code-js="codeJs"
|
|
4
|
+
header="_A_TABLE_GROUP_COMPLEX_HEADER_"
|
|
5
|
+
description="_A_TABLE_GROUP_COMPLEX_DESCRIPTION_"
|
|
6
|
+
)
|
|
7
|
+
div
|
|
8
|
+
div
|
|
9
|
+
a-switch(
|
|
10
|
+
v-model="modelLoading"
|
|
11
|
+
)
|
|
12
|
+
a-table(
|
|
13
|
+
ref="aloha"
|
|
14
|
+
:column-actions-width="250"
|
|
15
|
+
:column-actions-width-min="150"
|
|
16
|
+
:columns="columns"
|
|
17
|
+
:data="data"
|
|
18
|
+
:is-loading-options="isLoadingOptions"
|
|
19
|
+
label="Example table"
|
|
20
|
+
:row-actions="rowActions"
|
|
21
|
+
:table-actions="tableActions"
|
|
22
|
+
:multiple-actions="multipleActions"
|
|
23
|
+
preview="right"
|
|
24
|
+
:is-quick-search="true"
|
|
25
|
+
:is-action-column-visible="true"
|
|
26
|
+
:is-columns-dnd="true"
|
|
27
|
+
:pagination="{ use: true }"
|
|
28
|
+
:is-loading-table="modelLoading"
|
|
29
|
+
:is-loading-multiple-actions="false"
|
|
30
|
+
:model-is-table-without-scroll-start="true"
|
|
31
|
+
v-model:modelQuickSearch="modelQuickSearch"
|
|
32
|
+
:model-columns-ordering="modelColumnsOrdering"
|
|
33
|
+
:model-columns-visible="modelColumnsVisible"
|
|
34
|
+
@change-columns-ordering="changeColumnsOrdering"
|
|
35
|
+
@toggle-preview="togglePreview"
|
|
36
|
+
@update:model-columns-visible="changeModelColumnsVisible"
|
|
37
|
+
@update-model-is-table-without-scroll=""
|
|
38
|
+
@init-table="initTable"
|
|
39
|
+
)
|
|
40
|
+
template(
|
|
41
|
+
v-slot:rowActions="{ row }"
|
|
42
|
+
)
|
|
43
|
+
.a_btn_group(
|
|
44
|
+
role="group"
|
|
45
|
+
)
|
|
46
|
+
a-button.a_btn.a_btn_primary(
|
|
47
|
+
icon-left="Pencil"
|
|
48
|
+
)
|
|
49
|
+
a-button.a_btn.a_btn_secondary(
|
|
50
|
+
icon-left="Trash"
|
|
51
|
+
)
|
|
52
|
+
|
|
53
|
+
template(
|
|
54
|
+
v-slot:slot1="vm"
|
|
55
|
+
)
|
|
56
|
+
router-link(
|
|
57
|
+
:to="{ name: 'PageTabs' }"
|
|
58
|
+
) Tabs
|
|
59
|
+
|
|
60
|
+
template(
|
|
61
|
+
v-slot:preview="vm"
|
|
62
|
+
)
|
|
63
|
+
pre {{ vm }}
|
|
64
|
+
|
|
65
|
+
template(
|
|
66
|
+
v-slot:tableActions
|
|
67
|
+
)
|
|
68
|
+
button.a_btn.a_btn_primary Click me
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
template(
|
|
72
|
+
v-slot:termin="{ label, labelFiltered }"
|
|
73
|
+
)
|
|
74
|
+
a-icon.a_mr_1(
|
|
75
|
+
icon="Cog"
|
|
76
|
+
)
|
|
77
|
+
span(
|
|
78
|
+
v-if="labelFiltered"
|
|
79
|
+
v-html="labelFiltered"
|
|
80
|
+
)
|
|
81
|
+
span(
|
|
82
|
+
v-else
|
|
83
|
+
v-html="label"
|
|
84
|
+
)
|
|
85
|
+
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
export default function HtmlAPI() {
|
|
2
|
+
const codeHtml = `<a-table
|
|
3
|
+
ref="aloha"
|
|
4
|
+
:columns="columns"
|
|
5
|
+
:data="data"
|
|
6
|
+
:is-loading-options="isLoadingOptions"
|
|
7
|
+
label="Example table"
|
|
8
|
+
:row-actions="rowActions"
|
|
9
|
+
:table-actions="tableActions"
|
|
10
|
+
:multiple-actions="multipleActions"
|
|
11
|
+
preview="right"
|
|
12
|
+
:is-quick-search="true"
|
|
13
|
+
:is-action-column-visible="true"
|
|
14
|
+
:is-columns-dnd="true"
|
|
15
|
+
:pagination="{ use: true, limitsPerPage: ['10', '25', '50', '100', '500'] }"
|
|
16
|
+
:is-pagination="true"
|
|
17
|
+
:filter="{ filters }"
|
|
18
|
+
:rows-footer="rowsFooter"
|
|
19
|
+
:is-loading-table="false"
|
|
20
|
+
:is-loading-multiple-actions="false"
|
|
21
|
+
:views="views"
|
|
22
|
+
:model-view="modelView"
|
|
23
|
+
v-model:modelQuickSearch="modelQuickSearch"
|
|
24
|
+
:modelFilters="modelFilters"
|
|
25
|
+
:model-columns-ordering="modelColumnsOrdering"
|
|
26
|
+
:model-columns-visible="modelColumnsVisible"
|
|
27
|
+
@change-columns-ordering="changeColumnsOrdering"
|
|
28
|
+
:update-model-filters-local="updateModelFiltersLocal"
|
|
29
|
+
@toggle-preview="togglePreview"
|
|
30
|
+
@update-model-filters="updateModelFilters"
|
|
31
|
+
@update-view="updateView"
|
|
32
|
+
@update:model-columns-visible="changeModelColumnsVisible"
|
|
33
|
+
@init-table="initTable"
|
|
34
|
+
>
|
|
35
|
+
</a-table>`;
|
|
36
|
+
|
|
37
|
+
return {
|
|
38
|
+
codeHtml,
|
|
39
|
+
};
|
|
40
|
+
}
|