fix(api): align frontend with REST contracts
This commit is contained in:
@@ -228,7 +228,6 @@ const SchemeQuery: React.FC<Props> = ({
|
||||
setLoading(true);
|
||||
try {
|
||||
const params: Record<string, string> = {
|
||||
network: NETWORK_NAME,
|
||||
scheme_type: "burst_location",
|
||||
};
|
||||
if (!queryAll && queryDate) {
|
||||
@@ -238,7 +237,7 @@ const SchemeQuery: React.FC<Props> = ({
|
||||
const [response, simulationResponse] = await Promise.all([
|
||||
api.get(`${config.BACKEND_URL}/api/v1/schemes`, { params }),
|
||||
api.get(`${config.BACKEND_URL}/api/v1/schemes`, {
|
||||
params: { network: NETWORK_NAME, scheme_type: "burst_analysis" },
|
||||
params: { scheme_type: "burst_analysis" },
|
||||
}),
|
||||
]);
|
||||
const nextSchemes = response.data as BurstSchemeRecord[];
|
||||
@@ -281,7 +280,7 @@ const SchemeQuery: React.FC<Props> = ({
|
||||
try {
|
||||
const response = await api.get(
|
||||
`${config.BACKEND_URL}/api/v1/schemes/${encodeURIComponent(schemeName)}`,
|
||||
{ params: { network: NETWORK_NAME, scheme_type: "burst_location" } },
|
||||
{ params: { scheme_type: "burst_location" } },
|
||||
);
|
||||
const schemeRecord = response.data as BurstSchemeRecord & {
|
||||
result_payload?: BurstLocationResult;
|
||||
|
||||
Reference in New Issue
Block a user