mirror of
https://github.com/moghtech/komodo.git
synced 2026-03-11 17:44:19 -05:00
add status to update menu
This commit is contained in:
@@ -5,7 +5,6 @@ import ConfirmButton from "../shared/ConfirmButton";
|
||||
import Icon from "../shared/Icon";
|
||||
import Flex from "../shared/layout/Flex";
|
||||
import Grid from "../shared/layout/Grid";
|
||||
import { useActionStates } from "./ActionStateProvider";
|
||||
import { combineClasses, getId } from "../../util/helpers";
|
||||
import { useAppDimensions } from "../../state/DimensionProvider";
|
||||
import Updates from "./Updates";
|
||||
@@ -15,10 +14,9 @@ import { PermissionLevel } from "../../types";
|
||||
import { client } from "../..";
|
||||
|
||||
const Header: Component<{}> = (p) => {
|
||||
const { builds, ws } = useAppState();
|
||||
const { builds } = useAppState();
|
||||
const params = useParams();
|
||||
const build = () => builds.get(params.id)!;
|
||||
const actions = useActionStates();
|
||||
const { user } = useUser();
|
||||
const { isMobile } = useAppDimensions();
|
||||
const [showUpdates, toggleShowUpdates] =
|
||||
|
||||
@@ -6,9 +6,7 @@ import ConfirmButton from "../shared/ConfirmButton";
|
||||
import Icon from "../shared/Icon";
|
||||
import Flex from "../shared/layout/Flex";
|
||||
import Grid from "../shared/layout/Grid";
|
||||
import Loading from "../shared/loading/Loading";
|
||||
import HoverMenu from "../shared/menu/HoverMenu";
|
||||
import { useActionStates } from "./ActionStateProvider";
|
||||
import { useLocalStorageToggle } from "../../util/hooks";
|
||||
import { useAppDimensions } from "../../state/DimensionProvider";
|
||||
import Updates from "./Updates";
|
||||
@@ -17,7 +15,7 @@ import { useParams } from "@solidjs/router";
|
||||
import { client } from "../..";
|
||||
|
||||
const Header: Component<{}> = (p) => {
|
||||
const { deployments, ws } = useAppState();
|
||||
const { deployments } = useAppState();
|
||||
const params = useParams();
|
||||
const deployment = () => deployments.get(params.id)!;
|
||||
const { user } = useUser();
|
||||
@@ -26,7 +24,6 @@ const Header: Component<{}> = (p) => {
|
||||
deployment()!.state === DockerContainerState.NotDeployed
|
||||
? undefined
|
||||
: deployment().container?.status?.toLowerCase();
|
||||
const actions = useActionStates();
|
||||
const { isMobile } = useAppDimensions();
|
||||
const [showUpdates, toggleShowUpdates] =
|
||||
useLocalStorageToggle("show-updates");
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
import { Component, createResource, For, Show } from "solid-js";
|
||||
import { client } from "../..";
|
||||
import { Component, For, Show } from "solid-js";
|
||||
import { useAppState } from "../../state/StateProvider";
|
||||
import { Update as UpdateType } from "../../types";
|
||||
import { Update as UpdateType, UpdateStatus } from "../../types";
|
||||
import { combineClasses, readableDuration, readableMonitorTimestamp } from "../../util/helpers";
|
||||
import { useToggle } from "../../util/hooks";
|
||||
import Icon from "../shared/Icon";
|
||||
@@ -50,6 +49,7 @@ const UpdateMenuContent: Component<{ update: UpdateType }> = (p) => {
|
||||
return (
|
||||
<Grid class={s.LogContainer} gap="1rem">
|
||||
<Grid gap="0.5rem" class="card light shadow">
|
||||
<div>status: {p.update.status.replaceAll("_", " ")}</div>
|
||||
<div>operator: {usernames.get(p.update.operator)}</div>
|
||||
<div>started at: {readableMonitorTimestamp(p.update.start_ts)}</div>
|
||||
<Show when={p.update.end_ts}>
|
||||
|
||||
Reference in New Issue
Block a user