[WEB-4814] chore: enabled reordering in list when group is none #7684
This commit is contained in:
parent
f2edf637de
commit
e679dc3d12
2 changed files with 3 additions and 3 deletions
|
|
@ -240,7 +240,7 @@ export const ListGroup = observer((props: Props) => {
|
||||||
isWorkflowDropDisabled,
|
isWorkflowDropDisabled,
|
||||||
]);
|
]);
|
||||||
|
|
||||||
const isDragAllowed = !!group_by && DRAG_ALLOWED_GROUPS.includes(group_by);
|
const isDragAllowed = group_by ? DRAG_ALLOWED_GROUPS.includes(group_by) : true;
|
||||||
const canOverlayBeVisible = isWorkflowDropDisabled || orderBy !== "sort_order" || !!group.isDropDisabled;
|
const canOverlayBeVisible = isWorkflowDropDisabled || orderBy !== "sort_order" || !!group.isDropDisabled;
|
||||||
const isDropDisabled = isWorkflowDropDisabled || !!group.isDropDisabled;
|
const isDropDisabled = isWorkflowDropDisabled || !!group.isDropDisabled;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -521,7 +521,7 @@ export const handleGroupDragDrop = async (
|
||||||
subGroupBy: TIssueGroupByOptions | undefined,
|
subGroupBy: TIssueGroupByOptions | undefined,
|
||||||
shouldAddIssueAtTop = false
|
shouldAddIssueAtTop = false
|
||||||
) => {
|
) => {
|
||||||
if (!source.id || !groupBy || (subGroupBy && (!source.subGroupId || !destination.subGroupId))) return;
|
if (!source.id || (subGroupBy && (!source.subGroupId || !destination.subGroupId))) return;
|
||||||
|
|
||||||
let updatedIssue: Partial<TIssue> = {};
|
let updatedIssue: Partial<TIssue> = {};
|
||||||
const issueUpdates: IssueUpdates = {};
|
const issueUpdates: IssueUpdates = {};
|
||||||
|
|
@ -549,7 +549,7 @@ export const handleGroupDragDrop = async (
|
||||||
};
|
};
|
||||||
|
|
||||||
// update updatedIssue values based on the source and destination groupIds
|
// update updatedIssue values based on the source and destination groupIds
|
||||||
if (source.groupId && destination.groupId && source.groupId !== destination.groupId) {
|
if (source.groupId && destination.groupId && source.groupId !== destination.groupId && groupBy) {
|
||||||
const groupKey = ISSUE_FILTER_DEFAULT_DATA[groupBy];
|
const groupKey = ISSUE_FILTER_DEFAULT_DATA[groupBy];
|
||||||
let groupValue: any = clone(sourceIssue[groupKey]);
|
let groupValue: any = clone(sourceIssue[groupKey]);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue