Role access Update makes Document Action Access reset

Automated Testing Tools are used to assure modifications are always backward compatible and safe for production
Forum rules
This forum is personally pruned to avoid redundant posts. Related topics are moved to the same sub-forum. Language will be corrected for readability.

Role access Update makes Document Action Access reset

Postby dellph » Tue Aug 30, 2011 6:02 am

Every time execute Role access update the Document Action Access all reset. For example if you restrict a role so that he cannot complete a sales order. After you execute Role access update this restriction is gone.


Use Case
1. Login as GardenAdmin
2. open Role Window (under System Admin/General Rules/Security menu)
3. Select GardenWorld User
4. Click Document Action Access tab
5. Uncheck Active field of Any Document Type
6. execute Role Access Update (under System Admin/General Rules/Security menu)
7. go back to Role Window
8. Select GardenWorld User
9. Click Document Action Access tab
10. notice ALL you uncheck Active record will be active again <====bug

I report this in http://jira.idempiere.com/browse/IDEMPIERE-66. Thanks!
dellph
 
Posts: 15
Joined: Fri Mar 18, 2011 7:26 am

Re: Role access Update makes Document Action Access reset

Postby dellph » Tue Aug 30, 2011 6:04 am

I have notice in MRole.java in method updateAccessRecords this command in line 503

int docactDel = DB.executeUpdate("DELETE FROM AD_Document_Action_Access" + whereDel, get_TrxName());
int docact = DB.executeUpdate(sqlDocAction, get_TrxName());

I think this is the culprit. When I comment this to command the Document Action Access is not reset.

Would this be good solution? Why reset this table?
dellph
 
Posts: 15
Joined: Fri Mar 18, 2011 7:26 am


Return to Quality Assurance

Who is online

Users browsing this forum: No registered users and 2 guests

cron