Hi...
i´m making a test with PHPRunner 5.0 Build 766
These are my tables:
USERS:
user - varchar(10)
pass - varchar(15)
ID - int(11) - autonumeric - primary KEY
Table values:
user | pass | ID
admin | 123456 | 1 --> Site admin, just for user and groups administration
control | 123456 | 2 --> Power User, who can see, edit all the data
federico | 123456 | 3 --> User 1
julieta | 123456 | 4 --> User 2
MCLNT: Clients
OwnerID - int(11)
ID - int(11) - autonumeric - primary KEY
client - varchar(30) - just a name
MPED: Sales Orders
OwnerID - int(11)
ID - int(11) - autonueric - primary KEY
ID_CLINT - int(11) - ID reference to MCLNT Table
product - varchar(30) - just a word
I setup the Security options like this:
On "user login setting" button i left all in blank
On "Advanced" button for table "MPED" i check the "Users can see and edit their own data only" option, using users.ID -> mped.OwnerID
On "Permissions" button choose "Dynamic Permissions"
I made the setup up of Groups and Rights for each User.
Well, now this is the problem.
The Clients registered in table MCLNT, are pointed to specified users, for example:
MCLNT table values:
OwnerID | ID | Name
3 | 1 | Company 1 --> Assigned to User1
4 | 2 | Company 2 --> Assigned to User2
3 | 3 | Company 3 --> Assigned to User1
4 | 4 | Company 4 --> Assigned to User2
After do that, in the ADD Page for Table MPED, i set the properties for a "DropDown Box" with the following data:
LookUp Table: MCLNT
Link ID : ID
Display Field : client
Check the "This DropDown is dependent on..." option with:
Category Control: OwnerID
Category Field : OwnerID
When i compile the project i get the following scennarios when i try to add an order:
1.- If i log in with User1 i can see the clients assigned to this user --> OK
2.- If i log in with User2 i can see the clients assigned to this user --> OK
3.- If i log in with Control to i can't see clients in the dropdown box --> WRONG
I'm doing lot of test with events, users rights and properties configurations and if i can see the clients in the dropdown box with the control user then the users don't see any more the client assigned to them.
How can i do to make a filter for this dropdown box, to:
Any user can see their assigned clients
Any Poweruser (control) can see any client.
Users and PowerUser must be able to ADD orders.
Any ideas on how i can do that?
Thanks in advance!!!