fix(FN-4378): align delete option threading for github issue actions
Fusion-Task-Id: FN-4378 Fusion-Task-Lineage: d3867ba8-f852-41e3-9db0-584c0ffc23b1
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { useCallback, useEffect, useState, lazy, Suspense } from "react";
|
||||
import type { ProjectInfo } from "../api";
|
||||
import type { ColorTheme, Column, MergeResult, Task, TaskCreateInput, ThemeMode } from "@fusion/core";
|
||||
import type { ColorTheme, Column, MergeResult, Task, TaskCreateInput, ThemeMode, GithubIssueAction } from "@fusion/core";
|
||||
import type { UseProjectActionsResult } from "../hooks/useProjectActions";
|
||||
import type { ModalManager } from "../hooks/useModalManager";
|
||||
import type { UseTaskHandlersResult } from "../hooks/useTaskHandlers";
|
||||
@@ -54,7 +54,7 @@ interface AppModalsProps {
|
||||
taskHandlers: Pick<UseTaskHandlersResult, "handleModalCreate" | "handlePlanningTaskCreated" | "handlePlanningTasksCreated" | "handleSubtaskTasksCreated" | "handleGitHubImport">;
|
||||
taskOperations: {
|
||||
moveTask: (taskId: string, column: Column, optionsOrPosition?: { preserveProgress?: boolean } | number) => Promise<Task>;
|
||||
deleteTask: (taskId: string, options?: { removeDependencyReferences?: boolean }) => Promise<Task>;
|
||||
deleteTask: (taskId: string, options?: { removeDependencyReferences?: boolean; githubIssueAction?: GithubIssueAction }) => Promise<Task>;
|
||||
mergeTask: (taskId: string) => Promise<MergeResult>;
|
||||
retryTask: (taskId: string) => Promise<Task>;
|
||||
resetTask: (taskId: string) => Promise<Task>;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { useState, useEffect, useCallback, useRef } from "react";
|
||||
import type { Task, Column, TaskCreateInput, MergeResult } from "@fusion/core";
|
||||
import type { Task, Column, TaskCreateInput, MergeResult, GithubIssueAction } from "@fusion/core";
|
||||
import { normalizeColumn } from "@fusion/core";
|
||||
import * as api from "../api";
|
||||
import { subscribeSse } from "../sse-bus";
|
||||
@@ -367,7 +367,7 @@ export function useTasks(options?: UseTasksOptions) {
|
||||
|
||||
const deleteTask = useCallback(async (
|
||||
id: string,
|
||||
options?: { removeDependencyReferences?: boolean },
|
||||
options?: { removeDependencyReferences?: boolean; githubIssueAction?: GithubIssueAction },
|
||||
): Promise<Task> => {
|
||||
return normalizeTask(await api.deleteTask(id, projectId, options));
|
||||
}, [projectId]);
|
||||
|
||||
Reference in New Issue
Block a user