Implementing the dynamic home page based on user

The current home page view is for the admin and we need to create the view for users as well. So the home page has to change a little bit according to the user role.

As the discussion, we had yesterday meeting and also in the quick meeting today with @Gravewalker. We are going to create three tabs instead of the current tabs.

  1. Programs - Shows all the programs
  2. My mentoring programs - shows the programs that user mentoring
  3. My menteeing (not sure about the word :sweat_smile:) programs - shows the programs that the user is a mentee

In order to achieve this, we need two APIs for,

  1. Get the programs that the user is a mentor
  2. Get the programs that the user is a mentee

I will update this thread with the wireframes later.
@jaye @piumal1999 @YohanAvishke

2 Likes

Here are the wireframes:-

Here’s Github issue for this task:

@jaye Is there going to be a button in my menteeing program cards?

1 Like

Mentors might have. but mentees not. (Anyway we can move the manage mentee view to the program view later)

1 Like

@anjisvj This is impressive, good job. But there shouldn’t be tabs for mentoring and menteeing programs in the admin view. Scratch that part otherwise someone might get confused.

1 Like

yeah those tabs are disabled. I’ll hide them and update the thread.

Here’s the draft PR for the above task,

@piumal1999 What are the endpoints to get the mentee and mentor program?

Mentee programs:
me/programs/mentee

Mentor programs:
/me/programs/mentor

1 Like

There was an issue with accessing the cookie which was throwing 401 even the user cookie is there.
Me and @jaye had a call regarding this and fixed it by adding webconfig to allow CORS mapping.
Here’s the PR for that: -

Here’s the final PR:

Admin View

User (Logged in)

User (Logged Out)