0
有人知道如何從TaskFlow中的支持bean獲取用戶在Oracle SOA 11g BPMN應用程序中的角色?以編程方式在Oracle SOA套件11g中獲取用戶角色
我需要知道用戶的角色才能激活某些字段,我的想法是從支持bean中獲取它並執行某些操作。有一個更好的方法嗎?
有人知道如何從TaskFlow中的支持bean獲取用戶在Oracle SOA 11g BPMN應用程序中的角色?以編程方式在Oracle SOA套件11g中獲取用戶角色
我需要知道用戶的角色才能激活某些字段,我的想法是從支持bean中獲取它並執行某些操作。有一個更好的方法嗎?
您有幾種選擇: EL:
#{securityContext.userInRole}
但不能肯定是否檢查用戶是你所需要的。 你可以得到實際的角色列表中保持
oracle.adf.share.security.identitymanagement.UserProfile = ADFContext.getCurrent().getSecurityContext().getUserProfile();
,您還可以在VO/EO層使用Groovy,但在談論SOA,我不知道如果多數民衆贊成真的適用於你...
是的,這解決了這個問題沒有BPM的ADF應用程序。不幸的是,我發現我的問題是BPM不會將驗證信息發送給人工任務,因此當您使用此代碼時,UserProfile爲空,且ADFContext.getCurrent()。getSecurityContext()。getUserName()爲匿名。正因爲如此,我沒有結果地問這個問題:stackoverflow.com/q/3259840/194789 – alfredozn 2010-11-10 00:01:09