"git@gitlab.esss.lu.se:ics-infrastructure/etherlabmaster.git" did not exist on "c38673be8ffa3b08aa05f628765ee3bc8c3dc099"
CE-1891: Reroute no access to 401 page
4 unresolved threads
4 unresolved threads
Ticket: CE-1891
Reroute no access to 401 page for user page and management & admin tab on IOC details page
Merge request reports
Activity
requested review from @christinajenks, @domonkosgulyas, @henriquesilva, and @anderslindh1
assigned to @alexandermadsen
3 3 import { LinearProgress } from "@mui/material"; 4 4 import NotFoundView from "../../components/navigation/NotFoundView/NotFoundView"; 5 5 import { onFetchEntityError } from "../../components/common/Helper"; 6 6 import { useIOC } from "../../api/SwaggerApi"; 7 import { userContext } from "@ess-ics/ce-ui-common/dist/contexts/User"; 8 import useUrlState from "@ahooksjs/use-url-state"; 7 9 8 10 export function IOCDetailsContainer({ id }) { 9 const [notFoundError, setNotFoundError] = useState(); 11 const { user } = useContext(userContext); 12 const [errorMessage, setErrorMessage] = useState(null); 13 14 const [urlState] = useUrlState(); 15 const [statusTab] = useState(urlState?.tab); 16 17 const [notFoundError, setNotFoundError] = useState(null); This seems redundant? Makes logic a bit difficult to follow, could we use just one error state instead?
Edited by Christina Jenkschanged this line in version 3 of the diff
1 import React, { useState } from "react"; 1 import React, { useEffect, useContext, useState } from "react"; 2 2 import { IOCDetailsView } from "./IOCDetailsView"; 3 3 import { LinearProgress } from "@mui/material"; 4 4 import NotFoundView from "../../components/navigation/NotFoundView/NotFoundView"; 5 5 import { onFetchEntityError } from "../../components/common/Helper"; 6 6 import { useIOC } from "../../api/SwaggerApi"; 7 import { userContext } from "@ess-ics/ce-ui-common/dist/contexts/User"; 8 import useUrlState from "@ahooksjs/use-url-state"; 7 9 8 10 export function IOCDetailsContainer({ id }) { 9 const [notFoundError, setNotFoundError] = useState(); 11 const { user } = useContext(userContext); 12 const [errorMessage, setErrorMessage] = useState(null); changed this line in version 3 of the diff
- src/views/UserPage/UserDetailsContainer.js 0 → 100644
1 import React, { useContext, useEffect, useState } from "react"; 2 import { UserPageView } from "./UserPageView"; 3 import { LinearProgress } from "@mui/material"; 4 import NotFoundView from "../../components/navigation/NotFoundView/NotFoundView"; 5 import { useUserInfo } from "../../api/SwaggerApi"; 6 import { userContext } from "@ess-ics/ce-ui-common/dist/contexts/User"; 7 8 export function UserDetailsContainer({ userName }) { 9 const { user } = useContext(userContext); 10 const [errorMessage, setErrorMessage] = useState(null); changed this line in version 3 of the diff
added 8 commits
-
f81c9b3e...8f9a5fee - 6 commits from branch
develop
- faac6d89 - Show user 401 page when not logged in
- 680a6d9b - 401 page for ICO Manage & Admin tabs when not logged in
-
f81c9b3e...8f9a5fee - 6 commits from branch
added 9 commits
-
47d8a23a...334f1373 - 4 commits from branch
develop
- dd9c9195 - Show user 401 page when not logged in
- ebaf6657 - 401 page for ICO Manage & Admin tabs when not logged in
- fd7227c0 - Props with values for new KeyValueTable
- a2009e61 - One error state instead of two
- 4fca46ff - Error state name more to the point
Toggle commit list-
47d8a23a...334f1373 - 4 commits from branch
mentioned in commit 59dd9044
Please register or sign in to reply