IO-2893 Correct RBACs for editing tickets
Signed-off-by: Allan Carr <allan.carr@thinkimex.com>
This commit is contained in:
@@ -254,24 +254,41 @@ export function TimeTicketList({
|
|||||||
timeticket: record
|
timeticket: record
|
||||||
}}
|
}}
|
||||||
disabled={
|
disabled={
|
||||||
record.committed_at
|
record.ciecacode
|
||||||
? HasRbacAccess({
|
? record.committed_at
|
||||||
bodyshop,
|
? HasRbacAccess({
|
||||||
authLevel: authLevel,
|
bodyshop,
|
||||||
action: "timetickets:editcommitted"
|
authLevel: authLevel,
|
||||||
}) &&
|
action: "timetickets:editcommitted"
|
||||||
HasRbacAccess({
|
}) &&
|
||||||
bodyshop,
|
HasRbacAccess({
|
||||||
authLevel: authLevel,
|
bodyshop,
|
||||||
action: "timetickets:shiftedit"
|
authLevel: authLevel,
|
||||||
})
|
action: "timetickets:edit"
|
||||||
: HasRbacAccess({
|
})
|
||||||
|
: HasRbacAccess({
|
||||||
|
bodyshop,
|
||||||
|
authLevel: authLevel,
|
||||||
|
action: "timetickets:edit"
|
||||||
|
})
|
||||||
|
: record.committed_at
|
||||||
|
? HasRbacAccess({
|
||||||
|
bodyshop,
|
||||||
|
authLevel: authLevel,
|
||||||
|
action: "timetickets:editcommitted"
|
||||||
|
}) &&
|
||||||
|
HasRbacAccess({
|
||||||
bodyshop,
|
bodyshop,
|
||||||
authLevel: authLevel,
|
authLevel: authLevel,
|
||||||
action: "timetickets:shiftedit"
|
action: "timetickets:shiftedit"
|
||||||
})
|
})
|
||||||
? disabled
|
: HasRbacAccess({
|
||||||
: !record.jobid
|
bodyshop,
|
||||||
|
authLevel: authLevel,
|
||||||
|
action: "timetickets:shiftedit"
|
||||||
|
})
|
||||||
|
? disabled
|
||||||
|
: !record.jobid
|
||||||
}
|
}
|
||||||
>
|
>
|
||||||
<EditFilled />
|
<EditFilled />
|
||||||
|
|||||||
Reference in New Issue
Block a user