forked from github-starred/komodo
Include templates in onboarding selector
This commit is contained in:
@@ -325,7 +325,9 @@ impl Resolve<ReadArgs> for GetDeploymentsSummary {
|
||||
res.not_deployed += 1;
|
||||
}
|
||||
DeploymentState::Unknown => {
|
||||
res.unknown += 1;
|
||||
if !deployment.template {
|
||||
res.unknown += 1;
|
||||
}
|
||||
}
|
||||
_ => {
|
||||
res.unhealthy += 1;
|
||||
|
||||
@@ -142,7 +142,11 @@ impl Resolve<ReadArgs> for GetReposSummary {
|
||||
}
|
||||
(RepoState::Ok, _) => res.ok += 1,
|
||||
(RepoState::Failed, _) => res.failed += 1,
|
||||
(RepoState::Unknown, _) => res.unknown += 1,
|
||||
(RepoState::Unknown, _) => {
|
||||
if !repo.template {
|
||||
res.unknown += 1
|
||||
}
|
||||
}
|
||||
// will never come off the cache in the building state, since that comes from action states
|
||||
(RepoState::Cloning, _)
|
||||
| (RepoState::Pulling, _)
|
||||
|
||||
@@ -90,7 +90,9 @@ impl Resolve<ReadArgs> for GetServersSummary {
|
||||
res.unhealthy += 1;
|
||||
}
|
||||
ServerState::Disabled => {
|
||||
res.disabled += 1;
|
||||
if !server.template {
|
||||
res.disabled += 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -366,7 +366,11 @@ impl Resolve<ReadArgs> for GetStacksSummary {
|
||||
StackState::Running => res.running += 1,
|
||||
StackState::Stopped | StackState::Paused => res.stopped += 1,
|
||||
StackState::Down => res.down += 1,
|
||||
StackState::Unknown => res.unknown += 1,
|
||||
StackState::Unknown => {
|
||||
if !stack.template {
|
||||
res.unknown += 1
|
||||
}
|
||||
}
|
||||
_ => res.unhealthy += 1,
|
||||
}
|
||||
}
|
||||
|
||||
@@ -26,6 +26,7 @@ import { DataTable, SortableHeader } from "@ui/data-table";
|
||||
import { fmt_date_with_minutes } from "@lib/formatting";
|
||||
import { Switch } from "@ui/switch";
|
||||
import { ResourceSelector, TagSelector } from "@components/resources/common";
|
||||
import { Types } from "komodo_client";
|
||||
|
||||
export const Onboarding = () => {
|
||||
useSetTitle("Onboarding");
|
||||
@@ -64,7 +65,11 @@ export const Onboarding = () => {
|
||||
accessorKey: "copy_server",
|
||||
header: "Template",
|
||||
cell: ({ row }) => (
|
||||
<ResourceSelector type="Server" selected={row.original.copy_server} />
|
||||
<ResourceSelector
|
||||
type="Server"
|
||||
selected={row.original.copy_server}
|
||||
templates={Types.TemplatesQueryBehavior.Include}
|
||||
/>
|
||||
),
|
||||
},
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user