@cloudbase/weda-ui 3.4.11 → 3.4.13
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/dist/configs/components/common/form-input-required.js +3 -3
- package/dist/configs/components/customer-service.js +3 -0
- package/dist/configs/components/dataView.js +20 -10
- package/dist/configs/components/form-checkbox.js +15 -2
- package/dist/configs/components/form-date.js +1 -1
- package/dist/configs/components/form-depart-tree-select.js +1 -1
- package/dist/configs/components/form-email.js +17 -2
- package/dist/configs/components/form-input.js +17 -2
- package/dist/configs/components/form-location.js +1 -1
- package/dist/configs/components/form-multi-region.js +1 -1
- package/dist/configs/components/form-phone.js +17 -2
- package/dist/configs/components/form-radio.js +15 -2
- package/dist/configs/components/form-rich-text.js +1 -1
- package/dist/configs/components/form-select-multiple.js +362 -0
- package/dist/configs/components/form-select.js +1 -1
- package/dist/configs/components/form-switch.js +16 -3
- package/dist/configs/components/form-text-area.js +15 -2
- package/dist/configs/components/form-time.js +1 -1
- package/dist/configs/components/form-url.js +17 -2
- package/dist/configs/components/form-user-tree-select.js +14 -1
- package/dist/configs/components/listView.js +32 -49
- package/dist/configs/components/table.json +1 -54
- package/dist/configs/components/wd-bubble.js +46 -8
- package/dist/configs/components/wd-button.js +3 -0
- package/dist/configs/components/wd-checkbox.js +464 -0
- package/dist/configs/components/wd-form.js +66 -10
- package/dist/configs/components/wd-input-email.js +37 -0
- package/dist/configs/components/wd-input-phone.js +43 -0
- package/dist/configs/components/wd-input-url.js +37 -0
- package/dist/configs/components/wd-input.js +94 -0
- package/dist/configs/components/wd-official-account.js +87 -0
- package/dist/configs/components/wd-radio.js +443 -0
- package/dist/configs/components/wd-switch.js +315 -0
- package/dist/configs/components/wd-table.js +11 -59
- package/dist/configs/components/wd-textarea.js +82 -0
- package/dist/configs/components/wd-tree.js +443 -0
- package/dist/configs/components/web-view.js +3 -0
- package/dist/configs/index.js +24 -1
- package/dist/configs/type-utils/type-form.js +681 -0
- package/dist/docs/common/components/json-schema-view.js +1 -1
- package/dist/docs/common/components/methods-view.js +1 -1
- package/dist/docs/common/components/properties-view.js +3 -1
- package/dist/docs/common/format.js +7 -7
- package/dist/docs/common/tableView.js +3 -1
- package/dist/enum/index.js +196 -0
- package/dist/style/index.scss +1 -1
- package/dist/web/actions/showMessage/index.js +4 -1
- package/dist/web/components/carousel/index.js +1 -1
- package/dist/web/components/customer-service/customer-service.js +19 -2
- package/dist/web/components/dataView/index.js +16 -3
- package/dist/web/components/flow/common/hooks/useCommonFlowData/flow-get.js +5 -1
- package/dist/web/components/flow/common/request.js +5 -5
- package/dist/web/components/flow/modules/operations/controls-items/flow-task-info-modal.js +90 -0
- package/dist/web/components/form/formcell/index.css +13 -1
- package/dist/web/components/form/formcell/index.js +1 -1
- package/dist/web/components/form/location/components/LocationH5/location.h5.js +1 -1
- package/dist/web/components/form/select/dropdown-select/index.js +9 -3
- package/dist/web/components/form/select/h5.js +18 -8
- package/dist/web/components/form/select/index.js +9 -10
- package/dist/web/components/form/select/region/index.js +1 -1
- package/dist/web/components/form/selectMultiple/dropdown-select/h5.js +111 -0
- package/dist/web/components/form/selectMultiple/dropdown-select/index.css +270 -0
- package/dist/web/components/form/selectMultiple/dropdown-select/index.js +206 -0
- package/dist/web/components/form/selectMultiple/dropdown-select/pc.js +115 -0
- package/dist/web/components/form/selectMultiple/dropdown-select/ui.js +113 -0
- package/dist/web/components/form/selectMultiple/h5.js +40 -0
- package/dist/web/components/form/selectMultiple/index.js +94 -0
- package/dist/web/components/form/selectMultiple/request.js +76 -0
- package/dist/web/components/form/selectMultiple/status/allEmpty.js +5 -0
- package/dist/web/components/form/selectMultiple/status/empty.js +19 -0
- package/dist/web/components/form/selectMultiple/status/index.css +63 -0
- package/dist/web/components/form/selectMultiple/status/index.js +7 -0
- package/dist/web/components/form/selectMultiple/status/loading.js +19 -0
- package/dist/web/components/form/selectMultiple/status/propsType.js +1 -0
- package/dist/web/components/form/selectMultiple/status/retry.js +19 -0
- package/dist/web/components/form/tips/index.css +9 -3
- package/dist/web/components/form/uploader/index.css +10 -0
- package/dist/web/components/form/uploader/uploader.h5.js +60 -62
- package/dist/web/components/form/uploader/uploader.pc.js +48 -41
- package/dist/web/components/form/uploaderFile/uploadFile.h5.js +8 -33
- package/dist/web/components/form/uploaderFile/uploadFile.pc.js +8 -37
- package/dist/web/components/form/userOrgSelect/common/fetch-data-service.js +76 -50
- package/dist/web/components/form/userOrgSelect/common/utils.js +24 -8
- package/dist/web/components/form/userOrgSelect/component/depart-select/depart-select-pc.js +3 -8
- package/dist/web/components/form/userOrgSelect/component/depart-select/index.js +14 -18
- package/dist/web/components/form/userOrgSelect/component/depart-select/org-modal-pc.js +20 -14
- package/dist/web/components/form/userOrgSelect/component/modal-select-h5.js +1 -1
- package/dist/web/components/form/userOrgSelect/component/org-tree.js +21 -9
- package/dist/web/components/form/userOrgSelect/component/user-select-h5/index.js +76 -15
- package/dist/web/components/form/userOrgSelect/component/user-select-pc/user-model.js +2 -7
- package/dist/web/components/form/userOrgSelect/component/user-select-pc/user-select-pc.js +6 -4
- package/dist/web/components/form/userOrgSelect/component/userOrgSelect.css +8 -2
- package/dist/web/components/form/userOrgSelect/departTreeSelect/departTreeSelect.h5.js +25 -51
- package/dist/web/components/form/userOrgSelect/hooks/use-depart-data.js +10 -6
- package/dist/web/components/form-input-hooks/index.js +41 -15
- package/dist/web/components/form-select-multiple/index.js +26 -0
- package/dist/web/components/form-upload-file/index.js +0 -1
- package/dist/web/components/form-user-tree-select/index.js +2 -2
- package/dist/web/components/formdetail/index.css +31 -1
- package/dist/web/components/formdetail/index.js +33 -1
- package/dist/web/components/index.js +27 -11
- package/dist/web/components/listView/index.js +20 -5
- package/dist/web/components/navigationBar/common.js +1 -1
- package/dist/web/components/navigationBar/horizontalMenu.js +1 -1
- package/dist/web/components/navigationBar/index.css +11 -0
- package/dist/web/components/navigationBar/index.js +8 -1
- package/dist/web/components/phone/index.js +26 -1
- package/dist/web/components/phoneCode/index.js +3 -1
- package/dist/web/components/richText/index.css +70 -67
- package/dist/web/components/richText/index.js +311 -251
- package/dist/web/components/richText/richtext.module.css +1 -0
- package/dist/web/components/richTextView/index.css +39 -0
- package/dist/web/components/richTextView/index.js +1 -1
- package/dist/web/components/share/index.js +26 -1
- package/dist/web/components/table/ImportFileModalByApi/uploadCSVFile.js +1 -1
- package/dist/web/components/wd-checkbox/checkbox.js +34 -0
- package/dist/web/components/wd-checkbox/index.js +3 -0
- package/dist/web/components/wd-checkbox-list/checkboxList.js +140 -0
- package/dist/web/components/wd-checkbox-list/index.js +3 -0
- package/dist/web/components/wd-form/hooks/use-remote-value.js +9 -2
- package/dist/web/components/wd-form/index.js +69 -34
- package/dist/web/components/wd-form/wd-form.js +42 -0
- package/dist/web/components/wd-form-cell/index.js +3 -0
- package/dist/web/components/wd-form-cell/wd-form-cell.js +42 -0
- package/dist/web/components/wd-form-item/index.js +4 -0
- package/dist/web/components/wd-form-item/wd-form-item.js +55 -0
- package/dist/web/components/wd-form-item/wd-input-group.js +24 -0
- package/dist/web/components/wd-icon/wd-icon.js +10 -2
- package/dist/web/components/wd-input/index.js +3 -0
- package/dist/web/components/wd-input/wd-input.js +155 -0
- package/dist/web/components/wd-input-email/index.js +3 -0
- package/dist/web/components/wd-input-email/wd-input-email.js +13 -0
- package/dist/web/components/wd-input-group/index.js +3 -0
- package/dist/web/components/wd-input-group/wd-input-group.js +10 -0
- package/dist/web/components/wd-input-phone/index.js +3 -0
- package/dist/web/components/wd-input-phone/wd-input-phone.js +14 -0
- package/dist/web/components/wd-input-url/index.js +3 -0
- package/dist/web/components/wd-input-url/wd-input-url.js +13 -0
- package/dist/web/components/wd-input-wrap/index.js +3 -0
- package/dist/web/components/wd-input-wrap/wd-input-wrap.js +18 -0
- package/dist/web/components/wd-official-account/index.css +29 -0
- package/dist/web/components/wd-official-account/index.js +36 -0
- package/dist/web/components/wd-radio/index.js +3 -0
- package/dist/web/components/wd-radio/wd-radio.js +30 -0
- package/dist/web/components/wd-radio-list/index.js +3 -0
- package/dist/web/components/wd-radio-list/wd-radio-list.js +104 -0
- package/dist/web/components/wd-switch/index.js +3 -0
- package/dist/web/components/wd-switch/wd-switch.js +52 -0
- package/dist/web/components/wd-table/components/FieldRender/index.js +5 -4
- package/dist/web/components/wd-table/components/FilterFieldsPanel/FilterFieldItem.js +4 -0
- package/dist/web/components/wd-table/components/Table/index.js +40 -9
- package/dist/web/components/wd-table/hooks/useQueryParams.js +4 -1
- package/dist/web/components/wd-table/hooks/useTableData.js +6 -1
- package/dist/web/components/wd-table/hooks/useViewFields.js +1 -1
- package/dist/web/components/wd-table/utils/index.js +6 -2
- package/dist/web/components/wd-table/wd-table.js +125 -99
- package/dist/web/components/wd-textarea/index.js +3 -0
- package/dist/web/components/wd-textarea/wd-textarea.js +78 -0
- package/dist/web/components/wd-tree/index.js +3 -0
- package/dist/web/components/wd-tree/utils.js +291 -0
- package/dist/web/components/wd-tree/wd-tree.js +193 -0
- package/dist/web/utils/constant.js +16 -0
- package/dist/web/utils/datasource.js +2 -2
- package/dist/web/utils/date.js +3 -3
- package/dist/web/utils/hooks/useFormLegacy.js +112 -0
- package/dist/web/utils/tool.js +12 -2
- package/dist/web/weda-ui.css +197 -3
- package/package.json +6 -5
|
@@ -0,0 +1,362 @@
|
|
|
1
|
+
import { defineConfig, Tuple, Type, } from '../type-utils';
|
|
2
|
+
const data = Type.Object({
|
|
3
|
+
name: Type.String({
|
|
4
|
+
type: 'string',
|
|
5
|
+
title: '绑定字段',
|
|
6
|
+
default: 'formSelectMultiple',
|
|
7
|
+
remarks: '提交表单时会将组件值提交保存到所配置的字段中',
|
|
8
|
+
'x-index': 5,
|
|
9
|
+
'x-rules': [
|
|
10
|
+
{
|
|
11
|
+
message: '该字段必填',
|
|
12
|
+
required: true,
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
message: '必须以字母开头,仅能输入字母或下划线或数字',
|
|
16
|
+
pattern: '^[a-zA-Z][0-9a-zA-Z_]*$',
|
|
17
|
+
},
|
|
18
|
+
],
|
|
19
|
+
required: true,
|
|
20
|
+
'x-category': '基础属性',
|
|
21
|
+
description: '表单字段的Key值,用于提交数据时,匹配数据模型字段标识。页面内需保证唯一。',
|
|
22
|
+
}),
|
|
23
|
+
label: Type.String({
|
|
24
|
+
type: 'string',
|
|
25
|
+
title: '字段标题',
|
|
26
|
+
default: '下拉多选',
|
|
27
|
+
remarks: '组件标题位置的显示内容',
|
|
28
|
+
'x-index': 10,
|
|
29
|
+
'x-category': '基础属性',
|
|
30
|
+
}),
|
|
31
|
+
labelVisible: Type.Boolean({
|
|
32
|
+
type: 'boolean',
|
|
33
|
+
title: '显示标题',
|
|
34
|
+
default: true,
|
|
35
|
+
remarks: '显示组件的标题',
|
|
36
|
+
'x-index': 15,
|
|
37
|
+
'x-category': '基础属性',
|
|
38
|
+
}),
|
|
39
|
+
placeholder: Type.String({
|
|
40
|
+
type: 'string',
|
|
41
|
+
title: '提示文字',
|
|
42
|
+
default: '请选择',
|
|
43
|
+
remarks: '用于说明组件用途或注意事项的提示文字',
|
|
44
|
+
'x-index': 16,
|
|
45
|
+
'x-category': '基础属性',
|
|
46
|
+
}),
|
|
47
|
+
value: Type.Array(Type.String({
|
|
48
|
+
type: 'string',
|
|
49
|
+
title: 'value',
|
|
50
|
+
}), {
|
|
51
|
+
type: 'array',
|
|
52
|
+
title: '选中值',
|
|
53
|
+
default: [],
|
|
54
|
+
remarks: '默认选中的选项',
|
|
55
|
+
'x-index': 25,
|
|
56
|
+
inputProp: {
|
|
57
|
+
changeEvent: 'change',
|
|
58
|
+
valueFromEvent: 'event.detail.value',
|
|
59
|
+
},
|
|
60
|
+
'x-category': '基础属性',
|
|
61
|
+
}),
|
|
62
|
+
required: Type.Boolean({
|
|
63
|
+
type: 'boolean',
|
|
64
|
+
title: '必填',
|
|
65
|
+
default: false,
|
|
66
|
+
remarks: '启用后该组件强制必填,值不可为空',
|
|
67
|
+
'x-index': 30,
|
|
68
|
+
'x-category': '基础属性',
|
|
69
|
+
'x-linkages': [
|
|
70
|
+
{
|
|
71
|
+
type: 'value:visible',
|
|
72
|
+
target: '*(requiredFlag,requiredMsg)',
|
|
73
|
+
condition: '{{$self.value}}',
|
|
74
|
+
},
|
|
75
|
+
],
|
|
76
|
+
}),
|
|
77
|
+
requiredFlag: Type.Boolean({
|
|
78
|
+
type: 'boolean',
|
|
79
|
+
title: '必填标识',
|
|
80
|
+
default: true,
|
|
81
|
+
remarks: '启用后,组件若要求必填,则会显示必填星号标记',
|
|
82
|
+
'x-index': 35,
|
|
83
|
+
'x-category': '基础属性',
|
|
84
|
+
}),
|
|
85
|
+
requiredMsg: Type.String({
|
|
86
|
+
type: 'string',
|
|
87
|
+
title: '必填校验提示',
|
|
88
|
+
default: '该项为必填项',
|
|
89
|
+
remarks: '启用必填,但组件值为空时的提示信息',
|
|
90
|
+
'x-index': 40,
|
|
91
|
+
'x-category': '基础属性',
|
|
92
|
+
}),
|
|
93
|
+
layout: Type.StringEnum({
|
|
94
|
+
enum: Tuple([
|
|
95
|
+
{
|
|
96
|
+
label: '自动',
|
|
97
|
+
value: '',
|
|
98
|
+
},
|
|
99
|
+
{
|
|
100
|
+
label: '水平',
|
|
101
|
+
value: 'horizontal',
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
label: '垂直',
|
|
105
|
+
value: 'vertical',
|
|
106
|
+
},
|
|
107
|
+
]),
|
|
108
|
+
type: 'string',
|
|
109
|
+
title: '布局方式',
|
|
110
|
+
default: '',
|
|
111
|
+
remarks: '设置当前组件的标题和输入选择区域为左右布局或上下布局,如选择“自动”,则跟随父级表单容器的配置',
|
|
112
|
+
'x-index': 105,
|
|
113
|
+
'x-category': '高级属性',
|
|
114
|
+
}),
|
|
115
|
+
disabled: Type.Boolean({
|
|
116
|
+
type: 'boolean',
|
|
117
|
+
title: '禁用',
|
|
118
|
+
default: false,
|
|
119
|
+
remarks: '是否禁用输入/选择,启用后组件强制显示为只读效果',
|
|
120
|
+
'x-index': 113,
|
|
121
|
+
'x-category': '高级属性',
|
|
122
|
+
}),
|
|
123
|
+
range: Type.Array(Type.Object({
|
|
124
|
+
label: Type.String({
|
|
125
|
+
type: 'string',
|
|
126
|
+
title: '选项名称',
|
|
127
|
+
default: '选项名称',
|
|
128
|
+
}),
|
|
129
|
+
value: Type.String({
|
|
130
|
+
type: 'string',
|
|
131
|
+
title: '选项值',
|
|
132
|
+
default: '选项值',
|
|
133
|
+
}),
|
|
134
|
+
}, {
|
|
135
|
+
type: 'object',
|
|
136
|
+
default: {
|
|
137
|
+
label: '选项名称',
|
|
138
|
+
value: '选项值',
|
|
139
|
+
},
|
|
140
|
+
display: 'label',
|
|
141
|
+
}), {
|
|
142
|
+
type: 'array',
|
|
143
|
+
title: '选项',
|
|
144
|
+
default: [
|
|
145
|
+
{
|
|
146
|
+
label: '选项名称',
|
|
147
|
+
value: '选项值',
|
|
148
|
+
},
|
|
149
|
+
],
|
|
150
|
+
remarks: '供用户进行选择的选项列表',
|
|
151
|
+
'x-index': 140,
|
|
152
|
+
'x-props': {
|
|
153
|
+
'data-withBindMeta': true,
|
|
154
|
+
},
|
|
155
|
+
'x-category': '基础属性',
|
|
156
|
+
'x-component': 'list-bind-switch',
|
|
157
|
+
'x-component-props': {
|
|
158
|
+
'origin-component': 'list',
|
|
159
|
+
},
|
|
160
|
+
}),
|
|
161
|
+
size: Type.StringEnum({
|
|
162
|
+
enum: Tuple([
|
|
163
|
+
{
|
|
164
|
+
label: '大',
|
|
165
|
+
value: 'l',
|
|
166
|
+
},
|
|
167
|
+
{
|
|
168
|
+
label: '中',
|
|
169
|
+
value: 'm',
|
|
170
|
+
},
|
|
171
|
+
{
|
|
172
|
+
label: '小',
|
|
173
|
+
value: 's',
|
|
174
|
+
},
|
|
175
|
+
{
|
|
176
|
+
label: '占满',
|
|
177
|
+
value: 'full',
|
|
178
|
+
},
|
|
179
|
+
]),
|
|
180
|
+
type: 'string',
|
|
181
|
+
title: '组件宽度',
|
|
182
|
+
default: 'full',
|
|
183
|
+
'x-index': 165,
|
|
184
|
+
'x-category': '基础属性',
|
|
185
|
+
'x-platforms': ['PCWEB'],
|
|
186
|
+
}),
|
|
187
|
+
// where: Type.Array(Type.Any(), {
|
|
188
|
+
// type: 'array',
|
|
189
|
+
// items: {},
|
|
190
|
+
// title: '选项筛选',
|
|
191
|
+
// 'x-props': {
|
|
192
|
+
// 'data-hidebind': true,
|
|
193
|
+
// 'data-withBindMeta': true,
|
|
194
|
+
// 'data-hideBindValue': true,
|
|
195
|
+
// },
|
|
196
|
+
// 'x-category': '基础属性',
|
|
197
|
+
// 'x-component': 'condition-select',
|
|
198
|
+
// 'x-component-props': {
|
|
199
|
+
// selectedDsName: '',
|
|
200
|
+
// blackListConfig: {
|
|
201
|
+
// type: ['object', 'array'],
|
|
202
|
+
// format: ['x-file', 'x-image'],
|
|
203
|
+
// },
|
|
204
|
+
// customRelOptions: {
|
|
205
|
+
// number: [
|
|
206
|
+
// {
|
|
207
|
+
// text: '等于',
|
|
208
|
+
// type: 'equal',
|
|
209
|
+
// value: 'equal',
|
|
210
|
+
// },
|
|
211
|
+
// {
|
|
212
|
+
// text: '不等于',
|
|
213
|
+
// value: 'unequal',
|
|
214
|
+
// },
|
|
215
|
+
// {
|
|
216
|
+
// text: '大于',
|
|
217
|
+
// type: 'greate',
|
|
218
|
+
// value: 'greater',
|
|
219
|
+
// },
|
|
220
|
+
// {
|
|
221
|
+
// text: '大于等于',
|
|
222
|
+
// type: 'greater_or_equal',
|
|
223
|
+
// value: 'greater_or_equal',
|
|
224
|
+
// },
|
|
225
|
+
// {
|
|
226
|
+
// text: '小于',
|
|
227
|
+
// type: 'less',
|
|
228
|
+
// value: 'less',
|
|
229
|
+
// },
|
|
230
|
+
// {
|
|
231
|
+
// text: '小于等于',
|
|
232
|
+
// type: 'less_or_equal',
|
|
233
|
+
// value: 'less_or_equal',
|
|
234
|
+
// },
|
|
235
|
+
// ],
|
|
236
|
+
// },
|
|
237
|
+
// customLogicOptions: [
|
|
238
|
+
// {
|
|
239
|
+
// text: '且',
|
|
240
|
+
// value: 'and',
|
|
241
|
+
// },
|
|
242
|
+
// {
|
|
243
|
+
// text: '或',
|
|
244
|
+
// value: 'or',
|
|
245
|
+
// },
|
|
246
|
+
// ],
|
|
247
|
+
// selectedDataSourceName: '',
|
|
248
|
+
// },
|
|
249
|
+
// }),
|
|
250
|
+
format: Type.StringEnum({
|
|
251
|
+
type: 'string',
|
|
252
|
+
title: '字段类型',
|
|
253
|
+
default: '',
|
|
254
|
+
enum: Tuple([
|
|
255
|
+
{ label: 'one-many', value: 'one-many' },
|
|
256
|
+
{ label: 'many-many', value: 'many-many' },
|
|
257
|
+
]),
|
|
258
|
+
'x-linkages': [
|
|
259
|
+
{
|
|
260
|
+
type: 'value:visible',
|
|
261
|
+
target: 'range',
|
|
262
|
+
condition: "{{$self.value!='many-many'&&$self.value!='one-many'}}",
|
|
263
|
+
},
|
|
264
|
+
{
|
|
265
|
+
type: 'value:visible',
|
|
266
|
+
target: 'tipBlock',
|
|
267
|
+
condition: "{{$self.value=='many-many'||$self.value=='one-many'}}",
|
|
268
|
+
},
|
|
269
|
+
// {
|
|
270
|
+
// type: 'value:visible',
|
|
271
|
+
// target: 'where',
|
|
272
|
+
// condition: "{{$self.value=='many-many'||$self.value=='one-many'}}",
|
|
273
|
+
// },
|
|
274
|
+
],
|
|
275
|
+
'x-platforms': [''],
|
|
276
|
+
}),
|
|
277
|
+
viewId: Type.String({
|
|
278
|
+
type: 'string',
|
|
279
|
+
title: '选项',
|
|
280
|
+
default: '',
|
|
281
|
+
'x-platforms': [''],
|
|
282
|
+
}),
|
|
283
|
+
enumName: Type.String({
|
|
284
|
+
type: 'string',
|
|
285
|
+
title: '字段类型',
|
|
286
|
+
default: '',
|
|
287
|
+
'x-platforms': [''],
|
|
288
|
+
}),
|
|
289
|
+
tipBlock: Type.String({
|
|
290
|
+
type: 'string',
|
|
291
|
+
title: '选项',
|
|
292
|
+
default: '',
|
|
293
|
+
'x-props': {
|
|
294
|
+
'data-hidebind': true,
|
|
295
|
+
},
|
|
296
|
+
'x-component': 'selection-tip',
|
|
297
|
+
}),
|
|
298
|
+
primaryField: Type.String({
|
|
299
|
+
type: 'string',
|
|
300
|
+
title: '主列名称',
|
|
301
|
+
default: '',
|
|
302
|
+
'x-platforms': [''],
|
|
303
|
+
}),
|
|
304
|
+
dataSourceName: Type.String({
|
|
305
|
+
type: 'string',
|
|
306
|
+
title: '父数据源名称',
|
|
307
|
+
default: '',
|
|
308
|
+
// 'x-linkages': [
|
|
309
|
+
// {
|
|
310
|
+
// type: 'value:schema',
|
|
311
|
+
// schema: {
|
|
312
|
+
// 'x-component-props': '{{{selectedDataSourceName: $self.value}}}',
|
|
313
|
+
// },
|
|
314
|
+
// target: 'where',
|
|
315
|
+
// },
|
|
316
|
+
// ],
|
|
317
|
+
'x-platforms': [''],
|
|
318
|
+
}),
|
|
319
|
+
});
|
|
320
|
+
const events = [
|
|
321
|
+
{
|
|
322
|
+
title: '值改变',
|
|
323
|
+
name: 'change',
|
|
324
|
+
},
|
|
325
|
+
{
|
|
326
|
+
title: '取消',
|
|
327
|
+
name: 'cancel',
|
|
328
|
+
},
|
|
329
|
+
];
|
|
330
|
+
const config = defineConfig({
|
|
331
|
+
$schema: 'https://comp-public-1303824488.cos.ap-shanghai.myqcloud.com/schema/lcds_component.json',
|
|
332
|
+
data,
|
|
333
|
+
events,
|
|
334
|
+
compConfig: {
|
|
335
|
+
componentType: 'formField',
|
|
336
|
+
},
|
|
337
|
+
meta: {
|
|
338
|
+
title: '下拉多选',
|
|
339
|
+
name: 'FormSelectMultiple',
|
|
340
|
+
componentName: 'MultipleSelect',
|
|
341
|
+
description: '以列表形式展示选项,用户可进行多选操作。',
|
|
342
|
+
category: '表单',
|
|
343
|
+
icon: '../icons/FormSelect.svg',
|
|
344
|
+
categoryOrder: 500,
|
|
345
|
+
componentOrder: 376,
|
|
346
|
+
visible: ['APP', 'COMPONENT'],
|
|
347
|
+
docsUrl: 'https://docs.cloudbase.net/lowcode/components/wedaUI/src/docs/compsdocs/form/FormSelectMultiple',
|
|
348
|
+
shortcut: {
|
|
349
|
+
props: ['name', 'label'],
|
|
350
|
+
},
|
|
351
|
+
recommendTypes: {
|
|
352
|
+
name: [
|
|
353
|
+
{
|
|
354
|
+
text: '一对多/多对多',
|
|
355
|
+
type: 'string',
|
|
356
|
+
format: 'one-many/many-many',
|
|
357
|
+
},
|
|
358
|
+
],
|
|
359
|
+
},
|
|
360
|
+
},
|
|
361
|
+
});
|
|
362
|
+
export default config;
|
|
@@ -336,7 +336,7 @@ const config = defineConfig({
|
|
|
336
336
|
title: '下拉选择',
|
|
337
337
|
name: 'FormSelect',
|
|
338
338
|
componentName: 'Select',
|
|
339
|
-
description: '
|
|
339
|
+
description: '以列表形式展示选项,用户可进行搜索和选择操作。',
|
|
340
340
|
category: '表单',
|
|
341
341
|
icon: '../icons/FormSelect.svg',
|
|
342
342
|
categoryOrder: 500,
|
|
@@ -124,15 +124,28 @@ const config = defineConfig({
|
|
|
124
124
|
},
|
|
125
125
|
events,
|
|
126
126
|
meta: {
|
|
127
|
-
title: '开关',
|
|
127
|
+
title: '开关[旧]',
|
|
128
128
|
name: 'FormSwitch',
|
|
129
129
|
componentName: 'Switch',
|
|
130
|
-
description: '
|
|
130
|
+
description: '用于控制是和否(布尔值)。',
|
|
131
131
|
category: '表单',
|
|
132
132
|
icon: '../icons/FormSwitch.svg',
|
|
133
133
|
categoryOrder: 500,
|
|
134
134
|
componentOrder: 440,
|
|
135
|
-
visible: [
|
|
135
|
+
visible: [],
|
|
136
|
+
disableUpgradeAll: true,
|
|
137
|
+
deprecated: true,
|
|
138
|
+
renderMode: [
|
|
139
|
+
{
|
|
140
|
+
component: 'WdSwitch',
|
|
141
|
+
renderType: 'update',
|
|
142
|
+
description: `- 支持标题、内容框的提示语配置;
|
|
143
|
+
- 支持标题的对齐、宽度、换行配置;
|
|
144
|
+
- 支持开关图标大中小可选择;
|
|
145
|
+
- 支持快捷去除移动端下划线;
|
|
146
|
+
- 支持通过标准化的样式API和CSS变量灵活修改和自定义组件样式;`,
|
|
147
|
+
},
|
|
148
|
+
],
|
|
136
149
|
},
|
|
137
150
|
configMeta: {
|
|
138
151
|
docsUrl: 'https://docs.cloudbase.net/lowcode/components/wedaUI/src/docs/compsdocs/form/FormSwitch',
|
|
@@ -231,11 +231,24 @@ const config = defineConfig({
|
|
|
231
231
|
description: '用于输入/查看较长文本内容。',
|
|
232
232
|
icon: '//imgcache.qq.com/qcloud/lowcode/static/ide/left-material-icon/TextArea.svg',
|
|
233
233
|
docsUrl: 'https://docs.cloudbase.net/lowcode/components/wedaUI/src/docs/compsdocs/form/FormTextarea',
|
|
234
|
-
title: '多行输入',
|
|
234
|
+
title: '多行输入[旧]',
|
|
235
235
|
category: '表单',
|
|
236
236
|
categoryOrder: 500,
|
|
237
237
|
componentOrder: 360,
|
|
238
|
-
visible: [
|
|
238
|
+
visible: [],
|
|
239
|
+
disableUpgradeAll: true,
|
|
240
|
+
deprecated: true,
|
|
241
|
+
renderMode: [
|
|
242
|
+
{
|
|
243
|
+
component: 'WdTextarea',
|
|
244
|
+
renderType: 'update',
|
|
245
|
+
description: `- 支持标题、输入框的提示语配置;
|
|
246
|
+
- 支持标题的对齐、宽度、换行配置;
|
|
247
|
+
- 支持支持控制限制字数的展示;
|
|
248
|
+
- 支持快捷去除移动端下划线、PC端输入边框;
|
|
249
|
+
- 支持通过标准化的样式API和CSS变量灵活修改和自定义组件样式;`,
|
|
250
|
+
},
|
|
251
|
+
],
|
|
239
252
|
},
|
|
240
253
|
});
|
|
241
254
|
export default config;
|
|
@@ -195,7 +195,7 @@ const config = defineConfig({
|
|
|
195
195
|
title: '时间选择',
|
|
196
196
|
name: 'FormTime',
|
|
197
197
|
componentName: 'TimeInput',
|
|
198
|
-
description: '
|
|
198
|
+
description: '用于选择时间,支持时分选择模式,例如22:30。',
|
|
199
199
|
icon: '../icons/FormTime.svg',
|
|
200
200
|
category: '表单',
|
|
201
201
|
categoryOrder: 500,
|
|
@@ -231,14 +231,29 @@ const config = defineConfig({
|
|
|
231
231
|
events,
|
|
232
232
|
meta: {
|
|
233
233
|
name: 'FormUrl',
|
|
234
|
+
title: 'URL输入[旧]',
|
|
234
235
|
componentName: 'UrlInput',
|
|
235
|
-
title: 'URL输入',
|
|
236
236
|
description: '用于输入URL地址,会强制校验输入内容是否符合邮箱格式。',
|
|
237
237
|
category: '表单',
|
|
238
238
|
categoryOrder: 500,
|
|
239
239
|
componentOrder: 510,
|
|
240
240
|
icon: '../icons/FormUrl.svg',
|
|
241
|
-
visible: [
|
|
241
|
+
visible: [],
|
|
242
|
+
disableUpgradeAll: true,
|
|
243
|
+
deprecated: true,
|
|
244
|
+
renderMode: [
|
|
245
|
+
{
|
|
246
|
+
component: 'WdInputUrl',
|
|
247
|
+
renderType: 'update',
|
|
248
|
+
props: { 'data.value': 'data.inputValue' },
|
|
249
|
+
description: `- 支持标题、输入框的提示语配置;
|
|
250
|
+
- 支持标题的对齐、宽度、换行配置;
|
|
251
|
+
- 支持输入框前/后缀图标和文本的配置;
|
|
252
|
+
- 支持支持控制限制字数的展示;
|
|
253
|
+
- 支持快捷去除移动端下划线、PC端输入边框;
|
|
254
|
+
- 支持通过标准化的样式API和CSS变量灵活修改和自定义组件样式;`,
|
|
255
|
+
},
|
|
256
|
+
],
|
|
242
257
|
},
|
|
243
258
|
configMeta: {
|
|
244
259
|
docsUrl: 'https://docs.cloudbase.net/lowcode/components/wedaUI/src/docs/compsdocs/form/FormUrl',
|
|
@@ -196,6 +196,19 @@ const data = Type.Object({
|
|
|
196
196
|
selectedDataSourceName: 'sys_user',
|
|
197
197
|
},
|
|
198
198
|
}),
|
|
199
|
+
corpScope: Type.Array(Type.String({
|
|
200
|
+
type: 'string',
|
|
201
|
+
title: '企业id',
|
|
202
|
+
'x-category': '高级属性',
|
|
203
|
+
}), {
|
|
204
|
+
type: 'array',
|
|
205
|
+
title: '展示企业范围',
|
|
206
|
+
default: [],
|
|
207
|
+
'x-index': 88,
|
|
208
|
+
'x-category': '高级属性',
|
|
209
|
+
description: '填写企业id后,只展示这些企业下的部门和用户',
|
|
210
|
+
'x-helper-text': '支持写入企业id,用于限制组件中展示的企业列表',
|
|
211
|
+
}),
|
|
199
212
|
layout: Type.StringEnum({
|
|
200
213
|
enum: Tuple([
|
|
201
214
|
{
|
|
@@ -280,7 +293,7 @@ const config = defineConfig({
|
|
|
280
293
|
name: 'FormUserTreeSelect',
|
|
281
294
|
componentName: 'UserSelect',
|
|
282
295
|
title: '成员选择',
|
|
283
|
-
description: '
|
|
296
|
+
description: '用于选择组织架构中的用户成员。',
|
|
284
297
|
category: '表单',
|
|
285
298
|
categoryOrder: 500,
|
|
286
299
|
componentOrder: 450,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { Type } from '../type-utils';
|
|
1
2
|
const rawTemplate = `
|
|
2
3
|
|
|
3
4
|
{{#with (helper_getFields _datasourceName _methodName (helper_utils '?:' (helper_utils '===' _datasourceName 'sys_user') true false)) as |_fields|}}
|
|
@@ -8,7 +9,7 @@ const rawTemplate = `
|
|
|
8
9
|
[[template]]
|
|
9
10
|
component = 'Repeater'
|
|
10
11
|
[template.attributes]
|
|
11
|
-
':data' = '$
|
|
12
|
+
':data' = '$w.{{$self.id}}.records'
|
|
12
13
|
suffix = '{{$self.id}}'
|
|
13
14
|
forItem = 'item_{{$self.id}}'
|
|
14
15
|
forIndex = 'index_{{$self.id}}'
|
|
@@ -81,7 +82,7 @@ name = 'chevronright'
|
|
|
81
82
|
[[template]]
|
|
82
83
|
component = 'Repeater'
|
|
83
84
|
[template.attributes]
|
|
84
|
-
':data' = '$
|
|
85
|
+
':data' = '$w.{{$self.id}}.records'
|
|
85
86
|
suffix = '{{$self.id}}'
|
|
86
87
|
forItem = 'item_{{$self.id}}'
|
|
87
88
|
forIndex = 'index_{{$self.id}}'
|
|
@@ -176,7 +177,7 @@ type = 'inner'
|
|
|
176
177
|
[[template]]
|
|
177
178
|
component = 'Repeater'
|
|
178
179
|
[template.attributes]
|
|
179
|
-
':data' = '$
|
|
180
|
+
':data' = '$w.{{$self.id}}.records'
|
|
180
181
|
suffix = '{{$self.id}}'
|
|
181
182
|
forItem = 'item_{{$self.id}}'
|
|
182
183
|
forIndex = 'index_{{$self.id}}'
|
|
@@ -279,7 +280,7 @@ size = 48
|
|
|
279
280
|
[[template]]
|
|
280
281
|
component = 'Repeater'
|
|
281
282
|
[template.attributes]
|
|
282
|
-
':data' = '$
|
|
283
|
+
':data' = '$w.{{$self.id}}.records'
|
|
283
284
|
suffix = '{{$self.id}}'
|
|
284
285
|
forItem = 'item_{{$self.id}}'
|
|
285
286
|
forIndex = 'index_{{$self.id}}'
|
|
@@ -371,7 +372,7 @@ overflow=true
|
|
|
371
372
|
[[template]]
|
|
372
373
|
component = 'Repeater'
|
|
373
374
|
[template.attributes]
|
|
374
|
-
':data' = '$
|
|
375
|
+
':data' = '$w.{{$self.id}}.records'
|
|
375
376
|
suffix = '{{$self.id}}'
|
|
376
377
|
forItem = 'item_{{$self.id}}'
|
|
377
378
|
forIndex = 'index_{{$self.id}}'
|
|
@@ -408,6 +409,28 @@ ${rawTemplate}
|
|
|
408
409
|
{{/with}}
|
|
409
410
|
{{/with}}
|
|
410
411
|
`;
|
|
412
|
+
const properties = Type.Object({
|
|
413
|
+
records: Type.BasicTypeUnion({
|
|
414
|
+
title: '列表记录',
|
|
415
|
+
type: 'array',
|
|
416
|
+
description: '列表记录',
|
|
417
|
+
}),
|
|
418
|
+
total: Type.Number({
|
|
419
|
+
title: '记录总条数',
|
|
420
|
+
type: 'number',
|
|
421
|
+
description: '记录总条数',
|
|
422
|
+
}),
|
|
423
|
+
pageNo: Type.Number({
|
|
424
|
+
title: '页码',
|
|
425
|
+
type: 'number',
|
|
426
|
+
description: '当前页码',
|
|
427
|
+
}),
|
|
428
|
+
pageSize: Type.Number({
|
|
429
|
+
title: '每页大小',
|
|
430
|
+
type: 'number',
|
|
431
|
+
description: '每页大小',
|
|
432
|
+
}),
|
|
433
|
+
});
|
|
411
434
|
export default {
|
|
412
435
|
$schema: 'https://comp-public-1303824488.cos.ap-shanghai.myqcloud.com/schema/lcds_component.json',
|
|
413
436
|
data: {
|
|
@@ -655,55 +678,12 @@ export default {
|
|
|
655
678
|
paramsSchema: {
|
|
656
679
|
type: 'object',
|
|
657
680
|
properties: {
|
|
658
|
-
inParams: {
|
|
659
|
-
type: 'object',
|
|
660
|
-
properties: {
|
|
661
|
-
properties: {
|
|
662
|
-
type: 'object',
|
|
663
|
-
properties: {
|
|
664
|
-
pageNo: {
|
|
665
|
-
type: 'object',
|
|
666
|
-
properties: {
|
|
667
|
-
type: { const: 'number' },
|
|
668
|
-
},
|
|
669
|
-
required: ['type'],
|
|
670
|
-
},
|
|
671
|
-
pageSize: {
|
|
672
|
-
type: 'object',
|
|
673
|
-
properties: {
|
|
674
|
-
type: { const: 'number' },
|
|
675
|
-
},
|
|
676
|
-
required: ['type'],
|
|
677
|
-
},
|
|
678
|
-
orderBy: {
|
|
679
|
-
type: 'object',
|
|
680
|
-
properties: {
|
|
681
|
-
type: { const: 'string' },
|
|
682
|
-
},
|
|
683
|
-
},
|
|
684
|
-
orderType: {
|
|
685
|
-
type: 'object',
|
|
686
|
-
properties: {
|
|
687
|
-
type: { const: 'string' },
|
|
688
|
-
},
|
|
689
|
-
},
|
|
690
|
-
},
|
|
691
|
-
required: ['pageNo', 'pageSize'],
|
|
692
|
-
},
|
|
693
|
-
},
|
|
694
|
-
},
|
|
695
681
|
outParams: {
|
|
696
682
|
type: 'object',
|
|
697
683
|
properties: {
|
|
698
684
|
properties: {
|
|
699
685
|
type: 'object',
|
|
700
686
|
properties: {
|
|
701
|
-
total: {
|
|
702
|
-
type: 'object',
|
|
703
|
-
properties: {
|
|
704
|
-
type: { const: 'number' },
|
|
705
|
-
},
|
|
706
|
-
},
|
|
707
687
|
records: {
|
|
708
688
|
type: 'object',
|
|
709
689
|
properties: {
|
|
@@ -732,7 +712,7 @@ export default {
|
|
|
732
712
|
},
|
|
733
713
|
},
|
|
734
714
|
},
|
|
735
|
-
required: ['
|
|
715
|
+
required: ['records'],
|
|
736
716
|
},
|
|
737
717
|
},
|
|
738
718
|
},
|
|
@@ -936,6 +916,9 @@ export default {
|
|
|
936
916
|
remarks: '数据查询失败时触发',
|
|
937
917
|
},
|
|
938
918
|
],
|
|
919
|
+
// 组件实例属性
|
|
920
|
+
properties,
|
|
921
|
+
// 组件方法
|
|
939
922
|
methods: [
|
|
940
923
|
{
|
|
941
924
|
name: 'refresh',
|