Skip to content
Snippets Groups Projects

Deployment API clean-up ICSHWI-11790 (FE modifications)

Merged Zoltan Runyo requested to merge deployment-api-clean-up-ICSHWI-11790 into develop
2 files
+ 2
29
Compare changes
  • Side-by-side
  • Inline
Files
2
  • ad48f993
    ICSHWI-11790: Remove 'Fetch command' API call and replace it with 'Fetch operation' · ad48f993
    Zoltan Runyo authored
+ 0
27
@@ -344,24 +344,6 @@ export function unpackDeployment(deployment) {
return d;
}
export function unpackCommand(command) {
const c = { ...command };
return c;
}
export function unpackCommandList(commandList) {
let commandArr = commandList.commands.map((c) => unpackCommand(c));
let unpackedCommandList = {
totalCount: commandList.totalCount,
pageNumber: commandList.pageNumber,
limit: commandList.limit,
commandList: commandArr
};
return unpackedCommandList;
}
export function unpackOngoingCommand(command) {
if (command) {
return { ...command };
@@ -446,15 +428,6 @@ export function useDeploymentById() {
return useAsync({ fcn: method, call: false, init: null });
}
export function useCommandById() {
const api = useContext(apiContext);
const method = useCallAndUnpack(
(commandId) => api.apis.Deployments.fetchCommand({ command_id: commandId }),
unpackCommand
);
return useAsync({ fcn: method, call: false, init: null });
}
export function unpackJob(job) {
return { ...job };
}
Loading