From c2523a687bcb700516fda84fb1d08a7fd3cfcdd1 Mon Sep 17 00:00:00 2001 From: Alexander Skoblikov Date: Wed, 11 Dec 2024 11:04:49 +0300 Subject: [PATCH 1/4] CB-6026 use nio api for deletion (#3125) Co-authored-by: Evgenia <139753579+EvgeniaBzzz@users.noreply.github.com> --- .../io/cloudbeaver/model/rm/local/LocalResourceController.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/bundles/io.cloudbeaver.model/src/io/cloudbeaver/model/rm/local/LocalResourceController.java b/server/bundles/io.cloudbeaver.model/src/io/cloudbeaver/model/rm/local/LocalResourceController.java index 173d45d5c9..e64f4adb84 100644 --- a/server/bundles/io.cloudbeaver.model/src/io/cloudbeaver/model/rm/local/LocalResourceController.java +++ b/server/bundles/io.cloudbeaver.model/src/io/cloudbeaver/model/rm/local/LocalResourceController.java @@ -511,7 +511,7 @@ public void deleteResource(@NotNull String projectId, @NotNull String resourcePa log.warn("Failed to remove resources properties", e); } try { - if (targetPath.toFile().isDirectory()) { + if (Files.isDirectory(targetPath)) { IOUtils.deleteDirectory(targetPath); } else { Files.delete(targetPath); From d09bb9bb58c4ba8314b1f989cd9c74abf620beb5 Mon Sep 17 00:00:00 2001 From: sergeyteleshev Date: Wed, 11 Dec 2024 09:05:27 +0100 Subject: [PATCH 2/4] CB-4070 Migrate Project form to form template (#3101) * CB-4070 small layout issues problems from the ticket comments * CB-4070 ux fixes for project create/edit behavior * CB-4070 pr fixes --------- Co-authored-by: mr-anton-t <42037741+mr-anton-t@users.noreply.github.com> Co-authored-by: Daria Marutkina <125263541+dariamarutkina@users.noreply.github.com> --- webapp/packages/core-blocks/src/StatusMessage.tsx | 15 ++++++++++----- webapp/packages/core-ui/src/Form/FormPart.ts | 1 + .../GrantedUsersTableInnerHeader.tsx | 2 +- .../Teams/GrantedUsers/GrantedUsersTableItem.tsx | 2 +- 4 files changed, 13 insertions(+), 7 deletions(-) diff --git a/webapp/packages/core-blocks/src/StatusMessage.tsx b/webapp/packages/core-blocks/src/StatusMessage.tsx index fa0daa8a5d..4ff92676f4 100644 --- a/webapp/packages/core-blocks/src/StatusMessage.tsx +++ b/webapp/packages/core-blocks/src/StatusMessage.tsx @@ -39,13 +39,18 @@ export const StatusMessage = observer(function StatusMessage({ const errorDetails = useErrorDetails(exception); const isError = type === ENotificationType.Error || exception !== null; - if (Array.isArray(message)) { - message = message.map(m => translate(m)).join(', '); - } else if (message !== null) { - message = translate(message); + function translateMessage(message: string | string[] | null | undefined) { + if (Array.isArray(message)) { + message = message.map(m => translate(m)).join(', '); + } else if (message !== null) { + message = translate(message); + } + + return message; } - message = message ?? errorDetails.message; + message = translateMessage(message) || translateMessage(errorDetails.message); + let icon = '/icons/info_icon.svg'; if (isError) { diff --git a/webapp/packages/core-ui/src/Form/FormPart.ts b/webapp/packages/core-ui/src/Form/FormPart.ts index 65f78ff32d..995a22626d 100644 --- a/webapp/packages/core-ui/src/Form/FormPart.ts +++ b/webapp/packages/core-ui/src/Form/FormPart.ts @@ -88,6 +88,7 @@ export abstract class FormPart implements IFormPar if (this.loading) { return; } + this.loading = true; try { diff --git a/webapp/packages/plugin-authentication-administration/src/Administration/Users/Teams/GrantedUsers/GrantedUsersTableHeader/GrantedUsersTableInnerHeader.tsx b/webapp/packages/plugin-authentication-administration/src/Administration/Users/Teams/GrantedUsers/GrantedUsersTableHeader/GrantedUsersTableInnerHeader.tsx index 6508115c54..47c29cb055 100644 --- a/webapp/packages/plugin-authentication-administration/src/Administration/Users/Teams/GrantedUsers/GrantedUsersTableHeader/GrantedUsersTableInnerHeader.tsx +++ b/webapp/packages/plugin-authentication-administration/src/Administration/Users/Teams/GrantedUsers/GrantedUsersTableHeader/GrantedUsersTableInnerHeader.tsx @@ -26,7 +26,7 @@ export const GrantedUsersTableInnerHeader = observer(function GrantedUser {translate('administration_teams_team_granted_users_user_id')} {showUserTeamRole && ( - + {translate('plugin_authentication_administration_team_user_team_role_supervisor')} )} diff --git a/webapp/packages/plugin-authentication-administration/src/Administration/Users/Teams/GrantedUsers/GrantedUsersTableItem.tsx b/webapp/packages/plugin-authentication-administration/src/Administration/Users/Teams/GrantedUsers/GrantedUsersTableItem.tsx index 5782909738..f43388d8d1 100644 --- a/webapp/packages/plugin-authentication-administration/src/Administration/Users/Teams/GrantedUsers/GrantedUsersTableItem.tsx +++ b/webapp/packages/plugin-authentication-administration/src/Administration/Users/Teams/GrantedUsers/GrantedUsersTableItem.tsx @@ -49,7 +49,7 @@ export const GrantedUsersTableItem = observer(function GrantedUsersTableI {name} {teamRoles.length > 0 && ( - + onTeamRoleAssign(id, value ? USER_TEAM_ROLE_SUPERVISOR : null)} From 22af3b1c5ea4d80217b52b20c1b1775f667e605d Mon Sep 17 00:00:00 2001 From: sergeyteleshev Date: Wed, 11 Dec 2024 11:16:09 +0100 Subject: [PATCH 3/4] CB-5935 removes perform update for changing connection view (#3124) Co-authored-by: mr-anton-t <42037741+mr-anton-t@users.noreply.github.com> Co-authored-by: Evgenia <139753579+EvgeniaBzzz@users.noreply.github.com> --- .../src/ConnectionInfoResource.ts | 22 +++++++++---------- 1 file changed, 10 insertions(+), 12 deletions(-) diff --git a/webapp/packages/core-connections/src/ConnectionInfoResource.ts b/webapp/packages/core-connections/src/ConnectionInfoResource.ts index 2d1fcd1a99..fb975d1612 100644 --- a/webapp/packages/core-connections/src/ConnectionInfoResource.ts +++ b/webapp/packages/core-connections/src/ConnectionInfoResource.ts @@ -421,20 +421,18 @@ export class ConnectionInfoResource extends CachedMapResource { - await this.performUpdate(key, [], async () => { - const connectionNavigatorViewSettings = this.get(key)?.navigatorSettings || DEFAULT_NAVIGATOR_VIEW_SETTINGS; - const { connection } = await this.graphQLService.sdk.setConnectionNavigatorSettings({ - connectionId: key.connectionId, - projectId: key.projectId, - settings: { ...connectionNavigatorViewSettings, ...settings }, - ...this.getDefaultIncludes(), - ...this.getIncludesMap(key), - }); - - this.set(createConnectionParam(connection), connection); - this.onDataOutdated.execute(key); + const connectionNavigatorViewSettings = this.get(key)?.navigatorSettings || DEFAULT_NAVIGATOR_VIEW_SETTINGS; + const { connection } = await this.graphQLService.sdk.setConnectionNavigatorSettings({ + connectionId: key.connectionId, + projectId: key.projectId, + settings: { ...connectionNavigatorViewSettings, ...settings }, + ...this.getDefaultIncludes(), + ...this.getIncludesMap(key), }); + this.set(createConnectionParam(connection), connection); + this.onDataOutdated.execute(key); + return this.get(key)!; } From 02e6b9c6de7a57c01ad40e9fe2ea7497fa3ec828 Mon Sep 17 00:00:00 2001 From: Anastasiya <45152336+LonwoLonwo@users.noreply.github.com> Date: Wed, 11 Dec 2024 14:12:17 +0300 Subject: [PATCH 4/4] dbeaver/pro#3712 update contributors readme part (#3131) --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index e46c903d76..01b56d0f84 100644 --- a/README.md +++ b/README.md @@ -57,5 +57,5 @@ You can see a live demo of CloudBeaver here: https://demo.cloudbeaver.io As a community-driven open-source project, we warmly welcome contributions through GitHub pull requests. [We are happy to reward](https://dbeaver.com/help-dbeaver/) our most active contributors every major sprint. -The most significant contribution to our code for the major release 24.2.0 was made by: -1. [matthieukhl](https://github.com/matthieukhl) +The most significant contribution to our code for the major release 24.3.0 was made by: +1. [cashlifei](https://github.com/cashlifei)