Skip to content
This repository was archived by the owner on Mar 13, 2025. It is now read-only.

Commit 7a91a13

Browse files
committed
fix: get Team Name using TaaS API
ref issue #49
1 parent bd05dbf commit 7a91a13

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

src/constants/workPeriods.js

+1
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ export const JOBS_API_URL = `${API.V5}/jobs`;
2424
export const PAYMENTS_API_URL = `${API.V5}/work-period-payments`;
2525
export const PROJECTS_API_URL = `${API.V5}/projects`;
2626
export const WORK_PERIODS_API_URL = `${API.V5}/work-periods`;
27+
export const TAAS_TEAM_API_URL = `${API.V5}/taas-teams`;
2728

2829
export const DATE_FORMAT_API = "YYYY-MM-DD";
2930
export const DATE_FORMAT_UI = "MMM DD, YYYY";

src/services/workPeriods.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import {
66
PROJECTS_API_URL,
77
API_QUERY_PARAM_NAMES,
88
WORK_PERIODS_API_URL,
9+
TAAS_TEAM_API_URL,
910
} from "constants/workPeriods";
1011
import { buildRequestQuery, extractResponseData } from "utils/misc";
1112

@@ -38,7 +39,7 @@ export const fetchJob = (jobId, source) => {
3839
*/
3940
export const fetchProject = (projectId) => {
4041
return axios
41-
.get(`${PROJECTS_API_URL}/${projectId}?fields=projectId,name`)
42+
.get(`${TAAS_TEAM_API_URL}/${projectId}`)
4243
.then(extractResponseData);
4344
};
4445

0 commit comments

Comments
 (0)