Jump to content
  • 0

Multi User Redirect with Custom Role Names Each Company Chooses


EricB

Question

Hello,

I am building an App as follows, New company gets created in the company table and assigned a company_id. 

I then create an admin login assigned to this company_id that allows the user to do the following. They create new members for their company_id and custom role names. 

The custom role names will be similar to user, manager, district manager, CEO, etc BUT each company makes their own role names so keep that in mind.

The app will support multiple companies and each company will have multiple levels of titles with names they created as such.

 

What I am looking to accomplish is, 1 login form that will direct each company to their appropriate level of applications they will pay for based on each custom role name they created. So a user1 for company1 would login as see two forms to pick from and submit data. This would get sent to their direct supervisor for approval. Supervisor1 at company1 would login and see the request from user1 and approve or deny. If they approve it goes up another level and so on until the number of approval workflow is done.

Company2 would be similar but they would be named member2 logins and does the same workflow as above, but it gets sent to manager2. Manager2 logins in and see the request from member2 and so on.

 

I am looking for options on how to accomplish this since the roles will be custom names doing a user level redirect. There will be many companies with many role names so keep that in mind. Javascript, PHP, Caspio that can handle the redirect to show the user their appropriate GUI with the tabs and data they need to see with their company logo.

Link to comment
Share on other sites

3 answers to this question

Recommended Posts

  • 0

Hi @EricB,

Here is a possible workflow:

User have different Company, for this you can  "Create User-Specific Redirects After Login" : https://howto.caspio.com/tech-tips-and-articles/common-customizations/create-user-specific-redirect-after-login/

Then "Restrict Access to Data by User or Role " : https://howto.caspio.com/authentications-and-connections/authentication/record-level-security/restrict-access-to-data-by-user-or-role/

For Creating an Approval Process for New Submissions : https://howto.caspio.com/tech-tips-and-articles/common-customizations/how-to-create-an-approval-process-for-new-submissions/

I hope this helps

Link to comment
Share on other sites

  • 0
14 hours ago, telly said:

Hi @EricB

I highly suggest to normalize your table first, actually they have this tutorial: https://howto.caspio.com/tables-and-views/table-and-database-design/


 

Thanks for the quick responses. My database is normalized and relations are setup. I am familiar with restricting access of the data by role but I am looking for something that is more complex. 

 

Think of it this way,  all members will login to the same datapages but they will be redirected by company and custom role name to their appropriate tab view . Remember every company will have different workflow levels and different forms they will pay for but all share the same caspio datapages. I was thinking if anyone knew of a PHP or Javascript way to handle this so what i'll have is the HTML structure built out so when company1 user1 logs in to the app they get redirected to the correct URL with only the GUI they need to see and the data is restricted by record level security from there.

So Caspio handles the security/logins and the HTML structure handles what the end user gets redirected to. 

 

Any ideas are appreciated, thanks.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...