CEC-3519 Add car version history (#260)
* CEC-3519 Add car version history CEC-3455 Delete button is icon and remove column CEC-3496 Fix Issue delete * smell * Remove tab from issues details page * Fix date format
This commit is contained in:
@@ -233,6 +233,17 @@ export const VehicleProvider = ({ children }) => {
|
||||
}
|
||||
}
|
||||
|
||||
const getVersionLog = async (search, token) => {
|
||||
try {
|
||||
setBusy(true);
|
||||
const result = await api.getVersionLog(search, token);
|
||||
if (result.error) throw new Error(`Get version log error. ${result.message}`);
|
||||
return result;
|
||||
} finally {
|
||||
setBusy(false);
|
||||
}
|
||||
};
|
||||
|
||||
return (
|
||||
<VehicleContext.Provider
|
||||
value={{
|
||||
@@ -258,6 +269,7 @@ export const VehicleProvider = ({ children }) => {
|
||||
sendCommand,
|
||||
updateVehicle,
|
||||
getFleets,
|
||||
getVersionLog,
|
||||
}}
|
||||
>
|
||||
{children}
|
||||
|
||||
Reference in New Issue
Block a user