Update relationship endpoints

This commit is contained in:
Andrew Kingston 2024-12-05 15:48:18 +00:00
parent feee4032d5
commit 9877cafaf4
No known key found for this signature in database
1 changed files with 2 additions and 2 deletions

View File

@ -1,4 +1,4 @@
import { Row } from "@budibase/types"
import { FetchEnrichedRowResponse, Row } from "@budibase/types"
import { BaseAPIClient } from "./types"
export interface RelationshipEndpoints {
@ -19,7 +19,7 @@ export const buildRelationshipEndpoints = (
* @param fieldName the name of the relationship field
*/
fetchRelationshipData: async (sourceId, rowId, fieldName) => {
const response = await API.get<Row>({
const response = await API.get<FetchEnrichedRowResponse>({
url: `/api/${sourceId}/${rowId}/enrich?field=${fieldName}`,
})
if (!fieldName) {