小组应用还原用户权限中获取应用权限列表的方法

This commit is contained in:
anhc 2022-07-15 08:31:36 +08:00
parent 051c082e09
commit 47f1e3dd87
2 changed files with 6 additions and 20 deletions

View File

@ -1059,27 +1059,13 @@ public class CooperationWeb extends ActionWeb {
List<String> appPerm = new ArrayList<>();// 应用权限
List<String> actionPerm = new ArrayList<>();// 操作权限
// 获取应用权限选项范围
// aslp服务地址
String aslp = "aslp://com.actionsoft.apps.coe.pal.cooperation/listApps";
//列出已注册的流程团队扩展App
ResponseObject res = SDK.getAppAPI().callASLP(SDK.getAppAPI().getAppContext(CoEConstant.APP_ID), aslp, new HashMap<String, Object>());
if (res.isOk()) {
JSONArray appArr = (JSONArray)((Map)res.getData()).get("apps");
for (int i = 0; i < appArr.size(); i++) {
;
JSONObject appObj = new JSONObject();
appObj.put("value", appArr.getJSONObject(i).getString("title"));
appObj.put("label", appArr.getJSONObject(i).getString("id"));
appPermOpts.add(appObj);
}
List<CooperationAppProfile> appList = CooperationAppManager.getList();
for (CooperationAppProfile profile : appList) {
JSONObject appObj = new JSONObject();
appObj.put("value", profile.getTitle());
appObj.put("label", profile.getId());
appPermOpts.add(appObj);
}
// List<CooperationAppProfile> appList = CooperationAppManager.getList();
// for (CooperationAppProfile profile : appList) {
// JSONObject appObj = new JSONObject();
// appObj.put("value", profile.getTitle());
// appObj.put("label", profile.getId());
// appPermOpts.add(appObj);
// }
//权限操作权限options
JSONObject actionObj1 = new JSONObject();
actionObj1.put("value", "新建流程");