User permissions - can't fetch lookup table with username

This public forum is for user-to-user discussions of PHPMaker. Note that this is not support forum.
Post Reply
csmgomes
User
Posts: 105

User permissions - can't fetch lookup table with username

Post by csmgomes »

CONTEXT:

  • Have a table with a field that relates to User Table to show who created the record
  • Field: IDUser that connects to Users Table
  • Advanced Security: I've added the limitation that users can only see their own records ON ANOTHER TABLE, using UserID and ReportsTo field (to allow managers to see all records)
  • On dynamic permissions, I've allowed all users to view, lookup and search the users table

PROBLEM:

  • Same level users can't see the name associated to IDUser. They just see their own name and the other users as a number
  • If I don't use the advanced security options at all, they can all see each others names

every user can open and edit records from other users and that's how it should be
Only Admin can see Names instead of numbers. Why is that?

  • On the table's list, IDUser is connected on the project, to the UserTable through linkfield (IDUser) and DisplayField (Username)
  • Also, on the add record page, it only shows the current user. I don't mind that each user can only add records with their own name, the problem is that when they edit a record, if it's not their record, the user data disappears after saving
  • I've used previously Username as an autofill field but can't use it anymore, since sometimes I need to change the user associated to a record (as an admin)

Any thought?
Thanks in advance


mobhar
User
Posts: 11737

Post by mobhar »

csmgomes wrote:
the problem is that when they edit a record, if it's not their record, the user data disappears after saving

Try to use "Row_Updating" server event to assign the current user to that field.


Post Reply