Support Topics Documentation Slack YouTube Blog

Can we create a new Users table with all the UserServices


(David Avaneesh Reddy Katakam) #1

Hey Backendless,

I require an additional users table service. Is it possible for me to create. Or is there only one table that exists for users.
If possible from your end can you please create one named “Contacts”.

Thanks a lot guys.
David


(Vladimir Upirov) #2

Hi David

Most likely we can’t, could you please describe your end goal why you need that, and we will try to propose you a solution.

Regards, Vlad


(David Avaneesh Reddy Katakam) #3

Hey Vlad,

I need registered users to create new users(of another kind). I wish they also had functions similar to that of the original users.
Hope that is possible with backendless.

Thanks,
David


(Vladimir Upirov) #4

I don’t see any reasons to not use Users table for that.
Let’s take a look more deeply, for example you would like to have two kinds of users: “Admin user” and “Simple user”, you can create a new column for Users table let’s say “isAdmin” boolean column, and then use Custom Business Logic or/and Roles and Permissions to handle any cases for both users on the server

for a example for preventing user registration (only admin can register another user) you may have a “beforeRegister” Event Handler and inside the handler you can check if the current user (who made request) is not admin throw an exception


(David Avaneesh Reddy Katakam) #5

Thanks a lot Vlad. I’ll try that out and let you know. :+1:


(Vladimir Upirov) #6

great, looking forward to hearing from you, if you have any other issues I will be happy to help you