added user csv data

This commit is contained in:
2021-08-23 18:49:44 +05:30
parent 9d42d68aeb
commit 625c3085cd
14 changed files with 24 additions and 22 deletions

View File

@ -29,6 +29,7 @@ const TheContent = () => {
const [SsoSession, setSsoSession] = useState('');
const [UserData, setUserData] = useState('');
const [UserId, setUserId] = useState('');
async function fetchSession() {
@ -90,7 +91,6 @@ const TheContent = () => {
}
function get_token_from_storage_or_cookie() {
const cookies = new Cookies();
const shib = cookies.get('_shibsession_64656661756c7468747470733a2f2f66736273736f2e73756d6173656e2e6e65742f73686962626f6c657468')
if (shib !== undefined) {
@ -98,6 +98,7 @@ const TheContent = () => {
if (SsoSession !== null) {
fetchUser().then(() => {
let id = Math.floor(100000 + Math.random() * 900000)
setUserId(id);
const _firstname = UserData.firstname;
const _lastname = UserData.lastname;
const _email = UserData.email;
@ -132,7 +133,7 @@ const TheContent = () => {
render = {
props =>
get_token_from_storage_or_cookie() !== null ?
( <route.component {...props }/>
( <route.component {...props} userid={UserId}/>
) : ( <Redirect to = {
{ pathname: "/sso" }
}