mirror of
https://github.com/bluewave-labs/Checkmate.git
synced 2026-05-18 23:48:43 -05:00
Merge branch 'develop' into fix/routes
This commit is contained in:
@@ -124,7 +124,7 @@ const MonitorDetailsControlHeader = ({
|
||||
});
|
||||
}}
|
||||
>
|
||||
{monitor?.isActive ? "Pause" : "Resume"}
|
||||
{monitor?.isActive ? t("pause") : t("resume")}
|
||||
</Button>
|
||||
)}
|
||||
{isAdmin && (
|
||||
|
||||
@@ -80,13 +80,13 @@ const UptimeCreate = ({ isClone = false }) => {
|
||||
const [isFetchingMonitor] = useFetchMonitorById({
|
||||
monitorId,
|
||||
setMonitor,
|
||||
updateTrigger: true,
|
||||
updateTrigger,
|
||||
});
|
||||
|
||||
// Fetch games
|
||||
const [isFetchingGames] = useFetchMonitorGames({
|
||||
setGames,
|
||||
triggerUpdate: true,
|
||||
updateTrigger,
|
||||
});
|
||||
|
||||
// Combine the loading states
|
||||
@@ -283,10 +283,6 @@ const UptimeCreate = ({ isClone = false }) => {
|
||||
}));
|
||||
};
|
||||
|
||||
const handlePause = async () => {
|
||||
await pauseMonitor({ monitorId, triggerUpdate });
|
||||
};
|
||||
|
||||
const handleRemove = async (event) => {
|
||||
event.preventDefault();
|
||||
const TEMP_MONITOR = { id: monitor.id };
|
||||
@@ -438,7 +434,12 @@ const UptimeCreate = ({ isClone = false }) => {
|
||||
/>
|
||||
)
|
||||
}
|
||||
onClick={handlePause}
|
||||
onClick={() => {
|
||||
pauseMonitor({
|
||||
monitorId: monitor?.id,
|
||||
triggerUpdate,
|
||||
});
|
||||
}}
|
||||
>
|
||||
{monitor?.isActive ? t("pause") : t("resume")}
|
||||
</Button>
|
||||
|
||||
Reference in New Issue
Block a user