// responsible\r
Set<String> userlist = new TreeSet<String>(ticket.getParticipants());\r
\r
- for (RegistrantAccessPermission rp : app().repositories().getUserAccessPermissions(getRepositoryModel())) {\r
- if (rp.permission.atLeast(AccessPermission.PUSH) && !rp.isTeam()) {\r
- userlist.add(rp.registrant);\r
+ if (UserModel.ANONYMOUS.canPush(getRepositoryModel())) {\r
+ // anonymous push\r
+ userlist.addAll(app().users().getAllUsernames());\r
+ } else {\r
+ // authenticated push\r
+ for (RegistrantAccessPermission rp : app().repositories().getUserAccessPermissions(getRepositoryModel())) {\r
+ if (rp.permission.atLeast(AccessPermission.PUSH) && !rp.isTeam()) {\r
+ userlist.add(rp.registrant);\r
+ }\r
}\r
}\r
\r
List<TicketResponsible> responsibles = new ArrayList<TicketResponsible>();\r
for (String username : userlist) {\r
UserModel user = app().users().getUserModel(username);\r
- if (user != null) {\r
+ if (user != null && !user.disabled) {\r
TicketResponsible responsible = new TicketResponsible(user);\r
responsibles.add(responsible);\r
if (user.username.equals(ticket.responsible)) {\r
if (currentUser.canAdmin(null, getRepositoryModel())) {\r
// responsible\r
List<TicketResponsible> responsibles = new ArrayList<TicketResponsible>();\r
- for (RegistrantAccessPermission rp : app().repositories().getUserAccessPermissions(getRepositoryModel())) {\r
- if (rp.permission.atLeast(AccessPermission.PUSH) && !rp.isTeam()) {\r
- UserModel user = app().users().getUserModel(rp.registrant);\r
- if (user != null) {\r
+ if (UserModel.ANONYMOUS.canPush(getRepositoryModel())) {\r
+ // anonymous push allowed\r
+ for (UserModel user : app().users().getAllUsers()) {\r
+ if (!user.disabled) {\r
responsibles.add(new TicketResponsible(user));\r
}\r
}\r
+ } else {\r
+ // authenticated push\r
+ for (RegistrantAccessPermission rp : app().repositories().getUserAccessPermissions(getRepositoryModel())) {\r
+ if (rp.permission.atLeast(AccessPermission.PUSH) && !rp.isTeam()) {\r
+ UserModel user = app().users().getUserModel(rp.registrant);\r
+ if (user != null && !user.disabled) {\r
+ responsibles.add(new TicketResponsible(user));\r
+ }\r
+ }\r
+ }\r
}\r
Collections.sort(responsibles);\r
Fragment responsible = new Fragment("responsible", "responsibleFragment", this);\r