- Implement cloning of workflow
- Entity change will now only clear the assignees instead of the whole workflow - Fix bug where side panel was showing all workflow assignees instead of just selected step assignees
This commit is contained in:
@@ -24,6 +24,7 @@ import { IoIosAddCircleOutline } from "react-icons/io";
|
||||
import { toast, ToastContainer } from "react-toastify";
|
||||
|
||||
import approvalWorkflowsData from '../../demo/approval_workflows.json'; // to test locally
|
||||
import { FaRegClone } from "react-icons/fa6";
|
||||
|
||||
const columnHelper = createColumnHelper<ApprovalWorkflow>();
|
||||
|
||||
@@ -156,10 +157,6 @@ export default function ApprovalWorkflows({ user, workflows, workflowsAssignees,
|
||||
/* .finally(reload); */
|
||||
};
|
||||
|
||||
const editApprovalWorkflow = (id: string) => {
|
||||
|
||||
};
|
||||
|
||||
const columns = [
|
||||
columnHelper.accessor("name", {
|
||||
header: "NAME",
|
||||
@@ -262,6 +259,15 @@ export default function ApprovalWorkflows({ user, workflows, workflowsAssignees,
|
||||
<BsTrash className="hover:text-mti-purple-light transition ease-in-out duration-300" />
|
||||
</button>
|
||||
|
||||
<Link
|
||||
onClick={(e) => e.stopPropagation()}
|
||||
data-tip="Clone"
|
||||
href={`/approval-workflows/${row.original.id}/clone`}
|
||||
className="cursor-pointer tooltip"
|
||||
>
|
||||
<FaRegClone className="hover:text-mti-purple-light transition ease-in-out duration-300" />
|
||||
</Link>
|
||||
|
||||
{currentStep && (
|
||||
<Link
|
||||
onClick={(e) => e.stopPropagation()}
|
||||
@@ -368,7 +374,7 @@ export default function ApprovalWorkflows({ user, workflows, workflowsAssignees,
|
||||
{row.getVisibleCells().map((cell, cellIndex) => {
|
||||
const lastCellIndex = row.getVisibleCells().length - 1;
|
||||
|
||||
let cellClasses = "px-3 py-2 bg-purple-50 border-y-2 border-purple-300";
|
||||
let cellClasses = "pl-3 pr-4 py-2 bg-purple-50 border-y-2 border-purple-300";
|
||||
if (cellIndex === 0) {
|
||||
cellClasses += " border-l-2 rounded-l-2xl";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user