Skip to content

Database governance built for humans and agents — controlling changes and access across every major database.

Always fetch the project,project.projectMember info when fetching database

天舟4c1fc3b5d380
diff --git a/frontend/src/store/modules/database.ts b/frontend/src/store/modules/database.ts
index 6b1f76cc06..cd4423e102 100644
--- a/frontend/src/store/modules/database.ts
+++ b/frontend/src/store/modules/database.ts
@@ -236,16 +236,14 @@ const actions = {
},
async fetchDatabaseListByEnvironmentId(
- { commit, rootGetters }: any,
+ { state, commit, rootGetters }: any,
environmentId: EnvironmentId
) {
// Don't fetch the data source info as the current user may not have access to the
// database of this particular environment.
- // We need to fetch the instance info because we need it to populate the instance
- // environment field and that's how the client code gets environment from the database object
const data = (
await axios.get(
- `/api/database?environment=${environmentId}&include=instance`
+ `/api/database?environment=${environmentId}&include=instance,project,project.projectMember`
)
).data;
const databaseList = data.data.map((database: ResourceObject) => {