import React from "react"; // components import { KanBanGroupByHeaderRoot } from "./headers/group-by-root"; import { KanBanSubGroupByHeaderRoot } from "./headers/sub-group-by-root"; import { KanBan } from "./default"; // constants import { ISSUE_STATE_GROUPS, ISSUE_PRIORITIES } from "constants/issue"; // mobx import { observer } from "mobx-react-lite"; // mobx import { useMobxStore } from "lib/mobx/store-provider"; import { RootStore } from "store/root"; export interface IKanBanSwimLanes { issues?: any; handleIssues?: () => void; handleDragDrop?: () => void; } const SubGroupSwimlaneHeader = ({ list, _key }: any) => (
{list && list.length > 0 && list.map((_list: any) => (
))}
); const SubGroupSwimlane = ({ issues, list, _key }: any) => (
{list && list.length > 0 && list.map((_list: any) => (
))}
); export const KanBanSwimLanes: React.FC = observer(({ issues }) => { const { project: projectStore, issueFilter: issueFilterStore }: RootStore = useMobxStore(); const group_by: string | null = issueFilterStore?.userDisplayFilters?.group_by || null; const sub_group_by: string | null = issueFilterStore?.userDisplayFilters?.sub_group_by || null; console.log("sub_group_by", sub_group_by); return (
{group_by && group_by === "state" && } {group_by && group_by === "state_detail.group" && ( )} {group_by && group_by === "priority" && } {group_by && group_by === "labels" && } {group_by && group_by === "assignees" && ( )} {group_by && group_by === "created_by" && ( )}
{sub_group_by && sub_group_by === "state" && ( )} {sub_group_by && sub_group_by === "state_detail.group" && ( )} {sub_group_by && sub_group_by === "priority" && ( )} {sub_group_by && sub_group_by === "labels" && ( )} {sub_group_by && sub_group_by === "assignees" && ( )} {sub_group_by && sub_group_by === "created_by" && ( )}
); });