From fe1182cb551672b758d8338c53a0ceba5ecd4685 Mon Sep 17 00:00:00 2001 From: zhangheng Date: Sat, 11 Apr 2026 17:37:36 +0800 Subject: [PATCH] fix(task): auth --- app/project/detail/TaskTableContainer.tsx | 83 +++++++++++++---------- 1 file changed, 46 insertions(+), 37 deletions(-) diff --git a/app/project/detail/TaskTableContainer.tsx b/app/project/detail/TaskTableContainer.tsx index 2a63715..4f9e404 100644 --- a/app/project/detail/TaskTableContainer.tsx +++ b/app/project/detail/TaskTableContainer.tsx @@ -181,7 +181,8 @@ export default function TaskTableContainer(props: { }) { const { info, userEnums } = props - const { user_id } = usePermissionStore() + const { user_id, detailInfo } = usePermissionStore() + const hasRolePermissions = Boolean(detailInfo?.roles?.length) const urlParams = useSearchParams() const id = urlParams.get("id") @@ -775,22 +776,24 @@ export default function TaskTableContainer(props: { textAlign: "center", render: (record) => ( - + {hasRolePermissions ? ( + + ) : null} + {hasRolePermissions ? ( + + ) : null} - - + {hasRolePermissions ? ( + + ) : null} + {hasRolePermissions ? ( + + ) : null} } />