added back the task viewer on the bin page, fixed up some more styling

This commit is contained in:
csawatzky 2025-04-23 16:29:41 -06:00
parent 5c6be7c850
commit 9105b4be3a
4 changed files with 18 additions and 12 deletions

View file

@ -87,7 +87,7 @@ export default function Gate(props: Props) {
//const match = useRouteMatch<MatchParams>();
//const gateID = props.gateID ?? match.params.gateID;
const { gateKey } = props
const gateID = gateKey ?? useParams<{ gateID: string }>()?.gateID ?? "";
const gateID = gateKey ?? useParams<{ gateKey: string }>()?.gateKey ?? "";
const classes = useStyles();
const gateAPI = useGateAPI();
const userAPI = useUserAPI();
@ -115,13 +115,17 @@ export default function Gate(props: Props) {
};
useEffect(() => {
console.log(gateID)
let key = gateID;
let kind = "gate";
if (as) {
key = as;
kind = "team";
}
console.log(key)
console.log(kind)
userAPI.getUser(user.id(), { key: key, kind: kind } as Scope).then(resp => {
console.log(resp)
setPermissions(resp.permissions);
});
}, [as, gateID, userAPI, user]);