Skip to content

Commit b704492

Browse files
committed
fix data source payload
1 parent 2934db2 commit b704492

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

client/packages/lowcoder/src/pages/setting/environments/services/enterprise.service.ts

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -161,11 +161,14 @@ export const connectManagedDataSource = async (
161161
datasourceGid: string
162162
): Promise<void> => {
163163
try {
164-
await axios.post(`/api/plugins/enterprise/datasource`, {
165-
environmentId,
164+
const payload = {
165+
environment_id: environmentId,
166166
name,
167-
datasourceGid
168-
});
167+
datasource_gid: datasourceGid,
168+
};
169+
170+
171+
await axios.post(`/api/plugins/enterprise/datasource`, payload);
169172
} catch (error) {
170173
console.error("Error connecting managed data source:", error);
171174
throw error;

0 commit comments

Comments
 (0)