br-dionysus 0.7.11 → 0.7.12
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/README.md
CHANGED
|
@@ -488,7 +488,9 @@ sole 必须传递在表格数据内为唯一的值 如id key 等不会发生重
|
|
|
488
488
|
:minWidth="item.minWidth"
|
|
489
489
|
v-model:filtersValue="filtersValue"
|
|
490
490
|
showOverflowTooltip
|
|
491
|
-
|
|
491
|
+
:children="item.children||[]"
|
|
492
|
+
>
|
|
493
|
+
</MTableColumn>
|
|
492
494
|
</el-table>
|
|
493
495
|
</div>
|
|
494
496
|
</template>
|
|
@@ -544,8 +546,30 @@ const tableTitle = [
|
|
|
544
546
|
},
|
|
545
547
|
{
|
|
546
548
|
label: '地址',
|
|
547
|
-
|
|
548
|
-
|
|
549
|
+
children: [
|
|
550
|
+
{
|
|
551
|
+
label: '123', children: [
|
|
552
|
+
{
|
|
553
|
+
label: '222222222222',
|
|
554
|
+
prop: 'address',
|
|
555
|
+
minWidth: '134px'
|
|
556
|
+
|
|
557
|
+
},
|
|
558
|
+
{
|
|
559
|
+
label: 'qqqqqq',
|
|
560
|
+
prop: 'address',
|
|
561
|
+
minWidth: '134px'
|
|
562
|
+
|
|
563
|
+
}
|
|
564
|
+
]
|
|
565
|
+
},
|
|
566
|
+
{
|
|
567
|
+
label: '2222',
|
|
568
|
+
prop: 'address',
|
|
569
|
+
minWidth: '134px'
|
|
570
|
+
},
|
|
571
|
+
]
|
|
572
|
+
|
|
549
573
|
},
|
|
550
574
|
{
|
|
551
575
|
label: '标签',
|
package/package.json
CHANGED
|
@@ -9,7 +9,9 @@
|
|
|
9
9
|
:minWidth="item.minWidth"
|
|
10
10
|
v-model:filtersValue="filtersValue"
|
|
11
11
|
showOverflowTooltip
|
|
12
|
-
|
|
12
|
+
:children="item.children||[]"
|
|
13
|
+
>
|
|
14
|
+
</MTableColumn>
|
|
13
15
|
</el-table>
|
|
14
16
|
</div>
|
|
15
17
|
</template>
|
|
@@ -65,8 +67,30 @@ const tableTitle = [
|
|
|
65
67
|
},
|
|
66
68
|
{
|
|
67
69
|
label: '地址',
|
|
68
|
-
|
|
69
|
-
|
|
70
|
+
children: [
|
|
71
|
+
{
|
|
72
|
+
label: '123', children: [
|
|
73
|
+
{
|
|
74
|
+
label: '222222222222',
|
|
75
|
+
prop: 'address',
|
|
76
|
+
minWidth: '134px'
|
|
77
|
+
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
label: 'qqqqqq',
|
|
81
|
+
prop: 'address',
|
|
82
|
+
minWidth: '134px'
|
|
83
|
+
|
|
84
|
+
}
|
|
85
|
+
]
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
label: '2222',
|
|
89
|
+
prop: 'address',
|
|
90
|
+
minWidth: '134px'
|
|
91
|
+
},
|
|
92
|
+
]
|
|
93
|
+
|
|
70
94
|
},
|
|
71
95
|
{
|
|
72
96
|
label: '标签',
|
|
@@ -11,6 +11,17 @@
|
|
|
11
11
|
:index="scope.$index"
|
|
12
12
|
></slot>
|
|
13
13
|
</template>
|
|
14
|
+
<template v-if="props.children && props.children.length">
|
|
15
|
+
<index
|
|
16
|
+
v-for="child in props.children"
|
|
17
|
+
:key="child.prop"
|
|
18
|
+
:prop="child.prop"
|
|
19
|
+
:label="child.label"
|
|
20
|
+
:minWidth="child.minWidth"
|
|
21
|
+
showOverflowTooltip
|
|
22
|
+
:children="child.children || []"
|
|
23
|
+
></index>
|
|
24
|
+
</template>
|
|
14
25
|
<template #header="scope">
|
|
15
26
|
<span>
|
|
16
27
|
<slot
|
|
@@ -95,14 +106,21 @@ interface FilterValue {
|
|
|
95
106
|
[key: string]: Array<string | number>
|
|
96
107
|
}
|
|
97
108
|
|
|
109
|
+
interface PropChildren {
|
|
110
|
+
[prop: string]: any,
|
|
111
|
+
children?: PropChildren[]
|
|
112
|
+
}
|
|
113
|
+
|
|
98
114
|
const props = withDefaults(defineProps<{
|
|
99
115
|
filtersValue?: FilterValue,
|
|
100
116
|
filters?: Array<{ text: string | number, value: string | number }>,
|
|
101
|
-
filterMethod?: Function
|
|
117
|
+
filterMethod?: Function,
|
|
118
|
+
children?: Array<PropChildren>
|
|
102
119
|
}>(), {
|
|
103
120
|
filtersValue: () => ({}),
|
|
104
121
|
filters: () => [],
|
|
105
|
-
filterMethod: () => {}
|
|
122
|
+
filterMethod: () => {},
|
|
123
|
+
children: () => []
|
|
106
124
|
})
|
|
107
125
|
|
|
108
126
|
const slots = useSlots()
|