@nocobase/plugin-ai 2.3.0-alpha.1 → 3.0.0-alpha.1

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.
Files changed (246) hide show
  1. package/dist/ai/docs/nocobase/ai-employees/block/ai-chat-box.md +133 -0
  2. package/dist/ai/docs/nocobase/ai-employees/knowledge-base/knowledge-base/documents.md +1 -1
  3. package/dist/ai/docs/nocobase/ai-employees/knowledge-base/knowledge-base/index.md +11 -7
  4. package/dist/ai/docs/nocobase/ai-employees/knowledge-base/knowledge-base/settings.md +12 -8
  5. package/dist/ai/docs/nocobase/ai-employees/knowledge-base/vector-database.md +3 -3
  6. package/dist/ai/docs/nocobase/ai-employees/workflow/nodes/knowledge/create-document.md +1 -1
  7. package/dist/ai/docs/nocobase/api/app/env.md +3 -1
  8. package/dist/ai/docs/nocobase/api/cli/index.md +14 -2
  9. package/dist/ai/docs/nocobase/api/cli/portal/config.md +44 -0
  10. package/dist/ai/docs/nocobase/api/cli/portal/create.md +48 -0
  11. package/dist/ai/docs/nocobase/api/cli/portal/deploy.md +39 -0
  12. package/dist/ai/docs/nocobase/api/cli/portal/destroy.md +41 -0
  13. package/dist/ai/docs/nocobase/api/cli/portal/dev.md +39 -0
  14. package/dist/ai/docs/nocobase/api/cli/portal/index.md +136 -0
  15. package/dist/ai/docs/nocobase/api/cli/portal/info.md +41 -0
  16. package/dist/ai/docs/nocobase/api/cli/portal/list.md +40 -0
  17. package/dist/ai/docs/nocobase/api/cli/portal/pull.md +43 -0
  18. package/dist/ai/docs/nocobase/api/cli/portal/push.md +41 -0
  19. package/dist/ai/docs/nocobase/building-tips/ai-fill-js-block-form.md +1092 -0
  20. package/dist/ai/docs/nocobase/data-sources/calendar/calendar-collection.md +100 -3
  21. package/dist/ai/docs/nocobase/data-sources/collection-comment/index.md +92 -39
  22. package/dist/ai/docs/nocobase/data-sources/collection-sql/index.md +150 -29
  23. package/dist/ai/docs/nocobase/data-sources/collection-tree/index.md +93 -5
  24. package/dist/ai/docs/nocobase/data-sources/collection-view/index.md +226 -4
  25. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/advanced/china-region.md +122 -5
  26. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/advanced/collection-select.md +105 -4
  27. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/advanced/json.md +102 -4
  28. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/advanced/nano-id.md +104 -4
  29. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/advanced/snowflake-id.md +108 -4
  30. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/advanced/sort.md +3 -19
  31. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/advanced/uuid.md +104 -4
  32. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/associations/index.md +44 -8
  33. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/basic/color.md +102 -4
  34. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/basic/email.md +104 -4
  35. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/basic/icon.md +102 -4
  36. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/basic/input.md +112 -8
  37. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/basic/integer.md +103 -4
  38. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/basic/number.md +103 -4
  39. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/basic/password.md +102 -4
  40. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/basic/percent.md +104 -5
  41. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/basic/phone.md +104 -4
  42. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/basic/textarea.md +99 -8
  43. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/basic/url.md +103 -4
  44. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/choices/checkbox-group.md +105 -3
  45. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/choices/checkbox.md +102 -4
  46. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/choices/china-region.md +108 -5
  47. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/choices/multiple-select.md +103 -5
  48. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/choices/radio-group.md +106 -4
  49. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/choices/select.md +103 -5
  50. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/datetime/date.md +102 -4
  51. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/datetime/datetime-without-tz.md +103 -5
  52. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/datetime/datetime.md +103 -5
  53. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/datetime/index.md +53 -47
  54. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/datetime/time.md +102 -4
  55. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/datetime/unix-timestamp.md +103 -5
  56. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/geometric/circle.md +102 -4
  57. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/geometric/line.md +103 -5
  58. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/geometric/point.md +102 -4
  59. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/geometric/polygon.md +102 -4
  60. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/index.md +62 -16
  61. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/media/markdown.md +104 -4
  62. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/media/rich-text.md +105 -5
  63. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/system-info/created-at.md +105 -5
  64. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/system-info/created-by.md +103 -5
  65. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/system-info/space.md +100 -6
  66. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/system-info/table-oid.md +102 -4
  67. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/system-info/updated-at.md +104 -5
  68. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/system-info/updated-by.md +104 -6
  69. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection-fields/validation.md +68 -58
  70. package/dist/ai/docs/nocobase/data-sources/data-modeling/collection.md +32 -13
  71. package/dist/ai/docs/nocobase/data-sources/data-modeling/index.md +41 -33
  72. package/dist/ai/docs/nocobase/data-sources/data-source-external-mariadb/index.md +114 -6
  73. package/dist/ai/docs/nocobase/data-sources/data-source-external-mssql/index.md +117 -6
  74. package/dist/ai/docs/nocobase/data-sources/data-source-external-mysql/index.md +103 -6
  75. package/dist/ai/docs/nocobase/data-sources/data-source-external-nocobase/index.md +75 -73
  76. package/dist/ai/docs/nocobase/data-sources/data-source-external-oracle/index.md +129 -11
  77. package/dist/ai/docs/nocobase/data-sources/data-source-external-postgres/index.md +110 -6
  78. package/dist/ai/docs/nocobase/data-sources/data-source-kingbase/index.md +75 -49
  79. package/dist/ai/docs/nocobase/data-sources/data-source-main/general-collection.md +116 -15
  80. package/dist/ai/docs/nocobase/data-sources/data-source-main/index.md +92 -62
  81. package/dist/ai/docs/nocobase/data-sources/data-source-main/inheritance-collection.md +97 -10
  82. package/dist/ai/docs/nocobase/data-sources/data-source-manager/external-database.md +97 -58
  83. package/dist/ai/docs/nocobase/data-sources/data-source-manager/index.md +32 -24
  84. package/dist/ai/docs/nocobase/data-sources/data-source-rest-api/index.md +115 -153
  85. package/dist/ai/docs/nocobase/data-sources/external/clickhouse.md +124 -0
  86. package/dist/ai/docs/nocobase/data-sources/external/doris.md +130 -0
  87. package/dist/ai/docs/nocobase/data-sources/external/index.md +140 -0
  88. package/dist/ai/docs/nocobase/data-sources/external/kingbase.md +129 -0
  89. package/dist/ai/docs/nocobase/data-sources/external/mariadb.md +126 -0
  90. package/dist/ai/docs/nocobase/data-sources/external/mssql.md +129 -0
  91. package/dist/ai/docs/nocobase/data-sources/external/mysql.md +115 -0
  92. package/dist/ai/docs/nocobase/data-sources/external/nocobase.md +159 -0
  93. package/dist/ai/docs/nocobase/data-sources/external/oceanbase.md +126 -0
  94. package/dist/ai/docs/nocobase/data-sources/external/oracle.md +158 -0
  95. package/dist/ai/docs/nocobase/data-sources/external/postgresql.md +122 -0
  96. package/dist/ai/docs/nocobase/data-sources/external/rest-api.md +245 -0
  97. package/dist/ai/docs/nocobase/data-sources/field-attachment-url/index.md +100 -12
  98. package/dist/ai/docs/nocobase/data-sources/field-encryption/index.md +48 -47
  99. package/dist/ai/docs/nocobase/data-sources/field-formula/index.md +99 -5
  100. package/dist/ai/docs/nocobase/data-sources/field-markdown-vditor/index.md +105 -5
  101. package/dist/ai/docs/nocobase/data-sources/field-sequence/index.md +102 -5
  102. package/dist/ai/docs/nocobase/data-sources/field-signature/index.md +18 -16
  103. package/dist/ai/docs/nocobase/data-sources/field-sort/index.md +76 -73
  104. package/dist/ai/docs/nocobase/data-sources/file-manager/field-attachment.md +101 -7
  105. package/dist/ai/docs/nocobase/data-sources/file-manager/file-collection.md +101 -14
  106. package/dist/ai/docs/nocobase/data-sources/index.md +49 -33
  107. package/dist/ai/docs/nocobase/data-sources/main/index.md +130 -0
  108. package/dist/ai/docs/nocobase/data-sources/main/kingbase.md +147 -0
  109. package/dist/ai/docs/nocobase/data-sources/main/mariadb.md +59 -0
  110. package/dist/ai/docs/nocobase/data-sources/main/mysql.md +59 -0
  111. package/dist/ai/docs/nocobase/data-sources/main/oceanbase.md +62 -0
  112. package/dist/ai/docs/nocobase/data-sources/main/postgresql.md +61 -0
  113. package/dist/ai/docs/nocobase/file-manager/storage/index.md +66 -26
  114. package/dist/ai/docs/nocobase/file-manager/storage/s3-pro.md +58 -7
  115. package/dist/ai/docs/nocobase/get-started/installation/env.md +2 -2
  116. package/dist/ai/docs/nocobase/ops-management/migration-manager/built-in-tables.md +1 -2
  117. package/dist/ai/docs/nocobase/runjs/context/ai.md +194 -4
  118. package/dist/ai/tools/executeFrontendTool.d.ts +10 -0
  119. package/dist/ai/tools/executeFrontendTool.js +86 -0
  120. package/dist/ai/tools/getSkill.js +1 -1
  121. package/dist/ai/tools/loadFrontendTool.d.ts +10 -0
  122. package/dist/ai/tools/loadFrontendTool.js +99 -0
  123. package/dist/client/244.8631eb5cf3f05e21.js +10 -0
  124. package/dist/client/{525.203778500aca5d05.js → 525.94dd4136c1361477.js} +1 -1
  125. package/dist/client/681.6ffbc9329b9ac242.js +10 -0
  126. package/dist/{client-v2/705.1d10027ff8cfdf79.js → client/705.19b642db34de438a.js} +1 -1
  127. package/dist/client/index.d.ts +1 -3
  128. package/dist/client/index.js +8 -8
  129. package/dist/client-v2/244.c428e645ecb94414.js +10 -0
  130. package/dist/client-v2/420.b2aedb1ff71fca0e.js +10 -0
  131. package/dist/client-v2/681.6890caa389564ff7.js +10 -0
  132. package/dist/client-v2/705.8dc34d43f02f322c.js +10 -0
  133. package/dist/client-v2/ai-employees/AIEmployeeShortcut.d.ts +2 -0
  134. package/dist/client-v2/ai-employees/AddContextButton.d.ts +2 -0
  135. package/dist/client-v2/ai-employees/chatbox/components/AIEmployeeSwitcher.d.ts +1 -0
  136. package/dist/client-v2/ai-employees/chatbox/components/ChatBoxUnreadBadge.d.ts +17 -0
  137. package/dist/client-v2/ai-employees/chatbox/components/Conversations.d.ts +9 -1
  138. package/dist/client-v2/ai-employees/chatbox/components/MessageRenderers.d.ts +1 -1
  139. package/dist/client-v2/ai-employees/chatbox/components/Messages.d.ts +5 -1
  140. package/dist/client-v2/ai-employees/chatbox/components/ModelSwitcher.d.ts +4 -0
  141. package/dist/client-v2/ai-employees/chatbox/components/Sender.d.ts +33 -1
  142. package/dist/client-v2/ai-employees/chatbox/components/index.d.ts +1 -0
  143. package/dist/client-v2/ai-employees/chatbox/hooks/useChat.d.ts +8 -5
  144. package/dist/client-v2/ai-employees/chatbox/hooks/useChatBoxActions.d.ts +3 -2
  145. package/dist/client-v2/ai-employees/chatbox/hooks/useChatBoxEffect.d.ts +2 -1
  146. package/dist/client-v2/ai-employees/chatbox/hooks/useChatConversationActions.d.ts +3 -2
  147. package/dist/client-v2/ai-employees/chatbox/hooks/useChatMessageActions.d.ts +4 -2
  148. package/dist/client-v2/ai-employees/chatbox/hooks/useToolCallActions.d.ts +3 -1
  149. package/dist/client-v2/ai-employees/chatbox/hooks/useUploadFiles.d.ts +13 -3
  150. package/dist/client-v2/ai-employees/chatbox/hooks/useWorkflowTasks.d.ts +3 -2
  151. package/dist/client-v2/ai-employees/chatbox/index.d.ts +17 -0
  152. package/dist/client-v2/ai-employees/chatbox/roles.d.ts +2 -153
  153. package/dist/client-v2/ai-employees/chatbox/stores/chat-box.d.ts +46 -31
  154. package/dist/client-v2/ai-employees/chatbox/stores/chat-conversations.d.ts +7 -7
  155. package/dist/client-v2/ai-employees/chatbox/stores/chat-messages.d.ts +23 -18
  156. package/dist/client-v2/ai-employees/chatbox/stores/chat-sender.d.ts +43 -0
  157. package/dist/client-v2/ai-employees/chatbox/stores/chat-tool-call.d.ts +6 -5
  158. package/dist/client-v2/ai-employees/chatbox/stores/chat-tools.d.ts +11 -5
  159. package/dist/client-v2/ai-employees/chatbox/stores/mounted-chat-boxes.d.ts +20 -0
  160. package/dist/client-v2/ai-employees/chatbox/stores/runtime.d.ts +43 -0
  161. package/dist/client-v2/ai-employees/chatbox/stores/workflow-tasks.d.ts +22 -10
  162. package/dist/client-v2/ai-employees/chatbox/upload.d.ts +19 -0
  163. package/dist/client-v2/ai-employees/chatbox/utils.d.ts +28 -4
  164. package/dist/client-v2/ai-employees/frontend-tools.d.ts +11 -0
  165. package/dist/client-v2/ai-employees/tools/SuggestionsOptionsCard.d.ts +1 -1
  166. package/dist/client-v2/ai-employees/tools/WorkflowTaskOutputCard.d.ts +1 -1
  167. package/dist/client-v2/ai-employees/types.d.ts +30 -0
  168. package/dist/client-v2/block/ai-chat-box/AIChatBoxBlockModel.d.ts +21 -0
  169. package/dist/client-v2/block/ai-chat-box/AIChatBoxCoreModel.d.ts +13 -0
  170. package/dist/client-v2/block/ai-chat-box/components/AIChatBoxCoreView.d.ts +10 -0
  171. package/dist/client-v2/block/ai-chat-box/components/AIChatBoxView.d.ts +12 -0
  172. package/dist/client-v2/block/ai-chat-box/index.d.ts +14 -0
  173. package/dist/client-v2/block/ai-chat-box/settings.d.ts +12 -0
  174. package/dist/client-v2/block/ai-chat-box/sub-models.d.ts +26 -0
  175. package/dist/client-v2/block/ai-chat-box/types.d.ts +38 -0
  176. package/dist/client-v2/block/ai-chat-box/utils.d.ts +26 -0
  177. package/dist/client-v2/index.d.ts +3 -5
  178. package/dist/client-v2/index.js +3 -3
  179. package/dist/client-v2/llm-services/model-select.d.ts +33 -0
  180. package/dist/client-v2/llm-services/utils.d.ts +1 -0
  181. package/dist/client-v2/manager/ai-manager.d.ts +10 -3
  182. package/dist/client-v2/manager/frontend-tool-registry.d.ts +30 -0
  183. package/dist/client-v2/models/ai-employees/AIEmployeeActionModel.d.ts +4 -1
  184. package/dist/client-v2/models/ai-employees/AIEmployeeShortcutModel.d.ts +5 -0
  185. package/dist/client-v2/pages/EmployeesPage.d.ts +2 -0
  186. package/dist/client-v2/runjs/registerAIEmployeeRunJSFacade.d.ts +1 -0
  187. package/dist/common/ai-employee-validation.d.ts +15 -0
  188. package/dist/common/ai-employee-validation.js +61 -0
  189. package/dist/common/error-codes.d.ts +13 -0
  190. package/dist/common/error-codes.js +48 -0
  191. package/dist/common/frontend-tools.d.ts +26 -0
  192. package/dist/common/frontend-tools.js +57 -0
  193. package/dist/common/llm-service-models.d.ts +16 -0
  194. package/dist/common/llm-service-models.js +84 -0
  195. package/dist/externalVersion.js +16 -16
  196. package/dist/locale/en-US.json +67 -0
  197. package/dist/locale/zh-CN.json +67 -0
  198. package/dist/node_modules/@langchain/mistralai/package.json +1 -1
  199. package/dist/node_modules/@langchain/xai/package.json +1 -1
  200. package/dist/node_modules/fs-extra/package.json +1 -1
  201. package/dist/node_modules/jsonrepair/package.json +1 -1
  202. package/dist/node_modules/just-bash/package.json +1 -1
  203. package/dist/node_modules/nodejs-snowflake/package.json +1 -1
  204. package/dist/node_modules/openai/package.json +1 -1
  205. package/dist/node_modules/zod/package.json +1 -1
  206. package/dist/server/ai-employees/ai-conversations.d.ts +4 -1
  207. package/dist/server/ai-employees/ai-conversations.js +2 -0
  208. package/dist/server/ai-employees/ai-employee.d.ts +2 -1
  209. package/dist/server/ai-employees/ai-employee.js +26 -7
  210. package/dist/server/ai-employees/middleware/conversation.js +9 -2
  211. package/dist/server/collections/ai-conversations.js +5 -0
  212. package/dist/server/document-loader/constants.js +1 -1
  213. package/dist/server/frontend-tools.d.ts +25 -0
  214. package/dist/server/frontend-tools.js +171 -0
  215. package/dist/server/manager/work-context-handler.js +10 -3
  216. package/dist/server/plugin.d.ts +1 -0
  217. package/dist/server/plugin.js +25 -0
  218. package/dist/server/resource/aiConversations.d.ts +2 -0
  219. package/dist/server/resource/aiConversations.js +33 -3
  220. package/dist/server/resource/aiEmployees.d.ts +2 -0
  221. package/dist/server/resource/aiEmployees.js +62 -0
  222. package/dist/server/resource/aiWorkflowTasks.js +9 -1
  223. package/dist/server/resource/llmServices.d.ts +11 -0
  224. package/dist/server/resource/llmServices.js +85 -0
  225. package/dist/server/types/knowledge-base.type.d.ts +6 -2
  226. package/dist/swagger/common.d.ts +143 -0
  227. package/dist/swagger/common.js +144 -0
  228. package/dist/swagger/employees.d.ts +301 -0
  229. package/dist/swagger/employees.js +131 -0
  230. package/dist/swagger/index.d.ts +1588 -0
  231. package/dist/swagger/index.js +62 -0
  232. package/dist/swagger/llm.d.ts +555 -0
  233. package/dist/swagger/llm.js +247 -0
  234. package/dist/swagger/schemas.d.ts +736 -0
  235. package/dist/swagger/schemas.js +381 -0
  236. package/package.json +2 -2
  237. package/dist/ai/docs/nocobase/ai-employees/knowledge-base/vector-store.md +0 -24
  238. package/dist/ai/docs/nocobase/data-sources/development/index.md +0 -6
  239. package/dist/client/372.40eb52905e3f3049.js +0 -10
  240. package/dist/client/681.399948c18d753667.js +0 -10
  241. package/dist/client/705.380279da896021fb.js +0 -10
  242. package/dist/client-v2/372.8cc3fde09c9bec77.js +0 -10
  243. package/dist/client-v2/406.341be51205c674e0.js +0 -10
  244. package/dist/client-v2/681.082f4f1c7b841983.js +0 -10
  245. package/dist/client-v2/ai-employees/chatbox/stores/create-selectors.d.ts +0 -46
  246. package/dist/client-v2/ai-employees/chatbox/utils/normalizeTriggerTaskOptions.d.ts +0 -19
@@ -1,18 +1,122 @@
1
1
  ---
2
2
  pkg: "@nocobase/plugin-data-source-external-postgres"
3
+ title: "External data source - PostgreSQL"
4
+ description: "Connect PostgreSQL as an external NocoBase database, including version support, plugin installation, connection configuration, Schema, SSL, permissions, and field mapping."
5
+ keywords: "external data source,PostgreSQL,external database,Schema,SSL,field mapping,NocoBase"
3
6
  ---
4
7
 
5
- # External Data Source - PostgreSQL
8
+ # PostgreSQL
6
9
 
7
10
  ## Introduction
8
11
 
9
- Use an external PostgreSQL database as a data source. Currently supported versions: PostgreSQL >= 9.5
12
+ PostgreSQL can be connected to NocoBase as an external database. NocoBase reads PostgreSQL tables, fields, and views and uses them as collections in the external data source.
10
13
 
11
- ## Installation
14
+ Unlike the [main database](../main/index.md), the original business system, database client, or migration scripts continue to maintain the real PostgreSQL schema. NocoBase reads structure, stores field metadata, and configures blocks, permissions, workflows, and APIs.
12
15
 
13
- This is a commercial plugin. For detailed activation instructions, please refer to: [Commercial Plugin Activation Guide](https://www.nocobase.com/en/blog/nocobase-commercial-license-activation-guide)
16
+ | Setting | Description |
17
+ | --- | --- |
18
+ | Supported version | PostgreSQL >= 9.5. |
19
+ | Commercial editions | Standard, Professional, and Enterprise. |
20
+ | Plugin | `@nocobase/plugin-data-source-external-postgres`. |
14
21
 
22
+ Use external PostgreSQL to connect existing ERP, MES, WMS, or CRM databases; build management pages without migrating historical data; apply permissions, workflows, corrections, or reports to existing tables; and leave schema maintenance to DBAs, migration scripts, or the original system.
15
23
 
16
- ## Usage Instructions
24
+ :::warning Note
17
25
 
18
- Refer to the [Data Source / External Database](/data-sources/data-source-manager/external-database) section.
26
+ External PostgreSQL is not the NocoBase system database. NocoBase does not manage its backup, restore, migrations, or schema changes.
27
+
28
+ :::
29
+
30
+ ## Plugin installation
31
+
32
+ This is a commercial plugin. See the [commercial plugin activation guide](https://www.nocobase.com/en/blog/nocobase-commercial-license-activation-guide) for activation.
33
+
34
+ ## Add a data source
35
+
36
+ In **Data source management**, click **Add new**, select PostgreSQL, and enter the connection information.
37
+
38
+ ![Add PostgreSQL](https://static-docs.nocobase.com/20260709204045.png)
39
+
40
+ | Setting | Description |
41
+ | --- | --- |
42
+ | Data source name | Internal identifier used by blocks, permissions, workflows, and APIs. It cannot be changed after creation. |
43
+ | Data source display name | Name shown in the interface, such as ERP PostgreSQL or Reporting database. |
44
+ | Host / Port | PostgreSQL server address and port. The usual default port is `5432`. |
45
+ | Database | The PostgreSQL database to connect. |
46
+ | Username / Password | Connection credentials. NocoBase reads only objects that this account is allowed to access; it does not grant access to other users' private objects. |
47
+ | Schema | The PostgreSQL schema to read, such as `public`. When several schemas exist, set only the schema required by the current business use. |
48
+ | Table prefix | Limits reading to matching tables and views, and removes the prefix from the NocoBase collection name. |
49
+ | Collections / Add all collections | Controls the imported scope. With **Add all collections** enabled, NocoBase imports all tables and views in scope; otherwise it imports only selected objects. |
50
+ | Enabled the data source | Disables or enables access through blocks, permissions, workflows, and APIs while keeping the configuration. |
51
+ | SSL options | PostgreSQL SSL settings, including SSL mode, unauthorized-certificate handling, and CA, client-certificate, and client-key paths. |
52
+
53
+ :::tip Tip
54
+
55
+ For a database with many objects, narrow the scope with `Schema`, `Table prefix`, and **Collections**. Import only tables and views that the application needs so that permission configuration, page building, and later synchronization remain manageable.
56
+
57
+ :::
58
+
59
+ ## Select collections
60
+
61
+ After connection settings are entered, click **Load Collections** to read available PostgreSQL tables and views. Results depend on the connection account, `Schema`, `Table prefix`, and **Collections** settings.
62
+
63
+ **Add all collections** is enabled by default and imports every table and view in the current scope. Disable it and select individual tables or views when only part of the database is needed.
64
+
65
+ ![Select PostgreSQL collections](https://static-docs.nocobase.com/20260709204309.png)
66
+
67
+ :::warning Note
68
+
69
+ One external data source can import at most 500 tables or views. Narrow the scope with `Schema`, `Table prefix`, or **Collections** when PostgreSQL has many objects.
70
+
71
+ :::
72
+
73
+ ## Synchronize and configure fields
74
+
75
+ PostgreSQL maintains the external table structure. NocoBase does not create columns, change column types, or delete real fields in external PostgreSQL.
76
+
77
+ When the PostgreSQL schema changes, use **Sync from database** to reread collection and field metadata. Synchronization updates NocoBase collections, fields, primary keys, unique keys, and type mappings; it does not delete real PostgreSQL tables or data.
78
+
79
+ After synchronization, configure field titles, Field types, and Field interfaces in NocoBase. NocoBase relation fields are relation metadata only and do not automatically add real foreign-key columns to PostgreSQL.
80
+
81
+ ## Field type mapping
82
+
83
+ NocoBase automatically maps PostgreSQL types to suitable Field types and Field interfaces. You can adjust the display interface in field configuration.
84
+
85
+ | PostgreSQL type | NocoBase Field type | Available Field interfaces |
86
+ | --- | --- | --- |
87
+ | `BOOLEAN` | `boolean` | Checkbox, Switch. |
88
+ | `SMALLINT`, `INTEGER`, `SERIAL`, `SMALLSERIAL` | `integer`, `boolean`, `sort` | Integer, Sort, Checkbox, Switch, Select, Radio group. |
89
+ | `BIGINT`, `BIGSERIAL` | `bigInt`, `sort` | Integer, Sort, Checkbox, Switch, Select, Radio group, Unix timestamp, Created at, Updated at. |
90
+ | `REAL` | `float` | Number, Percent. |
91
+ | `DOUBLE PRECISION` | `double` | Number, Percent. |
92
+ | `DECIMAL`, `NUMERIC` | `decimal` | Number, Percent, Currency. |
93
+ | `VARCHAR`, `CHAR` | `string`, `password`, `uuid`, `nanoid` | Input, Email, Phone, Password, Color, Icon, Select, Radio group, UUID, Nano ID. |
94
+ | `TEXT` | `text`, `json` | Textarea, Markdown, Vditor, Rich text, URL, JSON. |
95
+ | `UUID` | `uuid` | UUID. |
96
+ | `JSON`, `JSONB` | `json` | JSON. |
97
+ | `TIMESTAMP` | `date` | Date, Time, Created at, Updated at. |
98
+ | `DATE` | `dateOnly` | Date. |
99
+ | `TIME` | `time` | Time. |
100
+ | `POINT`, `LINESTRING`, `POLYGON`, `CIRCLE` | `point`, `lineString`, `polygon`, `circle` | Point, Line string, Polygon, Circle, JSON. |
101
+ | `ARRAY` | `array` | Multiple select, Checkbox group. |
102
+
103
+ :::warning Note
104
+
105
+ Unsupported PostgreSQL types are shown separately in field configuration. They require development support before they can be used as normal NocoBase fields.
106
+
107
+ :::
108
+
109
+ ## Primary key and Record unique key
110
+
111
+ Collections used for block display and editing should have a primary key or unique field. NocoBase uses the primary key as the Record unique key when available.
112
+
113
+ For views, tables without a primary key, or composite-primary-key tables, configure **Record unique key** manually. Without a usable identifier, blocks might not view, edit, or delete records correctly.
114
+
115
+ ![Primary key and Record unique key](https://static-docs.nocobase.com/20260709204742.png)
116
+ ![Configure Record unique key](https://static-docs.nocobase.com/20260709204827.png)
117
+
118
+ ## Related links
119
+
120
+ - [External databases](./index.md) - General external-database configuration and management.
121
+ - [Data source management](../data-source-manager/index.md) - Data-source entry points and management.
122
+ - [Collection fields](../data-modeling/collection-fields/index.md) - Field types and mapping.
@@ -1,29 +1,42 @@
1
1
  ---
2
2
  pkg: "@nocobase/plugin-data-source-kingbase"
3
+ title: "Main data source - KingbaseES"
4
+ description: "Learn KingbaseES version support, installation, environment variables, Docker deployment, usage, and field mapping for the NocoBase main database."
5
+ keywords: "main data source,KingbaseES,main database,PostgreSQL compatibility mode,field mapping,NocoBase"
3
6
  ---
4
7
 
5
- # Data Source - KingbaseES Database
8
+ # KingbaseES
6
9
 
7
10
  ## Introduction
8
11
 
9
- KingbaseES can be used as a data source, either as the primary database or an external database.
12
+ KingbaseES can be used as the NocoBase main database. It stores NocoBase system-table data and business data in the main data source. Configure it when deploying NocoBase; it cannot be deleted after the application is running.
13
+
14
+ To connect an existing KingbaseES database as an external database, see [External KingbaseES](../external/kingbase.md).
15
+
16
+ | Setting | Description |
17
+ | --- | --- |
18
+ | Supported version | >= V9. |
19
+ | Commercial editions | Professional and Enterprise. |
20
+ | Database type | PostgreSQL compatibility mode. |
21
+
22
+ :::warning Note
23
+
24
+ Only KingbaseES databases running in PostgreSQL compatibility mode are supported.
10
25
 
11
- :::warning
12
- Currently, only KingbaseES databases running in pg mode are supported.
13
26
  :::
14
27
 
15
28
  ## Installation
16
29
 
17
- ### Using as the Primary Database
30
+ ### Use as the main database
18
31
 
19
- Refer to the Installation documentation for the setup procedures, the difference is mainly due to the environment variables.
32
+ Follow [Install a NocoBase application](/ai/install-nocobase-app). The main difference is the database environment variables.
20
33
 
21
- #### Environment Variables
34
+ #### Environment variables
22
35
 
23
- Edit the .env file to add or modify the following environment variable configurations:
36
+ Add or update these database variables in `.env`:
24
37
 
25
38
  ```bash
26
- # Adjust DB parameters as needed
39
+ # Adjust DB parameters for your environment.
27
40
  DB_DIALECT=kingbase
28
41
  DB_HOST=localhost
29
42
  DB_PORT=54321
@@ -32,7 +45,7 @@ DB_USER=nocobase
32
45
  DB_PASSWORD=nocobase
33
46
  ```
34
47
 
35
- #### Docker Installation
48
+ #### Docker installation
36
49
 
37
50
  ```yml
38
51
  networks:
@@ -41,81 +54,94 @@ networks:
41
54
 
42
55
  services:
43
56
  app:
44
- image: nocobase/nocobase:latest
57
+ image: registry.cn-shanghai.aliyuncs.com/nocobase/nocobase:latest
45
58
  restart: always
46
- networks:
47
- - nocobase
48
- depends_on:
49
- - kingbase
59
+ networks: [nocobase]
60
+ depends_on: [kingbase]
50
61
  environment:
51
- # Application key for generating user tokens, etc.
52
- # Changing APP_KEY invalidates old tokens
53
- # Use a random string and keep it confidential
54
62
  - APP_KEY=your-secret-key
55
- # Database type
56
63
  - DB_DIALECT=kingbase
57
- # Database host, replace with existing database server IP if needed
58
64
  - DB_HOST=kingbase
59
65
  - DB_PORT=54321
60
- # Database name
61
66
  - DB_DATABASE=kingbase
62
- # Database user
63
67
  - DB_USER=nocobase
64
- # Database password
65
68
  - DB_PASSWORD=nocobase
66
- # Timezone
67
69
  - TZ=UTC
68
70
  volumes:
69
71
  - ./storage:/app/nocobase/storage
70
72
  ports:
71
73
  - "11000:80"
72
74
 
73
- # Kingbase service for testing purposes only
74
75
  kingbase:
75
- image: nocobase/kingbase:v009r001c001b0030_single_x86
76
+ image: registry.cn-shanghai.aliyuncs.com/nocobase/kingbase:v009r001c001b0030_single_x86
76
77
  platform: linux/amd64
77
78
  restart: always
78
79
  privileged: true
79
- networks:
80
- - nocobase
80
+ networks: [nocobase]
81
81
  volumes:
82
82
  - ./storage/db/kingbase:/home/kingbase/userdata
83
83
  environment:
84
- ENABLE_CI: no # Must be set to no
84
+ ENABLE_CI: no
85
85
  DB_USER: nocobase
86
86
  DB_PASSWORD: nocobase
87
- DB_MODE: pg # pg only
87
+ DB_MODE: pg
88
88
  NEED_START: yes
89
89
  command: ["/usr/sbin/init"]
90
90
  ```
91
91
 
92
- #### Installation Using create-nocobase-app
92
+ `APP_KEY` is used for user tokens and similar application secrets. Changing it invalidates existing tokens; use a random value and store it safely. The `kingbase` service is intended only for local evaluation. `DB_MODE` must be `pg`.
93
+
94
+ #### Install with create-nocobase-app
93
95
 
94
96
  ```bash
95
97
  yarn create nocobase-app my-nocobase-app -d kingbase \
96
- -e DB_HOST=localhost \
97
- -e DB_PORT=54321 \
98
- -e DB_DATABASE=kingbase \
99
- -e DB_USER=nocobase \
100
- -e DB_PASSWORD=nocobase \
101
- -e TZ=UTC
98
+ -e DB_HOST=localhost \
99
+ -e DB_PORT=54321 \
100
+ -e DB_DATABASE=kingbase \
101
+ -e DB_USER=nocobase \
102
+ -e DB_PASSWORD=nocobase \
103
+ -e TZ=Asia/Shanghai
102
104
  ```
103
105
 
104
- ### Using as an External Database
106
+ ### Use as an external database
105
107
 
106
- Execute the installation or upgrade command
108
+ For configuration entry points, connection parameters, and synchronization rules when using KingbaseES as an external database, see [External KingbaseES](../external/kingbase.md).
107
109
 
108
- ```bash
109
- yarn nocobase install
110
- # or
111
- yarn nocobase upgrade
112
- ```
110
+ ## Usage
113
111
 
114
- Activate the Plugin
112
+ KingbaseES main data sources use PostgreSQL compatibility mode. For everyday management, see [PostgreSQL main data source](../main/postgresql.md).
115
113
 
116
- ![20241024121815](https://static-docs.nocobase.com/20241024121815.png)
114
+ 1. Select or enter KingbaseES connection settings when deploying NocoBase.
115
+ 2. After NocoBase starts, open **Data source management**, select **Main**, and manage collections and fields.
116
+ 3. Use **Sync from database** to connect tables that already exist in the main database.
117
+ 4. Use [Collections](../data-modeling/collection.md) and [Collection fields](../data-modeling/collection-fields/index.md) to choose Field types and Field interfaces.
117
118
 
118
- ## User Guide
119
+ ## Field type mapping
120
+
121
+ When you create a field in NocoBase, NocoBase creates the corresponding KingbaseES field. When you synchronize an existing table, NocoBase applies PostgreSQL-compatible mapping to select a Field type and Field interface.
122
+
123
+ | KingbaseES type | NocoBase Field type | Available Field interfaces |
124
+ | --- | --- | --- |
125
+ | `BOOLEAN` | `boolean` | Checkbox, Switch. |
126
+ | `SMALLINT`, `INTEGER` | `integer`, `sort` | Integer, Sort, Select, Radio group. |
127
+ | `BIGINT` | `bigInt`, `snowflakeId`, `unixTimestamp`, `sort` | Integer, Sort, Unix timestamp, Created at, Updated at. |
128
+ | `REAL`, `DOUBLE PRECISION` | `float` | Number, Percent. |
129
+ | `DECIMAL`, `NUMERIC` | `decimal` | Number, Percent, Currency. |
130
+ | `VARCHAR`, `CHAR` | `string`, `uuid`, `nanoid`, `encryption`, `datetimeNoTz` | Input, Email, Phone, Password, Color, Icon, Select, Radio group, UUID, Nano ID. |
131
+ | `TEXT` | `text` | Textarea, Markdown, Vditor, Rich text, URL. |
132
+ | `UUID` | `uuid` | UUID. |
133
+ | `JSON`, `JSONB` | `json`, `array` | JSON. |
134
+ | `TIMESTAMP WITHOUT TIME ZONE` | `datetimeNoTz` | Date, Time, Created at, Updated at. |
135
+ | `TIMESTAMP WITH TIME ZONE` | `datetimeTz`, `date` | Date, Time, Created at, Updated at. |
136
+ | `DATE` | `dateOnly` | Date. |
137
+ | `TIME WITHOUT TIME ZONE` | `time` | Time. |
138
+ | `POINT`, `PATH`, `POLYGON`, `CIRCLE` | `json` | JSON. |
139
+ | `ARRAY` | `array` | Multiple select, Checkbox group, JSON. |
140
+
141
+ :::warning Note
142
+
143
+ Unsupported KingbaseES types are shown separately in field configuration. They require development support before they can be used as normal NocoBase fields.
144
+
145
+ :::
119
146
 
120
- - Primary Database: Refer to the [Main data source](/data-sources/data-source-main/index.md)
121
- - External Database: See [Data Source / External Database](/data-sources/data-source-manager/external-database)
147
+ For common configuration, see [Main database](./index.md).
@@ -1,30 +1,131 @@
1
1
  ---
2
2
  pkg: "@nocobase/plugin-data-source-main"
3
+ title: "General collection"
4
+ description: "Use a General collection for common business data such as customers, orders, contracts, work orders, projects, and tasks."
5
+ keywords: "General collection,system fields,collection,NocoBase"
3
6
  ---
4
7
 
5
- # General Collection
8
+ # General collection
6
9
 
7
10
  ## Introduction
8
- It is used in most scenarios. A general collection can be used unless a special collection template is needed.
9
11
 
10
- ## User Manual
12
+ A **General collection** is the most common collection type. Use it for customers, orders, contracts, work orders, expense claims, projects, tasks, and other business records that do not need a special structure.
11
13
 
14
+ General collections can come from a new table created in the main database, an existing main-database table synchronized into NocoBase, an external-database table, a resource mapped from a REST API, or a collection in an external NocoBase application.
12
15
 
13
- ![20240324085739](https://static-docs.nocobase.com/20240324085739.png)
16
+ All of these are used as general collections in NocoBase. The difference is that NocoBase can create and maintain the real table structure for a main-database collection, while an external source normally exposes an existing structure maintained by the external system.
14
17
 
15
- ### Set Primary Key
18
+ ## Use cases
16
19
 
17
- When creating a collection, you need to specify a primary key field. It is recommended to enable the preset ID field when creating a new collection. The default primary key type for the ID field is Snowflake ID (53-bit).
20
+ - CRM data such as customers, contacts, opportunities, and contracts.
21
+ - Transaction data such as orders, deliveries, returns, and invoices.
22
+ - Collaboration data such as work orders, tasks, projects, and requirements.
23
+ - Process data such as expense claims, purchase orders, and payment requests.
24
+ - Master data such as equipment, assets, products, and stores.
18
25
 
19
- ![20251209210153](https://static-docs.nocobase.com/20251209210153.png)
26
+ ## Create and configure
20
27
 
21
- Hover over the Interface of the ID field to select other primary key types.
28
+ In the main data source, click **Create collection** and select **General collection**.
22
29
 
23
- ![20251209210517](https://static-docs.nocobase.com/20251209210517.png)
30
+ ![Create a general collection](https://static-docs.nocobase.com/20240324085739.png)
24
31
 
25
- Available primary key types include:
26
- - [Text](/data-sources/data-modeling/collection-fields/basic/input)
27
- - [Integer](/data-sources/data-modeling/collection-fields/basic/integer)
28
- - [Snowflake ID (53-bit)](/data-sources/data-modeling/collection-fields/advanced/snowflake-id)
29
- - [UUID](/data-sources/data-modeling/collection-fields/advanced/uuid)
30
- - [Nano ID](/data-sources/data-modeling/collection-fields/advanced/nano-id)
32
+ | Setting | Description |
33
+ | --- | --- |
34
+ | Collection display name | The name displayed in the interface, such as Customers, Orders, or Contract attachments. Use a name business users can understand. |
35
+ | Collection name | The internal identifier used by APIs, relation fields, permissions, and workflows. It is generated automatically but can be changed before creation. It supports letters, numbers, and underscores and must start with a letter. |
36
+ | Categories | Organizes collections in data-source management without changing the collection structure. Use business modules such as Customer management, Projects, or Finance when many collections exist. |
37
+ | Description | Document what the collection stores, who maintains it, and the related business processes. |
38
+ | Use simple pagination mode | Skips total-record counting when table blocks paginate. Use it for very large collections to reduce query pressure. |
39
+ | Preset fields | Adds common fields such as ID, created at, created by, updated at, and last updated by. Keep them for normal business collections. |
40
+
41
+ ### Built-in fields
42
+
43
+ Use `Preset fields` to add common system fields when creating the collection.
44
+
45
+ | Field | Field name | Description |
46
+ | --- | --- | --- |
47
+ | ID | `id` | The default primary key that uniquely identifies a record. Its default primary-key interface is `Snowflake ID (53-bit)`. |
48
+ | Created at | `createdAt` | Records when a record was created. Use it for sorting, filtering, auditing, and workflow conditions. |
49
+ | Created by | `createdBy` | Records the user who created the record. Use it for creator filtering, permissions, and ownership tracking. |
50
+ | Updated at | `updatedAt` | Records when the record was last updated. |
51
+ | Last updated by | `updatedBy` | Records the user who last updated the record. |
52
+ | [Space](../../multi-app/multi-space/index.md) | `space` | Available when the multi-space plugin is enabled. It isolates data by space and is not shown in preset fields otherwise. |
53
+
54
+ ### Primary key field
55
+
56
+ **Primary key** identifies a record uniquely at the database level. Keep the ID preset field when creating a collection; its default primary-key interface is `Snowflake ID (53-bit)`.
57
+
58
+ ![Primary key field](https://static-docs.nocobase.com/20251209210153.png)
59
+
60
+ Hover over the ID field interface to select another primary-key type.
61
+
62
+ ![Select a primary-key interface](https://static-docs.nocobase.com/20251209210517.png)
63
+
64
+ Available primary-key types are [Single line text](../data-modeling/collection-fields/basic/input.md), [Integer](../data-modeling/collection-fields/basic/integer.md), [Snowflake ID (53-bit)](../data-modeling/collection-fields/advanced/snowflake-id.md), [UUID](../data-modeling/collection-fields/advanced/uuid.md), and [Nano ID](../data-modeling/collection-fields/advanced/nano-id.md).
65
+
66
+ :::warning Note
67
+
68
+ A collection without a primary key must set a **Record unique key** when editing the collection. Otherwise, blocks cannot be created and records cannot be viewed or edited reliably.
69
+
70
+ :::
71
+
72
+ ## Use in pages
73
+
74
+ General collections can be used by most data and filter blocks.
75
+
76
+ | Block | Use |
77
+ | --- | --- |
78
+ | [Table](../../interface-builder/blocks/data-blocks/table.md) | View, filter, sort, and batch-process records. |
79
+ | [Form](../../interface-builder/blocks/data-blocks/form.md) | Create or edit one record. |
80
+ | [Details](../../interface-builder/blocks/data-blocks/details.md) | View one record in detail. |
81
+ | [List](../../interface-builder/blocks/data-blocks/list.md) | Display records as a list. |
82
+ | [Grid card](../../interface-builder/blocks/data-blocks/grid-card.md) | Display images, files, products, assets, and other records as cards. |
83
+ | [Kanban](../../interface-builder/blocks/data-blocks/kanban.md) | Group records by status, stage, owner, or another field. |
84
+ | [Calendar](../../interface-builder/blocks/data-blocks/calendar.md) | Display records by date or time range. |
85
+ | [Chart](../../interface-builder/blocks/data-blocks/chart.md) | Create statistics charts from records. |
86
+ | [Map](../../interface-builder/blocks/data-blocks/map.md) | Display records by geographic location. |
87
+ | [Gantt](../../plugins/@nocobase/plugin-gantt/index.md) | Display project plans and task schedules by start and end time. |
88
+ | [Form filter](../../interface-builder/blocks/filter-blocks/form.md) | Filter data blocks with form conditions. |
89
+ | [Tree filter](../../interface-builder/blocks/filter-blocks/tree.md) | Filter data blocks by hierarchy, such as category, organization, or region. |
90
+
91
+ ## Edit configuration
92
+
93
+ Click **Edit** beside the collection to change collection metadata and selected runtime configuration. Use **Configure fields** to add fields, change Field types or interfaces, or delete fields.
94
+
95
+ ![Edit a collection](https://static-docs.nocobase.com/edit_collection.png)
96
+
97
+ ![Edit collection configuration](https://static-docs.nocobase.com/edit_collection_configure.png)
98
+
99
+ | Setting | Can be edited | Description |
100
+ | --- | --- | --- |
101
+ | Collection display name | Yes | Changes only the name displayed in the interface. |
102
+ | Collection name | No | The internal identifier cannot be changed after creation. |
103
+ | Inherits | Conditional | Available only when the main database is PostgreSQL and the setting is displayed. Check fields, blocks, permissions, and workflows before changing inheritance for an existing collection. |
104
+ | Categories | Yes | Organizes the management interface without changing the schema. |
105
+ | Description | Yes | Document the collection purpose, maintainer, source, and related processes. |
106
+ | Use simple pagination mode | Yes | Skips total-count queries in table blocks. |
107
+ | Record unique key | Yes | Locates records in blocks. It normally uses a primary key or unique field. |
108
+
109
+ :::warning Note
110
+
111
+ Editing a collection does not adjust existing fields automatically. `Preset fields` apply only at creation. Add created-at, created-by, updated-at, or updated-by fields later through **Configure fields**.
112
+
113
+ :::
114
+
115
+ ## Delete a collection
116
+
117
+ Click **Delete** beside a general collection to delete it. Main-database collections can also be selected and deleted in batches.
118
+
119
+ ![Delete a collection](https://static-docs.nocobase.com/delete_collection.png)
120
+
121
+ After confirmation, NocoBase removes the collection metadata and the real table and data in the main database.
122
+
123
+ ![Delete confirmation](https://static-docs.nocobase.com/delete_collection_second_confirmation.png)
124
+
125
+ The confirmation dialog can automatically delete database objects that depend on the collection, such as database views built from it and objects that depend on those views.
126
+
127
+ :::danger Warning
128
+
129
+ Deleting a general collection is high risk. It can remove the table structure, table data, field metadata, and dependent page blocks, relation fields, permissions, workflows, and API calls. Confirm that dependent objects can be deleted before enabling automatic deletion.
130
+
131
+ :::