@truenewx/tnxvue3 3.0.0-alpha.26 → 3.0.0-alpha.27
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@truenewx/tnxvue3",
|
|
3
|
-
"version": "3.0.0-alpha.
|
|
3
|
+
"version": "3.0.0-alpha.27",
|
|
4
4
|
"description": "互联网技术解决方案:Vue3扩展支持",
|
|
5
5
|
"private": false,
|
|
6
6
|
"publishConfig": {
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
"vue-router": "~4.4.0"
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"@truenewx/tnxcore": "3.0.0-alpha.
|
|
27
|
+
"@truenewx/tnxcore": "3.0.0-alpha.15",
|
|
28
28
|
"@element-plus/icons-vue": "2.3.1",
|
|
29
29
|
"async-validator": "4.2.5",
|
|
30
30
|
"mitt": "3.0.1"
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<el-tooltip :content="tooltipContent" :placement="tooltipPlacement" :disabled="disabled || !tooltipContent"
|
|
3
|
-
|
|
3
|
+
v-if="disabled === false || disabledTip !== false">
|
|
4
4
|
<el-dropdown split-button :type="type" :class="className" :disabled="disabled" :title="title" :size="size"
|
|
5
|
-
|
|
5
|
+
:style="$attrs.style" @click="clickButton" @command="clickItem" v-if="dropdownItems.length">
|
|
6
6
|
<i :class="icon" style="margin-right: 0.5rem;" v-if="icon"></i>
|
|
7
7
|
<template v-if="!hiddenCaption">
|
|
8
8
|
<slot v-if="$slots.default"></slot>
|
|
@@ -11,18 +11,18 @@
|
|
|
11
11
|
<template #dropdown>
|
|
12
12
|
<el-dropdown-menu>
|
|
13
13
|
<el-dropdown-item v-for="dropdownItem of dropdownItems" :key="dropdownItem.path"
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
:icon="dropdownItem.icon" :disabled="dropdownItem.disabled"
|
|
15
|
+
:title="dropdownItem.title"
|
|
16
|
+
:command="dropdownItem">
|
|
17
17
|
{{ dropdownItem.caption || (dropdownItem.menuItem ? dropdownItem.menuItem.caption : '') }}
|
|
18
18
|
</el-dropdown-item>
|
|
19
19
|
</el-dropdown-menu>
|
|
20
20
|
</template>
|
|
21
21
|
</el-dropdown>
|
|
22
22
|
<el-button :type="type" :class="className" :disabled="disabled" :title="title" @click="clickButton" :size="size"
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
23
|
+
:loading="loading" :plain="plain" :link="link" :bg="bg" :autofocus="autofocus"
|
|
24
|
+
:round="round"
|
|
25
|
+
:circle="circle" :style="$attrs.style" v-else>
|
|
26
26
|
<tnxel-icon :value="icon" v-if="icon"/>
|
|
27
27
|
<span v-if="!hiddenCaption && ($slots.default || menuItem)">
|
|
28
28
|
<slot>{{ menuItem ? menuItem.caption : '' }}</slot>
|
|
@@ -56,7 +56,6 @@ export default {
|
|
|
56
56
|
loading: Boolean,
|
|
57
57
|
plain: Boolean,
|
|
58
58
|
link: Boolean,
|
|
59
|
-
text: Boolean,
|
|
60
59
|
bg: Boolean,
|
|
61
60
|
autofocus: Boolean,
|
|
62
61
|
round: Boolean,
|
|
@@ -12,13 +12,13 @@
|
|
|
12
12
|
<el-table-column label="排序" align="center" width="60px" v-if="sortable">
|
|
13
13
|
<template #default="scope">
|
|
14
14
|
<tnxel-button
|
|
15
|
-
type="
|
|
15
|
+
type="primary" link
|
|
16
16
|
icon="Top"
|
|
17
17
|
:class="{'text-transparent': scope.$index === 0}"
|
|
18
18
|
@click="sortUp(scope.$index)"
|
|
19
19
|
/>
|
|
20
20
|
<tnxel-button
|
|
21
|
-
type="
|
|
21
|
+
type="primary" link
|
|
22
22
|
icon="Bottom"
|
|
23
23
|
class="ms-0"
|
|
24
24
|
:class="{'text-transparent': scope.$index === data.length - 1}"
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
<el-table-column label="移除" align="center" width="60px" v-if="removable">
|
|
30
30
|
<template #default="scope">
|
|
31
31
|
<tnxel-button
|
|
32
|
-
type="primary"
|
|
32
|
+
type="primary" link
|
|
33
33
|
icon="CircleClose"
|
|
34
34
|
:tooltip="scope.row.removeTip"
|
|
35
35
|
@click="toRemoveRow(scope.$index)"
|
|
@@ -37,13 +37,9 @@
|
|
|
37
37
|
</template>
|
|
38
38
|
</el-table-column>
|
|
39
39
|
</el-table>
|
|
40
|
-
<
|
|
41
|
-
<
|
|
42
|
-
|
|
43
|
-
<tnxel-button type="text" icon="Plus" @click="toAddRow">{{ addText }}</tnxel-button>
|
|
44
|
-
</template>
|
|
45
|
-
</el-table-column>
|
|
46
|
-
</el-table>
|
|
40
|
+
<div class="tnxel-edit-table-footer" v-if="addable">
|
|
41
|
+
<tnxel-button type="primary" link icon="Plus" @click="toAddRow">{{ addText }}</tnxel-button>
|
|
42
|
+
</div>
|
|
47
43
|
</div>
|
|
48
44
|
</template>
|
|
49
45
|
|
|
@@ -335,7 +331,8 @@ export default {
|
|
|
335
331
|
padding: 0;
|
|
336
332
|
}
|
|
337
333
|
|
|
338
|
-
.tnxel-edit-table-container .el-table.padding-none .el-table__body-wrapper .el-input__wrapper
|
|
334
|
+
.tnxel-edit-table-container .el-table.padding-none .el-table__body-wrapper .el-input__wrapper,
|
|
335
|
+
.tnxel-edit-table-container .el-table.padding-none .el-table__body-wrapper .el-select__wrapper {
|
|
339
336
|
border-radius: 0;
|
|
340
337
|
height: 32px;
|
|
341
338
|
}
|
|
@@ -394,11 +391,15 @@ export default {
|
|
|
394
391
|
}
|
|
395
392
|
|
|
396
393
|
.tnxel-edit-table-container .tnxel-edit-table-footer {
|
|
397
|
-
border-
|
|
394
|
+
border-left: 1px solid var(--el-border-color);
|
|
395
|
+
border-right: 1px solid var(--el-border-color);
|
|
396
|
+
border-bottom: 1px solid var(--el-border-color);
|
|
397
|
+
height: 32px;
|
|
398
|
+
display: flex;
|
|
399
|
+
align-items: center;
|
|
398
400
|
}
|
|
399
401
|
|
|
400
|
-
.tnxel-edit-table-container .tnxel-edit-table-footer .el-
|
|
401
|
-
|
|
402
|
-
padding-bottom: 3px;
|
|
402
|
+
.tnxel-edit-table-container .tnxel-edit-table-footer .el-button {
|
|
403
|
+
width: 100%;
|
|
403
404
|
}
|
|
404
405
|
</style>
|
|
@@ -1,41 +1,41 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<span v-if="item">{{ item.caption }}</span>
|
|
3
|
-
</template>
|
|
4
|
-
|
|
5
|
-
<script>
|
|
6
|
-
export default {
|
|
7
|
-
name: 'TnxelEnumView',
|
|
8
|
-
props: {
|
|
9
|
-
type: {
|
|
10
|
-
type: String,
|
|
11
|
-
required: true,
|
|
12
|
-
},
|
|
13
|
-
subtype: String,
|
|
14
|
-
itemKey: {
|
|
15
|
-
type: String,
|
|
16
|
-
required: true,
|
|
17
|
-
},
|
|
18
|
-
app: {
|
|
19
|
-
type: String,
|
|
20
|
-
default: () => window.tnx.componentDefaultApp, // 设置为方法以延时加载,确保更改的值生效
|
|
21
|
-
},
|
|
22
|
-
},
|
|
23
|
-
data() {
|
|
24
|
-
return {
|
|
25
|
-
item: null,
|
|
26
|
-
};
|
|
27
|
-
},
|
|
28
|
-
mounted() {
|
|
29
|
-
window.tnx.app.rpc.loadEnumType(this.type, this.subtype, enumType => {
|
|
30
|
-
this.item = enumType.items.find(item => item.key === this.itemKey);
|
|
31
|
-
}, {
|
|
32
|
-
app: this.app,
|
|
33
|
-
});
|
|
34
|
-
},
|
|
35
|
-
methods: {}
|
|
36
|
-
}
|
|
37
|
-
</script>
|
|
38
|
-
|
|
39
|
-
<style scoped>
|
|
40
|
-
|
|
41
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<span v-if="item">{{ item.caption }}</span>
|
|
3
|
+
</template>
|
|
4
|
+
|
|
5
|
+
<script>
|
|
6
|
+
export default {
|
|
7
|
+
name: 'TnxelEnumView',
|
|
8
|
+
props: {
|
|
9
|
+
type: {
|
|
10
|
+
type: String,
|
|
11
|
+
required: true,
|
|
12
|
+
},
|
|
13
|
+
subtype: String,
|
|
14
|
+
itemKey: {
|
|
15
|
+
type: String,
|
|
16
|
+
required: true,
|
|
17
|
+
},
|
|
18
|
+
app: {
|
|
19
|
+
type: String,
|
|
20
|
+
default: () => window.tnx.componentDefaultApp, // 设置为方法以延时加载,确保更改的值生效
|
|
21
|
+
},
|
|
22
|
+
},
|
|
23
|
+
data() {
|
|
24
|
+
return {
|
|
25
|
+
item: null,
|
|
26
|
+
};
|
|
27
|
+
},
|
|
28
|
+
mounted() {
|
|
29
|
+
window.tnx.app.rpc.loadEnumType(this.type, this.subtype, enumType => {
|
|
30
|
+
this.item = enumType.items.find(item => item.key === this.itemKey);
|
|
31
|
+
}, {
|
|
32
|
+
app: this.app,
|
|
33
|
+
});
|
|
34
|
+
},
|
|
35
|
+
methods: {}
|
|
36
|
+
}
|
|
37
|
+
</script>
|
|
38
|
+
|
|
39
|
+
<style scoped>
|
|
40
|
+
|
|
41
|
+
</style>
|
|
@@ -34,6 +34,7 @@
|
|
|
34
34
|
<Memo v-else-if="value === 'Memo'"/>
|
|
35
35
|
<Minus v-else-if="value === 'Minus'"/>
|
|
36
36
|
<MoreFilled v-else-if="value === 'MoreFilled'"/>
|
|
37
|
+
<Notebook v-else-if="value === 'Notebook'"/>
|
|
37
38
|
<OfficeBuilding v-else-if="value === 'OfficeBuilding'"/>
|
|
38
39
|
<Picture v-else-if="value === 'Picture'"/>
|
|
39
40
|
<PictureFilled v-else-if="value === 'PictureFilled'"/>
|
|
@@ -96,6 +97,7 @@ import {
|
|
|
96
97
|
Memo,
|
|
97
98
|
Minus,
|
|
98
99
|
MoreFilled,
|
|
100
|
+
Notebook,
|
|
99
101
|
OfficeBuilding,
|
|
100
102
|
Picture,
|
|
101
103
|
PictureFilled,
|
|
@@ -155,6 +157,7 @@ const components = {
|
|
|
155
157
|
Memo,
|
|
156
158
|
Minus,
|
|
157
159
|
MoreFilled,
|
|
160
|
+
Notebook,
|
|
158
161
|
Loading,
|
|
159
162
|
OfficeBuilding,
|
|
160
163
|
Picture,
|