IDEMPIERE-401 SaveError when voiding order in web store / Thanks to Dirk Niemeyer (a42niem)

This commit is contained in:
Carlos Ruiz 2012-08-29 17:04:03 -05:00
parent 13f7391926
commit 3c4648f0c4
1 changed files with 2 additions and 1 deletions

View File

@ -3044,7 +3044,8 @@ public abstract class PO
// Carlos Ruiz - globalqss - IDEMPIERE-111
// Check if the role has access to this client
if (!MRole.getDefault().isClientAccess(getAD_Client_ID(), true))
// Don't check role System as webstore works with this role - see IDEMPIERE-401
if ((Env.getAD_Role_ID(getCtx()) != 0) && !MRole.getDefault().isClientAccess(getAD_Client_ID(), true))
{
log.warning("You cannot delete this record, role doesn't have access");
log.saveError("AccessCannotDelete", "", false);