Database governance built for humans and agents — controlling changes and access across every major database.
Go cicddata-governancedata-maskingdata-securitydatabase-accessdatabase-governancedevopsdevsecopsflywaygitopsliquibasemongodbmysqloraclepostgresqlschema-migrationssecuritysql-clientsqlservertidb
fix: merge metadata config (#9260)
ecmadaoefaf36c2ee19
diff --git a/frontend/src/store/modules/v1/dbSchema.ts b/frontend/src/store/modules/v1/dbSchema.tsindex 3f459ccee0..7f2cc61c16 100644--- a/frontend/src/store/modules/v1/dbSchema.ts+++ b/frontend/src/store/modules/v1/dbSchema.ts@@ -37,6 +37,29 @@ export const useDBSchemaV1Store = defineStore("dbSchema_v1", {return this.setCache(metadata);}+ for (const schemaConfig of metadata.schemaConfigs) {+ const schemaConfigIndex = existed.schemaConfigs.findIndex(+ (s) => s.name === schemaConfig.name+ );+ if (schemaConfigIndex < 0) {+ existed.schemaConfigs.push(schemaConfig);+ continue;+ }+ for (const tableConfig of schemaConfig.tableConfigs) {+ const tableIndex = existed.schemaConfigs[+ schemaConfigIndex+ ].tableConfigs.findIndex((t) => t.name === tableConfig.name);+ if (tableIndex < 0) {+ existed.schemaConfigs[schemaConfigIndex].tableConfigs.push(+ tableConfig+ );+ } else {+ existed.schemaConfigs[schemaConfigIndex].tableConfigs[tableIndex] =+ tableConfig;+ }+ }+ }+for (const schema of metadata.schemas) {const schemaIndex = existed.schemas.findIndex((s) => s.name === schema.name@@ -123,7 +146,7 @@ export const useDBSchemaV1Store = defineStore("dbSchema_v1", {}).then((res) => {- this.setCache(res);+ this.mergeToCache(res);return res;});this.requestCache.set(metadataName, promise);