"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "openmeetings-web/src/main/java/org/apache/openmeetings/web/room/menu/RoomInvitationForm.java" between
apache-openmeetings-6.1.0-src.tar.gz and apache-openmeetings-6.2.0-src.tar.gz

About: OpenMeetings is a browser-based software that allows you to set up instantly a conference in the Web. You can use your microphone or webcam, share documents on a white board, share your screen or record meetings. Source code.

RoomInvitationForm.java  (apache-openmeetings-6.1.0-src):RoomInvitationForm.java  (apache-openmeetings-6.2.0-src)
skipping to change at line 60 skipping to change at line 60
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.wicketstuff.select2.Select2MultiChoice; import org.wicketstuff.select2.Select2MultiChoice;
public class RoomInvitationForm extends InvitationForm { public class RoomInvitationForm extends InvitationForm {
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
private static final Logger log = LoggerFactory.getLogger(RoomInvitationF orm.class); private static final Logger log = LoggerFactory.getLogger(RoomInvitationF orm.class);
private final RadioGroup<InviteeType> rdi = new RadioGroup<>("inviteeType ", Model.of(InviteeType.user)); private final RadioGroup<InviteeType> rdi = new RadioGroup<>("inviteeType ", Model.of(InviteeType.user));
private final Long roomId; private final Long roomId;
private final WebMarkupContainer groupContainer = new WebMarkupContainer( "groupContainer"); private final WebMarkupContainer groupContainer = new WebMarkupContainer( "groupContainer");
final Select2MultiChoice<Group> groups = new Select2MultiChoice<>("groups " private final Select2MultiChoice<Group> groups = new Select2MultiChoice<> ("groups"
, new CollectionModel<>(new ArrayList<>()) , new CollectionModel<>(new ArrayList<>())
, new GroupChoiceProvider()); , new GroupChoiceProvider());
final WebMarkupContainer sipContainer = new WebMarkupContainer("sip-conta iner"); final WebMarkupContainer sipContainer = new WebMarkupContainer("sip-conta iner");
@SpringBean @SpringBean
private RoomDao roomDao; private RoomDao roomDao;
@SpringBean @SpringBean
private GroupUserDao groupUserDao; private GroupUserDao groupUserDao;
@SpringBean @SpringBean
private InvitationManager invitationManager; private InvitationManager invitationManager;
enum InviteeType { enum InviteeType {
user user
, group , group
} }
public RoomInvitationForm(String id, Long roomId) { public RoomInvitationForm(String id, Long roomId, String dropDownParentId
super(id); ) {
super(id, dropDownParentId);
this.roomId = roomId; this.roomId = roomId;
}
@Override
protected void onInitialize() {
groups.setLabel(new ResourceModel("126"));
boolean showGroups = AuthLevelUtil.hasAdminLevel(getRights()); boolean showGroups = AuthLevelUtil.hasAdminLevel(getRights());
add(rdi.add(new AjaxFormChoiceComponentUpdatingBehavior() { add(rdi.add(new AjaxFormChoiceComponentUpdatingBehavior() {
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
@Override @Override
protected void onUpdate(AjaxRequestTarget target) { protected void onUpdate(AjaxRequestTarget target) {
boolean groupsEnabled = InviteeType.group == rdi. getModelObject(); boolean groupsEnabled = InviteeType.group == rdi. getModelObject();
updateButtons(target); updateButtons(target);
target.add(groups.setEnabled(groupsEnabled), reci pients.setEnabled(!groupsEnabled)); target.add(groups.setEnabled(groupsEnabled), reci pients.setEnabled(!groupsEnabled));
} }
skipping to change at line 101 skipping to change at line 106
groups.setRequired(true).add(AjaxFormComponentUpdatingBeh avior.onUpdate(EVT_CHANGE, target -> { groups.setRequired(true).add(AjaxFormComponentUpdatingBeh avior.onUpdate(EVT_CHANGE, target -> {
url.setModelObject(null); url.setModelObject(null);
updateButtons(target); updateButtons(target);
})).setOutputMarkupId(true) })).setOutputMarkupId(true)
, new Radio<>("group", Model.of(InviteeType.group)) , new Radio<>("group", Model.of(InviteeType.group))
); );
rdi.add(recipients, groupContainer.setVisible(showGroups)); rdi.add(recipients, groupContainer.setVisible(showGroups));
rdi.add(new Radio<>("user", Model.of(InviteeType.user))); rdi.add(new Radio<>("user", Model.of(InviteeType.user)));
add(sipContainer.setOutputMarkupPlaceholderTag(true).setOutputMar kupId(true)); add(sipContainer.setOutputMarkupPlaceholderTag(true).setOutputMar kupId(true));
sipContainer.add(new Label("room.confno", "")).setVisible(false); sipContainer.add(new Label("room.confno", "")).setVisible(false);
} if (dropDownParentId != null) {
groups.getSettings().setDropdownParent(dropDownParentId);
@Override }
protected void onInitialize() {
groups.setLabel(new ResourceModel("126"));
super.onInitialize(); super.onInitialize();
} }
@Override @Override
protected void updateButtons(AjaxRequestTarget target) { protected void updateButtons(AjaxRequestTarget target) {
if (rdi.getModelObject() == InviteeType.user) { if (rdi.getModelObject() == InviteeType.user) {
super.updateButtons(target); super.updateButtons(target);
} else { } else {
Collection<Group> to = groups.getModelObject(); Collection<Group> to = groups.getModelObject();
target.add( target.add(
 End of changes. 4 change blocks. 
8 lines changed or deleted 12 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)