[autofix.ci] apply automated fixes

This commit is contained in:
autofix-ci[bot]
2026-03-03 07:05:09 +00:00
committed by GitHub
parent 08c9113405
commit 7599565e73
3 changed files with 19 additions and 17 deletions
@@ -73,14 +73,18 @@ export function ShowQueueTable(props: { embedded?: boolean }) {
);
const { data: isCloud } = api.settings.isCloud.useQuery();
const utils = api.useUtils();
const { mutateAsync: cancelApplicationDeployment, isPending: isCancellingApp } =
api.application.cancelDeployment.useMutation({
onSuccess: () => void utils.deployment.queueList.invalidate(),
});
const { mutateAsync: cancelComposeDeployment, isPending: isCancellingCompose } =
api.compose.cancelDeployment.useMutation({
onSuccess: () => void utils.deployment.queueList.invalidate(),
});
const {
mutateAsync: cancelApplicationDeployment,
isPending: isCancellingApp,
} = api.application.cancelDeployment.useMutation({
onSuccess: () => void utils.deployment.queueList.invalidate(),
});
const {
mutateAsync: cancelComposeDeployment,
isPending: isCancellingCompose,
} = api.compose.cancelDeployment.useMutation({
onSuccess: () => void utils.deployment.queueList.invalidate(),
});
const isCancelling = isCancellingApp || isCancellingCompose;
return (
@@ -149,11 +153,14 @@ export function ShowQueueTable(props: { embedded?: boolean }) {
</Link>
</Button>
) : (
<span className="text-muted-foreground text-xs"></span>
<span className="text-muted-foreground text-xs">
</span>
)}
{isCloud &&
row.state === "active" &&
(d?.applicationId != null || d?.composeId != null) && (
(d?.applicationId != null ||
d?.composeId != null) && (
<Button
variant="ghost"
size="sm"
@@ -28,10 +28,7 @@ import {
server,
} from "@/server/db/schema";
import { myQueue } from "@/server/queues/queueSetup";
import {
fetchDeployApiJobs,
type QueueJobRow,
} from "@/server/utils/deploy";
import { fetchDeployApiJobs, type QueueJobRow } from "@/server/utils/deploy";
import { createTRPCRouter, protectedProcedure } from "../trpc";
export const deploymentRouter = createTRPCRouter({
+1 -3
View File
@@ -889,9 +889,7 @@ export const findAllDeploymentsCentralized = async (
}
const conditions = [
...(appIds.length > 0
? [inArray(deployments.applicationId, appIds)]
: []),
...(appIds.length > 0 ? [inArray(deployments.applicationId, appIds)] : []),
...(compIds.length > 0 ? [inArray(deployments.composeId, compIds)] : []),
];
const whereClause =