@tachybase/client 0.23.58 → 1.0.18
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/api-client/APIClient.d.ts +5 -2
- package/es/api-client/APIClient.mjs +93 -49
- package/es/api-client/hooks/useRequest.d.ts +2 -0
- package/es/application/Application.d.ts +3 -0
- package/es/application/Application.mjs +11 -0
- package/es/application/CustomRouterContextProvider.d.ts +54 -0
- package/es/application/CustomRouterContextProvider.mjs +209 -0
- package/es/application/NoticesManager.d.ts +12 -3
- package/es/application/NoticesManager.mjs +27 -3
- package/es/application/RouterManager.d.ts +8 -3
- package/es/application/RouterManager.mjs +48 -15
- package/es/application/schema-initializer/context/index.d.ts +1 -1
- package/es/block-provider/hooks/index.d.ts +2 -0
- package/es/block-provider/hooks/index.mjs +25 -21
- package/es/built-in/context-menu/ContextMenu.provider.mjs +6 -6
- package/es/built-in/context-menu/ContextMenuItemsProps.d.ts +4 -4
- package/es/built-in/context-menu/ContextMenuItemsProps.mjs +6 -6
- package/es/built-in/context-menu/index.mjs +1 -1
- package/es/built-in/context-menu/useContextMenu.d.ts +2 -2
- package/es/built-in/index.mjs +5 -0
- package/es/built-in/page-style/PageStyle.provider.mjs +2 -2
- package/es/built-in/pm/PluginManager.mjs +45 -45
- package/es/collection-manager/interfaces/email.d.ts +0 -1
- package/es/collection-manager/interfaces/input.d.ts +0 -2
- package/es/collection-manager/interfaces/integer.d.ts +0 -2
- package/es/collection-manager/interfaces/number.d.ts +0 -1
- package/es/collection-manager/interfaces/password.d.ts +0 -1
- package/es/collection-manager/interfaces/percent.d.ts +0 -1
- package/es/collection-manager/interfaces/phone.d.ts +0 -1
- package/es/collection-manager/interfaces/properties/index.d.ts +0 -2
- package/es/collection-manager/interfaces/properties/index.mjs +0 -2
- package/es/collection-manager/templates/sql.d.ts +1 -1
- package/es/collection-manager/templates/view.d.ts +1 -1
- package/es/data-source/collection-field-interface/CollectionFieldInterface.d.ts +1 -0
- package/es/data-source/collection-field-interface/CollectionFieldInterface.mjs +18 -0
- package/es/data-source/collection-field-interface/CollectionFieldInterfaceManager.d.ts +8 -1
- package/es/data-source/collection-field-interface/CollectionFieldInterfaceManager.mjs +20 -0
- package/es/data-source/commonsSettingsItem/fieldComponent.mjs +3 -1
- package/es/data-source/data-source/DataSource.d.ts +1 -1
- package/es/filter-provider/utils.mjs +6 -0
- package/es/i18n/i18n.mjs +7 -12
- package/es/modules/actions/delete/deleteActionSettings.mjs +10 -0
- package/es/modules/blocks/data-blocks/form/FilterItemCustomSettings.mjs +1 -1
- package/es/modules/blocks/data-blocks/form/fieldSettingsFormItem.mjs +9 -4
- package/es/modules/blocks/data-blocks/table/hooks/useTableBlockProps.mjs +2 -2
- package/es/modules/blocks/data-blocks/table/tableBlockSettings.mjs +4 -0
- package/es/modules/blocks/data-blocks/table/tableColumnSettings.mjs +44 -0
- package/es/modules/blocks/filter-blocks/collapse/filterCollapseItemFieldSettings.mjs +4 -0
- package/es/modules/blocks/filter-blocks/form/filterFormItemFieldSettings.mjs +9 -0
- package/es/modules/fields/component/SubTable/secondLevelSelect.d.ts +11 -0
- package/es/modules/fields/component/SubTable/secondLevelSelect.mjs +102 -0
- package/es/modules/fields/component/SubTable/subTablePopoverComponentFieldSettings.d.ts +79 -41
- package/es/modules/fields/component/SubTable/subTablePopoverComponentFieldSettings.mjs +103 -100
- package/es/powered-by/index.mjs +4 -7
- package/es/schema-component/antd/action/Action.Designer.mjs +38 -3
- package/es/schema-component/antd/action/Action.Modal.mjs +0 -1
- package/es/schema-component/antd/action/Action.mjs +1 -3
- package/es/schema-component/antd/association-field/SubTabs/InternalCollapse.mjs +2 -1
- package/es/schema-component/antd/checkbox/Checkbox.mjs +6 -4
- package/es/schema-component/antd/index.d.ts +1 -0
- package/es/schema-component/antd/index.mjs +1 -0
- package/es/schema-component/antd/media-card/MediaCard.d.ts +11 -0
- package/es/schema-component/antd/media-card/MediaCard.mjs +35 -0
- package/es/schema-component/antd/media-card/index.d.ts +1 -0
- package/es/schema-component/antd/media-card/index.mjs +1 -0
- package/es/schema-component/antd/media-card/style.d.ts +3 -0
- package/es/schema-component/antd/media-card/style.mjs +25 -0
- package/es/schema-component/antd/page/Page.mjs +34 -24
- package/es/schema-component/antd/password/utils.d.ts +1 -1
- package/es/schema-component/common/dnd-context/index.mjs +1 -7
- package/es/schema-component/common/sortable-item/DragHandlePageTab.d.ts +1 -0
- package/es/schema-component/common/sortable-item/DragHandlePageTab.mjs +71 -0
- package/es/schema-component/common/sortable-item/DragHandlePageTab.style.d.ts +3 -0
- package/es/schema-component/common/sortable-item/DragHandlePageTab.style.mjs +25 -0
- package/es/schema-items/GeneralSettings.mjs +5 -0
- package/es/schema-settings/EditCustomDefaultValue.mjs +1 -1
- package/es/schema-settings/SchemaSettings.mjs +1 -1
- package/es/schema-settings/SchemaSettingsDefaultValue.mjs +2 -0
- package/es/schema-settings/utils/createModalSettingsItem.d.ts +26 -0
- package/es/schema-settings/utils/createModalSettingsItem.mjs +46 -0
- package/es/schema-settings/utils/createSelectSettingsItem.d.ts +25 -0
- package/es/schema-settings/utils/createSelectSettingsItem.mjs +40 -0
- package/es/schema-settings/utils/createSwitchSettingsItem.d.ts +21 -0
- package/es/schema-settings/utils/createSwitchSettingsItem.mjs +38 -0
- package/es/schema-settings/utils/createTextSettingsItem.d.ts +9 -0
- package/es/schema-settings/utils/createTextSettingsItem.mjs +21 -0
- package/es/schema-settings/utils/index.d.ts +4 -0
- package/es/schema-settings/utils/index.mjs +4 -0
- package/es/schema-settings/utils/util.d.ts +12 -0
- package/es/schema-settings/utils/util.mjs +24 -0
- package/es/user/CurrentUserProvider.mjs +6 -3
- package/lib/api-client/APIClient.js +93 -49
- package/lib/application/Application.js +11 -0
- package/lib/application/CustomRouterContextProvider.js +276 -0
- package/lib/application/NoticesManager.js +27 -3
- package/lib/application/RouterManager.js +49 -15
- package/lib/block-provider/hooks/index.js +76 -58
- package/lib/built-in/context-menu/ContextMenu.provider.js +6 -6
- package/lib/built-in/context-menu/ContextMenuItemsProps.js +6 -6
- package/lib/built-in/context-menu/index.js +1 -1
- package/lib/built-in/index.js +5 -0
- package/lib/built-in/page-style/PageStyle.provider.js +2 -2
- package/lib/built-in/pm/PluginManager.js +45 -45
- package/lib/collection-manager/interfaces/properties/index.js +0 -2
- package/lib/data-source/collection-field-interface/CollectionFieldInterface.js +18 -0
- package/lib/data-source/collection-field-interface/CollectionFieldInterfaceManager.js +20 -0
- package/lib/data-source/commonsSettingsItem/fieldComponent.js +3 -1
- package/lib/filter-provider/utils.js +6 -0
- package/lib/i18n/i18n.js +7 -12
- package/lib/locale/en_US.js +4 -0
- package/lib/locale/zh-CN.js +13 -1
- package/lib/modules/actions/delete/deleteActionSettings.js +10 -0
- package/lib/modules/blocks/data-blocks/form/FilterItemCustomSettings.js +1 -1
- package/lib/modules/blocks/data-blocks/form/fieldSettingsFormItem.js +9 -4
- package/lib/modules/blocks/data-blocks/table/hooks/useTableBlockProps.js +2 -2
- package/lib/modules/blocks/data-blocks/table/tableBlockSettings.js +4 -0
- package/lib/modules/blocks/data-blocks/table/tableColumnSettings.js +44 -0
- package/lib/modules/blocks/filter-blocks/collapse/filterCollapseItemFieldSettings.js +4 -0
- package/lib/modules/blocks/filter-blocks/form/filterFormItemFieldSettings.js +9 -0
- package/lib/modules/fields/component/SubTable/secondLevelSelect.js +136 -0
- package/lib/modules/fields/component/SubTable/subTablePopoverComponentFieldSettings.js +104 -103
- package/lib/powered-by/index.js +4 -7
- package/lib/schema-component/antd/action/Action.Designer.js +38 -3
- package/lib/schema-component/antd/action/Action.Modal.js +0 -1
- package/lib/schema-component/antd/action/Action.js +1 -3
- package/lib/schema-component/antd/association-field/SubTabs/InternalCollapse.js +2 -1
- package/lib/schema-component/antd/checkbox/Checkbox.js +6 -4
- package/lib/schema-component/antd/index.js +18 -4
- package/lib/schema-component/antd/media-card/MediaCard.js +69 -0
- package/lib/schema-component/antd/media-card/index.js +65 -0
- package/lib/schema-component/antd/media-card/style.js +59 -0
- package/lib/schema-component/antd/page/Page.js +34 -24
- package/lib/schema-component/common/dnd-context/index.js +1 -7
- package/lib/schema-component/common/sortable-item/DragHandlePageTab.js +105 -0
- package/lib/schema-component/common/sortable-item/DragHandlePageTab.style.js +59 -0
- package/lib/schema-items/GeneralSettings.js +5 -0
- package/lib/schema-settings/EditCustomDefaultValue.js +1 -1
- package/lib/schema-settings/SchemaSettings.js +1 -1
- package/lib/schema-settings/SchemaSettingsDefaultValue.js +2 -0
- package/lib/schema-settings/utils/createModalSettingsItem.js +94 -0
- package/lib/schema-settings/utils/createSelectSettingsItem.js +88 -0
- package/lib/schema-settings/utils/createSwitchSettingsItem.js +86 -0
- package/lib/schema-settings/utils/createTextSettingsItem.js +55 -0
- package/lib/schema-settings/utils/index.js +92 -0
- package/lib/schema-settings/utils/util.js +74 -0
- package/lib/user/CurrentUserProvider.js +6 -3
- package/package.json +7 -7
package/lib/locale/en_US.js
CHANGED
|
@@ -517,6 +517,7 @@ module.exports = {
|
|
|
517
517
|
"Multiple select": "Multiple select",
|
|
518
518
|
"Must select to the last level": "Must select to the last level",
|
|
519
519
|
Name: "Name",
|
|
520
|
+
"Name or descriptions": "Name or descriptions",
|
|
520
521
|
Navigate: "Navigate",
|
|
521
522
|
"New menu items are allowed to be accessed by default.": "New menu items are allowed to be accessed by default.",
|
|
522
523
|
"New password": "New password",
|
|
@@ -590,6 +591,7 @@ module.exports = {
|
|
|
590
591
|
"Please confirm the SQL statement first": "Please confirm the SQL statement first",
|
|
591
592
|
"Please enter search content": "Please enter search content",
|
|
592
593
|
"Please fill in the iframe URL": "Please fill in the iframe URL",
|
|
594
|
+
"Please select": "Please select",
|
|
593
595
|
"Please select the records to be updated": "Please select the records to be updated",
|
|
594
596
|
"Please use a valid SELECT or WITH AS statement": "Please use a valid SELECT or WITH AS statement",
|
|
595
597
|
"Plugin Zip File": "Plugin Zip File",
|
|
@@ -736,6 +738,7 @@ module.exports = {
|
|
|
736
738
|
"Source key": "Source key",
|
|
737
739
|
"Specific properties": "Specific properties",
|
|
738
740
|
"Start date field": "Start date field",
|
|
741
|
+
Status: "Status",
|
|
739
742
|
"Stay on current page": "Stay on current page",
|
|
740
743
|
"Store the creation time of each record": "Store the creation time of each record",
|
|
741
744
|
"Store the creation user of each record": "Store the creation user of each record",
|
|
@@ -768,6 +771,7 @@ module.exports = {
|
|
|
768
771
|
"Table OID(Inheritance)": "Table OID(Inheritance)",
|
|
769
772
|
"Table selected records": "Table selected records",
|
|
770
773
|
"Tablet device": "Tablet device",
|
|
774
|
+
"TachyBase Team": "TachyBase Team",
|
|
771
775
|
Tag: "Tag",
|
|
772
776
|
"Tag color field": "Tag color field",
|
|
773
777
|
Target: "Target",
|
package/lib/locale/zh-CN.js
CHANGED
|
@@ -67,6 +67,7 @@ module.exports = {
|
|
|
67
67
|
"After successful submission": "\u63D0\u4EA4\u6210\u529F\u540E",
|
|
68
68
|
"After successful update": "\u66F4\u65B0\u6210\u529F\u540E",
|
|
69
69
|
Agenda: "\u5217\u8868",
|
|
70
|
+
Align: "\u5BF9\u9F50\u65B9\u5F0F",
|
|
70
71
|
All: "\u6240\u6709",
|
|
71
72
|
"All collections": "\u5168\u90E8\u6570\u636E\u8868",
|
|
72
73
|
"All collections use general action permissions by default; permission configured individually will override the default one.": "\u6240\u6709\u6570\u636E\u8868\u90FD\u9ED8\u8BA4\u4F7F\u7528\u901A\u7528\u6570\u636E\u64CD\u4F5C\u6743\u9650\uFF1B\u540C\u65F6\uFF0C\u53EF\u4EE5\u9488\u5BF9\u6BCF\u4E2A\u6570\u636E\u8868\u5355\u72EC\u914D\u7F6E\u6743\u9650\u3002",
|
|
@@ -154,6 +155,7 @@ module.exports = {
|
|
|
154
155
|
Cascader: "\u7EA7\u8054\u9009\u62E9",
|
|
155
156
|
Categories: "\u6570\u636E\u8868\u7C7B\u522B",
|
|
156
157
|
"Category name": "\u5206\u7C7B\u540D\u79F0",
|
|
158
|
+
Center: "\u5C45\u4E2D",
|
|
157
159
|
"Chang on Parent": "\u9009\u62E9\u7236\u7EA7",
|
|
158
160
|
"Change password": "\u4FEE\u6539\u5BC6\u7801",
|
|
159
161
|
"Changed to": "\u4FEE\u6539\u4E3A",
|
|
@@ -173,6 +175,7 @@ module.exports = {
|
|
|
173
175
|
"Clear cache": "\u6E05\u9664\u7F13\u5B58",
|
|
174
176
|
"Click on the right to select variables \u2192": "\u70B9\u51FB\u53F3\u4FA7\u9009\u62E9\u53D8\u91CF \u2192",
|
|
175
177
|
"Click or drag file to this area to upload": "\u70B9\u51FB\u6216\u62D6\u62FD\u6587\u4EF6\u5230\u6B64\u533A\u57DF\u4E0A\u4F20",
|
|
178
|
+
"Click to select": "\u70B9\u9009\u6A21\u5F0F",
|
|
176
179
|
Close: "\u5173\u95ED",
|
|
177
180
|
Collapse: "\u6298\u53E0\u9762\u677F",
|
|
178
181
|
"Collapse all": "\u5168\u90E8\u6536\u8D77",
|
|
@@ -392,6 +395,7 @@ module.exports = {
|
|
|
392
395
|
"Enable link": "\u542F\u7528\u94FE\u63A5",
|
|
393
396
|
"Enable page header": "\u542F\u7528\u9875\u7709",
|
|
394
397
|
"Enable page tabs": "\u542F\u7528\u9875\u9762\u9009\u9879\u5361",
|
|
398
|
+
"Enable quick create": "\u542F\u7528\u5FEB\u901F\u521B\u5EFA",
|
|
395
399
|
Enabled: "\u542F\u7528",
|
|
396
400
|
"Enabled languages": "\u542F\u7528\u7684\u8BED\u8A00",
|
|
397
401
|
"End date field": "\u7ED3\u675F\u65E5\u671F\u5B57\u6BB5",
|
|
@@ -530,6 +534,7 @@ module.exports = {
|
|
|
530
534
|
"Last week": "\u4E0A\u5468",
|
|
531
535
|
"Last year": "\u53BB\u5E74",
|
|
532
536
|
"Leave it blank, unless you need a custom intermediate table": "\u9ED8\u8BA4\u7559\u7A7A\uFF0C\u9664\u975E\u4F60\u9700\u8981\u4E00\u4E2A\u81EA\u5B9A\u4E49\u7684\u4E2D\u95F4\u8868",
|
|
537
|
+
Left: "\u5DE6\u5BF9\u9F50",
|
|
533
538
|
Length: "\u957F\u5EA6",
|
|
534
539
|
License: "\u8BB8\u53EF\u8BC1",
|
|
535
540
|
Lime: "\u9752\u67E0",
|
|
@@ -597,6 +602,7 @@ module.exports = {
|
|
|
597
602
|
"Must be 2-16 characters in length (excluding @.<>\"'/)": `\u957F\u5EA6\u4E3A2\u523016\u4E2A\u5B57\u7B26\uFF08\u4E0D\u80FD\u5305\u542B@.<>"'/\uFF09`,
|
|
598
603
|
"Must select to the last level": "\u5FC5\u987B\u9009\u5230\u6700\u540E\u4E00\u7EA7",
|
|
599
604
|
Name: "\u540D\u79F0",
|
|
605
|
+
"Name or descriptions": "\u8F93\u5165\u540D\u79F0\u6216\u63CF\u8FF0",
|
|
600
606
|
Navigate: "\u5206\u9875",
|
|
601
607
|
"New menu items are allowed to be accessed by default.": "\u65B0\u589E\u83DC\u5355\u9879\u9ED8\u8BA4\u5141\u8BB8\u8BBF\u95EE",
|
|
602
608
|
"New password": "\u65B0\u5BC6\u7801",
|
|
@@ -683,6 +689,7 @@ module.exports = {
|
|
|
683
689
|
"Please confirm the SQL statement first": "\u8BF7\u5148\u786E\u8BA4 SQL \u8BED\u53E5",
|
|
684
690
|
"Please enter search content": "\u8BF7\u8F93\u5165\u67E5\u8BE2\u5185\u5BB9",
|
|
685
691
|
"Please fill in the iframe URL": "\u8BF7\u586B\u5199\u5D4C\u5165\u7684\u5730\u5740",
|
|
692
|
+
"Please select": "\u8BF7\u9009\u62E9",
|
|
686
693
|
"Please select the records to be updated": "\u8BF7\u9009\u62E9\u8981\u66F4\u65B0\u7684\u8BB0\u5F55",
|
|
687
694
|
"Please use a valid SELECT or WITH AS statement": "\u8BF7\u4F7F\u7528\u6709\u6548\u7684 SELECT \u6216 WITH AS \u8BED\u53E5",
|
|
688
695
|
"Plugin Management": "\u63D2\u4EF6\u7BA1\u7406\u5668",
|
|
@@ -767,6 +774,7 @@ module.exports = {
|
|
|
767
774
|
"Retry after {{count}} seconds": "{{count}} \u79D2\u540E\u91CD\u8BD5",
|
|
768
775
|
"Return to the main application": "\u8FD4\u56DE\u4E3B\u5E94\u7528",
|
|
769
776
|
"Rich Text": "\u5BCC\u6587\u672C",
|
|
777
|
+
Right: "\u53F3\u5BF9\u9F50",
|
|
770
778
|
"Role UID": "\u89D2\u8272\u6807\u8BC6",
|
|
771
779
|
"Role display name": "\u89D2\u8272\u540D\u79F0",
|
|
772
780
|
"Role name": "\u89D2\u8272\u540D\u79F0",
|
|
@@ -790,7 +798,7 @@ module.exports = {
|
|
|
790
798
|
"Search plugin": "\u641C\u7D22\u63D2\u4EF6",
|
|
791
799
|
Second: "\u79D2",
|
|
792
800
|
"Secondary confirmation": "\u4E8C\u6B21\u786E\u8BA4",
|
|
793
|
-
Security: "\
|
|
801
|
+
Security: "\u5B89\u5168",
|
|
794
802
|
Select: "\u9009\u62E9",
|
|
795
803
|
"Select a variable": "\u9009\u62E9\u53D8\u91CF",
|
|
796
804
|
"Select all": "\u5168\u9009",
|
|
@@ -810,6 +818,8 @@ module.exports = {
|
|
|
810
818
|
"Selector mode": "\u9009\u62E9\u5668\u6A21\u5F0F",
|
|
811
819
|
"Send code": "\u53D1\u9001\u9A8C\u8BC1\u7801",
|
|
812
820
|
Separator: "\u5206\u9694\u7B26",
|
|
821
|
+
"Set Quick Add Parent Tabs": "\u8BBE\u7F6E\u5FEB\u901F\u6DFB\u52A0\u7236\u7EA7\u9009\u9879",
|
|
822
|
+
"Set Quick Add Tabs": "\u8BBE\u7F6E\u5FEB\u901F\u6DFB\u52A0\u9009\u9879",
|
|
813
823
|
"Set data loading mode": "\u8BBE\u7F6E\u6570\u636E\u52A0\u8F7D\u65B9\u5F0F",
|
|
814
824
|
"Set default sorting rules": "\u8BBE\u7F6E\u6392\u5E8F\u89C4\u5219",
|
|
815
825
|
"Set default value": "\u8BBE\u7F6E\u9ED8\u8BA4\u503C",
|
|
@@ -848,6 +858,7 @@ module.exports = {
|
|
|
848
858
|
"Source key": "\u6E90\u6570\u636E\u8868\u5B57\u6BB5\u6807\u8BC6",
|
|
849
859
|
"Specific properties": "\u7279\u6709\u5C5E\u6027",
|
|
850
860
|
"Start date field": "\u5F00\u59CB\u65E5\u671F\u5B57\u6BB5",
|
|
861
|
+
Status: "\u72B6\u6001",
|
|
851
862
|
"Stay on current page": "\u505C\u7559\u5728\u5F53\u524D\u9875\u9762",
|
|
852
863
|
"Store the creation time of each record": "\u8BB0\u5F55\u521B\u5EFA\u65F6\u95F4",
|
|
853
864
|
"Store the creation user of each record": "\u8BB0\u5F55\u521B\u5EFA\u4EBA",
|
|
@@ -893,6 +904,7 @@ module.exports = {
|
|
|
893
904
|
"Table OID(Inheritance)": "\u6570\u636E\u8868 OID(\u7EE7\u627F)",
|
|
894
905
|
"Table selected records": "\u8868\u683C\u4E2D\u9009\u4E2D\u7684\u8BB0\u5F55",
|
|
895
906
|
"Tablet device": "\u5E73\u677F\u8BBE\u5907",
|
|
907
|
+
"TachyBase Team": "\u4E0A\u6D77\u9053\u6709\u4E91\u7F51\u7EDC\u79D1\u6280\u6709\u9650\u516C\u53F8 \u7248\u6743\u6240\u6709\uFF5C\u6CAAICP\u59072023024678\u53F7",
|
|
896
908
|
Tag: "\u6807\u7B7E",
|
|
897
909
|
"Tag color field": "\u6807\u7B7E\u989C\u8272\u5B57\u6BB5",
|
|
898
910
|
Target: "\u76EE\u6807",
|
|
@@ -28,6 +28,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
28
28
|
__webpack_require__.d(__webpack_exports__, {
|
|
29
29
|
deleteActionSettings: ()=>deleteActionSettings
|
|
30
30
|
});
|
|
31
|
+
const schema_namespaceObject = require("@tachybase/schema");
|
|
31
32
|
const index_js_namespaceObject = require("../../../application/index.js");
|
|
32
33
|
const SchemaSettings_js_namespaceObject = require("../../../application/schema-settings/SchemaSettings.js");
|
|
33
34
|
const external_collection_manager_index_js_namespaceObject = require("../../../collection-manager/index.js");
|
|
@@ -60,6 +61,15 @@ const deleteActionSettings = new SchemaSettings_js_namespaceObject.SchemaSetting
|
|
|
60
61
|
name: 'secondConFirm',
|
|
61
62
|
Component: Action_Designer_js_namespaceObject.SecondConFirm
|
|
62
63
|
},
|
|
64
|
+
{
|
|
65
|
+
name: 'workflowConfig',
|
|
66
|
+
Component: Action_Designer_js_namespaceObject.WorkflowConfig,
|
|
67
|
+
useVisible () {
|
|
68
|
+
var _fieldSchema_xactionsettings;
|
|
69
|
+
const fieldSchema = (0, schema_namespaceObject.useFieldSchema)();
|
|
70
|
+
return (0, schema_namespaceObject.isValid)(null == fieldSchema ? void 0 : null === (_fieldSchema_xactionsettings = fieldSchema['x-action-settings']) || void 0 === _fieldSchema_xactionsettings ? void 0 : _fieldSchema_xactionsettings.triggerWorkflows);
|
|
71
|
+
}
|
|
72
|
+
},
|
|
63
73
|
{
|
|
64
74
|
name: 'delete',
|
|
65
75
|
type: 'remove'
|
|
@@ -294,7 +294,7 @@ const FilterItemCustomSettings = new SchemaSettings_js_namespaceObject.SchemaSet
|
|
|
294
294
|
}
|
|
295
295
|
},
|
|
296
296
|
onSubmit (param) {
|
|
297
|
-
let { default: { value } } = param;
|
|
297
|
+
let { default: { value = null } } = param;
|
|
298
298
|
field.setValue(value);
|
|
299
299
|
fieldSchema['default'] = value;
|
|
300
300
|
fieldSchema['x-component-props']['defaultValue'] = value;
|
|
@@ -56,9 +56,7 @@ const external_schema_component_index_js_namespaceObject = require("../../../../
|
|
|
56
56
|
const FormItem_Settings_js_namespaceObject = require("../../../../schema-component/antd/form-item/FormItem.Settings.js");
|
|
57
57
|
const utils_js_namespaceObject = require("../../../../schema-component/antd/form-v2/utils.js");
|
|
58
58
|
const external_schema_settings_index_js_namespaceObject = require("../../../../schema-settings/index.js");
|
|
59
|
-
const useIsAllowToSetDefaultValue_js_namespaceObject = require("../../../../schema-settings/hooks/useIsAllowToSetDefaultValue.js");
|
|
60
59
|
const type_js_namespaceObject = require("../../../../schema-settings/LinkageRules/type.js");
|
|
61
|
-
const SchemaSettingsDefaultValue_js_namespaceObject = require("../../../../schema-settings/SchemaSettingsDefaultValue.js");
|
|
62
60
|
const fieldSettingsFormItem = new SchemaSettings_js_namespaceObject.SchemaSettings({
|
|
63
61
|
name: 'fieldSettings:FormItem',
|
|
64
62
|
items: [
|
|
@@ -261,10 +259,10 @@ const fieldSettingsFormItem = new SchemaSettings_js_namespaceObject.SchemaSettin
|
|
|
261
259
|
{
|
|
262
260
|
name: 'setDefaultValue',
|
|
263
261
|
useVisible () {
|
|
264
|
-
const { isAllowToSetDefaultValue } = (0,
|
|
262
|
+
const { isAllowToSetDefaultValue } = (0, external_schema_settings_index_js_namespaceObject.useIsAllowToSetDefaultValue)();
|
|
265
263
|
return isAllowToSetDefaultValue();
|
|
266
264
|
},
|
|
267
|
-
Component:
|
|
265
|
+
Component: external_schema_settings_index_js_namespaceObject.SchemaSettingsDefaultValue
|
|
268
266
|
},
|
|
269
267
|
{
|
|
270
268
|
name: 'layoutDirection',
|
|
@@ -522,6 +520,13 @@ const fieldSettingsFormItem = new SchemaSettings_js_namespaceObject.SchemaSettin
|
|
|
522
520
|
const validateSchema = (0, external_schema_component_index_js_namespaceObject.useValidateSchema)();
|
|
523
521
|
return form && !isFormReadPretty && validateSchema;
|
|
524
522
|
}
|
|
523
|
+
},
|
|
524
|
+
{
|
|
525
|
+
...external_data_source_index_js_namespaceObject.fieldComponentSettingsItem
|
|
526
|
+
},
|
|
527
|
+
{
|
|
528
|
+
name: 'editDefaultValue',
|
|
529
|
+
Component: external_schema_settings_index_js_namespaceObject.SchemaSettingsDefaultValue
|
|
525
530
|
}
|
|
526
531
|
];
|
|
527
532
|
}
|
|
@@ -51,11 +51,11 @@ const FilterProvider_js_namespaceObject = require("../../../../../filter-provide
|
|
|
51
51
|
const utils_js_namespaceObject = require("../../../../../filter-provider/utils.js");
|
|
52
52
|
const external_schema_component_index_js_namespaceObject = require("../../../../../schema-component/index.js");
|
|
53
53
|
const useTableBlockProps = ()=>{
|
|
54
|
-
var _fieldSchema_parent_xdecoratorprops, _fieldSchema_parent, _ctx_service, _ctx_service1, _ctx_field_data, _ctx_field, _ctx_service2, _ctx_service3, _fieldSchema_xcomponentprops;
|
|
54
|
+
var _fieldSchema_parent_xdecoratorprops, _fieldSchema_parent, _fieldSchema_parent_xdecoratorprops1, _fieldSchema_parent1, _ctx_service, _ctx_service1, _ctx_field_data, _ctx_field, _ctx_service2, _ctx_service3, _fieldSchema_xcomponentprops;
|
|
55
55
|
const field = (0, schema_namespaceObject.useField)();
|
|
56
56
|
const fieldSchema = (0, schema_namespaceObject.useFieldSchema)();
|
|
57
57
|
const ctx = (0, TableBlockProvider_js_namespaceObject.useTableBlockContext)();
|
|
58
|
-
const globalSort = null === (_fieldSchema_parent = fieldSchema.parent) || void 0 === _fieldSchema_parent ? void 0 : null === (_fieldSchema_parent_xdecoratorprops = _fieldSchema_parent['x-decorator-props']) || void 0 === _fieldSchema_parent_xdecoratorprops ? void 0 : _fieldSchema_parent_xdecoratorprops['dragSortBy'];
|
|
58
|
+
const globalSort = (null === (_fieldSchema_parent = fieldSchema.parent) || void 0 === _fieldSchema_parent ? void 0 : null === (_fieldSchema_parent_xdecoratorprops = _fieldSchema_parent['x-decorator-props']) || void 0 === _fieldSchema_parent_xdecoratorprops ? void 0 : _fieldSchema_parent_xdecoratorprops['dragSort']) === true ? null === (_fieldSchema_parent1 = fieldSchema.parent) || void 0 === _fieldSchema_parent1 ? void 0 : null === (_fieldSchema_parent_xdecoratorprops1 = _fieldSchema_parent1['x-decorator-props']) || void 0 === _fieldSchema_parent_xdecoratorprops1 ? void 0 : _fieldSchema_parent_xdecoratorprops1['dragSortBy'] : void 0;
|
|
59
59
|
const { getDataBlocks } = (0, FilterProvider_js_namespaceObject.useFilterBlock)();
|
|
60
60
|
const isLoading = null == ctx ? void 0 : null === (_ctx_service = ctx.service) || void 0 === _ctx_service ? void 0 : _ctx_service.loading;
|
|
61
61
|
null == ctx || null === (_ctx_service1 = ctx.service) || void 0 === _ctx_service1 || _ctx_service1.params;
|
|
@@ -121,6 +121,10 @@ const tableBlockSettings = new SchemaSettings_js_namespaceObject.SchemaSettings(
|
|
|
121
121
|
const sortBy = null == data ? void 0 : null === (_data_data = data.data) || void 0 === _data_data ? void 0 : null === (_data_data_ = _data_data[0]) || void 0 === _data_data_ ? void 0 : _data_data_.sortBy;
|
|
122
122
|
fieldSchema['x-decorator-props'].dragSortBy = sortBy;
|
|
123
123
|
}
|
|
124
|
+
if (!dragSort) {
|
|
125
|
+
fieldSchema['x-decorator-props'].dragSortBy = null;
|
|
126
|
+
field.decoratorProps.dragSortBy = null;
|
|
127
|
+
}
|
|
124
128
|
field.decoratorProps.dragSort = dragSort;
|
|
125
129
|
fieldSchema['x-decorator-props'].dragSort = dragSort;
|
|
126
130
|
service.run({
|
|
@@ -138,6 +138,50 @@ const tableColumnSettings = new SchemaSettings_js_namespaceObject.SchemaSettings
|
|
|
138
138
|
};
|
|
139
139
|
}
|
|
140
140
|
},
|
|
141
|
+
{
|
|
142
|
+
name: 'columnAlign',
|
|
143
|
+
type: 'select',
|
|
144
|
+
useComponentProps () {
|
|
145
|
+
var _fieldSchema_xcomponentprops;
|
|
146
|
+
const fieldSchema = (0, schema_namespaceObject.useFieldSchema)();
|
|
147
|
+
const { t } = (0, external_react_i18next_namespaceObject.useTranslation)();
|
|
148
|
+
const field = (0, schema_namespaceObject.useField)();
|
|
149
|
+
const { dn } = (0, external_schema_component_index_js_namespaceObject.useDesignable)();
|
|
150
|
+
return {
|
|
151
|
+
key: 'align',
|
|
152
|
+
title: t('Align'),
|
|
153
|
+
options: [
|
|
154
|
+
{
|
|
155
|
+
label: t('Left'),
|
|
156
|
+
value: 'left'
|
|
157
|
+
},
|
|
158
|
+
{
|
|
159
|
+
label: t('Center'),
|
|
160
|
+
value: 'center'
|
|
161
|
+
},
|
|
162
|
+
{
|
|
163
|
+
label: t('Right'),
|
|
164
|
+
value: 'right'
|
|
165
|
+
}
|
|
166
|
+
],
|
|
167
|
+
value: (null === (_fieldSchema_xcomponentprops = fieldSchema['x-component-props']) || void 0 === _fieldSchema_xcomponentprops ? void 0 : _fieldSchema_xcomponentprops.align) || 'left',
|
|
168
|
+
onChange: (align)=>{
|
|
169
|
+
const props = fieldSchema['x-component-props'] || {};
|
|
170
|
+
props['align'] = align;
|
|
171
|
+
const schema = {
|
|
172
|
+
['x-uid']: fieldSchema['x-uid']
|
|
173
|
+
};
|
|
174
|
+
schema['x-component-props'] = props;
|
|
175
|
+
fieldSchema['x-component-props'] = props;
|
|
176
|
+
field.componentProps.align = align;
|
|
177
|
+
dn.emit('patch', {
|
|
178
|
+
schema
|
|
179
|
+
});
|
|
180
|
+
dn.refresh();
|
|
181
|
+
}
|
|
182
|
+
};
|
|
183
|
+
}
|
|
184
|
+
},
|
|
141
185
|
{
|
|
142
186
|
name: 'sortable',
|
|
143
187
|
type: 'switch',
|
|
@@ -48,6 +48,7 @@ const external_react_i18next_namespaceObject = require("react-i18next");
|
|
|
48
48
|
const SchemaSettings_js_namespaceObject = require("../../../../application/schema-settings/SchemaSettings.js");
|
|
49
49
|
const index_js_namespaceObject = require("../../../../block-provider/index.js");
|
|
50
50
|
const external_collection_manager_index_js_namespaceObject = require("../../../../collection-manager/index.js");
|
|
51
|
+
const external_data_source_index_js_namespaceObject = require("../../../../data-source/index.js");
|
|
51
52
|
const external_schema_component_index_js_namespaceObject = require("../../../../schema-component/index.js");
|
|
52
53
|
const external_schema_settings_index_js_namespaceObject = require("../../../../schema-settings/index.js");
|
|
53
54
|
const SchemaSettingsDataScope_js_namespaceObject = require("../../../../schema-settings/SchemaSettingsDataScope.js");
|
|
@@ -227,6 +228,9 @@ const filterCollapseItemFieldSettings = new SchemaSettings_js_namespaceObject.Sc
|
|
|
227
228
|
onChange: onTitleFieldChange
|
|
228
229
|
};
|
|
229
230
|
}
|
|
231
|
+
},
|
|
232
|
+
{
|
|
233
|
+
...external_data_source_index_js_namespaceObject.fieldComponentSettingsItem
|
|
230
234
|
}
|
|
231
235
|
];
|
|
232
236
|
}
|
|
@@ -50,7 +50,9 @@ const index_js_namespaceObject = require("../../../../application/index.js");
|
|
|
50
50
|
const SchemaSettings_js_namespaceObject = require("../../../../application/schema-settings/SchemaSettings.js");
|
|
51
51
|
const external_collection_manager_index_js_namespaceObject = require("../../../../collection-manager/index.js");
|
|
52
52
|
const useFieldComponentName_js_namespaceObject = require("../../../../common/useFieldComponentName.js");
|
|
53
|
+
const external_data_source_index_js_namespaceObject = require("../../../../data-source/index.js");
|
|
53
54
|
const external_schema_component_index_js_namespaceObject = require("../../../../schema-component/index.js");
|
|
55
|
+
const external_schema_settings_index_js_namespaceObject = require("../../../../schema-settings/index.js");
|
|
54
56
|
const filterFormItemFieldSettings = new SchemaSettings_js_namespaceObject.SchemaSettings({
|
|
55
57
|
name: 'fieldSettings:FilterFormItem',
|
|
56
58
|
items: [
|
|
@@ -352,6 +354,13 @@ const filterFormItemFieldSettings = new SchemaSettings_js_namespaceObject.Schema
|
|
|
352
354
|
{
|
|
353
355
|
name: 'operator',
|
|
354
356
|
Component: external_schema_component_index_js_namespaceObject.EditOperator
|
|
357
|
+
},
|
|
358
|
+
{
|
|
359
|
+
...external_data_source_index_js_namespaceObject.fieldComponentSettingsItem
|
|
360
|
+
},
|
|
361
|
+
{
|
|
362
|
+
name: 'editDefaultValue',
|
|
363
|
+
Component: external_schema_settings_index_js_namespaceObject.SchemaSettingsDefaultValue
|
|
355
364
|
}
|
|
356
365
|
];
|
|
357
366
|
}
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __webpack_require__ = {};
|
|
3
|
+
(()=>{
|
|
4
|
+
__webpack_require__.d = function(exports1, definition) {
|
|
5
|
+
for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: definition[key]
|
|
8
|
+
});
|
|
9
|
+
};
|
|
10
|
+
})();
|
|
11
|
+
(()=>{
|
|
12
|
+
__webpack_require__.o = function(obj, prop) {
|
|
13
|
+
return Object.prototype.hasOwnProperty.call(obj, prop);
|
|
14
|
+
};
|
|
15
|
+
})();
|
|
16
|
+
(()=>{
|
|
17
|
+
__webpack_require__.r = function(exports1) {
|
|
18
|
+
if ('undefined' != typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, {
|
|
19
|
+
value: 'Module'
|
|
20
|
+
});
|
|
21
|
+
Object.defineProperty(exports1, '__esModule', {
|
|
22
|
+
value: true
|
|
23
|
+
});
|
|
24
|
+
};
|
|
25
|
+
})();
|
|
26
|
+
var __webpack_exports__ = {};
|
|
27
|
+
__webpack_require__.r(__webpack_exports__);
|
|
28
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
29
|
+
SecondLevelSelect: ()=>SecondLevelSelect
|
|
30
|
+
});
|
|
31
|
+
const jsx_runtime_namespaceObject = require("react/jsx-runtime");
|
|
32
|
+
const external_react_namespaceObject = require("react");
|
|
33
|
+
const schema_namespaceObject = require("@tachybase/schema");
|
|
34
|
+
const icons_namespaceObject = require("@ant-design/icons");
|
|
35
|
+
const external_antd_namespaceObject = require("antd");
|
|
36
|
+
const external_react_i18next_namespaceObject = require("react-i18next");
|
|
37
|
+
const index_js_namespaceObject = require("../../../../data-source/index.js");
|
|
38
|
+
const external_schema_component_index_js_namespaceObject = require("../../../../schema-component/index.js");
|
|
39
|
+
const ReadPretty_js_namespaceObject = require("../../../../schema-component/antd/select/ReadPretty.js");
|
|
40
|
+
const filterOption = (input, option)=>{
|
|
41
|
+
var _option_label;
|
|
42
|
+
return (null !== (_option_label = null == option ? void 0 : option.label) && void 0 !== _option_label ? _option_label : '').toLowerCase().includes((input || '').toLowerCase());
|
|
43
|
+
};
|
|
44
|
+
const SecondLevelSelect = (0, schema_namespaceObject.connect)((props)=>{
|
|
45
|
+
const { objectValue, loading, value, rawOptions, defaultValue, firstLevelValue, collectionField, ...others } = props;
|
|
46
|
+
const { t } = (0, external_react_i18next_namespaceObject.useTranslation)();
|
|
47
|
+
const compile = (0, external_schema_component_index_js_namespaceObject.useCompile)();
|
|
48
|
+
const cm = (0, index_js_namespaceObject.useCollectionManager)();
|
|
49
|
+
let mode = props.multiple ? 'multiple' : props.mode;
|
|
50
|
+
if (mode && ![
|
|
51
|
+
'multiple',
|
|
52
|
+
'tags'
|
|
53
|
+
].includes(mode)) mode = void 0;
|
|
54
|
+
const toValue = (v)=>{
|
|
55
|
+
if ([
|
|
56
|
+
'tags',
|
|
57
|
+
'multiple'
|
|
58
|
+
].includes(props.mode) || props.multiple) {
|
|
59
|
+
if (v) return (0, schema_namespaceObject.toArr)(v);
|
|
60
|
+
return;
|
|
61
|
+
}
|
|
62
|
+
return v;
|
|
63
|
+
};
|
|
64
|
+
const Parentoptions = cm.getCollectionFields("".concat(collectionField, ".").concat(firstLevelValue));
|
|
65
|
+
const fieldParentTabsOptions = Parentoptions.map((item)=>{
|
|
66
|
+
if ('m2o' === item.interface) return {
|
|
67
|
+
...item,
|
|
68
|
+
label: compile(item.uiSchema.title),
|
|
69
|
+
value: item.name
|
|
70
|
+
};
|
|
71
|
+
}).filter(Boolean);
|
|
72
|
+
fieldParentTabsOptions.unshift({
|
|
73
|
+
label: t('none'),
|
|
74
|
+
value: 'none'
|
|
75
|
+
});
|
|
76
|
+
const matchedOption = fieldParentTabsOptions.find((option)=>option.value === value);
|
|
77
|
+
const newValue = matchedOption ? value : 'none';
|
|
78
|
+
(0, external_react_namespaceObject.useEffect)(()=>{
|
|
79
|
+
if (!matchedOption) {
|
|
80
|
+
var _props_onChange;
|
|
81
|
+
null === (_props_onChange = props.onChange) || void 0 === _props_onChange || _props_onChange.call(props, 'none');
|
|
82
|
+
}
|
|
83
|
+
}, [
|
|
84
|
+
value,
|
|
85
|
+
fieldParentTabsOptions
|
|
86
|
+
]);
|
|
87
|
+
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_antd_namespaceObject.Select, {
|
|
88
|
+
role: "button",
|
|
89
|
+
"data-testid": "select-".concat(mode || 'single'),
|
|
90
|
+
showSearch: true,
|
|
91
|
+
filterOption: filterOption,
|
|
92
|
+
allowClear: {
|
|
93
|
+
clearIcon: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(icons_namespaceObject.CloseCircleFilled, {
|
|
94
|
+
role: "button",
|
|
95
|
+
"aria-label": "icon-close-select"
|
|
96
|
+
})
|
|
97
|
+
},
|
|
98
|
+
popupMatchSelectWidth: false,
|
|
99
|
+
notFoundContent: loading ? /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_antd_namespaceObject.Spin, {}) : /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_antd_namespaceObject.Empty, {
|
|
100
|
+
image: external_antd_namespaceObject.Empty.PRESENTED_IMAGE_SIMPLE
|
|
101
|
+
}),
|
|
102
|
+
value: toValue(newValue),
|
|
103
|
+
defaultValue: toValue(defaultValue),
|
|
104
|
+
tagRender: (props)=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_antd_namespaceObject.Tag, {
|
|
105
|
+
role: "button",
|
|
106
|
+
"aria-label": props.label,
|
|
107
|
+
closeIcon: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(icons_namespaceObject.CloseOutlined, {
|
|
108
|
+
role: "button",
|
|
109
|
+
"aria-label": "icon-close-tag"
|
|
110
|
+
}),
|
|
111
|
+
...props,
|
|
112
|
+
children: props.label
|
|
113
|
+
}),
|
|
114
|
+
options: fieldParentTabsOptions,
|
|
115
|
+
...others,
|
|
116
|
+
onChange: (changed)=>{
|
|
117
|
+
var _props_onChange;
|
|
118
|
+
null === (_props_onChange = props.onChange) || void 0 === _props_onChange || _props_onChange.call(props, void 0 === changed ? null : changed);
|
|
119
|
+
},
|
|
120
|
+
mode: mode
|
|
121
|
+
});
|
|
122
|
+
}, (0, schema_namespaceObject.mapProps)({
|
|
123
|
+
dataSource: 'options'
|
|
124
|
+
}, (props, field)=>({
|
|
125
|
+
...props,
|
|
126
|
+
fieldNames: {
|
|
127
|
+
...external_schema_component_index_js_namespaceObject.defaultFieldNames,
|
|
128
|
+
...props.fieldNames
|
|
129
|
+
},
|
|
130
|
+
suffixIcon: (null == field ? void 0 : field['loading']) || (null == field ? void 0 : field['validating']) ? /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(icons_namespaceObject.LoadingOutlined, {}) : props.suffixIcon
|
|
131
|
+
})), (0, schema_namespaceObject.mapReadPretty)(ReadPretty_js_namespaceObject.ReadPretty));
|
|
132
|
+
var __webpack_export_target__ = exports;
|
|
133
|
+
for(var __webpack_i__ in __webpack_exports__)__webpack_export_target__[__webpack_i__] = __webpack_exports__[__webpack_i__];
|
|
134
|
+
if (__webpack_exports__.__esModule) Object.defineProperty(__webpack_export_target__, '__esModule', {
|
|
135
|
+
value: true
|
|
136
|
+
});
|