You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@syncope.apache.org by il...@apache.org on 2015/04/22 15:51:28 UTC
[01/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Repository: syncope
Updated Branches:
refs/heads/master 047409836 -> 39f8a0696
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Tasks_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Tasks_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Tasks_it.properties
new file mode 100644
index 0000000..2c050e1
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Tasks_it.properties
@@ -0,0 +1,21 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tab1=Task di propagazione
+tab2=Task di notifica
+tab3=Task programmabili
+tab4=Task di sincronizzazione
+tab5=Task di push
\ No newline at end of file
[21/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Login.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Login.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Login.java
new file mode 100644
index 0000000..deaa359
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Login.java
@@ -0,0 +1,365 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.security.AccessControlException;
+import java.util.List;
+import java.util.Locale;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.panels.NotificationPanel;
+import org.apache.syncope.client.console.rest.UserSelfRestClient;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.LinkPanel;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.syncope.common.lib.wrap.EntitlementTO;
+import org.apache.syncope.common.rest.api.CollectionWrapper;
+import org.apache.syncope.common.rest.api.service.EntitlementService;
+import org.apache.wicket.Component;
+import org.apache.wicket.Page;
+import org.apache.wicket.ajax.AbstractDefaultAjaxBehavior;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.head.IHeaderResponse;
+import org.apache.wicket.markup.head.JavaScriptHeaderItem;
+import org.apache.wicket.markup.html.WebPage;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.ChoiceRenderer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.form.PasswordTextField;
+import org.apache.wicket.markup.html.form.StatelessForm;
+import org.apache.wicket.markup.html.form.TextField;
+import org.apache.wicket.markup.html.panel.Fragment;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.request.cycle.RequestCycle;
+import org.apache.wicket.request.mapper.parameter.PageParameters;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+/**
+ * Syncope Login page.
+ */
+public class Login extends WebPage {
+
+ private static final long serialVersionUID = -3744389270366566218L;
+
+ private final static int SELF_REG_WIN_HEIGHT = 550;
+
+ private final static int SELF_REG_WIN_WIDTH = 800;
+
+ private final static int PWD_RESET_WIN_HEIGHT = 300;
+
+ private final static int PWD_RESET_WIN_WIDTH = 800;
+
+ @SpringBean(name = "version")
+ private String version;
+
+ @SpringBean(name = "anonymousUser")
+ private String anonymousUser;
+
+ @SpringBean(name = "anonymousKey")
+ private String anonymousKey;
+
+ @SpringBean
+ private UserSelfRestClient userSelfRestClient;
+
+ private final StatelessForm<Void> form;
+
+ private final TextField<String> userIdField;
+
+ private final TextField<String> passwordField;
+
+ private final DropDownChoice<Locale> languageSelect;
+
+ private final NotificationPanel feedbackPanel;
+
+ public Login(final PageParameters parameters) {
+ super(parameters);
+ setStatelessHint(true);
+
+ feedbackPanel = new NotificationPanel(Constants.FEEDBACK);
+ add(feedbackPanel);
+
+ form = new StatelessForm<Void>("login");
+
+ userIdField = new TextField<String>("userId", new Model<String>());
+ userIdField.setMarkupId("userId");
+ form.add(userIdField);
+
+ passwordField = new PasswordTextField("password", new Model<String>());
+ passwordField.setMarkupId("password");
+ form.add(passwordField);
+
+ languageSelect = new LocaleDropDown("language");
+
+ form.add(languageSelect);
+
+ AjaxButton submitButton = new AjaxButton("submit", new Model<String>(getString("submit"))) {
+
+ private static final long serialVersionUID = 429178684321093953L;
+
+ @Override
+ protected void onSubmit(AjaxRequestTarget target, Form<?> form) {
+ try {
+ if (anonymousUser.equals(userIdField.getRawInput())) {
+ throw new AccessControlException("Illegal username");
+ }
+
+ authenticate(userIdField.getRawInput(), passwordField.getRawInput());
+
+ setResponsePage(WelcomePage.class, parameters);
+ } catch (AccessControlException e) {
+ error(getString("login-error"));
+ feedbackPanel.refresh(target);
+ SyncopeSession.get().resetClients();
+ }
+ }
+ };
+
+ submitButton.setDefaultFormProcessing(false);
+ form.add(submitButton);
+
+ add(form);
+
+ // Modal window for self registration
+ final ModalWindow selfRegModalWin = new ModalWindow("selfRegModal");
+ selfRegModalWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ selfRegModalWin.setInitialHeight(SELF_REG_WIN_HEIGHT);
+ selfRegModalWin.setInitialWidth(SELF_REG_WIN_WIDTH);
+ selfRegModalWin.setCookieName("self-reg-modal");
+ add(selfRegModalWin);
+
+ Fragment selfRegFrag;
+ if (userSelfRestClient.isSelfRegistrationAllowed()) {
+ selfRegFrag = new Fragment("selfRegistration", "selfRegAllowed", this);
+
+ final AjaxLink<Void> selfRegLink = new ClearIndicatingAjaxLink<Void>("link", getPageReference()) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ selfRegModalWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ // anonymous authentication needed for self-registration
+ authenticate(anonymousUser, anonymousKey);
+
+ return new UserSelfModalPage(Login.this.getPageReference(), selfRegModalWin, new UserTO());
+ }
+ });
+
+ selfRegModalWin.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
+
+ private static final long serialVersionUID = 251794406325329768L;
+
+ @Override
+ public void onClose(final AjaxRequestTarget target) {
+ SyncopeSession.get().invalidate();
+ }
+ });
+
+ selfRegModalWin.show(target);
+ }
+ };
+ selfRegLink.add(new Label("linkTitle", getString("selfRegistration")));
+
+ Panel panel = new LinkPanel("selfRegistration", new ResourceModel("selfRegistration"));
+ panel.add(selfRegLink);
+ selfRegFrag.add(panel);
+ } else {
+ selfRegFrag = new Fragment("selfRegistration", "selfRegNotAllowed", this);
+ }
+ add(selfRegFrag);
+
+ // Modal window for password reset request
+ final ModalWindow pwdResetReqModalWin = new ModalWindow("pwdResetReqModal");
+ pwdResetReqModalWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ pwdResetReqModalWin.setInitialHeight(PWD_RESET_WIN_HEIGHT);
+ pwdResetReqModalWin.setInitialWidth(PWD_RESET_WIN_WIDTH);
+ pwdResetReqModalWin.setCookieName("pwd-reset-req-modal");
+ add(pwdResetReqModalWin);
+
+ Fragment pwdResetFrag;
+ if (userSelfRestClient.isPasswordResetAllowed()) {
+ pwdResetFrag = new Fragment("passwordReset", "pwdResetAllowed", this);
+
+ final AjaxLink<Void> pwdResetLink = new ClearIndicatingAjaxLink<Void>("link", getPageReference()) {
+
+ private static final long serialVersionUID = -6957616042924610290L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ pwdResetReqModalWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ // anonymous authentication needed for password reset request
+ authenticate(anonymousUser, anonymousKey);
+
+ return new RequestPasswordResetModalPage(pwdResetReqModalWin);
+ }
+ });
+
+ pwdResetReqModalWin.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
+
+ private static final long serialVersionUID = 8804221891699487139L;
+
+ @Override
+ public void onClose(final AjaxRequestTarget target) {
+ SyncopeSession.get().invalidate();
+ setResponsePage(Login.class);
+ }
+ });
+
+ pwdResetReqModalWin.show(target);
+ }
+ };
+ pwdResetLink.add(new Label("linkTitle", getString("passwordReset")));
+
+ Panel panel = new LinkPanel("passwordReset", new ResourceModel("passwordReset"));
+ panel.add(pwdResetLink);
+ pwdResetFrag.add(panel);
+ } else {
+ pwdResetFrag = new Fragment("passwordReset", "pwdResetNotAllowed", this);
+ }
+ add(pwdResetFrag);
+
+ // Modal window for password reset confirm - automatically shown when token is available as request parameter
+ final String pwdResetToken = RequestCycle.get().getRequest().getRequestParameters().
+ getParameterValue(Constants.PARAM_PASSWORD_RESET_TOKEN).toOptionalString();
+ final ModalWindow pwdResetConfModalWin = new ModalWindow("pwdResetConfModal");
+ if (StringUtils.isNotBlank(pwdResetToken)) {
+ pwdResetConfModalWin.add(new AbstractDefaultAjaxBehavior() {
+
+ private static final long serialVersionUID = 3109256773218160485L;
+
+ @Override
+ protected void respond(final AjaxRequestTarget target) {
+ ModalWindow window = (ModalWindow) getComponent();
+ window.show(target);
+ }
+
+ @Override
+ public void renderHead(final Component component, final IHeaderResponse response) {
+ response.render(JavaScriptHeaderItem.forScript(getCallbackScript(), null));
+ }
+ });
+ }
+ pwdResetConfModalWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ pwdResetConfModalWin.setInitialHeight(PWD_RESET_WIN_HEIGHT);
+ pwdResetConfModalWin.setInitialWidth(PWD_RESET_WIN_WIDTH);
+ pwdResetConfModalWin.setCookieName("pwd-reset-conf-modal");
+ pwdResetConfModalWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ // anonymous authentication needed for password reset confirm
+ authenticate(anonymousUser, anonymousKey);
+
+ return new ConfirmPasswordResetModalPage(pwdResetConfModalWin, pwdResetToken);
+ }
+ });
+ pwdResetConfModalWin.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
+
+ private static final long serialVersionUID = 8804221891699487139L;
+
+ @Override
+ public void onClose(final AjaxRequestTarget target) {
+ SyncopeSession.get().invalidate();
+ setResponsePage(Login.class);
+ }
+ });
+ add(pwdResetConfModalWin);
+ }
+
+ private void authenticate(final String username, final String password) {
+ List<EntitlementTO> entitlements = SyncopeSession.get().
+ getService(EntitlementService.class, username, password).getOwnEntitlements();
+
+ SyncopeSession.get().setUsername(username);
+ SyncopeSession.get().setPassword(password);
+ SyncopeSession.get().setEntitlements(CollectionWrapper.unwrap(entitlements).toArray(new String[0]));
+ SyncopeSession.get().setVersion(version);
+ }
+
+ /**
+ * Inner class which implements (custom) Locale DropDownChoice component.
+ */
+ private class LocaleDropDown extends DropDownChoice<Locale> {
+
+ private static final long serialVersionUID = 2349382679992357202L;
+
+ private class LocaleRenderer extends ChoiceRenderer<Locale> {
+
+ private static final long serialVersionUID = -3657529581555164741L;
+
+ @Override
+ public String getDisplayValue(final Locale locale) {
+ return locale.getDisplayName(getLocale());
+ }
+ }
+
+ public LocaleDropDown(final String id) {
+ super(id, SyncopeSession.SUPPORTED_LOCALES);
+
+ setChoiceRenderer(new LocaleRenderer());
+ setModel(new IModel<Locale>() {
+
+ private static final long serialVersionUID = -6985170095629312963L;
+
+ @Override
+ public Locale getObject() {
+ return getSession().getLocale();
+ }
+
+ @Override
+ public void setObject(final Locale object) {
+ getSession().setLocale(object);
+ }
+
+ @Override
+ public void detach() {
+ // Empty.
+ }
+ });
+
+ // set default value to English
+ getModel().setObject(Locale.ENGLISH);
+ }
+
+ @Override
+ protected boolean wantOnSelectionChangedNotifications() {
+ return true;
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Logout.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Logout.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Logout.java
new file mode 100644
index 0000000..acf313b
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Logout.java
@@ -0,0 +1,38 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.wicket.request.mapper.parameter.PageParameters;
+
+/**
+ * Syncope Logout.
+ */
+public class Logout extends BasePage {
+
+ private static final long serialVersionUID = -2143007520243939450L;
+
+ public Logout(final PageParameters parameters) {
+ super(parameters);
+
+ SyncopeSession.get().invalidate();
+
+ setResponsePage(getApplication().getHomePage());
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/MembershipModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/MembershipModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/MembershipModalPage.java
new file mode 100644
index 0000000..f2e2189
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/MembershipModalPage.java
@@ -0,0 +1,114 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.commons.Mode;
+import org.apache.syncope.client.console.panels.AnnotatedBeanPanel;
+import org.apache.syncope.client.console.panels.DerAttrsPanel;
+import org.apache.syncope.client.console.panels.PlainAttrsPanel;
+import org.apache.syncope.client.console.panels.VirAttrsPanel;
+import org.apache.syncope.common.lib.to.MembershipTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.ResourceModel;
+
+public class MembershipModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = -4360802478081432549L;
+
+ private final AjaxButton submit;
+
+ public MembershipModalPage(final PageReference pageRef, final ModalWindow window, final MembershipTO membershipTO,
+ final Mode mode) {
+
+ final Form<MembershipTO> form = new Form<MembershipTO>("MembershipForm");
+
+ final UserTO userTO = ((UserModalPage) pageRef.getPage()).getUserTO();
+
+ form.setModel(new CompoundPropertyModel<MembershipTO>(membershipTO));
+
+ submit = new AjaxButton(SUBMIT, new ResourceModel(SUBMIT)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form form) {
+ userTO.getMemberships().remove(membershipTO);
+ userTO.getMemberships().add(membershipTO);
+
+ ((UserModalPage) pageRef.getPage()).setUserTO(userTO);
+
+ window.close(target);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+
+ form.add(submit);
+ form.setDefaultButton(submit);
+
+ final IndicatingAjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ ((UserModalPage) pageRef.getPage()).setUserTO(userTO);
+ window.close(target);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ }
+ };
+
+ cancel.setDefaultFormProcessing(false);
+ form.add(cancel);
+
+ //--------------------------------
+ // Attributes panel
+ //--------------------------------
+ form.add(new PlainAttrsPanel("plainAttrs", membershipTO, form, mode));
+ form.add(new AnnotatedBeanPanel("systeminformation", membershipTO));
+ //--------------------------------
+
+ //--------------------------------
+ // Derived attributes container
+ //--------------------------------
+ form.add(new DerAttrsPanel("derAttrs", membershipTO));
+ //--------------------------------
+
+ //--------------------------------
+ // Virtual attributes container
+ //--------------------------------
+ form.add(new VirAttrsPanel("virAttrs", membershipTO, mode == Mode.TEMPLATE));
+ //--------------------------------
+
+ add(form);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/NotificationModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/NotificationModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/NotificationModalPage.java
new file mode 100644
index 0000000..98d8862
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/NotificationModalPage.java
@@ -0,0 +1,441 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.EnumSet;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.panels.LoggerCategoryPanel;
+import org.apache.syncope.client.console.panels.GroupSearchPanel;
+import org.apache.syncope.client.console.panels.UserSearchPanel;
+import org.apache.syncope.client.console.rest.LoggerRestClient;
+import org.apache.syncope.client.console.rest.NotificationRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.NotificationTO;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.syncope.common.lib.types.IntMappingType;
+import org.apache.syncope.common.lib.types.TraceLevel;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.apache.wicket.validation.validator.EmailAddressValidator;
+
+class NotificationModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = -1975312550059578553L;
+
+ @SpringBean
+ private NotificationRestClient restClient;
+
+ @SpringBean
+ private LoggerRestClient loggerRestClient;
+
+ public NotificationModalPage(final PageReference pageRef, final ModalWindow window,
+ final NotificationTO notificationTO, final boolean createFlag) {
+
+ final Form<NotificationTO> form =
+ new Form<NotificationTO>(FORM, new CompoundPropertyModel<NotificationTO>(notificationTO));
+
+ final AjaxTextFieldPanel sender = new AjaxTextFieldPanel("sender", getString("sender"),
+ new PropertyModel<String>(notificationTO, "sender"));
+ sender.addRequiredLabel();
+ sender.addValidator(EmailAddressValidator.getInstance());
+ form.add(sender);
+
+ final AjaxTextFieldPanel subject = new AjaxTextFieldPanel("subject", getString("subject"),
+ new PropertyModel<String>(notificationTO, "subject"));
+ subject.addRequiredLabel();
+ form.add(subject);
+
+ final AjaxDropDownChoicePanel<String> template = new AjaxDropDownChoicePanel<String>(
+ "template", getString("template"),
+ new PropertyModel<String>(notificationTO, "template"));
+ template.setChoices(confRestClient.getMailTemplates());
+ template.addRequiredLabel();
+ form.add(template);
+
+ final AjaxDropDownChoicePanel<TraceLevel> traceLevel = new AjaxDropDownChoicePanel<TraceLevel>(
+ "traceLevel", getString("traceLevel"),
+ new PropertyModel<TraceLevel>(notificationTO, "traceLevel"));
+ traceLevel.setChoices(Arrays.asList(TraceLevel.values()));
+ traceLevel.addRequiredLabel();
+ form.add(traceLevel);
+
+ final AjaxCheckBoxPanel isActive = new AjaxCheckBoxPanel("isActive",
+ getString("isActive"), new PropertyModel<Boolean>(notificationTO, "active"));
+ if (createFlag) {
+ isActive.getField().setDefaultModelObject(Boolean.TRUE);
+ }
+ form.add(isActive);
+
+ final WebMarkupContainer aboutContainer = new WebMarkupContainer("aboutContainer");
+ aboutContainer.setOutputMarkupId(true);
+
+ form.add(aboutContainer);
+
+ final AjaxCheckBoxPanel checkAbout = new AjaxCheckBoxPanel("checkAbout", "checkAbout", new Model<Boolean>(
+ notificationTO.getUserAbout() == null && notificationTO.getGroupAbout() == null));
+ aboutContainer.add(checkAbout);
+
+ final AjaxCheckBoxPanel checkUserAbout = new AjaxCheckBoxPanel("checkUserAbout", "checkUserAbout",
+ new Model<Boolean>(notificationTO.getUserAbout() != null));
+ aboutContainer.add(checkUserAbout);
+
+ final AjaxCheckBoxPanel checkGroupAbout = new AjaxCheckBoxPanel("checkGroupAbout", "checkGroupAbout",
+ new Model<Boolean>(notificationTO.getGroupAbout() != null));
+ aboutContainer.add(checkGroupAbout);
+
+ final UserSearchPanel userAbout =
+ new UserSearchPanel.Builder("userAbout").fiql(notificationTO.getUserAbout()).build();
+ aboutContainer.add(userAbout);
+ userAbout.setEnabled(checkUserAbout.getModelObject());
+
+ final GroupSearchPanel groupAbout =
+ new GroupSearchPanel.Builder("groupAbout").fiql(notificationTO.getGroupAbout()).build();
+ aboutContainer.add(groupAbout);
+ groupAbout.setEnabled(checkGroupAbout.getModelObject());
+
+ checkAbout.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ if (checkAbout.getModelObject()) {
+ checkUserAbout.setModelObject(Boolean.FALSE);
+ checkGroupAbout.setModelObject(Boolean.FALSE);
+ userAbout.setEnabled(Boolean.FALSE);
+ groupAbout.setEnabled(Boolean.FALSE);
+ } else {
+ checkAbout.setModelObject(Boolean.TRUE);
+ }
+ target.add(aboutContainer);
+ }
+ });
+
+ checkUserAbout.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ if (checkUserAbout.getModelObject()) {
+ checkAbout.setModelObject(!checkUserAbout.getModelObject());
+ checkGroupAbout.setModelObject(!checkUserAbout.getModelObject());
+ groupAbout.setEnabled(Boolean.FALSE);
+ } else {
+ checkUserAbout.setModelObject(Boolean.TRUE);
+ }
+ userAbout.setEnabled(Boolean.TRUE);
+ target.add(aboutContainer);
+ }
+ });
+
+ checkGroupAbout.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ if (checkGroupAbout.getModelObject()) {
+ checkAbout.setModelObject(Boolean.FALSE);
+ checkUserAbout.setModelObject(Boolean.FALSE);
+ userAbout.setEnabled(Boolean.FALSE);
+ } else {
+ checkGroupAbout.setModelObject(Boolean.TRUE);
+ }
+ groupAbout.setEnabled(Boolean.TRUE);
+ target.add(aboutContainer);
+ }
+ });
+
+ final AjaxDropDownChoicePanel<IntMappingType> recipientAttrType = new AjaxDropDownChoicePanel<IntMappingType>(
+ "recipientAttrType", new ResourceModel("recipientAttrType", "recipientAttrType").getObject(),
+ new PropertyModel<IntMappingType>(notificationTO, "recipientAttrType"));
+ recipientAttrType.setChoices(new ArrayList<IntMappingType>(
+ IntMappingType.getAttributeTypes(AttributableType.USER,
+ EnumSet.of(IntMappingType.UserId, IntMappingType.Password))));
+ recipientAttrType.addRequiredLabel();
+ form.add(recipientAttrType);
+
+ final AjaxDropDownChoicePanel<String> recipientAttrName = new AjaxDropDownChoicePanel<String>(
+ "recipientAttrName", new ResourceModel("recipientAttrName", "recipientAttrName").getObject(),
+ new PropertyModel<String>(notificationTO, "recipientAttrName"));
+ recipientAttrName.setChoices(getSchemaNames(recipientAttrType.getModelObject()));
+ recipientAttrName.addRequiredLabel();
+ form.add(recipientAttrName);
+
+ recipientAttrType.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ recipientAttrName.setChoices(getSchemaNames(recipientAttrType.getModelObject()));
+ target.add(recipientAttrName);
+ }
+ });
+
+ form.add(new LoggerCategoryPanel(
+ "eventSelection",
+ loggerRestClient.listEvents(),
+ new PropertyModel<List<String>>(notificationTO, "events"),
+ getPageReference(),
+ "Notification") {
+
+ private static final long serialVersionUID = 6429053774964787735L;
+
+ @Override
+ protected String[] getListRoles() {
+ return new String[] {};
+ }
+
+ @Override
+ protected String[] getChangeRoles() {
+ return new String[] {};
+ }
+ });
+
+ final WebMarkupContainer recipientsContainer = new WebMarkupContainer("recipientsContainer");
+ recipientsContainer.setOutputMarkupId(true);
+
+ form.add(recipientsContainer);
+
+ final AjaxCheckBoxPanel checkStaticRecipients = new AjaxCheckBoxPanel("checkStaticRecipients",
+ "recipients", new Model<Boolean>(!notificationTO.getStaticRecipients().isEmpty()));
+ form.add(checkStaticRecipients);
+
+ if (createFlag) {
+ checkStaticRecipients.getField().setDefaultModelObject(Boolean.FALSE);
+ }
+
+ final AjaxTextFieldPanel staticRecipientsFieldPanel =
+ new AjaxTextFieldPanel("panel", "staticRecipients", new Model<String>(null));
+ staticRecipientsFieldPanel.addValidator(EmailAddressValidator.getInstance());
+ staticRecipientsFieldPanel.setRequired(checkStaticRecipients.getModelObject());
+
+ if (notificationTO.getStaticRecipients().isEmpty()) {
+ notificationTO.getStaticRecipients().add(null);
+ }
+
+ final MultiFieldPanel<String> staticRecipients = new MultiFieldPanel<String>("staticRecipients",
+ new PropertyModel<List<String>>(notificationTO, "staticRecipients"), staticRecipientsFieldPanel);
+ staticRecipients.setEnabled(checkStaticRecipients.getModelObject());
+ form.add(staticRecipients);
+
+ final AjaxCheckBoxPanel checkRecipients =
+ new AjaxCheckBoxPanel("checkRecipients", "checkRecipients",
+ new Model<Boolean>(notificationTO.getRecipients() == null ? false : true));
+ recipientsContainer.add(checkRecipients);
+
+ if (createFlag) {
+ checkRecipients.getField().setDefaultModelObject(Boolean.TRUE);
+ }
+
+ final UserSearchPanel recipients =
+ new UserSearchPanel.Builder("recipients").fiql(notificationTO.getRecipients()).build();
+
+ recipients.setEnabled(checkRecipients.getModelObject());
+ recipientsContainer.add(recipients);
+
+ final AjaxCheckBoxPanel selfAsRecipient = new AjaxCheckBoxPanel("selfAsRecipient",
+ getString("selfAsRecipient"), new PropertyModel<Boolean>(notificationTO, "selfAsRecipient"));
+ form.add(selfAsRecipient);
+
+ if (createFlag) {
+ selfAsRecipient.getField().setDefaultModelObject(Boolean.FALSE);
+ }
+
+ selfAsRecipient.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ if (!selfAsRecipient.getModelObject()
+ && !checkRecipients.getModelObject()
+ && !checkStaticRecipients.getModelObject()) {
+
+ checkRecipients.getField().setDefaultModelObject(Boolean.TRUE);
+ target.add(checkRecipients);
+ recipients.setEnabled(checkRecipients.getModelObject());
+ target.add(recipients);
+ target.add(recipientsContainer);
+ }
+ }
+ });
+
+ checkRecipients.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ if (!checkRecipients.getModelObject()
+ && !selfAsRecipient.getModelObject()
+ && !checkStaticRecipients.getModelObject()) {
+
+ checkStaticRecipients.getField().setDefaultModelObject(Boolean.TRUE);
+ target.add(checkStaticRecipients);
+ staticRecipients.setEnabled(Boolean.TRUE);
+ target.add(staticRecipients);
+ staticRecipientsFieldPanel.setRequired(Boolean.TRUE);
+ target.add(staticRecipientsFieldPanel);
+ }
+ recipients.setEnabled(checkRecipients.getModelObject());
+ target.add(recipients);
+ target.add(recipientsContainer);
+ }
+ });
+
+ checkStaticRecipients.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ if (!checkStaticRecipients.getModelObject()
+ && !selfAsRecipient.getModelObject()
+ && !checkRecipients.getModelObject()) {
+ checkRecipients.getField().setDefaultModelObject(Boolean.TRUE);
+ checkRecipients.setEnabled(Boolean.TRUE);
+ target.add(checkRecipients);
+ }
+ staticRecipients.setEnabled(checkStaticRecipients.getModelObject());
+ staticRecipientsFieldPanel.setRequired(checkStaticRecipients.getModelObject());
+ recipients.setEnabled(checkRecipients.getModelObject());
+ target.add(staticRecipientsFieldPanel);
+ target.add(staticRecipients);
+ target.add(recipients);
+ target.add(recipientsContainer);
+ }
+ });
+
+ AjaxButton submit = new IndicatingAjaxButton(APPLY, new Model<String>(getString(SUBMIT))) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ notificationTO.setUserAbout(
+ !checkAbout.getModelObject() && checkUserAbout.getModelObject() ? userAbout.buildFIQL() : null);
+ notificationTO.setGroupAbout(
+ !checkAbout.getModelObject()
+ && checkGroupAbout.getModelObject() ? groupAbout.buildFIQL() : null);
+ notificationTO.setRecipients(checkRecipients.getModelObject() ? recipients.buildFIQL() : null);
+ notificationTO.getStaticRecipients().removeAll(Collections.singleton(null));
+
+ try {
+ if (createFlag) {
+ restClient.create(notificationTO);
+ } else {
+ restClient.update(notificationTO);
+ }
+ info(getString(Constants.OPERATION_SUCCEEDED));
+
+ Configuration callerPage = (Configuration) pageRef.getPage();
+ callerPage.setModalResult(true);
+
+ window.close(target);
+ } catch (SyncopeClientException scee) {
+ error(getString(Constants.ERROR) + ": " + scee.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+
+ final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+ };
+
+ cancel.setDefaultFormProcessing(false);
+
+ String allowedRoles = createFlag
+ ? xmlRolesReader.getEntitlement("Notification", "create")
+ : xmlRolesReader.getEntitlement("Notification", "update");
+ MetaDataRoleAuthorizationStrategy.authorize(submit, ENABLE, allowedRoles);
+
+ form.add(submit);
+ form.setDefaultButton(submit);
+
+ form.add(cancel);
+
+ add(form);
+ }
+
+ private List<String> getSchemaNames(final IntMappingType type) {
+ final List<String> result;
+
+ if (type == null) {
+ result = Collections.<String>emptyList();
+ } else {
+ switch (type) {
+ case UserPlainSchema:
+ result = schemaRestClient.getPlainSchemaNames(AttributableType.USER);
+ break;
+
+ case UserDerivedSchema:
+ result = schemaRestClient.getDerSchemaNames(AttributableType.USER);
+ break;
+
+ case UserVirtualSchema:
+ result = schemaRestClient.getVirSchemaNames(AttributableType.USER);
+ break;
+
+ case Username:
+ result = Collections.singletonList("Username");
+ break;
+
+ default:
+ result = Collections.<String>emptyList();
+ }
+ }
+
+ return result;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/NotificationTaskModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/NotificationTaskModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/NotificationTaskModalPage.java
new file mode 100644
index 0000000..70f63d6
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/NotificationTaskModalPage.java
@@ -0,0 +1,69 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.common.lib.to.AbstractTaskTO;
+import org.apache.syncope.common.lib.to.NotificationTaskTO;
+import org.apache.wicket.markup.html.form.ListMultipleChoice;
+import org.apache.wicket.markup.html.form.TextArea;
+import org.apache.wicket.model.PropertyModel;
+
+public class NotificationTaskModalPage extends TaskModalPage {
+
+ private static final long serialVersionUID = -4399606755452034216L;
+
+ public NotificationTaskModalPage(final AbstractTaskTO taskTO) {
+ super(taskTO);
+
+ final AjaxTextFieldPanel sender = new AjaxTextFieldPanel("sender", getString("sender"),
+ new PropertyModel<String>(taskTO, "sender"));
+ sender.setEnabled(false);
+ profile.add(sender);
+
+ if (taskTO instanceof NotificationTaskTO) {
+ final ListMultipleChoice<String> recipients = new ListMultipleChoice<>("recipients",
+ new ArrayList<>(((NotificationTaskTO) taskTO).getRecipients()));
+ recipients.setMaxRows(5);
+ recipients.setEnabled(false);
+ profile.add(recipients);
+ }
+
+ final AjaxTextFieldPanel subject = new AjaxTextFieldPanel("subject", getString("subject"),
+ new PropertyModel<String>(taskTO, "subject"));
+ subject.setEnabled(false);
+ profile.add(subject);
+
+ final TextArea<String> textBody = new TextArea<String>("textBody",
+ new PropertyModel<String>(taskTO, "textBody"));
+ textBody.setEnabled(false);
+ profile.add(textBody);
+
+ final TextArea<String> htmlBody = new TextArea<String>("htmlBody",
+ new PropertyModel<String>(taskTO, "htmlBody"));
+ htmlBody.setEnabled(false);
+ profile.add(htmlBody);
+
+ final AjaxTextFieldPanel traceLevel = new AjaxTextFieldPanel("traceLevel", getString("traceLevel"),
+ new PropertyModel<String>(taskTO, "traceLevel"));
+ traceLevel.setEnabled(false);
+ profile.add(traceLevel);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/PlainSchemaModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/PlainSchemaModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/PlainSchemaModalPage.java
new file mode 100644
index 0000000..3adba7d
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/PlainSchemaModalPage.java
@@ -0,0 +1,456 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.JexlHelpUtils;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.SyncopeConstants;
+import org.apache.syncope.common.lib.to.PlainSchemaTO;
+import org.apache.syncope.common.lib.types.AttrSchemaType;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.syncope.common.lib.types.CipherAlgorithm;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.autocomplete.AutoCompleteTextField;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.util.string.Strings;
+
+/**
+ * Modal window with Schema form.
+ */
+public class PlainSchemaModalPage extends AbstractSchemaModalPage<PlainSchemaTO> {
+
+ private static final long serialVersionUID = -5991561277287424057L;
+
+ public PlainSchemaModalPage(final AttributableType kind) {
+ super(kind);
+ }
+
+ @Override
+ public void setSchemaModalPage(final PageReference pageRef, final ModalWindow window,
+ final PlainSchemaTO schemaTO, final boolean createFlag) {
+
+ final PlainSchemaTO schema = schemaTO == null
+ ? new PlainSchemaTO()
+ : schemaTO;
+
+ final Form<PlainSchemaTO> schemaForm = new Form<>(FORM);
+
+ schemaForm.setModel(new CompoundPropertyModel<>(schema));
+ schemaForm.setOutputMarkupId(true);
+
+ final AjaxTextFieldPanel name =
+ new AjaxTextFieldPanel("key", getString("key"), new PropertyModel<String>(schema, "key"));
+ name.addRequiredLabel();
+ name.setEnabled(createFlag);
+ schemaForm.add(name);
+
+ final AjaxDropDownChoicePanel<AttrSchemaType> type = new AjaxDropDownChoicePanel<>(
+ "type", getString("type"), new PropertyModel<AttrSchemaType>(schema, "type"));
+ type.setChoices(Arrays.asList(AttrSchemaType.values()));
+ type.addRequiredLabel();
+ schemaForm.add(type);
+
+ // -- long, double, date
+ final AjaxTextFieldPanel conversionPattern = new AjaxTextFieldPanel("conversionPattern",
+ getString("conversionPattern"), new PropertyModel<String>(schema, "conversionPattern"));
+ schemaForm.add(conversionPattern);
+
+ final WebMarkupContainer conversionParams = new WebMarkupContainer("conversionParams");
+ conversionParams.setOutputMarkupPlaceholderTag(true);
+ conversionParams.add(conversionPattern);
+ schemaForm.add(conversionParams);
+
+ final WebMarkupContainer typeParams = new WebMarkupContainer("typeParams");
+ typeParams.setOutputMarkupPlaceholderTag(true);
+ // -- enum
+ final AjaxTextFieldPanel enumerationValuesPanel =
+ new AjaxTextFieldPanel("panel", "enumerationValues", new Model<String>(null));
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ final MultiFieldPanel<String> enumerationValues = new MultiFieldPanel<>("enumerationValues",
+ new Model(),
+ enumerationValuesPanel);
+ enumerationValues.setModelObject(getEnumValuesAsList(schema.getEnumerationValues()));
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ final MultiFieldPanel<String> enumerationKeys = new MultiFieldPanel<>("enumerationKeys",
+ new Model(),
+ new AjaxTextFieldPanel("panel", "enumerationKeys", new Model<String>(null)));
+ enumerationKeys.setModelObject(getEnumValuesAsList(schema.getEnumerationKeys()));
+
+ final WebMarkupContainer enumParams = new WebMarkupContainer("enumParams");
+ enumParams.setOutputMarkupPlaceholderTag(true);
+ enumParams.add(enumerationValues);
+ enumParams.add(enumerationKeys);
+ typeParams.add(enumParams);
+
+ // -- encrypted
+ final AjaxTextFieldPanel secretKey = new AjaxTextFieldPanel("secretKey",
+ getString("secretKey"), new PropertyModel<String>(schema, "secretKey"));
+
+ final AjaxDropDownChoicePanel<CipherAlgorithm> cipherAlgorithm = new AjaxDropDownChoicePanel<>(
+ "cipherAlgorithm", getString("cipherAlgorithm"),
+ new PropertyModel<CipherAlgorithm>(schema, "cipherAlgorithm"));
+ cipherAlgorithm.setChoices(Arrays.asList(CipherAlgorithm.values()));
+
+ final WebMarkupContainer encryptedParams = new WebMarkupContainer("encryptedParams");
+ encryptedParams.setOutputMarkupPlaceholderTag(true);
+ encryptedParams.add(secretKey);
+ encryptedParams.add(cipherAlgorithm);
+ typeParams.add(encryptedParams);
+
+ // -- binary
+ final AjaxTextFieldPanel mimeType = new AjaxTextFieldPanel("mimeType",
+ getString("mimeType"), new PropertyModel<String>(schema, "mimeType"));
+ mimeType.setChoices(mimeTypesInitializer.getMimeTypes());
+
+ final WebMarkupContainer binaryParams = new WebMarkupContainer("binaryParams");
+ binaryParams.setOutputMarkupPlaceholderTag(true);
+ binaryParams.add(mimeType);
+ typeParams.add(binaryParams);
+
+ schemaForm.add(typeParams);
+
+ // -- show or hide
+ showHide(schema, type,
+ conversionParams, conversionPattern,
+ enumParams, enumerationValuesPanel, enumerationValues, enumerationKeys,
+ encryptedParams, secretKey, cipherAlgorithm,
+ binaryParams, mimeType);
+ type.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ PlainSchemaModalPage.this.showHide(schema, type,
+ conversionParams, conversionPattern,
+ enumParams, enumerationValuesPanel, enumerationValues, enumerationKeys,
+ encryptedParams, secretKey, cipherAlgorithm,
+ binaryParams, mimeType);
+ target.add(typeParams);
+ }
+ });
+
+ final IModel<List<String>> validatorsList = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ return schemaRestClient.getAllValidatorClasses();
+ }
+ };
+ final AjaxDropDownChoicePanel<String> validatorClass = new AjaxDropDownChoicePanel<>("validatorClass",
+ getString("validatorClass"), new PropertyModel<String>(schema, "validatorClass"));
+ ((DropDownChoice) validatorClass.getField()).setNullValid(true);
+ validatorClass.setChoices(validatorsList.getObject());
+ schemaForm.add(validatorClass);
+
+ final AutoCompleteTextField<String> mandatoryCondition =
+ new AutoCompleteTextField<String>("mandatoryCondition") {
+
+ private static final long serialVersionUID = -2428903969518079100L;
+
+ @Override
+ protected Iterator<String> getChoices(final String input) {
+ List<String> choices = new ArrayList<String>();
+
+ if (Strings.isEmpty(input)) {
+ choices = Collections.emptyList();
+ } else if ("true".startsWith(input.toLowerCase())) {
+ choices.add("true");
+ } else if ("false".startsWith(input.toLowerCase())) {
+ choices.add("false");
+ }
+
+ return choices.iterator();
+ }
+ };
+ mandatoryCondition.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ }
+ });
+ schemaForm.add(mandatoryCondition);
+
+ final WebMarkupContainer pwdJexlHelp = JexlHelpUtils.getJexlHelpWebContainer("jexlHelp");
+
+ final AjaxLink<Void> pwdQuestionMarkJexlHelp = JexlHelpUtils.getAjaxLink(pwdJexlHelp, "questionMarkJexlHelp");
+ schemaForm.add(pwdQuestionMarkJexlHelp);
+ pwdQuestionMarkJexlHelp.add(pwdJexlHelp);
+
+ final AjaxCheckBoxPanel multivalue = new AjaxCheckBoxPanel("multivalue", getString("multivalue"),
+ new PropertyModel<Boolean>(schema, "multivalue"));
+ schemaForm.add(multivalue);
+
+ final AjaxCheckBoxPanel readonly = new AjaxCheckBoxPanel("readonly", getString("readonly"),
+ new PropertyModel<Boolean>(schema, "readonly"));
+ schemaForm.add(readonly);
+
+ final AjaxCheckBoxPanel uniqueConstraint = new AjaxCheckBoxPanel("uniqueConstraint",
+ getString("uniqueConstraint"), new PropertyModel<Boolean>(schema, "uniqueConstraint"));
+ schemaForm.add(uniqueConstraint);
+
+ final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(SUBMIT)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ final PlainSchemaTO schemaTO = (PlainSchemaTO) form.getDefaultModelObject();
+
+ schemaTO.setEnumerationValues(getEnumValuesAsString(enumerationValues.getView().getModelObject()));
+ schemaTO.setEnumerationKeys(getEnumValuesAsString(enumerationKeys.getView().getModelObject()));
+
+ if (schemaTO.isMultivalue() && schemaTO.isUniqueConstraint()) {
+ error(getString("multivalueAndUniqueConstr.validation"));
+ feedbackPanel.refresh(target);
+ return;
+ }
+
+ try {
+ if (createFlag) {
+ schemaRestClient.createPlainSchema(kind, schemaTO);
+ } else {
+ schemaRestClient.updatePlainSchema(kind, schemaTO);
+ }
+ if (pageRef.getPage() instanceof BasePage) {
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+ }
+
+ window.close(target);
+ } catch (SyncopeClientException e) {
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+ schemaForm.add(submit);
+
+ final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+ };
+ cancel.setDefaultFormProcessing(false);
+ schemaForm.add(cancel);
+
+ String allowedRoles = createFlag
+ ? xmlRolesReader.getEntitlement("Schema", "create")
+ : xmlRolesReader.getEntitlement("Schema", "update");
+
+ MetaDataRoleAuthorizationStrategy.authorize(submit, ENABLE, allowedRoles);
+
+ add(schemaForm);
+ }
+
+ private void showHide(final PlainSchemaTO schema, final AjaxDropDownChoicePanel<AttrSchemaType> type,
+ final WebMarkupContainer conversionParams, final AjaxTextFieldPanel conversionPattern,
+ final WebMarkupContainer enumParams, final AjaxTextFieldPanel enumerationValuesPanel,
+ final MultiFieldPanel<String> enumerationValues, final MultiFieldPanel<String> enumerationKeys,
+ final WebMarkupContainer encryptedParams,
+ final AjaxTextFieldPanel secretKey, final AjaxDropDownChoicePanel<CipherAlgorithm> cipherAlgorithm,
+ final WebMarkupContainer binaryParams, final AjaxTextFieldPanel mimeType) {
+
+ final int typeOrdinal = Integer.parseInt(type.getField().getValue());
+ if (AttrSchemaType.Long.ordinal() == typeOrdinal
+ || AttrSchemaType.Double.ordinal() == typeOrdinal
+ || AttrSchemaType.Date.ordinal() == typeOrdinal) {
+
+ conversionParams.setVisible(true);
+
+ enumParams.setVisible(false);
+ if (enumerationValuesPanel.isRequired()) {
+ enumerationValuesPanel.removeRequiredLabel();
+ }
+ enumerationValues.setModelObject(getEnumValuesAsList(null));
+ enumerationKeys.setModelObject(getEnumValuesAsList(null));
+
+ encryptedParams.setVisible(false);
+ if (secretKey.isRequired()) {
+ secretKey.removeRequiredLabel();
+ }
+ secretKey.setModelObject(null);
+ if (cipherAlgorithm.isRequired()) {
+ cipherAlgorithm.removeRequiredLabel();
+ }
+ cipherAlgorithm.setModelObject(null);
+
+ binaryParams.setVisible(false);
+ mimeType.setModelObject(null);
+ } else if (AttrSchemaType.Enum.ordinal() == typeOrdinal) {
+ conversionParams.setVisible(false);
+ conversionPattern.setModelObject(null);
+
+ enumParams.setVisible(true);
+ if (!enumerationValuesPanel.isRequired()) {
+ enumerationValuesPanel.addRequiredLabel();
+ }
+ enumerationValues.setModelObject(getEnumValuesAsList(schema.getEnumerationValues()));
+ enumerationKeys.setModelObject(getEnumValuesAsList(schema.getEnumerationKeys()));
+
+ encryptedParams.setVisible(false);
+ if (secretKey.isRequired()) {
+ secretKey.removeRequiredLabel();
+ }
+ secretKey.setModelObject(null);
+ if (cipherAlgorithm.isRequired()) {
+ cipherAlgorithm.removeRequiredLabel();
+ }
+ cipherAlgorithm.setModelObject(null);
+
+ binaryParams.setVisible(false);
+ mimeType.setModelObject(null);
+ } else if (AttrSchemaType.Encrypted.ordinal() == typeOrdinal) {
+ conversionParams.setVisible(false);
+ conversionPattern.setModelObject(null);
+
+ enumParams.setVisible(false);
+ if (enumerationValuesPanel.isRequired()) {
+ enumerationValuesPanel.removeRequiredLabel();
+ }
+ enumerationValues.setModelObject(getEnumValuesAsList(null));
+ enumerationKeys.setModelObject(getEnumValuesAsList(null));
+
+ encryptedParams.setVisible(true);
+ if (!secretKey.isRequired()) {
+ secretKey.addRequiredLabel();
+ }
+ if (cipherAlgorithm.isRequired()) {
+ cipherAlgorithm.addRequiredLabel();
+ }
+
+ binaryParams.setVisible(false);
+ mimeType.setModelObject(null);
+ } else if (AttrSchemaType.Binary.ordinal() == typeOrdinal) {
+ conversionParams.setVisible(false);
+ conversionPattern.setModelObject(null);
+
+ enumParams.setVisible(false);
+ if (enumerationValuesPanel.isRequired()) {
+ enumerationValuesPanel.removeRequiredLabel();
+ }
+ enumerationValues.setModelObject(getEnumValuesAsList(null));
+ enumerationKeys.setModelObject(getEnumValuesAsList(null));
+
+ encryptedParams.setVisible(false);
+ if (secretKey.isRequired()) {
+ secretKey.removeRequiredLabel();
+ }
+ secretKey.setModelObject(null);
+ if (cipherAlgorithm.isRequired()) {
+ cipherAlgorithm.removeRequiredLabel();
+ }
+ cipherAlgorithm.setModelObject(null);
+
+ binaryParams.setVisible(true);
+ } else {
+ conversionParams.setVisible(false);
+ conversionPattern.setModelObject(null);
+
+ enumParams.setVisible(false);
+ if (enumerationValuesPanel.isRequired()) {
+ enumerationValuesPanel.removeRequiredLabel();
+ }
+ enumerationValues.setModelObject(getEnumValuesAsList(null));
+ enumerationKeys.setModelObject(getEnumValuesAsList(null));
+
+ encryptedParams.setVisible(false);
+ if (secretKey.isRequired()) {
+ secretKey.removeRequiredLabel();
+ }
+ secretKey.setModelObject(null);
+ if (cipherAlgorithm.isRequired()) {
+ cipherAlgorithm.removeRequiredLabel();
+ }
+ cipherAlgorithm.setModelObject(null);
+
+ binaryParams.setVisible(false);
+ mimeType.setModelObject(null);
+ }
+ }
+
+ private String getEnumValuesAsString(final List<String> enumerationValues) {
+ final StringBuilder builder = new StringBuilder();
+
+ for (String str : enumerationValues) {
+ if (StringUtils.isNotBlank(str)) {
+ if (builder.length() > 0) {
+ builder.append(SyncopeConstants.ENUM_VALUES_SEPARATOR);
+ }
+
+ builder.append(str.trim());
+ }
+ }
+
+ return builder.toString();
+ }
+
+ private List<String> getEnumValuesAsList(final String enumerationValues) {
+ final List<String> values = new ArrayList<String>();
+
+ if (StringUtils.isNotBlank(enumerationValues)) {
+ for (String value : enumerationValues.split(SyncopeConstants.ENUM_VALUES_SEPARATOR)) {
+ values.add(value.trim());
+ }
+ } else {
+ values.add(StringUtils.EMPTY);
+ }
+
+ return values;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/PolicyModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/PolicyModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/PolicyModalPage.java
new file mode 100644
index 0000000..ead376a
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/PolicyModalPage.java
@@ -0,0 +1,450 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.panels.NotificationPanel;
+import org.apache.syncope.client.console.panels.PolicyBeanPanel;
+import org.apache.syncope.client.console.rest.PolicyRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPalettePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.common.lib.to.AbstractPolicyTO;
+import org.apache.syncope.common.lib.to.AccountPolicyTO;
+import org.apache.syncope.common.lib.to.PasswordPolicyTO;
+import org.apache.syncope.common.lib.to.ResourceTO;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.to.SyncPolicyTO;
+import org.apache.syncope.common.lib.types.AccountPolicySpec;
+import org.apache.syncope.common.lib.types.PasswordPolicySpec;
+import org.apache.syncope.common.lib.types.PolicySpec;
+import org.apache.syncope.common.lib.types.PolicyType;
+import org.apache.syncope.common.lib.types.SyncPolicySpec;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.ISortableDataProvider;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.ChoiceRenderer;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.panel.Fragment;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.model.StringResourceModel;
+import org.apache.wicket.model.util.ListModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+/**
+ * Modal window with Resource form.
+ */
+public class PolicyModalPage<T extends AbstractPolicyTO<?>> extends BaseModalPage {
+
+ private static final long serialVersionUID = -7325772767481076679L;
+
+ private static final int WIN_HEIGHT = 600;
+
+ private static final int WIN_WIDTH = 1100;
+
+ @SpringBean
+ private PolicyRestClient policyRestClient;
+
+ public PolicyModalPage(final PageReference pageRef, final ModalWindow window, final T policyTO) {
+ super();
+
+ final Form<?> form = new Form<>(FORM);
+ form.setOutputMarkupId(true);
+ add(form);
+
+ final AjaxTextFieldPanel policyid =
+ new AjaxTextFieldPanel("key", "key", new PropertyModel<String>(policyTO, "key"));
+ policyid.setEnabled(false);
+ policyid.setStyleSheet("ui-widget-content ui-corner-all short_fixedsize");
+ form.add(policyid);
+
+ final AjaxTextFieldPanel description = new AjaxTextFieldPanel("description", "description",
+ new PropertyModel<String>(policyTO, "description"));
+ description.addRequiredLabel();
+ description.setStyleSheet("ui-widget-content ui-corner-all medium_dynamicsize");
+ form.add(description);
+
+ final AjaxDropDownChoicePanel<PolicyType> type =
+ new AjaxDropDownChoicePanel<>("type", "type", new PropertyModel<PolicyType>(policyTO, "type"));
+ switch (policyTO.getType()) {
+ case GLOBAL_ACCOUNT:
+ case ACCOUNT:
+ type.setChoices(Arrays.asList(new PolicyType[] { PolicyType.GLOBAL_ACCOUNT, PolicyType.ACCOUNT }));
+ break;
+
+ case GLOBAL_PASSWORD:
+ case PASSWORD:
+ type.setChoices(Arrays.asList(new PolicyType[] { PolicyType.GLOBAL_PASSWORD, PolicyType.PASSWORD }));
+ break;
+
+ case GLOBAL_SYNC:
+ case SYNC:
+ type.setChoices(Arrays.asList(new PolicyType[] { PolicyType.GLOBAL_SYNC, PolicyType.SYNC }));
+
+ default:
+ }
+ type.setChoiceRenderer(new PolicyTypeRenderer());
+ type.addRequiredLabel();
+ form.add(type);
+
+ // Authentication resources - only for AccountPolicyTO
+ Fragment fragment;
+ if (policyTO instanceof AccountPolicyTO) {
+ fragment = new Fragment("forAccountOnly", "authResourcesFragment", form);
+
+ final List<String> resourceNames = new ArrayList<>();
+ for (ResourceTO resource : resourceRestClient.getAll()) {
+ resourceNames.add(resource.getKey());
+ }
+ fragment.add(new AjaxPalettePanel<>("authResources",
+ new PropertyModel<List<String>>(policyTO, "resources"),
+ new ListModel<>(resourceNames)));
+ } else {
+ fragment = new Fragment("forAccountOnly", "emptyFragment", form);
+ }
+ form.add(fragment);
+ //
+
+ final PolicySpec policy = getPolicySpecification(policyTO);
+
+ form.add(new PolicyBeanPanel("panel", policy));
+
+ final ModalWindow mwindow = new ModalWindow("metaEditModalWin");
+ mwindow.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ mwindow.setInitialHeight(WIN_HEIGHT);
+ mwindow.setInitialWidth(WIN_WIDTH);
+ mwindow.setCookieName("meta-edit-modal");
+ add(mwindow);
+
+ List<IColumn<String, String>> resColumns = new ArrayList<>();
+ resColumns.add(new AbstractColumn<String, String>(new StringResourceModel("name", this, null, "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<String>> cellItem,
+ final String componentId, final IModel<String> rowModel) {
+
+ cellItem.add(new Label(componentId, rowModel.getObject()));
+ }
+ });
+ resColumns.add(new AbstractColumn<String, String>(new StringResourceModel("actions", this, null, "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public String getCssClass() {
+ return "action";
+ }
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<String>> cellItem, final String componentId,
+ final IModel<String> model) {
+
+ final String resource = model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ mwindow.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ResourceModalPage(PolicyModalPage.this.getPageReference(),
+ mwindow, resourceRestClient.read(resource), false);
+ }
+ });
+
+ mwindow.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, "Resources");
+
+ cellItem.add(panel);
+ }
+ });
+ ISortableDataProvider<String, String> resDataProvider = new SortableDataProvider<String, String>() {
+
+ private static final long serialVersionUID = 8263758912838836438L;
+
+ @Override
+ public Iterator<? extends String> iterator(final long first, final long count) {
+ return policyTO.getKey() == 0
+ ? Collections.<String>emptyList().iterator()
+ : policyRestClient.getPolicy(policyTO.getKey()).
+ getUsedByResources().subList((int) first, (int) first + (int) count).iterator();
+ }
+
+ @Override
+ public long size() {
+ return policyTO.getKey() == 0
+ ? 0
+ : policyRestClient.getPolicy(policyTO.getKey()).
+ getUsedByResources().size();
+ }
+
+ @Override
+ public IModel<String> model(final String object) {
+ return new Model<>(object);
+ }
+ };
+ final AjaxFallbackDefaultDataTable<String, String> resources =
+ new AjaxFallbackDefaultDataTable<>("resources", resColumns, resDataProvider, 10);
+ form.add(resources);
+
+ List<IColumn<GroupTO, String>> groupColumns = new ArrayList<>();
+ groupColumns.add(new PropertyColumn<GroupTO, String>(new ResourceModel("key", "key"), "key", "key"));
+ groupColumns.add(new PropertyColumn<GroupTO, String>(new ResourceModel("name", "name"), "name", "name"));
+ groupColumns.add(new AbstractColumn<GroupTO, String>(new StringResourceModel("actions", this, null, "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public String getCssClass() {
+ return "action";
+ }
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<GroupTO>> cellItem, final String componentId,
+ final IModel<GroupTO> model) {
+
+ final GroupTO group = model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ mwindow.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new GroupModalPage(PolicyModalPage.this.getPageReference(), mwindow, group);
+ }
+ });
+
+ mwindow.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, "Groups");
+
+ cellItem.add(panel);
+ }
+ });
+ ISortableDataProvider<GroupTO, String> groupDataProvider = new SortableDataProvider<GroupTO, String>() {
+
+ private static final long serialVersionUID = 8263758912838836438L;
+
+ @Override
+ public Iterator<? extends GroupTO> iterator(final long first, final long count) {
+ List<GroupTO> groups = new ArrayList<>();
+
+ if (policyTO.getKey() > 0) {
+ for (Long groupId : policyRestClient.getPolicy(policyTO.getKey()).getUsedByGroups().
+ subList((int) first, (int) first + (int) count)) {
+
+ groups.add(groupRestClient.read(groupId));
+ }
+ }
+
+ return groups.iterator();
+ }
+
+ @Override
+ public long size() {
+ return policyTO.getKey() == 0
+ ? 0
+ : policyRestClient.getPolicy(policyTO.getKey()).getUsedByGroups().size();
+ }
+
+ @Override
+ public IModel<GroupTO> model(final GroupTO object) {
+ return new Model<>(object);
+ }
+ };
+ final AjaxFallbackDefaultDataTable<GroupTO, String> groups =
+ new AjaxFallbackDefaultDataTable<>("groups", groupColumns, groupDataProvider, 10);
+ form.add(groups);
+
+ mwindow.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
+
+ private static final long serialVersionUID = 8804221891699487139L;
+
+ @Override
+ public void onClose(final AjaxRequestTarget target) {
+ target.add(resources);
+ target.add(groups);
+ if (isModalResult()) {
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ feedbackPanel.refresh(target);
+ setModalResult(false);
+ }
+ }
+ });
+
+ final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(APPLY)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ setPolicySpecification(policyTO, policy);
+
+ try {
+ if (policyTO.getKey() > 0) {
+ policyRestClient.updatePolicy(policyTO);
+ } else {
+ policyRestClient.createPolicy(policyTO);
+ }
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+
+ window.close(target);
+ } catch (Exception e) {
+ LOG.error("While creating policy", e);
+
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
+ }
+ };
+ form.add(submit);
+
+ final IndicatingAjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ }
+ };
+ cancel.setDefaultFormProcessing(false);
+ form.add(cancel);
+ }
+
+ private PolicySpec getPolicySpecification(final AbstractPolicyTO policyTO) {
+ PolicySpec spec;
+
+ switch (policyTO.getType()) {
+ case GLOBAL_ACCOUNT:
+ case ACCOUNT:
+ spec = ((AccountPolicyTO) policyTO).getSpecification() != null
+ ? ((AccountPolicyTO) policyTO).getSpecification()
+ : new AccountPolicySpec();
+ break;
+
+ case GLOBAL_PASSWORD:
+ case PASSWORD:
+ spec = ((PasswordPolicyTO) policyTO).getSpecification() != null
+ ? ((PasswordPolicyTO) policyTO).getSpecification()
+ : new PasswordPolicySpec();
+ break;
+
+ case GLOBAL_SYNC:
+ case SYNC:
+ default:
+ spec = ((SyncPolicyTO) policyTO).getSpecification() != null
+ ? ((SyncPolicyTO) policyTO).getSpecification()
+ : new SyncPolicySpec();
+ }
+
+ return spec;
+ }
+
+ private void setPolicySpecification(final AbstractPolicyTO policyTO, final PolicySpec specification) {
+ switch (policyTO.getType()) {
+ case GLOBAL_ACCOUNT:
+ case ACCOUNT:
+ if (!(specification instanceof AccountPolicySpec)) {
+ throw new ClassCastException("policy is type Account, but spec is not: "
+ + specification.getClass().getName());
+ }
+ ((AccountPolicyTO) policyTO).setSpecification((AccountPolicySpec) specification);
+ break;
+
+ case GLOBAL_PASSWORD:
+ case PASSWORD:
+ if (!(specification instanceof PasswordPolicySpec)) {
+ throw new ClassCastException("policy is type Password, but spec is not: "
+ + specification.getClass().getName());
+ }
+ ((PasswordPolicyTO) policyTO).setSpecification((PasswordPolicySpec) specification);
+ break;
+
+ case GLOBAL_SYNC:
+ case SYNC:
+ if (!(specification instanceof SyncPolicySpec)) {
+ throw new ClassCastException("policy is type Sync, but spec is not: "
+ + specification.getClass().getName());
+ }
+ ((SyncPolicyTO) policyTO).setSpecification((SyncPolicySpec) specification);
+
+ default:
+ }
+ }
+
+ private class PolicyTypeRenderer extends ChoiceRenderer<PolicyType> {
+
+ private static final long serialVersionUID = -8993265421104002134L;
+
+ @Override
+ public Object getDisplayValue(final PolicyType object) {
+ return getString(object.name());
+ }
+ };
+}
[08/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel.java
new file mode 100644
index 0000000..d8014f6
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel.java
@@ -0,0 +1,195 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import java.util.Calendar;
+import java.util.Date;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.wicket.AttributeModifier;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.extensions.yui.calendar.DateTimeField;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.form.FormComponent;
+import org.apache.wicket.markup.html.form.validation.AbstractFormValidator;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.validation.IValidationError;
+import org.apache.wicket.validation.ValidationError;
+
+public class DateTimeFieldPanel extends DateFieldPanel {
+
+ private static final long serialVersionUID = -428975732068281726L;
+
+ private Form form = null;
+
+ public DateTimeFieldPanel(final String id, final String name, final IModel<Date> model, final String datePattern) {
+ super(id, name, model, datePattern);
+
+ field = new DateTimeField("field", model);
+
+ final Calendar cal = Calendar.getInstance();
+
+ field.get("hours").add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ final Integer hours = ((DateTimeField) field).getHours();
+ if (hours != null) {
+ cal.set(hours > 12 ? Calendar.HOUR_OF_DAY : Calendar.HOUR, hours);
+ field.setModelObject(cal.getTime());
+ }
+ }
+ });
+
+ field.get("minutes").add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ final Integer minutes = ((DateTimeField) field).getMinutes();
+ if (minutes != null) {
+ cal.set(Calendar.MINUTE, minutes);
+ field.setModelObject(cal.getTime());
+ }
+ }
+ });
+
+ field.get("date").add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ final Date date = ((DateTimeField) field).getDate();
+ if (date == null) {
+ field.setModelObject(null);
+ } else {
+ cal.setTime(date);
+ cal.set(Calendar.AM_PM, "PM".equals("" + ((DateTimeField) field).getAmOrPm()) ? Calendar.PM
+ : Calendar.AM);
+ field.setModelObject(cal.getTime());
+ }
+ }
+ });
+
+ field.get("amOrPmChoice").add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ cal.set(Calendar.AM_PM, "PM".equals("" + ((DateTimeField) field).getAmOrPm()) ? Calendar.PM
+ : Calendar.AM);
+ field.setModelObject(cal.getTime());
+ }
+ });
+
+ add(field.setLabel(new Model<String>(name)).setOutputMarkupId(true));
+ }
+
+ /**
+ * Custom form validator for registering and handling DateTimeField components that are in it.
+ */
+ private class DateTimeFormValidator extends AbstractFormValidator {
+
+ private static final long serialVersionUID = 6842264694946633582L;
+
+ private FormComponent[] dateTimeComponents;
+
+ public DateTimeFormValidator(final DateTimeField dateTimeComponent) {
+ if (dateTimeComponent == null) {
+ throw new IllegalArgumentException("argument dateTimeComponent cannot be null");
+ }
+
+ dateTimeComponents = new FormComponent[] { dateTimeComponent };
+ }
+
+ @Override
+ public FormComponent[] getDependentFormComponents() {
+ return dateTimeComponents;
+ }
+
+ /**
+ * Validation rule : all 3 fields (date,hours,minutes) must be not-null.
+ *
+ * @param form
+ */
+ @Override
+ public void validate(final Form form) {
+ final DateTimeField dateTimeField = (DateTimeField) dateTimeComponents[0];
+
+ if (!(dateTimeField.getDate() != null && dateTimeField.getHours() != null
+ && dateTimeField.getMinutes() != null)) {
+
+ ValidationError ve = new ValidationError();
+ ve.setVariables(DateTimeFormValidator.this.variablesMap());
+ ve.addKey(resourceKey());
+ dateTimeComponents[0].error((IValidationError) ve);
+ }
+ }
+ }
+
+ @SuppressWarnings("rawtypes")
+ public FieldPanel<Date> setFormValidator(final Form form) {
+ if (field == null) {
+ LOG.error("Error setting form validator");
+ } else {
+ form.add(new DateTimeFormValidator(((DateTimeField) field)));
+ this.form = form;
+ }
+
+ return this;
+ }
+
+ @Override
+ public FieldPanel<Date> setStyleSheet(final String classes) {
+ field.get("date").add(AttributeModifier.replace("class", (classes == null ? "" : classes) + " date_size"));
+
+ field.get("hours").add(AttributeModifier.replace("class", classes == null ? "" : classes));
+
+ field.get("minutes").add(AttributeModifier.replace("class", classes == null ? "" : classes));
+
+ field.get("amOrPmChoice").add(AttributeModifier.replace("class", classes == null ? "" : classes));
+
+ return this;
+ }
+
+ @Override
+ public FieldPanel<Date> clone() {
+ final FieldPanel<Date> panel = new DateTimeFieldPanel(getId(), name, new Model<Date>(null), datePattern);
+
+ panel.setRequired(isRequired());
+ panel.setReadOnly(isReadOnly());
+ panel.setTitle(title);
+
+ if (isRequiredLabelAdded) {
+ panel.addRequiredLabel();
+ }
+
+ if (form != null && isRequired()) {
+ ((DateTimeFieldPanel) panel).setFormValidator(form);
+ }
+
+ return panel;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/FieldPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/FieldPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/FieldPanel.java
new file mode 100644
index 0000000..8dbc434
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/FieldPanel.java
@@ -0,0 +1,199 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import java.io.Serializable;
+import java.util.List;
+import org.apache.commons.lang3.SerializationUtils;
+import org.apache.wicket.AttributeModifier;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.FormComponent;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.panel.Fragment;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+
+public abstract class FieldPanel<T> extends AbstractFieldPanel<T> implements Cloneable {
+
+ private static final long serialVersionUID = -198988924922541273L;
+
+ protected FormComponent<T> field = null;
+
+ protected String title = null;
+
+ protected boolean isRequiredLabelAdded = false;
+
+ public FieldPanel(final String id, final IModel<T> model) {
+ super(id, model);
+
+ final Fragment fragment = new Fragment("required", "notRequiredFragment", this);
+ add(fragment);
+
+ setOutputMarkupId(true);
+ }
+
+ public FormComponent<T> getField() {
+ return field;
+ }
+
+ public FieldPanel<T> setTitle(final String title) {
+ this.title = title;
+ field.add(AttributeModifier.replace("title", title != null
+ ? title
+ : ""));
+
+ return this;
+ }
+
+ public FieldPanel<T> setStyleSheet(final String classes) {
+ field.add(AttributeModifier.replace("class", classes != null
+ ? classes
+ : ""));
+
+ return this;
+ }
+
+ public FieldPanel<T> setRequired(boolean required) {
+ field.setRequired(required);
+
+ return this;
+ }
+
+ public FieldPanel<T> setReadOnly(boolean readOnly) {
+ field.setEnabled(!readOnly);
+
+ return this;
+ }
+
+ public boolean isRequired() {
+ return field.isRequired();
+ }
+
+ public boolean isReadOnly() {
+ return !field.isEnabled();
+ }
+
+ public FieldPanel<T> addRequiredLabel() {
+ if (!isRequired()) {
+ setRequired(true);
+ }
+
+ final Fragment fragment = new Fragment("required", "requiredFragment", this);
+
+ fragment.add(new Label("requiredLabel", "*"));
+
+ replace(fragment);
+
+ this.isRequiredLabelAdded = true;
+
+ return this;
+ }
+
+ public FieldPanel<T> removeRequiredLabel() {
+ if (isRequired()) {
+ setRequired(false);
+ }
+
+ final Fragment fragment = new Fragment("required", "notRequiredFragment", this);
+
+ replace(fragment);
+
+ this.isRequiredLabelAdded = false;
+
+ return this;
+ }
+
+ @Override
+ public FieldPanel<T> setModelObject(final T object) {
+ field.setModelObject(object);
+ return this;
+ }
+
+ public T getModelObject() {
+ return (T) field.getModelObject();
+ }
+
+ public FieldPanel<T> setNewModel(final IModel<T> model) {
+ field.setModel(model);
+ return this;
+ }
+
+ /**
+ * Used by MultiValueSelectorPanel to attach items.
+ *
+ * @param item item to attach.
+ * @return updated FieldPanel object.
+ */
+ public FieldPanel<T> setNewModel(final ListItem<T> item) {
+ setNewModel(new IModel<T>() {
+
+ private static final long serialVersionUID = 6799404673615637845L;
+
+ @Override
+ public T getObject() {
+ return item.getModelObject();
+ }
+
+ @Override
+ public void setObject(final T object) {
+ item.setModelObject(object);
+ }
+
+ @Override
+ public void detach() {
+ // no detach
+ }
+ });
+ return this;
+ }
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ public FieldPanel<T> setNewModel(final List<Serializable> list) {
+ setNewModel(new Model() {
+
+ private static final long serialVersionUID = 1088212074765051906L;
+
+ @Override
+ public Serializable getObject() {
+ return list == null || list.isEmpty()
+ ? null
+ : list.get(0);
+ }
+
+ @Override
+ public void setObject(final Serializable object) {
+ list.clear();
+
+ if (object != null) {
+ list.add(object);
+ }
+ }
+ });
+
+ return this;
+ }
+
+ @Override
+ @SuppressWarnings("unchecked")
+ public FieldPanel<T> clone() {
+ final FieldPanel<T> panel = SerializationUtils.clone(this);
+ panel.setModelObject(null);
+ return panel;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/LinkPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/LinkPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/LinkPanel.java
new file mode 100644
index 0000000..b31bbab
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/LinkPanel.java
@@ -0,0 +1,39 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+
+/**
+ * This empty class must exist because there not seems to be alternative to
+ * provide specialized HTML for links.
+ */
+public class LinkPanel extends Panel {
+
+ private static final long serialVersionUID = 4799005986804366330L;
+
+ public LinkPanel(final String id) {
+ super(id);
+ }
+
+ public LinkPanel(final String id, final IModel<?> model) {
+ super(id, model);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/MappingPurposePanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/MappingPurposePanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/MappingPurposePanel.java
new file mode 100644
index 0000000..2c41f37
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/MappingPurposePanel.java
@@ -0,0 +1,133 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import org.apache.syncope.common.lib.types.MappingPurpose;
+import org.apache.wicket.AttributeModifier;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+
+public class MappingPurposePanel extends Panel {
+
+ private static final long serialVersionUID = 322966537010107771L;
+
+ private final AjaxLink<Void> propagation;
+
+ private final AjaxLink<Void> synchronization;
+
+ private final AjaxLink<Void> both;
+
+ private final AjaxLink<Void> none;
+
+ public MappingPurposePanel(final String componentId, final IModel<MappingPurpose> model,
+ final WebMarkupContainer container) {
+
+ super(componentId, model);
+
+ propagation = new AjaxLink<Void>("propagationPurposeLink") {
+
+ private static final long serialVersionUID = -6957616042924610305L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ model.setObject(MappingPurpose.PROPAGATION);
+ setOpacity(MappingPurpose.PROPAGATION);
+ target.add(container);
+ }
+ };
+
+ synchronization = new AjaxLink<Void>("synchronizationPurposeLink") {
+
+ private static final long serialVersionUID = -6957616042924610305L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ model.setObject(MappingPurpose.SYNCHRONIZATION);
+ setOpacity(MappingPurpose.SYNCHRONIZATION);
+ target.add(container);
+ }
+ };
+
+ both = new AjaxLink<Void>("bothPurposeLink") {
+
+ private static final long serialVersionUID = -6957616042924610305L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ model.setObject(MappingPurpose.BOTH);
+ setOpacity(MappingPurpose.BOTH);
+ target.add(container);
+ }
+ };
+
+ none = new AjaxLink<Void>("nonePurposeLink") {
+
+ private static final long serialVersionUID = -6957616042924610305L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ model.setObject(MappingPurpose.NONE);
+ setOpacity(MappingPurpose.NONE);
+ target.add(container);
+ }
+ };
+
+ add(propagation);
+ add(synchronization);
+ add(both);
+ add(none);
+
+ setOpacity(model.getObject());
+ }
+
+ private void setOpacity(final MappingPurpose mappingPurpose) {
+ switch (mappingPurpose) {
+ case PROPAGATION:
+ propagation.add(new AttributeModifier("style", new Model<String>("opacity: 1;")));
+ synchronization.add(new AttributeModifier("style", new Model<String>("opacity: 0.3;")));
+ both.add(new AttributeModifier("style", new Model<String>("opacity: 0.3;")));
+ none.add(new AttributeModifier("style", new Model<String>("opacity: 0.3;")));
+ break;
+ case SYNCHRONIZATION:
+ synchronization.add(new AttributeModifier("style", new Model<String>("opacity: 1;")));
+ propagation.add(new AttributeModifier("style", new Model<String>("opacity: 0.3;")));
+ both.add(new AttributeModifier("style", new Model<String>("opacity: 0.3;")));
+ none.add(new AttributeModifier("style", new Model<String>("opacity: 0.3;")));
+ break;
+ case BOTH:
+ both.add(new AttributeModifier("style", new Model<String>("opacity: 1;")));
+ propagation.add(new AttributeModifier("style", new Model<String>("opacity: 0.3;")));
+ synchronization.add(new AttributeModifier("style", new Model<String>("opacity: 0.3;")));
+ none.add(new AttributeModifier("style", new Model<String>("opacity: 0.3;")));
+ break;
+ case NONE:
+ none.add(new AttributeModifier("style", new Model<String>("opacity: 1;")));
+ synchronization.add(new AttributeModifier("style", new Model<String>("opacity: 0.3;")));
+ propagation.add(new AttributeModifier("style", new Model<String>("opacity: 0.3;")));
+ both.add(new AttributeModifier("style", new Model<String>("opacity: 0.3;")));
+ break;
+ default:
+ // do nothing
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel.java
new file mode 100644
index 0000000..cd4ab2a
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel.java
@@ -0,0 +1,172 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.event.Broadcast;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.markup.html.panel.Fragment;
+import org.apache.wicket.model.IModel;
+
+public class MultiFieldPanel<E> extends AbstractFieldPanel<List<E>> {
+
+ private static final long serialVersionUID = -6322397761456513324L;
+
+ private ListView<E> view;
+
+ private WebMarkupContainer container;
+
+ public MultiFieldPanel(final String id, final IModel<List<E>> model, final FieldPanel<E> panelTemplate) {
+ this(id, model, panelTemplate, false);
+ }
+
+ public MultiFieldPanel(final String id, final IModel<List<E>> model, final FieldPanel<E> panelTemplate,
+ final boolean eventTemplate) {
+
+ super(id, model);
+
+ // -----------------------
+ // Object container definition
+ // -----------------------
+ container = new WebMarkupContainer("multiValueContainer");
+ container.setOutputMarkupId(true);
+ add(container);
+ // -----------------------
+
+ view = new ListView<E>("view", model) {
+
+ private static final long serialVersionUID = -9180479401817023838L;
+
+ @Override
+ protected void populateItem(final ListItem<E> item) {
+ final FieldPanel<E> fieldPanel = panelTemplate.clone();
+
+ if (eventTemplate) {
+ fieldPanel.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ send(getPage(), Broadcast.BREADTH, new MultiValueSelectorEvent(target));
+ }
+ });
+ }
+
+ fieldPanel.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_BLUR) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ }
+ });
+
+ fieldPanel.setNewModel(item);
+ item.add(fieldPanel);
+
+ AjaxLink<Void> minus = new IndicatingAjaxLink<Void>("drop") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ //Drop current component
+ model.getObject().remove(item.getModelObject());
+ fieldPanel.getField().clearInput();
+ target.add(container);
+
+ if (eventTemplate) {
+ send(getPage(), Broadcast.BREADTH, new MultiValueSelectorEvent(target));
+ }
+ }
+ };
+
+ item.add(minus);
+
+ if (model.getObject().size() <= 1) {
+ minus.setVisible(false);
+ minus.setEnabled(false);
+ } else {
+ minus.setVisible(true);
+ minus.setEnabled(true);
+ }
+
+ final Fragment fragment;
+ if (item.getIndex() == model.getObject().size() - 1) {
+ final AjaxLink<Void> plus = new IndicatingAjaxLink<Void>("add") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ //Add current component
+ model.getObject().add(null);
+ target.add(container);
+ }
+ };
+
+ fragment = new Fragment("panelPlus", "fragmentPlus", container);
+
+ fragment.add(plus);
+ } else {
+ fragment = new Fragment("panelPlus", "emptyFragment", container);
+ }
+ item.add(fragment);
+ }
+ };
+
+ container.add(view.setOutputMarkupId(true));
+ setOutputMarkupId(true);
+ }
+
+ public ListView<E> getView() {
+ return view;
+ }
+
+ public WebMarkupContainer getContainer() {
+ return container;
+ }
+
+ @Override
+ public MultiFieldPanel<E> setModelObject(final List<E> object) {
+ view.setModelObject(object);
+ return this;
+ }
+
+ public static class MultiValueSelectorEvent {
+
+ final AjaxRequestTarget target;
+
+ public MultiValueSelectorEvent(final AjaxRequestTarget target) {
+ this.target = target;
+ }
+
+ public AjaxRequestTarget getTarget() {
+ return target;
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/NonI18nPalette.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/NonI18nPalette.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/NonI18nPalette.java
new file mode 100644
index 0000000..55038da
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/NonI18nPalette.java
@@ -0,0 +1,44 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import java.util.Collection;
+import java.util.List;
+import org.apache.wicket.extensions.markup.html.form.palette.Palette;
+import org.apache.wicket.markup.html.form.IChoiceRenderer;
+import org.apache.wicket.model.IModel;
+
+public class NonI18nPalette<T> extends Palette<T> {
+
+ private static final long serialVersionUID = 2659070187837941889L;
+
+ public NonI18nPalette(final String id,
+ final IModel<? extends List<? extends T>> model,
+ final IModel<? extends Collection<? extends T>> choicesModel,
+ final IChoiceRenderer<T> choiceRenderer, final int rows,
+ final boolean allowOrder, final boolean allowMoveAll) {
+
+ super(id, model, choicesModel, choiceRenderer, rows, allowOrder, allowMoveAll);
+ }
+
+ @Override
+ protected boolean localizeDisplayValues() {
+ return false;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/SelectableRecorder.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/SelectableRecorder.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/SelectableRecorder.java
new file mode 100644
index 0000000..2893533
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/SelectableRecorder.java
@@ -0,0 +1,204 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+
+import org.apache.wicket.WicketRuntimeException;
+import org.apache.wicket.extensions.markup.html.form.palette.Palette;
+import org.apache.wicket.extensions.markup.html.form.palette.component.Recorder;
+import org.apache.wicket.markup.html.form.IChoiceRenderer;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.util.string.Strings;
+
+/**
+ * A variant of Recorder, supporting single element selection (for editing purpose, for example). <b>Note</b>: this
+ * class extends Recorder<T> but in fact it is a bare copy of most source code; this was done because the original class
+ * is keeping everything private.
+ *
+ * @param <T> Type of the palette
+ */
+public class SelectableRecorder<T> extends Recorder<T> {
+
+ private static final long serialVersionUID = -3009044376132921879L;
+
+ private boolean attached = false;
+
+ private static final String[] EMPTY_IDS = new String[0];
+
+ /**
+ * Conveniently maintained array of selected ids.
+ */
+ private String[] ids;
+
+ private String selectedId;
+
+ public SelectableRecorder(final String id, final Palette<T> palette) {
+ super(id, palette);
+ }
+
+ @Override
+ protected void onBeforeRender() {
+ super.onBeforeRender();
+
+ if (!getForm().hasError()) {
+ initIds();
+ } else if (ids == null) {
+ ids = EMPTY_IDS;
+ }
+ attached = true;
+ }
+
+ /**
+ * Synchronize ids collection from the palette's model
+ */
+ private void initIds() {
+ // construct the model string based on selection collection
+ IChoiceRenderer<T> renderer = getPalette().getChoiceRenderer();
+ StringBuilder modelStringBuffer = new StringBuilder();
+ Collection<T> modelCollection = getPalette().getModelCollection();
+ if (modelCollection == null) {
+ throw new WicketRuntimeException("Expected getPalette().getModelCollection() to return a non-null value."
+ + " Please make sure you have model object assigned to the palette");
+ }
+ Iterator<T> selection = modelCollection.iterator();
+
+ int i = 0;
+ while (selection.hasNext()) {
+ modelStringBuffer.append(renderer.getIdValue(selection.next(), i++));
+ if (selection.hasNext()) {
+ modelStringBuffer.append(",");
+ }
+ }
+
+ // set model and update ids array
+ String modelString = modelStringBuffer.toString();
+ setDefaultModel(new Model<String>(modelString));
+ updateIds(modelString);
+ }
+
+ public T getSelectedItem() {
+ if (selectedId == null) {
+ return null;
+ }
+
+ IChoiceRenderer<T> renderer = getPalette().getChoiceRenderer();
+
+ T selected = null;
+ for (T choice : getPalette().getChoices()) {
+ if (renderer.getIdValue(choice, 0).equals(selectedId)) {
+ selected = choice;
+ break;
+ }
+ }
+
+ return selected;
+ }
+
+ /**
+ * @return iterator over selected choices
+ */
+ @Override
+ public Iterator<T> getSelectedChoices() {
+ IChoiceRenderer<T> renderer = getPalette().getChoiceRenderer();
+ if (ids.length == 0) {
+ return Collections.<T>emptyList().iterator();
+ }
+
+ List<T> selected = new ArrayList<T>(ids.length);
+ for (String id : ids) {
+ for (T choice : getPalette().getChoices()) {
+ if (renderer.getIdValue(choice, 0).equals(id)) {
+ selected.add(choice);
+ break;
+ }
+ }
+ }
+ return selected.iterator();
+ }
+
+ /**
+ * @return iterator over unselected choices
+ */
+ @Override
+ public Iterator<T> getUnselectedChoices() {
+ IChoiceRenderer<T> renderer = getPalette().getChoiceRenderer();
+ Collection<? extends T> choices = getPalette().getChoices();
+
+ if (choices.size() - ids.length == 0) {
+ return Collections.<T>emptyList().iterator();
+ }
+
+ List<T> unselected = new ArrayList<T>(Math.max(1, choices.size() - ids.length));
+ for (T choice : choices) {
+ final String choiceId = renderer.getIdValue(choice, 0);
+ boolean selected = false;
+ for (String id : ids) {
+ if (id.equals(choiceId)) {
+ selected = true;
+ break;
+ }
+ }
+ if (!selected) {
+ unselected.add(choice);
+ }
+ }
+ return unselected.iterator();
+ }
+
+ @Override
+ protected void onValid() {
+ super.onValid();
+ if (attached) {
+ updateIds();
+ }
+ }
+
+ @Override
+ protected void onInvalid() {
+ super.onInvalid();
+ if (attached) {
+ updateIds();
+ }
+ }
+
+ private void updateIds() {
+ updateIds(getValue());
+ }
+
+ @Override
+ protected void updateIds(final String value) {
+ if (Strings.isEmpty(value)) {
+ ids = EMPTY_IDS;
+ } else {
+ if (value.indexOf('|') == -1) {
+ ids = value.split(",");
+ selectedId = null;
+ } else {
+ String[] splitted = value.split("\\|");
+ selectedId = splitted[0];
+ ids = splitted[1].split(",");
+ }
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/SpinnerFieldPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/SpinnerFieldPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/SpinnerFieldPanel.java
new file mode 100644
index 0000000..4f71f81
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/SpinnerFieldPanel.java
@@ -0,0 +1,197 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import java.io.Serializable;
+import java.util.List;
+import java.util.UUID;
+import org.apache.commons.lang3.math.NumberUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.TextField;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.springframework.util.StringUtils;
+
+public class SpinnerFieldPanel<T extends Number> extends FieldPanel<T> {
+
+ private static final long serialVersionUID = 6413819574530703577L;
+
+ private final String name;
+
+ private final Class<T> reference;
+
+ private final IModel<T> model;
+
+ private final T min;
+
+ private final T max;
+
+ @SuppressWarnings("unchecked")
+ public SpinnerFieldPanel(final String id, final String name, final Class<T> reference, final IModel<T> model,
+ final T min, final T max) {
+
+ super(id, model);
+ this.name = name;
+ this.reference = reference;
+ this.model = model;
+ this.min = min;
+ this.max = max;
+
+ String uuid = UUID.randomUUID().toString();
+ field = new TextField<T>("spinnerField", model, reference);
+ field.setMarkupId(uuid);
+ add(field.setLabel(new Model<String>(name)));
+
+ if (!isReadOnly()) {
+ field.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ // nothing to do
+ }
+ });
+ }
+
+ final StringBuilder statements = new StringBuilder();
+ statements.append("jQuery(function() {").
+ append("var spinner = $('#").append(uuid).append("').spinner();").
+ append("$('#").append(uuid).append("').spinner(").
+ append("'option', 'stop', function(event, ui) { $(this).change(); });");
+ if (this.min != null) {
+ statements.
+ append("$('#").append(uuid).append("').spinner(").
+ append("'option', 'min', ").append(this.min).append(");");
+ }
+ if (this.max != null) {
+ statements.
+ append("$('#").append(uuid).append("').spinner(").
+ append("'option', 'max', ").append(this.max).append(");");
+ }
+ statements.append("});");
+ Label spinnerFieldJS = new Label("spinnerFieldJS", statements.toString());
+ spinnerFieldJS.setEscapeModelStrings(false);
+ add(spinnerFieldJS);
+ }
+
+ @Override
+ public SpinnerFieldPanel<T> setNewModel(final List<Serializable> list) {
+ setNewModel(new Model<T>() {
+
+ private static final long serialVersionUID = 527651414610325237L;
+
+ @Override
+ public T getObject() {
+ T value = null;
+
+ if (list != null && !list.isEmpty() && StringUtils.hasText(list.get(0).toString())) {
+ value = reference.equals(Integer.class)
+ ? reference.cast(NumberUtils.toInt(list.get(0).toString()))
+ : reference.equals(Long.class)
+ ? reference.cast(NumberUtils.toLong(list.get(0).toString()))
+ : reference.equals(Short.class)
+ ? reference.cast(NumberUtils.toShort(list.get(0).toString()))
+ : reference.equals(Float.class)
+ ? reference.cast(NumberUtils.toFloat(list.get(0).toString()))
+ : reference.equals(byte.class)
+ ? reference.cast(NumberUtils.toByte(list.get(0).toString()))
+ : reference.cast(NumberUtils.toDouble(list.get(0).toString()));
+ }
+
+ return value;
+ }
+
+ @Override
+ public void setObject(final T object) {
+ list.clear();
+ if (object != null) {
+ list.add(object.toString());
+ }
+ }
+ });
+
+ return this;
+ }
+
+ @SuppressWarnings("rawtypes")
+ @Override
+ public SpinnerFieldPanel<T> setNewModel(final ListItem item) {
+ field.setModel(new Model<T>() {
+
+ private static final long serialVersionUID = 6799404673615637845L;
+
+ @Override
+ public T getObject() {
+ T number = null;
+
+ final Object obj = item.getModelObject();
+
+ if (obj != null && !obj.toString().isEmpty()) {
+ if (obj instanceof String) {
+ number = reference.equals(Integer.class)
+ ? reference.cast(Integer.valueOf((String) obj))
+ : reference.equals(Long.class)
+ ? reference.cast(Long.valueOf((String) obj))
+ : reference.equals(Short.class)
+ ? reference.cast(Short.valueOf((String) obj))
+ : reference.equals(Float.class)
+ ? reference.cast(Float.valueOf((String) obj))
+ : reference.equals(byte.class)
+ ? reference.cast(Byte.valueOf((String) obj))
+ : reference.cast(Double.valueOf((String) obj));
+ } else if (obj instanceof Number) {
+ // Don't parse anything
+ number = reference.cast(obj);
+ }
+ }
+
+ return number;
+ }
+
+ @Override
+ @SuppressWarnings("unchecked")
+ public void setObject(final T object) {
+ item.setModelObject(object == null ? null : object.toString());
+ }
+ });
+
+ return this;
+ }
+
+ @Override
+ public SpinnerFieldPanel<T> clone() {
+ SpinnerFieldPanel<T> panel = new SpinnerFieldPanel<T>(getId(), name, reference, model, min, max);
+
+ panel.setRequired(isRequired());
+ panel.setReadOnly(isReadOnly());
+ panel.setTitle(title);
+
+ if (isRequiredLabelAdded) {
+ panel.addRequiredLabel();
+ }
+
+ return panel;
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/AbstractBinaryPreviewer.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/AbstractBinaryPreviewer.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/AbstractBinaryPreviewer.java
new file mode 100644
index 0000000..24bdb47
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/AbstractBinaryPreviewer.java
@@ -0,0 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form.preview;
+
+import org.apache.wicket.Component;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public abstract class AbstractBinaryPreviewer extends Panel {
+
+ /**
+ * Logger.
+ */
+ protected static final Logger LOG = LoggerFactory.getLogger(AbstractBinaryPreviewer.class);
+
+ private static final long serialVersionUID = -2482706463911903025L;
+
+ protected final String mimeType;
+
+ protected final byte[] uploadedBytes;
+
+ public AbstractBinaryPreviewer(final String id, final String mimeType, final byte[] uploadedBytes) {
+ super(id);
+ this.mimeType = mimeType;
+ this.uploadedBytes = uploadedBytes;
+ }
+
+ public abstract Component preview();
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryCertPreviewer.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryCertPreviewer.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryCertPreviewer.java
new file mode 100644
index 0000000..61589d7
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryCertPreviewer.java
@@ -0,0 +1,70 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form.preview;
+
+import java.io.ByteArrayInputStream;
+import java.security.cert.CertificateFactory;
+import java.security.cert.X509Certificate;
+import javax.naming.ldap.LdapName;
+import javax.naming.ldap.Rdn;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.BinaryPreview;
+import org.apache.wicket.Component;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.util.io.IOUtils;
+
+@BinaryPreview(mimeTypes = { "application/x-x509-ca-cert", "application/x-x509-user-cert", "application/pkix-cert" })
+public class BinaryCertPreviewer extends AbstractBinaryPreviewer {
+
+ private static final long serialVersionUID = -5843835939538055110L;
+
+ public BinaryCertPreviewer(final String id, final String mimeType, final byte[] uploadedBytes) {
+ super(id, mimeType, uploadedBytes);
+ }
+
+ @Override
+ public Component preview() {
+ final Label commonNameLabel = new Label("certCommonName", new Model<String>());
+ final ByteArrayInputStream certificateStream = new ByteArrayInputStream(uploadedBytes);
+ try {
+ final X509Certificate certificate = (X509Certificate) CertificateFactory.getInstance("X.509").
+ generateCertificate(certificateStream);
+
+ final StringBuilder commonNameBuilder = new StringBuilder("cn=");
+
+ final LdapName ldapName = new LdapName(certificate.getIssuerDN().getName());
+
+ for (Rdn rdn : ldapName.getRdns()) {
+ if ("CN".equalsIgnoreCase(rdn.getType())) {
+ commonNameBuilder.append(rdn.getValue() == null
+ ? StringUtils.EMPTY
+ : rdn.getValue().toString());
+ }
+ }
+ commonNameLabel.setDefaultModelObject(commonNameBuilder.toString());
+ } catch (Exception e) {
+ LOG.error("Error evaluating certificate file", e);
+ throw new IllegalArgumentException("Error evaluating certificate file", e);
+ } finally {
+ IOUtils.closeQuietly(certificateStream);
+ }
+ return this.add(commonNameLabel);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryImagePreviewer.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryImagePreviewer.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryImagePreviewer.java
new file mode 100644
index 0000000..35e442e
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryImagePreviewer.java
@@ -0,0 +1,51 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form.preview;
+
+import org.apache.syncope.client.console.BinaryPreview;
+import org.apache.wicket.Component;
+import org.apache.wicket.extensions.markup.html.image.resource.ThumbnailImageResource;
+import org.apache.wicket.markup.html.image.NonCachingImage;
+import org.apache.wicket.request.resource.DynamicImageResource;
+import org.apache.wicket.request.resource.IResource;
+
+@BinaryPreview(mimeTypes = { "image/jpeg", "image/png", "image/gif", "image/bmp", "image/x-png", "image/vnd.wap.wbmp" })
+public class BinaryImagePreviewer extends AbstractBinaryPreviewer {
+
+ private static final long serialVersionUID = 3338812359368457349L;
+
+ private static final int IMG_SIZE = 230;
+
+ public BinaryImagePreviewer(final String id, final String mimeType, final byte[] uploadedBytes) {
+ super(id, mimeType, uploadedBytes);
+ }
+
+ @Override
+ public Component preview() {
+ return this.add(new NonCachingImage("previewImage", new ThumbnailImageResource(new DynamicImageResource() {
+
+ private static final long serialVersionUID = 923201517955737928L;
+
+ @Override
+ protected byte[] getImageData(final IResource.Attributes attributes) {
+ return uploadedBytes;
+ }
+ }, IMG_SIZE)));
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/link/VeilPopupSettings.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/link/VeilPopupSettings.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/link/VeilPopupSettings.java
new file mode 100644
index 0000000..51c8ec5
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/link/VeilPopupSettings.java
@@ -0,0 +1,32 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.link;
+
+import org.apache.wicket.markup.html.link.PopupSettings;
+
+public class VeilPopupSettings extends PopupSettings {
+
+ private static final long serialVersionUID = -2727046117490858226L;
+
+ @Override
+ public String getPopupJavaScript() {
+ return "document.getElementById('veil').style.display = 'block';" + super.getPopupJavaScript();
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/list/AltListView.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/list/AltListView.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/list/AltListView.java
new file mode 100644
index 0000000..5a491ae
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/list/AltListView.java
@@ -0,0 +1,59 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.list;
+
+import java.util.List;
+import org.apache.wicket.markup.ComponentTag;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.model.IModel;
+
+public abstract class AltListView<T> extends ListView<T> {
+
+ private static final long serialVersionUID = 251378224847354710L;
+
+ public AltListView(final String id) {
+ super(id);
+ }
+
+ public AltListView(final String id, final IModel<? extends List<? extends T>> model) {
+ super(id, model);
+ }
+
+ public AltListView(final String id, final List<? extends T> list) {
+ super(id, list);
+ }
+
+ @Override
+ protected ListItem<T> newItem(final int index, final IModel<T> itemModel) {
+ return new ListItem<T>(index, itemModel) {
+
+ private static final long serialVersionUID = 5473483270932376694L;
+
+ @Override
+ protected void onComponentTag(final ComponentTag tag) {
+ if (index % 2 == 0) {
+ tag.append("class", "alt", " ");
+ }
+
+ super.onComponentTag(tag);
+ }
+ };
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/list/ConnConfPropertyListView.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/list/ConnConfPropertyListView.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/list/ConnConfPropertyListView.java
new file mode 100644
index 0000000..30775f5
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/list/ConnConfPropertyListView.java
@@ -0,0 +1,152 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.list;
+
+import java.io.Serializable;
+import java.util.List;
+import java.util.Set;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPasswordFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.FieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.SpinnerFieldPanel;
+import org.apache.syncope.common.lib.types.ConnConfProperty;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.PasswordTextField;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.util.ClassUtils;
+
+public class ConnConfPropertyListView extends AltListView<ConnConfProperty> {
+
+ private static final long serialVersionUID = -5239334900329150316L;
+
+ private static final Logger LOG = LoggerFactory.getLogger(ConnConfPropertyListView.class);
+
+ private final boolean withOverridable;
+
+ private final Set<ConnConfProperty> configuration;
+
+ public ConnConfPropertyListView(final String id, final IModel<? extends List<? extends ConnConfProperty>> model,
+ final boolean withOverridable, final Set<ConnConfProperty> configuration) {
+
+ super(id, model);
+ this.configuration = configuration;
+ this.withOverridable = withOverridable;
+ }
+
+ @Override
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ protected void populateItem(final ListItem<ConnConfProperty> item) {
+ final ConnConfProperty property = item.getModelObject();
+
+ final Label label = new Label("connPropAttrSchema",
+ StringUtils.isBlank(property.getSchema().getDisplayName())
+ ? property.getSchema().getName()
+ : property.getSchema().getDisplayName());
+ item.add(label);
+
+ FieldPanel<? extends Serializable> field;
+ boolean required = false;
+ boolean isArray = false;
+
+ if (property.getSchema().isConfidential()
+ || Constants.GUARDED_STRING.equalsIgnoreCase(property.getSchema().getType())
+ || Constants.GUARDED_BYTE_ARRAY.equalsIgnoreCase(property.getSchema().getType())) {
+
+ field = new AjaxPasswordFieldPanel("panel",
+ label.getDefaultModelObjectAsString(), new Model<String>());
+ ((PasswordTextField) field.getField()).setResetPassword(false);
+
+ required = property.getSchema().isRequired();
+ } else {
+ Class<?> propertySchemaClass;
+ try {
+ propertySchemaClass =
+ ClassUtils.forName(property.getSchema().getType(), ClassUtils.getDefaultClassLoader());
+ if (ClassUtils.isPrimitiveOrWrapper(propertySchemaClass)) {
+ propertySchemaClass = org.apache.commons.lang3.ClassUtils.primitiveToWrapper(propertySchemaClass);
+ }
+ } catch (Exception e) {
+ LOG.error("Error parsing attribute type", e);
+ propertySchemaClass = String.class;
+ }
+
+ if (ClassUtils.isAssignable(Number.class, propertySchemaClass)) {
+ @SuppressWarnings("unchecked")
+ final Class<Number> numberClass = (Class<Number>) propertySchemaClass;
+ field = new SpinnerFieldPanel<Number>("panel",
+ label.getDefaultModelObjectAsString(), numberClass, new Model<Number>(), null, null);
+
+ required = property.getSchema().isRequired();
+ } else if (ClassUtils.isAssignable(Boolean.class, propertySchemaClass)) {
+ field = new AjaxCheckBoxPanel("panel",
+ label.getDefaultModelObjectAsString(), new Model<Boolean>());
+ } else {
+ field = new AjaxTextFieldPanel("panel",
+ label.getDefaultModelObjectAsString(), new Model<String>());
+
+ required = property.getSchema().isRequired();
+ }
+
+ if (propertySchemaClass.isArray()) {
+ isArray = true;
+ }
+ }
+
+ field.setTitle(property.getSchema().getHelpMessage());
+
+ if (required) {
+ field.addRequiredLabel();
+ }
+
+ if (isArray) {
+ if (property.getValues().isEmpty()) {
+ property.getValues().add(null);
+ }
+
+ final MultiFieldPanel multiFieldPanel = new MultiFieldPanel("panel",
+ new PropertyModel<List<String>>(property, "values"), field);
+ item.add(multiFieldPanel);
+ } else {
+ setNewFieldModel(field, property.getValues());
+ item.add(field);
+ }
+
+ if (withOverridable) {
+ item.add(new AjaxCheckBoxPanel("connPropAttrOverridable",
+ "connPropAttrOverridable", new PropertyModel<Boolean>(property, "overridable")));
+ }
+
+ configuration.add(property);
+ }
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ private void setNewFieldModel(final FieldPanel field, final List<Object> values) {
+ field.setNewModel(values);
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/DefaultMutableTreeNodeExpansion.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/DefaultMutableTreeNodeExpansion.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/DefaultMutableTreeNodeExpansion.java
new file mode 100644
index 0000000..fa962bc
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/DefaultMutableTreeNodeExpansion.java
@@ -0,0 +1,160 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.tree;
+
+import java.io.Serializable;
+import java.util.Collection;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.Set;
+import javax.swing.tree.DefaultMutableTreeNode;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.wicket.MetaDataKey;
+import org.apache.wicket.Session;
+
+public class DefaultMutableTreeNodeExpansion implements Set<DefaultMutableTreeNode>, Serializable {
+
+ private static final long serialVersionUID = -2864060875425661224L;
+
+ private static MetaDataKey<DefaultMutableTreeNodeExpansion> KEY =
+ new MetaDataKey<DefaultMutableTreeNodeExpansion>() {
+
+ private static final long serialVersionUID = 3109256773218160485L;
+
+ };
+
+ private Set<Long> ids = new HashSet<Long>();
+
+ private boolean inverse;
+
+ public void expandAll() {
+ ids.clear();
+
+ inverse = true;
+ }
+
+ public void collapseAll() {
+ ids.clear();
+
+ inverse = false;
+ }
+
+ @Override
+ public boolean add(final DefaultMutableTreeNode node) {
+ GroupTO groupTO = (GroupTO) node.getUserObject();
+ boolean isAdded;
+ if (inverse) {
+ isAdded = ids.remove(groupTO.getKey());
+ } else {
+ isAdded = ids.add(groupTO.getKey());
+ }
+ return isAdded;
+ }
+
+ @Override
+ public boolean remove(final Object object) {
+ DefaultMutableTreeNode node = (DefaultMutableTreeNode) object;
+ GroupTO groupTO = (GroupTO) node.getUserObject();
+ boolean isRemoved;
+ if (inverse) {
+ isRemoved = ids.add(groupTO.getKey());
+ } else {
+ isRemoved = ids.remove(groupTO.getKey());
+ }
+ return isRemoved;
+ }
+
+ @Override
+ public boolean contains(final Object object) {
+ DefaultMutableTreeNode node = (DefaultMutableTreeNode) object;
+ GroupTO groupTO = (GroupTO) node.getUserObject();
+ boolean isContained;
+ if (inverse) {
+ isContained = !ids.contains(groupTO.getKey());
+ } else {
+ isContained = ids.contains(groupTO.getKey());
+ }
+ return isContained;
+ }
+
+ @Override
+ public void clear() {
+ throw new UnsupportedOperationException();
+ }
+
+ @Override
+ public int size() {
+ throw new UnsupportedOperationException();
+ }
+
+ @Override
+ public boolean isEmpty() {
+ throw new UnsupportedOperationException();
+ }
+
+ @Override
+ public <A> A[] toArray(final A[] a) {
+ throw new UnsupportedOperationException();
+ }
+
+ @Override
+ public Iterator<DefaultMutableTreeNode> iterator() {
+ throw new UnsupportedOperationException();
+ }
+
+ @Override
+ public Object[] toArray() {
+ throw new UnsupportedOperationException();
+ }
+
+ @Override
+ public boolean containsAll(Collection<?> c) {
+ throw new UnsupportedOperationException();
+ }
+
+ @Override
+ public boolean addAll(Collection<? extends DefaultMutableTreeNode> c) {
+ throw new UnsupportedOperationException();
+ }
+
+ @Override
+ public boolean retainAll(Collection<?> c) {
+ throw new UnsupportedOperationException();
+ }
+
+ @Override
+ public boolean removeAll(Collection<?> c) {
+ throw new UnsupportedOperationException();
+ }
+
+ /**
+ * Get the expansion for the session.
+ *
+ * @return expansion
+ */
+ public static DefaultMutableTreeNodeExpansion get() {
+ DefaultMutableTreeNodeExpansion expansion = Session.get().getMetaData(KEY);
+ if (expansion == null) {
+ expansion = new DefaultMutableTreeNodeExpansion();
+
+ Session.get().setMetaData(KEY, expansion);
+ }
+ return expansion;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/DefaultMutableTreeNodeExpansionModel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/DefaultMutableTreeNodeExpansionModel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/DefaultMutableTreeNodeExpansionModel.java
new file mode 100644
index 0000000..1b342bd
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/DefaultMutableTreeNodeExpansionModel.java
@@ -0,0 +1,36 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.tree;
+
+import java.util.Set;
+
+import javax.swing.tree.DefaultMutableTreeNode;
+
+import org.apache.wicket.model.AbstractReadOnlyModel;
+
+public class DefaultMutableTreeNodeExpansionModel
+ extends AbstractReadOnlyModel<Set<DefaultMutableTreeNode>> {
+
+ private static final long serialVersionUID = -3407581132184748054L;
+
+ @Override
+ public Set<DefaultMutableTreeNode> getObject() {
+ return DefaultMutableTreeNodeExpansion.get();
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupPanel.java
new file mode 100644
index 0000000..0638a73
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupPanel.java
@@ -0,0 +1,121 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.tree;
+
+import javax.swing.tree.DefaultMutableTreeNode;
+import org.apache.syncope.client.console.commons.GroupTreeBuilder;
+import org.apache.syncope.client.console.commons.XMLRolesReader;
+import org.apache.syncope.client.console.pages.Groups.TreeNodeClickUpdate;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.wicket.Component;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.event.Broadcast;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.extensions.markup.html.repeater.tree.DefaultNestedTree;
+import org.apache.wicket.extensions.markup.html.repeater.tree.ITreeProvider;
+import org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree;
+import org.apache.wicket.extensions.markup.html.repeater.tree.content.Folder;
+import org.apache.wicket.extensions.markup.html.repeater.tree.theme.WindowsTheme;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class TreeGroupPanel extends Panel {
+
+ private static final long serialVersionUID = 1762003213871836869L;
+
+ @SpringBean
+ private GroupTreeBuilder groupTreeBuilder;
+
+ @SpringBean
+ private XMLRolesReader xmlRolesReader;
+
+ private WebMarkupContainer treeContainer;
+
+ private NestedTree<DefaultMutableTreeNode> tree;
+
+ public TreeGroupPanel(final String id) {
+ super(id);
+
+ treeContainer = new WebMarkupContainer("treeContainer");
+ treeContainer.setOutputMarkupId(true);
+ add(treeContainer);
+ updateTree();
+ }
+
+ private void updateTree() {
+ final ITreeProvider<DefaultMutableTreeNode> treeProvider = new TreeGroupProvider(groupTreeBuilder, true);
+ final DefaultMutableTreeNodeExpansionModel treeModel = new DefaultMutableTreeNodeExpansionModel();
+
+ tree = new DefaultNestedTree<DefaultMutableTreeNode>("treeTable", treeProvider, treeModel) {
+
+ private static final long serialVersionUID = 7137658050662575546L;
+
+ @Override
+ protected Component newContentComponent(final String id, final IModel<DefaultMutableTreeNode> node) {
+ final DefaultMutableTreeNode treeNode = node.getObject();
+ final GroupTO groupTO = (GroupTO) treeNode.getUserObject();
+
+ return new Folder<DefaultMutableTreeNode>(id, TreeGroupPanel.this.tree, node) {
+
+ private static final long serialVersionUID = 9046323319920426493L;
+
+ @Override
+ protected boolean isClickable() {
+ return true;
+ }
+
+ @Override
+ protected IModel<?> newLabelModel(final IModel<DefaultMutableTreeNode> model) {
+ return new Model<>(groupTO.getDisplayName());
+ }
+
+ @Override
+ protected void onClick(final AjaxRequestTarget target) {
+ super.onClick(target);
+
+ send(getPage(), Broadcast.BREADTH, new TreeNodeClickUpdate(target, groupTO.getKey()));
+ }
+ };
+ }
+ };
+ tree.add(new WindowsTheme());
+ tree.setOutputMarkupId(true);
+
+ DefaultMutableTreeNodeExpansion.get().expandAll();
+
+ MetaDataRoleAuthorizationStrategy.authorize(tree, ENABLE, xmlRolesReader.getEntitlement("Groups", "read"));
+
+ treeContainer.addOrReplace(tree);
+ }
+
+ @Override
+ public void onEvent(final IEvent<?> event) {
+ super.onEvent(event);
+
+ if (event.getPayload() instanceof TreeNodeClickUpdate) {
+ final TreeNodeClickUpdate update = (TreeNodeClickUpdate) event.getPayload();
+ updateTree();
+ update.getTarget().add(treeContainer);
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupProvider.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupProvider.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupProvider.java
new file mode 100644
index 0000000..c0b55c3
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupProvider.java
@@ -0,0 +1,43 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.tree;
+
+import javax.swing.tree.DefaultMutableTreeNode;
+import org.apache.syncope.client.console.commons.GroupTreeBuilder;
+import org.apache.wicket.extensions.markup.html.repeater.util.TreeModelProvider;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+
+public class TreeGroupProvider extends TreeModelProvider<DefaultMutableTreeNode> {
+
+ private static final long serialVersionUID = -7741964777100892335L;
+
+ public TreeGroupProvider(final GroupTreeBuilder groupTreeBuilder) {
+ this(groupTreeBuilder, false);
+ }
+
+ public TreeGroupProvider(final GroupTreeBuilder groupTreeBuilde, final boolean rootVisible) {
+ super(groupTreeBuilde.build(), rootVisible);
+ }
+
+ @Override
+ public IModel<DefaultMutableTreeNode> model(final DefaultMutableTreeNode treeNode) {
+ return new Model<DefaultMutableTreeNode>(treeNode);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/bulk.css
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/bulk.css b/client/old_console/src/main/resources/META-INF/resources/css/bulk.css
new file mode 100644
index 0000000..1f0e621
--- /dev/null
+++ b/client/old_console/src/main/resources/META-INF/resources/css/bulk.css
@@ -0,0 +1,97 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+th.checkGroupColumn{
+ width: 20px;
+}
+
+td.checkGroupColumn{
+ text-align: center;
+}
+
+div.bulkAction{
+ display:inline-table;
+}
+
+div.bulkActionCell{
+ display: table-cell;
+ vertical-align: middle;
+ text-align: center;
+ width: 40px;
+ padding-left: 7px;
+}
+
+.pageRowElement{
+ display: inline-table;
+ width: 95%;
+}
+
+div#selectedObjects{
+ text-align: center;
+ margin-top: 10px;
+}
+
+div#selectedObjects table {
+ margin: 1em 0;
+ border-collapse: collapse;
+}
+
+div#selectedObjects table td, div#selectedObjects table th {
+ border: 1px solid #eee;
+ padding: .6em 10px;
+}
+
+div#actionRow{
+ height: 30px;
+ overflow: hidden;
+ text-align: left;
+ margin-top: 10px;
+}
+
+div#actions{
+ display: inline-table;
+ height: 30px;
+ overflow: hidden;
+}
+
+div#actions div#actionPanel{
+ display: table-cell;
+ height: 30px;
+ overflow: hidden;
+ cursor: auto;
+ background: none;
+ padding: 0px 10px;
+ vertical-align: middle;
+}
+
+div#actions div#cancelBtmForm{
+ display: table-cell;
+ height: 30px;
+ overflow: hidden;
+ vertical-align: middle;
+ padding-left: 3px;
+}
+
+div#actions div#cancelBtmForm form{
+ padding: 0px;
+ margin: 0px;
+}
+
+div#actions div#cancelBtmForm form input#cancel{
+ padding: 0.6em 1em;
+}
[36/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/BaseRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/BaseRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/BaseRestClient.java
index ddab7af..17b2d4f 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/BaseRestClient.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/rest/BaseRestClient.java
@@ -19,7 +19,7 @@
package org.apache.syncope.client.console.rest;
import java.io.Serializable;
-import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.client.console.SyncopeConsoleSession;
import org.apache.syncope.client.lib.SyncopeClient;
import org.apache.syncope.common.lib.search.OrderByClauseBuilder;
import org.apache.wicket.extensions.markup.html.repeater.util.SortParam;
@@ -35,20 +35,16 @@ public abstract class BaseRestClient implements Serializable {
private static final long serialVersionUID = 1523999867826481989L;
- protected <T> T getAnonymousService(final Class<T> serviceClass) {
- return SyncopeSession.get().getAnonymousService(serviceClass);
- }
-
protected <T> T getService(final Class<T> serviceClass) {
- return SyncopeSession.get().getService(serviceClass);
+ return SyncopeConsoleSession.get().getService(serviceClass);
}
protected <T> T getService(final String etag, final Class<T> serviceClass) {
- return SyncopeSession.get().getService(etag, serviceClass);
+ return SyncopeConsoleSession.get().getService(etag, serviceClass);
}
protected <T> void resetClient(final Class<T> serviceClass) {
- SyncopeSession.get().resetClient(serviceClass);
+ SyncopeConsoleSession.get().resetClient(serviceClass);
}
protected String toOrderBy(final SortParam<String> sort) {
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/ConfigurationRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/ConfigurationRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/ConfigurationRestClient.java
index ca00ea8..cc1501c 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/ConfigurationRestClient.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/rest/ConfigurationRestClient.java
@@ -21,7 +21,7 @@ package org.apache.syncope.client.console.rest;
import java.util.Iterator;
import java.util.List;
import javax.ws.rs.core.Response;
-import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.client.console.SyncopeConsoleSession;
import org.apache.syncope.client.console.commons.AttrLayoutType;
import org.apache.syncope.common.lib.SyncopeClientException;
import org.apache.syncope.common.lib.to.AttrTO;
@@ -88,7 +88,7 @@ public class ConfigurationRestClient extends BaseRestClient {
}
public List<String> getMailTemplates() {
- return SyncopeSession.get().getSyncopeTO().getMailTemplates();
+ return SyncopeConsoleSession.get().getSyncopeTO().getMailTemplates();
}
public Response dbExport() {
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/ConnectorRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/ConnectorRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/ConnectorRestClient.java
index d9a729d..a093dbd 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/ConnectorRestClient.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/rest/ConnectorRestClient.java
@@ -23,7 +23,7 @@ import java.util.Collections;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
-import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.client.console.SyncopeConsoleSession;
import org.apache.syncope.common.lib.SyncopeClientException;
import org.apache.syncope.common.lib.to.BulkAction;
import org.apache.syncope.common.lib.to.BulkActionResult;
@@ -49,7 +49,7 @@ public class ConnectorRestClient extends BaseRestClient {
public List<ConnInstanceTO> getAllConnectors() {
List<ConnInstanceTO> connectors = Collections.<ConnInstanceTO>emptyList();
try {
- connectors = getService(ConnectorService.class).list(SyncopeSession.get().getLocale().toString());
+ connectors = getService(ConnectorService.class).list(SyncopeConsoleSession.get().getLocale().toString());
} catch (Exception e) {
LOG.error("While reading connectors", e);
}
@@ -98,7 +98,7 @@ public class ConnectorRestClient extends BaseRestClient {
List<ConnBundleTO> bundles = Collections.<ConnBundleTO>emptyList();
try {
- bundles = getService(ConnectorService.class).getBundles(SyncopeSession.get().getLocale().toString());
+ bundles = getService(ConnectorService.class).getBundles(SyncopeConsoleSession.get().getLocale().toString());
} catch (SyncopeClientException e) {
LOG.error("While getting connector bundles", e);
}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/GroupRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/GroupRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/GroupRestClient.java
index 91634f2..89d016c 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/GroupRestClient.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/rest/GroupRestClient.java
@@ -18,6 +18,7 @@
*/
package org.apache.syncope.client.console.rest;
+import java.util.Collections;
import java.util.List;
import javax.ws.rs.core.Response;
@@ -47,27 +48,31 @@ public class GroupRestClient extends AbstractSubjectRestClient {
private static final long serialVersionUID = -8549081557283519638L;
@Override
- public int count() {
- return getService(GroupService.class).list(1, 1).getTotalCount();
+ public int count(final String realm) {
+ return getService(GroupService.class).list(Collections.singletonList(realm), 1, 1).getTotalCount();
}
- public List<GroupTO> list() {
- return getService(GroupService.class).list(1, 1000).getResult();
+ public List<GroupTO> list(final String realm) {
+ return getService(GroupService.class).list(Collections.singletonList(realm), 1, 1000).getResult();
}
@Override
- public List<GroupTO> list(final int page, final int size, final SortParam<String> sort) {
- return getService(GroupService.class).list(page, size, toOrderBy(sort)).getResult();
+ public List<GroupTO> list(final String realm, final int page, final int size, final SortParam<String> sort) {
+ return getService(GroupService.class).
+ list(Collections.singletonList(realm), page, size, toOrderBy(sort)).getResult();
}
@Override
- public int searchCount(final String fiql) {
- return getService(GroupService.class).search(fiql, 1, 1).getTotalCount();
+ public int searchCount(final String realm, final String fiql) {
+ return getService(GroupService.class).search(Collections.singletonList(realm), fiql, 1, 1).getTotalCount();
}
@Override
- public List<GroupTO> search(final String fiql, final int page, final int size, final SortParam<String> sort) {
- return getService(GroupService.class).search(fiql, page, size, toOrderBy(sort)).getResult();
+ public List<GroupTO> search(
+ final String realm, final String fiql, final int page, final int size, final SortParam<String> sort) {
+
+ return getService(GroupService.class).
+ search(Collections.singletonList(realm), fiql, page, size, toOrderBy(sort)).getResult();
}
@Override
@@ -80,8 +85,8 @@ public class GroupRestClient extends AbstractSubjectRestClient {
return response.readEntity(GroupTO.class);
}
- public GroupTO read(final Long id) {
- return getAnonymousService(GroupService.class).read(id);
+ public GroupTO read(final Long key) {
+ return getService(GroupService.class).read(key);
}
public GroupTO update(final String etag, final GroupMod groupMod) {
@@ -95,11 +100,11 @@ public class GroupRestClient extends AbstractSubjectRestClient {
}
@Override
- public GroupTO delete(final String etag, final Long id) {
+ public GroupTO delete(final String etag, final Long key) {
GroupTO result;
synchronized (this) {
GroupService service = getService(etag, GroupService.class);
- result = service.delete(id).readEntity(GroupTO.class);
+ result = service.delete(key).readEntity(GroupTO.class);
resetClient(GroupService.class);
}
return result;
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/InvalidPolicyType.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/InvalidPolicyType.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/InvalidPolicyType.java
deleted file mode 100644
index 6c7959c..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/InvalidPolicyType.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.rest;
-
-public class InvalidPolicyType extends RuntimeException {
-
- private static final long serialVersionUID = -1230154509336169378L;
-
- public InvalidPolicyType() {
- }
-
- public InvalidPolicyType(final String msg) {
- super(msg);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/LoggerRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/LoggerRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/LoggerRestClient.java
index a8b40ac..318edcb 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/LoggerRestClient.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/rest/LoggerRestClient.java
@@ -47,7 +47,7 @@ public class LoggerRestClient extends BaseRestClient {
}
public Map<String, Set<AuditLoggerName>> listAuditsByCategory() {
- Map<String, Set<AuditLoggerName>> result = new HashMap<String, Set<AuditLoggerName>>();
+ Map<String, Set<AuditLoggerName>> result = new HashMap<>();
for (AuditLoggerName auditLoggerName : listAudits()) {
if (!result.containsKey(auditLoggerName.getCategory())) {
result.put(auditLoggerName.getCategory(), new HashSet<AuditLoggerName>());
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/NotificationRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/NotificationRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/NotificationRestClient.java
index 687ade0..b33e4dc 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/NotificationRestClient.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/rest/NotificationRestClient.java
@@ -32,8 +32,8 @@ public class NotificationRestClient extends BaseRestClient {
return getService(NotificationService.class).list();
}
- public NotificationTO read(final Long id) {
- return getService(NotificationService.class).read(id);
+ public NotificationTO read(final Long key) {
+ return getService(NotificationService.class).read(key);
}
public void create(final NotificationTO notificationTO) {
@@ -44,7 +44,7 @@ public class NotificationRestClient extends BaseRestClient {
getService(NotificationService.class).update(notificationTO.getKey(), notificationTO);
}
- public void delete(final Long id) {
- getService(NotificationService.class).delete(id);
+ public void delete(final Long key) {
+ getService(NotificationService.class).delete(key);
}
}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/PolicyRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/PolicyRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/PolicyRestClient.java
index 4409f7c..c1f019f 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/PolicyRestClient.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/rest/PolicyRestClient.java
@@ -20,7 +20,7 @@ package org.apache.syncope.client.console.rest;
import java.util.ArrayList;
import java.util.List;
-import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.client.console.SyncopeConsoleSession;
import org.apache.syncope.common.lib.to.AbstractPolicyTO;
import org.apache.syncope.common.lib.types.PolicyType;
import org.apache.syncope.common.rest.api.service.PolicyService;
@@ -34,28 +34,18 @@ public class PolicyRestClient extends BaseRestClient {
private static final long serialVersionUID = -1392090291817187902L;
- public <T extends AbstractPolicyTO<?>> T getGlobalPolicy(final PolicyType type) {
+ public <T extends AbstractPolicyTO> T getPolicy(final Long key) {
T policy = null;
try {
- policy = getService(PolicyService.class).readGlobal(type);
+ policy = getService(PolicyService.class).read(key);
} catch (Exception e) {
- LOG.warn("No global " + type + " policy found", e);
- }
- return policy;
- }
-
- public <T extends AbstractPolicyTO<?>> T getPolicy(final Long id) {
- T policy = null;
- try {
- policy = getService(PolicyService.class).read(id);
- } catch (Exception e) {
- LOG.warn("No policy found for id {}", id, e);
+ LOG.warn("No policy found for id {}", key, e);
}
return policy;
}
@SuppressWarnings("unchecked")
- public <T extends AbstractPolicyTO<?>> List<T> getPolicies(final PolicyType type, final boolean includeGlobal) {
+ public <T extends AbstractPolicyTO> List<T> getPolicies(final PolicyType type) {
final List<T> res = new ArrayList<>();
try {
@@ -64,29 +54,18 @@ public class PolicyRestClient extends BaseRestClient {
LOG.debug("No policy found", ignore);
}
- if (includeGlobal) {
- try {
- T globalPolicy = getGlobalPolicy(type);
- if (globalPolicy != null) {
- res.add(0, globalPolicy);
- }
- } catch (Exception ignore) {
- LOG.warn("No global policy found", ignore);
- }
- }
-
return res;
}
- public <T extends AbstractPolicyTO<?>> void createPolicy(final T policy) {
+ public <T extends AbstractPolicyTO> void createPolicy(final T policy) {
getService(PolicyService.class).create(policy);
}
- public <T extends AbstractPolicyTO<?>> void updatePolicy(final T policy) {
+ public <T extends AbstractPolicyTO> void updatePolicy(final T policy) {
getService(PolicyService.class).update(policy.getKey(), policy);
}
- public void delete(final Long id, final Class<? extends AbstractPolicyTO<?>> policyClass) {
+ public void delete(final Long id, final Class<? extends AbstractPolicyTO> policyClass) {
getService(PolicyService.class).delete(id);
}
@@ -94,7 +73,7 @@ public class PolicyRestClient extends BaseRestClient {
List<String> rules = null;
try {
- rules = SyncopeSession.get().getSyncopeTO().getSyncCorrelationRules();
+ rules = SyncopeConsoleSession.get().getSyncopeTO().getSyncCorrelationRules();
} catch (Exception e) {
LOG.error("While getting all correlation rule classes", e);
}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/ReportRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/ReportRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/ReportRestClient.java
index 81b58ac..ffce9c7 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/ReportRestClient.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/rest/ReportRestClient.java
@@ -35,7 +35,7 @@ public class ReportRestClient extends BaseRestClient implements ExecutionRestCli
private static final long serialVersionUID = 1644689667998953604L;
public List<String> getReportletConfClasses() {
- List<String> result = new ArrayList<String>();
+ List<String> result = new ArrayList<>();
try {
List<ReportletConfClass> reportletConfClasses = getService(ReportService.class).getReportletConfClasses();
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/ResourceRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/ResourceRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/ResourceRestClient.java
index 2c44211..87c9a3a 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/ResourceRestClient.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/rest/ResourceRestClient.java
@@ -19,7 +19,7 @@
package org.apache.syncope.client.console.rest;
import java.util.List;
-import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.client.console.SyncopeConsoleSession;
import org.apache.syncope.common.lib.SyncopeClientException;
import org.apache.syncope.common.lib.to.AbstractAttributableTO;
import org.apache.syncope.common.lib.to.BulkAction;
@@ -41,7 +41,7 @@ public class ResourceRestClient extends BaseRestClient {
private static final long serialVersionUID = -6898907679835668987L;
public List<String> getPropagationActionsClasses() {
- return SyncopeSession.get().getSyncopeTO().getPropagationActions();
+ return SyncopeConsoleSession.get().getSyncopeTO().getPropagationActions();
}
public List<ResourceTO> getAll() {
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/SchemaRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/SchemaRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/SchemaRestClient.java
index 378f98d..6934ef6 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/SchemaRestClient.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/rest/SchemaRestClient.java
@@ -23,7 +23,9 @@ import java.util.Collection;
import java.util.Collections;
import java.util.List;
import java.util.ListIterator;
-import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.commons.collections4.CollectionUtils;
+import org.apache.commons.collections4.Transformer;
+import org.apache.syncope.client.console.SyncopeConsoleSession;
import org.apache.syncope.client.console.commons.AttrLayoutType;
import org.apache.syncope.common.lib.SyncopeClientException;
import org.apache.syncope.common.lib.to.AbstractSchemaTO;
@@ -89,13 +91,16 @@ public class SchemaRestClient extends BaseRestClient {
}
public List<String> getSchemaNames(final AttributableType attrType, final SchemaType schemaType) {
- final List<String> schemaNames = new ArrayList<>();
+ List<String> schemaNames = new ArrayList<>();
try {
- final List<? extends AbstractSchemaTO> schemas = getSchemas(attrType, schemaType);
- for (AbstractSchemaTO schemaTO : schemas) {
- schemaNames.add(schemaTO.getKey());
- }
+ CollectionUtils.collect(getSchemas(attrType, schemaType), new Transformer<AbstractSchemaTO, String>() {
+
+ @Override
+ public String transform(final AbstractSchemaTO schemaTO) {
+ return schemaTO.getKey();
+ }
+ }, schemaNames);
} catch (SyncopeClientException e) {
LOG.error("While getting all user schema names", e);
}
@@ -104,18 +109,7 @@ public class SchemaRestClient extends BaseRestClient {
}
public List<String> getPlainSchemaNames(final AttributableType type) {
- final List<String> schemaNames = new ArrayList<>();
-
- try {
- final List<PlainSchemaTO> schemas = getSchemas(type);
- for (PlainSchemaTO schemaTO : schemas) {
- schemaNames.add(schemaTO.getKey());
- }
- } catch (SyncopeClientException e) {
- LOG.error("While getting all user schema names", e);
- }
-
- return schemaNames;
+ return getSchemaNames(type, SchemaType.PLAIN);
}
public List<DerSchemaTO> getDerSchemas(final AttributableType type) {
@@ -131,19 +125,7 @@ public class SchemaRestClient extends BaseRestClient {
}
public List<String> getDerSchemaNames(final AttributableType type) {
- final List<String> userDerSchemasNames = new ArrayList<>();
-
- try {
- final List<DerSchemaTO> userDerSchemas = getService(SchemaService.class).list(type, SchemaType.DERIVED);
-
- for (DerSchemaTO schemaTO : userDerSchemas) {
- userDerSchemasNames.add(schemaTO.getKey());
- }
- } catch (SyncopeClientException e) {
- LOG.error("While getting all {} derived schema names", type, e);
- }
-
- return userDerSchemasNames;
+ return getSchemaNames(type, SchemaType.DERIVED);
}
public List<VirSchemaTO> getVirSchemas(final AttributableType type) {
@@ -159,19 +141,7 @@ public class SchemaRestClient extends BaseRestClient {
}
public List<String> getVirSchemaNames(final AttributableType type) {
- final List<String> userVirSchemasNames = new ArrayList<String>();
-
- try {
- @SuppressWarnings("unchecked")
- final List<VirSchemaTO> userVirSchemas = getService(SchemaService.class).list(type, SchemaType.VIRTUAL);
- for (VirSchemaTO schemaTO : userVirSchemas) {
- userVirSchemasNames.add(schemaTO.getKey());
- }
- } catch (SyncopeClientException e) {
- LOG.error("While getting all user derived schema names", e);
- }
-
- return userVirSchemasNames;
+ return getSchemaNames(type, SchemaType.VIRTUAL);
}
public void createPlainSchema(final AttributableType type, final PlainSchemaTO schemaTO) {
@@ -241,7 +211,7 @@ public class SchemaRestClient extends BaseRestClient {
List<String> response = null;
try {
- response = SyncopeSession.get().getSyncopeTO().getValidators();
+ response = SyncopeConsoleSession.get().getSyncopeTO().getValidators();
} catch (SyncopeClientException e) {
LOG.error("While getting all validators", e);
}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/TaskRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/TaskRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/TaskRestClient.java
index 541b5cd..be4976e 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/TaskRestClient.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/rest/TaskRestClient.java
@@ -19,7 +19,7 @@
package org.apache.syncope.client.console.rest;
import java.util.List;
-import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.client.console.SyncopeConsoleSession;
import org.apache.syncope.common.lib.to.AbstractTaskTO;
import org.apache.syncope.common.lib.to.BulkAction;
import org.apache.syncope.common.lib.to.BulkActionResult;
@@ -42,15 +42,15 @@ public class TaskRestClient extends BaseRestClient implements ExecutionRestClien
private static final long serialVersionUID = 6284485820911028843L;
public List<String> getJobClasses() {
- return SyncopeSession.get().getSyncopeTO().getTaskJobs();
+ return SyncopeConsoleSession.get().getSyncopeTO().getTaskJobs();
}
public List<String> getSyncActionsClasses() {
- return SyncopeSession.get().getSyncopeTO().getSyncActions();
+ return SyncopeConsoleSession.get().getSyncopeTO().getSyncActions();
}
public List<String> getPushActionsClasses() {
- return SyncopeSession.get().getSyncopeTO().getPushActions();
+ return SyncopeConsoleSession.get().getSyncopeTO().getPushActions();
}
/**
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/UserRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/UserRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/UserRestClient.java
index bca0e28..cb30536 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/UserRestClient.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/rest/UserRestClient.java
@@ -18,6 +18,7 @@
*/
package org.apache.syncope.client.console.rest;
+import java.util.Collections;
import java.util.List;
import javax.ws.rs.core.Response;
import org.apache.syncope.client.console.commons.status.StatusBean;
@@ -49,13 +50,14 @@ public class UserRestClient extends AbstractSubjectRestClient {
private static final long serialVersionUID = -1575748964398293968L;
@Override
- public int count() {
- return getService(UserService.class).list(1, 1).getTotalCount();
+ public int count(final String realm) {
+ return getService(UserService.class).list(Collections.singletonList(realm), 1, 1).getTotalCount();
}
@Override
- public List<UserTO> list(final int page, final int size, final SortParam<String> sort) {
- return getService(UserService.class).list(page, size, toOrderBy(sort)).getResult();
+ public List<UserTO> list(final String realm, final int page, final int size, final SortParam<String> sort) {
+ return getService(UserService.class).
+ list(Collections.singletonList(realm), page, size, toOrderBy(sort)).getResult();
}
public UserTO create(final UserTO userTO, final boolean storePassword) {
@@ -95,13 +97,16 @@ public class UserRestClient extends AbstractSubjectRestClient {
}
@Override
- public int searchCount(final String fiql) {
- return getService(UserService.class).search(fiql, 1, 1).getTotalCount();
+ public int searchCount(final String realm, final String fiql) {
+ return getService(UserService.class).search(Collections.singletonList(realm), fiql, 1, 1).getTotalCount();
}
@Override
- public List<UserTO> search(final String fiql, final int page, final int size, final SortParam<String> sort) {
- return getService(UserService.class).search(fiql, page, size, toOrderBy(sort)).getResult();
+ public List<UserTO> search(
+ final String realm, final String fiql, final int page, final int size, final SortParam<String> sort) {
+
+ return getService(UserService.class).
+ search(Collections.singletonList(realm), fiql, page, size, toOrderBy(sort)).getResult();
}
@Override
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/UserSelfRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/UserSelfRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/UserSelfRestClient.java
index 1bb1079..13e1555 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/UserSelfRestClient.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/rest/UserSelfRestClient.java
@@ -18,7 +18,7 @@
*/
package org.apache.syncope.client.console.rest;
-import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.client.console.SyncopeConsoleSession;
import org.apache.syncope.common.lib.SyncopeClientException;
import org.apache.syncope.common.lib.mod.UserMod;
import org.apache.syncope.common.lib.to.UserTO;
@@ -33,7 +33,7 @@ public class UserSelfRestClient extends BaseRestClient {
public boolean isSelfRegistrationAllowed() {
Boolean result = null;
try {
- result = SyncopeSession.get().getSyncopeTO().isSelfRegAllowed();
+ result = SyncopeConsoleSession.get().getSyncopeTO().isSelfRegAllowed();
} catch (SyncopeClientException e) {
LOG.error("While seeking if self registration is allowed", e);
}
@@ -44,7 +44,7 @@ public class UserSelfRestClient extends BaseRestClient {
}
public UserTO read() {
- return getService(UserSelfService.class).read();
+ return SyncopeConsoleSession.get().getSelfTO();
}
public void create(final UserTO userTO, final boolean storePassword) {
@@ -62,7 +62,7 @@ public class UserSelfRestClient extends BaseRestClient {
public boolean isPasswordResetAllowed() {
Boolean result = null;
try {
- result = SyncopeSession.get().getSyncopeTO().isPwdResetAllowed();
+ result = SyncopeConsoleSession.get().getSyncopeTO().isPwdResetAllowed();
} catch (SyncopeClientException e) {
LOG.error("While seeking if password reset is allowed", e);
}
@@ -75,7 +75,7 @@ public class UserSelfRestClient extends BaseRestClient {
public boolean isPwdResetRequiringSecurityQuestions() {
Boolean result = null;
try {
- result = SyncopeSession.get().getSyncopeTO().isPwdResetRequiringSecurityQuestions();
+ result = SyncopeConsoleSession.get().getSyncopeTO().isPwdResetRequiringSecurityQuestions();
} catch (SyncopeClientException e) {
LOG.error("While seeking if password reset requires security question", e);
}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/WorkflowRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/WorkflowRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/WorkflowRestClient.java
index f3bf60c..eb0527e 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/WorkflowRestClient.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/rest/WorkflowRestClient.java
@@ -23,7 +23,7 @@ import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.Response;
import org.apache.cxf.helpers.IOUtils;
import org.apache.cxf.jaxrs.client.WebClient;
-import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.client.console.SyncopeConsoleSession;
import org.apache.syncope.common.lib.types.SubjectType;
import org.apache.syncope.common.rest.api.RESTHeaders;
import org.apache.syncope.common.rest.api.service.WorkflowService;
@@ -35,7 +35,7 @@ public class WorkflowRestClient extends BaseRestClient {
private static final long serialVersionUID = 5049285686167071017L;
private WorkflowService getService(final MediaType mediaType) {
- return SyncopeSession.get().getService(mediaType, WorkflowService.class);
+ return SyncopeConsoleSession.get().getService(mediaType, WorkflowService.class);
}
public InputStream getDefinition(final MediaType mediaType) {
@@ -60,7 +60,7 @@ public class WorkflowRestClient extends BaseRestClient {
}
public boolean isActivitiEnabledForUsers() {
- return SyncopeSession.get().getSyncopeTO().getUserWorkflowAdapter().indexOf("Activiti") != -1;
+ return SyncopeConsoleSession.get().getSyncopeTO().getUserWorkflowAdapter().contains("Activiti");
}
public void updateDefinition(final MediaType mediaType, final String definition) {
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/ajax/form/AbstractAjaxDownloadBehavior.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/ajax/form/AbstractAjaxDownloadBehavior.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/ajax/form/AbstractAjaxDownloadBehavior.java
deleted file mode 100644
index 8074d37..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/ajax/form/AbstractAjaxDownloadBehavior.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.ajax.form;
-
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.behavior.AbstractAjaxBehavior;
-import org.apache.wicket.request.handler.resource.ResourceStreamRequestHandler;
-import org.apache.wicket.util.resource.IResourceStream;
-
-public abstract class AbstractAjaxDownloadBehavior extends AbstractAjaxBehavior {
-
- private static final long serialVersionUID = 6833760760338614245L;
-
- /**
- * Call this method to initiate the download.
- */
- public void initiate(final AjaxRequestTarget target) {
- CharSequence url = getCallbackUrl();
-
- target.appendJavaScript("window.location.href='" + url + "'");
- }
-
- @Override
- public void onRequest() {
- getComponent().getRequestCycle().scheduleRequestHandlerAfterCurrent(
- new ResourceStreamRequestHandler(getResourceStream(), getFileName()));
- }
-
- protected abstract String getFileName();
-
- protected abstract IResourceStream getResourceStream();
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/ClearIndicatingAjaxButton.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/ClearIndicatingAjaxButton.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/ClearIndicatingAjaxButton.java
deleted file mode 100644
index 314f66c..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/ClearIndicatingAjaxButton.java
+++ /dev/null
@@ -1,76 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.ajax.markup.html;
-
-import org.apache.syncope.client.console.pages.BasePage;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.IModel;
-
-public abstract class ClearIndicatingAjaxButton extends IndicatingAjaxButton {
-
- private static final long serialVersionUID = 7206379812788748287L;
-
- private final PageReference pageRef;
-
- private boolean reloadFeebackPanel = true;
-
- public ClearIndicatingAjaxButton(final String id, final PageReference pageRef) {
- super(id);
- this.pageRef = pageRef;
- }
-
- public ClearIndicatingAjaxButton(final String id, Form<?> form, final PageReference pageRef) {
- super(id, form);
- this.pageRef = pageRef;
- }
-
- public ClearIndicatingAjaxButton(final String id, IModel<String> model, final PageReference pageRef) {
- super(id, model);
- this.pageRef = pageRef;
- }
-
- public ClearIndicatingAjaxButton(final String id, final IModel<String> model, final Form<?> form,
- final PageReference pageRef) {
-
- super(id, model, form);
- this.pageRef = pageRef;
- }
-
- protected abstract void onSubmitInternal(AjaxRequestTarget target, Form<?> form);
-
- public ClearIndicatingAjaxButton feedbackPanelAutomaticReload(boolean reloadFeedbackPanel) {
- this.reloadFeebackPanel = reloadFeedbackPanel;
- return this;
- }
-
- @Override
- protected final void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- super.onSubmit(target, form);
-
- Page page = pageRef.getPage();
- if (reloadFeebackPanel && page instanceof BasePage) {
- target.add(((BasePage) page).getFeedbackPanel());
- }
- onSubmitInternal(target, form);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/ClearIndicatingAjaxLink.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/ClearIndicatingAjaxLink.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/ClearIndicatingAjaxLink.java
deleted file mode 100644
index 5bb5642..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/ClearIndicatingAjaxLink.java
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.ajax.markup.html;
-
-import org.apache.syncope.client.console.pages.BasePage;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
-import org.apache.wicket.model.IModel;
-
-public abstract class ClearIndicatingAjaxLink<T> extends IndicatingAjaxLink<T> {
-
- private static final long serialVersionUID = 7913625094362339643L;
-
- private final PageReference pageRef;
-
- private boolean reloadFeedbackPanel = true;
-
- public ClearIndicatingAjaxLink(final String id, final PageReference pageRef) {
- super(id);
- this.pageRef = pageRef;
- }
-
- public ClearIndicatingAjaxLink(final String id, final IModel<T> model, final PageReference pageRef) {
- super(id, model);
- this.pageRef = pageRef;
- }
-
- public ClearIndicatingAjaxLink<T> feedbackPanelAutomaticReload(boolean reloadFeedbackPanel) {
- this.reloadFeedbackPanel = reloadFeedbackPanel;
- return this;
- }
-
- protected abstract void onClickInternal(AjaxRequestTarget target);
-
- @Override
- public final void onClick(final AjaxRequestTarget target) {
- Page page = pageRef.getPage();
- if (reloadFeedbackPanel && page instanceof BasePage) {
- target.add(((BasePage) page).getFeedbackPanel());
- }
- onClickInternal(target);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/IndicatingOnConfirmAjaxLink.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/IndicatingOnConfirmAjaxLink.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/IndicatingOnConfirmAjaxLink.java
deleted file mode 100644
index 86db915..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/IndicatingOnConfirmAjaxLink.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.ajax.markup.html;
-
-import org.apache.wicket.Component;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.attributes.AjaxCallListener;
-import org.apache.wicket.ajax.attributes.AjaxRequestAttributes;
-
-public abstract class IndicatingOnConfirmAjaxLink<T> extends ClearIndicatingAjaxLink<T> {
-
- private static final long serialVersionUID = 2228670850922265663L;
-
- private final String msg;
-
- public IndicatingOnConfirmAjaxLink(final String id, final PageReference pageRef) {
- this(id, pageRef, "confirmDelete");
- }
-
- public IndicatingOnConfirmAjaxLink(final String id, final PageReference pageRef, final String msg) {
- super(id, pageRef);
- this.msg = msg;
- }
-
- @Override
- protected void updateAjaxAttributes(final AjaxRequestAttributes attributes) {
- super.updateAjaxAttributes(attributes);
-
- final AjaxCallListener ajaxCallListener = new AjaxCallListener() {
-
- private static final long serialVersionUID = 7160235486520935153L;
-
- @Override
- public CharSequence getPrecondition(final Component component) {
- return "if (!confirm('"
- + getString(IndicatingOnConfirmAjaxLink.this.msg)
- + "')) {return false;} else {return true;}";
- }
- };
- attributes.getAjaxCallListeners().add(ajaxCallListener);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/ActionColumn.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/ActionColumn.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/ActionColumn.java
deleted file mode 100644
index b9dfa62..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/ActionColumn.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
-
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.wicket.Component;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.IModel;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-public abstract class ActionColumn<T, S> extends AbstractColumn<T, S> {
-
- private static final long serialVersionUID = 7955560320949560725L;
-
- /**
- * Logger.
- */
- protected static final Logger LOG = LoggerFactory.getLogger(ActionColumn.class);
-
- public ActionColumn(final IModel<String> displayModel) {
- super(displayModel);
- }
-
- @Override
- public String getCssClass() {
- return "action";
- }
-
- @Override
- public Component getHeader(final String componentId) {
- return super.getHeader(componentId);
- }
-
- @Override
- public void populateItem(final Item<ICellPopulator<T>> item, final String componentId, final IModel<T> rowModel) {
- item.add(getActions(componentId, rowModel));
- }
-
- public abstract ActionLinksPanel getActions(final String componentId, final IModel<T> rowModel);
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/ActionResultColumn.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/ActionResultColumn.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/ActionResultColumn.java
deleted file mode 100644
index a2c40ff..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/ActionResultColumn.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
-
-import java.beans.PropertyDescriptor;
-import org.apache.syncope.common.lib.to.BulkActionResult;
-import org.apache.syncope.common.lib.to.BulkActionResult.Status;
-import org.apache.wicket.Component;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.ResourceModel;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.springframework.beans.BeanUtils;
-
-public class ActionResultColumn<T, S> extends AbstractColumn<T, S> {
-
- private static final long serialVersionUID = 7955560320949560716L;
-
- /**
- * Logger.
- */
- private static final Logger LOG = LoggerFactory.getLogger(ActionResultColumn.class);
-
- private final BulkActionResult results;
-
- private final String idFieldName;
-
- public ActionResultColumn(final BulkActionResult results, final String idFieldName) {
- super(new Model<String>());
- this.results = results;
- this.idFieldName = idFieldName;
- }
-
- @Override
- public String getCssClass() {
- return "bulkResultColumn";
- }
-
- @Override
- public Component getHeader(final String componentId) {
- return new Label(componentId, new ResourceModel("bulkActionResultLabel", "Result"));
- }
-
- @Override
- public void populateItem(final Item<ICellPopulator<T>> item, final String componentId, final IModel<T> rowModel) {
- try {
- final PropertyDescriptor propDesc =
- BeanUtils.getPropertyDescriptor(rowModel.getObject().getClass(), idFieldName);
- final Object id = propDesc.getReadMethod().invoke(rowModel.getObject(), new Object[0]);
- final Status status = id == null ? null : results.getResultMap().get(id.toString());
- item.add(new Label(componentId, status == null ? Status.SUCCESS : status.toString()));
- } catch (Exception e) {
- LOG.error("Errore retrieving target id value", e);
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/AttrColumn.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/AttrColumn.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/AttrColumn.java
deleted file mode 100644
index b40d7c8..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/AttrColumn.java
+++ /dev/null
@@ -1,85 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
-
-import java.util.List;
-import org.apache.syncope.common.lib.to.AbstractAttributableTO;
-import org.apache.syncope.common.lib.types.SchemaType;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.ResourceModel;
-
-public class AttrColumn extends AbstractColumn<AbstractAttributableTO, String> {
-
- private static final long serialVersionUID = 2624734332447371372L;
-
- private final String name;
-
- private final SchemaType schemaType;
-
- public AttrColumn(final String name, final SchemaType schemaType) {
- // set sortProperty to schematype#name (e.g. derivedSchema#cn,
- // for use with SortableUserProviderComparator.AttrModel#getObject)
- super(new ResourceModel(name, name), schemaType.name() + "#" + name);
- this.name = name;
- this.schemaType = schemaType;
- }
-
- @Override
- public void populateItem(final Item<ICellPopulator<AbstractAttributableTO>> cellItem, final String componentId,
- final IModel<AbstractAttributableTO> rowModel) {
-
- List<String> values = null;
-
- switch (schemaType) {
- case PLAIN:
- if (rowModel.getObject().getPlainAttrMap().containsKey(name)) {
- values = rowModel.getObject().getPlainAttrMap().get(name).getValues();
- }
- break;
-
- case VIRTUAL:
- if (rowModel.getObject().getVirAttrMap().containsKey(name)) {
- values = rowModel.getObject().getVirAttrMap().get(name).getValues();
- }
- break;
-
- case DERIVED:
- if (rowModel.getObject().getDerAttrMap().containsKey(name)) {
- values = rowModel.getObject().getDerAttrMap().get(name).getValues();
- }
- break;
-
- default:
- }
-
- if (values == null || values.isEmpty()) {
- cellItem.add(new Label(componentId, ""));
- } else {
- if (values.size() == 1) {
- cellItem.add(new Label(componentId, values.get(0)));
- } else {
- cellItem.add(new Label(componentId, values.toString()));
- }
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxGroupSelectorPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxGroupSelectorPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxGroupSelectorPanel.java
deleted file mode 100644
index 8f880b7..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxGroupSelectorPanel.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
-
-import org.apache.wicket.markup.html.form.CheckGroup;
-import org.apache.wicket.markup.html.form.CheckGroupSelector;
-import org.apache.wicket.markup.html.panel.Panel;
-
-public class CheckBoxGroupSelectorPanel<T> extends Panel {
-
- private static final long serialVersionUID = 4062106303929176865L;
-
- public CheckBoxGroupSelectorPanel(final String componentId, final CheckGroup<T> group) {
-
- super(componentId);
- add(new CheckGroupSelector("groupselector", group));
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxPanel.java
deleted file mode 100644
index db87192..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxPanel.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
-
-import org.apache.syncope.client.console.commons.ActionTableCheckGroup;
-import org.apache.wicket.markup.html.form.Check;
-import org.apache.wicket.markup.html.form.CheckGroup;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-
-public class CheckBoxPanel<T> extends Panel {
-
- private static final long serialVersionUID = 4062106303929176865L;
-
- private final Check<T> check;
-
- public CheckBoxPanel(final String componentId, final IModel<T> model, final CheckGroup<T> checkGroup) {
- super(componentId, model);
- this.check = new Check<T>("check", model, checkGroup);
- if (checkGroup instanceof ActionTableCheckGroup) {
- boolean checkable = ((ActionTableCheckGroup<T>) checkGroup).isCheckable(model.getObject());
- this.check.setEnabled(checkable);
- this.check.setVisible(checkable);
- }
- add(this.check);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckGroupColumn.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckGroupColumn.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckGroupColumn.java
deleted file mode 100644
index cf13f3c..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckGroupColumn.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
-
-import org.apache.wicket.Component;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
-import org.apache.wicket.markup.html.form.CheckGroup;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-
-public class CheckGroupColumn<T, S> extends AbstractColumn<T, S> {
-
- private static final long serialVersionUID = 7955560320949560715L;
-
- private final CheckGroup<T> group;
-
- public CheckGroupColumn(final CheckGroup<T> checkGroup) {
- super(new Model<String>());
- this.group = checkGroup;
- }
-
- @Override
- public String getCssClass() {
- return "checkGroupColumn";
- }
-
- @Override
- public Component getHeader(final String componentId) {
- return new CheckBoxGroupSelectorPanel<T>(componentId, group);
- }
-
- @Override
- public void populateItem(final Item<ICellPopulator<T>> item, final String componentId, final IModel<T> rowModel) {
- item.add(new CheckBoxPanel<T>(componentId, rowModel, group));
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPanel.java
deleted file mode 100644
index f04fa5a..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPanel.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
-
-import java.util.List;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.ResourceModel;
-
-public class CollectionPanel extends Panel {
-
- private static final long serialVersionUID = -4042497356836230377L;
-
- @SuppressWarnings("unchecked")
- public CollectionPanel(final String id, final List values) {
- super(id);
-
- add(new ListView("collection", values) {
-
- private static final long serialVersionUID = 4949588177564901031L;
-
- @Override
- protected void populateItem(final ListItem item) {
- final String value = item.getModelObject() == null ? null : item.getModelObject().toString();
- item.add(new Label("item", new ResourceModel(value, value)));
- }
- });
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPropertyColumn.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPropertyColumn.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPropertyColumn.java
deleted file mode 100644
index a5fd774..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPropertyColumn.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.List;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.IModel;
-
-public class CollectionPropertyColumn<T> extends PropertyColumn<T, String> {
-
- private static final long serialVersionUID = 8077865338230121496L;
-
- public CollectionPropertyColumn(
- final IModel<String> displayModel,
- final String sortProperty,
- final String propertyExpression) {
- super(displayModel, sortProperty, propertyExpression);
- }
-
- @Override
- @SuppressWarnings("unchecked")
- public void populateItem(
- final Item<ICellPopulator<T>> cellItem, final String componentId, final IModel<T> rowModel) {
-
- final Object value = getDataModel(rowModel).getObject();
-
- if (value instanceof Collection) {
- final List values = new ArrayList((Collection) value);
- Collections.sort(values);
- cellItem.add(new CollectionPanel(componentId, values));
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/DatePropertyColumn.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/DatePropertyColumn.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/DatePropertyColumn.java
deleted file mode 100644
index f767aa2..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/DatePropertyColumn.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
-
-import java.util.Date;
-import org.apache.syncope.client.console.SyncopeSession;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.IModel;
-
-/**
- * Format column's value as date string.
- */
-public class DatePropertyColumn<T> extends PropertyColumn<T, String> {
-
- private static final long serialVersionUID = 3527840552172947705L;
-
- public DatePropertyColumn(final IModel<String> displayModel, final String sortProperty,
- final String propertyExpression) {
-
- super(displayModel, sortProperty, propertyExpression);
- }
-
- @Override
- public void populateItem(final Item<ICellPopulator<T>> item, final String componentId, final IModel<T> rowModel) {
-
- IModel<Object> date = getDataModel(rowModel);
-
- String convertedDate = "";
- if (date.getObject() instanceof Date) {
- convertedDate = SyncopeSession.get().getDateFormat().format(date.getObject());
- }
- item.add(new Label(componentId, convertedDate));
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/TokenColumn.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/TokenColumn.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/TokenColumn.java
deleted file mode 100644
index 094e450..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/TokenColumn.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
-
-import org.apache.syncope.common.lib.to.AbstractAttributableTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.ResourceModel;
-import org.springframework.util.StringUtils;
-
-public class TokenColumn extends AbstractColumn<AbstractAttributableTO, String> {
-
- private static final long serialVersionUID = 8077865338230121496L;
-
- public TokenColumn(final String name) {
- super(new ResourceModel(name, name), name);
- }
-
- @Override
- public void populateItem(final Item<ICellPopulator<AbstractAttributableTO>> cellItem, final String componentId,
- final IModel<AbstractAttributableTO> rowModel) {
-
- if (rowModel.getObject() instanceof UserTO) {
- if (StringUtils.hasText(((UserTO) rowModel.getObject()).getToken())) {
- cellItem.add(new Label(componentId, new ResourceModel("tokenValued", "tokenValued")));
- } else {
- cellItem.add(new Label(componentId, new ResourceModel("tokenNotValued", "tokenNotValued")));
- }
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer.java
deleted file mode 100644
index 5555616..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer.java
+++ /dev/null
@@ -1,184 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.markup.html;
-
-import java.util.Arrays;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.SelectChoiceRenderer;
-import org.apache.syncope.client.console.commons.SelectOption;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.FormComponent;
-import org.apache.wicket.markup.html.form.TextField;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-
-public class CrontabContainer extends WebMarkupContainer {
-
- private static final long serialVersionUID = 7879593326085337650L;
-
- private final TextField seconds;
-
- private final TextField minutes;
-
- private final TextField hours;
-
- private final TextField daysOfMonth;
-
- private final TextField months;
-
- private final TextField daysOfWeek;
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- public CrontabContainer(final String id, final PropertyModel<String> cronExpressionModel,
- final String cronExpression) {
-
- super(id);
- setOutputMarkupId(true);
-
- final SelectOption[] CRON_TEMPLATES = {
- new SelectOption(getString("selOpt1"), "UNSCHEDULE"),
- new SelectOption(getString("selOpt2"), "0 0/5 * * * ?"),
- new SelectOption(getString("selOpt3"), "0 0 12 * * ?"),
- new SelectOption(getString("selOpt4"), "0 0 0 1 * ?"),
- new SelectOption(getString("selOpt5"), "0 0 0 L * ?"),
- new SelectOption(getString("selOpt6"), "0 0 0 ? * 2")
- };
-
- final DropDownChoice<SelectOption> cronTemplateChooser =
- new DropDownChoice<SelectOption>("cronTemplateChooser") {
-
- private static final long serialVersionUID = -5843424545478691442L;
-
- @Override
- protected CharSequence getDefaultChoice(final String selected) {
- return "<option value=\"\">" + getString("chooseForTemplate") + "</option>";
- }
- };
-
- cronTemplateChooser.setModel(new IModel<SelectOption>() {
-
- private static final long serialVersionUID = 6762568283146531315L;
-
- @Override
- public SelectOption getObject() {
- SelectOption result = null;
- for (SelectOption so : CRON_TEMPLATES) {
- if (so.getKeyValue().equals(cronExpressionModel.getObject())) {
-
- result = so;
- }
- }
-
- return result;
- }
-
- @Override
- public void setObject(final SelectOption object) {
- cronExpressionModel.setObject(object == null || object.equals(CRON_TEMPLATES[0])
- ? null
- : object.toString());
- }
-
- @Override
- public void detach() {
- // no detach
- }
- });
- cronTemplateChooser.setChoices(Arrays.asList(CRON_TEMPLATES));
- cronTemplateChooser.setChoiceRenderer(new SelectChoiceRenderer());
- add(cronTemplateChooser);
-
- seconds = new TextField("seconds", new Model(getCronField(cronExpression, 0)));
- add(seconds);
-
- minutes = new TextField("minutes", new Model(getCronField(cronExpression, 1)));
- add(minutes);
-
- hours = new TextField("hours", new Model(getCronField(cronExpression, 2)));
- add(hours);
-
- daysOfMonth = new TextField("daysOfMonth", new Model(getCronField(cronExpression, 3)));
- add(daysOfMonth);
-
- months = new TextField("months", new Model(getCronField(cronExpression, 4)));
- add(months);
-
- daysOfWeek = new TextField("daysOfWeek", new Model(getCronField(cronExpression, 5)));
- add(daysOfWeek);
-
- cronTemplateChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- seconds.setModelObject(getCronField(cronTemplateChooser, 0));
- minutes.setModelObject(getCronField(cronTemplateChooser, 1));
- hours.setModelObject(getCronField(cronTemplateChooser, 2));
- daysOfMonth.setModelObject(getCronField(cronTemplateChooser, 3));
- months.setModelObject(getCronField(cronTemplateChooser, 4));
- daysOfWeek.setModelObject(getCronField(cronTemplateChooser, 5));
- target.add(CrontabContainer.this);
- }
- });
- }
-
- private String getCronField(final FormComponent formComponent, final int field) {
- String cronField = null;
-
- if (formComponent != null) {
- cronField = getCronField(formComponent.getInput(), field);
- }
-
- return cronField;
- }
-
- private String getCronField(final String cron, final int field) {
- String cronField = null;
-
- if (cron != null && !cron.isEmpty() && !"UNSCHEDULE".equals(cron)) {
- cronField = cron.split(" ")[field].trim();
- }
-
- return cronField;
- }
-
- public String getCronExpression() {
- String cronExpression = null;
-
- if (seconds != null && seconds.getInput() != null && minutes != null && minutes.getInput() != null
- && hours != null && hours.getInput() != null && daysOfMonth != null && daysOfMonth.getInput() != null
- && months != null && months.getInput() != null && daysOfWeek != null && daysOfWeek.getInput() != null) {
-
- cronExpression = new StringBuilder().
- append(seconds.getInput().trim()).append(" ").
- append(minutes.getInput().trim()).append(" ").
- append(hours.getInput().trim()).append(" ").
- append(daysOfMonth.getInput().trim()).append(" ").
- append(months.getInput().trim()).append(" ").
- append(daysOfWeek.getInput().trim()).toString();
- }
-
- return cronExpression;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/ActionLink.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/ActionLink.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/ActionLink.java
deleted file mode 100644
index 3e7cc44..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/ActionLink.java
+++ /dev/null
@@ -1,83 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.markup.html.form;
-
-import java.io.Serializable;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-
-public abstract class ActionLink implements Serializable {
-
- private static final long serialVersionUID = 7031329706998320639L;
-
- private boolean reloadFeedbackPanel = true;
-
- public enum ActionType {
-
- CREATE("create"),
- EDIT("read"),
- USER_TEMPLATE("read"),
- GROUP_TEMPLATE("read"),
- RESET("update"),
- ENABLE("update"),
- SEARCH("read"),
- DELETE("delete"),
- EXECUTE("execute"),
- DRYRUN("execute"),
- CLAIM("claim"),
- SELECT("read"),
- EXPORT("read"),
- SUSPEND("update"),
- REACTIVATE("update"),
- RELOAD("reload"),
- CHANGE_VIEW("changeView"),
- UNLINK("update"),
- LINK("update"),
- UNASSIGN("update"),
- ASSIGN("update"),
- DEPROVISION("update"),
- PROVISION("update"),
- MANAGE_RESOURCES("update"),
- MANAGE_USERS("update"),
- MANAGE_GROUPS("update");
-
- private final String actionId;
-
- private ActionType(final String actionId) {
- this.actionId = actionId;
- }
-
- public String getActionId() {
- return actionId;
- }
- }
-
- public abstract void onClick(final AjaxRequestTarget target);
-
- public void postClick() {
- }
-
- public boolean feedbackPanelAutomaticReload() {
- return reloadFeedbackPanel;
- }
-
- public ActionLink feedbackPanelAutomaticReload(final boolean reloadFeedbackPanel) {
- this.reloadFeedbackPanel = reloadFeedbackPanel;
- return this;
- }
-}
[39/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/PoliciesPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/PoliciesPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/PoliciesPanel.java
deleted file mode 100644
index 4d66eda..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/PoliciesPanel.java
+++ /dev/null
@@ -1,343 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.PreferenceManager;
-import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
-import org.apache.syncope.client.console.commons.XMLRolesReader;
-import org.apache.syncope.client.console.pages.BasePage;
-import org.apache.syncope.client.console.pages.PolicyModalPage;
-import org.apache.syncope.client.console.rest.PolicyRestClient;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.AbstractPolicyTO;
-import org.apache.syncope.common.lib.to.AccountPolicyTO;
-import org.apache.syncope.common.lib.to.PasswordPolicyTO;
-import org.apache.syncope.common.lib.to.SyncPolicyTO;
-import org.apache.syncope.common.lib.types.PolicyType;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.request.http.WebResponse;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-public class PoliciesPanel extends Panel {
-
- /**
- * Logger.
- */
- private static final Logger LOG = LoggerFactory.getLogger(PoliciesPanel.class);
-
- private static final int MODAL_WIN_HEIGHT = 400;
-
- private static final int MODAL_WIN_WIDTH = 1000;
-
- private static final long serialVersionUID = -6804066913177804275L;
-
- @SpringBean
- private PolicyRestClient policyRestClient;
-
- @SpringBean
- protected XMLRolesReader xmlRolesReader;
-
- @SpringBean
- private PreferenceManager prefMan;
-
- private final PageReference pageRef;
-
- private final int paginatorRows = prefMan.getPaginatorRows(getWebRequest(), Constants.PREF_POLICY_PAGINATOR_ROWS);
-
- protected boolean modalResult = false;
-
- private final PolicyType policyType;
-
- public PoliciesPanel(final String id, final PageReference pageRef, final PolicyType policyType) {
- super(id);
- this.pageRef = pageRef;
- this.policyType = policyType;
-
- // Modal window for editing user attributes
- final ModalWindow mwindow = new ModalWindow("editModalWin");
- mwindow.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- mwindow.setInitialHeight(MODAL_WIN_HEIGHT);
- mwindow.setInitialWidth(MODAL_WIN_WIDTH);
- mwindow.setCookieName("policy-modal");
- add(mwindow);
-
- // Container for user list
- final WebMarkupContainer container = new WebMarkupContainer("container");
- container.setOutputMarkupId(true);
- add(container);
-
- setWindowClosedCallback(mwindow, container);
-
- final List<IColumn<AbstractPolicyTO, String>> columns = new ArrayList<>();
-
- columns.add(new PropertyColumn<AbstractPolicyTO, String>(new ResourceModel("key"), "key", "key"));
-
- columns.add(new PropertyColumn<AbstractPolicyTO, String>(
- new ResourceModel("description"), "description", "description"));
-
- columns.add(new AbstractColumn<AbstractPolicyTO, String>(new ResourceModel("type")) {
-
- private static final long serialVersionUID = 8263694778917279290L;
-
- @Override
- public void populateItem(final Item<ICellPopulator<AbstractPolicyTO>> cellItem, final String componentId,
- final IModel<AbstractPolicyTO> model) {
-
- cellItem.add(new Label(componentId, getString(model.getObject().getType().name())));
- }
- });
-
- columns.add(new AbstractColumn<AbstractPolicyTO, String>(new ResourceModel("actions", "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public String getCssClass() {
- return "action";
- }
-
- @Override
- public void populateItem(final Item<ICellPopulator<AbstractPolicyTO>> cellItem, final String componentId,
- final IModel<AbstractPolicyTO> model) {
-
- final AbstractPolicyTO policyTO = model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, pageRef);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
-
- mwindow.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- @Override
- public Page createPage() {
- return new PolicyModalPage(pageRef, mwindow, policyTO);
- }
- });
-
- mwindow.show(target);
- }
- }, ActionLink.ActionType.EDIT, "Policies");
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- policyRestClient.delete(policyTO.getKey(), policyTO.getClass());
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException e) {
- error(getString(Constants.OPERATION_ERROR));
-
- LOG.error("While deleting policy {}({})",
- policyTO.getKey(), policyTO.getDescription(), e);
- }
-
- target.add(container);
- ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
- }
- }, ActionLink.ActionType.DELETE, "Policies");
-
- cellItem.add(panel);
- }
- });
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- final AjaxFallbackDefaultDataTable table = new AjaxFallbackDefaultDataTable("datatable", columns,
- new PolicyDataProvider(), paginatorRows);
-
- container.add(table);
-
- final AjaxLink<Void> createButton = new ClearIndicatingAjaxLink<Void>("createLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- mwindow.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- @Override
- public Page createPage() {
- return new PolicyModalPage(pageRef, mwindow, getPolicyTOInstance(policyType));
- }
- });
-
- mwindow.show(target);
- }
- };
-
- add(createButton);
-
- MetaDataRoleAuthorizationStrategy.authorize(
- createButton, ENABLE, xmlRolesReader.getEntitlement("Policies", "create"));
-
- @SuppressWarnings("rawtypes")
- final Form paginatorForm = new Form("PaginatorForm");
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- final DropDownChoice rowsChooser = new DropDownChoice("rowsChooser", new PropertyModel(this, "paginatorRows"),
- prefMan.getPaginatorChoices());
-
- rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- prefMan.set(getWebRequest(), (WebResponse) getResponse(), Constants.PREF_POLICY_PAGINATOR_ROWS, String
- .valueOf(paginatorRows));
- table.setItemsPerPage(paginatorRows);
-
- target.add(container);
- }
- });
-
- paginatorForm.add(rowsChooser);
- add(paginatorForm);
- }
-
- private void setWindowClosedCallback(final ModalWindow window, final WebMarkupContainer container) {
- window.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
-
- private static final long serialVersionUID = 8804221891699487139L;
-
- @Override
- public void onClose(final AjaxRequestTarget target) {
- target.add(container);
- BasePage configuration = ((BasePage) pageRef.getPage());
- if (configuration.isModalResult()) {
- info(getString(Constants.OPERATION_SUCCEEDED));
- configuration.getFeedbackPanel().refresh(target);
- configuration.setModalResult(false);
- }
- }
- });
- }
-
- private class PolicyDataProvider extends SortableDataProvider<AbstractPolicyTO, String> {
-
- private static final long serialVersionUID = -6976327453925166730L;
-
- private final SortableDataProviderComparator<AbstractPolicyTO> comparator;
-
- public PolicyDataProvider() {
- super();
-
- //Default sorting
- setSort("description", SortOrder.ASCENDING);
-
- comparator = new SortableDataProviderComparator<AbstractPolicyTO>(this);
- }
-
- @Override
- public long size() {
- return policyRestClient.getPolicies(policyType, true).size();
- }
-
- @Override
- public Iterator<AbstractPolicyTO> iterator(final long first, final long count) {
- final List<AbstractPolicyTO> policies = policyRestClient.getPolicies(policyType, true);
-
- Collections.sort(policies, comparator);
-
- return policies.subList((int) first, (int) first + (int) count).iterator();
- }
-
- @Override
- public IModel<AbstractPolicyTO> model(final AbstractPolicyTO object) {
- return new CompoundPropertyModel<AbstractPolicyTO>(object);
- }
- }
-
- private AbstractPolicyTO getPolicyTOInstance(final PolicyType policyType) {
- AbstractPolicyTO policyTO;
- switch (policyType) {
- case GLOBAL_ACCOUNT:
- policyTO = new AccountPolicyTO(true);
- break;
-
- case ACCOUNT:
- policyTO = new AccountPolicyTO();
- break;
-
- case GLOBAL_PASSWORD:
- policyTO = new PasswordPolicyTO(true);
- break;
-
- case PASSWORD:
- policyTO = new PasswordPolicyTO();
- break;
-
- case GLOBAL_SYNC:
- policyTO = new SyncPolicyTO(true);
- break;
-
- case SYNC:
- default:
- policyTO = new SyncPolicyTO();
- }
-
- return policyTO;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/PolicyBeanPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/PolicyBeanPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/PolicyBeanPanel.java
deleted file mode 100644
index a55be9f..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/PolicyBeanPanel.java
+++ /dev/null
@@ -1,340 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.beans.PropertyDescriptor;
-import java.io.Serializable;
-import java.lang.reflect.Field;
-import java.lang.reflect.Modifier;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.rest.PolicyRestClient;
-import org.apache.syncope.client.console.rest.SchemaRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AbstractFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPalettePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.FieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.SpinnerFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.list.AltListView;
-import org.apache.syncope.common.lib.annotation.ClassList;
-import org.apache.syncope.common.lib.annotation.SchemaList;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.syncope.common.lib.types.PolicySpec;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.model.util.ListModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.springframework.beans.BeanUtils;
-import org.springframework.util.ClassUtils;
-import org.springframework.util.ReflectionUtils;
-import org.springframework.util.ReflectionUtils.FieldCallback;
-import org.springframework.util.ReflectionUtils.FieldFilter;
-
-public class PolicyBeanPanel extends Panel {
-
- private static final long serialVersionUID = -3035998190456928143L;
-
- /**
- * Logger.
- */
- private static final Logger LOG = LoggerFactory.getLogger(PolicyBeanPanel.class);
-
- @SpringBean
- private SchemaRestClient schemaRestClient;
-
- @SpringBean
- private PolicyRestClient policyRestClient;
-
- final IModel<List<String>> userSchemas = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = -2012833443695917883L;
-
- @Override
- protected List<String> load() {
- return schemaRestClient.getPlainSchemaNames(AttributableType.USER);
- }
- };
-
- final IModel<List<String>> groupSchemas = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- return schemaRestClient.getPlainSchemaNames(AttributableType.GROUP);
- }
- };
-
- final IModel<List<String>> correlationRules = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- return policyRestClient.getCorrelationRuleClasses();
- }
- };
-
- public PolicyBeanPanel(final String id, final PolicySpec policy) {
- super(id);
-
- final List<FieldWrapper> items = new ArrayList<>();
- ReflectionUtils.doWithFields(policy.getClass(), new FieldCallback() {
-
- @Override
- public void doWith(final Field field) throws IllegalArgumentException, IllegalAccessException {
- FieldWrapper fieldWrapper = new FieldWrapper();
- fieldWrapper.setName(field.getName());
- fieldWrapper.setType(field.getType());
-
- final SchemaList schemaList = field.getAnnotation(SchemaList.class);
- fieldWrapper.setSchemaList(schemaList);
-
- final ClassList classList = field.getAnnotation(ClassList.class);
- fieldWrapper.setClassList(classList);
-
- items.add(fieldWrapper);
- }
- },
- new FieldFilter() {
-
- @Override
- public boolean matches(final Field field) {
- return !Modifier.isStatic(field.getModifiers()) && !"serialVersionUID".equals(field.getName());
- }
- });
-
- final ListView<FieldWrapper> policies = new AltListView<FieldWrapper>("policies", items) {
-
- private static final long serialVersionUID = 9101744072914090143L;
-
- @Override
- @SuppressWarnings({ "unchecked", "rawtypes" })
- protected void populateItem(final ListItem<FieldWrapper> item) {
- final FieldWrapper field = item.getModelObject();
-
- final PropertyDescriptor propDesc = BeanUtils.getPropertyDescriptor(policy.getClass(), field.getName());
-
- item.add(new Label("label", new ResourceModel(field.getName())));
-
- AbstractFieldPanel component;
- try {
- if (field.getClassList() != null) {
- component = new AjaxDropDownChoicePanel("field", field.getName(), new PropertyModel(policy,
- field.getName()));
-
- final List<String> rules = correlationRules.getObject();
-
- if (rules != null && !rules.isEmpty()) {
- ((AjaxDropDownChoicePanel) component).setChoices(correlationRules.getObject());
- }
-
- item.add(component);
-
- item.add(getActivationControl(
- component,
- propDesc.getReadMethod().invoke(policy, new Object[] {}) != null,
- null,
- null));
-
- } else if (field.getType().isEnum()) {
- component = new AjaxDropDownChoicePanel("field", field.getName(), new PropertyModel(policy,
- field.getName()));
-
- final Serializable[] values = (Serializable[]) field.getType().getEnumConstants();
-
- if (values != null && values.length > 0) {
- ((AjaxDropDownChoicePanel) component).setChoices(Arrays.asList(values));
- }
-
- item.add(component);
-
- item.add(getActivationControl(
- component,
- (Enum<?>) propDesc.getReadMethod().invoke(policy, new Object[] {}) != null,
- values[0],
- values[0]));
-
- } else if (ClassUtils.isAssignable(Boolean.class, field.getType())) {
- item.add(new AjaxCheckBoxPanel("check", field.getName(),
- new PropertyModel<Boolean>(policy, field.getName())));
-
- item.add(new Label("field", new Model(null)));
- } else if (Collection.class.isAssignableFrom(field.getType())) {
- if (field.getSchemaList() != null) {
- final List<String> values = new ArrayList<>();
- if (field.getName().charAt(0) == 'r') {
- values.addAll(groupSchemas.getObject());
-
- if (field.getSchemaList().extended()) {
- values.add("name");
- }
- } else {
- values.addAll(userSchemas.getObject());
-
- if (field.getSchemaList().extended()) {
- values.add("key");
- values.add("username");
- }
- }
-
- component = new AjaxPalettePanel("field", new PropertyModel(policy, field.getName()),
- new ListModel<>(values));
- item.add(component);
-
- Collection<?> collection = (Collection) propDesc.getReadMethod().invoke(policy);
- item.add(getActivationControl(component,
- !collection.isEmpty(), new ArrayList<String>(), new ArrayList<String>()));
- } else {
- final FieldPanel panel = new AjaxTextFieldPanel("panel", field.getName(),
- new Model<String>(null));
- panel.setRequired(true);
-
- component = new MultiFieldPanel<String>("field",
- new PropertyModel(policy, field.getName()), panel);
-
- item.add(component);
-
- final List<String> reinitializedValue = new ArrayList<String>();
-
- reinitializedValue.add("");
-
- item.add(getActivationControl(component,
- !((Collection) propDesc.getReadMethod().invoke(policy, new Object[] {})).isEmpty(),
- new ArrayList<String>(), (Serializable) reinitializedValue));
- }
- } else if (ClassUtils.isAssignable(Number.class, field.getType())) {
- component = new SpinnerFieldPanel<Number>("field", field.getName(),
- (Class<Number>) field.getType(), new PropertyModel<Number>(policy, field.getName()),
- null, null);
- item.add(component);
-
- item.add(getActivationControl(component,
- (Integer) propDesc.getReadMethod().invoke(policy, new Object[] {}) > 0, 0, 0));
- } else if (field.getType().equals(String.class)) {
- component = new AjaxTextFieldPanel("field", field.getName(),
- new PropertyModel(policy, field.getName()));
-
- item.add(component);
-
- item.add(getActivationControl(component,
- propDesc.getReadMethod().invoke(policy, new Object[] {}) != null, null, null));
- } else {
- item.add(new AjaxCheckBoxPanel("check", field.getName(), new Model()));
- item.add(new Label("field", new Model(null)));
- }
- } catch (Exception e) {
- LOG.error("Error retrieving policy fields", e);
- }
- }
- };
-
- add(policies);
- }
-
- private <T extends Serializable> AjaxCheckBoxPanel getActivationControl(final AbstractFieldPanel<T> panel,
- final Boolean checked, final T defaultModelObject, final T reinitializedValue) {
-
- final AjaxCheckBoxPanel check = new AjaxCheckBoxPanel("check", "check", new Model<Boolean>(checked));
-
- panel.setEnabled(checked);
-
- check.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- if (check.getModelObject()) {
- panel.setEnabled(true);
- panel.setModelObject(reinitializedValue);
- } else {
- panel.setModelObject(defaultModelObject);
- panel.setEnabled(false);
- }
-
- target.add(panel);
- }
- });
-
- return check;
- }
-
- private static class FieldWrapper implements Serializable {
-
- private static final long serialVersionUID = -6770429509752964215L;
-
- private Class<?> type;
-
- private String name;
-
- private transient SchemaList schemaList;
-
- private transient ClassList classList;
-
- public String getName() {
- return name;
- }
-
- public void setName(final String name) {
- this.name = name;
- }
-
- public Class<?> getType() {
- return type;
- }
-
- public void setType(final Class<?> type) {
- this.type = type;
- }
-
- public SchemaList getSchemaList() {
- return schemaList;
- }
-
- public void setSchemaList(final SchemaList schemaList) {
- this.schemaList = schemaList;
- }
-
- public ClassList getClassList() {
- return classList;
- }
-
- public void setClassList(ClassList classList) {
- this.classList = classList;
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/PropagationTasks.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/PropagationTasks.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/PropagationTasks.java
deleted file mode 100644
index 41fdb03..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/PropagationTasks.java
+++ /dev/null
@@ -1,264 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.pages.PropagationTaskModalPage;
-import org.apache.syncope.client.console.pages.Tasks;
-import org.apache.syncope.client.console.pages.Tasks.TasksProvider;
-import org.apache.syncope.client.console.panels.AbstractSearchResultPanel.EventDataWrapper;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.AbstractTaskTO;
-import org.apache.syncope.common.lib.to.PropagationTaskTO;
-import org.apache.wicket.Component;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.StringResourceModel;
-import org.apache.wicket.request.http.WebResponse;
-
-/**
- * Tasks page.
- */
-public class PropagationTasks extends AbstractTasks {
-
- private static final long serialVersionUID = 4984337552918213290L;
-
- private int paginatorRows;
-
- private WebMarkupContainer container;
-
- private boolean operationResult = false;
-
- private ModalWindow window;
-
- private AjaxDataTablePanel<AbstractTaskTO, String> table;
-
- public PropagationTasks(final String id, final PageReference pageRef) {
- super(id, pageRef);
-
- container = new WebMarkupContainer("container");
- container.setOutputMarkupId(true);
- add(container);
-
- add(window = new ModalWindow("taskWin"));
-
- paginatorRows = prefMan.getPaginatorRows(getWebRequest(), Constants.PREF_PROPAGATION_TASKS_PAGINATOR_ROWS);
-
- table = Tasks.updateTaskTable(
- getColumns(),
- new TasksProvider<PropagationTaskTO>(restClient, paginatorRows, getId(), PropagationTaskTO.class),
- container,
- 0,
- pageRef,
- restClient);
-
- window.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
-
- private static final long serialVersionUID = 8804221891699487139L;
-
- @Override
- public void onClose(final AjaxRequestTarget target) {
- target.add(container);
- if (operationResult) {
- info(getString(Constants.OPERATION_SUCCEEDED));
- target.add(getPage().get(Constants.FEEDBACK));
- operationResult = false;
- }
- }
- });
-
- window.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- window.setInitialHeight(WIN_HEIGHT);
- window.setInitialWidth(WIN_WIDTH);
- window.setCookieName(VIEW_TASK_WIN_COOKIE_NAME);
-
- @SuppressWarnings("rawtypes")
- Form paginatorForm = new Form("PaginatorForm");
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- final DropDownChoice rowsChooser = new DropDownChoice(
- "rowsChooser", new PropertyModel(this, "paginatorRows"), prefMan.getPaginatorChoices());
-
- rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- prefMan.set(getWebRequest(), (WebResponse) getResponse(),
- Constants.PREF_PROPAGATION_TASKS_PAGINATOR_ROWS, String.valueOf(paginatorRows));
-
- table = Tasks.updateTaskTable(
- getColumns(),
- new TasksProvider<>(restClient, paginatorRows, getId(), PropagationTaskTO.class),
- container,
- table == null ? 0 : (int) table.getCurrentPage(),
- pageRef,
- restClient);
-
- target.add(container);
- }
- });
-
- paginatorForm.add(rowsChooser);
- add(paginatorForm);
- }
-
- private List<IColumn<AbstractTaskTO, String>> getColumns() {
- final List<IColumn<AbstractTaskTO, String>> columns = new ArrayList<>();
-
- columns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("key", this, null), "key", "key"));
- columns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("resource", this, null), "resource", "resource"));
- columns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("accountId", this, null), "accountId", "accountId"));
- columns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("propagationMode", this, null), "propagationMode", "propagationMode"));
- columns.add(new PropertyColumn<AbstractTaskTO, String>(new StringResourceModel(
- "propagationOperation", this, null), "propagationOperation", "propagationOperation"));
- columns.add(new DatePropertyColumn<AbstractTaskTO>(
- new StringResourceModel("startDate", this, null), "startDate", "startDate"));
- columns.add(new DatePropertyColumn<AbstractTaskTO>(
- new StringResourceModel("endDate", this, null), "endDate", "endDate"));
- columns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("latestExecStatus", this, null), "latestExecStatus", "latestExecStatus"));
- columns.add(new ActionColumn<AbstractTaskTO, String>(new StringResourceModel("actions", this, null, "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public String getCssClass() {
- return "action";
- }
-
- @Override
- public ActionLinksPanel getActions(final String componentId, final IModel<AbstractTaskTO> model) {
-
- final AbstractTaskTO taskTO = model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, pageRef);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
-
- window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new PropagationTaskModalPage(taskTO);
- }
- });
-
- window.show(target);
- }
- }, ActionLink.ActionType.EDIT, TASKS);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- restClient.startExecution(taskTO.getKey(), false);
- getSession().info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
-
- ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
- target.add(container);
- }
- }, ActionLink.ActionType.EXECUTE, TASKS);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- restClient.delete(taskTO.getKey(), PropagationTaskTO.class);
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
- target.add(container);
- ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
- }
- }, ActionLink.ActionType.DELETE, TASKS);
-
- return panel;
- }
-
- @Override
- public Component getHeader(final String componentId) {
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), pageRef);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- if (target != null) {
- target.add(table);
- }
- }
- }, ActionLink.ActionType.RELOAD, TASKS, "list");
-
- return panel;
- }
- });
-
- return columns;
- }
-
- @Override
- public void onEvent(final IEvent<?> event) {
- if (event.getPayload() instanceof EventDataWrapper) {
- ((EventDataWrapper) event.getPayload()).getTarget().add(container);
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/PushTasksPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/PushTasksPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/PushTasksPanel.java
deleted file mode 100644
index a93000d..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/PushTasksPanel.java
+++ /dev/null
@@ -1,184 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.pages.PushTaskModalPage;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.AbstractTaskTO;
-import org.apache.syncope.common.lib.to.PushTaskTO;
-import org.apache.syncope.common.lib.to.SyncTaskTO;
-import org.apache.wicket.Component;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.StringResourceModel;
-
-public class PushTasksPanel extends AbstractProvisioningTasksPanel<PushTaskTO> {
-
- private static final long serialVersionUID = -2492299671757861889L;
-
- public PushTasksPanel(final String id, final PageReference pageRef) {
- super(id, pageRef, PushTaskTO.class);
- initTasksTable();
- }
-
- @Override
- protected List<IColumn<AbstractTaskTO, String>> getColumns() {
- final List<IColumn<AbstractTaskTO, String>> pushTasksColumns = new ArrayList<IColumn<AbstractTaskTO, String>>();
-
- pushTasksColumns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("key", this, null), "key", "key"));
- pushTasksColumns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("name", this, null), "name", "name"));
- pushTasksColumns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("description", this, null), "description", "description"));
- pushTasksColumns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("resourceName", this, null), "resource", "resource"));
- pushTasksColumns.add(new DatePropertyColumn<AbstractTaskTO>(
- new StringResourceModel("lastExec", this, null), "lastExec", "lastExec"));
- pushTasksColumns.add(new DatePropertyColumn<AbstractTaskTO>(
- new StringResourceModel("nextExec", this, null), "nextExec", "nextExec"));
- pushTasksColumns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("latestExecStatus", this, null), "latestExecStatus", "latestExecStatus"));
-
- pushTasksColumns.add(
- new ActionColumn<AbstractTaskTO, String>(new StringResourceModel("actions", this, null, "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public ActionLinksPanel getActions(final String componentId, final IModel<AbstractTaskTO> model) {
-
- final PushTaskTO taskTO = (PushTaskTO) model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, pageRef);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
-
- window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new PushTaskModalPage(window, taskTO, pageRef);
- }
- });
-
- window.show(target);
- }
- }, ActionLink.ActionType.EDIT, TASKS);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- restClient.startExecution(taskTO.getKey(), false);
- getSession().info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
-
- target.add(container);
- ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
- }
- }, ActionLink.ActionType.EXECUTE, TASKS);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- restClient.startExecution(taskTO.getKey(), true);
- getSession().info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
-
- target.add(container);
- ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
- }
- }, ActionLink.ActionType.DRYRUN, TASKS);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- restClient.delete(taskTO.getKey(), SyncTaskTO.class);
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
- target.add(container);
- ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
- }
- }, ActionLink.ActionType.DELETE, TASKS);
-
- return panel;
- }
-
- @Override
- public Component getHeader(final String componentId) {
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), pageRef);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- if (target != null) {
- target.add(table);
- }
- }
- }, ActionLink.ActionType.RELOAD, TASKS, "list");
-
- return panel;
- }
- });
-
- return pushTasksColumns;
-
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourceConnConfPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourceConnConfPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourceConnConfPanel.java
deleted file mode 100644
index b3e63c5..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourceConnConfPanel.java
+++ /dev/null
@@ -1,187 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import org.apache.syncope.client.console.pages.BaseModalPage;
-import org.apache.syncope.client.console.pages.ResourceModalPage.ResourceEvent;
-import org.apache.syncope.client.console.panels.ResourceDetailsPanel.DetailsModEvent;
-import org.apache.syncope.client.console.rest.ConnectorRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel.MultiValueSelectorEvent;
-import org.apache.syncope.client.console.wicket.markup.html.list.ConnConfPropertyListView;
-import org.apache.syncope.common.lib.to.ResourceTO;
-import org.apache.syncope.common.lib.types.ConnConfProperty;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.event.Broadcast;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class ResourceConnConfPanel extends Panel {
-
- private static final long serialVersionUID = -7982691107029848579L;
-
- @SpringBean
- private ConnectorRestClient restClient;
-
- private final ResourceTO resourceTO;
-
- private final boolean createFlag;
-
- private List<ConnConfProperty> connConfProperties;
-
- private WebMarkupContainer connConfPropContainer;
-
- private AjaxButton check;
-
- public ResourceConnConfPanel(final String id, final ResourceTO resourceTO, final boolean createFlag) {
- super(id);
- setOutputMarkupId(true);
-
- this.createFlag = createFlag;
- this.resourceTO = resourceTO;
-
- connConfProperties = getConnConfProperties();
-
- connConfPropContainer = new WebMarkupContainer("connectorPropertiesContainer");
- connConfPropContainer.setOutputMarkupId(true);
- add(connConfPropContainer);
-
- /*
- * the list of overridable connector properties
- */
- final ListView<ConnConfProperty> connPropView = new ConnConfPropertyListView("connectorProperties",
- new PropertyModel<List<ConnConfProperty>>(this, "connConfProperties"),
- false, resourceTO.getConnConfProperties());
- connPropView.setOutputMarkupId(true);
- connConfPropContainer.add(connPropView);
-
- check = new IndicatingAjaxButton("check", new ResourceModel("check")) {
-
- private static final long serialVersionUID = -4199438518229098169L;
-
- @Override
- public void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- final ResourceTO resourceTO = (ResourceTO) form.getModelObject();
-
- if (restClient.check(resourceTO)) {
- info(getString("success_connection"));
- } else {
- error(getString("error_connection"));
- }
-
- ((BaseModalPage) getPage()).getFeedbackPanel().refresh(target);
- }
- };
-
- check.setEnabled(!connConfProperties.isEmpty());
- connConfPropContainer.add(check);
- }
-
- /**
- * Get overridable properties.
- *
- * @return overridable properties.
- */
- private List<ConnConfProperty> getConnConfProperties() {
- final List<ConnConfProperty> props = new ArrayList<ConnConfProperty>();
- final Long connectorId = resourceTO.getConnectorId();
- if (connectorId != null && connectorId > 0) {
- for (ConnConfProperty property : restClient.getConnectorProperties(connectorId)) {
- if (property.isOverridable()) {
- props.add(property);
- }
- }
- }
- if (createFlag || resourceTO.getConnConfProperties().isEmpty()) {
- resourceTO.getConnConfProperties().clear();
- } else {
- Map<String, ConnConfProperty> valuedProps = new HashMap<String, ConnConfProperty>();
- for (ConnConfProperty prop : resourceTO.getConnConfProperties()) {
- valuedProps.put(prop.getSchema().getName(), prop);
- }
-
- for (int i = 0; i < props.size(); i++) {
- if (valuedProps.containsKey(props.get(i).getSchema().getName())) {
- props.set(i, valuedProps.get(props.get(i).getSchema().getName()));
- }
- }
- }
-
- // re-order properties
- Collections.sort(props);
-
- return props;
- }
-
- @Override
- public void onEvent(final IEvent<?> event) {
- AjaxRequestTarget target = null;
- if (event.getPayload() instanceof DetailsModEvent) {
- // connector change: update properties and forward event
- target = ((ResourceEvent) event.getPayload()).getTarget();
-
- connConfProperties = getConnConfProperties();
- check.setEnabled(!connConfProperties.isEmpty());
-
- target.add(connConfPropContainer);
- } else if (event.getPayload() instanceof MultiValueSelectorEvent) {
- // multi value connector property change: forward event
- target = ((MultiValueSelectorEvent) event.getPayload()).getTarget();
- }
-
- if (target != null) {
- send(getPage(), Broadcast.BREADTH, new ConnConfModEvent(target, connConfProperties));
- }
- }
-
- /**
- * Connector configuration properties modification event.
- */
- public static class ConnConfModEvent extends ResourceEvent {
-
- private List<ConnConfProperty> configuration;
-
- /**
- * Constructor.
- *
- * @param target request target.
- * @param configuration connector configuration properties.
- */
- public ConnConfModEvent(final AjaxRequestTarget target, final List<ConnConfProperty> configuration) {
- super(target);
- this.configuration = configuration;
- }
-
- public List<ConnConfProperty> getConfiguration() {
- return configuration;
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourceDetailsPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourceDetailsPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourceDetailsPanel.java
deleted file mode 100644
index 3bff23f..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourceDetailsPanel.java
+++ /dev/null
@@ -1,306 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.Arrays;
-import java.util.List;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.pages.ResourceModalPage.ResourceEvent;
-import org.apache.syncope.client.console.rest.ConnectorRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.SpinnerFieldPanel;
-import org.apache.syncope.common.lib.to.ConnInstanceTO;
-import org.apache.syncope.common.lib.to.ResourceTO;
-import org.apache.syncope.common.lib.types.PropagationMode;
-import org.apache.syncope.common.lib.types.TraceLevel;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.event.Broadcast;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.ChoiceRenderer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-public class ResourceDetailsPanel extends Panel {
-
- private static final long serialVersionUID = -7982691107029848579L;
-
- /**
- * Logger.
- */
- private static final Logger LOG = LoggerFactory.getLogger(ResourceDetailsPanel.class);
-
- @SpringBean
- private ConnectorRestClient connRestClient;
-
- private ConnInstanceTO connInstanceTO;
-
- public ResourceDetailsPanel(final String id, final ResourceTO resourceTO, final List<String> actionClassNames,
- final boolean createFlag) {
-
- super(id);
- setOutputMarkupId(true);
-
- final AjaxTextFieldPanel resourceName = new AjaxTextFieldPanel("name", new ResourceModel("name", "name").
- getObject(), new PropertyModel<String>(resourceTO, "key"));
-
- resourceName.setEnabled(createFlag);
- resourceName.addRequiredLabel();
- add(resourceName);
-
- final AjaxCheckBoxPanel enforceMandatoryCondition = new AjaxCheckBoxPanel("enforceMandatoryCondition",
- new ResourceModel("enforceMandatoryCondition", "enforceMandatoryCondition").getObject(),
- new PropertyModel<Boolean>(resourceTO, "enforceMandatoryCondition"));
- add(enforceMandatoryCondition);
-
- final AjaxCheckBoxPanel propagationPrimary = new AjaxCheckBoxPanel("propagationPrimary", new ResourceModel(
- "propagationPrimary", "propagationPrimary").getObject(), new PropertyModel<Boolean>(resourceTO,
- "propagationPrimary"));
- add(propagationPrimary);
-
- final SpinnerFieldPanel<Integer> propagationPriority =
- new SpinnerFieldPanel<>("propagationPriority", "propagationPriority", Integer.class,
- new PropertyModel<Integer>(resourceTO, "propagationPriority"), null, null);
- add(propagationPriority);
-
- final AjaxDropDownChoicePanel<PropagationMode> propagationMode = new AjaxDropDownChoicePanel<>(
- "propagationMode", new ResourceModel("propagationMode", "propagationMode").getObject(),
- new PropertyModel<PropagationMode>(resourceTO, "propagationMode"));
- propagationMode.setChoices(Arrays.asList(PropagationMode.values()));
- add(propagationMode);
-
- final AjaxCheckBoxPanel randomPwdIfNotProvided = new AjaxCheckBoxPanel("randomPwdIfNotProvided",
- new ResourceModel("randomPwdIfNotProvided", "randomPwdIfNotProvided").getObject(),
- new PropertyModel<Boolean>(resourceTO, "randomPwdIfNotProvided"));
- add(randomPwdIfNotProvided);
-
- final WebMarkupContainer propagationActionsClassNames = new WebMarkupContainer("propagationActionsClassNames");
- propagationActionsClassNames.setOutputMarkupId(true);
- add(propagationActionsClassNames);
-
- final AjaxLink<Void> first = new IndicatingAjaxLink<Void>("first") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- resourceTO.getPropagationActionsClassNames().add(StringUtils.EMPTY);
- setVisible(false);
- target.add(propagationActionsClassNames);
- }
- };
- first.setOutputMarkupPlaceholderTag(true);
- first.setVisible(resourceTO.getPropagationActionsClassNames().isEmpty());
- propagationActionsClassNames.add(first);
-
- final ListView<String> actionsClasses = new ListView<String>("actionsClasses",
- new PropertyModel<List<String>>(resourceTO, "propagationActionsClassNames")) {
-
- private static final long serialVersionUID = 9101744072914090143L;
-
- @Override
- protected void populateItem(final ListItem<String> item) {
- final String className = item.getModelObject();
-
- final DropDownChoice<String> actionsClass = new DropDownChoice<>(
- "actionsClass", new Model<>(className), actionClassNames);
- actionsClass.setNullValid(true);
- actionsClass.setRequired(true);
- actionsClass.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_BLUR) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- resourceTO.getPropagationActionsClassNames().
- set(item.getIndex(), actionsClass.getModelObject());
- }
- });
- actionsClass.setRequired(true);
- actionsClass.setOutputMarkupId(true);
- actionsClass.setRequired(true);
- item.add(actionsClass);
-
- AjaxLink<Void> minus = new IndicatingAjaxLink<Void>("drop") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- resourceTO.getPropagationActionsClassNames().remove(className);
- first.setVisible(resourceTO.getPropagationActionsClassNames().isEmpty());
- target.add(propagationActionsClassNames);
- }
- };
- item.add(minus);
-
- final AjaxLink<Void> plus = new IndicatingAjaxLink<Void>("add") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- resourceTO.getPropagationActionsClassNames().add(StringUtils.EMPTY);
- target.add(propagationActionsClassNames);
- }
- };
- plus.setOutputMarkupPlaceholderTag(true);
- plus.setVisible(item.getIndex() == resourceTO.getPropagationActionsClassNames().size() - 1);
- item.add(plus);
- }
- };
- propagationActionsClassNames.add(actionsClasses);
-
- final AjaxDropDownChoicePanel<TraceLevel> createTraceLevel = new AjaxDropDownChoicePanel<>(
- "createTraceLevel", new ResourceModel("createTraceLevel", "createTraceLevel").getObject(),
- new PropertyModel<TraceLevel>(resourceTO, "createTraceLevel"));
- createTraceLevel.setChoices(Arrays.asList(TraceLevel.values()));
- add(createTraceLevel);
-
- final AjaxDropDownChoicePanel<TraceLevel> updateTraceLevel = new AjaxDropDownChoicePanel<>(
- "updateTraceLevel", new ResourceModel("updateTraceLevel", "updateTraceLevel").getObject(),
- new PropertyModel<TraceLevel>(resourceTO, "updateTraceLevel"));
- updateTraceLevel.setChoices(Arrays.asList(TraceLevel.values()));
- add(updateTraceLevel);
-
- final AjaxDropDownChoicePanel<TraceLevel> deleteTraceLevel = new AjaxDropDownChoicePanel<>(
- "deleteTraceLevel", new ResourceModel("deleteTraceLevel", "deleteTraceLevel").getObject(),
- new PropertyModel<TraceLevel>(resourceTO, "deleteTraceLevel"));
- deleteTraceLevel.setChoices(Arrays.asList(TraceLevel.values()));
- add(deleteTraceLevel);
-
- final AjaxDropDownChoicePanel<TraceLevel> syncTraceLevel = new AjaxDropDownChoicePanel<>(
- "syncTraceLevel", new ResourceModel("syncTraceLevel", "syncTraceLevel").getObject(),
- new PropertyModel<TraceLevel>(resourceTO, "syncTraceLevel"));
- syncTraceLevel.setChoices(Arrays.asList(TraceLevel.values()));
- add(syncTraceLevel);
-
- final IModel<List<ConnInstanceTO>> connectors = new LoadableDetachableModel<List<ConnInstanceTO>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<ConnInstanceTO> load() {
- return connRestClient.getAllConnectors();
- }
- };
-
- connInstanceTO = getConectorInstanceTO(connectors.getObject(), resourceTO);
-
- final AjaxDropDownChoicePanel<ConnInstanceTO> conn = new AjaxDropDownChoicePanel<>("connector",
- new ResourceModel("connector", "connector").getObject(),
- new PropertyModel<ConnInstanceTO>(this, "connInstanceTO"));
- conn.setChoices(connectors.getObject());
- conn.setChoiceRenderer(new ChoiceRenderer("displayName", "key"));
-
- conn.getField().setModel(new IModel<ConnInstanceTO>() {
-
- private static final long serialVersionUID = -4202872830392400310L;
-
- @Override
- public ConnInstanceTO getObject() {
- return connInstanceTO;
- }
-
- @Override
- public void setObject(final ConnInstanceTO connector) {
- resourceTO.setConnectorId(connector.getKey());
- connInstanceTO = connector;
- }
-
- @Override
- public void detach() {
- }
- });
-
- conn.addRequiredLabel();
- conn.setEnabled(createFlag);
-
- conn.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- send(getPage(), Broadcast.BREADTH, new DetailsModEvent(target));
- }
- });
-
- add(conn);
- }
-
- /**
- * Get the connetorTO linked to the resource.
- *
- * @param connectorTOs list of all connectors.
- * @param resourceTO resource.
- * @return selected connector instance: in case of no connectors available, null; in case of new resource
- * specification, the first on connector available
- */
- private ConnInstanceTO getConectorInstanceTO(final List<ConnInstanceTO> connectorTOs, final ResourceTO resourceTO) {
- if (connectorTOs.isEmpty()) {
- resourceTO.setConnectorId(null);
- return null;
- } else {
- // use the first element as default
- ConnInstanceTO res = connectorTOs.get(0);
-
- for (ConnInstanceTO to : connectorTOs) {
- if (Long.valueOf(to.getKey()).equals(resourceTO.getConnectorId())) {
- res = to;
- }
- }
-
- // in case of no match
- resourceTO.setConnectorId(res.getKey());
-
- return res;
- }
- }
-
- /**
- * Connector instance modification event.
- */
- public static class DetailsModEvent extends ResourceEvent {
-
- /**
- * Constructor.
- *
- * @param target request target.
- */
- public DetailsModEvent(final AjaxRequestTarget target) {
- super(target);
- }
- }
-}
[34/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/none-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/none-icon.png b/client/console/src/main/resources/META-INF/resources/img/actions/none-icon.png
deleted file mode 100644
index cc49adb..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/none-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/propagation-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/propagation-icon.png b/client/console/src/main/resources/META-INF/resources/img/actions/propagation-icon.png
deleted file mode 100644
index d7fa5e9..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/propagation-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/provision-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/provision-icon.png b/client/console/src/main/resources/META-INF/resources/img/actions/provision-icon.png
deleted file mode 100644
index 3f8faf1..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/provision-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/reactivate.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/reactivate.png b/client/console/src/main/resources/META-INF/resources/img/actions/reactivate.png
deleted file mode 100644
index 50503e2..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/reactivate.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/reload.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/reload.png b/client/console/src/main/resources/META-INF/resources/img/actions/reload.png
deleted file mode 100644
index bbf878e..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/reload.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/reset.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/reset.png b/client/console/src/main/resources/META-INF/resources/img/actions/reset.png
deleted file mode 100644
index bbf878e..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/reset.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/resources-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/resources-icon.png b/client/console/src/main/resources/META-INF/resources/img/actions/resources-icon.png
deleted file mode 100644
index 6240ba9..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/resources-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/search.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/search.png b/client/console/src/main/resources/META-INF/resources/img/actions/search.png
deleted file mode 100644
index 3ac297e..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/search.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/select.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/select.png b/client/console/src/main/resources/META-INF/resources/img/actions/select.png
deleted file mode 100644
index f2ea103..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/select.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/settings-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/settings-icon.png b/client/console/src/main/resources/META-INF/resources/img/actions/settings-icon.png
deleted file mode 100644
index 1da7e05..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/settings-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/suspend.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/suspend.png b/client/console/src/main/resources/META-INF/resources/img/actions/suspend.png
deleted file mode 100644
index bd5f0bd..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/suspend.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/synchronization-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/synchronization-icon.png b/client/console/src/main/resources/META-INF/resources/img/actions/synchronization-icon.png
deleted file mode 100644
index 394b907..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/synchronization-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/unassign-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/unassign-icon.png b/client/console/src/main/resources/META-INF/resources/img/actions/unassign-icon.png
deleted file mode 100644
index 860dc49..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/unassign-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/unlink-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/unlink-icon.png b/client/console/src/main/resources/META-INF/resources/img/actions/unlink-icon.png
deleted file mode 100644
index 86700a5..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/unlink-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/user_template.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/user_template.png b/client/console/src/main/resources/META-INF/resources/img/actions/user_template.png
deleted file mode 100644
index 6db6de8..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/user_template.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/users-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/users-icon.png b/client/console/src/main/resources/META-INF/resources/img/actions/users-icon.png
deleted file mode 100644
index cfab465..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/users-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/add.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/add.png b/client/console/src/main/resources/META-INF/resources/img/add.png
deleted file mode 100644
index 043aba8..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/add.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/addAll.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/addAll.png b/client/console/src/main/resources/META-INF/resources/img/addAll.png
deleted file mode 100644
index 86633fc..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/addAll.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/busy.gif
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/busy.gif b/client/console/src/main/resources/META-INF/resources/img/busy.gif
deleted file mode 100644
index e77264f..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/busy.gif and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/db_export.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/db_export.png b/client/console/src/main/resources/META-INF/resources/img/db_export.png
deleted file mode 100644
index 413cb06..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/db_export.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/disable.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/disable.png b/client/console/src/main/resources/META-INF/resources/img/disable.png
deleted file mode 100644
index 26fbe85..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/disable.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/down-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/down-icon.png b/client/console/src/main/resources/META-INF/resources/img/down-icon.png
deleted file mode 100644
index 6f818ee..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/down-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/favicon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/favicon.png b/client/console/src/main/resources/META-INF/resources/img/favicon.png
deleted file mode 100644
index aa2f3e2..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/favicon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/file-download.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/file-download.png b/client/console/src/main/resources/META-INF/resources/img/file-download.png
deleted file mode 100644
index ceae906..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/file-download.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/file-upload.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/file-upload.png b/client/console/src/main/resources/META-INF/resources/img/file-upload.png
deleted file mode 100644
index d4a399e..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/file-upload.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/help.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/help.png b/client/console/src/main/resources/META-INF/resources/img/help.png
deleted file mode 100644
index 560064e..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/help.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/info.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/info.png b/client/console/src/main/resources/META-INF/resources/img/info.png
deleted file mode 100644
index f1a4832..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/info.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/left-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/left-icon.png b/client/console/src/main/resources/META-INF/resources/img/left-icon.png
deleted file mode 100644
index 03b215c..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/left-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/loading.gif
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/loading.gif b/client/console/src/main/resources/META-INF/resources/img/loading.gif
deleted file mode 100644
index 85b99d4..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/loading.gif and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/logo.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/logo.png b/client/console/src/main/resources/META-INF/resources/img/logo.png
deleted file mode 100644
index f05105e..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/logo.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/configuration.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/configuration.png b/client/console/src/main/resources/META-INF/resources/img/menu/configuration.png
deleted file mode 100644
index 7d4bb91..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/configuration.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/connectors.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/connectors.png b/client/console/src/main/resources/META-INF/resources/img/menu/connectors.png
deleted file mode 100644
index 8ae8705..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/connectors.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/groups.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/groups.png b/client/console/src/main/resources/META-INF/resources/img/menu/groups.png
deleted file mode 100644
index fba8be7..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/groups.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/logout.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/logout.png b/client/console/src/main/resources/META-INF/resources/img/menu/logout.png
deleted file mode 100644
index e8ad795..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/logout.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/notsel/configuration.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/configuration.png b/client/console/src/main/resources/META-INF/resources/img/menu/notsel/configuration.png
deleted file mode 100644
index 2c3bb8e..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/configuration.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/notsel/connectors.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/connectors.png b/client/console/src/main/resources/META-INF/resources/img/menu/notsel/connectors.png
deleted file mode 100644
index 98394a9..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/connectors.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/notsel/groups.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/groups.png b/client/console/src/main/resources/META-INF/resources/img/menu/notsel/groups.png
deleted file mode 100644
index 9b64b4b..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/groups.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/notsel/logout.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/logout.png b/client/console/src/main/resources/META-INF/resources/img/menu/notsel/logout.png
deleted file mode 100644
index ffe0729..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/logout.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/notsel/reports.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/reports.png b/client/console/src/main/resources/META-INF/resources/img/menu/notsel/reports.png
deleted file mode 100644
index 596ff39..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/reports.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/notsel/resources.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/resources.png b/client/console/src/main/resources/META-INF/resources/img/menu/notsel/resources.png
deleted file mode 100644
index 98394a9..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/resources.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/notsel/schema.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/schema.png b/client/console/src/main/resources/META-INF/resources/img/menu/notsel/schema.png
deleted file mode 100644
index ee1ad4c..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/schema.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/notsel/sf_body.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/sf_body.png b/client/console/src/main/resources/META-INF/resources/img/menu/notsel/sf_body.png
deleted file mode 100644
index 0e3bc4c..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/sf_body.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/notsel/tasks.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/tasks.png b/client/console/src/main/resources/META-INF/resources/img/menu/notsel/tasks.png
deleted file mode 100644
index 08cde6d..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/tasks.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/notsel/todo.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/todo.png b/client/console/src/main/resources/META-INF/resources/img/menu/notsel/todo.png
deleted file mode 100644
index 26a10e3..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/todo.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/notsel/users.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/users.png b/client/console/src/main/resources/META-INF/resources/img/menu/notsel/users.png
deleted file mode 100644
index 97bf71b..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/notsel/users.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/reports.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/reports.png b/client/console/src/main/resources/META-INF/resources/img/menu/reports.png
deleted file mode 100644
index 847fd2b..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/reports.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/resources.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/resources.png b/client/console/src/main/resources/META-INF/resources/img/menu/resources.png
deleted file mode 100644
index 8ae8705..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/resources.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/schema.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/schema.png b/client/console/src/main/resources/META-INF/resources/img/menu/schema.png
deleted file mode 100644
index 378a83c..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/schema.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/tasks.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/tasks.png b/client/console/src/main/resources/META-INF/resources/img/menu/tasks.png
deleted file mode 100644
index 05bdc11..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/tasks.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/todo.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/todo.png b/client/console/src/main/resources/META-INF/resources/img/menu/todo.png
deleted file mode 100644
index 2fb374b..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/todo.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/menu/users.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/menu/users.png b/client/console/src/main/resources/META-INF/resources/img/menu/users.png
deleted file mode 100644
index 64264fa..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/menu/users.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/minus-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/minus-icon.png b/client/console/src/main/resources/META-INF/resources/img/minus-icon.png
deleted file mode 100644
index 4bc2f4e..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/minus-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/modeler.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/modeler.png b/client/console/src/main/resources/META-INF/resources/img/modeler.png
deleted file mode 100644
index d33c4ef..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/modeler.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/moveDown.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/moveDown.png b/client/console/src/main/resources/META-INF/resources/img/moveDown.png
deleted file mode 100644
index d6ce523..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/moveDown.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/moveUp.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/moveUp.png b/client/console/src/main/resources/META-INF/resources/img/moveUp.png
deleted file mode 100644
index d9b2790..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/moveUp.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/ok.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/ok.png b/client/console/src/main/resources/META-INF/resources/img/ok.png
deleted file mode 100644
index bc9d2f5..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/ok.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/ping.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/ping.png b/client/console/src/main/resources/META-INF/resources/img/ping.png
deleted file mode 100644
index 8ad053d..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/ping.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/plus-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/plus-icon.png b/client/console/src/main/resources/META-INF/resources/img/plus-icon.png
deleted file mode 100644
index 3f8faf1..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/plus-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/reload_30.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/reload_30.png b/client/console/src/main/resources/META-INF/resources/img/reload_30.png
deleted file mode 100644
index f9b1e98..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/reload_30.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/remove.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/remove.png b/client/console/src/main/resources/META-INF/resources/img/remove.png
deleted file mode 100644
index de5a5cf..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/remove.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/removeAll.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/removeAll.png b/client/console/src/main/resources/META-INF/resources/img/removeAll.png
deleted file mode 100644
index f293962..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/removeAll.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/right-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/right-icon.png b/client/console/src/main/resources/META-INF/resources/img/right-icon.png
deleted file mode 100644
index 2cf0882..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/right-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/search.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/search.png b/client/console/src/main/resources/META-INF/resources/img/search.png
deleted file mode 100644
index 640c7e8..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/search.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/sf_testa.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/sf_testa.png b/client/console/src/main/resources/META-INF/resources/img/sf_testa.png
deleted file mode 100644
index 6539dbd..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/sf_testa.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/statuses/active.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/statuses/active.png b/client/console/src/main/resources/META-INF/resources/img/statuses/active.png
deleted file mode 100644
index 79332c0..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/statuses/active.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/statuses/inactive.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/statuses/inactive.png b/client/console/src/main/resources/META-INF/resources/img/statuses/inactive.png
deleted file mode 100644
index 68975bd..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/statuses/inactive.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/statuses/objectnotfound.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/statuses/objectnotfound.png b/client/console/src/main/resources/META-INF/resources/img/statuses/objectnotfound.png
deleted file mode 100644
index a0a2933..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/statuses/objectnotfound.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/statuses/undefined.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/statuses/undefined.png b/client/console/src/main/resources/META-INF/resources/img/statuses/undefined.png
deleted file mode 100644
index 97188ba..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/statuses/undefined.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/success.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/success.png b/client/console/src/main/resources/META-INF/resources/img/success.png
deleted file mode 100644
index e4b1df7..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/success.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/tab ok.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/tab ok.png b/client/console/src/main/resources/META-INF/resources/img/tab ok.png
deleted file mode 100644
index 8b6d0ee..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/tab ok.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/tab old.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/tab old.png b/client/console/src/main/resources/META-INF/resources/img/tab old.png
deleted file mode 100644
index 3d5f156..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/tab old.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/tab.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/tab.png b/client/console/src/main/resources/META-INF/resources/img/tab.png
deleted file mode 100644
index 2ee49dd..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/tab.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/up-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/up-icon.png b/client/console/src/main/resources/META-INF/resources/img/up-icon.png
deleted file mode 100644
index 1a4dbdf..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/up-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/warning.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/warning.png b/client/console/src/main/resources/META-INF/resources/img/warning.png
deleted file mode 100644
index c98c1fd..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/warning.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/xml.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/xml.png b/client/console/src/main/resources/META-INF/resources/img/xml.png
deleted file mode 100644
index 110fdc4..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/xml.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/authorizations.xml
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/authorizations.xml b/client/console/src/main/resources/authorizations.xml
deleted file mode 100644
index 8de4a1d..0000000
--- a/client/console/src/main/resources/authorizations.xml
+++ /dev/null
@@ -1,333 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<auth>
- <page id="Schema">
- <action id="list">
- <entitlement>SCHEMA_LIST</entitlement>
- </action>
-
- <action id="create">
- <entitlement>SCHEMA_CREATE</entitlement>
- </action>
-
- <action id="read">
- <entitlement>SCHEMA_READ</entitlement>
- </action>
-
- <action id="update">
- <entitlement>SCHEMA_UPDATE</entitlement>
- </action>
-
- <action id="delete">
- <entitlement>SCHEMA_DELETE</entitlement>
- </action>
- </page>
-
- <page id="Users">
- <action id="list">
- <entitlement>USER_LIST</entitlement>
- </action>
-
- <action id="create">
- <entitlement>USER_CREATE</entitlement>
- </action>
-
- <action id="read">
- <entitlement>USER_READ</entitlement>
- </action>
-
- <action id="update">
- <entitlement>USER_UPDATE</entitlement>
- </action>
-
- <action id="delete">
- <entitlement>USER_DELETE</entitlement>
- </action>
-
- <action id="changeView">
- <entitlement>USER_VIEW</entitlement>
- </action>
- </page>
-
- <page id="Groups">
- <action id="list">
- <entitlement>GROUP_LIST</entitlement>
- </action>
-
- <action id="create">
- <entitlement>GROUP_CREATE</entitlement>
- </action>
-
- <action id="read">
- <entitlement>GROUP_READ</entitlement>
- </action>
-
- <action id="update">
- <entitlement>GROUP_UPDATE</entitlement>
- </action>
-
- <action id="delete">
- <entitlement>GROUP_DELETE</entitlement>
- </action>
- </page>
-
- <page id="Resources">
- <action id="list">
- <entitlement>RESOURCE_LIST</entitlement>
- </action>
-
- <action id="create">
- <entitlement>RESOURCE_CREATE</entitlement>
- </action>
-
- <action id="read">
- <entitlement>RESOURCE_READ</entitlement>
- </action>
-
- <action id="update">
- <entitlement>RESOURCE_UPDATE</entitlement>
- </action>
-
- <action id="delete">
- <entitlement>RESOURCE_DELETE</entitlement>
- </action>
-
- <action id="getConnectorObject">
- <entitlement>RESOURCE_GETCONNECTOROBJECT</entitlement>
- </action>
- </page>
-
- <page id="Reports">
- <action id="list">
- <entitlement>REPORT_LIST</entitlement>
- </action>
-
- <action id="create">
- <entitlement>REPORT_CREATE</entitlement>
- </action>
-
- <action id="read">
- <entitlement>REPORT_READ</entitlement>
- </action>
-
- <action id="update">
- <entitlement>REPORT_UPDATE</entitlement>
- </action>
-
- <action id="delete">
- <entitlement>REPORT_DELETE</entitlement>
- </action>
-
- <action id="execute">
- <entitlement>REPORT_EXECUTE</entitlement>
- </action>
- </page>
-
- <page id="Audit">
- <action id="list">
- <entitlement>AUDIT_LIST</entitlement>
- </action>
-
- <action id="enable">
- <entitlement>AUDIT_ENABLE</entitlement>
- </action>
-
- <action id="disable">
- <entitlement>AUDIT_DISABLE</entitlement>
- </action>
- </page>
-
- <page id="Connectors">
- <action id="list">
- <entitlement>CONNECTOR_LIST</entitlement>
- </action>
-
- <action id="create">
- <entitlement>CONNECTOR_CREATE</entitlement>
- </action>
-
- <action id="read">
- <entitlement>CONNECTOR_READ</entitlement>
- </action>
-
- <action id="update">
- <entitlement>CONNECTOR_UPDATE</entitlement>
- </action>
-
- <action id="delete">
- <entitlement>CONNECTOR_DELETE</entitlement>
- </action>
-
- <action id="reload">
- <entitlement>CONNECTOR_RELOAD</entitlement>
- </action>
-
- </page>
-
- <page id="Approval">
- <action id="list">
- <entitlement>WORKFLOW_FORM_LIST</entitlement>
- </action>
- <action id="read">
- <entitlement>WORKFLOW_FORM_READ</entitlement>
- </action>
- <action id="claim">
- <entitlement>WORKFLOW_FORM_CLAIM</entitlement>
- </action>
- <action id="submit">
- <entitlement>WORKFLOW_FORM_SUBMIT</entitlement>
- </action>
- </page>
-
- <page id="Configuration">
- <action id="list">
- <entitlement>CONFIGURATION_LIST</entitlement>
- </action>
-
- <action id="export">
- <entitlement>CONFIGURATION_EXPORT</entitlement>
- </action>
-
- <action id="set">
- <entitlement>CONFIGURATION_SET</entitlement>
- </action>
-
- <action id="delete">
- <entitlement>CONFIGURATION_DELETE</entitlement>
- </action>
-
- <action id="logList">
- <entitlement>LOG_LIST</entitlement>
- </action>
-
- <action id="logSetLevel">
- <entitlement>LOG_SET_LEVEL</entitlement>
- </action>
-
- <action id="logDelete">
- <entitlement>LOG_DELETE</entitlement>
- </action>
-
- <action id="workflowDefRead">
- <entitlement>WORKFLOW_DEF_READ</entitlement>
- </action>
-
- <action id="workflowDefUpdate">
- <entitlement>WORKFLOW_DEF_UPDATE</entitlement>
- </action>
- </page>
-
- <page id="Notification">
- <action id="list">
- <entitlement>NOTIFICATION_LIST</entitlement>
- </action>
-
- <action id="create">
- <entitlement>NOTIFICATION_CREATE</entitlement>
- </action>
-
- <action id="read">
- <entitlement>NOTIFICATION_READ</entitlement>
- </action>
-
- <action id="update">
- <entitlement>NOTIFICATION_UPDATE</entitlement>
- </action>
-
- <action id="delete">
- <entitlement>NOTIFICATION_DELETE</entitlement>
- </action>
- </page>
-
- <page id="SecurityQuestion">
- <action id="create">
- <entitlement>SECURITY_QUESTION_CREATE</entitlement>
- </action>
-
- <action id="update">
- <entitlement>SECURITY_QUESTION_UPDATE</entitlement>
- </action>
-
- <action id="delete">
- <entitlement>SECURITY_QUESTION_DELETE</entitlement>
- </action>
- </page>
-
- <page id="Tasks">
- <action id="list">
- <entitlement>TASK_LIST</entitlement>
- </action>
-
- <action id="execute">
- <entitlement>TASK_EXECUTE</entitlement>
- </action>
-
- <action id="read">
- <entitlement>TASK_READ</entitlement>
- </action>
-
- <action id="delete">
- <entitlement>TASK_DELETE</entitlement>
- </action>
-
- <action id="create">
- <entitlement>TASK_CREATE</entitlement>
- </action>
-
- <action id="update">
- <entitlement>TASK_UPDATE</entitlement>
- </action>
- </page>
-
- <page id="Policies">
- <action id="list">
- <entitlement>POLICY_LIST</entitlement>
- </action>
-
- <action id="read">
- <entitlement>POLICY_READ</entitlement>
- </action>
-
- <action id="delete">
- <entitlement>POLICY_DELETE</entitlement>
- </action>
-
- <action id="create">
- <entitlement>POLICY_CREATE</entitlement>
- </action>
-
- <action id="update">
- <entitlement>POLICY_UPDATE</entitlement>
- </action>
- </page>
- <page id="CamelRoutes">
- <action id="list">
- <entitlement>ROUTE_LIST</entitlement>
- </action>
-
- <action id="read">
- <entitlement>ROUTE_READ</entitlement>
- </action>
-
- <action id="update">
- <entitlement>ROUTE_UPDATE</entitlement>
- </action>
- </page>
-</auth>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/consoleContext.xml
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/consoleContext.xml b/client/console/src/main/resources/consoleContext.xml
index 1acb7b4..8b7fa16 100644
--- a/client/console/src/main/resources/consoleContext.xml
+++ b/client/console/src/main/resources/consoleContext.xml
@@ -60,17 +60,11 @@ under the License.
<constructor-arg value="${activitiModelerDirectory}"/>
</bean>
- <bean id="syncopeApplication" class="org.apache.syncope.client.console.SyncopeApplication"/>
+ <bean class="org.apache.syncope.client.console.SyncopeConsoleApplication"/>
- <bean id="preferenceManager" class="org.apache.syncope.client.console.commons.PreferenceManager"/>
+ <bean class="org.apache.syncope.client.console.PreferenceManager"/>
- <bean id="xmlRolesReader" class="org.apache.syncope.client.console.commons.XMLRolesReader" scope="singleton">
- <property name="authorizations" value="authorizations.xml"/>
- </bean>
-
- <bean id="groupTreeBuilder" class="org.apache.syncope.client.console.commons.GroupTreeBuilder"/>
-
- <bean id="syncopeClientFactory" class="org.apache.syncope.client.lib.SyncopeClientFactoryBean">
+ <bean class="org.apache.syncope.client.lib.SyncopeClientFactoryBean">
<property name="address" value="${scheme}://${host}:${port}/${rootPath}"/>
</bean>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication.properties b/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication.properties
deleted file mode 100644
index a5fe511..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication.properties
+++ /dev/null
@@ -1,55 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-users=Users
-groups=Groups
-configuration=Configuration
-resources=Resources
-connectors=Connectors
-reports=Reports
-tasks=Tasks
-logout=Logout
-schema=Schema
-operation_succeeded=Operation executed successfully
-operation_error=Error occurred during the requested operation
-alert=Alert:
-confirmDelete=Do you really want to delete the selected item(s)?
-confirmUnlink=Do you really want to remove the link between the selected item(s) and the resource?
-confirmUnassign=Do you really want to remove the assignment between the selected item(s) and the resource?
-confirmDeprovision=Do you really want to de-provision the selected item(s)?
-confirmProvision=Do you really want to provision the selected item(s)?
-
-
-unauthorizedInstantiationException=Missing authorization.
-accessControlException=Missing authorization while contacting Syncope core.
-restClientException=Error while contacting Syncope core.
-pageExpiredException=Session expired: please login again.
-
-dropDownChoiceField.nullValid=Choose one
-todo=TODO
-DateTimeField$HoursValidator=Hour value must be in range (1, 12)
-error=Error
-generic_error=An error occurred during the operation
-id=Id
-name=Name
-palette.available=Available
-palette.selected=Selected
-jexl_info=This field expects a JEXL expression, for example:
-jexl_ex1=surname + ',' + firstname
-jexl_ex2='new.' + surname
-jexl_syntax_url=Full JEXL reference
-create=Create
-key=Key
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication_it.properties
deleted file mode 100644
index 1f1e827..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication_it.properties
+++ /dev/null
@@ -1,54 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-users=Utenti
-groups=Gruppi
-configuration=Configurazione
-resources=Risorse
-connectors=Connettori
-reports=Rapporti
-logout=Logout
-schema=Schema
-tasks=Task
-operation_succeeded=Operazione eseguita con successo
-operation_error=Attenzione si \u00e8 verificato un errore durante l'esecuzione dell'operazione richiesta
-alert=Attenzione:
-confirmDelete=Vuoi davvero procedere con la cancellazione?
-confirmUnlink=Vuoi davvero procedere rimuovendo il link con la risorsa?
-confirmUnassign=Vuoi davvero procedere rimuovendo l'assegnamento sulla risorsa?
-confirmDeprovision=Vuoi davvero procedere con il de-provisioning?
-confirmProvision=Vuoi davvero procedere con il provisioning?
-
-unauthorizedInstantiationException=Autorizzazione mancante.
-accessControlException=Autorizzazione mancante durante la comunicazione con Syncope core.
-restClientException=Errore durante la comunicazione con Syncope core.
-pageExpiredException=Sessione scaduta: eseguire di nuovo l'accesso.
-
-dropDownChoiceField.nullValid=Seleziona
-todo=TODO
-DateTimeField$HoursValidator=L'ora deve essere nell'intervallo (1,12)
-error=Errore
-generic_error=Si \u00e8 verificato un errore durante l'operazione
-id=Id
-name=Nome
-palette.available=Opzioni
-palette.selected=Selezione
-jexl_info=In questo campo possono essere inserite espressioni di tipo JEXL, per esempio:
-jexl_ex1=surname + ',' + firstname
-jexl_ex2='new.' + surname
-jexl_syntax_url=Sintassi JEXL completa
-create=Crea
-key=Chiave
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication_pt_BR.properties
deleted file mode 100644
index de966d2..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication_pt_BR.properties
+++ /dev/null
@@ -1,54 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-users=Usu\u00e1rios
-groups=Grupos
-configuration=Configura\u00e7\u00f5es
-resources=Recursos
-connectors=Conectores
-reports=Relat\u00f3rios
-tasks=Tarefas
-logout=Sair
-schema=Esquemas
-operation_succeeded=Opera\u00e7\u00e3o executada com sucesso
-operation_error=Um erro ocorreu ao executar esta opera\u00e7\u00e3o
-alert=Alerta:
-confirmDelete=Voc\u00ea realmente deseja apagar este item(s) selecionado?
-confirmUnlink=Voc\u00ea realmente deseja apagar o v\u00ednculo entre o item e de recursos?
-confirmUnassign=Voc\u00ea realmente deseja apagar a atribui\u00e7\u00e3o entre o item e de recursos?
-confirmDeprovision=Voc\u00ea realmente de-provision item?
-confirmProvision=Voc\u00ea realmente provision item?
-
-unauthorizedInstantiationException=Falta de autoriza\u00e7\u00e3o para concluir.
-accessControlException=Falta de autoriza\u00e7\u00e3o ao comunicar-se com o Syncope core.
-restClientException=Erro ao comunicar-se com o Syncope core.
-pageExpiredException=Sess\u00e3o encerrada, favor logar-se novamente.
-
-dropDownChoiceField.nullValid=Escolha um
-todo=A fazer
-DateTimeField$HoursValidator=O seu valor precisa estar entre (1, 12)
-error=Erro
-generic_error=Um erro ocorreu durante a opera\u00e7\u00e3o
-id=Id
-name=Nome
-palette.available=Dispon\u00ed\u00advel
-palette.selected=Selecionado
-jexl_info=Este campo \u00e9 designado a uma express\u00e3o do tipo JEXL, por exemplo\:
-jexl_ex1=sobrenome + ',' + nome
-jexl_ex2='novo.' + sobrenome
-jexl_syntax_url=Refer\u00eancia JEXL completa
-create=Criar
-key=Chave
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeConsoleApplication.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeConsoleApplication.properties b/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeConsoleApplication.properties
new file mode 100644
index 0000000..a5fe511
--- /dev/null
+++ b/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeConsoleApplication.properties
@@ -0,0 +1,55 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+users=Users
+groups=Groups
+configuration=Configuration
+resources=Resources
+connectors=Connectors
+reports=Reports
+tasks=Tasks
+logout=Logout
+schema=Schema
+operation_succeeded=Operation executed successfully
+operation_error=Error occurred during the requested operation
+alert=Alert:
+confirmDelete=Do you really want to delete the selected item(s)?
+confirmUnlink=Do you really want to remove the link between the selected item(s) and the resource?
+confirmUnassign=Do you really want to remove the assignment between the selected item(s) and the resource?
+confirmDeprovision=Do you really want to de-provision the selected item(s)?
+confirmProvision=Do you really want to provision the selected item(s)?
+
+
+unauthorizedInstantiationException=Missing authorization.
+accessControlException=Missing authorization while contacting Syncope core.
+restClientException=Error while contacting Syncope core.
+pageExpiredException=Session expired: please login again.
+
+dropDownChoiceField.nullValid=Choose one
+todo=TODO
+DateTimeField$HoursValidator=Hour value must be in range (1, 12)
+error=Error
+generic_error=An error occurred during the operation
+id=Id
+name=Name
+palette.available=Available
+palette.selected=Selected
+jexl_info=This field expects a JEXL expression, for example:
+jexl_ex1=surname + ',' + firstname
+jexl_ex2='new.' + surname
+jexl_syntax_url=Full JEXL reference
+create=Create
+key=Key
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeConsoleApplication_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeConsoleApplication_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeConsoleApplication_it.properties
new file mode 100644
index 0000000..1f1e827
--- /dev/null
+++ b/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeConsoleApplication_it.properties
@@ -0,0 +1,54 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+users=Utenti
+groups=Gruppi
+configuration=Configurazione
+resources=Risorse
+connectors=Connettori
+reports=Rapporti
+logout=Logout
+schema=Schema
+tasks=Task
+operation_succeeded=Operazione eseguita con successo
+operation_error=Attenzione si \u00e8 verificato un errore durante l'esecuzione dell'operazione richiesta
+alert=Attenzione:
+confirmDelete=Vuoi davvero procedere con la cancellazione?
+confirmUnlink=Vuoi davvero procedere rimuovendo il link con la risorsa?
+confirmUnassign=Vuoi davvero procedere rimuovendo l'assegnamento sulla risorsa?
+confirmDeprovision=Vuoi davvero procedere con il de-provisioning?
+confirmProvision=Vuoi davvero procedere con il provisioning?
+
+unauthorizedInstantiationException=Autorizzazione mancante.
+accessControlException=Autorizzazione mancante durante la comunicazione con Syncope core.
+restClientException=Errore durante la comunicazione con Syncope core.
+pageExpiredException=Sessione scaduta: eseguire di nuovo l'accesso.
+
+dropDownChoiceField.nullValid=Seleziona
+todo=TODO
+DateTimeField$HoursValidator=L'ora deve essere nell'intervallo (1,12)
+error=Errore
+generic_error=Si \u00e8 verificato un errore durante l'operazione
+id=Id
+name=Nome
+palette.available=Opzioni
+palette.selected=Selezione
+jexl_info=In questo campo possono essere inserite espressioni di tipo JEXL, per esempio:
+jexl_ex1=surname + ',' + firstname
+jexl_ex2='new.' + surname
+jexl_syntax_url=Sintassi JEXL completa
+create=Crea
+key=Chiave
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeConsoleApplication_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeConsoleApplication_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeConsoleApplication_pt_BR.properties
new file mode 100644
index 0000000..de966d2
--- /dev/null
+++ b/client/console/src/main/resources/org/apache/syncope/client/console/SyncopeConsoleApplication_pt_BR.properties
@@ -0,0 +1,54 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+users=Usu\u00e1rios
+groups=Grupos
+configuration=Configura\u00e7\u00f5es
+resources=Recursos
+connectors=Conectores
+reports=Relat\u00f3rios
+tasks=Tarefas
+logout=Sair
+schema=Esquemas
+operation_succeeded=Opera\u00e7\u00e3o executada com sucesso
+operation_error=Um erro ocorreu ao executar esta opera\u00e7\u00e3o
+alert=Alerta:
+confirmDelete=Voc\u00ea realmente deseja apagar este item(s) selecionado?
+confirmUnlink=Voc\u00ea realmente deseja apagar o v\u00ednculo entre o item e de recursos?
+confirmUnassign=Voc\u00ea realmente deseja apagar a atribui\u00e7\u00e3o entre o item e de recursos?
+confirmDeprovision=Voc\u00ea realmente de-provision item?
+confirmProvision=Voc\u00ea realmente provision item?
+
+unauthorizedInstantiationException=Falta de autoriza\u00e7\u00e3o para concluir.
+accessControlException=Falta de autoriza\u00e7\u00e3o ao comunicar-se com o Syncope core.
+restClientException=Erro ao comunicar-se com o Syncope core.
+pageExpiredException=Sess\u00e3o encerrada, favor logar-se novamente.
+
+dropDownChoiceField.nullValid=Escolha um
+todo=A fazer
+DateTimeField$HoursValidator=O seu valor precisa estar entre (1, 12)
+error=Erro
+generic_error=Um erro ocorreu durante a opera\u00e7\u00e3o
+id=Id
+name=Nome
+palette.available=Dispon\u00ed\u00advel
+palette.selected=Selecionado
+jexl_info=Este campo \u00e9 designado a uma express\u00e3o do tipo JEXL, por exemplo\:
+jexl_ex1=sobrenome + ',' + nome
+jexl_ex2='novo.' + sobrenome
+jexl_syntax_url=Refer\u00eancia JEXL completa
+create=Criar
+key=Chave
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage.html
deleted file mode 100644
index 0c43c4b..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage.html
+++ /dev/null
@@ -1,122 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <link rel="stylesheet" type="text/css" href="css/bulk.css" media="all"/>
- <style>
- #dataTableSpan{
- display: block;
- clear: both;
- float: none;
- margin: 10px;
- padding-top: 10px;
- }
-
- #dataTableSpan table{
- width: 100%;
- }
-
- form#pwdMgtForm {
- border: 1px solid #AAAAAA;
- margin:10px;
- }
-
- div#changepwd {
- display: inline-row;
- margin-top: 5px;
- }
-
- div#changepwd div{
- display: table-cell;
- }
-
- div#changepwd div#label{
- padding-left: 5px;
- vertical-align: middle;
- font-family: Verdana,Arial,sans-serif;
- }
-
- div#password {
- display: inline-row;
- margin: 5px;
- }
-
- div#continue {
- display: inline-row;
- margin: 5px;
- }
-
- div#continue div{
- display: table-cell;
- }
-
- div#cancelBtmForm {
- padding-left: 5px;
- }
- </style>
- </wicket:head>
- <wicket:extend>
- <p class="ui-widget ui-corner-all ui-widget-header">
- <wicket:message key="title"/> <span wicket:id="displayName"/>
- </p>
- <span wicket:id="resourceDatatable" id="dataTableSpan">[resources]</span>
-
- <span wicket:id="pwdMgtFields">[password management]</span>
-
- <wicket:fragment wicket:id="pwdMgtFragment">
- <div wicket:id="pwdMgt">
- <form wicket:id="pwdMgtForm" id="pwdMgtForm">
- <div id="changepwd">
- <div id="value">
- <span wicket:id="changepwd">[changepwd]</span>
- </div>
- <div id="label">
- <label wicket:id="changePwdLabel">[Change password]</label>
- </div>
- </div>
-
- <div id="password">
- <input type="password" wicket:id="password" id="password" size="25" style="width: 180px" title="password"/>
- </div>
-
- <div id="password">
- <input type="password" wicket:id="confirm" id="confirm" size="25" style="width: 180px" title="confirm"/>
- </div>
-
- <div id="continue">
- <div id="continueBtmForm">
- <input type="button" wicket:id="continue" id="continue"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"/>
- </div>
-
- <div id="cancelBtmForm">
- <input type="button" wicket:id="cancel" id="cancel"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"/>
- </div>
- </div>
- </form>
- </div>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="emptyFragment">
- </wicket:fragment>
-
- <wicket:child />
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage.properties
deleted file mode 100644
index 0f1fcdc..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Global Status
-changePwdLabel=Password propagation
-passwordMismatch=Password mismatch
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage_it.properties
deleted file mode 100644
index e5619e2..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage_it.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Stato Globale
-changePwdLabel=Propagazione password
-passwordMismatch=Password non corrispondenti
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage_pt_BR.properties
deleted file mode 100644
index 36d86e8..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage_pt_BR.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Estatus Global
-changePwdLabel=Password propagation
-passwordMismatch=Password mismatch
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ActivitiModelerPopupPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ActivitiModelerPopupPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ActivitiModelerPopupPage.html
deleted file mode 100644
index 789538f..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ActivitiModelerPopupPage.html
+++ /dev/null
@@ -1,65 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml"
- xmlns:b3mn="http://b3mn.org/2007/b3mn"
- xmlns:ext="http://b3mn.org/2007/ext"
- xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
- xmlns:atom="http://b3mn.org/2007/atom+xhtml">
- <head profile="http://purl.org/NET/erdf/profile">
- <title>Apache Syncope / Activiti Modeler</title>
- <!-- libraries -->
- <script src="activiti-modeler/libs/prototype-1.5.1.js" type="text/javascript"></script>
- <script src="activiti-modeler/libs/path_parser.js" type="text/javascript"></script>
- <script src="activiti-modeler/libs/ext-2.0.2/adapter/ext/ext-base.js" type="text/javascript"></script>
- <script src="activiti-modeler/libs/ext-2.0.2/ext-all-debug.js" type="text/javascript"></script>
- <script src="activiti-modeler/libs/ext-2.0.2/color-field.js" type="text/javascript"></script>
- <link rel="Stylesheet" media="screen" href="activiti-modeler/libs/ext-2.0.2/resources/css/ext-all.css" type="text/css"></link>
- <link rel="Stylesheet" media="screen" href="activiti-modeler/libs/ext-2.0.2/resources/css/xtheme-darkgray.css" type="text/css"></link>
- <link rel="Stylesheet" media="screen" href="activiti-modeler/editor/css/theme_norm.css" type="text/css"></link>
- <link rel="Stylesheet" media="screen" href="activiti-modeler/editor/css/theme_norm_signavio.css" type="text/css"></link>
- <link rel="Stylesheet" media="screen" href="activiti-modeler/explorer/src/css/xtheme-smoky.css" type="text/css"></link>
- <link rel="Stylesheet" media="screen" href="activiti-modeler/explorer/src/css/custom-style.css" type="text/css"></link>
- <!-- oryx editor -->
- <!-- language files -->
- <script src="activiti-modeler/editor/i18n/translation_en_us.js" type="text/javascript"></script>
- <script src="activiti-modeler/editor/i18n/translation_signavio_en_us.js" type="text/javascript"></script>
- <script src="activiti-modeler/libs/utils.js" type="text/javascript"></script>
- <script src="activiti-modeler/editor/oryx.debug.js" type="text/javascript"></script>
- <!-- erdf schemas -->
- <link rel="schema.dc" href="http://purl.org/dc/elements/1.1/"></link>
- <link rel="schema.dcTerms" href="http://purl.org/dc/terms/"></link>
- <link rel="schema.b3mn" href="http://b3mn.org"></link>
- <link rel="schema.oryx" href="http://oryx-editor.org/"></link>
- <link rel="schema.raziel" href="http://raziel.org/"></link>
-
- <script type="text/javascript">
- window.onunload = refreshParent;
- function refreshParent() {
- if (window.opener.location.toString().indexOf('#workflow') === -1) {
- window.opener.location = window.opener.location + "#workflow";
- }
- window.opener.location.reload();
- }
- </script>
- </head>
- <body style="overflow:hidden;">
- </body>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage.html
deleted file mode 100644
index be1a4b0..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage.html
+++ /dev/null
@@ -1,52 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
- <div style="margin: 5px;">
- <form wicket:id="form">
- <div id="formtable">
- <div class="tablerow" wicket:id="propView">
- <div class="tablecolumn_label medium_dynamicsize">
- <span wicket:id="key">[key]</span>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="value">[value]</span>
-
- </div>
- </div>
- </div>
-
- <div style="margin: 20px 0">
- <input type="button"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="userDetails"/>
- <input type="submit"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="apply"/>
- <input type="button"
- accept=""class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="cancel"/>
- </div>
-
- </form>
- <div wicket:id="editUserWin">[Show modal window for editing user under approval]</div>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage.properties
deleted file mode 100644
index 547f13f..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Approval form
-userDetails=User details
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage_it.properties
deleted file mode 100644
index a2a7134..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage_it.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Form di approvazione
-userDetails=Dettagli utente
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage_pt_BR.properties
deleted file mode 100644
index 954d365..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage_pt_BR.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Formul\u00E1rio de Aprova\u00E7\u00E3o
-userDetails=Detalhes do Usu\u00E1rio
[44/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/Resources.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/Resources.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/Resources.java
deleted file mode 100644
index 542cc82..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/Resources.java
+++ /dev/null
@@ -1,723 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.PreferenceManager;
-import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
-import org.apache.syncope.client.console.panels.AbstractSearchResultPanel;
-import org.apache.syncope.client.console.panels.AjaxDataTablePanel;
-import org.apache.syncope.client.console.rest.ConnectorRestClient;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.LinkPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.ConnInstanceTO;
-import org.apache.syncope.common.lib.to.ResourceTO;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.AttributeModifier;
-import org.apache.wicket.Component;
-import org.apache.wicket.Page;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.attributes.AjaxCallListener;
-import org.apache.wicket.ajax.attributes.AjaxRequestAttributes;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.ISortableDataProvider;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.AbstractReadOnlyModel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.StringResourceModel;
-import org.apache.wicket.request.mapper.parameter.PageParameters;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-/**
- * Resources WebPage.
- */
-public class Resources extends BasePage {
-
- private static final long serialVersionUID = -3789252860990261728L;
-
- private static final int WIN_HEIGHT = 600;
-
- private static final int WIN_WIDTH = 1100;
-
- @SpringBean
- private ConnectorRestClient connectorRestClient;
-
- @SpringBean
- private PreferenceManager prefMan;
-
- private final ModalWindow createResourceWin;
-
- private final ModalWindow editResourceWin;
-
- private final ModalWindow createConnectorWin;
-
- private final ModalWindow editConnectorWin;
-
- private final int resourcePaginatorRows;
-
- private final int connectorPaginatorRows;
-
- private WebMarkupContainer resourceContainer;
-
- private WebMarkupContainer connectorContainer;
-
- /**
- * Modal window to be used for user status management.
- */
- protected final ModalWindow statusmodal = new ModalWindow("statusModal");
-
- /**
- * Schemas to be shown modal window height.
- */
- private final static int STATUS_MODAL_WIN_HEIGHT = 500;
-
- /**
- * Schemas to be shown modal window width.
- */
- private final static int STATUS_MODAL_WIN_WIDTH = 700;
-
- public Resources(final PageParameters parameters) {
- super(parameters);
-
- add(createResourceWin = new ModalWindow("createResourceWin"));
- add(editResourceWin = new ModalWindow("editResourceWin"));
- add(createConnectorWin = new ModalWindow("createConnectorWin"));
- add(editConnectorWin = new ModalWindow("editConnectorWin"));
-
- statusmodal.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- statusmodal.setInitialHeight(STATUS_MODAL_WIN_HEIGHT);
- statusmodal.setInitialWidth(STATUS_MODAL_WIN_WIDTH);
- statusmodal.setCookieName("status-modal");
- add(statusmodal);
-
- AjaxLink<Void> reloadLink = new ClearIndicatingAjaxLink<Void>("reloadLink", getPageReference()) {
-
- private static final long serialVersionUID = 3109256773218160485L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- try {
- connectorRestClient.reload();
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (Exception e) {
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- }
- feedbackPanel.refresh(target);
- target.add(connectorContainer);
- }
-
- @Override
- protected void updateAjaxAttributes(final AjaxRequestAttributes attributes) {
- super.updateAjaxAttributes(attributes);
-
- final AjaxCallListener ajaxCallListener = new AjaxCallListener() {
-
- private static final long serialVersionUID = 7160235486520935153L;
-
- @Override
- public CharSequence getPrecondition(final Component component) {
- return "if (!confirm('" + getString("confirmReloadConnectors") + "')) "
- + "{return false;} else {return true;}";
- }
- };
- attributes.getAjaxCallListeners().add(ajaxCallListener);
- }
- };
- MetaDataRoleAuthorizationStrategy.authorize(reloadLink, ENABLE, xmlRolesReader.getEntitlement(
- "Connectors", "reload"));
- add(reloadLink);
-
- resourcePaginatorRows = prefMan.getPaginatorRows(getRequest(), Constants.PREF_RESOURCES_PAGINATOR_ROWS);
- connectorPaginatorRows = prefMan.getPaginatorRows(getRequest(), Constants.PREF_CONNECTORS_PAGINATOR_ROWS);
-
- setupResources();
- setupConnectors();
- }
-
- private void setupResources() {
- List<IColumn<ResourceTO, String>> columns = new ArrayList<>();
-
- columns.add(new PropertyColumn<ResourceTO, String>(new StringResourceModel("key", this, null), "key", "key"));
-
- columns.add(new AbstractColumn<ResourceTO, String>(
- new StringResourceModel("connector", this, null, "connector")) {
-
- private static final long serialVersionUID = 8263694778917279290L;
-
- @Override
- public void populateItem(final Item<ICellPopulator<ResourceTO>> cellItem, final String componentId,
- final IModel<ResourceTO> rowModel) {
-
- final AjaxLink<String> editLink =
- new ClearIndicatingAjaxLink<String>("link", getPageReference()) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
-
- editConnectorWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ConnectorModalPage(Resources.this.getPageReference(),
- editConnectorWin,
- connectorRestClient.read(rowModel.getObject().getConnectorId()));
- }
- });
-
- editConnectorWin.show(target);
- }
- };
- editLink.add(new Label("linkTitle", rowModel.getObject().getConnectorDisplayName()));
-
- LinkPanel editConnPanel = new LinkPanel(componentId);
- editConnPanel.add(editLink);
-
- cellItem.add(editConnPanel);
-
- MetaDataRoleAuthorizationStrategy.authorize(editConnPanel, ENABLE, xmlRolesReader.
- getEntitlement(
- "Connectors", "read"));
- }
- });
-
- columns.add(new AbstractColumn<ResourceTO, String>(
- new StringResourceModel("propagationPrimary", this, null)) {
-
- private static final long serialVersionUID = -3503023501954863131L;
-
- @Override
- public void populateItem(final Item<ICellPopulator<ResourceTO>> item,
- final String componentId, final IModel<ResourceTO> model) {
-
- item.add(new Label(componentId, ""));
- item.add(new AttributeModifier("class", new Model<>(
- Boolean.toString(model.getObject().isPropagationPrimary()))));
- }
-
- @Override
- public String getCssClass() {
- return "narrowcolumn";
- }
- });
-
- columns.add(new PropertyColumn<ResourceTO, String>(new StringResourceModel(
- "propagationPriority", this, null), "propagationPriority", "propagationPriority") {
-
- @Override
- public String getCssClass() {
- return "narrowcolumn";
- }
- });
-
- columns.add(new AbstractColumn<ResourceTO, String>(new StringResourceModel("actions", this, null, "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public String getCssClass() {
- return "action";
- }
-
- @Override
- public void populateItem(final Item<ICellPopulator<ResourceTO>> cellItem, final String componentId,
- final IModel<ResourceTO> model) {
-
- final ResourceTO resourceTO = model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- statusmodal.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ProvisioningModalPage<>(
- getPageReference(), statusmodal, model.getObject(), UserTO.class);
- }
- });
-
- statusmodal.show(target);
- }
- }, ActionLink.ActionType.MANAGE_USERS, "Resources");
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
-
- statusmodal.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ProvisioningModalPage<>(
- getPageReference(), statusmodal, model.getObject(), GroupTO.class);
- }
- });
-
- statusmodal.show(target);
- }
- }, ActionLink.ActionType.MANAGE_GROUPS, "Resources");
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- resourceTO.setUsyncToken(null);
- resourceTO.setRsyncToken(null);
- try {
- resourceRestClient.update(resourceTO);
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException e) {
- error(getString(Constants.ERROR) + ":" + e.getMessage());
-
- LOG.error("While resetting sync token from " + resourceTO.getKey(), e);
- }
-
- feedbackPanel.refresh(target);
- target.add(resourceContainer);
- }
- }, ActionLink.ActionType.RESET, "Resources");
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- editResourceWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ResourceModalPage(Resources.this.getPageReference(),
- editResourceWin, resourceTO, false);
- }
- });
-
- editResourceWin.show(target);
- }
- }, ActionLink.ActionType.EDIT, "Resources");
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- resourceRestClient.delete(resourceTO.getKey());
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException e) {
- error(getString(Constants.ERROR) + ": " + e.getMessage());
-
- LOG.error("While deleting resource " + resourceTO.getKey(), e);
- }
-
- feedbackPanel.refresh(target);
- target.add(resourceContainer);
- }
- }, ActionLink.ActionType.DELETE, "Resources");
-
- cellItem.add(panel);
- }
- });
-
- final AjaxDataTablePanel<ResourceTO, String> table = new AjaxDataTablePanel<>(
- "resourceDatatable",
- columns,
- (ISortableDataProvider<ResourceTO, String>) new ResourcesProvider(),
- resourcePaginatorRows,
- Arrays.asList(new ActionLink.ActionType[] { ActionLink.ActionType.DELETE }),
- resourceRestClient,
- "key",
- "Resources",
- getPageReference());
-
- resourceContainer = new WebMarkupContainer("resourceContainer");
- resourceContainer.add(table);
- resourceContainer.setOutputMarkupId(true);
-
- add(resourceContainer);
-
- setWindowClosedCallback(createResourceWin, resourceContainer);
- setWindowClosedCallback(editResourceWin, resourceContainer);
-
- createResourceWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- createResourceWin.setInitialHeight(WIN_HEIGHT);
- createResourceWin.setInitialWidth(WIN_WIDTH);
- createResourceWin.setCookieName("create-res-modal");
-
- editResourceWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- editResourceWin.setInitialHeight(WIN_HEIGHT);
- editResourceWin.setInitialWidth(WIN_WIDTH);
- editResourceWin.setCookieName("edit-res-modal");
-
- AjaxLink<Void> createResourceLink =
- new ClearIndicatingAjaxLink<Void>("createResourceLink", getPageReference()) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- createResourceWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- final ResourceModalPage windows = new ResourceModalPage(Resources.this.
- getPageReference(),
- editResourceWin, new ResourceTO(), true);
- return windows;
- }
- });
-
- createResourceWin.show(target);
- }
- };
-
- MetaDataRoleAuthorizationStrategy.authorize(createResourceLink, ENABLE, xmlRolesReader.getEntitlement(
- "Resources", "create"));
-
- add(createResourceLink);
-
- @SuppressWarnings("rawtypes")
- final Form paginatorForm = new Form("resourcePaginatorForm");
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- final DropDownChoice rowsChooser = new DropDownChoice("rowsChooser", new PropertyModel(this,
- "resourcePaginatorRows"), prefMan.getPaginatorChoices());
-
- rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- prefMan.set(getRequest(), getResponse(), Constants.PREF_RESOURCES_PAGINATOR_ROWS,
- String.valueOf(resourcePaginatorRows));
-
- table.setItemsPerPage(resourcePaginatorRows);
- target.add(resourceContainer);
- }
- });
-
- paginatorForm.add(rowsChooser);
- add(paginatorForm);
- }
-
- private void setupConnectors() {
- List<IColumn<ConnInstanceTO, String>> columns = new ArrayList<>();
-
- columns.add(new PropertyColumn<ConnInstanceTO, String>(
- new StringResourceModel("key", this, null), "key", "key"));
- columns.add(new PropertyColumn<ConnInstanceTO, String>(
- new StringResourceModel("name", this, null), "connectorName", "connectorName"));
- columns.add(new PropertyColumn<ConnInstanceTO, String>(
- new StringResourceModel("displayName", this, null), "displayName", "displayName"));
- columns.add(new PropertyColumn<ConnInstanceTO, String>(
- new StringResourceModel("bundleName", this, null), "bundleName", "bundleName"));
- columns.add(new PropertyColumn<ConnInstanceTO, String>(
- new StringResourceModel("version", this, null), "version", "version"));
- columns.add(new AbstractColumn<ConnInstanceTO, String>(new StringResourceModel("actions", this, null, "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public String getCssClass() {
- return "action";
- }
-
- @Override
- public void populateItem(final Item<ICellPopulator<ConnInstanceTO>> cellItem, final String componentId,
- final IModel<ConnInstanceTO> model) {
-
- final ConnInstanceTO connectorTO = model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- editConnectorWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ConnectorModalPage(Resources.this.getPageReference(), editConnectorWin,
- connectorTO);
- }
- });
-
- editConnectorWin.show(target);
- }
- }, ActionLink.ActionType.EDIT, "Connectors");
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- connectorRestClient.delete(connectorTO.getKey());
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException e) {
- error(getString(Constants.ERROR) + ": " + e.getMessage());
-
- LOG.error("While deleting connector " + connectorTO.getKey(), e);
- }
-
- target.add(connectorContainer);
- feedbackPanel.refresh(target);
- }
- }, ActionLink.ActionType.DELETE, "Connectors");
-
- cellItem.add(panel);
- }
- });
-
- final AjaxDataTablePanel<ConnInstanceTO, String> table = new AjaxDataTablePanel<ConnInstanceTO, String>(
- "connectorDatatable",
- columns,
- (ISortableDataProvider<ConnInstanceTO, String>) new ConnectorsProvider(),
- connectorPaginatorRows,
- Arrays.asList(new ActionLink.ActionType[] { ActionLink.ActionType.DELETE }),
- connectorRestClient,
- "key",
- "Connectors",
- getPageReference());
-
- connectorContainer = new WebMarkupContainer("connectorContainer");
- connectorContainer.add(table);
- connectorContainer.setOutputMarkupId(true);
-
- MetaDataRoleAuthorizationStrategy.authorize(connectorContainer, RENDER, xmlRolesReader.getEntitlement(
- "Connectors", "list"));
-
- add(connectorContainer);
-
- setWindowClosedCallback(createConnectorWin, connectorContainer);
- setWindowClosedCallback(editConnectorWin, connectorContainer);
-
- createConnectorWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- createConnectorWin.setInitialHeight(WIN_HEIGHT);
- createConnectorWin.setInitialWidth(WIN_WIDTH);
- createConnectorWin.setCookieName("create-conn-modal");
-
- editConnectorWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- editConnectorWin.setInitialHeight(WIN_HEIGHT);
- editConnectorWin.setInitialWidth(WIN_WIDTH);
- editConnectorWin.setCookieName("edit-conn-modal");
-
- AjaxLink<Void> createConnectorLink =
- new ClearIndicatingAjaxLink<Void>("createConnectorLink", getPageReference()) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- createConnectorWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- ConnectorModalPage form = new ConnectorModalPage(Resources.this.getPageReference(),
- editConnectorWin, new ConnInstanceTO());
- return form;
- }
- });
-
- createConnectorWin.show(target);
- }
- };
-
- MetaDataRoleAuthorizationStrategy.authorize(createConnectorLink, ENABLE, xmlRolesReader.getEntitlement(
- "Connectors", "create"));
-
- add(createConnectorLink);
-
- @SuppressWarnings("rawtypes")
- Form paginatorForm = new Form("connectorPaginatorForm");
-
- MetaDataRoleAuthorizationStrategy.authorize(paginatorForm, RENDER, xmlRolesReader.getEntitlement(
- "Connectors", "list"));
-
- final DropDownChoice<Integer> rowsChooser = new DropDownChoice<Integer>(
- "rowsChooser",
- new PropertyModel<Integer>(this,
- "connectorPaginatorRows"),
- prefMan.getPaginatorChoices());
-
- rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(AjaxRequestTarget target) {
- prefMan.set(getRequest(), getResponse(), Constants.PREF_CONNECTORS_PAGINATOR_ROWS,
- String.valueOf(connectorPaginatorRows));
- table.setItemsPerPage(connectorPaginatorRows);
-
- target.add(connectorContainer);
- }
- });
-
- paginatorForm.add(rowsChooser);
- add(paginatorForm);
- }
-
- class ResourcesProvider extends SortableDataProvider<ResourceTO, String> {
-
- private static final long serialVersionUID = -9055916672926643975L;
-
- private final SortableDataProviderComparator<ResourceTO> comparator;
-
- public ResourcesProvider() {
- super();
- //Default sorting
- setSort("key", SortOrder.ASCENDING);
- comparator = new SortableDataProviderComparator<>(this);
- }
-
- @Override
- public Iterator<ResourceTO> iterator(final long first, final long count) {
- List<ResourceTO> list = resourceRestClient.getAll();
-
- Collections.sort(list, comparator);
-
- return list.subList((int) first, (int) first + (int) count).iterator();
- }
-
- @Override
- public long size() {
- return resourceRestClient.getAll().size();
- }
-
- @Override
- public IModel<ResourceTO> model(final ResourceTO resource) {
- return new AbstractReadOnlyModel<ResourceTO>() {
-
- private static final long serialVersionUID = 8952474152465381634L;
-
- @Override
- public ResourceTO getObject() {
- return resource;
- }
- };
- }
- }
-
- private class ConnectorsProvider extends SortableDataProvider<ConnInstanceTO, String> {
-
- private static final long serialVersionUID = 4445909568349448518L;
-
- private final SortableDataProviderComparator<ConnInstanceTO> comparator;
-
- public ConnectorsProvider() {
- super();
- //Default sorting
- setSort("key", SortOrder.ASCENDING);
- comparator = new SortableDataProviderComparator<>(this);
- }
-
- @Override
- public Iterator<ConnInstanceTO> iterator(long first, long count) {
- List<ConnInstanceTO> list = connectorRestClient.getAllConnectors();
-
- Collections.sort(list, comparator);
-
- return list.subList((int) first, (int) first + (int) count).iterator();
- }
-
- @Override
- public long size() {
- return connectorRestClient.getAllConnectors().size();
- }
-
- @Override
- public IModel<ConnInstanceTO> model(final ConnInstanceTO connector) {
-
- return new AbstractReadOnlyModel<ConnInstanceTO>() {
-
- private static final long serialVersionUID = -6033068018293569398L;
-
- @Override
- public ConnInstanceTO getObject() {
- return connector;
- }
- };
- }
- }
-
- @Override
- public void onEvent(final IEvent<?> event) {
- if (event.getPayload() instanceof AbstractSearchResultPanel.EventDataWrapper) {
- ((AbstractSearchResultPanel.EventDataWrapper) event.getPayload()).getTarget().add(resourceContainer);
- ((AbstractSearchResultPanel.EventDataWrapper) event.getPayload()).getTarget().add(connectorContainer);
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/ResultStatusModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/ResultStatusModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/ResultStatusModalPage.java
deleted file mode 100644
index e5017e3..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/ResultStatusModalPage.java
+++ /dev/null
@@ -1,424 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.commons.ConnIdSpecialAttributeName;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.Mode;
-import org.apache.syncope.client.console.commons.status.Status;
-import org.apache.syncope.client.console.commons.status.StatusUtils;
-import org.apache.syncope.common.lib.to.AbstractSubjectTO;
-import org.apache.syncope.common.lib.to.AttrTO;
-import org.apache.syncope.common.lib.to.ConnObjectTO;
-import org.apache.syncope.common.lib.to.PropagationStatus;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.syncope.common.lib.types.PropagationTaskExecStatus;
-import org.apache.wicket.Component;
-import org.apache.wicket.Page;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.behavior.Behavior;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.ComponentTag;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.image.Image;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.markup.html.panel.Fragment;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.request.resource.ContextRelativeResource;
-
-/**
- * Show user or group status after performing a successful operation.
- */
-public class ResultStatusModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = 2646115294319713723L;
-
- private static final String IMG_PREFIX = "/img/statuses/";
-
- private final AbstractSubjectTO subject;
-
- private final Mode mode;
-
- /**
- * Status management utilities.
- */
- private final StatusUtils statusUtils;
-
- public static class Builder implements Serializable {
-
- private static final long serialVersionUID = 220361441802274899L;
-
- private ModalWindow window;
-
- private Mode mode;
-
- private AbstractSubjectTO subject;
-
- public Builder(final ModalWindow window, final AbstractSubjectTO attributable) {
- this.window = window;
- this.subject = attributable;
- }
-
- public ResultStatusModalPage.Builder mode(final Mode mode) {
- this.mode = mode;
- return this;
- }
-
- public ResultStatusModalPage build() {
- return new ResultStatusModalPage(this);
- }
- }
-
- private ResultStatusModalPage(final Builder builder) {
- super();
- this.subject = builder.subject;
- statusUtils = new StatusUtils(this.userRestClient);
- if (builder.mode == null) {
- this.mode = Mode.ADMIN;
- } else {
- this.mode = builder.mode;
- }
-
- final BaseModalPage page = this;
-
- final WebMarkupContainer container = new WebMarkupContainer("container");
- container.setOutputMarkupId(true);
- add(container);
-
- final Fragment fragment = new Fragment("resultFrag", mode == Mode.SELF
- ? "userSelfResultFrag"
- : "propagationResultFrag", this);
- fragment.setOutputMarkupId(true);
- container.add(fragment);
-
- if (mode == Mode.ADMIN) {
- // add Syncope propagation status
- PropagationStatus syncope = new PropagationStatus();
- syncope.setResource("Syncope");
- syncope.setStatus(PropagationTaskExecStatus.SUCCESS);
-
- List<PropagationStatus> propagations = new ArrayList<PropagationStatus>();
- propagations.add(syncope);
- propagations.addAll(subject.getPropagationStatusTOs());
-
- fragment.add(new Label("info",
- ((subject instanceof UserTO) && ((UserTO) subject).getUsername() != null)
- ? ((UserTO) subject).getUsername()
- : ((subject instanceof GroupTO) && ((GroupTO) subject).getName() != null)
- ? ((GroupTO) subject).getName()
- : String.valueOf(subject.getKey())));
-
- final ListView<PropagationStatus> propRes = new ListView<PropagationStatus>("resources",
- propagations) {
-
- private static final long serialVersionUID = -1020475259727720708L;
-
- @Override
- protected void populateItem(final ListItem<PropagationStatus> item) {
- final PropagationStatus propTO = (PropagationStatus) item.getDefaultModelObject();
-
- final ListView attributes = getConnObjectView(propTO);
-
- final Fragment attrhead;
- if (attributes.getModelObject() == null || attributes.getModelObject().isEmpty()) {
- attrhead = new Fragment("attrhead", "emptyAttrHeadFrag", page);
- } else {
- attrhead = new Fragment("attrhead", "attrHeadFrag", page);
- }
-
- item.add(attrhead);
- item.add(attributes);
-
- attrhead.add(new Label("resource", propTO.getResource()));
-
- attrhead.add(new Label("propagation", propTO.getStatus() == null
- ? "UNDEFINED" : propTO.getStatus().toString()));
-
- final Image image;
- final String alt, title;
- final ModalWindow failureWindow = new ModalWindow("failureWindow");
- final AjaxLink<?> failureWindowLink = new AjaxLink<Void>("showFailureWindow") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(AjaxRequestTarget target) {
- failureWindow.show(target);
- }
- };
-
- switch (propTO.getStatus()) {
-
- case SUCCESS:
- case SUBMITTED:
- case CREATED:
- image = new Image("icon",
- new ContextRelativeResource(IMG_PREFIX + Status.ACTIVE.toString()
- + Constants.PNG_EXT));
- alt = "success icon";
- title = "success";
- failureWindow.setVisible(false);
- failureWindowLink.setEnabled(false);
- break;
-
- default:
- image = new Image("icon",
- new ContextRelativeResource(IMG_PREFIX + Status.SUSPENDED.toString()
- + Constants.PNG_EXT));
- alt = "failure icon";
- title = "failure";
- }
-
- image.add(new Behavior() {
-
- private static final long serialVersionUID = 1469628524240283489L;
-
- @Override
- public void onComponentTag(final Component component, final ComponentTag tag) {
- tag.put("alt", alt);
- tag.put("title", title);
- }
- });
- final FailureMessageModalPage executionFailureMessagePage;
- if (propTO.getFailureReason() == null) {
- executionFailureMessagePage =
- new FailureMessageModalPage(failureWindow.getContentId(), StringUtils.EMPTY);
- } else {
- executionFailureMessagePage =
- new FailureMessageModalPage(failureWindow.getContentId(), propTO.getFailureReason());
- }
-
- failureWindow.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return executionFailureMessagePage;
- }
- });
- failureWindow.setCookieName("failureWindow");
- failureWindow.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- failureWindowLink.add(image);
- attrhead.add(failureWindowLink);
- attrhead.add(failureWindow);
- }
- };
- fragment.add(propRes);
- }
-
- final AjaxLink<Void> close = new IndicatingAjaxLink<Void>("close") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- builder.window.close(target);
- }
- };
- container.add(close);
-
- setOutputMarkupId(true);
- }
-
- /**
- * Get remote attributes list view.
- *
- * @param propTO propagation TO.
- * @return list view.
- */
- private ListView<String> getConnObjectView(final PropagationStatus propTO) {
- final ConnObjectTO before = propTO.getBeforeObj();
- final ConnObjectTO after = propTO.getAfterObj();
-
- // sorted in reversed presentation order
- final List<String> head = new ArrayList<String>();
- if (subject instanceof UserTO) {
- head.add(ConnIdSpecialAttributeName.PASSWORD);
- head.add(ConnIdSpecialAttributeName.ENABLE);
- }
- head.add(ConnIdSpecialAttributeName.UID);
- head.add(ConnIdSpecialAttributeName.NAME);
-
- final Map<String, AttrTO> beforeAttrMap = before == null
- ? Collections.<String, AttrTO>emptyMap()
- : before.getPlainAttrMap();
-
- final Map<String, AttrTO> afterAttrMap = after == null
- ? Collections.<String, AttrTO>emptyMap()
- : after.getPlainAttrMap();
-
- final Set<String> attributes = new HashSet<String>();
- attributes.addAll(beforeAttrMap.keySet());
- attributes.addAll(afterAttrMap.keySet());
-
- if (!(subject instanceof UserTO)) {
- attributes.remove(ConnIdSpecialAttributeName.PASSWORD);
- attributes.remove(ConnIdSpecialAttributeName.ENABLE);
- }
-
- final List<String> profile = new ArrayList<String>();
- profile.addAll(attributes);
- profile.removeAll(head);
- Collections.sort(profile);
-
- for (String attr : head) {
- if (attributes.contains(attr)) {
- profile.add(0, attr);
- }
- }
-
- return new ListView<String>("attrs", profile) {
-
- private static final long serialVersionUID = 4949588177564901031L;
-
- @Override
- protected void populateItem(final ListItem<String> item) {
- String name = item.getModelObject();
-
- final Fragment beforeValue;
- final Fragment afterValue;
- if (ConnIdSpecialAttributeName.ENABLE.equals(name)) {
- beforeValue = getStatusIcon("beforeValue", propTO.getResource(), before);
- afterValue = getStatusIcon("afterValue", propTO.getResource(), after);
- } else {
- beforeValue = getLabelValue("beforeValue", name, beforeAttrMap);
- afterValue = getLabelValue("afterValue", name, afterAttrMap);
- }
-
- item.add(new Label("attrName", new ResourceModel(name, name)));
-
- item.add(beforeValue);
- item.add(afterValue);
- }
- };
- }
-
- /**
- * Get fragment for attribute value (not remote status).
- *
- * @param id component id to be replaced with the fragment content.
- * @param attrName remote attribute name
- * @param attrMap remote attributes map.
- * @return fragment.
- */
- private Fragment getLabelValue(final String id, final String attrName, final Map<String, AttrTO> attrMap) {
- final String value;
-
- final AttrTO attr = attrMap.get(attrName);
-
- if (attr == null || attr.getValues() == null || attr.getValues().isEmpty()) {
- value = "";
- } else {
- if (ConnIdSpecialAttributeName.PASSWORD.equals(attrName)) {
- value = "********";
- } else {
- value = attr.getValues().size() > 1
- ? attr.getValues().toString()
- : attr.getValues().get(0);
- }
- }
-
- Component label = new Label("value", value.length() > 50 ? value.substring(0, 50) + "..." : value).
- add(new Behavior() {
-
- private static final long serialVersionUID = 1469628524240283489L;
-
- @Override
- public void onComponentTag(final Component component, final ComponentTag tag) {
- tag.put("title", value);
- }
- });
-
- final Fragment frag = new Fragment(id, "attrValueFrag", this);
- frag.add(label);
-
- return frag;
- }
-
- /**
- * Get fragment for user status icon.
- *
- * @param id component id to be replaced with the fragment content
- * @param resourceName resource name
- * @param objectTO connector object TO
- * @return fragment.
- */
- private Fragment getStatusIcon(final String id, final String resourceName, final ConnObjectTO objectTO) {
- final Image image;
- final String alt, title;
- switch (statusUtils.getStatusBean(subject, resourceName, objectTO, this.subject instanceof GroupTO).getStatus()) {
-
- case ACTIVE:
- image = new Image("status",
- new ContextRelativeResource(IMG_PREFIX + Status.ACTIVE.toString() + Constants.PNG_EXT));
- alt = "active icon";
- title = "Enabled";
- break;
-
- case SUSPENDED:
- image = new Image("status",
- new ContextRelativeResource(IMG_PREFIX + Status.SUSPENDED.toString() + Constants.PNG_EXT));
- alt = "inactive icon";
- title = "Disabled";
- break;
-
- default:
- image = null;
- alt = null;
- title = null;
- }
-
- final Fragment frag;
- if (image == null) {
- frag = new Fragment(id, "emptyFrag", this);
- } else {
- image.add(new Behavior() {
-
- private static final long serialVersionUID = 1469628524240283489L;
-
- @Override
- public void onComponentTag(final Component component, final ComponentTag tag) {
- tag.put("alt", alt);
- tag.put("title", title);
- tag.put("width", "12px");
- tag.put("height", "12px");
- }
- });
-
- frag = new Fragment(id, "remoteStatusFrag", this);
- frag.add(image);
- }
-
- return frag;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/SchedTaskModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/SchedTaskModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/SchedTaskModalPage.java
deleted file mode 100644
index 6222717..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/SchedTaskModalPage.java
+++ /dev/null
@@ -1,68 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.List;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.common.lib.to.SchedTaskTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.model.PropertyModel;
-
-/**
- * Modal window with Task form (to stop and start execution).
- */
-public class SchedTaskModalPage extends AbstractSchedTaskModalPage {
-
- private static final long serialVersionUID = -2501860242590060867L;
-
- public SchedTaskModalPage(final ModalWindow window, final SchedTaskTO taskTO, final PageReference callerPageRef) {
-
- super(window, taskTO, callerPageRef);
-
- final IModel<List<String>> classNames = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- return taskRestClient.getJobClasses();
- }
- };
-
- final AjaxDropDownChoicePanel<String> className = new AjaxDropDownChoicePanel<String>("jobClassName",
- getString("class"), new PropertyModel<String>(taskTO, "jobClassName"));
- className.setChoices(classNames.getObject());
- className.addRequiredLabel();
- className.setEnabled(taskTO.getKey() == 0);
- className.setStyleSheet("ui-widget-content ui-corner-all long_dynamicsize");
- profile.add(className);
- }
-
- @Override
- public void submitAction(final SchedTaskTO taskTO) {
- if (taskTO.getKey() > 0) {
- taskRestClient.updateSchedTask(taskTO);
- } else {
- taskRestClient.createSchedTask(taskTO);
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/Schema.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/Schema.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/Schema.java
deleted file mode 100644
index cffb7cd..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/Schema.java
+++ /dev/null
@@ -1,468 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.lang.reflect.Field;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.commons.lang3.tuple.ImmutablePair;
-import org.apache.commons.lang3.tuple.Pair;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.PreferenceManager;
-import org.apache.syncope.client.console.commons.SchemaModalPageFactory;
-import org.apache.syncope.client.console.commons.SelectChoiceRenderer;
-import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
-import org.apache.syncope.client.console.panels.JQueryUITabbedPanel;
-import org.apache.syncope.client.console.rest.SchemaRestClient;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink.ActionType;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.common.lib.to.AbstractSchemaTO;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.syncope.common.lib.types.SchemaType;
-import org.apache.wicket.AttributeModifier;
-import org.apache.wicket.Page;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
-import org.apache.wicket.extensions.markup.html.tabs.AbstractTab;
-import org.apache.wicket.extensions.markup.html.tabs.ITab;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.springframework.beans.BeanWrapper;
-import org.springframework.beans.BeanWrapperImpl;
-import org.springframework.util.ReflectionUtils;
-
-/**
- * Schema WebPage.
- */
-@SuppressWarnings({ "unchecked", "rawtypes" })
-public class Schema extends BasePage {
-
- private static final long serialVersionUID = 8091922398776299403L;
-
- private static final Map<SchemaType, List<String>> COL_NAMES = new HashMap<SchemaType, List<String>>() {
-
- private static final long serialVersionUID = 3109256773218160485L;
-
- {
- put(SchemaType.PLAIN, Arrays.asList(new String[] { "key", "type",
- "mandatoryCondition", "uniqueConstraint", "multivalue", "readonly" }));
- put(SchemaType.DERIVED, Arrays.asList(new String[] { "key", "expression" }));
- put(SchemaType.VIRTUAL, Arrays.asList(new String[] { "key", "readonly" }));
- }
- };
-
- private static final Map<Pair<AttributableType, SchemaType>, String> PAGINATOR_ROWS_KEYS =
- new HashMap<Pair<AttributableType, SchemaType>, String>() {
-
- private static final long serialVersionUID = 3109256773218160485L;
-
- {
- put(new ImmutablePair<>(AttributableType.CONFIGURATION, SchemaType.PLAIN),
- Constants.PREF_CONF_SCHEMA_PAGINATOR_ROWS);
- put(new ImmutablePair<>(AttributableType.USER, SchemaType.PLAIN),
- Constants.PREF_USER_PLAIN_SCHEMA_PAGINATOR_ROWS);
- put(new ImmutablePair<>(AttributableType.USER, SchemaType.DERIVED),
- Constants.PREF_USER_DER_SCHEMA_PAGINATOR_ROWS);
- put(new ImmutablePair<>(AttributableType.USER, SchemaType.VIRTUAL),
- Constants.PREF_USER_VIR_SCHEMA_PAGINATOR_ROWS);
- put(new ImmutablePair<>(AttributableType.MEMBERSHIP, SchemaType.PLAIN),
- Constants.PREF_MEMBERSHIP_PLAIN_SCHEMA_PAGINATOR_ROWS);
- put(new ImmutablePair<>(AttributableType.MEMBERSHIP, SchemaType.DERIVED),
- Constants.PREF_MEMBERSHIP_DER_SCHEMA_PAGINATOR_ROWS);
- put(new ImmutablePair<>(AttributableType.MEMBERSHIP, SchemaType.VIRTUAL),
- Constants.PREF_MEMBERSHIP_VIR_SCHEMA_PAGINATOR_ROWS);
- put(new ImmutablePair<>(AttributableType.GROUP, SchemaType.PLAIN),
- Constants.PREF_GROUP_PLAIN_SCHEMA_PAGINATOR_ROWS);
- put(new ImmutablePair<>(AttributableType.GROUP, SchemaType.DERIVED),
- Constants.PREF_GROUP_DER_SCHEMA_PAGINATOR_ROWS);
- put(new ImmutablePair<>(AttributableType.GROUP, SchemaType.VIRTUAL),
- Constants.PREF_GROUP_VIR_SCHEMA_PAGINATOR_ROWS);
- }
- };
-
- private static final int WIN_WIDTH = 600;
-
- private static final int WIN_HEIGHT = 200;
-
- private static final int PLAIN_WIN_HEIGHT = 500;
-
- @SpringBean
- private SchemaRestClient restClient;
-
- @SpringBean
- private PreferenceManager prefMan;
-
- private final String allowedCreateRoles = xmlRolesReader.getEntitlement("Schema", "create");
-
- private final String allowedReadRoles = xmlRolesReader.getEntitlement("Schema", "read");
-
- private final String allowedDeleteRoles = xmlRolesReader.getEntitlement("Schema", "delete");
-
- public Schema() {
- super();
-
- for (final AttributableType attrType : AttributableType.values()) {
- final String attrTypeAsString = attrType.name().toLowerCase();
-
- List<ITab> tabs = new ArrayList<>();
-
- for (final SchemaType schemaType : SchemaType.values()) {
- if (attrType != AttributableType.CONFIGURATION || schemaType == SchemaType.PLAIN) {
- final String schemaTypeAsString = schemaType.name().toLowerCase();
-
- tabs.add(new AbstractTab(new Model<>(getString(schemaTypeAsString))) {
-
- private static final long serialVersionUID = -5861786415855103549L;
-
- @Override
- public WebMarkupContainer getPanel(final String panelId) {
- return new SchemaTypePanel(panelId, attrType, schemaType);
- }
- });
- }
- }
-
- add(new JQueryUITabbedPanel(attrTypeAsString + "Tabs", tabs));
- }
- }
-
- private <T extends AbstractSchemaModalPage> List<IColumn> getColumns(
- final WebMarkupContainer webContainer, final ModalWindow modalWindow,
- final AttributableType attributableType, final SchemaType schemaType,
- final Collection<String> fields) {
-
- List<IColumn> columns = new ArrayList<IColumn>();
-
- for (final String field : fields) {
- final Field clazzField = ReflectionUtils.findField(schemaType.getToClass(), field);
-
- if (clazzField != null) {
- if (clazzField.getType().equals(Boolean.class) || clazzField.getType().equals(boolean.class)) {
- columns.add(new AbstractColumn<AbstractSchemaTO, String>(new ResourceModel(field)) {
-
- private static final long serialVersionUID = 8263694778917279290L;
-
- @Override
- public void populateItem(final Item<ICellPopulator<AbstractSchemaTO>> item,
- final String componentId, final IModel<AbstractSchemaTO> model) {
-
- BeanWrapper bwi = new BeanWrapperImpl(model.getObject());
- Object obj = bwi.getPropertyValue(field);
-
- item.add(new Label(componentId, ""));
- item.add(new AttributeModifier("class", new Model<String>(obj.toString())));
- }
-
- @Override
- public String getCssClass() {
- return "small_fixedsize";
- }
- });
- } else {
- IColumn column = new PropertyColumn(new ResourceModel(field), field, field) {
-
- private static final long serialVersionUID = 3282547854226892169L;
-
- @Override
- public String getCssClass() {
- String css = super.getCssClass();
- if ("key".equals(field)) {
- css = StringUtils.isBlank(css)
- ? "medium_fixedsize"
- : css + " medium_fixedsize";
- }
- return css;
- }
- };
- columns.add(column);
- }
- }
- }
-
- columns.add(new AbstractColumn<AbstractSchemaTO, String>(new ResourceModel("actions", "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public String getCssClass() {
- return "action";
- }
-
- @Override
- public void populateItem(final Item<ICellPopulator<AbstractSchemaTO>> item, final String componentId,
- final IModel<AbstractSchemaTO> model) {
-
- final AbstractSchemaTO schemaTO = model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
-
- panel.addWithRoles(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- modalWindow.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- AbstractSchemaModalPage page = SchemaModalPageFactory.getSchemaModalPage(
- attributableType, schemaType);
-
- page.setSchemaModalPage(Schema.this.getPageReference(), modalWindow, schemaTO, false);
-
- return page;
- }
- });
-
- modalWindow.show(target);
- }
- }, ActionType.EDIT, allowedReadRoles);
-
- panel.addWithRoles(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
-
- switch (schemaType) {
- case DERIVED:
- restClient.deleteDerSchema(attributableType, schemaTO.getKey());
- break;
-
- case VIRTUAL:
- restClient.deleteVirSchema(attributableType, schemaTO.getKey());
- break;
-
- default:
- restClient.deletePlainSchema(attributableType, schemaTO.getKey());
- break;
- }
-
- info(getString(Constants.OPERATION_SUCCEEDED));
- feedbackPanel.refresh(target);
-
- target.add(webContainer);
- }
- }, ActionType.DELETE, allowedDeleteRoles);
-
- item.add(panel);
- }
- });
-
- return columns;
- }
-
- private Form<Void> getPaginatorForm(final WebMarkupContainer webContainer,
- final AjaxFallbackDefaultDataTable dataTable,
- final String formname, final SchemaTypePanel schemaTypePanel, final String rowsPerPagePrefName) {
-
- Form<Void> form = new Form<>(formname);
-
- final DropDownChoice<Integer> rowChooser = new DropDownChoice<Integer>("rowsChooser",
- new PropertyModel<Integer>(schemaTypePanel, "pageRows"), prefMan.getPaginatorChoices(),
- new SelectChoiceRenderer<Integer>());
-
- rowChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- prefMan.set(getRequest(), getResponse(), rowsPerPagePrefName, rowChooser.getInput());
- dataTable.setItemsPerPage(rowChooser.getModelObject());
-
- target.add(webContainer);
- }
- });
-
- form.add(rowChooser);
-
- return form;
- }
-
- private <T extends AbstractSchemaModalPage> AjaxLink<Void> getCreateSchemaLink(final ModalWindow modalWindow,
- final AttributableType attrType, final SchemaType schemaType, final String winLinkName) {
-
- AjaxLink<Void> link = new ClearIndicatingAjaxLink<Void>(winLinkName, getPageReference()) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- modalWindow.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- T page = SchemaModalPageFactory.getSchemaModalPage(attrType, schemaType);
- page.setSchemaModalPage(Schema.this.getPageReference(), modalWindow, null, true);
-
- return page;
- }
- });
-
- modalWindow.show(target);
- }
- };
-
- MetaDataRoleAuthorizationStrategy.authorize(link, ENABLE, allowedCreateRoles);
-
- return link;
-
- }
-
- private class SchemaProvider extends SortableDataProvider<AbstractSchemaTO, String> {
-
- private static final long serialVersionUID = -185944053385660794L;
-
- private final SortableDataProviderComparator<AbstractSchemaTO> comparator;
-
- private final AttributableType attrType;
-
- private final SchemaType schemaType;
-
- public SchemaProvider(final AttributableType attrType, final SchemaType schemaType) {
- super();
-
- this.attrType = attrType;
- this.schemaType = schemaType;
-
- // Default sorting
- setSort("key", SortOrder.ASCENDING);
-
- comparator = new SortableDataProviderComparator<>(this);
- }
-
- @Override
- public Iterator<AbstractSchemaTO> iterator(final long first, final long count) {
- @SuppressWarnings("unchecked")
- List<AbstractSchemaTO> list =
- (List<AbstractSchemaTO>) restClient.getSchemas(this.attrType, this.schemaType);
-
- Collections.sort(list, comparator);
-
- return list.subList((int) first, (int) first + (int) count).iterator();
- }
-
- @Override
- public long size() {
- return restClient.getSchemas(this.attrType, this.schemaType).size();
- }
-
- @Override
- public IModel<AbstractSchemaTO> model(final AbstractSchemaTO object) {
- return new CompoundPropertyModel<AbstractSchemaTO>(object);
- }
- }
-
- private class SchemaTypePanel extends Panel {
-
- private static final long serialVersionUID = 2854050613688773575L;
-
- private int pageRows;
-
- private final AttributableType attrType;
-
- private final SchemaType schemaType;
-
- public SchemaTypePanel(final String id, final AttributableType attrType, final SchemaType schemaType) {
- super(id);
-
- this.attrType = attrType;
- this.schemaType = schemaType;
-
- setup();
- }
-
- private void setup() {
- ModalWindow editSchemaWin = new ModalWindow("editSchemaWin");
- editSchemaWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- editSchemaWin.setInitialWidth(WIN_WIDTH);
- if (schemaType == SchemaType.PLAIN) {
- editSchemaWin.setInitialHeight(PLAIN_WIN_HEIGHT);
- } else {
- editSchemaWin.setInitialHeight(WIN_HEIGHT);
- }
- editSchemaWin.setCookieName("editSchemaWin");
- editSchemaWin.setMarkupId("editSchemaWin");
- add(editSchemaWin);
-
- WebMarkupContainer schemaWrapContainer = new WebMarkupContainer("schemaWrapContainer");
- schemaWrapContainer.setOutputMarkupId(true);
- if (schemaType != SchemaType.VIRTUAL) {
- schemaWrapContainer.add(new AttributeModifier("style", "width:auto;"));
- }
- add(schemaWrapContainer);
-
- WebMarkupContainer schemaContainer = new WebMarkupContainer("schemaContainer");
- schemaContainer.setOutputMarkupId(true);
- schemaWrapContainer.add(schemaContainer);
- setWindowClosedCallback(editSchemaWin, schemaContainer);
-
- final String paginatorRowsKey = PAGINATOR_ROWS_KEYS.get(
- new ImmutablePair<AttributableType, SchemaType>(attrType, schemaType));
- pageRows = prefMan.getPaginatorRows(getRequest(), paginatorRowsKey);
-
- List<IColumn> tableCols = getColumns(schemaContainer, editSchemaWin, attrType,
- schemaType, COL_NAMES.get(schemaType));
- final AjaxFallbackDefaultDataTable table = new AjaxFallbackDefaultDataTable("datatable", tableCols,
- new SchemaProvider(attrType, schemaType), pageRows);
- table.setOutputMarkupId(true);
- schemaContainer.add(table);
-
- schemaWrapContainer.add(getPaginatorForm(schemaContainer, table, "paginatorForm", this, paginatorRowsKey));
-
- add(getCreateSchemaLink(editSchemaWin, attrType, schemaType, "createSchemaLink"));
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.java
deleted file mode 100644
index 12bfc2b..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.java
+++ /dev/null
@@ -1,111 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.rest.SecurityQuestionRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.SecurityQuestionTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-class SecurityQuestionModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = -6709838862698327502L;
-
- @SpringBean
- private SecurityQuestionRestClient restClient;
-
- public SecurityQuestionModalPage(final PageReference pageRef, final ModalWindow window,
- final SecurityQuestionTO securityQuestionTO, final boolean createFlag) {
-
- final Form<SecurityQuestionTO> form =
- new Form<SecurityQuestionTO>(FORM, new CompoundPropertyModel<SecurityQuestionTO>(securityQuestionTO));
-
- final AjaxTextFieldPanel contentFieldPanel =
- new AjaxTextFieldPanel("content", "content", new PropertyModel<String>(securityQuestionTO, "content"));
- contentFieldPanel.setRequired(true);
- form.add(contentFieldPanel);
-
- AjaxButton submit = new IndicatingAjaxButton(APPLY, new Model<String>(getString(SUBMIT))) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- try {
- if (createFlag) {
- restClient.create(securityQuestionTO);
- } else {
- restClient.update(securityQuestionTO);
- }
- info(getString(Constants.OPERATION_SUCCEEDED));
-
- Configuration callerPage = (Configuration) pageRef.getPage();
- callerPage.setModalResult(true);
-
- window.close(target);
- } catch (SyncopeClientException scee) {
- error(getString(Constants.ERROR) + ": " + scee.getMessage());
- feedbackPanel.refresh(target);
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
-
- final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
- };
-
- cancel.setDefaultFormProcessing(false);
-
- String allowedRoles = createFlag
- ? xmlRolesReader.getEntitlement("SecurityQuestion", "create")
- : xmlRolesReader.getEntitlement("SecurityQuestion", "update");
- MetaDataRoleAuthorizationStrategy.authorize(submit, ENABLE, allowedRoles);
-
- form.add(submit);
- form.setDefaultButton(submit);
-
- form.add(cancel);
-
- add(form);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/SignOut.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/SignOut.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/SignOut.java
new file mode 100644
index 0000000..1b0ab30
--- /dev/null
+++ b/client/console/src/main/java/org/apache/syncope/client/console/pages/SignOut.java
@@ -0,0 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.SyncopeConsoleSession;
+import org.apache.wicket.markup.html.WebPage;
+import org.apache.wicket.request.mapper.parameter.PageParameters;
+
+public class SignOut extends WebPage {
+
+ private static final long serialVersionUID = -6497270741904509673L;
+
+ public SignOut(final PageParameters parameters) {
+ super(parameters);
+
+ SyncopeConsoleSession.get().invalidate();
+ }
+
+}
[03/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage_pt_BR.properties
new file mode 100644
index 0000000..a69aeb4
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage_pt_BR.properties
@@ -0,0 +1,87 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Gerenciamento de Pol\u00edtica
+
+description=Descri\u00e7\u00e3o
+type=Tipo
+apply=Salvar
+
+policyInfo=Info
+policySpecification = Especifica\u00e7\u00e3o
+
+#-----------------------------
+# Password policy specification properties
+#-----------------------------
+minLength=Tamanho m\u00ednimo
+maxLength=Tamanho M\u00e1ximo
+historyLength=Tamanho do Hist\u00f3rico
+prefixesNotPermitted=Prefixos n\u00e3o permitidos
+suffixesNotPermitted=sufixos n\u00e3o permitidos
+wordsNotPermitted=Substrings n\u00e3o permitidas
+schemasNotPermitted=N\u00e3o deve conter valores dos seguintes atributos
+digitRequired=Precisa possuir um ou mais d\u00edgitos
+nonAlphanumericRequired=Caractere n\u00e3o alfanum\u00e9rico requerido
+alphanumericRequired=Caractere alfanum\u00e9rico requerido
+lowercaseRequired=Requerido em letra min\u00fascula
+uppercaseRequired=Requerido em letra mai\u00fascula
+mustStartWithDigit=Precisa come\u00e7ar com um d\u00edgito
+mustntStartWithDigit=N\u00e3o deve come\u00e7\u00e3r com um d\u00edgito
+mustEndWithDigit=Precisa terminar com um d\u00edgito
+mustntEndWithDigit=N\u00e3o deve terminar com um d\u00edgito
+mustStartWithNonAlpha=Precisa come\u00e7ar com um caractere n\u00e3o alfanum\u00e9rico
+mustStartWithAlpha=Precisa come\u00e7ar com um caracter alfanum\u00e9rico
+mustntStartWithNonAlpha=N\u00e3o deve come\u00e7ar com um caractere n\u00e3o alfanum\u00e9rico
+mustntStartWithAlpha=N\u00e3o deve come\u00e7ar com um caractere alfanum\u00e9rico
+mustEndWithNonAlpha=Precisa terminar com um caractere n\u00e3o alfanum\u00e9rico
+mustEndWithAlpha=Precisa terminar com um caractere alfanum\u00e9rico
+mustntEndWithNonAlpha=N\u00e3o deve terminar com um caractere n\u00e3o alfanum\u00e9rico
+mustntEndWithAlpha=N\u00e3o precisa terminar com um caracter alfanum\u00e9rico
+allowNullPassword=A senha n\u00e3o pode ser armazenado internamente
+#-----------------------------
+
+#-----------------------------
+# Account policy specification properties
+#-----------------------------
+allUpperCase=Todos em letras mai\u00fasculas
+allLowerCase=todos em letras min\u00fasculas
+pattern=Pattern (regex)
+propagateSuspension=Suspender propaga\u00e7\u00e3o
+permittedLoginRetries=N\u00famero m\u00e1ximo de subsequentes falhas de login
+#-----------------------------
+
+#-----------------------------
+# Sync policy specification properties
+#-----------------------------
+uAltSearchSchemas=Atributos alternativos para busca local (usu\u00e1rios)
+gAltSearchSchemas=Atributos alternativos para busca local (grupos)
+userJavaRule=Regra customizada de correla\u00e7\u00e3o de usu\u00e1rio
+groupJavaRule=Regra de correla\u00e7\u00e3o de grupo customizada
+conflictResolutionAction= A\u00e7\u00e3o de resolu\u00e7\u00e3o de conflito
+#-----------------------------
+
+#-----------------------------
+# Policy Type
+#-----------------------------
+ACCOUNT=Pol\u00edtica de Conta
+GLOBAL_ACCOUNT=Pol\u00edtica Global de Conta
+PASSWORD=Plo\u00edtica de Senha
+GLOBAL_PASSWORD=Pol\u00edtica Global de Senha
+SYNC=Pol\u00edtica de Sincroniza\u00e7\u00e3o
+GLOBAL_SYNC=Pol\u00edtica Global de sincroniza\u00e7\u00e3o
+resources=Recursos
+groups=Grupos
+authResources=Recursos de autentica\u00e7\u00e3o
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage.html
new file mode 100644
index 0000000..67ac588
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage.html
@@ -0,0 +1,75 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <div id="dialog-form">
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+ <form wicket:id="form">
+ <div id="tabs">
+ <ul>
+ <li class="tabs-selected"><a href="#profile"><span><wicket:message key="profile"/></span></a></li>
+ <li><a href="#executions"><span><wicket:message key="executions"/></span></a></li>
+ </ul>
+ <div id="profile">
+ <div id="users-contain" class="ui-widget">
+ <span wicket:id="profile">
+ <div id="formtable">
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <span wicket:id="idLabel">[Id]</span>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="key">[key]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="accountId"><wicket:message key="accountId"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="accountId">[accountId]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="resource"><wicket:message key="resource"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="resource">[resource]</span>
+ </div>
+ </div>
+ </div>
+ </span>
+ </div>
+ </div>
+ <div id="executions" class="ui-widget">
+ <span wicket:id="executionContainer" id="executionContainer">
+ <table class="ui-widget ui-widget-content"
+ wicket:id="executionsTable" style="width: 100%"/>
+ </span>
+ </div>
+ </div>
+ </form>
+ </div>
+ <div wicket:id="taskExecMessageWin"/>
+ </wicket:extend>
+</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage.properties
new file mode 100644
index 0000000..1b035f7
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage.properties
@@ -0,0 +1,28 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Profile
+executions=Executions
+title=Task
+accountId=Account id
+resource=Resource
+startDate=Start date
+endDate=End date
+status=Status
+message=Message
+taskExecutions=Task executions
+delete=Delete
+showMessage=Show
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage_it.properties
new file mode 100644
index 0000000..770680b
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage_it.properties
@@ -0,0 +1,28 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Profilo
+executions=Esecuzioni
+title=Task
+accountId=Id account
+resource=Risorsa
+startDate=Data di avvio
+endDate=Data di conclusione
+status=Stato
+message=Messaggio
+taskExecutions=Esecuzione del task
+delete=Rimozione
+showMessage=Mostra
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage_pt_BR.properties
new file mode 100644
index 0000000..fd54adc
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage_pt_BR.properties
@@ -0,0 +1,28 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Perfil
+executions=Execu\u00E7\u00F5es
+title=Tarefas
+accountId=Identificador de Conta
+resource=Recurso
+startDate=Data Inicial
+endDate=Data final
+status=Estatus
+message=Mensagem
+taskExecutions=Execu\u00E7\u00E3o de Tarefas
+delete=Excluir
+showMessage=Mostrar
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage.html
new file mode 100644
index 0000000..5ac1379
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage.html
@@ -0,0 +1,228 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <div style="margin: 5px;">
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+
+ <form wicket:id="form">
+
+ <div id="tabs">
+ <ul>
+ <li class="tabs-selected"><a href="#profile"><span><wicket:message key="profile"/></span></a></li>
+ <li><a href="#crontab"><span><wicket:message key="crontab"/></span></a></li>
+ <li><a href="#executions"><span><wicket:message key="executions"/></span></a></li>
+ </ul>
+ <div id="profile">
+ <div class="ui-widget">
+ <span wicket:id="profile">
+ <div id="formtable">
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <span wicket:id="idLabel">[Id]</span>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="key">[key]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="name"><wicket:message key="name"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="name">[name]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="description"><wicket:message key="description"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="description">[description]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="resource"><wicket:message key="resourceName"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="resource">[resource]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="lastExec"><wicket:message key="lastExec"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="lastExec">[lastExec]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="nextExec"><wicket:message key="nextExec"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="nextExec">[nextExec]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="actionsClassNames"><wicket:message key="actionsClasses"/></label>
+ </div>
+ <span wicket:id="syncActionsClassNames">
+ <span wicket:id="actionsClasses">
+ <select class="text ui-widget-content ui-corner-all" wicket:id="actionsClass"/>
+ <a wicket:id="drop"><img src="img/minus-icon.png" alt="remove icon" class="drop_button"/></a>
+ <a wicket:id="add"><img src="img/plus-icon.png" alt="add icon" class="add_button"/></a>
+ <br/>
+ </span>
+ <a wicket:id="first"><img src="img/plus-icon.png" alt="add icon" class="add_button"/></a>
+ </span>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="performCreate"><wicket:message key="creates"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="performCreate">[performCreate]</span>
+ </div>
+ </div>
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="performUpdate"><wicket:message key="updates"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="performUpdate">[performUpdate]</span>
+ </div>
+ </div>
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="performDelete"><wicket:message key="deletes"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="performDelete">[performDelete]</span>
+ </div>
+ </div>
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="syncStatus"><wicket:message key="syncStatus"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="syncStatus">[syncStatus]</span>
+ </div>
+ </div>
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="matchingRule"><wicket:message key="matchingRule"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="matchingRule">[matchingRule]</span>
+ </div>
+ </div>
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="unmatchingRule"><wicket:message key="unmatchingRule"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="unmatchingRule">[unmatchingRule]</span>
+ </div>
+ </div>
+ <div id="filters">
+ <span wicket:id="filterContainer">
+ <div class="tablerow" style="width: auto;">
+ <div class="tablecolumn_field" style="width: auto; padding-right: 5px;">
+ <span wicket:id="checkUserFilter">[checkUserFilter]</span>
+ </div>
+ <div class="tablecolumn_label" style="width: auto;">
+ <label for="checkUserFilter"><wicket:message key="checkUserFilter"/></label>
+ </div>
+ </div>
+
+ <div id="userFilter" style="border: 1px solid #dddddd; padding-bottom: 2%; padding-top: 2%;">
+ <div id="condition">
+ <span wicket:id="userFilter"/>
+ </div>
+ </div>
+ <div class="tablerow" style="width: auto;">
+ <div class="tablecolumn_field" style="width: auto; padding-right: 5px;">
+ <span wicket:id="checkGroupFilter">[checkGroupFilter]</span>
+ </div>
+ <div class="tablecolumn_label" style="width: auto;">
+ <label for="checkGroupFilter"><wicket:message key="checkGroupFilter"/></label>
+ </div>
+ </div>
+ <div id="groupFilter" style="border: 1px solid #dddddd; padding-bottom: 2%; padding-top: 2%;">
+ <div id="condition">
+ <span wicket:id="groupFilter"/>
+ </div>
+ </div>
+ </span>
+ </div>
+ <wicket:child/>
+ </div>
+ </span>
+ </div>
+ </div>
+ <div id="crontab">
+ <span wicket:id="crontab">
+ <div id="formtable">
+ <div class="tablerow alt">
+ <label for="cron"><wicket:message key="cron"/></label>
+ </div>
+ <div class="tablerow">
+ <input type="text" id="seconds" class="text ui-widget-content ui-corner-all" wicket:id="seconds" style="width: 50px;float: left" />
+ <input type="text" id="minutes" class="text ui-widget-content ui-corner-all" wicket:id="minutes" style="width: 50px;float: left" />
+ <input type="text" id="hours" class="text ui-widget-content ui-corner-all" wicket:id="hours" style="width: 50px;float: left" />
+ <input type="text" id="daysOfMonth" class="text ui-widget-content ui-corner-all" wicket:id="daysOfMonth" style="width: 50px;float: left" />
+ <input type="text" id="months" class="text ui-widget-content ui-corner-all" wicket:id="months" style="width: 50px;float: left" />
+ <input type="text" id="daysOfWeek" class="text ui-widget-content ui-corner-all" wicket:id="daysOfWeek" style="width: 50px" />
+ </div>
+ <div class="tablerow alt">
+ <label for="cronExpression"><wicket:message key="templates"/></label>
+ </div>
+ <div class="tablerow">
+ <select class="text ui-widget-content ui-corner-all" wicket:id="cronTemplateChooser" style="width: 250px"/>
+ </div>
+ </div>
+ </span>
+ </div>
+ <div id="executions" class="ui-widget">
+ <span wicket:id="executionContainer" id="executionContainer">
+ <table class="ui-widget ui-widget-content"
+ wicket:id="executionsTable" style="width: 100%"/>
+ </span>
+ </div>
+ </div>
+ <div style="margin: 20px 10px 0">
+ <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="apply"/>
+ <input type="button" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="cancel"/>
+ </div>
+ </form>
+ </div>
+ <div wicket:id="taskExecMessageWin"/>
+ </wicket:extend>
+</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage.properties
new file mode 100644
index 0000000..b058db7
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage.properties
@@ -0,0 +1,45 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Profile
+crontab=Schedule
+executions=Executions
+title=Task
+resourceName=Resource Name
+name=Name
+description=Description
+lastExec=Last Execution
+nextExec=Next Execution
+cron=Schedule (seconds, minutes, hours, days of month, months, days of week)
+templates=Remove task from scheduler / Use a template to schedule
+apply=Save
+startDate=Start date
+endDate=End date
+status=Status
+message=Message
+delete=Delete
+showMessage=Show
+chooseForTemplate=Use A Template
+creates=Allow create operations
+deletes=Allow delete operations
+updates=Allow update operations
+syncStatus=Allow status synchronization
+fullReconciliation=Full reconciliation
+actionsClasses=Actions classes
+matchingRule=Matching Rule
+unmatchingRule=Unmatching Rule
+checkUserFilter=User Filter
+checkGroupFilter=Group Filter
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage_it.properties
new file mode 100644
index 0000000..52df2db
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage_it.properties
@@ -0,0 +1,47 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Profilo
+crontab=Schedule
+executions=Esecuzioni
+title=Task
+resourceName=Nome Risorsa
+name=Nome
+description=Descrizione
+lastExec=Ultima Esecuzione
+nextExec=Prossima Esecuzione
+cron=Schedule (secondi, minuti, ore, giorni del mese, mesi, giorni della settimana)
+templates=Rimuovi task dallo scheduler / Utilizza un template per schedulare
+apply=Salva
+startDate=Data di avvio
+endDate=Data di conclusione
+status=Stato
+message=Messaggio
+delete=Rimozione
+showMessage=Mostra
+chooseForTemplate=Usa Un Template
+creates=Consenti operazioni di creazione
+deletes=Consenti operazioni di rimozione
+updates=Consenti operazioni di modifica
+syncStatus=Consenti sincronizzazione di stato
+status=Sincronizza stato utente
+fullReconciliation=Riconciliazione totale
+actionsClasses=Classi azioni
+syncStatus=Sincronizza stato utente
+matchingRule=Regola di corrispondenza
+unmatchingRule=Regola di non corrispondenza
+checkUserFilter=Filtro Utente
+checkGroupFilter=Filtro Gruppo
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage_pt_BR.properties
new file mode 100644
index 0000000..69c09fa
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage_pt_BR.properties
@@ -0,0 +1,45 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Perfil
+crontab=Agenda
+executions=Execu\u00e7\u00f5es
+title=Tarefas
+resourceName=Nome de Recursos
+name=Nome
+description=Descri\u00e7\u00e3o
+lastExec=\u00daltima Execu\u00e7\u00e3o
+nextExec=Pr\u00f3xima Execu\u00e7\u00e3o
+cron=Agenda (segundos, minutos, horas, dias do m\u00eas, meses, dias da semana)
+templates=Remover tarefa agendada / usar template para agendar
+apply=Salvar
+startDate=Data de In\u00edcio
+endDate=Data Final
+status=Estatus
+message=Mensagem
+delete=Excluir
+showMessage=Mostrar
+chooseForTemplate=Usar um template
+creates=Permitir opera\u00e7\u00f5es de cria\u00e7\u00e3o
+deletes=Permitir opera\u00e7\u00f5es de remo\u00e7\u00e3o
+updates=Permitir a edi\u00e7\u00e3o
+syncStatus=Permitir a sincroniza\u00e7\u00e3o de status
+fullReconciliation=Reconcilia\u00e7\u00e3o completa
+actionsClasses=Classes de a\u00e7\u00f5es
+matchingRule=Regra de correspond\u00eancia
+unmatchingRule=Regra de non correspond\u00eancia
+checkUserFilter=Filtro Usu\u00e1rio
+checkGroupFilter=Filtro Grupo
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RecursivePanel.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RecursivePanel.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RecursivePanel.html
new file mode 100644
index 0000000..63cb904
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RecursivePanel.html
@@ -0,0 +1,28 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<wicket:panel>
+ <ul>
+ <span wicket:id="rows">
+ <li wicket:id="row">
+ <span wicket:id="label">[The label]</span>
+ </li>
+ <span wicket:id="nested"/>
+ </span>
+ </ul>
+</wicket:panel>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.html
new file mode 100644
index 0000000..aa9cd0b
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.html
@@ -0,0 +1,23 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<wicket:extend>
+ <div id="dialog">
+ <wicket:message key="downloadAs"/> <span wicket:id="format" class="small_dynamicsize">[format]</span>
+ </div>
+</wicket:extend>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.properties
new file mode 100644
index 0000000..22b990a
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.properties
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+downloadAs=Download as
+download=Download
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage_it.properties
new file mode 100644
index 0000000..7841efe
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage_it.properties
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+downloadAs=Scarica come
+download=Scarica
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage_pt_BR.properties
new file mode 100644
index 0000000..ba57357
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage_pt_BR.properties
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+downloadAs=Salvar como
+download=Salvar
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage.html
new file mode 100644
index 0000000..b813b12
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage.html
@@ -0,0 +1,146 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <div style="margin: 5px;">
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+ <form wicket:id="form">
+ <div id="tabs">
+ <ul>
+ <li class="tabs-selected"><a href="#profile"><span><wicket:message key="profile"/></span></a></li>
+ <li><a href="#crontab"><span><wicket:message key="crontab"/></span></a></li>
+ <li><a href="#executions"><span><wicket:message key="executions"/></span></a></li>
+ </ul>
+ <div id="profile">
+ <div id="users-contain" class="ui-widget">
+ <span wicket:id="profile">
+ <div id="formtable">
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <span wicket:id="idLabel">[Id]</span>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="key">[key]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <span wicket:id="nameLabel">[Name]</span>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="name">[name]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="lastExec"><wicket:message key="lastExec"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="lastExec">[lastExec]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="nextExec"><wicket:message key="nextExec"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="nextExec">[nextExec]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="reportlets"><wicket:message key="reportlets"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <div style="display: inline-table;">
+ <div id="selections" style="display: table-cell;">
+ <select wicket:id="reportletConfs" class="selectionSelect"></select>
+ </div>
+ <div id="orderingButtons" style="display: table-cell; width: 30px; vertical-align: middle; padding-left: 5px;">
+ <div style="padding-bottom: 5px;">
+ <a wicket:id="upButton"><img src="img/up-icon.png" alt="move up icon"/></a>
+ </div>
+ <div style="padding-top: 5px;">
+ <a wicket:id="downButton"><img src="img/down-icon.png" alt="move down icon"/></a>
+ </div>
+ </div>
+ </div>
+ <div id="actionButtons" style="padding-top: 5px;">
+ <div style="padding-left: 35px;float: left;">
+ <a wicket:id="addButton"><img src="img/plus-icon.png" alt="plus icon"/></a>
+ </div>
+ <div style="padding-left: 15px;float: left;">
+ <a wicket:id="editButton"><img src="img/actions/edit.png" alt="edit icon"/></a>
+ </div>
+ <div style="padding-left: 15px;float: left;">
+ <a wicket:id="removeButton"><img src="img/minus-icon.png" alt="minus icon"/></a>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </span>
+ </div>
+ </div>
+ <div id="crontab">
+ <span wicket:id="crontab">
+ <div id="formtable">
+ <div class="tablerow alt">
+ <label for="cron"><wicket:message key="cron"/></label>
+ </div>
+ <div class="tablerow">
+ <input type="text" id="seconds" class="text ui-widget-content ui-corner-all" wicket:id="seconds" style="width: 50px;float: left" />
+ <input type="text" id="minutes" class="text ui-widget-content ui-corner-all" wicket:id="minutes" style="width: 50px;float: left" />
+ <input type="text" id="hours" class="text ui-widget-content ui-corner-all" wicket:id="hours" style="width: 50px;float: left" />
+ <input type="text" id="daysOfMonth" class="text ui-widget-content ui-corner-all" wicket:id="daysOfMonth" style="width: 50px;float: left" />
+ <input type="text" id="months" class="text ui-widget-content ui-corner-all" wicket:id="months" style="width: 50px;float: left" />
+ <input type="text" id="daysOfWeek" class="text ui-widget-content ui-corner-all" wicket:id="daysOfWeek" style="width: 50px" />
+ </div>
+ <div class="tablerow alt">
+ <label for="cronExpression"><wicket:message key="templates"/></label>
+ </div>
+ <div class="tablerow">
+ <select class="text ui-widget-content ui-corner-all" wicket:id="cronTemplateChooser" style="width: 250px"/>
+ </div>
+ </div>
+ </span>
+ </div>
+ <div id="executions" class="ui-widget">
+ <span wicket:id="executionContainer" id="executionContainer">
+ <table class="ui-widget ui-widget-content"
+ wicket:id="executionsTable" style="width: 100%"/>
+ </span>
+ </div>
+ </div>
+ <div style="margin: 20px 10px 0">
+ <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="apply"/>
+ <input type="button" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="cancel"/>
+ </div>
+ </form>
+ </div>
+ <div wicket:id="reportletConfWin"/>
+ <div wicket:id="reportExecMessageWin"/>
+ <div wicket:id="reportExecExportWin"/>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage.properties
new file mode 100644
index 0000000..115fc49
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage.properties
@@ -0,0 +1,36 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Profile
+crontab=Schedule
+executions=Executions
+title=Report
+lastExec=Last Execution
+nextExec=Next Execution
+cron=Schedule (seconds, minutes, hours, days of month, months, days of week)
+templates=Remove task from scheduler / Use a template to schedule
+apply=Save
+startDate=Start date
+endDate=End date
+status=Status
+message=Message
+taskExecutions=Task executions
+delete=Delete
+showMessage=Show
+chooseForTemplate=Use A Template
+reportlets=Reportlets
+create_reportletconf=Add new Reporlet
+selectItem=Please select an item first
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage_it.properties
new file mode 100644
index 0000000..fa600f6
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage_it.properties
@@ -0,0 +1,36 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Profilo
+crontab=Schedule
+executions=Esecuzioni
+title=Rapporto
+lastExec=Ultima Esecuzione
+nextExec=Prossima Esecuzione
+cron=Schedule (secondi, minuti, ore, giorni del mese, mesi, giorni della settimana)
+templates=Rimuovi task dallo scheduler / Utilizza un template per schedulare
+apply=Salva
+startDate=Data di avvio
+endDate=Data di conclusione
+status=Stato
+message=Messaggio
+taskExecutions=Esecuzione del task
+delete=Rimozione
+showMessage=Mostra
+chooseForTemplate=Usa Un Template
+reportlets=Reportlets
+create_reportletconf=Aggiungi Reporlet
+selectItem=Seleziona un elemento
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage_pt_BR.properties
new file mode 100644
index 0000000..da48be6
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage_pt_BR.properties
@@ -0,0 +1,36 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Perfil
+crontab=Agendamento
+executions=Execu\u00E7\u00F5es
+title=Relat\u00F3rios
+lastExec=\u00DAlitima Execu\u00E7\u00E3o
+nextExec=Pr\u00F3xima Execu\u00E7\u00E3o
+cron=Agendar (segundos, minutos, horar, dias do m\u00EAs, meses, dias da semana)
+templates=Remover tarefa da agenda / Use um template para agendar
+apply=Salvar
+startDate=Data de in\u00EDcio
+endDate=Data Final
+status=Estatus
+message=Mensagem
+taskExecutions=Execu\u00E7\u00E3o de Tarefas
+delete=Remover
+showMessage=Mostar
+chooseForTemplate=Usar um Template
+reportlets=Reportlets
+create_reportletconf=Adicionar novo Reporlet
+selectItem=Por favor selecionar um item primeiro
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage.html
new file mode 100644
index 0000000..bc8a1f9
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage.html
@@ -0,0 +1,85 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <div style="margin: 5px;">
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+ <form wicket:id="form">
+ <div id="tabs">
+ <ul>
+ <li class="tabs-selected"><a href="#general"><span><wicket:message key="general"/></span></a></li>
+ <li><a href="#configuration"><span><wicket:message key="configuration"/></span></a></li>
+ </ul>
+ <div id="general">
+ <div id="formtable">
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="name"><wicket:message key="name"/></label>
+ </div>
+ <div class="tablecolumn_field short_dynamicsize">
+ <span wicket:id="name">[name]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="reportletClass"><wicket:message key="reportletClass"/></label>
+ </div>
+ <div class="tablecolumn_field">
+ <span wicket:id="reportletClass" style="width: 100%;">[reportletClass]</span>
+ </div>
+ </div>
+ </div>
+
+ <script type="text/javascript">
+ $(function() {
+ $('#general #formtable div.tablerow:even').addClass("alt");
+ });
+ </script>
+ </div>
+ <div id="configuration">
+ <div id="formtable">
+ <span wicket:id="container">
+ <div class="tablerow" wicket:id="propView">
+ <div class="tablecolumn_label short_fixedsize">
+ <span wicket:id="key">[key]</span>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="value">[value]</span>
+ </div>
+ </div>
+
+ <script type="text/javascript">
+ $(function() {
+ $('#configuration #formtable div.tablerow:even').addClass("alt");
+ });
+ </script>
+ </span>
+ </div>
+ </div>
+ </div>
+
+ <div style="margin: 20px 10px 0">
+ <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="apply"/>
+ <input type="button" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="cancel"/>
+ </div>
+ </form>
+ </div>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage.properties
new file mode 100644
index 0000000..52ca027
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage.properties
@@ -0,0 +1,22 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Reportlet
+general=General
+configuration=Configuration
+apply=Save
+name=Name
+reportletClass=Reportlet class
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage_it.properties
new file mode 100644
index 0000000..9245554
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage_it.properties
@@ -0,0 +1,22 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Reportlet
+general=Generale
+configuration=Configurazione
+apply=Salva
+name=Nome
+reportletClass=Classe Reportlet
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage_pt_BR.properties
new file mode 100644
index 0000000..dc7e422
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage_pt_BR.properties
@@ -0,0 +1,22 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Reportlet
+general=Geral
+configuration=Configura\u00E7\u00E3o
+apply=Salvar
+name=Nome
+reportletClass=Classe Reportlet
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Reports.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Reports.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Reports.html
new file mode 100644
index 0000000..456f7a3
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Reports.html
@@ -0,0 +1,58 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+
+ <div id="tabs">
+ <ul>
+ <li class="tabs-selected"><a href="#tabs-1"><span><wicket:message key="reports"/></span></a></li>
+ <li><a href="#tabs-2"><span><wicket:message key="audit"/></span></a></li>
+ </ul>
+
+ <div id="tabs-1">
+ <div id="users-contain" class="ui-widget" style="width:inherit;">
+ <span wicket:id="reportContainer">
+ <table class="ui-widget ui-widget-content table-hover" wicket:id="reportTable"/>
+ </span>
+ <span style="float:right">
+ <form wicket:id="paginatorForm" style="display:inline">
+ <label><wicket:message key="displayRows"/></label>
+ <select class="text ui-widget-content ui-corner-all" wicket:id="rowsChooser"/>
+ </form>
+ </span>
+ </div>
+
+ <div wicket:id="reportWin">[Show modal window for report editing]</div>
+ <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="createLink">
+ <wicket:message key="create"/>
+ </a>
+
+ </div>
+
+ <div id="tabs-2">
+ <span wicket:id="auditContainer">
+ <form wicket:id="auditForm">
+ <span wicket:id="events">[event builder]</span>
+ </form>
+ </span>
+ </div>
+ </div>
+
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Reports.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Reports.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Reports.properties
new file mode 100644
index 0000000..06ebaca
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Reports.properties
@@ -0,0 +1,24 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+audit=Audit
+lastExec=Last Execution
+nextExec=Next Execution
+latestExecStatus=Last status
+category=Category
+subcategory=Subcategory
+startDate=Start date
+endDate=End date
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Reports_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Reports_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Reports_it.properties
new file mode 100644
index 0000000..24b62ba
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Reports_it.properties
@@ -0,0 +1,24 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+audit=Audit
+lastExec=Ultima Esecuzione
+nextExec=Prossima Esecuzione
+latestExecStatus=Ultimo stato
+category=Categoria
+subcategory=Sottocategoria
+startDate=Data di avvio
+endDate=Data di conclusione
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Reports_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Reports_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Reports_pt_BR.properties
new file mode 100644
index 0000000..c688a06
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Reports_pt_BR.properties
@@ -0,0 +1,24 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+audit=Auditar
+lastExec=\u00daltima Execu\u00e7\u00e3o
+nextExec=Pr\u00f3xima Execu\u00e7\u00e3o
+latestExecStatus=\u00daltimo Estatus
+category=Categoria
+subcategory=Subcategoria
+startDate=Data de in\u00edcio
+endDate=Data Final
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.html
new file mode 100644
index 0000000..90b4da8
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.html
@@ -0,0 +1,64 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <div>
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+ <form wicket:id="form">
+ <div id="formtable">
+ <div class="tablerow alt">
+ <div class="tablecolumn_label medium_fixedsize">
+ <label for="username"><wicket:message key="username"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="username">[username]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label medium_fixedsize">
+ <label for="securityQuestion"><span wicket:id="securityQuestionLabel"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="securityQuestion">[securityQuestion]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label medium_fixedsize">
+ <label for="securityAnswer"><span wicket:id="securityAnswerLabel"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="securityAnswer">[securityAnswer]</span>
+ </div>
+ </div>
+ </div>
+
+ <div style="margin: 20px 10px 0">
+ <input type="submit"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="apply"/>
+ <input type="button"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="cancel"/>
+ </div>
+ </form>
+ </div>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.properties
new file mode 100644
index 0000000..4cc999a
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.properties
@@ -0,0 +1,21 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+securityQuestion=Security question
+title=Password reset
+username=User
+securityAnswer=Security answer
+submit=Submit
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage_it.properties
new file mode 100644
index 0000000..77c1dd4
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage_it.properties
@@ -0,0 +1,21 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+securityQuestion=Domanda di sicurezza
+title=Password smarrita
+username=Utente
+securityAnswer=Risposta di sicurezza
+submit=Invia
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage_pt_BR.properties
new file mode 100644
index 0000000..27728db
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage_pt_BR.properties
@@ -0,0 +1,21 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+securityQuestion=Pergunta de seguran\u00e7a
+title=Redefini\u00e7\u00e3o de senha
+username=Usu\u00e1rio
+securityAnswer=Resposta de seguran\u00e7a
+submit=Apresentar
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage.html
new file mode 100644
index 0000000..8f2cdab
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage.html
@@ -0,0 +1,64 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <div style="margin: 5px;">
+ <p class="ui-widget ui-corner-all ui-widget-header">
+ <span wicket:id="new"/> <wicket:message key="title"/> <span wicket:id="name"/>
+ </p>
+
+ <form wicket:id="form">
+ <div id="tabs">
+ <ul>
+ <li class="tabs-selected"><a href="#resource"><span><wicket:message key="resource"/></span></a></li>
+ <li><a href="#umapping"><span><wicket:message key="umapping"/></span></a></li>
+ <li><a href="#gmapping"><span><wicket:message key="gmapping"/></span></a></li>
+ <li><a href="#connectorProperties"><span><wicket:message key="connectorProperties"/></span></a></li>
+ <li><a href="#security"><span><wicket:message key="security"/></span></a></li>
+ </ul>
+ <div id="resource">
+ <span wicket:id="details">[details]</span>
+ <span wicket:id="systeminformation">[System Information]</span>
+ </div>
+ <div id="umapping">
+ <span wicket:id="umapping">[umapping]</span>
+ </div>
+ <div id="gmapping">
+ <span wicket:id="gmapping">[gmapping]</span>
+ </div>
+ <div id="connectorProperties">
+ <span wicket:id="connconf">[connconf]</span>
+ </div>
+ <div id="security">
+ <span wicket:id="security">[security]</span>
+ </div>
+ </div>
+
+ <div style="margin: 20px 10px 0">
+ <input type="submit"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="apply"/>
+ <input type="button"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="cancel"/>
+ </div>
+ </form>
+ </div>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage.properties
new file mode 100644
index 0000000..69e6e0a
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage.properties
@@ -0,0 +1,60 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+resource=Resource details
+umapping=User mapping
+connectorProperties=Connector properties
+security=Security
+required_alert=All form fields are required
+connector=Connector
+existing_resources=Existing resources
+action=Action
+edit_attribute=Edit resource
+title=Resource
+extAttrNames=External attributes
+intMappingTypes=Internal mapping types
+entity=Entity
+groupSchema=Group Schema
+accountId=AccountId
+mandatoryCondition=Mandatory
+password=Password
+purpose=Purpose
+mappingUserSchema=Mapping User Schema
+mappingGroupSchema=Mapping Group Schema
+delete=Delete
+intAttrNames=Internal attributes
+enforceMandatoryCondition=Enforce mandatory condition
+fieldName=Field name
+
+accountIdValidation=There must be exactly one AccountId
+propagationMode=Propagation mode
+accountLink=Account link
+enable=Enable
+
+createTraceLevel=Create trace level
+updateTraceLevel=Update trace level
+deleteTraceLevel=Delete trace level
+syncTraceLevel=Synchronization trace level
+propagationPriority=Propagation priority
+propagationPrimary=Propagation primary
+
+success_connection=Successful connection
+error_connection=Connection failure
+check=Check connection
+actionsClasses=Actions classes
+gmapping=Group mapping
+new=New
+randomPwdIfNotProvided=Generate random passwords when missing
[51/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
[SYNCOPE-156] Preparing place for new console
Project: http://git-wip-us.apache.org/repos/asf/syncope/repo
Commit: http://git-wip-us.apache.org/repos/asf/syncope/commit/39f8a069
Tree: http://git-wip-us.apache.org/repos/asf/syncope/tree/39f8a069
Diff: http://git-wip-us.apache.org/repos/asf/syncope/diff/39f8a069
Branch: refs/heads/master
Commit: 39f8a0696c465a5d170c4f37a36ea093743a60d1
Parents: 0474098
Author: Francesco Chicchiriccò <il...@apache.org>
Authored: Wed Apr 22 15:51:01 2015 +0200
Committer: Francesco Chicchiriccò <il...@apache.org>
Committed: Wed Apr 22 15:51:01 2015 +0200
----------------------------------------------------------------------
.../syncope/client/console/BinaryPreview.java | 34 -
.../syncope/client/console/ExtensionPanel.java | 34 -
.../client/console/PreferenceManager.java | 173 ++++
.../client/console/SyncopeApplication.java | 306 -------
.../console/SyncopeConsoleApplication.java | 60 ++
.../client/console/SyncopeConsoleSession.java | 179 ++++
.../console/SyncopeRequestCycleListener.java | 84 --
.../syncope/client/console/SyncopeSession.java | 185 -----
.../console/annotations/BinaryPreview.java | 34 +
.../console/annotations/ExtensionPanel.java | 34 +
.../console/commons/ActionTableCheckGroup.java | 40 -
.../commons/AttributableDataProvider.java | 101 ---
.../console/commons/CloseOnESCBehavior.java | 55 --
.../console/commons/DateFormatROModel.java | 50 --
.../console/commons/GroupTreeBuilder.java | 128 ---
.../client/console/commons/JexlHelpUtils.java | 61 --
.../console/commons/MapChoiceRenderer.java | 43 -
.../console/commons/PreferenceManager.java | 176 ----
.../console/commons/SchemaModalPageFactory.java | 58 --
.../console/commons/SelectChoiceRenderer.java | 40 -
.../client/console/commons/SelectOption.java | 72 --
.../client/console/commons/XMLRolesReader.java | 118 ---
.../status/AbstractStatusBeanProvider.java | 2 +-
.../console/commons/status/StatusBean.java | 2 +-
.../console/commons/status/StatusUtils.java | 42 -
.../init/ImplementationClassNamesLoader.java | 2 +-
.../client/console/pages/AbstractBasePage.java | 11 +-
.../pages/AbstractSchedTaskModalPage.java | 132 ---
.../console/pages/AbstractSchemaModalPage.java | 45 -
.../console/pages/AbstractStatusModalPage.java | 30 -
.../pages/AbstractSyncTaskModalPage.java | 209 -----
.../console/pages/ActivitiModelerPopupPage.java | 27 -
.../client/console/pages/ApprovalModalPage.java | 286 -------
.../client/console/pages/BaseModalPage.java | 32 +-
.../syncope/client/console/pages/BasePage.java | 70 --
.../console/pages/BulkActionModalPage.java | 166 ----
.../pages/BulkActionResultModalPage.java | 97 ---
.../client/console/pages/ConfModalPage.java | 112 ---
.../client/console/pages/Configuration.java | 814 -------------------
.../pages/ConfirmPasswordResetModalPage.java | 103 ---
.../console/pages/ConnObjectModalPage.java | 101 ---
.../console/pages/ConnectorModalPage.java | 479 -----------
.../console/pages/DerSchemaModalPage.java | 140 ----
.../pages/DisplayAttributesModalPage.java | 273 -------
.../client/console/pages/EditUserModalPage.java | 105 ---
.../syncope/client/console/pages/ErrorPage.java | 42 -
.../console/pages/ExecMessageModalPage.java | 32 -
.../console/pages/FailureMessageModalPage.java | 37 -
.../client/console/pages/GroupModalPage.java | 164 ----
.../console/pages/GroupSelectModalPage.java | 105 ---
.../console/pages/GroupTemplateModalPage.java | 50 --
.../syncope/client/console/pages/Groups.java | 186 -----
.../syncope/client/console/pages/HomePage.java | 9 +-
.../client/console/pages/InfoModalPage.java | 43 -
.../syncope/client/console/pages/Login.java | 365 ---------
.../syncope/client/console/pages/Logout.java | 38 -
.../console/pages/MembershipModalPage.java | 114 ---
.../console/pages/NotificationModalPage.java | 441 ----------
.../pages/NotificationTaskModalPage.java | 69 --
.../console/pages/PlainSchemaModalPage.java | 456 -----------
.../client/console/pages/PolicyModalPage.java | 450 ----------
.../console/pages/PropagationTaskModalPage.java | 45 -
.../console/pages/ProvisioningModalPage.java | 249 ------
.../client/console/pages/PushTaskModalPage.java | 135 ---
.../ReportExecResultDownloadModalPage.java | 73 --
.../client/console/pages/ReportModalPage.java | 640 ---------------
.../console/pages/ReportletConfModalPage.java | 362 ---------
.../syncope/client/console/pages/Reports.java | 412 ----------
.../pages/RequestPasswordResetModalPage.java | 153 ----
.../client/console/pages/ResourceModalPage.java | 214 -----
.../syncope/client/console/pages/Resources.java | 723 ----------------
.../console/pages/ResultStatusModalPage.java | 424 ----------
.../console/pages/SchedTaskModalPage.java | 68 --
.../syncope/client/console/pages/Schema.java | 468 -----------
.../pages/SecurityQuestionModalPage.java | 111 ---
.../syncope/client/console/pages/SignOut.java | 35 +
.../client/console/pages/StatusModalPage.java | 641 ---------------
.../client/console/pages/SyncTaskModalPage.java | 73 --
.../client/console/pages/TaskModalPage.java | 253 ------
.../syncope/client/console/pages/Tasks.java | 230 ------
.../syncope/client/console/pages/Todo.java | 245 ------
.../client/console/pages/UserModalPage.java | 229 ------
.../console/pages/UserOwnerSelectModalPage.java | 81 --
.../client/console/pages/UserSelfModalPage.java | 72 --
.../console/pages/UserTemplateModalPage.java | 60 --
.../syncope/client/console/pages/Users.java | 166 ----
.../client/console/pages/ViewUserModalPage.java | 49 --
.../console/pages/VirSchemaModalPage.java | 126 ---
.../client/console/pages/WelcomePage.java | 55 --
.../console/pages/XMLEditorPopupPage.java | 90 --
.../console/panels/AbstractExtensionPanel.java | 5 -
.../panels/AbstractProvisioningTasksPanel.java | 160 ----
.../console/panels/AbstractSearchPanel.java | 401 ---------
.../panels/AbstractSearchResultPanel.java | 353 --------
.../client/console/panels/AbstractTasks.java | 55 --
.../console/panels/AccountInformationPanel.java | 73 --
.../console/panels/ActionDataTablePanel.java | 149 ----
.../console/panels/AjaxDataTablePanel.java | 142 ----
.../console/panels/AnnotatedBeanPanel.java | 66 --
.../console/panels/AttrTemplatesPanel.java | 167 ----
.../client/console/panels/DataTablePanel.java | 113 ---
.../client/console/panels/DerAttrsPanel.java | 206 -----
.../console/panels/EventSelectionPanel.java | 243 ------
.../console/panels/GroupDetailsPanel.java | 435 ----------
.../client/console/panels/GroupPanel.java | 187 -----
.../client/console/panels/GroupSearchPanel.java | 101 ---
.../console/panels/GroupSearchResultPanel.java | 172 ----
.../console/panels/GroupSecurityPanel.java | 198 -----
.../console/panels/GroupSummaryPanel.java | 153 ----
.../client/console/panels/GroupTabPanel.java | 195 -----
.../console/panels/JQueryUITabbedPanel.java | 45 -
.../client/console/panels/LayoutsPanel.java | 130 ---
.../console/panels/LoggerCategoryPanel.java | 461 -----------
.../client/console/panels/MembershipsPanel.java | 255 ------
.../console/panels/NotificationPanel.java | 6 +-
.../console/panels/NotificationTasks.java | 254 ------
.../client/console/panels/PlainAttrsPanel.java | 395 ---------
.../client/console/panels/PoliciesPanel.java | 343 --------
.../client/console/panels/PolicyBeanPanel.java | 340 --------
.../client/console/panels/PropagationTasks.java | 264 ------
.../client/console/panels/PushTasksPanel.java | 184 -----
.../console/panels/ResourceConnConfPanel.java | 187 -----
.../console/panels/ResourceDetailsPanel.java | 306 -------
.../console/panels/ResourceMappingPanel.java | 644 ---------------
.../console/panels/ResourceSecurityPanel.java | 189 -----
.../client/console/panels/ResourcesPanel.java | 177 ----
.../client/console/panels/SchedTasks.java | 286 -------
.../client/console/panels/SearchClause.java | 129 ---
.../client/console/panels/SearchView.java | 461 -----------
.../console/panels/SecurityQuestionPanel.java | 98 ---
.../panels/SelectOnlyUserSearchResultPanel.java | 93 ---
.../console/panels/SelectedEventsPanel.java | 167 ----
.../client/console/panels/StatusPanel.java | 262 ------
.../client/console/panels/SyncTasksPanel.java | 225 -----
.../client/console/panels/UserDetailsPanel.java | 122 ---
.../client/console/panels/UserSearchPanel.java | 113 ---
.../console/panels/UserSearchResultPanel.java | 297 -------
.../client/console/panels/VirAttrsPanel.java | 294 -------
.../console/resources/FilesystemResource.java | 83 --
.../resources/WorkflowDefGETResource.java | 58 --
.../resources/WorkflowDefPUTResource.java | 74 --
.../console/rest/AbstractSubjectRestClient.java | 15 +-
.../client/console/rest/ApprovalRestClient.java | 4 +-
.../client/console/rest/AuthRestClient.java | 44 -
.../client/console/rest/BaseRestClient.java | 12 +-
.../console/rest/ConfigurationRestClient.java | 4 +-
.../console/rest/ConnectorRestClient.java | 6 +-
.../client/console/rest/GroupRestClient.java | 33 +-
.../client/console/rest/InvalidPolicyType.java | 31 -
.../client/console/rest/LoggerRestClient.java | 2 +-
.../console/rest/NotificationRestClient.java | 8 +-
.../client/console/rest/PolicyRestClient.java | 39 +-
.../client/console/rest/ReportRestClient.java | 2 +-
.../client/console/rest/ResourceRestClient.java | 4 +-
.../client/console/rest/SchemaRestClient.java | 60 +-
.../client/console/rest/TaskRestClient.java | 8 +-
.../client/console/rest/UserRestClient.java | 21 +-
.../client/console/rest/UserSelfRestClient.java | 10 +-
.../client/console/rest/WorkflowRestClient.java | 6 +-
.../ajax/form/AbstractAjaxDownloadBehavior.java | 48 --
.../markup/html/ClearIndicatingAjaxButton.java | 76 --
.../markup/html/ClearIndicatingAjaxLink.java | 61 --
.../html/IndicatingOnConfirmAjaxLink.java | 58 --
.../html/repeater/data/table/ActionColumn.java | 59 --
.../repeater/data/table/ActionResultColumn.java | 77 --
.../html/repeater/data/table/AttrColumn.java | 85 --
.../data/table/CheckBoxGroupSelectorPanel.java | 34 -
.../html/repeater/data/table/CheckBoxPanel.java | 43 -
.../repeater/data/table/CheckGroupColumn.java | 54 --
.../repeater/data/table/CollectionPanel.java | 47 --
.../data/table/CollectionPropertyColumn.java | 54 --
.../repeater/data/table/DatePropertyColumn.java | 53 --
.../html/repeater/data/table/TokenColumn.java | 51 --
.../wicket/markup/html/CrontabContainer.java | 184 -----
.../wicket/markup/html/form/ActionLink.java | 83 --
.../markup/html/form/ActionLinksPanel.java | 586 -------------
.../markup/html/form/AjaxPalettePanel.java | 3 +-
.../html/form/AjaxPasswordFieldPanel.java | 2 +-
.../markup/html/form/SelectChoiceRenderer.java | 40 +
.../wicket/markup/html/form/SelectOption.java | 72 ++
.../html/form/preview/BinaryCertPreviewer.java | 2 +-
.../html/form/preview/BinaryImagePreviewer.java | 2 +-
.../markup/html/link/VeilPopupSettings.java | 32 -
.../tree/DefaultMutableTreeNodeExpansion.java | 160 ----
.../DefaultMutableTreeNodeExpansionModel.java | 36 -
.../wicket/markup/html/tree/TreeGroupPanel.java | 121 ---
.../markup/html/tree/TreeGroupProvider.java | 43 -
.../resources/META-INF/resources/css/bulk.css | 97 ---
.../META-INF/resources/css/fieldstyle.css | 191 -----
.../ui-bg_diagonals-thick_20_666666_40x40.png | Bin 251 -> 0 bytes
.../css/images/ui-bg_flat_0_aaaaaa_40x100.png | Bin 1310 -> 0 bytes
.../ui-bg_flat_0_aaaaaa_40x100_greennotused.png | Bin 1312 -> 0 bytes
.../css/images/ui-bg_glass_55_fbf9ee_1x400.png | Bin 120 -> 0 bytes
.../css/images/ui-bg_glass_65_ffffff_1x400.png | Bin 105 -> 0 bytes
.../css/images/ui-bg_glass_75_dadada_1x400.png | Bin 111 -> 0 bytes
.../css/images/ui-bg_glass_75_e6e6e6_1x400.png | Bin 110 -> 0 bytes
.../css/images/ui-bg_glass_95_fef1ec_1x400.png | Bin 119 -> 0 bytes
.../ui-bg_highlight-soft_75_cccccc_1x100.png | Bin 1244 -> 0 bytes
...ghlight-soft_75_cccccc_1x100_greynotused.png | Bin 101 -> 0 bytes
...ui-bg_highlight-soft_75_cccccc_1x100_red.png | Bin 257 -> 0 bytes
.../css/images/ui-icons_222222_256x240.png | Bin 4369 -> 0 bytes
.../css/images/ui-icons_2e83ff_256x240.png | Bin 4369 -> 0 bytes
.../css/images/ui-icons_454545_256x240.png | Bin 4369 -> 0 bytes
.../css/images/ui-icons_888888_256x240.png | Bin 4369 -> 0 bytes
.../css/images/ui-icons_cd0a0a_256x240.png | Bin 4369 -> 0 bytes
.../resources/META-INF/resources/css/style.css | 550 -------------
.../resources/img/actions/assign-icon.png | Bin 566 -> 0 bytes
.../resources/img/actions/both-icon.png | Bin 611 -> 0 bytes
.../META-INF/resources/img/actions/bulk.png | Bin 1182 -> 0 bytes
.../META-INF/resources/img/actions/claim.png | Bin 509 -> 0 bytes
.../META-INF/resources/img/actions/create.png | Bin 360 -> 0 bytes
.../META-INF/resources/img/actions/delete.png | Bin 530 -> 0 bytes
.../resources/img/actions/deprovision-icon.png | Bin 210 -> 0 bytes
.../META-INF/resources/img/actions/dryrun.png | Bin 891 -> 0 bytes
.../META-INF/resources/img/actions/edit.png | Bin 455 -> 0 bytes
.../META-INF/resources/img/actions/enable.png | Bin 715 -> 0 bytes
.../META-INF/resources/img/actions/execute.png | Bin 695 -> 0 bytes
.../META-INF/resources/img/actions/export.png | Bin 474 -> 0 bytes
.../resources/img/actions/groups-icon.png | Bin 391 -> 0 bytes
.../resources/img/actions/link-icon.png | Bin 447 -> 0 bytes
.../resources/img/actions/manage-icon.png | Bin 611 -> 0 bytes
.../resources/img/actions/none-icon.png | Bin 521 -> 0 bytes
.../resources/img/actions/propagation-icon.png | Bin 362 -> 0 bytes
.../resources/img/actions/provision-icon.png | Bin 360 -> 0 bytes
.../resources/img/actions/reactivate.png | Bin 496 -> 0 bytes
.../META-INF/resources/img/actions/reload.png | Bin 491 -> 0 bytes
.../META-INF/resources/img/actions/reset.png | Bin 491 -> 0 bytes
.../resources/img/actions/resources-icon.png | Bin 634 -> 0 bytes
.../META-INF/resources/img/actions/search.png | Bin 763 -> 0 bytes
.../META-INF/resources/img/actions/select.png | Bin 279 -> 0 bytes
.../resources/img/actions/settings-icon.png | Bin 153 -> 0 bytes
.../META-INF/resources/img/actions/suspend.png | Bin 504 -> 0 bytes
.../img/actions/synchronization-icon.png | Bin 406 -> 0 bytes
.../resources/img/actions/unassign-icon.png | Bin 573 -> 0 bytes
.../resources/img/actions/unlink-icon.png | Bin 509 -> 0 bytes
.../resources/img/actions/user_template.png | Bin 597 -> 0 bytes
.../resources/img/actions/users-icon.png | Bin 754 -> 0 bytes
.../resources/META-INF/resources/img/add.png | Bin 814 -> 0 bytes
.../resources/META-INF/resources/img/addAll.png | Bin 1037 -> 0 bytes
.../resources/META-INF/resources/img/busy.gif | Bin 2834 -> 0 bytes
.../META-INF/resources/img/db_export.png | Bin 16675 -> 0 bytes
.../META-INF/resources/img/disable.png | Bin 1001 -> 0 bytes
.../META-INF/resources/img/down-icon.png | Bin 418 -> 0 bytes
.../META-INF/resources/img/favicon.png | Bin 641 -> 0 bytes
.../META-INF/resources/img/file-download.png | Bin 967 -> 0 bytes
.../META-INF/resources/img/file-upload.png | Bin 949 -> 0 bytes
.../resources/META-INF/resources/img/help.png | Bin 808 -> 0 bytes
.../resources/META-INF/resources/img/info.png | Bin 575 -> 0 bytes
.../META-INF/resources/img/left-icon.png | Bin 451 -> 0 bytes
.../META-INF/resources/img/loading.gif | Bin 2530 -> 0 bytes
.../resources/META-INF/resources/img/logo.png | Bin 8913 -> 0 bytes
.../resources/img/menu/configuration.png | Bin 5670 -> 0 bytes
.../META-INF/resources/img/menu/connectors.png | Bin 5772 -> 0 bytes
.../META-INF/resources/img/menu/groups.png | Bin 5020 -> 0 bytes
.../META-INF/resources/img/menu/logout.png | Bin 5460 -> 0 bytes
.../resources/img/menu/notsel/configuration.png | Bin 5518 -> 0 bytes
.../resources/img/menu/notsel/connectors.png | Bin 6401 -> 0 bytes
.../resources/img/menu/notsel/groups.png | Bin 5175 -> 0 bytes
.../resources/img/menu/notsel/logout.png | Bin 5720 -> 0 bytes
.../resources/img/menu/notsel/reports.png | Bin 6074 -> 0 bytes
.../resources/img/menu/notsel/resources.png | Bin 6401 -> 0 bytes
.../resources/img/menu/notsel/schema.png | Bin 5544 -> 0 bytes
.../resources/img/menu/notsel/sf_body.png | Bin 303 -> 0 bytes
.../resources/img/menu/notsel/tasks.png | Bin 7461 -> 0 bytes
.../META-INF/resources/img/menu/notsel/todo.png | Bin 6996 -> 0 bytes
.../resources/img/menu/notsel/users.png | Bin 7637 -> 0 bytes
.../META-INF/resources/img/menu/reports.png | Bin 5553 -> 0 bytes
.../META-INF/resources/img/menu/resources.png | Bin 5772 -> 0 bytes
.../META-INF/resources/img/menu/schema.png | Bin 5217 -> 0 bytes
.../META-INF/resources/img/menu/tasks.png | Bin 5742 -> 0 bytes
.../META-INF/resources/img/menu/todo.png | Bin 5722 -> 0 bytes
.../META-INF/resources/img/menu/users.png | Bin 6006 -> 0 bytes
.../META-INF/resources/img/minus-icon.png | Bin 210 -> 0 bytes
.../META-INF/resources/img/modeler.png | Bin 3118 -> 0 bytes
.../META-INF/resources/img/moveDown.png | Bin 833 -> 0 bytes
.../resources/META-INF/resources/img/moveUp.png | Bin 834 -> 0 bytes
.../resources/META-INF/resources/img/ok.png | Bin 497 -> 0 bytes
.../resources/META-INF/resources/img/ping.png | Bin 22945 -> 0 bytes
.../META-INF/resources/img/plus-icon.png | Bin 360 -> 0 bytes
.../META-INF/resources/img/reload_30.png | Bin 611 -> 0 bytes
.../resources/META-INF/resources/img/remove.png | Bin 825 -> 0 bytes
.../META-INF/resources/img/removeAll.png | Bin 1034 -> 0 bytes
.../META-INF/resources/img/right-icon.png | Bin 411 -> 0 bytes
.../resources/META-INF/resources/img/search.png | Bin 763 -> 0 bytes
.../META-INF/resources/img/sf_testa.png | Bin 293 -> 0 bytes
.../META-INF/resources/img/statuses/active.png | Bin 509 -> 0 bytes
.../resources/img/statuses/inactive.png | Bin 477 -> 0 bytes
.../resources/img/statuses/objectnotfound.png | Bin 668 -> 0 bytes
.../resources/img/statuses/undefined.png | Bin 758 -> 0 bytes
.../META-INF/resources/img/success.png | Bin 1696 -> 0 bytes
.../resources/META-INF/resources/img/tab ok.png | Bin 2330 -> 0 bytes
.../META-INF/resources/img/tab old.png | Bin 734 -> 0 bytes
.../resources/META-INF/resources/img/tab.png | Bin 2098 -> 0 bytes
.../META-INF/resources/img/up-icon.png | Bin 421 -> 0 bytes
.../META-INF/resources/img/warning.png | Bin 1107 -> 0 bytes
.../resources/META-INF/resources/img/xml.png | Bin 2741 -> 0 bytes
.../src/main/resources/authorizations.xml | 333 --------
.../src/main/resources/consoleContext.xml | 12 +-
.../console/SyncopeApplication.properties | 55 --
.../console/SyncopeApplication_it.properties | 54 --
.../console/SyncopeApplication_pt_BR.properties | 54 --
.../SyncopeConsoleApplication.properties | 55 ++
.../SyncopeConsoleApplication_it.properties | 54 ++
.../SyncopeConsoleApplication_pt_BR.properties | 54 ++
.../console/pages/AbstractStatusModalPage.html | 122 ---
.../pages/AbstractStatusModalPage.properties | 19 -
.../pages/AbstractStatusModalPage_it.properties | 19 -
.../AbstractStatusModalPage_pt_BR.properties | 19 -
.../console/pages/ActivitiModelerPopupPage.html | 65 --
.../client/console/pages/ApprovalModalPage.html | 52 --
.../console/pages/ApprovalModalPage.properties | 18 -
.../pages/ApprovalModalPage_it.properties | 18 -
.../pages/ApprovalModalPage_pt_BR.properties | 18 -
.../console/pages/BulkActionModalPage.html | 45 -
.../pages/BulkActionModalPage.properties | 17 -
.../pages/BulkActionModalPage_it.properties | 17 -
.../pages/BulkActionModalPage_pt_BR.properties | 17 -
.../pages/BulkActionResultModalPage.html | 57 --
.../pages/BulkActionResultModalPage.properties | 19 -
.../BulkActionResultModalPage_it.properties | 19 -
.../BulkActionResultModalPage_pt_BR.properties | 19 -
.../client/console/pages/ConfModalPage.html | 39 -
.../console/pages/ConfModalPage.properties | 17 -
.../console/pages/ConfModalPage_it.properties | 17 -
.../pages/ConfModalPage_pt_BR.properties | 17 -
.../client/console/pages/Configuration.html | 230 ------
.../console/pages/Configuration.properties | 48 --
.../console/pages/Configuration_it.properties | 48 --
.../pages/Configuration_pt_BR.properties | 48 --
.../pages/ConfirmPasswordResetModalPage.html | 55 --
.../ConfirmPasswordResetModalPage.properties | 20 -
.../ConfirmPasswordResetModalPage_it.properties | 20 -
...nfirmPasswordResetModalPage_pt_BR.properties | 20 -
.../console/pages/ConnObjectModalPage.html | 39 -
.../pages/ConnObjectModalPage.properties | 17 -
.../pages/ConnObjectModalPage_it.properties | 17 -
.../pages/ConnObjectModalPage_pt_BR.properties | 17 -
.../console/pages/ConnectorModalPage.html | 161 ----
.../console/pages/ConnectorModalPage.properties | 43 -
.../pages/ConnectorModalPage_it.properties | 43 -
.../pages/ConnectorModalPage_pt_BR.properties | 43 -
.../console/pages/DerSchemaModalPage.html | 64 --
.../console/pages/DerSchemaModalPage.properties | 22 -
.../pages/DerSchemaModalPage_it.properties | 22 -
.../pages/DerSchemaModalPage_pt_BR.properties | 22 -
.../pages/DisplayAttributesModalPage.html | 132 ---
.../pages/DisplayAttributesModalPage.properties | 33 -
.../DisplayAttributesModalPage_it.properties | 33 -
.../DisplayAttributesModalPage_pt_BR.properties | 33 -
.../syncope/client/console/pages/ErrorPage.html | 53 --
.../console/pages/ExecMessageModalPage.html | 25 -
.../console/pages/FailureMessageModalPage.html | 36 -
.../client/console/pages/GroupModalPage.html | 52 --
.../console/pages/GroupModalPage.properties | 48 --
.../console/pages/GroupModalPage_it.properties | 50 --
.../pages/GroupModalPage_pt_BR.properties | 48 --
.../console/pages/GroupSelectModalPage.html | 24 -
.../syncope/client/console/pages/Groups.html | 80 --
.../client/console/pages/Groups.properties | 26 -
.../client/console/pages/Groups_it.properties | 26 -
.../console/pages/Groups_pt_BR.properties | 26 -
.../syncope/client/console/pages/HomePage.html | 29 +-
.../client/console/pages/InfoModalPage.html | 42 -
.../console/pages/InfoModalPage.properties | 19 -
.../console/pages/InfoModalPage_it.properties | 19 -
.../pages/InfoModalPage_pt_BR.properties | 19 -
.../syncope/client/console/pages/Login.html | 89 --
.../client/console/pages/Login.properties | 22 -
.../client/console/pages/Login_it.properties | 22 -
.../client/console/pages/Login_pt_BR.properties | 22 -
.../console/pages/MembershipModalPage.html | 55 --
.../pages/MembershipModalPage.properties | 35 -
.../pages/MembershipModalPage_it.properties | 35 -
.../pages/MembershipModalPage_pt_BR.properties | 35 -
.../console/pages/NotificationModalPage.html | 234 ------
.../pages/NotificationModalPage.properties | 40 -
.../pages/NotificationModalPage_it.properties | 40 -
.../NotificationModalPage_pt_BR.properties | 40 -
.../pages/NotificationTaskModalPage.html | 111 ---
.../pages/NotificationTaskModalPage.properties | 32 -
.../NotificationTaskModalPage_it.properties | 32 -
.../NotificationTaskModalPage_pt_BR.properties | 32 -
.../console/pages/PlainSchemaModalPage.html | 172 ----
.../pages/PlainSchemaModalPage.properties | 38 -
.../pages/PlainSchemaModalPage_it.properties | 38 -
.../pages/PlainSchemaModalPage_pt_BR.properties | 38 -
.../client/console/pages/PolicyModalPage.html | 109 ---
.../console/pages/PolicyModalPage.properties | 88 --
.../console/pages/PolicyModalPage_it.properties | 88 --
.../pages/PolicyModalPage_pt_BR.properties | 87 --
.../console/pages/PropagationTaskModalPage.html | 75 --
.../pages/PropagationTaskModalPage.properties | 28 -
.../PropagationTaskModalPage_it.properties | 28 -
.../PropagationTaskModalPage_pt_BR.properties | 28 -
.../client/console/pages/PushTaskModalPage.html | 228 ------
.../console/pages/PushTaskModalPage.properties | 45 -
.../pages/PushTaskModalPage_it.properties | 47 --
.../pages/PushTaskModalPage_pt_BR.properties | 45 -
.../client/console/pages/RecursivePanel.html | 28 -
.../ReportExecResultDownloadModalPage.html | 23 -
...ReportExecResultDownloadModalPage.properties | 18 -
...ortExecResultDownloadModalPage_it.properties | 18 -
...ExecResultDownloadModalPage_pt_BR.properties | 18 -
.../client/console/pages/ReportModalPage.html | 146 ----
.../console/pages/ReportModalPage.properties | 36 -
.../console/pages/ReportModalPage_it.properties | 36 -
.../pages/ReportModalPage_pt_BR.properties | 36 -
.../console/pages/ReportletConfModalPage.html | 85 --
.../pages/ReportletConfModalPage.properties | 22 -
.../pages/ReportletConfModalPage_it.properties | 22 -
.../ReportletConfModalPage_pt_BR.properties | 22 -
.../syncope/client/console/pages/Reports.html | 58 --
.../client/console/pages/Reports.properties | 24 -
.../client/console/pages/Reports_it.properties | 24 -
.../console/pages/Reports_pt_BR.properties | 24 -
.../pages/RequestPasswordResetModalPage.html | 64 --
.../RequestPasswordResetModalPage.properties | 21 -
.../RequestPasswordResetModalPage_it.properties | 21 -
...questPasswordResetModalPage_pt_BR.properties | 21 -
.../client/console/pages/ResourceModalPage.html | 64 --
.../console/pages/ResourceModalPage.properties | 60 --
.../pages/ResourceModalPage_it.properties | 60 --
.../pages/ResourceModalPage_pt_BR.properties | 60 --
.../syncope/client/console/pages/Resources.html | 99 ---
.../client/console/pages/Resources.properties | 34 -
.../console/pages/Resources_it.properties | 34 -
.../console/pages/Resources_pt_BR.properties | 32 -
.../console/pages/ResultStatusModalPage.html | 226 -----
.../pages/ResultStatusModalPage.properties | 26 -
.../pages/ResultStatusModalPage_it.properties | 26 -
.../ResultStatusModalPage_pt_BR.properties | 26 -
.../client/console/pages/RouteModalPage.html | 49 --
.../console/pages/RouteModalPage.properties | 18 -
.../console/pages/RouteModalPage_it.properties | 18 -
.../pages/RouteModalPage_pt_BR.properties | 18 -
.../console/pages/SchedTaskModalPage.html | 136 ----
.../console/pages/SchedTaskModalPage.properties | 36 -
.../pages/SchedTaskModalPage_it.properties | 36 -
.../pages/SchedTaskModalPage_pt_BR.properties | 36 -
.../console/pages/Schema$SchemaTypePanel.html | 41 -
.../syncope/client/console/pages/Schema.html | 59 --
.../client/console/pages/Schema.properties | 35 -
.../client/console/pages/Schema_it.properties | 35 -
.../console/pages/Schema_pt_BR.properties | 35 -
.../pages/SecurityQuestionModalPage.html | 46 --
.../pages/SecurityQuestionModalPage.properties | 18 -
.../SecurityQuestionModalPage_it.properties | 18 -
.../SecurityQuestionModalPage_pt_BR.properties | 18 -
.../syncope/client/console/pages/SignOut.html | 33 +
.../client/console/pages/SyncTaskModalPage.html | 205 -----
.../console/pages/SyncTaskModalPage.properties | 43 -
.../pages/SyncTaskModalPage_it.properties | 44 -
.../pages/SyncTaskModalPage_pt_BR.properties | 43 -
.../syncope/client/console/pages/Tasks.html | 46 --
.../client/console/pages/Tasks.properties | 21 -
.../client/console/pages/Tasks_it.properties | 21 -
.../client/console/pages/Tasks_pt_BR.properties | 21 -
.../syncope/client/console/pages/Todo.html | 45 -
.../client/console/pages/Todo.properties | 31 -
.../client/console/pages/Todo_it.properties | 31 -
.../client/console/pages/Todo_pt_BR.properties | 31 -
.../client/console/pages/UserModalPage.html | 97 ---
.../console/pages/UserModalPage.properties | 52 --
.../console/pages/UserModalPage_it.properties | 53 --
.../pages/UserModalPage_pt_BR.properties | 52 --
.../console/pages/UserOwnerSelectModalPage.html | 38 -
.../pages/UserOwnerSelectModalPage.properties | 23 -
.../UserOwnerSelectModalPage_it.properties | 23 -
.../UserOwnerSelectModalPage_pt_BR.properties | 23 -
.../syncope/client/console/pages/Users.html | 72 --
.../client/console/pages/Users.properties | 26 -
.../client/console/pages/Users_it.properties | 26 -
.../client/console/pages/Users_pt_BR.properties | 26 -
.../console/pages/VirSchemaModalPage.html | 53 --
.../console/pages/VirSchemaModalPage.properties | 22 -
.../pages/VirSchemaModalPage_it.properties | 22 -
.../pages/VirSchemaModalPage_pt_BR.properties | 22 -
.../client/console/pages/WelcomePage.html | 70 --
.../client/console/pages/WelcomePage.properties | 18 -
.../console/pages/WelcomePage_it.properties | 18 -
.../console/pages/WelcomePage_pt_BR.properties | 18 -
.../console/pages/XMLEditorPopupPage.html | 82 --
.../console/pages/XMLEditorPopupPage.properties | 19 -
.../pages/XMLEditorPopupPage_it.properties | 19 -
.../pages/XMLEditorPopupPage_pt_BR.properties | 19 -
.../panels/AbstractProvisioningTasksPanel.html | 41 -
.../console/panels/AbstractSearchPanel.html | 50 --
.../panels/AbstractSearchResultPanel.html | 43 -
.../panels/AbstractSearchResultPanel.properties | 30 -
.../AbstractSearchResultPanel_it.properties | 30 -
.../AbstractSearchResultPanel_pt_BR.properties | 30 -
.../console/panels/AccountInformationPanel.html | 67 --
.../panels/AccountInformationPanel.properties | 22 -
.../AccountInformationPanel_it.properties | 23 -
.../AccountInformationPanel_pt_BR.properties | 23 -
.../console/panels/ActionDataTablePanel.html | 45 -
.../console/panels/AjaxDataTablePanel.html | 47 --
.../console/panels/AnnotatedBeanPanel.html | 98 ---
.../panels/AnnotatedBeanPanel.properties | 20 -
.../panels/AnnotatedBeanPanel_it.properties | 20 -
.../panels/AnnotatedBeanPanel_pt_BR.properties | 20 -
.../console/panels/AttrTemplatesPanel.html | 58 --
.../panels/AttrTemplatesPanel.properties | 23 -
.../panels/AttrTemplatesPanel_it.properties | 23 -
.../panels/AttrTemplatesPanel_pt_BR.properties | 23 -
.../client/console/panels/AuditEventsPanel.html | 122 ---
.../client/console/panels/DerAttrsPanel.html | 60 --
.../console/panels/DerAttrsPanel.properties | 17 -
.../console/panels/DerAttrsPanel_it.properties | 18 -
.../panels/DerAttrsPanel_pt_BR.properties | 17 -
.../console/panels/EventSelectionPanel.html | 125 ---
.../console/panels/GroupDetailsPanel.html | 107 ---
.../console/panels/GroupDetailsPanel.properties | 22 -
.../panels/GroupDetailsPanel_it.properties | 22 -
.../panels/GroupDetailsPanel_pt_BR.properties | 22 -
.../client/console/panels/GroupPanel.html | 88 --
.../client/console/panels/GroupPanel.properties | 51 --
.../console/panels/GroupPanel_it.properties | 53 --
.../console/panels/GroupPanel_pt_BR.properties | 40 -
.../console/panels/GroupSecurityPanel.html | 66 --
.../panels/GroupSecurityPanel.properties | 20 -
.../panels/GroupSecurityPanel_it.properties | 20 -
.../panels/GroupSecurityPanel_pt_BR.properties | 20 -
.../console/panels/GroupSummaryPanel.html | 39 -
.../client/console/panels/GroupTabPanel.html | 64 --
.../console/panels/GroupTabPanel.properties | 27 -
.../console/panels/GroupTabPanel_it.properties | 27 -
.../panels/GroupTabPanel_pt_BR.properties | 27 -
.../client/console/panels/ImagePanel.html | 23 -
.../console/panels/JQueryUITabbedPanel.html | 41 -
.../client/console/panels/LayoutsPanel.html | 41 -
.../console/panels/LayoutsPanel.properties | 18 -
.../console/panels/LayoutsPanel_it.properties | 18 -
.../panels/LayoutsPanel_pt_BR.properties | 18 -
.../console/panels/LoggerCategoryPanel.html | 106 ---
.../client/console/panels/MembershipsPanel.html | 66 --
.../console/panels/MembershipsPanel.properties | 23 -
.../panels/MembershipsPanel_it.properties | 24 -
.../panels/MembershipsPanel_pt_BR.properties | 23 -
.../console/panels/NotificationTasks.html | 38 -
.../console/panels/NotificationTasks.properties | 26 -
.../panels/NotificationTasks_it.properties | 26 -
.../panels/NotificationTasks_pt_BR.properties | 26 -
.../client/console/panels/PlainAttrsPanel.html | 44 -
.../client/console/panels/PoliciesPanel.html | 42 -
.../console/panels/PoliciesPanel.properties | 34 -
.../console/panels/PoliciesPanel_it.properties | 34 -
.../panels/PoliciesPanel_pt_BR.properties | 34 -
.../client/console/panels/PolicyBeanPanel.html | 39 -
.../client/console/panels/PropagationTasks.html | 37 -
.../console/panels/PropagationTasks.properties | 28 -
.../panels/PropagationTasks_it.properties | 28 -
.../panels/PropagationTasks_pt_BR.properties | 28 -
.../console/panels/PushTasksPanel.properties | 29 -
.../console/panels/PushTasksPanel_it.properties | 29 -
.../panels/PushTasksPanel_pt_BR.properties | 29 -
.../console/panels/ResourceConnConfPanel.html | 41 -
.../console/panels/ResourceDetailsPanel.html | 137 ----
.../console/panels/ResourceMappingPanel.html | 125 ---
.../console/panels/ResourceSecurityPanel.html | 56 --
.../panels/ResourceSecurityPanel.properties | 19 -
.../panels/ResourceSecurityPanel_it.properties | 19 -
.../ResourceSecurityPanel_pt_BR.properties | 19 -
.../client/console/panels/ResourcesPanel.html | 23 -
.../client/console/panels/SchedTasks.html | 42 -
.../client/console/panels/SchedTasks.properties | 28 -
.../console/panels/SchedTasks_it.properties | 28 -
.../console/panels/SchedTasks_pt_BR.properties | 28 -
.../console/panels/SecurityQuestionPanel.html | 41 -
.../panels/SecurityQuestionPanel.properties | 18 -
.../panels/SecurityQuestionPanel_it.properties | 18 -
.../SecurityQuestionPanel_pt_BR.properties | 18 -
.../console/panels/SelectedEventsPanel.html | 33 -
.../client/console/panels/StatusPanel.html | 130 ---
.../console/panels/StatusPanel.properties | 19 -
.../console/panels/StatusPanel_it.properties | 19 -
.../console/panels/StatusPanel_pt_BR.properties | 19 -
.../console/panels/SyncTasksPanel.properties | 29 -
.../console/panels/SyncTasksPanel_it.properties | 29 -
.../panels/SyncTasksPanel_pt_BR.properties | 29 -
.../client/console/panels/UserDetailsPanel.html | 71 --
.../console/panels/UserDetailsPanel.properties | 19 -
.../panels/UserDetailsPanel_it.properties | 19 -
.../panels/UserDetailsPanel_pt_BR.properties | 19 -
.../client/console/panels/VirAttrsPanel.html | 60 --
.../console/panels/VirAttrsPanel.properties | 19 -
.../console/panels/VirAttrsPanel_it.properties | 20 -
.../panels/VirAttrsPanel_pt_BR.properties | 19 -
.../data/table/CheckBoxGroupSelectorPanel.html | 21 -
.../html/repeater/data/table/CheckBoxPanel.html | 23 -
.../repeater/data/table/CollectionPanel.html | 25 -
.../markup/html/CrontabContainer.properties | 22 -
.../markup/html/CrontabContainer_it.properties | 22 -
.../html/CrontabContainer_pt_BR.properties | 22 -
.../markup/html/form/ActionLinksPanel.html | 163 ----
.../markup/html/form/AjaxCheckBoxPanel.html | 21 -
.../html/form/AjaxDropDownChoicePanel.html | 24 -
.../markup/html/form/AjaxNumberFieldPanel.html | 22 -
.../markup/html/form/AjaxPalettePanel.html | 23 -
.../html/form/AjaxPasswordFieldPanel.html | 22 -
.../markup/html/form/AjaxTextFieldPanel.html | 23 -
.../markup/html/form/BinaryFieldPanel.html | 44 -
.../form/CheckBoxMultipleChoiceFieldPanel.html | 23 -
.../markup/html/form/DateTextFieldPanel.html | 22 -
.../markup/html/form/DateTimeFieldPanel.html | 21 -
.../html/form/DateTimeFieldPanel.properties | 17 -
.../html/form/DateTimeFieldPanel_it.properties | 17 -
.../form/DateTimeFieldPanel_pt_BR.properties | 17 -
.../wicket/markup/html/form/FieldPanel.html | 34 -
.../wicket/markup/html/form/LinkPanel.html | 23 -
.../markup/html/form/MappingPurposePanel.html | 31 -
.../markup/html/form/MultiFieldPanel.html | 35 -
.../markup/html/form/MultiFieldPanel.properties | 22 -
.../html/form/MultiFieldPanel_it.properties | 22 -
.../html/form/MultiFieldPanel_pt_BR.properties | 22 -
.../wicket/markup/html/form/NonI18nPalette.html | 69 --
.../markup/html/form/SpinnerFieldPanel.html | 29 -
.../form/preview/AbstractBinaryPreviewer.html | 24 -
.../html/form/preview/BinaryCertPreviewer.html | 24 -
.../html/form/preview/BinaryImagePreviewer.html | 23 -
.../wicket/markup/html/tree/TreeGroupPanel.html | 25 -
client/old_console/pom.xml | 112 +++
.../syncope/client/console/BinaryPreview.java | 34 +
.../syncope/client/console/ExtensionPanel.java | 34 +
.../client/console/SyncopeApplication.java | 306 +++++++
.../console/SyncopeRequestCycleListener.java | 84 ++
.../syncope/client/console/SyncopeSession.java | 185 +++++
.../console/commons/ActionTableCheckGroup.java | 40 +
.../client/console/commons/AttrLayoutType.java | 105 +++
.../commons/AttributableDataProvider.java | 101 +++
.../console/commons/CloseOnESCBehavior.java | 55 ++
.../commons/ConnIdSpecialAttributeName.java | 34 +
.../client/console/commons/Constants.java | 110 +++
.../console/commons/DateFormatROModel.java | 50 ++
.../console/commons/GroupTreeBuilder.java | 128 +++
.../console/commons/HttpResourceStream.java | 101 +++
.../client/console/commons/JexlHelpUtils.java | 61 ++
.../console/commons/MapChoiceRenderer.java | 43 +
.../syncope/client/console/commons/Mode.java | 27 +
.../console/commons/PreferenceManager.java | 176 ++++
.../client/console/commons/PreviewUtils.java | 62 ++
.../console/commons/SchemaModalPageFactory.java | 58 ++
.../console/commons/SelectChoiceRenderer.java | 40 +
.../client/console/commons/SelectOption.java | 72 ++
.../SortableAttributableProviderComparator.java | 122 +++
.../commons/SortableDataProviderComparator.java | 66 ++
.../client/console/commons/XMLRolesReader.java | 118 +++
.../status/AbstractStatusBeanProvider.java | 69 ++
.../commons/status/ConnObjectWrapper.java | 55 ++
.../client/console/commons/status/Status.java | 45 +
.../console/commons/status/StatusBean.java | 103 +++
.../console/commons/status/StatusUtils.java | 324 ++++++++
.../client/console/init/ConsoleInitializer.java | 72 ++
.../init/ImplementationClassNamesLoader.java | 109 +++
.../client/console/init/MIMETypesLoader.java | 69 ++
.../console/init/SyncopeConsoleLoader.java | 35 +
.../client/console/pages/AbstractBasePage.java | 131 +++
.../pages/AbstractSchedTaskModalPage.java | 132 +++
.../console/pages/AbstractSchemaModalPage.java | 45 +
.../console/pages/AbstractStatusModalPage.java | 30 +
.../pages/AbstractSyncTaskModalPage.java | 209 +++++
.../console/pages/ActivitiModelerPopupPage.java | 27 +
.../client/console/pages/ApprovalModalPage.java | 286 +++++++
.../client/console/pages/BaseModalPage.java | 35 +
.../syncope/client/console/pages/BasePage.java | 111 +++
.../client/console/pages/BasePopupPage.java | 25 +
.../console/pages/BulkActionModalPage.java | 166 ++++
.../pages/BulkActionResultModalPage.java | 97 +++
.../client/console/pages/ConfModalPage.java | 112 +++
.../client/console/pages/Configuration.java | 814 +++++++++++++++++++
.../pages/ConfirmPasswordResetModalPage.java | 103 +++
.../console/pages/ConnObjectModalPage.java | 101 +++
.../console/pages/ConnectorModalPage.java | 479 +++++++++++
.../console/pages/DerSchemaModalPage.java | 140 ++++
.../pages/DisplayAttributesModalPage.java | 273 +++++++
.../client/console/pages/EditUserModalPage.java | 105 +++
.../syncope/client/console/pages/ErrorPage.java | 42 +
.../console/pages/ExecMessageModalPage.java | 32 +
.../console/pages/FailureMessageModalPage.java | 37 +
.../client/console/pages/GroupModalPage.java | 164 ++++
.../console/pages/GroupSelectModalPage.java | 105 +++
.../console/pages/GroupTemplateModalPage.java | 50 ++
.../syncope/client/console/pages/Groups.java | 186 +++++
.../syncope/client/console/pages/HomePage.java | 33 +
.../client/console/pages/InfoModalPage.java | 43 +
.../syncope/client/console/pages/Login.java | 365 +++++++++
.../syncope/client/console/pages/Logout.java | 38 +
.../console/pages/MembershipModalPage.java | 114 +++
.../console/pages/NotificationModalPage.java | 441 ++++++++++
.../pages/NotificationTaskModalPage.java | 69 ++
.../console/pages/PlainSchemaModalPage.java | 456 +++++++++++
.../client/console/pages/PolicyModalPage.java | 450 ++++++++++
.../console/pages/PropagationTaskModalPage.java | 45 +
.../console/pages/ProvisioningModalPage.java | 249 ++++++
.../client/console/pages/PushTaskModalPage.java | 135 +++
.../ReportExecResultDownloadModalPage.java | 73 ++
.../client/console/pages/ReportModalPage.java | 640 +++++++++++++++
.../console/pages/ReportletConfModalPage.java | 362 +++++++++
.../syncope/client/console/pages/Reports.java | 412 ++++++++++
.../pages/RequestPasswordResetModalPage.java | 153 ++++
.../client/console/pages/ResourceModalPage.java | 214 +++++
.../syncope/client/console/pages/Resources.java | 723 ++++++++++++++++
.../console/pages/ResultStatusModalPage.java | 424 ++++++++++
.../console/pages/SchedTaskModalPage.java | 68 ++
.../syncope/client/console/pages/Schema.java | 468 +++++++++++
.../pages/SecurityQuestionModalPage.java | 111 +++
.../client/console/pages/StatusModalPage.java | 641 +++++++++++++++
.../client/console/pages/SyncTaskModalPage.java | 73 ++
.../client/console/pages/TaskModalPage.java | 253 ++++++
.../syncope/client/console/pages/Tasks.java | 230 ++++++
.../syncope/client/console/pages/Todo.java | 245 ++++++
.../client/console/pages/UserModalPage.java | 229 ++++++
.../console/pages/UserOwnerSelectModalPage.java | 81 ++
.../client/console/pages/UserSelfModalPage.java | 72 ++
.../console/pages/UserTemplateModalPage.java | 60 ++
.../syncope/client/console/pages/Users.java | 166 ++++
.../client/console/pages/ViewUserModalPage.java | 49 ++
.../console/pages/VirSchemaModalPage.java | 126 +++
.../client/console/pages/WelcomePage.java | 55 ++
.../console/pages/XMLEditorPopupPage.java | 90 ++
.../console/panels/AbstractExtensionPanel.java | 39 +
.../panels/AbstractProvisioningTasksPanel.java | 160 ++++
.../console/panels/AbstractSearchPanel.java | 401 +++++++++
.../panels/AbstractSearchResultPanel.java | 353 ++++++++
.../client/console/panels/AbstractTasks.java | 55 ++
.../console/panels/AccountInformationPanel.java | 73 ++
.../console/panels/ActionDataTablePanel.java | 149 ++++
.../console/panels/AjaxDataTablePanel.java | 142 ++++
.../console/panels/AnnotatedBeanPanel.java | 66 ++
.../console/panels/AttrTemplatesPanel.java | 167 ++++
.../client/console/panels/DataTablePanel.java | 113 +++
.../client/console/panels/DerAttrsPanel.java | 206 +++++
.../console/panels/EventSelectionPanel.java | 243 ++++++
.../console/panels/GroupDetailsPanel.java | 435 ++++++++++
.../client/console/panels/GroupPanel.java | 187 +++++
.../client/console/panels/GroupSearchPanel.java | 101 +++
.../console/panels/GroupSearchResultPanel.java | 172 ++++
.../console/panels/GroupSecurityPanel.java | 198 +++++
.../console/panels/GroupSummaryPanel.java | 153 ++++
.../client/console/panels/GroupTabPanel.java | 195 +++++
.../client/console/panels/ImagePanel.java | 44 +
.../console/panels/JQueryUITabbedPanel.java | 45 +
.../client/console/panels/LayoutsPanel.java | 130 +++
.../console/panels/LoggerCategoryPanel.java | 461 +++++++++++
.../client/console/panels/MembershipsPanel.java | 255 ++++++
.../console/panels/NotificationPanel.java | 119 +++
.../console/panels/NotificationTasks.java | 254 ++++++
.../client/console/panels/PlainAttrsPanel.java | 395 +++++++++
.../client/console/panels/PoliciesPanel.java | 343 ++++++++
.../client/console/panels/PolicyBeanPanel.java | 340 ++++++++
.../client/console/panels/PropagationTasks.java | 264 ++++++
.../client/console/panels/PushTasksPanel.java | 184 +++++
.../console/panels/ResourceConnConfPanel.java | 187 +++++
.../console/panels/ResourceDetailsPanel.java | 306 +++++++
.../console/panels/ResourceMappingPanel.java | 644 +++++++++++++++
.../console/panels/ResourceSecurityPanel.java | 189 +++++
.../client/console/panels/ResourcesPanel.java | 177 ++++
.../client/console/panels/SchedTasks.java | 286 +++++++
.../client/console/panels/SearchClause.java | 129 +++
.../client/console/panels/SearchView.java | 461 +++++++++++
.../console/panels/SecurityQuestionPanel.java | 98 +++
.../panels/SelectOnlyUserSearchResultPanel.java | 93 +++
.../console/panels/SelectedEventsPanel.java | 167 ++++
.../client/console/panels/StatusPanel.java | 262 ++++++
.../client/console/panels/SyncTasksPanel.java | 225 +++++
.../client/console/panels/UserDetailsPanel.java | 122 +++
.../client/console/panels/UserSearchPanel.java | 113 +++
.../console/panels/UserSearchResultPanel.java | 297 +++++++
.../client/console/panels/VirAttrsPanel.java | 294 +++++++
.../console/resources/FilesystemResource.java | 83 ++
.../resources/WorkflowDefGETResource.java | 58 ++
.../resources/WorkflowDefPUTResource.java | 74 ++
.../console/rest/AbstractSubjectRestClient.java | 46 ++
.../client/console/rest/ApprovalRestClient.java | 45 +
.../client/console/rest/AuthRestClient.java | 44 +
.../client/console/rest/BaseRestClient.java | 70 ++
.../console/rest/ConfigurationRestClient.java | 97 +++
.../console/rest/ConnectorRestClient.java | 217 +++++
.../console/rest/ExecutionRestClient.java | 26 +
.../client/console/rest/GroupRestClient.java | 184 +++++
.../client/console/rest/InvalidPolicyType.java | 31 +
.../client/console/rest/LoggerRestClient.java | 92 +++
.../console/rest/NotificationRestClient.java | 50 ++
.../client/console/rest/PolicyRestClient.java | 104 +++
.../client/console/rest/ReportRestClient.java | 108 +++
.../client/console/rest/ResourceRestClient.java | 94 +++
.../client/console/rest/SchemaRestClient.java | 250 ++++++
.../rest/SecurityQuestionRestClient.java | 51 ++
.../client/console/rest/TaskRestClient.java | 139 ++++
.../client/console/rest/UserRestClient.java | 228 ++++++
.../client/console/rest/UserSelfRestClient.java | 96 +++
.../client/console/rest/WorkflowRestClient.java | 69 ++
.../ajax/form/AbstractAjaxDownloadBehavior.java | 48 ++
.../markup/html/ClearIndicatingAjaxButton.java | 76 ++
.../markup/html/ClearIndicatingAjaxLink.java | 61 ++
.../html/IndicatingOnConfirmAjaxLink.java | 58 ++
.../html/repeater/data/table/ActionColumn.java | 59 ++
.../repeater/data/table/ActionResultColumn.java | 77 ++
.../html/repeater/data/table/AttrColumn.java | 85 ++
.../data/table/CheckBoxGroupSelectorPanel.java | 34 +
.../html/repeater/data/table/CheckBoxPanel.java | 43 +
.../repeater/data/table/CheckGroupColumn.java | 54 ++
.../repeater/data/table/CollectionPanel.java | 47 ++
.../data/table/CollectionPropertyColumn.java | 54 ++
.../repeater/data/table/DatePropertyColumn.java | 53 ++
.../html/repeater/data/table/TokenColumn.java | 51 ++
.../wicket/markup/head/MetaHeaderItem.java | 49 ++
.../wicket/markup/html/CrontabContainer.java | 184 +++++
.../markup/html/form/AbstractFieldPanel.java | 40 +
.../wicket/markup/html/form/ActionLink.java | 83 ++
.../markup/html/form/ActionLinksPanel.java | 586 +++++++++++++
.../markup/html/form/AjaxCheckBoxPanel.java | 130 +++
.../markup/html/form/AjaxDecoratedCheckbox.java | 55 ++
.../html/form/AjaxDropDownChoicePanel.java | 87 ++
.../markup/html/form/AjaxPalettePanel.java | 70 ++
.../html/form/AjaxPasswordFieldPanel.java | 60 ++
.../markup/html/form/AjaxTextFieldPanel.java | 98 +++
.../markup/html/form/BinaryFieldPanel.java | 211 +++++
.../form/CheckBoxMultipleChoiceFieldPanel.java | 46 ++
.../wicket/markup/html/form/DateFieldPanel.java | 132 +++
.../markup/html/form/DateTextFieldPanel.java | 88 ++
.../markup/html/form/DateTimeFieldPanel.java | 195 +++++
.../wicket/markup/html/form/FieldPanel.java | 199 +++++
.../wicket/markup/html/form/LinkPanel.java | 39 +
.../markup/html/form/MappingPurposePanel.java | 133 +++
.../markup/html/form/MultiFieldPanel.java | 172 ++++
.../wicket/markup/html/form/NonI18nPalette.java | 44 +
.../markup/html/form/SelectableRecorder.java | 204 +++++
.../markup/html/form/SpinnerFieldPanel.java | 197 +++++
.../form/preview/AbstractBinaryPreviewer.java | 46 ++
.../html/form/preview/BinaryCertPreviewer.java | 70 ++
.../html/form/preview/BinaryImagePreviewer.java | 51 ++
.../markup/html/link/VeilPopupSettings.java | 32 +
.../wicket/markup/html/list/AltListView.java | 59 ++
.../html/list/ConnConfPropertyListView.java | 152 ++++
.../tree/DefaultMutableTreeNodeExpansion.java | 160 ++++
.../DefaultMutableTreeNodeExpansionModel.java | 36 +
.../wicket/markup/html/tree/TreeGroupPanel.java | 121 +++
.../markup/html/tree/TreeGroupProvider.java | 43 +
.../resources/META-INF/resources/css/bulk.css | 97 +++
.../META-INF/resources/css/fieldstyle.css | 191 +++++
.../ui-bg_diagonals-thick_20_666666_40x40.png | Bin 0 -> 251 bytes
.../css/images/ui-bg_flat_0_aaaaaa_40x100.png | Bin 0 -> 1310 bytes
.../ui-bg_flat_0_aaaaaa_40x100_greennotused.png | Bin 0 -> 1312 bytes
.../css/images/ui-bg_glass_55_fbf9ee_1x400.png | Bin 0 -> 120 bytes
.../css/images/ui-bg_glass_65_ffffff_1x400.png | Bin 0 -> 105 bytes
.../css/images/ui-bg_glass_75_dadada_1x400.png | Bin 0 -> 111 bytes
.../css/images/ui-bg_glass_75_e6e6e6_1x400.png | Bin 0 -> 110 bytes
.../css/images/ui-bg_glass_95_fef1ec_1x400.png | Bin 0 -> 119 bytes
.../ui-bg_highlight-soft_75_cccccc_1x100.png | Bin 0 -> 1244 bytes
...ghlight-soft_75_cccccc_1x100_greynotused.png | Bin 0 -> 101 bytes
...ui-bg_highlight-soft_75_cccccc_1x100_red.png | Bin 0 -> 257 bytes
.../css/images/ui-icons_222222_256x240.png | Bin 0 -> 4369 bytes
.../css/images/ui-icons_2e83ff_256x240.png | Bin 0 -> 4369 bytes
.../css/images/ui-icons_454545_256x240.png | Bin 0 -> 4369 bytes
.../css/images/ui-icons_888888_256x240.png | Bin 0 -> 4369 bytes
.../css/images/ui-icons_cd0a0a_256x240.png | Bin 0 -> 4369 bytes
.../resources/META-INF/resources/css/style.css | 550 +++++++++++++
.../resources/img/actions/assign-icon.png | Bin 0 -> 566 bytes
.../resources/img/actions/both-icon.png | Bin 0 -> 611 bytes
.../META-INF/resources/img/actions/bulk.png | Bin 0 -> 1182 bytes
.../META-INF/resources/img/actions/claim.png | Bin 0 -> 509 bytes
.../META-INF/resources/img/actions/create.png | Bin 0 -> 360 bytes
.../META-INF/resources/img/actions/delete.png | Bin 0 -> 530 bytes
.../resources/img/actions/deprovision-icon.png | Bin 0 -> 210 bytes
.../META-INF/resources/img/actions/dryrun.png | Bin 0 -> 891 bytes
.../META-INF/resources/img/actions/edit.png | Bin 0 -> 455 bytes
.../META-INF/resources/img/actions/enable.png | Bin 0 -> 715 bytes
.../META-INF/resources/img/actions/execute.png | Bin 0 -> 695 bytes
.../META-INF/resources/img/actions/export.png | Bin 0 -> 474 bytes
.../resources/img/actions/groups-icon.png | Bin 0 -> 391 bytes
.../resources/img/actions/link-icon.png | Bin 0 -> 447 bytes
.../resources/img/actions/manage-icon.png | Bin 0 -> 611 bytes
.../resources/img/actions/none-icon.png | Bin 0 -> 521 bytes
.../resources/img/actions/propagation-icon.png | Bin 0 -> 362 bytes
.../resources/img/actions/provision-icon.png | Bin 0 -> 360 bytes
.../resources/img/actions/reactivate.png | Bin 0 -> 496 bytes
.../META-INF/resources/img/actions/reload.png | Bin 0 -> 491 bytes
.../META-INF/resources/img/actions/reset.png | Bin 0 -> 491 bytes
.../resources/img/actions/resources-icon.png | Bin 0 -> 634 bytes
.../META-INF/resources/img/actions/search.png | Bin 0 -> 763 bytes
.../META-INF/resources/img/actions/select.png | Bin 0 -> 279 bytes
.../resources/img/actions/settings-icon.png | Bin 0 -> 153 bytes
.../META-INF/resources/img/actions/suspend.png | Bin 0 -> 504 bytes
.../img/actions/synchronization-icon.png | Bin 0 -> 406 bytes
.../resources/img/actions/unassign-icon.png | Bin 0 -> 573 bytes
.../resources/img/actions/unlink-icon.png | Bin 0 -> 509 bytes
.../resources/img/actions/user_template.png | Bin 0 -> 597 bytes
.../resources/img/actions/users-icon.png | Bin 0 -> 754 bytes
.../resources/META-INF/resources/img/add.png | Bin 0 -> 814 bytes
.../resources/META-INF/resources/img/addAll.png | Bin 0 -> 1037 bytes
.../resources/META-INF/resources/img/busy.gif | Bin 0 -> 2834 bytes
.../META-INF/resources/img/db_export.png | Bin 0 -> 16675 bytes
.../META-INF/resources/img/disable.png | Bin 0 -> 1001 bytes
.../META-INF/resources/img/down-icon.png | Bin 0 -> 418 bytes
.../META-INF/resources/img/favicon.png | Bin 0 -> 641 bytes
.../META-INF/resources/img/file-download.png | Bin 0 -> 967 bytes
.../META-INF/resources/img/file-upload.png | Bin 0 -> 949 bytes
.../resources/META-INF/resources/img/help.png | Bin 0 -> 808 bytes
.../resources/META-INF/resources/img/info.png | Bin 0 -> 575 bytes
.../META-INF/resources/img/left-icon.png | Bin 0 -> 451 bytes
.../META-INF/resources/img/loading.gif | Bin 0 -> 2530 bytes
.../resources/META-INF/resources/img/logo.png | Bin 0 -> 8913 bytes
.../resources/img/menu/configuration.png | Bin 0 -> 5670 bytes
.../META-INF/resources/img/menu/connectors.png | Bin 0 -> 5772 bytes
.../META-INF/resources/img/menu/groups.png | Bin 0 -> 5020 bytes
.../META-INF/resources/img/menu/logout.png | Bin 0 -> 5460 bytes
.../resources/img/menu/notsel/configuration.png | Bin 0 -> 5518 bytes
.../resources/img/menu/notsel/connectors.png | Bin 0 -> 6401 bytes
.../resources/img/menu/notsel/groups.png | Bin 0 -> 5175 bytes
.../resources/img/menu/notsel/logout.png | Bin 0 -> 5720 bytes
.../resources/img/menu/notsel/reports.png | Bin 0 -> 6074 bytes
.../resources/img/menu/notsel/resources.png | Bin 0 -> 6401 bytes
.../resources/img/menu/notsel/schema.png | Bin 0 -> 5544 bytes
.../resources/img/menu/notsel/sf_body.png | Bin 0 -> 303 bytes
.../resources/img/menu/notsel/tasks.png | Bin 0 -> 7461 bytes
.../META-INF/resources/img/menu/notsel/todo.png | Bin 0 -> 6996 bytes
.../resources/img/menu/notsel/users.png | Bin 0 -> 7637 bytes
.../META-INF/resources/img/menu/reports.png | Bin 0 -> 5553 bytes
.../META-INF/resources/img/menu/resources.png | Bin 0 -> 5772 bytes
.../META-INF/resources/img/menu/schema.png | Bin 0 -> 5217 bytes
.../META-INF/resources/img/menu/tasks.png | Bin 0 -> 5742 bytes
.../META-INF/resources/img/menu/todo.png | Bin 0 -> 5722 bytes
.../META-INF/resources/img/menu/users.png | Bin 0 -> 6006 bytes
.../META-INF/resources/img/minus-icon.png | Bin 0 -> 210 bytes
.../META-INF/resources/img/modeler.png | Bin 0 -> 3118 bytes
.../META-INF/resources/img/moveDown.png | Bin 0 -> 833 bytes
.../resources/META-INF/resources/img/moveUp.png | Bin 0 -> 834 bytes
.../resources/META-INF/resources/img/ok.png | Bin 0 -> 497 bytes
.../resources/META-INF/resources/img/ping.png | Bin 0 -> 22945 bytes
.../META-INF/resources/img/plus-icon.png | Bin 0 -> 360 bytes
.../META-INF/resources/img/reload_30.png | Bin 0 -> 611 bytes
.../resources/META-INF/resources/img/remove.png | Bin 0 -> 825 bytes
.../META-INF/resources/img/removeAll.png | Bin 0 -> 1034 bytes
.../META-INF/resources/img/right-icon.png | Bin 0 -> 411 bytes
.../resources/META-INF/resources/img/search.png | Bin 0 -> 763 bytes
.../META-INF/resources/img/sf_testa.png | Bin 0 -> 293 bytes
.../META-INF/resources/img/statuses/active.png | Bin 0 -> 509 bytes
.../resources/img/statuses/inactive.png | Bin 0 -> 477 bytes
.../resources/img/statuses/objectnotfound.png | Bin 0 -> 668 bytes
.../resources/img/statuses/undefined.png | Bin 0 -> 758 bytes
.../META-INF/resources/img/success.png | Bin 0 -> 1696 bytes
.../resources/META-INF/resources/img/tab ok.png | Bin 0 -> 2330 bytes
.../META-INF/resources/img/tab old.png | Bin 0 -> 734 bytes
.../resources/META-INF/resources/img/tab.png | Bin 0 -> 2098 bytes
.../META-INF/resources/img/up-icon.png | Bin 0 -> 421 bytes
.../META-INF/resources/img/warning.png | Bin 0 -> 1107 bytes
.../resources/META-INF/resources/img/xml.png | Bin 0 -> 2741 bytes
client/old_console/src/main/resources/MIMETypes | 671 +++++++++++++++
.../src/main/resources/authorizations.xml | 333 ++++++++
.../src/main/resources/console.properties | 22 +
.../src/main/resources/consoleContext.xml | 77 ++
.../console/SyncopeApplication.properties | 55 ++
.../console/SyncopeApplication_it.properties | 54 ++
.../console/SyncopeApplication_pt_BR.properties | 54 ++
.../console/pages/AbstractStatusModalPage.html | 122 +++
.../pages/AbstractStatusModalPage.properties | 19 +
.../pages/AbstractStatusModalPage_it.properties | 19 +
.../AbstractStatusModalPage_pt_BR.properties | 19 +
.../console/pages/ActivitiModelerPopupPage.html | 65 ++
.../client/console/pages/ApprovalModalPage.html | 52 ++
.../console/pages/ApprovalModalPage.properties | 18 +
.../pages/ApprovalModalPage_it.properties | 18 +
.../pages/ApprovalModalPage_pt_BR.properties | 18 +
.../client/console/pages/BaseModalPage.html | 56 ++
.../console/pages/BaseModalPage.properties | 20 +
.../console/pages/BaseModalPage_it.properties | 20 +
.../pages/BaseModalPage_pt_BR.properties | 20 +
.../syncope/client/console/pages/BasePage.html | 145 ++++
.../client/console/pages/BasePage.properties | 19 +
.../client/console/pages/BasePage_it.properties | 19 +
.../console/pages/BasePage_pt_BR.properties | 19 +
.../client/console/pages/BasePopupPage.html | 51 ++
.../console/pages/BulkActionModalPage.html | 45 +
.../pages/BulkActionModalPage.properties | 17 +
.../pages/BulkActionModalPage_it.properties | 17 +
.../pages/BulkActionModalPage_pt_BR.properties | 17 +
.../pages/BulkActionResultModalPage.html | 57 ++
.../pages/BulkActionResultModalPage.properties | 19 +
.../BulkActionResultModalPage_it.properties | 19 +
.../BulkActionResultModalPage_pt_BR.properties | 19 +
.../client/console/pages/ConfModalPage.html | 39 +
.../console/pages/ConfModalPage.properties | 17 +
.../console/pages/ConfModalPage_it.properties | 17 +
.../pages/ConfModalPage_pt_BR.properties | 17 +
.../client/console/pages/Configuration.html | 230 ++++++
.../console/pages/Configuration.properties | 48 ++
.../console/pages/Configuration_it.properties | 48 ++
.../pages/Configuration_pt_BR.properties | 48 ++
.../pages/ConfirmPasswordResetModalPage.html | 55 ++
.../ConfirmPasswordResetModalPage.properties | 20 +
.../ConfirmPasswordResetModalPage_it.properties | 20 +
...nfirmPasswordResetModalPage_pt_BR.properties | 20 +
.../console/pages/ConnObjectModalPage.html | 39 +
.../pages/ConnObjectModalPage.properties | 17 +
.../pages/ConnObjectModalPage_it.properties | 17 +
.../pages/ConnObjectModalPage_pt_BR.properties | 17 +
.../console/pages/ConnectorModalPage.html | 161 ++++
.../console/pages/ConnectorModalPage.properties | 43 +
.../pages/ConnectorModalPage_it.properties | 43 +
.../pages/ConnectorModalPage_pt_BR.properties | 43 +
.../console/pages/DerSchemaModalPage.html | 64 ++
.../console/pages/DerSchemaModalPage.properties | 22 +
.../pages/DerSchemaModalPage_it.properties | 22 +
.../pages/DerSchemaModalPage_pt_BR.properties | 22 +
.../pages/DisplayAttributesModalPage.html | 132 +++
.../pages/DisplayAttributesModalPage.properties | 33 +
.../DisplayAttributesModalPage_it.properties | 33 +
.../DisplayAttributesModalPage_pt_BR.properties | 33 +
.../syncope/client/console/pages/ErrorPage.html | 53 ++
.../console/pages/ExecMessageModalPage.html | 25 +
.../console/pages/FailureMessageModalPage.html | 36 +
.../client/console/pages/GroupModalPage.html | 52 ++
.../console/pages/GroupModalPage.properties | 48 ++
.../console/pages/GroupModalPage_it.properties | 50 ++
.../pages/GroupModalPage_pt_BR.properties | 48 ++
.../console/pages/GroupSelectModalPage.html | 24 +
.../syncope/client/console/pages/Groups.html | 80 ++
.../client/console/pages/Groups.properties | 26 +
.../client/console/pages/Groups_it.properties | 26 +
.../console/pages/Groups_pt_BR.properties | 26 +
.../syncope/client/console/pages/HomePage.html | 34 +
.../client/console/pages/InfoModalPage.html | 42 +
.../console/pages/InfoModalPage.properties | 19 +
.../console/pages/InfoModalPage_it.properties | 19 +
.../pages/InfoModalPage_pt_BR.properties | 19 +
.../syncope/client/console/pages/Login.html | 89 ++
.../client/console/pages/Login.properties | 22 +
.../client/console/pages/Login_it.properties | 22 +
.../client/console/pages/Login_pt_BR.properties | 22 +
.../console/pages/MembershipModalPage.html | 55 ++
.../pages/MembershipModalPage.properties | 35 +
.../pages/MembershipModalPage_it.properties | 35 +
.../pages/MembershipModalPage_pt_BR.properties | 35 +
.../console/pages/NotificationModalPage.html | 234 ++++++
.../pages/NotificationModalPage.properties | 40 +
.../pages/NotificationModalPage_it.properties | 40 +
.../NotificationModalPage_pt_BR.properties | 40 +
.../pages/NotificationTaskModalPage.html | 111 +++
.../pages/NotificationTaskModalPage.properties | 32 +
.../NotificationTaskModalPage_it.properties | 32 +
.../NotificationTaskModalPage_pt_BR.properties | 32 +
.../console/pages/PlainSchemaModalPage.html | 172 ++++
.../pages/PlainSchemaModalPage.properties | 38 +
.../pages/PlainSchemaModalPage_it.properties | 38 +
.../pages/PlainSchemaModalPage_pt_BR.properties | 38 +
.../client/console/pages/PolicyModalPage.html | 109 +++
.../console/pages/PolicyModalPage.properties | 88 ++
.../console/pages/PolicyModalPage_it.properties | 88 ++
.../pages/PolicyModalPage_pt_BR.properties | 87 ++
.../console/pages/PropagationTaskModalPage.html | 75 ++
.../pages/PropagationTaskModalPage.properties | 28 +
.../PropagationTaskModalPage_it.properties | 28 +
.../PropagationTaskModalPage_pt_BR.properties | 28 +
.../client/console/pages/PushTaskModalPage.html | 228 ++++++
.../console/pages/PushTaskModalPage.properties | 45 +
.../pages/PushTaskModalPage_it.properties | 47 ++
.../pages/PushTaskModalPage_pt_BR.properties | 45 +
.../client/console/pages/RecursivePanel.html | 28 +
.../ReportExecResultDownloadModalPage.html | 23 +
...ReportExecResultDownloadModalPage.properties | 18 +
...ortExecResultDownloadModalPage_it.properties | 18 +
...ExecResultDownloadModalPage_pt_BR.properties | 18 +
.../client/console/pages/ReportModalPage.html | 146 ++++
.../console/pages/ReportModalPage.properties | 36 +
.../console/pages/ReportModalPage_it.properties | 36 +
.../pages/ReportModalPage_pt_BR.properties | 36 +
.../console/pages/ReportletConfModalPage.html | 85 ++
.../pages/ReportletConfModalPage.properties | 22 +
.../pages/ReportletConfModalPage_it.properties | 22 +
.../ReportletConfModalPage_pt_BR.properties | 22 +
.../syncope/client/console/pages/Reports.html | 58 ++
.../client/console/pages/Reports.properties | 24 +
.../client/console/pages/Reports_it.properties | 24 +
.../console/pages/Reports_pt_BR.properties | 24 +
.../pages/RequestPasswordResetModalPage.html | 64 ++
.../RequestPasswordResetModalPage.properties | 21 +
.../RequestPasswordResetModalPage_it.properties | 21 +
...questPasswordResetModalPage_pt_BR.properties | 21 +
.../client/console/pages/ResourceModalPage.html | 64 ++
.../console/pages/ResourceModalPage.properties | 60 ++
.../pages/ResourceModalPage_it.properties | 60 ++
.../pages/ResourceModalPage_pt_BR.properties | 60 ++
.../syncope/client/console/pages/Resources.html | 99 +++
.../client/console/pages/Resources.properties | 34 +
.../console/pages/Resources_it.properties | 34 +
.../console/pages/Resources_pt_BR.properties | 32 +
.../console/pages/ResultStatusModalPage.html | 226 +++++
.../pages/ResultStatusModalPage.properties | 26 +
.../pages/ResultStatusModalPage_it.properties | 26 +
.../ResultStatusModalPage_pt_BR.properties | 26 +
.../client/console/pages/RouteModalPage.html | 49 ++
.../console/pages/RouteModalPage.properties | 18 +
.../console/pages/RouteModalPage_it.properties | 18 +
.../pages/RouteModalPage_pt_BR.properties | 18 +
.../console/pages/SchedTaskModalPage.html | 136 ++++
.../console/pages/SchedTaskModalPage.properties | 36 +
.../pages/SchedTaskModalPage_it.properties | 36 +
.../pages/SchedTaskModalPage_pt_BR.properties | 36 +
.../console/pages/Schema$SchemaTypePanel.html | 41 +
.../syncope/client/console/pages/Schema.html | 59 ++
.../client/console/pages/Schema.properties | 35 +
.../client/console/pages/Schema_it.properties | 35 +
.../console/pages/Schema_pt_BR.properties | 35 +
.../pages/SecurityQuestionModalPage.html | 46 ++
.../pages/SecurityQuestionModalPage.properties | 18 +
.../SecurityQuestionModalPage_it.properties | 18 +
.../SecurityQuestionModalPage_pt_BR.properties | 18 +
.../client/console/pages/SyncTaskModalPage.html | 205 +++++
.../console/pages/SyncTaskModalPage.properties | 43 +
.../pages/SyncTaskModalPage_it.properties | 44 +
.../pages/SyncTaskModalPage_pt_BR.properties | 43 +
.../syncope/client/console/pages/Tasks.html | 46 ++
.../client/console/pages/Tasks.properties | 21 +
.../client/console/pages/Tasks_it.properties | 21 +
.../client/console/pages/Tasks_pt_BR.properties | 21 +
.../syncope/client/console/pages/Todo.html | 45 +
.../client/console/pages/Todo.properties | 31 +
.../client/console/pages/Todo_it.properties | 31 +
.../client/console/pages/Todo_pt_BR.properties | 31 +
.../client/console/pages/UserModalPage.html | 97 +++
.../console/pages/UserModalPage.properties | 52 ++
.../console/pages/UserModalPage_it.properties | 53 ++
.../pages/UserModalPage_pt_BR.properties | 52 ++
.../console/pages/UserOwnerSelectModalPage.html | 38 +
.../pages/UserOwnerSelectModalPage.properties | 23 +
.../UserOwnerSelectModalPage_it.properties | 23 +
.../UserOwnerSelectModalPage_pt_BR.properties | 23 +
.../syncope/client/console/pages/Users.html | 72 ++
.../client/console/pages/Users.properties | 26 +
.../client/console/pages/Users_it.properties | 26 +
.../client/console/pages/Users_pt_BR.properties | 26 +
.../console/pages/VirSchemaModalPage.html | 53 ++
.../console/pages/VirSchemaModalPage.properties | 22 +
.../pages/VirSchemaModalPage_it.properties | 22 +
.../pages/VirSchemaModalPage_pt_BR.properties | 22 +
.../client/console/pages/WelcomePage.html | 70 ++
.../client/console/pages/WelcomePage.properties | 18 +
.../console/pages/WelcomePage_it.properties | 18 +
.../console/pages/WelcomePage_pt_BR.properties | 18 +
.../console/pages/XMLEditorPopupPage.html | 82 ++
.../console/pages/XMLEditorPopupPage.properties | 19 +
.../pages/XMLEditorPopupPage_it.properties | 19 +
.../pages/XMLEditorPopupPage_pt_BR.properties | 19 +
.../panels/AbstractProvisioningTasksPanel.html | 41 +
.../console/panels/AbstractSearchPanel.html | 50 ++
.../panels/AbstractSearchResultPanel.html | 43 +
.../panels/AbstractSearchResultPanel.properties | 30 +
.../AbstractSearchResultPanel_it.properties | 30 +
.../AbstractSearchResultPanel_pt_BR.properties | 30 +
.../console/panels/AccountInformationPanel.html | 67 ++
.../panels/AccountInformationPanel.properties | 22 +
.../AccountInformationPanel_it.properties | 23 +
.../AccountInformationPanel_pt_BR.properties | 23 +
.../console/panels/ActionDataTablePanel.html | 45 +
.../console/panels/AjaxDataTablePanel.html | 47 ++
.../console/panels/AnnotatedBeanPanel.html | 98 +++
.../panels/AnnotatedBeanPanel.properties | 20 +
.../panels/AnnotatedBeanPanel_it.properties | 20 +
.../panels/AnnotatedBeanPanel_pt_BR.properties | 20 +
.../console/panels/AttrTemplatesPanel.html | 58 ++
.../panels/AttrTemplatesPanel.properties | 23 +
.../panels/AttrTemplatesPanel_it.properties | 23 +
.../panels/AttrTemplatesPanel_pt_BR.properties | 23 +
.../client/console/panels/AuditEventsPanel.html | 122 +++
.../client/console/panels/DerAttrsPanel.html | 60 ++
.../console/panels/DerAttrsPanel.properties | 17 +
.../console/panels/DerAttrsPanel_it.properties | 18 +
.../panels/DerAttrsPanel_pt_BR.properties | 17 +
.../console/panels/EventSelectionPanel.html | 125 +++
.../console/panels/GroupDetailsPanel.html | 107 +++
.../console/panels/GroupDetailsPanel.properties | 22 +
.../panels/GroupDetailsPanel_it.properties | 22 +
.../panels/GroupDetailsPanel_pt_BR.properties | 22 +
.../client/console/panels/GroupPanel.html | 88 ++
.../client/console/panels/GroupPanel.properties | 51 ++
.../console/panels/GroupPanel_it.properties | 53 ++
.../console/panels/GroupPanel_pt_BR.properties | 40 +
.../console/panels/GroupSecurityPanel.html | 66 ++
.../panels/GroupSecurityPanel.properties | 20 +
.../panels/GroupSecurityPanel_it.properties | 20 +
.../panels/GroupSecurityPanel_pt_BR.properties | 20 +
.../console/panels/GroupSummaryPanel.html | 39 +
.../client/console/panels/GroupTabPanel.html | 64 ++
.../console/panels/GroupTabPanel.properties | 27 +
.../console/panels/GroupTabPanel_it.properties | 27 +
.../panels/GroupTabPanel_pt_BR.properties | 27 +
.../client/console/panels/ImagePanel.html | 23 +
.../console/panels/JQueryUITabbedPanel.html | 41 +
.../client/console/panels/LayoutsPanel.html | 41 +
.../console/panels/LayoutsPanel.properties | 18 +
.../console/panels/LayoutsPanel_it.properties | 18 +
.../panels/LayoutsPanel_pt_BR.properties | 18 +
.../console/panels/LoggerCategoryPanel.html | 106 +++
.../client/console/panels/MembershipsPanel.html | 66 ++
.../console/panels/MembershipsPanel.properties | 23 +
.../panels/MembershipsPanel_it.properties | 24 +
.../panels/MembershipsPanel_pt_BR.properties | 23 +
.../console/panels/NotificationTasks.html | 38 +
.../console/panels/NotificationTasks.properties | 26 +
.../panels/NotificationTasks_it.properties | 26 +
.../panels/NotificationTasks_pt_BR.properties | 26 +
.../client/console/panels/PlainAttrsPanel.html | 44 +
.../client/console/panels/PoliciesPanel.html | 42 +
.../console/panels/PoliciesPanel.properties | 34 +
.../console/panels/PoliciesPanel_it.properties | 34 +
.../panels/PoliciesPanel_pt_BR.properties | 34 +
.../client/console/panels/PolicyBeanPanel.html | 39 +
.../client/console/panels/PropagationTasks.html | 37 +
.../console/panels/PropagationTasks.properties | 28 +
.../panels/PropagationTasks_it.properties | 28 +
.../panels/PropagationTasks_pt_BR.properties | 28 +
.../console/panels/PushTasksPanel.properties | 29 +
.../console/panels/PushTasksPanel_it.properties | 29 +
.../panels/PushTasksPanel_pt_BR.properties | 29 +
.../console/panels/ResourceConnConfPanel.html | 41 +
.../console/panels/ResourceDetailsPanel.html | 137 ++++
.../console/panels/ResourceMappingPanel.html | 125 +++
.../console/panels/ResourceSecurityPanel.html | 56 ++
.../panels/ResourceSecurityPanel.properties | 19 +
.../panels/ResourceSecurityPanel_it.properties | 19 +
.../ResourceSecurityPanel_pt_BR.properties | 19 +
.../client/console/panels/ResourcesPanel.html | 23 +
.../client/console/panels/SchedTasks.html | 42 +
.../client/console/panels/SchedTasks.properties | 28 +
.../console/panels/SchedTasks_it.properties | 28 +
.../console/panels/SchedTasks_pt_BR.properties | 28 +
.../console/panels/SecurityQuestionPanel.html | 41 +
.../panels/SecurityQuestionPanel.properties | 18 +
.../panels/SecurityQuestionPanel_it.properties | 18 +
.../SecurityQuestionPanel_pt_BR.properties | 18 +
.../console/panels/SelectedEventsPanel.html | 33 +
.../client/console/panels/StatusPanel.html | 130 +++
.../console/panels/StatusPanel.properties | 19 +
.../console/panels/StatusPanel_it.properties | 19 +
.../console/panels/StatusPanel_pt_BR.properties | 19 +
.../console/panels/SyncTasksPanel.properties | 29 +
.../console/panels/SyncTasksPanel_it.properties | 29 +
.../panels/SyncTasksPanel_pt_BR.properties | 29 +
.../client/console/panels/UserDetailsPanel.html | 71 ++
.../console/panels/UserDetailsPanel.properties | 19 +
.../panels/UserDetailsPanel_it.properties | 19 +
.../panels/UserDetailsPanel_pt_BR.properties | 19 +
.../client/console/panels/VirAttrsPanel.html | 60 ++
.../console/panels/VirAttrsPanel.properties | 19 +
.../console/panels/VirAttrsPanel_it.properties | 20 +
.../panels/VirAttrsPanel_pt_BR.properties | 19 +
.../data/table/CheckBoxGroupSelectorPanel.html | 21 +
.../html/repeater/data/table/CheckBoxPanel.html | 23 +
.../repeater/data/table/CollectionPanel.html | 25 +
.../markup/html/CrontabContainer.properties | 22 +
.../markup/html/CrontabContainer_it.properties | 22 +
.../html/CrontabContainer_pt_BR.properties | 22 +
.../markup/html/form/ActionLinksPanel.html | 163 ++++
.../markup/html/form/AjaxCheckBoxPanel.html | 21 +
.../html/form/AjaxDropDownChoicePanel.html | 24 +
.../markup/html/form/AjaxNumberFieldPanel.html | 22 +
.../markup/html/form/AjaxPalettePanel.html | 23 +
.../html/form/AjaxPasswordFieldPanel.html | 22 +
.../markup/html/form/AjaxTextFieldPanel.html | 23 +
.../markup/html/form/BinaryFieldPanel.html | 44 +
.../form/CheckBoxMultipleChoiceFieldPanel.html | 23 +
.../markup/html/form/DateTextFieldPanel.html | 22 +
.../markup/html/form/DateTimeFieldPanel.html | 21 +
.../html/form/DateTimeFieldPanel.properties | 17 +
.../html/form/DateTimeFieldPanel_it.properties | 17 +
.../form/DateTimeFieldPanel_pt_BR.properties | 17 +
.../wicket/markup/html/form/FieldPanel.html | 34 +
.../wicket/markup/html/form/LinkPanel.html | 23 +
.../markup/html/form/MappingPurposePanel.html | 31 +
.../markup/html/form/MultiFieldPanel.html | 35 +
.../markup/html/form/MultiFieldPanel.properties | 22 +
.../html/form/MultiFieldPanel_it.properties | 22 +
.../html/form/MultiFieldPanel_pt_BR.properties | 22 +
.../wicket/markup/html/form/NonI18nPalette.html | 69 ++
.../markup/html/form/SpinnerFieldPanel.html | 29 +
.../form/preview/AbstractBinaryPreviewer.html | 24 +
.../html/form/preview/BinaryCertPreviewer.html | 24 +
.../html/form/preview/BinaryImagePreviewer.html | 23 +
.../wicket/markup/html/tree/TreeGroupPanel.html | 25 +
client/pom.xml | 3 +-
.../console/pages/CamelRouteModalPage.java | 46 +-
.../client/console/panels/CamelRoutePanel.java | 16 +-
.../console/rest/CamelRouteRestClient.java | 6 +-
pom.xml | 2 +-
1285 files changed, 49765 insertions(+), 41171 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/BinaryPreview.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/BinaryPreview.java b/client/console/src/main/java/org/apache/syncope/client/console/BinaryPreview.java
deleted file mode 100644
index c499d60..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/BinaryPreview.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console;
-
-import java.lang.annotation.Documented;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
-
-@Target({ ElementType.TYPE })
-@Retention(RetentionPolicy.RUNTIME)
-@Documented
-public @interface BinaryPreview {
-
- public String[] mimeTypes() default {};
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/ExtensionPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/ExtensionPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/ExtensionPanel.java
deleted file mode 100644
index 5574926..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/ExtensionPanel.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console;
-
-import java.lang.annotation.Documented;
-import java.lang.annotation.ElementType;
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.lang.annotation.Target;
-
-@Target({ ElementType.TYPE })
-@Retention(RetentionPolicy.RUNTIME)
-@Documented
-public @interface ExtensionPanel {
-
- public String value();
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/PreferenceManager.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/PreferenceManager.java b/client/console/src/main/java/org/apache/syncope/client/console/PreferenceManager.java
new file mode 100644
index 0000000..381fc65
--- /dev/null
+++ b/client/console/src/main/java/org/apache/syncope/client/console/PreferenceManager.java
@@ -0,0 +1,173 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console;
+
+import com.fasterxml.jackson.databind.ObjectMapper;
+import com.fasterxml.jackson.core.type.TypeReference;
+import java.io.IOException;
+import java.io.StringWriter;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import org.apache.commons.lang3.math.NumberUtils;
+import org.apache.wicket.request.Request;
+import org.apache.wicket.request.Response;
+import org.apache.wicket.util.cookies.CookieDefaults;
+import org.apache.wicket.util.cookies.CookieUtils;
+import org.apache.wicket.util.crypt.Base64;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.util.StringUtils;
+
+public class PreferenceManager {
+
+ private static final Logger LOG = LoggerFactory.getLogger(PreferenceManager.class);
+
+ private static final String PREFMAN_KEY = "prefMan";
+
+ private static final int ONE_YEAR_TIME = 60 * 60 * 24 * 365;
+
+ private static final TypeReference<Map<String, String>> MAP_TYPE_REF = new TypeReference<Map<String, String>>() {
+ };
+
+ private static final List<Integer> PAGINATOR_CHOICES = Arrays.asList(new Integer[] { 10, 25, 50 });
+
+ private final ObjectMapper mapper;
+
+ private final CookieUtils cookieUtils;
+
+ public PreferenceManager() {
+ this.mapper = new ObjectMapper();
+
+ CookieDefaults cookieDefaults = new CookieDefaults();
+ cookieDefaults.setMaxAge(ONE_YEAR_TIME);
+ this.cookieUtils = new CookieUtils(cookieDefaults);
+ }
+
+ public List<Integer> getPaginatorChoices() {
+ return PAGINATOR_CHOICES;
+ }
+
+ private Map<String, String> getPrefs(final String value) {
+ Map<String, String> prefs;
+ try {
+ if (StringUtils.hasText(value)) {
+ prefs = mapper.readValue(value, MAP_TYPE_REF);
+ } else {
+ throw new Exception("Invalid cookie value '" + value + "'");
+ }
+ } catch (Exception e) {
+ LOG.debug("No preferences found", e);
+ prefs = new HashMap<>();
+ }
+
+ return prefs;
+ }
+
+ private String setPrefs(final Map<String, String> prefs) throws IOException {
+ StringWriter writer = new StringWriter();
+ mapper.writeValue(writer, prefs);
+
+ return writer.toString();
+ }
+
+ public String get(final Request request, final String key) {
+ String result = null;
+
+ String prefString = cookieUtils.load(PREFMAN_KEY);
+ if (prefString != null) {
+ final Map<String, String> prefs = getPrefs(new String(Base64.decodeBase64(prefString.getBytes())));
+ result = prefs.get(key);
+ }
+
+ return result;
+ }
+
+ public Integer getPaginatorRows(final Request request, final String key) {
+ Integer result = getPaginatorChoices().get(0);
+
+ String value = get(request, key);
+ if (value != null) {
+ result = NumberUtils.toInt(value, 10);
+ }
+
+ return result;
+ }
+
+ public List<String> getList(final Request request, final String key) {
+ final List<String> result = new ArrayList<>();
+
+ final String compound = get(request, key);
+
+ if (StringUtils.hasText(compound)) {
+ String[] items = compound.split(";");
+ result.addAll(Arrays.asList(items));
+ }
+
+ return result;
+ }
+
+ public void set(final Request request, final Response response, final Map<String, List<String>> prefs) {
+ Map<String, String> current = new HashMap<>();
+
+ String prefString = cookieUtils.load(PREFMAN_KEY);
+ if (prefString != null) {
+ current.putAll(getPrefs(new String(Base64.decodeBase64(prefString.getBytes()))));
+ }
+
+ // after retrieved previous setting in order to overwrite the key ...
+ for (Map.Entry<String, List<String>> entry : prefs.entrySet()) {
+ current.put(entry.getKey(), StringUtils.collectionToDelimitedString(entry.getValue(), ";"));
+ }
+
+ try {
+ cookieUtils.save(PREFMAN_KEY, new String(Base64.encodeBase64(setPrefs(current).getBytes())));
+ } catch (IOException e) {
+ LOG.error("Could not save {} info: {}", getClass().getSimpleName(), current, e);
+ }
+ }
+
+ public void set(final Request request, final Response response, final String key, final String value) {
+ String prefString = cookieUtils.load(PREFMAN_KEY);
+
+ final Map<String, String> current = new HashMap<>();
+ if (prefString != null) {
+ current.putAll(getPrefs(new String(Base64.decodeBase64(prefString.getBytes()))));
+ }
+
+ // after retrieved previous setting in order to overwrite the key ...
+ current.put(key, value);
+
+ try {
+ cookieUtils.save(PREFMAN_KEY, new String(Base64.encodeBase64(setPrefs(current).getBytes())));
+ } catch (IOException e) {
+ LOG.error("Could not save {} info: {}", getClass().getSimpleName(), current, e);
+ }
+ }
+
+ public void setList(final Request request, final Response response, final String key, final List<String> values) {
+ set(request, response, key, StringUtils.collectionToDelimitedString(values, ";"));
+ }
+
+ public void setList(final Request request, final Response response, final Map<String, List<String>> prefs) {
+ set(request, response, prefs);
+ }
+}
[48/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/Configuration.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/Configuration.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/Configuration.java
deleted file mode 100644
index 9f8c734..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/Configuration.java
+++ /dev/null
@@ -1,814 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import static org.apache.syncope.client.console.pages.AbstractBasePage.LOG;
-
-import java.io.File;
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-import org.apache.logging.log4j.LogManager;
-import org.apache.logging.log4j.core.LoggerContext;
-import org.apache.logging.log4j.core.config.LoggerConfig;
-import org.apache.syncope.client.console.ExtensionPanel;
-import org.apache.syncope.client.console.commons.AttrLayoutType;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.HttpResourceStream;
-import org.apache.syncope.client.console.commons.PreferenceManager;
-import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
-import org.apache.syncope.client.console.init.ImplementationClassNamesLoader;
-import org.apache.syncope.client.console.panels.AbstractExtensionPanel;
-import org.apache.syncope.client.console.panels.JQueryUITabbedPanel;
-import org.apache.syncope.client.console.panels.LayoutsPanel;
-import org.apache.syncope.client.console.panels.PoliciesPanel;
-import org.apache.syncope.client.console.rest.LoggerRestClient;
-import org.apache.syncope.client.console.rest.NotificationRestClient;
-import org.apache.syncope.client.console.rest.SecurityQuestionRestClient;
-import org.apache.syncope.client.console.rest.WorkflowRestClient;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.CollectionPropertyColumn;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.client.console.wicket.markup.html.link.VeilPopupSettings;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.SyncopeConstants;
-import org.apache.syncope.common.lib.to.LoggerTO;
-import org.apache.syncope.common.lib.to.NotificationTO;
-import org.apache.syncope.common.lib.to.SecurityQuestionTO;
-import org.apache.syncope.common.lib.types.LoggerLevel;
-import org.apache.syncope.common.lib.types.PolicyType;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
-import org.apache.wicket.extensions.markup.html.tabs.AbstractTab;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.image.Image;
-import org.apache.wicket.markup.html.link.BookmarkablePageLink;
-import org.apache.wicket.markup.html.link.Link;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.PropertyListView;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.AbstractReadOnlyModel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.protocol.http.WebApplication;
-import org.apache.wicket.request.handler.resource.ResourceStreamRequestHandler;
-import org.apache.wicket.request.resource.ContentDisposition;
-import org.apache.wicket.request.resource.DynamicImageResource;
-import org.apache.wicket.request.resource.IResource;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.springframework.util.ClassUtils;
-import org.springframework.web.context.support.WebApplicationContextUtils;
-
-/**
- * Configurations WebPage.
- */
-public class Configuration extends BasePage {
-
- private static final long serialVersionUID = -2838270869037702214L;
-
- private static final int SYNCOPECONF_WIN_HEIGHT = 300;
-
- private static final int SYNCOPECONF_WIN_WIDTH = 900;
-
- private static final int NOTIFICATION_WIN_HEIGHT = 500;
-
- private static final int NOTIFICATION_WIN_WIDTH = 1100;
-
- private static final int SECURITY_QUESTION_WIN_HEIGHT = 300;
-
- private static final int SECURITY_QUESTION_WIN_WIDTH = 900;
-
- @SpringBean
- private LoggerRestClient loggerRestClient;
-
- @SpringBean
- private NotificationRestClient notificationRestClient;
-
- @SpringBean
- private SecurityQuestionRestClient securityQuestionRestClient;
-
- @SpringBean
- private WorkflowRestClient wfRestClient;
-
- @SpringBean
- private PreferenceManager prefMan;
-
- @SpringBean
- private ImplementationClassNamesLoader implementationClassNamesLoader;
-
- private final ModalWindow syncopeConfWin;
-
- private final ModalWindow createNotificationWin;
-
- private final ModalWindow editNotificationWin;
-
- private final ModalWindow createSecurityQuestionWin;
-
- private final ModalWindow editSecurityQuestionWin;
-
- private WebMarkupContainer notificationContainer;
-
- private WebMarkupContainer securityQuestionContainer;
-
- private int notificationPaginatorRows;
-
- public Configuration() {
- super();
-
- // Layouts
- add(new LayoutsPanel("adminUserLayoutPanel", AttrLayoutType.ADMIN_USER, feedbackPanel));
- add(new LayoutsPanel("selfUserLayoutPanel", AttrLayoutType.SELF_USER, feedbackPanel));
- add(new LayoutsPanel("adminGroupLayoutPanel", AttrLayoutType.ADMIN_GROUP, feedbackPanel));
- add(new LayoutsPanel("selfGroupLayoutPanel", AttrLayoutType.SELF_GROUP, feedbackPanel));
- add(new LayoutsPanel("adminMembershipLayoutPanel", AttrLayoutType.ADMIN_MEMBERSHIP, feedbackPanel));
- add(new LayoutsPanel("selfMembershipLayoutPanel", AttrLayoutType.SELF_MEMBERSHIP, feedbackPanel));
-
- add(syncopeConfWin = new ModalWindow("syncopeConfWin"));
- syncopeConfWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- syncopeConfWin.setInitialHeight(SYNCOPECONF_WIN_HEIGHT);
- syncopeConfWin.setInitialWidth(SYNCOPECONF_WIN_WIDTH);
- syncopeConfWin.setCookieName("syncopeconf-modal");
- setupSyncopeConf();
-
- add(new PoliciesPanel("passwordPoliciesPanel", getPageReference(), PolicyType.PASSWORD));
- add(new PoliciesPanel("accountPoliciesPanel", getPageReference(), PolicyType.ACCOUNT));
- add(new PoliciesPanel("syncPoliciesPanel", getPageReference(), PolicyType.SYNC));
-
- add(createNotificationWin = new ModalWindow("createNotificationWin"));
- createNotificationWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- createNotificationWin.setInitialHeight(NOTIFICATION_WIN_HEIGHT);
- createNotificationWin.setInitialWidth(NOTIFICATION_WIN_WIDTH);
- createNotificationWin.setCookieName("create-notification-modal");
- add(editNotificationWin = new ModalWindow("editNotificationWin"));
- editNotificationWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- editNotificationWin.setInitialHeight(NOTIFICATION_WIN_HEIGHT);
- editNotificationWin.setInitialWidth(NOTIFICATION_WIN_WIDTH);
- editNotificationWin.setCookieName("edit-notification-modal");
- setupNotification();
-
- add(createSecurityQuestionWin = new ModalWindow("createSecurityQuestionWin"));
- createSecurityQuestionWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- createSecurityQuestionWin.setInitialHeight(SECURITY_QUESTION_WIN_HEIGHT);
- createSecurityQuestionWin.setInitialWidth(SECURITY_QUESTION_WIN_WIDTH);
- createSecurityQuestionWin.setCookieName("create-security-question-modal");
- add(editSecurityQuestionWin = new ModalWindow("editSecurityQuestionWin"));
- editSecurityQuestionWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- editSecurityQuestionWin.setInitialHeight(SECURITY_QUESTION_WIN_HEIGHT);
- editSecurityQuestionWin.setInitialWidth(SECURITY_QUESTION_WIN_WIDTH);
- editSecurityQuestionWin.setCookieName("edit-security-question-modal");
- setupSecurityQuestion();
-
- // Workflow definition stuff
- WebMarkupContainer noActivitiEnabledForUsers = new WebMarkupContainer("noActivitiEnabledForUsers");
- noActivitiEnabledForUsers.setOutputMarkupPlaceholderTag(true);
- add(noActivitiEnabledForUsers);
-
- WebMarkupContainer workflowDefContainer = new WebMarkupContainer("workflowDefContainer");
- workflowDefContainer.setOutputMarkupPlaceholderTag(true);
-
- if (wfRestClient.isActivitiEnabledForUsers()) {
- noActivitiEnabledForUsers.setVisible(false);
- } else {
- workflowDefContainer.setVisible(false);
- }
-
- BookmarkablePageLink<Void> activitiModeler =
- new BookmarkablePageLink<>("activitiModeler", ActivitiModelerPopupPage.class);
- activitiModeler.setPopupSettings(new VeilPopupSettings().setHeight(600).setWidth(800));
- MetaDataRoleAuthorizationStrategy.authorize(activitiModeler, ENABLE,
- xmlRolesReader.getEntitlement("Configuration", "workflowDefRead"));
- workflowDefContainer.add(activitiModeler);
- // Check if Activiti Modeler directory is found
- boolean activitiModelerEnabled = false;
- try {
- String activitiModelerDirectory = WebApplicationContextUtils.getWebApplicationContext(
- WebApplication.get().getServletContext()).getBean("activitiModelerDirectory", String.class);
- File baseDir = new File(activitiModelerDirectory);
- activitiModelerEnabled = baseDir.exists() && baseDir.canRead() && baseDir.isDirectory();
- } catch (Exception e) {
- LOG.error("Could not check for Activiti Modeler directory", e);
- }
- activitiModeler.setEnabled(activitiModelerEnabled);
-
- BookmarkablePageLink<Void> xmlEditor = new BookmarkablePageLink<>("xmlEditor", XMLEditorPopupPage.class);
- xmlEditor.setPopupSettings(new VeilPopupSettings().setHeight(480).setWidth(800));
- MetaDataRoleAuthorizationStrategy.authorize(xmlEditor, ENABLE,
- xmlRolesReader.getEntitlement("Configuration", "workflowDefRead"));
- workflowDefContainer.add(xmlEditor);
-
- Image workflowDefDiagram = new Image("workflowDefDiagram", new Model()) {
-
- private static final long serialVersionUID = -8457850449086490660L;
-
- @Override
- protected IResource getImageResource() {
- return new DynamicImageResource() {
-
- private static final long serialVersionUID = 923201517955737928L;
-
- @Override
- protected byte[] getImageData(final IResource.Attributes attributes) {
- return wfRestClient.isActivitiEnabledForUsers()
- ? wfRestClient.getDiagram()
- : new byte[0];
- }
- };
- }
- };
- workflowDefContainer.add(workflowDefDiagram);
-
- MetaDataRoleAuthorizationStrategy.authorize(workflowDefContainer, ENABLE,
- xmlRolesReader.getEntitlement("Configuration", "workflowDefRead"));
- add(workflowDefContainer);
-
- // Logger stuff
- PropertyListView<LoggerTO> coreLoggerList =
- new LoggerPropertyList(null, "corelogger", loggerRestClient.listLogs());
- WebMarkupContainer coreLoggerContainer = new WebMarkupContainer("coreLoggerContainer");
- coreLoggerContainer.add(coreLoggerList);
- coreLoggerContainer.setOutputMarkupId(true);
-
- MetaDataRoleAuthorizationStrategy.authorize(coreLoggerContainer, ENABLE, xmlRolesReader.getEntitlement(
- "Configuration", "logList"));
- add(coreLoggerContainer);
-
- ConsoleLoggerController consoleLoggerController = new ConsoleLoggerController();
- PropertyListView<LoggerTO> consoleLoggerList =
- new LoggerPropertyList(consoleLoggerController, "consolelogger", consoleLoggerController.getLoggers());
- WebMarkupContainer consoleLoggerContainer = new WebMarkupContainer("consoleLoggerContainer");
- consoleLoggerContainer.add(consoleLoggerList);
- consoleLoggerContainer.setOutputMarkupId(true);
-
- MetaDataRoleAuthorizationStrategy.authorize(
- consoleLoggerContainer, ENABLE, xmlRolesReader.getEntitlement("Configuration", "logList"));
- add(consoleLoggerContainer);
-
- // Extension panels
- setupExtPanels();
- }
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- private void setupSyncopeConf() {
- final WebMarkupContainer parameters = new WebMarkupContainer("parameters");
- parameters.setOutputMarkupId(true);
- add(parameters);
-
- setWindowClosedCallback(syncopeConfWin, parameters);
-
- AjaxLink<Void> confLink = new IndicatingAjaxLink<Void>("confLink") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- syncopeConfWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ConfModalPage(getPageReference(), editNotificationWin, parameters);
- }
- });
-
- syncopeConfWin.show(target);
- }
- };
- parameters.add(confLink);
-
- Link<Void> dbExportLink = new Link<Void>("dbExportLink") {
-
- private static final long serialVersionUID = -4331619903296515985L;
-
- @Override
- public void onClick() {
- try {
- HttpResourceStream stream = new HttpResourceStream(confRestClient.dbExport());
-
- ResourceStreamRequestHandler rsrh = new ResourceStreamRequestHandler(stream);
- rsrh.setFileName(stream.getFilename() == null ? "content.xml" : stream.getFilename());
- rsrh.setContentDisposition(ContentDisposition.ATTACHMENT);
-
- getRequestCycle().scheduleRequestHandlerAfterCurrent(rsrh);
- } catch (Exception e) {
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- }
- }
- };
- MetaDataRoleAuthorizationStrategy.authorize(
- dbExportLink, ENABLE, xmlRolesReader.getEntitlement("Configuration", "export"));
- add(dbExportLink);
- }
-
- private void setupNotification() {
- notificationPaginatorRows = prefMan.getPaginatorRows(getRequest(), Constants.PREF_NOTIFICATION_PAGINATOR_ROWS);
-
- final List<IColumn<NotificationTO, String>> notificationCols = new ArrayList<>();
- notificationCols.add(new PropertyColumn<NotificationTO, String>(
- new ResourceModel("key"), "key", "key"));
- notificationCols.add(new CollectionPropertyColumn<NotificationTO>(
- new ResourceModel("events"), "events", "events"));
- notificationCols.add(new PropertyColumn<NotificationTO, String>(
- new ResourceModel("subject"), "subject", "subject"));
- notificationCols.add(new PropertyColumn<NotificationTO, String>(
- new ResourceModel("template"), "template", "template"));
- notificationCols.add(new PropertyColumn<NotificationTO, String>(
- new ResourceModel("traceLevel"), "traceLevel", "traceLevel"));
- notificationCols.add(new PropertyColumn<NotificationTO, String>(
- new ResourceModel("active"), "active", "active"));
-
- notificationCols.add(new AbstractColumn<NotificationTO, String>(new ResourceModel("actions", "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public String getCssClass() {
- return "action";
- }
-
- @Override
- public void populateItem(final Item<ICellPopulator<NotificationTO>> cellItem, final String componentId,
- final IModel<NotificationTO> model) {
-
- final NotificationTO notificationTO = model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- editNotificationWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new NotificationModalPage(Configuration.this.getPageReference(),
- editNotificationWin, notificationTO, false);
- }
- });
-
- editNotificationWin.show(target);
- }
- }, ActionLink.ActionType.EDIT, "Notification");
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- notificationRestClient.delete(notificationTO.getKey());
- } catch (SyncopeClientException e) {
- LOG.error("While deleting a notification", e);
- error(e.getMessage());
- return;
- }
-
- info(getString(Constants.OPERATION_SUCCEEDED));
- feedbackPanel.refresh(target);
- target.add(notificationContainer);
- }
- }, ActionLink.ActionType.DELETE, "Notification");
-
- cellItem.add(panel);
- }
- });
-
- final AjaxFallbackDefaultDataTable<NotificationTO, String> notificationTable =
- new AjaxFallbackDefaultDataTable<>(
- "notificationTable", notificationCols, new NotificationProvider(), notificationPaginatorRows);
-
- notificationContainer = new WebMarkupContainer("notificationContainer");
- notificationContainer.add(notificationTable);
- notificationContainer.setOutputMarkupId(true);
-
- add(notificationContainer);
-
- setWindowClosedCallback(createNotificationWin, notificationContainer);
- setWindowClosedCallback(editNotificationWin, notificationContainer);
-
- AjaxLink<Void> createNotificationLink = new AjaxLink<Void>("createNotificationLink") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- createNotificationWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new NotificationModalPage(Configuration.this.getPageReference(), createNotificationWin,
- new NotificationTO(), true);
- }
- });
-
- createNotificationWin.show(target);
- }
- };
-
- MetaDataRoleAuthorizationStrategy.authorize(createNotificationLink, ENABLE, xmlRolesReader.getEntitlement(
- "Notification", "create"));
- add(createNotificationLink);
-
- @SuppressWarnings("rawtypes")
- Form notificationPaginatorForm = new Form("notificationPaginatorForm");
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- final DropDownChoice rowsChooser = new DropDownChoice("rowsChooser", new PropertyModel(this,
- "notificationPaginatorRows"), prefMan.getPaginatorChoices());
-
- rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- prefMan.set(getRequest(), getResponse(), Constants.PREF_NOTIFICATION_PAGINATOR_ROWS, String.valueOf(
- notificationPaginatorRows));
- notificationTable.setItemsPerPage(notificationPaginatorRows);
-
- target.add(notificationContainer);
- }
- });
-
- notificationPaginatorForm.add(rowsChooser);
- add(notificationPaginatorForm);
- }
-
- private void setupSecurityQuestion() {
- final List<IColumn<SecurityQuestionTO, String>> securityQuestionCols = new ArrayList<>();
- securityQuestionCols.add(new PropertyColumn<SecurityQuestionTO, String>(
- new ResourceModel("key"), "key", "key"));
- securityQuestionCols.add(new PropertyColumn<SecurityQuestionTO, String>(
- new ResourceModel("content"), "content", "content"));
-
- securityQuestionCols.add(new AbstractColumn<SecurityQuestionTO, String>(new ResourceModel("actions", "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public String getCssClass() {
- return "action";
- }
-
- @Override
- public void populateItem(final Item<ICellPopulator<SecurityQuestionTO>> cellItem, final String componentId,
- final IModel<SecurityQuestionTO> model) {
-
- final SecurityQuestionTO securityQuestionTO = model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- editSecurityQuestionWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new SecurityQuestionModalPage(Configuration.this.getPageReference(),
- editSecurityQuestionWin, securityQuestionTO, false);
- }
- });
-
- editSecurityQuestionWin.show(target);
- }
- }, ActionLink.ActionType.EDIT, "SecurityQuestion");
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- securityQuestionRestClient.delete(securityQuestionTO.getKey());
- } catch (SyncopeClientException e) {
- LOG.error("While deleting a security question", e);
- error(e.getMessage());
- return;
- }
-
- info(getString(Constants.OPERATION_SUCCEEDED));
- feedbackPanel.refresh(target);
- target.add(securityQuestionContainer);
- }
- }, ActionLink.ActionType.DELETE, "SecurityQuestion");
-
- cellItem.add(panel);
- }
- });
-
- final AjaxFallbackDefaultDataTable<SecurityQuestionTO, String> securityQuestionTable =
- new AjaxFallbackDefaultDataTable<>("securityQuestionTable",
- securityQuestionCols, new SecurityQuestionProvider(), 50);
-
- securityQuestionContainer = new WebMarkupContainer("securityQuestionContainer");
- securityQuestionContainer.add(securityQuestionTable);
- securityQuestionContainer.setOutputMarkupId(true);
-
- add(securityQuestionContainer);
-
- setWindowClosedCallback(createSecurityQuestionWin, securityQuestionContainer);
- setWindowClosedCallback(editSecurityQuestionWin, securityQuestionContainer);
-
- AjaxLink<Void> createSecurityQuestionLink = new AjaxLink<Void>("createSecurityQuestionLink") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
-
- createSecurityQuestionWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new SecurityQuestionModalPage(Configuration.this.getPageReference(),
- createSecurityQuestionWin, new SecurityQuestionTO(), true);
- }
- });
-
- createSecurityQuestionWin.show(target);
- }
- };
-
- MetaDataRoleAuthorizationStrategy.authorize(
- createSecurityQuestionLink, ENABLE, xmlRolesReader.getEntitlement("SecurityQuestion", "create"));
- add(createSecurityQuestionLink);
- }
-
- private void setupExtPanels() {
- List<AbstractTab> tabs = new ArrayList<>();
- int index = 0;
- for (final Class<? extends AbstractExtensionPanel> clazz
- : implementationClassNamesLoader.getExtPanelClasses()) {
-
- String title = clazz.getAnnotation(ExtensionPanel.class) == null
- ? "Extension " + index
- : clazz.getAnnotation(ExtensionPanel.class).value();
- tabs.add(new AbstractTab(new Model<>(title)) {
-
- private static final long serialVersionUID = -5861786415855103549L;
-
- @Override
- public WebMarkupContainer getPanel(final String panelId) {
- Panel panel;
-
- try {
- panel = ClassUtils.getConstructorIfAvailable(clazz, String.class, PageReference.class).
- newInstance(panelId, Configuration.this.getPageReference());
- } catch (Exception e) {
- panel = new Panel(panelId) {
-
- private static final long serialVersionUID = 5538299138211283825L;
-
- };
-
- LOG.error("Could not instantiate {}", clazz.getName(), e);
- }
-
- return panel;
- }
- });
-
- index++;
- }
-
- JQueryUITabbedPanel<AbstractTab> extPanels = new JQueryUITabbedPanel<>("extPanels", tabs);
- extPanels.setVisible(!tabs.isEmpty());
- add(extPanels);
- }
-
- private class NotificationProvider extends SortableDataProvider<NotificationTO, String> {
-
- private static final long serialVersionUID = -276043813563988590L;
-
- private final SortableDataProviderComparator<NotificationTO> comparator;
-
- public NotificationProvider() {
- //Default sorting
- setSort("key", SortOrder.ASCENDING);
- comparator = new SortableDataProviderComparator<>(this);
- }
-
- @Override
- public Iterator<NotificationTO> iterator(final long first, final long count) {
- List<NotificationTO> list = notificationRestClient.getAllNotifications();
-
- Collections.sort(list, comparator);
-
- return list.subList((int) first, (int) first + (int) count).iterator();
- }
-
- @Override
- public long size() {
- return notificationRestClient.getAllNotifications().size();
- }
-
- @Override
- public IModel<NotificationTO> model(final NotificationTO notification) {
- return new AbstractReadOnlyModel<NotificationTO>() {
-
- private static final long serialVersionUID = 774694801558497248L;
-
- @Override
- public NotificationTO getObject() {
- return notification;
- }
- };
- }
- }
-
- private class SecurityQuestionProvider extends SortableDataProvider<SecurityQuestionTO, String> {
-
- private static final long serialVersionUID = -1458398823626281188L;
-
- private final SortableDataProviderComparator<SecurityQuestionTO> comparator;
-
- public SecurityQuestionProvider() {
- //Default sorting
- setSort("key", SortOrder.ASCENDING);
- comparator = new SortableDataProviderComparator<>(this);
- }
-
- @Override
- public Iterator<SecurityQuestionTO> iterator(final long first, final long count) {
- List<SecurityQuestionTO> list = securityQuestionRestClient.list();
-
- Collections.sort(list, comparator);
-
- return list.subList((int) first, (int) first + (int) count).iterator();
- }
-
- @Override
- public long size() {
- return securityQuestionRestClient.list().size();
- }
-
- @Override
- public IModel<SecurityQuestionTO> model(final SecurityQuestionTO securityQuestionTO) {
- return new AbstractReadOnlyModel<SecurityQuestionTO>() {
-
- private static final long serialVersionUID = 5079291243768775704L;
-
- @Override
- public SecurityQuestionTO getObject() {
- return securityQuestionTO;
- }
- };
- }
- }
-
- private class LoggerPropertyList extends PropertyListView<LoggerTO> {
-
- private static final long serialVersionUID = 5911412425994616111L;
-
- private final ConsoleLoggerController consoleLoggerController;
-
- public LoggerPropertyList(final ConsoleLoggerController consoleLoggerController, final String id,
- final List<? extends LoggerTO> list) {
-
- super(id, list);
- this.consoleLoggerController = consoleLoggerController;
- }
-
- @Override
- protected void populateItem(final ListItem<LoggerTO> item) {
- item.add(new Label("key"));
-
- DropDownChoice<LoggerLevel> level = new DropDownChoice<>("level");
- level.setModel(new IModel<LoggerLevel>() {
-
- private static final long serialVersionUID = -2350428186089596562L;
-
- @Override
- public LoggerLevel getObject() {
- return item.getModelObject().getLevel();
- }
-
- @Override
- public void setObject(final LoggerLevel object) {
- item.getModelObject().setLevel(object);
- }
-
- @Override
- public void detach() {
- }
- });
- level.setChoices(Arrays.asList(LoggerLevel.values()));
- level.setOutputMarkupId(true);
- level.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- try {
- if (getId().equals("corelogger")) {
- loggerRestClient.setLogLevel(item.getModelObject().getKey(),
- item.getModelObject().getLevel());
- } else {
- consoleLoggerController.setLogLevel(item.getModelObject().getKey(),
- item.getModelObject().getLevel());
- }
-
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException e) {
- info(getString(Constants.OPERATION_ERROR));
- }
-
- feedbackPanel.refresh(target);
- }
- });
-
- MetaDataRoleAuthorizationStrategy.authorize(level, ENABLE, xmlRolesReader.getEntitlement(
- "Configuration", "logSetLevel"));
-
- item.add(level);
- }
- }
-
- private static class ConsoleLoggerController implements Serializable {
-
- private static final long serialVersionUID = -1550459341476431714L;
-
- public List<LoggerTO> getLoggers() {
- LoggerContext ctx = (LoggerContext) LogManager.getContext(false);
-
- List<LoggerTO> result = new ArrayList<>();
- for (LoggerConfig logger : ctx.getConfiguration().getLoggers().values()) {
- final String loggerName = LogManager.ROOT_LOGGER_NAME.equals(logger.getName())
- ? SyncopeConstants.ROOT_LOGGER : logger.getName();
- if (logger.getLevel() != null) {
- LoggerTO loggerTO = new LoggerTO();
- loggerTO.setKey(loggerName);
- loggerTO.setLevel(LoggerLevel.fromLevel(logger.getLevel()));
- result.add(loggerTO);
- }
- }
-
- return result;
- }
-
- public void setLogLevel(final String name, final LoggerLevel level) {
- LoggerContext ctx = (LoggerContext) LogManager.getContext(false);
- LoggerConfig logConf = SyncopeConstants.ROOT_LOGGER.equals(name)
- ? ctx.getConfiguration().getLoggerConfig(LogManager.ROOT_LOGGER_NAME)
- : ctx.getConfiguration().getLoggerConfig(name);
- logConf.setLevel(level.getLevel());
- ctx.updateLoggers();
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.java
deleted file mode 100644
index ebc041d..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.java
+++ /dev/null
@@ -1,103 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.Mode;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPasswordFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.FieldPanel;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.form.PasswordTextField;
-import org.apache.wicket.markup.html.form.StatelessForm;
-import org.apache.wicket.markup.html.form.validation.EqualPasswordInputValidator;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.ResourceModel;
-
-public class ConfirmPasswordResetModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = -8419445804421211904L;
-
- public ConfirmPasswordResetModalPage(final ModalWindow window, final String token) {
- super();
- setOutputMarkupId(true);
-
- final StatelessForm<?> form = new StatelessForm<Object>(FORM);
- form.setOutputMarkupId(true);
-
- final FieldPanel<String> password =
- new AjaxPasswordFieldPanel("password", "password", new Model<String>()).setRequired(true);
- ((PasswordTextField) password.getField()).setResetPassword(true);
- form.add(password);
-
- final FieldPanel<String> confirmPassword =
- new AjaxPasswordFieldPanel("confirmPassword", "confirmPassword", new Model<String>());
- ((PasswordTextField) confirmPassword.getField()).setResetPassword(true);
- form.add(confirmPassword);
-
- form.add(new EqualPasswordInputValidator(password.getField(), confirmPassword.getField()));
-
- final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(SUBMIT, SUBMIT)) {
-
- private static final long serialVersionUID = -4804368561204623354L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- try {
- userSelfRestClient.confirmPasswordReset(token, password.getModelObject());
-
- setResponsePage(new ResultStatusModalPage.Builder(window, new UserTO()).mode(Mode.SELF).build());
- } catch (Exception e) {
- LOG.error("While confirming password reset for {}", token, e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
- form.add(submit);
- form.setDefaultButton(submit);
-
- final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- }
- };
- cancel.setDefaultFormProcessing(false);
- form.add(cancel);
-
- add(form);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/ConnObjectModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/ConnObjectModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/ConnObjectModalPage.java
deleted file mode 100644
index cf1c405..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/ConnObjectModalPage.java
+++ /dev/null
@@ -1,101 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.List;
-import org.apache.syncope.common.lib.to.AttrTO;
-import org.apache.syncope.common.lib.to.ConnObjectTO;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.list.AltListView;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.util.ListModel;
-
-public class ConnObjectModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = -6469290753080058487L;
-
- public ConnObjectModalPage(final ConnObjectTO connObjectTO) {
- super();
-
- final Form<Void> form = new Form<Void>(FORM);
- form.setEnabled(false);
- add(form);
-
- IModel<List<AttrTO>> formProps = new LoadableDetachableModel<List<AttrTO>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<AttrTO> load() {
- List<AttrTO> attrs = connObjectTO.getPlainAttrs();
- Collections.sort(attrs, new Comparator<AttrTO>() {
-
- @Override
- public int compare(final AttrTO attr1, final AttrTO attr2) {
- if (attr1 == null || attr1.getSchema() == null) {
- return -1;
- }
- if (attr2 == null || attr2.getSchema() == null) {
- return 1;
- }
- return attr1.getSchema().compareTo(attr2.getSchema());
- }
- });
-
- return attrs;
- }
- };
- final ListView<AttrTO> propView = new AltListView<AttrTO>("propView", formProps) {
-
- private static final long serialVersionUID = 3109256773218160485L;
-
- @Override
- protected void populateItem(final ListItem<AttrTO> item) {
- final AttrTO prop = item.getModelObject();
-
- Label label = new Label("key", prop.getSchema());
- item.add(label);
-
- Panel field;
- if (prop.getValues().isEmpty()) {
- field = new AjaxTextFieldPanel("value",
- prop.getSchema(), new Model<String>());
- } else if (prop.getValues().size() == 1) {
- field = new AjaxTextFieldPanel("value",
- prop.getSchema(), new Model<String>(prop.getValues().get(0)));
- } else {
- field = new MultiFieldPanel<String>("value", new ListModel<String>(prop.getValues()),
- new AjaxTextFieldPanel("panel", prop.getSchema(), new Model<String>()));
- }
- item.add(field);
- }
- };
- form.add(propView);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/ConnectorModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/ConnectorModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/ConnectorModalPage.java
deleted file mode 100644
index 8095591..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/ConnectorModalPage.java
+++ /dev/null
@@ -1,479 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.EnumSet;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.rest.ConnectorRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.SpinnerFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.list.ConnConfPropertyListView;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.ConnBundleTO;
-import org.apache.syncope.common.lib.to.ConnInstanceTO;
-import org.apache.syncope.common.lib.to.ConnPoolConfTO;
-import org.apache.syncope.common.lib.types.ConnConfPropSchema;
-import org.apache.syncope.common.lib.types.ConnConfProperty;
-import org.apache.syncope.common.lib.types.ConnectorCapability;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormChoiceComponentUpdatingBehavior;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.CheckBoxMultipleChoice;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.apache.wicket.validation.validator.RangeValidator;
-
-/**
- * Modal window with Connector form.
- */
-public class ConnectorModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = -2025535531121434050L;
-
- @SpringBean
- private ConnectorRestClient restClient;
-
- private final Map<String, Map<String, Map<String, ConnBundleTO>>> mapConnBundleTOs;
-
- private final List<ConnectorCapability> selectedCapabilities;
-
- private ConnBundleTO bundleTO;
-
- private List<ConnConfProperty> properties;
-
- private final WebMarkupContainer propertiesContainer;
-
- public ConnectorModalPage(final PageReference pageRef, final ModalWindow window,
- final ConnInstanceTO connInstanceTO) {
-
- super();
-
- this.add(new Label("new", connInstanceTO.getKey() == 0
- ? new ResourceModel("new")
- : new Model<>(StringUtils.EMPTY)));
- this.add(new Label("key", connInstanceTO.getKey() == 0
- ? StringUtils.EMPTY
- : connInstanceTO.getKey()));
-
- // general data setup
- selectedCapabilities = new ArrayList<>(connInstanceTO.getKey() == 0
- ? EnumSet.noneOf(ConnectorCapability.class)
- : connInstanceTO.getCapabilities());
-
- mapConnBundleTOs = new HashMap<>();
- for (ConnBundleTO connBundleTO : restClient.getAllBundles()) {
- // by location
- if (!mapConnBundleTOs.containsKey(connBundleTO.getLocation())) {
- mapConnBundleTOs.put(connBundleTO.getLocation(), new HashMap<String, Map<String, ConnBundleTO>>());
- }
- final Map<String, Map<String, ConnBundleTO>> byLocation = mapConnBundleTOs.get(connBundleTO.getLocation());
-
- // by name
- if (!byLocation.containsKey(connBundleTO.getBundleName())) {
- byLocation.put(connBundleTO.getBundleName(), new HashMap<String, ConnBundleTO>());
- }
- final Map<String, ConnBundleTO> byName = byLocation.get(connBundleTO.getBundleName());
-
- // by version
- if (!byName.containsKey(connBundleTO.getVersion())) {
- byName.put(connBundleTO.getVersion(), connBundleTO);
- }
- }
-
- bundleTO = getSelectedBundleTO(connInstanceTO);
- properties = fillProperties(bundleTO, connInstanceTO);
-
- // form - first tab
- final Form<ConnInstanceTO> connectorForm = new Form<>(FORM);
- connectorForm.setModel(new CompoundPropertyModel<>(connInstanceTO));
- connectorForm.setOutputMarkupId(true);
- add(connectorForm);
-
- propertiesContainer = new WebMarkupContainer("container");
- propertiesContainer.setOutputMarkupId(true);
- connectorForm.add(propertiesContainer);
-
- final Form<ConnInstanceTO> connectorPropForm = new Form<>("connectorPropForm");
- connectorPropForm.setModel(new CompoundPropertyModel<>(connInstanceTO));
- connectorPropForm.setOutputMarkupId(true);
- propertiesContainer.add(connectorPropForm);
-
- final AjaxTextFieldPanel displayName = new AjaxTextFieldPanel(
- "displayName", "display name", new PropertyModel<String>(connInstanceTO, "displayName"));
- displayName.setOutputMarkupId(true);
- displayName.addRequiredLabel();
- connectorForm.add(displayName);
-
- final AjaxDropDownChoicePanel<String> location =
- new AjaxDropDownChoicePanel<>("location", "location",
- new Model<>(bundleTO == null ? null : bundleTO.getLocation()));
- ((DropDownChoice<String>) location.getField()).setNullValid(true);
- location.setStyleSheet("long_dynamicsize");
- location.setChoices(new ArrayList<>(mapConnBundleTOs.keySet()));
- location.setRequired(true);
- location.addRequiredLabel();
- location.setOutputMarkupId(true);
- location.setEnabled(connInstanceTO.getKey() == 0);
- location.getField().setOutputMarkupId(true);
- connectorForm.add(location);
-
- final AjaxDropDownChoicePanel<String> connectorName =
- new AjaxDropDownChoicePanel<>("connectorName", "connectorName",
- new Model<>(bundleTO == null ? null : bundleTO.getBundleName()));
- ((DropDownChoice<String>) connectorName.getField()).setNullValid(true);
- connectorName.setStyleSheet("long_dynamicsize");
- connectorName.setChoices(bundleTO == null
- ? new ArrayList<String>()
- : new ArrayList<>(mapConnBundleTOs.get(connInstanceTO.getLocation()).keySet()));
- connectorName.setRequired(true);
- connectorName.addRequiredLabel();
- connectorName.setEnabled(connInstanceTO.getLocation() != null);
- connectorName.setOutputMarkupId(true);
- connectorName.setEnabled(connInstanceTO.getKey() == 0);
- connectorName.getField().setOutputMarkupId(true);
- connectorForm.add(connectorName);
-
- final AjaxDropDownChoicePanel<String> version =
- new AjaxDropDownChoicePanel<>("version", "version",
- new Model<>(bundleTO == null ? null : bundleTO.getVersion()));
- version.setStyleSheet("long_dynamicsize");
- version.setChoices(bundleTO == null
- ? new ArrayList<String>()
- : new ArrayList<>(mapConnBundleTOs.get(connInstanceTO.getLocation()).
- get(connInstanceTO.getBundleName()).keySet()));
- version.setRequired(true);
- version.addRequiredLabel();
- version.setEnabled(connInstanceTO.getBundleName() != null);
- version.setOutputMarkupId(true);
- version.addRequiredLabel();
- version.getField().setOutputMarkupId(true);
- connectorForm.add(version);
-
- final SpinnerFieldPanel<Integer> connRequestTimeout =
- new SpinnerFieldPanel<>("connRequestTimeout", "connRequestTimeout", Integer.class,
- new PropertyModel<Integer>(connInstanceTO, "connRequestTimeout"), 0, null);
- connRequestTimeout.getField().add(new RangeValidator<>(0, Integer.MAX_VALUE));
- connectorForm.add(connRequestTimeout);
-
- if (connInstanceTO.getPoolConf() == null) {
- connInstanceTO.setPoolConf(new ConnPoolConfTO());
- }
- final SpinnerFieldPanel<Integer> poolMaxObjects =
- new SpinnerFieldPanel<>("poolMaxObjects", "poolMaxObjects", Integer.class,
- new PropertyModel<Integer>(connInstanceTO.getPoolConf(), "maxObjects"), 0, null);
- poolMaxObjects.getField().add(new RangeValidator<>(0, Integer.MAX_VALUE));
- connectorForm.add(poolMaxObjects);
- final SpinnerFieldPanel<Integer> poolMinIdle =
- new SpinnerFieldPanel<>("poolMinIdle", "poolMinIdle", Integer.class,
- new PropertyModel<Integer>(connInstanceTO.getPoolConf(), "minIdle"), 0, null);
- poolMinIdle.getField().add(new RangeValidator<>(0, Integer.MAX_VALUE));
- connectorForm.add(poolMinIdle);
- final SpinnerFieldPanel<Integer> poolMaxIdle =
- new SpinnerFieldPanel<>("poolMaxIdle", "poolMaxIdle", Integer.class,
- new PropertyModel<Integer>(connInstanceTO.getPoolConf(), "maxIdle"), 0, null);
- poolMaxIdle.getField().add(new RangeValidator<>(0, Integer.MAX_VALUE));
- connectorForm.add(poolMaxIdle);
- final SpinnerFieldPanel<Long> poolMaxWait =
- new SpinnerFieldPanel<>("poolMaxWait", "poolMaxWait", Long.class,
- new PropertyModel<Long>(connInstanceTO.getPoolConf(), "maxWait"), 0L, null);
- poolMaxWait.getField().add(new RangeValidator<>(0L, Long.MAX_VALUE));
- connectorForm.add(poolMaxWait);
- final SpinnerFieldPanel<Long> poolMinEvictableIdleTime =
- new SpinnerFieldPanel<>("poolMinEvictableIdleTime", "poolMinEvictableIdleTime", Long.class,
- new PropertyModel<Long>(connInstanceTO.getPoolConf(), "minEvictableIdleTimeMillis"),
- 0L, null);
- poolMinEvictableIdleTime.getField().add(new RangeValidator<>(0L, Long.MAX_VALUE));
- connectorForm.add(poolMinEvictableIdleTime);
-
- // form - first tab - onchange()
- location.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- ((DropDownChoice<String>) location.getField()).setNullValid(false);
- connInstanceTO.setLocation(location.getModelObject());
- target.add(location);
-
- connectorName.setChoices(new ArrayList<>(
- mapConnBundleTOs.get(location.getModelObject()).keySet()));
- connectorName.setEnabled(true);
- connectorName.getField().setModelValue(null);
- target.add(connectorName);
-
- version.setChoices(new ArrayList<String>());
- version.getField().setModelValue(null);
- version.setEnabled(false);
- target.add(version);
-
- properties.clear();
- target.add(propertiesContainer);
- }
- });
- connectorName.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- ((DropDownChoice<String>) connectorName.getField()).setNullValid(false);
- connInstanceTO.setBundleName(connectorName.getModelObject());
- target.add(connectorName);
-
- List<String> versions = new ArrayList<>(
- mapConnBundleTOs.get(location.getModelObject()).get(connectorName.getModelObject()).keySet());
- version.setChoices(versions);
- version.setEnabled(true);
- if (versions.size() == 1) {
- selectVersion(target, connInstanceTO, version, versions.get(0));
- version.getField().setModelObject(versions.get(0));
- } else {
- version.getField().setModelValue(null);
- properties.clear();
- target.add(propertiesContainer);
- }
- target.add(version);
- }
- });
- version.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- selectVersion(target, connInstanceTO, version, version.getModelObject());
- }
- });
-
- // form - second tab (properties)
- final ListView<ConnConfProperty> connPropView = new ConnConfPropertyListView("connectorProperties",
- new PropertyModel<List<ConnConfProperty>>(this, "properties"),
- true, connInstanceTO.getConfiguration());
- connPropView.setOutputMarkupId(true);
- connectorPropForm.add(connPropView);
-
- final AjaxButton check = new IndicatingAjaxButton("check", new ResourceModel("check")) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- final ConnInstanceTO conn = (ConnInstanceTO) form.getModelObject();
-
- // ensure that connector bundle information is in sync
- conn.setBundleName(bundleTO.getBundleName());
- conn.setVersion(bundleTO.getVersion());
- conn.setConnectorName(bundleTO.getConnectorName());
-
- if (restClient.check(conn)) {
- info(getString("success_connection"));
- } else {
- error(getString("error_connection"));
- }
-
- feedbackPanel.refresh(target);
- }
- };
- connectorPropForm.add(check);
-
- // form - third tab (capabilities)
- final IModel<List<ConnectorCapability>> capabilities =
- new LoadableDetachableModel<List<ConnectorCapability>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<ConnectorCapability> load() {
- return Arrays.asList(ConnectorCapability.values());
- }
- };
- CheckBoxMultipleChoice<ConnectorCapability> capabilitiesPalette =
- new CheckBoxMultipleChoice<>("capabilitiesPalette",
- new PropertyModel<List<ConnectorCapability>>(this, "selectedCapabilities"), capabilities);
-
- capabilitiesPalette.add(new AjaxFormChoiceComponentUpdatingBehavior() {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(AjaxRequestTarget target) {
- }
- });
-
- connectorForm.add(capabilitiesPalette);
-
- // form - submit / cancel buttons
- final AjaxButton submit = new IndicatingAjaxButton(APPLY, new Model<>(getString(SUBMIT))) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- final ConnInstanceTO conn = (ConnInstanceTO) form.getModelObject();
-
- conn.setConnectorName(bundleTO.getConnectorName());
- conn.setBundleName(bundleTO.getBundleName());
- conn.setVersion(bundleTO.getVersion());
- conn.getConfiguration().clear();
- conn.getConfiguration().addAll(connPropView.getModelObject());
-
- // Set the model object's capabilities to capabilitiesPalette's converted Set
- conn.getCapabilities().clear();
- conn.getCapabilities().addAll(selectedCapabilities.isEmpty()
- ? EnumSet.noneOf(ConnectorCapability.class)
- : EnumSet.copyOf(selectedCapabilities));
-
- // Reset pool configuration if all fields are null
- if (conn.getPoolConf() != null
- && conn.getPoolConf().getMaxIdle() == null
- && conn.getPoolConf().getMaxObjects() == null
- && conn.getPoolConf().getMaxWait() == null
- && conn.getPoolConf().getMinEvictableIdleTimeMillis() == null
- && conn.getPoolConf().getMinIdle() == null) {
-
- conn.setPoolConf(null);
- }
-
- try {
- if (connInstanceTO.getKey() == 0) {
- restClient.create(conn);
- } else {
- restClient.update(conn);
- }
-
- ((Resources) pageRef.getPage()).setModalResult(true);
- window.close(target);
- } catch (SyncopeClientException e) {
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- ((Resources) pageRef.getPage()).setModalResult(false);
- LOG.error("While creating or updating connector {}", conn, e);
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
- String roles = connInstanceTO.getKey() == 0
- ? xmlRolesReader.getEntitlement("Connectors", "create")
- : xmlRolesReader.getEntitlement("Connectors", "update");
- MetaDataRoleAuthorizationStrategy.authorize(submit, ENABLE, roles);
- connectorForm.add(submit);
-
- final IndicatingAjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
- };
- cancel.setDefaultFormProcessing(false);
- connectorForm.add(cancel);
- }
-
- private ConnBundleTO getSelectedBundleTO(final ConnInstanceTO connInstanceTO) {
- ConnBundleTO result = null;
- if (connInstanceTO != null
- && StringUtils.isNotBlank(connInstanceTO.getLocation())
- && StringUtils.isNotBlank(connInstanceTO.getBundleName())
- && StringUtils.isNotBlank(connInstanceTO.getVersion())
- && mapConnBundleTOs.containsKey(connInstanceTO.getLocation())) {
-
- Map<String, Map<String, ConnBundleTO>> byLocation = mapConnBundleTOs.get(connInstanceTO.getLocation());
- if (byLocation.containsKey(connInstanceTO.getBundleName())) {
- Map<String, ConnBundleTO> byName = byLocation.get(connInstanceTO.getBundleName());
- if (byName.containsKey(connInstanceTO.getVersion())) {
- result = byName.get(connInstanceTO.getVersion());
- }
- }
- }
- return result;
- }
-
- private List<ConnConfProperty> fillProperties(final ConnBundleTO bundleTO, final ConnInstanceTO connInstanceTO) {
- final List<ConnConfProperty> props = new ArrayList<>();
-
- if (bundleTO != null) {
- for (ConnConfPropSchema key : bundleTO.getProperties()) {
- final ConnConfProperty property = new ConnConfProperty();
- property.setSchema(key);
- if (connInstanceTO.getKey() != 0
- && connInstanceTO.getConfigurationMap().containsKey(key.getName())
- && connInstanceTO.getConfigurationMap().get(key.getName()).getValues() != null) {
-
- property.getValues().addAll(connInstanceTO.getConfigurationMap().get(key.getName()).getValues());
- property.setOverridable(connInstanceTO.getConfigurationMap().get(key.getName()).isOverridable());
- }
-
- if (property.getValues().isEmpty() && !key.getDefaultValues().isEmpty()) {
- property.getValues().addAll(key.getDefaultValues());
- }
-
- props.add(property);
- }
- }
-
- // re-order properties (implements Comparable)
- Collections.sort(props);
- return props;
- }
-
- private void selectVersion(final AjaxRequestTarget target, final ConnInstanceTO connInstanceTO,
- final AjaxDropDownChoicePanel<String> version, final String versionValue) {
-
- connInstanceTO.setVersion(versionValue);
- target.add(version);
-
- bundleTO = getSelectedBundleTO(connInstanceTO);
- properties = fillProperties(bundleTO, connInstanceTO);
- target.add(propertiesContainer);
- }
-
- public List<ConnConfProperty> getProperties() {
- return properties;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/DerSchemaModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/DerSchemaModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/DerSchemaModalPage.java
deleted file mode 100644
index 1abe744..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/DerSchemaModalPage.java
+++ /dev/null
@@ -1,140 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.JexlHelpUtils;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.DerSchemaTO;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-
-/**
- * Modal window with Schema form.
- */
-public class DerSchemaModalPage extends AbstractSchemaModalPage<DerSchemaTO> {
-
- private static final long serialVersionUID = 6668789770131753386L;
-
- public DerSchemaModalPage(final AttributableType kind) {
- super(kind);
- }
-
- @Override
- public void setSchemaModalPage(final PageReference pageRef, final ModalWindow window,
- DerSchemaTO schema, final boolean createFlag) {
-
- if (schema == null) {
- schema = new DerSchemaTO();
- }
-
- final Form<DerSchemaTO> schemaForm = new Form<>(FORM);
-
- schemaForm.setModel(new CompoundPropertyModel<>(schema));
-
- final AjaxTextFieldPanel name =
- new AjaxTextFieldPanel("key", getString("key"), new PropertyModel<String>(schema, "key"));
- name.addRequiredLabel();
-
- final AjaxTextFieldPanel expression = new AjaxTextFieldPanel("expression", getString("expression"),
- new PropertyModel<String>(schema, "expression"));
- expression.addRequiredLabel();
-
- final WebMarkupContainer jexlHelp = JexlHelpUtils.getJexlHelpWebContainer("jexlHelp");
-
- final AjaxLink<Void> questionMarkJexlHelp = JexlHelpUtils.getAjaxLink(jexlHelp, "questionMarkJexlHelp");
- schemaForm.add(questionMarkJexlHelp);
- questionMarkJexlHelp.add(jexlHelp);
-
- name.setEnabled(createFlag);
-
- final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(SUBMIT)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form form) {
- DerSchemaTO schemaTO = (DerSchemaTO) form.getDefaultModelObject();
-
- try {
- if (createFlag) {
- schemaRestClient.createDerSchema(kind, schemaTO);
- } else {
- schemaRestClient.updateDerSchema(kind, schemaTO);
- }
-
- if (pageRef.getPage() instanceof BasePage) {
- ((BasePage) pageRef.getPage()).setModalResult(true);
- }
-
- window.close(target);
- } catch (SyncopeClientException e) {
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
-
- final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
- };
-
- cancel.setDefaultFormProcessing(
- false);
-
- String allowedRoles = createFlag
- ? xmlRolesReader.getEntitlement("Schema", "create")
- : xmlRolesReader.getEntitlement("Schema", "update");
-
- MetaDataRoleAuthorizationStrategy.authorize(submit, ENABLE, allowedRoles);
-
- schemaForm.add(name);
-
- schemaForm.add(expression);
-
- schemaForm.add(submit);
-
- schemaForm.add(cancel);
-
- add(schemaForm);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.java
deleted file mode 100644
index 6f89ec3..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.java
+++ /dev/null
@@ -1,273 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.PreferenceManager;
-import org.apache.syncope.common.lib.search.SearchableFields;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Check;
-import org.apache.wicket.markup.html.form.CheckGroup;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.markup.html.panel.Fragment;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-/**
- * Modal window with Display attributes form.
- */
-@SuppressWarnings({ "unchecked", "rawtypes" })
-public class DisplayAttributesModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = -4274117450918385110L;
-
- /**
- * Max allowed selections.
- */
- private static final int MAX_SELECTIONS = 9;
-
- public static final String[] DEFAULT_SELECTION = { "key", "username", "status" };
-
- @SpringBean
- private PreferenceManager prefMan;
-
- private final List<String> selectedDetails;
-
- private final List<String> selectedPlainSchemas;
-
- private final List<String> selectedDerSchemas;
-
- private final List<String> selectedVirSchemas;
-
- public DisplayAttributesModalPage(final PageReference pageRef, final ModalWindow window,
- final List<String> schemaNames, final List<String> dSchemaNames, final List<String> vSchemaNames) {
-
- super();
-
- final IModel<List<String>> fnames = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- return SearchableFields.get(UserTO.class);
- }
- };
-
- final IModel<List<String>> names = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- return schemaNames;
- }
- };
-
- final IModel<List<String>> dsnames = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- return dSchemaNames;
- }
- };
-
- final IModel<List<String>> vsnames = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- return vSchemaNames;
- }
- };
-
- final Form form = new Form(FORM);
- form.setModel(new CompoundPropertyModel(this));
-
- selectedDetails = prefMan.getList(getRequest(), Constants.PREF_USERS_DETAILS_VIEW);
-
- selectedPlainSchemas = prefMan.getList(getRequest(), Constants.PREF_USERS_ATTRIBUTES_VIEW);
-
- selectedDerSchemas = prefMan.getList(getRequest(), Constants.PREF_USERS_DERIVED_ATTRIBUTES_VIEW);
-
- selectedVirSchemas = prefMan.getList(getRequest(), Constants.PREF_USERS_VIRTUAL_ATTRIBUTES_VIEW);
-
- final CheckGroup dgroup = new CheckGroup("dCheckGroup", new PropertyModel(this, "selectedDetails"));
- form.add(dgroup);
-
- final ListView<String> details = new ListView<String>("details", fnames) {
-
- private static final long serialVersionUID = 9101744072914090143L;
-
- @Override
- protected void populateItem(final ListItem<String> item) {
- item.add(new Check("dcheck", item.getModel()));
- item.add(new Label("dname", new ResourceModel(item.getModelObject(), item.getModelObject())));
- }
- };
- dgroup.add(details);
-
- if (names.getObject() == null || names.getObject().isEmpty()) {
- final Fragment fragment = new Fragment("plainSchemas", "emptyFragment", form);
- form.add(fragment);
-
- selectedPlainSchemas.clear();
- } else {
- final Fragment fragment = new Fragment("plainSchemas", "sfragment", form);
- form.add(fragment);
-
- final CheckGroup sgroup = new CheckGroup("psCheckGroup", new PropertyModel(this, "selectedPlainSchemas"));
- fragment.add(sgroup);
-
- final ListView<String> schemas = new ListView<String>("plainSchemas", names) {
-
- private static final long serialVersionUID = 9101744072914090143L;
-
- @Override
- protected void populateItem(final ListItem<String> item) {
- item.add(new Check("scheck", item.getModel()));
- item.add(new Label("sname", new ResourceModel(item.getModelObject(), item.getModelObject())));
- }
- };
- sgroup.add(schemas);
- }
-
- if (dsnames.getObject() == null || dsnames.getObject().isEmpty()) {
- final Fragment fragment = new Fragment("dschemas", "emptyFragment", form);
- form.add(fragment);
-
- selectedDerSchemas.clear();
- } else {
- final Fragment fragment = new Fragment("dschemas", "dsfragment", form);
- form.add(fragment);
-
- final CheckGroup dsgroup = new CheckGroup("dsCheckGroup", new PropertyModel(this, "selectedDerSchemas"));
- fragment.add(dsgroup);
-
- final ListView<String> derSchemas = new ListView<String>("derSchemas", dsnames) {
-
- private static final long serialVersionUID = 9101744072914090143L;
-
- @Override
- protected void populateItem(ListItem<String> item) {
- item.add(new Check("dscheck", item.getModel()));
- item.add(new Label("dsname", new ResourceModel(item.getModelObject(), item.getModelObject())));
- }
- };
- dsgroup.add(derSchemas);
- }
-
- if (vsnames.getObject() == null || vsnames.getObject().isEmpty()) {
- final Fragment fragment = new Fragment("vschemas", "emptyFragment", form);
- form.add(fragment);
-
- selectedVirSchemas.clear();
- } else {
- final Fragment fragment = new Fragment("vschemas", "vsfragment", form);
- form.add(fragment);
-
- final CheckGroup vsgroup = new CheckGroup("vsCheckGroup", new PropertyModel(this, "selectedVirSchemas"));
- fragment.add(vsgroup);
-
- final ListView<String> virSchemas = new ListView<String>("virSchemas", vsnames) {
-
- private static final long serialVersionUID = 9101744072914090143L;
-
- @Override
- protected void populateItem(ListItem<String> item) {
- item.add(new Check("vscheck", item.getModel()));
- item.add(new Label("vsname", new ResourceModel(item.getModelObject(), item.getModelObject())));
- }
- };
- vsgroup.add(virSchemas);
- }
-
- final AjaxButton submit = new IndicatingAjaxButton(SUBMIT, new ResourceModel(SUBMIT)) {
-
- private static final long serialVersionUID = -4804368561204623354L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- if (selectedDetails.size() + selectedPlainSchemas.size() + selectedVirSchemas.size() + selectedDerSchemas.
- size()
- > MAX_SELECTIONS) {
-
- error(getString("tooManySelections"));
- onError(target, form);
- } else {
- final Map<String, List<String>> prefs = new HashMap<String, List<String>>();
-
- prefs.put(Constants.PREF_USERS_DETAILS_VIEW, selectedDetails);
-
- prefs.put(Constants.PREF_USERS_ATTRIBUTES_VIEW, selectedPlainSchemas);
-
- prefs.put(Constants.PREF_USERS_DERIVED_ATTRIBUTES_VIEW, selectedDerSchemas);
-
- prefs.put(Constants.PREF_USERS_VIRTUAL_ATTRIBUTES_VIEW, selectedVirSchemas);
-
- prefMan.setList(getRequest(), getResponse(), prefs);
-
- ((BasePage) pageRef.getPage()).setModalResult(true);
-
- window.close(target);
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
-
- form.add(submit);
-
- final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
- };
-
- cancel.setDefaultFormProcessing(false);
- form.add(cancel);
-
- add(form);
- }
-}
[07/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/fieldstyle.css
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/fieldstyle.css b/client/old_console/src/main/resources/META-INF/resources/css/fieldstyle.css
new file mode 100644
index 0000000..23ef109
--- /dev/null
+++ b/client/old_console/src/main/resources/META-INF/resources/css/fieldstyle.css
@@ -0,0 +1,191 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+.drop_button{
+ vertical-align: middle;
+}
+
+.add_button{
+ vertical-align: middle;
+ margin-left: 6px;
+}
+
+.date_size{
+ width: 90px;
+}
+
+.long_dynamicsize{
+ width: 80%;
+}
+
+.medium_dynamicsize{
+ width: 45%;
+}
+
+.short_dynamicsize{
+ width: 35%;
+}
+
+.long_fixedsize{
+ width: 500px;
+}
+
+.medium_fixedsize{
+ width: 300px;
+}
+
+.short_fixedsize{
+ width: 150px;
+}
+
+.veryshort_fixedsize{
+ width: 70px;
+}
+
+.all_dynamicsize{
+ width: 100%;
+}
+
+div#formtable {
+ display: table;
+ width: 100%;
+}
+
+div#formtable > span:first-of-type {
+ display: table-row-group;
+ width: 100%;
+}
+
+div.tablerow {
+ display: inline-table;
+ padding: 5px;
+ width: 99%;
+}
+
+div.tablerow.connectorProp {
+ height:22px;
+ vertical-align: middle;
+ font-size: 12px;
+}
+
+div.tablecolumn_connPropAttr {
+ display: table-cell;
+ vertical-align: middle;
+}
+
+div.tablerow2 {
+ display: inline-table;
+ padding: 5px 0px 5px 0px;
+ width: 99%;
+}
+
+div.alt {
+ background: #eff3ea;
+}
+
+div.tablecolumn_label{
+ display: table-cell;
+ font-size: 12px;
+ vertical-align: middle;
+ font-family: Verdana,Tahoma,sans-serif;
+ width: 30%;
+}
+
+div.tablecolumn_field{
+ display: table-cell;
+ vertical-align: middle;
+ font-family: Verdana,Tahoma,sans-serif;
+ width: 70%;
+}
+
+div.tablecolumn_check{
+ display: table-cell;
+ margin-right: 5px;
+ margin-left: 2px;
+ vertical-align: middle;
+}
+
+div.tablecolumn2_label{
+ display: table-cell;
+ font-size: 12px;
+ vertical-align: middle;
+ font-family: Verdana,Tahoma,sans-serif;
+ padding-left: 5px;
+ width: 15%;
+}
+
+div.tablecolumn2_field{
+ display: table-cell;
+ vertical-align: middle;
+ font-family: Verdana,Tahoma,sans-serif;
+ width: 35%;
+}
+
+.ui-tabs .ui-tabs-panel {
+ background: none repeat scroll 0 0 #FFFFFF;
+ border-width: 0;
+ display: block;
+ overflow: auto;
+ padding: 1em 1.4em;
+}
+
+.ui-widget input, .ui-widget select, .ui-widget textarea, .ui-widget button {
+ font-family: Verdana,Arial,sans-serif;
+ font-size: 12px;
+ padding: 2px 4px;
+}
+
+.ui-widget-header {
+ border: 1px solid #aaaaaa
+ /*{borderColorHeader}*/;
+ background: #cccccc
+ /*{bgColorHeader}*/
+ url(images/ui-bg_highlight-soft_75_cccccc_1x100.png)
+ /*{bgImgUrlHeader}*/
+ 50%/*{bgHeaderXPos}*/
+ 50%/*{bgHeaderYPos}*/
+ repeat-x/*{bgHeaderRepeat}*/;
+ color: #222222/*{fcHeader}*/;
+ font-weight: bold;
+ padding: 7px 15px;
+}
+
+.ui-button {
+ display: inline-block;
+ position: relative;
+ margin-right: .1em;
+ cursor: pointer;
+ text-align: center;
+ zoom: 1;
+ overflow: visible;
+ padding: 7px 15px;
+}
+
+.ui-spinner-button {
+ cursor: default;
+ display: block;
+ font-size: 0.5em;
+ height: 50%;
+ margin: 0;
+ overflow: hidden;
+ padding: 0;
+ position: absolute;
+ right: 0;
+ text-align: center;
+ width: 16px;
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_diagonals-thick_20_666666_40x40.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_diagonals-thick_20_666666_40x40.png b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_diagonals-thick_20_666666_40x40.png
new file mode 100644
index 0000000..64ece57
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_diagonals-thick_20_666666_40x40.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_flat_0_aaaaaa_40x100.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_flat_0_aaaaaa_40x100.png b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_flat_0_aaaaaa_40x100.png
new file mode 100644
index 0000000..fc9ef06
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_flat_0_aaaaaa_40x100.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_flat_0_aaaaaa_40x100_greennotused.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_flat_0_aaaaaa_40x100_greennotused.png b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_flat_0_aaaaaa_40x100_greennotused.png
new file mode 100644
index 0000000..b3d1999
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_flat_0_aaaaaa_40x100_greennotused.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_55_fbf9ee_1x400.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_55_fbf9ee_1x400.png b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_55_fbf9ee_1x400.png
new file mode 100644
index 0000000..ad3d634
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_55_fbf9ee_1x400.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_65_ffffff_1x400.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_65_ffffff_1x400.png b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_65_ffffff_1x400.png
new file mode 100644
index 0000000..42ccba2
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_65_ffffff_1x400.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_75_dadada_1x400.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_75_dadada_1x400.png b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_75_dadada_1x400.png
new file mode 100644
index 0000000..5a46b47
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_75_dadada_1x400.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_75_e6e6e6_1x400.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_75_e6e6e6_1x400.png b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_75_e6e6e6_1x400.png
new file mode 100644
index 0000000..86c2baa
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_75_e6e6e6_1x400.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_95_fef1ec_1x400.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_95_fef1ec_1x400.png b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_95_fef1ec_1x400.png
new file mode 100644
index 0000000..4443fdc
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_95_fef1ec_1x400.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100.png b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100.png
new file mode 100644
index 0000000..5749fc4
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100_greynotused.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100_greynotused.png b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100_greynotused.png
new file mode 100644
index 0000000..7c9fa6c
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100_greynotused.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100_red.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100_red.png b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100_red.png
new file mode 100644
index 0000000..4632529
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100_red.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_222222_256x240.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_222222_256x240.png b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_222222_256x240.png
new file mode 100644
index 0000000..ee039dc
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_222222_256x240.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_2e83ff_256x240.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_2e83ff_256x240.png b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_2e83ff_256x240.png
new file mode 100644
index 0000000..45e8928
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_2e83ff_256x240.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_454545_256x240.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_454545_256x240.png b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_454545_256x240.png
new file mode 100644
index 0000000..7ec70d1
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_454545_256x240.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_888888_256x240.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_888888_256x240.png b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_888888_256x240.png
new file mode 100644
index 0000000..5ba708c
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_888888_256x240.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_cd0a0a_256x240.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_cd0a0a_256x240.png b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_cd0a0a_256x240.png
new file mode 100644
index 0000000..7930a55
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/css/images/ui-icons_cd0a0a_256x240.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/css/style.css
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/css/style.css b/client/old_console/src/main/resources/META-INF/resources/css/style.css
new file mode 100644
index 0000000..0978141
--- /dev/null
+++ b/client/old_console/src/main/resources/META-INF/resources/css/style.css
@@ -0,0 +1,550 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+body {
+ margin: 0px;
+ padding: 0px;
+ font-family: Verdana, Tahoma, sans-serif;
+ color: #333;
+ font-size: 62.5%;
+}
+
+/* id */
+#tabs {
+ margin: 0px 5px;
+ margin-top: 5px;
+}
+#grouptabs {
+ margin: 0px 5px;
+ margin-top: 5px;
+}
+
+#tabs div {
+ /*background-color: #FFF;*/
+}
+
+#logo {
+ margin-top: 10px;
+ margin-bottom: 6px;
+}
+
+#splash {
+ background: url(../img/sf_testa.png) top repeat-x #B9CFB3;
+ width: 400px;
+ margin-left: auto;
+ margin-right: auto;
+ margin-top: 100px;
+ border: 1px solid #463;
+}
+
+#splash a {
+ color: #463;
+ text-decoration: none;
+ font-size: 14px;
+}
+
+a img {
+ border: none;
+}
+
+#splash h2 {
+ color: #FFF;
+ margin: 0px;
+ margin-top: 8px;
+ margin-bottom: 20px;
+ font-size: 14px;
+ text-align: center;
+ font-weight: normal;
+}
+
+#splash form {
+ margin: 6px auto;
+ width: 300px;
+ text-align: center;
+}
+
+#splash form label {
+ margin-right: 5px;
+ display: block;
+}
+
+#splash form label.password {
+}
+
+#splash form input {
+ margin-bottom: 15px;
+}
+
+#splash p {
+ margin: 6px 16px;
+ border-top: 1px solid #463;
+ text-align: center;
+ padding-top: 8px;
+}
+
+#splash ul {
+ height: 320px;
+ margin-left: 37px;
+ padding-left: 28px;
+ margin-top: 25px;
+}
+
+#splash ul li {
+ float: left;
+ width: 90px;
+ text-align: center;
+ list-style: none;
+ margin: 0px;
+}
+
+input[disabled] {
+ background-color: #ddd;
+ background-image: none;
+}
+
+select[disabled] {
+ background-color: #ddd;
+ background-image: none;
+}
+
+#loginFeedbackDiv {
+ width: 100%;
+}
+
+#loginFeedbackDiv ul {
+ list-style:none outside none;
+ margin:0;
+ text-align:center;
+ width: 100%;
+ height: 30px;
+ margin-left: 0px;
+ padding-left: 0px;
+}
+
+#loginFeedbackDiv ul li{
+ border:0 none;
+ padding-left: 20px;
+ padding: 1%;
+ padding-top: 2%;
+ list-style:none outside none;
+ margin:0;
+ text-align:center;
+ width: 100%;
+}
+
+#feedbackDiv {
+ height: 20px;
+ margin: 0px;
+ padding: 0px;
+}
+
+#feedbackDiv ul{
+ height: 20px !important;
+ margin: 0px;
+ padding: 0px;
+}
+
+#feedbackDiv li{
+ list-style:none outside none;
+ margin:0;
+ text-align:center;
+ width: 100%;
+}
+#feedbackDiv ul li{
+ list-style:none outside none;
+ margin:0;
+ text-align:center;
+ width: 100%;
+ color: red;
+}
+
+.feedbackPanel {
+ padding-left:20pt;
+ margin-right:20pt;
+}
+
+#navigationPane {
+ background: url(../img/sf_testa.png) top repeat-x #FFF;
+}
+
+#navigationPane a img {
+ border: none;
+}
+
+#navigationPane {
+ height: 103px;
+}
+
+#navigationPane a {
+ color: #FFF;
+ text-decoration: none;
+}
+
+#navigationPane a:hover {
+ color: #CCC;
+}
+
+#navigationPane ul {
+ clear: both;
+ padding: 0px;
+ margin: 0px;
+ margin-left: 280px;
+}
+
+#navigationPane ul li {
+ float: left;
+ width: 90px;
+ text-align: center;
+ margin: 0px;
+ color: #FFF;
+ font-size: 13px;
+ list-style: none;
+ padding: 1px;
+}
+
+#navigationPane span {
+ font-size: 13px;
+}
+
+/* MODAL-FORM */
+div#dialog-form label, div#dialog-form input { display:block; }
+div#dialog-form span.radio label, div#dialog-form span.radio input { margin-top: 4px; margin-bottom: 12px; display:inline; }
+/*div#dialog-form span.checkbox label, div#dialog-form span.checkbox input { margin-top: 4px; margin-bottom: 12px; display:inline; }*/
+div#dialog-form input.text { margin-bottom:12px; width: 95%; padding: .4em; }
+div#dialog-form select.text { margin-bottom:12px; width: auto; padding: .4em; }
+div#dialog-form fieldset { padding:0; border:0; margin-top:25px; }
+div#users-contain { width: 570px; margin-bottom: 20px;}/*width: 350px*/
+div#users-contain table { margin: 1em 0; border-collapse: collapse; width: 100%; }
+div#users-contain table td, div#users-contain table th { border: 1px solid #eee; padding: .6em 10px; }
+div#executions { margin-bottom: 0px;}/*width: 350px*/
+div#executions table { margin: 1em 0; border-collapse: collapse; width: 100%; }
+div#executions table td, div#executions table th { border: 1px solid #eee; padding: .3em 10px; }
+.ui-dialog .ui-state-error { padding: .3em; }
+.validateTips { border: 1px solid transparent; padding: 0.3em; }
+
+/* classi */
+#navigationPane .schema {
+ color: #99C;
+}
+
+#navigationPane a img:hover {
+ opacity:0.5;
+ -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(opacity=50)";
+ filter:alpha(opacity=50)
+}
+
+#splash a img:hover {
+ opacity:0.5;
+ -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(opacity=50)";
+ filter:alpha(opacity=50)
+}
+
+#navigationPane .users {
+ color: #9C0;
+}
+
+#navigationPane .groups {
+ color: #F90;
+}
+
+#navigationPane .resources {
+ color: #09F;
+}
+
+#navigationPane .tasks {
+ color: #FD0;
+}
+
+#navigationPane .todo {
+ color: #F3C98E;
+}
+
+#navigationPane .connectors {
+ color: #09F;
+}
+
+#navigationPane .reports {
+ color: #F66;
+}
+
+#navigationPane .configuration {
+ color: #CCC;
+}
+
+.onerowlabel {
+ float: left;
+}
+
+.onerowcheckbox {
+ margin-left: 10em;
+}
+
+div#attributes-view label {
+ display: block;
+ clear: none;
+ width: 300px;
+ margin-left: 20px;
+}
+
+div#attributes-view input {
+ display: block;
+ float: left;
+ clear: left;
+ height: 12px;
+ padding: 0;
+ margin: 0;
+}
+
+.selectedRow {
+ background-color: #eef1f1; /* alternative: LemonChiffon */
+}
+
+/* WICKET DATATABLE HEADERS */
+.headers {
+ border: 1px solid #aaaaaa;
+ background: #cccccc url(images/ui-bg_highlight-soft_75_cccccc_1x100.png)
+ 50% 50% repeat-x;
+}
+
+em {
+ font-size: inherit;
+ color: gray;
+}
+
+em img {
+ opacity:0.4;
+ filter:alpha(opacity=40);
+}
+
+th.action{
+ width: 140px;
+}
+
+td.action{
+ text-align: center;
+}
+
+.navigatorLabel {
+ float: left;
+}
+
+.navigator {
+ text-align: right;
+}
+
+.group-tree {
+ width: 30%;
+ display: block;
+ float: left;
+}
+
+.groupTable {
+ line-height: 1.5em;
+}
+
+.tree-folder-other {
+ padding-top: 2px;
+ display: block;
+ height: 18px;
+}
+
+.tree-folder-open {
+ display: block;
+ height: 18px;
+}
+
+#versionMP {
+ text-align: justify;
+ color: #463;
+ background: url(../img/sf_testa.png) top repeat-x #B9CFB3;
+ border: 1px solid #463;
+ padding: 5px;
+}
+
+#versionMP a {
+ color: white;
+ text-decoration: none;
+}
+
+#versionMP a:hover {
+ color: #463;
+ text-decoration: none;
+}
+
+a.tooltips {
+ position: relative;
+ display: inline;
+ text-decoration: none;
+}
+
+a.tooltips span {
+ position: absolute;
+ width:19em;
+ color: #000000;
+ background: whitesmoke;
+ visibility: hidden;
+ border-radius: 0px;
+ padding: 3px;
+}
+
+a.tooltips span:after {
+ position: absolute;
+ top: 50%;
+ left: 100%;
+ margin-top: -8px;
+ width: 0;
+ height: 0;
+}
+
+a.tooltips span {
+ visibility: visible;
+ opacity: none;
+ right: 100%;
+ top: 50%;
+ margin-right: 4px;
+ margin-top: -11px;
+ border: 1px solid black;
+ z-index: 1000000;
+}
+
+a.tooltips span a {
+ color: #463;
+ text-decoration: none;
+}
+
+.tree-junction-expanded {
+ display: none;
+}
+
+/* Style for autocomplete field */
+div.wicket-aa {
+ font-family: "Lucida Grande","Lucida Sans Unicode",Tahoma,Verdana;
+ font-size: 12px;
+ background-color: white;
+ border-width: 1px;
+ border-color: #cccccc;
+ border-style: solid;
+ padding: 2px;
+ margin: 1px 0 0 0;
+ text-align:left;
+}
+div.wicket-aa ul {
+ list-style:none;
+ padding: 2px;
+ margin:0;
+}
+div.wicket-aa ul li.selected {
+ background-color: #FFFF00;
+ padding: 2px;
+ margin:0;
+}
+
+.notificationpanel {
+ margin: 0px;
+ padding: 0px;
+ border-radius: 5px;
+}
+
+.notificationpanel_bottom_left {
+ bottom: 100px;
+ left: 30px;
+}
+
+.notificationpanel_bottom_detail_form {
+ top: 540px;
+ right: 30px;
+}
+
+.notificationpanel_bottom_right {
+ bottom: 100px;
+ right: 30px;
+}
+
+.notificationpanel_top_right {
+ top: 15px;
+ right: 30px;
+}
+
+/* notification panel info style */
+.notificationpanel_border_200 {
+ color: green;
+ margin: 0px;
+ background:url("images/ui-bg_highlight-soft_75_cccccc_1x100.png") repeat-x scroll 50% 50% #CCCCCC;
+ -moz-border-radius: 3px;
+ -webkit-border-radius: 3px;
+ border: 1px solid gray;
+ box-shadow: 0px 0px 5px gray;
+}
+
+.notificationpanel_row_INFO {
+ list-style-type: none;
+ color: green;
+}
+
+.notificationpanel_row_INFO span {
+ list-style-type: none;
+ color: green;
+ background: url("../img/ok.png") no-repeat left;
+ border:0 none;
+ padding-left: 20px;
+}
+
+/* notification panel warning style */
+.notificationpanel_border_300 {
+ border: 1px solid orangered;
+ box-shadow: 0px 0px 5px gray;
+}
+
+.notificationpanel_row_WARNING {
+ color: orangered;
+ list-style-type: none;
+ border:0 none;
+ padding-left: 20px;
+}
+
+/* notification panel error style */
+.notificationpanel_border_400 {
+ color: red;
+ -moz-border-radius: 3px;
+ -webkit-border-radius: 3px;
+ border: 1px solid gray;
+ box-shadow: 0px 0px 5px gray;
+ border-color: red;
+ background-image: -moz-linear-gradient(top, #FF8585 0%, #E60008 100%);
+ background-image: -webkit-linear-gradient(top, #FF8585 0%, #E60008 100%);
+ background-image: -o-linear-gradient(top, #FF8585 0%, #E60008 100%);
+ background-image: -ms-linear-gradient(top, #FF8585 0%, #E60008 100%);
+ background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0, #FF8585), color-stop(1, #E60008));
+ font-weight: bold;
+}
+
+.notificationpanel_row_ERROR {
+ list-style-type: none;
+ color: black;
+}
+
+.notificationpanel_row_ERROR span {
+ border:0 none;
+}
+pre {
+ white-space: -moz-pre-wrap; /* Mozilla, supported since 1999 */
+ white-space: -pre-wrap; /* Opera */
+ white-space: -o-pre-wrap; /* Opera */
+ white-space: pre-wrap; /* CSS3 - Text module (Candidate Recommendation) http://www.w3.org/TR/css3-text/#white-space */
+ word-wrap: break-word; /* IE 5.5+ */
+}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/assign-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/assign-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/assign-icon.png
new file mode 100644
index 0000000..f9f2a33
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/assign-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/both-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/both-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/both-icon.png
new file mode 100644
index 0000000..0f98eec
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/both-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/bulk.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/bulk.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/bulk.png
new file mode 100644
index 0000000..ea6d145
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/bulk.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/claim.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/claim.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/claim.png
new file mode 100644
index 0000000..79332c0
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/claim.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/create.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/create.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/create.png
new file mode 100644
index 0000000..3f8faf1
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/create.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/delete.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/delete.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/delete.png
new file mode 100644
index 0000000..1207d8d
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/delete.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/deprovision-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/deprovision-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/deprovision-icon.png
new file mode 100644
index 0000000..4bc2f4e
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/deprovision-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/dryrun.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/dryrun.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/dryrun.png
new file mode 100644
index 0000000..910b148
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/dryrun.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/edit.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/edit.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/edit.png
new file mode 100644
index 0000000..80e00db
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/edit.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/enable.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/enable.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/enable.png
new file mode 100644
index 0000000..39ba0ca
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/enable.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/execute.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/execute.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/execute.png
new file mode 100644
index 0000000..443c719
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/execute.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/export.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/export.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/export.png
new file mode 100644
index 0000000..038583b
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/export.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/groups-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/groups-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/groups-icon.png
new file mode 100644
index 0000000..9669486
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/groups-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/link-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/link-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/link-icon.png
new file mode 100644
index 0000000..8c166af
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/link-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/manage-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/manage-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/manage-icon.png
new file mode 100644
index 0000000..2e8e190
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/manage-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/none-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/none-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/none-icon.png
new file mode 100644
index 0000000..cc49adb
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/none-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/propagation-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/propagation-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/propagation-icon.png
new file mode 100644
index 0000000..d7fa5e9
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/propagation-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/provision-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/provision-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/provision-icon.png
new file mode 100644
index 0000000..3f8faf1
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/provision-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/reactivate.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/reactivate.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/reactivate.png
new file mode 100644
index 0000000..50503e2
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/reactivate.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/reload.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/reload.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/reload.png
new file mode 100644
index 0000000..bbf878e
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/reload.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/reset.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/reset.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/reset.png
new file mode 100644
index 0000000..bbf878e
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/reset.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/resources-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/resources-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/resources-icon.png
new file mode 100644
index 0000000..6240ba9
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/resources-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/search.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/search.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/search.png
new file mode 100644
index 0000000..3ac297e
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/search.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/select.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/select.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/select.png
new file mode 100644
index 0000000..f2ea103
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/select.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/settings-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/settings-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/settings-icon.png
new file mode 100644
index 0000000..1da7e05
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/settings-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/suspend.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/suspend.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/suspend.png
new file mode 100644
index 0000000..bd5f0bd
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/suspend.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/synchronization-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/synchronization-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/synchronization-icon.png
new file mode 100644
index 0000000..394b907
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/synchronization-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/unassign-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/unassign-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/unassign-icon.png
new file mode 100644
index 0000000..860dc49
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/unassign-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/unlink-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/unlink-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/unlink-icon.png
new file mode 100644
index 0000000..86700a5
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/unlink-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/user_template.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/user_template.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/user_template.png
new file mode 100644
index 0000000..6db6de8
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/user_template.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/actions/users-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/actions/users-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/actions/users-icon.png
new file mode 100644
index 0000000..cfab465
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/actions/users-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/add.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/add.png b/client/old_console/src/main/resources/META-INF/resources/img/add.png
new file mode 100644
index 0000000..043aba8
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/add.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/addAll.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/addAll.png b/client/old_console/src/main/resources/META-INF/resources/img/addAll.png
new file mode 100644
index 0000000..86633fc
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/addAll.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/busy.gif
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/busy.gif b/client/old_console/src/main/resources/META-INF/resources/img/busy.gif
new file mode 100644
index 0000000..e77264f
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/busy.gif differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/db_export.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/db_export.png b/client/old_console/src/main/resources/META-INF/resources/img/db_export.png
new file mode 100644
index 0000000..413cb06
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/db_export.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/disable.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/disable.png b/client/old_console/src/main/resources/META-INF/resources/img/disable.png
new file mode 100644
index 0000000..26fbe85
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/disable.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/down-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/down-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/down-icon.png
new file mode 100644
index 0000000..6f818ee
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/down-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/favicon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/favicon.png b/client/old_console/src/main/resources/META-INF/resources/img/favicon.png
new file mode 100644
index 0000000..aa2f3e2
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/favicon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/file-download.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/file-download.png b/client/old_console/src/main/resources/META-INF/resources/img/file-download.png
new file mode 100644
index 0000000..ceae906
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/file-download.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/file-upload.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/file-upload.png b/client/old_console/src/main/resources/META-INF/resources/img/file-upload.png
new file mode 100644
index 0000000..d4a399e
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/file-upload.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/help.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/help.png b/client/old_console/src/main/resources/META-INF/resources/img/help.png
new file mode 100644
index 0000000..560064e
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/help.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/info.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/info.png b/client/old_console/src/main/resources/META-INF/resources/img/info.png
new file mode 100644
index 0000000..f1a4832
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/info.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/left-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/left-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/left-icon.png
new file mode 100644
index 0000000..03b215c
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/left-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/loading.gif
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/loading.gif b/client/old_console/src/main/resources/META-INF/resources/img/loading.gif
new file mode 100644
index 0000000..85b99d4
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/loading.gif differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/logo.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/logo.png b/client/old_console/src/main/resources/META-INF/resources/img/logo.png
new file mode 100644
index 0000000..f05105e
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/logo.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/configuration.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/configuration.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/configuration.png
new file mode 100644
index 0000000..7d4bb91
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/configuration.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/connectors.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/connectors.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/connectors.png
new file mode 100644
index 0000000..8ae8705
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/connectors.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/groups.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/groups.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/groups.png
new file mode 100644
index 0000000..fba8be7
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/groups.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/logout.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/logout.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/logout.png
new file mode 100644
index 0000000..e8ad795
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/logout.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/configuration.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/configuration.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/configuration.png
new file mode 100644
index 0000000..2c3bb8e
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/configuration.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/connectors.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/connectors.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/connectors.png
new file mode 100644
index 0000000..98394a9
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/connectors.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/groups.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/groups.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/groups.png
new file mode 100644
index 0000000..9b64b4b
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/groups.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/logout.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/logout.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/logout.png
new file mode 100644
index 0000000..ffe0729
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/logout.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/reports.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/reports.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/reports.png
new file mode 100644
index 0000000..596ff39
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/reports.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/resources.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/resources.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/resources.png
new file mode 100644
index 0000000..98394a9
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/resources.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/schema.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/schema.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/schema.png
new file mode 100644
index 0000000..ee1ad4c
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/schema.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/sf_body.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/sf_body.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/sf_body.png
new file mode 100644
index 0000000..0e3bc4c
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/sf_body.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/tasks.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/tasks.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/tasks.png
new file mode 100644
index 0000000..08cde6d
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/tasks.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/todo.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/todo.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/todo.png
new file mode 100644
index 0000000..26a10e3
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/todo.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/users.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/users.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/users.png
new file mode 100644
index 0000000..97bf71b
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/notsel/users.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/reports.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/reports.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/reports.png
new file mode 100644
index 0000000..847fd2b
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/reports.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/resources.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/resources.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/resources.png
new file mode 100644
index 0000000..8ae8705
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/resources.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/schema.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/schema.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/schema.png
new file mode 100644
index 0000000..378a83c
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/schema.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/tasks.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/tasks.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/tasks.png
new file mode 100644
index 0000000..05bdc11
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/tasks.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/todo.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/todo.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/todo.png
new file mode 100644
index 0000000..2fb374b
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/todo.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/menu/users.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/menu/users.png b/client/old_console/src/main/resources/META-INF/resources/img/menu/users.png
new file mode 100644
index 0000000..64264fa
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/menu/users.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/minus-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/minus-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/minus-icon.png
new file mode 100644
index 0000000..4bc2f4e
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/minus-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/modeler.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/modeler.png b/client/old_console/src/main/resources/META-INF/resources/img/modeler.png
new file mode 100644
index 0000000..d33c4ef
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/modeler.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/moveDown.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/moveDown.png b/client/old_console/src/main/resources/META-INF/resources/img/moveDown.png
new file mode 100644
index 0000000..d6ce523
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/moveDown.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/moveUp.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/moveUp.png b/client/old_console/src/main/resources/META-INF/resources/img/moveUp.png
new file mode 100644
index 0000000..d9b2790
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/moveUp.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/ok.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/ok.png b/client/old_console/src/main/resources/META-INF/resources/img/ok.png
new file mode 100644
index 0000000..bc9d2f5
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/ok.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/ping.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/ping.png b/client/old_console/src/main/resources/META-INF/resources/img/ping.png
new file mode 100644
index 0000000..8ad053d
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/ping.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/plus-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/plus-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/plus-icon.png
new file mode 100644
index 0000000..3f8faf1
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/plus-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/reload_30.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/reload_30.png b/client/old_console/src/main/resources/META-INF/resources/img/reload_30.png
new file mode 100644
index 0000000..f9b1e98
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/reload_30.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/remove.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/remove.png b/client/old_console/src/main/resources/META-INF/resources/img/remove.png
new file mode 100644
index 0000000..de5a5cf
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/remove.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/removeAll.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/removeAll.png b/client/old_console/src/main/resources/META-INF/resources/img/removeAll.png
new file mode 100644
index 0000000..f293962
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/removeAll.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/right-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/right-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/right-icon.png
new file mode 100644
index 0000000..2cf0882
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/right-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/search.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/search.png b/client/old_console/src/main/resources/META-INF/resources/img/search.png
new file mode 100644
index 0000000..640c7e8
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/search.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/sf_testa.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/sf_testa.png b/client/old_console/src/main/resources/META-INF/resources/img/sf_testa.png
new file mode 100644
index 0000000..6539dbd
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/sf_testa.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/statuses/active.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/statuses/active.png b/client/old_console/src/main/resources/META-INF/resources/img/statuses/active.png
new file mode 100644
index 0000000..79332c0
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/statuses/active.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/statuses/inactive.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/statuses/inactive.png b/client/old_console/src/main/resources/META-INF/resources/img/statuses/inactive.png
new file mode 100644
index 0000000..68975bd
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/statuses/inactive.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/statuses/objectnotfound.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/statuses/objectnotfound.png b/client/old_console/src/main/resources/META-INF/resources/img/statuses/objectnotfound.png
new file mode 100644
index 0000000..a0a2933
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/statuses/objectnotfound.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/statuses/undefined.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/statuses/undefined.png b/client/old_console/src/main/resources/META-INF/resources/img/statuses/undefined.png
new file mode 100644
index 0000000..97188ba
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/statuses/undefined.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/success.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/success.png b/client/old_console/src/main/resources/META-INF/resources/img/success.png
new file mode 100644
index 0000000..e4b1df7
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/success.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/tab ok.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/tab ok.png b/client/old_console/src/main/resources/META-INF/resources/img/tab ok.png
new file mode 100644
index 0000000..8b6d0ee
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/tab ok.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/tab old.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/tab old.png b/client/old_console/src/main/resources/META-INF/resources/img/tab old.png
new file mode 100644
index 0000000..3d5f156
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/tab old.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/tab.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/tab.png b/client/old_console/src/main/resources/META-INF/resources/img/tab.png
new file mode 100644
index 0000000..2ee49dd
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/tab.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/up-icon.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/up-icon.png b/client/old_console/src/main/resources/META-INF/resources/img/up-icon.png
new file mode 100644
index 0000000..1a4dbdf
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/up-icon.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/warning.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/warning.png b/client/old_console/src/main/resources/META-INF/resources/img/warning.png
new file mode 100644
index 0000000..c98c1fd
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/warning.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/META-INF/resources/img/xml.png
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/META-INF/resources/img/xml.png b/client/old_console/src/main/resources/META-INF/resources/img/xml.png
new file mode 100644
index 0000000..110fdc4
Binary files /dev/null and b/client/old_console/src/main/resources/META-INF/resources/img/xml.png differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/MIMETypes
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/MIMETypes b/client/old_console/src/main/resources/MIMETypes
new file mode 100644
index 0000000..9571823
--- /dev/null
+++ b/client/old_console/src/main/resources/MIMETypes
@@ -0,0 +1,671 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+x-world/x-3dmf
+x-world/x-3dmf
+application/octet-stream
+application/x-authorware-bin
+application/x-authorware-map
+application/x-authorware-seg
+text/vnd.abc
+text/html
+video/animaflex
+application/postscript
+audio/aiff
+audio/x-aiff
+audio/aiff
+audio/x-aiff
+audio/aiff
+audio/x-aiff
+application/x-aim
+text/x-audiosoft-intra
+application/x-navi-animation
+application/x-nokia-9000-communicator-add-on-software
+application/mime
+application/octet-stream
+application/arj
+application/octet-stream
+image/x-jg
+video/x-ms-asf
+text/x-asm
+text/asp
+application/x-mplayer2
+video/x-ms-asf
+video/x-ms-asf-plugin
+audio/basic
+audio/x-au
+application/x-troff-msvideo
+video/avi
+video/msvideo
+video/x-msvideo
+video/avs-video
+application/x-bcpio
+application/mac-binary
+application/macbinary
+application/octet-stream
+application/x-binary
+application/x-macbinary
+image/bmp
+image/bmp
+image/x-windows-bmp
+application/book
+application/book
+application/x-bzip2
+application/x-bsh
+application/x-bzip
+application/x-bzip2
+text/plain
+text/x-c
+text/plain
+application/vnd.ms-pki.seccat
+text/plain
+text/x-c
+application/clariscad
+application/x-cocoa
+application/cdf
+application/x-cdf
+application/x-netcdf
+application/pkix-cert
+application/x-x509-ca-cert
+application/x-chat
+application/x-chat
+application/java
+application/java-byte-code
+application/x-java-class
+application/octet-stream
+text/plain
+text/plain
+application/x-cpio
+text/x-c
+application/mac-compactpro
+application/x-compactpro
+application/x-cpt
+application/pkcs-crl
+application/pkix-crl
+application/pkix-cert
+application/x-x509-ca-cert
+application/x-x509-user-cert
+application/x-csh
+text/x-script.csh
+application/x-pointplus
+text/css
+text/plain
+application/x-director
+application/x-deepv
+text/plain
+application/x-x509-ca-cert
+video/x-dv
+application/x-director
+video/dl
+video/x-dl
+application/msword
+application/msword
+application/commonground
+application/drafting
+application/octet-stream
+video/x-dv
+application/x-dvi
+drawing/x-dwf (old)
+model/vnd.dwf
+application/acad
+image/vnd.dwg
+image/x-dwg
+application/dxf
+image/vnd.dwg
+image/x-dwg
+application/x-director
+text/x-script.elisp
+application/x-bytecode.elisp (compiled elisp)
+application/x-elc
+application/x-envoy
+application/postscript
+application/x-esrehber
+text/x-setext
+application/envoy
+application/x-envoy
+application/octet-stream
+text/plain
+text/x-fortran
+text/x-fortran
+text/plain
+text/x-fortran
+application/vnd.fdf
+application/fractals
+image/fif
+video/fli
+video/x-fli
+image/florian
+text/vnd.fmi.flexstor
+video/x-atomic3d-feature
+text/plain
+text/x-fortran
+image/vnd.fpx
+image/vnd.net-fpx
+application/freeloader
+audio/make
+text/plain
+image/g3fax
+image/gif
+video/gl
+video/x-gl
+audio/x-gsm
+audio/x-gsm
+application/x-gsp
+application/x-gss
+application/x-gtar
+application/x-compressed
+application/x-gzip
+application/x-gzip
+multipart/x-gzip
+text/plain
+text/x-h
+application/x-hdf
+application/x-helpfile
+application/vnd.hp-hpgl
+text/plain
+text/x-h
+text/x-script
+application/hlp
+application/x-helpfile
+application/x-winhelp
+application/vnd.hp-hpgl
+application/vnd.hp-hpgl
+application/binhex
+application/binhex4
+application/mac-binhex
+application/mac-binhex40
+application/x-binhex40
+application/x-mac-binhex40
+application/hta
+text/x-component
+text/html
+text/html
+text/html
+text/webviewhtml
+text/html
+x-conference/x-cooltalk
+image/x-icon
+text/plain
+image/ief
+image/ief
+application/iges
+model/iges
+application/iges
+model/iges
+application/x-ima
+application/x-httpd-imap
+application/inf
+application/x-internett-signup
+application/x-ip2
+video/x-isvideo
+audio/it
+application/x-inventor
+i-world/i-vrml
+application/x-livescreen
+audio/x-jam
+text/plain
+text/x-java-source
+text/plain
+text/x-java-source
+application/x-java-commerce
+image/jpeg
+image/pjpeg
+image/jpeg
+image/jpeg
+image/pjpeg
+image/jpeg
+image/pjpeg
+image/jpeg
+image/pjpeg
+image/x-jps
+application/x-javascript
+application/javascript
+application/ecmascript
+text/javascript
+text/ecmascript
+image/jutvision
+audio/midi
+music/x-karaoke
+application/x-ksh
+text/x-script.ksh
+audio/nspaudio
+audio/x-nspaudio
+audio/x-liveaudio
+application/x-latex
+application/lha
+application/octet-stream
+application/x-lha
+application/octet-stream
+text/plain
+audio/nspaudio
+audio/x-nspaudio
+text/plain
+application/x-lisp
+text/x-script.lisp
+text/plain
+text/x-la-asf
+application/x-latex
+application/octet-stream
+application/x-lzh
+application/lzx
+application/octet-stream
+application/x-lzx
+text/plain
+text/x-m
+video/mpeg
+audio/mpeg
+video/mpeg
+audio/x-mpequrl
+application/x-troff-man
+application/x-navimap
+text/plain
+application/mbedlet
+application/x-magic-cap-package-1.0
+application/mcad
+application/x-mathcad
+image/vasa
+text/mcf
+application/netmc
+application/x-troff-me
+message/rfc822
+message/rfc822
+application/x-midi
+audio/midi
+audio/x-mid
+audio/x-midi
+music/crescendo
+x-music/x-midi
+application/x-midi
+audio/midi
+audio/x-mid
+audio/x-midi
+music/crescendo
+x-music/x-midi
+application/x-frame
+application/x-mif
+message/rfc822
+www/mime
+audio/x-vnd.audioexplosion.mjuicemediafile
+video/x-motion-jpeg
+application/base64
+application/x-meme
+application/base64
+audio/mod
+audio/x-mod
+video/quicktime
+video/quicktime
+video/x-sgi-movie
+audio/mpeg
+audio/x-mpeg
+video/mpeg
+video/x-mpeg
+video/x-mpeq2a
+audio/mpeg3
+audio/x-mpeg-3
+video/mpeg
+video/x-mpeg
+audio/mpeg
+video/mpeg
+application/x-project
+video/mpeg
+video/mpeg
+audio/mpeg
+video/mpeg
+audio/mpeg
+application/vnd.ms-project
+application/x-project
+application/x-project
+application/x-project
+application/marc
+application/x-troff-ms
+video/x-sgi-movie
+audio/make
+application/x-vnd.audioexplosion.mzz
+image/naplps
+image/naplps
+application/x-netcdf
+application/vnd.nokia.configuration-message
+image/x-niff
+image/x-niff
+application/x-mix-transfer
+application/x-conference
+application/x-navidoc
+application/octet-stream
+application/oda
+application/x-omc
+application/x-omcdatamaker
+application/x-omcregerator
+text/x-pascal
+application/pkcs10
+application/x-pkcs10
+application/pkcs-12
+application/x-pkcs12
+application/x-pkcs7-signature
+application/pkcs7-mime
+application/x-pkcs7-mime
+application/pkcs7-mime
+application/x-pkcs7-mime
+application/x-pkcs7-certreqresp
+application/pkcs7-signature
+application/pro_eng
+text/pascal
+image/x-portable-bitmap
+application/vnd.hp-pcl
+application/x-pcl
+image/x-pict
+image/x-pcx
+chemical/x-pdb
+application/pdf
+audio/make
+audio/make.my.funk
+image/x-portable-graymap
+image/x-portable-greymap
+image/pict
+image/pict
+application/x-newton-compatible-pkg
+application/vnd.ms-pki.pko
+text/plain
+text/x-script.perl
+application/x-pixclscript
+image/x-xpixmap
+text/x-script.perl-module
+application/x-pagemaker
+application/x-pagemaker
+image/png
+application/x-portable-anymap
+image/x-portable-anymap
+application/mspowerpoint
+application/vnd.ms-powerpoint
+model/x-pov
+application/vnd.ms-powerpoint
+image/x-portable-pixmap
+application/mspowerpoint
+application/vnd.ms-powerpoint
+application/mspowerpoint
+application/powerpoint
+application/vnd.ms-powerpoint
+application/x-mspowerpoint
+application/mspowerpoint
+application/x-freelance
+application/pro_eng
+application/postscript
+application/octet-stream
+paleovu/x-pv
+application/vnd.ms-powerpoint
+text/x-script.phyton
+application/x-bytecode.python
+audio/vnd.qcelp
+x-world/x-3dmf
+x-world/x-3dmf
+image/x-quicktime
+video/quicktime
+video/x-qtc
+image/x-quicktime
+image/x-quicktime
+audio/x-pn-realaudio
+audio/x-pn-realaudio-plugin
+audio/x-realaudio
+audio/x-pn-realaudio
+application/x-cmu-raster
+image/cmu-raster
+image/x-cmu-raster
+image/cmu-raster
+text/x-script.rexx
+image/vnd.rn-realflash
+image/x-rgb
+application/vnd.rn-realmedia
+audio/x-pn-realaudio
+audio/mid
+audio/x-pn-realaudio
+audio/x-pn-realaudio
+audio/x-pn-realaudio-plugin
+application/ringing-tones
+application/vnd.nokia.ringing-tone
+application/vnd.rn-realplayer
+application/x-troff
+image/vnd.rn-realpix
+audio/x-pn-realaudio-plugin
+text/richtext
+text/vnd.rn-realtext
+application/rtf
+application/x-rtf
+text/richtext
+application/rtf
+text/richtext
+video/vnd.rn-realvideo
+text/x-asm
+audio/s3m
+application/octet-stream
+application/x-tbook
+application/x-lotusscreencam
+text/x-script.guile
+text/x-script.scheme
+video/x-scm
+text/plain
+application/sdp
+application/x-sdp
+application/sounder
+application/sea
+application/x-sea
+application/set
+text/sgml
+text/x-sgml
+text/sgml
+text/x-sgml
+application/x-bsh
+application/x-sh
+application/x-shar
+text/x-script.sh
+application/x-bsh
+application/x-shar
+text/html
+text/x-server-parsed-html
+audio/x-psid
+application/x-sit
+application/x-stuffit
+application/x-koan
+application/x-koan
+application/x-koan
+application/x-koan
+application/x-seelogo
+application/smil
+application/smil
+audio/basic
+audio/x-adpcm
+application/solids
+application/x-pkcs7-certificates
+text/x-speech
+application/futuresplash
+application/x-sprite
+application/x-sprite
+application/x-wais-source
+text/x-server-parsed-html
+application/streamingmedia
+application/vnd.ms-pki.certstore
+application/step
+application/sla
+application/vnd.ms-pki.stl
+application/x-navistyle
+application/step
+application/x-sv4cpio
+application/x-sv4crc
+image/vnd.dwg
+image/x-dwg
+application/x-world
+x-world/x-svr
+application/x-shockwave-flash
+application/x-troff
+text/x-speech
+application/x-tar
+application/toolbook
+application/x-tbook
+application/x-tcl
+text/x-script.tcl
+text/x-script.tcsh
+application/x-tex
+application/x-texinfo
+application/x-texinfo
+application/plain
+text/plain
+application/gnutar
+application/x-compressed
+image/tiff
+image/x-tiff
+image/tiff
+image/x-tiff
+application/x-troff
+audio/tsp-audio
+application/dsptype
+audio/tsplayer
+text/tab-separated-values
+image/florian
+text/plain
+text/x-uil
+text/uri-list
+text/uri-list
+application/i-deas
+text/uri-list
+text/uri-list
+application/x-ustar
+multipart/x-ustar
+application/octet-stream
+text/x-uuencode
+text/x-uuencode
+application/x-cdlink
+text/x-vcalendar
+application/vda
+video/vdo
+application/groupwise
+video/vivo
+video/vnd.vivo
+video/vivo
+video/vnd.vivo
+application/vocaltec-media-desc
+application/vocaltec-media-file
+audio/voc
+audio/x-voc
+video/vosaic
+audio/voxware
+audio/x-twinvq-plugin
+audio/x-twinvq
+audio/x-twinvq-plugin
+application/x-vrml
+model/vrml
+x-world/x-vrml
+x-world/x-vrt
+application/x-visio
+application/x-visio
+application/x-visio
+application/wordperfect6.0
+application/wordperfect6.1
+application/msword
+audio/wav
+audio/x-wav
+application/x-qpro
+image/vnd.wap.wbmp
+application/vnd.xara
+application/msword
+application/x-123
+windows/metafile
+text/vnd.wap.wml
+application/vnd.wap.wmlc
+text/vnd.wap.wmlscript
+application/vnd.wap.wmlscriptc
+application/msword
+application/wordperfect
+application/wordperfect
+application/wordperfect6.0
+application/wordperfect
+application/wordperfect
+application/x-wpwin
+application/x-lotus
+application/mswrite
+application/x-wri
+application/x-world
+model/vrml
+x-world/x-vrml
+model/vrml
+x-world/x-vrml
+text/scriplet
+application/x-wais-source
+application/x-wintalk
+image/x-xbitmap
+image/x-xbm
+image/xbm
+video/x-amt-demorun
+xgl/drawing
+image/vnd.xiff
+application/excel
+application/excel
+application/x-excel
+application/x-msexcel
+application/excel
+application/vnd.ms-excel
+application/x-excel
+application/excel
+application/vnd.ms-excel
+application/x-excel
+application/excel
+application/x-excel
+application/excel
+application/x-excel
+application/excel
+application/vnd.ms-excel
+application/x-excel
+application/excel
+application/vnd.ms-excel
+application/x-excel
+application/excel
+application/vnd.ms-excel
+application/x-excel
+application/x-msexcel
+application/excel
+application/x-excel
+application/excel
+application/x-excel
+application/excel
+application/vnd.ms-excel
+application/x-excel
+application/x-msexcel
+audio/xm
+application/xml
+text/xml
+xgl/movie
+application/x-vnd.ls-xpix
+image/x-xpixmap
+image/xpm
+image/png
+video/x-amt-showrun
+image/x-xwd
+image/x-xwindowdump
+chemical/x-pdb
+application/x-compress
+application/x-compressed
+application/x-compressed
+application/x-zip-compressed
+application/zip
+multipart/x-zip
+application/octet-stream
+text/x-script.zsh
+application/vnd.oasis.opendocument.text
+application/vnd.oasis.opendocument.graphics
+application/vnd.oasis.opendocument.presentation
+application/vnd.oasis.opendocument.spreadsheet
+application/vnd.oasis.opendocument.chart
+application/vnd.oasis.opendocument.formula
+application/vnd.oasis.opendocument.database
+application/vnd.oasis.opendocument.image
\ No newline at end of file
[33/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage.html
deleted file mode 100644
index 9e5d497..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage.html
+++ /dev/null
@@ -1,45 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <link rel="stylesheet" type="text/css" href="css/bulk.css" media="all"/>
- </wicket:head>
- <wicket:extend>
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
-
- <div id="selectedObjects">
- <table class="ui-widget ui-widget-content table-hover pageRowElement" wicket:id="selectedObjects">[DataTable]</table>
-
- <div id="actionRow" class="pageRowElement">
- <div id="actions">
- <div id="actionPanel" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only">
- <span wicket:id="actions">[Actions]</span>
- </div>
-
- <div id="cancelBtmForm">
- <form wicket:id="form">
- <input type="button" wicket:id="cancel" id="cancel"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"/>
- </form>
- </div>
- </div>
- </div>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage.properties
deleted file mode 100644
index bd28d80..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Bulk action
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage_it.properties
deleted file mode 100644
index 3989422..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage_it.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Operazioni di gruppo
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage_pt_BR.properties
deleted file mode 100644
index ec07d02..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage_pt_BR.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=A\u00E7\u00E3o Composta
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage.html
deleted file mode 100644
index 16dd256..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage.html
+++ /dev/null
@@ -1,57 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<wicket:head>
- <link rel="stylesheet" type="text/css" href="css/bulk.css" media="all"/>
-</wicket:head>
-<wicket:extend>
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
-
-<div id="selectedObjects">
- <table class="ui-widget ui-widget-content table-hover pageRowElement" wicket:id="selectedObjects">[DataTable]</table>
-
- <div id="actionRow" class="pageRowElement">
- <div id="actions">
- <div id="cancelBtmForm" style="padding: 0px">
- <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="close">
- <wicket:message key="close"/>
- </a>
- </div>
- </div>
- </div>
-</div>
-</wicket:extend>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage.properties
deleted file mode 100644
index 7ba550c..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Bulk Action Result
-close=Close
-bulkActionResultLabel=Result
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage_it.properties
deleted file mode 100644
index 4268c00..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage_it.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Risultato esecuzion Bulk Action
-close=Chiudi
-bulkActionResultLabel=Esito
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage_pt_BR.properties
deleted file mode 100644
index 00c3a51..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage_pt_BR.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Resultado da A\u00E7\u00E3o Composta
-close=Fechar
-bulkActionResultLabel=Implantar
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage.html
deleted file mode 100644
index 4ce5575..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage.html
+++ /dev/null
@@ -1,39 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div style="margin: 5px;">
- <p class="ui-widget ui-corner-all ui-widget-header">
- <wicket:message key="title"/>
- </p>
- <form wicket:id="confForm">
- <span wicket:id="paramAttrs"/>
-
- <div style="bottom:0;margin:10px">
- <input type="submit"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="submit"/>
- <input type="button"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="cancel"/>
- </div>
- </form>
- </div>
- </wicket:extend>
-</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage.properties
deleted file mode 100644
index 363bef4..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Parameters
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage_it.properties
deleted file mode 100644
index 0fd85ae..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage_it.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Parametri
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage_pt_BR.properties
deleted file mode 100644
index e7f3992..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage_pt_BR.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Par\u00e2metros
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Configuration.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Configuration.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Configuration.html
deleted file mode 100644
index 58a0241..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Configuration.html
+++ /dev/null
@@ -1,230 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <script type="text/javascript">
- $(document).ready(function () {
- $("#policies").tabs();
- $("#logs").tabs();
- $("#layouts").tabs();
- });
- </script>
- </wicket:head>
-
- <wicket:extend>
-
- <div id="tabs">
- <ul>
- <li class="tabs-selected">
- <a href="#layouts"><span><wicket:message key="layouts"/></span></a>
- </li>
- <li><a href="#policies"><span><wicket:message key="policies"/></span></a></li>
- <li><a href="#notifications"><span><wicket:message key="notifications"/></span></a></li>
- <li><a href="#securityQuestions"><span><wicket:message key="securityQuestions"/></span></a></li>
- <li><a href="#workflow"><span><wicket:message key="workflow"/></span></a></li>
- <li><a href="#logs"><span><wicket:message key="logs"/></span></a></li>
- <li><a href="#ext"><span><wicket:message key="ext"/></span></a></li>
- </ul>
- <div id="layouts">
- <ul>
- <li class="tabs-selected">
- <a href="#adminUser"><span><wicket:message key="adminUser"/></span></a>
- </li>
- <li><a href="#selfUser"><span><wicket:message key="selfUser"/></span></a></li>
- <li><a href="#adminGroup"><span><wicket:message key="adminGroup"/></span></a></li>
- <li><a href="#selfGroup"><span><wicket:message key="selfGroup"/></span></a></li>
- <li><a href="#adminMembership"><span><wicket:message key="adminMembership"/></span></a></li>
- <li><a href="#selfMembership"><span><wicket:message key="selfMembership"/></span></a></li>
- </ul>
- <div id="adminUser" style="border-width: 1px;border-top-width: 0px;">
- <span wicket:id="adminUserLayoutPanel">[admin user layout panel]</span>
- </div>
- <div id="selfUser" style="border-width: 1px;border-top-width: 0px;">
- <span wicket:id="selfUserLayoutPanel">[self user layout panel]</span>
- </div>
- <div id="adminGroup" style="border-width: 1px;border-top-width: 0px;">
- <span wicket:id="adminGroupLayoutPanel">[admin group layout panel]</span>
- </div>
- <div id="selfGroup" style="border-width: 1px;border-top-width: 0px;">
- <span wicket:id="selfGroupLayoutPanel">[self group layout panel]</span>
- </div>
- <div id="adminMembership" style="border-width: 1px;border-top-width: 0px;">
- <span wicket:id="adminMembershipLayoutPanel">[admin membership layout panel]</span>
- </div>
- <div id="selfMembership" style="border-width: 1px;border-top-width: 0px;">
- <span wicket:id="selfMembershipLayoutPanel">[self membership layout panel]</span>
- </div>
- </div>
- <div id="policies">
- <ul>
- <li class="tabs-selected">
- <a href="#account"><span><wicket:message key="account"/></span></a>
- </li>
- <li><a href="#password"><span><wicket:message key="password"/></span></a></li>
- <li><a href="#sync"><span><wicket:message key="sync"/></span></a></li>
- </ul>
- <div id="account" style="border-width: 1px;border-top-width: 0px;">
- <span wicket:id="accountPoliciesPanel">[account policies]</span>
- </div>
- <div id="password" style="border-width: 1px;border-top-width: 0px;">
- <span wicket:id="passwordPoliciesPanel">[password policies]</span>
- </div>
- <div id="sync" style="border-width: 1px;border-top-width: 0px;">
- <span wicket:id="syncPoliciesPanel">[sync policies]</span>
- </div>
- </div>
- <div id="notifications">
- <div id="users-contain" class="ui-widget" style="width:inherit">
- <span wicket:id="notificationContainer">
- <table class="ui-widget ui-widget-content table-hover"
- wicket:id="notificationTable"/>
- </span>
-
- <span style="float:right">
- <form wicket:id="notificationPaginatorForm" style="display:inline">
- <label><wicket:message key="displayRows"/></label>
- <select class="text ui-widget-content ui-corner-all"
- wicket:id="rowsChooser"/>
- </form>
- </span>
- </div>
-
- <div wicket:id="createNotificationWin">[Show modal window for creating notification]</div>
- <div wicket:id="editNotificationWin">[Show modal window for editing notification]</div>
-
- <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="createNotificationLink">
- <wicket:message key="create"/>
- </a>
- </div>
- <div id="securityQuestions">
- <div id="users-contain" class="ui-widget" style="width:inherit">
- <span wicket:id="securityQuestionContainer">
- <table class="ui-widget ui-widget-content table-hover"
- wicket:id="securityQuestionTable"/>
- </span>
- </div>
-
- <div wicket:id="createSecurityQuestionWin">[Show modal window for creating security questions]</div>
- <div wicket:id="editSecurityQuestionWin">[Show modal window for editing security questions]</div>
-
- <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="createSecurityQuestionLink">
- <wicket:message key="create"/>
- </a>
- </div>
- <div id="workflow">
- <div id="users-contain" class="ui-widget" style="width:inherit">
- <span wicket:id="noActivitiEnabledForUsers"><i><wicket:message key="noActivitiEnabledForUsers"/></i></span>
- <span wicket:id="workflowDefContainer">
- <div style="float: left;">
- <button wicket:id="activitiModeler" style="width: 122px">
- <div style="display: table-row;">
- <div style="display: table-cell">
- <img src="img/modeler.png" alt="Activiti Modeler" title="Activiti Modeler"/>
- </div>
- <div style="display: table-cell;vertical-align:middle;font-size:62.5%;">
- Activiti Modeler
- </div>
- </div>
- </button>
- </div>
- <div>
- <button wicket:id="xmlEditor" style="width: 122px">
- <div style="display: table-row;">
- <div style="display: table-cell">
- <img src="img/xml.png" alt="XML editor" title="XML editor"/>
- </div>
- <div style="display: table-cell;vertical-align:middle;font-size:62.5%;">
- XML editor
- </div>
- </div>
- </button>
- </div>
- <img wicket:id="workflowDefDiagram" style="width: 100%;"/>
- </span>
- </div>
- </div>
- <div id="logs">
- <ul>
- <li class="tabs-selected">
- <a href="#core"><span>Core</span></a>
- </li>
- <li><a href="#console"><span>Console</span></a></li>
- </ul>
- <div id="core" style="border-width: 1px;border-top-width: 0px;">
- <div id="users-contain" class="ui-widget" style="width:inherit">
- <span wicket:id="coreLoggerContainer">
- <table class="ui-widget ui-widget-content table-hover">
- <thead class="ui-widget-header">
- <tr class="heaaders">
- <th><wicket:message key="logger"/></th>
- <th><wicket:message key="level"/></th>
- </tr>
- </thead>
- <tbody>
- <tr wicket:id="corelogger">
- <td><span wicket:id="key"/></td>
- <td id="level"><select wicket:id="level"/></td>
- </tr>
- </tbody>
- </table>
- </span>
- </div>
- </div>
- <div id="console" style="border-width: 1px;border-top-width: 0px;">
- <div id="users-contain" class="ui-widget" style="width:inherit">
- <span wicket:id="consoleLoggerContainer">
- <table class="ui-widget ui-widget-content table-hover">
- <thead class="ui-widget-header">
- <tr class="heaaders">
- <th><wicket:message key="logger"/></th>
- <th><wicket:message key="level"/></th>
- </tr>
- </thead>
- <tbody>
- <tr wicket:id="consolelogger">
- <td><span wicket:id="key"/></td>
- <td id="level"><select wicket:id="level"/></td>
- </tr>
- </tbody>
- </table>
- </span>
- </div>
- </div>
- </div>
- <div id="ext" wicket:id="extPanels">
- </div>
- <div>
- <div wicket:id="parameters">
- <a style="position: absolute; top: 2px; right:50px;" wicket:id="confLink">
- <img src="img/actions/settings-icon.png" width="30" height="30"
- alt="Parameters" title="title" wicket:message="title:parameters"/>
- </a>
- </div>
- <div wicket:id="syncopeConfWin">[Show modal window for conf parameters]</div>
-
- <a style="position: absolute; top: 2px; right:20px;" wicket:id="dbExportLink">
- <img src="img/db_export.png" width="30" height="30"
- alt="DB export" title="title" wicket:message="title:db_export"/>
- </a>
- </div>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Configuration.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Configuration.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Configuration.properties
deleted file mode 100644
index dea3e78..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Configuration.properties
+++ /dev/null
@@ -1,48 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-parameters=Parameters
-password=Password
-account=Account
-sync=Synchronization
-notifications=Notifications
-workflow=Workflow
-coreLog=Core Log
-consoleLog=Console Log
-edit=Edit
-delete=Delete
-db_export=DB export
-logger=Logger
-level=Level
-events=Events
-template=Template
-traceLevel=Trace level
-subject=Subject
-noActivitiEnabledForUsers=Activiti not enabled for users
-policies=Policies
-logs=Logs
-active=Enabled
-apply=Save
-securityQuestions=Security Questions
-content=Text
-layouts=Layouts
-adminUser=Administrator User Form
-selfUser=Self User Form
-adminGroup=Administrator Group Form
-selfGroup=Self Group Form
-adminMembership=Administrator Membership Form
-selfMembership=Self Membership Form
-ext=Extensions
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Configuration_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Configuration_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Configuration_it.properties
deleted file mode 100644
index 36140b2..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Configuration_it.properties
+++ /dev/null
@@ -1,48 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-parameters=Parametri
-password=Password
-account=Account
-sync=Sincronizzazione
-notifications=Notifiche
-workflow=Workflow
-coreLog=Log Core
-consoleLog=Log Console
-edit=Modifica
-delete=Rimuovi
-db_export=Esportazione DB
-logger=Logger
-level=Livello
-events=Eventi
-template=Modello
-traceLevel=Tracciamento
-subject=Oggetto
-noActivitiEnabledForUsers=Activiti non configurato per gli utenti
-policies=Politiche
-logs=Logs
-active=Abilitata
-apply=Salva
-securityQuestions=Domande di sicurezza
-content=Testo
-layouts=Layouts
-adminUser=Form Amministrazione Utente
-selfUser=Form Utente
-adminGroup=Form Amministrazione Gruppo
-selfGroup=Form Gruppo
-adminMembership=Form Amministrazione Membership
-selfMembership=Form Membership
-ext=Estensioni
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Configuration_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Configuration_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Configuration_pt_BR.properties
deleted file mode 100644
index a39ea61..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Configuration_pt_BR.properties
+++ /dev/null
@@ -1,48 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-parameters=Par\u00e2metros
-password=Senha
-account=Conta
-sync=Sincroniza\u00e7\u00e3o
-notifications=Notifica\u00e7\u00f5es
-workflow=Fluxo de Trabalho
-coreLog=Log Central
-consoleLog=Log do Console
-edit=Editar
-delete=Excluir
-db_export=Exportar Banco de Dados
-logger=Logger
-level=N\u00edvel
-events=Eventos
-template=Template
-traceLevel=N\u00edvel de Trace
-subject=Assunto
-noActivitiEnabledForUsers=Activiti n\u00e3o habilitado para usu\u00e1rios
-policies=Pol\u00edticas
-logs=Logs
-active=Ativada
-apply=Salvar
-securityQuestions=Quest\u00f5es de seguran\u00e7a
-content=Texto
-layouts=Layouts
-adminUser=Forma do usu\u00e1rio de administra\u00e7\u00e3o
-selfUser=Forma Usu\u00e1rio
-adminGroup=Forma de grupo de administra\u00e7\u00e3o
-selfGroup=Form Grupo
-adminMembership=Forma de membro de administra\u00e7\u00e3o
-selfMembership=Forma Membro
-ext=Extens\u00f5es
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.html
deleted file mode 100644
index 2471b30..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.html
+++ /dev/null
@@ -1,55 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div>
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
- <form wicket:id="form">
- <div id="formtable">
- <div class="tablerow alt">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="password"><wicket:message key="password"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="password">[password]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="confirmPassword"><wicket:message key="confirmPassword"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="confirmPassword">[confirmPassword]</span>
- </div>
- </div>
- </div>
-
- <div style="margin: 20px 10px 0">
- <input type="submit"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="apply"/>
- <input type="button"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="cancel"/>
- </div>
- </form>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.properties
deleted file mode 100644
index eb8d9f6..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.properties
+++ /dev/null
@@ -1,20 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Password reset
-submit=Submit
-password=Password
-confirmPassword=Password (confirm)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage_it.properties
deleted file mode 100644
index 2254365..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage_it.properties
+++ /dev/null
@@ -1,20 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Password smarrita
-submit=Invia
-password=Password
-confirmPassword=Password (conferma)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage_pt_BR.properties
deleted file mode 100644
index fa270b9..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage_pt_BR.properties
+++ /dev/null
@@ -1,20 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Redefini\u00e7\u00e3o de senha
-submit=Apresentar
-password=Senha
-confirmPassword=Senha (confirmar)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage.html
deleted file mode 100644
index e6d4676..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage.html
+++ /dev/null
@@ -1,39 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
-
- <div style="margin: 5px;">
- <form wicket:id="form">
- <div id="formtable">
- <div class="tablerow" wicket:id="propView">
- <div class="tablecolumn_label medium_dynamicsize">
- <span wicket:id="key">[key]</span>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="value">[value]</span>
-
- </div>
- </div>
- </div>
- </form>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage.properties
deleted file mode 100644
index 109326f..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Resource data
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage_it.properties
deleted file mode 100644
index 0f4f94f..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage_it.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Dati sulla risorsa
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage_pt_BR.properties
deleted file mode 100644
index daca223..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage_pt_BR.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Dados do Recurso
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage.html
deleted file mode 100644
index b85acb6..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage.html
+++ /dev/null
@@ -1,161 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <p class="ui-widget ui-corner-all ui-widget-header">
- <span wicket:id="new"/> <wicket:message key="title"/> <span wicket:id="key"/>
- </p>
- <div style="margin: 5px;">
- <form wicket:id="form">
- <div id="tabs">
- <ul>
- <li class="tabs-selected"><a href="#tabs-1"><span><wicket:message key="tab1"/></span></a></li>
- <li><a href="#tabs-2"><span><wicket:message key="tab2"/></span></a></li>
- <li><a href="#tabs-3"><span><wicket:message key="tab3"/></span></a></li>
- </ul>
- <div id="tabs-1">
- <div id="formtable">
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="displayName"><wicket:message key="displayName"/></label>
- </div>
- <div class="tablecolumn_field short_dynamicsize">
- <span wicket:id="displayName">[displayName]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="location"><wicket:message key="location"/></label>
- </div>
- <div class="tablecolumn_field short_dynamicsize">
- <span wicket:id="location">[location]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="name"><wicket:message key="name"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="connectorName">[connectorName]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="version"><wicket:message key="version"/></label>
- </div>
- <div class="tablecolumn_field short_dynamicsize">
- <span wicket:id="version">[version]</span>
- </div>
- </div>
- </div>
- <div style="display: table; border: 1px solid #BBBBBB;">
- <div class="tablerow2 alt">
- <div class="tablecolumn2_label short_dynamicsize">
- <label for="connRequestTimeout"><wicket:message key="connRequestTimeout"/></label>
- </div>
- <div class="tablecolumn2_field short_dynamicsize">
- <span wicket:id="connRequestTimeout">[connRequestTimeout]</span>
- </div>
- <div class="tablecolumn2_label short_dynamicsize">
- <label for="poolMaxObjects"><wicket:message key="poolMaxObjects"/></label>
- </div>
- <div class="tablecolumn2_field short_dynamicsize">
- <span wicket:id="poolMaxObjects">[poolMaxObjects]</span>
- </div>
- </div>
- <div class="tablerow2">
- <div class="tablecolumn2_label short_dynamicsize">
- <label for="poolMinIdle"><wicket:message key="poolMinIdle"/></label>
- </div>
- <div class="tablecolumn2_field short_dynamicsize">
- <span wicket:id="poolMinIdle">[poolMinIdle]</span>
- </div>
- <div class="tablecolumn2_label short_dynamicsize">
- <label for="poolMaxIdle"><wicket:message key="poolMaxIdle"/></label>
- </div>
- <div class="tablecolumn2_field short_dynamicsize">
- <span wicket:id="poolMaxIdle">[poolMaxIdle]</span>
- </div>
- </div>
- <div class="tablerow2 alt">
- <div class="tablecolumn2_label short_dynamicsize">
- <label for="poolMaxWait"><wicket:message key="poolMaxWait"/></label>
- </div>
- <div class="tablecolumn2_field short_dynamicsize">
- <span wicket:id="poolMaxWait">[poolMaxWait]</span>
- </div>
- <div class="tablecolumn2_label short_dynamicsize">
- <label for="poolMinEvictableIdleTime"><wicket:message key="poolMinEvictableIdleTime"/></label>
- </div>
- <div class="tablecolumn2_field short_dynamicsize">
- <span wicket:id="poolMinEvictableIdleTime">[poolMinEvictableIdleTime]</span>
- </div>
- </div>
- </div>
- </div>
- <div id="tabs-2">
- <div id="formtable">
- <span wicket:id="container">
- <div style="border-bottom: 10px">
- <div style="width: 40px; text-align: center; font-size: 7px">
- <label for="version"><wicket:message key="overridable"/></label>
- </div>
- </div>
- <form wicket:id="connectorPropForm">
- <div class="tablerow connectorProp" wicket:id="connectorProperties">
- <div class="tablecolumn_check" style="width: 27px; text-align: center; margin-right: 10px">
- <span wicket:id="connPropAttrOverridable">[connPropAttrOverridable]</span>
- </div>
- <div class="tablecolumn_connPropAttr">
- <span wicket:id="connPropAttrSchema">[connPropAttrSchema]</span>
- </div>
- <div class="tablecolumn_field veryshort_fixedsize">
- <span wicket:id="panel">[panel]</span>
- </div>
- </div>
- <div>
- <a style="position: absolute; top: 2px; right:20px;" wicket:id="check">
- <img src="img/ping.png"width="30" height="30"
- alt="ping" title="title" wicket:message="title:check"/>
- </a>
- </div>
- </form>
- </span>
- </div>
- </div>
- <div id="tabs-3">
- <span wicket:id="capabilitiesPalette"/>
- </div>
- </div>
-
- <div style="margin: 20px 10px 0">
- <input type="submit"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="apply"/>
- <input type="button"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="cancel"/>
- </div>
- </form>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage.properties
deleted file mode 100644
index 8500f1a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage.properties
+++ /dev/null
@@ -1,43 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=General
-tab2=Configuration
-tab3=Capabilities
-displayName=Display name
-bundleName=Bundle name
-version=Version
-connRequestTimeout=Request timeout (sec)
-action=Action
-edit=Edit
-edit_attribute=Edit attribute
-serviceName=Service name
-endpoint=Endpoint
-title=Connector
-overridable=Overridable
-property=Property
-value=Value
-
-success_connection=Successful connection
-error_connection=Connection failure
-check=Check connection
-location=Location
-poolMaxObjects=Max objects (idle+active)
-poolMinIdle=Min idle objects
-poolMaxIdle=Max idle objects
-poolMaxWait=Max waiting time (msec)
-poolMinEvictableIdleTime=Min eviction time (msec)
-new=New
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage_it.properties
deleted file mode 100644
index 96080c3..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage_it.properties
+++ /dev/null
@@ -1,43 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=Generale
-tab2=Configurazione
-tab3=Capabilities
-bundleName=Bundle name
-version=Versione
-connRequestTimeout=Timeout richiesta (sec)
-action=Azione
-edit=Edit
-edit_attribute=Edit attribute
-serviceName=Nome servizio
-endpoint=Endpoint
-title=Connettore
-displayName=Nome visualizzato
-overridable=Sovrascrivibile
-property=Propriet\u00e0
-value=Valore
-
-success_connection=Connessione avvenuta con successo
-error_connection=Connessione non riuscita
-check=Verifica connessione
-location=Posizione
-poolMaxObjects=Max oggetti (attivi e non)
-poolMinIdle=Max oggetti attivi
-poolMaxIdle=Max oggetti inattivi
-poolMaxWait=Tempo max attesa
-poolMinEvictableIdleTime=Tempo min espulsione
-new=Nuovo
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage_pt_BR.properties
deleted file mode 100644
index b688216..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage_pt_BR.properties
+++ /dev/null
@@ -1,43 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=Geral
-tab2=Configura\u00e7\u00e3o
-tab3=Capacidades
-displayName=Mostrar Nome
-bundleName=Nome do Pacote
-version=Vers\u00e3o
-connRequestTimeout=Timeout da Requisi\u00e7\u00e3o (seg)
-action=A\u00e7\u00e3o
-edit=Alterar
-edit_attribute=Alterar Atributo
-serviceName=Nome de Servi\u00e7o
-endpoint=Endpoint
-title=Conector
-overridable=Alter\u00e1vel
-property=Propriedade
-value=Valor
-
-success_connection=Sucesso na Conex\u00e3o
-error_connection=Falha na Conex\u00e3o
-check=Verificar a Conex\u00e3o
-location=Localiza\u00e7\u00e3o
-poolMaxObjects=Max objects (idle+active)
-poolMinIdle=Min idle objects
-poolMaxIdle=Max idle objects
-poolMaxWait=Max waiting time (msec)
-poolMinEvictableIdleTime=Min eviction time (msec)
-new=Novo
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage.html
deleted file mode 100644
index 5665e0e..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage.html
+++ /dev/null
@@ -1,64 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
- <div style="margin: 5px;">
- <form wicket:id="form">
- <div id="formtable">
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="key"><wicket:message key="key"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="key">[name]</span>
- </div>
- </div>
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="expression"><wicket:message key="expression"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="expression">[expression]</span>
- <a class="tooltips" wicket:id="questionMarkJexlHelp" href="#" alt="Click to help" title="Click to help">
- <img src="img/help.png"/>
- <span wicket:id="jexlHelp" class="tooltips">
- <wicket:message key="jexl_info"/>
- <ul>
- <li><wicket:message key="jexl_ex1"/></li>
- <li><wicket:message key="jexl_ex2"/></li>
- </ul>
- <a href="#" wicket:id="jexlLink" target="_blank"><wicket:message key="jexl_syntax_url"/></a>
- </span>
- </a>
- </div>
- </div>
- </div>
- <div style="margin: 10px 0px 0">
- <input type="submit"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="apply"/>
- <input type="button"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="cancel"/>
- </div>
- </form>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage.properties
deleted file mode 100644
index e39980a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-required_alert=All form fields are required.
-expression=Expression
-existing_schemas=Existing Schemas:
-edit_attribute=Edit attribute
-attributes=Derived attributes
-title=Derived Schema
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage_it.properties
deleted file mode 100644
index 425e118..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage_it.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-required_alert=Tutti i campi sono richiesti.
-expression=Expression
-existing_schemas=Schemi presenti:
-edit_attribute=Modifica attributo
-attributes=Attributi derivati
-title=Schema Derivato
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage_pt_BR.properties
deleted file mode 100644
index df3aff8..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage_pt_BR.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-required_alert=Todos os campos do formaul\u00e1rio s\u00e3o obrigat\u00f3rios
-expression=Express\u00e3o
-existing_schemas=Esquemas Existentes\:
-edit_attribute=Alterar Atributo
-attributes=Atributos Derivados
-title=Esquema Derivado
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.html
deleted file mode 100644
index 998483d..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.html
+++ /dev/null
@@ -1,132 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <style>
- div.group{
- width:450px;
- }
-
- div.group div{
- width:150;
- height: 25px;
- float:left;
- }
-
- div.group div input {
- width: 30px;
- }
-
- div#attributes-view {
- display: block;
- clear: both;
- float: none;
- overflow: auto;
- margin-top: 0px;
- margin-bottom: 20px;
- margin-left: 10px;
- margin-right: 10px;
- }
-
- .submit{
- display: block;
- clear: both;
- float: none;
- margin-left: 10px;
- }
-
- span.grouplabel{
- display:block;
- clear: both;
- margin-left: 10px;
- margin-bottom: 10px;
- font-weight: bold;
- }
- </style>
- </wicket:head>
- <wicket:extend>
- <form wicket:id="form">
- <div id="attributes-view">
- <p class="ui-widget ui-corner-all ui-widget-header">
- <wicket:message key="title"/>
- </p>
-
- <span class="grouplabel"><wicket:message key="plainSchemas"/></span>
- <span wicket:id="dCheckGroup">
- <div class="group">
- <div wicket:id="details">
- <input type="checkbox" wicket:id="dcheck"/>
- <span wicket:id="dname">[schema name]</span>
- </div>
- </div>
- </span>
-
- <span wicket:id="plainSchemas">[schemas]</span>
-
- <span wicket:id="dschemas">[derived schemas]</span>
-
- <span wicket:id="vschemas">[virtual schemas]</span>
-
- </div>
-
- <wicket:fragment wicket:id="sfragment">
- <span wicket:id="psCheckGroup">
- <div class="group">
- <div wicket:id="plainSchemas">
- <input type="checkbox" wicket:id="scheck"/>
- <span wicket:id="sname">[schema name]</span>
- </div>
- </div>
- </span>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="dsfragment">
- <span class="grouplabel"><wicket:message key="derSchemas"/></span>
- <span wicket:id="dsCheckGroup">
- <div class="group">
- <div wicket:id="derSchemas">
- <input type="checkbox" wicket:id="dscheck"/>
- <span wicket:id="dsname">[schema name]</span>
- </div>
- </div>
- </span>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="vsfragment">
- <span class="grouplabel"><wicket:message key="virSchemas"/></span>
- <span wicket:id="vsCheckGroup">
- <div class="group">
- <div wicket:id="virSchemas">
- <input type="checkbox" wicket:id="vscheck"/>
- <span wicket:id="vsname">[schema name]</span>
- </div>
- </div>
- </span>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="emptyFragment">
- </wicket:fragment>
-
- <div class="submit">
- <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="submit"/>
- <input type="button" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="cancel"/>
- </div>
- </form>
- </wicket:extend>
-</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.properties
deleted file mode 100644
index e7080ed..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.properties
+++ /dev/null
@@ -1,33 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Change display attributes
-tooManySelections=Too many columns to be shown
-plainSchemas=User plain attributes
-derSchemas=User derived attributes
-virSchemas=User virtual attributes
-
-firstname=Firstname
-surname=Surname
-userId=User Id
-edit=Edit
-delete=Delete
-status=Status
-token=Token
-username=Username
-creationDate=Creation Date
-tokenValued=Valued
-tokenNotValued=Not valued
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage_it.properties
deleted file mode 100644
index 6ee5963..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage_it.properties
+++ /dev/null
@@ -1,33 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Scegli attributi da visualizzare
-tooManySelections=Troppe colonne da visualizzare
-plainSchemas=Attributi normali utente
-derSchemas=Attributi derivati utente
-virSchemas=Attributi virtuali utente
-
-firstname=Nome
-surname=Cognome
-userId=User Id
-edit=Edit
-delete=Rimuovi
-status=Stato
-token=Token
-username=Username
-creationDate=Data Creazione
-tokenValued=Valorizzato
-tokenNotValued=Non valorizzato
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage_pt_BR.properties
deleted file mode 100644
index 7f2b8cb..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage_pt_BR.properties
+++ /dev/null
@@ -1,33 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Alterar atributos mostrados
-tooManySelections=Muitas colunas para exibir
-plainSchemas=Atributo Normal de Usu\u00e1rios
-derSchemas=Atributos Derivados de Usu\u00e1rios
-virSchemas=Atributos virtuais de Usu\u00e1rios
-
-firstname=Nome
-surname=Sobrenome
-userId=Identificador de Usu\u00e1rio
-edit=Alterar
-delete=Excluir
-status=Estatus
-token=Token
-username=Nome do Usu\u00e1rio
-creationDate=Data de Cria\u00e7\u00e3o
-tokenValued=Valorado
-tokenNotValued=N\u00e3o Valorado
[04/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Groups_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Groups_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Groups_it.properties
new file mode 100644
index 0000000..76e69f7
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Groups_it.properties
@@ -0,0 +1,26 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tabs-tree=Albero
+tabs-search=Ricerca
+search=Cerca
+create_user=Crea nuovo utente
+search_results_title=Risultati ricerca:
+search_noResults=Nessuna corrispondenza trovata.
+reset=Reset
+showingFrom=Risultati da
+showingTo=a
+showingOf=di
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Groups_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Groups_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Groups_pt_BR.properties
new file mode 100644
index 0000000..8d80401
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Groups_pt_BR.properties
@@ -0,0 +1,26 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tabs-tree=\u00C1rvore
+tabs-search=Buscar
+search=Buscar
+create_user=Criar novo usu\u00E1rio
+search_results_title=Resultados da busca
+search_noResults=N\u00E3o foram encontrados resultados
+reset=Resetar
+showingFrom=Mostrando
+showingTo=para
+showingOf=de
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/HomePage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/HomePage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/HomePage.html
new file mode 100644
index 0000000..2849c44
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/HomePage.html
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml">
+
+ <body>
+
+ <wicket:extend>
+
+ <div>
+ <b>Syncope</b> Home-Page!
+ </div>
+
+ </wicket:extend>
+
+ </body>
+
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage.html
new file mode 100644
index 0000000..1124735
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage.html
@@ -0,0 +1,42 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<wicket:extend>
+ <div id="versionMP">
+ <div style="text-align: center;">
+ <a wicket:id="syncopeLink" target="_blank">
+ <img id="logo" src="img/logo.png" alt="syncope" title="syncope"/>
+ </a>
+ <div style="color: white;font-weight: bold;">Version: <span wicket:id="version"/></div>
+ </div>
+ <br/>
+ <div>
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+ </div>
+ <a wicket:id="licenseLink" target="_blank">http://www.apache.org/licenses/LICENSE-2.0</a>
+ <div>
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+ </div>
+ </div>
+</wicket:extend>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage.properties
new file mode 100644
index 0000000..5f0020a
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage.properties
@@ -0,0 +1,19 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+info=Information
+syncopeSite=Apache Syncope Site
+version=Version
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage_it.properties
new file mode 100644
index 0000000..5a2beea
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage_it.properties
@@ -0,0 +1,19 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+info=Informazioni
+syncopeSite=Sito di Apache Syncope
+version=Versione
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage_pt_BR.properties
new file mode 100644
index 0000000..abd4055
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage_pt_BR.properties
@@ -0,0 +1,19 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+info=Informa\u00E7\u00E3o
+syncopeSite=Site do Apache Syncope
+version=Vers\u00E3o
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Login.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Login.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Login.html
new file mode 100644
index 0000000..78436de
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Login.html
@@ -0,0 +1,89 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+ <meta http-equiv="X-UA-Compatible" content="IE=edge"/>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
+ <meta http-equiv="Content-Style-Type" content="text/css"/>
+
+ <title>Apache Syncope - Login</title>
+
+ <link rel="shortcut icon" href="img/favicon.png" type="image/png"/>
+ <link rel="stylesheet" href="css/style.css" type="text/css" media="all"/>
+
+ <script type="text/javascript">
+
+ var notificationShownTimes = 0;
+
+ function showNotification(componentId, messagecount) {
+ notificationShownTimes++;
+ timeout = 1700 + (messagecount * 500) + notificationShownTimes * 200;
+ $('div#' + componentId).fadeTo('normal', 1.0);
+ setTimeout("$('div#" + componentId + "').fadeOut('normal')", timeout);
+ }
+ </script>
+
+ </head>
+ <body style="text-align:center">
+ <div id="splash">
+ <img src="img/logo.png" alt="syncope" title="syncope" id="logo" />
+ <p style="border: none"> </p>
+ <div id="loginFeedbackDiv">
+ <div wicket:id="feedback">feedbackmessages will be put here</div>
+ </div>
+ <form wicket:id="login">
+ <label for="userId">
+ <wicket:message key="userId"/>
+ </label>
+ <input type="text" wicket:id="userId" id="userId" size="25" style="width: 180px" />
+ <br />
+ <label for="password" class="password">
+ <wicket:message key="password"/>
+ </label>
+ <input type="password" wicket:id="password" id="password" size="25" style="width: 180px" />
+ <br />
+ <select wicket:id="language" id="language"/>
+ <br />
+ <br />
+ <input type="submit" wicket:id="submit"/>
+ </form>
+
+ <div style="display: inline-table; margin: 10px; width:380px;">
+ <div style="display: inline-table-cell; text-align: left; float: left;" wicket:id="selfRegistration"/>
+ <div style="display: inline-table-cell; text-align: left; float: right;" wicket:id="passwordReset"/>
+ </div>
+
+ <wicket:fragment wicket:id="selfRegNotAllowed"/>
+ <wicket:fragment wicket:id="selfRegAllowed">
+ <span wicket:id="selfRegistration"/>
+ </wicket:fragment>
+
+ <div wicket:id="selfRegModal"></div>
+
+ <wicket:fragment wicket:id="pwdResetNotAllowed"/>
+ <wicket:fragment wicket:id="pwdResetAllowed">
+ <span wicket:id="passwordReset"/>
+ </wicket:fragment>
+
+ <div wicket:id="pwdResetReqModal"></div>
+ <div wicket:id="pwdResetConfModal"></div>
+ </div>
+ </body>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Login.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Login.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Login.properties
new file mode 100644
index 0000000..9b31e6e
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Login.properties
@@ -0,0 +1,22 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+userId=Username
+password=Password
+submit=Login
+login-error=Wrong username and/or password
+selfRegistration=Self registration
+passwordReset=Password reset
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Login_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Login_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Login_it.properties
new file mode 100644
index 0000000..40f8c34
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Login_it.properties
@@ -0,0 +1,22 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+userId=Username
+password=Password
+submit=Login
+login-error=Username e/o password errati
+selfRegistration=Registrati
+passwordReset=Password smarrita
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Login_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Login_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Login_pt_BR.properties
new file mode 100644
index 0000000..fd312c4
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Login_pt_BR.properties
@@ -0,0 +1,22 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+userId=Usu\u00e1rio
+password=Senha
+submit=Login
+login-error=Usu\u00e1rio ou senha incorretos
+selfRegistration=Registrar-se
+passwordReset=Redefini\u00e7\u00e3o de senha
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage.html
new file mode 100644
index 0000000..9bc8cb7
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage.html
@@ -0,0 +1,55 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+ <form wicket:id="MembershipForm">
+ <div id="tabs">
+ <ul>
+ <li><a href="#tabs-1"><span><wicket:message key="tab1"/></span></a></li>
+ <li><a href="#tabs-2"><span><wicket:message key="tab2"/></span></a></li>
+ <li><a href="#tabs-3"><span><wicket:message key="tab3"/></span></a></li>
+ </ul>
+ <div id="tabs-1">
+ <div id="formtable">
+ <span wicket:id="plainAttrs">[membership plain attributes]</span>
+ <span wicket:id="systeminformation">[System Information]</span>
+ </div>
+
+ <script type="text/javascript">
+ $(function() {
+ $('#formtable div.tablerow:even').addClass("alt");
+ });
+ </script>
+ </div>
+ <div id="tabs-2">
+ <span wicket:id="derAttrs">[membership derived attributes]</span>
+ </div>
+
+ <div id="tabs-3">
+ <span wicket:id="virAttrs">[membership virtual attributes]</span>
+ </div>
+ </div>
+ <div style="margin: 20px 10px 0">
+ <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="submit"/>
+ <input type="button" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="cancel"/>
+ </div>
+ </form>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage.properties
new file mode 100644
index 0000000..bd02e50
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage.properties
@@ -0,0 +1,35 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tab1=Plain attributes
+tab2=Derived attributes
+tab3=Virtual attributes
+title=Groups
+add=+
+drop=-
+edit=Edit
+delete=Delete
+derAttrs=Derived Attributes
+derAttrToRemove=Delete
+derAttrName=Name
+derAttrValue=Derived value
+
+virAttrs=Virtual Attributes
+virAttrToRemove=Delete
+virAttrName=Name
+virAttrValue=Virtual value
+
+addAttributeBtn=Add
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage_it.properties
new file mode 100644
index 0000000..ebcfd3c
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage_it.properties
@@ -0,0 +1,35 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tab1=Attributi normali
+tab2=Attributi derivati
+tab3=Attributi virtuali
+title=Gruppi
+add=+
+drop=-
+edit=Edit
+delete=Rimuovi
+derAttrs=Attributi derivati
+derAttrToRemove=Elimina
+derAttrName=Nome
+derAttrValue=Valore derivato
+
+virAttrs=Attributi virtuali
+virAttrToRemove=Elimina
+virAttrName=Nome
+virAttrValue=Valore virtuale
+
+addAttributeBtn=Aggiungi
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage_pt_BR.properties
new file mode 100644
index 0000000..15e115d
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage_pt_BR.properties
@@ -0,0 +1,35 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tab1=Atributos Normal
+tab2=Atributos Derivados
+tab3=Atributos Virtuais
+title=Grupos
+add=+
+drop=-
+edit=Alterar
+delete=Excluir
+derAttrs=Atributos Derivados
+derAttrToRemove=Excluir
+derAttrName=Nome
+derAttrValue=Valor Derivado
+
+virAttrs=Atributos Virtuais
+virAttrToRemove=Excluir
+virAttrName=Nome
+virAttrValue=Valor Virtual
+
+addAttributeBtn=Adicionar
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage.html
new file mode 100644
index 0000000..655778b
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage.html
@@ -0,0 +1,234 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:head>
+ <style>
+ div#tabs div#events{
+ min-width: 970px;
+ overflow: hidden;
+ }
+
+ div#userFilter {
+ border: 1px solid #DDDDDD;
+ }
+
+ div#userFilter div#title {
+ margin: 10px 0px 0px 8px;
+ }
+
+ div#userFilter div#warning {
+ margin: 1px 0px 5px 8px;
+ }
+
+ div#userFilter div#title label {
+ font-weight: bold;
+ }
+
+ div#userFilter div#warning label {
+ color: #E00000;
+ font-size: 8px;
+ }
+ </style>
+ </wicket:head>
+ <wicket:extend>
+ <div style="margin: 5px;">
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+ <form wicket:id="form">
+ <div id="tabs">
+ <ul>
+ <li class="tabs-selected"><a href="#notification"><span><wicket:message key="notification"/></span></a></li>
+ <li><a href="#events"><span><wicket:message key="events"/></span></a></li>
+ <li><a href="#about"><span><wicket:message key="about"/></span></a></li>
+ <li><a href="#recipients"><span><wicket:message key="recipients"/></span></a></li>
+ </ul>
+
+ <div id="notification">
+ <div id="formtable">
+ <div class="tablerow alt">
+ <div class="tablecolumn_label medium_fixedsize">
+ <label for="sender"><wicket:message key="sender"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="sender">[sender]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label medium_fixedsize">
+ <label for="subject"><wicket:message key="subject"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="subject">[subject]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label medium_fixedsize">
+ <label for="recipientAttrType"><wicket:message key="recipientAttrType"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="recipientAttrType">[recipientAttrType]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label medium_fixedsize">
+ <label for="recipientAttrName"><wicket:message key="recipientAttrName"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="recipientAttrName">[recipientAttrName]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label medium_fixedsize">
+ <label for="template"><wicket:message key="template"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="template">[template]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label medium_fixedsize">
+ <label for="traceLevel"><wicket:message key="traceLevel"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="traceLevel">[traceLevel]</span>
+ </div>
+ </div>
+ <div class="tablerow alt">
+ <div class="tablecolumn_label medium_fixedsize">
+ <label for="isActive"><wicket:message key="isActive"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="isActive">[isActive]</span>
+ </div>
+ </div>
+ </div>
+ </div>
+
+ <div id="events">
+ <span wicket:id="eventSelection"/>
+ </div>
+
+ <div id="about">
+ <span wicket:id="aboutContainer">
+ <div class="tablerow" style="width: auto;">
+ <div class="tablecolumn_field" style="width: auto; padding-right: 5px;">
+ <span wicket:id="checkAbout">[checkAbout]</span>
+ </div>
+ <div class="tablecolumn_label" style="width: 100%">
+ <label for="checkAbout"><wicket:message key="checkAbout"/></label>
+ </div>
+ </div>
+ <div class="tablerow" style="width: auto;">
+ <div class="tablecolumn_field" style="width: auto; padding-right: 5px;">
+ <span wicket:id="checkUserAbout">[checkUserAbout]</span>
+ </div>
+ <div class="tablecolumn_label" style="width: auto;">
+ <label for="checkUserAbout"><wicket:message key="checkUserAbout"/></label>
+ </div>
+ </div>
+ <div id="userFilter">
+ <div id="title">
+ <label for="userFilter"><wicket:message key="userFilter"/></label>
+ </div>
+ <div id="warning">
+ <label for="userFilter"><wicket:message key="userFilterWarning"/></label>
+ </div>
+ <div id="condition">
+ <span wicket:id="userAbout"/>
+ </div>
+ </div>
+ <div class="tablerow" style="width: auto;">
+ <div class="tablecolumn_field" style="width: auto; padding-right: 5px;">
+ <span wicket:id="checkGroupAbout">[checkGroupAbout]</span>
+ </div>
+ <div class="tablecolumn_label" style="width: auto;">
+ <label for="checkGroupAbout"><wicket:message key="checkGroupAbout"/></label>
+ </div>
+ </div>
+ <div id="userFilter">
+ <div id="title">
+ <label for="groupFilter"><wicket:message key="groupFilter"/></label>
+ </div>
+ <div id="warning">
+ <label for="groupFilter"><wicket:message key="groupFilterWarning"/></label>
+ </div>
+ <div id="condition">
+ <span wicket:id="groupAbout"/>
+ </div>
+ </div>
+ </span>
+ </div>
+
+ <div id="recipients">
+ <div class="tablerow alt">
+ <div class="tablecolumn_label medium_dynamicsize">
+ <span wicket:id="checkStaticRecipients">[checkStaticRecipients]</span>
+ <label for="recipients"><wicket:message key="recipients"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="staticRecipients">[staticRecipients]</span>
+ </div>
+ </div>
+
+ <span wicket:id="recipientsContainer">
+ <div class="tablerow" style="width: auto;">
+ <div class="tablecolumn_field" style="width: auto; padding-right: 5px;">
+ <span wicket:id="checkRecipients">[checkRecipients]</span>
+ </div>
+ <div class="tablecolumn_label" style="width: auto;">
+ <label for="checkRecipients"><wicket:message key="checkRecipients"/></label>
+ </div>
+ </div>
+ <span wicket:id="recipients"/>
+ </span>
+ <div id="userFilter">
+ <div id="title">
+ <label for="userNotifications"><wicket:message key="userNotifications"/></label>
+ </div>
+ <div id="warning">
+ <label for="userNotificationsWarning"><wicket:message key="userNotificationsWarning"/></label>
+ </div>
+ <div class="tablerow" style="width: auto;">
+ <div class="tablecolumn_field" style="width: auto; padding-right: 5px;">
+ <span wicket:id="selfAsRecipient">[selfAsRecipient]</span>
+ </div>
+ <div class="tablecolumn_label" style="width: auto;">
+ <label for="selfAsRecipient"><wicket:message key="selfAsRecipient"/></label>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+
+ <div style="margin: 20px 10px 0">
+ <input type="submit"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="apply"/>
+ <input type="button"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="cancel"/>
+ </div>
+ </form>
+ </div>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage.properties
new file mode 100644
index 0000000..99b7dca
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage.properties
@@ -0,0 +1,40 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Edit notification
+submit=Save
+subject=Subject
+sender=Sender
+template=Template
+traceLevel=Trace level
+notification=Notification
+about=About
+events=Events
+recipients=Recipients
+selfAsRecipient=Include users matching About
+recipientAttrType=Recipients e-mail attribute type
+recipientAttrName=Recipients e-mail attribute schema
+checkRecipients=Search recipients
+checkAbout=All
+userFilter=User filter
+userFilterWarning=Do not use this filter unless events are not targeted at users
+userNotifications=User notifications
+userNotificationsWarning=Do not select this checkbox unless events are not targeted at users
+groupFilter=Group filter
+groupFilterWarning=Do not use this filter unless events are not targeted at groups
+isActive=Enabled
+checkUserAbout=Users
+checkGroupAbout=Groups
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage_it.properties
new file mode 100644
index 0000000..6015c91
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage_it.properties
@@ -0,0 +1,40 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Gestisci notifiche
+submit=Salva
+subject=Oggetto
+sender=Mittente
+template=Modello
+traceLevel=Livello di tracciamento
+notification=Notifica
+about=Soggetti
+events=Eventi
+recipients=Destinatari
+selfAsRecipient=Includi i soggetti
+recipientAttrType=Tipo attributo e-mail destinatari
+recipientAttrName=Schema attributo e-mail destinatari
+checkRecipients=Cerca i destinatari
+checkAbout=Tutto
+userFilter=Filtro utenti
+userFilterWarning=Non usare questo filtro se gli eventi catturati non riguardano espressamente utenti
+userNotifications=Notifiche utente
+userNotificationsWarning=Non selezionare questa checkbox se gli eventi catturati non riguardano espressamente utenti
+groupFilter=Filtro gruppi
+groupFilterWarning=Non usare questo filtro se gli eventi catturati non riguardano espressamente i ruoli
+isActive=Abilitata
+checkUserAbout=Utenti
+checkGroupAbout=Gruppi
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage_pt_BR.properties
new file mode 100644
index 0000000..867b98b
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage_pt_BR.properties
@@ -0,0 +1,40 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Alterar Notifica\u00e7\u00e3o
+submit=Salvar
+subject=Assunto
+sender=Remetente
+template=Template
+traceLevel=N\u00edvel de Trace
+notification=Notifica\u00e7\u00e3o
+about=Sobre
+events=Eventos
+recipients=Destinat\u00e1rios
+selfAsRecipient=Incluir usu\u00e1rios relacionados Sobre
+recipientAttrType=Tipo de atributo de destinat\u00e1rio de email.
+recipientAttrName=Destinat\u00e1rios de e-mail para atributos de esquema
+checkRecipients=Buscar Destinat\u00e1rios
+checkAbout=Todos
+userFilter=Filtro de Usu\u00e1rio
+userFilterWarning=N\u00e3o use este filtro n\u00e3o ser que os eventos n\u00e3o s\u00e3o direcionados a usu\u00e1rios
+userNotifications=Notifica\u00e7\u00f5es do usu\u00e1rio
+userNotificationsWarning=N\u00e3o selecione esta op\u00e7\u00e3o a menos que os eventos n\u00e3o s\u00e3o direcionados a usu\u00e1rios
+isActive=Ativada
+checkUserAbout=Usu\u00e1rio
+checkGroupAbout=Grupos
+groupFilter=Filtro de Grupo
+groupFilterWarning=N\u00e3o use este filtro, a menos que os eventos n\u00e3o s\u00e3o dirigidas a grupos
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage.html
new file mode 100644
index 0000000..c406ce9
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage.html
@@ -0,0 +1,111 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <div id="dialog-form">
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+ <form wicket:id="form">
+ <div id="tabs">
+ <ul>
+ <li class="tabs-selected"><a href="#profile"><span><wicket:message key="profile"/></span></a></li>
+ <li><a href="#executions"><span><wicket:message key="executions"/></span></a></li>
+ </ul>
+ <div id="profile">
+ <div id="users-contain" class="ui-widget">
+ <span wicket:id="profile">
+ <div id="formtable">
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <span wicket:id="idLabel">[Id]</span>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="key">[key]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="sender"><wicket:message key="sender"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="sender">[sender]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="recipients"><wicket:message key="recipients"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="recipients">[recipients]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="subject"><wicket:message key="subject"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="subject">[subject]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="textBody"><wicket:message key="textBody"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <textarea wicket:id="textBody" cols="40" rows="10">[textBody]</textarea>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="htmlBody"><wicket:message key="htmlBody"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <textarea wicket:id="htmlBody" cols="40" rows="10">[textBody]</textarea>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="traceLevel"><wicket:message key="traceLevel"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="traceLevel">[traceLevel]</span>
+ </div>
+ </div>
+ </div>
+ </span>
+ </div>
+ </div>
+ <div id="executions" class="ui-widget">
+ <span wicket:id="executionContainer" id="executionContainer">
+ <table class="ui-widget ui-widget-content"
+ wicket:id="executionsTable" style="width: 100%"/>
+ </span>
+ </div>
+ </div>
+ </form>
+ </div>
+ <div wicket:id="taskExecMessageWin"/>
+ </wicket:extend>
+</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage.properties
new file mode 100644
index 0000000..e9a3120
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage.properties
@@ -0,0 +1,32 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Profile
+executions=Executions
+title=Title
+startDate=Start date
+endDate=End date
+status=Status
+message=Message
+taskExecutions=Task executions
+delete=Delete
+showMessage=Show message
+sender=Sender
+subject=Subject
+recipients=Recipients
+traceLevel=Trace level
+htmlBody=E-mail body (HTML)
+textBody=E-mail body (TEXT)
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage_it.properties
new file mode 100644
index 0000000..c0fa5bd
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage_it.properties
@@ -0,0 +1,32 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Profilo
+executions=Esecuzioni
+title=Task
+startDate=Data di avvio
+endDate=Data di conclusione
+status=Stato
+message=Messaggio
+taskExecutions=Esecuzione del task
+delete=Rimozione
+showMessage=Mostra
+sender=Mittente
+subject=Oggetto
+recipients=Destinatari
+traceLevel=Livello di tracciamento
+htmlBody=Corpo e-mail (HTML)
+textBody=Corpo e-mail (testo)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage_pt_BR.properties
new file mode 100644
index 0000000..91aa59d
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage_pt_BR.properties
@@ -0,0 +1,32 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Perfil
+executions=Execu\u00E7\u00F5es
+title=T\u00EDtulo
+startDate=Data Inicial
+endDate=Data Final
+status=Estatus
+message=Mensagem
+taskExecutions=Execu\u00E7\u00E3o de Tarefas
+delete=Excluir
+showMessage=Exibir Mensagem
+sender=Rementente
+subject=Assunto
+recipients=Destinat\u00E1rios
+traceLevel=N\u00EDvel de Trace
+htmlBody=Corpo do e-mail (HTML)
+textBody=Corpo do E-mail (TEXT)
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage.html
new file mode 100644
index 0000000..154419f
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage.html
@@ -0,0 +1,172 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+ <div style="margin: 5px;">
+ <form wicket:id="form">
+ <div id="formtable">
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="key"><wicket:message key="key"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="key">[name]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="type"><wicket:message key="type"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="type">[type]</span>
+ </div>
+ </div>
+
+ <div wicket:id="conversionParams">
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="conversionPattern"><wicket:message key="conversionPattern"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="conversionPattern">[conversionPattern]</span>
+ </div>
+ </div>
+ </div>
+
+ <div wicket:id="typeParams">
+ <div wicket:id="enumParams">
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="enumerationValues"><wicket:message key="enumerationValues"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="enumerationValues">[enumerationValues]</span>
+ </div>
+ </div>
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="enumerationKeys"><wicket:message key="enumerationKeys"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="enumerationKeys">[enumerationKeys]</span>
+ </div>
+ </div>
+ </div>
+ <div wicket:id="encryptedParams">
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="secretKey"><wicket:message key="secretKey"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="secretKey">[secretKey]</span>
+ </div>
+ </div>
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="cipherAlgorithm"><wicket:message key="cipherAlgorithm"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="cipherAlgorithm">[cipherAlgorithm]</span>
+ </div>
+ </div>
+ </div>
+ <div wicket:id="binaryParams">
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="mimeType"><wicket:message key="mimeType"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="mimeType">[mimeType]</span>
+ </div>
+ </div>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="validatorClass"><wicket:message key="validatorClass"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="validatorClass">[validatorClass]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="mandatoryCondition"><wicket:message key="mandatoryCondition"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <input type="text" class="ui-widget-content ui-corner-all"
+ id="mandatoryCondition" wicket:id="mandatoryCondition"/>
+ <a class="tooltips" wicket:id="questionMarkJexlHelp" href="#" alt="Click to help" title="Click to help">
+ <img src="img/help.png"/>
+ <span wicket:id="jexlHelp" class="tooltips">
+ <wicket:message key="jexl_info"/>
+ <ul>
+ <li><wicket:message key="jexl_ex1"/></li>
+ <li><wicket:message key="jexl_ex2"/></li>
+ </ul>
+ <a href="#" wicket:id="jexlLink" target="_blank"><wicket:message key="jexl_syntax_url"/></a>
+ </span>
+ </a>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="uniqueConstraint" class="onerowlabel"><wicket:message key="uniqueConstraint"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="uniqueConstraint">[uniqueConstraint]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="multivalue" class="onerowlabel"><wicket:message key="multivalue"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="multivalue">[multivalue]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="readonly" class="onerowlabel"><wicket:message key="readonly"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="readonly">[readonly]</span>
+ </div>
+ </div>
+ </div>
+
+ <div style="margin: 10px 0px 0;">
+ <input type="submit"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="apply"/>
+ <input type="button"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="cancel"/>
+ </div>
+ </form>
+ </div>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage.properties
new file mode 100644
index 0000000..58c5708
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage.properties
@@ -0,0 +1,38 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tab1=Attributes
+tab2=Derived attributes
+tab3=User attributes
+tab4=User derived attributes
+required_alert=All form fields are required.
+mandatoryCondition=Mandatory
+enumerationValues= Enumeration values
+enumerationKeys= Enumeration labels
+uniqueConstraint=Unique
+multivalue=Multivalue
+multivalueAndUniqueConstr.validation='Multivalue' and 'Unique constraint' options can't be both checked
+type=Type
+validatorClass=Validator class
+conversionPattern=Conversion pattern
+existing_schemas=Existing Schemas:
+action=Action
+edit_attribute=Edit attribute
+title=Schema
+readonly=Read-only
+secretKey=Secret key
+cipherAlgorithm=Cipher algorithm
+mimeType=MIME Type
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage_it.properties
new file mode 100644
index 0000000..74eed7d
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage_it.properties
@@ -0,0 +1,38 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tab1=Attributi
+tab2=Attributi derivati
+tab3=Attributi utenti
+tab4=Attributi utenti derivati
+required_alert=Tutti i campi sono richiesti
+mandatoryCondition=Obbligatorio
+enumerationValues= Valori enumeration
+enumerationKeys= Label enumeration
+multivalue=Multivalore
+type=Tipo
+validatorClass=Validatore
+conversionPattern=Conversion pattern
+existing_schemas=Schema esistenti:
+action=Azione
+edit_attribute=Modifica attributo
+title=Schema
+readonly=Read-only
+uniqueConstraint=Univoco
+multivalueAndUniqueConstr.validation=Le opzioni 'Multivalore' e 'Vincolo unique' non possono essere entrambe impostate
+secretKey=Chiave segreta
+cipherAlgorithm=Algoritmo di cifratura
+mimeType=MIME Type
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage_pt_BR.properties
new file mode 100644
index 0000000..a026c17
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage_pt_BR.properties
@@ -0,0 +1,38 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tab1=Atributos
+tab2=Atributos derivados
+tab3=Atributos de usu\u00e1rios
+tab4=Atributos derivados de usu\u00e1rios
+required_alert=Todos os campos s\u00e3o obrigat\u00f3rios
+mandatoryCondition=obrigat\u00f3rio
+enumerationValues= Valores enumerados
+enumerationKeys= R\u00f3tulos de enumera\u00e7\u00e3o
+uniqueConstraint=\u00danico
+multivalue=Multivalorado
+multivalueAndUniqueConstr.validation=As op\u00e7\u00f5es 'Multivalorado' e 'Restri\u00e7\u00e3o \u00fanica' n\u00e3o podem serem ambas selecionadas
+type=Tipo
+validatorClass=Classe de Valida\u00e7\u00e3o
+conversionPattern=Padr\u00e3o de Convers\u00e3o
+existing_schemas=Esquemas Existentes\:
+action=A\u00e7\u00e3o
+edit_attribute=Editar Atributo
+title=Esquema
+readonly=Apenas leitura
+secretKey=Chave secreta
+cipherAlgorithm=Algoritmo de criptografia
+mimeType=MIME Type
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage.html
new file mode 100644
index 0000000..786c4e3
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage.html
@@ -0,0 +1,109 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <div style="margin: 5px;">
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+
+ <form wicket:id="form">
+ <div id="tabs">
+ <ul>
+ <li class="tabs-selected"><a href="#info"><span><wicket:message key="policyInfo"/></span></a></li>
+ <li><a href="#specification"><span><wicket:message key="policySpecification"/></span></a></li>
+ <li><a href="#resources"><span><wicket:message key="resources"/></span></a></li>
+ <li><a href="#groups"><span><wicket:message key="groups"/></span></a></li>
+ </ul>
+
+ <div id="info">
+ <div id="formtable">
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_fixedsize">
+ <label for="key"><wicket:message key="key"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="key">[key]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_fixedsize">
+ <label for="type"><wicket:message key="type"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="type">[type]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_fixedsize">
+ <label for="description"><wicket:message key="description"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="description">[description]</span>
+ </div>
+ </div>
+
+ <span wicket:id="forAccountOnly"/>
+ </div>
+ </div>
+
+ <wicket:fragment wicket:id="authResourcesFragment">
+ <div class="tablerow">
+ <div class="tablecolumn_label short_fixedsize">
+ <label for="authResources"><wicket:message key="authResources"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="authResources">[resources]</span>
+ </div>
+ </div>
+ </wicket:fragment>
+ <wicket:fragment wicket:id="emptyFragment">
+ </wicket:fragment>
+
+ <div id="specification">
+ <span wicket:id="panel">[password policy panel]</span>
+ </div>
+
+ <div id="resources">
+ <div id="users-contain" class="ui-widget" style="width:inherit;">
+ <table class="ui-widget ui-widget-content table-hover" wicket:id="resources"/>
+ </div>
+ </div>
+
+ <div id="groups">
+ <div id="users-contain" class="ui-widget" style="width:inherit;">
+ <table class="ui-widget ui-widget-content table-hover" wicket:id="groups"/>
+ </div>
+ </div>
+ </div>
+
+ <div style="margin: 20px 10px 0">
+ <input type="submit"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="apply"/>
+ <input type="button"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="cancel"/>
+ </div>
+ </form>
+ </div>
+
+ <div wicket:id="metaEditModalWin">[Show modal window for meta editing (resources, groups)]</div>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage.properties
new file mode 100644
index 0000000..e98ca25
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage.properties
@@ -0,0 +1,88 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Policy management
+
+description=Description
+type=Type
+apply=Save
+
+policyInfo=Info
+policySpecification = Specification
+
+#-----------------------------
+# Password policy specification properties
+#-----------------------------
+minLength=Minimum size
+maxLength=Maximum size
+historyLength=History length
+prefixesNotPermitted=Prefixes not permitted
+suffixesNotPermitted=Suffixes not permitted
+wordsNotPermitted=Substrings not permitted
+schemasNotPermitted=Mustn't contain value of the following attributes
+digitRequired=Must contain one or more digits
+nonAlphanumericRequired=Non alphanumeric character required
+alphanumericRequired=Alphanumeric character required
+lowercaseRequired=Lowercase required
+uppercaseRequired=Uppercase required
+mustStartWithDigit=Must start with digit
+mustntStartWithDigit=Mustn't start with digit
+mustEndWithDigit=Must end with digit
+mustntEndWithDigit=Mustn't end with digit
+mustStartWithNonAlpha=Must start with non alphanumeric character
+mustStartWithAlpha=Must start with alphanumeric character
+mustntStartWithNonAlpha=Mustn't start with non alphanumeric character
+mustntStartWithAlpha=Mustn't start with alphanumeric character
+mustEndWithNonAlpha=Must end with non alphanumeric character
+mustEndWithAlpha=Must end with alphanumeric character
+mustntEndWithNonAlpha=Mustn't end with non alphanumeric character
+mustntEndWithAlpha=Mustn't end with alphanumeric character
+allowNullPassword=Password may be not stored internally
+#-----------------------------
+
+#-----------------------------
+# Account policy specification properties
+#-----------------------------
+allUpperCase=All upper case
+allLowerCase=All lower case
+pattern=Pattern (regex)
+propagateSuspension=Propagate suspension
+permittedLoginRetries=Maximum number of subsequent failed logins
+#-----------------------------
+
+#-----------------------------
+# Sync policy specification properties
+#-----------------------------
+uAltSearchSchemas=Alternative attributes for local search (users)
+gAltSearchSchemas=Alternative attributes for local search (groups)
+userJavaRule=Custom user correlation rule
+groupJavaRule=Custom group correlation rule
+conflictResolutionAction= Conflict resolution action
+#-----------------------------
+
+#-----------------------------
+# Policy Type
+#-----------------------------
+ACCOUNT=Account Policy
+GLOBAL_ACCOUNT=Global Account Policy
+PASSWORD=Password Policy
+GLOBAL_PASSWORD=Global Password Policy
+SYNC=Synchronization Policy
+GLOBAL_SYNC=Global Synchronization Policy
+#-----------------------------
+resources=Resources
+groups=Groups
+authResources=Authentication resources
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage_it.properties
new file mode 100644
index 0000000..756411b
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage_it.properties
@@ -0,0 +1,88 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Gestione Policy
+
+description=Descrizione
+type=Tipo
+apply=Salva
+
+policyInfo=Info
+policySpecification = Specifica
+
+#-----------------------------
+# Password policy specification properties
+#-----------------------------
+minLength=Lunghezza minima
+maxLength=Lunghezza massima
+historyLength=Lunghezza storico
+prefixesNotPermitted=Prefissi non permessi
+suffixesNotPermitted=Suffissi non permessi
+wordsNotPermitted=Sottostringhe non permesse
+schemasNotPermitted=Non deve contenere i valore dei seguenti attributi
+digitRequired=Numero richiesto
+lowercaseRequired=Lettera minuscola richiesta
+uppercaseRequired=Lettera maiuscola richiesta
+mustStartWithDigit=Deve iniziare con un numero
+mustntStartWithDigit=Non deve iniziare con un numero
+mustEndWithDigit=Deve terminare con un numero
+mustntEndWithDigit=Non deve terminare con un numero
+mustStartWithNonAlpha=Deve iniziare con un carattere non alfanumerico
+mustStartWithAlpha=Deve iniziare con un carattere alfanumerico
+mustntStartWithNonAlpha=Non deve iniziare con un carattere non alfanumerico
+mustntStartWithAlpha=Non deve iniziare con un carattere alfanumerico
+mustEndWithNonAlpha=Deve terminare con un carattere non alfanumerico
+mustEndWithAlpha=Deve terminare con un carattere alfanumerico
+mustntEndWithNonAlpha=Non deve terminare con un carattere non alfanumerico
+mustntEndWithAlpha=Non deve terminare con un carattere alfanumerico
+allowNullPassword=La password pu\u00f2 non essere memorizzata internamente
+#-----------------------------
+
+#-----------------------------
+# Account policy specification properties
+#-----------------------------
+allUpperCase=Tutte maiuscole
+allLowerCase=Tutte minuscole
+pattern=Pattern (regex)
+propagateSuspension=Propagare sospensione
+permittedLoginRetries=Numero massimo di login consecutivi falliti
+#-----------------------------
+
+#-----------------------------
+# Sync policy specification properties
+#-----------------------------
+uAltSearchSchemas=Attributi alternativi per ricerca locale (utenti)
+conflictResolutionAction= Azione di risoluzione dei conflitti
+#-----------------------------
+
+#-----------------------------
+# Policy Type
+#-----------------------------
+ACCOUNT=Policy utente
+GLOBAL_ACCOUNT=Policy utente globale
+PASSWORD=Password policy
+GLOBAL_PASSWORD=Password policy globale
+SYNC=Policy di sincronizzazione
+GLOBAL_SYNC=Policy globale di sincronizzazione
+#-----------------------------
+nonAlphanumericRequired=Carattere non alfanumerico richiesto
+alphanumericRequired=Carattere alfanumerico richiesto
+gAltSearchSchemas=Attributi alternativi per ricerca locale (gruppi)
+userJavaRule=Regola di correlazione (utenti)
+groupJavaRule=Regola di correlazione (gruppi)
+resources=Risorse
+groups=Gruppi
+authResources=Risorse di autenticazione
[18/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Schema.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Schema.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Schema.java
new file mode 100644
index 0000000..cffb7cd
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Schema.java
@@ -0,0 +1,468 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.lang.reflect.Field;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.commons.lang3.tuple.ImmutablePair;
+import org.apache.commons.lang3.tuple.Pair;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.PreferenceManager;
+import org.apache.syncope.client.console.commons.SchemaModalPageFactory;
+import org.apache.syncope.client.console.commons.SelectChoiceRenderer;
+import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
+import org.apache.syncope.client.console.panels.JQueryUITabbedPanel;
+import org.apache.syncope.client.console.rest.SchemaRestClient;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink.ActionType;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.common.lib.to.AbstractSchemaTO;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.syncope.common.lib.types.SchemaType;
+import org.apache.wicket.AttributeModifier;
+import org.apache.wicket.Page;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
+import org.apache.wicket.extensions.markup.html.tabs.AbstractTab;
+import org.apache.wicket.extensions.markup.html.tabs.ITab;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.springframework.beans.BeanWrapper;
+import org.springframework.beans.BeanWrapperImpl;
+import org.springframework.util.ReflectionUtils;
+
+/**
+ * Schema WebPage.
+ */
+@SuppressWarnings({ "unchecked", "rawtypes" })
+public class Schema extends BasePage {
+
+ private static final long serialVersionUID = 8091922398776299403L;
+
+ private static final Map<SchemaType, List<String>> COL_NAMES = new HashMap<SchemaType, List<String>>() {
+
+ private static final long serialVersionUID = 3109256773218160485L;
+
+ {
+ put(SchemaType.PLAIN, Arrays.asList(new String[] { "key", "type",
+ "mandatoryCondition", "uniqueConstraint", "multivalue", "readonly" }));
+ put(SchemaType.DERIVED, Arrays.asList(new String[] { "key", "expression" }));
+ put(SchemaType.VIRTUAL, Arrays.asList(new String[] { "key", "readonly" }));
+ }
+ };
+
+ private static final Map<Pair<AttributableType, SchemaType>, String> PAGINATOR_ROWS_KEYS =
+ new HashMap<Pair<AttributableType, SchemaType>, String>() {
+
+ private static final long serialVersionUID = 3109256773218160485L;
+
+ {
+ put(new ImmutablePair<>(AttributableType.CONFIGURATION, SchemaType.PLAIN),
+ Constants.PREF_CONF_SCHEMA_PAGINATOR_ROWS);
+ put(new ImmutablePair<>(AttributableType.USER, SchemaType.PLAIN),
+ Constants.PREF_USER_PLAIN_SCHEMA_PAGINATOR_ROWS);
+ put(new ImmutablePair<>(AttributableType.USER, SchemaType.DERIVED),
+ Constants.PREF_USER_DER_SCHEMA_PAGINATOR_ROWS);
+ put(new ImmutablePair<>(AttributableType.USER, SchemaType.VIRTUAL),
+ Constants.PREF_USER_VIR_SCHEMA_PAGINATOR_ROWS);
+ put(new ImmutablePair<>(AttributableType.MEMBERSHIP, SchemaType.PLAIN),
+ Constants.PREF_MEMBERSHIP_PLAIN_SCHEMA_PAGINATOR_ROWS);
+ put(new ImmutablePair<>(AttributableType.MEMBERSHIP, SchemaType.DERIVED),
+ Constants.PREF_MEMBERSHIP_DER_SCHEMA_PAGINATOR_ROWS);
+ put(new ImmutablePair<>(AttributableType.MEMBERSHIP, SchemaType.VIRTUAL),
+ Constants.PREF_MEMBERSHIP_VIR_SCHEMA_PAGINATOR_ROWS);
+ put(new ImmutablePair<>(AttributableType.GROUP, SchemaType.PLAIN),
+ Constants.PREF_GROUP_PLAIN_SCHEMA_PAGINATOR_ROWS);
+ put(new ImmutablePair<>(AttributableType.GROUP, SchemaType.DERIVED),
+ Constants.PREF_GROUP_DER_SCHEMA_PAGINATOR_ROWS);
+ put(new ImmutablePair<>(AttributableType.GROUP, SchemaType.VIRTUAL),
+ Constants.PREF_GROUP_VIR_SCHEMA_PAGINATOR_ROWS);
+ }
+ };
+
+ private static final int WIN_WIDTH = 600;
+
+ private static final int WIN_HEIGHT = 200;
+
+ private static final int PLAIN_WIN_HEIGHT = 500;
+
+ @SpringBean
+ private SchemaRestClient restClient;
+
+ @SpringBean
+ private PreferenceManager prefMan;
+
+ private final String allowedCreateRoles = xmlRolesReader.getEntitlement("Schema", "create");
+
+ private final String allowedReadRoles = xmlRolesReader.getEntitlement("Schema", "read");
+
+ private final String allowedDeleteRoles = xmlRolesReader.getEntitlement("Schema", "delete");
+
+ public Schema() {
+ super();
+
+ for (final AttributableType attrType : AttributableType.values()) {
+ final String attrTypeAsString = attrType.name().toLowerCase();
+
+ List<ITab> tabs = new ArrayList<>();
+
+ for (final SchemaType schemaType : SchemaType.values()) {
+ if (attrType != AttributableType.CONFIGURATION || schemaType == SchemaType.PLAIN) {
+ final String schemaTypeAsString = schemaType.name().toLowerCase();
+
+ tabs.add(new AbstractTab(new Model<>(getString(schemaTypeAsString))) {
+
+ private static final long serialVersionUID = -5861786415855103549L;
+
+ @Override
+ public WebMarkupContainer getPanel(final String panelId) {
+ return new SchemaTypePanel(panelId, attrType, schemaType);
+ }
+ });
+ }
+ }
+
+ add(new JQueryUITabbedPanel(attrTypeAsString + "Tabs", tabs));
+ }
+ }
+
+ private <T extends AbstractSchemaModalPage> List<IColumn> getColumns(
+ final WebMarkupContainer webContainer, final ModalWindow modalWindow,
+ final AttributableType attributableType, final SchemaType schemaType,
+ final Collection<String> fields) {
+
+ List<IColumn> columns = new ArrayList<IColumn>();
+
+ for (final String field : fields) {
+ final Field clazzField = ReflectionUtils.findField(schemaType.getToClass(), field);
+
+ if (clazzField != null) {
+ if (clazzField.getType().equals(Boolean.class) || clazzField.getType().equals(boolean.class)) {
+ columns.add(new AbstractColumn<AbstractSchemaTO, String>(new ResourceModel(field)) {
+
+ private static final long serialVersionUID = 8263694778917279290L;
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<AbstractSchemaTO>> item,
+ final String componentId, final IModel<AbstractSchemaTO> model) {
+
+ BeanWrapper bwi = new BeanWrapperImpl(model.getObject());
+ Object obj = bwi.getPropertyValue(field);
+
+ item.add(new Label(componentId, ""));
+ item.add(new AttributeModifier("class", new Model<String>(obj.toString())));
+ }
+
+ @Override
+ public String getCssClass() {
+ return "small_fixedsize";
+ }
+ });
+ } else {
+ IColumn column = new PropertyColumn(new ResourceModel(field), field, field) {
+
+ private static final long serialVersionUID = 3282547854226892169L;
+
+ @Override
+ public String getCssClass() {
+ String css = super.getCssClass();
+ if ("key".equals(field)) {
+ css = StringUtils.isBlank(css)
+ ? "medium_fixedsize"
+ : css + " medium_fixedsize";
+ }
+ return css;
+ }
+ };
+ columns.add(column);
+ }
+ }
+ }
+
+ columns.add(new AbstractColumn<AbstractSchemaTO, String>(new ResourceModel("actions", "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public String getCssClass() {
+ return "action";
+ }
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<AbstractSchemaTO>> item, final String componentId,
+ final IModel<AbstractSchemaTO> model) {
+
+ final AbstractSchemaTO schemaTO = model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
+
+ panel.addWithRoles(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ modalWindow.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ AbstractSchemaModalPage page = SchemaModalPageFactory.getSchemaModalPage(
+ attributableType, schemaType);
+
+ page.setSchemaModalPage(Schema.this.getPageReference(), modalWindow, schemaTO, false);
+
+ return page;
+ }
+ });
+
+ modalWindow.show(target);
+ }
+ }, ActionType.EDIT, allowedReadRoles);
+
+ panel.addWithRoles(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+
+ switch (schemaType) {
+ case DERIVED:
+ restClient.deleteDerSchema(attributableType, schemaTO.getKey());
+ break;
+
+ case VIRTUAL:
+ restClient.deleteVirSchema(attributableType, schemaTO.getKey());
+ break;
+
+ default:
+ restClient.deletePlainSchema(attributableType, schemaTO.getKey());
+ break;
+ }
+
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ feedbackPanel.refresh(target);
+
+ target.add(webContainer);
+ }
+ }, ActionType.DELETE, allowedDeleteRoles);
+
+ item.add(panel);
+ }
+ });
+
+ return columns;
+ }
+
+ private Form<Void> getPaginatorForm(final WebMarkupContainer webContainer,
+ final AjaxFallbackDefaultDataTable dataTable,
+ final String formname, final SchemaTypePanel schemaTypePanel, final String rowsPerPagePrefName) {
+
+ Form<Void> form = new Form<>(formname);
+
+ final DropDownChoice<Integer> rowChooser = new DropDownChoice<Integer>("rowsChooser",
+ new PropertyModel<Integer>(schemaTypePanel, "pageRows"), prefMan.getPaginatorChoices(),
+ new SelectChoiceRenderer<Integer>());
+
+ rowChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ prefMan.set(getRequest(), getResponse(), rowsPerPagePrefName, rowChooser.getInput());
+ dataTable.setItemsPerPage(rowChooser.getModelObject());
+
+ target.add(webContainer);
+ }
+ });
+
+ form.add(rowChooser);
+
+ return form;
+ }
+
+ private <T extends AbstractSchemaModalPage> AjaxLink<Void> getCreateSchemaLink(final ModalWindow modalWindow,
+ final AttributableType attrType, final SchemaType schemaType, final String winLinkName) {
+
+ AjaxLink<Void> link = new ClearIndicatingAjaxLink<Void>(winLinkName, getPageReference()) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ modalWindow.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ T page = SchemaModalPageFactory.getSchemaModalPage(attrType, schemaType);
+ page.setSchemaModalPage(Schema.this.getPageReference(), modalWindow, null, true);
+
+ return page;
+ }
+ });
+
+ modalWindow.show(target);
+ }
+ };
+
+ MetaDataRoleAuthorizationStrategy.authorize(link, ENABLE, allowedCreateRoles);
+
+ return link;
+
+ }
+
+ private class SchemaProvider extends SortableDataProvider<AbstractSchemaTO, String> {
+
+ private static final long serialVersionUID = -185944053385660794L;
+
+ private final SortableDataProviderComparator<AbstractSchemaTO> comparator;
+
+ private final AttributableType attrType;
+
+ private final SchemaType schemaType;
+
+ public SchemaProvider(final AttributableType attrType, final SchemaType schemaType) {
+ super();
+
+ this.attrType = attrType;
+ this.schemaType = schemaType;
+
+ // Default sorting
+ setSort("key", SortOrder.ASCENDING);
+
+ comparator = new SortableDataProviderComparator<>(this);
+ }
+
+ @Override
+ public Iterator<AbstractSchemaTO> iterator(final long first, final long count) {
+ @SuppressWarnings("unchecked")
+ List<AbstractSchemaTO> list =
+ (List<AbstractSchemaTO>) restClient.getSchemas(this.attrType, this.schemaType);
+
+ Collections.sort(list, comparator);
+
+ return list.subList((int) first, (int) first + (int) count).iterator();
+ }
+
+ @Override
+ public long size() {
+ return restClient.getSchemas(this.attrType, this.schemaType).size();
+ }
+
+ @Override
+ public IModel<AbstractSchemaTO> model(final AbstractSchemaTO object) {
+ return new CompoundPropertyModel<AbstractSchemaTO>(object);
+ }
+ }
+
+ private class SchemaTypePanel extends Panel {
+
+ private static final long serialVersionUID = 2854050613688773575L;
+
+ private int pageRows;
+
+ private final AttributableType attrType;
+
+ private final SchemaType schemaType;
+
+ public SchemaTypePanel(final String id, final AttributableType attrType, final SchemaType schemaType) {
+ super(id);
+
+ this.attrType = attrType;
+ this.schemaType = schemaType;
+
+ setup();
+ }
+
+ private void setup() {
+ ModalWindow editSchemaWin = new ModalWindow("editSchemaWin");
+ editSchemaWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ editSchemaWin.setInitialWidth(WIN_WIDTH);
+ if (schemaType == SchemaType.PLAIN) {
+ editSchemaWin.setInitialHeight(PLAIN_WIN_HEIGHT);
+ } else {
+ editSchemaWin.setInitialHeight(WIN_HEIGHT);
+ }
+ editSchemaWin.setCookieName("editSchemaWin");
+ editSchemaWin.setMarkupId("editSchemaWin");
+ add(editSchemaWin);
+
+ WebMarkupContainer schemaWrapContainer = new WebMarkupContainer("schemaWrapContainer");
+ schemaWrapContainer.setOutputMarkupId(true);
+ if (schemaType != SchemaType.VIRTUAL) {
+ schemaWrapContainer.add(new AttributeModifier("style", "width:auto;"));
+ }
+ add(schemaWrapContainer);
+
+ WebMarkupContainer schemaContainer = new WebMarkupContainer("schemaContainer");
+ schemaContainer.setOutputMarkupId(true);
+ schemaWrapContainer.add(schemaContainer);
+ setWindowClosedCallback(editSchemaWin, schemaContainer);
+
+ final String paginatorRowsKey = PAGINATOR_ROWS_KEYS.get(
+ new ImmutablePair<AttributableType, SchemaType>(attrType, schemaType));
+ pageRows = prefMan.getPaginatorRows(getRequest(), paginatorRowsKey);
+
+ List<IColumn> tableCols = getColumns(schemaContainer, editSchemaWin, attrType,
+ schemaType, COL_NAMES.get(schemaType));
+ final AjaxFallbackDefaultDataTable table = new AjaxFallbackDefaultDataTable("datatable", tableCols,
+ new SchemaProvider(attrType, schemaType), pageRows);
+ table.setOutputMarkupId(true);
+ schemaContainer.add(table);
+
+ schemaWrapContainer.add(getPaginatorForm(schemaContainer, table, "paginatorForm", this, paginatorRowsKey));
+
+ add(getCreateSchemaLink(editSchemaWin, attrType, schemaType, "createSchemaLink"));
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.java
new file mode 100644
index 0000000..12bfc2b
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.java
@@ -0,0 +1,111 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.rest.SecurityQuestionRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.SecurityQuestionTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+class SecurityQuestionModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = -6709838862698327502L;
+
+ @SpringBean
+ private SecurityQuestionRestClient restClient;
+
+ public SecurityQuestionModalPage(final PageReference pageRef, final ModalWindow window,
+ final SecurityQuestionTO securityQuestionTO, final boolean createFlag) {
+
+ final Form<SecurityQuestionTO> form =
+ new Form<SecurityQuestionTO>(FORM, new CompoundPropertyModel<SecurityQuestionTO>(securityQuestionTO));
+
+ final AjaxTextFieldPanel contentFieldPanel =
+ new AjaxTextFieldPanel("content", "content", new PropertyModel<String>(securityQuestionTO, "content"));
+ contentFieldPanel.setRequired(true);
+ form.add(contentFieldPanel);
+
+ AjaxButton submit = new IndicatingAjaxButton(APPLY, new Model<String>(getString(SUBMIT))) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ try {
+ if (createFlag) {
+ restClient.create(securityQuestionTO);
+ } else {
+ restClient.update(securityQuestionTO);
+ }
+ info(getString(Constants.OPERATION_SUCCEEDED));
+
+ Configuration callerPage = (Configuration) pageRef.getPage();
+ callerPage.setModalResult(true);
+
+ window.close(target);
+ } catch (SyncopeClientException scee) {
+ error(getString(Constants.ERROR) + ": " + scee.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+
+ final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+ };
+
+ cancel.setDefaultFormProcessing(false);
+
+ String allowedRoles = createFlag
+ ? xmlRolesReader.getEntitlement("SecurityQuestion", "create")
+ : xmlRolesReader.getEntitlement("SecurityQuestion", "update");
+ MetaDataRoleAuthorizationStrategy.authorize(submit, ENABLE, allowedRoles);
+
+ form.add(submit);
+ form.setDefaultButton(submit);
+
+ form.add(cancel);
+
+ add(form);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/StatusModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/StatusModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/StatusModalPage.java
new file mode 100644
index 0000000..cab0e04
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/StatusModalPage.java
@@ -0,0 +1,641 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.List;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.status.AbstractStatusBeanProvider;
+import org.apache.syncope.client.console.commons.status.ConnObjectWrapper;
+import org.apache.syncope.client.console.commons.status.Status;
+import org.apache.syncope.client.console.commons.status.StatusBean;
+import org.apache.syncope.client.console.commons.status.StatusUtils;
+import org.apache.syncope.client.console.panels.ActionDataTablePanel;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.common.lib.to.AbstractSubjectTO;
+import org.apache.syncope.common.lib.to.BulkActionResult;
+import org.apache.syncope.common.lib.to.ResourceTO;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.syncope.common.lib.types.ResourceAssociationActionType;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.ISortableDataProvider;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.markup.ComponentTag;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.form.PasswordTextField;
+import org.apache.wicket.markup.html.panel.Fragment;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.model.StringResourceModel;
+
+public class StatusModalPage<T extends AbstractSubjectTO> extends AbstractStatusModalPage {
+
+ private static final long serialVersionUID = -9148734710505211261L;
+
+ private final AbstractSubjectTO subjectTO;
+
+ private int rowsPerPage = 10;
+
+ final StatusUtils statusUtils;
+
+ final boolean statusOnly;
+
+ // --------------------------------
+ // password management fields ..
+ // --------------------------------
+ final ClearIndicatingAjaxButton cancel;
+
+ final WebMarkupContainer pwdMgt;
+
+ final Form<?> pwdMgtForm;
+
+ final AjaxCheckBoxPanel changepwd;
+
+ final PasswordTextField password;
+
+ final PasswordTextField confirm;
+ // --------------------------------
+
+ final PageReference pageRef;
+
+ final ModalWindow window;
+
+ final ActionDataTablePanel<StatusBean, String> table;
+
+ final List<IColumn<StatusBean, String>> columns;
+
+ public StatusModalPage(
+ final PageReference pageRef,
+ final ModalWindow window,
+ final AbstractSubjectTO attributableTO) {
+
+ this(pageRef, window, attributableTO, false);
+ }
+
+ public StatusModalPage(
+ final PageReference pageRef,
+ final ModalWindow window,
+ final AbstractSubjectTO subjectTO,
+ final boolean statusOnly) {
+
+ super();
+
+ this.pageRef = pageRef;
+ this.window = window;
+ this.statusOnly = statusOnly;
+ this.subjectTO = subjectTO;
+
+ statusUtils = new StatusUtils(subjectTO instanceof UserTO ? userRestClient : groupRestClient);
+
+ add(new Label("displayName", subjectTO.getKey() + " "
+ + (subjectTO instanceof UserTO ? ((UserTO) subjectTO).getUsername() : ((GroupTO) subjectTO).getName())));
+
+ columns = new ArrayList<>();
+ columns.add(new AbstractColumn<StatusBean, String>(
+ new StringResourceModel("resourceName", this, null, "Resource name"), "resourceName") {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public void populateItem(
+ final Item<ICellPopulator<StatusBean>> cellItem,
+ final String componentId,
+ final IModel<StatusBean> model) {
+
+ cellItem.add(new Label(componentId, model.getObject().getResourceName()) {
+
+ private static final long serialVersionUID = 8432079838783825801L;
+
+ @Override
+ protected void onComponentTag(final ComponentTag tag) {
+ if (model.getObject().isLinked()) {
+ super.onComponentTag(tag);
+ } else {
+ tag.put("style", "color: #DDDDDD");
+ }
+ }
+ });
+ }
+ });
+
+ columns.add(new PropertyColumn<StatusBean, String>(
+ new StringResourceModel("accountLink", this, null, "Account link"), "accountLink", "accountLink"));
+
+ columns.add(new AbstractColumn<StatusBean, String>(
+ new StringResourceModel("status", this, null, "")) {
+
+ private static final long serialVersionUID = -3503023501954863131L;
+
+ @Override
+ public String getCssClass() {
+ return "action";
+ }
+
+ @Override
+ public void populateItem(
+ final Item<ICellPopulator<StatusBean>> cellItem,
+ final String componentId,
+ final IModel<StatusBean> model) {
+
+ if (model.getObject().isLinked()) {
+ cellItem.add(statusUtils.getStatusImagePanel(componentId, model.getObject().
+ getStatus()));
+ } else {
+ cellItem.add(new Label(componentId, ""));
+ }
+ }
+ });
+
+ table = new ActionDataTablePanel<StatusBean, String>(
+ "resourceDatatable",
+ columns,
+ (ISortableDataProvider<StatusBean, String>) new AttributableStatusProvider(),
+ rowsPerPage,
+ pageRef) {
+
+ private static final long serialVersionUID = 6510391461033818316L;
+
+ @Override
+ public boolean isElementEnabled(final StatusBean element) {
+ return !statusOnly || element.getStatus() != Status.OBJECT_NOT_FOUND;
+ }
+ };
+ table.setOutputMarkupId(true);
+
+ final String pageId = subjectTO instanceof GroupTO ? "Groups" : "Users";
+
+ final Fragment pwdMgtFragment = new Fragment("pwdMgtFields", "pwdMgtFragment", this);
+ addOrReplace(pwdMgtFragment);
+
+ pwdMgt = new WebMarkupContainer("pwdMgt");
+ pwdMgtFragment.add(pwdMgt.setOutputMarkupId(true));
+
+ pwdMgtForm = new Form("pwdMgtForm");
+ pwdMgtForm.setVisible(false).setEnabled(false);
+ pwdMgt.add(pwdMgtForm);
+
+ password = new PasswordTextField("password", new Model<String>());
+ pwdMgtForm.add(password.setRequired(false).setEnabled(false));
+
+ confirm = new PasswordTextField("confirm", new Model<String>());
+ pwdMgtForm.add(confirm.setRequired(false).setEnabled(false));
+
+ changepwd = new AjaxCheckBoxPanel("changepwd", "changepwd", new Model<Boolean>(false));
+ pwdMgtForm.add(changepwd.setModelObject(false));
+ pwdMgtForm.add(new Label("changePwdLabel", new ResourceModel("changePwdLabel", "Password propagation")));
+
+ changepwd.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ password.setEnabled(changepwd.getModelObject());
+ confirm.setEnabled(changepwd.getModelObject());
+ target.add(pwdMgt);
+ }
+ });
+
+ cancel = new ClearIndicatingAjaxButton("cancel", new ResourceModel("cancel"), pageRef) {
+
+ private static final long serialVersionUID = -2341391430136818026L;
+
+ @Override
+ protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
+ // ignore
+ window.close(target);
+ }
+ }.feedbackPanelAutomaticReload(false);
+
+ pwdMgtForm.add(cancel);
+
+ final ClearIndicatingAjaxButton goon =
+ new ClearIndicatingAjaxButton("continue", new ResourceModel("continue"), pageRef) {
+
+ private static final long serialVersionUID = -2341391430136818027L;
+
+ @Override
+ protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
+ // none
+ }
+ };
+
+ pwdMgtForm.add(goon);
+
+ if (statusOnly) {
+ table.addAction(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ userRestClient.reactivate(
+ subjectTO.getETagValue(),
+ subjectTO.getKey(),
+ new ArrayList<>(table.getModelObject()));
+
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+
+ window.close(target);
+ } catch (Exception e) {
+ LOG.error("Error enabling resources", e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+ }, ActionLink.ActionType.REACTIVATE, pageId);
+
+ table.addAction(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ userRestClient.suspend(
+ subjectTO.getETagValue(),
+ subjectTO.getKey(),
+ new ArrayList<>(table.getModelObject()));
+
+ if (pageRef.getPage() instanceof BasePage) {
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+ }
+
+ window.close(target);
+ } catch (Exception e) {
+ LOG.error("Error disabling resources", e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+ }, ActionLink.ActionType.SUSPEND, pageId);
+ } else {
+ table.addAction(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ if (subjectTO instanceof UserTO) {
+ userRestClient.unlink(
+ subjectTO.getETagValue(),
+ subjectTO.getKey(),
+ new ArrayList<>(table.getModelObject()));
+ } else {
+ groupRestClient.unlink(
+ subjectTO.getETagValue(),
+ subjectTO.getKey(),
+ new ArrayList<>(table.getModelObject()));
+ }
+
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+ window.close(target);
+ } catch (Exception e) {
+ LOG.error("Error unlinking resources", e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+ }, ActionLink.ActionType.UNLINK, pageId);
+
+ table.addAction(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ if (subjectTO instanceof UserTO) {
+ userRestClient.link(
+ subjectTO.getETagValue(),
+ subjectTO.getKey(),
+ new ArrayList<>(table.getModelObject()));
+ } else {
+ groupRestClient.link(
+ subjectTO.getETagValue(),
+ subjectTO.getKey(),
+ new ArrayList<>(table.getModelObject()));
+ }
+
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+ window.close(target);
+ } catch (Exception e) {
+ LOG.error("Error linking resources", e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+ }, ActionLink.ActionType.LINK, pageId);
+
+ table.addAction(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ BulkActionResult bulkActionResult;
+ if (subjectTO instanceof UserTO) {
+ bulkActionResult = userRestClient.deprovision(
+ subjectTO.getETagValue(),
+ subjectTO.getKey(),
+ new ArrayList<>(table.getModelObject()));
+ } else {
+ bulkActionResult = groupRestClient.deprovision(
+ subjectTO.getETagValue(),
+ subjectTO.getKey(),
+ new ArrayList<>(table.getModelObject()));
+ }
+
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+ loadBulkActionResultPage(table.getModelObject(), bulkActionResult);
+ } catch (Exception e) {
+ LOG.error("Error de-provisioning user", e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+ }, ActionLink.ActionType.DEPROVISION, pageId);
+
+ table.addAction(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+
+ if (subjectTO instanceof UserTO) {
+ StatusModalPage.this.passwordManagement(
+ target, ResourceAssociationActionType.PROVISION, table.getModelObject());
+ } else {
+ try {
+ final BulkActionResult bulkActionResult = groupRestClient.provision(
+ subjectTO.getETagValue(),
+ subjectTO.getKey(),
+ new ArrayList<>(table.getModelObject()));
+
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+ loadBulkActionResultPage(table.getModelObject(), bulkActionResult);
+ } catch (Exception e) {
+ LOG.error("Error provisioning user", e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+ }
+ }.feedbackPanelAutomaticReload(!(subjectTO instanceof UserTO)), ActionLink.ActionType.PROVISION, pageId);
+
+ table.addAction(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ final BulkActionResult bulkActionResult;
+ if (subjectTO instanceof UserTO) {
+ bulkActionResult = userRestClient.unassign(
+ subjectTO.getETagValue(),
+ subjectTO.getKey(),
+ new ArrayList<>(table.getModelObject()));
+ } else {
+ bulkActionResult = groupRestClient.unassign(
+ subjectTO.getETagValue(),
+ subjectTO.getKey(),
+ new ArrayList<>(table.getModelObject()));
+ }
+
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+ loadBulkActionResultPage(table.getModelObject(), bulkActionResult);
+ } catch (Exception e) {
+ LOG.error("Error unassigning resources", e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+ }, ActionLink.ActionType.UNASSIGN, pageId);
+
+ table.addAction(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ if (subjectTO instanceof UserTO) {
+ StatusModalPage.this.passwordManagement(
+ target, ResourceAssociationActionType.ASSIGN, table.getModelObject());
+ } else {
+ try {
+ final BulkActionResult bulkActionResult = groupRestClient.assign(
+ subjectTO.getETagValue(),
+ subjectTO.getKey(),
+ new ArrayList<>(table.getModelObject()));
+
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+ loadBulkActionResultPage(table.getModelObject(), bulkActionResult);
+ } catch (Exception e) {
+ LOG.error("Error assigning resources", e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+ }
+ }.feedbackPanelAutomaticReload(!(subjectTO instanceof UserTO)), ActionLink.ActionType.ASSIGN, pageId);
+ }
+
+ table.addCancelButton(window);
+ add(table);
+ }
+
+ private class AttributableStatusProvider extends AbstractStatusBeanProvider {
+
+ private static final long serialVersionUID = 4586969457669796621L;
+
+ public AttributableStatusProvider() {
+ super(statusOnly ? "resourceName" : "accountLink");
+ }
+
+ @SuppressWarnings("unchecked")
+ @Override
+ public List<StatusBean> getStatusBeans() {
+ final List<String> resources = new ArrayList<>();
+ for (ResourceTO resourceTO : resourceRestClient.getAll()) {
+ resources.add(resourceTO.getKey());
+ }
+
+ final List<ConnObjectWrapper> connObjects = statusUtils.getConnectorObjects(subjectTO);
+
+ final List<StatusBean> statusBeans = new ArrayList<StatusBean>(connObjects.size() + 1);
+
+ for (ConnObjectWrapper entry : connObjects) {
+ final StatusBean statusBean = statusUtils.getStatusBean(subjectTO,
+ entry.getResourceName(),
+ entry.getConnObjectTO(),
+ subjectTO instanceof GroupTO);
+
+ statusBeans.add(statusBean);
+ resources.remove(entry.getResourceName());
+ }
+
+ if (statusOnly) {
+ final StatusBean syncope = new StatusBean(subjectTO, "Syncope");
+
+ syncope.setAccountLink(((UserTO) subjectTO).getUsername());
+
+ Status syncopeStatus = Status.UNDEFINED;
+ if (((UserTO) subjectTO).getStatus() != null) {
+ try {
+ syncopeStatus = Status.valueOf(((UserTO) subjectTO).getStatus().toUpperCase());
+ } catch (IllegalArgumentException e) {
+ LOG.warn("Unexpected status found: {}", ((UserTO) subjectTO).getStatus(), e);
+ }
+ }
+ syncope.setStatus(syncopeStatus);
+
+ statusBeans.add(syncope);
+ } else {
+ for (String resource : resources) {
+ final StatusBean statusBean = statusUtils.getStatusBean(subjectTO,
+ resource,
+ null,
+ subjectTO instanceof GroupTO);
+
+ statusBean.setLinked(false);
+ statusBeans.add(statusBean);
+ }
+ }
+
+ return statusBeans;
+ }
+ }
+
+ private void passwordManagement(
+ final AjaxRequestTarget target,
+ final ResourceAssociationActionType type,
+ final Collection<StatusBean> selection) {
+
+ final ClearIndicatingAjaxButton goon =
+ new ClearIndicatingAjaxButton("continue", new ResourceModel("continue", "Continue"), pageRef) {
+
+ private static final long serialVersionUID = -2341391430136818027L;
+
+ @Override
+ protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
+ try {
+ if (StringUtils.isNotBlank(password.getModelObject())
+ && !password.getModelObject().equals(confirm.getModelObject())) {
+ throw new Exception(getString("passwordMismatch"));
+ }
+
+ final BulkActionResult bulkActionResult;
+ switch (type) {
+ case ASSIGN:
+ bulkActionResult = userRestClient.assign(
+ subjectTO.getETagValue(),
+ subjectTO.getKey(),
+ new ArrayList<>(selection),
+ changepwd.getModelObject(),
+ password.getModelObject());
+ break;
+ case PROVISION:
+ bulkActionResult = userRestClient.provision(
+ subjectTO.getETagValue(),
+ subjectTO.getKey(),
+ new ArrayList<>(selection),
+ changepwd.getModelObject(),
+ password.getModelObject());
+ break;
+ default:
+ bulkActionResult = null;
+ // ignore
+ }
+
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+
+ if (bulkActionResult != null) {
+ loadBulkActionResultPage(selection, bulkActionResult);
+ } else {
+
+ target.add(((BasePage) pageRef.getPage()).getFeedbackPanel());
+ window.close(target);
+ }
+ } catch (Exception e) {
+ LOG.error("Error provisioning resources", e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+ }.feedbackPanelAutomaticReload(false);
+
+ pwdMgtForm.addOrReplace(goon);
+
+ table.setVisible(false);
+ pwdMgtForm.setVisible(true).setEnabled(true);
+
+ target.add(table);
+ target.add(pwdMgt);
+ }
+
+ private void loadBulkActionResultPage(
+ final Collection<StatusBean> selection, final BulkActionResult bulkActionResult) {
+ final List<String> resources = new ArrayList<String>(selection.size());
+ for (StatusBean statusBean : selection) {
+ resources.add(statusBean.getResourceName());
+ }
+
+ final List<ConnObjectWrapper> connObjects =
+ statusUtils.getConnectorObjects(Collections.singletonList(subjectTO), resources);
+
+ final List<StatusBean> statusBeans = new ArrayList<StatusBean>(connObjects.size());
+
+ for (ConnObjectWrapper entry : connObjects) {
+ final StatusBean statusBean = statusUtils.getStatusBean(subjectTO,
+ entry.getResourceName(),
+ entry.getConnObjectTO(),
+ subjectTO instanceof GroupTO);
+
+ statusBeans.add(statusBean);
+ }
+
+ setResponsePage(new BulkActionResultModalPage<StatusBean, String>(
+ window,
+ statusBeans,
+ columns,
+ bulkActionResult,
+ "resourceName"));
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/SyncTaskModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/SyncTaskModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/SyncTaskModalPage.java
new file mode 100644
index 0000000..544f670
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/SyncTaskModalPage.java
@@ -0,0 +1,73 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.List;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.common.lib.to.SchedTaskTO;
+import org.apache.syncope.common.lib.to.SyncTaskTO;
+import org.apache.syncope.common.lib.types.MatchingRule;
+import org.apache.syncope.common.lib.types.UnmatchingRule;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.model.PropertyModel;
+
+/**
+ * Modal window with Sync Task form.
+ */
+public class SyncTaskModalPage extends AbstractSyncTaskModalPage {
+
+ private static final long serialVersionUID = 2148403203517274669L;
+
+ public SyncTaskModalPage(final ModalWindow window, final SyncTaskTO taskTO, final PageReference pageRef) {
+
+ super(window, taskTO, pageRef);
+
+ // set default Matching rule
+ ((DropDownChoice) matchingRule.getField()).setDefaultModelObject(taskTO.getMatchingRule() == null
+ ? MatchingRule.UPDATE
+ : taskTO.getMatchingRule());
+ profile.add(matchingRule);
+
+ // set default Unmatching rule
+ ((DropDownChoice) unmatchingRule.getField()).setDefaultModelObject(taskTO.getUnmatchingRule() == null
+ ? UnmatchingRule.PROVISION
+ : taskTO.getUnmatchingRule());
+ profile.add(unmatchingRule);
+
+ final AjaxCheckBoxPanel fullReconciliation = new AjaxCheckBoxPanel("fullReconciliation",
+ getString("fullReconciliation"), new PropertyModel<Boolean>(taskTO, "fullReconciliation"));
+ profile.add(fullReconciliation);
+ }
+
+ @Override
+ protected List<String> getSyncActions() {
+ return taskRestClient.getSyncActionsClasses();
+ }
+
+ @Override
+ public void submitAction(final SchedTaskTO taskTO) {
+ if (taskTO.getKey() > 0) {
+ taskRestClient.updateSyncTask((SyncTaskTO) taskTO);
+ } else {
+ taskRestClient.createSyncTask((SyncTaskTO) taskTO);
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/TaskModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/TaskModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/TaskModalPage.java
new file mode 100644
index 0000000..c251d87
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/TaskModalPage.java
@@ -0,0 +1,253 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.AbstractTaskTO;
+import org.apache.syncope.common.lib.to.NotificationTaskTO;
+import org.apache.syncope.common.lib.to.PropagationTaskTO;
+import org.apache.syncope.common.lib.to.SchedTaskTO;
+import org.apache.syncope.common.lib.to.SyncTaskTO;
+import org.apache.syncope.common.lib.to.TaskExecTO;
+import org.apache.wicket.Component;
+import org.apache.wicket.Page;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
+import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.AbstractReadOnlyModel;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.springframework.util.StringUtils;
+
+/**
+ * Modal window with Task form (to stop and start execution).
+ */
+public abstract class TaskModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = -4110576026663173545L;
+
+ protected WebMarkupContainer profile;
+
+ protected WebMarkupContainer executions;
+
+ protected Form<AbstractTaskTO> form;
+
+ public TaskModalPage(final AbstractTaskTO taskTO) {
+ final ModalWindow taskExecMessageWin = new ModalWindow("taskExecMessageWin");
+ taskExecMessageWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ taskExecMessageWin.setCookieName("task-exec-message-win-modal");
+ add(taskExecMessageWin);
+
+ form = new Form<>(FORM);
+ form.setModel(new CompoundPropertyModel<>(taskTO));
+ add(form);
+
+ profile = new WebMarkupContainer("profile");
+ profile.setOutputMarkupId(true);
+ form.add(profile);
+
+ executions = new WebMarkupContainer("executionContainer");
+ executions.setOutputMarkupId(true);
+ form.add(executions);
+
+ final Label idLabel = new Label("idLabel", new ResourceModel("key"));
+ profile.add(idLabel);
+
+ final AjaxTextFieldPanel id =
+ new AjaxTextFieldPanel("key", getString("key"), new PropertyModel<String>(taskTO, "key"));
+
+ id.setEnabled(false);
+ profile.add(id);
+
+ final List<IColumn<TaskExecTO, String>> columns = new ArrayList<>();
+
+ final int paginatorRows = 10;
+
+ columns.add(new PropertyColumn<TaskExecTO, String>(new ResourceModel("key"), "key", "key"));
+ columns.add(new DatePropertyColumn<TaskExecTO>(new ResourceModel("startDate"), "startDate", "startDate"));
+ columns.add(new DatePropertyColumn<TaskExecTO>(new ResourceModel("endDate"), "endDate", "endDate"));
+ columns.add(new PropertyColumn<TaskExecTO, String>(new ResourceModel("status"), "status", "status"));
+ columns.add(new ActionColumn<TaskExecTO, String>(new ResourceModel("actions", "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public ActionLinksPanel getActions(final String componentId, final IModel<TaskExecTO> model) {
+
+ final TaskExecTO taskExecutionTO = model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ taskExecMessageWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ExecMessageModalPage(model.getObject().getMessage());
+ }
+ });
+ taskExecMessageWin.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, TASKS, StringUtils.hasText(model.getObject().getMessage()));
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ taskRestClient.deleteExecution(taskExecutionTO.getKey());
+
+ taskTO.getExecutions().remove(taskExecutionTO);
+
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+
+ feedbackPanel.refresh(target);
+ target.add(executions);
+ }
+ }, ActionLink.ActionType.DELETE, TASKS);
+
+ return panel;
+ }
+
+ @Override
+ public Component getHeader(final String componentId) {
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), getPageReference());
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ if (target != null) {
+ final AjaxFallbackDefaultDataTable<TaskExecTO, String> currentTable =
+ new AjaxFallbackDefaultDataTable<TaskExecTO, String>("executionsTable", columns,
+ new TaskExecutionsProvider(getCurrentTaskExecution(taskTO)), paginatorRows);
+ currentTable.setOutputMarkupId(true);
+ target.add(currentTable);
+ executions.addOrReplace(currentTable);
+ }
+ }
+ }, ActionLink.ActionType.RELOAD, TASKS, "list");
+
+ return panel;
+ }
+ });
+
+ final AjaxFallbackDefaultDataTable<TaskExecTO, String> table =
+ new AjaxFallbackDefaultDataTable<TaskExecTO, String>("executionsTable", columns,
+ new TaskExecutionsProvider(getCurrentTaskExecution(taskTO)), paginatorRows);
+
+ executions.add(table);
+ }
+
+ protected static class TaskExecutionsProvider extends SortableDataProvider<TaskExecTO, String> {
+
+ private static final long serialVersionUID = 8943636537120648961L;
+
+ private SortableDataProviderComparator<TaskExecTO> comparator;
+
+ private AbstractTaskTO taskTO;
+
+ public TaskExecutionsProvider(final AbstractTaskTO taskTO) {
+ //Default sorting
+ this.taskTO = taskTO;
+ setSort("startDate", SortOrder.DESCENDING);
+ comparator = new SortableDataProviderComparator<TaskExecTO>(this);
+ }
+
+ @Override
+ public Iterator<TaskExecTO> iterator(final long first, final long count) {
+
+ List<TaskExecTO> list = taskTO.getExecutions();
+
+ Collections.sort(list, comparator);
+
+ return list.subList((int) first, (int) first + (int) count).iterator();
+ }
+
+ @Override
+ public long size() {
+ return taskTO.getExecutions().size();
+ }
+
+ @Override
+ public IModel<TaskExecTO> model(final TaskExecTO taskExecution) {
+
+ return new AbstractReadOnlyModel<TaskExecTO>() {
+
+ private static final long serialVersionUID = 7485475149862342421L;
+
+ @Override
+ public TaskExecTO getObject() {
+ return taskExecution;
+ }
+ };
+ }
+ }
+
+ private AbstractTaskTO getCurrentTaskExecution(final AbstractTaskTO taskTO) {
+ final AbstractTaskTO currentTask = taskTO.getKey() == 0
+ ? taskTO
+ : taskTO instanceof PropagationTaskTO
+ ? taskRestClient.readPropagationTask(taskTO.getKey())
+ : taskTO instanceof NotificationTaskTO
+ ? taskRestClient.readNotificationTask(taskTO.getKey())
+ : taskTO instanceof SyncTaskTO
+ ? taskRestClient.readSchedTask(SyncTaskTO.class, taskTO.getKey())
+ : taskRestClient.readSchedTask(SchedTaskTO.class, taskTO.getKey());
+
+ taskTO.getExecutions().clear();
+ taskTO.getExecutions().addAll(currentTask.getExecutions());
+ return taskTO;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Tasks.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Tasks.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Tasks.java
new file mode 100644
index 0000000..296c365
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Tasks.java
@@ -0,0 +1,230 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.Comparator;
+import java.util.Iterator;
+import java.util.List;
+import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
+import org.apache.syncope.client.console.panels.AjaxDataTablePanel;
+import org.apache.syncope.client.console.panels.NotificationTasks;
+import org.apache.syncope.client.console.panels.PropagationTasks;
+import org.apache.syncope.client.console.panels.PushTasksPanel;
+import org.apache.syncope.client.console.panels.SchedTasks;
+import org.apache.syncope.client.console.panels.SyncTasksPanel;
+import org.apache.syncope.client.console.rest.BaseRestClient;
+import org.apache.syncope.client.console.rest.TaskRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.common.lib.to.AbstractTaskTO;
+import org.apache.syncope.common.lib.to.SchedTaskTO;
+import org.apache.syncope.common.lib.to.TaskExecTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.ISortableDataProvider;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.model.AbstractReadOnlyModel;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.IModel;
+
+public class Tasks extends BasePage {
+
+ private static final long serialVersionUID = 5289215853622289061L;
+
+ public Tasks() {
+ super();
+
+ add(new PropagationTasks("propagation", getPageReference()));
+ add(new NotificationTasks("notification", getPageReference()));
+ add(new SchedTasks("sched", getPageReference()));
+ add(new SyncTasksPanel("sync", getPageReference()));
+ add(new PushTasksPanel("push", getPageReference()));
+
+ getPageReference();
+ }
+
+ @Override
+ public void setWindowClosedCallback(final ModalWindow window, final WebMarkupContainer container) {
+
+ super.setWindowClosedCallback(window, container);
+ }
+
+ public static class TaskExecutionsProvider extends SortableDataProvider<TaskExecTO, String> {
+
+ private static final long serialVersionUID = -5401263348984206145L;
+
+ private SortableDataProviderComparator<TaskExecTO> comparator;
+
+ private AbstractTaskTO taskTO;
+
+ public TaskExecutionsProvider(final AbstractTaskTO taskTO) {
+ super();
+
+ //Default sorting
+ this.taskTO = taskTO;
+ setSort("startDate", SortOrder.DESCENDING);
+ comparator = new SortableDataProviderComparator<TaskExecTO>(this);
+ }
+
+ @Override
+ public Iterator<TaskExecTO> iterator(final long first, final long count) {
+
+ List<TaskExecTO> list = getTaskDB();
+
+ Collections.sort(list, comparator);
+
+ return list.subList((int) first, (int) first + (int) count).iterator();
+ }
+
+ @Override
+ public long size() {
+ return getTaskDB().size();
+ }
+
+ @Override
+ public IModel<TaskExecTO> model(final TaskExecTO taskExecution) {
+
+ return new AbstractReadOnlyModel<TaskExecTO>() {
+
+ private static final long serialVersionUID = 7485475149862342421L;
+
+ @Override
+ public TaskExecTO getObject() {
+ return taskExecution;
+ }
+ };
+ }
+
+ public List<TaskExecTO> getTaskDB() {
+ return taskTO.getExecutions();
+ }
+ }
+
+ public static class TasksProvider<T extends AbstractTaskTO> extends SortableDataProvider<T, String> {
+
+ private static final long serialVersionUID = -20112718133295756L;
+
+ private SortableDataProviderComparator<T> comparator;
+
+ private TaskRestClient restClient;
+
+ private int paginatorRows;
+
+ private String id;
+
+ private Class<T> reference;
+
+ public TasksProvider(
+ final TaskRestClient restClient, final int paginatorRows, final String id, final Class<T> reference) {
+
+ super();
+
+ //Default sorting
+ setSort("key", SortOrder.DESCENDING);
+ comparator = new SortableDataProviderComparator<>(this);
+ this.paginatorRows = paginatorRows;
+ this.restClient = restClient;
+ this.id = id;
+ this.reference = reference;
+ }
+
+ @Override
+ public Iterator<T> iterator(final long first, final long count) {
+ final List<T> tasks = new ArrayList<>();
+
+ final int page = ((int) first / paginatorRows);
+
+ for (T task : restClient.list(reference, (page < 0 ? 0 : page) + 1, paginatorRows, getSort())) {
+ if (task instanceof SchedTaskTO && ((SchedTaskTO) task).getLastExec() == null
+ && task.getExecutions() != null && !task.getExecutions().isEmpty()) {
+
+ Collections.sort(task.getExecutions(), new Comparator<TaskExecTO>() {
+
+ @Override
+ public int compare(final TaskExecTO left, final TaskExecTO right) {
+ return left.getStartDate().compareTo(right.getStartDate());
+ }
+ });
+
+ ((SchedTaskTO) task).setLastExec(task.getExecutions().get(task.getExecutions().size() - 1).
+ getStartDate());
+ }
+ tasks.add(task);
+ }
+
+ Collections.sort(tasks, comparator);
+ return tasks.iterator();
+ }
+
+ @Override
+ public long size() {
+ return restClient.count(id);
+ }
+
+ @Override
+ public IModel<T> model(final T object) {
+ return new CompoundPropertyModel<>(object);
+ }
+ }
+
+ /**
+ * Update task table.
+ *
+ * @param columns columns.
+ * @param dataProvider data provider.
+ * @param container container.
+ * @param currentPage current page index.
+ * @param pageRef page reference
+ * @param restClient syncope base rest client
+ * @return data table.
+ */
+ public static AjaxDataTablePanel<AbstractTaskTO, String> updateTaskTable(
+ final List<IColumn<AbstractTaskTO, String>> columns,
+ final TasksProvider<? extends AbstractTaskTO> dataProvider,
+ final WebMarkupContainer container,
+ final int currentPage,
+ final PageReference pageRef,
+ final BaseRestClient restClient) {
+
+ @SuppressWarnings("unchecked")
+ final AjaxDataTablePanel<AbstractTaskTO, String> table = new AjaxDataTablePanel<>(
+ "datatable",
+ columns,
+ (ISortableDataProvider<AbstractTaskTO, String>) dataProvider,
+ dataProvider.paginatorRows,
+ Arrays.asList(new ActionLink.ActionType[] {
+ ActionLink.ActionType.DELETE, ActionLink.ActionType.DRYRUN, ActionLink.ActionType.EXECUTE }),
+ restClient,
+ "key",
+ TASKS,
+ pageRef);
+
+ table.setCurrentPage(currentPage);
+ table.setOutputMarkupId(true);
+
+ container.addOrReplace(table);
+
+ return table;
+ }
+}
[13/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourceConnConfPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourceConnConfPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourceConnConfPanel.java
new file mode 100644
index 0000000..b3e63c5
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourceConnConfPanel.java
@@ -0,0 +1,187 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import org.apache.syncope.client.console.pages.BaseModalPage;
+import org.apache.syncope.client.console.pages.ResourceModalPage.ResourceEvent;
+import org.apache.syncope.client.console.panels.ResourceDetailsPanel.DetailsModEvent;
+import org.apache.syncope.client.console.rest.ConnectorRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel.MultiValueSelectorEvent;
+import org.apache.syncope.client.console.wicket.markup.html.list.ConnConfPropertyListView;
+import org.apache.syncope.common.lib.to.ResourceTO;
+import org.apache.syncope.common.lib.types.ConnConfProperty;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.event.Broadcast;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class ResourceConnConfPanel extends Panel {
+
+ private static final long serialVersionUID = -7982691107029848579L;
+
+ @SpringBean
+ private ConnectorRestClient restClient;
+
+ private final ResourceTO resourceTO;
+
+ private final boolean createFlag;
+
+ private List<ConnConfProperty> connConfProperties;
+
+ private WebMarkupContainer connConfPropContainer;
+
+ private AjaxButton check;
+
+ public ResourceConnConfPanel(final String id, final ResourceTO resourceTO, final boolean createFlag) {
+ super(id);
+ setOutputMarkupId(true);
+
+ this.createFlag = createFlag;
+ this.resourceTO = resourceTO;
+
+ connConfProperties = getConnConfProperties();
+
+ connConfPropContainer = new WebMarkupContainer("connectorPropertiesContainer");
+ connConfPropContainer.setOutputMarkupId(true);
+ add(connConfPropContainer);
+
+ /*
+ * the list of overridable connector properties
+ */
+ final ListView<ConnConfProperty> connPropView = new ConnConfPropertyListView("connectorProperties",
+ new PropertyModel<List<ConnConfProperty>>(this, "connConfProperties"),
+ false, resourceTO.getConnConfProperties());
+ connPropView.setOutputMarkupId(true);
+ connConfPropContainer.add(connPropView);
+
+ check = new IndicatingAjaxButton("check", new ResourceModel("check")) {
+
+ private static final long serialVersionUID = -4199438518229098169L;
+
+ @Override
+ public void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ final ResourceTO resourceTO = (ResourceTO) form.getModelObject();
+
+ if (restClient.check(resourceTO)) {
+ info(getString("success_connection"));
+ } else {
+ error(getString("error_connection"));
+ }
+
+ ((BaseModalPage) getPage()).getFeedbackPanel().refresh(target);
+ }
+ };
+
+ check.setEnabled(!connConfProperties.isEmpty());
+ connConfPropContainer.add(check);
+ }
+
+ /**
+ * Get overridable properties.
+ *
+ * @return overridable properties.
+ */
+ private List<ConnConfProperty> getConnConfProperties() {
+ final List<ConnConfProperty> props = new ArrayList<ConnConfProperty>();
+ final Long connectorId = resourceTO.getConnectorId();
+ if (connectorId != null && connectorId > 0) {
+ for (ConnConfProperty property : restClient.getConnectorProperties(connectorId)) {
+ if (property.isOverridable()) {
+ props.add(property);
+ }
+ }
+ }
+ if (createFlag || resourceTO.getConnConfProperties().isEmpty()) {
+ resourceTO.getConnConfProperties().clear();
+ } else {
+ Map<String, ConnConfProperty> valuedProps = new HashMap<String, ConnConfProperty>();
+ for (ConnConfProperty prop : resourceTO.getConnConfProperties()) {
+ valuedProps.put(prop.getSchema().getName(), prop);
+ }
+
+ for (int i = 0; i < props.size(); i++) {
+ if (valuedProps.containsKey(props.get(i).getSchema().getName())) {
+ props.set(i, valuedProps.get(props.get(i).getSchema().getName()));
+ }
+ }
+ }
+
+ // re-order properties
+ Collections.sort(props);
+
+ return props;
+ }
+
+ @Override
+ public void onEvent(final IEvent<?> event) {
+ AjaxRequestTarget target = null;
+ if (event.getPayload() instanceof DetailsModEvent) {
+ // connector change: update properties and forward event
+ target = ((ResourceEvent) event.getPayload()).getTarget();
+
+ connConfProperties = getConnConfProperties();
+ check.setEnabled(!connConfProperties.isEmpty());
+
+ target.add(connConfPropContainer);
+ } else if (event.getPayload() instanceof MultiValueSelectorEvent) {
+ // multi value connector property change: forward event
+ target = ((MultiValueSelectorEvent) event.getPayload()).getTarget();
+ }
+
+ if (target != null) {
+ send(getPage(), Broadcast.BREADTH, new ConnConfModEvent(target, connConfProperties));
+ }
+ }
+
+ /**
+ * Connector configuration properties modification event.
+ */
+ public static class ConnConfModEvent extends ResourceEvent {
+
+ private List<ConnConfProperty> configuration;
+
+ /**
+ * Constructor.
+ *
+ * @param target request target.
+ * @param configuration connector configuration properties.
+ */
+ public ConnConfModEvent(final AjaxRequestTarget target, final List<ConnConfProperty> configuration) {
+ super(target);
+ this.configuration = configuration;
+ }
+
+ public List<ConnConfProperty> getConfiguration() {
+ return configuration;
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourceDetailsPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourceDetailsPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourceDetailsPanel.java
new file mode 100644
index 0000000..3bff23f
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourceDetailsPanel.java
@@ -0,0 +1,306 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.Arrays;
+import java.util.List;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.pages.ResourceModalPage.ResourceEvent;
+import org.apache.syncope.client.console.rest.ConnectorRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.SpinnerFieldPanel;
+import org.apache.syncope.common.lib.to.ConnInstanceTO;
+import org.apache.syncope.common.lib.to.ResourceTO;
+import org.apache.syncope.common.lib.types.PropagationMode;
+import org.apache.syncope.common.lib.types.TraceLevel;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.event.Broadcast;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.ChoiceRenderer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class ResourceDetailsPanel extends Panel {
+
+ private static final long serialVersionUID = -7982691107029848579L;
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(ResourceDetailsPanel.class);
+
+ @SpringBean
+ private ConnectorRestClient connRestClient;
+
+ private ConnInstanceTO connInstanceTO;
+
+ public ResourceDetailsPanel(final String id, final ResourceTO resourceTO, final List<String> actionClassNames,
+ final boolean createFlag) {
+
+ super(id);
+ setOutputMarkupId(true);
+
+ final AjaxTextFieldPanel resourceName = new AjaxTextFieldPanel("name", new ResourceModel("name", "name").
+ getObject(), new PropertyModel<String>(resourceTO, "key"));
+
+ resourceName.setEnabled(createFlag);
+ resourceName.addRequiredLabel();
+ add(resourceName);
+
+ final AjaxCheckBoxPanel enforceMandatoryCondition = new AjaxCheckBoxPanel("enforceMandatoryCondition",
+ new ResourceModel("enforceMandatoryCondition", "enforceMandatoryCondition").getObject(),
+ new PropertyModel<Boolean>(resourceTO, "enforceMandatoryCondition"));
+ add(enforceMandatoryCondition);
+
+ final AjaxCheckBoxPanel propagationPrimary = new AjaxCheckBoxPanel("propagationPrimary", new ResourceModel(
+ "propagationPrimary", "propagationPrimary").getObject(), new PropertyModel<Boolean>(resourceTO,
+ "propagationPrimary"));
+ add(propagationPrimary);
+
+ final SpinnerFieldPanel<Integer> propagationPriority =
+ new SpinnerFieldPanel<>("propagationPriority", "propagationPriority", Integer.class,
+ new PropertyModel<Integer>(resourceTO, "propagationPriority"), null, null);
+ add(propagationPriority);
+
+ final AjaxDropDownChoicePanel<PropagationMode> propagationMode = new AjaxDropDownChoicePanel<>(
+ "propagationMode", new ResourceModel("propagationMode", "propagationMode").getObject(),
+ new PropertyModel<PropagationMode>(resourceTO, "propagationMode"));
+ propagationMode.setChoices(Arrays.asList(PropagationMode.values()));
+ add(propagationMode);
+
+ final AjaxCheckBoxPanel randomPwdIfNotProvided = new AjaxCheckBoxPanel("randomPwdIfNotProvided",
+ new ResourceModel("randomPwdIfNotProvided", "randomPwdIfNotProvided").getObject(),
+ new PropertyModel<Boolean>(resourceTO, "randomPwdIfNotProvided"));
+ add(randomPwdIfNotProvided);
+
+ final WebMarkupContainer propagationActionsClassNames = new WebMarkupContainer("propagationActionsClassNames");
+ propagationActionsClassNames.setOutputMarkupId(true);
+ add(propagationActionsClassNames);
+
+ final AjaxLink<Void> first = new IndicatingAjaxLink<Void>("first") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ resourceTO.getPropagationActionsClassNames().add(StringUtils.EMPTY);
+ setVisible(false);
+ target.add(propagationActionsClassNames);
+ }
+ };
+ first.setOutputMarkupPlaceholderTag(true);
+ first.setVisible(resourceTO.getPropagationActionsClassNames().isEmpty());
+ propagationActionsClassNames.add(first);
+
+ final ListView<String> actionsClasses = new ListView<String>("actionsClasses",
+ new PropertyModel<List<String>>(resourceTO, "propagationActionsClassNames")) {
+
+ private static final long serialVersionUID = 9101744072914090143L;
+
+ @Override
+ protected void populateItem(final ListItem<String> item) {
+ final String className = item.getModelObject();
+
+ final DropDownChoice<String> actionsClass = new DropDownChoice<>(
+ "actionsClass", new Model<>(className), actionClassNames);
+ actionsClass.setNullValid(true);
+ actionsClass.setRequired(true);
+ actionsClass.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_BLUR) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ resourceTO.getPropagationActionsClassNames().
+ set(item.getIndex(), actionsClass.getModelObject());
+ }
+ });
+ actionsClass.setRequired(true);
+ actionsClass.setOutputMarkupId(true);
+ actionsClass.setRequired(true);
+ item.add(actionsClass);
+
+ AjaxLink<Void> minus = new IndicatingAjaxLink<Void>("drop") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ resourceTO.getPropagationActionsClassNames().remove(className);
+ first.setVisible(resourceTO.getPropagationActionsClassNames().isEmpty());
+ target.add(propagationActionsClassNames);
+ }
+ };
+ item.add(minus);
+
+ final AjaxLink<Void> plus = new IndicatingAjaxLink<Void>("add") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ resourceTO.getPropagationActionsClassNames().add(StringUtils.EMPTY);
+ target.add(propagationActionsClassNames);
+ }
+ };
+ plus.setOutputMarkupPlaceholderTag(true);
+ plus.setVisible(item.getIndex() == resourceTO.getPropagationActionsClassNames().size() - 1);
+ item.add(plus);
+ }
+ };
+ propagationActionsClassNames.add(actionsClasses);
+
+ final AjaxDropDownChoicePanel<TraceLevel> createTraceLevel = new AjaxDropDownChoicePanel<>(
+ "createTraceLevel", new ResourceModel("createTraceLevel", "createTraceLevel").getObject(),
+ new PropertyModel<TraceLevel>(resourceTO, "createTraceLevel"));
+ createTraceLevel.setChoices(Arrays.asList(TraceLevel.values()));
+ add(createTraceLevel);
+
+ final AjaxDropDownChoicePanel<TraceLevel> updateTraceLevel = new AjaxDropDownChoicePanel<>(
+ "updateTraceLevel", new ResourceModel("updateTraceLevel", "updateTraceLevel").getObject(),
+ new PropertyModel<TraceLevel>(resourceTO, "updateTraceLevel"));
+ updateTraceLevel.setChoices(Arrays.asList(TraceLevel.values()));
+ add(updateTraceLevel);
+
+ final AjaxDropDownChoicePanel<TraceLevel> deleteTraceLevel = new AjaxDropDownChoicePanel<>(
+ "deleteTraceLevel", new ResourceModel("deleteTraceLevel", "deleteTraceLevel").getObject(),
+ new PropertyModel<TraceLevel>(resourceTO, "deleteTraceLevel"));
+ deleteTraceLevel.setChoices(Arrays.asList(TraceLevel.values()));
+ add(deleteTraceLevel);
+
+ final AjaxDropDownChoicePanel<TraceLevel> syncTraceLevel = new AjaxDropDownChoicePanel<>(
+ "syncTraceLevel", new ResourceModel("syncTraceLevel", "syncTraceLevel").getObject(),
+ new PropertyModel<TraceLevel>(resourceTO, "syncTraceLevel"));
+ syncTraceLevel.setChoices(Arrays.asList(TraceLevel.values()));
+ add(syncTraceLevel);
+
+ final IModel<List<ConnInstanceTO>> connectors = new LoadableDetachableModel<List<ConnInstanceTO>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<ConnInstanceTO> load() {
+ return connRestClient.getAllConnectors();
+ }
+ };
+
+ connInstanceTO = getConectorInstanceTO(connectors.getObject(), resourceTO);
+
+ final AjaxDropDownChoicePanel<ConnInstanceTO> conn = new AjaxDropDownChoicePanel<>("connector",
+ new ResourceModel("connector", "connector").getObject(),
+ new PropertyModel<ConnInstanceTO>(this, "connInstanceTO"));
+ conn.setChoices(connectors.getObject());
+ conn.setChoiceRenderer(new ChoiceRenderer("displayName", "key"));
+
+ conn.getField().setModel(new IModel<ConnInstanceTO>() {
+
+ private static final long serialVersionUID = -4202872830392400310L;
+
+ @Override
+ public ConnInstanceTO getObject() {
+ return connInstanceTO;
+ }
+
+ @Override
+ public void setObject(final ConnInstanceTO connector) {
+ resourceTO.setConnectorId(connector.getKey());
+ connInstanceTO = connector;
+ }
+
+ @Override
+ public void detach() {
+ }
+ });
+
+ conn.addRequiredLabel();
+ conn.setEnabled(createFlag);
+
+ conn.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ send(getPage(), Broadcast.BREADTH, new DetailsModEvent(target));
+ }
+ });
+
+ add(conn);
+ }
+
+ /**
+ * Get the connetorTO linked to the resource.
+ *
+ * @param connectorTOs list of all connectors.
+ * @param resourceTO resource.
+ * @return selected connector instance: in case of no connectors available, null; in case of new resource
+ * specification, the first on connector available
+ */
+ private ConnInstanceTO getConectorInstanceTO(final List<ConnInstanceTO> connectorTOs, final ResourceTO resourceTO) {
+ if (connectorTOs.isEmpty()) {
+ resourceTO.setConnectorId(null);
+ return null;
+ } else {
+ // use the first element as default
+ ConnInstanceTO res = connectorTOs.get(0);
+
+ for (ConnInstanceTO to : connectorTOs) {
+ if (Long.valueOf(to.getKey()).equals(resourceTO.getConnectorId())) {
+ res = to;
+ }
+ }
+
+ // in case of no match
+ resourceTO.setConnectorId(res.getKey());
+
+ return res;
+ }
+ }
+
+ /**
+ * Connector instance modification event.
+ */
+ public static class DetailsModEvent extends ResourceEvent {
+
+ /**
+ * Constructor.
+ *
+ * @param target request target.
+ */
+ public DetailsModEvent(final AjaxRequestTarget target) {
+ super(target);
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourceMappingPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourceMappingPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourceMappingPanel.java
new file mode 100644
index 0000000..406676f
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourceMappingPanel.java
@@ -0,0 +1,644 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.Comparator;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.JexlHelpUtils;
+import org.apache.syncope.client.console.panels.ResourceConnConfPanel.ConnConfModEvent;
+import org.apache.syncope.client.console.rest.ConnectorRestClient;
+import org.apache.syncope.client.console.rest.SchemaRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDecoratedCheckbox;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.FieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.MappingPurposePanel;
+import org.apache.syncope.common.lib.to.ConnIdObjectClassTO;
+import org.apache.syncope.common.lib.to.ConnInstanceTO;
+import org.apache.syncope.common.lib.to.MappingItemTO;
+import org.apache.syncope.common.lib.to.MappingTO;
+import org.apache.syncope.common.lib.to.ResourceTO;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.syncope.common.lib.types.ConnConfProperty;
+import org.apache.syncope.common.lib.types.IntMappingType;
+import org.apache.syncope.common.lib.types.MappingPurpose;
+import org.apache.wicket.Component;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.attributes.AjaxCallListener;
+import org.apache.wicket.ajax.attributes.AjaxRequestAttributes;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+/**
+ * Resource mapping panel.
+ */
+public class ResourceMappingPanel extends Panel {
+
+ private static final long serialVersionUID = -7982691107029848579L;
+
+ /**
+ * Mapping field style sheet.
+ */
+ private static final String FIELD_STYLE = "ui-widget-content ui-corner-all short_fixedsize";
+
+ /**
+ * Mapping field style sheet.
+ */
+ private static final String DEF_FIELD_STYLE = "ui-widget-content ui-corner-all";
+
+ /**
+ * Mapping field style sheet.
+ */
+ private static final String SHORT_FIELD_STYLE = "ui-widget-content ui-corner-all veryshort_fixedsize";
+
+ /**
+ * Schema rest client.
+ */
+ @SpringBean
+ private SchemaRestClient schemaRestClient;
+
+ /**
+ * ConnInstance rest client.
+ */
+ @SpringBean
+ private ConnectorRestClient connRestClient;
+
+ /**
+ * Resource schema name.
+ */
+ private final List<String> schemaNames;
+
+ /**
+ * Add mapping button.
+ */
+ private final AjaxButton addMappingBtn;
+
+ /**
+ * All mappings.
+ */
+ private final ListView<MappingItemTO> mappings;
+
+ /**
+ * External resource to be updated.
+ */
+ private final ResourceTO resourceTO;
+
+ /**
+ * User / group.
+ */
+ private final AttributableType attrType;
+
+ /**
+ * Mapping container.
+ */
+ private final WebMarkupContainer mappingContainer;
+
+ /**
+ * AccountLink container.
+ */
+ private final WebMarkupContainer accountLinkContainer;
+
+ private final AjaxCheckBoxPanel accountLinkCheckbox;
+
+ private MappingTO getMapping() {
+ MappingTO result = null;
+
+ if (AttributableType.USER == this.attrType) {
+ if (this.resourceTO.getUmapping() == null) {
+ this.resourceTO.setUmapping(new MappingTO());
+ }
+ result = this.resourceTO.getUmapping();
+ }
+ if (AttributableType.GROUP == this.attrType) {
+ if (this.resourceTO.getGmapping() == null) {
+ this.resourceTO.setGmapping(new MappingTO());
+ }
+ result = this.resourceTO.getGmapping();
+ }
+
+ return result;
+ }
+
+ /**
+ * Attribute Mapping Panel.
+ *
+ * @param id panel id
+ * @param resourceTO external resource
+ * @param attrType USER / GROUP
+ */
+ public ResourceMappingPanel(final String id, final ResourceTO resourceTO, final AttributableType attrType) {
+ super(id);
+ setOutputMarkupId(true);
+
+ this.resourceTO = resourceTO;
+ this.attrType = attrType;
+
+ this.mappingContainer = new WebMarkupContainer("mappingContainer");
+ this.mappingContainer.setOutputMarkupId(true);
+ add(this.mappingContainer);
+
+ this.accountLinkContainer = new WebMarkupContainer("accountLinkContainer");
+ this.accountLinkContainer.setOutputMarkupId(true);
+ add(this.accountLinkContainer);
+
+ if (this.resourceTO.getConnectorId() != null && this.resourceTO.getConnectorId() > 0) {
+ schemaNames = getSchemaNames(this.resourceTO.getConnectorId(), this.resourceTO.getConnConfProperties());
+
+ setEnabled();
+ } else {
+ schemaNames = Collections.<String>emptyList();
+ }
+
+ final WebMarkupContainer jexlHelp = JexlHelpUtils.getJexlHelpWebContainer("jexlHelp");
+
+ AjaxLink<Void> questionMarkJexlHelp = JexlHelpUtils.getAjaxLink(jexlHelp, "questionMarkJexlHelp");
+ mappingContainer.add(questionMarkJexlHelp);
+ questionMarkJexlHelp.add(jexlHelp);
+
+ final Label passwordLabel = new Label("passwordLabel", new ResourceModel("password"));
+ mappingContainer.add(passwordLabel);
+ if (AttributableType.USER != ResourceMappingPanel.this.attrType) {
+ passwordLabel.setVisible(false);
+ }
+
+ Collections.sort(getMapping().getItems(), new Comparator<MappingItemTO>() {
+
+ @Override
+ public int compare(final MappingItemTO left, final MappingItemTO right) {
+ int compared;
+ if (left == null && right == null) {
+ compared = 0;
+ } else if (left == null) {
+ compared = 1;
+ } else if (right == null) {
+ compared = -1;
+ } else if (left.getPurpose() == MappingPurpose.BOTH && right.getPurpose() != MappingPurpose.BOTH) {
+ compared = -1;
+ } else if (left.getPurpose() != MappingPurpose.BOTH && right.getPurpose() == MappingPurpose.BOTH) {
+ compared = 1;
+ } else if (left.getPurpose() == MappingPurpose.PROPAGATION
+ && (right.getPurpose() == MappingPurpose.SYNCHRONIZATION || right.getPurpose()
+ == MappingPurpose.NONE)) {
+ compared = -1;
+ } else if (left.getPurpose() == MappingPurpose.SYNCHRONIZATION
+ && right.getPurpose() == MappingPurpose.PROPAGATION) {
+ compared = 1;
+ } else if (left.getPurpose() == MappingPurpose.SYNCHRONIZATION
+ && right.getPurpose() == MappingPurpose.NONE) {
+ compared = -1;
+ } else if (left.getPurpose() == MappingPurpose.NONE
+ && right.getPurpose() != MappingPurpose.NONE) {
+ compared = 1;
+ } else if (left.isAccountid()) {
+ compared = -1;
+ } else if (right.isAccountid()) {
+ compared = 1;
+ } else if (left.isPassword()) {
+ compared = -1;
+ } else if (right.isPassword()) {
+ compared = 1;
+ } else {
+ compared = left.getIntAttrName().compareTo(right.getIntAttrName());
+ }
+ return compared;
+ }
+ });
+
+ mappings = new ListView<MappingItemTO>("mappings", getMapping().getItems()) {
+
+ private static final long serialVersionUID = 4949588177564901031L;
+
+ @Override
+ protected void populateItem(final ListItem<MappingItemTO> item) {
+ final MappingItemTO mapItem = item.getModelObject();
+ if (mapItem.getPurpose() == null) {
+ mapItem.setPurpose(MappingPurpose.BOTH);
+ }
+
+ AttributableType entity = null;
+ if (mapItem.getIntMappingType() != null) {
+ entity = mapItem.getIntMappingType().getAttributableType();
+ }
+
+ final List<IntMappingType> attrTypes = new ArrayList<IntMappingType>(getAttributeTypes(entity));
+
+ item.add(new AjaxDecoratedCheckbox("toRemove", new Model<Boolean>(Boolean.FALSE)) {
+
+ private static final long serialVersionUID = 7170946748485726506L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ int index = -1;
+ for (int i = 0; i < getMapping().getItems().size() && index == -1; i++) {
+ if (mapItem.equals(getMapping().getItems().get(i))) {
+ index = i;
+ }
+ }
+
+ if (index != -1) {
+ getMapping().getItems().remove(index);
+ item.getParent().removeAll();
+ target.add(ResourceMappingPanel.this);
+ }
+ }
+
+ @Override
+ protected void updateAjaxAttributes(final AjaxRequestAttributes attributes) {
+ super.updateAjaxAttributes(attributes);
+
+ final AjaxCallListener ajaxCallListener = new AjaxCallListener() {
+
+ private static final long serialVersionUID = 7160235486520935153L;
+
+ @Override
+ public CharSequence getPrecondition(final Component component) {
+ return "if (!confirm('" + getString("confirmDelete") + "')) return false;";
+ }
+ };
+ attributes.getAjaxCallListeners().add(ajaxCallListener);
+ }
+ });
+
+ final AjaxDropDownChoicePanel<String> intAttrNames =
+ new AjaxDropDownChoicePanel<String>("intAttrNames", getString("intAttrNames"),
+ new PropertyModel<String>(mapItem, "intAttrName"), false);
+ intAttrNames.setChoices(schemaNames);
+ intAttrNames.setRequired(true);
+ intAttrNames.setStyleSheet(FIELD_STYLE);
+ intAttrNames.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ }
+ });
+ item.add(intAttrNames);
+
+ final AjaxDropDownChoicePanel<IntMappingType> intMappingTypes =
+ new AjaxDropDownChoicePanel<IntMappingType>("intMappingTypes",
+ new ResourceModel("intMappingTypes", "intMappingTypes").getObject(),
+ new PropertyModel<IntMappingType>(mapItem, "intMappingType"));
+ intMappingTypes.setRequired(true);
+ intMappingTypes.setChoices(attrTypes);
+ intMappingTypes.setStyleSheet(FIELD_STYLE);
+ item.add(intMappingTypes);
+
+ final AjaxDropDownChoicePanel<AttributableType> entitiesPanel =
+ new AjaxDropDownChoicePanel<AttributableType>("entities",
+ new ResourceModel("entities", "entities").getObject(), new Model<AttributableType>(
+ entity));
+ entitiesPanel.setChoices(attrType == AttributableType.GROUP
+ ? Collections.<AttributableType>singletonList(AttributableType.GROUP)
+ : Arrays.asList(AttributableType.values()));
+ entitiesPanel.setStyleSheet(DEF_FIELD_STYLE);
+ entitiesPanel.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ attrTypes.clear();
+ attrTypes.addAll(getAttributeTypes(entitiesPanel.getModelObject()));
+ intMappingTypes.setChoices(attrTypes);
+
+ intAttrNames.setChoices(Collections.<String>emptyList());
+
+ target.add(intMappingTypes.getField());
+ target.add(intAttrNames.getField());
+ }
+ });
+ item.add(entitiesPanel);
+
+ final FieldPanel<String> extAttrNames = new AjaxTextFieldPanel("extAttrName",
+ new ResourceModel("extAttrNames", "extAttrNames").getObject(),
+ new PropertyModel<String>(mapItem, "extAttrName"));
+ ((AjaxTextFieldPanel) extAttrNames).setChoices(schemaNames);
+
+ boolean required = false;
+ if (mapItem.isPassword()) {
+ ((AjaxTextFieldPanel) extAttrNames).setModelObject(null);
+ } else {
+ required = true;
+ }
+ extAttrNames.setRequired(required);
+ extAttrNames.setEnabled(required);
+ extAttrNames.setStyleSheet(FIELD_STYLE);
+ item.add(extAttrNames);
+
+ final AjaxTextFieldPanel mandatory = new AjaxTextFieldPanel("mandatoryCondition",
+ new ResourceModel("mandatoryCondition", "mandatoryCondition").getObject(),
+ new PropertyModel<String>(mapItem, "mandatoryCondition"));
+ mandatory.setChoices(Arrays.asList(new String[] { "true", "false" }));
+ mandatory.setStyleSheet(SHORT_FIELD_STYLE);
+ item.add(mandatory);
+
+ final AjaxCheckBoxPanel accountId = new AjaxCheckBoxPanel("accountId",
+ new ResourceModel("accountId", "accountId").getObject(),
+ new PropertyModel<Boolean>(mapItem, "accountid"));
+ accountId.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ if (accountId.getModelObject()) {
+ mapItem.setMandatoryCondition("true");
+ mandatory.setEnabled(false);
+ } else {
+ mapItem.setMandatoryCondition("false");
+ mandatory.setEnabled(true);
+ }
+ target.add(mandatory);
+ }
+ });
+ item.add(accountId);
+
+ final AjaxCheckBoxPanel password = new AjaxCheckBoxPanel("password",
+ new ResourceModel("password", "password").getObject(),
+ new PropertyModel<Boolean>(mapItem, "password"));
+ password.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ extAttrNames.setEnabled(!mapItem.isAccountid() && !password.getModelObject());
+ extAttrNames.setModelObject(null);
+ extAttrNames.setRequired(!password.getModelObject());
+ target.add(extAttrNames);
+
+ setAccountId(intMappingTypes.getModelObject(), accountId, password);
+ target.add(accountId);
+ }
+ });
+ item.add(password);
+ if (AttributableType.USER != ResourceMappingPanel.this.attrType) {
+ password.setVisible(false);
+ }
+
+ final WebMarkupContainer purpose = new WebMarkupContainer("purpose");
+ purpose.setOutputMarkupId(Boolean.TRUE);
+
+ final MappingPurposePanel panel = new MappingPurposePanel("purposeActions",
+ new PropertyModel<MappingPurpose>(mapItem, "purpose"), purpose);
+
+ purpose.add(panel);
+
+ item.add(purpose);
+
+ intMappingTypes.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ setAttrNames(intMappingTypes.getModelObject(), intAttrNames);
+ target.add(intAttrNames);
+
+ setAccountId(intMappingTypes.getModelObject(), accountId, password);
+ target.add(accountId);
+ }
+ });
+
+ setAttrNames(mapItem.getIntMappingType(), intAttrNames);
+ setAccountId(mapItem.getIntMappingType(), accountId, password);
+ }
+ };
+
+ mappings.setReuseItems(true);
+ mappingContainer.add(mappings);
+
+ addMappingBtn = new IndicatingAjaxButton("addMappingBtn", new ResourceModel("add")) {
+
+ private static final long serialVersionUID = -4804368561204623354L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ getMapping().getItems().add(new MappingItemTO());
+ target.add(ResourceMappingPanel.this);
+ }
+ };
+ addMappingBtn.setDefaultFormProcessing(false);
+ addMappingBtn.setEnabled(this.resourceTO.getConnectorId() != null && this.resourceTO.getConnectorId() > 0);
+ mappingContainer.add(addMappingBtn);
+
+ boolean accountLinkEnabled = false;
+ if (getMapping().getAccountLink() != null) {
+ accountLinkEnabled = true;
+ }
+ accountLinkCheckbox = new AjaxCheckBoxPanel("accountLinkCheckbox",
+ new ResourceModel("accountLinkCheckbox", "accountLinkCheckbox").getObject(),
+ new Model<Boolean>(Boolean.valueOf(accountLinkEnabled)));
+ accountLinkCheckbox.setEnabled(true);
+
+ accountLinkContainer.add(accountLinkCheckbox);
+
+ final AjaxTextFieldPanel accountLink = new AjaxTextFieldPanel("accountLink",
+ new ResourceModel("accountLink", "accountLink").getObject(),
+ new PropertyModel<String>(getMapping(), "accountLink"));
+ accountLink.setEnabled(accountLinkEnabled);
+ accountLinkContainer.add(accountLink);
+
+ accountLinkCheckbox.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ if (accountLinkCheckbox.getModelObject()) {
+ accountLink.setEnabled(Boolean.TRUE);
+ accountLink.setModelObject("");
+ } else {
+ accountLink.setEnabled(Boolean.FALSE);
+ accountLink.setModelObject("");
+ }
+
+ target.add(accountLink);
+ }
+ });
+ }
+
+ private List<String> getSchemaNames(final Long connectorId, final Set<ConnConfProperty> conf) {
+ final ConnInstanceTO connInstanceTO = new ConnInstanceTO();
+ connInstanceTO.setKey(connectorId);
+ connInstanceTO.getConfiguration().addAll(conf);
+
+ return connRestClient.getSchemaNames(connInstanceTO);
+ }
+
+ private void setEnabled() {
+ final ConnInstanceTO connInstanceTO = new ConnInstanceTO();
+ connInstanceTO.setKey(this.resourceTO.getConnectorId());
+ connInstanceTO.getConfiguration().addAll(this.resourceTO.getConnConfProperties());
+
+ List<ConnIdObjectClassTO> objectClasses = connRestClient.getSupportedObjectClasses(connInstanceTO);
+
+ boolean enabled = objectClasses.isEmpty()
+ || (AttributableType.USER == attrType && objectClasses.contains(ConnIdObjectClassTO.ACCOUNT))
+ || (AttributableType.GROUP == attrType && objectClasses.contains(ConnIdObjectClassTO.GROUP));
+ this.mappingContainer.setEnabled(enabled);
+ this.mappingContainer.setVisible(enabled);
+ this.accountLinkContainer.setEnabled(enabled);
+ this.accountLinkContainer.setVisible(enabled);
+
+ if (!enabled) {
+ getMapping().getItems().clear();
+ getMapping().setAccountLink(null);
+ if (this.accountLinkCheckbox != null) {
+ this.accountLinkCheckbox.setModelObject(null);
+ }
+ }
+ }
+
+ @Override
+ public void onEvent(final IEvent<?> event) {
+ if (event.getPayload() instanceof ConnConfModEvent) {
+ final AjaxRequestTarget target = ((ConnConfModEvent) event.getPayload()).getTarget();
+
+ final List<ConnConfProperty> conf = ((ConnConfModEvent) event.getPayload()).getConfiguration();
+
+ mappings.removeAll();
+
+ addMappingBtn.setEnabled(resourceTO.getConnectorId() != null && resourceTO.getConnectorId() > 0);
+
+ schemaNames.clear();
+ schemaNames.addAll(getSchemaNames(resourceTO.getConnectorId(), new HashSet<ConnConfProperty>(conf)));
+
+ setEnabled();
+
+ target.add(this);
+ }
+ }
+
+ /**
+ * Set attribute names for a drop down choice list.
+ *
+ * @param type attribute type.
+ * @param toBeUpdated drop down choice to be updated.
+ */
+ private void setAttrNames(final IntMappingType type, final AjaxDropDownChoicePanel<String> toBeUpdated) {
+ toBeUpdated.setRequired(true);
+ toBeUpdated.setEnabled(true);
+
+ if (type == null || type.getAttributableType() == null) {
+ toBeUpdated.setChoices(Collections.<String>emptyList());
+ } else {
+ switch (type) {
+ // user attribute names
+ case UserPlainSchema:
+ case GroupPlainSchema:
+ case MembershipPlainSchema:
+ toBeUpdated.setChoices(schemaRestClient.getPlainSchemaNames(type.getAttributableType()));
+ break;
+
+ case UserDerivedSchema:
+ case GroupDerivedSchema:
+ case MembershipDerivedSchema:
+ toBeUpdated.setChoices(schemaRestClient.getDerSchemaNames(type.getAttributableType()));
+ break;
+
+ case UserVirtualSchema:
+ case GroupVirtualSchema:
+ case MembershipVirtualSchema:
+ toBeUpdated.setChoices(schemaRestClient.getVirSchemaNames(type.getAttributableType()));
+ break;
+
+ case UserId:
+ case Password:
+ case Username:
+ case GroupId:
+ case GroupName:
+ default:
+ toBeUpdated.setRequired(false);
+ toBeUpdated.setEnabled(false);
+ toBeUpdated.setChoices(Collections.<String>emptyList());
+ }
+ }
+ }
+
+ /**
+ * Enable/Disable accountId checkbox.
+ *
+ * @param type attribute type.
+ * @param accountId accountId checkbox.
+ * @param password password checkbox.
+ */
+ private void setAccountId(final IntMappingType type, final AjaxCheckBoxPanel accountId,
+ final AjaxCheckBoxPanel password) {
+
+ if (type != null && type.getAttributableType() != null) {
+ switch (type) {
+ case UserVirtualSchema:
+ case GroupVirtualSchema:
+ case MembershipVirtualSchema:
+ // Virtual accountId is not permitted
+ case Password:
+ // AccountId cannot be derived from password.
+ accountId.setReadOnly(true);
+ accountId.setModelObject(false);
+ break;
+
+ default:
+ if (password.getModelObject()) {
+ accountId.setReadOnly(true);
+ accountId.setModelObject(false);
+ } else {
+ accountId.setReadOnly(false);
+ }
+ }
+ }
+ }
+
+ /**
+ * Get all attribute types from a selected attribute type.
+ *
+ * @param entity entity.
+ * @return all attribute types.
+ */
+ private List<IntMappingType> getAttributeTypes(final AttributableType entity) {
+ final List<IntMappingType> res = new ArrayList<IntMappingType>();
+
+ if (entity != null) {
+ res.addAll(IntMappingType.getAttributeTypes(AttributableType.valueOf(entity.name())));
+ }
+
+ return res;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourceSecurityPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourceSecurityPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourceSecurityPanel.java
new file mode 100644
index 0000000..40e031a
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourceSecurityPanel.java
@@ -0,0 +1,189 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.Map;
+import org.apache.syncope.client.console.rest.PolicyRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.common.lib.to.AbstractPolicyTO;
+import org.apache.syncope.common.lib.to.ResourceTO;
+import org.apache.syncope.common.lib.types.PolicyType;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.ChoiceRenderer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class ResourceSecurityPanel extends Panel {
+
+ private static final long serialVersionUID = -7982691107029848579L;
+
+ @SpringBean
+ private PolicyRestClient policyRestClient;
+
+ private IModel<Map<Long, String>> passwordPolicies = null;
+
+ private IModel<Map<Long, String>> accountPolicies = null;
+
+ private IModel<Map<Long, String>> syncPolicies = null;
+
+ public ResourceSecurityPanel(final String id, final ResourceTO resourceTO) {
+
+ super(id);
+
+ setOutputMarkupId(true);
+
+ passwordPolicies = new LoadableDetachableModel<Map<Long, String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected Map<Long, String> load() {
+ Map<Long, String> res = new HashMap<>();
+ for (AbstractPolicyTO policyTO : policyRestClient.getPolicies(PolicyType.PASSWORD, false)) {
+ res.put(policyTO.getKey(), policyTO.getDescription());
+ }
+ return res;
+ }
+ };
+
+ accountPolicies = new LoadableDetachableModel<Map<Long, String>>() {
+
+ private static final long serialVersionUID = -2012833443695917883L;
+
+ @Override
+ protected Map<Long, String> load() {
+ Map<Long, String> res = new HashMap<>();
+ for (AbstractPolicyTO policyTO : policyRestClient.getPolicies(PolicyType.ACCOUNT, false)) {
+ res.put(policyTO.getKey(), policyTO.getDescription());
+ }
+ return res;
+ }
+ };
+
+ syncPolicies = new LoadableDetachableModel<Map<Long, String>>() {
+
+ private static final long serialVersionUID = -2012833443695917883L;
+
+ @Override
+ protected Map<Long, String> load() {
+ Map<Long, String> res = new HashMap<>();
+ for (AbstractPolicyTO policyTO : policyRestClient.getPolicies(PolicyType.SYNC, false)) {
+ res.put(policyTO.getKey(), policyTO.getDescription());
+ }
+ return res;
+ }
+ };
+
+ final WebMarkupContainer securityContainer = new WebMarkupContainer("security");
+
+ securityContainer.setOutputMarkupId(true);
+ add(securityContainer);
+
+ // -------------------------------
+ // Password policy specification
+ // -------------------------------
+ final AjaxDropDownChoicePanel<Long> passwordPolicy = new AjaxDropDownChoicePanel<Long>("passwordPolicy",
+ new ResourceModel("passwordPolicy", "passwordPolicy").getObject(), new PropertyModel<Long>(resourceTO,
+ "passwordPolicy"));
+
+ passwordPolicy.setChoiceRenderer(new PolicyRenderer(PolicyType.PASSWORD));
+
+ passwordPolicy.setChoices(new ArrayList<>(passwordPolicies.getObject().keySet()));
+
+ ((DropDownChoice<?>) passwordPolicy.getField()).setNullValid(true);
+
+ securityContainer.add(passwordPolicy);
+ // -------------------------------
+
+ // -------------------------------
+ // Account policy specification
+ // -------------------------------
+ final AjaxDropDownChoicePanel<Long> accountPolicy = new AjaxDropDownChoicePanel<Long>("accountPolicy",
+ new ResourceModel("accountPolicy", "accountPolicy").getObject(), new PropertyModel<Long>(resourceTO,
+ "accountPolicy"));
+
+ accountPolicy.setChoiceRenderer(new PolicyRenderer(PolicyType.ACCOUNT));
+
+ accountPolicy.setChoices(new ArrayList<Long>(accountPolicies.getObject().keySet()));
+
+ ((DropDownChoice<?>) accountPolicy.getField()).setNullValid(true);
+
+ securityContainer.add(accountPolicy);
+ // -------------------------------
+
+ // -------------------------------
+ // Sync policy specification
+ // -------------------------------
+ final AjaxDropDownChoicePanel<Long> syncPolicy = new AjaxDropDownChoicePanel<Long>("syncPolicy",
+ new ResourceModel("syncPolicy", "syncPolicy").getObject(), new PropertyModel<Long>(resourceTO,
+ "syncPolicy"));
+
+ syncPolicy.setChoiceRenderer(new PolicyRenderer(PolicyType.SYNC));
+
+ syncPolicy.setChoices(new ArrayList<Long>(syncPolicies.getObject().keySet()));
+
+ ((DropDownChoice<?>) syncPolicy.getField()).setNullValid(true);
+
+ securityContainer.add(syncPolicy);
+ // -------------------------------
+ }
+
+ private class PolicyRenderer extends ChoiceRenderer<Long> {
+
+ private static final long serialVersionUID = 8060500161321947000L;
+
+ private PolicyType type;
+
+ public PolicyRenderer(final PolicyType type) {
+ super();
+ this.type = type;
+ }
+
+ @Override
+ public Object getDisplayValue(final Long object) {
+ switch (type) {
+ case GLOBAL_ACCOUNT:
+ case ACCOUNT:
+ return accountPolicies.getObject().get(object);
+ case GLOBAL_PASSWORD:
+ case PASSWORD:
+ return passwordPolicies.getObject().get(object);
+ case GLOBAL_SYNC:
+ case SYNC:
+ return syncPolicies.getObject().get(object);
+ default:
+ return "";
+ }
+ }
+
+ @Override
+ public String getIdValue(final Long object, final int index) {
+ return String.valueOf(object != null
+ ? object
+ : 0L);
+ }
+ };
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourcesPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourcesPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourcesPanel.java
new file mode 100644
index 0000000..028b3a0
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ResourcesPanel.java
@@ -0,0 +1,177 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.GroupTreeBuilder;
+import org.apache.syncope.client.console.commons.SelectChoiceRenderer;
+import org.apache.syncope.client.console.commons.status.StatusUtils;
+import org.apache.syncope.client.console.rest.ResourceRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPalettePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.NonI18nPalette;
+import org.apache.syncope.common.lib.to.AbstractSubjectTO;
+import org.apache.syncope.common.lib.to.MembershipTO;
+import org.apache.syncope.common.lib.to.ResourceTO;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.extensions.markup.html.form.palette.Palette;
+import org.apache.wicket.extensions.markup.html.form.palette.component.Recorder;
+import org.apache.wicket.markup.html.form.IChoiceRenderer;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.util.ListModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class ResourcesPanel extends Panel {
+
+ private static final long serialVersionUID = -8728071019777410008L;
+
+ @SpringBean
+ private ResourceRestClient resourceRestClient;
+
+ @SpringBean
+ private GroupTreeBuilder groupTreeBuilder;
+
+ private final AbstractSubjectTO subjectTO;
+
+ private final Set<String> previousResources;
+
+ private final List<String> allResources;
+
+ public static class Builder implements Serializable {
+
+ private static final long serialVersionUID = 8644108944633025494L;
+
+ private String id;
+
+ private Object to;
+
+ private StatusPanel statusPanel;
+
+ public Builder(final String id) {
+ this.id = id;
+ }
+
+ public Builder attributableTO(final Object to) {
+ this.to = to;
+ return this;
+ }
+
+ public Builder statusPanel(final StatusPanel statusPanel) {
+ this.statusPanel = statusPanel;
+ return this;
+ }
+
+ public ResourcesPanel build() {
+ return new ResourcesPanel(this);
+ }
+ }
+
+ private ResourcesPanel(final Builder builder) {
+ super(builder.id);
+ subjectTO = (AbstractSubjectTO) builder.to;
+ previousResources = new HashSet<>(subjectTO.getResources());
+ allResources = new ArrayList<>();
+ for (ResourceTO resourceTO : resourceRestClient.getAll()) {
+ allResources.add(resourceTO.getKey());
+ }
+ Collections.sort(allResources);
+
+ AjaxPalettePanel<String> resourcesPalette = null;
+
+ if (subjectTO instanceof UserTO) {
+ resourcesPalette = new AjaxRecordingPalettePanel<>("resourcesPalette",
+ new PropertyModel<List<String>>(subjectTO, "resources"),
+ new ListModel<>(allResources), builder.statusPanel);
+ } else if (subjectTO instanceof GroupTO) {
+ resourcesPalette = new AjaxPalettePanel<>("resourcesPalette",
+ new PropertyModel<List<String>>(subjectTO, "resources"), new ListModel<>(allResources));
+ }
+ add(resourcesPalette);
+ }
+
+ private class AjaxRecordingPalettePanel<T> extends AjaxPalettePanel<T> {
+
+ private static final long serialVersionUID = -4215625881756021988L;
+
+ private final StatusPanel statusPanel;
+
+ public AjaxRecordingPalettePanel(final String id, final IModel<List<T>> model, final ListModel<T> choices,
+ final StatusPanel statusPanel) {
+
+ super(id, model, choices, new SelectChoiceRenderer<T>(), false, false);
+ this.statusPanel = statusPanel;
+ }
+
+ @Override
+ protected Palette<T> createPalette(final IModel<List<T>> model, final ListModel<T> choices,
+ final IChoiceRenderer<T> renderer, final boolean allowOrder, final boolean allowMoveAll) {
+
+ return new NonI18nPalette<T>("paletteField", model, choices, renderer, 8, allowOrder, false) {
+
+ private static final long serialVersionUID = -3415146226879212841L;
+
+ @Override
+ protected Recorder<T> newRecorderComponent() {
+ Recorder<T> recorder = super.newRecorderComponent();
+ recorder.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = 5538299138211283825L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ if (subjectTO instanceof UserTO) {
+ UserTO userTO = (UserTO) subjectTO;
+
+ Set<String> resourcesToRemove = new HashSet<>(previousResources);
+ resourcesToRemove.removeAll(userTO.getResources());
+ if (!resourcesToRemove.isEmpty()) {
+ Set<String> resourcesAssignedViaMembership = new HashSet<>();
+ for (MembershipTO membTO : userTO.getMemberships()) {
+ GroupTO groupTO = groupTreeBuilder.findGroup(membTO.getGroupKey());
+ if (groupTO != null) {
+ resourcesAssignedViaMembership.addAll(groupTO.getResources());
+ }
+ }
+ resourcesToRemove.removeAll(resourcesAssignedViaMembership);
+ }
+
+ previousResources.clear();
+ previousResources.addAll(userTO.getResources());
+
+ StatusUtils.update(
+ userTO, statusPanel, target, userTO.getResources(), resourcesToRemove);
+ }
+ }
+ });
+ return recorder;
+ }
+ };
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SchedTasks.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SchedTasks.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SchedTasks.java
new file mode 100644
index 0000000..205bfa5
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SchedTasks.java
@@ -0,0 +1,286 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.pages.SchedTaskModalPage;
+import org.apache.syncope.client.console.pages.Tasks;
+import org.apache.syncope.client.console.pages.Tasks.TasksProvider;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.AbstractTaskTO;
+import org.apache.syncope.common.lib.to.SchedTaskTO;
+import org.apache.wicket.Component;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.StringResourceModel;
+import org.apache.wicket.request.http.WebResponse;
+
+public class SchedTasks extends AbstractTasks {
+
+ private static final long serialVersionUID = 525486152284253354L;
+
+ private int paginatorRows;
+
+ private WebMarkupContainer container;
+
+ private ModalWindow window;
+
+ private AjaxDataTablePanel<AbstractTaskTO, String> table;
+
+ public SchedTasks(final String id, final PageReference pageRef) {
+ super(id, pageRef);
+
+ container = new WebMarkupContainer("container");
+ container.setOutputMarkupId(true);
+ add(container);
+
+ window = new ModalWindow("taskWin");
+ window.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ window.setInitialHeight(WIN_HEIGHT);
+ window.setInitialWidth(WIN_WIDTH);
+ window.setCookieName(VIEW_TASK_WIN_COOKIE_NAME);
+ add(window);
+
+ ((Tasks) pageRef.getPage()).setWindowClosedCallback(window, container);
+
+ paginatorRows = prefMan.getPaginatorRows(getWebRequest(), Constants.PREF_SCHED_TASKS_PAGINATOR_ROWS);
+
+ table = Tasks.updateTaskTable(
+ getColumns(),
+ new TasksProvider<SchedTaskTO>(restClient, paginatorRows, getId(), SchedTaskTO.class),
+ container,
+ 0,
+ pageRef,
+ restClient);
+
+ container.add(table);
+
+ @SuppressWarnings("rawtypes")
+ Form paginatorForm = new Form("PaginatorForm");
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ final DropDownChoice rowsChooser = new DropDownChoice("rowsChooser", new PropertyModel(this, "paginatorRows"),
+ prefMan.getPaginatorChoices());
+
+ rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ prefMan.set(getWebRequest(), (WebResponse) getResponse(), Constants.PREF_SCHED_TASKS_PAGINATOR_ROWS,
+ String.valueOf(paginatorRows));
+
+ table = Tasks.updateTaskTable(
+ getColumns(),
+ new TasksProvider<SchedTaskTO>(restClient, paginatorRows, getId(), SchedTaskTO.class),
+ container,
+ table == null ? 0 : (int) table.getCurrentPage(),
+ pageRef,
+ restClient);
+
+ target.add(container);
+ }
+ });
+
+ paginatorForm.add(rowsChooser);
+ add(paginatorForm);
+
+ AjaxLink createLink = new ClearIndicatingAjaxLink("createLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new SchedTaskModalPage(window, new SchedTaskTO(), pageRef);
+ }
+ });
+
+ window.show(target);
+ }
+ };
+
+ MetaDataRoleAuthorizationStrategy.authorize(
+ createLink, RENDER, xmlRolesReader.getEntitlement(TASKS, "create"));
+
+ add(createLink);
+ }
+
+ private List<IColumn<AbstractTaskTO, String>> getColumns() {
+ final List<IColumn<AbstractTaskTO, String>> columns = new ArrayList<IColumn<AbstractTaskTO, String>>();
+
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("key", this, null), "key", "key"));
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("name", this, null), "name", "name"));
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("description", this, null), "description", "description"));
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("class", this, null), "jobClassName", "jobClassName"));
+ columns.add(new DatePropertyColumn<AbstractTaskTO>(
+ new StringResourceModel("lastExec", this, null), "lastExec", "lastExec"));
+ columns.add(new DatePropertyColumn<AbstractTaskTO>(
+ new StringResourceModel("nextExec", this, null), "nextExec", "nextExec"));
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("latestExecStatus", this, null), "latestExecStatus", "latestExecStatus"));
+
+ columns.add(new ActionColumn<AbstractTaskTO, String>(new StringResourceModel("actions", this, null, "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public ActionLinksPanel getActions(final String componentId, final IModel<AbstractTaskTO> model) {
+
+ final SchedTaskTO taskTO = (SchedTaskTO) model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, pageRef);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new SchedTaskModalPage(window, taskTO, pageRef);
+ }
+ });
+
+ window.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, TASKS);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ restClient.startExecution(taskTO.getKey(), false);
+ getSession().info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+
+ ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
+ target.add(container);
+ }
+ }, ActionLink.ActionType.EXECUTE, TASKS);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ restClient.startExecution(taskTO.getKey(), true);
+ getSession().info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+
+ ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
+ target.add(container);
+ }
+ }, ActionLink.ActionType.DRYRUN, TASKS);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ restClient.delete(taskTO.getKey(), SchedTaskTO.class);
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+ target.add(container);
+ ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
+ }
+ }, ActionLink.ActionType.DELETE, TASKS);
+
+ return panel;
+ }
+
+ @Override
+ public Component getHeader(final String componentId) {
+ @SuppressWarnings("rawtypes")
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), pageRef);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ if (target != null) {
+ target.add(table);
+ }
+ }
+ }, ActionLink.ActionType.RELOAD, TASKS, "list");
+
+ return panel;
+ }
+ });
+ return columns;
+ }
+
+ @Override
+ public void onEvent(final IEvent<?> event) {
+ if (event.getPayload() instanceof AbstractSearchResultPanel.EventDataWrapper) {
+ ((AbstractSearchResultPanel.EventDataWrapper) event.getPayload()).getTarget().add(container);
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SearchClause.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SearchClause.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SearchClause.java
new file mode 100644
index 0000000..488a2cf
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SearchClause.java
@@ -0,0 +1,129 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.io.Serializable;
+import org.apache.commons.lang3.builder.EqualsBuilder;
+import org.apache.commons.lang3.builder.HashCodeBuilder;
+import org.apache.commons.lang3.builder.ReflectionToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+
+public class SearchClause implements Serializable {
+
+ private static final long serialVersionUID = 2010794463096110104L;
+
+ public enum Operator {
+
+ AND,
+ OR;
+
+ }
+
+ public enum Type {
+
+ ATTRIBUTE,
+ MEMBERSHIP,
+ RESOURCE,
+ ENTITLEMENT;
+
+ }
+
+ public enum Comparator {
+
+ IS_NULL,
+ IS_NOT_NULL,
+ EQUALS,
+ NOT_EQUALS,
+ GREATER_OR_EQUALS,
+ GREATER_THAN,
+ LESS_OR_EQUALS,
+ LESS_THAN;
+
+ }
+
+ private Operator operator;
+
+ private Type type;
+
+ private String property;
+
+ private Comparator comparator;
+
+ private String value;
+
+ public SearchClause() {
+ setOperator(SearchClause.Operator.AND);
+ setComparator(SearchClause.Comparator.EQUALS);
+ }
+
+ public Operator getOperator() {
+ return operator;
+ }
+
+ public void setOperator(final Operator operator) {
+ this.operator = operator;
+ }
+
+ public Type getType() {
+ return type;
+ }
+
+ public void setType(final Type type) {
+ this.type = type;
+ }
+
+ public String getProperty() {
+ return property;
+ }
+
+ public void setProperty(final String property) {
+ this.property = property;
+ }
+
+ public Comparator getComparator() {
+ return comparator;
+ }
+
+ public void setComparator(final Comparator comparator) {
+ this.comparator = comparator;
+ }
+
+ public String getValue() {
+ return value;
+ }
+
+ public void setValue(final String value) {
+ this.value = value;
+ }
+
+ @Override
+ public boolean equals(final Object obj) {
+ return EqualsBuilder.reflectionEquals(this, obj);
+ }
+
+ @Override
+ public int hashCode() {
+ return HashCodeBuilder.reflectionHashCode(this);
+ }
+
+ @Override
+ public String toString() {
+ return ReflectionToStringBuilder.toString(this, ToStringStyle.MULTI_LINE_STYLE);
+ }
+}
[37/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/SelectOnlyUserSearchResultPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/SelectOnlyUserSearchResultPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/SelectOnlyUserSearchResultPanel.java
deleted file mode 100644
index efa5a3d..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/SelectOnlyUserSearchResultPanel.java
+++ /dev/null
@@ -1,93 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.List;
-import org.apache.syncope.client.console.pages.DisplayAttributesModalPage;
-import org.apache.syncope.client.console.rest.UserRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.common.lib.to.AbstractAttributableTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.event.Broadcast;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.ResourceModel;
-
-public class SelectOnlyUserSearchResultPanel extends UserSearchResultPanel {
-
- private static final long serialVersionUID = 2146781496050131930L;
-
- private final PageReference pageRef;
-
- private final ModalWindow window;
-
- public <T extends AbstractAttributableTO> SelectOnlyUserSearchResultPanel(final String id, final boolean filtered,
- final String fiql, final PageReference pageRef, final ModalWindow window, final UserRestClient restClient) {
-
- super(id, filtered, fiql, pageRef, restClient);
-
- this.pageRef = pageRef;
- this.window = window;
- }
-
- @Override
- protected List<IColumn<AbstractAttributableTO, String>> getColumns() {
- final List<IColumn<AbstractAttributableTO, String>> columns =
- new ArrayList<IColumn<AbstractAttributableTO, String>>();
- for (String name : DisplayAttributesModalPage.DEFAULT_SELECTION) {
- columns.add(new PropertyColumn<AbstractAttributableTO, String>(new ResourceModel(name, name), name, name));
- }
-
- columns.add(new AbstractColumn<AbstractAttributableTO, String>(new ResourceModel("actions", "")) {
-
- private static final long serialVersionUID = 8263694778917279290L;
-
- @Override
- public void populateItem(final Item<ICellPopulator<AbstractAttributableTO>> cellItem,
- final String componentId, final IModel<AbstractAttributableTO> rowModel) {
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, rowModel, pageRef);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- send(pageRef.getPage(), Broadcast.BREADTH,
- new GroupDetailsPanel.UserOwnerSelectPayload(rowModel.getObject().getKey()));
- window.close(target);
- }
- }, ActionLink.ActionType.SELECT, "Users");
-
- cellItem.add(panel);
- }
- });
-
- return columns;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/SelectedEventsPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/SelectedEventsPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/SelectedEventsPanel.java
deleted file mode 100644
index 96c8d77..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/SelectedEventsPanel.java
+++ /dev/null
@@ -1,167 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.List;
-import java.util.Set;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.event.Broadcast;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.markup.ComponentTag;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.IChoiceRenderer;
-import org.apache.wicket.markup.html.form.ListMultipleChoice;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.util.ListModel;
-
-public class SelectedEventsPanel extends Panel {
-
- private static final long serialVersionUID = -4832450230348213500L;
-
- private final WebMarkupContainer selectionContainer;
-
- private ListMultipleChoice<String> selectedEvents;
-
- private final IModel<List<String>> model;
-
- public SelectedEventsPanel(final String id, final IModel<List<String>> model) {
- super(id);
-
- this.model = model;
-
- selectionContainer = new WebMarkupContainer("selectionContainer");
- selectionContainer.setOutputMarkupId(true);
- add(selectionContainer);
-
- selectedEvents = new ListMultipleChoice<String>("selectedEvents", new ListModel<String>(), model) {
-
- private static final long serialVersionUID = 1226677544225737338L;
-
- @Override
- protected void onComponentTag(final ComponentTag tag) {
- super.onComponentTag(tag);
- tag.remove("size");
- tag.remove("multiple");
- tag.put("size", 5);
- }
- };
-
- selectedEvents.setMaxRows(5);
- selectedEvents.setChoiceRenderer(new IChoiceRenderer<String>() {
-
- private static final long serialVersionUID = -4288397951948436434L;
-
- @Override
- public Object getDisplayValue(final String object) {
- return object;
- }
-
- @Override
- public String getIdValue(final String object, final int index) {
- return object;
- }
- });
-
- selectedEvents.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -151291731388673682L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- send(SelectedEventsPanel.this.getPage(),
- Broadcast.BREADTH,
- new InspectSelectedEvent(target, selectedEvents.getModelValue()));
- }
- });
-
- selectionContainer.add(selectedEvents);
- }
-
- @Override
- public void onEvent(final IEvent<?> event) {
- if (event.getPayload() instanceof EventSelectionChanged) {
- final EventSelectionChanged eventSelectionChanged = (EventSelectionChanged) event.getPayload();
-
- for (String toBeRemoved : eventSelectionChanged.getToBeRemoved()) {
- model.getObject().remove(toBeRemoved);
- }
-
- for (String toBeAdded : eventSelectionChanged.getToBeAdded()) {
- if (!model.getObject().contains(toBeAdded)) {
- model.getObject().add(toBeAdded);
- }
- }
-
- eventSelectionChanged.getTarget().add(selectionContainer);
- }
- }
-
- public static class InspectSelectedEvent {
-
- private final AjaxRequestTarget target;
-
- private final String event;
-
- public InspectSelectedEvent(final AjaxRequestTarget target, final String event) {
- this.target = target;
- this.event = event;
- }
-
- public AjaxRequestTarget getTarget() {
- return target;
- }
-
- public String getEvent() {
- return event;
- }
- }
-
- public static class EventSelectionChanged {
-
- private final AjaxRequestTarget target;
-
- private final Set<String> toBeRemoved;
-
- private final Set<String> toBeAdded;
-
- public EventSelectionChanged(
- final AjaxRequestTarget target,
- final Set<String> toBeAdded,
- final Set<String> toBeRemoved) {
- this.target = target;
- this.toBeAdded = toBeAdded;
- this.toBeRemoved = toBeRemoved;
- }
-
- public AjaxRequestTarget getTarget() {
- return target;
- }
-
- public Set<String> getToBeRemoved() {
- return toBeRemoved;
- }
-
- public Set<String> getToBeAdded() {
- return toBeAdded;
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/StatusPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/StatusPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/StatusPanel.java
deleted file mode 100644
index fb74065..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/StatusPanel.java
+++ /dev/null
@@ -1,262 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.LinkedHashMap;
-import java.util.List;
-import java.util.Map;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.commons.status.ConnObjectWrapper;
-import org.apache.syncope.client.console.commons.status.Status;
-import org.apache.syncope.client.console.commons.status.StatusBean;
-import org.apache.syncope.client.console.commons.status.StatusUtils;
-import org.apache.syncope.client.console.pages.ConnObjectModalPage;
-import org.apache.syncope.client.console.rest.GroupRestClient;
-import org.apache.syncope.client.console.rest.UserRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.client.console.wicket.markup.html.list.AltListView;
-import org.apache.syncope.common.lib.mod.StatusMod;
-import org.apache.syncope.common.lib.to.AbstractAttributableTO;
-import org.apache.syncope.common.lib.to.AbstractSubjectTO;
-import org.apache.syncope.common.lib.to.ConnObjectTO;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormChoiceComponentUpdatingBehavior;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.IHeaderContributor;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Check;
-import org.apache.wicket.markup.html.form.CheckGroup;
-import org.apache.wicket.markup.html.form.CheckGroupSelector;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-public class StatusPanel extends Panel implements IHeaderContributor {
-
- /**
- * Logger.
- */
- private static final Logger LOG = LoggerFactory.getLogger(StatusPanel.class);
-
- private static final long serialVersionUID = -4064294905566247728L;
-
- public static final String IMG_STATUES = "../statuses/";
-
- private static final int CONNOBJECT_WIN_HEIGHT = 400;
-
- private static final int CONNOBJECT_WIN_WIDTH = 600;
-
- @SpringBean
- private UserRestClient userRestClient;
-
- @SpringBean
- private GroupRestClient groupRestClient;
-
- private final ModalWindow connObjectWin;
-
- private final List<ConnObjectWrapper> connObjects;
-
- private final Map<String, StatusBean> initialStatusBeanMap;
-
- private final CheckGroup<StatusBean> checkGroup;
-
- private final ListView<StatusBean> statusBeansListView;
-
- private final StatusUtils statusUtils;
-
- public <T extends AbstractAttributableTO> StatusPanel(
- final String id,
- final AbstractSubjectTO subject,
- final List<StatusBean> selectedResources,
- final PageReference pageref) {
-
- super(id);
-
- connObjectWin = new ModalWindow("connObjectWin");
- connObjectWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- connObjectWin.setInitialHeight(CONNOBJECT_WIN_HEIGHT);
- connObjectWin.setInitialWidth(CONNOBJECT_WIN_WIDTH);
- connObjectWin.setCookieName("connobject-modal");
- add(connObjectWin);
-
- statusUtils = new StatusUtils(subject instanceof GroupTO ? groupRestClient : userRestClient);
-
- connObjects = statusUtils.getConnectorObjects(subject);
-
- final List<StatusBean> statusBeans = new ArrayList<>(connObjects.size() + 1);
- initialStatusBeanMap = new LinkedHashMap<>(connObjects.size() + 1);
-
- final StatusBean syncope = new StatusBean(subject, "syncope");
-
- if (subject instanceof UserTO) {
- syncope.setAccountLink(((UserTO) subject).getUsername());
-
- Status syncopeStatus = Status.UNDEFINED;
- if (((UserTO) subject).getStatus() != null) {
- try {
- syncopeStatus = Status.valueOf(((UserTO) subject).getStatus().toUpperCase());
- } catch (IllegalArgumentException e) {
- LOG.warn("Unexpected status found: {}", ((UserTO) subject).getStatus(), e);
- }
- }
- syncope.setStatus(syncopeStatus);
- } else if (subject instanceof GroupTO) {
- syncope.setAccountLink(((GroupTO) subject).getDisplayName());
- syncope.setStatus(Status.ACTIVE);
- }
-
- statusBeans.add(syncope);
- initialStatusBeanMap.put(syncope.getResourceName(), syncope);
-
- for (ConnObjectWrapper entry : connObjects) {
- final StatusBean statusBean = statusUtils.getStatusBean(entry.getAttributable(),
- entry.getResourceName(),
- entry.getConnObjectTO(),
- subject instanceof GroupTO);
-
- initialStatusBeanMap.put(entry.getResourceName(), statusBean);
- statusBeans.add(statusBean);
- }
-
- checkGroup = new CheckGroup<>("group", selectedResources);
- checkGroup.setOutputMarkupId(true);
- checkGroup.add(new AjaxFormChoiceComponentUpdatingBehavior() {
-
- private static final long serialVersionUID = -151291731388673682L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- // ignore
- }
- });
- add(checkGroup);
-
- CheckGroupSelector groupSelector = new CheckGroupSelector("groupselector", checkGroup);
- if (subject instanceof GroupTO) {
- groupSelector.setVisible(false);
- }
- add(groupSelector);
-
- statusBeansListView = new AltListView<StatusBean>("resources", statusBeans) {
-
- private static final long serialVersionUID = 4949588177564901031L;
-
- @Override
- protected void populateItem(final ListItem<StatusBean> item) {
- item.add(statusUtils.getStatusImage("icon", item.getModelObject().getStatus()));
-
- final Check<StatusBean> check = new Check<StatusBean>("check", item.getModel(), checkGroup);
- if (subject instanceof GroupTO) {
- check.setVisible(false);
- }
- item.add(check);
-
- item.add(new Label("resource", new ResourceModel(item.getModelObject().getResourceName(), item
- .getModelObject().getResourceName())));
-
- if (StringUtils.isNotBlank(item.getModelObject().getAccountLink())) {
- item.add(new Label("accountLink", new ResourceModel(item.getModelObject().getAccountLink(),
- item.getModelObject().getAccountLink())));
- } else {
- item.add(new Label("accountLink", ""));
- }
-
- final ConnObjectTO connObjectTO = statusUtils.getConnObjectTO(
- item.getModelObject().getAttributableId(),
- item.getModelObject().getResourceName(),
- connObjects);
-
- if (pageref == null || connObjectTO == null) {
- item.add(new Label("connObject", new Model<String>()));
- } else {
- final ActionLinksPanel connObject = new ActionLinksPanel("connObject", new Model(), pageref);
-
- connObject.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- connObjectWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ConnObjectModalPage(connObjectTO);
- }
- });
-
- connObjectWin.show(target);
- }
- }, ActionLink.ActionType.SEARCH, "Resources", "getConnectorObject");
-
- item.add(connObject);
- }
- }
- };
- statusBeansListView.setReuseItems(true);
- checkGroup.add(statusBeansListView);
- }
-
- public StatusMod getStatusMod() {
- StatusMod result = new StatusMod();
-
- Collection<StatusBean> statusBeans = checkGroup.getModel().getObject();
- if (statusBeans != null && !statusBeans.isEmpty()) {
- result = StatusUtils.buildStatusMod(statusBeans);
- }
-
- return result;
- }
-
- public List<StatusBean> getStatusBeans() {
- return statusBeansListView.getModelObject();
- }
-
- public Map<String, StatusBean> getInitialStatusBeanMap() {
- return initialStatusBeanMap;
- }
-
- public void updateStatusBeans(final List<StatusBean> statusBeans) {
- statusBeansListView.removeAll();
- statusBeansListView.getModelObject().clear();
- statusBeansListView.getModelObject().addAll(statusBeans);
-
- for (StatusBean statusBean : statusBeans) {
- if (!checkGroup.getModelObject().contains(statusBean)
- && statusBean.getStatus() == Status.NOT_YET_SUBMITTED) {
-
- checkGroup.getModelObject().add(statusBean);
- }
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/SyncTasksPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/SyncTasksPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/SyncTasksPanel.java
deleted file mode 100644
index 5561716..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/SyncTasksPanel.java
+++ /dev/null
@@ -1,225 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.pages.GroupTemplateModalPage;
-import org.apache.syncope.client.console.pages.SyncTaskModalPage;
-import org.apache.syncope.client.console.pages.UserTemplateModalPage;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.AbstractTaskTO;
-import org.apache.syncope.common.lib.to.SyncTaskTO;
-import org.apache.wicket.Component;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.StringResourceModel;
-
-public class SyncTasksPanel extends AbstractProvisioningTasksPanel<SyncTaskTO> {
-
- private static final long serialVersionUID = 53189199346016099L;
-
- public SyncTasksPanel(final String id, final PageReference pageRef) {
- super(id, pageRef, SyncTaskTO.class);
- initTasksTable();
- }
-
- @Override
- protected List<IColumn<AbstractTaskTO, String>> getColumns() {
- final List<IColumn<AbstractTaskTO, String>> syncTaskscolumns = new ArrayList<>();
-
- syncTaskscolumns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("key", this, null), "key", "key"));
- syncTaskscolumns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("name", this, null), "name", "name"));
- syncTaskscolumns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("description", this, null), "description", "description"));
- syncTaskscolumns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("resourceName", this, null), "resource", "resource"));
- syncTaskscolumns.add(new DatePropertyColumn<AbstractTaskTO>(
- new StringResourceModel("lastExec", this, null), "lastExec", "lastExec"));
- syncTaskscolumns.add(new DatePropertyColumn<AbstractTaskTO>(
- new StringResourceModel("nextExec", this, null), "nextExec", "nextExec"));
- syncTaskscolumns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("latestExecStatus", this, null), "latestExecStatus", "latestExecStatus"));
-
- syncTaskscolumns.add(new ActionColumn<AbstractTaskTO, String>(new StringResourceModel("actions", this, null, "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public ActionLinksPanel getActions(final String componentId, final IModel<AbstractTaskTO> model) {
-
- final SyncTaskTO taskTO = (SyncTaskTO) model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, pageRef);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
-
- window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new SyncTaskModalPage(window, taskTO, pageRef);
- }
- });
-
- window.show(target);
- }
- }, ActionLink.ActionType.EDIT, TASKS);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
-
- window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new UserTemplateModalPage(pageRef, window, taskTO);
- }
- });
-
- window.show(target);
- }
- }, ActionLink.ActionType.USER_TEMPLATE, TASKS);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
-
- window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new GroupTemplateModalPage(pageRef, window, taskTO);
- }
- });
-
- window.show(target);
- }
- }, ActionLink.ActionType.GROUP_TEMPLATE, TASKS);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- restClient.startExecution(taskTO.getKey(), false);
- getSession().info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
-
- target.add(container);
- ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
- }
- }, ActionLink.ActionType.EXECUTE, TASKS);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- restClient.startExecution(taskTO.getKey(), true);
- getSession().info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
-
- target.add(container);
- ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
- }
- }, ActionLink.ActionType.DRYRUN, TASKS);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- restClient.delete(taskTO.getKey(), SyncTaskTO.class);
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
- target.add(container);
- ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
- }
- }, ActionLink.ActionType.DELETE, TASKS);
-
- return panel;
- }
-
- @Override
- public Component getHeader(final String componentId) {
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), pageRef);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- if (target != null) {
- target.add(table);
- }
- }
- }, ActionLink.ActionType.RELOAD, TASKS, "list");
-
- return panel;
- }
- });
-
- return syncTaskscolumns;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/UserDetailsPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/UserDetailsPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/UserDetailsPanel.java
deleted file mode 100644
index bf990ec..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/UserDetailsPanel.java
+++ /dev/null
@@ -1,122 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import org.apache.syncope.client.console.commons.JexlHelpUtils;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPasswordFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.FieldPanel;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.Component;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.behavior.Behavior;
-import org.apache.wicket.markup.ComponentTag;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.form.PasswordTextField;
-import org.apache.wicket.markup.html.form.validation.EqualPasswordInputValidator;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-
-public class UserDetailsPanel extends Panel {
-
- private static final long serialVersionUID = 6592027822510220463L;
-
- public UserDetailsPanel(final String id, final UserTO userTO, final Form form, final boolean resetPassword,
- final boolean templateMode) {
-
- super(id);
-
- // ------------------------
- // Username
- // ------------------------
- final FieldPanel<String> username = new AjaxTextFieldPanel("username", "username",
- new PropertyModel<String>(userTO, "username"));
-
- final WebMarkupContainer jexlHelp = JexlHelpUtils.getJexlHelpWebContainer("usernameJexlHelp");
-
- final AjaxLink<?> questionMarkJexlHelp = JexlHelpUtils.getAjaxLink(jexlHelp, "usernameQuestionMarkJexlHelp");
- add(questionMarkJexlHelp);
- questionMarkJexlHelp.add(jexlHelp);
-
- if (!templateMode) {
- username.addRequiredLabel();
- questionMarkJexlHelp.setVisible(false);
- }
- add(username);
- // ------------------------
-
- // ------------------------
- // Password
- // ------------------------
- final WebMarkupContainer pwdJexlHelp = JexlHelpUtils.getJexlHelpWebContainer("pwdJexlHelp");
-
- final AjaxLink<?> pwdQuestionMarkJexlHelp = JexlHelpUtils.getAjaxLink(pwdJexlHelp, "pwdQuestionMarkJexlHelp");
- add(pwdQuestionMarkJexlHelp);
- pwdQuestionMarkJexlHelp.add(pwdJexlHelp);
-
- FieldPanel<String> password;
- Label confirmPasswordLabel = new Label("confirmPasswordLabel", new ResourceModel("confirmPassword"));
- FieldPanel<String> confirmPassword;
- if (templateMode) {
- password = new AjaxTextFieldPanel("password", "password", new PropertyModel<String>(userTO, "password"));
-
- confirmPasswordLabel.setVisible(false);
- confirmPassword = new AjaxTextFieldPanel("confirmPassword", "confirmPassword", new Model<String>());
- confirmPassword.setEnabled(false);
- confirmPassword.setVisible(false);
- } else {
- pwdQuestionMarkJexlHelp.setVisible(false);
-
- password = new AjaxPasswordFieldPanel("password", "password",
- new PropertyModel<String>(userTO, "password"));
- ((PasswordTextField) password.getField()).setResetPassword(resetPassword);
-
- confirmPassword = new AjaxPasswordFieldPanel("confirmPassword", "confirmPassword", new Model<String>());
- if (!resetPassword) {
- confirmPassword.getField().setModelObject(userTO.getPassword());
- }
- ((PasswordTextField) confirmPassword.getField()).setResetPassword(resetPassword);
-
- form.add(new EqualPasswordInputValidator(password.getField(), confirmPassword.getField()));
- }
- add(password);
- add(confirmPasswordLabel);
- add(confirmPassword);
-
- final WebMarkupContainer mandatoryPassword = new WebMarkupContainer("mandatory_pwd");
- mandatoryPassword.add(new Behavior() {
-
- private static final long serialVersionUID = 1469628524240283489L;
-
- @Override
- public void onComponentTag(final Component component, final ComponentTag tag) {
- if (userTO.getKey() > 0) {
- tag.put("style", "display:none;");
- }
- }
- });
-
- add(mandatoryPassword);
- // ------------------------
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/UserSearchPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/UserSearchPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/UserSearchPanel.java
deleted file mode 100644
index 6618728..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/UserSearchPanel.java
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.List;
-import org.apache.syncope.client.console.rest.GroupRestClient;
-import org.apache.syncope.client.lib.SyncopeClient;
-import org.apache.syncope.common.lib.search.AbstractFiqlSearchConditionBuilder;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class UserSearchPanel extends AbstractSearchPanel {
-
- private static final long serialVersionUID = -1769527800450203738L;
-
- @SpringBean
- private GroupRestClient groupRestClient;
-
- public static class Builder implements Serializable {
-
- private static final long serialVersionUID = 6308997285778809578L;
-
- private String id;
-
- private String fiql = null;
-
- private boolean required = true;
-
- public Builder(final String id) {
- this.id = id;
- }
-
- public Builder fiql(final String fiql) {
- this.fiql = fiql;
- return this;
- }
-
- public Builder required(final boolean required) {
- this.required = required;
- return this;
- }
-
- public UserSearchPanel build() {
- return new UserSearchPanel(this);
- }
- }
-
- private UserSearchPanel(final Builder builder) {
- super(builder.id, AttributableType.USER, builder.fiql, builder.required);
- }
-
- @Override
- protected void populate() {
- super.populate();
-
- this.types = new LoadableDetachableModel<List<SearchClause.Type>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<SearchClause.Type> load() {
- List<SearchClause.Type> result = new ArrayList<SearchClause.Type>();
- result.add(SearchClause.Type.ATTRIBUTE);
- result.add(SearchClause.Type.MEMBERSHIP);
- result.add(SearchClause.Type.RESOURCE);
- return result;
- }
- };
-
- this.groupNames = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- List<GroupTO> groupTOs = groupRestClient.list();
-
- List<String> result = new ArrayList<>(groupTOs.size());
- for (GroupTO group : groupTOs) {
- result.add(group.getDisplayName());
- }
-
- return result;
- }
- };
- }
-
- @Override
- protected AbstractFiqlSearchConditionBuilder getSearchConditionBuilder() {
- return SyncopeClient.getUserSearchConditionBuilder();
- }
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/UserSearchResultPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/UserSearchResultPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/UserSearchResultPanel.java
deleted file mode 100644
index 132bb66..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/UserSearchResultPanel.java
+++ /dev/null
@@ -1,297 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.lang.reflect.Field;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.Date;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.pages.DisplayAttributesModalPage;
-import org.apache.syncope.client.console.pages.EditUserModalPage;
-import org.apache.syncope.client.console.pages.ResultStatusModalPage;
-import org.apache.syncope.client.console.pages.StatusModalPage;
-import org.apache.syncope.client.console.rest.AbstractSubjectRestClient;
-import org.apache.syncope.client.console.rest.SchemaRestClient;
-import org.apache.syncope.client.console.rest.UserRestClient;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.AttrColumn;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.TokenColumn;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink.ActionType;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.AbstractAttributableTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.syncope.common.lib.types.SchemaType;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.springframework.util.ReflectionUtils;
-
-public class UserSearchResultPanel extends AbstractSearchResultPanel {
-
- private static final long serialVersionUID = -905187144506842332L;
-
- private final static String PAGEID = "Users";
-
- @SpringBean
- private SchemaRestClient schemaRestClient;
-
- private final List<String> pSchemaNames;
-
- private final List<String> dSchemaNames;
-
- private final List<String> vSchemaNames;
-
- public <T extends AbstractAttributableTO> UserSearchResultPanel(final String id, final boolean filtered,
- final String fiql, final PageReference callerRef, final AbstractSubjectRestClient restClient) {
-
- super(id, filtered, fiql, callerRef, restClient);
-
- this.pSchemaNames = schemaRestClient.getPlainSchemaNames(AttributableType.USER);
- this.dSchemaNames = schemaRestClient.getDerSchemaNames(AttributableType.USER);
- this.vSchemaNames = schemaRestClient.getVirSchemaNames(AttributableType.USER);
-
- initResultTable();
- }
-
- @Override
- protected List<IColumn<AbstractAttributableTO, String>> getColumns() {
- final List<IColumn<AbstractAttributableTO, String>> columns = new ArrayList<>();
-
- for (String name : prefMan.getList(getRequest(), Constants.PREF_USERS_DETAILS_VIEW)) {
- final Field field = ReflectionUtils.findField(UserTO.class, name);
-
- if ("token".equalsIgnoreCase(name)) {
- columns.add(new TokenColumn("token"));
- } else if (field != null && field.getType().equals(Date.class)) {
- columns.add(new DatePropertyColumn<AbstractAttributableTO>(new ResourceModel(name, name), name, name));
- } else {
- columns.add(
- new PropertyColumn<AbstractAttributableTO, String>(new ResourceModel(name, name), name, name));
- }
- }
-
- for (String name : prefMan.getList(getRequest(), Constants.PREF_USERS_ATTRIBUTES_VIEW)) {
- if (pSchemaNames.contains(name)) {
- columns.add(new AttrColumn(name, SchemaType.PLAIN));
- }
- }
-
- for (String name : prefMan.getList(getRequest(), Constants.PREF_USERS_DERIVED_ATTRIBUTES_VIEW)) {
- if (dSchemaNames.contains(name)) {
- columns.add(new AttrColumn(name, SchemaType.DERIVED));
- }
- }
-
- for (String name : prefMan.getList(getRequest(), Constants.PREF_USERS_VIRTUAL_ATTRIBUTES_VIEW)) {
- if (vSchemaNames.contains(name)) {
- columns.add(new AttrColumn(name, SchemaType.VIRTUAL));
- }
- }
-
- // Add defaults in case of no selection
- if (columns.isEmpty()) {
- for (String name : DisplayAttributesModalPage.DEFAULT_SELECTION) {
- columns.add(
- new PropertyColumn<AbstractAttributableTO, String>(new ResourceModel(name, name), name, name));
- }
-
- prefMan.setList(getRequest(), getResponse(), Constants.PREF_USERS_DETAILS_VIEW,
- Arrays.asList(DisplayAttributesModalPage.DEFAULT_SELECTION));
- }
-
- columns.add(new ActionColumn<AbstractAttributableTO, String>(new ResourceModel("actions", "")) {
-
- private static final long serialVersionUID = -3503023501954863131L;
-
- @Override
- public ActionLinksPanel getActions(final String componentId, final IModel<AbstractAttributableTO> model) {
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, page.getPageReference());
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- statusmodal.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new StatusModalPage<UserTO>(
- page.getPageReference(), statusmodal, (UserTO) model.getObject());
- }
- });
-
- statusmodal.show(target);
- }
- }, ActionLink.ActionType.MANAGE_RESOURCES, PAGEID);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- statusmodal.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new StatusModalPage<UserTO>(
- page.getPageReference(), statusmodal, (UserTO) model.getObject(), true);
- }
- });
-
- statusmodal.show(target);
- }
- }, ActionLink.ActionType.ENABLE, PAGEID);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- editmodal.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- // SYNCOPE-294: re-read userTO before edit
- UserTO userTO = ((UserRestClient) restClient).read(model.getObject().getKey());
- return new EditUserModalPage(page.getPageReference(), editmodal, userTO);
- }
- });
-
- editmodal.show(target);
- }
- }, ActionLink.ActionType.EDIT, PAGEID);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- final UserTO userTO = (UserTO) restClient.
- delete(model.getObject().getETagValue(), model.getObject().getKey());
-
- page.setModalResult(true);
-
- editmodal.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ResultStatusModalPage.Builder(editmodal, userTO).build();
- }
- });
-
- editmodal.show(target);
- } catch (SyncopeClientException scce) {
- error(getString(Constants.OPERATION_ERROR) + ": " + scce.getMessage());
- feedbackPanel.refresh(target);
- }
- }
- }, ActionLink.ActionType.DELETE, PAGEID);
-
- return panel;
- }
-
- @Override
- public ActionLinksPanel getHeader(final String componentId) {
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), page.getPageReference());
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- displaymodal.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new DisplayAttributesModalPage(page.getPageReference(), displaymodal,
- pSchemaNames, dSchemaNames, vSchemaNames);
- }
- });
-
- displaymodal.show(target);
- }
- }, ActionLink.ActionType.CHANGE_VIEW, PAGEID);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- if (target != null) {
- target.add(container);
- }
- }
- }, ActionLink.ActionType.RELOAD, PAGEID, "list");
-
- return panel;
- }
- });
-
- return columns;
- }
-
- @Override
- protected <T extends AbstractAttributableTO> Collection<ActionType> getBulkActions() {
- final List<ActionType> bulkActions = new ArrayList<ActionType>();
-
- bulkActions.add(ActionType.DELETE);
- bulkActions.add(ActionType.SUSPEND);
- bulkActions.add(ActionType.REACTIVATE);
-
- return bulkActions;
- }
-
- @Override
- protected String getPageId() {
- return PAGEID;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/VirAttrsPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/VirAttrsPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/VirAttrsPanel.java
deleted file mode 100644
index 84049f0..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/VirAttrsPanel.java
+++ /dev/null
@@ -1,294 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.HashSet;
-import java.util.List;
-import java.util.ListIterator;
-import java.util.Map;
-import java.util.Set;
-import java.util.TreeMap;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.panels.AttrTemplatesPanel.GroupAttrTemplatesChange;
-import org.apache.syncope.client.console.rest.GroupRestClient;
-import org.apache.syncope.client.console.rest.SchemaRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDecoratedCheckbox;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel;
-import org.apache.syncope.common.lib.to.AbstractAttributableTO;
-import org.apache.syncope.common.lib.to.AttrTO;
-import org.apache.syncope.common.lib.to.MembershipTO;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.syncope.common.lib.to.VirSchemaTO;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.wicket.Component;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.attributes.AjaxCallListener;
-import org.apache.wicket.ajax.attributes.AjaxRequestAttributes;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.ChoiceRenderer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class VirAttrsPanel extends Panel {
-
- private static final long serialVersionUID = -7982691107029848579L;
-
- @SpringBean
- private SchemaRestClient schemaRestClient;
-
- @SpringBean
- private GroupRestClient groupRestClient;
-
- private final AttrTemplatesPanel attrTemplates;
-
- private final Map<String, VirSchemaTO> schemas = new TreeMap<String, VirSchemaTO>();
-
- public <T extends AbstractAttributableTO> VirAttrsPanel(final String id, final T entityTO,
- final boolean templateMode) {
-
- this(id, entityTO, templateMode, null);
- }
-
- public <T extends AbstractAttributableTO> VirAttrsPanel(final String id, final T entityTO,
- final boolean templateMode, final AttrTemplatesPanel attrTemplates) {
-
- super(id);
- this.attrTemplates = attrTemplates;
- this.setOutputMarkupId(true);
-
- final IModel<List<String>> virSchemas = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- private void filter(final List<VirSchemaTO> schemaTOs, final Set<String> allowed) {
- for (ListIterator<VirSchemaTO> itor = schemaTOs.listIterator(); itor.hasNext();) {
- VirSchemaTO schema = itor.next();
- if (!allowed.contains(schema.getKey())) {
- itor.remove();
- }
- }
- }
-
- @Override
- protected List<String> load() {
- List<VirSchemaTO> schemaTOs;
-
- if (entityTO instanceof GroupTO) {
- final GroupTO groupTO = (GroupTO) entityTO;
-
- schemaTOs = schemaRestClient.getVirSchemas(AttributableType.GROUP);
- Set<String> allowed;
- if (attrTemplates == null) {
- allowed = new HashSet<>(groupTO.getGVirAttrTemplates());
- } else {
- allowed = new HashSet<>(attrTemplates.getSelected(AttrTemplatesPanel.Type.gVirAttrTemplates));
- if (groupTO.isInheritTemplates() && groupTO.getParent() != 0) {
- allowed.addAll(groupRestClient.read(groupTO.getParent()).getGVirAttrTemplates());
- }
- }
- filter(schemaTOs, allowed);
- } else if (entityTO instanceof UserTO) {
- schemaTOs = schemaRestClient.getVirSchemas(AttributableType.USER);
- } else {
- schemaTOs = schemaRestClient.getVirSchemas(AttributableType.MEMBERSHIP);
- Set<String> allowed = new HashSet<String>(
- groupRestClient.read(((MembershipTO) entityTO).getGroupKey()).getMVirAttrTemplates());
- filter(schemaTOs, allowed);
- }
-
- schemas.clear();
-
- for (VirSchemaTO schemaTO : schemaTOs) {
- schemas.put(schemaTO.getKey(), schemaTO);
- }
-
- return new ArrayList<>(schemas.keySet());
- }
- };
-
- final WebMarkupContainer attributesContainer = new WebMarkupContainer("virAttrContainer");
- attributesContainer.setOutputMarkupId(true);
- add(attributesContainer);
-
- AjaxButton addAttributeBtn = new IndicatingAjaxButton("addAttributeBtn", new ResourceModel("addAttributeBtn")) {
-
- private static final long serialVersionUID = -4804368561204623354L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- entityTO.getVirAttrs().add(new AttrTO());
- target.add(attributesContainer);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- target.add(attributesContainer);
- }
- };
-
- add(addAttributeBtn.setDefaultFormProcessing(Boolean.FALSE));
-
- ListView<AttrTO> attributes = new ListView<AttrTO>("attrs",
- new PropertyModel<List<? extends AttrTO>>(entityTO, "virAttrs")) {
-
- private static final long serialVersionUID = 9101744072914090143L;
-
- @Override
- @SuppressWarnings("unchecked")
- protected void populateItem(final ListItem<AttrTO> item) {
- final AttrTO attributeTO = item.getModelObject();
-
- item.add(new AjaxDecoratedCheckbox("toRemove", new Model<Boolean>(Boolean.FALSE)) {
-
- private static final long serialVersionUID = 7170946748485726506L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- entityTO.getVirAttrs().remove(attributeTO);
- target.add(attributesContainer);
- }
-
- @Override
- protected void updateAjaxAttributes(final AjaxRequestAttributes attributes) {
- super.updateAjaxAttributes(attributes);
-
- final AjaxCallListener ajaxCallListener = new AjaxCallListener() {
-
- private static final long serialVersionUID = 7160235486520935153L;
-
- @Override
- public CharSequence getPrecondition(final Component component) {
- return "if (!confirm('" + getString("confirmDelete") + "')) return false;";
- }
- };
- attributes.getAjaxCallListeners().add(ajaxCallListener);
- }
- });
-
- if (attributeTO.getValues().isEmpty()) {
- attributeTO.getValues().add("");
- }
-
- if (attributeTO.getSchema() != null) {
- VirSchemaTO attributeSchema = schemas.get(attributeTO.getSchema());
- if (attributeSchema != null) {
- attributeTO.setReadonly(attributeSchema.isReadonly());
- }
- }
-
- final AjaxTextFieldPanel panel;
- final MultiFieldPanel multiPanel;
- if (templateMode) {
- panel = new AjaxTextFieldPanel("values", "values", new Model<String>());
- panel.setReadOnly(attributeTO.isReadonly());
- multiPanel = null;
- } else {
- panel = new AjaxTextFieldPanel("panel", "values", new Model<String>(null));
- panel.setReadOnly(attributeTO.isReadonly());
- multiPanel = new MultiFieldPanel("values",
- new PropertyModel<List<String>>(attributeTO, "values"), panel);
- }
-
- final DropDownChoice<String> schemaChoice = new DropDownChoice<String>("schema",
- new PropertyModel<String>(attributeTO, "schema"), virSchemas,
- new ChoiceRenderer<String>() {
-
- private static final long serialVersionUID = 3109256773218160485L;
-
- @Override
- public Object getDisplayValue(final String object) {
- final StringBuilder text = new StringBuilder(object);
- if (templateMode) {
- text.append(" (JEXL)");
- }
- return text.toString();
- }
- });
-
- schemaChoice.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_BLUR) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- attributeTO.setSchema(schemaChoice.getModelObject());
-
- VirSchemaTO virSchema = schemas.get(attributeTO.getSchema());
- if (virSchema != null) {
- attributeTO.setReadonly(virSchema.isReadonly());
- panel.setReadOnly(attributeTO.isReadonly());
- }
-
- if (multiPanel != null) {
- multiPanel.getView().setEnabled(false);
- }
- }
- });
-
- schemaChoice.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- target.add(attributesContainer);
- }
- });
-
- schemaChoice.setOutputMarkupId(true);
- schemaChoice.setRequired(true);
- item.add(schemaChoice);
-
- if (templateMode) {
- item.add(panel);
- } else {
- item.add(multiPanel);
- }
- }
- };
-
- attributesContainer.add(attributes);
- }
-
- @Override
- public void onEvent(final IEvent<?> event) {
- if ((event.getPayload() instanceof GroupAttrTemplatesChange)) {
- final GroupAttrTemplatesChange update = (GroupAttrTemplatesChange) event.getPayload();
- if (attrTemplates != null && update.getType() == AttrTemplatesPanel.Type.gVirAttrTemplates) {
- update.getTarget().add(this);
- }
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/resources/FilesystemResource.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/resources/FilesystemResource.java b/client/console/src/main/java/org/apache/syncope/client/console/resources/FilesystemResource.java
deleted file mode 100644
index 8a95de6..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/resources/FilesystemResource.java
+++ /dev/null
@@ -1,83 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.resources;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.IOException;
-import org.apache.wicket.request.resource.AbstractResource;
-import org.apache.wicket.util.io.IOUtils;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-/**
- * Mounts directory on local filesystem as subcontext.
- */
-public class FilesystemResource extends AbstractResource {
-
- private static final long serialVersionUID = -4791087117785935198L;
-
- /**
- * Logger.
- */
- private static final Logger LOG = LoggerFactory.getLogger(FilesystemResource.class);
-
- private final String baseCtx;
-
- private final String basePath;
-
- public FilesystemResource(final String baseCtx, final String basePath) {
- this.baseCtx = baseCtx;
- this.basePath = basePath;
- }
-
- @Override
- protected ResourceResponse newResourceResponse(final Attributes attributes) {
- ResourceResponse response = new ResourceResponse();
-
- final File baseDir = new File(basePath);
- if (baseDir.exists() && baseDir.canRead() && baseDir.isDirectory()) {
- String reqPath = attributes.getRequest().getUrl().getPath();
- final String subPath = reqPath.substring(reqPath.indexOf(baseCtx) + baseCtx.length()).
- replace('/', File.separatorChar);
- LOG.debug("Request for {}", subPath);
-
- response.setWriteCallback(new WriteCallback() {
-
- @Override
- public void writeData(final Attributes attributes) throws IOException {
- FileInputStream resourceIS = null;
- try {
- resourceIS = new FileInputStream(new File(baseDir, subPath));
- IOUtils.copy(resourceIS, attributes.getResponse().getOutputStream());
- } catch (IOException e) {
- LOG.error("Could not read from {}", baseDir.getAbsolutePath() + subPath, e);
- } finally {
- IOUtils.closeQuietly(resourceIS);
- }
- }
- });
- } else {
- LOG.error("{} not found, not readable or not a directory", basePath);
- }
-
- return response;
- }
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/resources/WorkflowDefGETResource.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/resources/WorkflowDefGETResource.java b/client/console/src/main/java/org/apache/syncope/client/console/resources/WorkflowDefGETResource.java
deleted file mode 100644
index 2104745..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/resources/WorkflowDefGETResource.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.resources;
-
-import java.io.IOException;
-import javax.ws.rs.core.MediaType;
-import org.apache.syncope.client.console.rest.WorkflowRestClient;
-import org.apache.wicket.protocol.http.WebApplication;
-import org.apache.wicket.request.resource.AbstractResource;
-import org.apache.wicket.util.io.IOUtils;
-import org.springframework.web.context.support.WebApplicationContextUtils;
-
-/**
- * Mirror REST resource for obtaining user workflow definition in JSON (used by Activiti Modeler).
- *
- * @see org.apache.syncope.common.services.WorkflowService#exportDefinition(org.apache.syncope.common.types.SubjectType)
- */
-public class WorkflowDefGETResource extends AbstractResource {
-
- private static final long serialVersionUID = 4637304868056148970L;
-
- @Override
- protected ResourceResponse newResourceResponse(final Attributes attributes) {
- ResourceResponse response = new ResourceResponse();
- response.disableCaching();
- response.setContentType(MediaType.APPLICATION_JSON);
-
- response.setWriteCallback(new WriteCallback() {
-
- @Override
- public void writeData(final Attributes attributes) throws IOException {
- IOUtils.copy(WebApplicationContextUtils.getWebApplicationContext(
- WebApplication.get().getServletContext()).getBean(WorkflowRestClient.class).
- getDefinition(MediaType.APPLICATION_JSON_TYPE),
- attributes.getResponse().getOutputStream());
- }
- });
-
- return response;
- }
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/resources/WorkflowDefPUTResource.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/resources/WorkflowDefPUTResource.java b/client/console/src/main/java/org/apache/syncope/client/console/resources/WorkflowDefPUTResource.java
deleted file mode 100644
index add6485..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/resources/WorkflowDefPUTResource.java
+++ /dev/null
@@ -1,74 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.resources;
-
-import java.io.IOException;
-import javax.servlet.http.HttpServletRequest;
-import javax.ws.rs.core.MediaType;
-import org.apache.cxf.common.util.UrlUtils;
-import org.apache.syncope.client.console.rest.WorkflowRestClient;
-import org.apache.wicket.protocol.http.WebApplication;
-import org.apache.wicket.request.resource.AbstractResource;
-import org.apache.wicket.util.io.IOUtils;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.springframework.web.context.support.WebApplicationContextUtils;
-
-/**
- * Mirror REST resource for putting user workflow definition in JSON (used by Activiti Modeler).
- *
- * @see org.apache.syncope.common.services.WorkflowService#importDefinition(
- * org.apache.syncope.common.types.SubjectType, java.lang.String)
- */
-public class WorkflowDefPUTResource extends AbstractResource {
-
- private static final long serialVersionUID = 2964542005207297944L;
-
- /**
- * Logger.
- */
- private static final Logger LOG = LoggerFactory.getLogger(WorkflowDefPUTResource.class);
-
- @Override
- protected ResourceResponse newResourceResponse(final Attributes attributes) {
- String definition = null;
- try {
- HttpServletRequest request = (HttpServletRequest) attributes.getRequest().getContainerRequest();
- String requestBody = IOUtils.toString(request.getInputStream());
- String[] split = requestBody.split("&");
- for (int i = 0; i < split.length && definition == null; i++) {
- String keyValue = split[i];
- if (keyValue.startsWith("json_xml=")) {
- definition = UrlUtils.urlDecode(keyValue.split("=")[1]);
- }
- }
- } catch (IOException e) {
- LOG.error("Could not extract workflow definition from request", e);
- }
-
- WebApplicationContextUtils.getWebApplicationContext(WebApplication.get().getServletContext()).
- getBean(WorkflowRestClient.class).
- updateDefinition(MediaType.APPLICATION_JSON_TYPE, definition);
-
- ResourceResponse response = new ResourceResponse();
- response.setStatusCode(204);
- return response;
- }
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/AbstractSubjectRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/AbstractSubjectRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/AbstractSubjectRestClient.java
index a18a0a9..4b64b30 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/AbstractSubjectRestClient.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/rest/AbstractSubjectRestClient.java
@@ -29,18 +29,19 @@ public abstract class AbstractSubjectRestClient extends BaseRestClient {
private static final long serialVersionUID = 1962529678091410544L;
- public abstract int count();
+ public abstract int count(String realm);
- public abstract List<? extends AbstractAttributableTO> list(int page, int size, final SortParam<String> sort);
+ public abstract List<? extends AbstractAttributableTO> list(
+ String realm, int page, int size, final SortParam<String> sort);
- public abstract int searchCount(String fiql);
+ public abstract int searchCount(String realm, String fiql);
- public abstract List<? extends AbstractAttributableTO> search(String fiql,
- int page, int size, final SortParam<String> sort);
+ public abstract List<? extends AbstractAttributableTO> search(
+ String realm, String fiql, int page, int size, final SortParam<String> sort);
- public abstract ConnObjectTO getConnectorObject(String resourceName, Long id);
+ public abstract ConnObjectTO getConnectorObject(String resourceName, Long key);
- public abstract AbstractAttributableTO delete(String etag, Long id);
+ public abstract AbstractAttributableTO delete(String etag, Long key);
public abstract BulkActionResult bulkAction(BulkAction action);
}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/ApprovalRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/ApprovalRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/ApprovalRestClient.java
index dc9d12f..b0a19aa 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/ApprovalRestClient.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/rest/ApprovalRestClient.java
@@ -35,8 +35,8 @@ public class ApprovalRestClient extends BaseRestClient {
return getService(UserWorkflowService.class).getForms();
}
- public WorkflowFormTO claimForm(final String taskId) {
- return getService(UserWorkflowService.class).claimForm(taskId);
+ public WorkflowFormTO claimForm(final String taskKey) {
+ return getService(UserWorkflowService.class).claimForm(taskKey);
}
public void submitForm(final WorkflowFormTO form) {
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/rest/AuthRestClient.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/rest/AuthRestClient.java b/client/console/src/main/java/org/apache/syncope/client/console/rest/AuthRestClient.java
deleted file mode 100644
index 01e6838..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/rest/AuthRestClient.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.rest;
-
-import java.util.ArrayList;
-import java.util.List;
-import org.apache.syncope.common.rest.api.CollectionWrapper;
-import org.apache.syncope.common.rest.api.service.EntitlementService;
-import org.springframework.stereotype.Component;
-
-/**
- * Console client for invoking Rest Resources services.
- */
-@Component
-public class AuthRestClient extends BaseRestClient {
-
- private static final long serialVersionUID = 2999780105004742914L;
-
- public List<String> getAllEntitlements() {
- return new ArrayList<>(
- CollectionWrapper.unwrap(getService(EntitlementService.class).getAllEntitlements()));
- }
-
- public List<String> getOwnedEntitlements() {
- return new ArrayList<>(
- CollectionWrapper.unwrap(getService(EntitlementService.class).getOwnEntitlements()));
- }
-}
[22/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.java
new file mode 100644
index 0000000..ebc041d
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.java
@@ -0,0 +1,103 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.Mode;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPasswordFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.FieldPanel;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.form.PasswordTextField;
+import org.apache.wicket.markup.html.form.StatelessForm;
+import org.apache.wicket.markup.html.form.validation.EqualPasswordInputValidator;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.ResourceModel;
+
+public class ConfirmPasswordResetModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = -8419445804421211904L;
+
+ public ConfirmPasswordResetModalPage(final ModalWindow window, final String token) {
+ super();
+ setOutputMarkupId(true);
+
+ final StatelessForm<?> form = new StatelessForm<Object>(FORM);
+ form.setOutputMarkupId(true);
+
+ final FieldPanel<String> password =
+ new AjaxPasswordFieldPanel("password", "password", new Model<String>()).setRequired(true);
+ ((PasswordTextField) password.getField()).setResetPassword(true);
+ form.add(password);
+
+ final FieldPanel<String> confirmPassword =
+ new AjaxPasswordFieldPanel("confirmPassword", "confirmPassword", new Model<String>());
+ ((PasswordTextField) confirmPassword.getField()).setResetPassword(true);
+ form.add(confirmPassword);
+
+ form.add(new EqualPasswordInputValidator(password.getField(), confirmPassword.getField()));
+
+ final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(SUBMIT, SUBMIT)) {
+
+ private static final long serialVersionUID = -4804368561204623354L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ try {
+ userSelfRestClient.confirmPasswordReset(token, password.getModelObject());
+
+ setResponsePage(new ResultStatusModalPage.Builder(window, new UserTO()).mode(Mode.SELF).build());
+ } catch (Exception e) {
+ LOG.error("While confirming password reset for {}", token, e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+ form.add(submit);
+ form.setDefaultButton(submit);
+
+ final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ }
+ };
+ cancel.setDefaultFormProcessing(false);
+ form.add(cancel);
+
+ add(form);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ConnObjectModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ConnObjectModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ConnObjectModalPage.java
new file mode 100644
index 0000000..cf1c405
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ConnObjectModalPage.java
@@ -0,0 +1,101 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.Collections;
+import java.util.Comparator;
+import java.util.List;
+import org.apache.syncope.common.lib.to.AttrTO;
+import org.apache.syncope.common.lib.to.ConnObjectTO;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.list.AltListView;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.util.ListModel;
+
+public class ConnObjectModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = -6469290753080058487L;
+
+ public ConnObjectModalPage(final ConnObjectTO connObjectTO) {
+ super();
+
+ final Form<Void> form = new Form<Void>(FORM);
+ form.setEnabled(false);
+ add(form);
+
+ IModel<List<AttrTO>> formProps = new LoadableDetachableModel<List<AttrTO>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<AttrTO> load() {
+ List<AttrTO> attrs = connObjectTO.getPlainAttrs();
+ Collections.sort(attrs, new Comparator<AttrTO>() {
+
+ @Override
+ public int compare(final AttrTO attr1, final AttrTO attr2) {
+ if (attr1 == null || attr1.getSchema() == null) {
+ return -1;
+ }
+ if (attr2 == null || attr2.getSchema() == null) {
+ return 1;
+ }
+ return attr1.getSchema().compareTo(attr2.getSchema());
+ }
+ });
+
+ return attrs;
+ }
+ };
+ final ListView<AttrTO> propView = new AltListView<AttrTO>("propView", formProps) {
+
+ private static final long serialVersionUID = 3109256773218160485L;
+
+ @Override
+ protected void populateItem(final ListItem<AttrTO> item) {
+ final AttrTO prop = item.getModelObject();
+
+ Label label = new Label("key", prop.getSchema());
+ item.add(label);
+
+ Panel field;
+ if (prop.getValues().isEmpty()) {
+ field = new AjaxTextFieldPanel("value",
+ prop.getSchema(), new Model<String>());
+ } else if (prop.getValues().size() == 1) {
+ field = new AjaxTextFieldPanel("value",
+ prop.getSchema(), new Model<String>(prop.getValues().get(0)));
+ } else {
+ field = new MultiFieldPanel<String>("value", new ListModel<String>(prop.getValues()),
+ new AjaxTextFieldPanel("panel", prop.getSchema(), new Model<String>()));
+ }
+ item.add(field);
+ }
+ };
+ form.add(propView);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ConnectorModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ConnectorModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ConnectorModalPage.java
new file mode 100644
index 0000000..8095591
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ConnectorModalPage.java
@@ -0,0 +1,479 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.EnumSet;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.rest.ConnectorRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.SpinnerFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.list.ConnConfPropertyListView;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.ConnBundleTO;
+import org.apache.syncope.common.lib.to.ConnInstanceTO;
+import org.apache.syncope.common.lib.to.ConnPoolConfTO;
+import org.apache.syncope.common.lib.types.ConnConfPropSchema;
+import org.apache.syncope.common.lib.types.ConnConfProperty;
+import org.apache.syncope.common.lib.types.ConnectorCapability;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormChoiceComponentUpdatingBehavior;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.CheckBoxMultipleChoice;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.apache.wicket.validation.validator.RangeValidator;
+
+/**
+ * Modal window with Connector form.
+ */
+public class ConnectorModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = -2025535531121434050L;
+
+ @SpringBean
+ private ConnectorRestClient restClient;
+
+ private final Map<String, Map<String, Map<String, ConnBundleTO>>> mapConnBundleTOs;
+
+ private final List<ConnectorCapability> selectedCapabilities;
+
+ private ConnBundleTO bundleTO;
+
+ private List<ConnConfProperty> properties;
+
+ private final WebMarkupContainer propertiesContainer;
+
+ public ConnectorModalPage(final PageReference pageRef, final ModalWindow window,
+ final ConnInstanceTO connInstanceTO) {
+
+ super();
+
+ this.add(new Label("new", connInstanceTO.getKey() == 0
+ ? new ResourceModel("new")
+ : new Model<>(StringUtils.EMPTY)));
+ this.add(new Label("key", connInstanceTO.getKey() == 0
+ ? StringUtils.EMPTY
+ : connInstanceTO.getKey()));
+
+ // general data setup
+ selectedCapabilities = new ArrayList<>(connInstanceTO.getKey() == 0
+ ? EnumSet.noneOf(ConnectorCapability.class)
+ : connInstanceTO.getCapabilities());
+
+ mapConnBundleTOs = new HashMap<>();
+ for (ConnBundleTO connBundleTO : restClient.getAllBundles()) {
+ // by location
+ if (!mapConnBundleTOs.containsKey(connBundleTO.getLocation())) {
+ mapConnBundleTOs.put(connBundleTO.getLocation(), new HashMap<String, Map<String, ConnBundleTO>>());
+ }
+ final Map<String, Map<String, ConnBundleTO>> byLocation = mapConnBundleTOs.get(connBundleTO.getLocation());
+
+ // by name
+ if (!byLocation.containsKey(connBundleTO.getBundleName())) {
+ byLocation.put(connBundleTO.getBundleName(), new HashMap<String, ConnBundleTO>());
+ }
+ final Map<String, ConnBundleTO> byName = byLocation.get(connBundleTO.getBundleName());
+
+ // by version
+ if (!byName.containsKey(connBundleTO.getVersion())) {
+ byName.put(connBundleTO.getVersion(), connBundleTO);
+ }
+ }
+
+ bundleTO = getSelectedBundleTO(connInstanceTO);
+ properties = fillProperties(bundleTO, connInstanceTO);
+
+ // form - first tab
+ final Form<ConnInstanceTO> connectorForm = new Form<>(FORM);
+ connectorForm.setModel(new CompoundPropertyModel<>(connInstanceTO));
+ connectorForm.setOutputMarkupId(true);
+ add(connectorForm);
+
+ propertiesContainer = new WebMarkupContainer("container");
+ propertiesContainer.setOutputMarkupId(true);
+ connectorForm.add(propertiesContainer);
+
+ final Form<ConnInstanceTO> connectorPropForm = new Form<>("connectorPropForm");
+ connectorPropForm.setModel(new CompoundPropertyModel<>(connInstanceTO));
+ connectorPropForm.setOutputMarkupId(true);
+ propertiesContainer.add(connectorPropForm);
+
+ final AjaxTextFieldPanel displayName = new AjaxTextFieldPanel(
+ "displayName", "display name", new PropertyModel<String>(connInstanceTO, "displayName"));
+ displayName.setOutputMarkupId(true);
+ displayName.addRequiredLabel();
+ connectorForm.add(displayName);
+
+ final AjaxDropDownChoicePanel<String> location =
+ new AjaxDropDownChoicePanel<>("location", "location",
+ new Model<>(bundleTO == null ? null : bundleTO.getLocation()));
+ ((DropDownChoice<String>) location.getField()).setNullValid(true);
+ location.setStyleSheet("long_dynamicsize");
+ location.setChoices(new ArrayList<>(mapConnBundleTOs.keySet()));
+ location.setRequired(true);
+ location.addRequiredLabel();
+ location.setOutputMarkupId(true);
+ location.setEnabled(connInstanceTO.getKey() == 0);
+ location.getField().setOutputMarkupId(true);
+ connectorForm.add(location);
+
+ final AjaxDropDownChoicePanel<String> connectorName =
+ new AjaxDropDownChoicePanel<>("connectorName", "connectorName",
+ new Model<>(bundleTO == null ? null : bundleTO.getBundleName()));
+ ((DropDownChoice<String>) connectorName.getField()).setNullValid(true);
+ connectorName.setStyleSheet("long_dynamicsize");
+ connectorName.setChoices(bundleTO == null
+ ? new ArrayList<String>()
+ : new ArrayList<>(mapConnBundleTOs.get(connInstanceTO.getLocation()).keySet()));
+ connectorName.setRequired(true);
+ connectorName.addRequiredLabel();
+ connectorName.setEnabled(connInstanceTO.getLocation() != null);
+ connectorName.setOutputMarkupId(true);
+ connectorName.setEnabled(connInstanceTO.getKey() == 0);
+ connectorName.getField().setOutputMarkupId(true);
+ connectorForm.add(connectorName);
+
+ final AjaxDropDownChoicePanel<String> version =
+ new AjaxDropDownChoicePanel<>("version", "version",
+ new Model<>(bundleTO == null ? null : bundleTO.getVersion()));
+ version.setStyleSheet("long_dynamicsize");
+ version.setChoices(bundleTO == null
+ ? new ArrayList<String>()
+ : new ArrayList<>(mapConnBundleTOs.get(connInstanceTO.getLocation()).
+ get(connInstanceTO.getBundleName()).keySet()));
+ version.setRequired(true);
+ version.addRequiredLabel();
+ version.setEnabled(connInstanceTO.getBundleName() != null);
+ version.setOutputMarkupId(true);
+ version.addRequiredLabel();
+ version.getField().setOutputMarkupId(true);
+ connectorForm.add(version);
+
+ final SpinnerFieldPanel<Integer> connRequestTimeout =
+ new SpinnerFieldPanel<>("connRequestTimeout", "connRequestTimeout", Integer.class,
+ new PropertyModel<Integer>(connInstanceTO, "connRequestTimeout"), 0, null);
+ connRequestTimeout.getField().add(new RangeValidator<>(0, Integer.MAX_VALUE));
+ connectorForm.add(connRequestTimeout);
+
+ if (connInstanceTO.getPoolConf() == null) {
+ connInstanceTO.setPoolConf(new ConnPoolConfTO());
+ }
+ final SpinnerFieldPanel<Integer> poolMaxObjects =
+ new SpinnerFieldPanel<>("poolMaxObjects", "poolMaxObjects", Integer.class,
+ new PropertyModel<Integer>(connInstanceTO.getPoolConf(), "maxObjects"), 0, null);
+ poolMaxObjects.getField().add(new RangeValidator<>(0, Integer.MAX_VALUE));
+ connectorForm.add(poolMaxObjects);
+ final SpinnerFieldPanel<Integer> poolMinIdle =
+ new SpinnerFieldPanel<>("poolMinIdle", "poolMinIdle", Integer.class,
+ new PropertyModel<Integer>(connInstanceTO.getPoolConf(), "minIdle"), 0, null);
+ poolMinIdle.getField().add(new RangeValidator<>(0, Integer.MAX_VALUE));
+ connectorForm.add(poolMinIdle);
+ final SpinnerFieldPanel<Integer> poolMaxIdle =
+ new SpinnerFieldPanel<>("poolMaxIdle", "poolMaxIdle", Integer.class,
+ new PropertyModel<Integer>(connInstanceTO.getPoolConf(), "maxIdle"), 0, null);
+ poolMaxIdle.getField().add(new RangeValidator<>(0, Integer.MAX_VALUE));
+ connectorForm.add(poolMaxIdle);
+ final SpinnerFieldPanel<Long> poolMaxWait =
+ new SpinnerFieldPanel<>("poolMaxWait", "poolMaxWait", Long.class,
+ new PropertyModel<Long>(connInstanceTO.getPoolConf(), "maxWait"), 0L, null);
+ poolMaxWait.getField().add(new RangeValidator<>(0L, Long.MAX_VALUE));
+ connectorForm.add(poolMaxWait);
+ final SpinnerFieldPanel<Long> poolMinEvictableIdleTime =
+ new SpinnerFieldPanel<>("poolMinEvictableIdleTime", "poolMinEvictableIdleTime", Long.class,
+ new PropertyModel<Long>(connInstanceTO.getPoolConf(), "minEvictableIdleTimeMillis"),
+ 0L, null);
+ poolMinEvictableIdleTime.getField().add(new RangeValidator<>(0L, Long.MAX_VALUE));
+ connectorForm.add(poolMinEvictableIdleTime);
+
+ // form - first tab - onchange()
+ location.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ ((DropDownChoice<String>) location.getField()).setNullValid(false);
+ connInstanceTO.setLocation(location.getModelObject());
+ target.add(location);
+
+ connectorName.setChoices(new ArrayList<>(
+ mapConnBundleTOs.get(location.getModelObject()).keySet()));
+ connectorName.setEnabled(true);
+ connectorName.getField().setModelValue(null);
+ target.add(connectorName);
+
+ version.setChoices(new ArrayList<String>());
+ version.getField().setModelValue(null);
+ version.setEnabled(false);
+ target.add(version);
+
+ properties.clear();
+ target.add(propertiesContainer);
+ }
+ });
+ connectorName.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ ((DropDownChoice<String>) connectorName.getField()).setNullValid(false);
+ connInstanceTO.setBundleName(connectorName.getModelObject());
+ target.add(connectorName);
+
+ List<String> versions = new ArrayList<>(
+ mapConnBundleTOs.get(location.getModelObject()).get(connectorName.getModelObject()).keySet());
+ version.setChoices(versions);
+ version.setEnabled(true);
+ if (versions.size() == 1) {
+ selectVersion(target, connInstanceTO, version, versions.get(0));
+ version.getField().setModelObject(versions.get(0));
+ } else {
+ version.getField().setModelValue(null);
+ properties.clear();
+ target.add(propertiesContainer);
+ }
+ target.add(version);
+ }
+ });
+ version.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ selectVersion(target, connInstanceTO, version, version.getModelObject());
+ }
+ });
+
+ // form - second tab (properties)
+ final ListView<ConnConfProperty> connPropView = new ConnConfPropertyListView("connectorProperties",
+ new PropertyModel<List<ConnConfProperty>>(this, "properties"),
+ true, connInstanceTO.getConfiguration());
+ connPropView.setOutputMarkupId(true);
+ connectorPropForm.add(connPropView);
+
+ final AjaxButton check = new IndicatingAjaxButton("check", new ResourceModel("check")) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ final ConnInstanceTO conn = (ConnInstanceTO) form.getModelObject();
+
+ // ensure that connector bundle information is in sync
+ conn.setBundleName(bundleTO.getBundleName());
+ conn.setVersion(bundleTO.getVersion());
+ conn.setConnectorName(bundleTO.getConnectorName());
+
+ if (restClient.check(conn)) {
+ info(getString("success_connection"));
+ } else {
+ error(getString("error_connection"));
+ }
+
+ feedbackPanel.refresh(target);
+ }
+ };
+ connectorPropForm.add(check);
+
+ // form - third tab (capabilities)
+ final IModel<List<ConnectorCapability>> capabilities =
+ new LoadableDetachableModel<List<ConnectorCapability>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<ConnectorCapability> load() {
+ return Arrays.asList(ConnectorCapability.values());
+ }
+ };
+ CheckBoxMultipleChoice<ConnectorCapability> capabilitiesPalette =
+ new CheckBoxMultipleChoice<>("capabilitiesPalette",
+ new PropertyModel<List<ConnectorCapability>>(this, "selectedCapabilities"), capabilities);
+
+ capabilitiesPalette.add(new AjaxFormChoiceComponentUpdatingBehavior() {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(AjaxRequestTarget target) {
+ }
+ });
+
+ connectorForm.add(capabilitiesPalette);
+
+ // form - submit / cancel buttons
+ final AjaxButton submit = new IndicatingAjaxButton(APPLY, new Model<>(getString(SUBMIT))) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ final ConnInstanceTO conn = (ConnInstanceTO) form.getModelObject();
+
+ conn.setConnectorName(bundleTO.getConnectorName());
+ conn.setBundleName(bundleTO.getBundleName());
+ conn.setVersion(bundleTO.getVersion());
+ conn.getConfiguration().clear();
+ conn.getConfiguration().addAll(connPropView.getModelObject());
+
+ // Set the model object's capabilities to capabilitiesPalette's converted Set
+ conn.getCapabilities().clear();
+ conn.getCapabilities().addAll(selectedCapabilities.isEmpty()
+ ? EnumSet.noneOf(ConnectorCapability.class)
+ : EnumSet.copyOf(selectedCapabilities));
+
+ // Reset pool configuration if all fields are null
+ if (conn.getPoolConf() != null
+ && conn.getPoolConf().getMaxIdle() == null
+ && conn.getPoolConf().getMaxObjects() == null
+ && conn.getPoolConf().getMaxWait() == null
+ && conn.getPoolConf().getMinEvictableIdleTimeMillis() == null
+ && conn.getPoolConf().getMinIdle() == null) {
+
+ conn.setPoolConf(null);
+ }
+
+ try {
+ if (connInstanceTO.getKey() == 0) {
+ restClient.create(conn);
+ } else {
+ restClient.update(conn);
+ }
+
+ ((Resources) pageRef.getPage()).setModalResult(true);
+ window.close(target);
+ } catch (SyncopeClientException e) {
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ ((Resources) pageRef.getPage()).setModalResult(false);
+ LOG.error("While creating or updating connector {}", conn, e);
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+ String roles = connInstanceTO.getKey() == 0
+ ? xmlRolesReader.getEntitlement("Connectors", "create")
+ : xmlRolesReader.getEntitlement("Connectors", "update");
+ MetaDataRoleAuthorizationStrategy.authorize(submit, ENABLE, roles);
+ connectorForm.add(submit);
+
+ final IndicatingAjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+ };
+ cancel.setDefaultFormProcessing(false);
+ connectorForm.add(cancel);
+ }
+
+ private ConnBundleTO getSelectedBundleTO(final ConnInstanceTO connInstanceTO) {
+ ConnBundleTO result = null;
+ if (connInstanceTO != null
+ && StringUtils.isNotBlank(connInstanceTO.getLocation())
+ && StringUtils.isNotBlank(connInstanceTO.getBundleName())
+ && StringUtils.isNotBlank(connInstanceTO.getVersion())
+ && mapConnBundleTOs.containsKey(connInstanceTO.getLocation())) {
+
+ Map<String, Map<String, ConnBundleTO>> byLocation = mapConnBundleTOs.get(connInstanceTO.getLocation());
+ if (byLocation.containsKey(connInstanceTO.getBundleName())) {
+ Map<String, ConnBundleTO> byName = byLocation.get(connInstanceTO.getBundleName());
+ if (byName.containsKey(connInstanceTO.getVersion())) {
+ result = byName.get(connInstanceTO.getVersion());
+ }
+ }
+ }
+ return result;
+ }
+
+ private List<ConnConfProperty> fillProperties(final ConnBundleTO bundleTO, final ConnInstanceTO connInstanceTO) {
+ final List<ConnConfProperty> props = new ArrayList<>();
+
+ if (bundleTO != null) {
+ for (ConnConfPropSchema key : bundleTO.getProperties()) {
+ final ConnConfProperty property = new ConnConfProperty();
+ property.setSchema(key);
+ if (connInstanceTO.getKey() != 0
+ && connInstanceTO.getConfigurationMap().containsKey(key.getName())
+ && connInstanceTO.getConfigurationMap().get(key.getName()).getValues() != null) {
+
+ property.getValues().addAll(connInstanceTO.getConfigurationMap().get(key.getName()).getValues());
+ property.setOverridable(connInstanceTO.getConfigurationMap().get(key.getName()).isOverridable());
+ }
+
+ if (property.getValues().isEmpty() && !key.getDefaultValues().isEmpty()) {
+ property.getValues().addAll(key.getDefaultValues());
+ }
+
+ props.add(property);
+ }
+ }
+
+ // re-order properties (implements Comparable)
+ Collections.sort(props);
+ return props;
+ }
+
+ private void selectVersion(final AjaxRequestTarget target, final ConnInstanceTO connInstanceTO,
+ final AjaxDropDownChoicePanel<String> version, final String versionValue) {
+
+ connInstanceTO.setVersion(versionValue);
+ target.add(version);
+
+ bundleTO = getSelectedBundleTO(connInstanceTO);
+ properties = fillProperties(bundleTO, connInstanceTO);
+ target.add(propertiesContainer);
+ }
+
+ public List<ConnConfProperty> getProperties() {
+ return properties;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/DerSchemaModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/DerSchemaModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/DerSchemaModalPage.java
new file mode 100644
index 0000000..1abe744
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/DerSchemaModalPage.java
@@ -0,0 +1,140 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.JexlHelpUtils;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.DerSchemaTO;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+
+/**
+ * Modal window with Schema form.
+ */
+public class DerSchemaModalPage extends AbstractSchemaModalPage<DerSchemaTO> {
+
+ private static final long serialVersionUID = 6668789770131753386L;
+
+ public DerSchemaModalPage(final AttributableType kind) {
+ super(kind);
+ }
+
+ @Override
+ public void setSchemaModalPage(final PageReference pageRef, final ModalWindow window,
+ DerSchemaTO schema, final boolean createFlag) {
+
+ if (schema == null) {
+ schema = new DerSchemaTO();
+ }
+
+ final Form<DerSchemaTO> schemaForm = new Form<>(FORM);
+
+ schemaForm.setModel(new CompoundPropertyModel<>(schema));
+
+ final AjaxTextFieldPanel name =
+ new AjaxTextFieldPanel("key", getString("key"), new PropertyModel<String>(schema, "key"));
+ name.addRequiredLabel();
+
+ final AjaxTextFieldPanel expression = new AjaxTextFieldPanel("expression", getString("expression"),
+ new PropertyModel<String>(schema, "expression"));
+ expression.addRequiredLabel();
+
+ final WebMarkupContainer jexlHelp = JexlHelpUtils.getJexlHelpWebContainer("jexlHelp");
+
+ final AjaxLink<Void> questionMarkJexlHelp = JexlHelpUtils.getAjaxLink(jexlHelp, "questionMarkJexlHelp");
+ schemaForm.add(questionMarkJexlHelp);
+ questionMarkJexlHelp.add(jexlHelp);
+
+ name.setEnabled(createFlag);
+
+ final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(SUBMIT)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form form) {
+ DerSchemaTO schemaTO = (DerSchemaTO) form.getDefaultModelObject();
+
+ try {
+ if (createFlag) {
+ schemaRestClient.createDerSchema(kind, schemaTO);
+ } else {
+ schemaRestClient.updateDerSchema(kind, schemaTO);
+ }
+
+ if (pageRef.getPage() instanceof BasePage) {
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+ }
+
+ window.close(target);
+ } catch (SyncopeClientException e) {
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+
+ final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+ };
+
+ cancel.setDefaultFormProcessing(
+ false);
+
+ String allowedRoles = createFlag
+ ? xmlRolesReader.getEntitlement("Schema", "create")
+ : xmlRolesReader.getEntitlement("Schema", "update");
+
+ MetaDataRoleAuthorizationStrategy.authorize(submit, ENABLE, allowedRoles);
+
+ schemaForm.add(name);
+
+ schemaForm.add(expression);
+
+ schemaForm.add(submit);
+
+ schemaForm.add(cancel);
+
+ add(schemaForm);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.java
new file mode 100644
index 0000000..6f89ec3
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.java
@@ -0,0 +1,273 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.PreferenceManager;
+import org.apache.syncope.common.lib.search.SearchableFields;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Check;
+import org.apache.wicket.markup.html.form.CheckGroup;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.markup.html.panel.Fragment;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+/**
+ * Modal window with Display attributes form.
+ */
+@SuppressWarnings({ "unchecked", "rawtypes" })
+public class DisplayAttributesModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = -4274117450918385110L;
+
+ /**
+ * Max allowed selections.
+ */
+ private static final int MAX_SELECTIONS = 9;
+
+ public static final String[] DEFAULT_SELECTION = { "key", "username", "status" };
+
+ @SpringBean
+ private PreferenceManager prefMan;
+
+ private final List<String> selectedDetails;
+
+ private final List<String> selectedPlainSchemas;
+
+ private final List<String> selectedDerSchemas;
+
+ private final List<String> selectedVirSchemas;
+
+ public DisplayAttributesModalPage(final PageReference pageRef, final ModalWindow window,
+ final List<String> schemaNames, final List<String> dSchemaNames, final List<String> vSchemaNames) {
+
+ super();
+
+ final IModel<List<String>> fnames = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ return SearchableFields.get(UserTO.class);
+ }
+ };
+
+ final IModel<List<String>> names = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ return schemaNames;
+ }
+ };
+
+ final IModel<List<String>> dsnames = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ return dSchemaNames;
+ }
+ };
+
+ final IModel<List<String>> vsnames = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ return vSchemaNames;
+ }
+ };
+
+ final Form form = new Form(FORM);
+ form.setModel(new CompoundPropertyModel(this));
+
+ selectedDetails = prefMan.getList(getRequest(), Constants.PREF_USERS_DETAILS_VIEW);
+
+ selectedPlainSchemas = prefMan.getList(getRequest(), Constants.PREF_USERS_ATTRIBUTES_VIEW);
+
+ selectedDerSchemas = prefMan.getList(getRequest(), Constants.PREF_USERS_DERIVED_ATTRIBUTES_VIEW);
+
+ selectedVirSchemas = prefMan.getList(getRequest(), Constants.PREF_USERS_VIRTUAL_ATTRIBUTES_VIEW);
+
+ final CheckGroup dgroup = new CheckGroup("dCheckGroup", new PropertyModel(this, "selectedDetails"));
+ form.add(dgroup);
+
+ final ListView<String> details = new ListView<String>("details", fnames) {
+
+ private static final long serialVersionUID = 9101744072914090143L;
+
+ @Override
+ protected void populateItem(final ListItem<String> item) {
+ item.add(new Check("dcheck", item.getModel()));
+ item.add(new Label("dname", new ResourceModel(item.getModelObject(), item.getModelObject())));
+ }
+ };
+ dgroup.add(details);
+
+ if (names.getObject() == null || names.getObject().isEmpty()) {
+ final Fragment fragment = new Fragment("plainSchemas", "emptyFragment", form);
+ form.add(fragment);
+
+ selectedPlainSchemas.clear();
+ } else {
+ final Fragment fragment = new Fragment("plainSchemas", "sfragment", form);
+ form.add(fragment);
+
+ final CheckGroup sgroup = new CheckGroup("psCheckGroup", new PropertyModel(this, "selectedPlainSchemas"));
+ fragment.add(sgroup);
+
+ final ListView<String> schemas = new ListView<String>("plainSchemas", names) {
+
+ private static final long serialVersionUID = 9101744072914090143L;
+
+ @Override
+ protected void populateItem(final ListItem<String> item) {
+ item.add(new Check("scheck", item.getModel()));
+ item.add(new Label("sname", new ResourceModel(item.getModelObject(), item.getModelObject())));
+ }
+ };
+ sgroup.add(schemas);
+ }
+
+ if (dsnames.getObject() == null || dsnames.getObject().isEmpty()) {
+ final Fragment fragment = new Fragment("dschemas", "emptyFragment", form);
+ form.add(fragment);
+
+ selectedDerSchemas.clear();
+ } else {
+ final Fragment fragment = new Fragment("dschemas", "dsfragment", form);
+ form.add(fragment);
+
+ final CheckGroup dsgroup = new CheckGroup("dsCheckGroup", new PropertyModel(this, "selectedDerSchemas"));
+ fragment.add(dsgroup);
+
+ final ListView<String> derSchemas = new ListView<String>("derSchemas", dsnames) {
+
+ private static final long serialVersionUID = 9101744072914090143L;
+
+ @Override
+ protected void populateItem(ListItem<String> item) {
+ item.add(new Check("dscheck", item.getModel()));
+ item.add(new Label("dsname", new ResourceModel(item.getModelObject(), item.getModelObject())));
+ }
+ };
+ dsgroup.add(derSchemas);
+ }
+
+ if (vsnames.getObject() == null || vsnames.getObject().isEmpty()) {
+ final Fragment fragment = new Fragment("vschemas", "emptyFragment", form);
+ form.add(fragment);
+
+ selectedVirSchemas.clear();
+ } else {
+ final Fragment fragment = new Fragment("vschemas", "vsfragment", form);
+ form.add(fragment);
+
+ final CheckGroup vsgroup = new CheckGroup("vsCheckGroup", new PropertyModel(this, "selectedVirSchemas"));
+ fragment.add(vsgroup);
+
+ final ListView<String> virSchemas = new ListView<String>("virSchemas", vsnames) {
+
+ private static final long serialVersionUID = 9101744072914090143L;
+
+ @Override
+ protected void populateItem(ListItem<String> item) {
+ item.add(new Check("vscheck", item.getModel()));
+ item.add(new Label("vsname", new ResourceModel(item.getModelObject(), item.getModelObject())));
+ }
+ };
+ vsgroup.add(virSchemas);
+ }
+
+ final AjaxButton submit = new IndicatingAjaxButton(SUBMIT, new ResourceModel(SUBMIT)) {
+
+ private static final long serialVersionUID = -4804368561204623354L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ if (selectedDetails.size() + selectedPlainSchemas.size() + selectedVirSchemas.size() + selectedDerSchemas.
+ size()
+ > MAX_SELECTIONS) {
+
+ error(getString("tooManySelections"));
+ onError(target, form);
+ } else {
+ final Map<String, List<String>> prefs = new HashMap<String, List<String>>();
+
+ prefs.put(Constants.PREF_USERS_DETAILS_VIEW, selectedDetails);
+
+ prefs.put(Constants.PREF_USERS_ATTRIBUTES_VIEW, selectedPlainSchemas);
+
+ prefs.put(Constants.PREF_USERS_DERIVED_ATTRIBUTES_VIEW, selectedDerSchemas);
+
+ prefs.put(Constants.PREF_USERS_VIRTUAL_ATTRIBUTES_VIEW, selectedVirSchemas);
+
+ prefMan.setList(getRequest(), getResponse(), prefs);
+
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+
+ window.close(target);
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+
+ form.add(submit);
+
+ final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+ };
+
+ cancel.setDefaultFormProcessing(false);
+ form.add(cancel);
+
+ add(form);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/EditUserModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/EditUserModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/EditUserModalPage.java
new file mode 100644
index 0000000..af502d2
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/EditUserModalPage.java
@@ -0,0 +1,105 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import org.apache.commons.lang3.SerializationUtils;
+import org.apache.syncope.client.console.commons.Mode;
+import org.apache.syncope.client.console.commons.status.StatusBean;
+import org.apache.syncope.client.console.panels.AccountInformationPanel;
+import org.apache.syncope.client.console.panels.MembershipsPanel;
+import org.apache.syncope.client.console.panels.ResourcesPanel;
+import org.apache.syncope.client.console.panels.StatusPanel;
+import org.apache.syncope.common.lib.AttributableOperations;
+import org.apache.syncope.common.lib.mod.UserMod;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.ResourceModel;
+
+/**
+ * Modal window with User form.
+ */
+public class EditUserModalPage extends UserModalPage {
+
+ private static final long serialVersionUID = -6479209496805705739L;
+
+ protected Form form;
+
+ private final UserTO initialUserTO;
+
+ private StatusPanel statusPanel;
+
+ public EditUserModalPage(final PageReference pageRef, final ModalWindow window, final UserTO userTO) {
+ super(pageRef, window, userTO, Mode.ADMIN, true);
+
+ this.initialUserTO = SerializationUtils.clone(userTO);
+
+ form = setupEditPanel();
+
+ // add resource assignment details in case of update
+ if (userTO.getKey() != 0) {
+ form.addOrReplace(new Label("pwdChangeInfo", new ResourceModel("pwdChangeInfo")));
+
+ statusPanel = new StatusPanel("statuspanel", userTO, new ArrayList<StatusBean>(), getPageReference());
+ statusPanel.setOutputMarkupId(true);
+ MetaDataRoleAuthorizationStrategy.authorize(
+ statusPanel, RENDER, xmlRolesReader.getEntitlement("Resources", "getConnectorObject"));
+ form.addOrReplace(statusPanel);
+
+ form.addOrReplace(new AccountInformationPanel("accountinformation", userTO));
+
+ form.addOrReplace(new ResourcesPanel.Builder("resources").attributableTO(userTO).
+ statusPanel(statusPanel).build());
+
+ form.addOrReplace(new MembershipsPanel("memberships", userTO, mode, statusPanel, getPageReference()));
+ }
+ }
+
+ @SuppressWarnings("rawtypes")
+ @Override
+ protected void submitAction(final AjaxRequestTarget target, final Form form) {
+ final UserTO updatedUserTO = (UserTO) form.getModelObject();
+
+ if (updatedUserTO.getKey() == 0) {
+ userTO = userRestClient.create(updatedUserTO, storePassword.getModelObject());
+ } else {
+ final UserMod userMod = AttributableOperations.diff(updatedUserTO, initialUserTO);
+
+ if (statusPanel != null) {
+ userMod.setPwdPropRequest(statusPanel.getStatusMod());
+ }
+
+ // update user just if it is changed
+ if (!userMod.isEmpty()) {
+ userTO = userRestClient.update(initialUserTO.getETagValue(), userMod);
+ }
+ }
+ }
+
+ @SuppressWarnings("rawtypes")
+ @Override
+ protected void closeAction(final AjaxRequestTarget target, final Form form) {
+ setResponsePage(new ResultStatusModalPage.Builder(window, userTO).mode(mode).build());
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ErrorPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ErrorPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ErrorPage.java
new file mode 100644
index 0000000..db46171
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ErrorPage.java
@@ -0,0 +1,42 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.wicket.Page;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.link.BookmarkablePageLink;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.request.mapper.parameter.PageParameters;
+
+/**
+ * Error WebPage.
+ */
+public class ErrorPage extends BasePage {
+
+ private static final long serialVersionUID = -390761262038796657L;
+
+ public ErrorPage(final PageParameters parameters) {
+ super(parameters);
+
+ add(new Label("errorTitle", new Model<String>(parameters.get("errorTitle").toString())));
+ add(new Label("errorMessage", new Model<String>(parameters.get("errorMessage").toString())));
+
+ add(new BookmarkablePageLink<Page>("home", getApplication().getHomePage()));
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ExecMessageModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ExecMessageModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ExecMessageModalPage.java
new file mode 100644
index 0000000..e39f3fc
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ExecMessageModalPage.java
@@ -0,0 +1,32 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.model.Model;
+
+public class ExecMessageModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = 3163146190501510888L;
+
+ public ExecMessageModalPage(final String message) {
+ final Label dialogContent = new Label("message", new Model<String>(message));
+ add(dialogContent.setOutputMarkupId(true));
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/FailureMessageModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/FailureMessageModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/FailureMessageModalPage.java
new file mode 100644
index 0000000..c0ee7ec
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/FailureMessageModalPage.java
@@ -0,0 +1,37 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.model.Model;
+
+public class FailureMessageModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = 9216117990503199258L;
+
+ public FailureMessageModalPage(final String message, final String failureMessage) {
+ final Label executionFailureMessage;
+ if (!failureMessage.isEmpty()) {
+ executionFailureMessage = new Label("failureMessage", new Model<String>(failureMessage));
+ } else {
+ executionFailureMessage = new Label("failureMessage");
+ }
+ add(executionFailureMessage.setOutputMarkupId(true));
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/GroupModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/GroupModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/GroupModalPage.java
new file mode 100644
index 0000000..8b4daa9
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/GroupModalPage.java
@@ -0,0 +1,164 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import java.util.List;
+import org.apache.commons.lang3.SerializationUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.Mode;
+import org.apache.syncope.client.console.panels.GroupPanel;
+import org.apache.syncope.common.lib.AttributableOperations;
+import org.apache.syncope.common.lib.mod.GroupMod;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.ResourceModel;
+
+/**
+ * Modal window with Group form.
+ */
+public class GroupModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = -1732493223434085205L;
+
+ protected final PageReference pageRef;
+
+ protected final ModalWindow window;
+
+ protected final Mode mode;
+
+ protected final boolean createFlag;
+
+ protected final GroupPanel groupPanel;
+
+ protected GroupTO originalGroupTO;
+
+ public GroupModalPage(final PageReference pageRef, final ModalWindow window, final GroupTO groupTO) {
+ this(pageRef, window, groupTO, Mode.ADMIN);
+ }
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ public GroupModalPage(
+ final PageReference pageRef, final ModalWindow window, final GroupTO groupTO, final Mode mode) {
+
+ super();
+
+ this.pageRef = pageRef;
+ this.window = window;
+ this.mode = mode;
+
+ this.createFlag = groupTO.getKey() == 0;
+ if (!createFlag) {
+ originalGroupTO = SerializationUtils.clone(groupTO);
+ }
+
+ final Form<GroupTO> form = new Form<GroupTO>("groupForm");
+ form.setMultiPart(true);
+
+ add(new Label("displayName", groupTO.getKey() == 0 ? "" : groupTO.getDisplayName()));
+
+ form.setModel(new CompoundPropertyModel<GroupTO>(groupTO));
+
+ this.groupPanel = new GroupPanel.Builder("groupPanel").
+ form(form).groupTO(groupTO).groupModalPageMode(mode).pageRef(getPageReference()).build();
+ form.add(groupPanel);
+
+ final AjaxButton submit = new IndicatingAjaxButton(SUBMIT, new ResourceModel(SUBMIT)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ try {
+ submitAction(target, form);
+
+ if (pageRef.getPage() instanceof BasePage) {
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+ }
+
+ closeAction(target, form);
+ } catch (Exception e) {
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+ form.add(submit);
+ form.setDefaultButton(submit);
+
+ final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ closeAction(target, form);
+ }
+ };
+ cancel.setDefaultFormProcessing(false);
+ form.add(cancel);
+
+ MetaDataRoleAuthorizationStrategy.authorize(submit, ENABLE, xmlRolesReader.getEntitlement("Groups",
+ createFlag
+ ? "create"
+ : "update"));
+
+ add(form);
+ }
+
+ protected void submitAction(final AjaxRequestTarget target, final Form<?> form) {
+ final GroupTO groupTO = (GroupTO) form.getDefaultModelObject();
+ final List<String> entitlementList = new ArrayList<String>(groupPanel.getSelectedEntitlements());
+ groupTO.getEntitlements().clear();
+ groupTO.getEntitlements().addAll(entitlementList);
+
+ GroupTO result;
+ if (createFlag) {
+ result = groupRestClient.create(groupTO);
+ } else {
+ GroupMod groupMod = AttributableOperations.diff(groupTO, originalGroupTO);
+
+ // update group just if it is changed
+ if (groupMod.isEmpty()) {
+ result = groupTO;
+ } else {
+ result = groupRestClient.update(originalGroupTO.getETagValue(), groupMod);
+ }
+ }
+
+ setResponsePage(new ResultStatusModalPage.Builder(window, result).build());
+ }
+
+ protected void closeAction(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/GroupSelectModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/GroupSelectModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/GroupSelectModalPage.java
new file mode 100644
index 0000000..97b7abf
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/GroupSelectModalPage.java
@@ -0,0 +1,105 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.lang.reflect.Constructor;
+import javax.swing.tree.DefaultMutableTreeNode;
+import org.apache.syncope.client.console.commons.GroupTreeBuilder;
+import org.apache.syncope.client.console.wicket.markup.html.tree.DefaultMutableTreeNodeExpansion;
+import org.apache.syncope.client.console.wicket.markup.html.tree.DefaultMutableTreeNodeExpansionModel;
+import org.apache.syncope.client.console.wicket.markup.html.tree.TreeGroupProvider;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.wicket.Component;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.event.Broadcast;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.markup.html.repeater.tree.DefaultNestedTree;
+import org.apache.wicket.extensions.markup.html.repeater.tree.ITreeProvider;
+import org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree;
+import org.apache.wicket.extensions.markup.html.repeater.tree.content.Folder;
+import org.apache.wicket.extensions.markup.html.repeater.tree.theme.WindowsTheme;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class GroupSelectModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = 2106489458494696439L;
+
+ @SpringBean
+ private GroupTreeBuilder groupTreeBuilder;
+
+ private final NestedTree<DefaultMutableTreeNode> tree;
+
+ public GroupSelectModalPage(final PageReference pageRef, final ModalWindow window, final Class<?> payloadClass) {
+ super();
+
+ final ITreeProvider<DefaultMutableTreeNode> treeProvider = new TreeGroupProvider(groupTreeBuilder, true);
+ final DefaultMutableTreeNodeExpansionModel treeModel = new DefaultMutableTreeNodeExpansionModel();
+
+ tree = new DefaultNestedTree<DefaultMutableTreeNode>("treeTable", treeProvider, treeModel) {
+
+ private static final long serialVersionUID = 7137658050662575546L;
+
+ @Override
+ protected Component newContentComponent(final String id, final IModel<DefaultMutableTreeNode> node) {
+ final DefaultMutableTreeNode treeNode = node.getObject();
+ final GroupTO groupTO = (GroupTO) treeNode.getUserObject();
+
+ return new Folder<DefaultMutableTreeNode>(id, GroupSelectModalPage.this.tree, node) {
+
+ private static final long serialVersionUID = 9046323319920426493L;
+
+ @Override
+ protected boolean isClickable() {
+ return true;
+ }
+
+ @Override
+ protected IModel<?> newLabelModel(final IModel<DefaultMutableTreeNode> model) {
+ return new Model<>(groupTO.getDisplayName());
+ }
+
+ @Override
+ protected void onClick(final AjaxRequestTarget target) {
+ super.onClick(target);
+
+ try {
+ Constructor<?> constructor = payloadClass.getConstructor(Long.class);
+ Object payload = constructor.newInstance(groupTO.getKey());
+
+ send(pageRef.getPage(), Broadcast.BREADTH, payload);
+ } catch (Exception e) {
+ LOG.error("Could not send group select event", e);
+ }
+
+ window.close(target);
+ }
+ };
+ }
+ };
+ tree.add(new WindowsTheme());
+ tree.setOutputMarkupId(true);
+
+ DefaultMutableTreeNodeExpansion.get().expandAll();
+
+ this.add(tree);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/GroupTemplateModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/GroupTemplateModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/GroupTemplateModalPage.java
new file mode 100644
index 0000000..293e402
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/GroupTemplateModalPage.java
@@ -0,0 +1,50 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.commons.Mode;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.to.SyncTaskTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.form.Form;
+
+public class GroupTemplateModalPage extends GroupModalPage {
+
+ private static final long serialVersionUID = -3849135555203409845L;
+
+ private final SyncTaskTO syncTaskTO;
+
+ public GroupTemplateModalPage(final PageReference callerPageRef, final ModalWindow window,
+ final SyncTaskTO syncTaskTO) {
+
+ super(callerPageRef, window, syncTaskTO.getGroupTemplate() == null
+ ? new GroupTO()
+ : syncTaskTO.getGroupTemplate(), Mode.TEMPLATE);
+
+ this.syncTaskTO = syncTaskTO;
+ }
+
+ @Override
+ protected void submitAction(final AjaxRequestTarget target, final Form form) {
+ syncTaskTO.setGroupTemplate((GroupTO) form.getModelObject());
+ taskRestClient.updateSyncTask(syncTaskTO);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Groups.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Groups.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Groups.java
new file mode 100644
index 0000000..2e92940
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Groups.java
@@ -0,0 +1,186 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.panels.AbstractSearchResultPanel;
+import org.apache.syncope.client.console.panels.GroupSearchPanel;
+import org.apache.syncope.client.console.panels.GroupSearchResultPanel;
+import org.apache.syncope.client.console.panels.GroupSummaryPanel;
+import org.apache.syncope.client.console.rest.GroupRestClient;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
+import org.apache.syncope.client.console.wicket.markup.html.tree.TreeGroupPanel;
+import org.apache.wicket.Session;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.event.Broadcast;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.request.mapper.parameter.PageParameters;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+/**
+ * Groups WebPage.
+ */
+public class Groups extends BasePage {
+
+ private static final long serialVersionUID = -2147758241610831969L;
+
+ private static final int WIN_HEIGHT = 500;
+
+ private static final int WIN_WIDTH = 800;
+
+ @SpringBean
+ private GroupRestClient restClient;
+
+ private final ModalWindow editGroupWin;
+
+ private final WebMarkupContainer groupTabsContainer;
+
+ public Groups(final PageParameters parameters) {
+ super(parameters);
+
+ groupTabsContainer = new WebMarkupContainer("groupTabsContainer");
+ groupTabsContainer.setOutputMarkupId(true);
+ add(groupTabsContainer);
+
+ editGroupWin = new ModalWindow("editGroupWin");
+ editGroupWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ editGroupWin.setInitialHeight(WIN_HEIGHT);
+ editGroupWin.setInitialWidth(WIN_WIDTH);
+ editGroupWin.setCookieName("edit-group-modal");
+ add(editGroupWin);
+
+ final TreeGroupPanel treePanel = new TreeGroupPanel("treePanel");
+ treePanel.setOutputMarkupId(true);
+ groupTabsContainer.add(treePanel);
+
+ final GroupSummaryPanel summaryPanel = new GroupSummaryPanel.Builder("summaryPanel")
+ .window(editGroupWin).callerPageRef(Groups.this.getPageReference()).build();
+ groupTabsContainer.add(summaryPanel);
+
+ editGroupWin.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
+
+ private static final long serialVersionUID = 8804221891699487139L;
+
+ @Override
+ public void onClose(final AjaxRequestTarget target) {
+ final GroupSummaryPanel summaryPanel = (GroupSummaryPanel) groupTabsContainer.get("summaryPanel");
+
+ final TreeNodeClickUpdate data = new TreeNodeClickUpdate(target,
+ summaryPanel == null || summaryPanel.getSelectedNode() == null
+ ? 0
+ : summaryPanel.getSelectedNode().getKey());
+
+ send(getPage(), Broadcast.BREADTH, data);
+
+ if (modalResult) {
+ getSession().info(getString(Constants.OPERATION_SUCCEEDED));
+ feedbackPanel.refresh(target);
+ modalResult = false;
+ }
+
+ }
+ });
+
+ final AbstractSearchResultPanel searchResult =
+ new GroupSearchResultPanel("searchResult", true, null, getPageReference(), restClient);
+ add(searchResult);
+
+ final Form searchForm = new Form("searchForm");
+ add(searchForm);
+
+ final GroupSearchPanel searchPanel = new GroupSearchPanel.Builder("searchPanel").build();
+ searchForm.add(searchPanel);
+
+ searchForm.add(new ClearIndicatingAjaxButton("search", new ResourceModel("search"), getPageReference()) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
+ final String fiql = searchPanel.buildFIQL();
+ LOG.debug("Node condition {}", fiql);
+
+ doSearch(target, fiql, searchResult);
+
+ Session.get().getFeedbackMessages().clear();
+ searchPanel.getSearchFeedback().refresh(target);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ searchPanel.getSearchFeedback().refresh(target);
+ }
+ });
+ }
+
+ private void doSearch(final AjaxRequestTarget target, final String fiql,
+ final AbstractSearchResultPanel resultsetPanel) {
+
+ if (fiql == null) {
+ error(getString(Constants.SEARCH_ERROR));
+ return;
+ }
+
+ resultsetPanel.search(fiql, target);
+ }
+
+ @Override
+ public void onEvent(final IEvent<?> event) {
+ super.onEvent(event);
+
+ if (event.getPayload() instanceof TreeNodeClickUpdate) {
+ final TreeNodeClickUpdate update = (TreeNodeClickUpdate) event.getPayload();
+
+ final GroupSummaryPanel summaryPanel = new GroupSummaryPanel.Builder("summaryPanel")
+ .window(editGroupWin).callerPageRef(Groups.this.getPageReference())
+ .selectedNodeId(update.getSelectedNodeId()).build();
+
+ groupTabsContainer.addOrReplace(summaryPanel);
+ update.getTarget().add(groupTabsContainer);
+ }
+ }
+
+ public static class TreeNodeClickUpdate {
+
+ private final AjaxRequestTarget target;
+
+ private Long selectedNodeId;
+
+ public TreeNodeClickUpdate(final AjaxRequestTarget target, final Long selectedNodeId) {
+ this.target = target;
+ this.selectedNodeId = selectedNodeId;
+ }
+
+ public AjaxRequestTarget getTarget() {
+ return target;
+ }
+
+ public Long getSelectedNodeId() {
+ return selectedNodeId;
+ }
+
+ public void setSelectedNodeId(final Long selectedNodeId) {
+ this.selectedNodeId = selectedNodeId;
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/HomePage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/HomePage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/HomePage.java
new file mode 100644
index 0000000..7b4ba68
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/HomePage.java
@@ -0,0 +1,33 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.wicket.request.mapper.parameter.PageParameters;
+
+/**
+ * Syncope Home-Page.
+ */
+public class HomePage extends BasePage {
+
+ private static final long serialVersionUID = -6712990478380766293L;
+
+ public HomePage(final PageParameters parameters) {
+ super(parameters);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/InfoModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/InfoModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/InfoModalPage.java
new file mode 100644
index 0000000..83e0163
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/InfoModalPage.java
@@ -0,0 +1,43 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.link.ExternalLink;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class InfoModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = 5558354927844399580L;
+
+ @SpringBean(name = "site")
+ private String siteUrl;
+
+ @SpringBean(name = "license")
+ private String licenseUrl;
+
+ public InfoModalPage() {
+ super();
+
+ add(new ExternalLink("syncopeLink", siteUrl));
+ add(new ExternalLink("licenseLink", licenseUrl));
+ add(new Label("version", SyncopeSession.get().getVersion()));
+ }
+}
[23/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractSyncTaskModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractSyncTaskModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractSyncTaskModalPage.java
new file mode 100644
index 0000000..aa62b41
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractSyncTaskModalPage.java
@@ -0,0 +1,209 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.List;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.SelectChoiceRenderer;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.common.lib.to.AbstractProvisioningTaskTO;
+import org.apache.syncope.common.lib.to.ResourceTO;
+import org.apache.syncope.common.lib.types.MatchingRule;
+import org.apache.syncope.common.lib.types.UnmatchingRule;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+
+/**
+ * Abstract Modal window for Sync and Push Task form.
+ */
+public abstract class AbstractSyncTaskModalPage extends AbstractSchedTaskModalPage {
+
+ private static final long serialVersionUID = 2148403203517274669L;
+
+ protected AjaxDropDownChoicePanel<MatchingRule> matchingRule;
+
+ protected AjaxDropDownChoicePanel<UnmatchingRule> unmatchingRule;
+
+ protected abstract List<String> getSyncActions();
+
+ final IModel<List<String>> allResources = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ final List<String> resourceNames = new ArrayList<>();
+
+ for (ResourceTO resourceTO : resourceRestClient.getAll()) {
+ resourceNames.add(resourceTO.getKey());
+ }
+
+ Collections.sort(resourceNames);
+ return resourceNames;
+ }
+ };
+
+ final IModel<List<String>> syncActionsClasses = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157438L;
+
+ @Override
+ protected List<String> load() {
+ return getSyncActions();
+ }
+ };
+
+ public AbstractSyncTaskModalPage(
+ final ModalWindow window, final AbstractProvisioningTaskTO taskTO, final PageReference pageRef) {
+
+ super(window, taskTO, pageRef);
+
+ final AjaxDropDownChoicePanel<String> resource = new AjaxDropDownChoicePanel<>("resource",
+ getString("resourceName"), new PropertyModel<String>(taskTO, "resource"));
+ resource.setChoices(allResources.getObject());
+ resource.setChoiceRenderer(new SelectChoiceRenderer<String>());
+ resource.addRequiredLabel();
+ resource.setEnabled(taskTO.getKey() == 0);
+ resource.setStyleSheet("ui-widget-content ui-corner-all long_dynamicsize");
+
+ profile.add(resource);
+
+ final WebMarkupContainer syncActionsClassNames = new WebMarkupContainer("syncActionsClassNames");
+ syncActionsClassNames.setOutputMarkupId(true);
+ profile.add(syncActionsClassNames);
+
+ final AjaxLink<Void> first = new IndicatingAjaxLink<Void>("first") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ taskTO.getActionsClassNames().add(StringUtils.EMPTY);
+ setVisible(false);
+ target.add(syncActionsClassNames);
+ }
+ };
+ first.setOutputMarkupPlaceholderTag(true);
+ first.setVisible(taskTO.getActionsClassNames().isEmpty());
+ syncActionsClassNames.add(first);
+
+ final ListView<String> actionsClasses = new ListView<String>(
+ "actionsClasses", new PropertyModel<List<String>>(taskTO, "actionsClassNames")) {
+
+ private static final long serialVersionUID = 9101744072914090143L;
+
+ @Override
+ protected void populateItem(final ListItem<String> item) {
+ final String className = item.getModelObject();
+
+ final DropDownChoice<String> actionsClass = new DropDownChoice<String>(
+ "actionsClass", new Model<String>(className), syncActionsClasses.getObject());
+ actionsClass.setNullValid(true);
+ actionsClass.setRequired(true);
+ actionsClass.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ taskTO.getActionsClassNames().set(item.getIndex(), actionsClass.getModelObject());
+ target.add(syncActionsClassNames);
+ }
+ });
+ actionsClass.setRequired(true);
+ actionsClass.setOutputMarkupId(true);
+ actionsClass.setRequired(true);
+ item.add(actionsClass);
+
+ AjaxLink<Void> minus = new IndicatingAjaxLink<Void>("drop") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ taskTO.getActionsClassNames().remove(className);
+ first.setVisible(taskTO.getActionsClassNames().isEmpty());
+ target.add(syncActionsClassNames);
+ }
+ };
+ item.add(minus);
+
+ final AjaxLink<Void> plus = new IndicatingAjaxLink<Void>("add") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ taskTO.getActionsClassNames().add(StringUtils.EMPTY);
+ target.add(syncActionsClassNames);
+ }
+ };
+ plus.setOutputMarkupPlaceholderTag(true);
+ plus.setVisible(item.getIndex() == taskTO.getActionsClassNames().size() - 1);
+ item.add(plus);
+ }
+ };
+ syncActionsClassNames.add(actionsClasses);
+
+ syncActionsClassNames.setEnabled(!syncActionsClasses.getObject().isEmpty());
+
+ final AjaxCheckBoxPanel creates = new AjaxCheckBoxPanel("performCreate", getString("creates"),
+ new PropertyModel<Boolean>(taskTO, "performCreate"));
+ profile.add(creates);
+
+ final AjaxCheckBoxPanel updates = new AjaxCheckBoxPanel("performUpdate", getString("updates"),
+ new PropertyModel<Boolean>(taskTO, "performUpdate"));
+ profile.add(updates);
+
+ final AjaxCheckBoxPanel deletes = new AjaxCheckBoxPanel("performDelete", getString("updates"),
+ new PropertyModel<Boolean>(taskTO, "performDelete"));
+ profile.add(deletes);
+
+ final AjaxCheckBoxPanel syncStatus = new AjaxCheckBoxPanel("syncStatus", getString("syncStatus"),
+ new PropertyModel<Boolean>(taskTO, "syncStatus"));
+ profile.add(syncStatus);
+
+ matchingRule = new AjaxDropDownChoicePanel<MatchingRule>(
+ "matchingRule", "matchingRule", new PropertyModel<MatchingRule>(taskTO, "matchingRule"));
+ matchingRule.setChoices(Arrays.asList(MatchingRule.values()));
+ ((DropDownChoice) matchingRule.getField()).setNullValid(false);
+
+ unmatchingRule = new AjaxDropDownChoicePanel<UnmatchingRule>(
+ "unmatchingRule", "unmatchingRule", new PropertyModel<UnmatchingRule>(taskTO, "unmatchingRule"));
+ unmatchingRule.setChoices(Arrays.asList(UnmatchingRule.values()));
+ ((DropDownChoice) unmatchingRule.getField()).setNullValid(false);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ActivitiModelerPopupPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ActivitiModelerPopupPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ActivitiModelerPopupPage.java
new file mode 100644
index 0000000..05658fc
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ActivitiModelerPopupPage.java
@@ -0,0 +1,27 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.wicket.markup.html.WebPage;
+
+public class ActivitiModelerPopupPage extends WebPage {
+
+ private static final long serialVersionUID = -7031206743629422898L;
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ApprovalModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ApprovalModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ApprovalModalPage.java
new file mode 100644
index 0000000..79deeb0
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ApprovalModalPage.java
@@ -0,0 +1,286 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.io.Serializable;
+import java.text.ParseException;
+import java.text.SimpleDateFormat;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Date;
+import java.util.List;
+import java.util.Map;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.commons.lang3.math.NumberUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.MapChoiceRenderer;
+import org.apache.syncope.client.console.rest.ApprovalRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.DateTimeFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.FieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.SpinnerFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.list.AltListView;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.WorkflowFormPropertyTO;
+import org.apache.syncope.common.lib.to.WorkflowFormTO;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class ApprovalModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = -8847854414429745216L;
+
+ private final static int USER_WIN_HEIGHT = 550;
+
+ private final static int USER_WIN_WIDTH = 800;
+
+ @SpringBean
+ private ApprovalRestClient restClient;
+
+ private final ModalWindow editUserWin;
+
+ public ApprovalModalPage(final PageReference pageRef, final ModalWindow window, final WorkflowFormTO formTO) {
+ super();
+
+ IModel<List<WorkflowFormPropertyTO>> formProps = new LoadableDetachableModel<List<WorkflowFormPropertyTO>>() {
+
+ private static final long serialVersionUID = 3169142472626817508L;
+
+ @Override
+ protected List<WorkflowFormPropertyTO> load() {
+ return formTO.getProperties();
+ }
+ };
+
+ final ListView<WorkflowFormPropertyTO> propView =
+ new AltListView<WorkflowFormPropertyTO>("propView", formProps) {
+
+ private static final long serialVersionUID = 9101744072914090143L;
+
+ @Override
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ protected void populateItem(final ListItem<WorkflowFormPropertyTO> item) {
+ final WorkflowFormPropertyTO prop = item.getModelObject();
+
+ Label label = new Label("key", prop.getName() == null
+ ? prop.getId()
+ : prop.getName());
+ item.add(label);
+
+ FieldPanel field;
+ switch (prop.getType()) {
+ case Boolean:
+ field = new AjaxDropDownChoicePanel("value", label.getDefaultModelObjectAsString(),
+ new Model<Boolean>(Boolean.valueOf(prop.getValue()))).setChoices(Arrays.asList(
+ new String[] { "Yes", "No" }));
+ break;
+
+ case Date:
+ SimpleDateFormat df = StringUtils.isNotBlank(prop.getDatePattern())
+ ? new SimpleDateFormat(prop.getDatePattern())
+ : new SimpleDateFormat();
+ Date parsedDate = null;
+ if (StringUtils.isNotBlank(prop.getValue())) {
+ try {
+ parsedDate = df.parse(prop.getValue());
+ } catch (ParseException e) {
+ LOG.error("Unparsable date: {}", prop.getValue(), e);
+ }
+ }
+
+ field = new DateTimeFieldPanel("value", label.getDefaultModelObjectAsString(),
+ new Model<Date>(parsedDate), df.toLocalizedPattern());
+ break;
+
+ case Enum:
+ MapChoiceRenderer<String, String> enumCR =
+ new MapChoiceRenderer<String, String>(prop.getEnumValues());
+
+ field = new AjaxDropDownChoicePanel("value", label.getDefaultModelObjectAsString(),
+ new Model(prop.getValue())).setChoiceRenderer(enumCR).setChoices(new Model() {
+
+ private static final long serialVersionUID = -858521070366432018L;
+
+ @Override
+ public Serializable getObject() {
+ return new ArrayList<String>(prop.getEnumValues().keySet());
+ }
+ });
+ break;
+
+ case Long:
+ field = new SpinnerFieldPanel<Long>("value", label.getDefaultModelObjectAsString(),
+ Long.class, new Model<Long>(NumberUtils.toLong(prop.getValue())),
+ null, null);
+ break;
+
+ case String:
+ default:
+ field = new AjaxTextFieldPanel("value", PARENT_PATH,
+ new Model<String>(prop.getValue()));
+ break;
+ }
+
+ field.setReadOnly(!prop.isWritable());
+ if (prop.isRequired()) {
+ field.addRequiredLabel();
+ }
+
+ item.add(field);
+ }
+ };
+
+ final AjaxButton userDetails = new IndicatingAjaxButton("userDetails",
+ new Model<String>(getString("userDetails"))) {
+
+ private static final long serialVersionUID = -4804368561204623354L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ editUserWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ViewUserModalPage(ApprovalModalPage.this.getPageReference(), editUserWin,
+ userRestClient.read(formTO.getUserKey())) {
+
+ private static final long serialVersionUID = -2819994749866481607L;
+
+ @Override
+ protected void closeAction(final AjaxRequestTarget target, final Form form) {
+ setResponsePage(ApprovalModalPage.this);
+ }
+ };
+ }
+ });
+
+ editUserWin.show(target);
+ }
+ };
+ MetaDataRoleAuthorizationStrategy.authorize(userDetails, ENABLE,
+ xmlRolesReader.getEntitlement("Users", "read"));
+
+ final AjaxButton submit = new IndicatingAjaxButton(APPLY, new Model<String>(getString(SUBMIT))) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+
+ Map<String, WorkflowFormPropertyTO> props = formTO.getPropertyMap();
+
+ for (int i = 0; i < propView.size(); i++) {
+ @SuppressWarnings("unchecked")
+ ListItem<WorkflowFormPropertyTO> item = (ListItem<WorkflowFormPropertyTO>) propView.get(i);
+ String input = ((FieldPanel) item.get("value")).getField().getInput();
+
+ if (!props.containsKey(item.getModelObject().getId())) {
+ props.put(item.getModelObject().getId(), new WorkflowFormPropertyTO());
+ }
+
+ if (item.getModelObject().isWritable()) {
+ switch (item.getModelObject().getType()) {
+ case Boolean:
+ props.get(item.getModelObject().getId()).setValue(String.valueOf("0".equals(input)));
+ break;
+
+ case Date:
+ case Enum:
+ case String:
+ case Long:
+ default:
+ props.get(item.getModelObject().getId()).setValue(input);
+ break;
+ }
+ }
+ }
+
+ formTO.getProperties().clear();
+ formTO.getProperties().addAll(props.values());
+ try {
+ restClient.submitForm(formTO);
+
+ ((Todo) pageRef.getPage()).setModalResult(true);
+ window.close(target);
+ } catch (SyncopeClientException e) {
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ LOG.error("While submitting form {}", formTO, e);
+ feedbackPanel.refresh(target);
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+
+ final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form form) {
+ window.close(target);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form form) {
+ // nothing
+ }
+ };
+
+ cancel.setDefaultFormProcessing(false);
+
+ Form form = new Form(FORM);
+ form.add(propView);
+ form.add(userDetails);
+ form.add(submit);
+ form.add(cancel);
+
+ MetaDataRoleAuthorizationStrategy.authorize(form, ENABLE, xmlRolesReader.getEntitlement("Approval",
+ SUBMIT));
+
+ editUserWin = new ModalWindow("editUserWin");
+ editUserWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ editUserWin.setInitialHeight(USER_WIN_HEIGHT);
+ editUserWin.setInitialWidth(USER_WIN_WIDTH);
+ editUserWin.setCookieName("edit-user-modal");
+ add(editUserWin);
+
+ add(form);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BaseModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BaseModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BaseModalPage.java
new file mode 100644
index 0000000..20892dd
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BaseModalPage.java
@@ -0,0 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.commons.CloseOnESCBehavior;
+
+/**
+ * Syncope Modal Window.
+ */
+public abstract class BaseModalPage extends AbstractBasePage {
+
+ private static final long serialVersionUID = -1443079028368471943L;
+
+ public BaseModalPage() {
+ super();
+
+ add(new CloseOnESCBehavior("keyup"));
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BasePage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BasePage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BasePage.java
new file mode 100644
index 0000000..2540c37
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BasePage.java
@@ -0,0 +1,111 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.SyncopeApplication;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.wicket.Component;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.IAjaxIndicatorAware;
+import org.apache.wicket.behavior.Behavior;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.ComponentTag;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.link.BookmarkablePageLink;
+import org.apache.wicket.request.mapper.parameter.PageParameters;
+
+/**
+ * Syncope Wicket base-page.
+ */
+public class BasePage extends AbstractBasePage implements IAjaxIndicatorAware {
+
+ private static final long serialVersionUID = 1571997737305598502L;
+
+ public BasePage() {
+ this(null);
+ }
+
+ public BasePage(final PageParameters parameters) {
+ super(parameters);
+
+ pageSetup();
+ }
+
+ private void pageSetup() {
+ ((SyncopeApplication) getApplication()).setupNavigationPanel(this, xmlRolesReader, true);
+
+ final String kind = getClass().getSimpleName().toLowerCase();
+ final BookmarkablePageLink kindLink = (BookmarkablePageLink) get(kind);
+ if (kindLink != null) {
+ kindLink.add(new Behavior() {
+
+ private static final long serialVersionUID = 1469628524240283489L;
+
+ @Override
+ public void onComponentTag(final Component component, final ComponentTag tag) {
+ tag.put("class", kind);
+ }
+ });
+
+ Component kindIcon = kindLink.get(0);
+ if (kindIcon != null) {
+ kindIcon.add(new Behavior() {
+
+ private static final long serialVersionUID = 1469628524240283489L;
+
+ @Override
+ public void onComponentTag(final Component component, final ComponentTag tag) {
+ tag.put("src", "../.." + SyncopeApplication.IMG_PREFIX + kind + Constants.PNG_EXT);
+ }
+ });
+ }
+ }
+
+ ((SyncopeApplication) getApplication()).setupEditProfileModal(this, userSelfRestClient);
+ }
+
+ @Override
+ public String getAjaxIndicatorMarkupId() {
+ return "veil";
+ }
+
+ /**
+ * Set a WindowClosedCallback for a ModalWindow instance.
+ *
+ * @param window window
+ * @param container container
+ */
+ protected void setWindowClosedCallback(final ModalWindow window, final WebMarkupContainer container) {
+
+ window.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
+
+ private static final long serialVersionUID = 8804221891699487139L;
+
+ @Override
+ public void onClose(final AjaxRequestTarget target) {
+ target.add(container);
+ if (isModalResult()) {
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ feedbackPanel.refresh(target);
+ setModalResult(false);
+ }
+ }
+ });
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BasePopupPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BasePopupPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BasePopupPage.java
new file mode 100644
index 0000000..856f469
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BasePopupPage.java
@@ -0,0 +1,25 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+public class BasePopupPage extends AbstractBasePage {
+
+ private static final long serialVersionUID = -2633667311332659505L;
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BulkActionModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BulkActionModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BulkActionModalPage.java
new file mode 100644
index 0000000..95e514b
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BulkActionModalPage.java
@@ -0,0 +1,166 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.lang.reflect.InvocationTargetException;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.rest.BaseRestClient;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.common.lib.to.BulkAction;
+import org.apache.syncope.common.lib.to.BulkActionResult;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.ResourceModel;
+import org.springframework.beans.BeanUtils;
+
+public class BulkActionModalPage<T, S> extends BaseModalPage {
+
+ private static final long serialVersionUID = 4114026480146090962L;
+
+ public BulkActionModalPage(
+ final ModalWindow window,
+ final Collection<T> items,
+ final List<IColumn<T, S>> columns,
+ final Collection<ActionLink.ActionType> actions,
+ final BaseRestClient bulkActionExecutor,
+ final String idFieldName,
+ final String pageId) {
+
+ super();
+
+ final SortableDataProvider<T, S> dataProvider = new SortableDataProvider<T, S>() {
+
+ private static final long serialVersionUID = 5291903859908641954L;
+
+ @Override
+ public Iterator<? extends T> iterator(final long first, final long count) {
+ return items.iterator();
+ }
+
+ @Override
+ public long size() {
+ return items.size();
+ }
+
+ @Override
+ public IModel<T> model(final T object) {
+ return new CompoundPropertyModel<>(object);
+ }
+ };
+
+ add(new AjaxFallbackDefaultDataTable<>(
+ "selectedObjects",
+ new ArrayList<>(columns.subList(1, columns.size() - 1)),
+ dataProvider,
+ Integer.MAX_VALUE).setVisible(items != null && !items.isEmpty()));
+
+ @SuppressWarnings("rawtypes")
+ final ActionLinksPanel actionPanel = new ActionLinksPanel("actions", new Model(), getPageReference());
+ add(actionPanel);
+
+ for (ActionLink.ActionType action : actions) {
+ final BulkAction bulkAction = new BulkAction();
+ for (T item : items) {
+ try {
+ bulkAction.getTargets().add(getTargetId(item, idFieldName).toString());
+ } catch (Exception e) {
+ LOG.error("Error retrieving item id {}", idFieldName, e);
+ }
+ }
+
+ switch (action) {
+ case DELETE:
+ bulkAction.setOperation(BulkAction.Type.DELETE);
+ break;
+ case SUSPEND:
+ bulkAction.setOperation(BulkAction.Type.SUSPEND);
+ break;
+ case REACTIVATE:
+ bulkAction.setOperation(BulkAction.Type.REACTIVATE);
+ break;
+ case EXECUTE:
+ bulkAction.setOperation(BulkAction.Type.EXECUTE);
+ break;
+ case DRYRUN:
+ bulkAction.setOperation(BulkAction.Type.DRYRUN);
+ break;
+ default:
+ LOG.error("Bulk action type not supported");
+ }
+
+ actionPanel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ final BulkActionResult res = (BulkActionResult) bulkActionExecutor.getClass().
+ getMethod("bulkAction", BulkAction.class).invoke(bulkActionExecutor, bulkAction);
+
+ setResponsePage(new BulkActionResultModalPage<>(window, items, columns, res, idFieldName));
+ } catch (Exception e) {
+ error(getString(Constants.ERROR)
+ + ": Operation " + bulkAction.getOperation() + " not supported");
+ feedbackPanel.refresh(target);
+ }
+
+ }
+ }, action, pageId, !items.isEmpty());
+ }
+
+ final Form<Void> form = new Form<>(FORM);
+ add(form);
+
+ final AjaxButton cancel =
+ new ClearIndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL), getPageReference()) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+ };
+
+ cancel.setDefaultFormProcessing(false);
+ form.add(cancel);
+ }
+
+ private Object getTargetId(final Object target, final String idFieldName)
+ throws IllegalAccessException, InvocationTargetException {
+
+ return BeanUtils.getPropertyDescriptor(target.getClass(), idFieldName).
+ getReadMethod().invoke(target, new Object[0]);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BulkActionResultModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BulkActionResultModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BulkActionResultModalPage.java
new file mode 100644
index 0000000..b9b8968
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/BulkActionResultModalPage.java
@@ -0,0 +1,97 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.List;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionResultColumn;
+import org.apache.syncope.common.lib.to.BulkActionResult;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.IModel;
+
+/**
+ * Show user or group status after performing a successful operation.
+ */
+public class BulkActionResultModalPage<T, S> extends BaseModalPage {
+
+ /**
+ * Serial version id.
+ */
+ private static final long serialVersionUID = 2646115294319713724L;
+
+ public BulkActionResultModalPage(
+ final ModalWindow window,
+ final Collection<T> items,
+ final List<IColumn<T, S>> columns,
+ final BulkActionResult results,
+ final String idFieldName) {
+
+ super();
+
+ final List<IColumn<T, S>> newColumnList = new ArrayList<>(columns.subList(1, columns.size() - 1));
+ newColumnList.add(newColumnList.size(), new ActionResultColumn<T, S>(results, idFieldName));
+
+ final SortableDataProvider<T, S> dataProvider = new SortableDataProvider<T, S>() {
+
+ private static final long serialVersionUID = 5291903859908641954L;
+
+ @Override
+ public Iterator<? extends T> iterator(final long first, final long count) {
+ return items.iterator();
+ }
+
+ @Override
+ public long size() {
+ return items.size();
+ }
+
+ @Override
+ public IModel<T> model(final T object) {
+ return new CompoundPropertyModel<T>(object);
+ }
+ };
+
+ add(new AjaxFallbackDefaultDataTable<T, S>(
+ "selectedObjects",
+ newColumnList,
+ dataProvider,
+ Integer.MAX_VALUE).setVisible(items != null && !items.isEmpty()));
+
+ final AjaxLink<Void> close = new IndicatingAjaxLink<Void>("close") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ window.close(target);
+ }
+ };
+
+ add(close);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ConfModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ConfModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ConfModalPage.java
new file mode 100644
index 0000000..0c65ac2
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ConfModalPage.java
@@ -0,0 +1,112 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.Collections;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.Mode;
+import org.apache.syncope.client.console.panels.PlainAttrsPanel;
+import org.apache.syncope.common.lib.to.AttrTO;
+import org.apache.syncope.common.lib.to.ConfTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.ResourceModel;
+
+public class ConfModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = 3524777398688399977L;
+
+ public ConfModalPage(final PageReference pageRef, final ModalWindow window, final WebMarkupContainer parameters) {
+ super();
+
+ MetaDataRoleAuthorizationStrategy.authorize(
+ parameters, ENABLE, xmlRolesReader.getEntitlement("Configuration", "list"));
+ final ConfTO conf = confRestClient.list();
+
+ final Form<ConfTO> form = new Form<>("confForm");
+ form.setModel(new CompoundPropertyModel<>(conf));
+
+ form.add(new PlainAttrsPanel("paramAttrs", conf, form, Mode.ADMIN));
+
+ final AjaxButton submit = new IndicatingAjaxButton(SUBMIT, new ResourceModel(SUBMIT)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ final ConfTO updatedConf = (ConfTO) form.getModelObject();
+
+ try {
+ for (AttrTO attr : updatedConf.getPlainAttrs()) {
+ attr.getValues().removeAll(Collections.singleton(null));
+ if (attr.getValues().isEmpty()
+ || attr.getValues().equals(Collections.singletonList(StringUtils.EMPTY))) {
+
+ confRestClient.delete(attr.getSchema());
+ } else {
+ confRestClient.set(attr);
+ }
+ }
+
+ if (pageRef.getPage() instanceof BasePage) {
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+ }
+
+ window.close(target);
+ } catch (Exception e) {
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+ MetaDataRoleAuthorizationStrategy.authorize(
+ submit, ENABLE, xmlRolesReader.getEntitlement("Configuration", "set"));
+ MetaDataRoleAuthorizationStrategy.authorize(
+ submit, ENABLE, xmlRolesReader.getEntitlement("Configuration", "delete"));
+ form.add(submit);
+ form.setDefaultButton(submit);
+
+ final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+ };
+ cancel.setDefaultFormProcessing(false);
+ form.add(cancel);
+
+ add(form);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Configuration.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Configuration.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Configuration.java
new file mode 100644
index 0000000..9f8c734
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Configuration.java
@@ -0,0 +1,814 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import static org.apache.syncope.client.console.pages.AbstractBasePage.LOG;
+
+import java.io.File;
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+import org.apache.logging.log4j.LogManager;
+import org.apache.logging.log4j.core.LoggerContext;
+import org.apache.logging.log4j.core.config.LoggerConfig;
+import org.apache.syncope.client.console.ExtensionPanel;
+import org.apache.syncope.client.console.commons.AttrLayoutType;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.HttpResourceStream;
+import org.apache.syncope.client.console.commons.PreferenceManager;
+import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
+import org.apache.syncope.client.console.init.ImplementationClassNamesLoader;
+import org.apache.syncope.client.console.panels.AbstractExtensionPanel;
+import org.apache.syncope.client.console.panels.JQueryUITabbedPanel;
+import org.apache.syncope.client.console.panels.LayoutsPanel;
+import org.apache.syncope.client.console.panels.PoliciesPanel;
+import org.apache.syncope.client.console.rest.LoggerRestClient;
+import org.apache.syncope.client.console.rest.NotificationRestClient;
+import org.apache.syncope.client.console.rest.SecurityQuestionRestClient;
+import org.apache.syncope.client.console.rest.WorkflowRestClient;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.CollectionPropertyColumn;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.client.console.wicket.markup.html.link.VeilPopupSettings;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.SyncopeConstants;
+import org.apache.syncope.common.lib.to.LoggerTO;
+import org.apache.syncope.common.lib.to.NotificationTO;
+import org.apache.syncope.common.lib.to.SecurityQuestionTO;
+import org.apache.syncope.common.lib.types.LoggerLevel;
+import org.apache.syncope.common.lib.types.PolicyType;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
+import org.apache.wicket.extensions.markup.html.tabs.AbstractTab;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.image.Image;
+import org.apache.wicket.markup.html.link.BookmarkablePageLink;
+import org.apache.wicket.markup.html.link.Link;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.PropertyListView;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.AbstractReadOnlyModel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.protocol.http.WebApplication;
+import org.apache.wicket.request.handler.resource.ResourceStreamRequestHandler;
+import org.apache.wicket.request.resource.ContentDisposition;
+import org.apache.wicket.request.resource.DynamicImageResource;
+import org.apache.wicket.request.resource.IResource;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.springframework.util.ClassUtils;
+import org.springframework.web.context.support.WebApplicationContextUtils;
+
+/**
+ * Configurations WebPage.
+ */
+public class Configuration extends BasePage {
+
+ private static final long serialVersionUID = -2838270869037702214L;
+
+ private static final int SYNCOPECONF_WIN_HEIGHT = 300;
+
+ private static final int SYNCOPECONF_WIN_WIDTH = 900;
+
+ private static final int NOTIFICATION_WIN_HEIGHT = 500;
+
+ private static final int NOTIFICATION_WIN_WIDTH = 1100;
+
+ private static final int SECURITY_QUESTION_WIN_HEIGHT = 300;
+
+ private static final int SECURITY_QUESTION_WIN_WIDTH = 900;
+
+ @SpringBean
+ private LoggerRestClient loggerRestClient;
+
+ @SpringBean
+ private NotificationRestClient notificationRestClient;
+
+ @SpringBean
+ private SecurityQuestionRestClient securityQuestionRestClient;
+
+ @SpringBean
+ private WorkflowRestClient wfRestClient;
+
+ @SpringBean
+ private PreferenceManager prefMan;
+
+ @SpringBean
+ private ImplementationClassNamesLoader implementationClassNamesLoader;
+
+ private final ModalWindow syncopeConfWin;
+
+ private final ModalWindow createNotificationWin;
+
+ private final ModalWindow editNotificationWin;
+
+ private final ModalWindow createSecurityQuestionWin;
+
+ private final ModalWindow editSecurityQuestionWin;
+
+ private WebMarkupContainer notificationContainer;
+
+ private WebMarkupContainer securityQuestionContainer;
+
+ private int notificationPaginatorRows;
+
+ public Configuration() {
+ super();
+
+ // Layouts
+ add(new LayoutsPanel("adminUserLayoutPanel", AttrLayoutType.ADMIN_USER, feedbackPanel));
+ add(new LayoutsPanel("selfUserLayoutPanel", AttrLayoutType.SELF_USER, feedbackPanel));
+ add(new LayoutsPanel("adminGroupLayoutPanel", AttrLayoutType.ADMIN_GROUP, feedbackPanel));
+ add(new LayoutsPanel("selfGroupLayoutPanel", AttrLayoutType.SELF_GROUP, feedbackPanel));
+ add(new LayoutsPanel("adminMembershipLayoutPanel", AttrLayoutType.ADMIN_MEMBERSHIP, feedbackPanel));
+ add(new LayoutsPanel("selfMembershipLayoutPanel", AttrLayoutType.SELF_MEMBERSHIP, feedbackPanel));
+
+ add(syncopeConfWin = new ModalWindow("syncopeConfWin"));
+ syncopeConfWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ syncopeConfWin.setInitialHeight(SYNCOPECONF_WIN_HEIGHT);
+ syncopeConfWin.setInitialWidth(SYNCOPECONF_WIN_WIDTH);
+ syncopeConfWin.setCookieName("syncopeconf-modal");
+ setupSyncopeConf();
+
+ add(new PoliciesPanel("passwordPoliciesPanel", getPageReference(), PolicyType.PASSWORD));
+ add(new PoliciesPanel("accountPoliciesPanel", getPageReference(), PolicyType.ACCOUNT));
+ add(new PoliciesPanel("syncPoliciesPanel", getPageReference(), PolicyType.SYNC));
+
+ add(createNotificationWin = new ModalWindow("createNotificationWin"));
+ createNotificationWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ createNotificationWin.setInitialHeight(NOTIFICATION_WIN_HEIGHT);
+ createNotificationWin.setInitialWidth(NOTIFICATION_WIN_WIDTH);
+ createNotificationWin.setCookieName("create-notification-modal");
+ add(editNotificationWin = new ModalWindow("editNotificationWin"));
+ editNotificationWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ editNotificationWin.setInitialHeight(NOTIFICATION_WIN_HEIGHT);
+ editNotificationWin.setInitialWidth(NOTIFICATION_WIN_WIDTH);
+ editNotificationWin.setCookieName("edit-notification-modal");
+ setupNotification();
+
+ add(createSecurityQuestionWin = new ModalWindow("createSecurityQuestionWin"));
+ createSecurityQuestionWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ createSecurityQuestionWin.setInitialHeight(SECURITY_QUESTION_WIN_HEIGHT);
+ createSecurityQuestionWin.setInitialWidth(SECURITY_QUESTION_WIN_WIDTH);
+ createSecurityQuestionWin.setCookieName("create-security-question-modal");
+ add(editSecurityQuestionWin = new ModalWindow("editSecurityQuestionWin"));
+ editSecurityQuestionWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ editSecurityQuestionWin.setInitialHeight(SECURITY_QUESTION_WIN_HEIGHT);
+ editSecurityQuestionWin.setInitialWidth(SECURITY_QUESTION_WIN_WIDTH);
+ editSecurityQuestionWin.setCookieName("edit-security-question-modal");
+ setupSecurityQuestion();
+
+ // Workflow definition stuff
+ WebMarkupContainer noActivitiEnabledForUsers = new WebMarkupContainer("noActivitiEnabledForUsers");
+ noActivitiEnabledForUsers.setOutputMarkupPlaceholderTag(true);
+ add(noActivitiEnabledForUsers);
+
+ WebMarkupContainer workflowDefContainer = new WebMarkupContainer("workflowDefContainer");
+ workflowDefContainer.setOutputMarkupPlaceholderTag(true);
+
+ if (wfRestClient.isActivitiEnabledForUsers()) {
+ noActivitiEnabledForUsers.setVisible(false);
+ } else {
+ workflowDefContainer.setVisible(false);
+ }
+
+ BookmarkablePageLink<Void> activitiModeler =
+ new BookmarkablePageLink<>("activitiModeler", ActivitiModelerPopupPage.class);
+ activitiModeler.setPopupSettings(new VeilPopupSettings().setHeight(600).setWidth(800));
+ MetaDataRoleAuthorizationStrategy.authorize(activitiModeler, ENABLE,
+ xmlRolesReader.getEntitlement("Configuration", "workflowDefRead"));
+ workflowDefContainer.add(activitiModeler);
+ // Check if Activiti Modeler directory is found
+ boolean activitiModelerEnabled = false;
+ try {
+ String activitiModelerDirectory = WebApplicationContextUtils.getWebApplicationContext(
+ WebApplication.get().getServletContext()).getBean("activitiModelerDirectory", String.class);
+ File baseDir = new File(activitiModelerDirectory);
+ activitiModelerEnabled = baseDir.exists() && baseDir.canRead() && baseDir.isDirectory();
+ } catch (Exception e) {
+ LOG.error("Could not check for Activiti Modeler directory", e);
+ }
+ activitiModeler.setEnabled(activitiModelerEnabled);
+
+ BookmarkablePageLink<Void> xmlEditor = new BookmarkablePageLink<>("xmlEditor", XMLEditorPopupPage.class);
+ xmlEditor.setPopupSettings(new VeilPopupSettings().setHeight(480).setWidth(800));
+ MetaDataRoleAuthorizationStrategy.authorize(xmlEditor, ENABLE,
+ xmlRolesReader.getEntitlement("Configuration", "workflowDefRead"));
+ workflowDefContainer.add(xmlEditor);
+
+ Image workflowDefDiagram = new Image("workflowDefDiagram", new Model()) {
+
+ private static final long serialVersionUID = -8457850449086490660L;
+
+ @Override
+ protected IResource getImageResource() {
+ return new DynamicImageResource() {
+
+ private static final long serialVersionUID = 923201517955737928L;
+
+ @Override
+ protected byte[] getImageData(final IResource.Attributes attributes) {
+ return wfRestClient.isActivitiEnabledForUsers()
+ ? wfRestClient.getDiagram()
+ : new byte[0];
+ }
+ };
+ }
+ };
+ workflowDefContainer.add(workflowDefDiagram);
+
+ MetaDataRoleAuthorizationStrategy.authorize(workflowDefContainer, ENABLE,
+ xmlRolesReader.getEntitlement("Configuration", "workflowDefRead"));
+ add(workflowDefContainer);
+
+ // Logger stuff
+ PropertyListView<LoggerTO> coreLoggerList =
+ new LoggerPropertyList(null, "corelogger", loggerRestClient.listLogs());
+ WebMarkupContainer coreLoggerContainer = new WebMarkupContainer("coreLoggerContainer");
+ coreLoggerContainer.add(coreLoggerList);
+ coreLoggerContainer.setOutputMarkupId(true);
+
+ MetaDataRoleAuthorizationStrategy.authorize(coreLoggerContainer, ENABLE, xmlRolesReader.getEntitlement(
+ "Configuration", "logList"));
+ add(coreLoggerContainer);
+
+ ConsoleLoggerController consoleLoggerController = new ConsoleLoggerController();
+ PropertyListView<LoggerTO> consoleLoggerList =
+ new LoggerPropertyList(consoleLoggerController, "consolelogger", consoleLoggerController.getLoggers());
+ WebMarkupContainer consoleLoggerContainer = new WebMarkupContainer("consoleLoggerContainer");
+ consoleLoggerContainer.add(consoleLoggerList);
+ consoleLoggerContainer.setOutputMarkupId(true);
+
+ MetaDataRoleAuthorizationStrategy.authorize(
+ consoleLoggerContainer, ENABLE, xmlRolesReader.getEntitlement("Configuration", "logList"));
+ add(consoleLoggerContainer);
+
+ // Extension panels
+ setupExtPanels();
+ }
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ private void setupSyncopeConf() {
+ final WebMarkupContainer parameters = new WebMarkupContainer("parameters");
+ parameters.setOutputMarkupId(true);
+ add(parameters);
+
+ setWindowClosedCallback(syncopeConfWin, parameters);
+
+ AjaxLink<Void> confLink = new IndicatingAjaxLink<Void>("confLink") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ syncopeConfWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ConfModalPage(getPageReference(), editNotificationWin, parameters);
+ }
+ });
+
+ syncopeConfWin.show(target);
+ }
+ };
+ parameters.add(confLink);
+
+ Link<Void> dbExportLink = new Link<Void>("dbExportLink") {
+
+ private static final long serialVersionUID = -4331619903296515985L;
+
+ @Override
+ public void onClick() {
+ try {
+ HttpResourceStream stream = new HttpResourceStream(confRestClient.dbExport());
+
+ ResourceStreamRequestHandler rsrh = new ResourceStreamRequestHandler(stream);
+ rsrh.setFileName(stream.getFilename() == null ? "content.xml" : stream.getFilename());
+ rsrh.setContentDisposition(ContentDisposition.ATTACHMENT);
+
+ getRequestCycle().scheduleRequestHandlerAfterCurrent(rsrh);
+ } catch (Exception e) {
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ }
+ }
+ };
+ MetaDataRoleAuthorizationStrategy.authorize(
+ dbExportLink, ENABLE, xmlRolesReader.getEntitlement("Configuration", "export"));
+ add(dbExportLink);
+ }
+
+ private void setupNotification() {
+ notificationPaginatorRows = prefMan.getPaginatorRows(getRequest(), Constants.PREF_NOTIFICATION_PAGINATOR_ROWS);
+
+ final List<IColumn<NotificationTO, String>> notificationCols = new ArrayList<>();
+ notificationCols.add(new PropertyColumn<NotificationTO, String>(
+ new ResourceModel("key"), "key", "key"));
+ notificationCols.add(new CollectionPropertyColumn<NotificationTO>(
+ new ResourceModel("events"), "events", "events"));
+ notificationCols.add(new PropertyColumn<NotificationTO, String>(
+ new ResourceModel("subject"), "subject", "subject"));
+ notificationCols.add(new PropertyColumn<NotificationTO, String>(
+ new ResourceModel("template"), "template", "template"));
+ notificationCols.add(new PropertyColumn<NotificationTO, String>(
+ new ResourceModel("traceLevel"), "traceLevel", "traceLevel"));
+ notificationCols.add(new PropertyColumn<NotificationTO, String>(
+ new ResourceModel("active"), "active", "active"));
+
+ notificationCols.add(new AbstractColumn<NotificationTO, String>(new ResourceModel("actions", "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public String getCssClass() {
+ return "action";
+ }
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<NotificationTO>> cellItem, final String componentId,
+ final IModel<NotificationTO> model) {
+
+ final NotificationTO notificationTO = model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ editNotificationWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new NotificationModalPage(Configuration.this.getPageReference(),
+ editNotificationWin, notificationTO, false);
+ }
+ });
+
+ editNotificationWin.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, "Notification");
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ notificationRestClient.delete(notificationTO.getKey());
+ } catch (SyncopeClientException e) {
+ LOG.error("While deleting a notification", e);
+ error(e.getMessage());
+ return;
+ }
+
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ feedbackPanel.refresh(target);
+ target.add(notificationContainer);
+ }
+ }, ActionLink.ActionType.DELETE, "Notification");
+
+ cellItem.add(panel);
+ }
+ });
+
+ final AjaxFallbackDefaultDataTable<NotificationTO, String> notificationTable =
+ new AjaxFallbackDefaultDataTable<>(
+ "notificationTable", notificationCols, new NotificationProvider(), notificationPaginatorRows);
+
+ notificationContainer = new WebMarkupContainer("notificationContainer");
+ notificationContainer.add(notificationTable);
+ notificationContainer.setOutputMarkupId(true);
+
+ add(notificationContainer);
+
+ setWindowClosedCallback(createNotificationWin, notificationContainer);
+ setWindowClosedCallback(editNotificationWin, notificationContainer);
+
+ AjaxLink<Void> createNotificationLink = new AjaxLink<Void>("createNotificationLink") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ createNotificationWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new NotificationModalPage(Configuration.this.getPageReference(), createNotificationWin,
+ new NotificationTO(), true);
+ }
+ });
+
+ createNotificationWin.show(target);
+ }
+ };
+
+ MetaDataRoleAuthorizationStrategy.authorize(createNotificationLink, ENABLE, xmlRolesReader.getEntitlement(
+ "Notification", "create"));
+ add(createNotificationLink);
+
+ @SuppressWarnings("rawtypes")
+ Form notificationPaginatorForm = new Form("notificationPaginatorForm");
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ final DropDownChoice rowsChooser = new DropDownChoice("rowsChooser", new PropertyModel(this,
+ "notificationPaginatorRows"), prefMan.getPaginatorChoices());
+
+ rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ prefMan.set(getRequest(), getResponse(), Constants.PREF_NOTIFICATION_PAGINATOR_ROWS, String.valueOf(
+ notificationPaginatorRows));
+ notificationTable.setItemsPerPage(notificationPaginatorRows);
+
+ target.add(notificationContainer);
+ }
+ });
+
+ notificationPaginatorForm.add(rowsChooser);
+ add(notificationPaginatorForm);
+ }
+
+ private void setupSecurityQuestion() {
+ final List<IColumn<SecurityQuestionTO, String>> securityQuestionCols = new ArrayList<>();
+ securityQuestionCols.add(new PropertyColumn<SecurityQuestionTO, String>(
+ new ResourceModel("key"), "key", "key"));
+ securityQuestionCols.add(new PropertyColumn<SecurityQuestionTO, String>(
+ new ResourceModel("content"), "content", "content"));
+
+ securityQuestionCols.add(new AbstractColumn<SecurityQuestionTO, String>(new ResourceModel("actions", "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public String getCssClass() {
+ return "action";
+ }
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<SecurityQuestionTO>> cellItem, final String componentId,
+ final IModel<SecurityQuestionTO> model) {
+
+ final SecurityQuestionTO securityQuestionTO = model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ editSecurityQuestionWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new SecurityQuestionModalPage(Configuration.this.getPageReference(),
+ editSecurityQuestionWin, securityQuestionTO, false);
+ }
+ });
+
+ editSecurityQuestionWin.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, "SecurityQuestion");
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ securityQuestionRestClient.delete(securityQuestionTO.getKey());
+ } catch (SyncopeClientException e) {
+ LOG.error("While deleting a security question", e);
+ error(e.getMessage());
+ return;
+ }
+
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ feedbackPanel.refresh(target);
+ target.add(securityQuestionContainer);
+ }
+ }, ActionLink.ActionType.DELETE, "SecurityQuestion");
+
+ cellItem.add(panel);
+ }
+ });
+
+ final AjaxFallbackDefaultDataTable<SecurityQuestionTO, String> securityQuestionTable =
+ new AjaxFallbackDefaultDataTable<>("securityQuestionTable",
+ securityQuestionCols, new SecurityQuestionProvider(), 50);
+
+ securityQuestionContainer = new WebMarkupContainer("securityQuestionContainer");
+ securityQuestionContainer.add(securityQuestionTable);
+ securityQuestionContainer.setOutputMarkupId(true);
+
+ add(securityQuestionContainer);
+
+ setWindowClosedCallback(createSecurityQuestionWin, securityQuestionContainer);
+ setWindowClosedCallback(editSecurityQuestionWin, securityQuestionContainer);
+
+ AjaxLink<Void> createSecurityQuestionLink = new AjaxLink<Void>("createSecurityQuestionLink") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+
+ createSecurityQuestionWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new SecurityQuestionModalPage(Configuration.this.getPageReference(),
+ createSecurityQuestionWin, new SecurityQuestionTO(), true);
+ }
+ });
+
+ createSecurityQuestionWin.show(target);
+ }
+ };
+
+ MetaDataRoleAuthorizationStrategy.authorize(
+ createSecurityQuestionLink, ENABLE, xmlRolesReader.getEntitlement("SecurityQuestion", "create"));
+ add(createSecurityQuestionLink);
+ }
+
+ private void setupExtPanels() {
+ List<AbstractTab> tabs = new ArrayList<>();
+ int index = 0;
+ for (final Class<? extends AbstractExtensionPanel> clazz
+ : implementationClassNamesLoader.getExtPanelClasses()) {
+
+ String title = clazz.getAnnotation(ExtensionPanel.class) == null
+ ? "Extension " + index
+ : clazz.getAnnotation(ExtensionPanel.class).value();
+ tabs.add(new AbstractTab(new Model<>(title)) {
+
+ private static final long serialVersionUID = -5861786415855103549L;
+
+ @Override
+ public WebMarkupContainer getPanel(final String panelId) {
+ Panel panel;
+
+ try {
+ panel = ClassUtils.getConstructorIfAvailable(clazz, String.class, PageReference.class).
+ newInstance(panelId, Configuration.this.getPageReference());
+ } catch (Exception e) {
+ panel = new Panel(panelId) {
+
+ private static final long serialVersionUID = 5538299138211283825L;
+
+ };
+
+ LOG.error("Could not instantiate {}", clazz.getName(), e);
+ }
+
+ return panel;
+ }
+ });
+
+ index++;
+ }
+
+ JQueryUITabbedPanel<AbstractTab> extPanels = new JQueryUITabbedPanel<>("extPanels", tabs);
+ extPanels.setVisible(!tabs.isEmpty());
+ add(extPanels);
+ }
+
+ private class NotificationProvider extends SortableDataProvider<NotificationTO, String> {
+
+ private static final long serialVersionUID = -276043813563988590L;
+
+ private final SortableDataProviderComparator<NotificationTO> comparator;
+
+ public NotificationProvider() {
+ //Default sorting
+ setSort("key", SortOrder.ASCENDING);
+ comparator = new SortableDataProviderComparator<>(this);
+ }
+
+ @Override
+ public Iterator<NotificationTO> iterator(final long first, final long count) {
+ List<NotificationTO> list = notificationRestClient.getAllNotifications();
+
+ Collections.sort(list, comparator);
+
+ return list.subList((int) first, (int) first + (int) count).iterator();
+ }
+
+ @Override
+ public long size() {
+ return notificationRestClient.getAllNotifications().size();
+ }
+
+ @Override
+ public IModel<NotificationTO> model(final NotificationTO notification) {
+ return new AbstractReadOnlyModel<NotificationTO>() {
+
+ private static final long serialVersionUID = 774694801558497248L;
+
+ @Override
+ public NotificationTO getObject() {
+ return notification;
+ }
+ };
+ }
+ }
+
+ private class SecurityQuestionProvider extends SortableDataProvider<SecurityQuestionTO, String> {
+
+ private static final long serialVersionUID = -1458398823626281188L;
+
+ private final SortableDataProviderComparator<SecurityQuestionTO> comparator;
+
+ public SecurityQuestionProvider() {
+ //Default sorting
+ setSort("key", SortOrder.ASCENDING);
+ comparator = new SortableDataProviderComparator<>(this);
+ }
+
+ @Override
+ public Iterator<SecurityQuestionTO> iterator(final long first, final long count) {
+ List<SecurityQuestionTO> list = securityQuestionRestClient.list();
+
+ Collections.sort(list, comparator);
+
+ return list.subList((int) first, (int) first + (int) count).iterator();
+ }
+
+ @Override
+ public long size() {
+ return securityQuestionRestClient.list().size();
+ }
+
+ @Override
+ public IModel<SecurityQuestionTO> model(final SecurityQuestionTO securityQuestionTO) {
+ return new AbstractReadOnlyModel<SecurityQuestionTO>() {
+
+ private static final long serialVersionUID = 5079291243768775704L;
+
+ @Override
+ public SecurityQuestionTO getObject() {
+ return securityQuestionTO;
+ }
+ };
+ }
+ }
+
+ private class LoggerPropertyList extends PropertyListView<LoggerTO> {
+
+ private static final long serialVersionUID = 5911412425994616111L;
+
+ private final ConsoleLoggerController consoleLoggerController;
+
+ public LoggerPropertyList(final ConsoleLoggerController consoleLoggerController, final String id,
+ final List<? extends LoggerTO> list) {
+
+ super(id, list);
+ this.consoleLoggerController = consoleLoggerController;
+ }
+
+ @Override
+ protected void populateItem(final ListItem<LoggerTO> item) {
+ item.add(new Label("key"));
+
+ DropDownChoice<LoggerLevel> level = new DropDownChoice<>("level");
+ level.setModel(new IModel<LoggerLevel>() {
+
+ private static final long serialVersionUID = -2350428186089596562L;
+
+ @Override
+ public LoggerLevel getObject() {
+ return item.getModelObject().getLevel();
+ }
+
+ @Override
+ public void setObject(final LoggerLevel object) {
+ item.getModelObject().setLevel(object);
+ }
+
+ @Override
+ public void detach() {
+ }
+ });
+ level.setChoices(Arrays.asList(LoggerLevel.values()));
+ level.setOutputMarkupId(true);
+ level.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ try {
+ if (getId().equals("corelogger")) {
+ loggerRestClient.setLogLevel(item.getModelObject().getKey(),
+ item.getModelObject().getLevel());
+ } else {
+ consoleLoggerController.setLogLevel(item.getModelObject().getKey(),
+ item.getModelObject().getLevel());
+ }
+
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException e) {
+ info(getString(Constants.OPERATION_ERROR));
+ }
+
+ feedbackPanel.refresh(target);
+ }
+ });
+
+ MetaDataRoleAuthorizationStrategy.authorize(level, ENABLE, xmlRolesReader.getEntitlement(
+ "Configuration", "logSetLevel"));
+
+ item.add(level);
+ }
+ }
+
+ private static class ConsoleLoggerController implements Serializable {
+
+ private static final long serialVersionUID = -1550459341476431714L;
+
+ public List<LoggerTO> getLoggers() {
+ LoggerContext ctx = (LoggerContext) LogManager.getContext(false);
+
+ List<LoggerTO> result = new ArrayList<>();
+ for (LoggerConfig logger : ctx.getConfiguration().getLoggers().values()) {
+ final String loggerName = LogManager.ROOT_LOGGER_NAME.equals(logger.getName())
+ ? SyncopeConstants.ROOT_LOGGER : logger.getName();
+ if (logger.getLevel() != null) {
+ LoggerTO loggerTO = new LoggerTO();
+ loggerTO.setKey(loggerName);
+ loggerTO.setLevel(LoggerLevel.fromLevel(logger.getLevel()));
+ result.add(loggerTO);
+ }
+ }
+
+ return result;
+ }
+
+ public void setLogLevel(final String name, final LoggerLevel level) {
+ LoggerContext ctx = (LoggerContext) LogManager.getContext(false);
+ LoggerConfig logConf = SyncopeConstants.ROOT_LOGGER.equals(name)
+ ? ctx.getConfiguration().getLoggerConfig(LogManager.ROOT_LOGGER_NAME)
+ : ctx.getConfiguration().getLoggerConfig(name);
+ logConf.setLevel(level.getLevel());
+ ctx.updateLoggers();
+ }
+ }
+}
[10/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/SchemaRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/SchemaRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/SchemaRestClient.java
new file mode 100644
index 0000000..378f98d
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/SchemaRestClient.java
@@ -0,0 +1,250 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.List;
+import java.util.ListIterator;
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.client.console.commons.AttrLayoutType;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.AbstractSchemaTO;
+import org.apache.syncope.common.lib.to.DerSchemaTO;
+import org.apache.syncope.common.lib.to.PlainSchemaTO;
+import org.apache.syncope.common.lib.to.VirSchemaTO;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.syncope.common.lib.types.SchemaType;
+import org.apache.syncope.common.rest.api.service.SchemaService;
+import org.springframework.stereotype.Component;
+
+/**
+ * Console client for invoking rest schema services.
+ */
+@Component
+public class SchemaRestClient extends BaseRestClient {
+
+ private static final long serialVersionUID = -2479730152700312373L;
+
+ public void filter(
+ final List<? extends AbstractSchemaTO> schemaTOs, final Collection<String> allowed, final boolean exclude) {
+
+ for (ListIterator<? extends AbstractSchemaTO> itor = schemaTOs.listIterator(); itor.hasNext();) {
+ AbstractSchemaTO schema = itor.next();
+ if (exclude) {
+ if (!allowed.contains(schema.getKey())) {
+ itor.remove();
+ }
+ } else {
+ if (allowed.contains(schema.getKey())) {
+ itor.remove();
+ }
+ }
+ }
+ }
+
+ public List<? extends AbstractSchemaTO> getSchemas(final AttributableType attrType, final SchemaType schemaType) {
+ List<? extends AbstractSchemaTO> schemas = Collections.emptyList();
+
+ try {
+ schemas = getService(SchemaService.class).list(attrType, schemaType);
+ } catch (SyncopeClientException e) {
+ LOG.error("While getting all schemas for {} and {}", attrType, schemaType, e);
+ }
+
+ if (attrType == AttributableType.CONFIGURATION) {
+ filter(schemas, AttrLayoutType.confKeys(), false);
+ }
+
+ return schemas;
+ }
+
+ public List<PlainSchemaTO> getSchemas(final AttributableType type) {
+ List<PlainSchemaTO> schemas = null;
+
+ try {
+ schemas = getService(SchemaService.class).list(type, SchemaType.PLAIN);
+ } catch (SyncopeClientException e) {
+ LOG.error("While getting all schemas", e);
+ }
+
+ return schemas;
+ }
+
+ public List<String> getSchemaNames(final AttributableType attrType, final SchemaType schemaType) {
+ final List<String> schemaNames = new ArrayList<>();
+
+ try {
+ final List<? extends AbstractSchemaTO> schemas = getSchemas(attrType, schemaType);
+ for (AbstractSchemaTO schemaTO : schemas) {
+ schemaNames.add(schemaTO.getKey());
+ }
+ } catch (SyncopeClientException e) {
+ LOG.error("While getting all user schema names", e);
+ }
+
+ return schemaNames;
+ }
+
+ public List<String> getPlainSchemaNames(final AttributableType type) {
+ final List<String> schemaNames = new ArrayList<>();
+
+ try {
+ final List<PlainSchemaTO> schemas = getSchemas(type);
+ for (PlainSchemaTO schemaTO : schemas) {
+ schemaNames.add(schemaTO.getKey());
+ }
+ } catch (SyncopeClientException e) {
+ LOG.error("While getting all user schema names", e);
+ }
+
+ return schemaNames;
+ }
+
+ public List<DerSchemaTO> getDerSchemas(final AttributableType type) {
+ List<DerSchemaTO> userDerSchemas = null;
+
+ try {
+ userDerSchemas = getService(SchemaService.class).list(type, SchemaType.DERIVED);
+ } catch (SyncopeClientException e) {
+ LOG.error("While getting all user derived schemas", e);
+ }
+
+ return userDerSchemas;
+ }
+
+ public List<String> getDerSchemaNames(final AttributableType type) {
+ final List<String> userDerSchemasNames = new ArrayList<>();
+
+ try {
+ final List<DerSchemaTO> userDerSchemas = getService(SchemaService.class).list(type, SchemaType.DERIVED);
+
+ for (DerSchemaTO schemaTO : userDerSchemas) {
+ userDerSchemasNames.add(schemaTO.getKey());
+ }
+ } catch (SyncopeClientException e) {
+ LOG.error("While getting all {} derived schema names", type, e);
+ }
+
+ return userDerSchemasNames;
+ }
+
+ public List<VirSchemaTO> getVirSchemas(final AttributableType type) {
+ List<VirSchemaTO> userVirSchemas = null;
+
+ try {
+ userVirSchemas = getService(SchemaService.class).list(type, SchemaType.VIRTUAL);
+ } catch (SyncopeClientException e) {
+ LOG.error("While getting all {} virtual schemas", type, e);
+ }
+
+ return userVirSchemas;
+ }
+
+ public List<String> getVirSchemaNames(final AttributableType type) {
+ final List<String> userVirSchemasNames = new ArrayList<String>();
+
+ try {
+ @SuppressWarnings("unchecked")
+ final List<VirSchemaTO> userVirSchemas = getService(SchemaService.class).list(type, SchemaType.VIRTUAL);
+ for (VirSchemaTO schemaTO : userVirSchemas) {
+ userVirSchemasNames.add(schemaTO.getKey());
+ }
+ } catch (SyncopeClientException e) {
+ LOG.error("While getting all user derived schema names", e);
+ }
+
+ return userVirSchemasNames;
+ }
+
+ public void createPlainSchema(final AttributableType type, final PlainSchemaTO schemaTO) {
+ getService(SchemaService.class).create(type, SchemaType.PLAIN, schemaTO);
+ }
+
+ public PlainSchemaTO readPlainSchema(final AttributableType type, final String name) {
+ PlainSchemaTO schema = null;
+
+ try {
+ schema = getService(SchemaService.class).read(type, SchemaType.PLAIN, name);
+ } catch (SyncopeClientException e) {
+ LOG.error("While reading a user schema", e);
+ }
+ return schema;
+ }
+
+ public void updatePlainSchema(final AttributableType type, final PlainSchemaTO schemaTO) {
+ getService(SchemaService.class).update(type, SchemaType.PLAIN, schemaTO.getKey(), schemaTO);
+ }
+
+ public PlainSchemaTO deletePlainSchema(final AttributableType type, final String name) {
+ PlainSchemaTO response = getService(SchemaService.class).read(type, SchemaType.PLAIN, name);
+ getService(SchemaService.class).delete(type, SchemaType.PLAIN, name);
+ return response;
+ }
+
+ public void createDerSchema(final AttributableType type, final DerSchemaTO schemaTO) {
+ getService(SchemaService.class).create(type, SchemaType.DERIVED, schemaTO);
+ }
+
+ public DerSchemaTO readDerSchema(final AttributableType type, final String name) {
+ DerSchemaTO derivedSchemaTO = null;
+ try {
+ derivedSchemaTO = getService(SchemaService.class).read(type, SchemaType.DERIVED, name);
+ } catch (SyncopeClientException e) {
+ LOG.error("While reading a derived user schema", e);
+ }
+ return derivedSchemaTO;
+ }
+
+ public void updateVirSchema(final AttributableType type, final VirSchemaTO schemaTO) {
+ getService(SchemaService.class).update(type, SchemaType.VIRTUAL, schemaTO.getKey(), schemaTO);
+ }
+
+ public DerSchemaTO deleteDerSchema(final AttributableType type, final String name) {
+ DerSchemaTO schemaTO = getService(SchemaService.class).read(type, SchemaType.DERIVED, name);
+ getService(SchemaService.class).delete(type, SchemaType.DERIVED, name);
+ return schemaTO;
+ }
+
+ public void createVirSchema(final AttributableType type, final VirSchemaTO schemaTO) {
+ getService(SchemaService.class).create(type, SchemaType.VIRTUAL, schemaTO);
+ }
+
+ public void updateDerSchema(final AttributableType type, final DerSchemaTO schemaTO) {
+ getService(SchemaService.class).update(type, SchemaType.DERIVED, schemaTO.getKey(), schemaTO);
+ }
+
+ public VirSchemaTO deleteVirSchema(final AttributableType type, final String name) {
+ VirSchemaTO schemaTO = getService(SchemaService.class).read(type, SchemaType.VIRTUAL, name);
+ getService(SchemaService.class).delete(type, SchemaType.VIRTUAL, name);
+ return schemaTO;
+ }
+
+ public List<String> getAllValidatorClasses() {
+ List<String> response = null;
+
+ try {
+ response = SyncopeSession.get().getSyncopeTO().getValidators();
+ } catch (SyncopeClientException e) {
+ LOG.error("While getting all validators", e);
+ }
+ return response;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/SecurityQuestionRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/SecurityQuestionRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/SecurityQuestionRestClient.java
new file mode 100644
index 0000000..119b3b5
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/SecurityQuestionRestClient.java
@@ -0,0 +1,51 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.util.List;
+import org.apache.syncope.common.lib.to.SecurityQuestionTO;
+import org.apache.syncope.common.rest.api.service.SecurityQuestionService;
+import org.springframework.stereotype.Component;
+
+@Component
+public class SecurityQuestionRestClient extends BaseRestClient {
+
+ private static final long serialVersionUID = -3167730221361895176L;
+
+ public List<SecurityQuestionTO> list() {
+ return getService(SecurityQuestionService.class).list();
+ }
+
+ public void create(final SecurityQuestionTO securityQuestionTO) {
+ getService(SecurityQuestionService.class).create(securityQuestionTO);
+ }
+
+ public void update(final SecurityQuestionTO securityQuestionTO) {
+ getService(SecurityQuestionService.class).update(securityQuestionTO.getKey(), securityQuestionTO);
+ }
+
+ public void delete(final Long securityQuestionId) {
+ getService(SecurityQuestionService.class).delete(securityQuestionId);
+ }
+
+ public SecurityQuestionTO readByUser(final String username) {
+ return getService(SecurityQuestionService.class).readByUser(username);
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/TaskRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/TaskRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/TaskRestClient.java
new file mode 100644
index 0000000..541b5cd
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/TaskRestClient.java
@@ -0,0 +1,139 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.util.List;
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.common.lib.to.AbstractTaskTO;
+import org.apache.syncope.common.lib.to.BulkAction;
+import org.apache.syncope.common.lib.to.BulkActionResult;
+import org.apache.syncope.common.lib.to.NotificationTaskTO;
+import org.apache.syncope.common.lib.to.PropagationTaskTO;
+import org.apache.syncope.common.lib.to.PushTaskTO;
+import org.apache.syncope.common.lib.to.SchedTaskTO;
+import org.apache.syncope.common.lib.to.SyncTaskTO;
+import org.apache.syncope.common.lib.types.TaskType;
+import org.apache.syncope.common.rest.api.service.TaskService;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortParam;
+import org.springframework.stereotype.Component;
+
+/**
+ * Console client for invoking Rest Tasks services.
+ */
+@Component
+public class TaskRestClient extends BaseRestClient implements ExecutionRestClient {
+
+ private static final long serialVersionUID = 6284485820911028843L;
+
+ public List<String> getJobClasses() {
+ return SyncopeSession.get().getSyncopeTO().getTaskJobs();
+ }
+
+ public List<String> getSyncActionsClasses() {
+ return SyncopeSession.get().getSyncopeTO().getSyncActions();
+ }
+
+ public List<String> getPushActionsClasses() {
+ return SyncopeSession.get().getSyncopeTO().getPushActions();
+ }
+
+ /**
+ * Return the number of tasks.
+ *
+ * @param kind of task (propagation, sched, sync).
+ * @return number of stored tasks.
+ */
+ public int count(final String kind) {
+ return getService(TaskService.class).list(TaskType.fromString(kind), 1, 1).getTotalCount();
+ }
+
+ @SuppressWarnings("unchecked")
+ public <T extends AbstractTaskTO> List<T> list(final Class<T> reference,
+ final int page, final int size, final SortParam<String> sort) {
+
+ return (List<T>) getService(TaskService.class).list(getTaskType(reference), page, size, toOrderBy(sort)).
+ getResult();
+ }
+
+ private TaskType getTaskType(final Class<?> reference) {
+ TaskType result = null;
+ if (PropagationTaskTO.class.equals(reference)) {
+ result = TaskType.PROPAGATION;
+ } else if (NotificationTaskTO.class.equals(reference)) {
+ result = TaskType.NOTIFICATION;
+ } else if (SchedTaskTO.class.equals(reference)) {
+ result = TaskType.SCHEDULED;
+ } else if (SyncTaskTO.class.equals(reference)) {
+ result = TaskType.SYNCHRONIZATION;
+ } else if (PushTaskTO.class.equals(reference)) {
+ result = TaskType.PUSH;
+ }
+ return result;
+ }
+
+ public PropagationTaskTO readPropagationTask(final Long taskId) {
+ return getService(TaskService.class).read(taskId);
+ }
+
+ public NotificationTaskTO readNotificationTask(final Long taskId) {
+ return getService(TaskService.class).read(taskId);
+ }
+
+ public <T extends SchedTaskTO> T readSchedTask(final Class<T> reference, final Long taskId) {
+ return getService(TaskService.class).read(taskId);
+ }
+
+ public void delete(final Long taskId, final Class<? extends AbstractTaskTO> taskToClass) {
+ getService(TaskService.class).delete(taskId);
+ }
+
+ @Override
+ public void startExecution(final long taskId) {
+ startExecution(taskId, false);
+ }
+
+ public void startExecution(final long taskId, final boolean dryRun) {
+ getService(TaskService.class).execute(taskId, dryRun);
+ }
+
+ @Override
+ public void deleteExecution(final long taskExecId) {
+ getService(TaskService.class).deleteExecution(taskExecId);
+ }
+
+ public void createSyncTask(final SyncTaskTO taskTO) {
+ getService(TaskService.class).create(taskTO);
+ }
+
+ public void createSchedTask(final SchedTaskTO taskTO) {
+ getService(TaskService.class).create(taskTO);
+ }
+
+ public void updateSchedTask(final SchedTaskTO taskTO) {
+ getService(TaskService.class).update(taskTO.getKey(), taskTO);
+ }
+
+ public void updateSyncTask(final SyncTaskTO taskTO) {
+ getService(TaskService.class).update(taskTO.getKey(), taskTO);
+ }
+
+ public BulkActionResult bulkAction(final BulkAction action) {
+ return getService(TaskService.class).bulk(action);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/UserRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/UserRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/UserRestClient.java
new file mode 100644
index 0000000..bca0e28
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/UserRestClient.java
@@ -0,0 +1,228 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.util.List;
+import javax.ws.rs.core.Response;
+import org.apache.syncope.client.console.commons.status.StatusBean;
+import org.apache.syncope.client.console.commons.status.StatusUtils;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.mod.ResourceAssociationMod;
+import org.apache.syncope.common.lib.mod.StatusMod;
+import org.apache.syncope.common.lib.mod.UserMod;
+import org.apache.syncope.common.lib.to.BulkAction;
+import org.apache.syncope.common.lib.to.BulkActionResult;
+import org.apache.syncope.common.lib.to.ConnObjectTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.syncope.common.lib.types.ResourceAssociationActionType;
+import org.apache.syncope.common.lib.types.ResourceDeassociationActionType;
+import org.apache.syncope.common.lib.types.SubjectType;
+import org.apache.syncope.common.lib.wrap.ResourceName;
+import org.apache.syncope.common.rest.api.CollectionWrapper;
+import org.apache.syncope.common.rest.api.service.ResourceService;
+import org.apache.syncope.common.rest.api.service.UserService;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortParam;
+import org.springframework.stereotype.Component;
+
+/**
+ * Console client for invoking rest users services.
+ */
+@Component
+public class UserRestClient extends AbstractSubjectRestClient {
+
+ private static final long serialVersionUID = -1575748964398293968L;
+
+ @Override
+ public int count() {
+ return getService(UserService.class).list(1, 1).getTotalCount();
+ }
+
+ @Override
+ public List<UserTO> list(final int page, final int size, final SortParam<String> sort) {
+ return getService(UserService.class).list(page, size, toOrderBy(sort)).getResult();
+ }
+
+ public UserTO create(final UserTO userTO, final boolean storePassword) {
+ Response response = getService(UserService.class).create(userTO, storePassword);
+ return response.readEntity(UserTO.class);
+ }
+
+ public UserTO update(final String etag, final UserMod userMod) {
+ UserTO result;
+ synchronized (this) {
+ UserService service = getService(etag, UserService.class);
+ result = service.update(userMod.getKey(), userMod).readEntity(UserTO.class);
+ resetClient(UserService.class);
+ }
+ return result;
+ }
+
+ @Override
+ public UserTO delete(final String etag, final Long id) {
+ UserTO result;
+ synchronized (this) {
+ UserService service = getService(etag, UserService.class);
+ result = service.delete(id).readEntity(UserTO.class);
+ resetClient(UserService.class);
+ }
+ return result;
+ }
+
+ public UserTO read(final Long id) {
+ UserTO userTO = null;
+ try {
+ userTO = getService(UserService.class).read(id);
+ } catch (SyncopeClientException e) {
+ LOG.error("While reading a user", e);
+ }
+ return userTO;
+ }
+
+ @Override
+ public int searchCount(final String fiql) {
+ return getService(UserService.class).search(fiql, 1, 1).getTotalCount();
+ }
+
+ @Override
+ public List<UserTO> search(final String fiql, final int page, final int size, final SortParam<String> sort) {
+ return getService(UserService.class).search(fiql, page, size, toOrderBy(sort)).getResult();
+ }
+
+ @Override
+ public ConnObjectTO getConnectorObject(final String resourceName, final Long id) {
+ return getService(ResourceService.class).getConnectorObject(resourceName, SubjectType.USER, id);
+ }
+
+ public void suspend(final String etag, final long userId, final List<StatusBean> statuses) {
+ StatusMod statusMod = StatusUtils.buildStatusMod(statuses, false);
+ statusMod.setType(StatusMod.ModType.SUSPEND);
+ synchronized (this) {
+ UserService service = getService(etag, UserService.class);
+ service.status(userId, statusMod);
+ resetClient(UserService.class);
+ }
+ }
+
+ public void reactivate(final String etag, final long userId, final List<StatusBean> statuses) {
+ StatusMod statusMod = StatusUtils.buildStatusMod(statuses, true);
+ statusMod.setType(StatusMod.ModType.REACTIVATE);
+ synchronized (this) {
+ UserService service = getService(etag, UserService.class);
+ service.status(userId, statusMod);
+ resetClient(UserService.class);
+ }
+ }
+
+ @Override
+ public BulkActionResult bulkAction(final BulkAction action) {
+ return getService(UserService.class).bulk(action);
+ }
+
+ public void unlink(final String etag, final long userId, final List<StatusBean> statuses) {
+ synchronized (this) {
+ UserService service = getService(etag, UserService.class);
+ service.bulkDeassociation(userId, ResourceDeassociationActionType.UNLINK,
+ CollectionWrapper.wrap(StatusUtils.buildStatusMod(statuses).getResourceNames(),
+ ResourceName.class));
+ resetClient(UserService.class);
+ }
+ }
+
+ public void link(final String etag, final long userId, final List<StatusBean> statuses) {
+ synchronized (this) {
+ UserService service = getService(etag, UserService.class);
+
+ final ResourceAssociationMod associationMod = new ResourceAssociationMod();
+ associationMod.getTargetResources().addAll(
+ CollectionWrapper.wrap(StatusUtils.buildStatusMod(statuses).getResourceNames(),
+ ResourceName.class));
+ service.bulkAssociation(userId, ResourceAssociationActionType.LINK, associationMod);
+
+ resetClient(UserService.class);
+ }
+ }
+
+ public BulkActionResult deprovision(final String etag, final long userId, final List<StatusBean> statuses) {
+ BulkActionResult result;
+ synchronized (this) {
+ UserService service = getService(etag, UserService.class);
+ result = service.bulkDeassociation(userId, ResourceDeassociationActionType.DEPROVISION,
+ CollectionWrapper.wrap(StatusUtils.buildStatusMod(statuses).getResourceNames(),
+ ResourceName.class)).
+ readEntity(BulkActionResult.class);
+ resetClient(UserService.class);
+ }
+ return result;
+ }
+
+ public BulkActionResult provision(final String etag, final long userId,
+ final List<StatusBean> statuses, final boolean changepwd, final String password) {
+
+ BulkActionResult result;
+ synchronized (this) {
+ UserService service = getService(etag, UserService.class);
+
+ final ResourceAssociationMod associationMod = new ResourceAssociationMod();
+ associationMod.getTargetResources().addAll(
+ CollectionWrapper.wrap(StatusUtils.buildStatusMod(statuses).getResourceNames(),
+ ResourceName.class));
+ associationMod.setChangePwd(changepwd);
+ associationMod.setPassword(password);
+
+ result = service.bulkAssociation(userId, ResourceAssociationActionType.PROVISION, associationMod).
+ readEntity(BulkActionResult.class);
+ resetClient(UserService.class);
+ }
+ return result;
+ }
+
+ public BulkActionResult unassign(final String etag, final long userId, final List<StatusBean> statuses) {
+ BulkActionResult result;
+ synchronized (this) {
+ UserService service = getService(etag, UserService.class);
+ result = service.bulkDeassociation(userId, ResourceDeassociationActionType.UNASSIGN,
+ CollectionWrapper.wrap(StatusUtils.buildStatusMod(statuses).getResourceNames(),
+ ResourceName.class)).
+ readEntity(BulkActionResult.class);
+ resetClient(UserService.class);
+ }
+ return result;
+ }
+
+ public BulkActionResult assign(final String etag, final long userId,
+ final List<StatusBean> statuses, final boolean changepwd, final String password) {
+
+ BulkActionResult result;
+ synchronized (this) {
+ UserService service = getService(etag, UserService.class);
+
+ final ResourceAssociationMod associationMod = new ResourceAssociationMod();
+ associationMod.getTargetResources().addAll(
+ CollectionWrapper.wrap(StatusUtils.buildStatusMod(statuses).getResourceNames(),
+ ResourceName.class));
+ associationMod.setChangePwd(changepwd);
+ associationMod.setPassword(password);
+
+ result = service.bulkAssociation(userId, ResourceAssociationActionType.ASSIGN, associationMod).
+ readEntity(BulkActionResult.class);
+ resetClient(UserService.class);
+ }
+ return result;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/UserSelfRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/UserSelfRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/UserSelfRestClient.java
new file mode 100644
index 0000000..1bb1079
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/UserSelfRestClient.java
@@ -0,0 +1,96 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.mod.UserMod;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.syncope.common.rest.api.service.UserSelfService;
+import org.springframework.stereotype.Component;
+
+@Component
+public class UserSelfRestClient extends BaseRestClient {
+
+ private static final long serialVersionUID = 2994691796924731295L;
+
+ public boolean isSelfRegistrationAllowed() {
+ Boolean result = null;
+ try {
+ result = SyncopeSession.get().getSyncopeTO().isSelfRegAllowed();
+ } catch (SyncopeClientException e) {
+ LOG.error("While seeking if self registration is allowed", e);
+ }
+
+ return result == null
+ ? false
+ : result.booleanValue();
+ }
+
+ public UserTO read() {
+ return getService(UserSelfService.class).read();
+ }
+
+ public void create(final UserTO userTO, final boolean storePassword) {
+ getService(UserSelfService.class).create(userTO, storePassword);
+ }
+
+ public void update(final UserMod userMod) {
+ getService(UserSelfService.class).update(userMod.getKey(), userMod);
+ }
+
+ public void delete() {
+ getService(UserSelfService.class).delete();
+ }
+
+ public boolean isPasswordResetAllowed() {
+ Boolean result = null;
+ try {
+ result = SyncopeSession.get().getSyncopeTO().isPwdResetAllowed();
+ } catch (SyncopeClientException e) {
+ LOG.error("While seeking if password reset is allowed", e);
+ }
+
+ return result == null
+ ? false
+ : result.booleanValue();
+ }
+
+ public boolean isPwdResetRequiringSecurityQuestions() {
+ Boolean result = null;
+ try {
+ result = SyncopeSession.get().getSyncopeTO().isPwdResetRequiringSecurityQuestions();
+ } catch (SyncopeClientException e) {
+ LOG.error("While seeking if password reset requires security question", e);
+ }
+
+ return result == null
+ ? false
+ : result.booleanValue();
+ }
+
+ public void requestPasswordReset(final String username, final String securityAnswer) {
+ getService(UserSelfService.class).requestPasswordReset(username, securityAnswer);
+ }
+
+ public void confirmPasswordReset(final String token, final String password) {
+ getService(UserSelfService.class).confirmPasswordReset(token, password);
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/WorkflowRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/WorkflowRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/WorkflowRestClient.java
new file mode 100644
index 0000000..f3bf60c
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/WorkflowRestClient.java
@@ -0,0 +1,69 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.io.InputStream;
+import javax.ws.rs.core.MediaType;
+import javax.ws.rs.core.Response;
+import org.apache.cxf.helpers.IOUtils;
+import org.apache.cxf.jaxrs.client.WebClient;
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.common.lib.types.SubjectType;
+import org.apache.syncope.common.rest.api.RESTHeaders;
+import org.apache.syncope.common.rest.api.service.WorkflowService;
+import org.springframework.stereotype.Component;
+
+@Component
+public class WorkflowRestClient extends BaseRestClient {
+
+ private static final long serialVersionUID = 5049285686167071017L;
+
+ private WorkflowService getService(final MediaType mediaType) {
+ return SyncopeSession.get().getService(mediaType, WorkflowService.class);
+ }
+
+ public InputStream getDefinition(final MediaType mediaType) {
+ Response response = getService(mediaType).exportDefinition(SubjectType.USER);
+
+ return (InputStream) response.getEntity();
+ }
+
+ public byte[] getDiagram() {
+ WorkflowService service = getService(WorkflowService.class);
+ WebClient.client(service).accept(RESTHeaders.MEDIATYPE_IMAGE_PNG);
+ Response response = service.exportDiagram(SubjectType.USER);
+
+ byte[] diagram;
+ try {
+ diagram = IOUtils.readBytesFromStream((InputStream) response.getEntity());
+ } catch (Exception e) {
+ LOG.error("Could not get workflow diagram", e);
+ diagram = new byte[0];
+ }
+ return diagram;
+ }
+
+ public boolean isActivitiEnabledForUsers() {
+ return SyncopeSession.get().getSyncopeTO().getUserWorkflowAdapter().indexOf("Activiti") != -1;
+ }
+
+ public void updateDefinition(final MediaType mediaType, final String definition) {
+ getService(mediaType).importDefinition(SubjectType.USER, definition);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/ajax/form/AbstractAjaxDownloadBehavior.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/ajax/form/AbstractAjaxDownloadBehavior.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/ajax/form/AbstractAjaxDownloadBehavior.java
new file mode 100644
index 0000000..8074d37
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/ajax/form/AbstractAjaxDownloadBehavior.java
@@ -0,0 +1,48 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.ajax.form;
+
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.behavior.AbstractAjaxBehavior;
+import org.apache.wicket.request.handler.resource.ResourceStreamRequestHandler;
+import org.apache.wicket.util.resource.IResourceStream;
+
+public abstract class AbstractAjaxDownloadBehavior extends AbstractAjaxBehavior {
+
+ private static final long serialVersionUID = 6833760760338614245L;
+
+ /**
+ * Call this method to initiate the download.
+ */
+ public void initiate(final AjaxRequestTarget target) {
+ CharSequence url = getCallbackUrl();
+
+ target.appendJavaScript("window.location.href='" + url + "'");
+ }
+
+ @Override
+ public void onRequest() {
+ getComponent().getRequestCycle().scheduleRequestHandlerAfterCurrent(
+ new ResourceStreamRequestHandler(getResourceStream(), getFileName()));
+ }
+
+ protected abstract String getFileName();
+
+ protected abstract IResourceStream getResourceStream();
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/ClearIndicatingAjaxButton.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/ClearIndicatingAjaxButton.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/ClearIndicatingAjaxButton.java
new file mode 100644
index 0000000..314f66c
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/ClearIndicatingAjaxButton.java
@@ -0,0 +1,76 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.ajax.markup.html;
+
+import org.apache.syncope.client.console.pages.BasePage;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.IModel;
+
+public abstract class ClearIndicatingAjaxButton extends IndicatingAjaxButton {
+
+ private static final long serialVersionUID = 7206379812788748287L;
+
+ private final PageReference pageRef;
+
+ private boolean reloadFeebackPanel = true;
+
+ public ClearIndicatingAjaxButton(final String id, final PageReference pageRef) {
+ super(id);
+ this.pageRef = pageRef;
+ }
+
+ public ClearIndicatingAjaxButton(final String id, Form<?> form, final PageReference pageRef) {
+ super(id, form);
+ this.pageRef = pageRef;
+ }
+
+ public ClearIndicatingAjaxButton(final String id, IModel<String> model, final PageReference pageRef) {
+ super(id, model);
+ this.pageRef = pageRef;
+ }
+
+ public ClearIndicatingAjaxButton(final String id, final IModel<String> model, final Form<?> form,
+ final PageReference pageRef) {
+
+ super(id, model, form);
+ this.pageRef = pageRef;
+ }
+
+ protected abstract void onSubmitInternal(AjaxRequestTarget target, Form<?> form);
+
+ public ClearIndicatingAjaxButton feedbackPanelAutomaticReload(boolean reloadFeedbackPanel) {
+ this.reloadFeebackPanel = reloadFeedbackPanel;
+ return this;
+ }
+
+ @Override
+ protected final void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ super.onSubmit(target, form);
+
+ Page page = pageRef.getPage();
+ if (reloadFeebackPanel && page instanceof BasePage) {
+ target.add(((BasePage) page).getFeedbackPanel());
+ }
+ onSubmitInternal(target, form);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/ClearIndicatingAjaxLink.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/ClearIndicatingAjaxLink.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/ClearIndicatingAjaxLink.java
new file mode 100644
index 0000000..5bb5642
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/ClearIndicatingAjaxLink.java
@@ -0,0 +1,61 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.ajax.markup.html;
+
+import org.apache.syncope.client.console.pages.BasePage;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
+import org.apache.wicket.model.IModel;
+
+public abstract class ClearIndicatingAjaxLink<T> extends IndicatingAjaxLink<T> {
+
+ private static final long serialVersionUID = 7913625094362339643L;
+
+ private final PageReference pageRef;
+
+ private boolean reloadFeedbackPanel = true;
+
+ public ClearIndicatingAjaxLink(final String id, final PageReference pageRef) {
+ super(id);
+ this.pageRef = pageRef;
+ }
+
+ public ClearIndicatingAjaxLink(final String id, final IModel<T> model, final PageReference pageRef) {
+ super(id, model);
+ this.pageRef = pageRef;
+ }
+
+ public ClearIndicatingAjaxLink<T> feedbackPanelAutomaticReload(boolean reloadFeedbackPanel) {
+ this.reloadFeedbackPanel = reloadFeedbackPanel;
+ return this;
+ }
+
+ protected abstract void onClickInternal(AjaxRequestTarget target);
+
+ @Override
+ public final void onClick(final AjaxRequestTarget target) {
+ Page page = pageRef.getPage();
+ if (reloadFeedbackPanel && page instanceof BasePage) {
+ target.add(((BasePage) page).getFeedbackPanel());
+ }
+ onClickInternal(target);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/IndicatingOnConfirmAjaxLink.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/IndicatingOnConfirmAjaxLink.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/IndicatingOnConfirmAjaxLink.java
new file mode 100644
index 0000000..86db915
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/ajax/markup/html/IndicatingOnConfirmAjaxLink.java
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.ajax.markup.html;
+
+import org.apache.wicket.Component;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.attributes.AjaxCallListener;
+import org.apache.wicket.ajax.attributes.AjaxRequestAttributes;
+
+public abstract class IndicatingOnConfirmAjaxLink<T> extends ClearIndicatingAjaxLink<T> {
+
+ private static final long serialVersionUID = 2228670850922265663L;
+
+ private final String msg;
+
+ public IndicatingOnConfirmAjaxLink(final String id, final PageReference pageRef) {
+ this(id, pageRef, "confirmDelete");
+ }
+
+ public IndicatingOnConfirmAjaxLink(final String id, final PageReference pageRef, final String msg) {
+ super(id, pageRef);
+ this.msg = msg;
+ }
+
+ @Override
+ protected void updateAjaxAttributes(final AjaxRequestAttributes attributes) {
+ super.updateAjaxAttributes(attributes);
+
+ final AjaxCallListener ajaxCallListener = new AjaxCallListener() {
+
+ private static final long serialVersionUID = 7160235486520935153L;
+
+ @Override
+ public CharSequence getPrecondition(final Component component) {
+ return "if (!confirm('"
+ + getString(IndicatingOnConfirmAjaxLink.this.msg)
+ + "')) {return false;} else {return true;}";
+ }
+ };
+ attributes.getAjaxCallListeners().add(ajaxCallListener);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/ActionColumn.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/ActionColumn.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/ActionColumn.java
new file mode 100644
index 0000000..b9dfa62
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/ActionColumn.java
@@ -0,0 +1,59 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
+
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.wicket.Component;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.IModel;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public abstract class ActionColumn<T, S> extends AbstractColumn<T, S> {
+
+ private static final long serialVersionUID = 7955560320949560725L;
+
+ /**
+ * Logger.
+ */
+ protected static final Logger LOG = LoggerFactory.getLogger(ActionColumn.class);
+
+ public ActionColumn(final IModel<String> displayModel) {
+ super(displayModel);
+ }
+
+ @Override
+ public String getCssClass() {
+ return "action";
+ }
+
+ @Override
+ public Component getHeader(final String componentId) {
+ return super.getHeader(componentId);
+ }
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<T>> item, final String componentId, final IModel<T> rowModel) {
+ item.add(getActions(componentId, rowModel));
+ }
+
+ public abstract ActionLinksPanel getActions(final String componentId, final IModel<T> rowModel);
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/ActionResultColumn.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/ActionResultColumn.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/ActionResultColumn.java
new file mode 100644
index 0000000..a2c40ff
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/ActionResultColumn.java
@@ -0,0 +1,77 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
+
+import java.beans.PropertyDescriptor;
+import org.apache.syncope.common.lib.to.BulkActionResult;
+import org.apache.syncope.common.lib.to.BulkActionResult.Status;
+import org.apache.wicket.Component;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.ResourceModel;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.BeanUtils;
+
+public class ActionResultColumn<T, S> extends AbstractColumn<T, S> {
+
+ private static final long serialVersionUID = 7955560320949560716L;
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(ActionResultColumn.class);
+
+ private final BulkActionResult results;
+
+ private final String idFieldName;
+
+ public ActionResultColumn(final BulkActionResult results, final String idFieldName) {
+ super(new Model<String>());
+ this.results = results;
+ this.idFieldName = idFieldName;
+ }
+
+ @Override
+ public String getCssClass() {
+ return "bulkResultColumn";
+ }
+
+ @Override
+ public Component getHeader(final String componentId) {
+ return new Label(componentId, new ResourceModel("bulkActionResultLabel", "Result"));
+ }
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<T>> item, final String componentId, final IModel<T> rowModel) {
+ try {
+ final PropertyDescriptor propDesc =
+ BeanUtils.getPropertyDescriptor(rowModel.getObject().getClass(), idFieldName);
+ final Object id = propDesc.getReadMethod().invoke(rowModel.getObject(), new Object[0]);
+ final Status status = id == null ? null : results.getResultMap().get(id.toString());
+ item.add(new Label(componentId, status == null ? Status.SUCCESS : status.toString()));
+ } catch (Exception e) {
+ LOG.error("Errore retrieving target id value", e);
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/AttrColumn.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/AttrColumn.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/AttrColumn.java
new file mode 100644
index 0000000..b40d7c8
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/AttrColumn.java
@@ -0,0 +1,85 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
+
+import java.util.List;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.types.SchemaType;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.ResourceModel;
+
+public class AttrColumn extends AbstractColumn<AbstractAttributableTO, String> {
+
+ private static final long serialVersionUID = 2624734332447371372L;
+
+ private final String name;
+
+ private final SchemaType schemaType;
+
+ public AttrColumn(final String name, final SchemaType schemaType) {
+ // set sortProperty to schematype#name (e.g. derivedSchema#cn,
+ // for use with SortableUserProviderComparator.AttrModel#getObject)
+ super(new ResourceModel(name, name), schemaType.name() + "#" + name);
+ this.name = name;
+ this.schemaType = schemaType;
+ }
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<AbstractAttributableTO>> cellItem, final String componentId,
+ final IModel<AbstractAttributableTO> rowModel) {
+
+ List<String> values = null;
+
+ switch (schemaType) {
+ case PLAIN:
+ if (rowModel.getObject().getPlainAttrMap().containsKey(name)) {
+ values = rowModel.getObject().getPlainAttrMap().get(name).getValues();
+ }
+ break;
+
+ case VIRTUAL:
+ if (rowModel.getObject().getVirAttrMap().containsKey(name)) {
+ values = rowModel.getObject().getVirAttrMap().get(name).getValues();
+ }
+ break;
+
+ case DERIVED:
+ if (rowModel.getObject().getDerAttrMap().containsKey(name)) {
+ values = rowModel.getObject().getDerAttrMap().get(name).getValues();
+ }
+ break;
+
+ default:
+ }
+
+ if (values == null || values.isEmpty()) {
+ cellItem.add(new Label(componentId, ""));
+ } else {
+ if (values.size() == 1) {
+ cellItem.add(new Label(componentId, values.get(0)));
+ } else {
+ cellItem.add(new Label(componentId, values.toString()));
+ }
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxGroupSelectorPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxGroupSelectorPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxGroupSelectorPanel.java
new file mode 100644
index 0000000..8f880b7
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxGroupSelectorPanel.java
@@ -0,0 +1,34 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
+
+import org.apache.wicket.markup.html.form.CheckGroup;
+import org.apache.wicket.markup.html.form.CheckGroupSelector;
+import org.apache.wicket.markup.html.panel.Panel;
+
+public class CheckBoxGroupSelectorPanel<T> extends Panel {
+
+ private static final long serialVersionUID = 4062106303929176865L;
+
+ public CheckBoxGroupSelectorPanel(final String componentId, final CheckGroup<T> group) {
+
+ super(componentId);
+ add(new CheckGroupSelector("groupselector", group));
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxPanel.java
new file mode 100644
index 0000000..db87192
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxPanel.java
@@ -0,0 +1,43 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
+
+import org.apache.syncope.client.console.commons.ActionTableCheckGroup;
+import org.apache.wicket.markup.html.form.Check;
+import org.apache.wicket.markup.html.form.CheckGroup;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+
+public class CheckBoxPanel<T> extends Panel {
+
+ private static final long serialVersionUID = 4062106303929176865L;
+
+ private final Check<T> check;
+
+ public CheckBoxPanel(final String componentId, final IModel<T> model, final CheckGroup<T> checkGroup) {
+ super(componentId, model);
+ this.check = new Check<T>("check", model, checkGroup);
+ if (checkGroup instanceof ActionTableCheckGroup) {
+ boolean checkable = ((ActionTableCheckGroup<T>) checkGroup).isCheckable(model.getObject());
+ this.check.setEnabled(checkable);
+ this.check.setVisible(checkable);
+ }
+ add(this.check);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckGroupColumn.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckGroupColumn.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckGroupColumn.java
new file mode 100644
index 0000000..cf13f3c
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckGroupColumn.java
@@ -0,0 +1,54 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
+
+import org.apache.wicket.Component;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
+import org.apache.wicket.markup.html.form.CheckGroup;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+
+public class CheckGroupColumn<T, S> extends AbstractColumn<T, S> {
+
+ private static final long serialVersionUID = 7955560320949560715L;
+
+ private final CheckGroup<T> group;
+
+ public CheckGroupColumn(final CheckGroup<T> checkGroup) {
+ super(new Model<String>());
+ this.group = checkGroup;
+ }
+
+ @Override
+ public String getCssClass() {
+ return "checkGroupColumn";
+ }
+
+ @Override
+ public Component getHeader(final String componentId) {
+ return new CheckBoxGroupSelectorPanel<T>(componentId, group);
+ }
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<T>> item, final String componentId, final IModel<T> rowModel) {
+ item.add(new CheckBoxPanel<T>(componentId, rowModel, group));
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPanel.java
new file mode 100644
index 0000000..f04fa5a
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPanel.java
@@ -0,0 +1,47 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
+
+import java.util.List;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.ResourceModel;
+
+public class CollectionPanel extends Panel {
+
+ private static final long serialVersionUID = -4042497356836230377L;
+
+ @SuppressWarnings("unchecked")
+ public CollectionPanel(final String id, final List values) {
+ super(id);
+
+ add(new ListView("collection", values) {
+
+ private static final long serialVersionUID = 4949588177564901031L;
+
+ @Override
+ protected void populateItem(final ListItem item) {
+ final String value = item.getModelObject() == null ? null : item.getModelObject().toString();
+ item.add(new Label("item", new ResourceModel(value, value)));
+ }
+ });
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPropertyColumn.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPropertyColumn.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPropertyColumn.java
new file mode 100644
index 0000000..a5fd774
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPropertyColumn.java
@@ -0,0 +1,54 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.List;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.IModel;
+
+public class CollectionPropertyColumn<T> extends PropertyColumn<T, String> {
+
+ private static final long serialVersionUID = 8077865338230121496L;
+
+ public CollectionPropertyColumn(
+ final IModel<String> displayModel,
+ final String sortProperty,
+ final String propertyExpression) {
+ super(displayModel, sortProperty, propertyExpression);
+ }
+
+ @Override
+ @SuppressWarnings("unchecked")
+ public void populateItem(
+ final Item<ICellPopulator<T>> cellItem, final String componentId, final IModel<T> rowModel) {
+
+ final Object value = getDataModel(rowModel).getObject();
+
+ if (value instanceof Collection) {
+ final List values = new ArrayList((Collection) value);
+ Collections.sort(values);
+ cellItem.add(new CollectionPanel(componentId, values));
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/DatePropertyColumn.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/DatePropertyColumn.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/DatePropertyColumn.java
new file mode 100644
index 0000000..f767aa2
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/DatePropertyColumn.java
@@ -0,0 +1,53 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
+
+import java.util.Date;
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.IModel;
+
+/**
+ * Format column's value as date string.
+ */
+public class DatePropertyColumn<T> extends PropertyColumn<T, String> {
+
+ private static final long serialVersionUID = 3527840552172947705L;
+
+ public DatePropertyColumn(final IModel<String> displayModel, final String sortProperty,
+ final String propertyExpression) {
+
+ super(displayModel, sortProperty, propertyExpression);
+ }
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<T>> item, final String componentId, final IModel<T> rowModel) {
+
+ IModel<Object> date = getDataModel(rowModel);
+
+ String convertedDate = "";
+ if (date.getObject() instanceof Date) {
+ convertedDate = SyncopeSession.get().getDateFormat().format(date.getObject());
+ }
+ item.add(new Label(componentId, convertedDate));
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/TokenColumn.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/TokenColumn.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/TokenColumn.java
new file mode 100644
index 0000000..094e450
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/TokenColumn.java
@@ -0,0 +1,51 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table;
+
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.ResourceModel;
+import org.springframework.util.StringUtils;
+
+public class TokenColumn extends AbstractColumn<AbstractAttributableTO, String> {
+
+ private static final long serialVersionUID = 8077865338230121496L;
+
+ public TokenColumn(final String name) {
+ super(new ResourceModel(name, name), name);
+ }
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<AbstractAttributableTO>> cellItem, final String componentId,
+ final IModel<AbstractAttributableTO> rowModel) {
+
+ if (rowModel.getObject() instanceof UserTO) {
+ if (StringUtils.hasText(((UserTO) rowModel.getObject()).getToken())) {
+ cellItem.add(new Label(componentId, new ResourceModel("tokenValued", "tokenValued")));
+ } else {
+ cellItem.add(new Label(componentId, new ResourceModel("tokenNotValued", "tokenNotValued")));
+ }
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/head/MetaHeaderItem.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/head/MetaHeaderItem.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/head/MetaHeaderItem.java
new file mode 100644
index 0000000..2c5150e
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/head/MetaHeaderItem.java
@@ -0,0 +1,49 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.head;
+
+import java.io.Serializable;
+import java.util.Arrays;
+import org.apache.wicket.markup.head.HeaderItem;
+import org.apache.wicket.request.Response;
+
+public class MetaHeaderItem extends HeaderItem implements Serializable {
+
+ private static final long serialVersionUID = 7578609827530302053L;
+
+ private final String key;
+
+ private final String value;
+
+ public MetaHeaderItem(final String key, final String value) {
+ this.key = key;
+ this.value = value;
+ }
+
+ @Override
+ public Iterable<?> getRenderTokens() {
+ return Arrays.asList("meta-" + key + "-" + value);
+ }
+
+ @Override
+ public void render(final Response response) {
+ response.write("<meta http-equiv=\"" + key + "\" content=\"" + value + "\"/>");
+ response.write("\n");
+ }
+}
[12/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SearchView.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SearchView.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SearchView.java
new file mode 100644
index 0000000..c081cd3
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SearchView.java
@@ -0,0 +1,461 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.List;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.IChoiceRenderer;
+import org.apache.wicket.markup.html.form.TextField;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.model.PropertyModel;
+
+public class SearchView extends ListView<SearchClause> {
+
+ private static final long serialVersionUID = -527351923968737757L;
+
+ private final WebMarkupContainer searchFormContainer;
+
+ private final boolean required;
+
+ private final IModel<List<SearchClause.Type>> types;
+
+ private final IModel<List<String>> anames;
+
+ private final IModel<List<String>> dnames;
+
+ private final IModel<List<String>> groupNames;
+
+ private final IModel<List<String>> resourceNames;
+
+ private final IModel<List<String>> entitlements;
+
+ public SearchView(final String id, final List<? extends SearchClause> list,
+ final WebMarkupContainer searchFormContainer,
+ final boolean required,
+ final IModel<List<SearchClause.Type>> types,
+ final IModel<List<String>> anames,
+ final IModel<List<String>> dnames,
+ final IModel<List<String>> groupNames,
+ final IModel<List<String>> resourceNames,
+ final IModel<List<String>> entitlements) {
+
+ super(id, list);
+
+ this.searchFormContainer = searchFormContainer;
+ this.required = required;
+ this.types = types;
+ this.anames = anames;
+ this.dnames = dnames;
+ this.groupNames = groupNames;
+ this.resourceNames = resourceNames;
+ this.entitlements = entitlements;
+ }
+
+ @Override
+ protected void populateItem(final ListItem<SearchClause> item) {
+ final SearchClause searchClause = item.getModelObject();
+
+ final DropDownChoice<SearchClause.Operator> operator = new DropDownChoice<SearchClause.Operator>("operator",
+ new PropertyModel<SearchClause.Operator>(searchClause, "operator"),
+ Arrays.asList(SearchClause.Operator.values()));
+ operator.setOutputMarkupPlaceholderTag(true);
+ operator.setNullValid(false);
+ operator.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ }
+ });
+ item.add(operator);
+ if (item.getIndex() == 0) {
+ operator.setVisible(false);
+ }
+
+ final DropDownChoice<SearchClause.Type> type = new DropDownChoice<SearchClause.Type>("type",
+ new PropertyModel<SearchClause.Type>(searchClause, "type"), types);
+ type.setOutputMarkupId(true);
+ type.setRequired(required);
+ type.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ target.add(searchFormContainer);
+ }
+ });
+ item.add(type);
+
+ @SuppressWarnings("unchecked")
+ final DropDownChoice<String> property = new DropDownChoice<String>("property",
+ new PropertyModel<String>(searchClause, "property"), (IModel) null);
+ property.setOutputMarkupId(true);
+ property.setRequired(required);
+ property.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ }
+ });
+ item.add(property);
+
+ final TextField<String> value = new TextField<String>("value",
+ new PropertyModel<String>(searchClause, "value"));
+ value.setOutputMarkupId(true);
+ value.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ }
+ });
+ item.add(value);
+
+ final DropDownChoice<SearchClause.Comparator> comparator =
+ new DropDownChoice<SearchClause.Comparator>("comparator",
+ new PropertyModel<SearchClause.Comparator>(searchClause, "comparator"),
+ Collections.<SearchClause.Comparator>emptyList());
+ comparator.setOutputMarkupId(true);
+ comparator.setNullValid(false);
+ comparator.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ if (type.getModelObject() == SearchClause.Type.ATTRIBUTE) {
+ if (comparator.getModelObject() == SearchClause.Comparator.IS_NULL
+ || comparator.getModelObject() == SearchClause.Comparator.IS_NOT_NULL) {
+
+ value.setModelObject(null);
+ value.setEnabled(false);
+ } else {
+ value.setEnabled(true);
+ }
+ target.add(value);
+ }
+ }
+ });
+ comparator.setRequired(required);
+ item.add(comparator);
+
+ AjaxLink<Void> drop = new IndicatingAjaxLink<Void>("drop") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ SearchView.this.getModel().getObject().remove(item.getModelObject());
+ target.add(searchFormContainer);
+ }
+ };
+ item.add(drop);
+ if (item.getIndex() == 0) {
+ drop.setVisible(false);
+ drop.setEnabled(false);
+ } else {
+ drop.setVisible(true);
+ drop.setEnabled(true);
+ }
+
+ final AjaxLink<Void> add = new IndicatingAjaxLink<Void>("add") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ SearchClause clause = new SearchClause();
+ SearchView.this.getModel().getObject().add(clause);
+ target.add(searchFormContainer);
+ }
+ };
+ item.add(add);
+
+ if (searchClause == null || searchClause.getType() == null) {
+ property.setChoices(Collections.<String>emptyList());
+ } else {
+ switch (searchClause.getType()) {
+ case ATTRIBUTE:
+ final List<String> names = new ArrayList<String>(dnames.getObject());
+ if (anames.getObject() != null && !anames.getObject().isEmpty()) {
+ names.addAll(anames.getObject());
+ }
+ Collections.sort(names);
+ property.setChoices(names);
+
+ comparator.setChoices(new LoadableDetachableModel<List<SearchClause.Comparator>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<SearchClause.Comparator> load() {
+ return Arrays.asList(SearchClause.Comparator.values());
+ }
+ });
+ comparator.setChoiceRenderer(new IChoiceRenderer<SearchClause.Comparator>() {
+
+ private static final long serialVersionUID = -9086043750227867686L;
+
+ @Override
+ public Object getDisplayValue(final SearchClause.Comparator object) {
+ String display;
+
+ switch (object) {
+ case IS_NULL:
+ display = "NULL";
+ break;
+
+ case IS_NOT_NULL:
+ display = "NOT NULL";
+ break;
+
+ case EQUALS:
+ display = "==";
+ break;
+
+ case NOT_EQUALS:
+ display = "!=";
+ break;
+
+ case LESS_THAN:
+ display = "<";
+ break;
+
+ case LESS_OR_EQUALS:
+ display = "<=";
+ break;
+
+ case GREATER_THAN:
+ display = ">";
+ break;
+
+ case GREATER_OR_EQUALS:
+ display = ">=";
+ break;
+
+ default:
+ display = StringUtils.EMPTY;
+ }
+
+ return display;
+ }
+
+ @Override
+ public String getIdValue(final SearchClause.Comparator object, int index) {
+ return getDisplayValue(object).toString();
+ }
+ });
+ if (!comparator.isEnabled()) {
+ comparator.setEnabled(true);
+ comparator.setRequired(true);
+ }
+
+ if (!value.isEnabled()) {
+ value.setEnabled(true);
+ }
+ break;
+
+ case MEMBERSHIP:
+ property.setChoices(groupNames);
+ property.setChoiceRenderer(new IChoiceRenderer<String>() {
+
+ private static final long serialVersionUID = -4288397951948436434L;
+
+ @Override
+ public Object getDisplayValue(final String object) {
+ return object;
+ }
+
+ @Override
+ public String getIdValue(final String object, final int index) {
+ return object;
+ }
+ });
+
+ comparator.setChoices(new LoadableDetachableModel<List<SearchClause.Comparator>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<SearchClause.Comparator> load() {
+ List<SearchClause.Comparator> comparators = new ArrayList<SearchClause.Comparator>();
+ comparators.add(SearchClause.Comparator.EQUALS);
+ comparators.add(SearchClause.Comparator.NOT_EQUALS);
+ return comparators;
+ }
+ });
+ comparator.setChoiceRenderer(new IChoiceRenderer<SearchClause.Comparator>() {
+
+ private static final long serialVersionUID = -9086043750227867686L;
+
+ @Override
+ public Object getDisplayValue(final SearchClause.Comparator object) {
+ String display;
+
+ switch (object) {
+ case EQUALS:
+ display = "IN";
+ break;
+
+ case NOT_EQUALS:
+ display = "NOT IN";
+ break;
+
+ default:
+ display = StringUtils.EMPTY;
+ }
+
+ return display;
+ }
+
+ @Override
+ public String getIdValue(final SearchClause.Comparator object, final int index) {
+ return getDisplayValue(object).toString();
+ }
+ });
+
+ value.setEnabled(false);
+ value.setModelObject("");
+
+ break;
+
+ case RESOURCE:
+ property.setChoices(resourceNames);
+
+ comparator.setChoices(new LoadableDetachableModel<List<SearchClause.Comparator>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<SearchClause.Comparator> load() {
+ List<SearchClause.Comparator> comparators = new ArrayList<SearchClause.Comparator>();
+ comparators.add(SearchClause.Comparator.EQUALS);
+ comparators.add(SearchClause.Comparator.NOT_EQUALS);
+ return comparators;
+ }
+ });
+ comparator.setChoiceRenderer(new IChoiceRenderer<SearchClause.Comparator>() {
+
+ private static final long serialVersionUID = -9086043750227867686L;
+
+ @Override
+ public Object getDisplayValue(final SearchClause.Comparator object) {
+ String display;
+
+ switch (object) {
+ case EQUALS:
+ display = "HAS";
+ break;
+
+ case NOT_EQUALS:
+ display = "HAS NOT";
+ break;
+
+ default:
+ display = StringUtils.EMPTY;
+ }
+
+ return display;
+ }
+
+ @Override
+ public String getIdValue(final SearchClause.Comparator object, final int index) {
+ return getDisplayValue(object).toString();
+ }
+ });
+
+ value.setEnabled(false);
+ value.setModelObject("");
+
+ break;
+
+ case ENTITLEMENT:
+ property.setChoices(entitlements);
+
+ comparator.setChoices(new LoadableDetachableModel<List<SearchClause.Comparator>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<SearchClause.Comparator> load() {
+ List<SearchClause.Comparator> comparators = new ArrayList<SearchClause.Comparator>();
+ comparators.add(SearchClause.Comparator.EQUALS);
+ comparators.add(SearchClause.Comparator.NOT_EQUALS);
+ return comparators;
+ }
+ });
+ comparator.setChoiceRenderer(new IChoiceRenderer<SearchClause.Comparator>() {
+
+ private static final long serialVersionUID = -9086043750227867686L;
+
+ @Override
+ public Object getDisplayValue(final SearchClause.Comparator object) {
+ String display;
+
+ switch (object) {
+ case EQUALS:
+ display = "HAS";
+ break;
+
+ case NOT_EQUALS:
+ display = "HAS NOT";
+ break;
+
+ default:
+ display = StringUtils.EMPTY;
+ }
+
+ return display;
+ }
+
+ @Override
+ public String getIdValue(final SearchClause.Comparator object, final int index) {
+ return getDisplayValue(object).toString();
+ }
+ });
+
+ value.setEnabled(false);
+ value.setModelObject("");
+
+ break;
+
+ default:
+ property.setChoices(Collections.<String>emptyList());
+ }
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SecurityQuestionPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SecurityQuestionPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SecurityQuestionPanel.java
new file mode 100644
index 0000000..8658cf6
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SecurityQuestionPanel.java
@@ -0,0 +1,98 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.Map;
+import java.util.TreeMap;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.rest.SecurityQuestionRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.common.lib.to.SecurityQuestionTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.IChoiceRenderer;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class SecurityQuestionPanel extends Panel {
+
+ private static final long serialVersionUID = -790642213865180146L;
+
+ private final Map<Long, String> questions = new TreeMap<Long, String>();
+
+ @SpringBean
+ private SecurityQuestionRestClient restClient;
+
+ public SecurityQuestionPanel(final String id, final UserTO userTO) {
+ super(id);
+ setOutputMarkupId(true);
+
+ for (SecurityQuestionTO secQues : restClient.list()) {
+ questions.put(secQues.getKey(), secQues.getContent());
+ }
+
+ final AjaxTextFieldPanel securityAnswer = new AjaxTextFieldPanel("securityAnswer", "securityAnswer",
+ new PropertyModel<String>(userTO, "securityAnswer"));
+ securityAnswer.getField().setOutputMarkupId(true);
+ securityAnswer.setEnabled(false);
+ add(securityAnswer);
+
+ final AjaxDropDownChoicePanel<Long> securityQuestion =
+ new AjaxDropDownChoicePanel<>("securityQuestion", "securityQuestion",
+ new PropertyModel<Long>(userTO, "securityQuestion"));
+ ((DropDownChoice) securityQuestion.getField()).setNullValid(true);
+ securityQuestion.setChoices(new ArrayList<>(questions.keySet()));
+ securityQuestion.setStyleSheet("ui-widget-content ui-corner-all long_dynamicsize");
+ securityQuestion.getField().setOutputMarkupId(true);
+ securityQuestion.setChoiceRenderer(new IChoiceRenderer<Long>() {
+
+ private static final long serialVersionUID = 2693996850376268294L;
+
+ @Override
+ public Object getDisplayValue(final Long object) {
+ return questions.get(object);
+ }
+
+ @Override
+ public String getIdValue(final Long object, final int index) {
+ return questions.get(object);
+ }
+ });
+ securityQuestion.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ if (securityQuestion.getModelObject() == null) {
+ securityAnswer.setModelObject(null);
+ } else {
+ securityAnswer.setEnabled(true);
+ }
+ target.add(SecurityQuestionPanel.this);
+ }
+ });
+ add(securityQuestion);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SelectOnlyUserSearchResultPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SelectOnlyUserSearchResultPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SelectOnlyUserSearchResultPanel.java
new file mode 100644
index 0000000..efa5a3d
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SelectOnlyUserSearchResultPanel.java
@@ -0,0 +1,93 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.List;
+import org.apache.syncope.client.console.pages.DisplayAttributesModalPage;
+import org.apache.syncope.client.console.rest.UserRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.event.Broadcast;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.ResourceModel;
+
+public class SelectOnlyUserSearchResultPanel extends UserSearchResultPanel {
+
+ private static final long serialVersionUID = 2146781496050131930L;
+
+ private final PageReference pageRef;
+
+ private final ModalWindow window;
+
+ public <T extends AbstractAttributableTO> SelectOnlyUserSearchResultPanel(final String id, final boolean filtered,
+ final String fiql, final PageReference pageRef, final ModalWindow window, final UserRestClient restClient) {
+
+ super(id, filtered, fiql, pageRef, restClient);
+
+ this.pageRef = pageRef;
+ this.window = window;
+ }
+
+ @Override
+ protected List<IColumn<AbstractAttributableTO, String>> getColumns() {
+ final List<IColumn<AbstractAttributableTO, String>> columns =
+ new ArrayList<IColumn<AbstractAttributableTO, String>>();
+ for (String name : DisplayAttributesModalPage.DEFAULT_SELECTION) {
+ columns.add(new PropertyColumn<AbstractAttributableTO, String>(new ResourceModel(name, name), name, name));
+ }
+
+ columns.add(new AbstractColumn<AbstractAttributableTO, String>(new ResourceModel("actions", "")) {
+
+ private static final long serialVersionUID = 8263694778917279290L;
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<AbstractAttributableTO>> cellItem,
+ final String componentId, final IModel<AbstractAttributableTO> rowModel) {
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, rowModel, pageRef);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ send(pageRef.getPage(), Broadcast.BREADTH,
+ new GroupDetailsPanel.UserOwnerSelectPayload(rowModel.getObject().getKey()));
+ window.close(target);
+ }
+ }, ActionLink.ActionType.SELECT, "Users");
+
+ cellItem.add(panel);
+ }
+ });
+
+ return columns;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SelectedEventsPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SelectedEventsPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SelectedEventsPanel.java
new file mode 100644
index 0000000..96c8d77
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SelectedEventsPanel.java
@@ -0,0 +1,167 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.List;
+import java.util.Set;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.event.Broadcast;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.markup.ComponentTag;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.IChoiceRenderer;
+import org.apache.wicket.markup.html.form.ListMultipleChoice;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.util.ListModel;
+
+public class SelectedEventsPanel extends Panel {
+
+ private static final long serialVersionUID = -4832450230348213500L;
+
+ private final WebMarkupContainer selectionContainer;
+
+ private ListMultipleChoice<String> selectedEvents;
+
+ private final IModel<List<String>> model;
+
+ public SelectedEventsPanel(final String id, final IModel<List<String>> model) {
+ super(id);
+
+ this.model = model;
+
+ selectionContainer = new WebMarkupContainer("selectionContainer");
+ selectionContainer.setOutputMarkupId(true);
+ add(selectionContainer);
+
+ selectedEvents = new ListMultipleChoice<String>("selectedEvents", new ListModel<String>(), model) {
+
+ private static final long serialVersionUID = 1226677544225737338L;
+
+ @Override
+ protected void onComponentTag(final ComponentTag tag) {
+ super.onComponentTag(tag);
+ tag.remove("size");
+ tag.remove("multiple");
+ tag.put("size", 5);
+ }
+ };
+
+ selectedEvents.setMaxRows(5);
+ selectedEvents.setChoiceRenderer(new IChoiceRenderer<String>() {
+
+ private static final long serialVersionUID = -4288397951948436434L;
+
+ @Override
+ public Object getDisplayValue(final String object) {
+ return object;
+ }
+
+ @Override
+ public String getIdValue(final String object, final int index) {
+ return object;
+ }
+ });
+
+ selectedEvents.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -151291731388673682L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ send(SelectedEventsPanel.this.getPage(),
+ Broadcast.BREADTH,
+ new InspectSelectedEvent(target, selectedEvents.getModelValue()));
+ }
+ });
+
+ selectionContainer.add(selectedEvents);
+ }
+
+ @Override
+ public void onEvent(final IEvent<?> event) {
+ if (event.getPayload() instanceof EventSelectionChanged) {
+ final EventSelectionChanged eventSelectionChanged = (EventSelectionChanged) event.getPayload();
+
+ for (String toBeRemoved : eventSelectionChanged.getToBeRemoved()) {
+ model.getObject().remove(toBeRemoved);
+ }
+
+ for (String toBeAdded : eventSelectionChanged.getToBeAdded()) {
+ if (!model.getObject().contains(toBeAdded)) {
+ model.getObject().add(toBeAdded);
+ }
+ }
+
+ eventSelectionChanged.getTarget().add(selectionContainer);
+ }
+ }
+
+ public static class InspectSelectedEvent {
+
+ private final AjaxRequestTarget target;
+
+ private final String event;
+
+ public InspectSelectedEvent(final AjaxRequestTarget target, final String event) {
+ this.target = target;
+ this.event = event;
+ }
+
+ public AjaxRequestTarget getTarget() {
+ return target;
+ }
+
+ public String getEvent() {
+ return event;
+ }
+ }
+
+ public static class EventSelectionChanged {
+
+ private final AjaxRequestTarget target;
+
+ private final Set<String> toBeRemoved;
+
+ private final Set<String> toBeAdded;
+
+ public EventSelectionChanged(
+ final AjaxRequestTarget target,
+ final Set<String> toBeAdded,
+ final Set<String> toBeRemoved) {
+ this.target = target;
+ this.toBeAdded = toBeAdded;
+ this.toBeRemoved = toBeRemoved;
+ }
+
+ public AjaxRequestTarget getTarget() {
+ return target;
+ }
+
+ public Set<String> getToBeRemoved() {
+ return toBeRemoved;
+ }
+
+ public Set<String> getToBeAdded() {
+ return toBeAdded;
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/StatusPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/StatusPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/StatusPanel.java
new file mode 100644
index 0000000..fb74065
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/StatusPanel.java
@@ -0,0 +1,262 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.LinkedHashMap;
+import java.util.List;
+import java.util.Map;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.status.ConnObjectWrapper;
+import org.apache.syncope.client.console.commons.status.Status;
+import org.apache.syncope.client.console.commons.status.StatusBean;
+import org.apache.syncope.client.console.commons.status.StatusUtils;
+import org.apache.syncope.client.console.pages.ConnObjectModalPage;
+import org.apache.syncope.client.console.rest.GroupRestClient;
+import org.apache.syncope.client.console.rest.UserRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.client.console.wicket.markup.html.list.AltListView;
+import org.apache.syncope.common.lib.mod.StatusMod;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.to.AbstractSubjectTO;
+import org.apache.syncope.common.lib.to.ConnObjectTO;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormChoiceComponentUpdatingBehavior;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.IHeaderContributor;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Check;
+import org.apache.wicket.markup.html.form.CheckGroup;
+import org.apache.wicket.markup.html.form.CheckGroupSelector;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class StatusPanel extends Panel implements IHeaderContributor {
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(StatusPanel.class);
+
+ private static final long serialVersionUID = -4064294905566247728L;
+
+ public static final String IMG_STATUES = "../statuses/";
+
+ private static final int CONNOBJECT_WIN_HEIGHT = 400;
+
+ private static final int CONNOBJECT_WIN_WIDTH = 600;
+
+ @SpringBean
+ private UserRestClient userRestClient;
+
+ @SpringBean
+ private GroupRestClient groupRestClient;
+
+ private final ModalWindow connObjectWin;
+
+ private final List<ConnObjectWrapper> connObjects;
+
+ private final Map<String, StatusBean> initialStatusBeanMap;
+
+ private final CheckGroup<StatusBean> checkGroup;
+
+ private final ListView<StatusBean> statusBeansListView;
+
+ private final StatusUtils statusUtils;
+
+ public <T extends AbstractAttributableTO> StatusPanel(
+ final String id,
+ final AbstractSubjectTO subject,
+ final List<StatusBean> selectedResources,
+ final PageReference pageref) {
+
+ super(id);
+
+ connObjectWin = new ModalWindow("connObjectWin");
+ connObjectWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ connObjectWin.setInitialHeight(CONNOBJECT_WIN_HEIGHT);
+ connObjectWin.setInitialWidth(CONNOBJECT_WIN_WIDTH);
+ connObjectWin.setCookieName("connobject-modal");
+ add(connObjectWin);
+
+ statusUtils = new StatusUtils(subject instanceof GroupTO ? groupRestClient : userRestClient);
+
+ connObjects = statusUtils.getConnectorObjects(subject);
+
+ final List<StatusBean> statusBeans = new ArrayList<>(connObjects.size() + 1);
+ initialStatusBeanMap = new LinkedHashMap<>(connObjects.size() + 1);
+
+ final StatusBean syncope = new StatusBean(subject, "syncope");
+
+ if (subject instanceof UserTO) {
+ syncope.setAccountLink(((UserTO) subject).getUsername());
+
+ Status syncopeStatus = Status.UNDEFINED;
+ if (((UserTO) subject).getStatus() != null) {
+ try {
+ syncopeStatus = Status.valueOf(((UserTO) subject).getStatus().toUpperCase());
+ } catch (IllegalArgumentException e) {
+ LOG.warn("Unexpected status found: {}", ((UserTO) subject).getStatus(), e);
+ }
+ }
+ syncope.setStatus(syncopeStatus);
+ } else if (subject instanceof GroupTO) {
+ syncope.setAccountLink(((GroupTO) subject).getDisplayName());
+ syncope.setStatus(Status.ACTIVE);
+ }
+
+ statusBeans.add(syncope);
+ initialStatusBeanMap.put(syncope.getResourceName(), syncope);
+
+ for (ConnObjectWrapper entry : connObjects) {
+ final StatusBean statusBean = statusUtils.getStatusBean(entry.getAttributable(),
+ entry.getResourceName(),
+ entry.getConnObjectTO(),
+ subject instanceof GroupTO);
+
+ initialStatusBeanMap.put(entry.getResourceName(), statusBean);
+ statusBeans.add(statusBean);
+ }
+
+ checkGroup = new CheckGroup<>("group", selectedResources);
+ checkGroup.setOutputMarkupId(true);
+ checkGroup.add(new AjaxFormChoiceComponentUpdatingBehavior() {
+
+ private static final long serialVersionUID = -151291731388673682L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ // ignore
+ }
+ });
+ add(checkGroup);
+
+ CheckGroupSelector groupSelector = new CheckGroupSelector("groupselector", checkGroup);
+ if (subject instanceof GroupTO) {
+ groupSelector.setVisible(false);
+ }
+ add(groupSelector);
+
+ statusBeansListView = new AltListView<StatusBean>("resources", statusBeans) {
+
+ private static final long serialVersionUID = 4949588177564901031L;
+
+ @Override
+ protected void populateItem(final ListItem<StatusBean> item) {
+ item.add(statusUtils.getStatusImage("icon", item.getModelObject().getStatus()));
+
+ final Check<StatusBean> check = new Check<StatusBean>("check", item.getModel(), checkGroup);
+ if (subject instanceof GroupTO) {
+ check.setVisible(false);
+ }
+ item.add(check);
+
+ item.add(new Label("resource", new ResourceModel(item.getModelObject().getResourceName(), item
+ .getModelObject().getResourceName())));
+
+ if (StringUtils.isNotBlank(item.getModelObject().getAccountLink())) {
+ item.add(new Label("accountLink", new ResourceModel(item.getModelObject().getAccountLink(),
+ item.getModelObject().getAccountLink())));
+ } else {
+ item.add(new Label("accountLink", ""));
+ }
+
+ final ConnObjectTO connObjectTO = statusUtils.getConnObjectTO(
+ item.getModelObject().getAttributableId(),
+ item.getModelObject().getResourceName(),
+ connObjects);
+
+ if (pageref == null || connObjectTO == null) {
+ item.add(new Label("connObject", new Model<String>()));
+ } else {
+ final ActionLinksPanel connObject = new ActionLinksPanel("connObject", new Model(), pageref);
+
+ connObject.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ connObjectWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ConnObjectModalPage(connObjectTO);
+ }
+ });
+
+ connObjectWin.show(target);
+ }
+ }, ActionLink.ActionType.SEARCH, "Resources", "getConnectorObject");
+
+ item.add(connObject);
+ }
+ }
+ };
+ statusBeansListView.setReuseItems(true);
+ checkGroup.add(statusBeansListView);
+ }
+
+ public StatusMod getStatusMod() {
+ StatusMod result = new StatusMod();
+
+ Collection<StatusBean> statusBeans = checkGroup.getModel().getObject();
+ if (statusBeans != null && !statusBeans.isEmpty()) {
+ result = StatusUtils.buildStatusMod(statusBeans);
+ }
+
+ return result;
+ }
+
+ public List<StatusBean> getStatusBeans() {
+ return statusBeansListView.getModelObject();
+ }
+
+ public Map<String, StatusBean> getInitialStatusBeanMap() {
+ return initialStatusBeanMap;
+ }
+
+ public void updateStatusBeans(final List<StatusBean> statusBeans) {
+ statusBeansListView.removeAll();
+ statusBeansListView.getModelObject().clear();
+ statusBeansListView.getModelObject().addAll(statusBeans);
+
+ for (StatusBean statusBean : statusBeans) {
+ if (!checkGroup.getModelObject().contains(statusBean)
+ && statusBean.getStatus() == Status.NOT_YET_SUBMITTED) {
+
+ checkGroup.getModelObject().add(statusBean);
+ }
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SyncTasksPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SyncTasksPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SyncTasksPanel.java
new file mode 100644
index 0000000..5561716
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/SyncTasksPanel.java
@@ -0,0 +1,225 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.pages.GroupTemplateModalPage;
+import org.apache.syncope.client.console.pages.SyncTaskModalPage;
+import org.apache.syncope.client.console.pages.UserTemplateModalPage;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.AbstractTaskTO;
+import org.apache.syncope.common.lib.to.SyncTaskTO;
+import org.apache.wicket.Component;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.StringResourceModel;
+
+public class SyncTasksPanel extends AbstractProvisioningTasksPanel<SyncTaskTO> {
+
+ private static final long serialVersionUID = 53189199346016099L;
+
+ public SyncTasksPanel(final String id, final PageReference pageRef) {
+ super(id, pageRef, SyncTaskTO.class);
+ initTasksTable();
+ }
+
+ @Override
+ protected List<IColumn<AbstractTaskTO, String>> getColumns() {
+ final List<IColumn<AbstractTaskTO, String>> syncTaskscolumns = new ArrayList<>();
+
+ syncTaskscolumns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("key", this, null), "key", "key"));
+ syncTaskscolumns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("name", this, null), "name", "name"));
+ syncTaskscolumns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("description", this, null), "description", "description"));
+ syncTaskscolumns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("resourceName", this, null), "resource", "resource"));
+ syncTaskscolumns.add(new DatePropertyColumn<AbstractTaskTO>(
+ new StringResourceModel("lastExec", this, null), "lastExec", "lastExec"));
+ syncTaskscolumns.add(new DatePropertyColumn<AbstractTaskTO>(
+ new StringResourceModel("nextExec", this, null), "nextExec", "nextExec"));
+ syncTaskscolumns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("latestExecStatus", this, null), "latestExecStatus", "latestExecStatus"));
+
+ syncTaskscolumns.add(new ActionColumn<AbstractTaskTO, String>(new StringResourceModel("actions", this, null, "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public ActionLinksPanel getActions(final String componentId, final IModel<AbstractTaskTO> model) {
+
+ final SyncTaskTO taskTO = (SyncTaskTO) model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, pageRef);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+
+ window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new SyncTaskModalPage(window, taskTO, pageRef);
+ }
+ });
+
+ window.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, TASKS);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+
+ window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new UserTemplateModalPage(pageRef, window, taskTO);
+ }
+ });
+
+ window.show(target);
+ }
+ }, ActionLink.ActionType.USER_TEMPLATE, TASKS);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+
+ window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new GroupTemplateModalPage(pageRef, window, taskTO);
+ }
+ });
+
+ window.show(target);
+ }
+ }, ActionLink.ActionType.GROUP_TEMPLATE, TASKS);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ restClient.startExecution(taskTO.getKey(), false);
+ getSession().info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+
+ target.add(container);
+ ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
+ }
+ }, ActionLink.ActionType.EXECUTE, TASKS);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ restClient.startExecution(taskTO.getKey(), true);
+ getSession().info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+
+ target.add(container);
+ ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
+ }
+ }, ActionLink.ActionType.DRYRUN, TASKS);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ restClient.delete(taskTO.getKey(), SyncTaskTO.class);
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+ target.add(container);
+ ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
+ }
+ }, ActionLink.ActionType.DELETE, TASKS);
+
+ return panel;
+ }
+
+ @Override
+ public Component getHeader(final String componentId) {
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), pageRef);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ if (target != null) {
+ target.add(table);
+ }
+ }
+ }, ActionLink.ActionType.RELOAD, TASKS, "list");
+
+ return panel;
+ }
+ });
+
+ return syncTaskscolumns;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/UserDetailsPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/UserDetailsPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/UserDetailsPanel.java
new file mode 100644
index 0000000..bf990ec
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/UserDetailsPanel.java
@@ -0,0 +1,122 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import org.apache.syncope.client.console.commons.JexlHelpUtils;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPasswordFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.FieldPanel;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.Component;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.behavior.Behavior;
+import org.apache.wicket.markup.ComponentTag;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.form.PasswordTextField;
+import org.apache.wicket.markup.html.form.validation.EqualPasswordInputValidator;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+
+public class UserDetailsPanel extends Panel {
+
+ private static final long serialVersionUID = 6592027822510220463L;
+
+ public UserDetailsPanel(final String id, final UserTO userTO, final Form form, final boolean resetPassword,
+ final boolean templateMode) {
+
+ super(id);
+
+ // ------------------------
+ // Username
+ // ------------------------
+ final FieldPanel<String> username = new AjaxTextFieldPanel("username", "username",
+ new PropertyModel<String>(userTO, "username"));
+
+ final WebMarkupContainer jexlHelp = JexlHelpUtils.getJexlHelpWebContainer("usernameJexlHelp");
+
+ final AjaxLink<?> questionMarkJexlHelp = JexlHelpUtils.getAjaxLink(jexlHelp, "usernameQuestionMarkJexlHelp");
+ add(questionMarkJexlHelp);
+ questionMarkJexlHelp.add(jexlHelp);
+
+ if (!templateMode) {
+ username.addRequiredLabel();
+ questionMarkJexlHelp.setVisible(false);
+ }
+ add(username);
+ // ------------------------
+
+ // ------------------------
+ // Password
+ // ------------------------
+ final WebMarkupContainer pwdJexlHelp = JexlHelpUtils.getJexlHelpWebContainer("pwdJexlHelp");
+
+ final AjaxLink<?> pwdQuestionMarkJexlHelp = JexlHelpUtils.getAjaxLink(pwdJexlHelp, "pwdQuestionMarkJexlHelp");
+ add(pwdQuestionMarkJexlHelp);
+ pwdQuestionMarkJexlHelp.add(pwdJexlHelp);
+
+ FieldPanel<String> password;
+ Label confirmPasswordLabel = new Label("confirmPasswordLabel", new ResourceModel("confirmPassword"));
+ FieldPanel<String> confirmPassword;
+ if (templateMode) {
+ password = new AjaxTextFieldPanel("password", "password", new PropertyModel<String>(userTO, "password"));
+
+ confirmPasswordLabel.setVisible(false);
+ confirmPassword = new AjaxTextFieldPanel("confirmPassword", "confirmPassword", new Model<String>());
+ confirmPassword.setEnabled(false);
+ confirmPassword.setVisible(false);
+ } else {
+ pwdQuestionMarkJexlHelp.setVisible(false);
+
+ password = new AjaxPasswordFieldPanel("password", "password",
+ new PropertyModel<String>(userTO, "password"));
+ ((PasswordTextField) password.getField()).setResetPassword(resetPassword);
+
+ confirmPassword = new AjaxPasswordFieldPanel("confirmPassword", "confirmPassword", new Model<String>());
+ if (!resetPassword) {
+ confirmPassword.getField().setModelObject(userTO.getPassword());
+ }
+ ((PasswordTextField) confirmPassword.getField()).setResetPassword(resetPassword);
+
+ form.add(new EqualPasswordInputValidator(password.getField(), confirmPassword.getField()));
+ }
+ add(password);
+ add(confirmPasswordLabel);
+ add(confirmPassword);
+
+ final WebMarkupContainer mandatoryPassword = new WebMarkupContainer("mandatory_pwd");
+ mandatoryPassword.add(new Behavior() {
+
+ private static final long serialVersionUID = 1469628524240283489L;
+
+ @Override
+ public void onComponentTag(final Component component, final ComponentTag tag) {
+ if (userTO.getKey() > 0) {
+ tag.put("style", "display:none;");
+ }
+ }
+ });
+
+ add(mandatoryPassword);
+ // ------------------------
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/UserSearchPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/UserSearchPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/UserSearchPanel.java
new file mode 100644
index 0000000..6618728
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/UserSearchPanel.java
@@ -0,0 +1,113 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.List;
+import org.apache.syncope.client.console.rest.GroupRestClient;
+import org.apache.syncope.client.lib.SyncopeClient;
+import org.apache.syncope.common.lib.search.AbstractFiqlSearchConditionBuilder;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class UserSearchPanel extends AbstractSearchPanel {
+
+ private static final long serialVersionUID = -1769527800450203738L;
+
+ @SpringBean
+ private GroupRestClient groupRestClient;
+
+ public static class Builder implements Serializable {
+
+ private static final long serialVersionUID = 6308997285778809578L;
+
+ private String id;
+
+ private String fiql = null;
+
+ private boolean required = true;
+
+ public Builder(final String id) {
+ this.id = id;
+ }
+
+ public Builder fiql(final String fiql) {
+ this.fiql = fiql;
+ return this;
+ }
+
+ public Builder required(final boolean required) {
+ this.required = required;
+ return this;
+ }
+
+ public UserSearchPanel build() {
+ return new UserSearchPanel(this);
+ }
+ }
+
+ private UserSearchPanel(final Builder builder) {
+ super(builder.id, AttributableType.USER, builder.fiql, builder.required);
+ }
+
+ @Override
+ protected void populate() {
+ super.populate();
+
+ this.types = new LoadableDetachableModel<List<SearchClause.Type>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<SearchClause.Type> load() {
+ List<SearchClause.Type> result = new ArrayList<SearchClause.Type>();
+ result.add(SearchClause.Type.ATTRIBUTE);
+ result.add(SearchClause.Type.MEMBERSHIP);
+ result.add(SearchClause.Type.RESOURCE);
+ return result;
+ }
+ };
+
+ this.groupNames = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ List<GroupTO> groupTOs = groupRestClient.list();
+
+ List<String> result = new ArrayList<>(groupTOs.size());
+ for (GroupTO group : groupTOs) {
+ result.add(group.getDisplayName());
+ }
+
+ return result;
+ }
+ };
+ }
+
+ @Override
+ protected AbstractFiqlSearchConditionBuilder getSearchConditionBuilder() {
+ return SyncopeClient.getUserSearchConditionBuilder();
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/UserSearchResultPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/UserSearchResultPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/UserSearchResultPanel.java
new file mode 100644
index 0000000..132bb66
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/UserSearchResultPanel.java
@@ -0,0 +1,297 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.lang.reflect.Field;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.Date;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.pages.DisplayAttributesModalPage;
+import org.apache.syncope.client.console.pages.EditUserModalPage;
+import org.apache.syncope.client.console.pages.ResultStatusModalPage;
+import org.apache.syncope.client.console.pages.StatusModalPage;
+import org.apache.syncope.client.console.rest.AbstractSubjectRestClient;
+import org.apache.syncope.client.console.rest.SchemaRestClient;
+import org.apache.syncope.client.console.rest.UserRestClient;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.AttrColumn;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.TokenColumn;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink.ActionType;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.syncope.common.lib.types.SchemaType;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.springframework.util.ReflectionUtils;
+
+public class UserSearchResultPanel extends AbstractSearchResultPanel {
+
+ private static final long serialVersionUID = -905187144506842332L;
+
+ private final static String PAGEID = "Users";
+
+ @SpringBean
+ private SchemaRestClient schemaRestClient;
+
+ private final List<String> pSchemaNames;
+
+ private final List<String> dSchemaNames;
+
+ private final List<String> vSchemaNames;
+
+ public <T extends AbstractAttributableTO> UserSearchResultPanel(final String id, final boolean filtered,
+ final String fiql, final PageReference callerRef, final AbstractSubjectRestClient restClient) {
+
+ super(id, filtered, fiql, callerRef, restClient);
+
+ this.pSchemaNames = schemaRestClient.getPlainSchemaNames(AttributableType.USER);
+ this.dSchemaNames = schemaRestClient.getDerSchemaNames(AttributableType.USER);
+ this.vSchemaNames = schemaRestClient.getVirSchemaNames(AttributableType.USER);
+
+ initResultTable();
+ }
+
+ @Override
+ protected List<IColumn<AbstractAttributableTO, String>> getColumns() {
+ final List<IColumn<AbstractAttributableTO, String>> columns = new ArrayList<>();
+
+ for (String name : prefMan.getList(getRequest(), Constants.PREF_USERS_DETAILS_VIEW)) {
+ final Field field = ReflectionUtils.findField(UserTO.class, name);
+
+ if ("token".equalsIgnoreCase(name)) {
+ columns.add(new TokenColumn("token"));
+ } else if (field != null && field.getType().equals(Date.class)) {
+ columns.add(new DatePropertyColumn<AbstractAttributableTO>(new ResourceModel(name, name), name, name));
+ } else {
+ columns.add(
+ new PropertyColumn<AbstractAttributableTO, String>(new ResourceModel(name, name), name, name));
+ }
+ }
+
+ for (String name : prefMan.getList(getRequest(), Constants.PREF_USERS_ATTRIBUTES_VIEW)) {
+ if (pSchemaNames.contains(name)) {
+ columns.add(new AttrColumn(name, SchemaType.PLAIN));
+ }
+ }
+
+ for (String name : prefMan.getList(getRequest(), Constants.PREF_USERS_DERIVED_ATTRIBUTES_VIEW)) {
+ if (dSchemaNames.contains(name)) {
+ columns.add(new AttrColumn(name, SchemaType.DERIVED));
+ }
+ }
+
+ for (String name : prefMan.getList(getRequest(), Constants.PREF_USERS_VIRTUAL_ATTRIBUTES_VIEW)) {
+ if (vSchemaNames.contains(name)) {
+ columns.add(new AttrColumn(name, SchemaType.VIRTUAL));
+ }
+ }
+
+ // Add defaults in case of no selection
+ if (columns.isEmpty()) {
+ for (String name : DisplayAttributesModalPage.DEFAULT_SELECTION) {
+ columns.add(
+ new PropertyColumn<AbstractAttributableTO, String>(new ResourceModel(name, name), name, name));
+ }
+
+ prefMan.setList(getRequest(), getResponse(), Constants.PREF_USERS_DETAILS_VIEW,
+ Arrays.asList(DisplayAttributesModalPage.DEFAULT_SELECTION));
+ }
+
+ columns.add(new ActionColumn<AbstractAttributableTO, String>(new ResourceModel("actions", "")) {
+
+ private static final long serialVersionUID = -3503023501954863131L;
+
+ @Override
+ public ActionLinksPanel getActions(final String componentId, final IModel<AbstractAttributableTO> model) {
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, page.getPageReference());
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ statusmodal.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new StatusModalPage<UserTO>(
+ page.getPageReference(), statusmodal, (UserTO) model.getObject());
+ }
+ });
+
+ statusmodal.show(target);
+ }
+ }, ActionLink.ActionType.MANAGE_RESOURCES, PAGEID);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ statusmodal.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new StatusModalPage<UserTO>(
+ page.getPageReference(), statusmodal, (UserTO) model.getObject(), true);
+ }
+ });
+
+ statusmodal.show(target);
+ }
+ }, ActionLink.ActionType.ENABLE, PAGEID);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ editmodal.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ // SYNCOPE-294: re-read userTO before edit
+ UserTO userTO = ((UserRestClient) restClient).read(model.getObject().getKey());
+ return new EditUserModalPage(page.getPageReference(), editmodal, userTO);
+ }
+ });
+
+ editmodal.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, PAGEID);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ final UserTO userTO = (UserTO) restClient.
+ delete(model.getObject().getETagValue(), model.getObject().getKey());
+
+ page.setModalResult(true);
+
+ editmodal.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ResultStatusModalPage.Builder(editmodal, userTO).build();
+ }
+ });
+
+ editmodal.show(target);
+ } catch (SyncopeClientException scce) {
+ error(getString(Constants.OPERATION_ERROR) + ": " + scce.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+ }, ActionLink.ActionType.DELETE, PAGEID);
+
+ return panel;
+ }
+
+ @Override
+ public ActionLinksPanel getHeader(final String componentId) {
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), page.getPageReference());
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ displaymodal.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new DisplayAttributesModalPage(page.getPageReference(), displaymodal,
+ pSchemaNames, dSchemaNames, vSchemaNames);
+ }
+ });
+
+ displaymodal.show(target);
+ }
+ }, ActionLink.ActionType.CHANGE_VIEW, PAGEID);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ if (target != null) {
+ target.add(container);
+ }
+ }
+ }, ActionLink.ActionType.RELOAD, PAGEID, "list");
+
+ return panel;
+ }
+ });
+
+ return columns;
+ }
+
+ @Override
+ protected <T extends AbstractAttributableTO> Collection<ActionType> getBulkActions() {
+ final List<ActionType> bulkActions = new ArrayList<ActionType>();
+
+ bulkActions.add(ActionType.DELETE);
+ bulkActions.add(ActionType.SUSPEND);
+ bulkActions.add(ActionType.REACTIVATE);
+
+ return bulkActions;
+ }
+
+ @Override
+ protected String getPageId() {
+ return PAGEID;
+ }
+}
[09/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer.java
new file mode 100644
index 0000000..5555616
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer.java
@@ -0,0 +1,184 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html;
+
+import java.util.Arrays;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.SelectChoiceRenderer;
+import org.apache.syncope.client.console.commons.SelectOption;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.FormComponent;
+import org.apache.wicket.markup.html.form.TextField;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+
+public class CrontabContainer extends WebMarkupContainer {
+
+ private static final long serialVersionUID = 7879593326085337650L;
+
+ private final TextField seconds;
+
+ private final TextField minutes;
+
+ private final TextField hours;
+
+ private final TextField daysOfMonth;
+
+ private final TextField months;
+
+ private final TextField daysOfWeek;
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ public CrontabContainer(final String id, final PropertyModel<String> cronExpressionModel,
+ final String cronExpression) {
+
+ super(id);
+ setOutputMarkupId(true);
+
+ final SelectOption[] CRON_TEMPLATES = {
+ new SelectOption(getString("selOpt1"), "UNSCHEDULE"),
+ new SelectOption(getString("selOpt2"), "0 0/5 * * * ?"),
+ new SelectOption(getString("selOpt3"), "0 0 12 * * ?"),
+ new SelectOption(getString("selOpt4"), "0 0 0 1 * ?"),
+ new SelectOption(getString("selOpt5"), "0 0 0 L * ?"),
+ new SelectOption(getString("selOpt6"), "0 0 0 ? * 2")
+ };
+
+ final DropDownChoice<SelectOption> cronTemplateChooser =
+ new DropDownChoice<SelectOption>("cronTemplateChooser") {
+
+ private static final long serialVersionUID = -5843424545478691442L;
+
+ @Override
+ protected CharSequence getDefaultChoice(final String selected) {
+ return "<option value=\"\">" + getString("chooseForTemplate") + "</option>";
+ }
+ };
+
+ cronTemplateChooser.setModel(new IModel<SelectOption>() {
+
+ private static final long serialVersionUID = 6762568283146531315L;
+
+ @Override
+ public SelectOption getObject() {
+ SelectOption result = null;
+ for (SelectOption so : CRON_TEMPLATES) {
+ if (so.getKeyValue().equals(cronExpressionModel.getObject())) {
+
+ result = so;
+ }
+ }
+
+ return result;
+ }
+
+ @Override
+ public void setObject(final SelectOption object) {
+ cronExpressionModel.setObject(object == null || object.equals(CRON_TEMPLATES[0])
+ ? null
+ : object.toString());
+ }
+
+ @Override
+ public void detach() {
+ // no detach
+ }
+ });
+ cronTemplateChooser.setChoices(Arrays.asList(CRON_TEMPLATES));
+ cronTemplateChooser.setChoiceRenderer(new SelectChoiceRenderer());
+ add(cronTemplateChooser);
+
+ seconds = new TextField("seconds", new Model(getCronField(cronExpression, 0)));
+ add(seconds);
+
+ minutes = new TextField("minutes", new Model(getCronField(cronExpression, 1)));
+ add(minutes);
+
+ hours = new TextField("hours", new Model(getCronField(cronExpression, 2)));
+ add(hours);
+
+ daysOfMonth = new TextField("daysOfMonth", new Model(getCronField(cronExpression, 3)));
+ add(daysOfMonth);
+
+ months = new TextField("months", new Model(getCronField(cronExpression, 4)));
+ add(months);
+
+ daysOfWeek = new TextField("daysOfWeek", new Model(getCronField(cronExpression, 5)));
+ add(daysOfWeek);
+
+ cronTemplateChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ seconds.setModelObject(getCronField(cronTemplateChooser, 0));
+ minutes.setModelObject(getCronField(cronTemplateChooser, 1));
+ hours.setModelObject(getCronField(cronTemplateChooser, 2));
+ daysOfMonth.setModelObject(getCronField(cronTemplateChooser, 3));
+ months.setModelObject(getCronField(cronTemplateChooser, 4));
+ daysOfWeek.setModelObject(getCronField(cronTemplateChooser, 5));
+ target.add(CrontabContainer.this);
+ }
+ });
+ }
+
+ private String getCronField(final FormComponent formComponent, final int field) {
+ String cronField = null;
+
+ if (formComponent != null) {
+ cronField = getCronField(formComponent.getInput(), field);
+ }
+
+ return cronField;
+ }
+
+ private String getCronField(final String cron, final int field) {
+ String cronField = null;
+
+ if (cron != null && !cron.isEmpty() && !"UNSCHEDULE".equals(cron)) {
+ cronField = cron.split(" ")[field].trim();
+ }
+
+ return cronField;
+ }
+
+ public String getCronExpression() {
+ String cronExpression = null;
+
+ if (seconds != null && seconds.getInput() != null && minutes != null && minutes.getInput() != null
+ && hours != null && hours.getInput() != null && daysOfMonth != null && daysOfMonth.getInput() != null
+ && months != null && months.getInput() != null && daysOfWeek != null && daysOfWeek.getInput() != null) {
+
+ cronExpression = new StringBuilder().
+ append(seconds.getInput().trim()).append(" ").
+ append(minutes.getInput().trim()).append(" ").
+ append(hours.getInput().trim()).append(" ").
+ append(daysOfMonth.getInput().trim()).append(" ").
+ append(months.getInput().trim()).append(" ").
+ append(daysOfWeek.getInput().trim()).toString();
+ }
+
+ return cronExpression;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AbstractFieldPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AbstractFieldPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AbstractFieldPanel.java
new file mode 100644
index 0000000..30bb47c
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AbstractFieldPanel.java
@@ -0,0 +1,40 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public abstract class AbstractFieldPanel<T> extends Panel {
+
+ /**
+ * Logger.
+ */
+ protected static final Logger LOG = LoggerFactory.getLogger(AbstractFieldPanel.class);
+
+ private static final long serialVersionUID = 5958017546318855690L;
+
+ public AbstractFieldPanel(final String id, final IModel<T> model) {
+ super(id, model);
+ }
+
+ public abstract AbstractFieldPanel setModelObject(T object);
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/ActionLink.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/ActionLink.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/ActionLink.java
new file mode 100644
index 0000000..3e7cc44
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/ActionLink.java
@@ -0,0 +1,83 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import java.io.Serializable;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+
+public abstract class ActionLink implements Serializable {
+
+ private static final long serialVersionUID = 7031329706998320639L;
+
+ private boolean reloadFeedbackPanel = true;
+
+ public enum ActionType {
+
+ CREATE("create"),
+ EDIT("read"),
+ USER_TEMPLATE("read"),
+ GROUP_TEMPLATE("read"),
+ RESET("update"),
+ ENABLE("update"),
+ SEARCH("read"),
+ DELETE("delete"),
+ EXECUTE("execute"),
+ DRYRUN("execute"),
+ CLAIM("claim"),
+ SELECT("read"),
+ EXPORT("read"),
+ SUSPEND("update"),
+ REACTIVATE("update"),
+ RELOAD("reload"),
+ CHANGE_VIEW("changeView"),
+ UNLINK("update"),
+ LINK("update"),
+ UNASSIGN("update"),
+ ASSIGN("update"),
+ DEPROVISION("update"),
+ PROVISION("update"),
+ MANAGE_RESOURCES("update"),
+ MANAGE_USERS("update"),
+ MANAGE_GROUPS("update");
+
+ private final String actionId;
+
+ private ActionType(final String actionId) {
+ this.actionId = actionId;
+ }
+
+ public String getActionId() {
+ return actionId;
+ }
+ }
+
+ public abstract void onClick(final AjaxRequestTarget target);
+
+ public void postClick() {
+ }
+
+ public boolean feedbackPanelAutomaticReload() {
+ return reloadFeedbackPanel;
+ }
+
+ public ActionLink feedbackPanelAutomaticReload(final boolean reloadFeedbackPanel) {
+ this.reloadFeedbackPanel = reloadFeedbackPanel;
+ return this;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/ActionLinksPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/ActionLinksPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/ActionLinksPanel.java
new file mode 100644
index 0000000..35e4a65
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/ActionLinksPanel.java
@@ -0,0 +1,586 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import org.apache.syncope.client.console.commons.XMLRolesReader;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.IndicatingOnConfirmAjaxLink;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.markup.html.panel.Fragment;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+/**
+ * This empty class must exist because there not seems to be alternative to provide specialized HTML for edit links.
+ */
+public class ActionLinksPanel extends Panel {
+
+ private static final long serialVersionUID = 322966537010107771L;
+
+ /**
+ * Role reader for authorizations management.
+ */
+ @SpringBean
+ protected XMLRolesReader xmlRolesReader;
+
+ private final PageReference pageRef;
+
+ public ActionLinksPanel(final String componentId, final IModel<?> model, final PageReference pageRef) {
+ super(componentId, model);
+ this.pageRef = pageRef;
+
+ super.add(new Fragment("panelClaim", "emptyFragment", this));
+ super.add(new Fragment("panelManageResources", "emptyFragment", this));
+ super.add(new Fragment("panelManageUsers", "emptyFragment", this));
+ super.add(new Fragment("panelManageGroups", "emptyFragment", this));
+ super.add(new Fragment("panelCreate", "emptyFragment", this));
+ super.add(new Fragment("panelEdit", "emptyFragment", this));
+ super.add(new Fragment("panelReset", "emptyFragment", this));
+ super.add(new Fragment("panelUserTemplate", "emptyFragment", this));
+ super.add(new Fragment("panelGroupTemplate", "emptyFragment", this));
+ super.add(new Fragment("panelEnable", "emptyFragment", this));
+ super.add(new Fragment("panelSearch", "emptyFragment", this));
+ super.add(new Fragment("panelDelete", "emptyFragment", this));
+ super.add(new Fragment("panelExecute", "emptyFragment", this));
+ super.add(new Fragment("panelDryRun", "emptyFragment", this));
+ super.add(new Fragment("panelSelect", "emptyFragment", this));
+ super.add(new Fragment("panelExport", "emptyFragment", this));
+ super.add(new Fragment("panelSuspend", "emptyFragment", this));
+ super.add(new Fragment("panelReactivate", "emptyFragment", this));
+ super.add(new Fragment("panelReload", "emptyFragment", this));
+ super.add(new Fragment("panelChangeView", "emptyFragment", this));
+ super.add(new Fragment("panelUnlink", "emptyFragment", this));
+ super.add(new Fragment("panelLink", "emptyFragment", this));
+ super.add(new Fragment("panelUnassign", "emptyFragment", this));
+ super.add(new Fragment("panelAssign", "emptyFragment", this));
+ super.add(new Fragment("panelDeprovision", "emptyFragment", this));
+ super.add(new Fragment("panelProvision", "emptyFragment", this));
+ }
+
+ public void add(
+ final ActionLink link, final ActionLink.ActionType type, final String pageId, final String actionId) {
+
+ addWithRoles(link, type, xmlRolesReader.getEntitlement(pageId, actionId), true);
+ }
+
+ public void add(
+ final ActionLink link, final ActionLink.ActionType type, final String pageId) {
+
+ add(link, type, pageId, true);
+ }
+
+ public void add(
+ final ActionLink link, final ActionLink.ActionType type, final String pageId, final boolean enabled) {
+
+ addWithRoles(link, type, xmlRolesReader.getEntitlement(pageId, type.getActionId()), enabled);
+ }
+
+ public void addWithRoles(
+ final ActionLink link, final ActionLink.ActionType type, final String roles) {
+
+ addWithRoles(link, type, roles, true);
+ }
+
+ public void addWithRoles(
+ final ActionLink link, final ActionLink.ActionType type, final String roles, final boolean enabled) {
+
+ Fragment fragment = null;
+
+ switch (type) {
+
+ case CLAIM:
+ fragment = new Fragment("panelClaim", "fragmentClaim", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("claimLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case MANAGE_RESOURCES:
+ fragment = new Fragment("panelManageResources", "fragmentManageResources", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("manageResourcesLink", pageRef) {
+
+ private static final long serialVersionUID = -6957616042924610291L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case MANAGE_USERS:
+ fragment = new Fragment("panelManageUsers", "fragmentManageUsers", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("manageUsersLink", pageRef) {
+
+ private static final long serialVersionUID = -6957616042924610292L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case MANAGE_GROUPS:
+ fragment = new Fragment("panelManageGroups", "fragmentManageGroups", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("manageGroupsLink", pageRef) {
+
+ private static final long serialVersionUID = -6957616042924610293L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case CREATE:
+ fragment = new Fragment("panelCreate", "fragmentCreate", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("createLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case RESET:
+ fragment = new Fragment("panelReset", "fragmentReset", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("resetLink", pageRef) {
+
+ private static final long serialVersionUID = -6957616042924610290L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ });
+ break;
+
+ case EDIT:
+ fragment = new Fragment("panelEdit", "fragmentEdit", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("editLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case USER_TEMPLATE:
+ fragment = new Fragment("panelUserTemplate", "fragmentUserTemplate", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("userTemplateLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case GROUP_TEMPLATE:
+ fragment = new Fragment("panelGroupTemplate", "fragmentGroupTemplate", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("groupTemplateLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case ENABLE:
+ fragment = new Fragment("panelEnable", "fragmentEnable", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("enableLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case SEARCH:
+ fragment = new Fragment("panelSearch", "fragmentSearch", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("searchLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case EXECUTE:
+ fragment = new Fragment("panelExecute", "fragmentExecute", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("executeLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case DRYRUN:
+ fragment = new Fragment("panelDryRun", "fragmentDryRun", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("dryRunLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case DELETE:
+ fragment = new Fragment("panelDelete", "fragmentDelete", this);
+
+ fragment.addOrReplace(new IndicatingOnConfirmAjaxLink<Void>("deleteLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+
+ break;
+
+ case SELECT:
+ fragment = new Fragment("panelSelect", "fragmentSelect", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("selectLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+
+ break;
+
+ case EXPORT:
+ fragment = new Fragment("panelExport", "fragmentExport", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("exportLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case SUSPEND:
+ fragment = new Fragment("panelSuspend", "fragmentSuspend", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("suspendLink", pageRef) {
+
+ private static final long serialVersionUID = -6957616042924610291L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case REACTIVATE:
+ fragment = new Fragment("panelReactivate", "fragmentReactivate", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("reactivateLink", pageRef) {
+
+ private static final long serialVersionUID = -6957616042924610292L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case RELOAD:
+ fragment = new Fragment("panelReload", "fragmentReload", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("reloadLink", pageRef) {
+
+ private static final long serialVersionUID = -6957616042924610293L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case CHANGE_VIEW:
+ fragment = new Fragment("panelChangeView", "fragmentChangeView", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("changeViewLink", pageRef) {
+
+ private static final long serialVersionUID = -6957616042924610292L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case UNLINK:
+ fragment = new Fragment("panelUnlink", "fragmentUnlink", this);
+
+ fragment.addOrReplace(
+ new IndicatingOnConfirmAjaxLink<Void>("unlinkLink", pageRef, "confirmUnlink") {
+
+ private static final long serialVersionUID = -6957616042924610293L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case LINK:
+ fragment = new Fragment("panelLink", "fragmentLink", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("linkLink", pageRef) {
+
+ private static final long serialVersionUID = -6957616042924610303L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case UNASSIGN:
+ fragment = new Fragment("panelUnassign", "fragmentUnassign", this);
+
+ fragment.addOrReplace(
+ new IndicatingOnConfirmAjaxLink<Void>("unassignLink", pageRef, "confirmUnassign") {
+
+ private static final long serialVersionUID = -6957616042924610294L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case ASSIGN:
+ fragment = new Fragment("panelAssign", "fragmentAssign", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("assignLink", pageRef) {
+
+ private static final long serialVersionUID = -6957616042924610304L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case DEPROVISION:
+ fragment = new Fragment("panelDeprovision", "fragmentDeprovision", this);
+
+ fragment.addOrReplace(
+ new IndicatingOnConfirmAjaxLink<Void>("deprovisionLink", pageRef, "confirmDeprovision") {
+
+ private static final long serialVersionUID = -6957616042924610295L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+
+ case PROVISION:
+ fragment = new Fragment("panelProvision", "fragmentProvision", this);
+
+ fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("provisionLink", pageRef) {
+
+ private static final long serialVersionUID = -6957616042924610305L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ link.onClick(target);
+ }
+ }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
+ break;
+ default:
+ // do nothing
+ }
+
+ if (fragment != null) {
+ fragment.setEnabled(enabled);
+ MetaDataRoleAuthorizationStrategy.authorize(fragment, ENABLE, roles);
+ super.addOrReplace(fragment);
+ }
+ }
+
+ public void remove(final ActionLink.ActionType type) {
+ switch (type) {
+ case CLAIM:
+ super.addOrReplace(new Fragment("panelClaim", "emptyFragment", this));
+ break;
+
+ case MANAGE_RESOURCES:
+ super.addOrReplace(new Fragment("panelManageResources", "emptyFragment", this));
+ break;
+
+ case MANAGE_USERS:
+ super.addOrReplace(new Fragment("panelManageUsers", "emptyFragment", this));
+ break;
+
+ case MANAGE_GROUPS:
+ super.addOrReplace(new Fragment("panelManageGroups", "emptyFragment", this));
+ break;
+
+ case CREATE:
+ super.addOrReplace(new Fragment("panelCreate", "emptyFragment", this));
+ break;
+
+ case EDIT:
+ super.addOrReplace(new Fragment("panelEdit", "emptyFragment", this));
+ break;
+
+ case USER_TEMPLATE:
+ super.addOrReplace(new Fragment("panelUserTemplate", "emptyFragment", this));
+ break;
+
+ case SEARCH:
+ super.addOrReplace(new Fragment("panelSearch", "emptyFragment", this));
+ break;
+
+ case EXECUTE:
+ super.addOrReplace(new Fragment("panelExecute", "emptyFragment", this));
+ break;
+
+ case DRYRUN:
+ super.addOrReplace(new Fragment("panelDryRun", "emptyFragment", this));
+ break;
+
+ case DELETE:
+ super.addOrReplace(new Fragment("panelDelete", "emptyFragment", this));
+ break;
+
+ case SELECT:
+ super.addOrReplace(new Fragment("panelSelect", "emptyFragment", this));
+ break;
+
+ case EXPORT:
+ super.addOrReplace(new Fragment("panelExport", "emptyFragment", this));
+ break;
+
+ case SUSPEND:
+ super.addOrReplace(new Fragment("panelSuspend", "emptyFragment", this));
+ break;
+
+ case REACTIVATE:
+ super.addOrReplace(new Fragment("panelReactivate", "emptyFragment", this));
+ break;
+
+ case RELOAD:
+ super.addOrReplace(new Fragment("panelReload", "emptyFragment", this));
+ break;
+
+ case CHANGE_VIEW:
+ super.addOrReplace(new Fragment("panelChangeView", "emptyFragment", this));
+ break;
+
+ case UNLINK:
+ super.addOrReplace(new Fragment("panelUnlink", "emptyFragment", this));
+ break;
+
+ case LINK:
+ super.addOrReplace(new Fragment("panelLink", "emptyFragment", this));
+ break;
+
+ case UNASSIGN:
+ super.addOrReplace(new Fragment("panelUnassign", "emptyFragment", this));
+ break;
+
+ case ASSIGN:
+ super.addOrReplace(new Fragment("panelAssign", "emptyFragment", this));
+ break;
+
+ case DEPROVISION:
+ super.addOrReplace(new Fragment("panelDeprovision", "emptyFragment", this));
+ break;
+
+ case PROVISION:
+ super.addOrReplace(new Fragment("panelProvision", "emptyFragment", this));
+ break;
+ default:
+ // do nothing
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxCheckBoxPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxCheckBoxPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxCheckBoxPanel.java
new file mode 100644
index 0000000..3702aa2
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxCheckBoxPanel.java
@@ -0,0 +1,130 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import java.io.Serializable;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.markup.html.form.CheckBox;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+
+public class AjaxCheckBoxPanel extends FieldPanel<Boolean> {
+
+ private static final long serialVersionUID = 5664138233103884310L;
+
+ public AjaxCheckBoxPanel(final String id, final String name, final IModel<Boolean> model) {
+ super(id, model);
+
+ field = new CheckBox("checkboxField", model);
+ add(field.setLabel(new Model<String>(name)).setOutputMarkupId(true));
+
+ if (!isReadOnly()) {
+ field.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ // nothing to do
+ }
+ });
+ }
+ }
+
+ @Override
+ public FieldPanel<Boolean> addRequiredLabel() {
+ if (!isRequired()) {
+ setRequired(true);
+ }
+
+ this.isRequiredLabelAdded = true;
+
+ return this;
+ }
+
+ @Override
+ public FieldPanel<Boolean> setNewModel(final List<Serializable> list) {
+ setNewModel(new Model<Boolean>() {
+
+ private static final long serialVersionUID = 527651414610325237L;
+
+ @Override
+ public Boolean getObject() {
+ Boolean value = null;
+
+ if (list != null && !list.isEmpty()) {
+ value = Boolean.TRUE.toString().equalsIgnoreCase(list.get(0).toString());
+ }
+
+ return value;
+ }
+
+ @Override
+ public void setObject(final Boolean object) {
+ list.clear();
+ if (object != null) {
+ list.add(object.toString());
+ }
+ }
+ });
+
+ return this;
+ }
+
+ @SuppressWarnings("rawtypes")
+ @Override
+ public FieldPanel<Boolean> setNewModel(final ListItem item) {
+ IModel<Boolean> model = new Model<Boolean>() {
+
+ private static final long serialVersionUID = 6799404673615637845L;
+
+ @Override
+ public Boolean getObject() {
+ Boolean bool = null;
+
+ final Object obj = item.getModelObject();
+
+ if (obj != null && !obj.toString().isEmpty()) {
+ if (obj instanceof String) {
+ bool = Boolean.TRUE.toString().equalsIgnoreCase(obj.toString());
+ } else if (obj instanceof Boolean) {
+ // Don't parse anything
+ bool = (Boolean) obj;
+ }
+ }
+
+ return bool;
+ }
+
+ @Override
+ @SuppressWarnings("unchecked")
+ public void setObject(final Boolean object) {
+ item.setModelObject(object == null ? Boolean.FALSE.toString() : object.toString());
+ }
+ };
+
+ field.setModel(model);
+ return this;
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxDecoratedCheckbox.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxDecoratedCheckbox.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxDecoratedCheckbox.java
new file mode 100644
index 0000000..547d91a
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxDecoratedCheckbox.java
@@ -0,0 +1,55 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.wicket.ajax.AjaxEventBehavior;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxCheckBox;
+import org.apache.wicket.model.IModel;
+
+/**
+ * AjaxCheckBox allowing AjaxCallDecorator.
+ */
+public abstract class AjaxDecoratedCheckbox extends AjaxCheckBox {
+
+ private static final long serialVersionUID = 7345848589265633002L;
+
+ public AjaxDecoratedCheckbox(final String id) {
+ this(id, null);
+ }
+
+ public AjaxDecoratedCheckbox(final String id, final IModel<Boolean> model) {
+ super(id, model);
+
+ add(new AjaxEventBehavior(Constants.ON_CLICK) {
+
+ private static final long serialVersionUID = -295188647830294610L;
+
+ @Override
+ protected void onEvent(final AjaxRequestTarget target) {
+ refreshComponent(target);
+ }
+ });
+ }
+
+ private void refreshComponent(final AjaxRequestTarget target) {
+ target.add(this);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxDropDownChoicePanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxDropDownChoicePanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxDropDownChoicePanel.java
new file mode 100644
index 0000000..19e0e1d
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxDropDownChoicePanel.java
@@ -0,0 +1,87 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import java.io.Serializable;
+import java.util.Collections;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.markup.html.form.ChoiceRenderer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.IChoiceRenderer;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+
+public class AjaxDropDownChoicePanel<T extends Serializable> extends FieldPanel<T> implements Cloneable {
+
+ private static final long serialVersionUID = -4716376580659196095L;
+
+ public AjaxDropDownChoicePanel(final String id, final String name, final IModel<T> model) {
+ this(id, name, model, true);
+ }
+
+ public AjaxDropDownChoicePanel(final String id, final String name, final IModel<T> model, boolean enableOnBlur) {
+ super(id, model);
+
+ field = new DropDownChoice<T>(
+ "dropDownChoiceField", model, Collections.<T>emptyList(), new ChoiceRenderer<T>());
+ add(field.setLabel(new Model<String>(name)).setOutputMarkupId(true));
+
+ if (enableOnBlur) {
+ field.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_BLUR) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ // nothing to do
+ }
+ });
+ }
+ }
+
+ @SuppressWarnings("unchecked")
+ public AjaxDropDownChoicePanel<T> setChoiceRenderer(final IChoiceRenderer renderer) {
+ ((DropDownChoice) field).setChoiceRenderer(renderer);
+ return this;
+ }
+
+ @SuppressWarnings("unchecked")
+ public AjaxDropDownChoicePanel<T> setChoices(final List<T> choices) {
+ ((DropDownChoice) field).setChoices(choices);
+ return this;
+ }
+
+ @SuppressWarnings("unchecked")
+ public AjaxDropDownChoicePanel<T> setChoices(final IModel<? extends List<? extends T>> choices) {
+ ((DropDownChoice) field).setChoices(choices);
+ return this;
+ }
+
+ @Override
+ @SuppressWarnings("unchecked")
+ public FieldPanel clone() {
+ final AjaxDropDownChoicePanel<T> panel = (AjaxDropDownChoicePanel<T>) super.clone();
+ panel.setChoiceRenderer(((DropDownChoice) field).getChoiceRenderer());
+ panel.setChoices(((DropDownChoice) field).getChoices());
+ return panel;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPalettePanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPalettePanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPalettePanel.java
new file mode 100644
index 0000000..91b6306
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPalettePanel.java
@@ -0,0 +1,70 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import java.util.Collection;
+import java.util.List;
+import org.apache.syncope.client.console.commons.SelectChoiceRenderer;
+import org.apache.wicket.extensions.markup.html.form.palette.Palette;
+import org.apache.wicket.markup.html.form.IChoiceRenderer;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.util.ListModel;
+
+public class AjaxPalettePanel<T> extends AbstractFieldPanel<List<T>> {
+
+ private static final long serialVersionUID = 7738499668258805567L;
+
+ protected final Palette<T> palette;
+
+ public AjaxPalettePanel(final String id, final IModel<List<T>> model, final ListModel<T> choices) {
+ this(id, model, choices, false);
+ }
+
+ public AjaxPalettePanel(final String id, final IModel<List<T>> model, final ListModel<T> choices,
+ final boolean allowOrder) {
+
+ this(id, model, choices, new SelectChoiceRenderer<T>(), allowOrder, false);
+ }
+
+ public AjaxPalettePanel(final String id, final IModel<List<T>> model, final ListModel<T> choices,
+ final IChoiceRenderer<T> renderer, final boolean allowOrder, final boolean allowMoveAll) {
+
+ super(id, model);
+
+ this.palette = createPalette(model, choices, renderer, allowOrder, allowMoveAll);
+ add(palette.setOutputMarkupId(true));
+ setOutputMarkupId(true);
+ }
+
+ protected Palette<T> createPalette(final IModel<List<T>> model, final ListModel<T> choices,
+ final IChoiceRenderer<T> renderer, final boolean allowOrder, final boolean allowMoveAll) {
+
+ return new NonI18nPalette<T>("paletteField", model, choices, renderer, 8, allowOrder, allowMoveAll);
+ }
+
+ @Override
+ public AjaxPalettePanel<T> setModelObject(final List<T> object) {
+ palette.setDefaultModelObject(object);
+ return this;
+ }
+
+ public Collection<T> getModelCollection() {
+ return palette.getModelCollection();
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPasswordFieldPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPasswordFieldPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPasswordFieldPanel.java
new file mode 100644
index 0000000..14fdf9e
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPasswordFieldPanel.java
@@ -0,0 +1,60 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.markup.html.form.PasswordTextField;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+
+public class AjaxPasswordFieldPanel extends FieldPanel<String> {
+
+ private static final long serialVersionUID = -5490115280336667460L;
+
+ public AjaxPasswordFieldPanel(final String id, final String name, final IModel<String> model) {
+ super(id, model);
+
+ field = new PasswordTextField("passwordField", model);
+ add(field.setLabel(new Model<String>(name)).setRequired(false).setOutputMarkupId(true));
+
+ if (!isReadOnly()) {
+ field.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget art) {
+ // nothing to do
+ }
+ });
+ }
+ }
+
+ @Override
+ public FieldPanel<String> addRequiredLabel() {
+ if (!isRequired()) {
+ setRequired(true);
+ }
+
+ this.isRequiredLabelAdded = true;
+ return this;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxTextFieldPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxTextFieldPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxTextFieldPanel.java
new file mode 100644
index 0000000..6854fb0
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxTextFieldPanel.java
@@ -0,0 +1,98 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+import java.util.regex.Pattern;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.extensions.ajax.markup.html.autocomplete.AutoCompleteSettings;
+import org.apache.wicket.extensions.ajax.markup.html.autocomplete.AutoCompleteTextField;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.validation.IValidator;
+
+public class AjaxTextFieldPanel extends FieldPanel<String> implements Cloneable {
+
+ private static final long serialVersionUID = 238940918106696068L;
+
+ private List<String> choices = Collections.emptyList();
+
+ public AjaxTextFieldPanel(final String id, final String name, final IModel<String> model) {
+ super(id, model);
+
+ final AutoCompleteSettings settings = new AutoCompleteSettings();
+ settings.setShowCompleteListOnFocusGain(true);
+ settings.setShowListOnEmptyInput(true);
+
+ field = new AutoCompleteTextField<String>("textField", model, settings) {
+
+ private static final long serialVersionUID = -6648767303091874219L;
+
+ @Override
+ protected Iterator<String> getChoices(final String input) {
+ final Pattern pattern = Pattern.compile(".*" + Pattern.quote(input) + ".*", Pattern.CASE_INSENSITIVE);
+
+ final List<String> result = new ArrayList<String>();
+
+ for (String choice : choices) {
+ if (pattern.matcher(choice).matches()) {
+ result.add(choice);
+ }
+ }
+
+ return result.iterator();
+ }
+ };
+ add(field.setLabel(new Model<String>(name)).setOutputMarkupId(true));
+
+ if (!isReadOnly()) {
+ field.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ // nothing to do
+ }
+ });
+ }
+ }
+
+ public void addValidator(final IValidator<? super String> validator) {
+ this.field.add(validator);
+ }
+
+ public void setChoices(final List<String> choices) {
+ if (choices != null) {
+ this.choices = choices;
+ }
+ }
+
+ @Override
+ public FieldPanel<String> clone() {
+ final AjaxTextFieldPanel panel = (AjaxTextFieldPanel) super.clone();
+ panel.setChoices(choices);
+ return panel;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/BinaryFieldPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/BinaryFieldPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/BinaryFieldPanel.java
new file mode 100644
index 0000000..40a88ac
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/BinaryFieldPanel.java
@@ -0,0 +1,211 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import java.io.ByteArrayInputStream;
+import javax.ws.rs.core.MediaType;
+import javax.ws.rs.core.Response;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.PreviewUtils;
+import org.apache.syncope.client.console.commons.HttpResourceStream;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.pages.BaseModalPage;
+import org.apache.syncope.common.lib.SyncopeConstants;
+import org.apache.wicket.Component;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormSubmitBehavior;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.form.StatelessForm;
+import org.apache.wicket.markup.html.form.TextField;
+import org.apache.wicket.markup.html.form.upload.FileUpload;
+import org.apache.wicket.markup.html.form.upload.FileUploadField;
+import org.apache.wicket.markup.html.link.Link;
+import org.apache.wicket.markup.html.panel.Fragment;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.request.handler.resource.ResourceStreamRequestHandler;
+import org.apache.wicket.request.resource.ContentDisposition;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.apache.wicket.util.crypt.Base64;
+import org.apache.wicket.util.lang.Bytes;
+
+public class BinaryFieldPanel extends FieldPanel<String> {
+
+ private static final long serialVersionUID = 6264462604183088931L;
+
+ private final String mimeType;
+
+ private final WebMarkupContainer container;
+
+ private final Link<Void> downloadLink;
+
+ private final Form<?> uploadForm;
+
+ private final Fragment emptyFragment;
+
+ @SpringBean
+ private PreviewUtils previewUtil;
+
+ public BinaryFieldPanel(final String id, final String name, final IModel<String> model, final String mimeType) {
+ super(id, model);
+ this.mimeType = mimeType;
+
+ uploadForm = new StatelessForm<Void>("uploadForm");
+ uploadForm.setMultiPart(true);
+ uploadForm.setMaxSize(Bytes.megabytes(4));
+ add(uploadForm);
+
+ container = new WebMarkupContainer("previewContainer");
+ container.setOutputMarkupId(true);
+
+ emptyFragment = new Fragment("panelPreview", "emptyFragment", container);
+ emptyFragment.setOutputMarkupId(true);
+ container.add(emptyFragment);
+ uploadForm.add(container);
+
+ field = new TextField<String>("textField", model);
+ add(field.setLabel(new Model<String>(name)).setOutputMarkupId(true));
+
+ uploadForm.add(new Label("preview", StringUtils.isBlank(mimeType) ? StringUtils.EMPTY : "(" + mimeType + ")"));
+
+ downloadLink = new Link<Void>("downloadLink") {
+
+ private static final long serialVersionUID = -4331619903296515985L;
+
+ @Override
+ public void onClick() {
+ try {
+ HttpResourceStream stream = new HttpResourceStream(buildResponse());
+
+ ResourceStreamRequestHandler rsrh = new ResourceStreamRequestHandler(stream);
+ rsrh.setFileName(stream.getFilename() == null ? name : stream.getFilename());
+ rsrh.setContentDisposition(ContentDisposition.ATTACHMENT);
+
+ getRequestCycle().scheduleRequestHandlerAfterCurrent(rsrh);
+ } catch (Exception e) {
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ }
+ }
+ };
+ downloadLink.setOutputMarkupId(true);
+ uploadForm.add(downloadLink);
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ final FileUploadField fileUpload = new FileUploadField("fileUpload", new Model());
+ fileUpload.setOutputMarkupId(true);
+ fileUpload.add(new AjaxFormSubmitBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target) {
+ final FileUpload uploadedFile = fileUpload.getFileUpload();
+ if (uploadedFile != null) {
+ try {
+ final byte[] uploadedBytes = uploadedFile.getBytes();
+ final String uploaded = new String(
+ Base64.encodeBase64(uploadedBytes),
+ SyncopeConstants.DEFAULT_CHARSET);
+ field.setModelObject(uploaded);
+ target.add(field);
+
+ final Component panelPreview = previewUtil.getPreviewer(mimeType, uploadedBytes);
+
+ if (panelPreview != null) {
+ changePreviewer(panelPreview);
+ }
+
+ fileUpload.setModelObject(null);
+ uploadForm.addOrReplace(fileUpload);
+ downloadLink.setEnabled(StringUtils.isNotBlank(uploaded));
+ target.add(uploadForm);
+ } catch (Exception e) {
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ ((BaseModalPage) getPage()).getFeedbackPanel().refresh(target);
+ LOG.error("While saving uploaded file", e);
+ }
+ }
+ }
+ });
+
+ uploadForm.add(fileUpload);
+
+ IndicatingAjaxLink<Void> uploadLink = new IndicatingAjaxLink<Void>("uploadLink") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ }
+ };
+ uploadForm.add(uploadLink);
+
+ IndicatingAjaxLink<Void> resetLink = new IndicatingAjaxLink<Void>("resetLink") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ field.setModelObject(null);
+ target.add(field);
+ downloadLink.setEnabled(false);
+ container.addOrReplace(emptyFragment);
+ uploadForm.addOrReplace(container);
+ target.add(uploadForm);
+ }
+ };
+ uploadForm.add(resetLink);
+ }
+
+ private Response buildResponse() {
+ return Response.ok(new ByteArrayInputStream(Base64.decodeBase64(getModelObject()))).
+ type(StringUtils.isBlank(mimeType) ? MediaType.APPLICATION_OCTET_STREAM : mimeType).build();
+ }
+
+ private void changePreviewer(final Component panelPreview) {
+ final Fragment fragment = new Fragment("panelPreview", "previewFragment", container);
+ fragment.add(panelPreview);
+ container.addOrReplace(fragment);
+ uploadForm.addOrReplace(container);
+ }
+
+ @Override
+ public BinaryFieldPanel clone() {
+ return (BinaryFieldPanel) super.clone();
+ }
+
+ @Override
+ public FieldPanel<String> setNewModel(final IModel<String> model) {
+ field.setModel(model);
+ try {
+ final Component panelPreview = previewUtil.getPreviewer(mimeType, model.getObject());
+ if (panelPreview != null) {
+ changePreviewer(panelPreview);
+ }
+ } catch (Exception e) {
+ LOG.error("While loading saved file", e);
+ }
+ downloadLink.setEnabled(StringUtils.isNotBlank(model.getObject()));
+ uploadForm.addOrReplace(downloadLink);
+ return this;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/CheckBoxMultipleChoiceFieldPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/CheckBoxMultipleChoiceFieldPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/CheckBoxMultipleChoiceFieldPanel.java
new file mode 100644
index 0000000..3c5119b
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/CheckBoxMultipleChoiceFieldPanel.java
@@ -0,0 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import java.util.List;
+
+import org.apache.wicket.markup.html.form.CheckBoxMultipleChoice;
+import org.apache.wicket.model.IModel;
+
+public class CheckBoxMultipleChoiceFieldPanel<E> extends AbstractFieldPanel<List<E>> {
+
+ private static final long serialVersionUID = 4124935025837737298L;
+
+ private final CheckBoxMultipleChoice<E> field;
+
+ public CheckBoxMultipleChoiceFieldPanel(
+ final String id, final IModel<List<E>> model, final IModel<List<E>> choices) {
+
+ super(id, model);
+
+ field = new CheckBoxMultipleChoice<E>("checkBoxMultipleChoice", model, choices);
+ add(field);
+ }
+
+ @Override
+ public AbstractFieldPanel<List<E>> setModelObject(final List<E> object) {
+ field.setModelObject(object);
+ return this;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/DateFieldPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/DateFieldPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/DateFieldPanel.java
new file mode 100644
index 0000000..1f5aaf6
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/DateFieldPanel.java
@@ -0,0 +1,132 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import java.io.Serializable;
+import java.text.ParseException;
+import java.text.SimpleDateFormat;
+import java.util.Date;
+import java.util.List;
+import java.util.Locale;
+import org.apache.syncope.common.lib.SyncopeConstants;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.springframework.util.StringUtils;
+
+public class DateFieldPanel extends FieldPanel<Date> {
+
+ private static final long serialVersionUID = -428975732068281726L;
+
+ protected final String name;
+
+ protected final String datePattern;
+
+ protected DateFieldPanel(final String id, final String name, final IModel<Date> model, final String datePattern) {
+ super(id, model);
+ this.name = name;
+ this.datePattern = datePattern;
+ }
+
+ @Override
+ public FieldPanel<Date> setNewModel(final List<Serializable> list) {
+ final SimpleDateFormat formatter = datePattern == null
+ ? new SimpleDateFormat(SyncopeConstants.DEFAULT_DATE_PATTERN, Locale.getDefault())
+ : new SimpleDateFormat(datePattern, Locale.getDefault());
+
+ setNewModel(new Model<Date>() {
+
+ private static final long serialVersionUID = 527651414610325237L;
+
+ @Override
+ public Date getObject() {
+ Date date = null;
+
+ if (list != null && !list.isEmpty() && StringUtils.hasText(list.get(0).toString())) {
+ try {
+ // Parse string using datePattern
+ date = formatter.parse(list.get(0).toString());
+ } catch (ParseException e) {
+ LOG.error("invalid parse exception", e);
+ }
+ }
+
+ return date;
+ }
+
+ @Override
+ public void setObject(final Date object) {
+ list.clear();
+ if (object != null) {
+ list.add(formatter.format(object));
+ }
+ }
+ });
+
+ return this;
+ }
+
+ @SuppressWarnings("rawtypes")
+ @Override
+ public FieldPanel<Date> setNewModel(final ListItem item) {
+ final SimpleDateFormat formatter = datePattern == null
+ ? new SimpleDateFormat(SyncopeConstants.DEFAULT_DATE_PATTERN, Locale.getDefault())
+ : new SimpleDateFormat(datePattern, Locale.getDefault());
+
+ IModel<Date> model = new Model<Date>() {
+
+ private static final long serialVersionUID = 6799404673615637845L;
+
+ @Override
+ public Date getObject() {
+ Date date = null;
+
+ final Object obj = item.getModelObject();
+
+ if (obj != null && !obj.toString().isEmpty()) {
+ if (obj instanceof String) {
+ // Parse string using datePattern
+ try {
+ date = formatter.parse(obj.toString());
+ } catch (ParseException e) {
+ LOG.error("While parsing date", e);
+ }
+ } else if (obj instanceof Date) {
+ // Don't parse anything
+ date = (Date) obj;
+ } else {
+ // consider Long
+ date = new Date((Long) obj);
+ }
+ }
+
+ return date;
+ }
+
+ @Override
+ @SuppressWarnings("unchecked")
+ public void setObject(final Date object) {
+ item.setModelObject(object != null ? formatter.format(object) : null);
+ }
+ };
+
+ field.setModel(model);
+ return this;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/DateTextFieldPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/DateTextFieldPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/DateTextFieldPanel.java
new file mode 100644
index 0000000..add3de6
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/DateTextFieldPanel.java
@@ -0,0 +1,88 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import java.util.Date;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.datetime.markup.html.form.DateTextField;
+import org.apache.wicket.extensions.yui.calendar.DatePicker;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+
+public class DateTextFieldPanel extends DateFieldPanel {
+
+ private static final long serialVersionUID = 1919852712185883648L;
+
+ public DateTextFieldPanel(final String id, final String name, final IModel<Date> model, final String datePattern) {
+ super(id, name, model, datePattern);
+
+ field = DateTextField.forDatePattern("field", model, datePattern);
+
+ if (!isReadOnly()) {
+ field.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ // nothing to do
+ }
+ });
+ }
+
+ field.add(getDatePicker());
+
+ add(field.setLabel(new Model<String>(name)).setOutputMarkupId(true));
+ }
+
+ /**
+ * Setup a DatePicker component.
+ */
+ private DatePicker getDatePicker() {
+ final DatePicker picker = new DatePicker() {
+
+ private static final long serialVersionUID = 4166072895162221956L;
+
+ @Override
+ protected boolean enableMonthYearSelection() {
+ return true;
+ }
+ };
+
+ picker.setShowOnFieldClick(true);
+
+ return picker;
+ }
+
+ @Override
+ public FieldPanel<Date> clone() {
+ final FieldPanel<Date> panel = new DateTextFieldPanel(getId(), name, new Model<Date>(), datePattern);
+ panel.setRequired(isRequired());
+ panel.setReadOnly(isReadOnly());
+ panel.setTitle(title);
+
+ if (isRequiredLabelAdded) {
+ panel.addRequiredLabel();
+ }
+
+ return panel;
+ }
+}
[29/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage.html
deleted file mode 100644
index fc9b0a5..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage.html
+++ /dev/null
@@ -1,205 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div style="margin: 5px;">
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
-
- <form wicket:id="form">
-
- <div id="tabs">
- <ul>
- <li class="tabs-selected"><a href="#profile"><span><wicket:message key="profile"/></span></a></li>
- <li><a href="#crontab"><span><wicket:message key="crontab"/></span></a></li>
- <li><a href="#executions"><span><wicket:message key="executions"/></span></a></li>
- </ul>
- <div id="profile">
- <div class="ui-widget">
- <span wicket:id="profile">
- <div id="formtable">
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <span wicket:id="idLabel">[Id]</span>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="key">[key]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="name"><wicket:message key="name"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="name">[name]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="description"><wicket:message key="description"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="description">[description]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="resource"><wicket:message key="resourceName"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="resource">[resource]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="lastExec"><wicket:message key="lastExec"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="lastExec">[lastExec]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="nextExec"><wicket:message key="nextExec"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="nextExec">[nextExec]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="actionsClassNames"><wicket:message key="actionsClasses"/></label>
- </div>
- <span wicket:id="syncActionsClassNames">
- <span wicket:id="actionsClasses">
- <select class="text ui-widget-content ui-corner-all" wicket:id="actionsClass"/>
- <a wicket:id="drop"><img src="img/minus-icon.png" alt="remove icon" class="drop_button"/></a>
- <a wicket:id="add"><img src="img/plus-icon.png" alt="add icon" class="add_button"/></a>
- <br/>
- </span>
- <a wicket:id="first"><img src="img/plus-icon.png" alt="add icon" class="add_button"/></a>
- </span>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="performCreate"><wicket:message key="creates"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="performCreate">[performCreate]</span>
- </div>
- </div>
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="performUpdate"><wicket:message key="updates"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="performUpdate">[performUpdate]</span>
- </div>
- </div>
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="performDelete"><wicket:message key="deletes"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="performDelete">[performDelete]</span>
- </div>
- </div>
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="syncStatus"><wicket:message key="syncStatus"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="syncStatus">[syncStatus]</span>
- </div>
- </div>
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="fullReconciliation"><wicket:message key="fullReconciliation"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="fullReconciliation">[fullReconciliation]</span>
- </div>
- </div>
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="matchingRule"><wicket:message key="matchingRule"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="matchingRule">[matchingRule]</span>
- </div>
- </div>
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="unmatchingRule"><wicket:message key="unmatchingRule"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="unmatchingRule">[unmatchingRule]</span>
- </div>
- </div>
- <wicket:child/>
- </div>
- </span>
- </div>
- </div>
- <div id="crontab">
- <span wicket:id="crontab">
- <div id="formtable">
- <div class="tablerow alt">
- <label for="cron"><wicket:message key="cron"/></label>
- </div>
- <div class="tablerow">
- <input type="text" id="seconds" class="text ui-widget-content ui-corner-all" wicket:id="seconds" style="width: 50px;float: left" />
- <input type="text" id="minutes" class="text ui-widget-content ui-corner-all" wicket:id="minutes" style="width: 50px;float: left" />
- <input type="text" id="hours" class="text ui-widget-content ui-corner-all" wicket:id="hours" style="width: 50px;float: left" />
- <input type="text" id="daysOfMonth" class="text ui-widget-content ui-corner-all" wicket:id="daysOfMonth" style="width: 50px;float: left" />
- <input type="text" id="months" class="text ui-widget-content ui-corner-all" wicket:id="months" style="width: 50px;float: left" />
- <input type="text" id="daysOfWeek" class="text ui-widget-content ui-corner-all" wicket:id="daysOfWeek" style="width: 50px" />
- </div>
- <div class="tablerow alt">
- <label for="cronExpression"><wicket:message key="templates"/></label>
- </div>
- <div class="tablerow">
- <select class="text ui-widget-content ui-corner-all" wicket:id="cronTemplateChooser" style="width: 250px"/>
- </div>
- </div>
- </span>
- </div>
- <div id="executions" class="ui-widget">
- <span wicket:id="executionContainer" id="executionContainer">
- <table class="ui-widget ui-widget-content"
- wicket:id="executionsTable" style="width: 100%"/>
- </span>
- </div>
- </div>
- <div style="margin: 20px 10px 0">
- <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="apply"/>
- <input type="button" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="cancel"/>
- </div>
- </form>
- </div>
- <div wicket:id="taskExecMessageWin"/>
- </wicket:extend>
-</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage.properties
deleted file mode 100644
index 4fa0321..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage.properties
+++ /dev/null
@@ -1,43 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Profile
-crontab=Schedule
-executions=Executions
-title=Task
-resourceName=Resource Name
-name=Name
-description=Description
-lastExec=Last Execution
-nextExec=Next Execution
-cron=Schedule (seconds, minutes, hours, days of month, months, days of week)
-templates=Remove task from scheduler / Use a template to schedule
-apply=Save
-startDate=Start date
-endDate=End date
-status=Status
-message=Message
-delete=Delete
-showMessage=Show
-chooseForTemplate=Use A Template
-creates=Allow create operations
-deletes=Allow delete operations
-updates=Allow update operations
-syncStatus=Allow status synchronization
-fullReconciliation=Full reconciliation
-actionsClasses=Actions classes
-matchingRule=Matching Rule
-unmatchingRule=Unmatching Rule
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage_it.properties
deleted file mode 100644
index 0ec6d67..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage_it.properties
+++ /dev/null
@@ -1,44 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Profilo
-crontab=Schedule
-executions=Esecuzioni
-title=Task
-resourceName=Nome Risorsa
-name=Nome
-description=Descrizione
-lastExec=Ultima Esecuzione
-nextExec=Prossima Esecuzione
-cron=Schedule (secondi, minuti, ore, giorni del mese, mesi, giorni della settimana)
-templates=Rimuovi task dallo scheduler / Utilizza un template per schedulare
-apply=Salva
-startDate=Data di avvio
-endDate=Data di conclusione
-status=Stato
-message=Messaggio
-delete=Rimozione
-showMessage=Mostra
-chooseForTemplate=Usa Un Template
-creates=Consenti operazioni di creazione
-deletes=Consenti operazioni di rimozione
-updates=Consenti operazioni di modifica
-syncStatus=Consenti sincronizzazione di stato
-fullReconciliation=Riconciliazione totale
-actionsClasses=Classi azioni
-syncStatus=Sincronizza stato utente
-matchingRule=Regola di corrispondenza
-unmatchingRule=Regola di non corrispondenza
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage_pt_BR.properties
deleted file mode 100644
index b790e58..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage_pt_BR.properties
+++ /dev/null
@@ -1,43 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Perfil
-crontab=Agenda
-executions=Execu\u00e7\u00f5es
-title=Tarefas
-resourceName=Nome de Recursos
-name=Nome
-description=Descri\u00e7\u00e3o
-lastExec=\u00daltima Execu\u00e7\u00e3o
-nextExec=Pr\u00f3xima Execu\u00e7\u00e3o
-cron=Agenda (segundos, minutos, horas, dias do m\u00eas, meses, dias da semana)
-templates=Remover tarefa agendada / usar template para agendar
-apply=Salvar
-startDate=Data de In\u00edcio
-endDate=Data Final
-status=Estatus
-message=Mensagem
-delete=Excluir
-showMessage=Mostrar
-chooseForTemplate=Usar um template
-creates=Permitir opera\u00e7\u00f5es de cria\u00e7\u00e3o
-deletes=Permitir opera\u00e7\u00f5es de remo\u00e7\u00e3o
-updates=Permitir a edi\u00e7\u00e3o
-syncStatus=Permitir a sincroniza\u00e7\u00e3o de status
-fullReconciliation=Reconcilia\u00e7\u00e3o completa
-actionsClasses=Classes de a\u00e7\u00f5es
-matchingRule=Regra de correspond\u00eancia
-unmatchingRule=Regra de non correspond\u00eancia
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Tasks.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Tasks.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Tasks.html
deleted file mode 100644
index 7df418a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Tasks.html
+++ /dev/null
@@ -1,46 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<wicket:extend>
-
- <div id="tabs">
- <ul>
- <li class="tabs-selected"><a href="#tabs-1"><span><wicket:message key="tab1"/></span></a></li>
- <li><a href="#tabs-2"><span><wicket:message key="tab2"/></span></a></li>
- <li><a href="#tabs-3"><span><wicket:message key="tab3"/></span></a></li>
- <li><a href="#tabs-4"><span><wicket:message key="tab4"/></span></a></li>
- <li><a href="#tabs-5"><span><wicket:message key="tab5"/></span></a></li>
- </ul>
- <div id="tabs-1">
- <span wicket:id="propagation">[propagation tasks]</span>
- </div>
- <div id="tabs-2">
- <span wicket:id="notification">[notification tasks]</span>
- </div>
- <div id="tabs-3">
- <span wicket:id="sched">[scheduled tasks]</span>
- </div>
- <div id="tabs-4">
- <span wicket:id="sync">[synchronization tasks]</span>
- </div>
- <div id="tabs-5">
- <span wicket:id="push">[push tasks]</span>
- </div>
- </div>
-
-</wicket:extend>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Tasks.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Tasks.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Tasks.properties
deleted file mode 100644
index 6dcc9f7..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Tasks.properties
+++ /dev/null
@@ -1,21 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=Propagation Tasks
-tab2=Notification tasks
-tab3=Scheduled Tasks
-tab4=Synchronization Tasks
-tab5=Push Tasks
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Tasks_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Tasks_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Tasks_it.properties
deleted file mode 100644
index 2c050e1..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Tasks_it.properties
+++ /dev/null
@@ -1,21 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=Task di propagazione
-tab2=Task di notifica
-tab3=Task programmabili
-tab4=Task di sincronizzazione
-tab5=Task di push
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Tasks_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Tasks_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Tasks_pt_BR.properties
deleted file mode 100644
index 638934a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Tasks_pt_BR.properties
+++ /dev/null
@@ -1,21 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=Propaga\u00e7\u00e3o de Tarefas
-tab2=Tarefas de Notifica\u00e7\u00e3o
-tab3=Tarefas Agendadas
-tab4=Sincroniza\u00e7\u00e3o de Tarefas
-tab5=Push de Tarefas
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Todo.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Todo.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Todo.html
deleted file mode 100644
index e18efa0..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Todo.html
+++ /dev/null
@@ -1,45 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div id="tabs">
- <ul>
- <li class="tabs-selected"><a href="#tabs-1"><span><wicket:message key="approvals"/></span></a></li>
- </ul>
- <div id="tabs-1">
-
- <div id="users-contain" class="ui-widget" style="width:inherit;">
- <span wicket:id="approvalContainer">
- <table class="ui-widget ui-widget-content table-hover"
- wicket:id="approvalTable"/>
- </span>
- <span style="float:right">
- <form wicket:id="paginatorForm" style="display:inline">
- <label><wicket:message key="displayRows"/></label>
- <select class="text ui-widget-content ui-corner-all"
- wicket:id="rowsChooser"/>
- </form>
- </span>
- </div>
-
- <div wicket:id="editApprovalWin">[Show modal window for editing approval]</div>
- </div>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Todo.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Todo.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Todo.properties
deleted file mode 100644
index 2e4442a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Todo.properties
+++ /dev/null
@@ -1,31 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-taskId=Task
-key=Key
-description=Description
-createTime=Create time
-dueDate=Due date
-owner=Owner
-claim=Claim
-manage=Manage
-approvals=Approvals
-delete=Delete
-type=Type
-username=User
-new_user=New user
-creationDate = Creation date
-claimDate = Claim date
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Todo_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Todo_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Todo_it.properties
deleted file mode 100644
index df4fba8..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Todo_it.properties
+++ /dev/null
@@ -1,31 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-taskId=Task
-key=Chiave
-description=Descrizione
-createTime=Data di creazione
-dueDate=Scadenza
-owner=Esecutore
-claim=Richiedi
-manage=Gestisci
-approvals=Approvazioni
-delete=Rimuovi
-type=Tipo
-username=Utente
-new_user=Nuovo utente
-creationDate = Data creazione
-claimDate = Data rivendicazione
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Todo_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Todo_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Todo_pt_BR.properties
deleted file mode 100644
index fb255fb..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Todo_pt_BR.properties
+++ /dev/null
@@ -1,31 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-taskId=Tarefa
-key=Chave
-description=Descri\u00e7\u00e3o
-createTime=Tempo de Cria\u00e7\u00e3o
-dueDate=Data acordada
-owner=Propriet\u00e1rio
-claim=Requerimento
-manage=Ger\u00eancia
-approvals=Aprova\u00e7\u00e3o
-delete=Excluir
-type=Tipo
-username=Usu\u00e1rio
-new_user=Novo Usu\u00e1rio
-creationDate = Data de cria\u00e7\u00e3o
-claimDate = Data de reivindica\u00e7\u00e3o
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserModalPage.html
deleted file mode 100644
index 991f726..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserModalPage.html
+++ /dev/null
@@ -1,97 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
-
- <span wicket:id="userModalFrag"/>
-
- <wicket:fragment wicket:id="userModalEditFrag">
-
- <div style="margin: 5px;">
- <p class="ui-widget ui-corner-all ui-widget-header">
- <span wicket:id="new"/> <wicket:message key="title"/> <span wicket:id="id"/>
- </p>
-
- <form wicket:id="UserForm">
- <div id="tabs">
- <ul>
- <li class="tabs-selected"><a href="#tabs-1"><span><wicket:message key="tab1"/></span></a></li>
- <li><a href="#tabs-2"><span><wicket:message key="tab2"/></span></a></li>
- <li><a href="#tabs-3"><span><wicket:message key="tab3"/></span></a></li>
- <li><a href="#tabs-4"><span><wicket:message key="tab4"/></span></a></li>
- <li><a href="#tabs-5"><span><wicket:message key="tab5"/></span></a></li>
- <li><a href="#tabs-6"><span><wicket:message key="tab6"/></span></a></li>
- </ul>
- <div id="tabs-1">
- <span wicket:id="details">[user details]</span>
- <span wicket:id="storePwdFrag">[storePwdFrag]</span>
- <wicket:fragment wicket:id="storePwdCheck">
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <span wicket:id="storePasswordLabel">[storePasswordLabel]</span>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="storePassword">[storePassword]</span>
- </div>
- </div>
- </wicket:fragment>
- <wicket:fragment wicket:id="emptyFragment">
- </wicket:fragment>
- <div wicket:id="securityQuestion">[Security Question]</div>
- <div wicket:id="pwdChangeInfo" style="margin-top: 10px;">[pwdChangeInfo]</div>
- <span wicket:id="statuspanel">[Status Panel]</span>
- <span wicket:id="accountinformation">[Account Information]</span>
- </div>
- <div id="tabs-2">
- <div id="formtable">
- <span wicket:id="plainAttrs">[user plain attributes]</span>
- </div>
- </div>
-
- <div id="tabs-3">
- <span wicket:id="derAttrs">[user derived attributes]</span>
- </div>
-
- <div id="tabs-4">
- <span wicket:id="virAttrs">[user virtual attributes]</span>
- </div>
-
- <div id="tabs-5">
- <span wicket:id="resources">[resources]</span>
- </div>
-
- <div id="tabs-6">
- <span wicket:id="memberships">[memberships]</span>
- </div>
- </div>
-
- <div style="margin: 20px 10px 0">
- <input type="submit"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="apply"/>
- <input type="button"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="cancel"/>
- </div>
- </form>
- </div>
- </wicket:fragment>
-
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserModalPage.properties
deleted file mode 100644
index 9cb9c55..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserModalPage.properties
+++ /dev/null
@@ -1,52 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-required_alert=All form fields are required.
-title=User
-firstname=Firstname
-surname=Surname
-tab1=Details
-tab2=Plain attributes
-tab3=Derived attributes
-tab4=Virtual attributes
-tab5=Resources
-tab6=Groups
-add=+
-drop=-
-resources=Resources transfer
-firstResourcesList=User's resources
-secondResourcesList=Available resources
-updating_error=Generic error occurred during updating
-column1=Groups
-column2=Action
-
-edit=Edit
-delete=Delete
-derAttrs=Derived Attributes
-derAttrToRemove=Delete
-derAttrName=Name
-derAttrValue=Derived value
-
-virAttrs=Virtual Attributes
-virAttrToRemove=Delete
-virAttrName=Name
-virAttrValue=Virtual value
-
-addAttributeBtn=Add
-new=New
-pwdChangeInfo=If provided, the password will be changed on the following resources.
-
-storePassword=Store password internally
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserModalPage_it.properties
deleted file mode 100644
index 454a171..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserModalPage_it.properties
+++ /dev/null
@@ -1,53 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-required_alert=Tutti i campi sono obbligatori.
-title=Utente
-firstname=Nome
-surname=Cognome
-tab1=Details
-tab2=Attributi normali
-tab3=Attributi derivati
-tab4=Attributi virtuali
-tab5=Risorse
-tab6=Gruppi
-add=+
-drop=-
-resources=Associazione risorse
-firstResourcesList=Risorse utente
-secondResourcesList=Risorse disponibili
-updating_error=Errore generico durante l'aggiornamento
-column1=Gruppi
-column2=Azioni
-edit=Modifica
-delete=Rimuovi
-
-derAttrs=Attributi derivati
-derAttrToRemove=Elimina
-derAttrName=Nome
-derAttrValue=Valore derivato
-
-virAttrs=Attributi virtual
-virAttrToRemove=Elimina
-virAttrName=Nome
-virAttrValue=Valore virtuale
-
-addAttributeBtn=Aggiungi
-
-new=Nuovo
-pwdChangeInfo=Se inserita, la password verr\u00e0 cambiata sulle seguenti risorse.
-
-storePassword=Salva la password internamente
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserModalPage_pt_BR.properties
deleted file mode 100644
index 8486112..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserModalPage_pt_BR.properties
+++ /dev/null
@@ -1,52 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-required_alert=Todos os campos s\u00e3o obrigat\u00f3rios
-title=Usu\u00e1rio
-firstname=Nome
-surname=Sobrenome
-tab1=Detalhes
-tab2=Atributos Normal
-tab3=Atriutos Derivados
-tab4=Atributos Virtuais
-tab5=Recursos
-tab6=Grupos
-add=+
-drop=-
-resources=Transfer\u00eancia de Recursos
-firstResourcesList=Recursos de usu\u00e1rio
-secondResourcesList=Recursos Dispon\u00edveis
-updating_error=Um erro gern\u00e9rico ocorreu durante a atualiza\u00e7\u00e3o
-column1=Grupos
-column2=A\u00e7\u00e3o
-
-edit=Alterar
-delete=Excluir
-derAttrs=Atributos Derivados
-derAttrToRemove=Excluir
-derAttrName=Nome
-derAttrValue=Valor Derivado
-
-virAttrs=Atributos virtuais
-virAttrToRemove=Excluir
-virAttrName=Nome
-virAttrValue=Valor Virtual
-
-addAttributeBtn=Adicionar
-new=Novo
-pwdChangeInfo=Se provida, a senha ser\u00e1 alterada nos seguintes recursos
-
-storePassword=Salvar senha internamente
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage.html
deleted file mode 100644
index e62e4f3..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage.html
+++ /dev/null
@@ -1,38 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<wicket:extend>
- <div style="padding: 5px;">
- <div>
- <form wicket:id="searchForm">
- <span wicket:id="searchPanel">searchPanel</span>
-
- <br/>
- <a wicket:id="search"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only">
- <img src="img/search.png" alt="search"/>
- <wicket:message key="search"/>
- </a>
- </form>
- </div>
-
- <div id="users-contain" class="ui-widget" style="width:auto">
- <span wicket:id="searchResult"> [search result] </span>
- </div>
- </div>
-</wicket:extend>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage.properties
deleted file mode 100644
index 6e0a6ea..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage.properties
+++ /dev/null
@@ -1,23 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-search=Search
-search_error=Error:search's format is invalid
-search_noResults=No matches found.
-reset=Reset
-showingFrom=Showing
-showingTo=to
-showingOf=of
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage_it.properties
deleted file mode 100644
index 1d4f230..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage_it.properties
+++ /dev/null
@@ -1,23 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-search=Cerca
-search_error=Errore:il formato di ricerca non \u00e8 valido
-search_noResults=Nessuna corrispondenza trovata.
-reset=Reset
-showingFrom=Risultati da
-showingTo=a
-showingOf=di
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage_pt_BR.properties
deleted file mode 100644
index 28ef869..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage_pt_BR.properties
+++ /dev/null
@@ -1,23 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-search=Senha
-search_error=Erro\: formato de busca incorreto.
-search_noResults=Nenhum resultado encontrado.
-reset=Resetar
-showingFrom=Mostrando
-showingTo=para
-showingOf=de
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Users.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Users.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Users.html
deleted file mode 100644
index e302ea1..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Users.html
+++ /dev/null
@@ -1,72 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div id="tabs">
- <ul>
- <li class="tabs-selected">
- <a href="#tabs-1">
- <span><wicket:message key="tab1"/>
- </span>
- </a>
- </li>
- <li>
- <a href="#tabs-2">
- <span><wicket:message key="tab2"/>
- </span>
- </a>
- </li>
- </ul>
-
- <div id="tabs-1">
- <div id="users-contain" class="ui-widget" style="width:auto">
- <span wicket:id="listResult"> [search result] </span>
- <div wicket:id="editModal" ></div>
- </div>
-
- <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="createLink">
- <wicket:message key="create"/>
- </a>
- </div>
-
- <div id="tabs-2">
- <div>
- <form wicket:id="searchForm">
- <span wicket:id="searchPanel">searchPanel</span>
-
- <br/>
- <a wicket:id="search"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only">
- <img src="img/search.png" alt="search"/>
- <wicket:message key="search"/>
- </a>
- </form>
- </div>
-
- <div id="users-contain" class="ui-widget" style="width:auto">
- <span wicket:id="searchResult">[search result]</span>
- </div>
- </div>
-
- </div>
-
- <wicket:child/>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Users.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Users.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Users.properties
deleted file mode 100644
index 8ad9ae6..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Users.properties
+++ /dev/null
@@ -1,26 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=List
-tab2=Search
-search=Search
-search_results_title=Search results:
-search_noResults=No matches found.
-search_error=Error:search's format is invalid
-reset=Reset
-showingFrom=Showing
-showingTo=to
-showingOf=of
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Users_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Users_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Users_it.properties
deleted file mode 100644
index 708bfed..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Users_it.properties
+++ /dev/null
@@ -1,26 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=Elenco
-tab2=Ricerca
-search=Cerca
-search_results_title=Risultati ricerca:
-search_noResults=Nessuna corrispondenza trovata.
-search_error=Errore:il formato di ricerca non \u00e8 valido
-reset=Reset
-showingFrom=Risultati da
-showingTo=a
-showingOf=di
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Users_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Users_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Users_pt_BR.properties
deleted file mode 100644
index 7ab1053..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Users_pt_BR.properties
+++ /dev/null
@@ -1,26 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=Lista
-tab2=Buscar
-search=Buscar
-search_results_title=Resultados de pesquisa\:
-search_noResults=Nenhum resultado encontrado
-search_error=Erro\: formato de busca incorreto.
-reset=Resetar
-showingFrom=Mostrar
-showingTo=para
-showingOf=de
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/VirSchemaModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/VirSchemaModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/VirSchemaModalPage.html
deleted file mode 100644
index 3adea45..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/VirSchemaModalPage.html
+++ /dev/null
@@ -1,53 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title" /></p>
- <div style="margin: 5px;">
- <form wicket:id="form">
- <div id="formtable">
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="key"><wicket:message key="key"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="key">[name]</span>
- </div>
- </div>
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="readonly" class="onerowlabel"><wicket:message key="readonly"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="readonly">[readonly]</span>
- </div>
- </div>
- </div>
- <div style="margin: 10px 0px 0">
- <input type="submit"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="apply"/>
- <input type="button"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="cancel"/>
- </div>
- </form>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/VirSchemaModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/VirSchemaModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/VirSchemaModalPage.properties
deleted file mode 100644
index ef0cb6a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/VirSchemaModalPage.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-required_alert=All form fields are required.
-existing_schemas=Existing Schemas:
-edit_attribute=Edit attribute
-attributes=Virtual attributes
-title=Virtual Schema
-readonly=Read-only
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/VirSchemaModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/VirSchemaModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/VirSchemaModalPage_it.properties
deleted file mode 100644
index 21c2d3c..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/VirSchemaModalPage_it.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-required_alert=Tutti i campi sono richiesti.
-existing_schemas=Schemi presenti:
-edit_attribute=Modifica attributo
-attributes=Attributi virtuali
-title=Schema Virtuale
-readonly=Read-only
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/VirSchemaModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/VirSchemaModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/VirSchemaModalPage_pt_BR.properties
deleted file mode 100644
index 1d0de8a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/VirSchemaModalPage_pt_BR.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-required_alert=Todos os campos do formul\u00e1rio s\u00e3o obrigat\u00f3rios
-existing_schemas=Esquemas Existentes\:
-edit_attribute=Editar Atributo
-attributes=Atributos Virtuais
-title=Esquema Virtual
-readonly=Apenas Leitura
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/WelcomePage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/WelcomePage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/WelcomePage.html
deleted file mode 100644
index 938ecc4..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/WelcomePage.html
+++ /dev/null
@@ -1,70 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml">
- <head>
- <meta http-equiv="X-UA-Compatible" content="IE=edge"/>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
- <meta http-equiv="Content-Style-Type" content="text/css"/>
-
- <title>Apache Syncope - <wicket:message key="welcome"/></title>
-
- <link rel="stylesheet" href="css/style.css" type="text/css" media="all"/>
- <style type="text/css">
- em {
- font-size: 14px;
- color: gray;
- }
- em img {
- opacity:0.4;
- filter:alpha(opacity=40);
- }
- </style>
- </head>
- <body style="text-align:center">
- <div id="splash">
- <img src="img/logo.png" alt="syncope" title="syncope" id="logo" />
- <div style="display: table-row;height: 20px;">
- <div id="username" style="display: table-cell; padding-left: 5px; cursor: pointer; width: 100%;vertical-align: bottom;">
- <a href="#" wicket:id="editProfileLink" style="font-family: monospace;">
- <span style="color: #B9CFB3;"><wicket:message key="welcome"/>,
- <span wicket:id="username" style="color: #B9CFB3;text-decoration: underline;"/>
- </span>
- </a>
- </div>
- <div style="display: table-cell; padding-right: 5px;vertical-align: bottom;">
- <div wicket:id="infoModal"/>
- <a wicket:id="infoLink"><img src="img/info.png" alt="info"/></a>
- </div>
- </div>
- <ul>
- <li><a href="#" wicket:id="todo" class="todo"><img wicket:id="todoIcon" alt="TODO" width="80" height="80" /><br /><wicket:message key="todo"/></a></li>
- <li><a href="#" wicket:id="schema" class="schema"><img wicket:id="schemaIcon" alt="Schema" width="80" height="80" /><br /><wicket:message key="schema"/></a></li>
- <li><a href="#" wicket:id="users" class="users"><img wicket:id="usersIcon" alt="Users" width="80" height="80" /><br /><wicket:message key="users"/></a></li>
- <li><a href="#" wicket:id="groups" class="groups"><img wicket:id="groupsIcon" alt="Groups" width="80" height="80" /><br /><wicket:message key="groups"/></a></li>
- <li><a href="#" wicket:id="resources" class="resources"><img wicket:id="resourcesIcon" alt="Resources" width="80" height="80" /><br /><wicket:message key="resources"/></a></li>
- <li><a href="#" wicket:id="tasks" class="tasks"><img wicket:id="tasksIcon" alt="Tasks" width="80" height="80" /><br /><wicket:message key="tasks"/></a></li>
- <li><a href="#" wicket:id="reports" class="reports"><img wicket:id="reportsIcon" alt="Reports" width="80" height="80" /><br /><wicket:message key="reports"/></a></li>
- <li><a href="#" wicket:id="configuration" class="configuration"><img wicket:id="configurationIcon" alt="Configuration" width="80" height="80" /><br /><wicket:message key="configuration"/></a></li>
- <li><a href="#" wicket:id="logout" class="logout"><img src="img/menu/logout.png" alt="Logout" width="80" height="80" /><br /><wicket:message key="logout"/></a></li>
- </ul>
- </div>
- <div wicket:id="editProfileModal"></div>
- </body>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/WelcomePage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/WelcomePage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/WelcomePage.properties
deleted file mode 100644
index f08be49..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/WelcomePage.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-welcome=Welcome
-version=VERSION
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/WelcomePage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/WelcomePage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/WelcomePage_it.properties
deleted file mode 100644
index 2499ae4..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/WelcomePage_it.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-welcome=Benvenuto
-version=VERSIONE
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/WelcomePage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/WelcomePage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/WelcomePage_pt_BR.properties
deleted file mode 100644
index c22a518..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/WelcomePage_pt_BR.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-welcome=Bem Vindo
-version=VERS\u00C3O
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/XMLEditorPopupPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/XMLEditorPopupPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/XMLEditorPopupPage.html
deleted file mode 100644
index 07aba41..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/XMLEditorPopupPage.html
+++ /dev/null
@@ -1,82 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <link rel="stylesheet" type="text/css" href="webjars/codemirror/${codemirror.version}/lib/codemirror.css"/>
-
- <script type="text/javascript" src="webjars/codemirror/${codemirror.version}/lib/codemirror.js"></script>
- <script type="text/javascript" src="webjars/codemirror/${codemirror.version}/mode/xml/xml.js"></script>
- <script type="text/javascript">
- function updateTextArea(editor) {
- document.getElementById("workflowDefArea").value = editor.getValue();
- }
- </script>
- <script>
- window.onunload = refreshParent;
- function refreshParent() {
- if (window.opener.location.toString().indexOf('#workflow') === -1) {
- window.opener.location = window.opener.location + "#workflow";
- }
- window.opener.location.reload();
- }
- </script>
- <style>
- .w_content_3 {
- padding: 0;
- color: #333333;
- font-family: Verdana,Tahoma,sans-serif;
- font-size: 100%;
- border: 1px solid #BBBBBB;
- padding: 1%;
- }
- </style>
- </wicket:head>
- <wicket:extend>
- <div style="padding: 1%;">
- <div class="w_content_3">
- <p class="ui-widget ui-corner-all ui-widget-header">
- <wicket:message key="title"/>
- </p>
- <form wicket:id="workflowDefForm">
- <div class="ui-tabs ui-widget ui-widget-content ui-corner-all">
- <textarea wicket:id="workflowDefArea" id="workflowDefArea" style="width: 100%; height: 350px;">
- </textarea>
- </div>
- <div style="padding-top: 1%;">
- <input type="submit"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="apply"
- style="width: 50px"/>
- <input type="submit"
- wicket:id="closePage"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- onclick="window.close();"
- style="width: 50px"/>
- </div>
- </form>
- </div>
- </div>
- <script>
- window.onload = function() {
- var editor = CodeMirror.fromTextArea(document.getElementById("workflowDefArea"), {lineNumbers: true});
- editor.on("change", updateTextArea);
- };
- </script>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/XMLEditorPopupPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/XMLEditorPopupPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/XMLEditorPopupPage.properties
deleted file mode 100644
index 2276791..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/XMLEditorPopupPage.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-submit=Save
-cancel=Close
-title=Workflow XML Editor
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/XMLEditorPopupPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/XMLEditorPopupPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/XMLEditorPopupPage_it.properties
deleted file mode 100644
index 818dfb4..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/XMLEditorPopupPage_it.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-submit=Salva
-cancel=Chiudi
-title=Workflow XML Editor
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/XMLEditorPopupPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/XMLEditorPopupPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/XMLEditorPopupPage_pt_BR.properties
deleted file mode 100644
index 4152188..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/XMLEditorPopupPage_pt_BR.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-submit=Salvar
-cancel=Fechar
-title=Workflow XML Editor
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractProvisioningTasksPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractProvisioningTasksPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractProvisioningTasksPanel.html
deleted file mode 100644
index cbe6296..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractProvisioningTasksPanel.html
+++ /dev/null
@@ -1,41 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div id="users-contain" class="ui-widget" style="width:auto">
- <span wicket:id="container">
- <span wicket:id="datatable">[datatable]</span>
- <span style="float:right">
- <form wicket:id="PaginatorForm" style="display:inline">
- <label><wicket:message key="displayRows"/></label>
- <select class="text ui-widget-content ui-corner-all"
- wicket:id="rowsChooser"/>
- </form>
- </span>
- </span>
- </div>
- <div wicket:id="taskWin">
- [Show modal window for viewing task]
- </div>
- <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="createLink">
- <wicket:message key="create"/>
- </a>
- </wicket:panel>
-</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchPanel.html
deleted file mode 100644
index a2af697..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchPanel.html
+++ /dev/null
@@ -1,50 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div id="searchBox">
- <div wicket:id="searchFeedback"></div>
- <table border="0">
- <tbody wicket:id="searchFormContainer">
- <tr wicket:id="searchView">
- <td width="60">
- <select class="text ui-widget-content ui-corner-all" wicket:id="operator"/>
- </td>
- <td>
- <select class="text ui-widget-content ui-corner-all" wicket:id="type"/>
- </td>
- <td>
- <select class="text ui-widget-content ui-corner-all" wicket:id="property"/>
- </td>
- <td>
- <select class="text ui-widget-content ui-corner-all" wicket:id="comparator"/>
- </td>
- <td>
- <input type="text" class="text ui-widget-content ui-corner-all" wicket:id="value"/>
- </td>
- <td>
- <a wicket:id="add"><img src="img/plus-icon.png" alt="add icon" class="add_button"/></a>
- <a wicket:id="drop"><img src="img/minus-icon.png" alt="remove icon" class="drop_button"/></a>
- </td>
- </tr>
- </tbody>
- </table>
- </div>
- </wicket:panel>
-</html>
[31/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage.properties
deleted file mode 100644
index 58c5708..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage.properties
+++ /dev/null
@@ -1,38 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=Attributes
-tab2=Derived attributes
-tab3=User attributes
-tab4=User derived attributes
-required_alert=All form fields are required.
-mandatoryCondition=Mandatory
-enumerationValues= Enumeration values
-enumerationKeys= Enumeration labels
-uniqueConstraint=Unique
-multivalue=Multivalue
-multivalueAndUniqueConstr.validation='Multivalue' and 'Unique constraint' options can't be both checked
-type=Type
-validatorClass=Validator class
-conversionPattern=Conversion pattern
-existing_schemas=Existing Schemas:
-action=Action
-edit_attribute=Edit attribute
-title=Schema
-readonly=Read-only
-secretKey=Secret key
-cipherAlgorithm=Cipher algorithm
-mimeType=MIME Type
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage_it.properties
deleted file mode 100644
index 74eed7d..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage_it.properties
+++ /dev/null
@@ -1,38 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=Attributi
-tab2=Attributi derivati
-tab3=Attributi utenti
-tab4=Attributi utenti derivati
-required_alert=Tutti i campi sono richiesti
-mandatoryCondition=Obbligatorio
-enumerationValues= Valori enumeration
-enumerationKeys= Label enumeration
-multivalue=Multivalore
-type=Tipo
-validatorClass=Validatore
-conversionPattern=Conversion pattern
-existing_schemas=Schema esistenti:
-action=Azione
-edit_attribute=Modifica attributo
-title=Schema
-readonly=Read-only
-uniqueConstraint=Univoco
-multivalueAndUniqueConstr.validation=Le opzioni 'Multivalore' e 'Vincolo unique' non possono essere entrambe impostate
-secretKey=Chiave segreta
-cipherAlgorithm=Algoritmo di cifratura
-mimeType=MIME Type
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage_pt_BR.properties
deleted file mode 100644
index a026c17..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage_pt_BR.properties
+++ /dev/null
@@ -1,38 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=Atributos
-tab2=Atributos derivados
-tab3=Atributos de usu\u00e1rios
-tab4=Atributos derivados de usu\u00e1rios
-required_alert=Todos os campos s\u00e3o obrigat\u00f3rios
-mandatoryCondition=obrigat\u00f3rio
-enumerationValues= Valores enumerados
-enumerationKeys= R\u00f3tulos de enumera\u00e7\u00e3o
-uniqueConstraint=\u00danico
-multivalue=Multivalorado
-multivalueAndUniqueConstr.validation=As op\u00e7\u00f5es 'Multivalorado' e 'Restri\u00e7\u00e3o \u00fanica' n\u00e3o podem serem ambas selecionadas
-type=Tipo
-validatorClass=Classe de Valida\u00e7\u00e3o
-conversionPattern=Padr\u00e3o de Convers\u00e3o
-existing_schemas=Esquemas Existentes\:
-action=A\u00e7\u00e3o
-edit_attribute=Editar Atributo
-title=Esquema
-readonly=Apenas leitura
-secretKey=Chave secreta
-cipherAlgorithm=Algoritmo de criptografia
-mimeType=MIME Type
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage.html
deleted file mode 100644
index 786c4e3..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage.html
+++ /dev/null
@@ -1,109 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div style="margin: 5px;">
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
-
- <form wicket:id="form">
- <div id="tabs">
- <ul>
- <li class="tabs-selected"><a href="#info"><span><wicket:message key="policyInfo"/></span></a></li>
- <li><a href="#specification"><span><wicket:message key="policySpecification"/></span></a></li>
- <li><a href="#resources"><span><wicket:message key="resources"/></span></a></li>
- <li><a href="#groups"><span><wicket:message key="groups"/></span></a></li>
- </ul>
-
- <div id="info">
- <div id="formtable">
- <div class="tablerow alt">
- <div class="tablecolumn_label short_fixedsize">
- <label for="key"><wicket:message key="key"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="key">[key]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_fixedsize">
- <label for="type"><wicket:message key="type"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="type">[type]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_fixedsize">
- <label for="description"><wicket:message key="description"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="description">[description]</span>
- </div>
- </div>
-
- <span wicket:id="forAccountOnly"/>
- </div>
- </div>
-
- <wicket:fragment wicket:id="authResourcesFragment">
- <div class="tablerow">
- <div class="tablecolumn_label short_fixedsize">
- <label for="authResources"><wicket:message key="authResources"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="authResources">[resources]</span>
- </div>
- </div>
- </wicket:fragment>
- <wicket:fragment wicket:id="emptyFragment">
- </wicket:fragment>
-
- <div id="specification">
- <span wicket:id="panel">[password policy panel]</span>
- </div>
-
- <div id="resources">
- <div id="users-contain" class="ui-widget" style="width:inherit;">
- <table class="ui-widget ui-widget-content table-hover" wicket:id="resources"/>
- </div>
- </div>
-
- <div id="groups">
- <div id="users-contain" class="ui-widget" style="width:inherit;">
- <table class="ui-widget ui-widget-content table-hover" wicket:id="groups"/>
- </div>
- </div>
- </div>
-
- <div style="margin: 20px 10px 0">
- <input type="submit"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="apply"/>
- <input type="button"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="cancel"/>
- </div>
- </form>
- </div>
-
- <div wicket:id="metaEditModalWin">[Show modal window for meta editing (resources, groups)]</div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage.properties
deleted file mode 100644
index e98ca25..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage.properties
+++ /dev/null
@@ -1,88 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Policy management
-
-description=Description
-type=Type
-apply=Save
-
-policyInfo=Info
-policySpecification = Specification
-
-#-----------------------------
-# Password policy specification properties
-#-----------------------------
-minLength=Minimum size
-maxLength=Maximum size
-historyLength=History length
-prefixesNotPermitted=Prefixes not permitted
-suffixesNotPermitted=Suffixes not permitted
-wordsNotPermitted=Substrings not permitted
-schemasNotPermitted=Mustn't contain value of the following attributes
-digitRequired=Must contain one or more digits
-nonAlphanumericRequired=Non alphanumeric character required
-alphanumericRequired=Alphanumeric character required
-lowercaseRequired=Lowercase required
-uppercaseRequired=Uppercase required
-mustStartWithDigit=Must start with digit
-mustntStartWithDigit=Mustn't start with digit
-mustEndWithDigit=Must end with digit
-mustntEndWithDigit=Mustn't end with digit
-mustStartWithNonAlpha=Must start with non alphanumeric character
-mustStartWithAlpha=Must start with alphanumeric character
-mustntStartWithNonAlpha=Mustn't start with non alphanumeric character
-mustntStartWithAlpha=Mustn't start with alphanumeric character
-mustEndWithNonAlpha=Must end with non alphanumeric character
-mustEndWithAlpha=Must end with alphanumeric character
-mustntEndWithNonAlpha=Mustn't end with non alphanumeric character
-mustntEndWithAlpha=Mustn't end with alphanumeric character
-allowNullPassword=Password may be not stored internally
-#-----------------------------
-
-#-----------------------------
-# Account policy specification properties
-#-----------------------------
-allUpperCase=All upper case
-allLowerCase=All lower case
-pattern=Pattern (regex)
-propagateSuspension=Propagate suspension
-permittedLoginRetries=Maximum number of subsequent failed logins
-#-----------------------------
-
-#-----------------------------
-# Sync policy specification properties
-#-----------------------------
-uAltSearchSchemas=Alternative attributes for local search (users)
-gAltSearchSchemas=Alternative attributes for local search (groups)
-userJavaRule=Custom user correlation rule
-groupJavaRule=Custom group correlation rule
-conflictResolutionAction= Conflict resolution action
-#-----------------------------
-
-#-----------------------------
-# Policy Type
-#-----------------------------
-ACCOUNT=Account Policy
-GLOBAL_ACCOUNT=Global Account Policy
-PASSWORD=Password Policy
-GLOBAL_PASSWORD=Global Password Policy
-SYNC=Synchronization Policy
-GLOBAL_SYNC=Global Synchronization Policy
-#-----------------------------
-resources=Resources
-groups=Groups
-authResources=Authentication resources
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage_it.properties
deleted file mode 100644
index 756411b..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage_it.properties
+++ /dev/null
@@ -1,88 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Gestione Policy
-
-description=Descrizione
-type=Tipo
-apply=Salva
-
-policyInfo=Info
-policySpecification = Specifica
-
-#-----------------------------
-# Password policy specification properties
-#-----------------------------
-minLength=Lunghezza minima
-maxLength=Lunghezza massima
-historyLength=Lunghezza storico
-prefixesNotPermitted=Prefissi non permessi
-suffixesNotPermitted=Suffissi non permessi
-wordsNotPermitted=Sottostringhe non permesse
-schemasNotPermitted=Non deve contenere i valore dei seguenti attributi
-digitRequired=Numero richiesto
-lowercaseRequired=Lettera minuscola richiesta
-uppercaseRequired=Lettera maiuscola richiesta
-mustStartWithDigit=Deve iniziare con un numero
-mustntStartWithDigit=Non deve iniziare con un numero
-mustEndWithDigit=Deve terminare con un numero
-mustntEndWithDigit=Non deve terminare con un numero
-mustStartWithNonAlpha=Deve iniziare con un carattere non alfanumerico
-mustStartWithAlpha=Deve iniziare con un carattere alfanumerico
-mustntStartWithNonAlpha=Non deve iniziare con un carattere non alfanumerico
-mustntStartWithAlpha=Non deve iniziare con un carattere alfanumerico
-mustEndWithNonAlpha=Deve terminare con un carattere non alfanumerico
-mustEndWithAlpha=Deve terminare con un carattere alfanumerico
-mustntEndWithNonAlpha=Non deve terminare con un carattere non alfanumerico
-mustntEndWithAlpha=Non deve terminare con un carattere alfanumerico
-allowNullPassword=La password pu\u00f2 non essere memorizzata internamente
-#-----------------------------
-
-#-----------------------------
-# Account policy specification properties
-#-----------------------------
-allUpperCase=Tutte maiuscole
-allLowerCase=Tutte minuscole
-pattern=Pattern (regex)
-propagateSuspension=Propagare sospensione
-permittedLoginRetries=Numero massimo di login consecutivi falliti
-#-----------------------------
-
-#-----------------------------
-# Sync policy specification properties
-#-----------------------------
-uAltSearchSchemas=Attributi alternativi per ricerca locale (utenti)
-conflictResolutionAction= Azione di risoluzione dei conflitti
-#-----------------------------
-
-#-----------------------------
-# Policy Type
-#-----------------------------
-ACCOUNT=Policy utente
-GLOBAL_ACCOUNT=Policy utente globale
-PASSWORD=Password policy
-GLOBAL_PASSWORD=Password policy globale
-SYNC=Policy di sincronizzazione
-GLOBAL_SYNC=Policy globale di sincronizzazione
-#-----------------------------
-nonAlphanumericRequired=Carattere non alfanumerico richiesto
-alphanumericRequired=Carattere alfanumerico richiesto
-gAltSearchSchemas=Attributi alternativi per ricerca locale (gruppi)
-userJavaRule=Regola di correlazione (utenti)
-groupJavaRule=Regola di correlazione (gruppi)
-resources=Risorse
-groups=Gruppi
-authResources=Risorse di autenticazione
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage_pt_BR.properties
deleted file mode 100644
index a69aeb4..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PolicyModalPage_pt_BR.properties
+++ /dev/null
@@ -1,87 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Gerenciamento de Pol\u00edtica
-
-description=Descri\u00e7\u00e3o
-type=Tipo
-apply=Salvar
-
-policyInfo=Info
-policySpecification = Especifica\u00e7\u00e3o
-
-#-----------------------------
-# Password policy specification properties
-#-----------------------------
-minLength=Tamanho m\u00ednimo
-maxLength=Tamanho M\u00e1ximo
-historyLength=Tamanho do Hist\u00f3rico
-prefixesNotPermitted=Prefixos n\u00e3o permitidos
-suffixesNotPermitted=sufixos n\u00e3o permitidos
-wordsNotPermitted=Substrings n\u00e3o permitidas
-schemasNotPermitted=N\u00e3o deve conter valores dos seguintes atributos
-digitRequired=Precisa possuir um ou mais d\u00edgitos
-nonAlphanumericRequired=Caractere n\u00e3o alfanum\u00e9rico requerido
-alphanumericRequired=Caractere alfanum\u00e9rico requerido
-lowercaseRequired=Requerido em letra min\u00fascula
-uppercaseRequired=Requerido em letra mai\u00fascula
-mustStartWithDigit=Precisa come\u00e7ar com um d\u00edgito
-mustntStartWithDigit=N\u00e3o deve come\u00e7\u00e3r com um d\u00edgito
-mustEndWithDigit=Precisa terminar com um d\u00edgito
-mustntEndWithDigit=N\u00e3o deve terminar com um d\u00edgito
-mustStartWithNonAlpha=Precisa come\u00e7ar com um caractere n\u00e3o alfanum\u00e9rico
-mustStartWithAlpha=Precisa come\u00e7ar com um caracter alfanum\u00e9rico
-mustntStartWithNonAlpha=N\u00e3o deve come\u00e7ar com um caractere n\u00e3o alfanum\u00e9rico
-mustntStartWithAlpha=N\u00e3o deve come\u00e7ar com um caractere alfanum\u00e9rico
-mustEndWithNonAlpha=Precisa terminar com um caractere n\u00e3o alfanum\u00e9rico
-mustEndWithAlpha=Precisa terminar com um caractere alfanum\u00e9rico
-mustntEndWithNonAlpha=N\u00e3o deve terminar com um caractere n\u00e3o alfanum\u00e9rico
-mustntEndWithAlpha=N\u00e3o precisa terminar com um caracter alfanum\u00e9rico
-allowNullPassword=A senha n\u00e3o pode ser armazenado internamente
-#-----------------------------
-
-#-----------------------------
-# Account policy specification properties
-#-----------------------------
-allUpperCase=Todos em letras mai\u00fasculas
-allLowerCase=todos em letras min\u00fasculas
-pattern=Pattern (regex)
-propagateSuspension=Suspender propaga\u00e7\u00e3o
-permittedLoginRetries=N\u00famero m\u00e1ximo de subsequentes falhas de login
-#-----------------------------
-
-#-----------------------------
-# Sync policy specification properties
-#-----------------------------
-uAltSearchSchemas=Atributos alternativos para busca local (usu\u00e1rios)
-gAltSearchSchemas=Atributos alternativos para busca local (grupos)
-userJavaRule=Regra customizada de correla\u00e7\u00e3o de usu\u00e1rio
-groupJavaRule=Regra de correla\u00e7\u00e3o de grupo customizada
-conflictResolutionAction= A\u00e7\u00e3o de resolu\u00e7\u00e3o de conflito
-#-----------------------------
-
-#-----------------------------
-# Policy Type
-#-----------------------------
-ACCOUNT=Pol\u00edtica de Conta
-GLOBAL_ACCOUNT=Pol\u00edtica Global de Conta
-PASSWORD=Plo\u00edtica de Senha
-GLOBAL_PASSWORD=Pol\u00edtica Global de Senha
-SYNC=Pol\u00edtica de Sincroniza\u00e7\u00e3o
-GLOBAL_SYNC=Pol\u00edtica Global de sincroniza\u00e7\u00e3o
-resources=Recursos
-groups=Grupos
-authResources=Recursos de autentica\u00e7\u00e3o
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage.html
deleted file mode 100644
index 67ac588..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage.html
+++ /dev/null
@@ -1,75 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div id="dialog-form">
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
- <form wicket:id="form">
- <div id="tabs">
- <ul>
- <li class="tabs-selected"><a href="#profile"><span><wicket:message key="profile"/></span></a></li>
- <li><a href="#executions"><span><wicket:message key="executions"/></span></a></li>
- </ul>
- <div id="profile">
- <div id="users-contain" class="ui-widget">
- <span wicket:id="profile">
- <div id="formtable">
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <span wicket:id="idLabel">[Id]</span>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="key">[key]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="accountId"><wicket:message key="accountId"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="accountId">[accountId]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="resource"><wicket:message key="resource"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="resource">[resource]</span>
- </div>
- </div>
- </div>
- </span>
- </div>
- </div>
- <div id="executions" class="ui-widget">
- <span wicket:id="executionContainer" id="executionContainer">
- <table class="ui-widget ui-widget-content"
- wicket:id="executionsTable" style="width: 100%"/>
- </span>
- </div>
- </div>
- </form>
- </div>
- <div wicket:id="taskExecMessageWin"/>
- </wicket:extend>
-</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage.properties
deleted file mode 100644
index 1b035f7..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage.properties
+++ /dev/null
@@ -1,28 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Profile
-executions=Executions
-title=Task
-accountId=Account id
-resource=Resource
-startDate=Start date
-endDate=End date
-status=Status
-message=Message
-taskExecutions=Task executions
-delete=Delete
-showMessage=Show
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage_it.properties
deleted file mode 100644
index 770680b..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage_it.properties
+++ /dev/null
@@ -1,28 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Profilo
-executions=Esecuzioni
-title=Task
-accountId=Id account
-resource=Risorsa
-startDate=Data di avvio
-endDate=Data di conclusione
-status=Stato
-message=Messaggio
-taskExecutions=Esecuzione del task
-delete=Rimozione
-showMessage=Mostra
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage_pt_BR.properties
deleted file mode 100644
index fd54adc..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PropagationTaskModalPage_pt_BR.properties
+++ /dev/null
@@ -1,28 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Perfil
-executions=Execu\u00E7\u00F5es
-title=Tarefas
-accountId=Identificador de Conta
-resource=Recurso
-startDate=Data Inicial
-endDate=Data final
-status=Estatus
-message=Mensagem
-taskExecutions=Execu\u00E7\u00E3o de Tarefas
-delete=Excluir
-showMessage=Mostrar
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage.html
deleted file mode 100644
index 5ac1379..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage.html
+++ /dev/null
@@ -1,228 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div style="margin: 5px;">
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
-
- <form wicket:id="form">
-
- <div id="tabs">
- <ul>
- <li class="tabs-selected"><a href="#profile"><span><wicket:message key="profile"/></span></a></li>
- <li><a href="#crontab"><span><wicket:message key="crontab"/></span></a></li>
- <li><a href="#executions"><span><wicket:message key="executions"/></span></a></li>
- </ul>
- <div id="profile">
- <div class="ui-widget">
- <span wicket:id="profile">
- <div id="formtable">
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <span wicket:id="idLabel">[Id]</span>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="key">[key]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="name"><wicket:message key="name"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="name">[name]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="description"><wicket:message key="description"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="description">[description]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="resource"><wicket:message key="resourceName"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="resource">[resource]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="lastExec"><wicket:message key="lastExec"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="lastExec">[lastExec]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="nextExec"><wicket:message key="nextExec"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="nextExec">[nextExec]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="actionsClassNames"><wicket:message key="actionsClasses"/></label>
- </div>
- <span wicket:id="syncActionsClassNames">
- <span wicket:id="actionsClasses">
- <select class="text ui-widget-content ui-corner-all" wicket:id="actionsClass"/>
- <a wicket:id="drop"><img src="img/minus-icon.png" alt="remove icon" class="drop_button"/></a>
- <a wicket:id="add"><img src="img/plus-icon.png" alt="add icon" class="add_button"/></a>
- <br/>
- </span>
- <a wicket:id="first"><img src="img/plus-icon.png" alt="add icon" class="add_button"/></a>
- </span>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="performCreate"><wicket:message key="creates"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="performCreate">[performCreate]</span>
- </div>
- </div>
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="performUpdate"><wicket:message key="updates"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="performUpdate">[performUpdate]</span>
- </div>
- </div>
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="performDelete"><wicket:message key="deletes"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="performDelete">[performDelete]</span>
- </div>
- </div>
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="syncStatus"><wicket:message key="syncStatus"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="syncStatus">[syncStatus]</span>
- </div>
- </div>
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="matchingRule"><wicket:message key="matchingRule"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="matchingRule">[matchingRule]</span>
- </div>
- </div>
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="unmatchingRule"><wicket:message key="unmatchingRule"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="unmatchingRule">[unmatchingRule]</span>
- </div>
- </div>
- <div id="filters">
- <span wicket:id="filterContainer">
- <div class="tablerow" style="width: auto;">
- <div class="tablecolumn_field" style="width: auto; padding-right: 5px;">
- <span wicket:id="checkUserFilter">[checkUserFilter]</span>
- </div>
- <div class="tablecolumn_label" style="width: auto;">
- <label for="checkUserFilter"><wicket:message key="checkUserFilter"/></label>
- </div>
- </div>
-
- <div id="userFilter" style="border: 1px solid #dddddd; padding-bottom: 2%; padding-top: 2%;">
- <div id="condition">
- <span wicket:id="userFilter"/>
- </div>
- </div>
- <div class="tablerow" style="width: auto;">
- <div class="tablecolumn_field" style="width: auto; padding-right: 5px;">
- <span wicket:id="checkGroupFilter">[checkGroupFilter]</span>
- </div>
- <div class="tablecolumn_label" style="width: auto;">
- <label for="checkGroupFilter"><wicket:message key="checkGroupFilter"/></label>
- </div>
- </div>
- <div id="groupFilter" style="border: 1px solid #dddddd; padding-bottom: 2%; padding-top: 2%;">
- <div id="condition">
- <span wicket:id="groupFilter"/>
- </div>
- </div>
- </span>
- </div>
- <wicket:child/>
- </div>
- </span>
- </div>
- </div>
- <div id="crontab">
- <span wicket:id="crontab">
- <div id="formtable">
- <div class="tablerow alt">
- <label for="cron"><wicket:message key="cron"/></label>
- </div>
- <div class="tablerow">
- <input type="text" id="seconds" class="text ui-widget-content ui-corner-all" wicket:id="seconds" style="width: 50px;float: left" />
- <input type="text" id="minutes" class="text ui-widget-content ui-corner-all" wicket:id="minutes" style="width: 50px;float: left" />
- <input type="text" id="hours" class="text ui-widget-content ui-corner-all" wicket:id="hours" style="width: 50px;float: left" />
- <input type="text" id="daysOfMonth" class="text ui-widget-content ui-corner-all" wicket:id="daysOfMonth" style="width: 50px;float: left" />
- <input type="text" id="months" class="text ui-widget-content ui-corner-all" wicket:id="months" style="width: 50px;float: left" />
- <input type="text" id="daysOfWeek" class="text ui-widget-content ui-corner-all" wicket:id="daysOfWeek" style="width: 50px" />
- </div>
- <div class="tablerow alt">
- <label for="cronExpression"><wicket:message key="templates"/></label>
- </div>
- <div class="tablerow">
- <select class="text ui-widget-content ui-corner-all" wicket:id="cronTemplateChooser" style="width: 250px"/>
- </div>
- </div>
- </span>
- </div>
- <div id="executions" class="ui-widget">
- <span wicket:id="executionContainer" id="executionContainer">
- <table class="ui-widget ui-widget-content"
- wicket:id="executionsTable" style="width: 100%"/>
- </span>
- </div>
- </div>
- <div style="margin: 20px 10px 0">
- <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="apply"/>
- <input type="button" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="cancel"/>
- </div>
- </form>
- </div>
- <div wicket:id="taskExecMessageWin"/>
- </wicket:extend>
-</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage.properties
deleted file mode 100644
index b058db7..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage.properties
+++ /dev/null
@@ -1,45 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Profile
-crontab=Schedule
-executions=Executions
-title=Task
-resourceName=Resource Name
-name=Name
-description=Description
-lastExec=Last Execution
-nextExec=Next Execution
-cron=Schedule (seconds, minutes, hours, days of month, months, days of week)
-templates=Remove task from scheduler / Use a template to schedule
-apply=Save
-startDate=Start date
-endDate=End date
-status=Status
-message=Message
-delete=Delete
-showMessage=Show
-chooseForTemplate=Use A Template
-creates=Allow create operations
-deletes=Allow delete operations
-updates=Allow update operations
-syncStatus=Allow status synchronization
-fullReconciliation=Full reconciliation
-actionsClasses=Actions classes
-matchingRule=Matching Rule
-unmatchingRule=Unmatching Rule
-checkUserFilter=User Filter
-checkGroupFilter=Group Filter
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage_it.properties
deleted file mode 100644
index 52df2db..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage_it.properties
+++ /dev/null
@@ -1,47 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Profilo
-crontab=Schedule
-executions=Esecuzioni
-title=Task
-resourceName=Nome Risorsa
-name=Nome
-description=Descrizione
-lastExec=Ultima Esecuzione
-nextExec=Prossima Esecuzione
-cron=Schedule (secondi, minuti, ore, giorni del mese, mesi, giorni della settimana)
-templates=Rimuovi task dallo scheduler / Utilizza un template per schedulare
-apply=Salva
-startDate=Data di avvio
-endDate=Data di conclusione
-status=Stato
-message=Messaggio
-delete=Rimozione
-showMessage=Mostra
-chooseForTemplate=Usa Un Template
-creates=Consenti operazioni di creazione
-deletes=Consenti operazioni di rimozione
-updates=Consenti operazioni di modifica
-syncStatus=Consenti sincronizzazione di stato
-status=Sincronizza stato utente
-fullReconciliation=Riconciliazione totale
-actionsClasses=Classi azioni
-syncStatus=Sincronizza stato utente
-matchingRule=Regola di corrispondenza
-unmatchingRule=Regola di non corrispondenza
-checkUserFilter=Filtro Utente
-checkGroupFilter=Filtro Gruppo
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage_pt_BR.properties
deleted file mode 100644
index 69c09fa..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PushTaskModalPage_pt_BR.properties
+++ /dev/null
@@ -1,45 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Perfil
-crontab=Agenda
-executions=Execu\u00e7\u00f5es
-title=Tarefas
-resourceName=Nome de Recursos
-name=Nome
-description=Descri\u00e7\u00e3o
-lastExec=\u00daltima Execu\u00e7\u00e3o
-nextExec=Pr\u00f3xima Execu\u00e7\u00e3o
-cron=Agenda (segundos, minutos, horas, dias do m\u00eas, meses, dias da semana)
-templates=Remover tarefa agendada / usar template para agendar
-apply=Salvar
-startDate=Data de In\u00edcio
-endDate=Data Final
-status=Estatus
-message=Mensagem
-delete=Excluir
-showMessage=Mostrar
-chooseForTemplate=Usar um template
-creates=Permitir opera\u00e7\u00f5es de cria\u00e7\u00e3o
-deletes=Permitir opera\u00e7\u00f5es de remo\u00e7\u00e3o
-updates=Permitir a edi\u00e7\u00e3o
-syncStatus=Permitir a sincroniza\u00e7\u00e3o de status
-fullReconciliation=Reconcilia\u00e7\u00e3o completa
-actionsClasses=Classes de a\u00e7\u00f5es
-matchingRule=Regra de correspond\u00eancia
-unmatchingRule=Regra de non correspond\u00eancia
-checkUserFilter=Filtro Usu\u00e1rio
-checkGroupFilter=Filtro Grupo
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/RecursivePanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RecursivePanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/RecursivePanel.html
deleted file mode 100644
index 63cb904..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RecursivePanel.html
+++ /dev/null
@@ -1,28 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<wicket:panel>
- <ul>
- <span wicket:id="rows">
- <li wicket:id="row">
- <span wicket:id="label">[The label]</span>
- </li>
- <span wicket:id="nested"/>
- </span>
- </ul>
-</wicket:panel>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.html
deleted file mode 100644
index aa9cd0b..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.html
+++ /dev/null
@@ -1,23 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<wicket:extend>
- <div id="dialog">
- <wicket:message key="downloadAs"/> <span wicket:id="format" class="small_dynamicsize">[format]</span>
- </div>
-</wicket:extend>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.properties
deleted file mode 100644
index 22b990a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-downloadAs=Download as
-download=Download
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage_it.properties
deleted file mode 100644
index 7841efe..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage_it.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-downloadAs=Scarica come
-download=Scarica
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage_pt_BR.properties
deleted file mode 100644
index ba57357..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage_pt_BR.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-downloadAs=Salvar como
-download=Salvar
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage.html
deleted file mode 100644
index b813b12..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage.html
+++ /dev/null
@@ -1,146 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div style="margin: 5px;">
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
- <form wicket:id="form">
- <div id="tabs">
- <ul>
- <li class="tabs-selected"><a href="#profile"><span><wicket:message key="profile"/></span></a></li>
- <li><a href="#crontab"><span><wicket:message key="crontab"/></span></a></li>
- <li><a href="#executions"><span><wicket:message key="executions"/></span></a></li>
- </ul>
- <div id="profile">
- <div id="users-contain" class="ui-widget">
- <span wicket:id="profile">
- <div id="formtable">
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <span wicket:id="idLabel">[Id]</span>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="key">[key]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <span wicket:id="nameLabel">[Name]</span>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="name">[name]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="lastExec"><wicket:message key="lastExec"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="lastExec">[lastExec]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="nextExec"><wicket:message key="nextExec"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="nextExec">[nextExec]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="reportlets"><wicket:message key="reportlets"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <div style="display: inline-table;">
- <div id="selections" style="display: table-cell;">
- <select wicket:id="reportletConfs" class="selectionSelect"></select>
- </div>
- <div id="orderingButtons" style="display: table-cell; width: 30px; vertical-align: middle; padding-left: 5px;">
- <div style="padding-bottom: 5px;">
- <a wicket:id="upButton"><img src="img/up-icon.png" alt="move up icon"/></a>
- </div>
- <div style="padding-top: 5px;">
- <a wicket:id="downButton"><img src="img/down-icon.png" alt="move down icon"/></a>
- </div>
- </div>
- </div>
- <div id="actionButtons" style="padding-top: 5px;">
- <div style="padding-left: 35px;float: left;">
- <a wicket:id="addButton"><img src="img/plus-icon.png" alt="plus icon"/></a>
- </div>
- <div style="padding-left: 15px;float: left;">
- <a wicket:id="editButton"><img src="img/actions/edit.png" alt="edit icon"/></a>
- </div>
- <div style="padding-left: 15px;float: left;">
- <a wicket:id="removeButton"><img src="img/minus-icon.png" alt="minus icon"/></a>
- </div>
- </div>
- </div>
- </div>
- </div>
- </span>
- </div>
- </div>
- <div id="crontab">
- <span wicket:id="crontab">
- <div id="formtable">
- <div class="tablerow alt">
- <label for="cron"><wicket:message key="cron"/></label>
- </div>
- <div class="tablerow">
- <input type="text" id="seconds" class="text ui-widget-content ui-corner-all" wicket:id="seconds" style="width: 50px;float: left" />
- <input type="text" id="minutes" class="text ui-widget-content ui-corner-all" wicket:id="minutes" style="width: 50px;float: left" />
- <input type="text" id="hours" class="text ui-widget-content ui-corner-all" wicket:id="hours" style="width: 50px;float: left" />
- <input type="text" id="daysOfMonth" class="text ui-widget-content ui-corner-all" wicket:id="daysOfMonth" style="width: 50px;float: left" />
- <input type="text" id="months" class="text ui-widget-content ui-corner-all" wicket:id="months" style="width: 50px;float: left" />
- <input type="text" id="daysOfWeek" class="text ui-widget-content ui-corner-all" wicket:id="daysOfWeek" style="width: 50px" />
- </div>
- <div class="tablerow alt">
- <label for="cronExpression"><wicket:message key="templates"/></label>
- </div>
- <div class="tablerow">
- <select class="text ui-widget-content ui-corner-all" wicket:id="cronTemplateChooser" style="width: 250px"/>
- </div>
- </div>
- </span>
- </div>
- <div id="executions" class="ui-widget">
- <span wicket:id="executionContainer" id="executionContainer">
- <table class="ui-widget ui-widget-content"
- wicket:id="executionsTable" style="width: 100%"/>
- </span>
- </div>
- </div>
- <div style="margin: 20px 10px 0">
- <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="apply"/>
- <input type="button" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="cancel"/>
- </div>
- </form>
- </div>
- <div wicket:id="reportletConfWin"/>
- <div wicket:id="reportExecMessageWin"/>
- <div wicket:id="reportExecExportWin"/>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage.properties
deleted file mode 100644
index 115fc49..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage.properties
+++ /dev/null
@@ -1,36 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Profile
-crontab=Schedule
-executions=Executions
-title=Report
-lastExec=Last Execution
-nextExec=Next Execution
-cron=Schedule (seconds, minutes, hours, days of month, months, days of week)
-templates=Remove task from scheduler / Use a template to schedule
-apply=Save
-startDate=Start date
-endDate=End date
-status=Status
-message=Message
-taskExecutions=Task executions
-delete=Delete
-showMessage=Show
-chooseForTemplate=Use A Template
-reportlets=Reportlets
-create_reportletconf=Add new Reporlet
-selectItem=Please select an item first
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage_it.properties
deleted file mode 100644
index fa600f6..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage_it.properties
+++ /dev/null
@@ -1,36 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Profilo
-crontab=Schedule
-executions=Esecuzioni
-title=Rapporto
-lastExec=Ultima Esecuzione
-nextExec=Prossima Esecuzione
-cron=Schedule (secondi, minuti, ore, giorni del mese, mesi, giorni della settimana)
-templates=Rimuovi task dallo scheduler / Utilizza un template per schedulare
-apply=Salva
-startDate=Data di avvio
-endDate=Data di conclusione
-status=Stato
-message=Messaggio
-taskExecutions=Esecuzione del task
-delete=Rimozione
-showMessage=Mostra
-chooseForTemplate=Usa Un Template
-reportlets=Reportlets
-create_reportletconf=Aggiungi Reporlet
-selectItem=Seleziona un elemento
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage_pt_BR.properties
deleted file mode 100644
index da48be6..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportModalPage_pt_BR.properties
+++ /dev/null
@@ -1,36 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Perfil
-crontab=Agendamento
-executions=Execu\u00E7\u00F5es
-title=Relat\u00F3rios
-lastExec=\u00DAlitima Execu\u00E7\u00E3o
-nextExec=Pr\u00F3xima Execu\u00E7\u00E3o
-cron=Agendar (segundos, minutos, horar, dias do m\u00EAs, meses, dias da semana)
-templates=Remover tarefa da agenda / Use um template para agendar
-apply=Salvar
-startDate=Data de in\u00EDcio
-endDate=Data Final
-status=Estatus
-message=Mensagem
-taskExecutions=Execu\u00E7\u00E3o de Tarefas
-delete=Remover
-showMessage=Mostar
-chooseForTemplate=Usar um Template
-reportlets=Reportlets
-create_reportletconf=Adicionar novo Reporlet
-selectItem=Por favor selecionar um item primeiro
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage.html
deleted file mode 100644
index bc8a1f9..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage.html
+++ /dev/null
@@ -1,85 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div style="margin: 5px;">
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
- <form wicket:id="form">
- <div id="tabs">
- <ul>
- <li class="tabs-selected"><a href="#general"><span><wicket:message key="general"/></span></a></li>
- <li><a href="#configuration"><span><wicket:message key="configuration"/></span></a></li>
- </ul>
- <div id="general">
- <div id="formtable">
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="name"><wicket:message key="name"/></label>
- </div>
- <div class="tablecolumn_field short_dynamicsize">
- <span wicket:id="name">[name]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="reportletClass"><wicket:message key="reportletClass"/></label>
- </div>
- <div class="tablecolumn_field">
- <span wicket:id="reportletClass" style="width: 100%;">[reportletClass]</span>
- </div>
- </div>
- </div>
-
- <script type="text/javascript">
- $(function() {
- $('#general #formtable div.tablerow:even').addClass("alt");
- });
- </script>
- </div>
- <div id="configuration">
- <div id="formtable">
- <span wicket:id="container">
- <div class="tablerow" wicket:id="propView">
- <div class="tablecolumn_label short_fixedsize">
- <span wicket:id="key">[key]</span>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="value">[value]</span>
- </div>
- </div>
-
- <script type="text/javascript">
- $(function() {
- $('#configuration #formtable div.tablerow:even').addClass("alt");
- });
- </script>
- </span>
- </div>
- </div>
- </div>
-
- <div style="margin: 20px 10px 0">
- <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="apply"/>
- <input type="button" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="cancel"/>
- </div>
- </form>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage.properties
deleted file mode 100644
index 52ca027..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Reportlet
-general=General
-configuration=Configuration
-apply=Save
-name=Name
-reportletClass=Reportlet class
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage_it.properties
deleted file mode 100644
index 9245554..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage_it.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Reportlet
-general=Generale
-configuration=Configurazione
-apply=Salva
-name=Nome
-reportletClass=Classe Reportlet
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage_pt_BR.properties
deleted file mode 100644
index dc7e422..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ReportletConfModalPage_pt_BR.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Reportlet
-general=Geral
-configuration=Configura\u00E7\u00E3o
-apply=Salvar
-name=Nome
-reportletClass=Classe Reportlet
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Reports.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Reports.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Reports.html
deleted file mode 100644
index 456f7a3..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Reports.html
+++ /dev/null
@@ -1,58 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
-
- <div id="tabs">
- <ul>
- <li class="tabs-selected"><a href="#tabs-1"><span><wicket:message key="reports"/></span></a></li>
- <li><a href="#tabs-2"><span><wicket:message key="audit"/></span></a></li>
- </ul>
-
- <div id="tabs-1">
- <div id="users-contain" class="ui-widget" style="width:inherit;">
- <span wicket:id="reportContainer">
- <table class="ui-widget ui-widget-content table-hover" wicket:id="reportTable"/>
- </span>
- <span style="float:right">
- <form wicket:id="paginatorForm" style="display:inline">
- <label><wicket:message key="displayRows"/></label>
- <select class="text ui-widget-content ui-corner-all" wicket:id="rowsChooser"/>
- </form>
- </span>
- </div>
-
- <div wicket:id="reportWin">[Show modal window for report editing]</div>
- <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="createLink">
- <wicket:message key="create"/>
- </a>
-
- </div>
-
- <div id="tabs-2">
- <span wicket:id="auditContainer">
- <form wicket:id="auditForm">
- <span wicket:id="events">[event builder]</span>
- </form>
- </span>
- </div>
- </div>
-
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Reports.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Reports.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Reports.properties
deleted file mode 100644
index 06ebaca..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Reports.properties
+++ /dev/null
@@ -1,24 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-audit=Audit
-lastExec=Last Execution
-nextExec=Next Execution
-latestExecStatus=Last status
-category=Category
-subcategory=Subcategory
-startDate=Start date
-endDate=End date
\ No newline at end of file
[20/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/PropagationTaskModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/PropagationTaskModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/PropagationTaskModalPage.java
new file mode 100644
index 0000000..5a6779f
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/PropagationTaskModalPage.java
@@ -0,0 +1,45 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.common.lib.to.AbstractTaskTO;
+import org.apache.wicket.model.PropertyModel;
+
+/**
+ * Modal window with Task form (to stop and start execution).
+ */
+public class PropagationTaskModalPage extends TaskModalPage {
+
+ private static final long serialVersionUID = 523379887023786151L;
+
+ public PropagationTaskModalPage(final AbstractTaskTO taskTO) {
+ super(taskTO);
+
+ final AjaxTextFieldPanel accountId = new AjaxTextFieldPanel("accountId", getString("accountId"),
+ new PropertyModel<String>(taskTO, "accountId"));
+ accountId.setEnabled(false);
+ profile.add(accountId);
+
+ final AjaxTextFieldPanel resource = new AjaxTextFieldPanel("resource", getString("resource"),
+ new PropertyModel<String>(taskTO, "resource"));
+ resource.setEnabled(false);
+ profile.add(resource);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ProvisioningModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ProvisioningModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ProvisioningModalPage.java
new file mode 100644
index 0000000..6418d61
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ProvisioningModalPage.java
@@ -0,0 +1,249 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.LinkedHashMap;
+import java.util.List;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.status.AbstractStatusBeanProvider;
+import org.apache.syncope.client.console.commons.status.ConnObjectWrapper;
+import org.apache.syncope.client.console.commons.status.StatusBean;
+import org.apache.syncope.client.console.commons.status.StatusUtils;
+import org.apache.syncope.client.console.panels.ActionDataTablePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.lib.SyncopeClient;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.to.AbstractSubjectTO;
+import org.apache.syncope.common.lib.to.BulkActionResult;
+import org.apache.syncope.common.lib.to.ResourceTO;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.syncope.common.lib.types.ResourceDeassociationActionType;
+import org.apache.syncope.common.lib.wrap.AbstractWrappable;
+import org.apache.syncope.common.lib.wrap.SubjectKey;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.ISortableDataProvider;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortParam;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.StringResourceModel;
+
+public class ProvisioningModalPage<T extends AbstractAttributableTO> extends AbstractStatusModalPage {
+
+ private static final long serialVersionUID = -4285220460543213901L;
+
+ private static final int ROWS_PER_PAGE = 10;
+
+ private final ResourceTO resourceTO;
+
+ private final Class<? extends AbstractAttributableTO> typeRef;
+
+ private final PageReference pageRef;
+
+ private final ModalWindow window;
+
+ private final StatusUtils statusUtils;
+
+ public ProvisioningModalPage(
+ final PageReference pageRef,
+ final ModalWindow window,
+ final ResourceTO resourceTO,
+ final Class<T> typeRef) {
+
+ super();
+
+ this.pageRef = pageRef;
+ this.window = window;
+ this.resourceTO = resourceTO;
+ this.typeRef = typeRef;
+
+ statusUtils = new StatusUtils((UserTO.class.isAssignableFrom(typeRef) ? userRestClient : groupRestClient));
+
+ add(new Label("displayName", StringUtils.EMPTY));
+
+ final List<IColumn<StatusBean, String>> columns = new ArrayList<>();
+ columns.add(new PropertyColumn<StatusBean, String>(
+ new StringResourceModel("key", this, null, "Attributable key"),
+ "attributableKey", "attributableKey"));
+ columns.add(new PropertyColumn<StatusBean, String>(
+ new StringResourceModel("name", this, null, "Attributable name"),
+ "attributableName", "attributableName"));
+ columns.add(new PropertyColumn<StatusBean, String>(
+ new StringResourceModel("resourceName", this, null, "Resource name"),
+ "resourceName", "resourceName"));
+ columns.add(new PropertyColumn<StatusBean, String>(
+ new StringResourceModel("accountLink", this, null, "Account link"),
+ "accountLink", "accountLink"));
+ columns.add(new AbstractColumn<StatusBean, String>(
+ new StringResourceModel("status", this, null, "")) {
+
+ private static final long serialVersionUID = -3503023501954863131L;
+
+ @Override
+ public String getCssClass() {
+ return "action";
+ }
+
+ @Override
+ public void populateItem(
+ final Item<ICellPopulator<StatusBean>> cellItem,
+ final String componentId,
+ final IModel<StatusBean> model) {
+ cellItem.
+ add(statusUtils.getStatusImagePanel(componentId, model.getObject().getStatus()));
+ }
+ });
+
+ final ActionDataTablePanel<StatusBean, String> table = new ActionDataTablePanel<>(
+ "resourceDatatable",
+ columns,
+ (ISortableDataProvider<StatusBean, String>) new StatusBeanProvider(),
+ ROWS_PER_PAGE,
+ pageRef);
+
+ final String pageId = "Resources";
+
+ table.addAction(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ bulkAssociationAction(target, ResourceDeassociationActionType.UNLINK, table, columns);
+ } catch (Exception e) {
+ LOG.error("Error unlinkink resources", e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+ }, ActionLink.ActionType.UNLINK, pageId);
+
+ table.addAction(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ bulkAssociationAction(target, ResourceDeassociationActionType.DEPROVISION, table, columns);
+ } catch (Exception e) {
+ LOG.error("Error de-provisioning user", e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+ }, ActionLink.ActionType.DEPROVISION, pageId);
+
+ table.addAction(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ bulkAssociationAction(target, ResourceDeassociationActionType.UNASSIGN, table, columns);
+ } catch (Exception e) {
+ LOG.error("Error unassigning resources", e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+ }, ActionLink.ActionType.UNASSIGN, pageId);
+
+ table.addCancelButton(window);
+
+ add(table);
+ }
+
+ private class StatusBeanProvider extends AbstractStatusBeanProvider {
+
+ private static final long serialVersionUID = 4287357360778016173L;
+
+ public StatusBeanProvider() {
+ super("accountLink");
+ }
+
+ @SuppressWarnings("unchecked")
+ @Override
+ public List<StatusBean> getStatusBeans() {
+ final String fiql = SyncopeClient.getUserSearchConditionBuilder().hasResources(resourceTO.getKey()).query();
+
+ final List<T> subjects = new ArrayList<>();
+ if (UserTO.class.isAssignableFrom(typeRef)) {
+ subjects.addAll((List<T>) userRestClient.search(fiql, 1, ROWS_PER_PAGE, new SortParam<>("key", true)));
+ } else {
+ subjects.addAll((List<T>) groupRestClient.search(fiql, 1, ROWS_PER_PAGE, new SortParam<>("key", true)));
+ }
+
+ final List<ConnObjectWrapper> connObjects = statusUtils.getConnectorObjects(
+ (List<AbstractSubjectTO>) subjects, Collections.<String>singleton(resourceTO.getKey()));
+
+ final List<StatusBean> statusBeans = new ArrayList<>(connObjects.size() + 1);
+ final LinkedHashMap<String, StatusBean> initialStatusBeanMap = new LinkedHashMap<>(connObjects.size());
+
+ for (ConnObjectWrapper entry : connObjects) {
+ final StatusBean statusBean = statusUtils.getStatusBean(entry.getAttributable(),
+ entry.getResourceName(),
+ entry.getConnObjectTO(),
+ GroupTO.class.isAssignableFrom(typeRef));
+
+ initialStatusBeanMap.put(entry.getResourceName(), statusBean);
+ statusBeans.add(statusBean);
+ }
+
+ return statusBeans;
+ }
+ }
+
+ private void bulkAssociationAction(
+ final AjaxRequestTarget target,
+ final ResourceDeassociationActionType type,
+ final ActionDataTablePanel<StatusBean, String> table,
+ final List<IColumn<StatusBean, String>> columns) {
+
+ final List<StatusBean> beans = new ArrayList<>(table.getModelObject());
+ List<SubjectKey> subjectKeys = new ArrayList<>();
+ for (StatusBean bean : beans) {
+ LOG.debug("Selected bean {}", bean);
+ subjectKeys.add(AbstractWrappable.getInstance(SubjectKey.class, bean.getAttributableId()));
+ }
+
+ if (beans.isEmpty()) {
+ window.close(target);
+ } else {
+ final BulkActionResult res = resourceRestClient.bulkAssociationAction(
+ resourceTO.getKey(), typeRef, type, subjectKeys);
+
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+
+ setResponsePage(new BulkActionResultModalPage<>(window, beans, columns, res, "attributableKey"));
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/PushTaskModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/PushTaskModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/PushTaskModalPage.java
new file mode 100644
index 0000000..51852be
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/PushTaskModalPage.java
@@ -0,0 +1,135 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.panels.GroupSearchPanel;
+import org.apache.syncope.client.console.panels.UserSearchPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.common.lib.to.PushTaskTO;
+import org.apache.syncope.common.lib.to.SchedTaskTO;
+import org.apache.syncope.common.lib.types.MatchingRule;
+import org.apache.syncope.common.lib.types.UnmatchingRule;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.model.Model;
+
+/**
+ * Modal window with Push Task form.
+ */
+public class PushTaskModalPage extends AbstractSyncTaskModalPage {
+
+ private static final long serialVersionUID = 2148403203517274669L;
+
+ private final UserSearchPanel userFilter;
+
+ private final GroupSearchPanel groupFilter;
+
+ private final AjaxCheckBoxPanel checkUserFilter;
+
+ private final AjaxCheckBoxPanel checkGroupFilter;
+
+ @Override
+ protected List<String> getSyncActions() {
+ return taskRestClient.getPushActionsClasses();
+ }
+
+ public PushTaskModalPage(final ModalWindow window, final PushTaskTO taskTO, final PageReference pageRef) {
+
+ super(window, taskTO, pageRef);
+
+ // set default Matching rule
+ ((DropDownChoice) matchingRule.getField()).setDefaultModelObject(taskTO.getMatchingRule() == null
+ ? MatchingRule.UPDATE
+ : taskTO.getMatchingRule());
+ profile.add(matchingRule);
+
+ // set default Unmatching rule
+ ((DropDownChoice) unmatchingRule.getField()).setDefaultModelObject(taskTO.getUnmatchingRule() == null
+ ? UnmatchingRule.ASSIGN
+ : taskTO.getUnmatchingRule());
+ profile.add(unmatchingRule);
+
+ final WebMarkupContainer filterContainer = new WebMarkupContainer("filterContainer");
+ filterContainer.setOutputMarkupId(true);
+
+ checkUserFilter = new AjaxCheckBoxPanel("checkUserFilter", "checkUserFilter",
+ new Model<>(taskTO.getUserFilter() != null));
+ filterContainer.add(checkUserFilter);
+
+ checkGroupFilter = new AjaxCheckBoxPanel("checkGroupFilter", "checkGroupFilter",
+ new Model<>(taskTO.getGroupFilter() != null));
+ filterContainer.add(checkGroupFilter);
+
+ userFilter = new UserSearchPanel.Builder("userFilter").fiql(taskTO.getUserFilter()).build();
+ userFilter.setEnabled(checkUserFilter.getModelObject());
+
+ filterContainer.add(userFilter);
+
+ groupFilter = new GroupSearchPanel.Builder("groupFilter").fiql(taskTO.getGroupFilter()).build();
+ groupFilter.setEnabled(checkGroupFilter.getModelObject());
+ filterContainer.add(groupFilter);
+
+ checkUserFilter.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ userFilter.setEnabled(checkUserFilter.getModelObject());
+ target.add(filterContainer);
+ }
+ });
+
+ checkGroupFilter.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ groupFilter.setEnabled(checkGroupFilter.getModelObject());
+ target.add(filterContainer);
+ }
+ });
+
+ profile.add(filterContainer);
+ }
+
+ @Override
+ public void submitAction(final SchedTaskTO taskTO) {
+ setFilters((PushTaskTO) taskTO);
+ if (taskTO.getKey() > 0) {
+ taskRestClient.updateSchedTask((PushTaskTO) taskTO);
+ } else {
+ taskRestClient.createSchedTask((PushTaskTO) taskTO);
+ }
+ }
+
+ private void setFilters(final PushTaskTO pushTaskTO) {
+ // set user filter if enabled
+ pushTaskTO.setUserFilter(checkUserFilter.getModelObject() ? userFilter.buildFIQL() : null);
+ // set group filter if enabled
+ pushTaskTO.setGroupFilter(checkGroupFilter.getModelObject() ? groupFilter.buildFIQL() : null);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.java
new file mode 100644
index 0000000..c6b57d2
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.java
@@ -0,0 +1,73 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.Arrays;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.common.lib.types.ReportExecExportFormat;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.form.IChoiceRenderer;
+import org.apache.wicket.model.Model;
+
+public class ReportExecResultDownloadModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = 3163146190501510888L;
+
+ public ReportExecResultDownloadModalPage(final ModalWindow window, final PageReference callerPageRef) {
+
+ final AjaxDropDownChoicePanel<ReportExecExportFormat> format =
+ new AjaxDropDownChoicePanel<>("format", "format", new Model<ReportExecExportFormat>());
+
+ format.setChoices(Arrays.asList(ReportExecExportFormat.values()));
+
+ format.setChoiceRenderer(new IChoiceRenderer<ReportExecExportFormat>() {
+
+ private static final long serialVersionUID = -3941271550163141339L;
+
+ @Override
+ public Object getDisplayValue(final ReportExecExportFormat object) {
+ return object.name();
+ }
+
+ @Override
+ public String getIdValue(final ReportExecExportFormat object, final int index) {
+
+ return object.name();
+ }
+ });
+
+ format.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ format.getField();
+
+ ((ReportModalPage) callerPageRef.getPage()).setExportFormat(format.getField().getModelObject());
+ window.close(target);
+ }
+ });
+ add(format);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ReportModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ReportModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ReportModalPage.java
new file mode 100644
index 0000000..0ef7c6a
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ReportModalPage.java
@@ -0,0 +1,640 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.DateFormatROModel;
+import org.apache.syncope.client.console.commons.HttpResourceStream;
+import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
+import org.apache.syncope.client.console.wicket.ajax.form.AbstractAjaxDownloadBehavior;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
+import org.apache.syncope.client.console.wicket.markup.html.CrontabContainer;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.report.AbstractReportletConf;
+import org.apache.syncope.common.lib.report.ReportletConf;
+import org.apache.syncope.common.lib.to.ReportExecTO;
+import org.apache.syncope.common.lib.to.ReportTO;
+import org.apache.syncope.common.lib.types.ReportExecExportFormat;
+import org.apache.syncope.common.lib.types.ReportExecStatus;
+import org.apache.wicket.Component;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.attributes.AjaxCallListener;
+import org.apache.wicket.ajax.attributes.AjaxRequestAttributes;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
+import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.form.IChoiceRenderer;
+import org.apache.wicket.markup.html.form.ListChoice;
+import org.apache.wicket.model.AbstractReadOnlyModel;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.util.resource.IResourceStream;
+import org.springframework.util.StringUtils;
+
+public class ReportModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = -5747628615211127644L;
+
+ private static final String ADD_BUTTON_ID = "addButton";
+
+ private static final String EDIT_BUTTON_ID = "editButton";
+
+ private static final String REMOVE_BUTTON_ID = "removeButton";
+
+ private static final String UP_BUTTON_ID = "upButton";
+
+ private static final String DOWN_BUTTON_ID = "downButton";
+
+ private static final int EXEC_EXPORT_WIN_HEIGHT = 100;
+
+ private static final int EXEC_EXPORT_WIN_WIDTH = 400;
+
+ private static final int REPORTLET_CONF_WIN_HEIGHT = 500;
+
+ private static final int REPORTLET_CONF_WIN_WIDTH = 800;
+
+ private final ReportTO reportTO;
+
+ private final Form<ReportTO> form;
+
+ private ReportExecExportFormat exportFormat;
+
+ private long exportExecId;
+
+ private AbstractReportletConf modalReportletConf;
+
+ private String modalReportletConfOldName;
+
+ private ListChoice<AbstractReportletConf> reportlets;
+
+ public ReportModalPage(final ModalWindow window, final ReportTO reportTO, final PageReference callerPageRef) {
+ super();
+ this.reportTO = reportTO;
+
+ form = new Form<ReportTO>(FORM);
+ form.setModel(new CompoundPropertyModel<ReportTO>(reportTO));
+ add(form);
+
+ setupProfile();
+ setupExecutions();
+
+ final CrontabContainer crontab = new CrontabContainer("crontab", new PropertyModel<String>(reportTO,
+ "cronExpression"), reportTO.getCronExpression());
+ form.add(crontab);
+
+ final AjaxButton submit =
+ new ClearIndicatingAjaxButton(APPLY, new ResourceModel(APPLY), getPageReference()) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
+ ReportTO toSubmit = (ReportTO) form.getModelObject();
+ toSubmit.setCronExpression(StringUtils.hasText(toSubmit.getCronExpression())
+ ? crontab.getCronExpression()
+ : null);
+
+ try {
+ if (toSubmit.getKey() > 0) {
+ reportRestClient.update(toSubmit);
+ } else {
+ reportRestClient.create(toSubmit);
+ }
+
+ ((BasePage) callerPageRef.getPage()).setModalResult(true);
+
+ window.close(target);
+ } catch (SyncopeClientException e) {
+ LOG.error("While creating or updating report", e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+
+ if (reportTO.getKey() > 0) {
+ MetaDataRoleAuthorizationStrategy.authorize(submit, RENDER,
+ xmlRolesReader.getEntitlement("Reports", "update"));
+ } else {
+ MetaDataRoleAuthorizationStrategy.authorize(submit, RENDER,
+ xmlRolesReader.getEntitlement("Reports", "create"));
+ }
+
+ form.add(submit);
+
+ final AjaxButton cancel =
+ new ClearIndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL), getPageReference()) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+ };
+
+ cancel.setDefaultFormProcessing(false);
+ form.add(cancel);
+ }
+
+ private void setupProfile() {
+ final WebMarkupContainer profile = new WebMarkupContainer("profile");
+ profile.setOutputMarkupId(true);
+ form.add(profile);
+
+ final ModalWindow reportletConfWin = new ModalWindow("reportletConfWin");
+ reportletConfWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ reportletConfWin.setCookieName("reportlet-conf-win-modal");
+ reportletConfWin.setInitialHeight(REPORTLET_CONF_WIN_HEIGHT);
+ reportletConfWin.setInitialWidth(REPORTLET_CONF_WIN_WIDTH);
+ reportletConfWin.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
+
+ private static final long serialVersionUID = 8804221891699487139L;
+
+ @Override
+ public void onClose(final AjaxRequestTarget target) {
+ int foundIdx = -1;
+ if (modalReportletConfOldName != null) {
+ for (int i = 0; i < reportTO.getReportletConfs().size() && foundIdx == -1; i++) {
+ if (reportTO.getReportletConfs().get(i).getName().equals(modalReportletConfOldName)) {
+ foundIdx = i;
+ }
+ }
+ }
+ if (modalReportletConf != null) {
+ if (foundIdx == -1) {
+ reportTO.getReportletConfs().add(modalReportletConf);
+ } else {
+ reportTO.getReportletConfs().set(foundIdx, modalReportletConf);
+ }
+ }
+
+ target.add(reportlets);
+ }
+ });
+ add(reportletConfWin);
+
+ final Label idLabel = new Label("idLabel", new ResourceModel("key"));
+ profile.add(idLabel);
+
+ final AjaxTextFieldPanel key =
+ new AjaxTextFieldPanel("key", getString("key"), new PropertyModel<String>(reportTO, "key"));
+ key.setEnabled(false);
+ profile.add(key);
+
+ final Label nameLabel = new Label("nameLabel", new ResourceModel("name"));
+ profile.add(nameLabel);
+
+ final AjaxTextFieldPanel name =
+ new AjaxTextFieldPanel("name", getString("name"), new PropertyModel<String>(reportTO, "name"));
+ profile.add(name);
+
+ final AjaxTextFieldPanel lastExec = new AjaxTextFieldPanel("lastExec", getString("lastExec"),
+ new DateFormatROModel(new PropertyModel<String>(reportTO, "lastExec")));
+ lastExec.setEnabled(false);
+ profile.add(lastExec);
+
+ final AjaxTextFieldPanel nextExec = new AjaxTextFieldPanel("nextExec", getString("nextExec"),
+ new DateFormatROModel(new PropertyModel<String>(reportTO, "nextExec")));
+ nextExec.setEnabled(false);
+ profile.add(nextExec);
+
+ reportlets = new ListChoice<AbstractReportletConf>("reportletConfs", new Model<AbstractReportletConf>(),
+ reportTO.getReportletConfs(), new IChoiceRenderer<ReportletConf>() {
+
+ private static final long serialVersionUID = 1048000918946220007L;
+
+ @Override
+ public Object getDisplayValue(final ReportletConf object) {
+ return object.getName();
+ }
+
+ @Override
+ public String getIdValue(final ReportletConf object, final int index) {
+ return object.getName();
+ }
+ }) {
+
+ private static final long serialVersionUID = 4022366881854379834L;
+
+ @Override
+ protected CharSequence getDefaultChoice(final String selectedValue) {
+ return null;
+ }
+ };
+
+ reportlets.setNullValid(true);
+ profile.add(reportlets);
+ reportlets.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ target.add(reportlets);
+ }
+ });
+
+ profile.add(new AjaxLink<Void>(ADD_BUTTON_ID) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ reportletConfWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ modalReportletConfOldName = null;
+ modalReportletConf = null;
+ return new ReportletConfModalPage(null, reportletConfWin,
+ ReportModalPage.this.getPageReference());
+ }
+ });
+ reportletConfWin.show(target);
+ }
+ });
+
+ profile.add(new AjaxLink<Void>(EDIT_BUTTON_ID) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ if (reportlets.getModelObject() != null) {
+ reportletConfWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ modalReportletConfOldName = reportlets.getModelObject().getName();
+ modalReportletConf = null;
+ return new ReportletConfModalPage(reportlets.getModelObject(), reportletConfWin,
+ ReportModalPage.this.getPageReference());
+ }
+ });
+ reportletConfWin.show(target);
+ }
+ }
+ });
+
+ profile.add(new AjaxLink<Void>(REMOVE_BUTTON_ID) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ reportTO.getReportletConfs().remove(reportlets.getModelObject());
+ reportlets.setModelObject(null);
+ target.add(reportlets);
+ }
+
+ @Override
+ protected void updateAjaxAttributes(final AjaxRequestAttributes attributes) {
+ if (reportlets.getModelObject() != null) {
+
+ super.updateAjaxAttributes(attributes);
+
+ final AjaxCallListener ajaxCallListener = new AjaxCallListener() {
+
+ private static final long serialVersionUID = 7160235486520935153L;
+
+ @Override
+ public CharSequence getPrecondition(final Component component) {
+ return "if (!confirm('" + getString("confirmDelete") + "')) {return false;}";
+ }
+ };
+ attributes.getAjaxCallListeners().add(ajaxCallListener);
+ }
+ }
+ });
+
+ profile.add(new AjaxLink<Void>(UP_BUTTON_ID) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ if (reportlets.getModelObject() != null) {
+ moveUp(reportlets.getModelObject());
+ target.add(reportlets);
+ }
+ }
+ });
+
+ profile.add(new AjaxLink<Void>(DOWN_BUTTON_ID) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ if (reportlets.getModelObject() != null) {
+ moveDown(reportlets.getModelObject());
+ target.add(reportlets);
+ }
+ }
+ });
+ }
+
+ private void moveUp(final AbstractReportletConf item) {
+ final List<AbstractReportletConf> list = reportTO.getReportletConfs();
+ int newPosition = list.indexOf(item) - 1;
+ if (newPosition > -1) {
+ list.remove(item);
+ list.add(newPosition, item);
+ }
+ }
+
+ private void moveDown(final AbstractReportletConf item) {
+ final List<AbstractReportletConf> list = reportTO.getReportletConfs();
+ int newPosition = list.indexOf(item) + 1;
+ if (newPosition < list.size()) {
+ list.remove(item);
+ list.add(newPosition, item);
+ }
+ }
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ private void setupExecutions() {
+ final WebMarkupContainer executions = new WebMarkupContainer("executionContainer");
+ executions.setOutputMarkupId(true);
+ form.add(executions);
+
+ final ModalWindow reportExecMessageWin = new ModalWindow("reportExecMessageWin");
+ reportExecMessageWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ reportExecMessageWin.setCookieName("report-exec-message-win-modal");
+ add(reportExecMessageWin);
+
+ final ModalWindow reportExecExportWin = new ModalWindow("reportExecExportWin");
+ reportExecExportWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ reportExecExportWin.setCookieName("report-exec-export-win-modal");
+ reportExecExportWin.setInitialHeight(EXEC_EXPORT_WIN_HEIGHT);
+ reportExecExportWin.setInitialWidth(EXEC_EXPORT_WIN_WIDTH);
+ reportExecExportWin.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
+
+ private static final long serialVersionUID = 8804221891699487139L;
+
+ @Override
+ public void onClose(final AjaxRequestTarget target) {
+ AjaxExportDownloadBehavior behavior = new AjaxExportDownloadBehavior(ReportModalPage.this.exportFormat,
+ ReportModalPage.this.exportExecId);
+ executions.add(behavior);
+ behavior.initiate(target);
+ }
+ });
+ add(reportExecExportWin);
+
+ final List<IColumn> columns = new ArrayList<IColumn>();
+ columns.add(new PropertyColumn(new ResourceModel("key"), "key", "key"));
+ columns.add(new DatePropertyColumn(new ResourceModel("startDate"), "startDate", "startDate"));
+ columns.add(new DatePropertyColumn(new ResourceModel("endDate"), "endDate", "endDate"));
+ columns.add(new PropertyColumn(new ResourceModel("status"), "status", "status"));
+ columns.add(new ActionColumn<ReportExecTO, String>(new ResourceModel("actions", "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public ActionLinksPanel getActions(final String componentId, final IModel<ReportExecTO> model) {
+
+ final ReportExecTO taskExecutionTO = model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ reportExecMessageWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ExecMessageModalPage(model.getObject().getMessage());
+ }
+ });
+ reportExecMessageWin.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, "Reports", StringUtils.hasText(model.getObject().getMessage()));
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ reportExecExportWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ ReportModalPage.this.exportExecId = model.getObject().getKey();
+ return new ReportExecResultDownloadModalPage(reportExecExportWin,
+ ReportModalPage.this.getPageReference());
+ }
+ });
+ reportExecExportWin.show(target);
+ }
+ }, ActionLink.ActionType.EXPORT, "Reports", ReportExecStatus.SUCCESS.name().equals(
+ model.getObject().getStatus()));
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ reportRestClient.deleteExecution(taskExecutionTO.getKey());
+
+ reportTO.getExecutions().remove(taskExecutionTO);
+
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+
+ feedbackPanel.refresh(target);
+ target.add(executions);
+ }
+ }, ActionLink.ActionType.DELETE, "Reports");
+
+ return panel;
+ }
+
+ @Override
+ public Component getHeader(final String componentId) {
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), getPageReference());
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ if (target != null) {
+ final ReportTO currentReportTO = reportTO.getKey() == 0
+ ? reportTO
+ : reportRestClient.read(reportTO.getKey());
+ reportTO.getExecutions().clear();
+ reportTO.getExecutions().addAll(currentReportTO.getExecutions());
+ final AjaxFallbackDefaultDataTable currentTable =
+ new AjaxFallbackDefaultDataTable("executionsTable", columns,
+ new ReportExecutionsProvider(reportTO), 10);
+ currentTable.setOutputMarkupId(true);
+ target.add(currentTable);
+ executions.addOrReplace(currentTable);
+ }
+ }
+ }, ActionLink.ActionType.RELOAD, TASKS, "list");
+
+ return panel;
+ }
+ });
+
+ final AjaxFallbackDefaultDataTable table = new AjaxFallbackDefaultDataTable("executionsTable", columns,
+ new ReportExecutionsProvider(reportTO), 10);
+ executions.add(table);
+ }
+
+ public void setExportFormat(final ReportExecExportFormat exportFormat) {
+ this.exportFormat = exportFormat;
+ }
+
+ public void setModalReportletConf(final AbstractReportletConf modalReportletConf) {
+ this.modalReportletConf = modalReportletConf;
+ }
+
+ private static class ReportExecutionsProvider extends SortableDataProvider<ReportExecTO, String> {
+
+ private static final long serialVersionUID = 2118096121691420539L;
+
+ private final SortableDataProviderComparator<ReportExecTO> comparator;
+
+ private final ReportTO reportTO;
+
+ public ReportExecutionsProvider(final ReportTO reportTO) {
+ super();
+ this.reportTO = reportTO;
+ setSort("startDate", SortOrder.DESCENDING);
+ comparator = new SortableDataProviderComparator<ReportExecTO>(this);
+ }
+
+ @Override
+ public Iterator<ReportExecTO> iterator(final long first, final long count) {
+
+ List<ReportExecTO> list = reportTO.getExecutions();
+
+ Collections.sort(list, comparator);
+
+ return list.subList((int) first, (int) first + (int) count).iterator();
+ }
+
+ @Override
+ public long size() {
+ return reportTO.getExecutions().size();
+ }
+
+ @Override
+ public IModel<ReportExecTO> model(final ReportExecTO taskExecution) {
+
+ return new AbstractReadOnlyModel<ReportExecTO>() {
+
+ private static final long serialVersionUID = 7485475149862342421L;
+
+ @Override
+ public ReportExecTO getObject() {
+ return taskExecution;
+ }
+ };
+ }
+ }
+
+ private class AjaxExportDownloadBehavior extends AbstractAjaxDownloadBehavior {
+
+ private static final long serialVersionUID = 3109256773218160485L;
+
+ private final ReportExecExportFormat exportFormat;
+
+ private final long exportExecId;
+
+ private HttpResourceStream stream;
+
+ public AjaxExportDownloadBehavior(final ReportExecExportFormat exportFormat, final long exportExecId) {
+ super();
+ this.exportFormat = exportFormat;
+ this.exportExecId = exportExecId;
+ }
+
+ private void createResourceStream() {
+ if (stream == null) {
+ stream = new HttpResourceStream(reportRestClient.exportExecutionResult(exportExecId, exportFormat));
+ }
+ }
+
+ @Override
+ protected String getFileName() {
+ createResourceStream();
+ return stream == null
+ ? null
+ : stream.getFilename();
+ }
+
+ @Override
+ protected IResourceStream getResourceStream() {
+ createResourceStream();
+ return stream;
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ReportletConfModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ReportletConfModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ReportletConfModalPage.java
new file mode 100644
index 0000000..36560b0
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ReportletConfModalPage.java
@@ -0,0 +1,362 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.lang.reflect.Field;
+import java.lang.reflect.ParameterizedType;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.Date;
+import java.util.List;
+import org.apache.commons.lang3.ArrayUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.panels.GroupSearchPanel;
+import org.apache.syncope.client.console.panels.UserSearchPanel;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPalettePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.CheckBoxMultipleChoiceFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.DateTimeFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.FieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.SpinnerFieldPanel;
+import org.apache.syncope.common.lib.SyncopeConstants;
+import org.apache.syncope.common.lib.annotation.FormAttributeField;
+import org.apache.syncope.common.lib.report.AbstractReportletConf;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.wicket.Component;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.model.util.ListModel;
+import org.apache.wicket.util.visit.IVisit;
+import org.apache.wicket.util.visit.IVisitor;
+import org.springframework.beans.BeanWrapper;
+import org.springframework.beans.PropertyAccessorFactory;
+import org.springframework.util.ClassUtils;
+
+public class ReportletConfModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = 3910027601200382958L;
+
+ private static final String[] EXCLUDE_PROPERTIES =
+ new String[] { "serialVersionUID", "class", "name", "reportletClassName" };
+
+ private AbstractReportletConf reportletConf;
+
+ private final AjaxTextFieldPanel name;
+
+ private WebMarkupContainer propertiesContainer;
+
+ private ListView<String> propView;
+
+ public ReportletConfModalPage(final AbstractReportletConf reportletConf, final ModalWindow window,
+ final PageReference pageRef) {
+
+ this.reportletConf = reportletConf;
+
+ final Form form = new Form(FORM);
+ add(form);
+
+ propertiesContainer = new WebMarkupContainer("container");
+ propertiesContainer.setOutputMarkupId(true);
+ form.add(propertiesContainer);
+
+ name = new AjaxTextFieldPanel("name", "name", this.reportletConf == null
+ ? new Model<String>()
+ : new PropertyModel<String>(this.reportletConf, "name"));
+ name.setOutputMarkupId(true);
+ name.addRequiredLabel();
+ form.add(name);
+
+ final AjaxDropDownChoicePanel<String> reportletClass = new AjaxDropDownChoicePanel<String>("reportletClass",
+ "reportletClass", new IModel<String>() {
+
+ private static final long serialVersionUID = -2316468110411802130L;
+
+ @Override
+ public String getObject() {
+ return ReportletConfModalPage.this.reportletConf == null
+ ? null
+ : ReportletConfModalPage.this.reportletConf.getClass().getName();
+ }
+
+ @Override
+ public void setObject(final String object) {
+ try {
+ Class<?> reportletClass = Class.forName(object);
+ ReportletConfModalPage.this.reportletConf = (AbstractReportletConf) reportletClass.
+ newInstance();
+ propertiesContainer.replace(buildPropView());
+ } catch (Exception e) {
+ LOG.error("Cannot find or initialize {}", object, e);
+ }
+ }
+
+ @Override
+ public void detach() {
+ }
+ });
+ reportletClass.setStyleSheet("long_dynamicsize");
+ reportletClass.setChoices(reportRestClient.getReportletConfClasses());
+ ((DropDownChoice) reportletClass.getField()).setNullValid(true);
+ reportletClass.addRequiredLabel();
+ reportletClass.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = 5538299138211283825L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ ((DropDownChoice) reportletClass.getField()).setNullValid(false);
+ target.add(reportletClass.getField());
+ target.add(propertiesContainer);
+ }
+ });
+ form.add(reportletClass);
+
+ propertiesContainer.add(buildPropView());
+
+ final AjaxButton submit = new AjaxButton(APPLY, new ResourceModel(APPLY)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ final BeanWrapper wrapper = PropertyAccessorFactory.
+ forBeanPropertyAccess(ReportletConfModalPage.this.reportletConf);
+ wrapper.setPropertyValue("name", name.getField().getInput());
+
+ // Iterate over properties in order to find UserSearchPanel instances and manually update
+ // this.reportletConf with select search criteria - this is needed because UserSearchPanel
+ // does not comply with usual Wicket model paradigm.
+ ReportletConfModalPage.this.propView.visitChildren(new IVisitor<Component, Void>() {
+
+ @Override
+ public void component(final Component component, final IVisit<Void> ivisit) {
+ if (component instanceof UserSearchPanel) {
+ // using component.getDefaultModelObjectAsString() to fetch field name (set above)
+ wrapper.setPropertyValue(component.getDefaultModelObjectAsString(),
+ ((UserSearchPanel) component).buildFIQL());
+ }
+ }
+ });
+
+ ((ReportModalPage) pageRef.getPage()).setModalReportletConf(ReportletConfModalPage.this.reportletConf);
+ window.close(target);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+ form.add(submit);
+
+ final AjaxButton cancel = new ClearIndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL), pageRef) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+ };
+
+ cancel.setDefaultFormProcessing(false);
+ form.add(cancel);
+ }
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ private FieldPanel buildSinglePanel(final Class<?> type, final String fieldName, final String id) {
+ FieldPanel result = null;
+ PropertyModel model = new PropertyModel(ReportletConfModalPage.this.reportletConf, fieldName);
+ if (ClassUtils.isAssignable(Boolean.class, type)) {
+ result = new AjaxCheckBoxPanel(id, fieldName, model);
+ } else if (ClassUtils.isAssignable(Number.class, type)) {
+ result = new SpinnerFieldPanel<Number>(id, fieldName,
+ (Class<Number>) ClassUtils.resolvePrimitiveIfNecessary(type), model, null, null);
+ } else if (Date.class.equals(type)) {
+ result = new DateTimeFieldPanel(id, fieldName, model, SyncopeConstants.DEFAULT_DATE_PATTERN);
+ } else if (type.isEnum()) {
+ result = new AjaxDropDownChoicePanel(id, fieldName, model).setChoices(
+ Arrays.asList(type.getEnumConstants()));
+ }
+
+ // treat as String if nothing matched above
+ if (result == null) {
+ result = new AjaxTextFieldPanel(id, fieldName, model);
+ }
+
+ return result;
+ }
+
+ private ListView<String> buildPropView() {
+ LoadableDetachableModel<List<String>> propViewModel = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ List<String> result = new ArrayList<String>();
+ if (ReportletConfModalPage.this.reportletConf != null) {
+ for (Field field : ReportletConfModalPage.this.reportletConf.getClass().getDeclaredFields()) {
+ if (!ArrayUtils.contains(EXCLUDE_PROPERTIES, field.getName())) {
+ result.add(field.getName());
+ }
+ }
+ }
+
+ return result;
+ }
+ };
+
+ propView = new ListView<String>("propView", propViewModel) {
+
+ private static final long serialVersionUID = 9101744072914090143L;
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ @Override
+ protected void populateItem(final ListItem<String> item) {
+ final String fieldName = item.getModelObject();
+
+ Label label = new Label("key", fieldName);
+ item.add(label);
+
+ Field field = null;
+ try {
+ field = ReportletConfModalPage.this.reportletConf.getClass().getDeclaredField(fieldName);
+ } catch (Exception e) {
+ LOG.error("Could not find field {} in class {}",
+ fieldName, ReportletConfModalPage.this.reportletConf.getClass(), e);
+ }
+ if (field == null) {
+ return;
+ }
+
+ FormAttributeField annotation = field.getAnnotation(FormAttributeField.class);
+
+ BeanWrapper wrapper = PropertyAccessorFactory.
+ forBeanPropertyAccess(ReportletConfModalPage.this.reportletConf);
+
+ Panel panel;
+
+ if (String.class.equals(field.getType()) && annotation != null && annotation.userSearch()) {
+ panel = new UserSearchPanel.Builder("value").
+ fiql((String) wrapper.getPropertyValue(fieldName)).required(false).build();
+ // This is needed in order to manually update this.reportletConf with search panel selections
+ panel.setDefaultModel(new Model<String>(fieldName));
+ } else if (String.class.equals(field.getType()) && annotation != null && annotation.groupSearch()) {
+ panel = new GroupSearchPanel.Builder("value").
+ fiql((String) wrapper.getPropertyValue(fieldName)).required(false).build();
+ // This is needed in order to manually update this.reportletConf with search panel selections
+ panel.setDefaultModel(new Model<String>(fieldName));
+ } else if (List.class.equals(field.getType())) {
+ Class<?> listItemType = String.class;
+ if (field.getGenericType() instanceof ParameterizedType) {
+ listItemType =
+ (Class<?>) ((ParameterizedType) field.getGenericType()).getActualTypeArguments()[0];
+ }
+
+ if (listItemType.equals(String.class) && annotation != null) {
+ List<String> choices;
+ switch (annotation.schema()) {
+ case UserPlainSchema:
+ choices = schemaRestClient.getPlainSchemaNames(AttributableType.USER);
+ break;
+
+ case UserDerivedSchema:
+ choices = schemaRestClient.getDerSchemaNames(AttributableType.USER);
+ break;
+
+ case UserVirtualSchema:
+ choices = schemaRestClient.getVirSchemaNames(AttributableType.USER);
+ break;
+
+ case GroupPlainSchema:
+ choices = schemaRestClient.getPlainSchemaNames(AttributableType.GROUP);
+ break;
+
+ case GroupDerivedSchema:
+ choices = schemaRestClient.getDerSchemaNames(AttributableType.GROUP);
+ break;
+
+ case GroupVirtualSchema:
+ choices = schemaRestClient.getVirSchemaNames(AttributableType.GROUP);
+ break;
+
+ case MembershipPlainSchema:
+ choices = schemaRestClient.getPlainSchemaNames(AttributableType.MEMBERSHIP);
+ break;
+
+ case MembershipDerivedSchema:
+ choices = schemaRestClient.getDerSchemaNames(AttributableType.MEMBERSHIP);
+ break;
+
+ case MembershipVirtualSchema:
+ choices = schemaRestClient.getVirSchemaNames(AttributableType.MEMBERSHIP);
+ break;
+
+ default:
+ choices = Collections.emptyList();
+ }
+
+ panel = new AjaxPalettePanel("value", new PropertyModel<List<String>>(
+ ReportletConfModalPage.this.reportletConf, fieldName), new ListModel<String>(choices),
+ true);
+ } else if (listItemType.isEnum()) {
+ panel = new CheckBoxMultipleChoiceFieldPanel("value", new PropertyModel(
+ ReportletConfModalPage.this.reportletConf, fieldName),
+ new ListModel(Arrays.asList(listItemType.getEnumConstants())));
+ } else {
+ if (((List) wrapper.getPropertyValue(fieldName)).isEmpty()) {
+ ((List) wrapper.getPropertyValue(fieldName)).add(null);
+ }
+
+ panel = new MultiFieldPanel("value", new PropertyModel<List>(
+ ReportletConfModalPage.this.reportletConf, fieldName),
+ buildSinglePanel(field.getType(), fieldName, "panel"));
+ }
+ } else {
+ panel = buildSinglePanel(field.getType(), fieldName, "value");
+ }
+
+ item.add(panel);
+ }
+ };
+
+ return propView;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Reports.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Reports.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Reports.java
new file mode 100644
index 0000000..e484701
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Reports.java
@@ -0,0 +1,412 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+import org.apache.commons.lang3.tuple.Pair;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.PreferenceManager;
+import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
+import org.apache.syncope.client.console.panels.LoggerCategoryPanel;
+import org.apache.syncope.client.console.panels.SelectedEventsPanel;
+import org.apache.syncope.client.console.rest.LoggerRestClient;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.EventCategoryTO;
+import org.apache.syncope.common.lib.to.ReportTO;
+import org.apache.syncope.common.lib.types.AuditElements.Result;
+import org.apache.syncope.common.lib.types.AuditLoggerName;
+import org.apache.wicket.Component;
+import org.apache.wicket.Page;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
+import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.AbstractReadOnlyModel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.model.util.ListModel;
+import org.apache.wicket.request.mapper.parameter.PageParameters;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.springframework.util.CollectionUtils;
+
+/**
+ * Auditing and Reporting.
+ */
+public class Reports extends BasePage {
+
+ private static final long serialVersionUID = -2071214196989178694L;
+
+ private static final int WIN_HEIGHT = 500;
+
+ private static final int WIN_WIDTH = 700;
+
+ @SpringBean
+ private LoggerRestClient loggerRestClient;
+
+ @SpringBean
+ private PreferenceManager prefMan;
+
+ private WebMarkupContainer reportContainer;
+
+ private WebMarkupContainer auditContainer;
+
+ private int paginatorRows;
+
+ private final ModalWindow window;
+
+ public Reports(final PageParameters parameters) {
+ super(parameters);
+
+ window = new ModalWindow("reportWin");
+ window.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ window.setInitialHeight(WIN_HEIGHT);
+ window.setInitialWidth(WIN_WIDTH);
+ window.setCookieName("view-report-win");
+ add(window);
+
+ setupReport();
+ setupAudit();
+ }
+
+ private void setupReport() {
+ reportContainer = new WebMarkupContainer("reportContainer");
+ setWindowClosedCallback(window, reportContainer);
+
+ MetaDataRoleAuthorizationStrategy.authorize(reportContainer, RENDER,
+ xmlRolesReader.getEntitlement("Reports", "list"));
+
+ paginatorRows = prefMan.getPaginatorRows(getRequest(), Constants.PREF_REPORT_PAGINATOR_ROWS);
+
+ List<IColumn<ReportTO, String>> columns = new ArrayList<>();
+ columns.add(new PropertyColumn<ReportTO, String>(new ResourceModel("key"), "key", "key"));
+ columns.add(new PropertyColumn<ReportTO, String>(new ResourceModel("name"), "name", "name"));
+ columns.add(new DatePropertyColumn<ReportTO>(new ResourceModel("lastExec"), "lastExec", "lastExec"));
+ columns.add(new DatePropertyColumn<ReportTO>(new ResourceModel("nextExec"), "nextExec", "nextExec"));
+ columns.add(new DatePropertyColumn<ReportTO>(new ResourceModel("startDate"), "startDate", "startDate"));
+ columns.add(new DatePropertyColumn<ReportTO>(new ResourceModel("endDate"), "endDate", "endDate"));
+ columns.add(new PropertyColumn<ReportTO, String>(
+ new ResourceModel("latestExecStatus"), "latestExecStatus", "latestExecStatus"));
+ columns.add(new ActionColumn<ReportTO, String>(new ResourceModel("actions", "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public ActionLinksPanel getActions(final String componentId, final IModel<ReportTO> model) {
+
+ final ReportTO reportTO = model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+
+ window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ReportModalPage(window, reportTO, Reports.this.getPageReference());
+ }
+ });
+
+ window.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, "Reports");
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ reportRestClient.startExecution(reportTO.getKey());
+ getSession().info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+
+ feedbackPanel.refresh(target);
+ target.add(reportContainer);
+ }
+ }, ActionLink.ActionType.EXECUTE, "Reports");
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ reportRestClient.delete(reportTO.getKey());
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+ target.add(reportContainer);
+ feedbackPanel.refresh(target);
+ }
+ }, ActionLink.ActionType.DELETE, "Reports");
+
+ return panel;
+ }
+
+ @Override
+ public Component getHeader(final String componentId) {
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), getPageReference());
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ if (target != null) {
+ target.add(reportContainer);
+ }
+ }
+ }, ActionLink.ActionType.RELOAD, TASKS, "list");
+
+ return panel;
+ }
+ });
+
+ final AjaxFallbackDefaultDataTable<ReportTO, String> reportTable =
+ new AjaxFallbackDefaultDataTable<>("reportTable", columns, new ReportProvider(), paginatorRows);
+
+ reportContainer.add(reportTable);
+ reportContainer.setOutputMarkupId(true);
+
+ add(reportContainer);
+
+ @SuppressWarnings("rawtypes")
+ Form paginatorForm = new Form("paginatorForm");
+
+ MetaDataRoleAuthorizationStrategy.authorize(paginatorForm, RENDER,
+ xmlRolesReader.getEntitlement("Reports", "list"));
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ final DropDownChoice rowsChooser = new DropDownChoice("rowsChooser", new PropertyModel(this, "paginatorRows"),
+ prefMan.getPaginatorChoices());
+
+ rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ prefMan.set(getRequest(), getResponse(), Constants.PREF_REPORT_PAGINATOR_ROWS,
+ String.valueOf(paginatorRows));
+ reportTable.setItemsPerPage(paginatorRows);
+
+ target.add(reportContainer);
+ }
+ });
+
+ paginatorForm.add(rowsChooser);
+ add(paginatorForm);
+
+ AjaxLink<Void> createLink = new ClearIndicatingAjaxLink<Void>("createLink", getPageReference()) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ReportModalPage(window, new ReportTO(), Reports.this.getPageReference());
+ }
+ });
+
+ window.show(target);
+ }
+ };
+
+ MetaDataRoleAuthorizationStrategy.authorize(createLink, RENDER, xmlRolesReader.getEntitlement("Reports",
+ "create"));
+
+ add(createLink);
+ }
+
+ @SuppressWarnings("rawtypes")
+ private void setupAudit() {
+ auditContainer = new WebMarkupContainer("auditContainer");
+ auditContainer.setOutputMarkupId(true);
+ add(auditContainer);
+
+ MetaDataRoleAuthorizationStrategy.authorize(
+ auditContainer, RENDER, xmlRolesReader.getEntitlement("Audit", "list"));
+
+ final Form form = new Form("auditForm");
+ auditContainer.add(form);
+
+ final List<String> events = new ArrayList<>();
+
+ final List<AuditLoggerName> audits = loggerRestClient.listAudits();
+ for (AuditLoggerName audit : audits) {
+ events.add(AuditLoggerName.buildEvent(
+ audit.getType(),
+ audit.getCategory(),
+ audit.getSubcategory(),
+ audit.getEvent(),
+ audit.getResult()));
+ }
+
+ final ListModel<String> model = new ListModel<>(new ArrayList<>(events));
+
+ form.add(new LoggerCategoryPanel(
+ "events", loggerRestClient.listEvents(), model, getPageReference(), "Reports") {
+
+ private static final long serialVersionUID = 6113164334533550277L;
+
+ @Override
+ protected String[] getListRoles() {
+ return new String[] {
+ xmlRolesReader.getEntitlement("Audit", "list")
+ };
+ }
+
+ @Override
+ protected String[] getChangeRoles() {
+ return new String[] {
+ xmlRolesReader.getEntitlement("Audit", "enable"),
+ xmlRolesReader.getEntitlement("Audit", "disable")
+ };
+ }
+
+ @Override
+ public void onEventAction(final IEvent<?> event) {
+ if (event.getPayload() instanceof SelectedEventsPanel.EventSelectionChanged) {
+
+ final SelectedEventsPanel.EventSelectionChanged eventSelectionChanged =
+ (SelectedEventsPanel.EventSelectionChanged) event.getPayload();
+
+ for (String toBeRemoved : eventSelectionChanged.getToBeRemoved()) {
+ if (events.contains(toBeRemoved)) {
+ Pair<EventCategoryTO, Result> eventCategory =
+ AuditLoggerName.parseEventCategory(toBeRemoved);
+
+ final AuditLoggerName auditLoggerName = new AuditLoggerName(
+ eventCategory.getKey().getType(),
+ eventCategory.getKey().getCategory(),
+ eventCategory.getKey().getSubcategory(),
+ CollectionUtils.isEmpty(eventCategory.getKey().getEvents())
+ ? null : eventCategory.getKey().getEvents().iterator().next(),
+ eventCategory.getValue());
+
+ loggerRestClient.disableAudit(auditLoggerName);
+ events.remove(toBeRemoved);
+ }
+ }
+
+ for (String toBeAdded : eventSelectionChanged.getToBeAdded()) {
+ if (!events.contains(toBeAdded)) {
+ Pair<EventCategoryTO, Result> eventCategory =
+ AuditLoggerName.parseEventCategory(toBeAdded);
+
+ final AuditLoggerName auditLoggerName = new AuditLoggerName(
+ eventCategory.getKey().getType(),
+ eventCategory.getKey().getCategory(),
+ eventCategory.getKey().getSubcategory(),
+ CollectionUtils.isEmpty(eventCategory.getKey().getEvents())
+ ? null : eventCategory.getKey().getEvents().iterator().next(),
+ eventCategory.getValue());
+
+ loggerRestClient.enableAudit(auditLoggerName);
+ events.add(toBeAdded);
+ }
+ }
+ }
+ }
+ });
+ }
+
+ private class ReportProvider extends SortableDataProvider<ReportTO, String> {
+
+ private static final long serialVersionUID = -2311716167583335852L;
+
+ private final SortableDataProviderComparator<ReportTO> comparator;
+
+ public ReportProvider() {
+ super();
+
+ //Default sorting
+ setSort("key", SortOrder.ASCENDING);
+ comparator = new SortableDataProviderComparator<>(this);
+ }
+
+ @Override
+ public Iterator<ReportTO> iterator(final long first, final long count) {
+ final int page = ((int) first / paginatorRows);
+
+ final List<ReportTO> list =
+ reportRestClient.list((page < 0 ? 0 : page) + 1, paginatorRows, getSort());
+ Collections.sort(list, comparator);
+ return list.iterator();
+ }
+
+ @Override
+ public long size() {
+ return reportRestClient.count();
+ }
+
+ @Override
+ public IModel<ReportTO> model(final ReportTO configuration) {
+
+ return new AbstractReadOnlyModel<ReportTO>() {
+
+ private static final long serialVersionUID = 4921104837546595602L;
+
+ @Override
+ public ReportTO getObject() {
+ return configuration;
+ }
+ };
+ }
+ }
+}
[41/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/AttrTemplatesPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/AttrTemplatesPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/AttrTemplatesPanel.java
deleted file mode 100644
index 98ada28..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/AttrTemplatesPanel.java
+++ /dev/null
@@ -1,167 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.Collection;
-import java.util.Collections;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.SelectChoiceRenderer;
-import org.apache.syncope.client.console.rest.SchemaRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.NonI18nPalette;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.syncope.common.lib.types.SchemaType;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.event.Broadcast;
-import org.apache.wicket.extensions.markup.html.form.palette.component.Recorder;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.util.ListModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class AttrTemplatesPanel extends Panel {
-
- public enum Type {
-
- gPlainAttrTemplates,
- gDerAttrTemplates,
- gVirAttrTemplates,
- mPlainAttrTemplates,
- mDerAttrTemplates,
- mVirAttrTemplates;
-
- }
-
- private static final long serialVersionUID = 1016028222120619000L;
-
- @SpringBean
- private SchemaRestClient schemaRestClient;
-
- private final GroupTO groupTO;
-
- private final NonI18nPalette<String> rPlainAttrTemplates;
-
- private final NonI18nPalette<String> rDerAttrTemplates;
-
- private final NonI18nPalette<String> rVirAttrTemplates;
-
- public AttrTemplatesPanel(final String id, final GroupTO groupTO) {
- super(id);
- this.groupTO = groupTO;
-
- rPlainAttrTemplates = buildPalette(Type.gPlainAttrTemplates,
- schemaRestClient.getSchemaNames(AttributableType.GROUP, SchemaType.PLAIN));
- this.add(rPlainAttrTemplates);
- rDerAttrTemplates = buildPalette(Type.gDerAttrTemplates,
- schemaRestClient.getSchemaNames(AttributableType.GROUP, SchemaType.DERIVED));
- this.add(rDerAttrTemplates);
- rVirAttrTemplates = buildPalette(Type.gVirAttrTemplates,
- schemaRestClient.getSchemaNames(AttributableType.GROUP, SchemaType.VIRTUAL));
- this.add(rVirAttrTemplates);
-
- this.add(buildPalette(Type.mPlainAttrTemplates,
- schemaRestClient.getSchemaNames(AttributableType.MEMBERSHIP, SchemaType.PLAIN)));
- this.add(buildPalette(Type.mDerAttrTemplates,
- schemaRestClient.getSchemaNames(AttributableType.MEMBERSHIP, SchemaType.DERIVED)));
- this.add(buildPalette(Type.mVirAttrTemplates,
- schemaRestClient.getSchemaNames(AttributableType.MEMBERSHIP, SchemaType.VIRTUAL)));
- }
-
- private NonI18nPalette<String> buildPalette(final Type type, final List<String> allSchemas) {
- if (allSchemas != null && !allSchemas.isEmpty()) {
- Collections.sort(allSchemas);
- }
- ListModel<String> availableSchemas = new ListModel<>(allSchemas);
-
- return new NonI18nPalette<String>(type.name(), new PropertyModel<List<String>>(groupTO, type.name()),
- availableSchemas, new SelectChoiceRenderer<String>(), 8, false, true) {
-
- private static final long serialVersionUID = 2295567122085510330L;
-
- @Override
- protected Recorder<String> newRecorderComponent() {
- final Recorder<String> recorder = super.newRecorderComponent();
-
- switch (type) {
- case gPlainAttrTemplates:
- case gDerAttrTemplates:
- case gVirAttrTemplates:
- recorder.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- send(getPage(), Broadcast.BREADTH, new GroupAttrTemplatesChange(type, target));
- }
- });
- break;
-
- default:
- }
-
- return recorder;
- }
- };
- }
-
- public Collection<String> getSelected(final Type type) {
- Collection<String> selected;
- switch (type) {
- case gPlainAttrTemplates:
- selected = this.rPlainAttrTemplates.getModelCollection();
- break;
-
- case gDerAttrTemplates:
- selected = this.rDerAttrTemplates.getModelCollection();
- break;
-
- case gVirAttrTemplates:
- selected = this.rVirAttrTemplates.getModelCollection();
- break;
-
- default:
- selected = Collections.emptyList();
- }
-
- return selected;
- }
-
- public static class GroupAttrTemplatesChange {
-
- private final Type type;
-
- private final AjaxRequestTarget target;
-
- public GroupAttrTemplatesChange(final Type type, final AjaxRequestTarget target) {
- this.type = type;
- this.target = target;
- }
-
- public Type getType() {
- return type;
- }
-
- public AjaxRequestTarget getTarget() {
- return target;
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/DataTablePanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/DataTablePanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/DataTablePanel.java
deleted file mode 100644
index a5f6588..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/DataTablePanel.java
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.Collection;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.Set;
-import org.apache.wicket.Component;
-import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.DataGridView;
-import org.apache.wicket.markup.html.form.CheckGroup;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.IModel;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-public abstract class DataTablePanel<T, S> extends Panel {
-
- private static final long serialVersionUID = -7264400471578272966L;
-
- /**
- * Logger.
- */
- private static final Logger LOG = LoggerFactory.getLogger(DataTablePanel.class);
-
- protected CheckGroup<T> group;
-
- protected AjaxFallbackDefaultDataTable<T, S> dataTable;
-
- protected IModel<Collection<T>> model;
-
- public DataTablePanel(final String id) {
- super(id);
-
- model = new IModel<Collection<T>>() {
-
- private static final long serialVersionUID = 4886729136344643465L;
-
- private Collection<T> values = new HashSet<T>();
-
- @Override
- public Collection<T> getObject() {
- // Someone or something call this method to change the model: this is not the right behavior.
- // Return a copy of the model object in order to avoid SYNCOPE-465
- return new HashSet<T>(values);
- }
-
- @Override
- public void setObject(final Collection<T> selected) {
- final Collection<T> all = getGroupModelObjects();
- values.removeAll(all);
- values.addAll(selected);
- }
-
- @Override
- public void detach() {
- }
- };
- }
-
- public final void setCurrentPage(final long page) {
- dataTable.setCurrentPage(page);
- }
-
- public final long getRowCount() {
- return dataTable.getRowCount();
- }
-
- public final long getCurrentPage() {
- return dataTable.getCurrentPage();
- }
-
- public final long getPageCount() {
- return dataTable.getPageCount();
- }
-
- public void setItemsPerPage(final int resourcePaginatorRows) {
- dataTable.setItemsPerPage(resourcePaginatorRows);
- }
-
- protected Collection<T> getGroupModelObjects() {
- final Set<T> res = new HashSet<T>();
-
- final Component rows = group.get("dataTable:body:rows");
- if (rows instanceof DataGridView) {
- @SuppressWarnings("unchecked")
- final Iterator<Item<T>> iter = ((DataGridView<T>) rows).getItems();
-
- while (iter.hasNext()) {
- res.add(iter.next().getModelObject());
- }
- }
- return res;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/DerAttrsPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/DerAttrsPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/DerAttrsPanel.java
deleted file mode 100644
index 8be459a..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/DerAttrsPanel.java
+++ /dev/null
@@ -1,206 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.panels.AttrTemplatesPanel.GroupAttrTemplatesChange;
-import org.apache.syncope.client.console.rest.GroupRestClient;
-import org.apache.syncope.client.console.rest.SchemaRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDecoratedCheckbox;
-import org.apache.syncope.common.lib.to.AbstractAttributableTO;
-import org.apache.syncope.common.lib.to.AttrTO;
-import org.apache.syncope.common.lib.to.MembershipTO;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.wicket.Component;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.attributes.AjaxCallListener;
-import org.apache.wicket.ajax.attributes.AjaxRequestAttributes;
-import org.apache.wicket.ajax.attributes.IAjaxCallListener;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.form.TextField;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class DerAttrsPanel extends Panel {
-
- private static final long serialVersionUID = -5387344116983102292L;
-
- @SpringBean
- private SchemaRestClient schemaRestClient;
-
- @SpringBean
- private GroupRestClient groupRestClient;
-
- private final AttrTemplatesPanel attrTemplates;
-
- public <T extends AbstractAttributableTO> DerAttrsPanel(final String id, final T entityTO) {
- this(id, entityTO, null);
- }
-
- public <T extends AbstractAttributableTO> DerAttrsPanel(final String id, final T entityTO,
- final AttrTemplatesPanel attrTemplates) {
-
- super(id);
- this.attrTemplates = attrTemplates;
- setOutputMarkupId(true);
-
- final IModel<List<String>> derSchemas = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- List<String> derSchemaNames;
-
- if (entityTO instanceof GroupTO) {
- final GroupTO groupTO = (GroupTO) entityTO;
-
- if (attrTemplates == null) {
- derSchemaNames = groupTO.getGDerAttrTemplates();
- } else {
- derSchemaNames = new ArrayList<>(
- attrTemplates.getSelected(AttrTemplatesPanel.Type.gDerAttrTemplates));
- if (groupTO.isInheritTemplates() && groupTO.getParent() != 0) {
- derSchemaNames.addAll(groupRestClient.read(groupTO.getParent()).getGDerAttrTemplates());
- }
- }
- } else if (entityTO instanceof UserTO) {
- derSchemaNames = schemaRestClient.getDerSchemaNames(AttributableType.USER);
- } else {
- derSchemaNames = groupRestClient.read(((MembershipTO) entityTO).getGroupKey()).getMDerAttrTemplates();
- }
-
- return derSchemaNames;
- }
- };
-
- final WebMarkupContainer attributesContainer = new WebMarkupContainer("derAttrContainer");
-
- attributesContainer.setOutputMarkupId(true);
- add(attributesContainer);
-
- AjaxButton addAttributeBtn = new IndicatingAjaxButton("addAttributeBtn", new ResourceModel("addAttributeBtn")) {
-
- private static final long serialVersionUID = -4804368561204623354L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- entityTO.getDerAttrs().add(new AttrTO());
- target.add(attributesContainer);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- target.add(attributesContainer);
- }
- };
- add(addAttributeBtn.setDefaultFormProcessing(false));
-
- ListView<AttrTO> attributes = new ListView<AttrTO>("attrs",
- new PropertyModel<List<? extends AttrTO>>(entityTO, "derAttrs")) {
-
- private static final long serialVersionUID = 9101744072914090143L;
-
- @Override
- protected void populateItem(final ListItem<AttrTO> item) {
- final AttrTO attributeTO = item.getModelObject();
-
- item.add(new AjaxDecoratedCheckbox("toRemove", new Model<>(Boolean.FALSE)) {
-
- private static final long serialVersionUID = 7170946748485726506L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- entityTO.getDerAttrs().remove(attributeTO);
- target.add(attributesContainer);
- }
-
- @Override
- protected void updateAjaxAttributes(final AjaxRequestAttributes attributes) {
- super.updateAjaxAttributes(attributes);
-
- IAjaxCallListener ajaxCallListener = new AjaxCallListener() {
-
- private static final long serialVersionUID = 7160235486520935153L;
-
- @Override
- public CharSequence getPrecondition(final Component component) {
- return "if (!confirm('" + getString("confirmDelete") + "')) return false;";
- }
- };
- attributes.getAjaxCallListeners().add(ajaxCallListener);
- }
- });
-
- final DropDownChoice<String> schemaChoice = new DropDownChoice<String>("schema",
- new PropertyModel<String>(attributeTO, "schema"), derSchemas);
- schemaChoice.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_BLUR) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- attributeTO.setSchema(schemaChoice.getModelObject());
- }
- });
- schemaChoice.setRequired(true);
- schemaChoice.setOutputMarkupId(true);
- schemaChoice.setRequired(true);
- item.add(schemaChoice);
-
- final List<String> values = attributeTO.getValues();
- if (values == null || values.isEmpty()) {
- item.add(new TextField<String>("value",
- new Model<String>(null)).setVisible(false));
- } else {
- item.add(new TextField<String>("value",
- new Model<String>(values.get(0))).setEnabled(false));
- }
- }
- };
- attributesContainer.add(attributes);
- }
-
- @Override
- public void onEvent(final IEvent<?> event) {
- if ((event.getPayload() instanceof GroupAttrTemplatesChange)) {
- final GroupAttrTemplatesChange update = (GroupAttrTemplatesChange) event.getPayload();
- if (attrTemplates != null && update.getType() == AttrTemplatesPanel.Type.gDerAttrTemplates) {
- update.getTarget().add(this);
- }
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/EventSelectionPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/EventSelectionPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/EventSelectionPanel.java
deleted file mode 100644
index 5332cb5..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/EventSelectionPanel.java
+++ /dev/null
@@ -1,243 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.Collections;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.wicket.markup.html.list.AltListView;
-import org.apache.syncope.common.lib.to.EventCategoryTO;
-import org.apache.syncope.common.lib.types.AuditElements;
-import org.apache.syncope.common.lib.types.AuditLoggerName;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormChoiceComponentUpdatingBehavior;
-import org.apache.wicket.event.Broadcast;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Check;
-import org.apache.wicket.markup.html.form.CheckGroup;
-import org.apache.wicket.markup.html.form.CheckGroupSelector;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.ResourceModel;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-public abstract class EventSelectionPanel extends Panel {
-
- /**
- * Logger.
- */
- private static final Logger LOG = LoggerFactory.getLogger(EventSelectionPanel.class);
-
- private static final long serialVersionUID = 752233163798301002L;
-
- private final Set<String> selected = new HashSet<String>();
-
- public EventSelectionPanel(
- final String id, final EventCategoryTO eventCategoryTO, final IModel<List<String>> model) {
- super(id);
- setOutputMarkupId(true);
-
- final List<String> events = getEvents(eventCategoryTO);
-
- // needed to avoid model reset: model have to be managed into SelectedEventsPanel
- selected.addAll(model.getObject());
-
- final CheckGroup<String> successGroup = new CheckGroup<String>(
- "successGroup",
- selected);
-
- successGroup.add(new AjaxFormChoiceComponentUpdatingBehavior() {
-
- private static final long serialVersionUID = -151291731388673682L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
-
- final Set<String> toBeRemoved = new HashSet<>();
- final Set<String> toBeAdded = new HashSet<>();
-
- for (String event : getEvents(eventCategoryTO)) {
- final String eventString = AuditLoggerName.buildEvent(
- eventCategoryTO.getType(),
- eventCategoryTO.getCategory(),
- eventCategoryTO.getSubcategory(),
- event,
- AuditElements.Result.SUCCESS);
-
- if (successGroup.getModelObject().contains(eventString)) {
- toBeAdded.add(eventString);
- } else {
- toBeRemoved.add(eventString);
- }
- }
-
- send(EventSelectionPanel.this.getPage(), Broadcast.BREADTH,
- new SelectedEventsPanel.EventSelectionChanged(target, toBeAdded, toBeRemoved));
- }
- });
-
- successGroup.setVisible(!events.isEmpty());
- add(successGroup);
-
- add(new Label("successLabel", new ResourceModel("Success", "Success"))).setVisible(!events.isEmpty());
-
- final CheckGroupSelector successSelector = new CheckGroupSelector("successSelector", successGroup);
- successSelector.setVisible(!events.isEmpty());
- add(successSelector);
-
- final ListView<String> categoryView = new AltListView<String>("categoryView", events) {
-
- private static final long serialVersionUID = 4949588177564901031L;
-
- @Override
- protected void populateItem(final ListItem<String> item) {
- final String subcategory = item.getModelObject();
-
- item.add(new Label("subcategory", new ResourceModel(subcategory, subcategory)));
- }
- };
- add(categoryView);
-
- final ListView<String> successView = new AltListView<String>("successView", events) {
-
- private static final long serialVersionUID = 4949588177564901031L;
-
- @Override
- protected void populateItem(final ListItem<String> item) {
- final String event = item.getModelObject();
-
- final Check<String> successCheck = new Check<>("successCheck",
- new Model<String>(AuditLoggerName.buildEvent(
- eventCategoryTO.getType(),
- eventCategoryTO.getCategory(),
- eventCategoryTO.getSubcategory(),
- event,
- AuditElements.Result.SUCCESS)),
- successGroup);
- item.add(successCheck);
- }
- };
- successGroup.add(successView);
-
- final CheckGroup<String> failureGroup = new CheckGroup<String>(
- "failureGroup",
- selected);
-
- failureGroup.add(new AjaxFormChoiceComponentUpdatingBehavior() {
-
- private static final long serialVersionUID = -151291731388673682L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
-
- final Set<String> toBeRemoved = new HashSet<>();
- final Set<String> toBeAdded = new HashSet<>();
-
- for (String event : getEvents(eventCategoryTO)) {
- final String eventString = AuditLoggerName.buildEvent(
- eventCategoryTO.getType(),
- eventCategoryTO.getCategory(),
- eventCategoryTO.getSubcategory(),
- event,
- AuditElements.Result.FAILURE);
-
- if (failureGroup.getModelObject().contains(eventString)) {
- toBeAdded.add(eventString);
- } else {
- toBeRemoved.add(eventString);
- }
- }
-
- send(EventSelectionPanel.this.getPage(), Broadcast.BREADTH,
- new SelectedEventsPanel.EventSelectionChanged(target, toBeAdded, toBeRemoved));
- }
- });
-
- failureGroup.setVisible(!events.isEmpty());
- add(failureGroup);
-
- add(new Label("failureLabel", new ResourceModel("Failure", "Failure"))).setVisible(!events.isEmpty());
-
- final CheckGroupSelector failureSelector = new CheckGroupSelector("failureSelector", failureGroup);
- failureSelector.setVisible(!events.isEmpty());
- add(failureSelector);
-
- final ListView<String> failureView = new AltListView<String>("failureView", events) {
-
- private static final long serialVersionUID = 4949588177564901031L;
-
- @Override
- protected void populateItem(final ListItem<String> item) {
- final String event = item.getModelObject();
-
- final Check<String> failureCheck = new Check<>("failureCheck",
- new Model<String>(AuditLoggerName.buildEvent(
- eventCategoryTO.getType(),
- eventCategoryTO.getCategory(),
- eventCategoryTO.getSubcategory(),
- event,
- AuditElements.Result.FAILURE)),
- failureGroup);
- item.add(failureCheck);
- }
- };
- failureGroup.add(failureView);
- }
-
- private List<String> getEvents(final EventCategoryTO eventCategoryTO) {
- final List<String> res;
-
- res = eventCategoryTO.getEvents();
-
- if (res.isEmpty()) {
- if ((AuditElements.EventCategoryType.PROPAGATION == eventCategoryTO.getType()
- || AuditElements.EventCategoryType.SYNCHRONIZATION == eventCategoryTO.getType()
- || AuditElements.EventCategoryType.PUSH == eventCategoryTO.getType())
- && StringUtils.isEmpty(eventCategoryTO.getCategory())) {
- res.add(eventCategoryTO.getType().toString());
- } else if (AuditElements.EventCategoryType.TASK == eventCategoryTO.getType()
- && StringUtils.isNotEmpty(eventCategoryTO.getCategory())) {
- res.add(eventCategoryTO.getCategory());
- }
- } else {
- Collections.sort(res);
- }
-
- return res;
- }
-
- /**
- * To be extended in order to add actions on events.
- *
- * @param event event.
- */
- protected abstract void onEventAction(final IEvent<?> event);
-
- @Override
- public void onEvent(final IEvent<?> event) {
- onEventAction(event);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupDetailsPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupDetailsPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupDetailsPanel.java
deleted file mode 100644
index 7662e4a..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupDetailsPanel.java
+++ /dev/null
@@ -1,435 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.JexlHelpUtils;
-import org.apache.syncope.client.console.pages.GroupSelectModalPage;
-import org.apache.syncope.client.console.pages.UserOwnerSelectModalPage;
-import org.apache.syncope.client.console.panels.AttrTemplatesPanel.GroupAttrTemplatesChange;
-import org.apache.syncope.client.console.panels.AttrTemplatesPanel.Type;
-import org.apache.syncope.client.console.rest.GroupRestClient;
-import org.apache.syncope.client.console.rest.UserRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.wicket.Page;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.event.Broadcast;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.panel.Fragment;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-public class GroupDetailsPanel extends Panel {
-
- private static final long serialVersionUID = 855618618337931784L;
-
- /**
- * Logger.
- */
- protected static final Logger LOG = LoggerFactory.getLogger(GroupDetailsPanel.class);
-
- @SpringBean
- private UserRestClient userRestClient;
-
- @SpringBean
- private GroupRestClient groupRestClient;
-
- private final Fragment parentFragment;
-
- private final WebMarkupContainer ownerContainer;
-
- private final OwnerModel userOwnerModel;
-
- private final OwnerModel groupOwnerModel;
-
- private ParentModel parentModel;
-
- public GroupDetailsPanel(final String id, final GroupTO groupTO, final boolean templateMode) {
- super(id);
-
- ownerContainer = new WebMarkupContainer("ownerContainer");
- ownerContainer.setOutputMarkupId(true);
- this.add(ownerContainer);
-
- final ModalWindow userOwnerSelectWin = new ModalWindow("userOwnerSelectWin");
- userOwnerSelectWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- userOwnerSelectWin.setCookieName("create-userOwnerSelect-modal");
- this.add(userOwnerSelectWin);
- final ModalWindow groupOwnerSelectWin = new ModalWindow("groupOwnerSelectWin");
- groupOwnerSelectWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- groupOwnerSelectWin.setCookieName("create-groupOwnerSelect-modal");
- this.add(groupOwnerSelectWin);
- final ModalWindow parentSelectWin = new ModalWindow("parentSelectWin");
- parentSelectWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- parentSelectWin.setCookieName("create-parentSelect-modal");
- this.add(parentSelectWin);
-
- if (templateMode) {
- parentFragment = new Fragment("parent", "parentFragment", this);
-
- parentModel = new ParentModel(groupTO);
- @SuppressWarnings("unchecked")
- final AjaxTextFieldPanel parent = new AjaxTextFieldPanel("parent", "parent", parentModel);
- parent.setReadOnly(true);
- parent.setOutputMarkupId(true);
- parentFragment.add(parent);
- final AjaxLink<Void> parentSelect = new IndicatingAjaxLink<Void>("parentSelect") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- parentSelectWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new GroupSelectModalPage(getPage().getPageReference(), parentSelectWin,
- ParentSelectPayload.class);
- }
- });
- parentSelectWin.show(target);
- }
- };
- parentFragment.add(parentSelect);
- final IndicatingAjaxLink<Void> parentReset = new IndicatingAjaxLink<Void>("parentReset") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- parentModel.setObject(null);
- target.add(parent);
- }
- };
- parentFragment.add(parentReset);
- } else {
- parentFragment = new Fragment("parent", "emptyFragment", this);
- }
- parentFragment.setOutputMarkupId(true);
- this.add(parentFragment);
-
- final AjaxTextFieldPanel name =
- new AjaxTextFieldPanel("name", "name", new PropertyModel<String>(groupTO, "key"));
-
- final WebMarkupContainer jexlHelp = JexlHelpUtils.getJexlHelpWebContainer("jexlHelp");
-
- final AjaxLink<Void> questionMarkJexlHelp = JexlHelpUtils.getAjaxLink(jexlHelp, "questionMarkJexlHelp");
- this.add(questionMarkJexlHelp);
- questionMarkJexlHelp.add(jexlHelp);
-
- if (!templateMode) {
- name.addRequiredLabel();
- questionMarkJexlHelp.setVisible(false);
- }
- this.add(name);
-
- userOwnerModel = new OwnerModel(groupTO, AttributableType.USER);
- @SuppressWarnings("unchecked")
- final AjaxTextFieldPanel userOwner = new AjaxTextFieldPanel("userOwner", "userOwner", userOwnerModel);
- userOwner.setReadOnly(true);
- userOwner.setOutputMarkupId(true);
- ownerContainer.add(userOwner);
- final AjaxLink<Void> userOwnerSelect = new IndicatingAjaxLink<Void>("userOwnerSelect") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- userOwnerSelectWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new UserOwnerSelectModalPage(getPage().getPageReference(), userOwnerSelectWin);
- }
- });
- userOwnerSelectWin.show(target);
- }
- };
- ownerContainer.add(userOwnerSelect);
- final IndicatingAjaxLink<Void> userOwnerReset = new IndicatingAjaxLink<Void>("userOwnerReset") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- userOwnerModel.setObject(null);
- target.add(userOwner);
- }
- };
- ownerContainer.add(userOwnerReset);
-
- groupOwnerModel = new OwnerModel(groupTO, AttributableType.GROUP);
- @SuppressWarnings("unchecked")
- final AjaxTextFieldPanel groupOwner = new AjaxTextFieldPanel("groupOwner", "groupOwner", groupOwnerModel);
- groupOwner.setReadOnly(true);
- groupOwner.setOutputMarkupId(true);
- ownerContainer.add(groupOwner);
- final AjaxLink<Void> groupOwnerSelect = new IndicatingAjaxLink<Void>("groupOwnerSelect") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- parentSelectWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new GroupSelectModalPage(getPage().getPageReference(), parentSelectWin,
- GroupOwnerSelectPayload.class);
- }
- });
- parentSelectWin.show(target);
- }
- };
- ownerContainer.add(groupOwnerSelect);
- final IndicatingAjaxLink<Void> groupOwnerReset = new IndicatingAjaxLink<Void>("groupOwnerReset") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- groupOwnerModel.setObject(null);
- target.add(groupOwner);
- }
- };
- ownerContainer.add(groupOwnerReset);
-
- final AjaxCheckBoxPanel inhOwner = new AjaxCheckBoxPanel("inheritOwner", "inheritOwner",
- new PropertyModel<Boolean>(groupTO, "inheritOwner"));
- this.add(inhOwner);
-
- final AjaxCheckBoxPanel inhTemplates = new AjaxCheckBoxPanel("inheritTemplates", "inheritTemplates",
- new PropertyModel<Boolean>(groupTO, "inheritTemplates"));
- inhTemplates.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- send(getPage(), Broadcast.BREADTH, new GroupAttrTemplatesChange(Type.gPlainAttrTemplates, target));
- send(getPage(), Broadcast.BREADTH, new GroupAttrTemplatesChange(Type.gDerAttrTemplates, target));
- send(getPage(), Broadcast.BREADTH, new GroupAttrTemplatesChange(Type.gVirAttrTemplates, target));
- }
- });
- this.add(inhTemplates);
- }
-
- /**
- * This is waiting for events from opened modal windows: first to get the selected user / group, then to update the
- * respective text panel.
- *
- * {@inheritDoc }
- */
- @Override
- public void onEvent(final IEvent<?> event) {
- super.onEvent(event);
-
- if (event.getPayload() instanceof ParentSelectPayload) {
- parentModel.setObject(((ParentSelectPayload) event.getPayload()).getGroupId());
- }
- if (event.getPayload() instanceof UserOwnerSelectPayload) {
- userOwnerModel.setObject(((UserOwnerSelectPayload) event.getPayload()).getUserId());
- }
- if (event.getPayload() instanceof GroupOwnerSelectPayload) {
- groupOwnerModel.setObject(((GroupOwnerSelectPayload) event.getPayload()).getGroupId());
- }
-
- if (event.getPayload() instanceof AjaxRequestTarget) {
- ((AjaxRequestTarget) event.getPayload()).add(parentFragment);
- ((AjaxRequestTarget) event.getPayload()).add(ownerContainer);
- }
- }
-
- private class OwnerModel implements IModel {
-
- private static final long serialVersionUID = -3865621970810102714L;
-
- private final GroupTO groupTO;
-
- private final AttributableType type;
-
- public OwnerModel(final GroupTO groupTO, final AttributableType type) {
- this.groupTO = groupTO;
- this.type = type;
- }
-
- @Override
- public Object getObject() {
- String object = null;
-
- switch (type) {
- case USER:
- if (groupTO.getUserOwner() != null) {
- UserTO user = null;
- try {
- user = userRestClient.read(groupTO.getUserOwner());
- } catch (Exception e) {
- LOG.warn("Could not find user with id {}, ignoring", groupTO.getUserOwner(), e);
- }
- if (user == null) {
- groupTO.setUserOwner(null);
- } else {
- object = user.getKey() + " " + user.getUsername();
- }
- }
- break;
-
- case GROUP:
- GroupTO group = null;
- if (groupTO.getGroupOwner() != null) {
- try {
- group = groupRestClient.read(groupTO.getGroupOwner());
- } catch (Exception e) {
- LOG.warn("Could not find group with id {}, ignoring", groupTO.getGroupOwner(), e);
- }
- if (group == null) {
- groupTO.setGroupOwner(null);
- } else {
- object = group.getDisplayName();
- }
- }
- break;
-
- case MEMBERSHIP:
- default:
- }
-
- return object;
- }
-
- @Override
- public void setObject(final Object object) {
- switch (type) {
- case USER:
- groupTO.setUserOwner((Long) object);
- break;
-
- case GROUP:
- groupTO.setGroupOwner((Long) object);
- break;
-
- case MEMBERSHIP:
- default:
- }
- }
-
- @Override
- public void detach() {
- // ignore
- }
- }
-
- private class ParentModel implements IModel {
-
- private static final long serialVersionUID = 1006546156848990721L;
-
- private final GroupTO groupTO;
-
- public ParentModel(final GroupTO groupTO) {
- this.groupTO = groupTO;
- }
-
- @Override
- public Object getObject() {
- Object object = null;
- if (groupTO.getParent() != 0) {
- GroupTO parent = null;
- try {
- parent = groupRestClient.read(groupTO.getParent());
- } catch (Exception e) {
- LOG.warn("Could not find group with id {}, ignoring", groupTO.getParent(), e);
- }
- if (parent == null) {
- groupTO.setParent(0);
- } else {
- object = parent.getDisplayName();
- }
- }
- return object;
- }
-
- @Override
- public void setObject(final Object object) {
- groupTO.setParent((object instanceof Long) ? ((Long) object) : 0);
- }
-
- @Override
- public void detach() {
- // ignore
- }
- }
-
- public static class UserOwnerSelectPayload {
-
- private final Long userId;
-
- public UserOwnerSelectPayload(final Long userId) {
- this.userId = userId;
- }
-
- public Long getUserId() {
- return userId;
- }
- }
-
- public static class GroupOwnerSelectPayload {
-
- private final Long groupId;
-
- public GroupOwnerSelectPayload(final Long groupId) {
- this.groupId = groupId;
- }
-
- public Long getGroupId() {
- return groupId;
- }
- }
-
- public static class ParentSelectPayload {
-
- private final Long groupId;
-
- public ParentSelectPayload(final Long groupId) {
- this.groupId = groupId;
- }
-
- public Long getGroupId() {
- return groupId;
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupPanel.java
deleted file mode 100644
index 7cbf47e..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupPanel.java
+++ /dev/null
@@ -1,187 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Mode;
-import org.apache.syncope.client.console.commons.XMLRolesReader;
-import org.apache.syncope.client.console.commons.status.StatusBean;
-import org.apache.syncope.client.console.rest.AuthRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPalettePanel;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.util.ListModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class GroupPanel extends Panel {
-
- private static final long serialVersionUID = 4216376097320768369L;
-
- @SpringBean
- private AuthRestClient authRestClient;
-
- @SpringBean
- private XMLRolesReader xmlRolesReader;
-
- private final AjaxPalettePanel<String> entitlements;
-
- public static class Builder implements Serializable {
-
- private static final long serialVersionUID = 8150440254654306070L;
-
- private String id;
-
- private Form form;
-
- private GroupTO groupTO;
-
- private Mode mode;
-
- private PageReference pageReference;
-
- public Builder(final String id) {
- this.id = id;
- }
-
- public Builder form(final Form form) {
- this.form = form;
- return this;
- }
-
- public Builder groupTO(final GroupTO groupTO) {
- this.groupTO = groupTO;
- return this;
- }
-
- public Builder groupModalPageMode(final Mode mode) {
- this.mode = mode;
- return this;
- }
-
- public Builder pageRef(final PageReference pageReference) {
- this.pageReference = pageReference;
- return this;
- }
-
- public GroupPanel build() {
- return new GroupPanel(this);
- }
- }
-
- private GroupPanel(final Builder builder) {
- super(builder.id);
-
- this.add(new GroupDetailsPanel("details", builder.groupTO, builder.mode == Mode.TEMPLATE));
-
- if (builder.pageReference == null || builder.groupTO.getKey() == 0) {
- this.add(new Label("statuspanel", ""));
- } else {
- StatusPanel statusPanel = new StatusPanel(
- "statuspanel", builder.groupTO, new ArrayList<StatusBean>(), builder.pageReference);
- statusPanel.setOutputMarkupId(true);
- MetaDataRoleAuthorizationStrategy.authorize(
- statusPanel, RENDER, xmlRolesReader.getEntitlement("Resources", "getConnectorObject"));
- this.add(statusPanel);
- }
-
- this.add(new AnnotatedBeanPanel("systeminformation", builder.groupTO));
-
- //--------------------------------
- // Attribute templates panel
- //--------------------------------
- AttrTemplatesPanel attrTemplates = new AttrTemplatesPanel("templates", builder.groupTO);
- this.add(attrTemplates);
-
- //--------------------------------
- // Attributes panel
- //--------------------------------
- this.add(new PlainAttrsPanel(
- "plainAttrs", builder.groupTO, builder.form, builder.mode, attrTemplates));
-
- final AjaxCheckBoxPanel inhAttributes = new AjaxCheckBoxPanel("inheritPlainAttrs", "inheritPlainAttrs",
- new PropertyModel<Boolean>(builder.groupTO, "inheritPlainAttrs"));
- inhAttributes.setOutputMarkupId(true);
- this.add(inhAttributes);
- //--------------------------------
-
- //--------------------------------
- // Derived attributes panel
- //--------------------------------
- this.add(new DerAttrsPanel("derAttrs", builder.groupTO, attrTemplates));
-
- final AjaxCheckBoxPanel inhDerivedAttributes = new AjaxCheckBoxPanel("inheritDerAttrs",
- "inheritDerAttrs", new PropertyModel<Boolean>(builder.groupTO, "inheritDerAttrs"));
- inhDerivedAttributes.setOutputMarkupId(true);
- this.add(inhDerivedAttributes);
- //--------------------------------
-
- //--------------------------------
- // Virtual attributes panel
- //--------------------------------
- this.add(new VirAttrsPanel(
- "virAttrs", builder.groupTO, builder.mode == Mode.TEMPLATE, attrTemplates));
-
- final AjaxCheckBoxPanel inhVirtualAttributes = new AjaxCheckBoxPanel("inheritVirAttrs",
- "inheritVirAttrs", new PropertyModel<Boolean>(builder.groupTO, "inheritVirAttrs"));
- inhVirtualAttributes.setOutputMarkupId(true);
- this.add(inhVirtualAttributes);
- //--------------------------------
-
- //--------------------------------
- // Resources panel
- //--------------------------------
- this.add(new ResourcesPanel.Builder("resources").attributableTO(builder.groupTO).build().
- setOutputMarkupId(true));
- //--------------------------------
-
- //--------------------------------
- // Entitlements
- //--------------------------------
- ListModel<String> selectedEntitlements = new ListModel<String>(builder.groupTO.getEntitlements());
-
- List<String> allEntitlements = authRestClient.getAllEntitlements();
- if (allEntitlements != null && !allEntitlements.isEmpty()) {
- Collections.sort(allEntitlements);
- }
- ListModel<String> availableEntitlements = new ListModel<String>(allEntitlements);
-
- entitlements = new AjaxPalettePanel<String>("entitlements", selectedEntitlements, availableEntitlements);
- this.add(entitlements);
-
- //--------------------------------
- // Security panel
- //--------------------------------
- this.add(new GroupSecurityPanel("security", builder.groupTO).setOutputMarkupId(true));
- //--------------------------------
- }
-
- public Collection<String> getSelectedEntitlements() {
- return this.entitlements.getModelCollection();
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupSearchPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupSearchPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupSearchPanel.java
deleted file mode 100644
index d13ab94..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupSearchPanel.java
+++ /dev/null
@@ -1,101 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-import org.apache.syncope.client.lib.SyncopeClient;
-import org.apache.syncope.common.lib.search.AbstractFiqlSearchConditionBuilder;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.wicket.model.LoadableDetachableModel;
-
-public class GroupSearchPanel extends AbstractSearchPanel {
-
- private static final long serialVersionUID = 5757183539269316263L;
-
- public static class Builder implements Serializable {
-
- private static final long serialVersionUID = 6308997285778809579L;
-
- private String id;
-
- private String fiql = null;
-
- private boolean required = true;
-
- public Builder(final String id) {
- this.id = id;
- }
-
- public Builder fiql(final String fiql) {
- this.fiql = fiql;
- return this;
- }
-
- public Builder required(final boolean required) {
- this.required = required;
- return this;
- }
-
- public GroupSearchPanel build() {
- return new GroupSearchPanel(this);
- }
- }
-
- private GroupSearchPanel(final Builder builder) {
- super(builder.id, AttributableType.GROUP, builder.fiql, builder.required);
- }
-
- @Override
- protected void populate() {
- super.populate();
-
- this.types = new LoadableDetachableModel<List<SearchClause.Type>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<SearchClause.Type> load() {
- final List<SearchClause.Type> result = new ArrayList<SearchClause.Type>();
- result.add(SearchClause.Type.ATTRIBUTE);
- result.add(SearchClause.Type.ENTITLEMENT);
- result.add(SearchClause.Type.RESOURCE);
- return result;
- }
- };
-
- this.groupNames = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- return Collections.<String>emptyList();
- }
- };
- }
-
- @Override
- protected AbstractFiqlSearchConditionBuilder getSearchConditionBuilder() {
- return SyncopeClient.getGroupSearchConditionBuilder();
- }
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupSearchResultPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupSearchResultPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupSearchResultPanel.java
deleted file mode 100644
index a7dac82..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupSearchResultPanel.java
+++ /dev/null
@@ -1,172 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.pages.ResultStatusModalPage;
-import org.apache.syncope.client.console.pages.GroupModalPage;
-import org.apache.syncope.client.console.pages.StatusModalPage;
-import org.apache.syncope.client.console.rest.AbstractSubjectRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink.ActionType;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.AbstractAttributableTO;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.ResourceModel;
-
-public class GroupSearchResultPanel extends AbstractSearchResultPanel {
-
- private static final long serialVersionUID = -1180593361914008764L;
-
- private final static String PAGEID = "Groups";
-
- public <T extends AbstractAttributableTO> GroupSearchResultPanel(final String id, final boolean filtered,
- final String fiql, final PageReference callerRef, final AbstractSubjectRestClient restClient) {
-
- super(id, filtered, fiql, callerRef, restClient);
- initResultTable();
- }
-
- @Override
- protected List<IColumn<AbstractAttributableTO, String>> getColumns() {
- final List<IColumn<AbstractAttributableTO, String>> columns = new ArrayList<>();
-
- for (String item : new String[] { "key", "name", "entitlements" }) {
- columns.add(new PropertyColumn<AbstractAttributableTO, String>(new ResourceModel(item, item), item, item));
- }
-
- columns.add(new AbstractColumn<AbstractAttributableTO, String>(new ResourceModel("actions", "")) {
-
- private static final long serialVersionUID = -3503023501954863131L;
-
- @Override
- public String getCssClass() {
- return "action";
- }
-
- @Override
- public void populateItem(final Item<ICellPopulator<AbstractAttributableTO>> cellItem,
- final String componentId, final IModel<AbstractAttributableTO> model) {
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, page.getPageReference());
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- statusmodal.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new StatusModalPage<GroupTO>(
- page.getPageReference(), statusmodal, (GroupTO) model.getObject());
- }
- });
-
- statusmodal.show(target);
- }
- }, ActionLink.ActionType.MANAGE_RESOURCES, PAGEID);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- editmodal.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new GroupModalPage(
- page.getPageReference(), editmodal, (GroupTO) model.getObject());
- }
- });
-
- editmodal.show(target);
- }
- }, ActionLink.ActionType.EDIT, PAGEID);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- final GroupTO groupTO = (GroupTO) restClient.
- delete(model.getObject().getETagValue(), model.getObject().getKey());
-
- page.setModalResult(true);
-
- editmodal.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ResultStatusModalPage.Builder(editmodal, groupTO).build();
- }
- });
-
- editmodal.show(target);
- } catch (SyncopeClientException scce) {
- error(getString(Constants.OPERATION_ERROR) + ": " + scce.getMessage());
- feedbackPanel.refresh(target);
- }
- }
- }, ActionLink.ActionType.DELETE, PAGEID);
-
- cellItem.add(panel);
- }
- });
-
- return columns;
- }
-
- @Override
- protected Collection<ActionType> getBulkActions() {
- return Collections.<ActionLink.ActionType>singletonList(ActionLink.ActionType.DELETE);
- }
-
- @Override
- protected String getPageId() {
- return PAGEID;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupSecurityPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupSecurityPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupSecurityPanel.java
deleted file mode 100644
index 4e0e1f9..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupSecurityPanel.java
+++ /dev/null
@@ -1,198 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Map;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.rest.PolicyRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.common.lib.to.AbstractAttributableTO;
-import org.apache.syncope.common.lib.to.AbstractPolicyTO;
-import org.apache.syncope.common.lib.types.PolicyType;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.ChoiceRenderer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-public class GroupSecurityPanel extends Panel {
-
- /**
- * Logger.
- */
- protected static final Logger LOG = LoggerFactory.getLogger(GroupSecurityPanel.class);
-
- private static final long serialVersionUID = -7982691107029848579L;
-
- @SpringBean
- private PolicyRestClient policyRestClient;
-
- private IModel<Map<Long, String>> passwordPolicies = null;
-
- private IModel<Map<Long, String>> accountPolicies = null;
-
- public <T extends AbstractAttributableTO> GroupSecurityPanel(final String id, final T entityTO) {
- super(id);
-
- setOutputMarkupId(true);
-
- passwordPolicies = new LoadableDetachableModel<Map<Long, String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected Map<Long, String> load() {
- Map<Long, String> res = new HashMap<>();
- for (AbstractPolicyTO policyTO : policyRestClient.getPolicies(PolicyType.PASSWORD, false)) {
- res.put(policyTO.getKey(), policyTO.getDescription());
- }
- return res;
- }
- };
-
- accountPolicies = new LoadableDetachableModel<Map<Long, String>>() {
-
- private static final long serialVersionUID = -2012833443695917883L;
-
- @Override
- protected Map<Long, String> load() {
- Map<Long, String> res = new HashMap<>();
- for (AbstractPolicyTO policyTO : policyRestClient.getPolicies(PolicyType.ACCOUNT, false)) {
- res.put(policyTO.getKey(), policyTO.getDescription());
- }
- return res;
- }
- };
-
- final WebMarkupContainer securityContainer = new WebMarkupContainer("security");
-
- securityContainer.setOutputMarkupId(true);
- add(securityContainer);
-
- // -------------------------------
- // Password policy specification
- // -------------------------------
- final AjaxDropDownChoicePanel<Long> passwordPolicy = new AjaxDropDownChoicePanel<Long>("passwordPolicy",
- "passwordPolicy", new PropertyModel<Long>(entityTO, "passwordPolicy"));
-
- passwordPolicy.setChoiceRenderer(new PolicyRenderer(PolicyType.PASSWORD));
-
- passwordPolicy.setChoices(new ArrayList<Long>(passwordPolicies.getObject().keySet()));
-
- ((DropDownChoice<?>) passwordPolicy.getField()).setNullValid(true);
-
- securityContainer.add(passwordPolicy);
-
- final AjaxCheckBoxPanel inhPasswordPolicy = new AjaxCheckBoxPanel("inheritPasswordPolicy",
- "inheritPasswordPolicy", new PropertyModel<Boolean>(entityTO, "inheritPasswordPolicy"));
-
- passwordPolicy.setReadOnly(inhPasswordPolicy.getModelObject());
-
- inhPasswordPolicy.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- passwordPolicy.setReadOnly(inhPasswordPolicy.getModelObject());
- target.add(passwordPolicy);
- }
- });
-
- securityContainer.add(inhPasswordPolicy);
- // -------------------------------
-
- // -------------------------------
- // Account policy specification
- // -------------------------------
- final AjaxDropDownChoicePanel<Long> accountPolicy = new AjaxDropDownChoicePanel<Long>("accountPolicy",
- "accountPolicy", new PropertyModel<Long>(entityTO, "accountPolicy"));
-
- accountPolicy.setChoiceRenderer(new PolicyRenderer(PolicyType.ACCOUNT));
-
- accountPolicy.setChoices(new ArrayList<Long>(accountPolicies.getObject().keySet()));
-
- ((DropDownChoice<?>) accountPolicy.getField()).setNullValid(true);
-
- securityContainer.add(accountPolicy);
-
- final AjaxCheckBoxPanel inhAccountPolicy = new AjaxCheckBoxPanel("inheritAccountPolicy",
- "inheritAccountPolicy", new PropertyModel<Boolean>(entityTO, "inheritAccountPolicy"));
- accountPolicy.setReadOnly(inhAccountPolicy.getModelObject());
-
- inhAccountPolicy.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- accountPolicy.setReadOnly(inhAccountPolicy.getModelObject());
- target.add(accountPolicy);
- }
- });
-
- securityContainer.add(inhAccountPolicy);
- // -------------------------------
- }
-
- private class PolicyRenderer extends ChoiceRenderer<Long> {
-
- private static final long serialVersionUID = 8060500161321947000L;
-
- private PolicyType type;
-
- public PolicyRenderer(final PolicyType type) {
- super();
- this.type = type;
- }
-
- @Override
- public Object getDisplayValue(final Long object) {
- Object displayValue;
- switch (type) {
- case ACCOUNT:
- displayValue = accountPolicies.getObject().get(object);
- break;
- case PASSWORD:
- displayValue = passwordPolicies.getObject().get(object);
- break;
- default:
- displayValue = "";
- }
- return displayValue;
- }
-
- @Override
- public String getIdValue(Long object, int index) {
- return String.valueOf(object != null
- ? object
- : 0L);
- }
- };
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupSummaryPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupSummaryPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupSummaryPanel.java
deleted file mode 100644
index f9a56e6..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupSummaryPanel.java
+++ /dev/null
@@ -1,153 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.io.Serializable;
-import org.apache.syncope.client.console.commons.XMLRolesReader;
-import org.apache.syncope.client.console.pages.GroupModalPage;
-import org.apache.syncope.client.console.rest.GroupRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.panel.Fragment;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-public class GroupSummaryPanel extends Panel {
-
- private static final long serialVersionUID = 643769814985593156L;
-
- /**
- * Logger.
- */
- private static final Logger LOG = LoggerFactory.getLogger(GroupSummaryPanel.class);
-
- @SpringBean
- private XMLRolesReader xmlRolesReader;
-
- @SpringBean
- private GroupRestClient restClient;
-
- private GroupTO selectedNode;
-
- public static class Builder implements Serializable {
-
- private static final long serialVersionUID = 4164563358509351832L;
-
- private String id;
-
- private ModalWindow window;
-
- private PageReference callerPageRef;
-
- private Long selectedNodeId = null;
-
- public Builder(final String id) {
- this.id = id;
- }
-
- public GroupSummaryPanel.Builder window(final ModalWindow window) {
- this.window = window;
- return this;
- }
-
- public GroupSummaryPanel.Builder callerPageRef(final PageReference callerPageRef) {
- this.callerPageRef = callerPageRef;
- return this;
- }
-
- public GroupSummaryPanel.Builder selectedNodeId(final Long selectedNodeId) {
- this.selectedNodeId = selectedNodeId;
- return this;
- }
-
- public GroupSummaryPanel build() {
- return new GroupSummaryPanel(this);
- }
- }
-
- private GroupSummaryPanel(final Builder builder) {
- super(builder.id);
-
- if (builder.selectedNodeId == null || builder.selectedNodeId == 0) {
- selectedNode = null;
- } else {
- try {
- selectedNode = restClient.read(builder.selectedNodeId);
- } catch (SyncopeClientException e) {
- LOG.error("Could not read {}", builder.selectedNodeId, e);
- selectedNode = null;
- builder.selectedNodeId = null;
- }
- }
-
- Fragment fragment = new Fragment("groupSummaryPanel",
- builder.selectedNodeId == null
- ? "fakerootFrag"
- : (builder.selectedNodeId == 0 ? "rootPanel" : "groupViewPanel"),
- this);
-
- if (builder.selectedNodeId != null) {
- if (builder.selectedNodeId == 0) {
- @SuppressWarnings("rawtypes")
- final ActionLinksPanel links = new ActionLinksPanel("actionLinks", new Model(), builder.callerPageRef);
- links.setOutputMarkupId(true);
- fragment.add(links);
-
- links.addWithRoles(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- builder.window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new GroupModalPage(builder.callerPageRef, builder.window, new GroupTO());
- }
- });
-
- builder.window.show(target);
- }
- }, ActionLink.ActionType.CREATE, xmlRolesReader.getEntitlement("Groups", "create"));
- } else {
- GroupTabPanel groupTabPanel =
- new GroupTabPanel("nodeViewPanel", selectedNode, builder.window, builder.callerPageRef);
- groupTabPanel.setOutputMarkupId(true);
- fragment.add(groupTabPanel);
- }
- }
- add(fragment);
- }
-
- public GroupTO getSelectedNode() {
- return selectedNode;
- }
-}
[26/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/SecurityQuestionPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SecurityQuestionPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/SecurityQuestionPanel.properties
deleted file mode 100644
index 672fc21..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SecurityQuestionPanel.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-securityQuestion=Security question
-securityAnswer=Security answer
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/SecurityQuestionPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SecurityQuestionPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/SecurityQuestionPanel_it.properties
deleted file mode 100644
index 014f3aa..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SecurityQuestionPanel_it.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-securityQuestion=Domanda di sicurezza
-securityAnswer=Risposta di sicurezza
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/SecurityQuestionPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SecurityQuestionPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/SecurityQuestionPanel_pt_BR.properties
deleted file mode 100644
index 0afcb73..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SecurityQuestionPanel_pt_BR.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-securityQuestion=Pergunta de seguran\u00e7a
-securityAnswer=Resposta de seguran\u00e7a
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/SelectedEventsPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SelectedEventsPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/SelectedEventsPanel.html
deleted file mode 100644
index 3ef0354..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SelectedEventsPanel.html
+++ /dev/null
@@ -1,33 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <style>
- div#selectionContainer select{
- width: 585px;
- min-width: 585px;
- }
- </style>
- </wicket:head>
- <wicket:panel>
- <div id="selectionContainer" wicket:id="selectionContainer">
- <select wicket:id="selectedEvents" ></select>
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/StatusPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/StatusPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/StatusPanel.html
deleted file mode 100644
index e558a61..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/StatusPanel.html
+++ /dev/null
@@ -1,130 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <style>
- div.group{
- width:100%;
- }
-
- div#check{
- height: 25px;
- float:left;
- }
-
- div#resource{
- margin-top: 3px;
- margin-left: 5px;
- width: 35%;
- height: 25px;
- float:left;
- }
-
- div#accountLink{
- margin-top: 3px;
- width:45%;
- height: 25px;
- float:left
- }
-
- div#status{
- margin-top: 3px;
- height: 25px;
- width: 5%;
- float: left;
- text-align: center;
- }
-
- div#connObject{
- margin-top: 3px;
- height: 25px;
- width: 5%;
- float: left;
- text-align: center;
- }
-
- div.assignment {
- display: inline-table;
- width: 100%
- }
-
- div.assignments {
- margin-top: 5px;
- display: inline-table;
- width: 100%;
- border: 1px solid #DDDDDD;
- color: #555555;
- }
- </style>
- </wicket:head>
- <wicket:panel>
- <div class="assignments">
- <div class="group">
- <div>
- <div id="check">
- <input type="checkbox" wicket:id="groupselector" />
- </div>
-
- <div id="resource">
- <span style="font: Verdana,Arial,sans-serif; font-weight: bold">
- <wicket:message key="resourceheader"/>
- </span>
- </div>
- <div id="accountLink">
- <span style="font: Verdana,Arial,sans-serif; font-weight: bold">
- <wicket:message key="accountlinkheader"/>
- </span>
- </div>
- <div id="status">
- <span style="font: Verdana,Arial,sans-serif; font-weight: bold">
- <wicket:message key="statusheader"/>
- </span>
- </div>
- <div id="connObject">
- </div>
- </div>
-
- <span wicket:id="group">
-
- <div wicket:id="resources" class="assignment">
- <div id="check">
- <input type="checkbox" wicket:id="check"/>
- </div>
-
- <div id="resource">
- <span wicket:id="resource">[resource name]</span>
- </div>
- <div id="accountLink">
- <span wicket:id="accountLink">[accountLink]</span>
- </div>
- <div id="status">
- <img wicket:id="icon"/>
- </div>
- <div id="connObject">
- <span wicket:id="connObject">[connObject]</span>
- </div>
- </div>
- </span>
- </div>
-
- </div>
-
- <div wicket:id="connObjectWin">[Show modal window for showing connector object]</div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/StatusPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/StatusPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/StatusPanel.properties
deleted file mode 100644
index e50c7d7..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/StatusPanel.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-resourceheader = Resource
-accountlinkheader = AccountLink
-statusheader = Status
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/StatusPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/StatusPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/StatusPanel_it.properties
deleted file mode 100644
index 6e3e2c4..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/StatusPanel_it.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-resourceheader = Risorsa
-accountlinkheader = AccountLink
-statusheader = Stato
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/StatusPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/StatusPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/StatusPanel_pt_BR.properties
deleted file mode 100644
index 55ab218..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/StatusPanel_pt_BR.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-resourceheader = Recurso
-accountlinkheader = Link da Conta
-statusheader = Estatus
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/SyncTasksPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SyncTasksPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/SyncTasksPanel.properties
deleted file mode 100644
index 497da5a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SyncTasksPanel.properties
+++ /dev/null
@@ -1,29 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Id
-name=Name
-description=Description
-resourceName=Resource Name
-lastExec=Last Execution
-nextExec=Next Execution
-detail=Detail
-delete=Delete
-edit=Edit
-execute=Execute
-executeDryRun=Dry run
-userTemplate=User template
-latestExecStatus=Last status
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/SyncTasksPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SyncTasksPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/SyncTasksPanel_it.properties
deleted file mode 100644
index abb82a4..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SyncTasksPanel_it.properties
+++ /dev/null
@@ -1,29 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Id
-name=Nome
-description=Descrizione
-resourceName=Nome Risorsa
-lastExec=Ultima Esecuzione
-nextExec=Prossima Esecuzione
-detail=Dettagli
-delete=Rimuovi
-edit=Modifica
-execute=Esegui
-executeDryRun=Esecuzione simulata
-userTemplate=Modello utente
-latestExecStatus=Ultimo stato
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/SyncTasksPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SyncTasksPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/SyncTasksPanel_pt_BR.properties
deleted file mode 100644
index 054af39..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SyncTasksPanel_pt_BR.properties
+++ /dev/null
@@ -1,29 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Identificador
-name=Nome
-description=Descri\u00e7\u00e3o
-resourceName=Nome do Recurso
-lastExec=\u00daltima Execu\u00e7\u00e3o
-nextExec=Pr\u00f3xima Execu\u00e7\u00e3o
-detail=Detalhe
-delete=Remove
-edit=Alterar
-execute=Executar
-executeDryRun=Executar (Ensaio)
-userTemplate=Usar Template
-latestExecStatus=\u00daltimo Estatus
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/UserDetailsPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/UserDetailsPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/UserDetailsPanel.html
deleted file mode 100644
index 3f54a1a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/UserDetailsPanel.html
+++ /dev/null
@@ -1,71 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div id="formtable">
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <wicket:message key="username"/>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="username"/>
- <a class="tooltips" wicket:id="usernameQuestionMarkJexlHelp" href="#" alt="Click to help" title="Click to help"><img src="img/help.png"/>
- <span wicket:id="usernameJexlHelp" class="tooltips">
- <wicket:message key="jexl_info"/>
- <ul>
- <li><wicket:message key="jexl_ex1"/></li>
- <li><wicket:message key="jexl_ex2"/></li>
- </ul>
- <a href="#" wicket:id="jexlLink" target="_blank"><wicket:message key="jexl_syntax_url"/></a>
- </span>
- </a>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <wicket:message key="password"/>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="password"/>
- <span wicket:id="mandatory_pwd"></span>
- <a class="tooltips" wicket:id="pwdQuestionMarkJexlHelp" href="#" alt="Click to help" title="Click to help">
- <img src="img/help.png"/>
- <span wicket:id="pwdJexlHelp" class="tooltips">
- <wicket:message key="jexl_info"/>
- <ul>
- <li><wicket:message key="jexl_ex1"/></li>
- <li><wicket:message key="jexl_ex2"/></li>
- </ul>
- <a href="#" wicket:id="jexlLink" target="_blank"><wicket:message key="jexl_syntax_url"/></a>
- </span>
- </a>
- </div>
- </div>
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <span wicket:id="confirmPasswordLabel"/>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="confirmPassword"/>
- </div>
- </div>
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/UserDetailsPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/UserDetailsPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/UserDetailsPanel.properties
deleted file mode 100644
index f07fe03..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/UserDetailsPanel.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-username=Username
-password=Password
-confirmPassword=Password (confirm)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/UserDetailsPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/UserDetailsPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/UserDetailsPanel_it.properties
deleted file mode 100644
index 741d7dd..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/UserDetailsPanel_it.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-username=Username
-password=Password
-confirmPassword=Password (conferma)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/UserDetailsPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/UserDetailsPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/UserDetailsPanel_pt_BR.properties
deleted file mode 100644
index 9debd26..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/UserDetailsPanel_pt_BR.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-username=Nome do Usu\u00E1rio
-password=Senha
-confirmPassword=Senha (confirmar)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/VirAttrsPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/VirAttrsPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/VirAttrsPanel.html
deleted file mode 100644
index 5b3454e..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/VirAttrsPanel.html
+++ /dev/null
@@ -1,60 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <table class="ui-widget ui-widget-content ui-corner-all"
- style="font-size: 1em;margin-top:2px;"
- width="100%" cellpadding="2px" cellspacing="1px">
- <thead>
- <tr class="ui-widget-header">
- <th><wicket:message key="virAttrToRemove"/></th>
- <th><wicket:message key="virAttrName"/></th>
- <th><wicket:message key="virAttrValue"/></th>
- </tr>
- </thead>
-
- <tfoot>
- <tr>
- <td>
- <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="addAttributeBtn" />
- </td>
- </tr>
- </tfoot>
-
- <tbody wicket:id="virAttrContainer">
- <tr wicket:id="attrs">
- <td align="center" valign="top">
- <input type="checkbox" class="text ui-widget-content ui-corner-all" wicket:id="toRemove"/>
- </td>
-
- <td align="center" valign="top">
- <select class="text ui-widget-content ui-corner-all"
- style="width:100%" wicket:id="schema"/>
- </td>
-
- <td align="center " valign="top">
- <span wicket:id="values" style="text-align:left;display:block;width:95%">[values]</span>
- </td>
-
- </tr>
- </tbody>
- </table>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/VirAttrsPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/VirAttrsPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/VirAttrsPanel.properties
deleted file mode 100644
index 4f686f7..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/VirAttrsPanel.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-addAttributeBtn=Add
-add=+
-drop=-
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/VirAttrsPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/VirAttrsPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/VirAttrsPanel_it.properties
deleted file mode 100644
index f639bf5..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/VirAttrsPanel_it.properties
+++ /dev/null
@@ -1,20 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-addAttributeBtn=Aggiungi
-add=+
-drop=-
-
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/VirAttrsPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/VirAttrsPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/VirAttrsPanel_pt_BR.properties
deleted file mode 100644
index bde1908..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/VirAttrsPanel_pt_BR.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-addAttributeBtn=Adicionar
-add=+
-drop=-
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxGroupSelectorPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxGroupSelectorPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxGroupSelectorPanel.html
deleted file mode 100644
index fde1840..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxGroupSelectorPanel.html
+++ /dev/null
@@ -1,21 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<wicket:panel>
- <input wicket:id="groupselector" type="checkbox"/>
-</wicket:panel>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxPanel.html
deleted file mode 100644
index 23156a2..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CheckBoxPanel.html
+++ /dev/null
@@ -1,23 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <input wicket:id="check" type="checkbox"/>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPanel.html
deleted file mode 100644
index 56220a9..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/extensions/markup/html/repeater/data/table/CollectionPanel.html
+++ /dev/null
@@ -1,25 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div id="collection" wicket:id="collection">
- <span id="item" wicket:id="item"/>
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer.properties b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer.properties
deleted file mode 100644
index d41c779..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-selOpt1=Unschedule
-selOpt2=Every 5 minutes
-selOpt3=Fire at 12pm (noon) every day
-selOpt4=Fire at 12am (midnight) every first day of the month
-selOpt5=Fire at 12am (midnight) every last day of the month
-selOpt6=Fire at 12am (midnight) every Monday
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer_it.properties
deleted file mode 100644
index 5514ce9..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer_it.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-selOpt1=Non schedulato
-selOpt2=Ogni 5 minuti
-selOpt3=Lanciato ogni giorno a mezzanotte
-selOpt4=Lanciato ogni primo giorno del mese a mezzogiorno
-selOpt5=Lanciato ogni ultimo giorno del mese a mezzogiorno
-selOpt6=Lanciato ogni Luned\u00ec a mezzogiorno
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer_pt_BR.properties
deleted file mode 100644
index f621f92..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/CrontabContainer_pt_BR.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-selOpt1=N\u00E3o Agendado
-selOpt2=A cada 5 minutos
-selOpt3=Acionar \u00E0s 12\:00 todos os dias
-selOpt4=Acionar \u00E0s 24\:00 sempre no primeiro dia de cada m\u00EAs
-selOpt5=Acionar \u00E0s 24\:00 sempre no \u00FAltimo dia de cada m\u00EAs
-selOpt6=Acionar \u00E0s 24\:00 de toda Segunda Feira
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/ActionLinksPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/ActionLinksPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/ActionLinksPanel.html
deleted file mode 100644
index a09d453..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/ActionLinksPanel.html
+++ /dev/null
@@ -1,163 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <style>
- span#actionLink{
- margin-left: 1px;
- margin-right: 1px;
- }
- </style>
- </wicket:head>
- <wicket:panel>
- <span wicket:id="panelClaim">[plus]</span>
- <span wicket:id="panelManageResources">[plus]</span>
- <span wicket:id="panelManageUsers">[plus]</span>
- <span wicket:id="panelManageGroups">[plus]</span>
- <span wicket:id="panelDryRun">[plus]</span>
- <span wicket:id="panelExecute">[plus]</span>
- <span wicket:id="panelEnable">[plus]</span>
- <span wicket:id="panelSearch">[plus]</span>
- <span wicket:id="panelCreate">[plus]</span>
- <span wicket:id="panelUserTemplate">[plus]</span>
- <span wicket:id="panelGroupTemplate">[plus]</span>
- <span wicket:id="panelReset">[plus]</span>
- <span wicket:id="panelEdit">[plus]</span>
- <span wicket:id="panelExport">[plus]</span>
- <span wicket:id="panelDelete">[plus]</span>
- <span wicket:id="panelSelect">[plus]</span>
- <span wicket:id="panelSuspend">[plus]</span>
- <span wicket:id="panelReactivate">[plus]</span>
- <span wicket:id="panelReload">[plus]</span>
- <span wicket:id="panelChangeView">[plus]</span>
- <span wicket:id="panelUnlink">[plus]</span>
- <span wicket:id="panelLink">[plus]</span>
- <span wicket:id="panelUnassign">[plus]</span>
- <span wicket:id="panelAssign">[plus]</span>
- <span wicket:id="panelDeprovision">[plus]</span>
- <span wicket:id="panelProvision">[plus]</span>
-
- <wicket:fragment wicket:id="fragmentClaim">
- <a href="#" wicket:id="claimLink"><img id="actionLink" src="img/actions/claim.png" alt="claim icon" title="Claim"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentManageResources">
- <a href="#" wicket:id="manageResourcesLink"><img id="actionLink" src="img/actions/resources-icon.png" alt="manage resources icon" title="Manage resources"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentManageUsers">
- <a href="#" wicket:id="manageUsersLink"><img id="actionLink" src="img/actions/users-icon.png" alt="manage users icon" title="Manage users"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentManageGroups">
- <a href="#" wicket:id="manageGroupsLink"><img id="actionLink" src="img/actions/groups-icon.png" alt="manage groups icon" title="Manage groups"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentCreate">
- <a href="#" wicket:id="createLink"><img id="actionLink" src="img/actions/create.png" alt="create icon" title="Create"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentSearch">
- <a href="#" wicket:id="searchLink"><img id="actionLink" src="img/actions/search.png" alt="search icon" title="Search and modify"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentEnable">
- <a href="#" wicket:id="enableLink"><img id="actionLink" src="img/actions/enable.png" alt="enable icon" title="Enable / Disable"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentEdit">
- <a href="#" wicket:id="editLink"><img id="actionLink" src="img/actions/edit.png" alt="edit icon" title="Edit"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentReset">
- <a href="#" wicket:id="resetLink"><img id="actionLink" src="img/actions/reset.png" alt="reset icon" title="Reset sync token"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentUserTemplate">
- <a href="#" wicket:id="userTemplateLink"><img id="actionLink" src="img/actions/user_template.png" alt="user template icon" title="Specify user template"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentGroupTemplate">
- <a href="#" wicket:id="groupTemplateLink"><img id="actionLink" src="img/actions/groups-icon.png" alt="group template icon" title="Specify group template"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentDelete">
- <a href="#" wicket:id="deleteLink"><img id="actionLink" src="img/actions/delete.png" alt="delete icon" title="Delete"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentDryRun">
- <a href="#" wicket:id="dryRunLink"><img id="actionLink" src="img/actions/dryrun.png" alt="dryrun icon" title="DryRun"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentExecute">
- <a href="#" wicket:id="executeLink"><img id="actionLink" src="img/actions/execute.png" alt="execute icon" title="Execute"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentSelect">
- <a href="#" wicket:id="selectLink"><img id="actionLink" src="img/actions/select.png" alt="select icon" title="Select"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentExport">
- <a href="#" wicket:id="exportLink"><img id="actionLink" src="img/actions/export.png" alt="export icon" title="Export"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentSuspend">
- <a href="#" wicket:id="suspendLink"><img id="actionLink" src="img/actions/suspend.png" alt="suspend icon" title="Suspend"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentReactivate">
- <a href="#" wicket:id="reactivateLink"><img id="actionLink" src="img/actions/reactivate.png" alt="reactivate icon" title="Reactivate"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentReload">
- <a href="#" wicket:id="reloadLink"><img id="actionLink" src="img/actions/reload.png" alt="reload icon" title="Reload"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentChangeView">
- <a href="#" wicket:id="changeViewLink"><img id="actionLink" src="img/actions/settings-icon.png" alt="Change view icon" title="Change view"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentUnlink">
- <a href="#" wicket:id="unlinkLink"><img id="actionLink" src="img/actions/unlink-icon.png" alt="Unlink icon" title="Unlink"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentLink">
- <a href="#" wicket:id="linkLink"><img id="actionLink" src="img/actions/link-icon.png" alt="Link icon" title="Link"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentUnassign">
- <a href="#" wicket:id="unassignLink"><img id="actionLink" src="img/actions/unassign-icon.png" alt="Unassign icon" title="Unassign"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentAssign">
- <a href="#" wicket:id="assignLink"><img id="actionLink" src="img/actions/assign-icon.png" alt="Assign icon" title="Assign"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentDeprovision">
- <a href="#" wicket:id="deprovisionLink"><img id="actionLink" src="img/actions/deprovision-icon.png" alt="De-provision icon" title="De-provision"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fragmentProvision">
- <a href="#" wicket:id="provisionLink"><img id="actionLink" src="img/actions/provision-icon.png" alt="Provision icon" title="Provision"/></a>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="emptyFragment">
- </wicket:fragment>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxCheckBoxPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxCheckBoxPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxCheckBoxPanel.html
deleted file mode 100644
index fc7596f..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxCheckBoxPanel.html
+++ /dev/null
@@ -1,21 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<wicket:extend>
- <input type="checkbox" class="checkbox" wicket:id="checkboxField"/>
-</wicket:extend>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxDropDownChoicePanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxDropDownChoicePanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxDropDownChoicePanel.html
deleted file mode 100644
index 12d5bf2..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxDropDownChoicePanel.html
+++ /dev/null
@@ -1,24 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <select class="ui-widget-content ui-corner-all medium_dynamicsize"
- wicket:id="dropDownChoiceField" />
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxNumberFieldPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxNumberFieldPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxNumberFieldPanel.html
deleted file mode 100644
index 3a719d1..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxNumberFieldPanel.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<wicket:extend>
- <input type="text" class="ui-widget-content ui-corner-all medium_dynamicsize"
- wicket:id="numberField" />
-</wicket:extend>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPalettePanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPalettePanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPalettePanel.html
deleted file mode 100644
index 1833140..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPalettePanel.html
+++ /dev/null
@@ -1,23 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <span wicket:id="paletteField">[Palette]</span>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPasswordFieldPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPasswordFieldPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPasswordFieldPanel.html
deleted file mode 100644
index 1f7b8f3..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPasswordFieldPanel.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<wicket:extend>
- <input type="password" class="ui-widget-content ui-corner-all long_dynamicsize"
- wicket:id="passwordField" />
-</wicket:extend>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxTextFieldPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxTextFieldPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxTextFieldPanel.html
deleted file mode 100644
index e6f1d7c..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/AjaxTextFieldPanel.html
+++ /dev/null
@@ -1,23 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <input type="text" class="ui-widget-content ui-corner-all long_dynamicsize" wicket:id="textField"/>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/BinaryFieldPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/BinaryFieldPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/BinaryFieldPanel.html
deleted file mode 100644
index 6b2556f..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/BinaryFieldPanel.html
+++ /dev/null
@@ -1,44 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <input style="display: none;" wicket:id="textField"/>
- <span style="margin-right: 20px;">
- <div style="display: table-cell;">
- <form wicket:id="uploadForm" encType="multipart/form-data" method="post" accept-charset="UTF-8">
- <input wicket:id="fileUpload" type="file"/>
- <div style="top: -25px; left: 100%; position: relative; vertical-align: middle;">
- <a href="#" wicket:id="uploadLink"><img src="img/file-upload.png" alt="upload" title="upload" style="vertical-align: middle;"/></a>
- <a href="#" wicket:id="downloadLink"><img src="img/file-download.png" alt="download" title="download" style="vertical-align: middle;"/></a>
- <a href="#" wicket:id="resetLink"><img src="img/disable.png" alt="disable" title="remove value" style="vertical-align: middle;"/></a>
- <span wicket:id="preview"/>
- </div>
- <span wicket:id="previewContainer">
- <span wicket:id="panelPreview">[panelPreview]</span>
- <wicket:fragment wicket:id="previewFragment">
- <div wicket:id = "previewer" class="ui-widget-content ui-corner-all"></div>
- </wicket:fragment>
- <wicket:fragment wicket:id="emptyFragment">
- </wicket:fragment>
- </span>
- </form>
- </div>
- </span>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/CheckBoxMultipleChoiceFieldPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/CheckBoxMultipleChoiceFieldPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/CheckBoxMultipleChoiceFieldPanel.html
deleted file mode 100644
index 52f1da9..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/CheckBoxMultipleChoiceFieldPanel.html
+++ /dev/null
@@ -1,23 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html>
- <wicket:panel>
- <span wicket:id="checkBoxMultipleChoice" />
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTextFieldPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTextFieldPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTextFieldPanel.html
deleted file mode 100644
index caaf991..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTextFieldPanel.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<wicket:extend>
- <input type="text" class="text ui-widget-content ui-corner-all date_size"
- wicket:id="field"/>
-</wicket:extend>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel.html
deleted file mode 100644
index e3a191b..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel.html
+++ /dev/null
@@ -1,21 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<wicket:extend>
- <span wicket:id="field"/>
-</wicket:extend>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel.properties
deleted file mode 100644
index 9a39f4c..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-field.DateTimeFieldPanel$DateTimeFormValidator=Field '${label0}' must be fully valued
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel_it.properties
deleted file mode 100644
index c524834..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel_it.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-field.DateTimeFieldPanel$DateTimeFormValidator=Il campo '${label0}' dev'essere completamente valorizzato
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel_pt_BR.properties
deleted file mode 100644
index 95be437..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/DateTimeFieldPanel_pt_BR.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-field.DateTimeFieldPanel$DateTimeFormValidator=Campo'${label0}' precisa ser preenchido
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/FieldPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/FieldPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/FieldPanel.html
deleted file mode 100644
index 55a77e1..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/FieldPanel.html
+++ /dev/null
@@ -1,34 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head></wicket:head>
- <wicket:panel>
-
- <wicket:fragment wicket:id="requiredFragment">
- <span wicket:id="requiredLabel"/>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="notRequiredFragment">
- </wicket:fragment>
-
- <wicket:child />
-
- <span wicket:id="required"/>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/LinkPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/LinkPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/LinkPanel.html
deleted file mode 100644
index c4b75f0..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/LinkPanel.html
+++ /dev/null
@@ -1,23 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<wicket:panel>
- <a href="#" wicket:id="link">
- <span wicket:id="linkTitle"/>
- </a>
-</wicket:panel>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MappingPurposePanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MappingPurposePanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MappingPurposePanel.html
deleted file mode 100644
index 963a087..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MappingPurposePanel.html
+++ /dev/null
@@ -1,31 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
-
- <a href="#" wicket:id="propagationPurposeLink"><img id="action" src="img/actions/propagation-icon.png" alt="Propagation icon" title="Propagation"/></a>
-
- <a href="#" wicket:id="synchronizationPurposeLink"><img id="action" src="img/actions/synchronization-icon.png" alt="Synchronization icon" title="Synchronization"/></a>
-
- <a href="#" wicket:id="bothPurposeLink"><img id="action" src="img/actions/both-icon.png" alt="Both icon" title="Both"/></a>
-
- <a href="#" wicket:id="nonePurposeLink"><img id="action" src="img/actions/none-icon.png" alt="None icon" title="None"/></a>
-
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel.html
deleted file mode 100644
index 2208220..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel.html
+++ /dev/null
@@ -1,35 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <span wicket:id="multiValueContainer">
- <span wicket:id="view">
- <span wicket:id="panel">[form field]</span>
- <a wicket:id="drop"><img src="img/minus-icon.png" alt="remove icon" class="drop_button" /></a>
- <span wicket:id="panelPlus">[plus]</span>
- <br />
- </span>
- <wicket:fragment wicket:id="fragmentPlus">
- <a wicket:id="add"><img src="img/plus-icon.png" alt="add icon" class="add_button" /></a>
- </wicket:fragment>
- <wicket:fragment wicket:id="emptyFragment">
- </wicket:fragment>
- </span>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel.properties
deleted file mode 100644
index 958e9e0..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-minLength=Minimum password size
-maxLength=Maximum password size
-historyLength=Password history length
-digitRequired=Password must contain one or more digits
-prefixesNotPermitted=Password prefixes not permitted
-apply=Save
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel_it.properties
deleted file mode 100644
index 398d634..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel_it.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-minLength=Lunghezza minima password
-maxLength=Lunghezza massima password
-historyLength=Lunghezza storico password
-digitRequired=La password deve contenere uno o pi\u00f9 numeri
-prefixesNotPermitted=Prefissi password non permessi
-apply=Salva
\ No newline at end of file
[05/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Configuration.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Configuration.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Configuration.html
new file mode 100644
index 0000000..58a0241
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Configuration.html
@@ -0,0 +1,230 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:head>
+ <script type="text/javascript">
+ $(document).ready(function () {
+ $("#policies").tabs();
+ $("#logs").tabs();
+ $("#layouts").tabs();
+ });
+ </script>
+ </wicket:head>
+
+ <wicket:extend>
+
+ <div id="tabs">
+ <ul>
+ <li class="tabs-selected">
+ <a href="#layouts"><span><wicket:message key="layouts"/></span></a>
+ </li>
+ <li><a href="#policies"><span><wicket:message key="policies"/></span></a></li>
+ <li><a href="#notifications"><span><wicket:message key="notifications"/></span></a></li>
+ <li><a href="#securityQuestions"><span><wicket:message key="securityQuestions"/></span></a></li>
+ <li><a href="#workflow"><span><wicket:message key="workflow"/></span></a></li>
+ <li><a href="#logs"><span><wicket:message key="logs"/></span></a></li>
+ <li><a href="#ext"><span><wicket:message key="ext"/></span></a></li>
+ </ul>
+ <div id="layouts">
+ <ul>
+ <li class="tabs-selected">
+ <a href="#adminUser"><span><wicket:message key="adminUser"/></span></a>
+ </li>
+ <li><a href="#selfUser"><span><wicket:message key="selfUser"/></span></a></li>
+ <li><a href="#adminGroup"><span><wicket:message key="adminGroup"/></span></a></li>
+ <li><a href="#selfGroup"><span><wicket:message key="selfGroup"/></span></a></li>
+ <li><a href="#adminMembership"><span><wicket:message key="adminMembership"/></span></a></li>
+ <li><a href="#selfMembership"><span><wicket:message key="selfMembership"/></span></a></li>
+ </ul>
+ <div id="adminUser" style="border-width: 1px;border-top-width: 0px;">
+ <span wicket:id="adminUserLayoutPanel">[admin user layout panel]</span>
+ </div>
+ <div id="selfUser" style="border-width: 1px;border-top-width: 0px;">
+ <span wicket:id="selfUserLayoutPanel">[self user layout panel]</span>
+ </div>
+ <div id="adminGroup" style="border-width: 1px;border-top-width: 0px;">
+ <span wicket:id="adminGroupLayoutPanel">[admin group layout panel]</span>
+ </div>
+ <div id="selfGroup" style="border-width: 1px;border-top-width: 0px;">
+ <span wicket:id="selfGroupLayoutPanel">[self group layout panel]</span>
+ </div>
+ <div id="adminMembership" style="border-width: 1px;border-top-width: 0px;">
+ <span wicket:id="adminMembershipLayoutPanel">[admin membership layout panel]</span>
+ </div>
+ <div id="selfMembership" style="border-width: 1px;border-top-width: 0px;">
+ <span wicket:id="selfMembershipLayoutPanel">[self membership layout panel]</span>
+ </div>
+ </div>
+ <div id="policies">
+ <ul>
+ <li class="tabs-selected">
+ <a href="#account"><span><wicket:message key="account"/></span></a>
+ </li>
+ <li><a href="#password"><span><wicket:message key="password"/></span></a></li>
+ <li><a href="#sync"><span><wicket:message key="sync"/></span></a></li>
+ </ul>
+ <div id="account" style="border-width: 1px;border-top-width: 0px;">
+ <span wicket:id="accountPoliciesPanel">[account policies]</span>
+ </div>
+ <div id="password" style="border-width: 1px;border-top-width: 0px;">
+ <span wicket:id="passwordPoliciesPanel">[password policies]</span>
+ </div>
+ <div id="sync" style="border-width: 1px;border-top-width: 0px;">
+ <span wicket:id="syncPoliciesPanel">[sync policies]</span>
+ </div>
+ </div>
+ <div id="notifications">
+ <div id="users-contain" class="ui-widget" style="width:inherit">
+ <span wicket:id="notificationContainer">
+ <table class="ui-widget ui-widget-content table-hover"
+ wicket:id="notificationTable"/>
+ </span>
+
+ <span style="float:right">
+ <form wicket:id="notificationPaginatorForm" style="display:inline">
+ <label><wicket:message key="displayRows"/></label>
+ <select class="text ui-widget-content ui-corner-all"
+ wicket:id="rowsChooser"/>
+ </form>
+ </span>
+ </div>
+
+ <div wicket:id="createNotificationWin">[Show modal window for creating notification]</div>
+ <div wicket:id="editNotificationWin">[Show modal window for editing notification]</div>
+
+ <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="createNotificationLink">
+ <wicket:message key="create"/>
+ </a>
+ </div>
+ <div id="securityQuestions">
+ <div id="users-contain" class="ui-widget" style="width:inherit">
+ <span wicket:id="securityQuestionContainer">
+ <table class="ui-widget ui-widget-content table-hover"
+ wicket:id="securityQuestionTable"/>
+ </span>
+ </div>
+
+ <div wicket:id="createSecurityQuestionWin">[Show modal window for creating security questions]</div>
+ <div wicket:id="editSecurityQuestionWin">[Show modal window for editing security questions]</div>
+
+ <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="createSecurityQuestionLink">
+ <wicket:message key="create"/>
+ </a>
+ </div>
+ <div id="workflow">
+ <div id="users-contain" class="ui-widget" style="width:inherit">
+ <span wicket:id="noActivitiEnabledForUsers"><i><wicket:message key="noActivitiEnabledForUsers"/></i></span>
+ <span wicket:id="workflowDefContainer">
+ <div style="float: left;">
+ <button wicket:id="activitiModeler" style="width: 122px">
+ <div style="display: table-row;">
+ <div style="display: table-cell">
+ <img src="img/modeler.png" alt="Activiti Modeler" title="Activiti Modeler"/>
+ </div>
+ <div style="display: table-cell;vertical-align:middle;font-size:62.5%;">
+ Activiti Modeler
+ </div>
+ </div>
+ </button>
+ </div>
+ <div>
+ <button wicket:id="xmlEditor" style="width: 122px">
+ <div style="display: table-row;">
+ <div style="display: table-cell">
+ <img src="img/xml.png" alt="XML editor" title="XML editor"/>
+ </div>
+ <div style="display: table-cell;vertical-align:middle;font-size:62.5%;">
+ XML editor
+ </div>
+ </div>
+ </button>
+ </div>
+ <img wicket:id="workflowDefDiagram" style="width: 100%;"/>
+ </span>
+ </div>
+ </div>
+ <div id="logs">
+ <ul>
+ <li class="tabs-selected">
+ <a href="#core"><span>Core</span></a>
+ </li>
+ <li><a href="#console"><span>Console</span></a></li>
+ </ul>
+ <div id="core" style="border-width: 1px;border-top-width: 0px;">
+ <div id="users-contain" class="ui-widget" style="width:inherit">
+ <span wicket:id="coreLoggerContainer">
+ <table class="ui-widget ui-widget-content table-hover">
+ <thead class="ui-widget-header">
+ <tr class="heaaders">
+ <th><wicket:message key="logger"/></th>
+ <th><wicket:message key="level"/></th>
+ </tr>
+ </thead>
+ <tbody>
+ <tr wicket:id="corelogger">
+ <td><span wicket:id="key"/></td>
+ <td id="level"><select wicket:id="level"/></td>
+ </tr>
+ </tbody>
+ </table>
+ </span>
+ </div>
+ </div>
+ <div id="console" style="border-width: 1px;border-top-width: 0px;">
+ <div id="users-contain" class="ui-widget" style="width:inherit">
+ <span wicket:id="consoleLoggerContainer">
+ <table class="ui-widget ui-widget-content table-hover">
+ <thead class="ui-widget-header">
+ <tr class="heaaders">
+ <th><wicket:message key="logger"/></th>
+ <th><wicket:message key="level"/></th>
+ </tr>
+ </thead>
+ <tbody>
+ <tr wicket:id="consolelogger">
+ <td><span wicket:id="key"/></td>
+ <td id="level"><select wicket:id="level"/></td>
+ </tr>
+ </tbody>
+ </table>
+ </span>
+ </div>
+ </div>
+ </div>
+ <div id="ext" wicket:id="extPanels">
+ </div>
+ <div>
+ <div wicket:id="parameters">
+ <a style="position: absolute; top: 2px; right:50px;" wicket:id="confLink">
+ <img src="img/actions/settings-icon.png" width="30" height="30"
+ alt="Parameters" title="title" wicket:message="title:parameters"/>
+ </a>
+ </div>
+ <div wicket:id="syncopeConfWin">[Show modal window for conf parameters]</div>
+
+ <a style="position: absolute; top: 2px; right:20px;" wicket:id="dbExportLink">
+ <img src="img/db_export.png" width="30" height="30"
+ alt="DB export" title="title" wicket:message="title:db_export"/>
+ </a>
+ </div>
+ </div>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Configuration.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Configuration.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Configuration.properties
new file mode 100644
index 0000000..dea3e78
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Configuration.properties
@@ -0,0 +1,48 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+parameters=Parameters
+password=Password
+account=Account
+sync=Synchronization
+notifications=Notifications
+workflow=Workflow
+coreLog=Core Log
+consoleLog=Console Log
+edit=Edit
+delete=Delete
+db_export=DB export
+logger=Logger
+level=Level
+events=Events
+template=Template
+traceLevel=Trace level
+subject=Subject
+noActivitiEnabledForUsers=Activiti not enabled for users
+policies=Policies
+logs=Logs
+active=Enabled
+apply=Save
+securityQuestions=Security Questions
+content=Text
+layouts=Layouts
+adminUser=Administrator User Form
+selfUser=Self User Form
+adminGroup=Administrator Group Form
+selfGroup=Self Group Form
+adminMembership=Administrator Membership Form
+selfMembership=Self Membership Form
+ext=Extensions
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Configuration_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Configuration_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Configuration_it.properties
new file mode 100644
index 0000000..36140b2
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Configuration_it.properties
@@ -0,0 +1,48 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+parameters=Parametri
+password=Password
+account=Account
+sync=Sincronizzazione
+notifications=Notifiche
+workflow=Workflow
+coreLog=Log Core
+consoleLog=Log Console
+edit=Modifica
+delete=Rimuovi
+db_export=Esportazione DB
+logger=Logger
+level=Livello
+events=Eventi
+template=Modello
+traceLevel=Tracciamento
+subject=Oggetto
+noActivitiEnabledForUsers=Activiti non configurato per gli utenti
+policies=Politiche
+logs=Logs
+active=Abilitata
+apply=Salva
+securityQuestions=Domande di sicurezza
+content=Testo
+layouts=Layouts
+adminUser=Form Amministrazione Utente
+selfUser=Form Utente
+adminGroup=Form Amministrazione Gruppo
+selfGroup=Form Gruppo
+adminMembership=Form Amministrazione Membership
+selfMembership=Form Membership
+ext=Estensioni
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Configuration_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Configuration_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Configuration_pt_BR.properties
new file mode 100644
index 0000000..a39ea61
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Configuration_pt_BR.properties
@@ -0,0 +1,48 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+parameters=Par\u00e2metros
+password=Senha
+account=Conta
+sync=Sincroniza\u00e7\u00e3o
+notifications=Notifica\u00e7\u00f5es
+workflow=Fluxo de Trabalho
+coreLog=Log Central
+consoleLog=Log do Console
+edit=Editar
+delete=Excluir
+db_export=Exportar Banco de Dados
+logger=Logger
+level=N\u00edvel
+events=Eventos
+template=Template
+traceLevel=N\u00edvel de Trace
+subject=Assunto
+noActivitiEnabledForUsers=Activiti n\u00e3o habilitado para usu\u00e1rios
+policies=Pol\u00edticas
+logs=Logs
+active=Ativada
+apply=Salvar
+securityQuestions=Quest\u00f5es de seguran\u00e7a
+content=Texto
+layouts=Layouts
+adminUser=Forma do usu\u00e1rio de administra\u00e7\u00e3o
+selfUser=Forma Usu\u00e1rio
+adminGroup=Forma de grupo de administra\u00e7\u00e3o
+selfGroup=Form Grupo
+adminMembership=Forma de membro de administra\u00e7\u00e3o
+selfMembership=Forma Membro
+ext=Extens\u00f5es
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.html
new file mode 100644
index 0000000..2471b30
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.html
@@ -0,0 +1,55 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <div>
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+ <form wicket:id="form">
+ <div id="formtable">
+ <div class="tablerow alt">
+ <div class="tablecolumn_label medium_fixedsize">
+ <label for="password"><wicket:message key="password"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="password">[password]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label medium_fixedsize">
+ <label for="confirmPassword"><wicket:message key="confirmPassword"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="confirmPassword">[confirmPassword]</span>
+ </div>
+ </div>
+ </div>
+
+ <div style="margin: 20px 10px 0">
+ <input type="submit"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="apply"/>
+ <input type="button"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="cancel"/>
+ </div>
+ </form>
+ </div>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.properties
new file mode 100644
index 0000000..eb8d9f6
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage.properties
@@ -0,0 +1,20 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Password reset
+submit=Submit
+password=Password
+confirmPassword=Password (confirm)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage_it.properties
new file mode 100644
index 0000000..2254365
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage_it.properties
@@ -0,0 +1,20 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Password smarrita
+submit=Invia
+password=Password
+confirmPassword=Password (conferma)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage_pt_BR.properties
new file mode 100644
index 0000000..fa270b9
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfirmPasswordResetModalPage_pt_BR.properties
@@ -0,0 +1,20 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Redefini\u00e7\u00e3o de senha
+submit=Apresentar
+password=Senha
+confirmPassword=Senha (confirmar)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage.html
new file mode 100644
index 0000000..e6d4676
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage.html
@@ -0,0 +1,39 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+
+ <div style="margin: 5px;">
+ <form wicket:id="form">
+ <div id="formtable">
+ <div class="tablerow" wicket:id="propView">
+ <div class="tablecolumn_label medium_dynamicsize">
+ <span wicket:id="key">[key]</span>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="value">[value]</span>
+
+ </div>
+ </div>
+ </div>
+ </form>
+ </div>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage.properties
new file mode 100644
index 0000000..109326f
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage.properties
@@ -0,0 +1,17 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Resource data
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage_it.properties
new file mode 100644
index 0000000..0f4f94f
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage_it.properties
@@ -0,0 +1,17 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Dati sulla risorsa
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage_pt_BR.properties
new file mode 100644
index 0000000..daca223
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnObjectModalPage_pt_BR.properties
@@ -0,0 +1,17 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Dados do Recurso
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage.html
new file mode 100644
index 0000000..b85acb6
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage.html
@@ -0,0 +1,161 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <p class="ui-widget ui-corner-all ui-widget-header">
+ <span wicket:id="new"/> <wicket:message key="title"/> <span wicket:id="key"/>
+ </p>
+ <div style="margin: 5px;">
+ <form wicket:id="form">
+ <div id="tabs">
+ <ul>
+ <li class="tabs-selected"><a href="#tabs-1"><span><wicket:message key="tab1"/></span></a></li>
+ <li><a href="#tabs-2"><span><wicket:message key="tab2"/></span></a></li>
+ <li><a href="#tabs-3"><span><wicket:message key="tab3"/></span></a></li>
+ </ul>
+ <div id="tabs-1">
+ <div id="formtable">
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="displayName"><wicket:message key="displayName"/></label>
+ </div>
+ <div class="tablecolumn_field short_dynamicsize">
+ <span wicket:id="displayName">[displayName]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="location"><wicket:message key="location"/></label>
+ </div>
+ <div class="tablecolumn_field short_dynamicsize">
+ <span wicket:id="location">[location]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="name"><wicket:message key="name"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="connectorName">[connectorName]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="version"><wicket:message key="version"/></label>
+ </div>
+ <div class="tablecolumn_field short_dynamicsize">
+ <span wicket:id="version">[version]</span>
+ </div>
+ </div>
+ </div>
+ <div style="display: table; border: 1px solid #BBBBBB;">
+ <div class="tablerow2 alt">
+ <div class="tablecolumn2_label short_dynamicsize">
+ <label for="connRequestTimeout"><wicket:message key="connRequestTimeout"/></label>
+ </div>
+ <div class="tablecolumn2_field short_dynamicsize">
+ <span wicket:id="connRequestTimeout">[connRequestTimeout]</span>
+ </div>
+ <div class="tablecolumn2_label short_dynamicsize">
+ <label for="poolMaxObjects"><wicket:message key="poolMaxObjects"/></label>
+ </div>
+ <div class="tablecolumn2_field short_dynamicsize">
+ <span wicket:id="poolMaxObjects">[poolMaxObjects]</span>
+ </div>
+ </div>
+ <div class="tablerow2">
+ <div class="tablecolumn2_label short_dynamicsize">
+ <label for="poolMinIdle"><wicket:message key="poolMinIdle"/></label>
+ </div>
+ <div class="tablecolumn2_field short_dynamicsize">
+ <span wicket:id="poolMinIdle">[poolMinIdle]</span>
+ </div>
+ <div class="tablecolumn2_label short_dynamicsize">
+ <label for="poolMaxIdle"><wicket:message key="poolMaxIdle"/></label>
+ </div>
+ <div class="tablecolumn2_field short_dynamicsize">
+ <span wicket:id="poolMaxIdle">[poolMaxIdle]</span>
+ </div>
+ </div>
+ <div class="tablerow2 alt">
+ <div class="tablecolumn2_label short_dynamicsize">
+ <label for="poolMaxWait"><wicket:message key="poolMaxWait"/></label>
+ </div>
+ <div class="tablecolumn2_field short_dynamicsize">
+ <span wicket:id="poolMaxWait">[poolMaxWait]</span>
+ </div>
+ <div class="tablecolumn2_label short_dynamicsize">
+ <label for="poolMinEvictableIdleTime"><wicket:message key="poolMinEvictableIdleTime"/></label>
+ </div>
+ <div class="tablecolumn2_field short_dynamicsize">
+ <span wicket:id="poolMinEvictableIdleTime">[poolMinEvictableIdleTime]</span>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div id="tabs-2">
+ <div id="formtable">
+ <span wicket:id="container">
+ <div style="border-bottom: 10px">
+ <div style="width: 40px; text-align: center; font-size: 7px">
+ <label for="version"><wicket:message key="overridable"/></label>
+ </div>
+ </div>
+ <form wicket:id="connectorPropForm">
+ <div class="tablerow connectorProp" wicket:id="connectorProperties">
+ <div class="tablecolumn_check" style="width: 27px; text-align: center; margin-right: 10px">
+ <span wicket:id="connPropAttrOverridable">[connPropAttrOverridable]</span>
+ </div>
+ <div class="tablecolumn_connPropAttr">
+ <span wicket:id="connPropAttrSchema">[connPropAttrSchema]</span>
+ </div>
+ <div class="tablecolumn_field veryshort_fixedsize">
+ <span wicket:id="panel">[panel]</span>
+ </div>
+ </div>
+ <div>
+ <a style="position: absolute; top: 2px; right:20px;" wicket:id="check">
+ <img src="img/ping.png"width="30" height="30"
+ alt="ping" title="title" wicket:message="title:check"/>
+ </a>
+ </div>
+ </form>
+ </span>
+ </div>
+ </div>
+ <div id="tabs-3">
+ <span wicket:id="capabilitiesPalette"/>
+ </div>
+ </div>
+
+ <div style="margin: 20px 10px 0">
+ <input type="submit"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="apply"/>
+ <input type="button"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="cancel"/>
+ </div>
+ </form>
+ </div>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage.properties
new file mode 100644
index 0000000..8500f1a
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage.properties
@@ -0,0 +1,43 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tab1=General
+tab2=Configuration
+tab3=Capabilities
+displayName=Display name
+bundleName=Bundle name
+version=Version
+connRequestTimeout=Request timeout (sec)
+action=Action
+edit=Edit
+edit_attribute=Edit attribute
+serviceName=Service name
+endpoint=Endpoint
+title=Connector
+overridable=Overridable
+property=Property
+value=Value
+
+success_connection=Successful connection
+error_connection=Connection failure
+check=Check connection
+location=Location
+poolMaxObjects=Max objects (idle+active)
+poolMinIdle=Min idle objects
+poolMaxIdle=Max idle objects
+poolMaxWait=Max waiting time (msec)
+poolMinEvictableIdleTime=Min eviction time (msec)
+new=New
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage_it.properties
new file mode 100644
index 0000000..96080c3
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage_it.properties
@@ -0,0 +1,43 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tab1=Generale
+tab2=Configurazione
+tab3=Capabilities
+bundleName=Bundle name
+version=Versione
+connRequestTimeout=Timeout richiesta (sec)
+action=Azione
+edit=Edit
+edit_attribute=Edit attribute
+serviceName=Nome servizio
+endpoint=Endpoint
+title=Connettore
+displayName=Nome visualizzato
+overridable=Sovrascrivibile
+property=Propriet\u00e0
+value=Valore
+
+success_connection=Connessione avvenuta con successo
+error_connection=Connessione non riuscita
+check=Verifica connessione
+location=Posizione
+poolMaxObjects=Max oggetti (attivi e non)
+poolMinIdle=Max oggetti attivi
+poolMaxIdle=Max oggetti inattivi
+poolMaxWait=Tempo max attesa
+poolMinEvictableIdleTime=Tempo min espulsione
+new=Nuovo
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage_pt_BR.properties
new file mode 100644
index 0000000..b688216
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConnectorModalPage_pt_BR.properties
@@ -0,0 +1,43 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tab1=Geral
+tab2=Configura\u00e7\u00e3o
+tab3=Capacidades
+displayName=Mostrar Nome
+bundleName=Nome do Pacote
+version=Vers\u00e3o
+connRequestTimeout=Timeout da Requisi\u00e7\u00e3o (seg)
+action=A\u00e7\u00e3o
+edit=Alterar
+edit_attribute=Alterar Atributo
+serviceName=Nome de Servi\u00e7o
+endpoint=Endpoint
+title=Conector
+overridable=Alter\u00e1vel
+property=Propriedade
+value=Valor
+
+success_connection=Sucesso na Conex\u00e3o
+error_connection=Falha na Conex\u00e3o
+check=Verificar a Conex\u00e3o
+location=Localiza\u00e7\u00e3o
+poolMaxObjects=Max objects (idle+active)
+poolMinIdle=Min idle objects
+poolMaxIdle=Max idle objects
+poolMaxWait=Max waiting time (msec)
+poolMinEvictableIdleTime=Min eviction time (msec)
+new=Novo
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage.html
new file mode 100644
index 0000000..5665e0e
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage.html
@@ -0,0 +1,64 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+ <div style="margin: 5px;">
+ <form wicket:id="form">
+ <div id="formtable">
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="key"><wicket:message key="key"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="key">[name]</span>
+ </div>
+ </div>
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="expression"><wicket:message key="expression"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="expression">[expression]</span>
+ <a class="tooltips" wicket:id="questionMarkJexlHelp" href="#" alt="Click to help" title="Click to help">
+ <img src="img/help.png"/>
+ <span wicket:id="jexlHelp" class="tooltips">
+ <wicket:message key="jexl_info"/>
+ <ul>
+ <li><wicket:message key="jexl_ex1"/></li>
+ <li><wicket:message key="jexl_ex2"/></li>
+ </ul>
+ <a href="#" wicket:id="jexlLink" target="_blank"><wicket:message key="jexl_syntax_url"/></a>
+ </span>
+ </a>
+ </div>
+ </div>
+ </div>
+ <div style="margin: 10px 0px 0">
+ <input type="submit"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="apply"/>
+ <input type="button"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="cancel"/>
+ </div>
+ </form>
+ </div>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage.properties
new file mode 100644
index 0000000..e39980a
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage.properties
@@ -0,0 +1,22 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+required_alert=All form fields are required.
+expression=Expression
+existing_schemas=Existing Schemas:
+edit_attribute=Edit attribute
+attributes=Derived attributes
+title=Derived Schema
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage_it.properties
new file mode 100644
index 0000000..425e118
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage_it.properties
@@ -0,0 +1,22 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+required_alert=Tutti i campi sono richiesti.
+expression=Expression
+existing_schemas=Schemi presenti:
+edit_attribute=Modifica attributo
+attributes=Attributi derivati
+title=Schema Derivato
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage_pt_BR.properties
new file mode 100644
index 0000000..df3aff8
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DerSchemaModalPage_pt_BR.properties
@@ -0,0 +1,22 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+required_alert=Todos os campos do formaul\u00e1rio s\u00e3o obrigat\u00f3rios
+expression=Express\u00e3o
+existing_schemas=Esquemas Existentes\:
+edit_attribute=Alterar Atributo
+attributes=Atributos Derivados
+title=Esquema Derivado
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.html
new file mode 100644
index 0000000..998483d
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.html
@@ -0,0 +1,132 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:head>
+ <style>
+ div.group{
+ width:450px;
+ }
+
+ div.group div{
+ width:150;
+ height: 25px;
+ float:left;
+ }
+
+ div.group div input {
+ width: 30px;
+ }
+
+ div#attributes-view {
+ display: block;
+ clear: both;
+ float: none;
+ overflow: auto;
+ margin-top: 0px;
+ margin-bottom: 20px;
+ margin-left: 10px;
+ margin-right: 10px;
+ }
+
+ .submit{
+ display: block;
+ clear: both;
+ float: none;
+ margin-left: 10px;
+ }
+
+ span.grouplabel{
+ display:block;
+ clear: both;
+ margin-left: 10px;
+ margin-bottom: 10px;
+ font-weight: bold;
+ }
+ </style>
+ </wicket:head>
+ <wicket:extend>
+ <form wicket:id="form">
+ <div id="attributes-view">
+ <p class="ui-widget ui-corner-all ui-widget-header">
+ <wicket:message key="title"/>
+ </p>
+
+ <span class="grouplabel"><wicket:message key="plainSchemas"/></span>
+ <span wicket:id="dCheckGroup">
+ <div class="group">
+ <div wicket:id="details">
+ <input type="checkbox" wicket:id="dcheck"/>
+ <span wicket:id="dname">[schema name]</span>
+ </div>
+ </div>
+ </span>
+
+ <span wicket:id="plainSchemas">[schemas]</span>
+
+ <span wicket:id="dschemas">[derived schemas]</span>
+
+ <span wicket:id="vschemas">[virtual schemas]</span>
+
+ </div>
+
+ <wicket:fragment wicket:id="sfragment">
+ <span wicket:id="psCheckGroup">
+ <div class="group">
+ <div wicket:id="plainSchemas">
+ <input type="checkbox" wicket:id="scheck"/>
+ <span wicket:id="sname">[schema name]</span>
+ </div>
+ </div>
+ </span>
+ </wicket:fragment>
+
+ <wicket:fragment wicket:id="dsfragment">
+ <span class="grouplabel"><wicket:message key="derSchemas"/></span>
+ <span wicket:id="dsCheckGroup">
+ <div class="group">
+ <div wicket:id="derSchemas">
+ <input type="checkbox" wicket:id="dscheck"/>
+ <span wicket:id="dsname">[schema name]</span>
+ </div>
+ </div>
+ </span>
+ </wicket:fragment>
+
+ <wicket:fragment wicket:id="vsfragment">
+ <span class="grouplabel"><wicket:message key="virSchemas"/></span>
+ <span wicket:id="vsCheckGroup">
+ <div class="group">
+ <div wicket:id="virSchemas">
+ <input type="checkbox" wicket:id="vscheck"/>
+ <span wicket:id="vsname">[schema name]</span>
+ </div>
+ </div>
+ </span>
+ </wicket:fragment>
+
+ <wicket:fragment wicket:id="emptyFragment">
+ </wicket:fragment>
+
+ <div class="submit">
+ <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="submit"/>
+ <input type="button" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="cancel"/>
+ </div>
+ </form>
+ </wicket:extend>
+</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.properties
new file mode 100644
index 0000000..e7080ed
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage.properties
@@ -0,0 +1,33 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Change display attributes
+tooManySelections=Too many columns to be shown
+plainSchemas=User plain attributes
+derSchemas=User derived attributes
+virSchemas=User virtual attributes
+
+firstname=Firstname
+surname=Surname
+userId=User Id
+edit=Edit
+delete=Delete
+status=Status
+token=Token
+username=Username
+creationDate=Creation Date
+tokenValued=Valued
+tokenNotValued=Not valued
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage_it.properties
new file mode 100644
index 0000000..6ee5963
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage_it.properties
@@ -0,0 +1,33 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Scegli attributi da visualizzare
+tooManySelections=Troppe colonne da visualizzare
+plainSchemas=Attributi normali utente
+derSchemas=Attributi derivati utente
+virSchemas=Attributi virtuali utente
+
+firstname=Nome
+surname=Cognome
+userId=User Id
+edit=Edit
+delete=Rimuovi
+status=Stato
+token=Token
+username=Username
+creationDate=Data Creazione
+tokenValued=Valorizzato
+tokenNotValued=Non valorizzato
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage_pt_BR.properties
new file mode 100644
index 0000000..7f2b8cb
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/DisplayAttributesModalPage_pt_BR.properties
@@ -0,0 +1,33 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Alterar atributos mostrados
+tooManySelections=Muitas colunas para exibir
+plainSchemas=Atributo Normal de Usu\u00e1rios
+derSchemas=Atributos Derivados de Usu\u00e1rios
+virSchemas=Atributos virtuais de Usu\u00e1rios
+
+firstname=Nome
+surname=Sobrenome
+userId=Identificador de Usu\u00e1rio
+edit=Alterar
+delete=Excluir
+status=Estatus
+token=Token
+username=Nome do Usu\u00e1rio
+creationDate=Data de Cria\u00e7\u00e3o
+tokenValued=Valorado
+tokenNotValued=N\u00e3o Valorado
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ErrorPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ErrorPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ErrorPage.html
new file mode 100644
index 0000000..c1c7407
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ErrorPage.html
@@ -0,0 +1,53 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<wicket:head>
+ <style type="text/css">
+ .ui-state-error, .ui-widget-content .ui-state-error, .ui-widget-header .ui-state-error {
+ background:url("../../css/images/ui-bg_glass_95_fef1ec_1x400.png") repeat-x scroll 50% 50% #FEF1EC;
+ border:1px solid #CD0A0A;
+ color:#CD0A0A;
+ width: 400px;
+ padding: 0px;
+ margin-top: 200px;
+ margin-left: auto;
+ margin-right: auto;
+ }
+ body {
+ background: url("../../css/images/ui-bg_diagonals-thick_20_666666_40x40.png")
+ repeat scroll 50% 50% #666666;
+ }
+ </style>
+</wicket:head>
+<wicket:extend>
+
+ <div class="ui-widget">
+ <div style="padding: 0pt 0.7em;" class="ui-state-error ui-corner-all">
+ <p><span style="float: left; margin-right: 0.3em;"
+ class="ui-icon ui-icon-alert"></span>
+ <strong><span wicket:id="errorTitle"/></strong>
+ <div><span wicket:id="errorMessage"/></div>
+ <p>
+ <a href="" wicket:id="home">
+ <wicket:message key="home"/>
+ </a>
+ </p>
+ </p>
+ </div>
+ </div>
+</wicket:extend>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ExecMessageModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ExecMessageModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ExecMessageModalPage.html
new file mode 100644
index 0000000..bf00ee4
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ExecMessageModalPage.html
@@ -0,0 +1,25 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<wicket:extend>
+ <div id="dialog">
+ <pre wicket:id="message">
+ [Task execution's message to show]
+ </pre>
+ </div>
+</wicket:extend>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/FailureMessageModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/FailureMessageModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/FailureMessageModalPage.html
new file mode 100644
index 0000000..db7c53d
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/FailureMessageModalPage.html
@@ -0,0 +1,36 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<!DOCTYPE html>
+<style>
+ .w_content_3 {
+ padding: 0;
+ color: #333333;
+ font-family: Verdana,Tahoma,sans-serif;
+ font-size: 62.5%;
+ }
+</style>
+<wicket:extend>
+ <div class="w_content_3">
+ <div>
+ <div style="margin: 1em">
+ <pre wicket:id="failureMessage"></pre>
+ </div>
+ </div>
+ </div>
+</wicket:extend>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage.html
new file mode 100644
index 0000000..bbcd878
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage.html
@@ -0,0 +1,52 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <div style="margin: 5px;">
+ <p class="ui-widget ui-corner-all ui-widget-header">
+ <wicket:message key="title"/> <span wicket:id="displayName"/>
+ </p>
+ <form wicket:id="groupForm">
+ <div id="tabs">
+ <div style="display: block; clear: both">
+ <ul>
+ <li><a href="#details"><span><wicket:message key="details"/></span></a></li>
+ <li><a href="#templates"><span><wicket:message key="templates"/></span></a></li>
+ <li><a href="#plainAttrs"><span><wicket:message key="plainAttrs"/></span></a></li>
+ <li><a href="#derAttrs"><span><wicket:message key="derAttrs"/></span></a></li>
+ <li><a href="#virAttrs"><span><wicket:message key="virAttrs"/></span></a></li>
+ <li><a href="#resources"><span><wicket:message key="resources"/></span></a></li>
+ <li><a href="#entitlements"><span><wicket:message key="entitlements"/></span></a></li>
+ <li><a href="#security"><span><wicket:message key="security"/></span></a></li>
+ </ul>
+ </div>
+ <div wicket:id="groupPanel"></div>
+ </div>
+ <div style="bottom:0;margin:10px">
+ <input type="submit"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="submit"/>
+ <input type="button"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="cancel"/>
+ </div>
+ </form>
+ </div>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage.properties
new file mode 100644
index 0000000..4ffa2fb
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage.properties
@@ -0,0 +1,48 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+required_alert=All form fields are required.
+title=Group
+details=Details
+plainAttrs=Plain attributes
+tab3=Derived attributes
+tab4=Virtual attributes
+resources=Resources
+entitlements=Entitlements
+security=Security
+add=+
+drop=-
+error=Generic error occurred during the operation
+firstResourcesList=Group's resources
+secondResourcesList=Available resources
+firstEntitlementsList=Group's entitlements
+secondEntitlementsList=Available entitlements
+derAttrs=Derived Attributes
+derAttrToRemove=Delete
+derAttrName=Name
+derAttrValue=Derived value
+
+virAttrs=Virtual Attributes
+virAttrToRemove=Delete
+virAttrName=Name
+virAttrValue=Virtual value
+
+addAttributeBtn=Add
+
+inheritPlainAttrs=Inherit plain attributes
+inheritDerAttrs=Inherit derived attributes
+inheritVirAttrs=Inherit virtual attributes
+templates=Templates
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage_it.properties
new file mode 100644
index 0000000..1c6efec
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage_it.properties
@@ -0,0 +1,50 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+required_alert=All form fields are required.
+title=Gruppo
+details=Dettagli
+plainAttrs=Attributi normali
+tab3=Attributi derivati
+tab4=Attributi virtuali
+resources=Risorse
+entitlements=Entitlement
+security=Sicurezza
+add=+
+drop=-
+error=Errore generico durante l'operazione
+firstResourcesList=Risorse ruolo
+secondResourcesList=Risorse disponibili
+firstResourcesList=Risorse gruppo
+secondResourcesList=Risorse disponibili
+derAttrs=Attributi derivati
+derAttrToRemove=Elimina
+derAttrName=Nome
+derAttrValue=Valore derivato
+
+virAttrs=Attributi virtuali
+virAttrToRemove=Elimina
+virAttrName=Nome
+virAttrValue=Valore virtuale
+
+addAttributeBtn=Aggiungi
+
+inheritPlainAttrs=Eredita attributi normali
+inheritDerAttrs=Eredita attributi derivati
+inheritVirAttrs=Eredita attributi virtuali
+templates=Modelo
+secondEntitlementsList=Entitlement disponibili
+firstEntitlementsList=Entitlement gruppo
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage_pt_BR.properties
new file mode 100644
index 0000000..0649585
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage_pt_BR.properties
@@ -0,0 +1,48 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+required_alert=Todos os campos s\u00e3o obrigat\u00f3rios
+title=Grupo
+details=Detalhes
+plainAttrs=Atributos Normal
+tab3=Atributos Derivados
+tab4=Atributos Virtuais
+resources=Recursos
+entitlements=Direitos
+security=Seguran\u00e7a
+add=+
+drop=-
+error=Um erro gen\u00e9rico ocorreu durante a opera\u00e7\u00e3o
+firstResourcesList=Recursos de grupos
+secondResourcesList=Recursos dispon\u00edveis
+firstEntitlementsList=Direitos de grupos
+secondEntitlementsList=Direitos dispon\u00edveis
+derAttrs=Atributos derivados
+derAttrToRemove=Exluir
+derAttrName=Nome
+derAttrValue=Valor Derivado
+
+virAttrs=Atributos Virtuais
+virAttrToRemove=Excluir
+virAttrName=Nome
+virAttrValue=Valor Virtual
+
+addAttributeBtn=Adicionar
+
+inheritPlainAttrs=Atributos Herdados Normal
+inheritDerAttrs=Atributos Derivados Herdados
+inheritVirAttrs=Atributos Virtuais Herdados
+templates=Modelli
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupSelectModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupSelectModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupSelectModalPage.html
new file mode 100644
index 0000000..203ffa9
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/GroupSelectModalPage.html
@@ -0,0 +1,24 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <div wicket:id="treeTable"
+ style="width: 100%;display:block;margin:auto;" class="groupTable group-tree"/>
+ </wicket:extend>
+</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Groups.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Groups.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Groups.html
new file mode 100644
index 0000000..a335c28
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Groups.html
@@ -0,0 +1,80 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:head>
+ <style>
+ div.group-tree div.wicket-tree-table a {
+ color:black;
+ }
+ </style>
+ <script type="text/javascript">
+ $(document).ready(function() {
+ $("#grouptabs").tabs();
+ });
+ </script>
+ </wicket:head>
+ <wicket:extend>
+ <div id="grouptabs">
+ <ul>
+ <li class="tabs-selected">
+ <a href="#tabs-tree">
+ <span><wicket:message key="tabs-tree"/>
+ </span>
+ </a>
+ </li>
+ <li>
+ <a href="#tabs-search">
+ <span><wicket:message key="tabs-search"/>
+ </span>
+ </a>
+ </li>
+ </ul>
+
+ <div id="tabs-tree" >
+ <div wicket:id="groupTabsContainer">
+ <span wicket:id="treePanel"></span>
+ <span wicket:id="summaryPanel"></span>
+ </div>
+ <div wicket:id="editGroupWin">[Show modal window for create/editing group]</div>
+ </div>
+
+ <div id="tabs-search">
+ <div>
+ <form wicket:id="searchForm">
+ <span wicket:id="searchPanel">searchPanel</span>
+
+ <br/>
+ <a wicket:id="search"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only">
+ <img src="img/search.png" alt="search"/>
+ <wicket:message key="search"/>
+ </a>
+ </form>
+ </div>
+
+ <div id="users-contain" class="ui-widget" style="width:auto">
+ <span wicket:id="searchResult">[search result]</span>
+ </div>
+ </div>
+
+ </div>
+
+ <wicket:child/>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Groups.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Groups.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Groups.properties
new file mode 100644
index 0000000..bfe9385
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Groups.properties
@@ -0,0 +1,26 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tabs-tree=Tree
+tabs-search=Search
+search=Search
+create_user=Create new user
+search_results_title=Search results
+search_noResults=No matches found.
+reset=Reset
+showingFrom=Showing
+showingTo=to
+showingOf=of
[15/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupPanel.java
new file mode 100644
index 0000000..7cbf47e
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupPanel.java
@@ -0,0 +1,187 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Mode;
+import org.apache.syncope.client.console.commons.XMLRolesReader;
+import org.apache.syncope.client.console.commons.status.StatusBean;
+import org.apache.syncope.client.console.rest.AuthRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPalettePanel;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.util.ListModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class GroupPanel extends Panel {
+
+ private static final long serialVersionUID = 4216376097320768369L;
+
+ @SpringBean
+ private AuthRestClient authRestClient;
+
+ @SpringBean
+ private XMLRolesReader xmlRolesReader;
+
+ private final AjaxPalettePanel<String> entitlements;
+
+ public static class Builder implements Serializable {
+
+ private static final long serialVersionUID = 8150440254654306070L;
+
+ private String id;
+
+ private Form form;
+
+ private GroupTO groupTO;
+
+ private Mode mode;
+
+ private PageReference pageReference;
+
+ public Builder(final String id) {
+ this.id = id;
+ }
+
+ public Builder form(final Form form) {
+ this.form = form;
+ return this;
+ }
+
+ public Builder groupTO(final GroupTO groupTO) {
+ this.groupTO = groupTO;
+ return this;
+ }
+
+ public Builder groupModalPageMode(final Mode mode) {
+ this.mode = mode;
+ return this;
+ }
+
+ public Builder pageRef(final PageReference pageReference) {
+ this.pageReference = pageReference;
+ return this;
+ }
+
+ public GroupPanel build() {
+ return new GroupPanel(this);
+ }
+ }
+
+ private GroupPanel(final Builder builder) {
+ super(builder.id);
+
+ this.add(new GroupDetailsPanel("details", builder.groupTO, builder.mode == Mode.TEMPLATE));
+
+ if (builder.pageReference == null || builder.groupTO.getKey() == 0) {
+ this.add(new Label("statuspanel", ""));
+ } else {
+ StatusPanel statusPanel = new StatusPanel(
+ "statuspanel", builder.groupTO, new ArrayList<StatusBean>(), builder.pageReference);
+ statusPanel.setOutputMarkupId(true);
+ MetaDataRoleAuthorizationStrategy.authorize(
+ statusPanel, RENDER, xmlRolesReader.getEntitlement("Resources", "getConnectorObject"));
+ this.add(statusPanel);
+ }
+
+ this.add(new AnnotatedBeanPanel("systeminformation", builder.groupTO));
+
+ //--------------------------------
+ // Attribute templates panel
+ //--------------------------------
+ AttrTemplatesPanel attrTemplates = new AttrTemplatesPanel("templates", builder.groupTO);
+ this.add(attrTemplates);
+
+ //--------------------------------
+ // Attributes panel
+ //--------------------------------
+ this.add(new PlainAttrsPanel(
+ "plainAttrs", builder.groupTO, builder.form, builder.mode, attrTemplates));
+
+ final AjaxCheckBoxPanel inhAttributes = new AjaxCheckBoxPanel("inheritPlainAttrs", "inheritPlainAttrs",
+ new PropertyModel<Boolean>(builder.groupTO, "inheritPlainAttrs"));
+ inhAttributes.setOutputMarkupId(true);
+ this.add(inhAttributes);
+ //--------------------------------
+
+ //--------------------------------
+ // Derived attributes panel
+ //--------------------------------
+ this.add(new DerAttrsPanel("derAttrs", builder.groupTO, attrTemplates));
+
+ final AjaxCheckBoxPanel inhDerivedAttributes = new AjaxCheckBoxPanel("inheritDerAttrs",
+ "inheritDerAttrs", new PropertyModel<Boolean>(builder.groupTO, "inheritDerAttrs"));
+ inhDerivedAttributes.setOutputMarkupId(true);
+ this.add(inhDerivedAttributes);
+ //--------------------------------
+
+ //--------------------------------
+ // Virtual attributes panel
+ //--------------------------------
+ this.add(new VirAttrsPanel(
+ "virAttrs", builder.groupTO, builder.mode == Mode.TEMPLATE, attrTemplates));
+
+ final AjaxCheckBoxPanel inhVirtualAttributes = new AjaxCheckBoxPanel("inheritVirAttrs",
+ "inheritVirAttrs", new PropertyModel<Boolean>(builder.groupTO, "inheritVirAttrs"));
+ inhVirtualAttributes.setOutputMarkupId(true);
+ this.add(inhVirtualAttributes);
+ //--------------------------------
+
+ //--------------------------------
+ // Resources panel
+ //--------------------------------
+ this.add(new ResourcesPanel.Builder("resources").attributableTO(builder.groupTO).build().
+ setOutputMarkupId(true));
+ //--------------------------------
+
+ //--------------------------------
+ // Entitlements
+ //--------------------------------
+ ListModel<String> selectedEntitlements = new ListModel<String>(builder.groupTO.getEntitlements());
+
+ List<String> allEntitlements = authRestClient.getAllEntitlements();
+ if (allEntitlements != null && !allEntitlements.isEmpty()) {
+ Collections.sort(allEntitlements);
+ }
+ ListModel<String> availableEntitlements = new ListModel<String>(allEntitlements);
+
+ entitlements = new AjaxPalettePanel<String>("entitlements", selectedEntitlements, availableEntitlements);
+ this.add(entitlements);
+
+ //--------------------------------
+ // Security panel
+ //--------------------------------
+ this.add(new GroupSecurityPanel("security", builder.groupTO).setOutputMarkupId(true));
+ //--------------------------------
+ }
+
+ public Collection<String> getSelectedEntitlements() {
+ return this.entitlements.getModelCollection();
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupSearchPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupSearchPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupSearchPanel.java
new file mode 100644
index 0000000..d13ab94
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupSearchPanel.java
@@ -0,0 +1,101 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+import org.apache.syncope.client.lib.SyncopeClient;
+import org.apache.syncope.common.lib.search.AbstractFiqlSearchConditionBuilder;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.wicket.model.LoadableDetachableModel;
+
+public class GroupSearchPanel extends AbstractSearchPanel {
+
+ private static final long serialVersionUID = 5757183539269316263L;
+
+ public static class Builder implements Serializable {
+
+ private static final long serialVersionUID = 6308997285778809579L;
+
+ private String id;
+
+ private String fiql = null;
+
+ private boolean required = true;
+
+ public Builder(final String id) {
+ this.id = id;
+ }
+
+ public Builder fiql(final String fiql) {
+ this.fiql = fiql;
+ return this;
+ }
+
+ public Builder required(final boolean required) {
+ this.required = required;
+ return this;
+ }
+
+ public GroupSearchPanel build() {
+ return new GroupSearchPanel(this);
+ }
+ }
+
+ private GroupSearchPanel(final Builder builder) {
+ super(builder.id, AttributableType.GROUP, builder.fiql, builder.required);
+ }
+
+ @Override
+ protected void populate() {
+ super.populate();
+
+ this.types = new LoadableDetachableModel<List<SearchClause.Type>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<SearchClause.Type> load() {
+ final List<SearchClause.Type> result = new ArrayList<SearchClause.Type>();
+ result.add(SearchClause.Type.ATTRIBUTE);
+ result.add(SearchClause.Type.ENTITLEMENT);
+ result.add(SearchClause.Type.RESOURCE);
+ return result;
+ }
+ };
+
+ this.groupNames = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ return Collections.<String>emptyList();
+ }
+ };
+ }
+
+ @Override
+ protected AbstractFiqlSearchConditionBuilder getSearchConditionBuilder() {
+ return SyncopeClient.getGroupSearchConditionBuilder();
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupSearchResultPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupSearchResultPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupSearchResultPanel.java
new file mode 100644
index 0000000..a7dac82
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupSearchResultPanel.java
@@ -0,0 +1,172 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.pages.ResultStatusModalPage;
+import org.apache.syncope.client.console.pages.GroupModalPage;
+import org.apache.syncope.client.console.pages.StatusModalPage;
+import org.apache.syncope.client.console.rest.AbstractSubjectRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink.ActionType;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.ResourceModel;
+
+public class GroupSearchResultPanel extends AbstractSearchResultPanel {
+
+ private static final long serialVersionUID = -1180593361914008764L;
+
+ private final static String PAGEID = "Groups";
+
+ public <T extends AbstractAttributableTO> GroupSearchResultPanel(final String id, final boolean filtered,
+ final String fiql, final PageReference callerRef, final AbstractSubjectRestClient restClient) {
+
+ super(id, filtered, fiql, callerRef, restClient);
+ initResultTable();
+ }
+
+ @Override
+ protected List<IColumn<AbstractAttributableTO, String>> getColumns() {
+ final List<IColumn<AbstractAttributableTO, String>> columns = new ArrayList<>();
+
+ for (String item : new String[] { "key", "name", "entitlements" }) {
+ columns.add(new PropertyColumn<AbstractAttributableTO, String>(new ResourceModel(item, item), item, item));
+ }
+
+ columns.add(new AbstractColumn<AbstractAttributableTO, String>(new ResourceModel("actions", "")) {
+
+ private static final long serialVersionUID = -3503023501954863131L;
+
+ @Override
+ public String getCssClass() {
+ return "action";
+ }
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<AbstractAttributableTO>> cellItem,
+ final String componentId, final IModel<AbstractAttributableTO> model) {
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, page.getPageReference());
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ statusmodal.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new StatusModalPage<GroupTO>(
+ page.getPageReference(), statusmodal, (GroupTO) model.getObject());
+ }
+ });
+
+ statusmodal.show(target);
+ }
+ }, ActionLink.ActionType.MANAGE_RESOURCES, PAGEID);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ editmodal.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new GroupModalPage(
+ page.getPageReference(), editmodal, (GroupTO) model.getObject());
+ }
+ });
+
+ editmodal.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, PAGEID);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ final GroupTO groupTO = (GroupTO) restClient.
+ delete(model.getObject().getETagValue(), model.getObject().getKey());
+
+ page.setModalResult(true);
+
+ editmodal.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ResultStatusModalPage.Builder(editmodal, groupTO).build();
+ }
+ });
+
+ editmodal.show(target);
+ } catch (SyncopeClientException scce) {
+ error(getString(Constants.OPERATION_ERROR) + ": " + scce.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+ }, ActionLink.ActionType.DELETE, PAGEID);
+
+ cellItem.add(panel);
+ }
+ });
+
+ return columns;
+ }
+
+ @Override
+ protected Collection<ActionType> getBulkActions() {
+ return Collections.<ActionLink.ActionType>singletonList(ActionLink.ActionType.DELETE);
+ }
+
+ @Override
+ protected String getPageId() {
+ return PAGEID;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupSecurityPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupSecurityPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupSecurityPanel.java
new file mode 100644
index 0000000..4e0e1f9
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupSecurityPanel.java
@@ -0,0 +1,198 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.Map;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.rest.PolicyRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.to.AbstractPolicyTO;
+import org.apache.syncope.common.lib.types.PolicyType;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.ChoiceRenderer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class GroupSecurityPanel extends Panel {
+
+ /**
+ * Logger.
+ */
+ protected static final Logger LOG = LoggerFactory.getLogger(GroupSecurityPanel.class);
+
+ private static final long serialVersionUID = -7982691107029848579L;
+
+ @SpringBean
+ private PolicyRestClient policyRestClient;
+
+ private IModel<Map<Long, String>> passwordPolicies = null;
+
+ private IModel<Map<Long, String>> accountPolicies = null;
+
+ public <T extends AbstractAttributableTO> GroupSecurityPanel(final String id, final T entityTO) {
+ super(id);
+
+ setOutputMarkupId(true);
+
+ passwordPolicies = new LoadableDetachableModel<Map<Long, String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected Map<Long, String> load() {
+ Map<Long, String> res = new HashMap<>();
+ for (AbstractPolicyTO policyTO : policyRestClient.getPolicies(PolicyType.PASSWORD, false)) {
+ res.put(policyTO.getKey(), policyTO.getDescription());
+ }
+ return res;
+ }
+ };
+
+ accountPolicies = new LoadableDetachableModel<Map<Long, String>>() {
+
+ private static final long serialVersionUID = -2012833443695917883L;
+
+ @Override
+ protected Map<Long, String> load() {
+ Map<Long, String> res = new HashMap<>();
+ for (AbstractPolicyTO policyTO : policyRestClient.getPolicies(PolicyType.ACCOUNT, false)) {
+ res.put(policyTO.getKey(), policyTO.getDescription());
+ }
+ return res;
+ }
+ };
+
+ final WebMarkupContainer securityContainer = new WebMarkupContainer("security");
+
+ securityContainer.setOutputMarkupId(true);
+ add(securityContainer);
+
+ // -------------------------------
+ // Password policy specification
+ // -------------------------------
+ final AjaxDropDownChoicePanel<Long> passwordPolicy = new AjaxDropDownChoicePanel<Long>("passwordPolicy",
+ "passwordPolicy", new PropertyModel<Long>(entityTO, "passwordPolicy"));
+
+ passwordPolicy.setChoiceRenderer(new PolicyRenderer(PolicyType.PASSWORD));
+
+ passwordPolicy.setChoices(new ArrayList<Long>(passwordPolicies.getObject().keySet()));
+
+ ((DropDownChoice<?>) passwordPolicy.getField()).setNullValid(true);
+
+ securityContainer.add(passwordPolicy);
+
+ final AjaxCheckBoxPanel inhPasswordPolicy = new AjaxCheckBoxPanel("inheritPasswordPolicy",
+ "inheritPasswordPolicy", new PropertyModel<Boolean>(entityTO, "inheritPasswordPolicy"));
+
+ passwordPolicy.setReadOnly(inhPasswordPolicy.getModelObject());
+
+ inhPasswordPolicy.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ passwordPolicy.setReadOnly(inhPasswordPolicy.getModelObject());
+ target.add(passwordPolicy);
+ }
+ });
+
+ securityContainer.add(inhPasswordPolicy);
+ // -------------------------------
+
+ // -------------------------------
+ // Account policy specification
+ // -------------------------------
+ final AjaxDropDownChoicePanel<Long> accountPolicy = new AjaxDropDownChoicePanel<Long>("accountPolicy",
+ "accountPolicy", new PropertyModel<Long>(entityTO, "accountPolicy"));
+
+ accountPolicy.setChoiceRenderer(new PolicyRenderer(PolicyType.ACCOUNT));
+
+ accountPolicy.setChoices(new ArrayList<Long>(accountPolicies.getObject().keySet()));
+
+ ((DropDownChoice<?>) accountPolicy.getField()).setNullValid(true);
+
+ securityContainer.add(accountPolicy);
+
+ final AjaxCheckBoxPanel inhAccountPolicy = new AjaxCheckBoxPanel("inheritAccountPolicy",
+ "inheritAccountPolicy", new PropertyModel<Boolean>(entityTO, "inheritAccountPolicy"));
+ accountPolicy.setReadOnly(inhAccountPolicy.getModelObject());
+
+ inhAccountPolicy.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ accountPolicy.setReadOnly(inhAccountPolicy.getModelObject());
+ target.add(accountPolicy);
+ }
+ });
+
+ securityContainer.add(inhAccountPolicy);
+ // -------------------------------
+ }
+
+ private class PolicyRenderer extends ChoiceRenderer<Long> {
+
+ private static final long serialVersionUID = 8060500161321947000L;
+
+ private PolicyType type;
+
+ public PolicyRenderer(final PolicyType type) {
+ super();
+ this.type = type;
+ }
+
+ @Override
+ public Object getDisplayValue(final Long object) {
+ Object displayValue;
+ switch (type) {
+ case ACCOUNT:
+ displayValue = accountPolicies.getObject().get(object);
+ break;
+ case PASSWORD:
+ displayValue = passwordPolicies.getObject().get(object);
+ break;
+ default:
+ displayValue = "";
+ }
+ return displayValue;
+ }
+
+ @Override
+ public String getIdValue(Long object, int index) {
+ return String.valueOf(object != null
+ ? object
+ : 0L);
+ }
+ };
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupSummaryPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupSummaryPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupSummaryPanel.java
new file mode 100644
index 0000000..f9a56e6
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupSummaryPanel.java
@@ -0,0 +1,153 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.io.Serializable;
+import org.apache.syncope.client.console.commons.XMLRolesReader;
+import org.apache.syncope.client.console.pages.GroupModalPage;
+import org.apache.syncope.client.console.rest.GroupRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.panel.Fragment;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class GroupSummaryPanel extends Panel {
+
+ private static final long serialVersionUID = 643769814985593156L;
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(GroupSummaryPanel.class);
+
+ @SpringBean
+ private XMLRolesReader xmlRolesReader;
+
+ @SpringBean
+ private GroupRestClient restClient;
+
+ private GroupTO selectedNode;
+
+ public static class Builder implements Serializable {
+
+ private static final long serialVersionUID = 4164563358509351832L;
+
+ private String id;
+
+ private ModalWindow window;
+
+ private PageReference callerPageRef;
+
+ private Long selectedNodeId = null;
+
+ public Builder(final String id) {
+ this.id = id;
+ }
+
+ public GroupSummaryPanel.Builder window(final ModalWindow window) {
+ this.window = window;
+ return this;
+ }
+
+ public GroupSummaryPanel.Builder callerPageRef(final PageReference callerPageRef) {
+ this.callerPageRef = callerPageRef;
+ return this;
+ }
+
+ public GroupSummaryPanel.Builder selectedNodeId(final Long selectedNodeId) {
+ this.selectedNodeId = selectedNodeId;
+ return this;
+ }
+
+ public GroupSummaryPanel build() {
+ return new GroupSummaryPanel(this);
+ }
+ }
+
+ private GroupSummaryPanel(final Builder builder) {
+ super(builder.id);
+
+ if (builder.selectedNodeId == null || builder.selectedNodeId == 0) {
+ selectedNode = null;
+ } else {
+ try {
+ selectedNode = restClient.read(builder.selectedNodeId);
+ } catch (SyncopeClientException e) {
+ LOG.error("Could not read {}", builder.selectedNodeId, e);
+ selectedNode = null;
+ builder.selectedNodeId = null;
+ }
+ }
+
+ Fragment fragment = new Fragment("groupSummaryPanel",
+ builder.selectedNodeId == null
+ ? "fakerootFrag"
+ : (builder.selectedNodeId == 0 ? "rootPanel" : "groupViewPanel"),
+ this);
+
+ if (builder.selectedNodeId != null) {
+ if (builder.selectedNodeId == 0) {
+ @SuppressWarnings("rawtypes")
+ final ActionLinksPanel links = new ActionLinksPanel("actionLinks", new Model(), builder.callerPageRef);
+ links.setOutputMarkupId(true);
+ fragment.add(links);
+
+ links.addWithRoles(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ builder.window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new GroupModalPage(builder.callerPageRef, builder.window, new GroupTO());
+ }
+ });
+
+ builder.window.show(target);
+ }
+ }, ActionLink.ActionType.CREATE, xmlRolesReader.getEntitlement("Groups", "create"));
+ } else {
+ GroupTabPanel groupTabPanel =
+ new GroupTabPanel("nodeViewPanel", selectedNode, builder.window, builder.callerPageRef);
+ groupTabPanel.setOutputMarkupId(true);
+ fragment.add(groupTabPanel);
+ }
+ }
+ add(fragment);
+ }
+
+ public GroupTO getSelectedNode() {
+ return selectedNode;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupTabPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupTabPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupTabPanel.java
new file mode 100644
index 0000000..9615554
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupTabPanel.java
@@ -0,0 +1,195 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.Mode;
+import org.apache.syncope.client.console.commons.XMLRolesReader;
+import org.apache.syncope.client.console.pages.ResultStatusModalPage;
+import org.apache.syncope.client.console.pages.GroupModalPage;
+import org.apache.syncope.client.console.pages.Groups;
+import org.apache.syncope.client.console.pages.StatusModalPage;
+import org.apache.syncope.client.console.rest.GroupRestClient;
+import org.apache.syncope.client.console.rest.UserRestClient;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.client.lib.SyncopeClient;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class GroupTabPanel extends Panel {
+
+ private static final long serialVersionUID = 859236186975983959L;
+
+ @SpringBean
+ private XMLRolesReader xmlRolesReader;
+
+ @SpringBean
+ private GroupRestClient groupRestClient;
+
+ @SpringBean
+ private UserRestClient userRestClient;
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ public GroupTabPanel(final String id, final GroupTO selectedNode, final ModalWindow window,
+ final PageReference pageRef) {
+
+ super(id);
+
+ this.add(new Label("displayName", selectedNode.getDisplayName()));
+
+ final ActionLinksPanel links = new ActionLinksPanel("actionLinks", new Model(), pageRef);
+ links.setOutputMarkupId(true);
+ this.add(links);
+ links.addWithRoles(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ GroupTO groupTO = new GroupTO();
+ groupTO.setParent(selectedNode.getKey());
+ return new GroupModalPage(pageRef, window, groupTO);
+ }
+ });
+
+ window.show(target);
+ }
+ }, ActionLink.ActionType.CREATE, xmlRolesReader.getEntitlement("Groups", "create"));
+ links.addWithRoles(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new StatusModalPage<GroupTO>(pageRef, window, groupRestClient.read(selectedNode.getKey()));
+ }
+ });
+
+ window.show(target);
+ }
+ }, ActionLink.ActionType.MANAGE_RESOURCES, xmlRolesReader.getEntitlement("Groups", "update"));
+ links.addWithRoles(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ GroupTO groupTO = groupRestClient.read(selectedNode.getKey());
+ return new GroupModalPage(pageRef, window, groupTO);
+ }
+ });
+
+ window.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, xmlRolesReader.getEntitlement("Groups", "update"));
+ links.addWithRoles(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ final GroupTO groupTO = groupRestClient.delete(selectedNode.getETagValue(), selectedNode.getKey());
+
+ ((Groups) pageRef.getPage()).setModalResult(true);
+
+ window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ResultStatusModalPage.Builder(window, groupTO).build();
+ }
+ });
+
+ window.show(target);
+ } catch (SyncopeClientException e) {
+ error(getString(Constants.OPERATION_ERROR) + ": " + e.getMessage());
+ ((Groups) pageRef.getPage()).getFeedbackPanel().refresh(target);
+ }
+ }
+ }, ActionLink.ActionType.DELETE, xmlRolesReader.getEntitlement("Groups", "delete"));
+
+ final Form form = new Form("groupForm");
+ form.setModel(new CompoundPropertyModel(selectedNode));
+ form.setOutputMarkupId(true);
+
+ final GroupPanel groupPanel = new GroupPanel.Builder("groupPanel").
+ form(form).groupTO(selectedNode).groupModalPageMode(Mode.ADMIN).build();
+ groupPanel.setEnabled(false);
+ form.add(groupPanel);
+
+ final WebMarkupContainer userListContainer = new WebMarkupContainer("userListContainer");
+
+ userListContainer.setOutputMarkupId(true);
+ userListContainer.setEnabled(true);
+ userListContainer.add(new UserSearchResultPanel("userList", true, null, pageRef, userRestClient));
+ userListContainer.add(new ClearIndicatingAjaxButton("search", new ResourceModel("search"), pageRef) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
+ userListContainer.replace(new UserSearchResultPanel("userList",
+ true,
+ SyncopeClient.getUserSearchConditionBuilder().inGroups(selectedNode.getKey()).query(),
+ pageRef,
+ userRestClient));
+
+ target.add(userListContainer);
+ }
+ });
+
+ form.add(userListContainer);
+ add(form);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ImagePanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ImagePanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ImagePanel.java
new file mode 100644
index 0000000..7969c63
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ImagePanel.java
@@ -0,0 +1,44 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import org.apache.wicket.Component;
+import org.apache.wicket.behavior.Behavior;
+import org.apache.wicket.markup.html.image.Image;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.request.resource.ContextRelativeResource;
+
+public class ImagePanel extends Panel {
+
+ private static final long serialVersionUID = 5564818820574092960L;
+
+ final Image img;
+
+ public ImagePanel(final String id, final ContextRelativeResource img) {
+ super(id);
+ this.img = new Image("img", img);
+ add(this.img);
+ }
+
+ @Override
+ public Component add(final Behavior... behaviors) {
+ this.img.add(behaviors);
+ return this;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/JQueryUITabbedPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/JQueryUITabbedPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/JQueryUITabbedPanel.java
new file mode 100644
index 0000000..d898ba6
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/JQueryUITabbedPanel.java
@@ -0,0 +1,45 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.List;
+import org.apache.wicket.extensions.ajax.markup.html.tabs.AjaxTabbedPanel;
+import org.apache.wicket.extensions.markup.html.tabs.ITab;
+
+/**
+ * AjaxTabbedPanel with JQueryUI styling.
+ */
+public class JQueryUITabbedPanel<T extends ITab> extends AjaxTabbedPanel<T> {
+
+ private static final long serialVersionUID = -5059184710433341333L;
+
+ public JQueryUITabbedPanel(final String id, final List<T> tabs) {
+ super(id, tabs);
+ }
+
+ @Override
+ protected String getTabContainerCssClass() {
+ return "";
+ }
+
+ @Override
+ protected String getSelectedTabCssClass() {
+ return "ui-state-active selected";
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/LayoutsPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/LayoutsPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/LayoutsPanel.java
new file mode 100644
index 0000000..26f1894
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/LayoutsPanel.java
@@ -0,0 +1,130 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.List;
+import org.apache.syncope.client.console.commons.AttrLayoutType;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.SelectChoiceRenderer;
+import org.apache.syncope.client.console.commons.XMLRolesReader;
+import org.apache.syncope.client.console.rest.ConfigurationRestClient;
+import org.apache.syncope.client.console.rest.SchemaRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPalettePanel;
+import org.apache.syncope.common.lib.to.AttrTO;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.model.util.ListModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class LayoutsPanel extends Panel {
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(LayoutsPanel.class);
+
+ private static final long serialVersionUID = -6804066913177804275L;
+
+ private static final String CANCEL = "cancel";
+
+ private static final String APPLY = "apply";
+
+ @SpringBean
+ protected XMLRolesReader xmlRolesReader;
+
+ @SpringBean
+ private SchemaRestClient schemaRestClient;
+
+ @SpringBean
+ private ConfigurationRestClient confRestClient;
+
+ @SuppressWarnings("unchecked")
+ public LayoutsPanel(final String id, final AttrLayoutType attrLayoutType, final NotificationPanel feedbackPanel) {
+ super(id);
+
+ final WebMarkupContainer container = new WebMarkupContainer("container");
+ container.setOutputMarkupId(true);
+
+ final Form<String> form = new Form<String>("form");
+ form.setOutputMarkupId(true);
+
+ final AttrTO attrLayout = confRestClient.readAttrLayout(attrLayoutType);
+ form.setModel(new CompoundPropertyModel(attrLayout.getValues()));
+
+ final List<String> fields = schemaRestClient.getPlainSchemaNames(attrLayoutType.getAttrType());
+ final ListModel<String> selectedFields =
+ new ListModel<String>(attrLayout.getValues().isEmpty() ? fields : attrLayout.getValues());
+ final ListModel<String> availableFields = new ListModel<String>(fields);
+
+ form.add(new AjaxPalettePanel<String>("fields", selectedFields, availableFields,
+ new SelectChoiceRenderer<String>(), true, true));
+
+ final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(APPLY)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ try {
+ confRestClient.set(attrLayout);
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (Exception e) {
+ LOG.error("While saving layout configuration", e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ }
+ feedbackPanel.refresh(target);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ error(getString(Constants.ERROR) + ": While saving layout configuration");
+ feedbackPanel.refresh(target);
+ }
+ };
+
+ form.add(submit);
+
+ final IndicatingAjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ target.add(container);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ }
+ };
+
+ cancel.setDefaultFormProcessing(false);
+ form.add(cancel);
+ container.add(form);
+ add(container);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/LoggerCategoryPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/LoggerCategoryPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/LoggerCategoryPanel.java
new file mode 100644
index 0000000..70e0361
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/LoggerCategoryPanel.java
@@ -0,0 +1,461 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Set;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.commons.lang3.tuple.Pair;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.panels.SelectedEventsPanel.EventSelectionChanged;
+import org.apache.syncope.client.console.panels.SelectedEventsPanel.InspectSelectedEvent;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.common.lib.to.EventCategoryTO;
+import org.apache.syncope.common.lib.types.AuditElements;
+import org.apache.syncope.common.lib.types.AuditElements.EventCategoryType;
+import org.apache.syncope.common.lib.types.AuditLoggerName;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.event.Broadcast;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.IChoiceRenderer;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+
+public abstract class LoggerCategoryPanel extends Panel {
+
+ private static final long serialVersionUID = 6429053774964787734L;
+
+ private final List<EventCategoryTO> eventCategoryTOs;
+
+ private final EventCategoryTO eventCategoryTO = new EventCategoryTO();
+
+ private final WebMarkupContainer categoryContainer;
+
+ private final WebMarkupContainer eventsContainer;
+
+ private final SelectedEventsPanel selectedEventsPanel;
+
+ private final AjaxDropDownChoicePanel<EventCategoryType> type;
+
+ private final AjaxDropDownChoicePanel<String> category;
+
+ private final AjaxDropDownChoicePanel<String> subcategory;
+
+ private final AjaxTextFieldPanel custom;
+
+ private final ActionLinksPanel actionPanel;
+
+ private final IModel<List<String>> model;
+
+ public LoggerCategoryPanel(
+ final String id,
+ final List<EventCategoryTO> eventCategoryTOs,
+ final IModel<List<String>> model,
+ final PageReference pageReference,
+ final String pageId) {
+ super(id);
+
+ this.model = model;
+ selectedEventsPanel = new SelectedEventsPanel("selectedEventsPanel", model);
+ add(selectedEventsPanel);
+
+ this.eventCategoryTOs = eventCategoryTOs;
+
+ categoryContainer = new WebMarkupContainer("categoryContainer");
+ categoryContainer.setOutputMarkupId(true);
+ add(categoryContainer);
+
+ eventsContainer = new WebMarkupContainer("eventsContainer");
+ eventsContainer.setOutputMarkupId(true);
+ add(eventsContainer);
+
+ authorizeList();
+ authorizeChanges();
+
+ categoryContainer.add(new Label("typeLabel", new ResourceModel("type", "type")));
+
+ type = new AjaxDropDownChoicePanel<EventCategoryType>(
+ "type",
+ "type",
+ new PropertyModel<EventCategoryType>(eventCategoryTO, "type"),
+ false);
+ type.setChoices(Arrays.asList(EventCategoryType.values()));
+ type.setStyleSheet("ui-widget-content ui-corner-all");
+ type.setChoiceRenderer(new IChoiceRenderer<EventCategoryType>() {
+
+ private static final long serialVersionUID = 2317134950949778735L;
+
+ @Override
+ public String getDisplayValue(final EventCategoryType eventCategoryType) {
+ return eventCategoryType.name();
+ }
+
+ @Override
+ public String getIdValue(final EventCategoryType eventCategoryType, final int i) {
+ return eventCategoryType.name();
+ }
+ });
+ categoryContainer.add(type);
+
+ type.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ send(LoggerCategoryPanel.this, Broadcast.EXACT, new ChangeCategoryEvent(target, type));
+ }
+ });
+
+ categoryContainer.add(new Label("categoryLabel", new ResourceModel("category", "category")));
+
+ category = new AjaxDropDownChoicePanel<String>(
+ "category",
+ "category",
+ new PropertyModel<String>(eventCategoryTO, "category"),
+ false);
+ category.setChoices(filter(eventCategoryTOs, type.getModelObject()));
+ category.setStyleSheet("ui-widget-content ui-corner-all");
+ categoryContainer.add(category);
+
+ category.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306811L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ send(LoggerCategoryPanel.this, Broadcast.EXACT, new ChangeCategoryEvent(target, category));
+ }
+ });
+
+ categoryContainer.add(new Label("subcategoryLabel", new ResourceModel("subcategory", "subcategory")));
+
+ subcategory = new AjaxDropDownChoicePanel<String>(
+ "subcategory",
+ "subcategory",
+ new PropertyModel<String>(eventCategoryTO, "subcategory"),
+ false);
+ subcategory.setChoices(filter(eventCategoryTOs, type.getModelObject(), category.getModelObject()));
+ subcategory.setStyleSheet("ui-widget-content ui-corner-all");
+ categoryContainer.add(subcategory);
+
+ subcategory.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306812L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ send(LoggerCategoryPanel.this, Broadcast.EXACT, new ChangeCategoryEvent(target, subcategory));
+ }
+ });
+
+ categoryContainer.add(new Label("customLabel", new ResourceModel("custom", "custom")).setVisible(false));
+
+ custom = new AjaxTextFieldPanel("custom", "custom", new Model<String>(null));
+ custom.setStyleSheet("ui-widget-content ui-corner-all short_fixedsize");
+ custom.setVisible(false);
+ custom.setEnabled(false);
+
+ categoryContainer.add(custom);
+
+ actionPanel = new ActionLinksPanel("customActions", new Model(), pageReference);
+ categoryContainer.add(actionPanel);
+
+ actionPanel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ if (StringUtils.isNotBlank(custom.getModelObject())) {
+ final Pair<EventCategoryTO, AuditElements.Result> parsed =
+ AuditLoggerName.parseEventCategory(custom.getModelObject());
+
+ final String eventString = AuditLoggerName.buildEvent(
+ parsed.getKey().getType(),
+ null,
+ null,
+ parsed.getKey().getEvents().isEmpty()
+ ? StringUtils.EMPTY : parsed.getKey().getEvents().iterator().next(),
+ parsed.getValue());
+
+ custom.setModelObject(StringUtils.EMPTY);
+ send(LoggerCategoryPanel.this.getPage(), Broadcast.BREADTH, new EventSelectionChanged(
+ target,
+ Collections.<String>singleton(eventString),
+ Collections.<String>emptySet()));
+ target.add(categoryContainer);
+ }
+ }
+ }, ActionLink.ActionType.CREATE, pageId, true);
+
+ actionPanel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435502L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ if (StringUtils.isNotBlank(custom.getModelObject())) {
+ Pair<EventCategoryTO, AuditElements.Result> parsed =
+ AuditLoggerName.parseEventCategory(custom.getModelObject());
+
+ String eventString = AuditLoggerName.buildEvent(
+ parsed.getKey().getType(),
+ null,
+ null,
+ parsed.getKey().getEvents().isEmpty()
+ ? StringUtils.EMPTY : parsed.getKey().getEvents().iterator().next(),
+ parsed.getValue());
+
+ custom.setModelObject(StringUtils.EMPTY);
+ send(LoggerCategoryPanel.this.getPage(), Broadcast.BREADTH, new EventSelectionChanged(
+ target,
+ Collections.<String>emptySet(),
+ Collections.<String>singleton(eventString)));
+ target.add(categoryContainer);
+ }
+ }
+ }, ActionLink.ActionType.DELETE, pageId, true);
+
+ actionPanel.setVisible(false);
+ actionPanel.setEnabled(false);
+
+ eventsContainer.add(new EventSelectionPanel("eventsPanel", eventCategoryTO, model) {
+
+ private static final long serialVersionUID = 3513194801190026082L;
+
+ @Override
+ protected void onEventAction(final IEvent<?> event) {
+ LoggerCategoryPanel.this.onEventAction(event);
+ }
+ });
+ }
+
+ private List<String> filter(
+ final List<EventCategoryTO> eventCategoryTOs, final EventCategoryType type) {
+ final Set<String> res = new HashSet<String>();
+
+ for (EventCategoryTO eventCategory : eventCategoryTOs) {
+ if (type == eventCategory.getType() && StringUtils.isNotEmpty(eventCategory.getCategory())) {
+ res.add(eventCategory.getCategory());
+ }
+ }
+
+ final List<String> filtered = new ArrayList<String>(res);
+ Collections.sort(filtered);
+ return filtered;
+ }
+
+ private List<String> filter(
+ final List<EventCategoryTO> eventCategoryTOs, final EventCategoryType type, final String category) {
+ final Set<String> res = new HashSet<String>();
+
+ for (EventCategoryTO eventCategory : eventCategoryTOs) {
+ if (type == eventCategory.getType() && StringUtils.equals(category, eventCategory.getCategory())
+ && StringUtils.isNotEmpty(eventCategory.getSubcategory())) {
+ res.add(eventCategory.getSubcategory());
+ }
+ }
+
+ final List<String> filtered = new ArrayList<String>(res);
+ Collections.sort(filtered);
+ return filtered;
+ }
+
+ @Override
+ @SuppressWarnings("unchecked")
+ public void onEvent(final IEvent<?> event) {
+ if (event.getPayload() instanceof ChangeCategoryEvent) {
+ // update objects ....
+ eventCategoryTO.getEvents().clear();
+
+ final ChangeCategoryEvent change = (ChangeCategoryEvent) event.getPayload();
+
+ final Panel changedPanel = change.getChangedPanel();
+ if ("type".equals(changedPanel.getId())) {
+ eventCategoryTO.setType(type.getModelObject());
+ eventCategoryTO.setCategory(null);
+ eventCategoryTO.setSubcategory(null);
+
+ if (type.getModelObject() == EventCategoryType.CUSTOM) {
+ category.setChoices(Collections.<String>emptyList());
+ subcategory.setChoices(Collections.<String>emptyList());
+ category.setEnabled(false);
+ subcategory.setEnabled(false);
+ custom.setVisible(true);
+ custom.setEnabled(true);
+ actionPanel.setVisible(true);
+ actionPanel.setEnabled(true);
+
+ } else {
+ category.setChoices(filter(eventCategoryTOs, type.getModelObject()));
+ subcategory.setChoices(Collections.<String>emptyList());
+ category.setEnabled(true);
+ subcategory.setEnabled(true);
+ custom.setVisible(false);
+ custom.setEnabled(false);
+ actionPanel.setVisible(false);
+ actionPanel.setEnabled(false);
+ }
+ change.getTarget().add(categoryContainer);
+ } else if ("category".equals(changedPanel.getId())) {
+ subcategory.setChoices(filter(eventCategoryTOs, type.getModelObject(), category.getModelObject()));
+ eventCategoryTO.setCategory(category.getModelObject());
+ eventCategoryTO.setSubcategory(null);
+ change.getTarget().add(categoryContainer);
+ } else {
+ eventCategoryTO.setSubcategory(subcategory.getModelObject());
+ }
+
+ updateEventsContainer(change.getTarget());
+ } else if (event.getPayload() instanceof InspectSelectedEvent) {
+ // update objects ....
+ eventCategoryTO.getEvents().clear();
+
+ InspectSelectedEvent inspectSelectedEvent = (InspectSelectedEvent) event.getPayload();
+
+ Pair<EventCategoryTO, AuditElements.Result> categoryEvent =
+ AuditLoggerName.parseEventCategory(inspectSelectedEvent.getEvent());
+
+ eventCategoryTO.setType(categoryEvent.getKey().getType());
+ category.setChoices(filter(eventCategoryTOs, type.getModelObject()));
+
+ eventCategoryTO.setCategory(categoryEvent.getKey().getCategory());
+ subcategory.setChoices(filter(eventCategoryTOs, type.getModelObject(), category.getModelObject()));
+
+ eventCategoryTO.setSubcategory(categoryEvent.getKey().getSubcategory());
+
+ if (categoryEvent.getKey().getType() == EventCategoryType.CUSTOM) {
+ custom.setModelObject(AuditLoggerName.buildEvent(
+ categoryEvent.getKey().getType(),
+ categoryEvent.getKey().getCategory(),
+ categoryEvent.getKey().getSubcategory(),
+ categoryEvent.getKey().getEvents().isEmpty()
+ ? StringUtils.EMPTY : categoryEvent.getKey().getEvents().iterator().next(),
+ categoryEvent.getValue()));
+
+ category.setEnabled(false);
+ subcategory.setEnabled(false);
+ custom.setVisible(true);
+ custom.setEnabled(true);
+ actionPanel.setVisible(true);
+ actionPanel.setEnabled(true);
+ } else {
+ category.setEnabled(true);
+ subcategory.setEnabled(true);
+ custom.setVisible(false);
+ custom.setEnabled(false);
+ actionPanel.setVisible(false);
+ actionPanel.setEnabled(false);
+ }
+
+ inspectSelectedEvent.getTarget().add(categoryContainer);
+ updateEventsContainer(inspectSelectedEvent.getTarget());
+ }
+ }
+
+ private void setEvents() {
+ final Iterator<EventCategoryTO> itor = eventCategoryTOs.iterator();
+ while (itor.hasNext() && eventCategoryTO.getEvents().isEmpty()) {
+ final EventCategoryTO eventCategory = itor.next();
+ if (eventCategory.getType() == eventCategoryTO.getType()
+ && StringUtils.equals(eventCategory.getCategory(), eventCategoryTO.getCategory())
+ && StringUtils.equals(eventCategory.getSubcategory(), eventCategoryTO.getSubcategory())) {
+ eventCategoryTO.getEvents().addAll(eventCategory.getEvents());
+ }
+ }
+ }
+
+ private class ChangeCategoryEvent {
+
+ private final AjaxRequestTarget target;
+
+ private final Panel changedPanel;
+
+ public ChangeCategoryEvent(final AjaxRequestTarget target, final Panel changedPanel) {
+ this.target = target;
+ this.changedPanel = changedPanel;
+ }
+
+ public AjaxRequestTarget getTarget() {
+ return target;
+ }
+
+ public Panel getChangedPanel() {
+ return changedPanel;
+ }
+ }
+
+ /**
+ * To be extended in order to add actions on events.
+ *
+ * @param event event.
+ */
+ protected void onEventAction(final IEvent<?> event) {
+ // nothing by default
+ }
+
+ private void authorizeList() {
+ for (String role : getListRoles()) {
+ MetaDataRoleAuthorizationStrategy.authorize(selectedEventsPanel, RENDER, role);
+ }
+ }
+
+ private void authorizeChanges() {
+ for (String role : getChangeRoles()) {
+ MetaDataRoleAuthorizationStrategy.authorize(categoryContainer, RENDER, role);
+ MetaDataRoleAuthorizationStrategy.authorize(eventsContainer, RENDER, role);
+ }
+ }
+
+ private void updateEventsContainer(final AjaxRequestTarget target) {
+ setEvents();
+
+ eventsContainer.addOrReplace(new EventSelectionPanel("eventsPanel", eventCategoryTO, model) {
+
+ private static final long serialVersionUID = 3513194801190026082L;
+
+ @Override
+ public void onEventAction(final IEvent<?> event) {
+ LoggerCategoryPanel.this.onEventAction(event);
+ }
+ });
+ target.add(eventsContainer);
+ }
+
+ protected abstract String[] getListRoles();
+
+ protected abstract String[] getChangeRoles();
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/MembershipsPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/MembershipsPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/MembershipsPanel.java
new file mode 100644
index 0000000..fa0a9bc
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/MembershipsPanel.java
@@ -0,0 +1,255 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+import javax.swing.tree.DefaultMutableTreeNode;
+import org.apache.syncope.client.console.commons.Mode;
+import org.apache.syncope.client.console.commons.GroupTreeBuilder;
+import org.apache.syncope.client.console.commons.status.StatusUtils;
+import org.apache.syncope.client.console.pages.MembershipModalPage;
+import org.apache.syncope.client.console.pages.UserModalPage;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.IndicatingOnConfirmAjaxLink;
+import org.apache.syncope.client.console.wicket.markup.html.tree.DefaultMutableTreeNodeExpansion;
+import org.apache.syncope.client.console.wicket.markup.html.tree.DefaultMutableTreeNodeExpansionModel;
+import org.apache.syncope.client.console.wicket.markup.html.tree.TreeGroupProvider;
+import org.apache.syncope.common.lib.to.MembershipTO;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.Component;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.markup.html.repeater.tree.DefaultNestedTree;
+import org.apache.wicket.extensions.markup.html.repeater.tree.ITreeProvider;
+import org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree;
+import org.apache.wicket.extensions.markup.html.repeater.tree.content.Folder;
+import org.apache.wicket.extensions.markup.html.repeater.tree.theme.WindowsTheme;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class MembershipsPanel extends Panel {
+
+ private static final long serialVersionUID = -2559791301973107191L;
+
+ @SpringBean
+ private GroupTreeBuilder groupTreeBuilder;
+
+ private final ListView<MembershipTO> membView;
+
+ private final UserTO userTO;
+
+ private final StatusPanel statusPanel;
+
+ private final NestedTree<DefaultMutableTreeNode> tree;
+
+ public MembershipsPanel(final String id, final UserTO userTO, final Mode mode,
+ final StatusPanel statusPanel, final PageReference pageRef) {
+
+ super(id);
+ this.userTO = userTO;
+ this.statusPanel = statusPanel;
+
+ final WebMarkupContainer membershipsContainer = new WebMarkupContainer("membershipsContainer");
+ membershipsContainer.setOutputMarkupId(true);
+ add(membershipsContainer);
+
+ final ModalWindow membWin = new ModalWindow("membershipWin");
+ membWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ membWin.setCookieName("create-membership-modal");
+ add(membWin);
+
+ final ITreeProvider<DefaultMutableTreeNode> treeProvider = new TreeGroupProvider(groupTreeBuilder, true);
+ final DefaultMutableTreeNodeExpansionModel treeModel = new DefaultMutableTreeNodeExpansionModel();
+
+ tree = new DefaultNestedTree<DefaultMutableTreeNode>("treeTable", treeProvider, treeModel) {
+
+ private static final long serialVersionUID = 7137658050662575546L;
+
+ @Override
+ protected Component newContentComponent(final String id, final IModel<DefaultMutableTreeNode> node) {
+ final DefaultMutableTreeNode treeNode = node.getObject();
+ final GroupTO groupTO = (GroupTO) treeNode.getUserObject();
+
+ return new Folder<DefaultMutableTreeNode>(id, MembershipsPanel.this.tree, node) {
+
+ private static final long serialVersionUID = 9046323319920426493L;
+
+ @Override
+ protected boolean isClickable() {
+ return true;
+ }
+
+ @Override
+ protected IModel<?> newLabelModel(final IModel<DefaultMutableTreeNode> model) {
+ return new Model<String>(groupTO.getDisplayName());
+ }
+
+ @Override
+ protected void onClick(final AjaxRequestTarget target) {
+ if (groupTO.getKey() > 0) {
+ membWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = 7661763358801821185L;
+
+ @Override
+ public Page createPage() {
+ PageReference pageRef = getPage().getPageReference();
+
+ for (MembershipTO membTO : membView.getList()) {
+ if (membTO.getGroupKey() == groupTO.getKey()) {
+ return new MembershipModalPage(pageRef, membWin, membTO, mode);
+ }
+ }
+ MembershipTO membTO = new MembershipTO();
+ membTO.setGroupKey(groupTO.getKey());
+ membTO.setGroupName(groupTO.getName());
+
+ return new MembershipModalPage(pageRef, membWin, membTO, mode);
+ }
+ });
+ membWin.show(target);
+ }
+ }
+ };
+ }
+ };
+ tree.add(new WindowsTheme());
+ tree.setOutputMarkupId(true);
+
+ DefaultMutableTreeNodeExpansion.get().expandAll();
+
+ this.add(tree);
+
+ membView = new ListView<MembershipTO>("memberships",
+ new PropertyModel<List<? extends MembershipTO>>(userTO, "memberships")) {
+
+ private static final long serialVersionUID = 9101744072914090143L;
+
+ @Override
+ protected void populateItem(final ListItem<MembershipTO> item) {
+ final MembershipTO membershipTO = (MembershipTO) item.getDefaultModelObject();
+
+ item.add(new Label("groupId", new Model<Long>(membershipTO.getGroupKey())));
+ item.add(new Label("groupName", new Model<String>(membershipTO.getGroupName())));
+
+ AjaxLink editLink = new ClearIndicatingAjaxLink("editLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ membWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new MembershipModalPage(getPage().getPageReference(), membWin,
+ membershipTO, mode);
+
+ }
+ });
+ membWin.show(target);
+ }
+ };
+ item.add(editLink);
+
+ AjaxLink deleteLink = new IndicatingOnConfirmAjaxLink("deleteLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ userTO.getMemberships().remove(membershipTO);
+ ((UserModalPage) getPage()).getUserTO().getMemberships().remove(membershipTO);
+ target.add(membershipsContainer);
+
+ GroupTO groupTO = groupTreeBuilder.findGroup(membershipTO.getGroupKey());
+ Set<String> resourcesToRemove = groupTO == null
+ ? Collections.<String>emptySet() : groupTO.getResources();
+ if (!resourcesToRemove.isEmpty()) {
+ Set<String> resourcesAssignedViaMembership = new HashSet<>();
+ for (MembershipTO membTO : userTO.getMemberships()) {
+ groupTO = groupTreeBuilder.findGroup(membTO.getGroupKey());
+ if (groupTO != null) {
+ resourcesAssignedViaMembership.addAll(groupTO.getResources());
+ }
+ }
+ resourcesToRemove.removeAll(resourcesAssignedViaMembership);
+ resourcesToRemove.removeAll(userTO.getResources());
+ }
+
+ StatusUtils.update(
+ userTO, statusPanel, target, Collections.<String>emptySet(), resourcesToRemove);
+ }
+ };
+ item.add(deleteLink);
+ }
+ };
+
+ membershipsContainer.add(membView);
+
+ setWindowClosedCallback(membWin, membershipsContainer);
+ }
+
+ private void setWindowClosedCallback(final ModalWindow window, final WebMarkupContainer container) {
+ window.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
+
+ private static final long serialVersionUID = 8804221891699487139L;
+
+ @Override
+ public void onClose(final AjaxRequestTarget target) {
+ final UserTO updatedUserTO = ((UserModalPage) getPage()).getUserTO();
+ if (!userTO.equals(updatedUserTO)) {
+ if (updatedUserTO.getMemberships().size() > userTO.getMemberships().size()) {
+ Set<Long> diff = new HashSet<Long>(updatedUserTO.getMembershipMap().keySet());
+ diff.removeAll(userTO.getMembershipMap().keySet());
+
+ Set<String> resourcesToAdd = new HashSet<>();
+ for (Long diffMembId : diff) {
+ long groupId = updatedUserTO.getMembershipMap().get(diffMembId).getGroupKey();
+ GroupTO groupTO = groupTreeBuilder.findGroup(groupId);
+ resourcesToAdd.addAll(groupTO.getResources());
+ StatusUtils.update(
+ userTO, statusPanel, target, resourcesToAdd, Collections.<String>emptySet());
+ }
+ }
+
+ MembershipsPanel.this.userTO.getMemberships().clear();
+ MembershipsPanel.this.userTO.getMemberships().addAll(updatedUserTO.getMemberships());
+ target.add(container);
+ }
+ }
+ });
+ }
+}
[43/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/StatusModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/StatusModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/StatusModalPage.java
deleted file mode 100644
index cab0e04..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/StatusModalPage.java
+++ /dev/null
@@ -1,641 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Collections;
-import java.util.List;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.status.AbstractStatusBeanProvider;
-import org.apache.syncope.client.console.commons.status.ConnObjectWrapper;
-import org.apache.syncope.client.console.commons.status.Status;
-import org.apache.syncope.client.console.commons.status.StatusBean;
-import org.apache.syncope.client.console.commons.status.StatusUtils;
-import org.apache.syncope.client.console.panels.ActionDataTablePanel;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
-import org.apache.syncope.common.lib.to.AbstractSubjectTO;
-import org.apache.syncope.common.lib.to.BulkActionResult;
-import org.apache.syncope.common.lib.to.ResourceTO;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.syncope.common.lib.types.ResourceAssociationActionType;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.ISortableDataProvider;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.markup.ComponentTag;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.form.PasswordTextField;
-import org.apache.wicket.markup.html.panel.Fragment;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.model.StringResourceModel;
-
-public class StatusModalPage<T extends AbstractSubjectTO> extends AbstractStatusModalPage {
-
- private static final long serialVersionUID = -9148734710505211261L;
-
- private final AbstractSubjectTO subjectTO;
-
- private int rowsPerPage = 10;
-
- final StatusUtils statusUtils;
-
- final boolean statusOnly;
-
- // --------------------------------
- // password management fields ..
- // --------------------------------
- final ClearIndicatingAjaxButton cancel;
-
- final WebMarkupContainer pwdMgt;
-
- final Form<?> pwdMgtForm;
-
- final AjaxCheckBoxPanel changepwd;
-
- final PasswordTextField password;
-
- final PasswordTextField confirm;
- // --------------------------------
-
- final PageReference pageRef;
-
- final ModalWindow window;
-
- final ActionDataTablePanel<StatusBean, String> table;
-
- final List<IColumn<StatusBean, String>> columns;
-
- public StatusModalPage(
- final PageReference pageRef,
- final ModalWindow window,
- final AbstractSubjectTO attributableTO) {
-
- this(pageRef, window, attributableTO, false);
- }
-
- public StatusModalPage(
- final PageReference pageRef,
- final ModalWindow window,
- final AbstractSubjectTO subjectTO,
- final boolean statusOnly) {
-
- super();
-
- this.pageRef = pageRef;
- this.window = window;
- this.statusOnly = statusOnly;
- this.subjectTO = subjectTO;
-
- statusUtils = new StatusUtils(subjectTO instanceof UserTO ? userRestClient : groupRestClient);
-
- add(new Label("displayName", subjectTO.getKey() + " "
- + (subjectTO instanceof UserTO ? ((UserTO) subjectTO).getUsername() : ((GroupTO) subjectTO).getName())));
-
- columns = new ArrayList<>();
- columns.add(new AbstractColumn<StatusBean, String>(
- new StringResourceModel("resourceName", this, null, "Resource name"), "resourceName") {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public void populateItem(
- final Item<ICellPopulator<StatusBean>> cellItem,
- final String componentId,
- final IModel<StatusBean> model) {
-
- cellItem.add(new Label(componentId, model.getObject().getResourceName()) {
-
- private static final long serialVersionUID = 8432079838783825801L;
-
- @Override
- protected void onComponentTag(final ComponentTag tag) {
- if (model.getObject().isLinked()) {
- super.onComponentTag(tag);
- } else {
- tag.put("style", "color: #DDDDDD");
- }
- }
- });
- }
- });
-
- columns.add(new PropertyColumn<StatusBean, String>(
- new StringResourceModel("accountLink", this, null, "Account link"), "accountLink", "accountLink"));
-
- columns.add(new AbstractColumn<StatusBean, String>(
- new StringResourceModel("status", this, null, "")) {
-
- private static final long serialVersionUID = -3503023501954863131L;
-
- @Override
- public String getCssClass() {
- return "action";
- }
-
- @Override
- public void populateItem(
- final Item<ICellPopulator<StatusBean>> cellItem,
- final String componentId,
- final IModel<StatusBean> model) {
-
- if (model.getObject().isLinked()) {
- cellItem.add(statusUtils.getStatusImagePanel(componentId, model.getObject().
- getStatus()));
- } else {
- cellItem.add(new Label(componentId, ""));
- }
- }
- });
-
- table = new ActionDataTablePanel<StatusBean, String>(
- "resourceDatatable",
- columns,
- (ISortableDataProvider<StatusBean, String>) new AttributableStatusProvider(),
- rowsPerPage,
- pageRef) {
-
- private static final long serialVersionUID = 6510391461033818316L;
-
- @Override
- public boolean isElementEnabled(final StatusBean element) {
- return !statusOnly || element.getStatus() != Status.OBJECT_NOT_FOUND;
- }
- };
- table.setOutputMarkupId(true);
-
- final String pageId = subjectTO instanceof GroupTO ? "Groups" : "Users";
-
- final Fragment pwdMgtFragment = new Fragment("pwdMgtFields", "pwdMgtFragment", this);
- addOrReplace(pwdMgtFragment);
-
- pwdMgt = new WebMarkupContainer("pwdMgt");
- pwdMgtFragment.add(pwdMgt.setOutputMarkupId(true));
-
- pwdMgtForm = new Form("pwdMgtForm");
- pwdMgtForm.setVisible(false).setEnabled(false);
- pwdMgt.add(pwdMgtForm);
-
- password = new PasswordTextField("password", new Model<String>());
- pwdMgtForm.add(password.setRequired(false).setEnabled(false));
-
- confirm = new PasswordTextField("confirm", new Model<String>());
- pwdMgtForm.add(confirm.setRequired(false).setEnabled(false));
-
- changepwd = new AjaxCheckBoxPanel("changepwd", "changepwd", new Model<Boolean>(false));
- pwdMgtForm.add(changepwd.setModelObject(false));
- pwdMgtForm.add(new Label("changePwdLabel", new ResourceModel("changePwdLabel", "Password propagation")));
-
- changepwd.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- password.setEnabled(changepwd.getModelObject());
- confirm.setEnabled(changepwd.getModelObject());
- target.add(pwdMgt);
- }
- });
-
- cancel = new ClearIndicatingAjaxButton("cancel", new ResourceModel("cancel"), pageRef) {
-
- private static final long serialVersionUID = -2341391430136818026L;
-
- @Override
- protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
- // ignore
- window.close(target);
- }
- }.feedbackPanelAutomaticReload(false);
-
- pwdMgtForm.add(cancel);
-
- final ClearIndicatingAjaxButton goon =
- new ClearIndicatingAjaxButton("continue", new ResourceModel("continue"), pageRef) {
-
- private static final long serialVersionUID = -2341391430136818027L;
-
- @Override
- protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
- // none
- }
- };
-
- pwdMgtForm.add(goon);
-
- if (statusOnly) {
- table.addAction(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- userRestClient.reactivate(
- subjectTO.getETagValue(),
- subjectTO.getKey(),
- new ArrayList<>(table.getModelObject()));
-
- ((BasePage) pageRef.getPage()).setModalResult(true);
-
- window.close(target);
- } catch (Exception e) {
- LOG.error("Error enabling resources", e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
- }, ActionLink.ActionType.REACTIVATE, pageId);
-
- table.addAction(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- userRestClient.suspend(
- subjectTO.getETagValue(),
- subjectTO.getKey(),
- new ArrayList<>(table.getModelObject()));
-
- if (pageRef.getPage() instanceof BasePage) {
- ((BasePage) pageRef.getPage()).setModalResult(true);
- }
-
- window.close(target);
- } catch (Exception e) {
- LOG.error("Error disabling resources", e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
- }, ActionLink.ActionType.SUSPEND, pageId);
- } else {
- table.addAction(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- if (subjectTO instanceof UserTO) {
- userRestClient.unlink(
- subjectTO.getETagValue(),
- subjectTO.getKey(),
- new ArrayList<>(table.getModelObject()));
- } else {
- groupRestClient.unlink(
- subjectTO.getETagValue(),
- subjectTO.getKey(),
- new ArrayList<>(table.getModelObject()));
- }
-
- ((BasePage) pageRef.getPage()).setModalResult(true);
- window.close(target);
- } catch (Exception e) {
- LOG.error("Error unlinking resources", e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
- }, ActionLink.ActionType.UNLINK, pageId);
-
- table.addAction(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- if (subjectTO instanceof UserTO) {
- userRestClient.link(
- subjectTO.getETagValue(),
- subjectTO.getKey(),
- new ArrayList<>(table.getModelObject()));
- } else {
- groupRestClient.link(
- subjectTO.getETagValue(),
- subjectTO.getKey(),
- new ArrayList<>(table.getModelObject()));
- }
-
- ((BasePage) pageRef.getPage()).setModalResult(true);
- window.close(target);
- } catch (Exception e) {
- LOG.error("Error linking resources", e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
- }, ActionLink.ActionType.LINK, pageId);
-
- table.addAction(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- BulkActionResult bulkActionResult;
- if (subjectTO instanceof UserTO) {
- bulkActionResult = userRestClient.deprovision(
- subjectTO.getETagValue(),
- subjectTO.getKey(),
- new ArrayList<>(table.getModelObject()));
- } else {
- bulkActionResult = groupRestClient.deprovision(
- subjectTO.getETagValue(),
- subjectTO.getKey(),
- new ArrayList<>(table.getModelObject()));
- }
-
- ((BasePage) pageRef.getPage()).setModalResult(true);
- loadBulkActionResultPage(table.getModelObject(), bulkActionResult);
- } catch (Exception e) {
- LOG.error("Error de-provisioning user", e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
- }, ActionLink.ActionType.DEPROVISION, pageId);
-
- table.addAction(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
-
- if (subjectTO instanceof UserTO) {
- StatusModalPage.this.passwordManagement(
- target, ResourceAssociationActionType.PROVISION, table.getModelObject());
- } else {
- try {
- final BulkActionResult bulkActionResult = groupRestClient.provision(
- subjectTO.getETagValue(),
- subjectTO.getKey(),
- new ArrayList<>(table.getModelObject()));
-
- ((BasePage) pageRef.getPage()).setModalResult(true);
- loadBulkActionResultPage(table.getModelObject(), bulkActionResult);
- } catch (Exception e) {
- LOG.error("Error provisioning user", e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
- }
- }.feedbackPanelAutomaticReload(!(subjectTO instanceof UserTO)), ActionLink.ActionType.PROVISION, pageId);
-
- table.addAction(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- final BulkActionResult bulkActionResult;
- if (subjectTO instanceof UserTO) {
- bulkActionResult = userRestClient.unassign(
- subjectTO.getETagValue(),
- subjectTO.getKey(),
- new ArrayList<>(table.getModelObject()));
- } else {
- bulkActionResult = groupRestClient.unassign(
- subjectTO.getETagValue(),
- subjectTO.getKey(),
- new ArrayList<>(table.getModelObject()));
- }
-
- ((BasePage) pageRef.getPage()).setModalResult(true);
- loadBulkActionResultPage(table.getModelObject(), bulkActionResult);
- } catch (Exception e) {
- LOG.error("Error unassigning resources", e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
- }, ActionLink.ActionType.UNASSIGN, pageId);
-
- table.addAction(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- if (subjectTO instanceof UserTO) {
- StatusModalPage.this.passwordManagement(
- target, ResourceAssociationActionType.ASSIGN, table.getModelObject());
- } else {
- try {
- final BulkActionResult bulkActionResult = groupRestClient.assign(
- subjectTO.getETagValue(),
- subjectTO.getKey(),
- new ArrayList<>(table.getModelObject()));
-
- ((BasePage) pageRef.getPage()).setModalResult(true);
- loadBulkActionResultPage(table.getModelObject(), bulkActionResult);
- } catch (Exception e) {
- LOG.error("Error assigning resources", e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
- }
- }.feedbackPanelAutomaticReload(!(subjectTO instanceof UserTO)), ActionLink.ActionType.ASSIGN, pageId);
- }
-
- table.addCancelButton(window);
- add(table);
- }
-
- private class AttributableStatusProvider extends AbstractStatusBeanProvider {
-
- private static final long serialVersionUID = 4586969457669796621L;
-
- public AttributableStatusProvider() {
- super(statusOnly ? "resourceName" : "accountLink");
- }
-
- @SuppressWarnings("unchecked")
- @Override
- public List<StatusBean> getStatusBeans() {
- final List<String> resources = new ArrayList<>();
- for (ResourceTO resourceTO : resourceRestClient.getAll()) {
- resources.add(resourceTO.getKey());
- }
-
- final List<ConnObjectWrapper> connObjects = statusUtils.getConnectorObjects(subjectTO);
-
- final List<StatusBean> statusBeans = new ArrayList<StatusBean>(connObjects.size() + 1);
-
- for (ConnObjectWrapper entry : connObjects) {
- final StatusBean statusBean = statusUtils.getStatusBean(subjectTO,
- entry.getResourceName(),
- entry.getConnObjectTO(),
- subjectTO instanceof GroupTO);
-
- statusBeans.add(statusBean);
- resources.remove(entry.getResourceName());
- }
-
- if (statusOnly) {
- final StatusBean syncope = new StatusBean(subjectTO, "Syncope");
-
- syncope.setAccountLink(((UserTO) subjectTO).getUsername());
-
- Status syncopeStatus = Status.UNDEFINED;
- if (((UserTO) subjectTO).getStatus() != null) {
- try {
- syncopeStatus = Status.valueOf(((UserTO) subjectTO).getStatus().toUpperCase());
- } catch (IllegalArgumentException e) {
- LOG.warn("Unexpected status found: {}", ((UserTO) subjectTO).getStatus(), e);
- }
- }
- syncope.setStatus(syncopeStatus);
-
- statusBeans.add(syncope);
- } else {
- for (String resource : resources) {
- final StatusBean statusBean = statusUtils.getStatusBean(subjectTO,
- resource,
- null,
- subjectTO instanceof GroupTO);
-
- statusBean.setLinked(false);
- statusBeans.add(statusBean);
- }
- }
-
- return statusBeans;
- }
- }
-
- private void passwordManagement(
- final AjaxRequestTarget target,
- final ResourceAssociationActionType type,
- final Collection<StatusBean> selection) {
-
- final ClearIndicatingAjaxButton goon =
- new ClearIndicatingAjaxButton("continue", new ResourceModel("continue", "Continue"), pageRef) {
-
- private static final long serialVersionUID = -2341391430136818027L;
-
- @Override
- protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
- try {
- if (StringUtils.isNotBlank(password.getModelObject())
- && !password.getModelObject().equals(confirm.getModelObject())) {
- throw new Exception(getString("passwordMismatch"));
- }
-
- final BulkActionResult bulkActionResult;
- switch (type) {
- case ASSIGN:
- bulkActionResult = userRestClient.assign(
- subjectTO.getETagValue(),
- subjectTO.getKey(),
- new ArrayList<>(selection),
- changepwd.getModelObject(),
- password.getModelObject());
- break;
- case PROVISION:
- bulkActionResult = userRestClient.provision(
- subjectTO.getETagValue(),
- subjectTO.getKey(),
- new ArrayList<>(selection),
- changepwd.getModelObject(),
- password.getModelObject());
- break;
- default:
- bulkActionResult = null;
- // ignore
- }
-
- ((BasePage) pageRef.getPage()).setModalResult(true);
-
- if (bulkActionResult != null) {
- loadBulkActionResultPage(selection, bulkActionResult);
- } else {
-
- target.add(((BasePage) pageRef.getPage()).getFeedbackPanel());
- window.close(target);
- }
- } catch (Exception e) {
- LOG.error("Error provisioning resources", e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
- }.feedbackPanelAutomaticReload(false);
-
- pwdMgtForm.addOrReplace(goon);
-
- table.setVisible(false);
- pwdMgtForm.setVisible(true).setEnabled(true);
-
- target.add(table);
- target.add(pwdMgt);
- }
-
- private void loadBulkActionResultPage(
- final Collection<StatusBean> selection, final BulkActionResult bulkActionResult) {
- final List<String> resources = new ArrayList<String>(selection.size());
- for (StatusBean statusBean : selection) {
- resources.add(statusBean.getResourceName());
- }
-
- final List<ConnObjectWrapper> connObjects =
- statusUtils.getConnectorObjects(Collections.singletonList(subjectTO), resources);
-
- final List<StatusBean> statusBeans = new ArrayList<StatusBean>(connObjects.size());
-
- for (ConnObjectWrapper entry : connObjects) {
- final StatusBean statusBean = statusUtils.getStatusBean(subjectTO,
- entry.getResourceName(),
- entry.getConnObjectTO(),
- subjectTO instanceof GroupTO);
-
- statusBeans.add(statusBean);
- }
-
- setResponsePage(new BulkActionResultModalPage<StatusBean, String>(
- window,
- statusBeans,
- columns,
- bulkActionResult,
- "resourceName"));
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/SyncTaskModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/SyncTaskModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/SyncTaskModalPage.java
deleted file mode 100644
index 544f670..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/SyncTaskModalPage.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.List;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
-import org.apache.syncope.common.lib.to.SchedTaskTO;
-import org.apache.syncope.common.lib.to.SyncTaskTO;
-import org.apache.syncope.common.lib.types.MatchingRule;
-import org.apache.syncope.common.lib.types.UnmatchingRule;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.model.PropertyModel;
-
-/**
- * Modal window with Sync Task form.
- */
-public class SyncTaskModalPage extends AbstractSyncTaskModalPage {
-
- private static final long serialVersionUID = 2148403203517274669L;
-
- public SyncTaskModalPage(final ModalWindow window, final SyncTaskTO taskTO, final PageReference pageRef) {
-
- super(window, taskTO, pageRef);
-
- // set default Matching rule
- ((DropDownChoice) matchingRule.getField()).setDefaultModelObject(taskTO.getMatchingRule() == null
- ? MatchingRule.UPDATE
- : taskTO.getMatchingRule());
- profile.add(matchingRule);
-
- // set default Unmatching rule
- ((DropDownChoice) unmatchingRule.getField()).setDefaultModelObject(taskTO.getUnmatchingRule() == null
- ? UnmatchingRule.PROVISION
- : taskTO.getUnmatchingRule());
- profile.add(unmatchingRule);
-
- final AjaxCheckBoxPanel fullReconciliation = new AjaxCheckBoxPanel("fullReconciliation",
- getString("fullReconciliation"), new PropertyModel<Boolean>(taskTO, "fullReconciliation"));
- profile.add(fullReconciliation);
- }
-
- @Override
- protected List<String> getSyncActions() {
- return taskRestClient.getSyncActionsClasses();
- }
-
- @Override
- public void submitAction(final SchedTaskTO taskTO) {
- if (taskTO.getKey() > 0) {
- taskRestClient.updateSyncTask((SyncTaskTO) taskTO);
- } else {
- taskRestClient.createSyncTask((SyncTaskTO) taskTO);
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/TaskModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/TaskModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/TaskModalPage.java
deleted file mode 100644
index c251d87..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/TaskModalPage.java
+++ /dev/null
@@ -1,253 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.AbstractTaskTO;
-import org.apache.syncope.common.lib.to.NotificationTaskTO;
-import org.apache.syncope.common.lib.to.PropagationTaskTO;
-import org.apache.syncope.common.lib.to.SchedTaskTO;
-import org.apache.syncope.common.lib.to.SyncTaskTO;
-import org.apache.syncope.common.lib.to.TaskExecTO;
-import org.apache.wicket.Component;
-import org.apache.wicket.Page;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
-import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.AbstractReadOnlyModel;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.springframework.util.StringUtils;
-
-/**
- * Modal window with Task form (to stop and start execution).
- */
-public abstract class TaskModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = -4110576026663173545L;
-
- protected WebMarkupContainer profile;
-
- protected WebMarkupContainer executions;
-
- protected Form<AbstractTaskTO> form;
-
- public TaskModalPage(final AbstractTaskTO taskTO) {
- final ModalWindow taskExecMessageWin = new ModalWindow("taskExecMessageWin");
- taskExecMessageWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- taskExecMessageWin.setCookieName("task-exec-message-win-modal");
- add(taskExecMessageWin);
-
- form = new Form<>(FORM);
- form.setModel(new CompoundPropertyModel<>(taskTO));
- add(form);
-
- profile = new WebMarkupContainer("profile");
- profile.setOutputMarkupId(true);
- form.add(profile);
-
- executions = new WebMarkupContainer("executionContainer");
- executions.setOutputMarkupId(true);
- form.add(executions);
-
- final Label idLabel = new Label("idLabel", new ResourceModel("key"));
- profile.add(idLabel);
-
- final AjaxTextFieldPanel id =
- new AjaxTextFieldPanel("key", getString("key"), new PropertyModel<String>(taskTO, "key"));
-
- id.setEnabled(false);
- profile.add(id);
-
- final List<IColumn<TaskExecTO, String>> columns = new ArrayList<>();
-
- final int paginatorRows = 10;
-
- columns.add(new PropertyColumn<TaskExecTO, String>(new ResourceModel("key"), "key", "key"));
- columns.add(new DatePropertyColumn<TaskExecTO>(new ResourceModel("startDate"), "startDate", "startDate"));
- columns.add(new DatePropertyColumn<TaskExecTO>(new ResourceModel("endDate"), "endDate", "endDate"));
- columns.add(new PropertyColumn<TaskExecTO, String>(new ResourceModel("status"), "status", "status"));
- columns.add(new ActionColumn<TaskExecTO, String>(new ResourceModel("actions", "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public ActionLinksPanel getActions(final String componentId, final IModel<TaskExecTO> model) {
-
- final TaskExecTO taskExecutionTO = model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- taskExecMessageWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ExecMessageModalPage(model.getObject().getMessage());
- }
- });
- taskExecMessageWin.show(target);
- }
- }, ActionLink.ActionType.EDIT, TASKS, StringUtils.hasText(model.getObject().getMessage()));
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- taskRestClient.deleteExecution(taskExecutionTO.getKey());
-
- taskTO.getExecutions().remove(taskExecutionTO);
-
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
-
- feedbackPanel.refresh(target);
- target.add(executions);
- }
- }, ActionLink.ActionType.DELETE, TASKS);
-
- return panel;
- }
-
- @Override
- public Component getHeader(final String componentId) {
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), getPageReference());
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- if (target != null) {
- final AjaxFallbackDefaultDataTable<TaskExecTO, String> currentTable =
- new AjaxFallbackDefaultDataTable<TaskExecTO, String>("executionsTable", columns,
- new TaskExecutionsProvider(getCurrentTaskExecution(taskTO)), paginatorRows);
- currentTable.setOutputMarkupId(true);
- target.add(currentTable);
- executions.addOrReplace(currentTable);
- }
- }
- }, ActionLink.ActionType.RELOAD, TASKS, "list");
-
- return panel;
- }
- });
-
- final AjaxFallbackDefaultDataTable<TaskExecTO, String> table =
- new AjaxFallbackDefaultDataTable<TaskExecTO, String>("executionsTable", columns,
- new TaskExecutionsProvider(getCurrentTaskExecution(taskTO)), paginatorRows);
-
- executions.add(table);
- }
-
- protected static class TaskExecutionsProvider extends SortableDataProvider<TaskExecTO, String> {
-
- private static final long serialVersionUID = 8943636537120648961L;
-
- private SortableDataProviderComparator<TaskExecTO> comparator;
-
- private AbstractTaskTO taskTO;
-
- public TaskExecutionsProvider(final AbstractTaskTO taskTO) {
- //Default sorting
- this.taskTO = taskTO;
- setSort("startDate", SortOrder.DESCENDING);
- comparator = new SortableDataProviderComparator<TaskExecTO>(this);
- }
-
- @Override
- public Iterator<TaskExecTO> iterator(final long first, final long count) {
-
- List<TaskExecTO> list = taskTO.getExecutions();
-
- Collections.sort(list, comparator);
-
- return list.subList((int) first, (int) first + (int) count).iterator();
- }
-
- @Override
- public long size() {
- return taskTO.getExecutions().size();
- }
-
- @Override
- public IModel<TaskExecTO> model(final TaskExecTO taskExecution) {
-
- return new AbstractReadOnlyModel<TaskExecTO>() {
-
- private static final long serialVersionUID = 7485475149862342421L;
-
- @Override
- public TaskExecTO getObject() {
- return taskExecution;
- }
- };
- }
- }
-
- private AbstractTaskTO getCurrentTaskExecution(final AbstractTaskTO taskTO) {
- final AbstractTaskTO currentTask = taskTO.getKey() == 0
- ? taskTO
- : taskTO instanceof PropagationTaskTO
- ? taskRestClient.readPropagationTask(taskTO.getKey())
- : taskTO instanceof NotificationTaskTO
- ? taskRestClient.readNotificationTask(taskTO.getKey())
- : taskTO instanceof SyncTaskTO
- ? taskRestClient.readSchedTask(SyncTaskTO.class, taskTO.getKey())
- : taskRestClient.readSchedTask(SchedTaskTO.class, taskTO.getKey());
-
- taskTO.getExecutions().clear();
- taskTO.getExecutions().addAll(currentTask.getExecutions());
- return taskTO;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/Tasks.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/Tasks.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/Tasks.java
deleted file mode 100644
index 296c365..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/Tasks.java
+++ /dev/null
@@ -1,230 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.Iterator;
-import java.util.List;
-import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
-import org.apache.syncope.client.console.panels.AjaxDataTablePanel;
-import org.apache.syncope.client.console.panels.NotificationTasks;
-import org.apache.syncope.client.console.panels.PropagationTasks;
-import org.apache.syncope.client.console.panels.PushTasksPanel;
-import org.apache.syncope.client.console.panels.SchedTasks;
-import org.apache.syncope.client.console.panels.SyncTasksPanel;
-import org.apache.syncope.client.console.rest.BaseRestClient;
-import org.apache.syncope.client.console.rest.TaskRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.common.lib.to.AbstractTaskTO;
-import org.apache.syncope.common.lib.to.SchedTaskTO;
-import org.apache.syncope.common.lib.to.TaskExecTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.ISortableDataProvider;
-import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.model.AbstractReadOnlyModel;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.IModel;
-
-public class Tasks extends BasePage {
-
- private static final long serialVersionUID = 5289215853622289061L;
-
- public Tasks() {
- super();
-
- add(new PropagationTasks("propagation", getPageReference()));
- add(new NotificationTasks("notification", getPageReference()));
- add(new SchedTasks("sched", getPageReference()));
- add(new SyncTasksPanel("sync", getPageReference()));
- add(new PushTasksPanel("push", getPageReference()));
-
- getPageReference();
- }
-
- @Override
- public void setWindowClosedCallback(final ModalWindow window, final WebMarkupContainer container) {
-
- super.setWindowClosedCallback(window, container);
- }
-
- public static class TaskExecutionsProvider extends SortableDataProvider<TaskExecTO, String> {
-
- private static final long serialVersionUID = -5401263348984206145L;
-
- private SortableDataProviderComparator<TaskExecTO> comparator;
-
- private AbstractTaskTO taskTO;
-
- public TaskExecutionsProvider(final AbstractTaskTO taskTO) {
- super();
-
- //Default sorting
- this.taskTO = taskTO;
- setSort("startDate", SortOrder.DESCENDING);
- comparator = new SortableDataProviderComparator<TaskExecTO>(this);
- }
-
- @Override
- public Iterator<TaskExecTO> iterator(final long first, final long count) {
-
- List<TaskExecTO> list = getTaskDB();
-
- Collections.sort(list, comparator);
-
- return list.subList((int) first, (int) first + (int) count).iterator();
- }
-
- @Override
- public long size() {
- return getTaskDB().size();
- }
-
- @Override
- public IModel<TaskExecTO> model(final TaskExecTO taskExecution) {
-
- return new AbstractReadOnlyModel<TaskExecTO>() {
-
- private static final long serialVersionUID = 7485475149862342421L;
-
- @Override
- public TaskExecTO getObject() {
- return taskExecution;
- }
- };
- }
-
- public List<TaskExecTO> getTaskDB() {
- return taskTO.getExecutions();
- }
- }
-
- public static class TasksProvider<T extends AbstractTaskTO> extends SortableDataProvider<T, String> {
-
- private static final long serialVersionUID = -20112718133295756L;
-
- private SortableDataProviderComparator<T> comparator;
-
- private TaskRestClient restClient;
-
- private int paginatorRows;
-
- private String id;
-
- private Class<T> reference;
-
- public TasksProvider(
- final TaskRestClient restClient, final int paginatorRows, final String id, final Class<T> reference) {
-
- super();
-
- //Default sorting
- setSort("key", SortOrder.DESCENDING);
- comparator = new SortableDataProviderComparator<>(this);
- this.paginatorRows = paginatorRows;
- this.restClient = restClient;
- this.id = id;
- this.reference = reference;
- }
-
- @Override
- public Iterator<T> iterator(final long first, final long count) {
- final List<T> tasks = new ArrayList<>();
-
- final int page = ((int) first / paginatorRows);
-
- for (T task : restClient.list(reference, (page < 0 ? 0 : page) + 1, paginatorRows, getSort())) {
- if (task instanceof SchedTaskTO && ((SchedTaskTO) task).getLastExec() == null
- && task.getExecutions() != null && !task.getExecutions().isEmpty()) {
-
- Collections.sort(task.getExecutions(), new Comparator<TaskExecTO>() {
-
- @Override
- public int compare(final TaskExecTO left, final TaskExecTO right) {
- return left.getStartDate().compareTo(right.getStartDate());
- }
- });
-
- ((SchedTaskTO) task).setLastExec(task.getExecutions().get(task.getExecutions().size() - 1).
- getStartDate());
- }
- tasks.add(task);
- }
-
- Collections.sort(tasks, comparator);
- return tasks.iterator();
- }
-
- @Override
- public long size() {
- return restClient.count(id);
- }
-
- @Override
- public IModel<T> model(final T object) {
- return new CompoundPropertyModel<>(object);
- }
- }
-
- /**
- * Update task table.
- *
- * @param columns columns.
- * @param dataProvider data provider.
- * @param container container.
- * @param currentPage current page index.
- * @param pageRef page reference
- * @param restClient syncope base rest client
- * @return data table.
- */
- public static AjaxDataTablePanel<AbstractTaskTO, String> updateTaskTable(
- final List<IColumn<AbstractTaskTO, String>> columns,
- final TasksProvider<? extends AbstractTaskTO> dataProvider,
- final WebMarkupContainer container,
- final int currentPage,
- final PageReference pageRef,
- final BaseRestClient restClient) {
-
- @SuppressWarnings("unchecked")
- final AjaxDataTablePanel<AbstractTaskTO, String> table = new AjaxDataTablePanel<>(
- "datatable",
- columns,
- (ISortableDataProvider<AbstractTaskTO, String>) dataProvider,
- dataProvider.paginatorRows,
- Arrays.asList(new ActionLink.ActionType[] {
- ActionLink.ActionType.DELETE, ActionLink.ActionType.DRYRUN, ActionLink.ActionType.EXECUTE }),
- restClient,
- "key",
- TASKS,
- pageRef);
-
- table.setCurrentPage(currentPage);
- table.setOutputMarkupId(true);
-
- container.addOrReplace(table);
-
- return table;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/Todo.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/Todo.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/Todo.java
deleted file mode 100644
index 1329fe4..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/Todo.java
+++ /dev/null
@@ -1,245 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-import org.apache.syncope.client.console.SyncopeSession;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.PreferenceManager;
-import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
-import org.apache.syncope.client.console.rest.ApprovalRestClient;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.WorkflowFormTO;
-import org.apache.wicket.Page;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.AbstractReadOnlyModel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.request.mapper.parameter.PageParameters;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class Todo extends BasePage {
-
- private static final long serialVersionUID = -7122136682275797903L;
-
- @SpringBean
- private ApprovalRestClient restClient;
-
- @SpringBean
- private PreferenceManager prefMan;
-
- private final ModalWindow window;
-
- private static final int WIN_HEIGHT = 400;
-
- private static final int WIN_WIDTH = 600;
-
- private WebMarkupContainer container;
-
- private int paginatorRows;
-
- public Todo(final PageParameters parameters) {
- super(parameters);
-
- add(window = new ModalWindow("editApprovalWin"));
-
- container = new WebMarkupContainer("approvalContainer");
-
- MetaDataRoleAuthorizationStrategy.authorize(
- container, RENDER, xmlRolesReader.getEntitlement("Approval", "list"));
-
- paginatorRows = prefMan.getPaginatorRows(getRequest(), Constants.PREF_TODO_PAGINATOR_ROWS);
-
- List<IColumn<WorkflowFormTO, String>> columns = new ArrayList<IColumn<WorkflowFormTO, String>>();
- columns.add(new PropertyColumn<WorkflowFormTO, String>(
- new ResourceModel("taskId"), "taskId", "taskId"));
- columns.add(new PropertyColumn<WorkflowFormTO, String>(
- new ResourceModel("key"), "key", "key"));
- columns.add(new PropertyColumn<WorkflowFormTO, String>(
- new ResourceModel("description"), "description", "description"));
- columns.add(new DatePropertyColumn<WorkflowFormTO>(
- new ResourceModel("createTime"), "createTime", "createTime"));
- columns.add(new DatePropertyColumn<WorkflowFormTO>(
- new ResourceModel("dueDate"), "dueDate", "dueDate"));
- columns.add(new PropertyColumn<WorkflowFormTO, String>(new ResourceModel("owner"), "owner", "owner"));
- columns.add(new AbstractColumn<WorkflowFormTO, String>(new ResourceModel("actions", "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public String getCssClass() {
- return "action";
- }
-
- @Override
- public void populateItem(final Item<ICellPopulator<WorkflowFormTO>> cellItem, final String componentId,
- final IModel<WorkflowFormTO> model) {
-
- final WorkflowFormTO formTO = model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- restClient.claimForm(formTO.getTaskId());
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scee) {
- error(getString(Constants.ERROR) + ": " + scee.getMessage());
- }
- feedbackPanel.refresh(target);
- target.add(container);
- }
- }, ActionLink.ActionType.CLAIM, "Approval");
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ApprovalModalPage(Todo.this.getPageReference(), window, formTO);
- }
- });
-
- window.show(target);
- }
- }, ActionLink.ActionType.EDIT, "Approval",
- SyncopeSession.get().getUsername().equals(formTO.getOwner()));
-
- cellItem.add(panel);
- }
- });
-
- final AjaxFallbackDefaultDataTable<WorkflowFormTO, String> approvalTable =
- new AjaxFallbackDefaultDataTable<WorkflowFormTO, String>(
- "approvalTable", columns, new ApprovalProvider(), paginatorRows);
- container.add(approvalTable);
-
- container.setOutputMarkupId(true);
- add(container);
-
- @SuppressWarnings("rawtypes")
- Form approvalPaginatorForm = new Form("paginatorForm");
-
- MetaDataRoleAuthorizationStrategy.authorize(approvalPaginatorForm, RENDER,
- xmlRolesReader.getEntitlement("Approval", "list"));
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- final DropDownChoice rowsChooser = new DropDownChoice("rowsChooser",
- new PropertyModel(this, "paginatorRows"), prefMan.getPaginatorChoices());
-
- rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- prefMan.set(getRequest(), getResponse(), Constants.PREF_TODO_PAGINATOR_ROWS,
- String.valueOf(paginatorRows));
- approvalTable.setItemsPerPage(paginatorRows);
-
- target.add(container);
- }
- });
-
- approvalPaginatorForm.add(rowsChooser);
- add(approvalPaginatorForm);
-
- window.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- window.setInitialHeight(WIN_HEIGHT);
- window.setInitialWidth(WIN_WIDTH);
- window.setCookieName("edit-approval-modal");
-
- setWindowClosedCallback(window, container);
- }
-
- private class ApprovalProvider extends SortableDataProvider<WorkflowFormTO, String> {
-
- private static final long serialVersionUID = -2311716167583335852L;
-
- private final SortableDataProviderComparator<WorkflowFormTO> comparator;
-
- public ApprovalProvider() {
- super();
- //Default sorting
- setSort("key", SortOrder.ASCENDING);
- comparator = new SortableDataProviderComparator<WorkflowFormTO>(this);
- }
-
- @Override
- public Iterator<WorkflowFormTO> iterator(final long first, final long count) {
- final List<WorkflowFormTO> list = restClient.getForms();
-
- Collections.sort(list, comparator);
-
- return list.subList((int) first, (int) first + (int) count).iterator();
- }
-
- @Override
- public long size() {
- return restClient.getForms().size();
- }
-
- @Override
- public IModel<WorkflowFormTO> model(final WorkflowFormTO configuration) {
- return new AbstractReadOnlyModel<WorkflowFormTO>() {
-
- private static final long serialVersionUID = -2566070996511906708L;
-
- @Override
- public WorkflowFormTO getObject() {
- return configuration;
- }
- };
- }
- }
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/UserModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/UserModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/UserModalPage.java
deleted file mode 100644
index 0835ca2..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/UserModalPage.java
+++ /dev/null
@@ -1,229 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.Mode;
-import org.apache.syncope.client.console.panels.DerAttrsPanel;
-import org.apache.syncope.client.console.panels.MembershipsPanel;
-import org.apache.syncope.client.console.panels.PlainAttrsPanel;
-import org.apache.syncope.client.console.panels.ResourcesPanel;
-import org.apache.syncope.client.console.panels.SecurityQuestionPanel;
-import org.apache.syncope.client.console.panels.UserDetailsPanel;
-import org.apache.syncope.client.console.panels.VirAttrsPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.panel.Fragment;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.ResourceModel;
-
-/**
- * Modal window with User form.
- */
-public abstract class UserModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = 5002005009737457667L;
-
- protected final PageReference pageRef;
-
- protected final ModalWindow window;
-
- protected UserTO userTO;
-
- protected final Mode mode;
-
- private Fragment fragment = null;
-
- private final boolean resetPassword;
-
- protected final AjaxCheckBoxPanel storePassword;
-
- public UserModalPage(final PageReference callerPageRef, final ModalWindow window, final UserTO userTO,
- final Mode mode, final boolean resetPassword) {
-
- super();
-
- this.pageRef = callerPageRef;
- this.window = window;
- this.userTO = userTO;
- this.mode = mode;
- this.resetPassword = resetPassword;
-
- fragment = new Fragment("userModalFrag", "userModalEditFrag", this);
- fragment.setOutputMarkupId(true);
- add(fragment);
-
- storePassword = new AjaxCheckBoxPanel("storePassword", "storePassword",
- new Model<Boolean>(Boolean.TRUE));
- }
-
- public UserTO getUserTO() {
- return userTO;
- }
-
- public void setUserTO(final UserTO userTO) {
- this.userTO = userTO;
- }
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- protected Form setupEditPanel() {
- fragment.add(new Label("id", userTO.getKey() == 0
- ? StringUtils.EMPTY
- : userTO.getUsername()));
-
- fragment.add(new Label("new", userTO.getKey() == 0
- ? new ResourceModel("new")
- : new Model(StringUtils.EMPTY)));
-
- final Form form = new Form("UserForm");
- form.setModel(new CompoundPropertyModel(userTO));
-
- //--------------------------------
- // User details
- //--------------------------------
- form.add(new UserDetailsPanel("details", userTO, form, resetPassword, mode == Mode.TEMPLATE));
-
- form.add(new Label("statuspanel", ""));
-
- form.add(new Label("pwdChangeInfo", ""));
-
- form.add(new Label("securityQuestion", ""));
- form.addOrReplace(new SecurityQuestionPanel("securityQuestion", userTO));
-
- form.add(new Label("accountinformation", ""));
- //--------------------------------
-
- //--------------------------------
- // Store password internally checkbox
- //--------------------------------
- final Fragment storePwdFragment = new Fragment("storePwdFrag", "storePwdCheck", form);
- storePwdFragment.setOutputMarkupId(true);
- final Label storePasswordLabel = new Label("storePasswordLabel", new ResourceModel("storePassword"));
- storePwdFragment.add(storePasswordLabel);
- storePwdFragment.add(storePassword);
- form.add(userTO.getKey() == 0 && mode != Mode.TEMPLATE
- ? storePwdFragment : new Fragment("storePwdFrag", "emptyFragment", form));
- //--------------------------------
-
- //--------------------------------
- // Attributes panel
- //--------------------------------
- form.add(new PlainAttrsPanel("plainAttrs", userTO, form, mode));
- //--------------------------------
-
- //--------------------------------
- // Derived attributes panel
- //--------------------------------
- form.add(new DerAttrsPanel("derAttrs", userTO));
- //--------------------------------
-
- //--------------------------------
- // Virtual attributes panel
- //--------------------------------
- form.add(new VirAttrsPanel("virAttrs", userTO, mode == Mode.TEMPLATE));
- //--------------------------------
-
- //--------------------------------
- // Resources panel
- //--------------------------------
- form.add(new ResourcesPanel.Builder("resources").attributableTO(userTO).build());
- //--------------------------------
-
- //--------------------------------
- // Groups panel
- //--------------------------------
- form.add(new MembershipsPanel("memberships", userTO, mode, null, getPageReference()));
- //--------------------------------
-
- final AjaxButton submit = getOnSubmit();
-
- if (mode == Mode.ADMIN) {
- String allowedRoles = userTO.getKey() == 0
- ? xmlRolesReader.getEntitlement("Users", "create")
- : xmlRolesReader.getEntitlement("Users", "update");
- MetaDataRoleAuthorizationStrategy.authorize(submit, RENDER, allowedRoles);
- }
-
- fragment.add(form);
- form.add(submit);
- form.setDefaultButton(submit);
-
- final AjaxButton cancel = new AjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = 530608535790823587L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- }
- };
-
- cancel.setDefaultFormProcessing(false);
- form.add(cancel);
-
- return form;
- }
-
- protected AjaxButton getOnSubmit() {
- return new IndicatingAjaxButton(APPLY, new ResourceModel(SUBMIT)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- try {
- submitAction(target, form);
-
- if (pageRef.getPage() instanceof BasePage) {
- ((BasePage) pageRef.getPage()).setModalResult(true);
- }
-
- closeAction(target, form);
- } catch (Exception e) {
- LOG.error("While creating or updating user", e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
- }
-
- protected abstract void submitAction(AjaxRequestTarget target, Form<?> form);
-
- protected abstract void closeAction(AjaxRequestTarget target, Form<?> form);
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage.java
deleted file mode 100644
index ae8a5da..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage.java
+++ /dev/null
@@ -1,81 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.panels.AbstractSearchResultPanel;
-import org.apache.syncope.client.console.panels.SelectOnlyUserSearchResultPanel;
-import org.apache.syncope.client.console.panels.UserSearchPanel;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.Session;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.ResourceModel;
-
-public class UserOwnerSelectModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = 2106489458494696439L;
-
- public UserOwnerSelectModalPage(final PageReference pageRef, final ModalWindow window) {
- super();
-
- final SelectOnlyUserSearchResultPanel searchResult =
- new SelectOnlyUserSearchResultPanel("searchResult", true, null, pageRef, window, userRestClient);
- add(searchResult);
-
- final Form<?> searchForm = new Form("searchForm");
- add(searchForm);
-
- final UserSearchPanel searchPanel = new UserSearchPanel.Builder("searchPanel").build();
- searchForm.add(searchPanel);
-
- searchForm.add(new IndicatingAjaxButton("search", new ResourceModel("search")) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- final String searchCond = searchPanel.buildFIQL();
- doSearch(target, searchCond, searchResult);
-
- Session.get().getFeedbackMessages().clear();
- searchPanel.getSearchFeedback().refresh(target);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- searchPanel.getSearchFeedback().refresh(target);
- }
- });
-
- }
-
- private void doSearch(final AjaxRequestTarget target, final String fiql,
- final AbstractSearchResultPanel resultsetPanel) {
-
- if (fiql == null) {
- error(getString(Constants.SEARCH_ERROR));
- return;
- }
-
- resultsetPanel.search(fiql, target);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/UserSelfModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/UserSelfModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/UserSelfModalPage.java
deleted file mode 100644
index 087bd69..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/UserSelfModalPage.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.commons.lang3.SerializationUtils;
-import org.apache.syncope.client.console.commons.Mode;
-import org.apache.syncope.client.console.rest.UserSelfRestClient;
-import org.apache.syncope.common.lib.AttributableOperations;
-import org.apache.syncope.common.lib.mod.UserMod;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-/**
- * Modal window with User form.
- */
-public class UserSelfModalPage extends UserModalPage {
-
- private static final long serialVersionUID = 603212869211672852L;
-
- @SpringBean
- private UserSelfRestClient restClient;
-
- private final UserTO initialUserTO;
-
- public UserSelfModalPage(final PageReference callerPageRef, final ModalWindow window, final UserTO userTO) {
- super(callerPageRef, window, userTO, Mode.SELF, userTO.getKey() != 0);
-
- this.initialUserTO = SerializationUtils.clone(userTO);
- setupEditPanel();
- }
-
- @Override
- protected void submitAction(final AjaxRequestTarget target, final Form<?> form) {
- final UserTO updatedUserTO = (UserTO) form.getModelObject();
-
- if (updatedUserTO.getKey() == 0) {
- restClient.create(updatedUserTO, storePassword.getModelObject());
- } else {
- final UserMod userMod = AttributableOperations.diff(updatedUserTO, initialUserTO);
-
- // update user only if it has changed
- if (!userMod.isEmpty()) {
- restClient.update(userMod);
- }
- }
- }
-
- @Override
- protected void closeAction(final AjaxRequestTarget target, final Form<?> form) {
- setResponsePage(new ResultStatusModalPage.Builder(window, userTO).mode(mode).build());
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/UserTemplateModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/UserTemplateModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/UserTemplateModalPage.java
deleted file mode 100644
index 2b04035..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/UserTemplateModalPage.java
+++ /dev/null
@@ -1,60 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.client.console.commons.Mode;
-import org.apache.syncope.common.lib.to.SyncTaskTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.form.Form;
-
-/**
- * Modal window with User form.
- */
-public class UserTemplateModalPage extends UserModalPage {
-
- private static final long serialVersionUID = 511003221213581368L;
-
- private final SyncTaskTO syncTaskTO;
-
- public UserTemplateModalPage(final PageReference callerPageRef, final ModalWindow window,
- final SyncTaskTO syncTaskTO) {
-
- super(callerPageRef, window, syncTaskTO.getUserTemplate() == null
- ? new UserTO()
- : syncTaskTO.getUserTemplate(), Mode.TEMPLATE, true);
-
- this.syncTaskTO = syncTaskTO;
-
- setupEditPanel();
- }
-
- @Override
- protected void submitAction(final AjaxRequestTarget target, final Form form) {
- syncTaskTO.setUserTemplate((UserTO) form.getModelObject());
- taskRestClient.updateSyncTask(syncTaskTO);
- }
-
- @Override
- protected void closeAction(final AjaxRequestTarget target, final Form form) {
- window.close(target);
- }
-}
[49/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractSchedTaskModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractSchedTaskModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractSchedTaskModalPage.java
deleted file mode 100644
index 78ca906..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractSchedTaskModalPage.java
+++ /dev/null
@@ -1,132 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.DateFormatROModel;
-import org.apache.syncope.client.console.wicket.markup.html.CrontabContainer;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.SchedTaskTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.springframework.util.StringUtils;
-
-/**
- * Modal window with Task form (to stop and start execution).
- */
-public abstract class AbstractSchedTaskModalPage extends TaskModalPage {
-
- private static final long serialVersionUID = 2892005971093059242L;
-
- protected CrontabContainer crontab;
-
- public AbstractSchedTaskModalPage(final ModalWindow window, final SchedTaskTO taskTO,
- final PageReference pageRef) {
-
- super(taskTO);
-
- crontab = new CrontabContainer("crontab", new PropertyModel<String>(taskTO, "cronExpression"),
- taskTO.getCronExpression());
- form.add(crontab);
-
- final AjaxTextFieldPanel name =
- new AjaxTextFieldPanel("name", "name", new PropertyModel<String>(taskTO, "name"));
- name.setEnabled(true);
- profile.add(name);
-
- final AjaxTextFieldPanel description = new AjaxTextFieldPanel("description", "description",
- new PropertyModel<String>(taskTO, "description"));
- description.setEnabled(true);
- profile.add(description);
-
- final AjaxTextFieldPanel lastExec = new AjaxTextFieldPanel("lastExec", getString("lastExec"),
- new DateFormatROModel(new PropertyModel<String>(taskTO, "lastExec")));
- lastExec.setEnabled(false);
- profile.add(lastExec);
-
- final AjaxTextFieldPanel nextExec = new AjaxTextFieldPanel("nextExec", getString("nextExec"),
- new DateFormatROModel(new PropertyModel<String>(taskTO, "nextExec")));
- nextExec.setEnabled(false);
- profile.add(nextExec);
-
- final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(APPLY)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- SchedTaskTO taskTO = (SchedTaskTO) form.getModelObject();
- taskTO.setCronExpression(StringUtils.hasText(taskTO.getCronExpression())
- ? crontab.getCronExpression()
- : null);
-
- try {
- submitAction(taskTO);
-
- ((BasePage) pageRef.getPage()).setModalResult(true);
-
- window.close(target);
- } catch (SyncopeClientException e) {
- LOG.error("While creating or updating task", e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
-
- final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
- };
-
- cancel.setDefaultFormProcessing(false);
-
- if (taskTO.getKey() > 0) {
- MetaDataRoleAuthorizationStrategy.authorize(
- submit, RENDER, xmlRolesReader.getEntitlement(TASKS, "update"));
- } else {
- MetaDataRoleAuthorizationStrategy.authorize(
- submit, RENDER, xmlRolesReader.getEntitlement(TASKS, "create"));
- }
-
- form.add(submit);
- form.add(cancel);
- }
-
- protected abstract void submitAction(SchedTaskTO taskTO);
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractSchemaModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractSchemaModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractSchemaModalPage.java
deleted file mode 100644
index 1c1bd0f..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractSchemaModalPage.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.common.lib.to.AbstractSchemaTO;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-
-/**
- * Modal window with Schema form.
- */
-public abstract class AbstractSchemaModalPage<T extends AbstractSchemaTO> extends BaseModalPage {
-
- private static final long serialVersionUID = 7369215690388444748L;
-
- protected AttributableType kind;
-
- public AbstractSchemaModalPage(final AttributableType kind) {
- this.kind = kind;
- }
-
- public abstract void setSchemaModalPage(PageReference callerPageRef, ModalWindow window, T schema,
- boolean createFlag);
-
- public AttributableType getKind() {
- return kind;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractStatusModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractStatusModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractStatusModalPage.java
deleted file mode 100644
index f5dfbca..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractStatusModalPage.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.wicket.markup.html.panel.Fragment;
-
-public class AbstractStatusModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = 6633408683036028540L;
-
- public AbstractStatusModalPage() {
- add(new Fragment("pwdMgtFields", "emptyFragment", this));
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractSyncTaskModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractSyncTaskModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractSyncTaskModalPage.java
deleted file mode 100644
index aa62b41..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractSyncTaskModalPage.java
+++ /dev/null
@@ -1,209 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.List;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.SelectChoiceRenderer;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.common.lib.to.AbstractProvisioningTaskTO;
-import org.apache.syncope.common.lib.to.ResourceTO;
-import org.apache.syncope.common.lib.types.MatchingRule;
-import org.apache.syncope.common.lib.types.UnmatchingRule;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-
-/**
- * Abstract Modal window for Sync and Push Task form.
- */
-public abstract class AbstractSyncTaskModalPage extends AbstractSchedTaskModalPage {
-
- private static final long serialVersionUID = 2148403203517274669L;
-
- protected AjaxDropDownChoicePanel<MatchingRule> matchingRule;
-
- protected AjaxDropDownChoicePanel<UnmatchingRule> unmatchingRule;
-
- protected abstract List<String> getSyncActions();
-
- final IModel<List<String>> allResources = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- final List<String> resourceNames = new ArrayList<>();
-
- for (ResourceTO resourceTO : resourceRestClient.getAll()) {
- resourceNames.add(resourceTO.getKey());
- }
-
- Collections.sort(resourceNames);
- return resourceNames;
- }
- };
-
- final IModel<List<String>> syncActionsClasses = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157438L;
-
- @Override
- protected List<String> load() {
- return getSyncActions();
- }
- };
-
- public AbstractSyncTaskModalPage(
- final ModalWindow window, final AbstractProvisioningTaskTO taskTO, final PageReference pageRef) {
-
- super(window, taskTO, pageRef);
-
- final AjaxDropDownChoicePanel<String> resource = new AjaxDropDownChoicePanel<>("resource",
- getString("resourceName"), new PropertyModel<String>(taskTO, "resource"));
- resource.setChoices(allResources.getObject());
- resource.setChoiceRenderer(new SelectChoiceRenderer<String>());
- resource.addRequiredLabel();
- resource.setEnabled(taskTO.getKey() == 0);
- resource.setStyleSheet("ui-widget-content ui-corner-all long_dynamicsize");
-
- profile.add(resource);
-
- final WebMarkupContainer syncActionsClassNames = new WebMarkupContainer("syncActionsClassNames");
- syncActionsClassNames.setOutputMarkupId(true);
- profile.add(syncActionsClassNames);
-
- final AjaxLink<Void> first = new IndicatingAjaxLink<Void>("first") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- taskTO.getActionsClassNames().add(StringUtils.EMPTY);
- setVisible(false);
- target.add(syncActionsClassNames);
- }
- };
- first.setOutputMarkupPlaceholderTag(true);
- first.setVisible(taskTO.getActionsClassNames().isEmpty());
- syncActionsClassNames.add(first);
-
- final ListView<String> actionsClasses = new ListView<String>(
- "actionsClasses", new PropertyModel<List<String>>(taskTO, "actionsClassNames")) {
-
- private static final long serialVersionUID = 9101744072914090143L;
-
- @Override
- protected void populateItem(final ListItem<String> item) {
- final String className = item.getModelObject();
-
- final DropDownChoice<String> actionsClass = new DropDownChoice<String>(
- "actionsClass", new Model<String>(className), syncActionsClasses.getObject());
- actionsClass.setNullValid(true);
- actionsClass.setRequired(true);
- actionsClass.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- taskTO.getActionsClassNames().set(item.getIndex(), actionsClass.getModelObject());
- target.add(syncActionsClassNames);
- }
- });
- actionsClass.setRequired(true);
- actionsClass.setOutputMarkupId(true);
- actionsClass.setRequired(true);
- item.add(actionsClass);
-
- AjaxLink<Void> minus = new IndicatingAjaxLink<Void>("drop") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- taskTO.getActionsClassNames().remove(className);
- first.setVisible(taskTO.getActionsClassNames().isEmpty());
- target.add(syncActionsClassNames);
- }
- };
- item.add(minus);
-
- final AjaxLink<Void> plus = new IndicatingAjaxLink<Void>("add") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- taskTO.getActionsClassNames().add(StringUtils.EMPTY);
- target.add(syncActionsClassNames);
- }
- };
- plus.setOutputMarkupPlaceholderTag(true);
- plus.setVisible(item.getIndex() == taskTO.getActionsClassNames().size() - 1);
- item.add(plus);
- }
- };
- syncActionsClassNames.add(actionsClasses);
-
- syncActionsClassNames.setEnabled(!syncActionsClasses.getObject().isEmpty());
-
- final AjaxCheckBoxPanel creates = new AjaxCheckBoxPanel("performCreate", getString("creates"),
- new PropertyModel<Boolean>(taskTO, "performCreate"));
- profile.add(creates);
-
- final AjaxCheckBoxPanel updates = new AjaxCheckBoxPanel("performUpdate", getString("updates"),
- new PropertyModel<Boolean>(taskTO, "performUpdate"));
- profile.add(updates);
-
- final AjaxCheckBoxPanel deletes = new AjaxCheckBoxPanel("performDelete", getString("updates"),
- new PropertyModel<Boolean>(taskTO, "performDelete"));
- profile.add(deletes);
-
- final AjaxCheckBoxPanel syncStatus = new AjaxCheckBoxPanel("syncStatus", getString("syncStatus"),
- new PropertyModel<Boolean>(taskTO, "syncStatus"));
- profile.add(syncStatus);
-
- matchingRule = new AjaxDropDownChoicePanel<MatchingRule>(
- "matchingRule", "matchingRule", new PropertyModel<MatchingRule>(taskTO, "matchingRule"));
- matchingRule.setChoices(Arrays.asList(MatchingRule.values()));
- ((DropDownChoice) matchingRule.getField()).setNullValid(false);
-
- unmatchingRule = new AjaxDropDownChoicePanel<UnmatchingRule>(
- "unmatchingRule", "unmatchingRule", new PropertyModel<UnmatchingRule>(taskTO, "unmatchingRule"));
- unmatchingRule.setChoices(Arrays.asList(UnmatchingRule.values()));
- ((DropDownChoice) unmatchingRule.getField()).setNullValid(false);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/ActivitiModelerPopupPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/ActivitiModelerPopupPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/ActivitiModelerPopupPage.java
deleted file mode 100644
index 05658fc..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/ActivitiModelerPopupPage.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.wicket.markup.html.WebPage;
-
-public class ActivitiModelerPopupPage extends WebPage {
-
- private static final long serialVersionUID = -7031206743629422898L;
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/ApprovalModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/ApprovalModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/ApprovalModalPage.java
deleted file mode 100644
index 79deeb0..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/ApprovalModalPage.java
+++ /dev/null
@@ -1,286 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.io.Serializable;
-import java.text.ParseException;
-import java.text.SimpleDateFormat;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Date;
-import java.util.List;
-import java.util.Map;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.commons.lang3.math.NumberUtils;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.MapChoiceRenderer;
-import org.apache.syncope.client.console.rest.ApprovalRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.DateTimeFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.FieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.SpinnerFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.list.AltListView;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.WorkflowFormPropertyTO;
-import org.apache.syncope.common.lib.to.WorkflowFormTO;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class ApprovalModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = -8847854414429745216L;
-
- private final static int USER_WIN_HEIGHT = 550;
-
- private final static int USER_WIN_WIDTH = 800;
-
- @SpringBean
- private ApprovalRestClient restClient;
-
- private final ModalWindow editUserWin;
-
- public ApprovalModalPage(final PageReference pageRef, final ModalWindow window, final WorkflowFormTO formTO) {
- super();
-
- IModel<List<WorkflowFormPropertyTO>> formProps = new LoadableDetachableModel<List<WorkflowFormPropertyTO>>() {
-
- private static final long serialVersionUID = 3169142472626817508L;
-
- @Override
- protected List<WorkflowFormPropertyTO> load() {
- return formTO.getProperties();
- }
- };
-
- final ListView<WorkflowFormPropertyTO> propView =
- new AltListView<WorkflowFormPropertyTO>("propView", formProps) {
-
- private static final long serialVersionUID = 9101744072914090143L;
-
- @Override
- @SuppressWarnings({ "unchecked", "rawtypes" })
- protected void populateItem(final ListItem<WorkflowFormPropertyTO> item) {
- final WorkflowFormPropertyTO prop = item.getModelObject();
-
- Label label = new Label("key", prop.getName() == null
- ? prop.getId()
- : prop.getName());
- item.add(label);
-
- FieldPanel field;
- switch (prop.getType()) {
- case Boolean:
- field = new AjaxDropDownChoicePanel("value", label.getDefaultModelObjectAsString(),
- new Model<Boolean>(Boolean.valueOf(prop.getValue()))).setChoices(Arrays.asList(
- new String[] { "Yes", "No" }));
- break;
-
- case Date:
- SimpleDateFormat df = StringUtils.isNotBlank(prop.getDatePattern())
- ? new SimpleDateFormat(prop.getDatePattern())
- : new SimpleDateFormat();
- Date parsedDate = null;
- if (StringUtils.isNotBlank(prop.getValue())) {
- try {
- parsedDate = df.parse(prop.getValue());
- } catch (ParseException e) {
- LOG.error("Unparsable date: {}", prop.getValue(), e);
- }
- }
-
- field = new DateTimeFieldPanel("value", label.getDefaultModelObjectAsString(),
- new Model<Date>(parsedDate), df.toLocalizedPattern());
- break;
-
- case Enum:
- MapChoiceRenderer<String, String> enumCR =
- new MapChoiceRenderer<String, String>(prop.getEnumValues());
-
- field = new AjaxDropDownChoicePanel("value", label.getDefaultModelObjectAsString(),
- new Model(prop.getValue())).setChoiceRenderer(enumCR).setChoices(new Model() {
-
- private static final long serialVersionUID = -858521070366432018L;
-
- @Override
- public Serializable getObject() {
- return new ArrayList<String>(prop.getEnumValues().keySet());
- }
- });
- break;
-
- case Long:
- field = new SpinnerFieldPanel<Long>("value", label.getDefaultModelObjectAsString(),
- Long.class, new Model<Long>(NumberUtils.toLong(prop.getValue())),
- null, null);
- break;
-
- case String:
- default:
- field = new AjaxTextFieldPanel("value", PARENT_PATH,
- new Model<String>(prop.getValue()));
- break;
- }
-
- field.setReadOnly(!prop.isWritable());
- if (prop.isRequired()) {
- field.addRequiredLabel();
- }
-
- item.add(field);
- }
- };
-
- final AjaxButton userDetails = new IndicatingAjaxButton("userDetails",
- new Model<String>(getString("userDetails"))) {
-
- private static final long serialVersionUID = -4804368561204623354L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- editUserWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ViewUserModalPage(ApprovalModalPage.this.getPageReference(), editUserWin,
- userRestClient.read(formTO.getUserKey())) {
-
- private static final long serialVersionUID = -2819994749866481607L;
-
- @Override
- protected void closeAction(final AjaxRequestTarget target, final Form form) {
- setResponsePage(ApprovalModalPage.this);
- }
- };
- }
- });
-
- editUserWin.show(target);
- }
- };
- MetaDataRoleAuthorizationStrategy.authorize(userDetails, ENABLE,
- xmlRolesReader.getEntitlement("Users", "read"));
-
- final AjaxButton submit = new IndicatingAjaxButton(APPLY, new Model<String>(getString(SUBMIT))) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
-
- Map<String, WorkflowFormPropertyTO> props = formTO.getPropertyMap();
-
- for (int i = 0; i < propView.size(); i++) {
- @SuppressWarnings("unchecked")
- ListItem<WorkflowFormPropertyTO> item = (ListItem<WorkflowFormPropertyTO>) propView.get(i);
- String input = ((FieldPanel) item.get("value")).getField().getInput();
-
- if (!props.containsKey(item.getModelObject().getId())) {
- props.put(item.getModelObject().getId(), new WorkflowFormPropertyTO());
- }
-
- if (item.getModelObject().isWritable()) {
- switch (item.getModelObject().getType()) {
- case Boolean:
- props.get(item.getModelObject().getId()).setValue(String.valueOf("0".equals(input)));
- break;
-
- case Date:
- case Enum:
- case String:
- case Long:
- default:
- props.get(item.getModelObject().getId()).setValue(input);
- break;
- }
- }
- }
-
- formTO.getProperties().clear();
- formTO.getProperties().addAll(props.values());
- try {
- restClient.submitForm(formTO);
-
- ((Todo) pageRef.getPage()).setModalResult(true);
- window.close(target);
- } catch (SyncopeClientException e) {
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- LOG.error("While submitting form {}", formTO, e);
- feedbackPanel.refresh(target);
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
-
- final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form form) {
- window.close(target);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form form) {
- // nothing
- }
- };
-
- cancel.setDefaultFormProcessing(false);
-
- Form form = new Form(FORM);
- form.add(propView);
- form.add(userDetails);
- form.add(submit);
- form.add(cancel);
-
- MetaDataRoleAuthorizationStrategy.authorize(form, ENABLE, xmlRolesReader.getEntitlement("Approval",
- SUBMIT));
-
- editUserWin = new ModalWindow("editUserWin");
- editUserWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- editUserWin.setInitialHeight(USER_WIN_HEIGHT);
- editUserWin.setInitialWidth(USER_WIN_WIDTH);
- editUserWin.setCookieName("edit-user-modal");
- add(editUserWin);
-
- add(form);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/BaseModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/BaseModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/BaseModalPage.java
index 20892dd..6da298a 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/BaseModalPage.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/pages/BaseModalPage.java
@@ -18,7 +18,12 @@
*/
package org.apache.syncope.client.console.pages;
-import org.apache.syncope.client.console.commons.CloseOnESCBehavior;
+import org.apache.wicket.Component;
+import org.apache.wicket.ajax.AjaxEventBehavior;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.attributes.AjaxCallListener;
+import org.apache.wicket.ajax.attributes.AjaxRequestAttributes;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
/**
* Syncope Modal Window.
@@ -30,6 +35,29 @@ public abstract class BaseModalPage extends AbstractBasePage {
public BaseModalPage() {
super();
- add(new CloseOnESCBehavior("keyup"));
+ add(new AjaxEventBehavior("keyup") {
+
+ private static final long serialVersionUID = -7133385027739964990L;
+
+ @Override
+ protected void onEvent(final AjaxRequestTarget target) {
+ ModalWindow.closeCurrent(target);
+ }
+
+ @Override
+ protected void updateAjaxAttributes(final AjaxRequestAttributes attributes) {
+ super.updateAjaxAttributes(attributes);
+
+ attributes.getAjaxCallListeners().add(new AjaxCallListener() {
+
+ private static final long serialVersionUID = 7160235486520935153L;
+
+ @Override
+ public CharSequence getPrecondition(final Component aComponent) {
+ return " if(Wicket.Event.keyCode(attrs.event) != 27){return false;}";
+ }
+ });
+ }
+ });
}
}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/BasePage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/BasePage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/BasePage.java
index 2540c37..7547448 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/BasePage.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/pages/BasePage.java
@@ -18,21 +18,9 @@
*/
package org.apache.syncope.client.console.pages;
-import org.apache.syncope.client.console.SyncopeApplication;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.wicket.Component;
-import org.apache.wicket.ajax.AjaxRequestTarget;
import org.apache.wicket.ajax.IAjaxIndicatorAware;
-import org.apache.wicket.behavior.Behavior;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.ComponentTag;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.link.BookmarkablePageLink;
import org.apache.wicket.request.mapper.parameter.PageParameters;
-/**
- * Syncope Wicket base-page.
- */
public class BasePage extends AbstractBasePage implements IAjaxIndicatorAware {
private static final long serialVersionUID = 1571997737305598502L;
@@ -43,41 +31,6 @@ public class BasePage extends AbstractBasePage implements IAjaxIndicatorAware {
public BasePage(final PageParameters parameters) {
super(parameters);
-
- pageSetup();
- }
-
- private void pageSetup() {
- ((SyncopeApplication) getApplication()).setupNavigationPanel(this, xmlRolesReader, true);
-
- final String kind = getClass().getSimpleName().toLowerCase();
- final BookmarkablePageLink kindLink = (BookmarkablePageLink) get(kind);
- if (kindLink != null) {
- kindLink.add(new Behavior() {
-
- private static final long serialVersionUID = 1469628524240283489L;
-
- @Override
- public void onComponentTag(final Component component, final ComponentTag tag) {
- tag.put("class", kind);
- }
- });
-
- Component kindIcon = kindLink.get(0);
- if (kindIcon != null) {
- kindIcon.add(new Behavior() {
-
- private static final long serialVersionUID = 1469628524240283489L;
-
- @Override
- public void onComponentTag(final Component component, final ComponentTag tag) {
- tag.put("src", "../.." + SyncopeApplication.IMG_PREFIX + kind + Constants.PNG_EXT);
- }
- });
- }
- }
-
- ((SyncopeApplication) getApplication()).setupEditProfileModal(this, userSelfRestClient);
}
@Override
@@ -85,27 +38,4 @@ public class BasePage extends AbstractBasePage implements IAjaxIndicatorAware {
return "veil";
}
- /**
- * Set a WindowClosedCallback for a ModalWindow instance.
- *
- * @param window window
- * @param container container
- */
- protected void setWindowClosedCallback(final ModalWindow window, final WebMarkupContainer container) {
-
- window.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
-
- private static final long serialVersionUID = 8804221891699487139L;
-
- @Override
- public void onClose(final AjaxRequestTarget target) {
- target.add(container);
- if (isModalResult()) {
- info(getString(Constants.OPERATION_SUCCEEDED));
- feedbackPanel.refresh(target);
- setModalResult(false);
- }
- }
- });
- }
}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/BulkActionModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/BulkActionModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/BulkActionModalPage.java
deleted file mode 100644
index 95e514b..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/BulkActionModalPage.java
+++ /dev/null
@@ -1,166 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.lang.reflect.InvocationTargetException;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Iterator;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.rest.BaseRestClient;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.common.lib.to.BulkAction;
-import org.apache.syncope.common.lib.to.BulkActionResult;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.ResourceModel;
-import org.springframework.beans.BeanUtils;
-
-public class BulkActionModalPage<T, S> extends BaseModalPage {
-
- private static final long serialVersionUID = 4114026480146090962L;
-
- public BulkActionModalPage(
- final ModalWindow window,
- final Collection<T> items,
- final List<IColumn<T, S>> columns,
- final Collection<ActionLink.ActionType> actions,
- final BaseRestClient bulkActionExecutor,
- final String idFieldName,
- final String pageId) {
-
- super();
-
- final SortableDataProvider<T, S> dataProvider = new SortableDataProvider<T, S>() {
-
- private static final long serialVersionUID = 5291903859908641954L;
-
- @Override
- public Iterator<? extends T> iterator(final long first, final long count) {
- return items.iterator();
- }
-
- @Override
- public long size() {
- return items.size();
- }
-
- @Override
- public IModel<T> model(final T object) {
- return new CompoundPropertyModel<>(object);
- }
- };
-
- add(new AjaxFallbackDefaultDataTable<>(
- "selectedObjects",
- new ArrayList<>(columns.subList(1, columns.size() - 1)),
- dataProvider,
- Integer.MAX_VALUE).setVisible(items != null && !items.isEmpty()));
-
- @SuppressWarnings("rawtypes")
- final ActionLinksPanel actionPanel = new ActionLinksPanel("actions", new Model(), getPageReference());
- add(actionPanel);
-
- for (ActionLink.ActionType action : actions) {
- final BulkAction bulkAction = new BulkAction();
- for (T item : items) {
- try {
- bulkAction.getTargets().add(getTargetId(item, idFieldName).toString());
- } catch (Exception e) {
- LOG.error("Error retrieving item id {}", idFieldName, e);
- }
- }
-
- switch (action) {
- case DELETE:
- bulkAction.setOperation(BulkAction.Type.DELETE);
- break;
- case SUSPEND:
- bulkAction.setOperation(BulkAction.Type.SUSPEND);
- break;
- case REACTIVATE:
- bulkAction.setOperation(BulkAction.Type.REACTIVATE);
- break;
- case EXECUTE:
- bulkAction.setOperation(BulkAction.Type.EXECUTE);
- break;
- case DRYRUN:
- bulkAction.setOperation(BulkAction.Type.DRYRUN);
- break;
- default:
- LOG.error("Bulk action type not supported");
- }
-
- actionPanel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- final BulkActionResult res = (BulkActionResult) bulkActionExecutor.getClass().
- getMethod("bulkAction", BulkAction.class).invoke(bulkActionExecutor, bulkAction);
-
- setResponsePage(new BulkActionResultModalPage<>(window, items, columns, res, idFieldName));
- } catch (Exception e) {
- error(getString(Constants.ERROR)
- + ": Operation " + bulkAction.getOperation() + " not supported");
- feedbackPanel.refresh(target);
- }
-
- }
- }, action, pageId, !items.isEmpty());
- }
-
- final Form<Void> form = new Form<>(FORM);
- add(form);
-
- final AjaxButton cancel =
- new ClearIndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL), getPageReference()) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
- };
-
- cancel.setDefaultFormProcessing(false);
- form.add(cancel);
- }
-
- private Object getTargetId(final Object target, final String idFieldName)
- throws IllegalAccessException, InvocationTargetException {
-
- return BeanUtils.getPropertyDescriptor(target.getClass(), idFieldName).
- getReadMethod().invoke(target, new Object[0]);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/BulkActionResultModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/BulkActionResultModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/BulkActionResultModalPage.java
deleted file mode 100644
index b9b8968..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/BulkActionResultModalPage.java
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Iterator;
-import java.util.List;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionResultColumn;
-import org.apache.syncope.common.lib.to.BulkActionResult;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.IModel;
-
-/**
- * Show user or group status after performing a successful operation.
- */
-public class BulkActionResultModalPage<T, S> extends BaseModalPage {
-
- /**
- * Serial version id.
- */
- private static final long serialVersionUID = 2646115294319713724L;
-
- public BulkActionResultModalPage(
- final ModalWindow window,
- final Collection<T> items,
- final List<IColumn<T, S>> columns,
- final BulkActionResult results,
- final String idFieldName) {
-
- super();
-
- final List<IColumn<T, S>> newColumnList = new ArrayList<>(columns.subList(1, columns.size() - 1));
- newColumnList.add(newColumnList.size(), new ActionResultColumn<T, S>(results, idFieldName));
-
- final SortableDataProvider<T, S> dataProvider = new SortableDataProvider<T, S>() {
-
- private static final long serialVersionUID = 5291903859908641954L;
-
- @Override
- public Iterator<? extends T> iterator(final long first, final long count) {
- return items.iterator();
- }
-
- @Override
- public long size() {
- return items.size();
- }
-
- @Override
- public IModel<T> model(final T object) {
- return new CompoundPropertyModel<T>(object);
- }
- };
-
- add(new AjaxFallbackDefaultDataTable<T, S>(
- "selectedObjects",
- newColumnList,
- dataProvider,
- Integer.MAX_VALUE).setVisible(items != null && !items.isEmpty()));
-
- final AjaxLink<Void> close = new IndicatingAjaxLink<Void>("close") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- window.close(target);
- }
- };
-
- add(close);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/ConfModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/ConfModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/ConfModalPage.java
deleted file mode 100644
index 0c65ac2..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/ConfModalPage.java
+++ /dev/null
@@ -1,112 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.Collections;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.Mode;
-import org.apache.syncope.client.console.panels.PlainAttrsPanel;
-import org.apache.syncope.common.lib.to.AttrTO;
-import org.apache.syncope.common.lib.to.ConfTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.ResourceModel;
-
-public class ConfModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = 3524777398688399977L;
-
- public ConfModalPage(final PageReference pageRef, final ModalWindow window, final WebMarkupContainer parameters) {
- super();
-
- MetaDataRoleAuthorizationStrategy.authorize(
- parameters, ENABLE, xmlRolesReader.getEntitlement("Configuration", "list"));
- final ConfTO conf = confRestClient.list();
-
- final Form<ConfTO> form = new Form<>("confForm");
- form.setModel(new CompoundPropertyModel<>(conf));
-
- form.add(new PlainAttrsPanel("paramAttrs", conf, form, Mode.ADMIN));
-
- final AjaxButton submit = new IndicatingAjaxButton(SUBMIT, new ResourceModel(SUBMIT)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- final ConfTO updatedConf = (ConfTO) form.getModelObject();
-
- try {
- for (AttrTO attr : updatedConf.getPlainAttrs()) {
- attr.getValues().removeAll(Collections.singleton(null));
- if (attr.getValues().isEmpty()
- || attr.getValues().equals(Collections.singletonList(StringUtils.EMPTY))) {
-
- confRestClient.delete(attr.getSchema());
- } else {
- confRestClient.set(attr);
- }
- }
-
- if (pageRef.getPage() instanceof BasePage) {
- ((BasePage) pageRef.getPage()).setModalResult(true);
- }
-
- window.close(target);
- } catch (Exception e) {
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
- MetaDataRoleAuthorizationStrategy.authorize(
- submit, ENABLE, xmlRolesReader.getEntitlement("Configuration", "set"));
- MetaDataRoleAuthorizationStrategy.authorize(
- submit, ENABLE, xmlRolesReader.getEntitlement("Configuration", "delete"));
- form.add(submit);
- form.setDefaultButton(submit);
-
- final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
- };
- cancel.setDefaultFormProcessing(false);
- form.add(cancel);
-
- add(form);
- }
-}
[45/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/ReportModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/ReportModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/ReportModalPage.java
deleted file mode 100644
index 0ef7c6a..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/ReportModalPage.java
+++ /dev/null
@@ -1,640 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.DateFormatROModel;
-import org.apache.syncope.client.console.commons.HttpResourceStream;
-import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
-import org.apache.syncope.client.console.wicket.ajax.form.AbstractAjaxDownloadBehavior;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
-import org.apache.syncope.client.console.wicket.markup.html.CrontabContainer;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.report.AbstractReportletConf;
-import org.apache.syncope.common.lib.report.ReportletConf;
-import org.apache.syncope.common.lib.to.ReportExecTO;
-import org.apache.syncope.common.lib.to.ReportTO;
-import org.apache.syncope.common.lib.types.ReportExecExportFormat;
-import org.apache.syncope.common.lib.types.ReportExecStatus;
-import org.apache.wicket.Component;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.attributes.AjaxCallListener;
-import org.apache.wicket.ajax.attributes.AjaxRequestAttributes;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
-import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.form.IChoiceRenderer;
-import org.apache.wicket.markup.html.form.ListChoice;
-import org.apache.wicket.model.AbstractReadOnlyModel;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.util.resource.IResourceStream;
-import org.springframework.util.StringUtils;
-
-public class ReportModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = -5747628615211127644L;
-
- private static final String ADD_BUTTON_ID = "addButton";
-
- private static final String EDIT_BUTTON_ID = "editButton";
-
- private static final String REMOVE_BUTTON_ID = "removeButton";
-
- private static final String UP_BUTTON_ID = "upButton";
-
- private static final String DOWN_BUTTON_ID = "downButton";
-
- private static final int EXEC_EXPORT_WIN_HEIGHT = 100;
-
- private static final int EXEC_EXPORT_WIN_WIDTH = 400;
-
- private static final int REPORTLET_CONF_WIN_HEIGHT = 500;
-
- private static final int REPORTLET_CONF_WIN_WIDTH = 800;
-
- private final ReportTO reportTO;
-
- private final Form<ReportTO> form;
-
- private ReportExecExportFormat exportFormat;
-
- private long exportExecId;
-
- private AbstractReportletConf modalReportletConf;
-
- private String modalReportletConfOldName;
-
- private ListChoice<AbstractReportletConf> reportlets;
-
- public ReportModalPage(final ModalWindow window, final ReportTO reportTO, final PageReference callerPageRef) {
- super();
- this.reportTO = reportTO;
-
- form = new Form<ReportTO>(FORM);
- form.setModel(new CompoundPropertyModel<ReportTO>(reportTO));
- add(form);
-
- setupProfile();
- setupExecutions();
-
- final CrontabContainer crontab = new CrontabContainer("crontab", new PropertyModel<String>(reportTO,
- "cronExpression"), reportTO.getCronExpression());
- form.add(crontab);
-
- final AjaxButton submit =
- new ClearIndicatingAjaxButton(APPLY, new ResourceModel(APPLY), getPageReference()) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
- ReportTO toSubmit = (ReportTO) form.getModelObject();
- toSubmit.setCronExpression(StringUtils.hasText(toSubmit.getCronExpression())
- ? crontab.getCronExpression()
- : null);
-
- try {
- if (toSubmit.getKey() > 0) {
- reportRestClient.update(toSubmit);
- } else {
- reportRestClient.create(toSubmit);
- }
-
- ((BasePage) callerPageRef.getPage()).setModalResult(true);
-
- window.close(target);
- } catch (SyncopeClientException e) {
- LOG.error("While creating or updating report", e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
-
- if (reportTO.getKey() > 0) {
- MetaDataRoleAuthorizationStrategy.authorize(submit, RENDER,
- xmlRolesReader.getEntitlement("Reports", "update"));
- } else {
- MetaDataRoleAuthorizationStrategy.authorize(submit, RENDER,
- xmlRolesReader.getEntitlement("Reports", "create"));
- }
-
- form.add(submit);
-
- final AjaxButton cancel =
- new ClearIndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL), getPageReference()) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
- };
-
- cancel.setDefaultFormProcessing(false);
- form.add(cancel);
- }
-
- private void setupProfile() {
- final WebMarkupContainer profile = new WebMarkupContainer("profile");
- profile.setOutputMarkupId(true);
- form.add(profile);
-
- final ModalWindow reportletConfWin = new ModalWindow("reportletConfWin");
- reportletConfWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- reportletConfWin.setCookieName("reportlet-conf-win-modal");
- reportletConfWin.setInitialHeight(REPORTLET_CONF_WIN_HEIGHT);
- reportletConfWin.setInitialWidth(REPORTLET_CONF_WIN_WIDTH);
- reportletConfWin.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
-
- private static final long serialVersionUID = 8804221891699487139L;
-
- @Override
- public void onClose(final AjaxRequestTarget target) {
- int foundIdx = -1;
- if (modalReportletConfOldName != null) {
- for (int i = 0; i < reportTO.getReportletConfs().size() && foundIdx == -1; i++) {
- if (reportTO.getReportletConfs().get(i).getName().equals(modalReportletConfOldName)) {
- foundIdx = i;
- }
- }
- }
- if (modalReportletConf != null) {
- if (foundIdx == -1) {
- reportTO.getReportletConfs().add(modalReportletConf);
- } else {
- reportTO.getReportletConfs().set(foundIdx, modalReportletConf);
- }
- }
-
- target.add(reportlets);
- }
- });
- add(reportletConfWin);
-
- final Label idLabel = new Label("idLabel", new ResourceModel("key"));
- profile.add(idLabel);
-
- final AjaxTextFieldPanel key =
- new AjaxTextFieldPanel("key", getString("key"), new PropertyModel<String>(reportTO, "key"));
- key.setEnabled(false);
- profile.add(key);
-
- final Label nameLabel = new Label("nameLabel", new ResourceModel("name"));
- profile.add(nameLabel);
-
- final AjaxTextFieldPanel name =
- new AjaxTextFieldPanel("name", getString("name"), new PropertyModel<String>(reportTO, "name"));
- profile.add(name);
-
- final AjaxTextFieldPanel lastExec = new AjaxTextFieldPanel("lastExec", getString("lastExec"),
- new DateFormatROModel(new PropertyModel<String>(reportTO, "lastExec")));
- lastExec.setEnabled(false);
- profile.add(lastExec);
-
- final AjaxTextFieldPanel nextExec = new AjaxTextFieldPanel("nextExec", getString("nextExec"),
- new DateFormatROModel(new PropertyModel<String>(reportTO, "nextExec")));
- nextExec.setEnabled(false);
- profile.add(nextExec);
-
- reportlets = new ListChoice<AbstractReportletConf>("reportletConfs", new Model<AbstractReportletConf>(),
- reportTO.getReportletConfs(), new IChoiceRenderer<ReportletConf>() {
-
- private static final long serialVersionUID = 1048000918946220007L;
-
- @Override
- public Object getDisplayValue(final ReportletConf object) {
- return object.getName();
- }
-
- @Override
- public String getIdValue(final ReportletConf object, final int index) {
- return object.getName();
- }
- }) {
-
- private static final long serialVersionUID = 4022366881854379834L;
-
- @Override
- protected CharSequence getDefaultChoice(final String selectedValue) {
- return null;
- }
- };
-
- reportlets.setNullValid(true);
- profile.add(reportlets);
- reportlets.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- target.add(reportlets);
- }
- });
-
- profile.add(new AjaxLink<Void>(ADD_BUTTON_ID) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- reportletConfWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- modalReportletConfOldName = null;
- modalReportletConf = null;
- return new ReportletConfModalPage(null, reportletConfWin,
- ReportModalPage.this.getPageReference());
- }
- });
- reportletConfWin.show(target);
- }
- });
-
- profile.add(new AjaxLink<Void>(EDIT_BUTTON_ID) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- if (reportlets.getModelObject() != null) {
- reportletConfWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- modalReportletConfOldName = reportlets.getModelObject().getName();
- modalReportletConf = null;
- return new ReportletConfModalPage(reportlets.getModelObject(), reportletConfWin,
- ReportModalPage.this.getPageReference());
- }
- });
- reportletConfWin.show(target);
- }
- }
- });
-
- profile.add(new AjaxLink<Void>(REMOVE_BUTTON_ID) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- reportTO.getReportletConfs().remove(reportlets.getModelObject());
- reportlets.setModelObject(null);
- target.add(reportlets);
- }
-
- @Override
- protected void updateAjaxAttributes(final AjaxRequestAttributes attributes) {
- if (reportlets.getModelObject() != null) {
-
- super.updateAjaxAttributes(attributes);
-
- final AjaxCallListener ajaxCallListener = new AjaxCallListener() {
-
- private static final long serialVersionUID = 7160235486520935153L;
-
- @Override
- public CharSequence getPrecondition(final Component component) {
- return "if (!confirm('" + getString("confirmDelete") + "')) {return false;}";
- }
- };
- attributes.getAjaxCallListeners().add(ajaxCallListener);
- }
- }
- });
-
- profile.add(new AjaxLink<Void>(UP_BUTTON_ID) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- if (reportlets.getModelObject() != null) {
- moveUp(reportlets.getModelObject());
- target.add(reportlets);
- }
- }
- });
-
- profile.add(new AjaxLink<Void>(DOWN_BUTTON_ID) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- if (reportlets.getModelObject() != null) {
- moveDown(reportlets.getModelObject());
- target.add(reportlets);
- }
- }
- });
- }
-
- private void moveUp(final AbstractReportletConf item) {
- final List<AbstractReportletConf> list = reportTO.getReportletConfs();
- int newPosition = list.indexOf(item) - 1;
- if (newPosition > -1) {
- list.remove(item);
- list.add(newPosition, item);
- }
- }
-
- private void moveDown(final AbstractReportletConf item) {
- final List<AbstractReportletConf> list = reportTO.getReportletConfs();
- int newPosition = list.indexOf(item) + 1;
- if (newPosition < list.size()) {
- list.remove(item);
- list.add(newPosition, item);
- }
- }
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- private void setupExecutions() {
- final WebMarkupContainer executions = new WebMarkupContainer("executionContainer");
- executions.setOutputMarkupId(true);
- form.add(executions);
-
- final ModalWindow reportExecMessageWin = new ModalWindow("reportExecMessageWin");
- reportExecMessageWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- reportExecMessageWin.setCookieName("report-exec-message-win-modal");
- add(reportExecMessageWin);
-
- final ModalWindow reportExecExportWin = new ModalWindow("reportExecExportWin");
- reportExecExportWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- reportExecExportWin.setCookieName("report-exec-export-win-modal");
- reportExecExportWin.setInitialHeight(EXEC_EXPORT_WIN_HEIGHT);
- reportExecExportWin.setInitialWidth(EXEC_EXPORT_WIN_WIDTH);
- reportExecExportWin.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
-
- private static final long serialVersionUID = 8804221891699487139L;
-
- @Override
- public void onClose(final AjaxRequestTarget target) {
- AjaxExportDownloadBehavior behavior = new AjaxExportDownloadBehavior(ReportModalPage.this.exportFormat,
- ReportModalPage.this.exportExecId);
- executions.add(behavior);
- behavior.initiate(target);
- }
- });
- add(reportExecExportWin);
-
- final List<IColumn> columns = new ArrayList<IColumn>();
- columns.add(new PropertyColumn(new ResourceModel("key"), "key", "key"));
- columns.add(new DatePropertyColumn(new ResourceModel("startDate"), "startDate", "startDate"));
- columns.add(new DatePropertyColumn(new ResourceModel("endDate"), "endDate", "endDate"));
- columns.add(new PropertyColumn(new ResourceModel("status"), "status", "status"));
- columns.add(new ActionColumn<ReportExecTO, String>(new ResourceModel("actions", "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public ActionLinksPanel getActions(final String componentId, final IModel<ReportExecTO> model) {
-
- final ReportExecTO taskExecutionTO = model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- reportExecMessageWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ExecMessageModalPage(model.getObject().getMessage());
- }
- });
- reportExecMessageWin.show(target);
- }
- }, ActionLink.ActionType.EDIT, "Reports", StringUtils.hasText(model.getObject().getMessage()));
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- reportExecExportWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- ReportModalPage.this.exportExecId = model.getObject().getKey();
- return new ReportExecResultDownloadModalPage(reportExecExportWin,
- ReportModalPage.this.getPageReference());
- }
- });
- reportExecExportWin.show(target);
- }
- }, ActionLink.ActionType.EXPORT, "Reports", ReportExecStatus.SUCCESS.name().equals(
- model.getObject().getStatus()));
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- reportRestClient.deleteExecution(taskExecutionTO.getKey());
-
- reportTO.getExecutions().remove(taskExecutionTO);
-
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
-
- feedbackPanel.refresh(target);
- target.add(executions);
- }
- }, ActionLink.ActionType.DELETE, "Reports");
-
- return panel;
- }
-
- @Override
- public Component getHeader(final String componentId) {
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), getPageReference());
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- if (target != null) {
- final ReportTO currentReportTO = reportTO.getKey() == 0
- ? reportTO
- : reportRestClient.read(reportTO.getKey());
- reportTO.getExecutions().clear();
- reportTO.getExecutions().addAll(currentReportTO.getExecutions());
- final AjaxFallbackDefaultDataTable currentTable =
- new AjaxFallbackDefaultDataTable("executionsTable", columns,
- new ReportExecutionsProvider(reportTO), 10);
- currentTable.setOutputMarkupId(true);
- target.add(currentTable);
- executions.addOrReplace(currentTable);
- }
- }
- }, ActionLink.ActionType.RELOAD, TASKS, "list");
-
- return panel;
- }
- });
-
- final AjaxFallbackDefaultDataTable table = new AjaxFallbackDefaultDataTable("executionsTable", columns,
- new ReportExecutionsProvider(reportTO), 10);
- executions.add(table);
- }
-
- public void setExportFormat(final ReportExecExportFormat exportFormat) {
- this.exportFormat = exportFormat;
- }
-
- public void setModalReportletConf(final AbstractReportletConf modalReportletConf) {
- this.modalReportletConf = modalReportletConf;
- }
-
- private static class ReportExecutionsProvider extends SortableDataProvider<ReportExecTO, String> {
-
- private static final long serialVersionUID = 2118096121691420539L;
-
- private final SortableDataProviderComparator<ReportExecTO> comparator;
-
- private final ReportTO reportTO;
-
- public ReportExecutionsProvider(final ReportTO reportTO) {
- super();
- this.reportTO = reportTO;
- setSort("startDate", SortOrder.DESCENDING);
- comparator = new SortableDataProviderComparator<ReportExecTO>(this);
- }
-
- @Override
- public Iterator<ReportExecTO> iterator(final long first, final long count) {
-
- List<ReportExecTO> list = reportTO.getExecutions();
-
- Collections.sort(list, comparator);
-
- return list.subList((int) first, (int) first + (int) count).iterator();
- }
-
- @Override
- public long size() {
- return reportTO.getExecutions().size();
- }
-
- @Override
- public IModel<ReportExecTO> model(final ReportExecTO taskExecution) {
-
- return new AbstractReadOnlyModel<ReportExecTO>() {
-
- private static final long serialVersionUID = 7485475149862342421L;
-
- @Override
- public ReportExecTO getObject() {
- return taskExecution;
- }
- };
- }
- }
-
- private class AjaxExportDownloadBehavior extends AbstractAjaxDownloadBehavior {
-
- private static final long serialVersionUID = 3109256773218160485L;
-
- private final ReportExecExportFormat exportFormat;
-
- private final long exportExecId;
-
- private HttpResourceStream stream;
-
- public AjaxExportDownloadBehavior(final ReportExecExportFormat exportFormat, final long exportExecId) {
- super();
- this.exportFormat = exportFormat;
- this.exportExecId = exportExecId;
- }
-
- private void createResourceStream() {
- if (stream == null) {
- stream = new HttpResourceStream(reportRestClient.exportExecutionResult(exportExecId, exportFormat));
- }
- }
-
- @Override
- protected String getFileName() {
- createResourceStream();
- return stream == null
- ? null
- : stream.getFilename();
- }
-
- @Override
- protected IResourceStream getResourceStream() {
- createResourceStream();
- return stream;
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/ReportletConfModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/ReportletConfModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/ReportletConfModalPage.java
deleted file mode 100644
index 36560b0..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/ReportletConfModalPage.java
+++ /dev/null
@@ -1,362 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.lang.reflect.Field;
-import java.lang.reflect.ParameterizedType;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.Date;
-import java.util.List;
-import org.apache.commons.lang3.ArrayUtils;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.panels.GroupSearchPanel;
-import org.apache.syncope.client.console.panels.UserSearchPanel;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPalettePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.CheckBoxMultipleChoiceFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.DateTimeFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.FieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.SpinnerFieldPanel;
-import org.apache.syncope.common.lib.SyncopeConstants;
-import org.apache.syncope.common.lib.annotation.FormAttributeField;
-import org.apache.syncope.common.lib.report.AbstractReportletConf;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.wicket.Component;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.model.util.ListModel;
-import org.apache.wicket.util.visit.IVisit;
-import org.apache.wicket.util.visit.IVisitor;
-import org.springframework.beans.BeanWrapper;
-import org.springframework.beans.PropertyAccessorFactory;
-import org.springframework.util.ClassUtils;
-
-public class ReportletConfModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = 3910027601200382958L;
-
- private static final String[] EXCLUDE_PROPERTIES =
- new String[] { "serialVersionUID", "class", "name", "reportletClassName" };
-
- private AbstractReportletConf reportletConf;
-
- private final AjaxTextFieldPanel name;
-
- private WebMarkupContainer propertiesContainer;
-
- private ListView<String> propView;
-
- public ReportletConfModalPage(final AbstractReportletConf reportletConf, final ModalWindow window,
- final PageReference pageRef) {
-
- this.reportletConf = reportletConf;
-
- final Form form = new Form(FORM);
- add(form);
-
- propertiesContainer = new WebMarkupContainer("container");
- propertiesContainer.setOutputMarkupId(true);
- form.add(propertiesContainer);
-
- name = new AjaxTextFieldPanel("name", "name", this.reportletConf == null
- ? new Model<String>()
- : new PropertyModel<String>(this.reportletConf, "name"));
- name.setOutputMarkupId(true);
- name.addRequiredLabel();
- form.add(name);
-
- final AjaxDropDownChoicePanel<String> reportletClass = new AjaxDropDownChoicePanel<String>("reportletClass",
- "reportletClass", new IModel<String>() {
-
- private static final long serialVersionUID = -2316468110411802130L;
-
- @Override
- public String getObject() {
- return ReportletConfModalPage.this.reportletConf == null
- ? null
- : ReportletConfModalPage.this.reportletConf.getClass().getName();
- }
-
- @Override
- public void setObject(final String object) {
- try {
- Class<?> reportletClass = Class.forName(object);
- ReportletConfModalPage.this.reportletConf = (AbstractReportletConf) reportletClass.
- newInstance();
- propertiesContainer.replace(buildPropView());
- } catch (Exception e) {
- LOG.error("Cannot find or initialize {}", object, e);
- }
- }
-
- @Override
- public void detach() {
- }
- });
- reportletClass.setStyleSheet("long_dynamicsize");
- reportletClass.setChoices(reportRestClient.getReportletConfClasses());
- ((DropDownChoice) reportletClass.getField()).setNullValid(true);
- reportletClass.addRequiredLabel();
- reportletClass.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = 5538299138211283825L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- ((DropDownChoice) reportletClass.getField()).setNullValid(false);
- target.add(reportletClass.getField());
- target.add(propertiesContainer);
- }
- });
- form.add(reportletClass);
-
- propertiesContainer.add(buildPropView());
-
- final AjaxButton submit = new AjaxButton(APPLY, new ResourceModel(APPLY)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- final BeanWrapper wrapper = PropertyAccessorFactory.
- forBeanPropertyAccess(ReportletConfModalPage.this.reportletConf);
- wrapper.setPropertyValue("name", name.getField().getInput());
-
- // Iterate over properties in order to find UserSearchPanel instances and manually update
- // this.reportletConf with select search criteria - this is needed because UserSearchPanel
- // does not comply with usual Wicket model paradigm.
- ReportletConfModalPage.this.propView.visitChildren(new IVisitor<Component, Void>() {
-
- @Override
- public void component(final Component component, final IVisit<Void> ivisit) {
- if (component instanceof UserSearchPanel) {
- // using component.getDefaultModelObjectAsString() to fetch field name (set above)
- wrapper.setPropertyValue(component.getDefaultModelObjectAsString(),
- ((UserSearchPanel) component).buildFIQL());
- }
- }
- });
-
- ((ReportModalPage) pageRef.getPage()).setModalReportletConf(ReportletConfModalPage.this.reportletConf);
- window.close(target);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
- form.add(submit);
-
- final AjaxButton cancel = new ClearIndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL), pageRef) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
- };
-
- cancel.setDefaultFormProcessing(false);
- form.add(cancel);
- }
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- private FieldPanel buildSinglePanel(final Class<?> type, final String fieldName, final String id) {
- FieldPanel result = null;
- PropertyModel model = new PropertyModel(ReportletConfModalPage.this.reportletConf, fieldName);
- if (ClassUtils.isAssignable(Boolean.class, type)) {
- result = new AjaxCheckBoxPanel(id, fieldName, model);
- } else if (ClassUtils.isAssignable(Number.class, type)) {
- result = new SpinnerFieldPanel<Number>(id, fieldName,
- (Class<Number>) ClassUtils.resolvePrimitiveIfNecessary(type), model, null, null);
- } else if (Date.class.equals(type)) {
- result = new DateTimeFieldPanel(id, fieldName, model, SyncopeConstants.DEFAULT_DATE_PATTERN);
- } else if (type.isEnum()) {
- result = new AjaxDropDownChoicePanel(id, fieldName, model).setChoices(
- Arrays.asList(type.getEnumConstants()));
- }
-
- // treat as String if nothing matched above
- if (result == null) {
- result = new AjaxTextFieldPanel(id, fieldName, model);
- }
-
- return result;
- }
-
- private ListView<String> buildPropView() {
- LoadableDetachableModel<List<String>> propViewModel = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- List<String> result = new ArrayList<String>();
- if (ReportletConfModalPage.this.reportletConf != null) {
- for (Field field : ReportletConfModalPage.this.reportletConf.getClass().getDeclaredFields()) {
- if (!ArrayUtils.contains(EXCLUDE_PROPERTIES, field.getName())) {
- result.add(field.getName());
- }
- }
- }
-
- return result;
- }
- };
-
- propView = new ListView<String>("propView", propViewModel) {
-
- private static final long serialVersionUID = 9101744072914090143L;
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- @Override
- protected void populateItem(final ListItem<String> item) {
- final String fieldName = item.getModelObject();
-
- Label label = new Label("key", fieldName);
- item.add(label);
-
- Field field = null;
- try {
- field = ReportletConfModalPage.this.reportletConf.getClass().getDeclaredField(fieldName);
- } catch (Exception e) {
- LOG.error("Could not find field {} in class {}",
- fieldName, ReportletConfModalPage.this.reportletConf.getClass(), e);
- }
- if (field == null) {
- return;
- }
-
- FormAttributeField annotation = field.getAnnotation(FormAttributeField.class);
-
- BeanWrapper wrapper = PropertyAccessorFactory.
- forBeanPropertyAccess(ReportletConfModalPage.this.reportletConf);
-
- Panel panel;
-
- if (String.class.equals(field.getType()) && annotation != null && annotation.userSearch()) {
- panel = new UserSearchPanel.Builder("value").
- fiql((String) wrapper.getPropertyValue(fieldName)).required(false).build();
- // This is needed in order to manually update this.reportletConf with search panel selections
- panel.setDefaultModel(new Model<String>(fieldName));
- } else if (String.class.equals(field.getType()) && annotation != null && annotation.groupSearch()) {
- panel = new GroupSearchPanel.Builder("value").
- fiql((String) wrapper.getPropertyValue(fieldName)).required(false).build();
- // This is needed in order to manually update this.reportletConf with search panel selections
- panel.setDefaultModel(new Model<String>(fieldName));
- } else if (List.class.equals(field.getType())) {
- Class<?> listItemType = String.class;
- if (field.getGenericType() instanceof ParameterizedType) {
- listItemType =
- (Class<?>) ((ParameterizedType) field.getGenericType()).getActualTypeArguments()[0];
- }
-
- if (listItemType.equals(String.class) && annotation != null) {
- List<String> choices;
- switch (annotation.schema()) {
- case UserPlainSchema:
- choices = schemaRestClient.getPlainSchemaNames(AttributableType.USER);
- break;
-
- case UserDerivedSchema:
- choices = schemaRestClient.getDerSchemaNames(AttributableType.USER);
- break;
-
- case UserVirtualSchema:
- choices = schemaRestClient.getVirSchemaNames(AttributableType.USER);
- break;
-
- case GroupPlainSchema:
- choices = schemaRestClient.getPlainSchemaNames(AttributableType.GROUP);
- break;
-
- case GroupDerivedSchema:
- choices = schemaRestClient.getDerSchemaNames(AttributableType.GROUP);
- break;
-
- case GroupVirtualSchema:
- choices = schemaRestClient.getVirSchemaNames(AttributableType.GROUP);
- break;
-
- case MembershipPlainSchema:
- choices = schemaRestClient.getPlainSchemaNames(AttributableType.MEMBERSHIP);
- break;
-
- case MembershipDerivedSchema:
- choices = schemaRestClient.getDerSchemaNames(AttributableType.MEMBERSHIP);
- break;
-
- case MembershipVirtualSchema:
- choices = schemaRestClient.getVirSchemaNames(AttributableType.MEMBERSHIP);
- break;
-
- default:
- choices = Collections.emptyList();
- }
-
- panel = new AjaxPalettePanel("value", new PropertyModel<List<String>>(
- ReportletConfModalPage.this.reportletConf, fieldName), new ListModel<String>(choices),
- true);
- } else if (listItemType.isEnum()) {
- panel = new CheckBoxMultipleChoiceFieldPanel("value", new PropertyModel(
- ReportletConfModalPage.this.reportletConf, fieldName),
- new ListModel(Arrays.asList(listItemType.getEnumConstants())));
- } else {
- if (((List) wrapper.getPropertyValue(fieldName)).isEmpty()) {
- ((List) wrapper.getPropertyValue(fieldName)).add(null);
- }
-
- panel = new MultiFieldPanel("value", new PropertyModel<List>(
- ReportletConfModalPage.this.reportletConf, fieldName),
- buildSinglePanel(field.getType(), fieldName, "panel"));
- }
- } else {
- panel = buildSinglePanel(field.getType(), fieldName, "value");
- }
-
- item.add(panel);
- }
- };
-
- return propView;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/Reports.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/Reports.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/Reports.java
deleted file mode 100644
index e484701..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/Reports.java
+++ /dev/null
@@ -1,412 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-import org.apache.commons.lang3.tuple.Pair;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.PreferenceManager;
-import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
-import org.apache.syncope.client.console.panels.LoggerCategoryPanel;
-import org.apache.syncope.client.console.panels.SelectedEventsPanel;
-import org.apache.syncope.client.console.rest.LoggerRestClient;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.EventCategoryTO;
-import org.apache.syncope.common.lib.to.ReportTO;
-import org.apache.syncope.common.lib.types.AuditElements.Result;
-import org.apache.syncope.common.lib.types.AuditLoggerName;
-import org.apache.wicket.Component;
-import org.apache.wicket.Page;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
-import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.AbstractReadOnlyModel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.model.util.ListModel;
-import org.apache.wicket.request.mapper.parameter.PageParameters;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.springframework.util.CollectionUtils;
-
-/**
- * Auditing and Reporting.
- */
-public class Reports extends BasePage {
-
- private static final long serialVersionUID = -2071214196989178694L;
-
- private static final int WIN_HEIGHT = 500;
-
- private static final int WIN_WIDTH = 700;
-
- @SpringBean
- private LoggerRestClient loggerRestClient;
-
- @SpringBean
- private PreferenceManager prefMan;
-
- private WebMarkupContainer reportContainer;
-
- private WebMarkupContainer auditContainer;
-
- private int paginatorRows;
-
- private final ModalWindow window;
-
- public Reports(final PageParameters parameters) {
- super(parameters);
-
- window = new ModalWindow("reportWin");
- window.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- window.setInitialHeight(WIN_HEIGHT);
- window.setInitialWidth(WIN_WIDTH);
- window.setCookieName("view-report-win");
- add(window);
-
- setupReport();
- setupAudit();
- }
-
- private void setupReport() {
- reportContainer = new WebMarkupContainer("reportContainer");
- setWindowClosedCallback(window, reportContainer);
-
- MetaDataRoleAuthorizationStrategy.authorize(reportContainer, RENDER,
- xmlRolesReader.getEntitlement("Reports", "list"));
-
- paginatorRows = prefMan.getPaginatorRows(getRequest(), Constants.PREF_REPORT_PAGINATOR_ROWS);
-
- List<IColumn<ReportTO, String>> columns = new ArrayList<>();
- columns.add(new PropertyColumn<ReportTO, String>(new ResourceModel("key"), "key", "key"));
- columns.add(new PropertyColumn<ReportTO, String>(new ResourceModel("name"), "name", "name"));
- columns.add(new DatePropertyColumn<ReportTO>(new ResourceModel("lastExec"), "lastExec", "lastExec"));
- columns.add(new DatePropertyColumn<ReportTO>(new ResourceModel("nextExec"), "nextExec", "nextExec"));
- columns.add(new DatePropertyColumn<ReportTO>(new ResourceModel("startDate"), "startDate", "startDate"));
- columns.add(new DatePropertyColumn<ReportTO>(new ResourceModel("endDate"), "endDate", "endDate"));
- columns.add(new PropertyColumn<ReportTO, String>(
- new ResourceModel("latestExecStatus"), "latestExecStatus", "latestExecStatus"));
- columns.add(new ActionColumn<ReportTO, String>(new ResourceModel("actions", "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public ActionLinksPanel getActions(final String componentId, final IModel<ReportTO> model) {
-
- final ReportTO reportTO = model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
-
- window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ReportModalPage(window, reportTO, Reports.this.getPageReference());
- }
- });
-
- window.show(target);
- }
- }, ActionLink.ActionType.EDIT, "Reports");
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- reportRestClient.startExecution(reportTO.getKey());
- getSession().info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
-
- feedbackPanel.refresh(target);
- target.add(reportContainer);
- }
- }, ActionLink.ActionType.EXECUTE, "Reports");
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- reportRestClient.delete(reportTO.getKey());
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
- target.add(reportContainer);
- feedbackPanel.refresh(target);
- }
- }, ActionLink.ActionType.DELETE, "Reports");
-
- return panel;
- }
-
- @Override
- public Component getHeader(final String componentId) {
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), getPageReference());
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- if (target != null) {
- target.add(reportContainer);
- }
- }
- }, ActionLink.ActionType.RELOAD, TASKS, "list");
-
- return panel;
- }
- });
-
- final AjaxFallbackDefaultDataTable<ReportTO, String> reportTable =
- new AjaxFallbackDefaultDataTable<>("reportTable", columns, new ReportProvider(), paginatorRows);
-
- reportContainer.add(reportTable);
- reportContainer.setOutputMarkupId(true);
-
- add(reportContainer);
-
- @SuppressWarnings("rawtypes")
- Form paginatorForm = new Form("paginatorForm");
-
- MetaDataRoleAuthorizationStrategy.authorize(paginatorForm, RENDER,
- xmlRolesReader.getEntitlement("Reports", "list"));
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- final DropDownChoice rowsChooser = new DropDownChoice("rowsChooser", new PropertyModel(this, "paginatorRows"),
- prefMan.getPaginatorChoices());
-
- rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- prefMan.set(getRequest(), getResponse(), Constants.PREF_REPORT_PAGINATOR_ROWS,
- String.valueOf(paginatorRows));
- reportTable.setItemsPerPage(paginatorRows);
-
- target.add(reportContainer);
- }
- });
-
- paginatorForm.add(rowsChooser);
- add(paginatorForm);
-
- AjaxLink<Void> createLink = new ClearIndicatingAjaxLink<Void>("createLink", getPageReference()) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ReportModalPage(window, new ReportTO(), Reports.this.getPageReference());
- }
- });
-
- window.show(target);
- }
- };
-
- MetaDataRoleAuthorizationStrategy.authorize(createLink, RENDER, xmlRolesReader.getEntitlement("Reports",
- "create"));
-
- add(createLink);
- }
-
- @SuppressWarnings("rawtypes")
- private void setupAudit() {
- auditContainer = new WebMarkupContainer("auditContainer");
- auditContainer.setOutputMarkupId(true);
- add(auditContainer);
-
- MetaDataRoleAuthorizationStrategy.authorize(
- auditContainer, RENDER, xmlRolesReader.getEntitlement("Audit", "list"));
-
- final Form form = new Form("auditForm");
- auditContainer.add(form);
-
- final List<String> events = new ArrayList<>();
-
- final List<AuditLoggerName> audits = loggerRestClient.listAudits();
- for (AuditLoggerName audit : audits) {
- events.add(AuditLoggerName.buildEvent(
- audit.getType(),
- audit.getCategory(),
- audit.getSubcategory(),
- audit.getEvent(),
- audit.getResult()));
- }
-
- final ListModel<String> model = new ListModel<>(new ArrayList<>(events));
-
- form.add(new LoggerCategoryPanel(
- "events", loggerRestClient.listEvents(), model, getPageReference(), "Reports") {
-
- private static final long serialVersionUID = 6113164334533550277L;
-
- @Override
- protected String[] getListRoles() {
- return new String[] {
- xmlRolesReader.getEntitlement("Audit", "list")
- };
- }
-
- @Override
- protected String[] getChangeRoles() {
- return new String[] {
- xmlRolesReader.getEntitlement("Audit", "enable"),
- xmlRolesReader.getEntitlement("Audit", "disable")
- };
- }
-
- @Override
- public void onEventAction(final IEvent<?> event) {
- if (event.getPayload() instanceof SelectedEventsPanel.EventSelectionChanged) {
-
- final SelectedEventsPanel.EventSelectionChanged eventSelectionChanged =
- (SelectedEventsPanel.EventSelectionChanged) event.getPayload();
-
- for (String toBeRemoved : eventSelectionChanged.getToBeRemoved()) {
- if (events.contains(toBeRemoved)) {
- Pair<EventCategoryTO, Result> eventCategory =
- AuditLoggerName.parseEventCategory(toBeRemoved);
-
- final AuditLoggerName auditLoggerName = new AuditLoggerName(
- eventCategory.getKey().getType(),
- eventCategory.getKey().getCategory(),
- eventCategory.getKey().getSubcategory(),
- CollectionUtils.isEmpty(eventCategory.getKey().getEvents())
- ? null : eventCategory.getKey().getEvents().iterator().next(),
- eventCategory.getValue());
-
- loggerRestClient.disableAudit(auditLoggerName);
- events.remove(toBeRemoved);
- }
- }
-
- for (String toBeAdded : eventSelectionChanged.getToBeAdded()) {
- if (!events.contains(toBeAdded)) {
- Pair<EventCategoryTO, Result> eventCategory =
- AuditLoggerName.parseEventCategory(toBeAdded);
-
- final AuditLoggerName auditLoggerName = new AuditLoggerName(
- eventCategory.getKey().getType(),
- eventCategory.getKey().getCategory(),
- eventCategory.getKey().getSubcategory(),
- CollectionUtils.isEmpty(eventCategory.getKey().getEvents())
- ? null : eventCategory.getKey().getEvents().iterator().next(),
- eventCategory.getValue());
-
- loggerRestClient.enableAudit(auditLoggerName);
- events.add(toBeAdded);
- }
- }
- }
- }
- });
- }
-
- private class ReportProvider extends SortableDataProvider<ReportTO, String> {
-
- private static final long serialVersionUID = -2311716167583335852L;
-
- private final SortableDataProviderComparator<ReportTO> comparator;
-
- public ReportProvider() {
- super();
-
- //Default sorting
- setSort("key", SortOrder.ASCENDING);
- comparator = new SortableDataProviderComparator<>(this);
- }
-
- @Override
- public Iterator<ReportTO> iterator(final long first, final long count) {
- final int page = ((int) first / paginatorRows);
-
- final List<ReportTO> list =
- reportRestClient.list((page < 0 ? 0 : page) + 1, paginatorRows, getSort());
- Collections.sort(list, comparator);
- return list.iterator();
- }
-
- @Override
- public long size() {
- return reportRestClient.count();
- }
-
- @Override
- public IModel<ReportTO> model(final ReportTO configuration) {
-
- return new AbstractReadOnlyModel<ReportTO>() {
-
- private static final long serialVersionUID = 4921104837546595602L;
-
- @Override
- public ReportTO getObject() {
- return configuration;
- }
- };
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.java
deleted file mode 100644
index d8b762f..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.java
+++ /dev/null
@@ -1,153 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.Mode;
-import org.apache.syncope.client.console.rest.SecurityQuestionRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.common.lib.to.SecurityQuestionTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.form.StatelessForm;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class RequestPasswordResetModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = -8419445804421211904L;
-
- @SpringBean
- private SecurityQuestionRestClient securityQuestionRestClient;
-
- public RequestPasswordResetModalPage(final ModalWindow window) {
- super();
- setOutputMarkupId(true);
-
- final boolean handleSecurityQuestion = userSelfRestClient.isPwdResetRequiringSecurityQuestions();
-
- final StatelessForm<?> form = new StatelessForm<Object>(FORM);
- form.setOutputMarkupId(true);
-
- final Label securityQuestionLabel = new Label("securityQuestionLabel", getString("securityQuestion"));
- securityQuestionLabel.setOutputMarkupPlaceholderTag(true);
- securityQuestionLabel.setVisible(handleSecurityQuestion);
- form.add(securityQuestionLabel);
- final AjaxTextFieldPanel securityQuestion =
- new AjaxTextFieldPanel("securityQuestion", "securityQuestion", new Model<String>());
- securityQuestion.setReadOnly(true);
- securityQuestion.setRequired(true);
- securityQuestion.getField().setOutputMarkupId(true);
- securityQuestion.setOutputMarkupPlaceholderTag(true);
- securityQuestion.setVisible(handleSecurityQuestion);
- form.add(securityQuestion);
-
- final AjaxTextFieldPanel username =
- new AjaxTextFieldPanel("username", "username", new Model<String>());
- username.setRequired(true);
- username.getField().setOutputMarkupId(true);
- if (handleSecurityQuestion) {
- username.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_BLUR) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- getFeedbackMessages().clear();
- target.add(feedbackPanel);
- try {
- SecurityQuestionTO read = securityQuestionRestClient.readByUser(username.getModelObject());
- securityQuestion.setModelObject(read.getContent());
- } catch (Exception e) {
- LOG.error("While fetching security question for {}", username.getModelObject(), e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- securityQuestion.setModelObject(null);
- } finally {
- target.add(securityQuestion);
- }
- }
- });
- }
- form.add(username);
-
- final Label securityAnswerLabel = new Label("securityAnswerLabel", getString("securityAnswer"));
- securityAnswerLabel.setOutputMarkupPlaceholderTag(true);
- securityAnswerLabel.setVisible(handleSecurityQuestion);
- form.add(securityAnswerLabel);
- final AjaxTextFieldPanel securityAnswer =
- new AjaxTextFieldPanel("securityAnswer", "securityAnswer", new Model<String>());
- securityAnswer.setRequired(handleSecurityQuestion);
- securityAnswer.setOutputMarkupPlaceholderTag(true);
- securityAnswer.setVisible(handleSecurityQuestion);
- form.add(securityAnswer);
-
- final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(SUBMIT, SUBMIT)) {
-
- private static final long serialVersionUID = -4804368561204623354L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- try {
- userSelfRestClient.requestPasswordReset(username.getModelObject(), securityAnswer.getModelObject());
-
- setResponsePage(new ResultStatusModalPage.Builder(window, new UserTO()).
- mode(Mode.SELF).build());
- } catch (Exception e) {
- LOG.error("While requesting password reset for {}", username.getModelObject(), e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
- form.add(submit);
- form.setDefaultButton(submit);
-
- final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- // do nothing
- }
- };
- cancel.setDefaultFormProcessing(false);
- form.add(cancel);
-
- add(form);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/ResourceModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/ResourceModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/ResourceModalPage.java
deleted file mode 100644
index 0becc1a..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/ResourceModalPage.java
+++ /dev/null
@@ -1,214 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.panels.AnnotatedBeanPanel;
-import org.apache.syncope.client.console.panels.ResourceConnConfPanel;
-import org.apache.syncope.client.console.panels.ResourceDetailsPanel;
-import org.apache.syncope.client.console.panels.ResourceMappingPanel;
-import org.apache.syncope.client.console.panels.ResourceSecurityPanel;
-import org.apache.syncope.common.lib.to.MappingItemTO;
-import org.apache.syncope.common.lib.to.ResourceTO;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.ResourceModel;
-
-/**
- * Modal window with Resource form.
- */
-public class ResourceModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = 1734415311027284221L;
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- public ResourceModalPage(final PageReference pageRef, final ModalWindow window, final ResourceTO resourceTO,
- final boolean createFlag) {
-
- super();
-
- this.add(new Label("new", StringUtils.isBlank(resourceTO.getKey())
- ? new ResourceModel("new")
- : new Model(StringUtils.EMPTY)));
- this.add(new Label("name", StringUtils.isBlank(resourceTO.getKey())
- ? StringUtils.EMPTY
- : resourceTO.getKey()));
-
- final Form<ResourceTO> form = new Form<>(FORM);
- form.setModel(new CompoundPropertyModel<>(resourceTO));
-
- //--------------------------------
- // Resource details panel
- //--------------------------------
- form.add(new ResourceDetailsPanel("details", resourceTO,
- resourceRestClient.getPropagationActionsClasses(), createFlag));
-
- form.add(new AnnotatedBeanPanel("systeminformation", resourceTO));
- //--------------------------------
-
- //--------------------------------
- // Resource mapping panels
- //--------------------------------
- form.add(new ResourceMappingPanel("umapping", resourceTO, AttributableType.USER));
- form.add(new ResourceMappingPanel("gmapping", resourceTO, AttributableType.GROUP));
- //--------------------------------
-
- //--------------------------------
- // Resource connector configuration panel
- //--------------------------------
- ResourceConnConfPanel resourceConnConfPanel = new ResourceConnConfPanel("connconf", resourceTO, createFlag);
- MetaDataRoleAuthorizationStrategy.authorize(
- resourceConnConfPanel, ENABLE, xmlRolesReader.getEntitlement("Connectors", "read"));
- form.add(resourceConnConfPanel);
- //--------------------------------
-
- //--------------------------------
- // Resource security panel
- //--------------------------------
- form.add(new ResourceSecurityPanel("security", resourceTO));
- //--------------------------------
-
- final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(SUBMIT, SUBMIT)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- final ResourceTO resourceTO = (ResourceTO) form.getDefaultModelObject();
-
- boolean accountIdError = false;
-
- if (resourceTO.getUmapping() == null || resourceTO.getUmapping().getItems().isEmpty()) {
- resourceTO.setUmapping(null);
- } else {
- int uAccountIdCount = 0;
- for (MappingItemTO item : resourceTO.getUmapping().getItems()) {
- if (item.isAccountid()) {
- uAccountIdCount++;
- }
- }
- accountIdError = uAccountIdCount != 1;
- }
-
- if (resourceTO.getGmapping() == null || resourceTO.getGmapping().getItems().isEmpty()) {
- resourceTO.setGmapping(null);
- } else {
- int rAccountIdCount = 0;
- for (MappingItemTO item : resourceTO.getGmapping().getItems()) {
- if (item.isAccountid()) {
- rAccountIdCount++;
- }
- }
- accountIdError |= rAccountIdCount != 1;
- }
-
- if (accountIdError) {
- error(getString("accountIdValidation"));
- feedbackPanel.refresh(target);
- } else {
- try {
- if (createFlag) {
- resourceRestClient.create(resourceTO);
- } else {
- resourceRestClient.update(resourceTO);
- }
-
- if (pageRef != null && pageRef.getPage() instanceof AbstractBasePage) {
- ((AbstractBasePage) pageRef.getPage()).setModalResult(true);
- }
- window.close(target);
- } catch (Exception e) {
- LOG.error("Failure managing resource {}", resourceTO, e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
-
- form.add(submit);
- form.setDefaultButton(submit);
-
- final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- }
- };
-
- cancel.setDefaultFormProcessing(false);
- form.add(cancel);
-
- add(form);
-
- MetaDataRoleAuthorizationStrategy.authorize(
- submit, ENABLE, xmlRolesReader.getEntitlement("Resources", createFlag ? "create" : "update"));
- }
-
- /**
- * Generic resource event.
- */
- public static class ResourceEvent {
-
- /**
- * Request target.
- */
- private final AjaxRequestTarget target;
-
- /**
- * Constructor.
- *
- * @param target request target.
- */
- public ResourceEvent(final AjaxRequestTarget target) {
- this.target = target;
- }
-
- /**
- * Target getter.
- *
- * @return request target.
- */
- public AjaxRequestTarget getTarget() {
- return target;
- }
- }
-}
[14/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/NotificationPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/NotificationPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/NotificationPanel.java
new file mode 100644
index 0000000..8624d26
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/NotificationPanel.java
@@ -0,0 +1,119 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.wicket.AttributeModifier;
+import org.apache.wicket.ajax.AjaxEventBehavior;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.feedback.FeedbackMessage;
+import org.apache.wicket.feedback.IFeedbackMessageFilter;
+import org.apache.wicket.markup.html.panel.FeedbackPanel;
+import org.apache.wicket.model.Model;
+
+public class NotificationPanel extends FeedbackPanel {
+
+ private static final long serialVersionUID = 5895940553202128621L;
+
+ private static final String CSS_CLASS = "notificationpanel";
+
+ private static final String DEFAULT_ADDITIONAL_CSS_CLASS = "notificationpanel_top_right";
+
+ private final String additionalCSSClass;
+
+ public NotificationPanel(final String id) {
+ this(id, null, null);
+ }
+
+ public NotificationPanel(final String id, final String additionalCSSClass,
+ final IFeedbackMessageFilter feedbackMessageFilter) {
+
+ super(id, feedbackMessageFilter);
+
+ this.add(new AjaxEventBehavior(Constants.ON_CLICK) {
+
+ private static final long serialVersionUID = -7133385027739964990L;
+
+ @Override
+ protected void onEvent(final AjaxRequestTarget target) {
+ target.appendJavaScript(
+ "setTimeout(\"$('div#" + getMarkupId() + "').fadeOut('normal')\", 0);");
+ }
+ });
+
+ this.additionalCSSClass = StringUtils.isBlank(additionalCSSClass)
+ ? DEFAULT_ADDITIONAL_CSS_CLASS
+ : additionalCSSClass;
+
+ // set custom markup id and ouput it, to find the component later on in the js function
+ setMarkupId(id);
+ setOutputMarkupId(true);
+
+ // Add the additional cssClass and hide the element by default
+ add(new AttributeModifier("class", new Model<String>(CSS_CLASS + " " + this.additionalCSSClass)));
+ add(new AttributeModifier("style", new Model<String>("opacity: 0;")));
+ }
+
+ /**
+ * Method to refresh the notification panel.
+ *
+ * If there are any feedback messages for the user, find the gravest level, format the notification panel
+ * accordingly and show it.
+ *
+ * @param target AjaxRequestTarget to add panel and the calling javascript function
+ */
+ public void refresh(final AjaxRequestTarget target) {
+ // any feedback at all in the current form?
+ if (anyMessage()) {
+ int highestFeedbackLevel = FeedbackMessage.INFO;
+
+ // any feedback with the given level?
+ if (anyMessage(FeedbackMessage.WARNING)) {
+ highestFeedbackLevel = FeedbackMessage.WARNING;
+ }
+ if (anyMessage(FeedbackMessage.ERROR)) {
+ highestFeedbackLevel = FeedbackMessage.ERROR;
+ }
+
+ // add the css classes to the notification panel,
+ // including the border css which represents the highest level of feedback
+ add(new AttributeModifier("class",
+ new Model<String>(CSS_CLASS
+ + " " + additionalCSSClass
+ + " notificationpanel_border_" + highestFeedbackLevel)));
+
+ // refresh the panel and call the js function with the panel markup id
+ // and the total count of messages
+ target.add(this);
+ if (anyMessage(FeedbackMessage.ERROR)) {
+ target.appendJavaScript(
+ "$('div#" + getMarkupId() + "').fadeTo('normal', 1.0);");
+ } else {
+ target.appendJavaScript(
+ "showNotification('" + getMarkupId() + "', " + getCurrentMessages().size() + ");");
+ }
+ }
+ }
+
+ @Override
+ protected String getCSSClass(final FeedbackMessage message) {
+ return "notificationpanel_row_" + message.getLevelAsString();
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/NotificationTasks.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/NotificationTasks.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/NotificationTasks.java
new file mode 100644
index 0000000..d7f52e1
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/NotificationTasks.java
@@ -0,0 +1,254 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.pages.NotificationTaskModalPage;
+import org.apache.syncope.client.console.pages.Tasks;
+import org.apache.syncope.client.console.pages.Tasks.TasksProvider;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.AbstractTaskTO;
+import org.apache.syncope.common.lib.to.NotificationTaskTO;
+import org.apache.wicket.Component;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.StringResourceModel;
+import org.apache.wicket.request.http.WebResponse;
+
+public class NotificationTasks extends AbstractTasks {
+
+ private static final long serialVersionUID = 4984337552918213290L;
+
+ private int paginatorRows;
+
+ private WebMarkupContainer container;
+
+ private boolean operationResult = false;
+
+ private ModalWindow window;
+
+ private AjaxDataTablePanel<AbstractTaskTO, String> table;
+
+ public NotificationTasks(final String id, final PageReference pageRef) {
+ super(id, pageRef);
+
+ container = new WebMarkupContainer("container");
+ container.setOutputMarkupId(true);
+ add(container);
+
+ add(window = new ModalWindow("taskWin"));
+
+ paginatorRows = prefMan.getPaginatorRows(getWebRequest(), Constants.PREF_NOTIFICATION_TASKS_PAGINATOR_ROWS);
+
+ table = Tasks.updateTaskTable(
+ getColumns(),
+ new TasksProvider<NotificationTaskTO>(restClient, paginatorRows, getId(), NotificationTaskTO.class),
+ container,
+ 0,
+ pageRef,
+ restClient);
+
+ container.add(table);
+
+ window.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
+
+ private static final long serialVersionUID = 8804221891699487139L;
+
+ @Override
+ public void onClose(final AjaxRequestTarget target) {
+ target.add(container);
+ if (operationResult) {
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ target.add(getPage().get(Constants.FEEDBACK));
+ operationResult = false;
+ }
+ }
+ });
+
+ window.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ window.setInitialHeight(WIN_HEIGHT);
+ window.setInitialWidth(WIN_WIDTH);
+ window.setCookieName(VIEW_TASK_WIN_COOKIE_NAME);
+
+ @SuppressWarnings("rawtypes")
+ final Form paginatorForm = new Form("PaginatorForm");
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ final DropDownChoice rowsChooser = new DropDownChoice("rowsChooser", new PropertyModel(this, "paginatorRows"),
+ prefMan.getPaginatorChoices());
+
+ rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ prefMan.set(getWebRequest(), (WebResponse) getResponse(),
+ Constants.PREF_NOTIFICATION_TASKS_PAGINATOR_ROWS, String.valueOf(paginatorRows));
+
+ table = Tasks.updateTaskTable(
+ getColumns(),
+ new TasksProvider<NotificationTaskTO>(restClient, paginatorRows, getId(),
+ NotificationTaskTO.class),
+ container,
+ table == null ? 0 : (int) table.getCurrentPage(),
+ pageRef,
+ restClient);
+
+ target.add(container);
+ }
+ });
+
+ paginatorForm.add(rowsChooser);
+ add(paginatorForm);
+ }
+
+ private List<IColumn<AbstractTaskTO, String>> getColumns() {
+ final List<IColumn<AbstractTaskTO, String>> columns = new ArrayList<>();
+
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("key", this, null), "key", "key"));
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("sender", this, null), "sender", "sender"));
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("recipients", this, null), "recipients", "recipients"));
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("subject", this, null), "subject", "subject"));
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("traceLevel", this, null), "traceLevel", "traceLevel"));
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("latestExecStatus", this, null), "latestExecStatus", "latestExecStatus"));
+
+ columns.add(new ActionColumn<AbstractTaskTO, String>(new StringResourceModel("actions", this, null, "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public ActionLinksPanel getActions(final String componentId, final IModel<AbstractTaskTO> model) {
+
+ final AbstractTaskTO taskTO = model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, pageRef);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+
+ window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new NotificationTaskModalPage(taskTO);
+ }
+ });
+
+ window.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, TASKS);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ restClient.startExecution(taskTO.getKey(), false);
+ getSession().info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+
+ ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
+ target.add(container);
+ }
+ }, ActionLink.ActionType.EXECUTE, TASKS);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ restClient.delete(taskTO.getKey(), NotificationTaskTO.class);
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+ target.add(container);
+ ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
+ }
+ }, ActionLink.ActionType.DELETE, TASKS);
+
+ return panel;
+ }
+
+ @Override
+ public Component getHeader(String componentId) {
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), pageRef);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ if (target != null) {
+ target.add(table);
+ }
+ }
+ }, ActionLink.ActionType.RELOAD, TASKS, "list");
+
+ return panel;
+ }
+ });
+
+ return columns;
+ }
+
+ @Override
+ public void onEvent(final IEvent<?> event) {
+ if (event.getPayload() instanceof AbstractSearchResultPanel.EventDataWrapper) {
+ ((AbstractSearchResultPanel.EventDataWrapper) event.getPayload()).getTarget().add(container);
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PlainAttrsPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PlainAttrsPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PlainAttrsPanel.java
new file mode 100644
index 0000000..b0517b0
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PlainAttrsPanel.java
@@ -0,0 +1,395 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Comparator;
+import java.util.Date;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.LinkedHashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+import java.util.TreeMap;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.AttrLayoutType;
+import org.apache.syncope.client.console.commons.JexlHelpUtils;
+import org.apache.syncope.client.console.commons.Mode;
+import org.apache.syncope.client.console.panels.AttrTemplatesPanel.GroupAttrTemplatesChange;
+import org.apache.syncope.client.console.rest.ConfigurationRestClient;
+import org.apache.syncope.client.console.rest.GroupRestClient;
+import org.apache.syncope.client.console.rest.SchemaRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.BinaryFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.DateTextFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.DateTimeFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.FieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.SpinnerFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.list.AltListView;
+import org.apache.syncope.common.lib.SyncopeConstants;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.to.AttrTO;
+import org.apache.syncope.common.lib.to.ConfTO;
+import org.apache.syncope.common.lib.to.MembershipTO;
+import org.apache.syncope.common.lib.to.PlainSchemaTO;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.syncope.common.lib.types.AttrSchemaType;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.form.IChoiceRenderer;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class PlainAttrsPanel extends Panel {
+
+ private static final long serialVersionUID = 552437609667518888L;
+
+ @SpringBean
+ private SchemaRestClient schemaRestClient;
+
+ @SpringBean
+ private ConfigurationRestClient confRestClient;
+
+ @SpringBean
+ private GroupRestClient groupRestClient;
+
+ private final AbstractAttributableTO entityTO;
+
+ private final Mode mode;
+
+ private final AttrTemplatesPanel attrTemplates;
+
+ private Map<String, PlainSchemaTO> schemas = new LinkedHashMap<>();
+
+ public <T extends AbstractAttributableTO> PlainAttrsPanel(final String id, final T entityTO,
+ final Form<?> form, final Mode mode) {
+
+ this(id, entityTO, form, mode, null);
+ }
+
+ public <T extends AbstractAttributableTO> PlainAttrsPanel(final String id, final T entityTO,
+ final Form<?> form, final Mode mode, final AttrTemplatesPanel attrTemplates) {
+
+ super(id);
+ this.entityTO = entityTO;
+ this.mode = mode;
+ this.attrTemplates = attrTemplates;
+ this.setOutputMarkupId(true);
+
+ setSchemas();
+ setAttrs();
+
+ add(new AltListView<AttrTO>("schemas", new PropertyModel<List<? extends AttrTO>>(entityTO, "attrs")) {
+
+ private static final long serialVersionUID = 9101744072914090143L;
+
+ @Override
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ protected void populateItem(final ListItem<AttrTO> item) {
+ final AttrTO attributeTO = (AttrTO) item.getDefaultModelObject();
+
+ final WebMarkupContainer jexlHelp = JexlHelpUtils.getJexlHelpWebContainer("jexlHelp");
+
+ final AjaxLink<Void> questionMarkJexlHelp = JexlHelpUtils.getAjaxLink(jexlHelp, "questionMarkJexlHelp");
+ item.add(questionMarkJexlHelp);
+ questionMarkJexlHelp.add(jexlHelp);
+
+ if (mode != Mode.TEMPLATE) {
+ questionMarkJexlHelp.setVisible(false);
+ }
+
+ item.add(new Label("name", attributeTO.getSchema()));
+
+ final FieldPanel panel = getFieldPanel(schemas.get(attributeTO.getSchema()), form, attributeTO);
+
+ if (mode == Mode.TEMPLATE || !schemas.get(attributeTO.getSchema()).isMultivalue()) {
+ item.add(panel);
+ } else {
+ item.add(new MultiFieldPanel<String>(
+ "panel", new PropertyModel<List<String>>(attributeTO, "values"), panel));
+ }
+ }
+ }
+ );
+ }
+
+ private void setSchemas() {
+ AttrTO attrLayout = null;
+ List<PlainSchemaTO> schemaTOs;
+
+ if (entityTO instanceof GroupTO) {
+ final GroupTO groupTO = (GroupTO) entityTO;
+
+ attrLayout = confRestClient.readAttrLayout(AttrLayoutType.valueOf(mode, AttributableType.GROUP));
+ schemaTOs = schemaRestClient.getSchemas(AttributableType.GROUP);
+ Set<String> allowed;
+ if (attrTemplates == null) {
+ allowed = new HashSet<>(groupTO.getGPlainAttrTemplates());
+ } else {
+ allowed = new HashSet<>(attrTemplates.getSelected(AttrTemplatesPanel.Type.gPlainAttrTemplates));
+ if (groupTO.isInheritTemplates() && groupTO.getParent() != 0) {
+ allowed.addAll(groupRestClient.read(groupTO.getParent()).getGPlainAttrTemplates());
+ }
+ }
+ schemaRestClient.filter(schemaTOs, allowed, true);
+ } else if (entityTO instanceof UserTO) {
+ attrLayout = confRestClient.readAttrLayout(AttrLayoutType.valueOf(mode, AttributableType.USER));
+ schemaTOs = schemaRestClient.getSchemas(AttributableType.USER);
+ } else if (entityTO instanceof MembershipTO) {
+ attrLayout = confRestClient.readAttrLayout(AttrLayoutType.valueOf(mode, AttributableType.MEMBERSHIP));
+ schemaTOs = schemaRestClient.getSchemas(AttributableType.MEMBERSHIP);
+ Set<String> allowed = new HashSet<>(
+ groupRestClient.read(((MembershipTO) entityTO).getGroupKey()).getMPlainAttrTemplates());
+ schemaRestClient.filter(schemaTOs, allowed, true);
+ } else {
+ schemas = new TreeMap<>();
+ schemaTOs = schemaRestClient.getSchemas(AttributableType.CONFIGURATION);
+ for (Iterator<PlainSchemaTO> it = schemaTOs.iterator(); it.hasNext();) {
+ PlainSchemaTO schemaTO = it.next();
+ for (AttrLayoutType type : AttrLayoutType.values()) {
+ if (type.getConfKey().equals(schemaTO.getKey())) {
+ it.remove();
+ }
+ }
+ }
+ }
+
+ schemas.clear();
+
+ if (attrLayout != null && mode != Mode.TEMPLATE && !(entityTO instanceof ConfTO)) {
+ // 1. remove attributes not selected for display
+ schemaRestClient.filter(schemaTOs, attrLayout.getValues(), true);
+ // 2. sort remainig attributes according to configuration, e.g. attrLayout
+ final Map<String, Integer> attrLayoutMap = new HashMap<>(attrLayout.getValues().size());
+ for (int i = 0; i < attrLayout.getValues().size(); i++) {
+ attrLayoutMap.put(attrLayout.getValues().get(i), i);
+ }
+ Collections.sort(schemaTOs, new Comparator<PlainSchemaTO>() {
+
+ @Override
+ public int compare(final PlainSchemaTO schema1, final PlainSchemaTO schema2) {
+ int value = 0;
+
+ if (attrLayoutMap.get(schema1.getKey()) > attrLayoutMap.get(schema2.getKey())) {
+ value = 1;
+ } else if (attrLayoutMap.get(schema1.getKey()) < attrLayoutMap.get(schema2.getKey())) {
+ value = -1;
+ }
+
+ return value;
+ }
+ });
+ }
+ for (PlainSchemaTO schemaTO : schemaTOs) {
+ schemas.put(schemaTO.getKey(), schemaTO);
+ }
+ }
+
+ private void setAttrs() {
+ final List<AttrTO> entityData = new ArrayList<>();
+
+ final Map<String, AttrTO> attrMap = entityTO.getPlainAttrMap();
+
+ for (PlainSchemaTO schema : schemas.values()) {
+ final AttrTO attributeTO = new AttrTO();
+ attributeTO.setSchema(schema.getKey());
+
+ if (attrMap.get(schema.getKey()) == null || attrMap.get(schema.getKey()).getValues().isEmpty()) {
+ attributeTO.getValues().add("");
+
+ // is important to set readonly only after values setting
+ attributeTO.setReadonly(schema.isReadonly());
+ } else {
+ attributeTO.getValues().addAll(attrMap.get(schema.getKey()).getValues());
+ }
+ entityData.add(attributeTO);
+ }
+
+ entityTO.getPlainAttrs().clear();
+ entityTO.getPlainAttrs().addAll(entityData);
+ }
+
+ @SuppressWarnings({ "rawtypes", "unchecked" })
+ private FieldPanel getFieldPanel(final PlainSchemaTO schemaTO, final Form form, final AttrTO attributeTO) {
+ final boolean required = mode == Mode.TEMPLATE
+ ? false
+ : schemaTO.getMandatoryCondition().equalsIgnoreCase("true");
+
+ final boolean readOnly = mode == Mode.TEMPLATE ? false : schemaTO.isReadonly();
+
+ final AttrSchemaType type = mode == Mode.TEMPLATE ? AttrSchemaType.String : schemaTO.getType();
+
+ final FieldPanel panel;
+ switch (type) {
+ case Boolean:
+ panel = new AjaxCheckBoxPanel("panel", schemaTO.getKey(), new Model<Boolean>());
+ panel.setRequired(required);
+ break;
+
+ case Date:
+ final String dataPattern = schemaTO.getConversionPattern() == null
+ ? SyncopeConstants.DEFAULT_DATE_PATTERN
+ : schemaTO.getConversionPattern();
+
+ if (dataPattern.contains("H")) {
+ panel = new DateTimeFieldPanel("panel", schemaTO.getKey(), new Model<Date>(), dataPattern);
+
+ if (required) {
+ panel.addRequiredLabel();
+ ((DateTimeFieldPanel) panel).setFormValidator(form);
+ }
+ panel.setStyleSheet("ui-widget-content ui-corner-all");
+ } else {
+ panel = new DateTextFieldPanel("panel", schemaTO.getKey(), new Model<Date>(), dataPattern);
+
+ if (required) {
+ panel.addRequiredLabel();
+ }
+ }
+ break;
+
+ case Enum:
+ panel = new AjaxDropDownChoicePanel<String>("panel", schemaTO.getKey(), new Model<String>());
+ ((AjaxDropDownChoicePanel<String>) panel).setChoices(getEnumeratedValues(schemaTO));
+
+ if (StringUtils.isNotBlank(schemaTO.getEnumerationKeys())) {
+ ((AjaxDropDownChoicePanel) panel).setChoiceRenderer(new IChoiceRenderer<String>() {
+
+ private static final long serialVersionUID = -3724971416312135885L;
+
+ private final Map<String, String> valueMap = getEnumeratedKeyValues(schemaTO);
+
+ @Override
+ public String getDisplayValue(final String value) {
+ return valueMap.get(value) == null ? value : valueMap.get(value);
+ }
+
+ @Override
+ public String getIdValue(final String value, final int i) {
+ return value;
+ }
+ });
+ }
+
+ if (required) {
+ panel.addRequiredLabel();
+ }
+ break;
+
+ case Long:
+ panel = new SpinnerFieldPanel<Long>("panel", schemaTO.getKey(),
+ Long.class, new Model<Long>(), null, null);
+
+ if (required) {
+ panel.addRequiredLabel();
+ }
+ break;
+
+ case Double:
+ panel = new SpinnerFieldPanel<Double>("panel", schemaTO.getKey(),
+ Double.class, new Model<Double>(), null, null);
+
+ if (required) {
+ panel.addRequiredLabel();
+ }
+ break;
+
+ case Binary:
+ panel = new BinaryFieldPanel("panel", schemaTO.getKey(), new Model<String>(),
+ schemas.containsKey(schemaTO.getKey())
+ ? schemas.get(schemaTO.getKey()).getMimeType()
+ : null);
+
+ if (required) {
+ panel.addRequiredLabel();
+ }
+ break;
+
+ default:
+ panel = new AjaxTextFieldPanel("panel", schemaTO.getKey(), new Model<String>());
+
+ if (required) {
+ panel.addRequiredLabel();
+ }
+ }
+
+ panel.setReadOnly(readOnly);
+ panel.setNewModel(attributeTO.getValues());
+
+ return panel;
+ }
+
+ private Map<String, String> getEnumeratedKeyValues(final PlainSchemaTO schemaTO) {
+ final Map<String, String> res = new HashMap<>();
+
+ final String[] values = StringUtils.isBlank(schemaTO.getEnumerationValues())
+ ? new String[0]
+ : schemaTO.getEnumerationValues().split(SyncopeConstants.ENUM_VALUES_SEPARATOR);
+
+ final String[] keys = StringUtils.isBlank(schemaTO.getEnumerationKeys())
+ ? new String[0]
+ : schemaTO.getEnumerationKeys().split(SyncopeConstants.ENUM_VALUES_SEPARATOR);
+
+ for (int i = 0; i < values.length; i++) {
+ res.put(values[i].trim(), keys.length > i ? keys[i].trim() : null);
+ }
+
+ return res;
+ }
+
+ private List<String> getEnumeratedValues(final PlainSchemaTO schemaTO) {
+ final List<String> res = new ArrayList<>();
+
+ final String[] values = StringUtils.isBlank(schemaTO.getEnumerationValues())
+ ? new String[0]
+ : schemaTO.getEnumerationValues().split(SyncopeConstants.ENUM_VALUES_SEPARATOR);
+
+ for (String value : values) {
+ res.add(value.trim());
+ }
+
+ return res;
+ }
+
+ @Override
+ public void onEvent(final IEvent<?> event) {
+ if ((event.getPayload() instanceof GroupAttrTemplatesChange)) {
+ final GroupAttrTemplatesChange update = (GroupAttrTemplatesChange) event.getPayload();
+ if (attrTemplates != null && update.getType() == AttrTemplatesPanel.Type.gPlainAttrTemplates) {
+ setSchemas();
+ setAttrs();
+ update.getTarget().add(this);
+ }
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PoliciesPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PoliciesPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PoliciesPanel.java
new file mode 100644
index 0000000..4d66eda
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PoliciesPanel.java
@@ -0,0 +1,343 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.PreferenceManager;
+import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
+import org.apache.syncope.client.console.commons.XMLRolesReader;
+import org.apache.syncope.client.console.pages.BasePage;
+import org.apache.syncope.client.console.pages.PolicyModalPage;
+import org.apache.syncope.client.console.rest.PolicyRestClient;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.AbstractPolicyTO;
+import org.apache.syncope.common.lib.to.AccountPolicyTO;
+import org.apache.syncope.common.lib.to.PasswordPolicyTO;
+import org.apache.syncope.common.lib.to.SyncPolicyTO;
+import org.apache.syncope.common.lib.types.PolicyType;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.request.http.WebResponse;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class PoliciesPanel extends Panel {
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(PoliciesPanel.class);
+
+ private static final int MODAL_WIN_HEIGHT = 400;
+
+ private static final int MODAL_WIN_WIDTH = 1000;
+
+ private static final long serialVersionUID = -6804066913177804275L;
+
+ @SpringBean
+ private PolicyRestClient policyRestClient;
+
+ @SpringBean
+ protected XMLRolesReader xmlRolesReader;
+
+ @SpringBean
+ private PreferenceManager prefMan;
+
+ private final PageReference pageRef;
+
+ private final int paginatorRows = prefMan.getPaginatorRows(getWebRequest(), Constants.PREF_POLICY_PAGINATOR_ROWS);
+
+ protected boolean modalResult = false;
+
+ private final PolicyType policyType;
+
+ public PoliciesPanel(final String id, final PageReference pageRef, final PolicyType policyType) {
+ super(id);
+ this.pageRef = pageRef;
+ this.policyType = policyType;
+
+ // Modal window for editing user attributes
+ final ModalWindow mwindow = new ModalWindow("editModalWin");
+ mwindow.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ mwindow.setInitialHeight(MODAL_WIN_HEIGHT);
+ mwindow.setInitialWidth(MODAL_WIN_WIDTH);
+ mwindow.setCookieName("policy-modal");
+ add(mwindow);
+
+ // Container for user list
+ final WebMarkupContainer container = new WebMarkupContainer("container");
+ container.setOutputMarkupId(true);
+ add(container);
+
+ setWindowClosedCallback(mwindow, container);
+
+ final List<IColumn<AbstractPolicyTO, String>> columns = new ArrayList<>();
+
+ columns.add(new PropertyColumn<AbstractPolicyTO, String>(new ResourceModel("key"), "key", "key"));
+
+ columns.add(new PropertyColumn<AbstractPolicyTO, String>(
+ new ResourceModel("description"), "description", "description"));
+
+ columns.add(new AbstractColumn<AbstractPolicyTO, String>(new ResourceModel("type")) {
+
+ private static final long serialVersionUID = 8263694778917279290L;
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<AbstractPolicyTO>> cellItem, final String componentId,
+ final IModel<AbstractPolicyTO> model) {
+
+ cellItem.add(new Label(componentId, getString(model.getObject().getType().name())));
+ }
+ });
+
+ columns.add(new AbstractColumn<AbstractPolicyTO, String>(new ResourceModel("actions", "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public String getCssClass() {
+ return "action";
+ }
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<AbstractPolicyTO>> cellItem, final String componentId,
+ final IModel<AbstractPolicyTO> model) {
+
+ final AbstractPolicyTO policyTO = model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, pageRef);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+
+ mwindow.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ @Override
+ public Page createPage() {
+ return new PolicyModalPage(pageRef, mwindow, policyTO);
+ }
+ });
+
+ mwindow.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, "Policies");
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ policyRestClient.delete(policyTO.getKey(), policyTO.getClass());
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException e) {
+ error(getString(Constants.OPERATION_ERROR));
+
+ LOG.error("While deleting policy {}({})",
+ policyTO.getKey(), policyTO.getDescription(), e);
+ }
+
+ target.add(container);
+ ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
+ }
+ }, ActionLink.ActionType.DELETE, "Policies");
+
+ cellItem.add(panel);
+ }
+ });
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ final AjaxFallbackDefaultDataTable table = new AjaxFallbackDefaultDataTable("datatable", columns,
+ new PolicyDataProvider(), paginatorRows);
+
+ container.add(table);
+
+ final AjaxLink<Void> createButton = new ClearIndicatingAjaxLink<Void>("createLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ mwindow.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ @Override
+ public Page createPage() {
+ return new PolicyModalPage(pageRef, mwindow, getPolicyTOInstance(policyType));
+ }
+ });
+
+ mwindow.show(target);
+ }
+ };
+
+ add(createButton);
+
+ MetaDataRoleAuthorizationStrategy.authorize(
+ createButton, ENABLE, xmlRolesReader.getEntitlement("Policies", "create"));
+
+ @SuppressWarnings("rawtypes")
+ final Form paginatorForm = new Form("PaginatorForm");
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ final DropDownChoice rowsChooser = new DropDownChoice("rowsChooser", new PropertyModel(this, "paginatorRows"),
+ prefMan.getPaginatorChoices());
+
+ rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ prefMan.set(getWebRequest(), (WebResponse) getResponse(), Constants.PREF_POLICY_PAGINATOR_ROWS, String
+ .valueOf(paginatorRows));
+ table.setItemsPerPage(paginatorRows);
+
+ target.add(container);
+ }
+ });
+
+ paginatorForm.add(rowsChooser);
+ add(paginatorForm);
+ }
+
+ private void setWindowClosedCallback(final ModalWindow window, final WebMarkupContainer container) {
+ window.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
+
+ private static final long serialVersionUID = 8804221891699487139L;
+
+ @Override
+ public void onClose(final AjaxRequestTarget target) {
+ target.add(container);
+ BasePage configuration = ((BasePage) pageRef.getPage());
+ if (configuration.isModalResult()) {
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ configuration.getFeedbackPanel().refresh(target);
+ configuration.setModalResult(false);
+ }
+ }
+ });
+ }
+
+ private class PolicyDataProvider extends SortableDataProvider<AbstractPolicyTO, String> {
+
+ private static final long serialVersionUID = -6976327453925166730L;
+
+ private final SortableDataProviderComparator<AbstractPolicyTO> comparator;
+
+ public PolicyDataProvider() {
+ super();
+
+ //Default sorting
+ setSort("description", SortOrder.ASCENDING);
+
+ comparator = new SortableDataProviderComparator<AbstractPolicyTO>(this);
+ }
+
+ @Override
+ public long size() {
+ return policyRestClient.getPolicies(policyType, true).size();
+ }
+
+ @Override
+ public Iterator<AbstractPolicyTO> iterator(final long first, final long count) {
+ final List<AbstractPolicyTO> policies = policyRestClient.getPolicies(policyType, true);
+
+ Collections.sort(policies, comparator);
+
+ return policies.subList((int) first, (int) first + (int) count).iterator();
+ }
+
+ @Override
+ public IModel<AbstractPolicyTO> model(final AbstractPolicyTO object) {
+ return new CompoundPropertyModel<AbstractPolicyTO>(object);
+ }
+ }
+
+ private AbstractPolicyTO getPolicyTOInstance(final PolicyType policyType) {
+ AbstractPolicyTO policyTO;
+ switch (policyType) {
+ case GLOBAL_ACCOUNT:
+ policyTO = new AccountPolicyTO(true);
+ break;
+
+ case ACCOUNT:
+ policyTO = new AccountPolicyTO();
+ break;
+
+ case GLOBAL_PASSWORD:
+ policyTO = new PasswordPolicyTO(true);
+ break;
+
+ case PASSWORD:
+ policyTO = new PasswordPolicyTO();
+ break;
+
+ case GLOBAL_SYNC:
+ policyTO = new SyncPolicyTO(true);
+ break;
+
+ case SYNC:
+ default:
+ policyTO = new SyncPolicyTO();
+ }
+
+ return policyTO;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PolicyBeanPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PolicyBeanPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PolicyBeanPanel.java
new file mode 100644
index 0000000..a55be9f
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PolicyBeanPanel.java
@@ -0,0 +1,340 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.beans.PropertyDescriptor;
+import java.io.Serializable;
+import java.lang.reflect.Field;
+import java.lang.reflect.Modifier;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.rest.PolicyRestClient;
+import org.apache.syncope.client.console.rest.SchemaRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AbstractFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPalettePanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.FieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.SpinnerFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.list.AltListView;
+import org.apache.syncope.common.lib.annotation.ClassList;
+import org.apache.syncope.common.lib.annotation.SchemaList;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.syncope.common.lib.types.PolicySpec;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.model.util.ListModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.BeanUtils;
+import org.springframework.util.ClassUtils;
+import org.springframework.util.ReflectionUtils;
+import org.springframework.util.ReflectionUtils.FieldCallback;
+import org.springframework.util.ReflectionUtils.FieldFilter;
+
+public class PolicyBeanPanel extends Panel {
+
+ private static final long serialVersionUID = -3035998190456928143L;
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(PolicyBeanPanel.class);
+
+ @SpringBean
+ private SchemaRestClient schemaRestClient;
+
+ @SpringBean
+ private PolicyRestClient policyRestClient;
+
+ final IModel<List<String>> userSchemas = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = -2012833443695917883L;
+
+ @Override
+ protected List<String> load() {
+ return schemaRestClient.getPlainSchemaNames(AttributableType.USER);
+ }
+ };
+
+ final IModel<List<String>> groupSchemas = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ return schemaRestClient.getPlainSchemaNames(AttributableType.GROUP);
+ }
+ };
+
+ final IModel<List<String>> correlationRules = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ return policyRestClient.getCorrelationRuleClasses();
+ }
+ };
+
+ public PolicyBeanPanel(final String id, final PolicySpec policy) {
+ super(id);
+
+ final List<FieldWrapper> items = new ArrayList<>();
+ ReflectionUtils.doWithFields(policy.getClass(), new FieldCallback() {
+
+ @Override
+ public void doWith(final Field field) throws IllegalArgumentException, IllegalAccessException {
+ FieldWrapper fieldWrapper = new FieldWrapper();
+ fieldWrapper.setName(field.getName());
+ fieldWrapper.setType(field.getType());
+
+ final SchemaList schemaList = field.getAnnotation(SchemaList.class);
+ fieldWrapper.setSchemaList(schemaList);
+
+ final ClassList classList = field.getAnnotation(ClassList.class);
+ fieldWrapper.setClassList(classList);
+
+ items.add(fieldWrapper);
+ }
+ },
+ new FieldFilter() {
+
+ @Override
+ public boolean matches(final Field field) {
+ return !Modifier.isStatic(field.getModifiers()) && !"serialVersionUID".equals(field.getName());
+ }
+ });
+
+ final ListView<FieldWrapper> policies = new AltListView<FieldWrapper>("policies", items) {
+
+ private static final long serialVersionUID = 9101744072914090143L;
+
+ @Override
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ protected void populateItem(final ListItem<FieldWrapper> item) {
+ final FieldWrapper field = item.getModelObject();
+
+ final PropertyDescriptor propDesc = BeanUtils.getPropertyDescriptor(policy.getClass(), field.getName());
+
+ item.add(new Label("label", new ResourceModel(field.getName())));
+
+ AbstractFieldPanel component;
+ try {
+ if (field.getClassList() != null) {
+ component = new AjaxDropDownChoicePanel("field", field.getName(), new PropertyModel(policy,
+ field.getName()));
+
+ final List<String> rules = correlationRules.getObject();
+
+ if (rules != null && !rules.isEmpty()) {
+ ((AjaxDropDownChoicePanel) component).setChoices(correlationRules.getObject());
+ }
+
+ item.add(component);
+
+ item.add(getActivationControl(
+ component,
+ propDesc.getReadMethod().invoke(policy, new Object[] {}) != null,
+ null,
+ null));
+
+ } else if (field.getType().isEnum()) {
+ component = new AjaxDropDownChoicePanel("field", field.getName(), new PropertyModel(policy,
+ field.getName()));
+
+ final Serializable[] values = (Serializable[]) field.getType().getEnumConstants();
+
+ if (values != null && values.length > 0) {
+ ((AjaxDropDownChoicePanel) component).setChoices(Arrays.asList(values));
+ }
+
+ item.add(component);
+
+ item.add(getActivationControl(
+ component,
+ (Enum<?>) propDesc.getReadMethod().invoke(policy, new Object[] {}) != null,
+ values[0],
+ values[0]));
+
+ } else if (ClassUtils.isAssignable(Boolean.class, field.getType())) {
+ item.add(new AjaxCheckBoxPanel("check", field.getName(),
+ new PropertyModel<Boolean>(policy, field.getName())));
+
+ item.add(new Label("field", new Model(null)));
+ } else if (Collection.class.isAssignableFrom(field.getType())) {
+ if (field.getSchemaList() != null) {
+ final List<String> values = new ArrayList<>();
+ if (field.getName().charAt(0) == 'r') {
+ values.addAll(groupSchemas.getObject());
+
+ if (field.getSchemaList().extended()) {
+ values.add("name");
+ }
+ } else {
+ values.addAll(userSchemas.getObject());
+
+ if (field.getSchemaList().extended()) {
+ values.add("key");
+ values.add("username");
+ }
+ }
+
+ component = new AjaxPalettePanel("field", new PropertyModel(policy, field.getName()),
+ new ListModel<>(values));
+ item.add(component);
+
+ Collection<?> collection = (Collection) propDesc.getReadMethod().invoke(policy);
+ item.add(getActivationControl(component,
+ !collection.isEmpty(), new ArrayList<String>(), new ArrayList<String>()));
+ } else {
+ final FieldPanel panel = new AjaxTextFieldPanel("panel", field.getName(),
+ new Model<String>(null));
+ panel.setRequired(true);
+
+ component = new MultiFieldPanel<String>("field",
+ new PropertyModel(policy, field.getName()), panel);
+
+ item.add(component);
+
+ final List<String> reinitializedValue = new ArrayList<String>();
+
+ reinitializedValue.add("");
+
+ item.add(getActivationControl(component,
+ !((Collection) propDesc.getReadMethod().invoke(policy, new Object[] {})).isEmpty(),
+ new ArrayList<String>(), (Serializable) reinitializedValue));
+ }
+ } else if (ClassUtils.isAssignable(Number.class, field.getType())) {
+ component = new SpinnerFieldPanel<Number>("field", field.getName(),
+ (Class<Number>) field.getType(), new PropertyModel<Number>(policy, field.getName()),
+ null, null);
+ item.add(component);
+
+ item.add(getActivationControl(component,
+ (Integer) propDesc.getReadMethod().invoke(policy, new Object[] {}) > 0, 0, 0));
+ } else if (field.getType().equals(String.class)) {
+ component = new AjaxTextFieldPanel("field", field.getName(),
+ new PropertyModel(policy, field.getName()));
+
+ item.add(component);
+
+ item.add(getActivationControl(component,
+ propDesc.getReadMethod().invoke(policy, new Object[] {}) != null, null, null));
+ } else {
+ item.add(new AjaxCheckBoxPanel("check", field.getName(), new Model()));
+ item.add(new Label("field", new Model(null)));
+ }
+ } catch (Exception e) {
+ LOG.error("Error retrieving policy fields", e);
+ }
+ }
+ };
+
+ add(policies);
+ }
+
+ private <T extends Serializable> AjaxCheckBoxPanel getActivationControl(final AbstractFieldPanel<T> panel,
+ final Boolean checked, final T defaultModelObject, final T reinitializedValue) {
+
+ final AjaxCheckBoxPanel check = new AjaxCheckBoxPanel("check", "check", new Model<Boolean>(checked));
+
+ panel.setEnabled(checked);
+
+ check.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ if (check.getModelObject()) {
+ panel.setEnabled(true);
+ panel.setModelObject(reinitializedValue);
+ } else {
+ panel.setModelObject(defaultModelObject);
+ panel.setEnabled(false);
+ }
+
+ target.add(panel);
+ }
+ });
+
+ return check;
+ }
+
+ private static class FieldWrapper implements Serializable {
+
+ private static final long serialVersionUID = -6770429509752964215L;
+
+ private Class<?> type;
+
+ private String name;
+
+ private transient SchemaList schemaList;
+
+ private transient ClassList classList;
+
+ public String getName() {
+ return name;
+ }
+
+ public void setName(final String name) {
+ this.name = name;
+ }
+
+ public Class<?> getType() {
+ return type;
+ }
+
+ public void setType(final Class<?> type) {
+ this.type = type;
+ }
+
+ public SchemaList getSchemaList() {
+ return schemaList;
+ }
+
+ public void setSchemaList(final SchemaList schemaList) {
+ this.schemaList = schemaList;
+ }
+
+ public ClassList getClassList() {
+ return classList;
+ }
+
+ public void setClassList(ClassList classList) {
+ this.classList = classList;
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PropagationTasks.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PropagationTasks.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PropagationTasks.java
new file mode 100644
index 0000000..41fdb03
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PropagationTasks.java
@@ -0,0 +1,264 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.pages.PropagationTaskModalPage;
+import org.apache.syncope.client.console.pages.Tasks;
+import org.apache.syncope.client.console.pages.Tasks.TasksProvider;
+import org.apache.syncope.client.console.panels.AbstractSearchResultPanel.EventDataWrapper;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.AbstractTaskTO;
+import org.apache.syncope.common.lib.to.PropagationTaskTO;
+import org.apache.wicket.Component;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.StringResourceModel;
+import org.apache.wicket.request.http.WebResponse;
+
+/**
+ * Tasks page.
+ */
+public class PropagationTasks extends AbstractTasks {
+
+ private static final long serialVersionUID = 4984337552918213290L;
+
+ private int paginatorRows;
+
+ private WebMarkupContainer container;
+
+ private boolean operationResult = false;
+
+ private ModalWindow window;
+
+ private AjaxDataTablePanel<AbstractTaskTO, String> table;
+
+ public PropagationTasks(final String id, final PageReference pageRef) {
+ super(id, pageRef);
+
+ container = new WebMarkupContainer("container");
+ container.setOutputMarkupId(true);
+ add(container);
+
+ add(window = new ModalWindow("taskWin"));
+
+ paginatorRows = prefMan.getPaginatorRows(getWebRequest(), Constants.PREF_PROPAGATION_TASKS_PAGINATOR_ROWS);
+
+ table = Tasks.updateTaskTable(
+ getColumns(),
+ new TasksProvider<PropagationTaskTO>(restClient, paginatorRows, getId(), PropagationTaskTO.class),
+ container,
+ 0,
+ pageRef,
+ restClient);
+
+ window.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
+
+ private static final long serialVersionUID = 8804221891699487139L;
+
+ @Override
+ public void onClose(final AjaxRequestTarget target) {
+ target.add(container);
+ if (operationResult) {
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ target.add(getPage().get(Constants.FEEDBACK));
+ operationResult = false;
+ }
+ }
+ });
+
+ window.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ window.setInitialHeight(WIN_HEIGHT);
+ window.setInitialWidth(WIN_WIDTH);
+ window.setCookieName(VIEW_TASK_WIN_COOKIE_NAME);
+
+ @SuppressWarnings("rawtypes")
+ Form paginatorForm = new Form("PaginatorForm");
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ final DropDownChoice rowsChooser = new DropDownChoice(
+ "rowsChooser", new PropertyModel(this, "paginatorRows"), prefMan.getPaginatorChoices());
+
+ rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ prefMan.set(getWebRequest(), (WebResponse) getResponse(),
+ Constants.PREF_PROPAGATION_TASKS_PAGINATOR_ROWS, String.valueOf(paginatorRows));
+
+ table = Tasks.updateTaskTable(
+ getColumns(),
+ new TasksProvider<>(restClient, paginatorRows, getId(), PropagationTaskTO.class),
+ container,
+ table == null ? 0 : (int) table.getCurrentPage(),
+ pageRef,
+ restClient);
+
+ target.add(container);
+ }
+ });
+
+ paginatorForm.add(rowsChooser);
+ add(paginatorForm);
+ }
+
+ private List<IColumn<AbstractTaskTO, String>> getColumns() {
+ final List<IColumn<AbstractTaskTO, String>> columns = new ArrayList<>();
+
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("key", this, null), "key", "key"));
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("resource", this, null), "resource", "resource"));
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("accountId", this, null), "accountId", "accountId"));
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("propagationMode", this, null), "propagationMode", "propagationMode"));
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(new StringResourceModel(
+ "propagationOperation", this, null), "propagationOperation", "propagationOperation"));
+ columns.add(new DatePropertyColumn<AbstractTaskTO>(
+ new StringResourceModel("startDate", this, null), "startDate", "startDate"));
+ columns.add(new DatePropertyColumn<AbstractTaskTO>(
+ new StringResourceModel("endDate", this, null), "endDate", "endDate"));
+ columns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("latestExecStatus", this, null), "latestExecStatus", "latestExecStatus"));
+ columns.add(new ActionColumn<AbstractTaskTO, String>(new StringResourceModel("actions", this, null, "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public String getCssClass() {
+ return "action";
+ }
+
+ @Override
+ public ActionLinksPanel getActions(final String componentId, final IModel<AbstractTaskTO> model) {
+
+ final AbstractTaskTO taskTO = model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, pageRef);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+
+ window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new PropagationTaskModalPage(taskTO);
+ }
+ });
+
+ window.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, TASKS);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ restClient.startExecution(taskTO.getKey(), false);
+ getSession().info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+
+ ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
+ target.add(container);
+ }
+ }, ActionLink.ActionType.EXECUTE, TASKS);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ restClient.delete(taskTO.getKey(), PropagationTaskTO.class);
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+ target.add(container);
+ ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
+ }
+ }, ActionLink.ActionType.DELETE, TASKS);
+
+ return panel;
+ }
+
+ @Override
+ public Component getHeader(final String componentId) {
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), pageRef);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ if (target != null) {
+ target.add(table);
+ }
+ }
+ }, ActionLink.ActionType.RELOAD, TASKS, "list");
+
+ return panel;
+ }
+ });
+
+ return columns;
+ }
+
+ @Override
+ public void onEvent(final IEvent<?> event) {
+ if (event.getPayload() instanceof EventDataWrapper) {
+ ((EventDataWrapper) event.getPayload()).getTarget().add(container);
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PushTasksPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PushTasksPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PushTasksPanel.java
new file mode 100644
index 0000000..a93000d
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/PushTasksPanel.java
@@ -0,0 +1,184 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.pages.PushTaskModalPage;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.AbstractTaskTO;
+import org.apache.syncope.common.lib.to.PushTaskTO;
+import org.apache.syncope.common.lib.to.SyncTaskTO;
+import org.apache.wicket.Component;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.StringResourceModel;
+
+public class PushTasksPanel extends AbstractProvisioningTasksPanel<PushTaskTO> {
+
+ private static final long serialVersionUID = -2492299671757861889L;
+
+ public PushTasksPanel(final String id, final PageReference pageRef) {
+ super(id, pageRef, PushTaskTO.class);
+ initTasksTable();
+ }
+
+ @Override
+ protected List<IColumn<AbstractTaskTO, String>> getColumns() {
+ final List<IColumn<AbstractTaskTO, String>> pushTasksColumns = new ArrayList<IColumn<AbstractTaskTO, String>>();
+
+ pushTasksColumns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("key", this, null), "key", "key"));
+ pushTasksColumns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("name", this, null), "name", "name"));
+ pushTasksColumns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("description", this, null), "description", "description"));
+ pushTasksColumns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("resourceName", this, null), "resource", "resource"));
+ pushTasksColumns.add(new DatePropertyColumn<AbstractTaskTO>(
+ new StringResourceModel("lastExec", this, null), "lastExec", "lastExec"));
+ pushTasksColumns.add(new DatePropertyColumn<AbstractTaskTO>(
+ new StringResourceModel("nextExec", this, null), "nextExec", "nextExec"));
+ pushTasksColumns.add(new PropertyColumn<AbstractTaskTO, String>(
+ new StringResourceModel("latestExecStatus", this, null), "latestExecStatus", "latestExecStatus"));
+
+ pushTasksColumns.add(
+ new ActionColumn<AbstractTaskTO, String>(new StringResourceModel("actions", this, null, "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public ActionLinksPanel getActions(final String componentId, final IModel<AbstractTaskTO> model) {
+
+ final PushTaskTO taskTO = (PushTaskTO) model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, pageRef);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+
+ window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new PushTaskModalPage(window, taskTO, pageRef);
+ }
+ });
+
+ window.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, TASKS);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ restClient.startExecution(taskTO.getKey(), false);
+ getSession().info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+
+ target.add(container);
+ ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
+ }
+ }, ActionLink.ActionType.EXECUTE, TASKS);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ restClient.startExecution(taskTO.getKey(), true);
+ getSession().info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+
+ target.add(container);
+ ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
+ }
+ }, ActionLink.ActionType.DRYRUN, TASKS);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ restClient.delete(taskTO.getKey(), SyncTaskTO.class);
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scce) {
+ error(scce.getMessage());
+ }
+ target.add(container);
+ ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
+ }
+ }, ActionLink.ActionType.DELETE, TASKS);
+
+ return panel;
+ }
+
+ @Override
+ public Component getHeader(final String componentId) {
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), pageRef);
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ if (target != null) {
+ target.add(table);
+ }
+ }
+ }, ActionLink.ActionType.RELOAD, TASKS, "list");
+
+ return panel;
+ }
+ });
+
+ return pushTasksColumns;
+
+ }
+}
[02/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage_it.properties
new file mode 100644
index 0000000..a7b33b8
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage_it.properties
@@ -0,0 +1,60 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+resource=Dettagli Risorsa
+umapping=Mapping utenti
+connectorProperties=Propriet\u00e0\u00a0 Connettore
+security=Sicurezza
+required_alert=Tutti i campi sono richiesti
+connector=Connettore
+existing_resources=Risorse esistenti
+action=Azione
+edit_attribute=Modifica risorsa
+title=Risorsa
+extAttrNames=Attributi esterni
+intMappingTypes=Tipo mapping interno
+entity=Entità
+groupSchema=Schema Gruppo
+accountId=AccountId
+mandatoryCondition=Obbligatorio
+password=Password
+purpose=Scopo
+mappingUserSchema=Mapping User Schema
+mappingGroupSchema=Mapping Group Schema
+delete=Rimuovi
+intAttrNames=Attributi interni
+enforceMandatoryCondition=Abilita mandatory condition
+fieldName=Nome campo
+
+accountIdValidation=Deve essere definito esattamente un AccountId
+propagationMode=Modalit\u00e0 di propagazione
+accountLink=Account link
+enable=Abilita
+
+createTraceLevel=Livello di tracciamento delle creazioni
+updateTraceLevel=Livello di tracciamento degli aggiornamenti
+deleteTraceLevel=Livello di tracciamento delle cancellazioni
+syncTraceLevel=Livello di tracciamento delle sincronizzazioni
+propagationPriority=Priorit\u00e0 in propagazione
+propagationPrimary=Primaria in propagazione
+
+success_connection=Connessione avvenuta con successo
+error_connection=Connessione non riuscita
+check=Verifica connessione
+actionsClasses=Classi azioni
+gmapping=Mapping gruppi
+new=Nuova
+randomPwdIfNotProvided=Genera password casuali se mancanti
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage_pt_BR.properties
new file mode 100644
index 0000000..be08c73
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage_pt_BR.properties
@@ -0,0 +1,60 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+resource=Detalhes de Recursos
+umapping=Mapeamento de usu\u00e1rios
+connectorProperties=Propriedades de Conectores
+security=Seguran\u00e7a
+required_alert=Todos os campos deste formul\u00e1rio s\u00e3o obrigat\u00f3rios
+connector=Conector
+existing_resources=Recursos Existentes
+action=A\u00e7\u00e3o
+edit_attribute=Alterar Recurso
+title=Recurso
+extAttrNames=Atributos Externos
+intMappingTypes=Tipos internos de mapeamentos
+entity=Entidade
+groupSchema=Esquema de Grupo
+accountId=Identificador da Conta
+mandatoryCondition=Obrigat\u00f3rio
+password=Senha
+purpose=Prop\u00f3sito
+mappingUserSchema=Esquema de mapeamento de usu\u00e1rio
+mappingGroupSchema=Esquema de mapeamento de grupo
+delete=Excluir
+intAttrNames=Atributos internos
+enforceMandatoryCondition=Aplicar condi\u00e7\u00e3o obrigat\u00f3ria
+fieldName=Nome do Campo
+
+accountIdValidation=Precisa ser exatamente um Identificador de Conta
+propagationMode=Modo de propaga\u00e7\u00e3o
+accountLink=Link de Conta
+enable=Habilitado
+
+createTraceLevel=Criar n\u00edvel de trace
+updateTraceLevel=Atualizar n\u00edvel de trace
+deleteTraceLevel=Excluir n\u00edvel de trace
+syncTraceLevel=N\u00edvel de trace de sincroniza\u00e7\u00e3o
+propagationPriority=Prioridade de propaga\u00e7\u00e3o
+propagationPrimary=Propaga\u00e7\u00e3o prim\u00e1ria
+
+success_connection=Conex\u00e3o com sucesso
+error_connection=Conex\u00e3o sem sucesso
+check=Verificar a conex\u00e3o
+actionsClasses=Classes de a\u00e7\u00f5es
+gmapping=Mapeamento de grupos
+new=Novo
+randomPwdIfNotProvided=Gerar senhas aleat\u00f3rias quando n\u00e3o houver
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Resources.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Resources.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Resources.html
new file mode 100644
index 0000000..6486a0e
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Resources.html
@@ -0,0 +1,99 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:head>
+ <style type="text/css">
+ .true {
+ background-image: url(../../img/ok.png);
+ background-position: center center;
+ background-repeat: no-repeat;
+ height: 18px;
+ width: 65px;
+ }
+ .false {
+ width: 65px;
+ }
+ .narrowcolumn {
+ width: 120px;
+ }
+ </style>
+ </wicket:head>
+ <wicket:extend>
+
+ <div id="tabs">
+ <ul>
+ <li class="tabs-selected">
+ <a href="#tabs-1"><span><wicket:message key="tab1"/></span></a>
+ </li>
+ <li><a href="#tabs-2"><span><wicket:message key="tab2"/></span></a></li>
+ </ul>
+ <div id="tabs-1">
+ <div id="users-contain" class="ui-widget" style="width:inherit">
+ <span wicket:id="resourceContainer">
+ <span wicket:id="resourceDatatable">[resources]</span>
+ </span>
+
+ <span style="float:right">
+ <form wicket:id="resourcePaginatorForm" style="display:inline">
+ <label><wicket:message key="displayRows"/></label>
+ <select class="text ui-widget-content ui-corner-all" wicket:id="rowsChooser"/>
+ </form>
+ </span>
+ </div>
+
+ <div wicket:id="statusModal">[Show modal window for provisioning status]</div>
+ <div wicket:id="createResourceWin">[Show modal window for creating resource]</div>
+ <div wicket:id="editResourceWin">[Show modal window for editing resource]</div>
+
+ <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="createResourceLink">
+ <wicket:message key="create-resource"/>
+ </a>
+ </div>
+ <div id="tabs-2">
+ <div id="users-contain" class="ui-widget" style="width:inherit">
+ <span wicket:id="connectorContainer">
+ <span wicket:id="connectorDatatable">[connectors]</span>
+ </span>
+
+ <span style="float:right">
+ <form wicket:id="connectorPaginatorForm" style="display:inline">
+ <label><wicket:message key="displayRows"/></label>
+ <select class="text ui-widget-content ui-corner-all" wicket:id="rowsChooser"/>
+ </form>
+ </span>
+ </div>
+
+ <div wicket:id="createConnectorWin">[Show modal window for creating connector]</div>
+ <div wicket:id="editConnectorWin">[Show modal window for editing connector]</div>
+
+ <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="createConnectorLink">
+ <wicket:message key="create-connector"/>
+ </a>
+ </div>
+
+ <div>
+ <a href="#" style="position: absolute; top: 4px; right:20px;" wicket:id="reloadLink">
+ <img src="img/reload_30.png" width="25" height="25"
+ alt="Reload connectors" title="title" wicket:message="title:reloadConnectors"/>
+ </a>
+ </div>
+ </div>
+
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Resources.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Resources.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Resources.properties
new file mode 100644
index 0000000..fb6b8a1
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Resources.properties
@@ -0,0 +1,34 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tab1=Resources
+edit=Edit
+delete=Delete
+create-resource=Create
+propagationPriority=Propagation priority
+propagationPrimary=Propagation primary
+
+tab2=Connectors
+displayName=Display name
+version=Version
+bundleName=Bundle name
+edit=Edit
+delete=Delete
+create-connector=Create
+delete_error=Operation forbidden:the connector you're trying to delete is connected to a Resource
+connector=Connector
+reloadConnectors=Reload connectors
+confirmReloadConnectors=This request is potentially dangerous for running operations, continue?
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Resources_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Resources_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Resources_it.properties
new file mode 100644
index 0000000..80a5185
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Resources_it.properties
@@ -0,0 +1,34 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tab1=Risorse
+edit=Modifica
+delete=Rimuovi
+create-resource=Crea
+propagationPriority=Priorit\u00e0 in propagazione
+propagationPrimary=Primaria in propagazione
+
+tab2=Connettori
+create-connector=Crea
+version=Versione
+bundleName=Bundle name
+edit=Modifica
+delete=Elimina
+delete_error=Operazione vietata: il connettore che si desidera rimuovere \u00e8 correlato ad una risorsa
+displayName=Nome visualizzato
+connector=Connettore
+reloadConnectors=Ricarica connettori
+confirmReloadConnectors=Questa richiesta \u00e8 potenzialmente dannosa per le operazioni in corso, proseguire?
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Resources_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Resources_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Resources_pt_BR.properties
new file mode 100644
index 0000000..a631352
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Resources_pt_BR.properties
@@ -0,0 +1,32 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tab1=Recursos
+edit=Alterar
+delete=Excluir
+create-resource=Criar
+propagationPriority=Prioridade de propaga\u00e7\u00e3o
+propagationPrimary=Propaga\u00e7\u00e3o prim\u00e1ria
+
+tab2=Conectores
+displayName=Mostar
+version=Vers\u00e3o
+bundleName=Nome do Pacote
+create-connector=Criar
+delete_error=Opera\u00e7\u00e3o n\u00e3o permitida\: o conector que voc\u00ea est\u00e1 tentando excluir est\u00e1 conectado a um recurso
+connector=Conector
+reloadConnectors=Carregar Conector
+confirmReloadConnectors=Esta requis\u00e7\u00e3o \u00e9 potencialmente perigosa para opera\u00e7\u00f5es em execu\u00e7\u00e3o, prosseguir?
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage.html
new file mode 100644
index 0000000..647a311
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage.html
@@ -0,0 +1,226 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:head>
+ <style>
+ div#propagation {
+ font-size: 8px;
+ height: auto;
+ margin-top: 3px;
+ text-align: left;
+ }
+
+ div#status {
+ float: left;
+ height: 25px;
+ margin-top: 3px;
+ text-align: center;
+ width: 8%;
+ }
+
+ div.assignment {
+ border: 1px solid #DDDDDD;
+ display: inline-table;
+ margin-bottom: 20px;
+ width: 100%;
+ }
+
+ div.assignments {
+ color: #555555;
+ display: inline-table;
+ margin-top: 20px;
+ width: 100%;
+ }
+
+ div.header {
+ display: inline-table;
+ margin: 5px;
+ width: 98%;
+ }
+
+ div.profile div#row{
+ display: inline-table;
+ width:100%;
+ vertical-align: middle;
+ }
+
+ div.profile {
+ background-color: #EEEEEE;
+ color: #555555;
+ display: inline-table;
+ margin: 0px 5px 5px 5px;
+ width: 98%;
+ }
+
+ div#name {
+ border-bottom: 1px solid #DDDDDD;
+ display: table-cell;
+ height: 15px;
+ width: 220px;
+ padding: 0px 5px 0px 5px;
+ vertical-align: middle;
+ }
+
+ div#value {
+ border-bottom: 1px solid #DDDDDD;
+ border-left: 1px solid #DDDDDD;
+ display: table-cell;
+ height: 15px;
+ width: 38%;
+ padding: 0px 5px 0px 5px;
+ overflow: hidden;
+ vertical-align: middle;
+ }
+
+ div#resource {
+ display: table-cell;
+ width: 220px;
+ height: 30px;
+ padding: 10px 0px 5px 0px;
+ }
+
+ div#resource img{
+ width: 12px;
+ height: 12px;
+ position: relative;
+ left: 3px;
+ top: 1px;
+ opacity: 1;
+ }
+
+ div#attrhead {
+ display: table-cell;
+ border-left: 1px solid #DDDDDD;
+ width: 38%;
+ height: 30px;
+ padding: 3px 0px 5px 0px;
+ text-align: center;
+ vertical-align: middle;
+ font-size: 11px;
+ }
+ </style>
+ </wicket:head>
+ <wicket:extend>
+
+ <wicket:fragment wicket:id="propagationResultFrag">
+ <p class="ui-widget ui-corner-all ui-widget-header">
+ <wicket:message key="operationResult"/> <span wicket:id="info"/>
+ </p>
+
+ <div class="assignments">
+ <div wicket:id="resources" class="assignment">
+
+ <span wicket:id="attrhead">[Attributes head]</span>
+
+ <div class="profile">
+ <span wicket:id="attrs">
+ <div id="row">
+ <div id="name">
+ <span wicket:id="attrName">[Attribute name]</span>
+ </div>
+ <div id="value">
+ <span wicket:id="beforeValue">[Before value]</span>
+ </div>
+ <div id="value">
+ <span wicket:id="afterValue">[After value]</span>
+ </div>
+ </div>
+ </span>
+ </div>
+ </div>
+ </div>
+ </wicket:fragment>
+
+ <wicket:fragment wicket:id="userSelfResultFrag">
+ <p><wicket:message key="selfResult"/></p>
+ </wicket:fragment>
+
+ <wicket:fragment wicket:id="remoteStatusFrag">
+ <img wicket:id="status"/>
+ </wicket:fragment>
+
+ <wicket:fragment wicket:id="attrValueFrag">
+ <span wicket:id="value">[After value]</span>
+ </wicket:fragment>
+
+ <wicket:fragment wicket:id="attrHeadFrag">
+ <div class="header alt">
+ <div id="resource">
+ <div>
+ <span wicket:id="resource">[resource name]</span>
+ <a wicket:id="showFailureWindow" href="#">
+ <img wicket:id="icon"/>
+ </a>
+
+ <div id="propagation">
+ <wicket:message key="propresult">[propagation result message]</wicket:message>
+
+ <span wicket:id="propagation">[propagation result]</span>
+ </div>
+
+ <div wicket:id="failureWindow"></div>
+
+ </div>
+ </div>
+
+ <div id="attrhead">
+ <wicket:message key="before">[before]</wicket:message>
+ </div>
+
+ <div id="attrhead">
+ <wicket:message key="after">[after]</wicket:message>
+ </div>
+ </div>
+ </wicket:fragment>
+
+ <wicket:fragment wicket:id="emptyAttrHeadFrag">
+ <div class="header alt">
+ <div id="resource">
+ <div>
+ <span wicket:id="resource">[resource name]</span>
+ <a wicket:id="showFailureWindow" href="#">
+ <img wicket:id="icon"/>
+ </a>
+
+ <div id="propagation">
+ <wicket:message key="propresult">[propagation result message]</wicket:message>
+
+ <span wicket:id="propagation">[propagation result]</span>
+ <div wicket:id="failureWindow"></div>
+
+ </div>
+
+ </div>
+ </div>
+ </div>
+ </wicket:fragment>
+
+ <wicket:fragment wicket:id="emptyFrag">
+ </wicket:fragment>
+
+ <div wicket:id="container" id="users-contain" class="ui-widget" style="margin:30px; width:inherit">
+
+ <span wicket:id="resultFrag"/>
+
+ <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="close">
+ <wicket:message key="close"/>
+ </a>
+ </div>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage.properties
new file mode 100644
index 0000000..3ee25f8
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage.properties
@@ -0,0 +1,26 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+operationResult=Operation result for
+close=Close
+selfResult=Your request has been registered: depending on configuration, approval might be required.
+__NAME__=Account Link
+__UID__=Account Id
+__PASSWORD__=Password
+__ENABLE__=Enabled
+propresult=Propagation:
+before=Before propagation
+after=After propagation
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage_it.properties
new file mode 100644
index 0000000..92ee70e
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage_it.properties
@@ -0,0 +1,26 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+operationResult=Risultato dell'operazione per
+close=Chiudi
+selfResult=La sua richiesta \u00e8 stata presa in carico: se la configurazione lo prevede, sar\u00e0 necessaria l'approvazione.
+__NAME__=Account Link
+__UID__=Account Id
+__PASSWORD__=Password
+__ENABLE__=Abilitato
+propresult=Propagazione:
+before=Prima della propagazione
+after=Dopo la propagazione
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage_pt_BR.properties
new file mode 100644
index 0000000..319d1c9
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage_pt_BR.properties
@@ -0,0 +1,26 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+operationResult=Resultado de opera\u00E7\u00E3o para\:
+close=Fechar
+selfResult=Sua requis\u00E7\u00E3o foi registrada e ser\u00E1 encaminhada ao administrador respons\u00E1vel. Obrigado
+__NAME__=Link de conta
+__UID__=Identificador de Conta
+__PASSWORD__=Senha
+__ENABLE__=Habilitado
+propresult=Propaga\u00E7\u00E3o
+before=Antes da Propaga\u00E7\u00E3o
+after=Depois da Propaga\u00E7\u00E3o
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage.html
new file mode 100644
index 0000000..a237c27
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage.html
@@ -0,0 +1,49 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:head>
+ <link rel="stylesheet" type="text/css" href="webjars/codemirror/${codemirror.version}/lib/codemirror.css"/>
+
+ <script type="text/javascript" src="webjars/codemirror/${codemirror.version}/lib/codemirror.js"></script>
+ <script type="text/javascript" src="webjars/codemirror/${codemirror.version}/mode/xml/xml.js"></script>
+ <script type="text/javascript">
+ function updateTextArea(editor) {
+ document.getElementById("routeDefForm").elements["routeContent"].value = editor.getValue();
+ }
+ </script>
+ </wicket:head>
+ <wicket:extend>
+ <form wicket:id="routeDefForm" id="routeDefForm">
+ <textarea wicket:id="routeContent" id="routeContent" name="routeContent" style="width: 100%; height: 350px;">
+ </textarea>
+ <div style="margin: 10px;">
+ <input type="submit"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="apply"
+ onclick=""/>
+ </div>
+ </form>
+ <script>
+ window.onload = function(){
+ var editor = CodeMirror.fromTextArea(document.getElementById("routeContent"),{lineNumbers: true});
+ editor.on("change", updateTextArea);
+ }
+ </script>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage.properties
new file mode 100644
index 0000000..8ac2655
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage.properties
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Edit route
+id=id
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage_it.properties
new file mode 100644
index 0000000..44663f7
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage_it.properties
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Modifica le rotte
+id=id
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage_pt_BR.properties
new file mode 100644
index 0000000..a6395a0
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage_pt_BR.properties
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Editar rotas
+id=id
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage.html
new file mode 100644
index 0000000..2d25618
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage.html
@@ -0,0 +1,136 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <div style="margin: 5px;">
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+ <form wicket:id="form">
+ <div id="tabs">
+ <ul>
+ <li class="tabs-selected"><a href="#profile"><span><wicket:message key="profile"/></span></a></li>
+ <li><a href="#crontab"><span><wicket:message key="crontab"/></span></a></li>
+ <li><a href="#executions"><span><wicket:message key="executions"/></span></a></li>
+ </ul>
+ <div id="profile">
+ <div id="users-contain" class="ui-widget">
+ <span wicket:id="profile">
+ <div id="formtable">
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <span wicket:id="idLabel">[Id]</span>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="key">[key]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="name"><wicket:message key="name"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="name">[name]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="description"><wicket:message key="description"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="description">[description]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="jobClassName"><wicket:message key="class"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="jobClassName">[jobClassName]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="lastExec"><wicket:message key="lastExec"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="lastExec">[lastExec]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="nextExec"><wicket:message key="nextExec"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="nextExec">[nextExec]</span>
+ </div>
+ </div>
+ </div>
+
+ <script type="text/javascript">
+ $(function () {
+ $('#formtable div.tablerow:even').addClass("alt");
+ });
+ </script>
+ </span>
+ </div>
+ </div>
+ <div id="crontab">
+ <span wicket:id="crontab">
+ <div id="formtable">
+ <div class="tablerow alt">
+ <label for="cron"><wicket:message key="cron"/></label>
+ </div>
+ <div class="tablerow">
+ <input type="text" id="seconds" class="text ui-widget-content ui-corner-all" wicket:id="seconds" style="width: 50px;float: left" />
+ <input type="text" id="minutes" class="text ui-widget-content ui-corner-all" wicket:id="minutes" style="width: 50px;float: left" />
+ <input type="text" id="hours" class="text ui-widget-content ui-corner-all" wicket:id="hours" style="width: 50px;float: left" />
+ <input type="text" id="daysOfMonth" class="text ui-widget-content ui-corner-all" wicket:id="daysOfMonth" style="width: 50px;float: left" />
+ <input type="text" id="months" class="text ui-widget-content ui-corner-all" wicket:id="months" style="width: 50px;float: left" />
+ <input type="text" id="daysOfWeek" class="text ui-widget-content ui-corner-all" wicket:id="daysOfWeek" style="width: 50px" />
+ </div>
+ <div class="tablerow alt">
+ <label for="cronExpression"><wicket:message key="templates"/></label>
+ </div>
+ <div class="tablerow">
+ <select class="text ui-widget-content ui-corner-all" wicket:id="cronTemplateChooser" style="width: 250px"/>
+ </div>
+ </div>
+ </span>
+ </div>
+ <div id="executions" class="ui-widget">
+ <span wicket:id="executionContainer" id="executionContainer">
+ <table class="ui-widget ui-widget-content"
+ wicket:id="executionsTable" style="width: 100%"/>
+ </span>
+ </div>
+ </div>
+ <div style="margin: 20px 10px 0">
+ <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="apply"/>
+ <input type="button" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="cancel"/>
+ </div>
+ </form>
+ </div>
+ <div wicket:id="taskExecMessageWin"/>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage.properties
new file mode 100644
index 0000000..3e0f41c
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage.properties
@@ -0,0 +1,36 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Profile
+crontab=Schedule
+executions=Executions
+title=Task
+class=Class
+name=Name
+description=Description
+lastExec=Last Execution
+nextExec=Next Execution
+cron=Schedule (seconds, minutes, hours, days of month, months, days of week)
+templates=Remove task from scheduler / Use a template to schedule
+apply=Save
+startDate=Start date
+endDate=End date
+status=Status
+message=Message
+taskExecutions=Task executions
+delete=Delete
+showMessage=Show
+chooseForTemplate=Use A Template
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage_it.properties
new file mode 100644
index 0000000..fefc847
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage_it.properties
@@ -0,0 +1,36 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Profilo
+crontab=Schedule
+executions=Esecuzioni
+title=Task
+class=Classe
+name=Nome
+description=Descrizione
+lastExec=Ultima Esecuzione
+nextExec=Prossima Esecuzione
+cron=Schedule (secondi, minuti, ore, giorni del mese, mesi, giorni della settimana)
+templates=Rimuovi task dallo scheduler / Utilizza un template per schedulare
+apply=Salva
+startDate=Data di avvio
+endDate=Data di conclusione
+status=Stato
+message=Messaggio
+taskExecutions=Esecuzione del task
+delete=Rimozione
+showMessage=Mostra
+chooseForTemplate=Usa Un Template
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage_pt_BR.properties
new file mode 100644
index 0000000..36738b8
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage_pt_BR.properties
@@ -0,0 +1,36 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Perfil
+crontab=Agenda
+executions=Execu\u00E7\u00F5es
+title=Tarefa
+class=Classe
+name=Nome
+description=Descri\u00E7\u00E3o
+lastExec=\u00DAltima execu\u00E7\u00E3o
+nextExec=Pr\u00F3xima Execu\u00E7\u00E3o
+cron=Agendar (segundos, minutos, horas, dias do m\u00EAs, meses, dias da semana)
+templates=Remover tarefa do agendamento / Usar template para agendar
+apply=Salvar
+startDate=Data de In\u00EDcio
+endDate=Data de Conclus\u00E3o
+status=Estatus
+message=Mensagem
+taskExecutions=Execu\u00E7\u00E3o de Tarefas
+delete=Excluir
+showMessage=Mostrar
+chooseForTemplate=Usar um template
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema$SchemaTypePanel.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema$SchemaTypePanel.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema$SchemaTypePanel.html
new file mode 100644
index 0000000..acc761e
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema$SchemaTypePanel.html
@@ -0,0 +1,41 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:panel>
+ <div wicket:id="schemaWrapContainer" id="users-contain" class="ui-widget">
+ <span wicket:id="schemaContainer">
+ <table class="ui-widget ui-widget-content table-hover" wicket:id="datatable"/>
+ </span>
+
+ <span style="float:right">
+ <form wicket:id="paginatorForm" style="display:inline">
+ <label><wicket:message key="displayRows"/></label>
+ <select class="text ui-widget-content ui-corner-all" wicket:id="rowsChooser"/>
+ </form>
+ </span>
+ </div>
+
+ <div wicket:id="editSchemaWin">[Show modal window for editing schema]</div>
+
+ <a wicket:id="createSchemaLink"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only">
+ <wicket:message key="create"/>
+ </a>
+ </wicket:panel>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema.html
new file mode 100644
index 0000000..af0b83f
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema.html
@@ -0,0 +1,59 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:head>
+ <style type="text/css">
+ .true {
+ background-image: url(../../img/ok.png);
+ background-position: center center;
+ background-repeat: no-repeat;
+ height: 18px;
+ width: 65px;
+ }
+ .false {
+ width: 65px;
+ }
+ </style>
+ </wicket:head>
+ <wicket:extend>
+
+ <div id="tabs">
+ <ul>
+ <li class="tabs-selected"><a href="#cschema"><wicket:message key="configuration"/></a></li>
+ <li><a href="#uschema"><wicket:message key="user"/></a></li>
+ <li><a href="#mschema"><wicket:message key="membership"/></a></li>
+ <li><a href="#gschema"><wicket:message key="group"/></a></li>
+ </ul>
+
+ <div id="cschema">
+ <div wicket:id="configurationTabs"/>
+ </div>
+ <div id="uschema">
+ <div wicket:id="userTabs"/>
+ </div>
+ <div id="mschema">
+ <div wicket:id="membershipTabs"/>
+ </div>
+ <div id="gschema">
+ <div wicket:id="groupTabs"/>
+ </div>
+ </div>
+
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema.properties
new file mode 100644
index 0000000..920d29c
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema.properties
@@ -0,0 +1,35 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+user=User
+group=Group
+membership=Membership
+required_alert=All fields are required
+mandatory=Mandatory
+multivalue=Multivalue
+type=Type
+validatorClass=Validator class
+conversionPattern=Conversion pattern
+edit=Edit
+delete=Delete
+attributes=Attributes
+expression=Expression
+plain=Plain
+derived=Derived
+virtual=Virtual
+mandatoryCondition=Mandatory
+uniqueConstraint=Unique
+readonly=Read-only
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema_it.properties
new file mode 100644
index 0000000..186b540
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema_it.properties
@@ -0,0 +1,35 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+user=Utente
+group=Gruppo
+membership=Membership
+required_alert=Tutti i campi sono richiesti.
+mandatory=Obbligatorio
+multivalue=Multivalore
+type=Tipo
+validatorClass=Validator class
+conversionPattern=Pattern di conversione
+edit=Modifica
+delete=Rimuovi
+attributes=Attributi
+expression=Expression
+plain=Normali
+derived=Derivati
+virtual=Virtuali
+mandatoryCondition=Obbligatorio
+uniqueConstraint=Univoco
+readonly=Sola lettura
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema_pt_BR.properties
new file mode 100644
index 0000000..8c41db6
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Schema_pt_BR.properties
@@ -0,0 +1,35 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+user=Usu\u00e1rio
+group=Grupo
+membership=Membro
+required_alert=Todos os campos s\u00e3o requeridos
+mandatory=Obrigat\u00f3rio
+multivalue=Multivalorado
+type=Tipo
+validatorClass=classe de Valida\u00e7\u00e3o
+conversionPattern=Padr\u00e3o de Convers\u00e3o
+edit=Editar
+delete=Remover
+attributes=Atributos
+expression=Express\u00e3o
+plain=Normal
+derived=Derivado
+virtual=Virtual
+mandatoryCondition=Mandat\u00f3rio
+uniqueConstraint=\u00danico
+readonly=Apenas leitura
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.html
new file mode 100644
index 0000000..fe4fad4
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.html
@@ -0,0 +1,46 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <div>
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+ <form wicket:id="form">
+ <div id="formtable">
+ <div class="tablerow alt">
+ <div class="tablecolumn_label medium_fixedsize">
+ <label for="content"><wicket:message key="content"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="content">[content]</span>
+ </div>
+ </div>
+ </div>
+
+ <div style="margin: 20px 10px 0">
+ <input type="submit"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="apply"/>
+ <input type="button"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="cancel"/>
+ </div>
+ </form>
+ </div>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.properties
new file mode 100644
index 0000000..3f7ab40
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.properties
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Security question
+content=Text
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage_it.properties
new file mode 100644
index 0000000..6324e64
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage_it.properties
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Domanda di sicurezza
+content=Testo
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage_pt_BR.properties
new file mode 100644
index 0000000..511b4ad
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage_pt_BR.properties
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Pergunta de seguran\u00e7a
+content=Texto
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage.html
new file mode 100644
index 0000000..fc9b0a5
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage.html
@@ -0,0 +1,205 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <div style="margin: 5px;">
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+
+ <form wicket:id="form">
+
+ <div id="tabs">
+ <ul>
+ <li class="tabs-selected"><a href="#profile"><span><wicket:message key="profile"/></span></a></li>
+ <li><a href="#crontab"><span><wicket:message key="crontab"/></span></a></li>
+ <li><a href="#executions"><span><wicket:message key="executions"/></span></a></li>
+ </ul>
+ <div id="profile">
+ <div class="ui-widget">
+ <span wicket:id="profile">
+ <div id="formtable">
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <span wicket:id="idLabel">[Id]</span>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="key">[key]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="name"><wicket:message key="name"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="name">[name]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="description"><wicket:message key="description"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="description">[description]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="resource"><wicket:message key="resourceName"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="resource">[resource]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="lastExec"><wicket:message key="lastExec"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="lastExec">[lastExec]</span>
+ </div>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="nextExec"><wicket:message key="nextExec"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="nextExec">[nextExec]</span>
+ </div>
+ </div>
+
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="actionsClassNames"><wicket:message key="actionsClasses"/></label>
+ </div>
+ <span wicket:id="syncActionsClassNames">
+ <span wicket:id="actionsClasses">
+ <select class="text ui-widget-content ui-corner-all" wicket:id="actionsClass"/>
+ <a wicket:id="drop"><img src="img/minus-icon.png" alt="remove icon" class="drop_button"/></a>
+ <a wicket:id="add"><img src="img/plus-icon.png" alt="add icon" class="add_button"/></a>
+ <br/>
+ </span>
+ <a wicket:id="first"><img src="img/plus-icon.png" alt="add icon" class="add_button"/></a>
+ </span>
+ </div>
+
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="performCreate"><wicket:message key="creates"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="performCreate">[performCreate]</span>
+ </div>
+ </div>
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="performUpdate"><wicket:message key="updates"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="performUpdate">[performUpdate]</span>
+ </div>
+ </div>
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="performDelete"><wicket:message key="deletes"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="performDelete">[performDelete]</span>
+ </div>
+ </div>
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="syncStatus"><wicket:message key="syncStatus"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="syncStatus">[syncStatus]</span>
+ </div>
+ </div>
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="fullReconciliation"><wicket:message key="fullReconciliation"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="fullReconciliation">[fullReconciliation]</span>
+ </div>
+ </div>
+ <div class="tablerow alt">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="matchingRule"><wicket:message key="matchingRule"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="matchingRule">[matchingRule]</span>
+ </div>
+ </div>
+ <div class="tablerow">
+ <div class="tablecolumn_label short_dynamicsize">
+ <label for="unmatchingRule"><wicket:message key="unmatchingRule"/></label>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="unmatchingRule">[unmatchingRule]</span>
+ </div>
+ </div>
+ <wicket:child/>
+ </div>
+ </span>
+ </div>
+ </div>
+ <div id="crontab">
+ <span wicket:id="crontab">
+ <div id="formtable">
+ <div class="tablerow alt">
+ <label for="cron"><wicket:message key="cron"/></label>
+ </div>
+ <div class="tablerow">
+ <input type="text" id="seconds" class="text ui-widget-content ui-corner-all" wicket:id="seconds" style="width: 50px;float: left" />
+ <input type="text" id="minutes" class="text ui-widget-content ui-corner-all" wicket:id="minutes" style="width: 50px;float: left" />
+ <input type="text" id="hours" class="text ui-widget-content ui-corner-all" wicket:id="hours" style="width: 50px;float: left" />
+ <input type="text" id="daysOfMonth" class="text ui-widget-content ui-corner-all" wicket:id="daysOfMonth" style="width: 50px;float: left" />
+ <input type="text" id="months" class="text ui-widget-content ui-corner-all" wicket:id="months" style="width: 50px;float: left" />
+ <input type="text" id="daysOfWeek" class="text ui-widget-content ui-corner-all" wicket:id="daysOfWeek" style="width: 50px" />
+ </div>
+ <div class="tablerow alt">
+ <label for="cronExpression"><wicket:message key="templates"/></label>
+ </div>
+ <div class="tablerow">
+ <select class="text ui-widget-content ui-corner-all" wicket:id="cronTemplateChooser" style="width: 250px"/>
+ </div>
+ </div>
+ </span>
+ </div>
+ <div id="executions" class="ui-widget">
+ <span wicket:id="executionContainer" id="executionContainer">
+ <table class="ui-widget ui-widget-content"
+ wicket:id="executionsTable" style="width: 100%"/>
+ </span>
+ </div>
+ </div>
+ <div style="margin: 20px 10px 0">
+ <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="apply"/>
+ <input type="button" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="cancel"/>
+ </div>
+ </form>
+ </div>
+ <div wicket:id="taskExecMessageWin"/>
+ </wicket:extend>
+</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage.properties
new file mode 100644
index 0000000..4fa0321
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage.properties
@@ -0,0 +1,43 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Profile
+crontab=Schedule
+executions=Executions
+title=Task
+resourceName=Resource Name
+name=Name
+description=Description
+lastExec=Last Execution
+nextExec=Next Execution
+cron=Schedule (seconds, minutes, hours, days of month, months, days of week)
+templates=Remove task from scheduler / Use a template to schedule
+apply=Save
+startDate=Start date
+endDate=End date
+status=Status
+message=Message
+delete=Delete
+showMessage=Show
+chooseForTemplate=Use A Template
+creates=Allow create operations
+deletes=Allow delete operations
+updates=Allow update operations
+syncStatus=Allow status synchronization
+fullReconciliation=Full reconciliation
+actionsClasses=Actions classes
+matchingRule=Matching Rule
+unmatchingRule=Unmatching Rule
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage_it.properties
new file mode 100644
index 0000000..0ec6d67
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage_it.properties
@@ -0,0 +1,44 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Profilo
+crontab=Schedule
+executions=Esecuzioni
+title=Task
+resourceName=Nome Risorsa
+name=Nome
+description=Descrizione
+lastExec=Ultima Esecuzione
+nextExec=Prossima Esecuzione
+cron=Schedule (secondi, minuti, ore, giorni del mese, mesi, giorni della settimana)
+templates=Rimuovi task dallo scheduler / Utilizza un template per schedulare
+apply=Salva
+startDate=Data di avvio
+endDate=Data di conclusione
+status=Stato
+message=Messaggio
+delete=Rimozione
+showMessage=Mostra
+chooseForTemplate=Usa Un Template
+creates=Consenti operazioni di creazione
+deletes=Consenti operazioni di rimozione
+updates=Consenti operazioni di modifica
+syncStatus=Consenti sincronizzazione di stato
+fullReconciliation=Riconciliazione totale
+actionsClasses=Classi azioni
+syncStatus=Sincronizza stato utente
+matchingRule=Regola di corrispondenza
+unmatchingRule=Regola di non corrispondenza
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage_pt_BR.properties
new file mode 100644
index 0000000..b790e58
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/SyncTaskModalPage_pt_BR.properties
@@ -0,0 +1,43 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+profile=Perfil
+crontab=Agenda
+executions=Execu\u00e7\u00f5es
+title=Tarefas
+resourceName=Nome de Recursos
+name=Nome
+description=Descri\u00e7\u00e3o
+lastExec=\u00daltima Execu\u00e7\u00e3o
+nextExec=Pr\u00f3xima Execu\u00e7\u00e3o
+cron=Agenda (segundos, minutos, horas, dias do m\u00eas, meses, dias da semana)
+templates=Remover tarefa agendada / usar template para agendar
+apply=Salvar
+startDate=Data de In\u00edcio
+endDate=Data Final
+status=Estatus
+message=Mensagem
+delete=Excluir
+showMessage=Mostrar
+chooseForTemplate=Usar um template
+creates=Permitir opera\u00e7\u00f5es de cria\u00e7\u00e3o
+deletes=Permitir opera\u00e7\u00f5es de remo\u00e7\u00e3o
+updates=Permitir a edi\u00e7\u00e3o
+syncStatus=Permitir a sincroniza\u00e7\u00e3o de status
+fullReconciliation=Reconcilia\u00e7\u00e3o completa
+actionsClasses=Classes de a\u00e7\u00f5es
+matchingRule=Regra de correspond\u00eancia
+unmatchingRule=Regra de non correspond\u00eancia
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Tasks.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Tasks.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Tasks.html
new file mode 100644
index 0000000..7df418a
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Tasks.html
@@ -0,0 +1,46 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<wicket:extend>
+
+ <div id="tabs">
+ <ul>
+ <li class="tabs-selected"><a href="#tabs-1"><span><wicket:message key="tab1"/></span></a></li>
+ <li><a href="#tabs-2"><span><wicket:message key="tab2"/></span></a></li>
+ <li><a href="#tabs-3"><span><wicket:message key="tab3"/></span></a></li>
+ <li><a href="#tabs-4"><span><wicket:message key="tab4"/></span></a></li>
+ <li><a href="#tabs-5"><span><wicket:message key="tab5"/></span></a></li>
+ </ul>
+ <div id="tabs-1">
+ <span wicket:id="propagation">[propagation tasks]</span>
+ </div>
+ <div id="tabs-2">
+ <span wicket:id="notification">[notification tasks]</span>
+ </div>
+ <div id="tabs-3">
+ <span wicket:id="sched">[scheduled tasks]</span>
+ </div>
+ <div id="tabs-4">
+ <span wicket:id="sync">[synchronization tasks]</span>
+ </div>
+ <div id="tabs-5">
+ <span wicket:id="push">[push tasks]</span>
+ </div>
+ </div>
+
+</wicket:extend>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Tasks.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Tasks.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Tasks.properties
new file mode 100644
index 0000000..6dcc9f7
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/Tasks.properties
@@ -0,0 +1,21 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+tab1=Propagation Tasks
+tab2=Notification tasks
+tab3=Scheduled Tasks
+tab4=Synchronization Tasks
+tab5=Push Tasks
\ No newline at end of file
[16/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractSearchResultPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractSearchResultPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractSearchResultPanel.java
new file mode 100644
index 0000000..6139ee4
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractSearchResultPanel.java
@@ -0,0 +1,353 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.Collection;
+import java.util.List;
+import org.apache.syncope.client.console.commons.AttributableDataProvider;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.PreferenceManager;
+import org.apache.syncope.client.console.commons.XMLRolesReader;
+import org.apache.syncope.client.console.pages.AbstractBasePage;
+import org.apache.syncope.client.console.rest.AbstractSubjectRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.event.Broadcast;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.event.IEventSource;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public abstract class AbstractSearchResultPanel extends Panel implements IEventSource {
+
+ private static final long serialVersionUID = -9170191461250434024L;
+
+ /**
+ * Logger.
+ */
+ protected static final Logger LOG = LoggerFactory.getLogger(AbstractSearchResultPanel.class);
+
+ /**
+ * Edit modal window height.
+ */
+ private final static int EDIT_MODAL_WIN_HEIGHT = 550;
+
+ /**
+ * Edit modal window width.
+ */
+ private final static int EDIT_MODAL_WIN_WIDTH = 800;
+
+ /**
+ * Schemas to be shown modal window height.
+ */
+ private final static int DISPLAYATTRS_MODAL_WIN_HEIGHT = 550;
+
+ /**
+ * Schemas to be shown modal window width.
+ */
+ private final static int DISPLAYATTRS_MODAL_WIN_WIDTH = 550;
+
+ /**
+ * Schemas to be shown modal window height.
+ */
+ private final static int STATUS_MODAL_WIN_HEIGHT = 500;
+
+ /**
+ * Schemas to be shown modal window width.
+ */
+ private final static int STATUS_MODAL_WIN_WIDTH = 700;
+
+ /**
+ * Application preferences.
+ */
+ @SpringBean
+ protected PreferenceManager prefMan;
+
+ /**
+ * Role reader for authorizations management.
+ */
+ @SpringBean
+ protected XMLRolesReader xmlRolesReader;
+
+ protected final AbstractSubjectRestClient restClient;
+
+ /**
+ * Number of rows per page.
+ */
+ private final int rows;
+
+ /**
+ * Container used to refresh table.
+ */
+ protected final WebMarkupContainer container;
+
+ /**
+ * Feedback panel specified by the caller.
+ */
+ protected final NotificationPanel feedbackPanel;
+
+ /**
+ * Specify if results are about a filtered search or not. Using this attribute it is possible to use this panel to
+ * show results about user list and user search.
+ */
+ private final boolean filtered;
+
+ /**
+ * Filter used in case of filtered search.
+ */
+ private String fiql;
+
+ /**
+ * Result table.
+ */
+ private AjaxDataTablePanel<AbstractAttributableTO, String> resultTable;
+
+ /**
+ * Data provider used to search for users.
+ */
+ private AttributableDataProvider dataProvider;
+
+ /**
+ * Modal window to be used for user profile editing. Global visibility is required ...
+ */
+ protected final ModalWindow editmodal = new ModalWindow("editModal");
+
+ /**
+ * Modal window to be used for attributes choosing to display in tables.
+ */
+ protected final ModalWindow displaymodal = new ModalWindow("displayModal");
+
+ /**
+ * Modal window to be used for user status management.
+ */
+ protected final ModalWindow statusmodal = new ModalWindow("statusModal");
+
+ /**
+ * Owner page.
+ */
+ protected final AbstractBasePage page;
+
+ protected <T extends AbstractAttributableTO> AbstractSearchResultPanel(final String id, final boolean filtered,
+ final String fiql, final PageReference pageRef, final AbstractSubjectRestClient restClient) {
+
+ super(id);
+
+ setOutputMarkupId(true);
+
+ this.page = (AbstractBasePage) pageRef.getPage();
+
+ this.filtered = filtered;
+ this.fiql = fiql;
+ this.feedbackPanel = page.getFeedbackPanel();
+
+ this.restClient = restClient;
+
+ editmodal.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ editmodal.setInitialHeight(EDIT_MODAL_WIN_HEIGHT);
+ editmodal.setInitialWidth(EDIT_MODAL_WIN_WIDTH);
+ editmodal.setCookieName("edit-modal");
+ add(editmodal);
+
+ displaymodal.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ displaymodal.setInitialHeight(DISPLAYATTRS_MODAL_WIN_HEIGHT);
+ displaymodal.setInitialWidth(DISPLAYATTRS_MODAL_WIN_WIDTH);
+ displaymodal.setCookieName("display-modal");
+ add(displaymodal);
+
+ statusmodal.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ statusmodal.setInitialHeight(STATUS_MODAL_WIN_HEIGHT);
+ statusmodal.setInitialWidth(STATUS_MODAL_WIN_WIDTH);
+ statusmodal.setCookieName("status-modal");
+ add(statusmodal);
+
+ // Container for user search result
+ container = new WebMarkupContainer("container");
+ container.setOutputMarkupId(true);
+ add(container);
+
+ rows = prefMan.getPaginatorRows(getRequest(), Constants.PREF_USERS_PAGINATOR_ROWS);
+ }
+
+ protected void initResultTable() {
+ // ---------------------------
+ // Result table initialization
+ // ---------------------------
+ updateResultTable(false);
+ // ---------------------------
+
+ // ---------------------------
+ // Rows-per-page selector
+ // ---------------------------
+ final Form<?> paginatorForm = new Form<>("paginator");
+ container.add(paginatorForm);
+
+ final DropDownChoice<Integer> rowsChooser = new DropDownChoice<>(
+ "rowsChooser", new PropertyModel<Integer>(this, "rows"), prefMan.getPaginatorChoices());
+
+ rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ prefMan.set(getRequest(), getResponse(), Constants.PREF_USERS_PAGINATOR_ROWS, String.valueOf(rows));
+
+ final EventDataWrapper data = new EventDataWrapper();
+ data.setTarget(target);
+ data.setRows(rows);
+
+ send(getParent(), Broadcast.BREADTH, data);
+ }
+ });
+ paginatorForm.add(rowsChooser);
+ // ---------------------------
+
+ setWindowClosedReloadCallback(statusmodal);
+ setWindowClosedReloadCallback(editmodal);
+ setWindowClosedReloadCallback(displaymodal);
+ }
+
+ public void search(final String fiql, final AjaxRequestTarget target) {
+ this.fiql = fiql;
+ dataProvider.setFIQL(fiql);
+ target.add(container);
+ }
+
+ private void updateResultTable(final boolean create) {
+ updateResultTable(create, rows);
+ }
+
+ private void updateResultTable(final boolean create, final int rows) {
+ dataProvider = new AttributableDataProvider(restClient, rows, filtered);
+ dataProvider.setFIQL(fiql);
+
+ final int currentPage = resultTable != null
+ ? (create
+ ? (int) resultTable.getPageCount() - 1
+ : (int) resultTable.getCurrentPage())
+ : 0;
+
+ resultTable = new AjaxDataTablePanel<>(
+ "resultTable",
+ getColumns(),
+ dataProvider,
+ rows,
+ getBulkActions(),
+ restClient,
+ "key",
+ getPageId(),
+ page.getPageReference());
+
+ resultTable.setCurrentPage(currentPage);
+
+ resultTable.setOutputMarkupId(true);
+
+ container.addOrReplace(resultTable);
+ }
+
+ protected abstract List<IColumn<AbstractAttributableTO, String>> getColumns();
+
+ @Override
+ public void onEvent(final IEvent<?> event) {
+ if (event.getPayload() instanceof EventDataWrapper) {
+ final EventDataWrapper data = (EventDataWrapper) event.getPayload();
+
+ if (data.getRows() < 1) {
+ updateResultTable(data.isCreate());
+ } else {
+ updateResultTable(data.isCreate(), data.getRows());
+ }
+
+ data.getTarget().add(container);
+ }
+ }
+
+ private void setWindowClosedReloadCallback(final ModalWindow window) {
+ window.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
+
+ private static final long serialVersionUID = 8804221891699487139L;
+
+ @Override
+ public void onClose(final AjaxRequestTarget target) {
+ final EventDataWrapper data = new EventDataWrapper();
+ data.setTarget(target);
+ data.setRows(rows);
+
+ send(getParent(), Broadcast.BREADTH, data);
+
+ if (page.isModalResult()) {
+ // reset modal result
+ page.setModalResult(false);
+ // set operation succeeded
+ getSession().info(getString(Constants.OPERATION_SUCCEEDED));
+ // refresh feedback panel
+ feedbackPanel.refresh(target);
+ }
+ }
+ });
+ }
+
+ public static class EventDataWrapper {
+
+ private AjaxRequestTarget target;
+
+ private boolean create;
+
+ private int rows;
+
+ public AjaxRequestTarget getTarget() {
+ return target;
+ }
+
+ public void setTarget(final AjaxRequestTarget target) {
+ this.target = target;
+ }
+
+ public boolean isCreate() {
+ return create;
+ }
+
+ public void setCreate(boolean create) {
+ this.create = create;
+ }
+
+ public int getRows() {
+ return rows;
+ }
+
+ public void setRows(int rows) {
+ this.rows = rows;
+ }
+ }
+
+ protected abstract <T extends AbstractAttributableTO> Collection<ActionLink.ActionType> getBulkActions();
+
+ protected abstract String getPageId();
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractTasks.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractTasks.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractTasks.java
new file mode 100644
index 0000000..381f878
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractTasks.java
@@ -0,0 +1,55 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import org.apache.syncope.client.console.commons.PreferenceManager;
+import org.apache.syncope.client.console.commons.XMLRolesReader;
+import org.apache.syncope.client.console.rest.TaskRestClient;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public abstract class AbstractTasks extends Panel {
+
+ private static final long serialVersionUID = -1190836516156843561L;
+
+ protected static final String VIEW_TASK_WIN_COOKIE_NAME = "view-task-win";
+
+ protected static final int WIN_HEIGHT = 500;
+
+ protected static final int WIN_WIDTH = 700;
+
+ protected static final String TASKS = "Tasks";
+
+ protected PageReference pageRef;
+
+ @SpringBean
+ protected TaskRestClient restClient;
+
+ @SpringBean
+ protected PreferenceManager prefMan;
+
+ @SpringBean
+ protected XMLRolesReader xmlRolesReader;
+
+ public AbstractTasks(final String id, final PageReference pageRef) {
+ super(id);
+ this.pageRef = pageRef;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AccountInformationPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AccountInformationPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AccountInformationPanel.java
new file mode 100644
index 0000000..3bc7dd8
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AccountInformationPanel.java
@@ -0,0 +1,73 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.model.Model;
+
+public class AccountInformationPanel extends AnnotatedBeanPanel {
+
+ private static final long serialVersionUID = 4228064224811390808L;
+
+ public <T extends AbstractAttributableTO> AccountInformationPanel(final String id, final UserTO userTO) {
+ super(id, userTO);
+
+ // ------------------------
+ // Change password date
+ // ------------------------
+ add(new Label("changePwdDate", new Model<String>(userTO.getChangePwdDate() == null
+ ? StringUtils.EMPTY
+ : SyncopeSession.get().getDateFormat().format(userTO.getChangePwdDate()))));
+ // ------------------------
+
+ // ------------------------
+ // Last login date
+ // ------------------------
+ add(new Label("lastLoginDate", new Model<String>(userTO.getLastLoginDate() == null
+ ? StringUtils.EMPTY
+ : SyncopeSession.get().getDateFormat().format(userTO.getLastLoginDate()))));
+ // ------------------------
+
+ // ------------------------
+ // Failed logins
+ // ------------------------
+ add(new Label("failedLogins", new Model<Integer>(userTO.getFailedLogins())));
+ // ------------------------
+
+ // ------------------------
+ // Token
+ // ------------------------
+ add(new Label("token", new Model<String>(userTO.getToken() == null
+ ? StringUtils.EMPTY
+ : userTO.getToken())));
+ // ------------------------
+
+ // ------------------------
+ // Token expire time
+ // ------------------------
+ add(new Label("tokenExpireTime", new Model<String>(userTO.getTokenExpireTime() == null
+ ? StringUtils.EMPTY
+ : SyncopeSession.get().getDateFormat().format(userTO.getTokenExpireTime()))));
+ // ------------------------
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ActionDataTablePanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ActionDataTablePanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ActionDataTablePanel.java
new file mode 100644
index 0000000..bfade98
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/ActionDataTablePanel.java
@@ -0,0 +1,149 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.Collection;
+import java.util.List;
+import org.apache.syncope.client.console.commons.ActionTableCheckGroup;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.CheckGroupColumn;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink.ActionType;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.wicket.AttributeModifier;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormChoiceComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.ISortableDataProvider;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.ResourceModel;
+
+public class ActionDataTablePanel<T, S> extends DataTablePanel<T, S> {
+
+ private static final long serialVersionUID = -8826989026203543957L;
+
+ private static final String CANCEL = "cancel";
+
+ private final Form<T> bulkActionForm;
+
+ private final ActionLinksPanel actionPanel;
+
+ private final PageReference pageRef;
+
+ public ActionDataTablePanel(
+ final String id,
+ final List<IColumn<T, S>> columns,
+ final ISortableDataProvider<T, S> dataProvider,
+ final int rowsPerPage,
+ final PageReference pageRef) {
+
+ super(id);
+
+ this.pageRef = pageRef;
+
+ bulkActionForm = new Form<T>("groupForm");
+ add(bulkActionForm);
+
+ group = new ActionTableCheckGroup<T>("checkgroup", model) {
+
+ private static final long serialVersionUID = -8667764190925075389L;
+
+ @Override
+ public boolean isCheckable(final T element) {
+ return isElementEnabled(element);
+ }
+ };
+ group.add(new AjaxFormChoiceComponentUpdatingBehavior() {
+
+ private static final long serialVersionUID = -151291731388673682L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ // triggers AJAX form submit
+ }
+ });
+ bulkActionForm.add(group);
+
+ columns.add(0, new CheckGroupColumn<T, S>(group));
+ dataTable = new AjaxFallbackDefaultDataTable<T, S>("dataTable", columns, dataProvider, rowsPerPage);
+ group.add(dataTable);
+
+ final WebMarkupContainer actionPanelContainer = new WebMarkupContainer("actionPanelContainer");
+ bulkActionForm.add(actionPanelContainer);
+
+ actionPanel = new ActionLinksPanel("actions", new Model(), pageRef);
+ actionPanelContainer.add(actionPanel);
+
+ if (dataTable.getRowCount() == 0) {
+ actionPanelContainer.add(new AttributeModifier("style", "display: none"));
+ }
+
+ bulkActionForm.add(new ClearIndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL), pageRef) {
+
+ private static final long serialVersionUID = -2341391430136818025L;
+
+ @Override
+ protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
+ // ignore
+ }
+ }.setVisible(false).setEnabled(false));
+ }
+
+ public void addAction(final ActionLink action, final ActionType type, final String pageId) {
+ actionPanel.add(action, type, pageId);
+ }
+
+ public void addAction(final ActionLink action, final ActionType type, final String pageId, final String actionId) {
+ actionPanel.add(action, type, pageId, actionId);
+ }
+
+ public void addAction(final ActionLink action, final ActionType type, final String pageId, final boolean enabled) {
+ actionPanel.add(action, type, pageId, enabled);
+ }
+
+ public void addCancelButton(final ModalWindow window) {
+
+ final AjaxButton cancel = new ClearIndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL), pageRef) {
+
+ private static final long serialVersionUID = -2341391430136818025L;
+
+ @Override
+ protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+ }.feedbackPanelAutomaticReload(false);
+
+ cancel.setDefaultFormProcessing(false);
+ bulkActionForm.addOrReplace(cancel);
+ }
+
+ public Collection<T> getModelObject() {
+ return group.getModelObject();
+ }
+
+ public boolean isElementEnabled(final T element) {
+ return true;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AjaxDataTablePanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AjaxDataTablePanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AjaxDataTablePanel.java
new file mode 100644
index 0000000..563bd17
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AjaxDataTablePanel.java
@@ -0,0 +1,142 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.Collection;
+import java.util.List;
+import org.apache.syncope.client.console.rest.BaseRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.panels.AbstractSearchResultPanel.EventDataWrapper;
+import org.apache.syncope.client.console.pages.AbstractBasePage;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.CheckGroupColumn;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
+import org.apache.syncope.client.console.pages.BulkActionModalPage;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormChoiceComponentUpdatingBehavior;
+import org.apache.wicket.event.Broadcast;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.ISortableDataProvider;
+import org.apache.wicket.markup.html.form.CheckGroup;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.panel.Fragment;
+
+public class AjaxDataTablePanel<T, S> extends DataTablePanel<T, S> {
+
+ private static final long serialVersionUID = -7264400471578272966L;
+
+ public AjaxDataTablePanel(
+ final String id,
+ final List<IColumn<T, S>> columns,
+ final ISortableDataProvider<T, S> dataProvider,
+ final int rowsPerPage,
+ final Collection<ActionLink.ActionType> actions,
+ final BaseRestClient bulkActionExecutor,
+ final String itemIdField,
+ final String pageId,
+ final PageReference pageRef) {
+
+ super(id);
+
+ final ModalWindow bulkModalWin = new ModalWindow("bulkModal");
+ bulkModalWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ bulkModalWin.setInitialHeight(600);
+ bulkModalWin.setInitialWidth(900);
+ bulkModalWin.setCookieName("bulk-modal");
+ add(bulkModalWin);
+
+ bulkModalWin.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
+
+ private static final long serialVersionUID = 8804221891699487149L;
+
+ @Override
+ public void onClose(final AjaxRequestTarget target) {
+ final EventDataWrapper data = new EventDataWrapper();
+ data.setTarget(target);
+ data.setRows(rowsPerPage);
+
+ send(pageRef.getPage(), Broadcast.BREADTH, data);
+
+ final AbstractBasePage page = (AbstractBasePage) pageRef.getPage();
+
+ if (page.isModalResult()) {
+ // reset modal result
+ page.setModalResult(false);
+ // set operation succeeded
+ getSession().info(getString(Constants.OPERATION_SUCCEEDED));
+ // refresh feedback panel
+ target.add(page.getFeedbackPanel());
+ }
+ }
+ });
+
+ Fragment fragment = new Fragment("tablePanel", "bulkAvailable", this);
+ add(fragment);
+
+ Form<T> bulkActionForm = new Form<>("groupForm");
+ fragment.add(bulkActionForm);
+
+ group = new CheckGroup<>("checkgroup", model);
+ group.add(new AjaxFormChoiceComponentUpdatingBehavior() {
+
+ private static final long serialVersionUID = -151291731388673682L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ // triggers AJAX form submit
+ }
+ });
+ bulkActionForm.add(group);
+
+ columns.add(0, new CheckGroupColumn<T, S>(group));
+ dataTable = new AjaxFallbackDefaultDataTable<>("dataTable", columns, dataProvider, rowsPerPage);
+ group.add(dataTable);
+
+ fragment.add(new ClearIndicatingAjaxButton("bulkActionLink", bulkActionForm, pageRef) {
+
+ private static final long serialVersionUID = 382302811235019988L;
+
+ @Override
+ protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
+ bulkModalWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690941L;
+
+ @Override
+ public Page createPage() {
+ return new BulkActionModalPage<>(
+ bulkModalWin,
+ group.getModelObject(),
+ columns,
+ actions,
+ bulkActionExecutor,
+ itemIdField,
+ pageId);
+ }
+ });
+
+ bulkModalWin.show(target);
+ }
+ });
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AnnotatedBeanPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AnnotatedBeanPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AnnotatedBeanPanel.java
new file mode 100644
index 0000000..714cb5f
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AnnotatedBeanPanel.java
@@ -0,0 +1,66 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.common.lib.to.AbstractAnnotatedBean;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.Model;
+
+public class AnnotatedBeanPanel extends Panel {
+
+ private static final long serialVersionUID = 4228064224811390809L;
+
+ public <T extends AbstractAttributableTO> AnnotatedBeanPanel(
+ final String id, final AbstractAnnotatedBean sysInfoTO) {
+
+ super(id);
+
+ // ------------------------
+ // Creation date
+ // ------------------------
+ add(new Label("creationDate", new Model<String>(sysInfoTO.getCreationDate() != null
+ ? SyncopeSession.get().getDateFormat().format(sysInfoTO.getCreationDate()) : "")));
+ // ------------------------
+
+ // ------------------------
+ // Last change date
+ // ------------------------
+ add(new Label("lastChangeDate", new Model<String>(sysInfoTO.getLastChangeDate() != null
+ ? SyncopeSession.get().getDateFormat().format(sysInfoTO.getCreationDate()) : "")));
+ // ------------------------
+
+ // ------------------------
+ // Creator
+ // ------------------------
+ add(new Label("creator", new Model<String>(sysInfoTO.getCreator() != null
+ ? sysInfoTO.getCreator() : "")));
+ // ------------------------
+
+ // ------------------------
+ // Last modifier
+ // ------------------------
+ add(new Label("lastModifier", new Model<String>(sysInfoTO.getLastModifier() != null
+ ? sysInfoTO.getLastModifier() : "")));
+ // ------------------------
+
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AttrTemplatesPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AttrTemplatesPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AttrTemplatesPanel.java
new file mode 100644
index 0000000..98ada28
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AttrTemplatesPanel.java
@@ -0,0 +1,167 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.Collection;
+import java.util.Collections;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.SelectChoiceRenderer;
+import org.apache.syncope.client.console.rest.SchemaRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.NonI18nPalette;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.syncope.common.lib.types.SchemaType;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.event.Broadcast;
+import org.apache.wicket.extensions.markup.html.form.palette.component.Recorder;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.util.ListModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class AttrTemplatesPanel extends Panel {
+
+ public enum Type {
+
+ gPlainAttrTemplates,
+ gDerAttrTemplates,
+ gVirAttrTemplates,
+ mPlainAttrTemplates,
+ mDerAttrTemplates,
+ mVirAttrTemplates;
+
+ }
+
+ private static final long serialVersionUID = 1016028222120619000L;
+
+ @SpringBean
+ private SchemaRestClient schemaRestClient;
+
+ private final GroupTO groupTO;
+
+ private final NonI18nPalette<String> rPlainAttrTemplates;
+
+ private final NonI18nPalette<String> rDerAttrTemplates;
+
+ private final NonI18nPalette<String> rVirAttrTemplates;
+
+ public AttrTemplatesPanel(final String id, final GroupTO groupTO) {
+ super(id);
+ this.groupTO = groupTO;
+
+ rPlainAttrTemplates = buildPalette(Type.gPlainAttrTemplates,
+ schemaRestClient.getSchemaNames(AttributableType.GROUP, SchemaType.PLAIN));
+ this.add(rPlainAttrTemplates);
+ rDerAttrTemplates = buildPalette(Type.gDerAttrTemplates,
+ schemaRestClient.getSchemaNames(AttributableType.GROUP, SchemaType.DERIVED));
+ this.add(rDerAttrTemplates);
+ rVirAttrTemplates = buildPalette(Type.gVirAttrTemplates,
+ schemaRestClient.getSchemaNames(AttributableType.GROUP, SchemaType.VIRTUAL));
+ this.add(rVirAttrTemplates);
+
+ this.add(buildPalette(Type.mPlainAttrTemplates,
+ schemaRestClient.getSchemaNames(AttributableType.MEMBERSHIP, SchemaType.PLAIN)));
+ this.add(buildPalette(Type.mDerAttrTemplates,
+ schemaRestClient.getSchemaNames(AttributableType.MEMBERSHIP, SchemaType.DERIVED)));
+ this.add(buildPalette(Type.mVirAttrTemplates,
+ schemaRestClient.getSchemaNames(AttributableType.MEMBERSHIP, SchemaType.VIRTUAL)));
+ }
+
+ private NonI18nPalette<String> buildPalette(final Type type, final List<String> allSchemas) {
+ if (allSchemas != null && !allSchemas.isEmpty()) {
+ Collections.sort(allSchemas);
+ }
+ ListModel<String> availableSchemas = new ListModel<>(allSchemas);
+
+ return new NonI18nPalette<String>(type.name(), new PropertyModel<List<String>>(groupTO, type.name()),
+ availableSchemas, new SelectChoiceRenderer<String>(), 8, false, true) {
+
+ private static final long serialVersionUID = 2295567122085510330L;
+
+ @Override
+ protected Recorder<String> newRecorderComponent() {
+ final Recorder<String> recorder = super.newRecorderComponent();
+
+ switch (type) {
+ case gPlainAttrTemplates:
+ case gDerAttrTemplates:
+ case gVirAttrTemplates:
+ recorder.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ send(getPage(), Broadcast.BREADTH, new GroupAttrTemplatesChange(type, target));
+ }
+ });
+ break;
+
+ default:
+ }
+
+ return recorder;
+ }
+ };
+ }
+
+ public Collection<String> getSelected(final Type type) {
+ Collection<String> selected;
+ switch (type) {
+ case gPlainAttrTemplates:
+ selected = this.rPlainAttrTemplates.getModelCollection();
+ break;
+
+ case gDerAttrTemplates:
+ selected = this.rDerAttrTemplates.getModelCollection();
+ break;
+
+ case gVirAttrTemplates:
+ selected = this.rVirAttrTemplates.getModelCollection();
+ break;
+
+ default:
+ selected = Collections.emptyList();
+ }
+
+ return selected;
+ }
+
+ public static class GroupAttrTemplatesChange {
+
+ private final Type type;
+
+ private final AjaxRequestTarget target;
+
+ public GroupAttrTemplatesChange(final Type type, final AjaxRequestTarget target) {
+ this.type = type;
+ this.target = target;
+ }
+
+ public Type getType() {
+ return type;
+ }
+
+ public AjaxRequestTarget getTarget() {
+ return target;
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/DataTablePanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/DataTablePanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/DataTablePanel.java
new file mode 100644
index 0000000..a5f6588
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/DataTablePanel.java
@@ -0,0 +1,113 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.Collection;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.Set;
+import org.apache.wicket.Component;
+import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.DataGridView;
+import org.apache.wicket.markup.html.form.CheckGroup;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.IModel;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public abstract class DataTablePanel<T, S> extends Panel {
+
+ private static final long serialVersionUID = -7264400471578272966L;
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(DataTablePanel.class);
+
+ protected CheckGroup<T> group;
+
+ protected AjaxFallbackDefaultDataTable<T, S> dataTable;
+
+ protected IModel<Collection<T>> model;
+
+ public DataTablePanel(final String id) {
+ super(id);
+
+ model = new IModel<Collection<T>>() {
+
+ private static final long serialVersionUID = 4886729136344643465L;
+
+ private Collection<T> values = new HashSet<T>();
+
+ @Override
+ public Collection<T> getObject() {
+ // Someone or something call this method to change the model: this is not the right behavior.
+ // Return a copy of the model object in order to avoid SYNCOPE-465
+ return new HashSet<T>(values);
+ }
+
+ @Override
+ public void setObject(final Collection<T> selected) {
+ final Collection<T> all = getGroupModelObjects();
+ values.removeAll(all);
+ values.addAll(selected);
+ }
+
+ @Override
+ public void detach() {
+ }
+ };
+ }
+
+ public final void setCurrentPage(final long page) {
+ dataTable.setCurrentPage(page);
+ }
+
+ public final long getRowCount() {
+ return dataTable.getRowCount();
+ }
+
+ public final long getCurrentPage() {
+ return dataTable.getCurrentPage();
+ }
+
+ public final long getPageCount() {
+ return dataTable.getPageCount();
+ }
+
+ public void setItemsPerPage(final int resourcePaginatorRows) {
+ dataTable.setItemsPerPage(resourcePaginatorRows);
+ }
+
+ protected Collection<T> getGroupModelObjects() {
+ final Set<T> res = new HashSet<T>();
+
+ final Component rows = group.get("dataTable:body:rows");
+ if (rows instanceof DataGridView) {
+ @SuppressWarnings("unchecked")
+ final Iterator<Item<T>> iter = ((DataGridView<T>) rows).getItems();
+
+ while (iter.hasNext()) {
+ res.add(iter.next().getModelObject());
+ }
+ }
+ return res;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/DerAttrsPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/DerAttrsPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/DerAttrsPanel.java
new file mode 100644
index 0000000..8be459a
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/DerAttrsPanel.java
@@ -0,0 +1,206 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.panels.AttrTemplatesPanel.GroupAttrTemplatesChange;
+import org.apache.syncope.client.console.rest.GroupRestClient;
+import org.apache.syncope.client.console.rest.SchemaRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDecoratedCheckbox;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.to.AttrTO;
+import org.apache.syncope.common.lib.to.MembershipTO;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.wicket.Component;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.attributes.AjaxCallListener;
+import org.apache.wicket.ajax.attributes.AjaxRequestAttributes;
+import org.apache.wicket.ajax.attributes.IAjaxCallListener;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.form.TextField;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class DerAttrsPanel extends Panel {
+
+ private static final long serialVersionUID = -5387344116983102292L;
+
+ @SpringBean
+ private SchemaRestClient schemaRestClient;
+
+ @SpringBean
+ private GroupRestClient groupRestClient;
+
+ private final AttrTemplatesPanel attrTemplates;
+
+ public <T extends AbstractAttributableTO> DerAttrsPanel(final String id, final T entityTO) {
+ this(id, entityTO, null);
+ }
+
+ public <T extends AbstractAttributableTO> DerAttrsPanel(final String id, final T entityTO,
+ final AttrTemplatesPanel attrTemplates) {
+
+ super(id);
+ this.attrTemplates = attrTemplates;
+ setOutputMarkupId(true);
+
+ final IModel<List<String>> derSchemas = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ List<String> derSchemaNames;
+
+ if (entityTO instanceof GroupTO) {
+ final GroupTO groupTO = (GroupTO) entityTO;
+
+ if (attrTemplates == null) {
+ derSchemaNames = groupTO.getGDerAttrTemplates();
+ } else {
+ derSchemaNames = new ArrayList<>(
+ attrTemplates.getSelected(AttrTemplatesPanel.Type.gDerAttrTemplates));
+ if (groupTO.isInheritTemplates() && groupTO.getParent() != 0) {
+ derSchemaNames.addAll(groupRestClient.read(groupTO.getParent()).getGDerAttrTemplates());
+ }
+ }
+ } else if (entityTO instanceof UserTO) {
+ derSchemaNames = schemaRestClient.getDerSchemaNames(AttributableType.USER);
+ } else {
+ derSchemaNames = groupRestClient.read(((MembershipTO) entityTO).getGroupKey()).getMDerAttrTemplates();
+ }
+
+ return derSchemaNames;
+ }
+ };
+
+ final WebMarkupContainer attributesContainer = new WebMarkupContainer("derAttrContainer");
+
+ attributesContainer.setOutputMarkupId(true);
+ add(attributesContainer);
+
+ AjaxButton addAttributeBtn = new IndicatingAjaxButton("addAttributeBtn", new ResourceModel("addAttributeBtn")) {
+
+ private static final long serialVersionUID = -4804368561204623354L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ entityTO.getDerAttrs().add(new AttrTO());
+ target.add(attributesContainer);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ target.add(attributesContainer);
+ }
+ };
+ add(addAttributeBtn.setDefaultFormProcessing(false));
+
+ ListView<AttrTO> attributes = new ListView<AttrTO>("attrs",
+ new PropertyModel<List<? extends AttrTO>>(entityTO, "derAttrs")) {
+
+ private static final long serialVersionUID = 9101744072914090143L;
+
+ @Override
+ protected void populateItem(final ListItem<AttrTO> item) {
+ final AttrTO attributeTO = item.getModelObject();
+
+ item.add(new AjaxDecoratedCheckbox("toRemove", new Model<>(Boolean.FALSE)) {
+
+ private static final long serialVersionUID = 7170946748485726506L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ entityTO.getDerAttrs().remove(attributeTO);
+ target.add(attributesContainer);
+ }
+
+ @Override
+ protected void updateAjaxAttributes(final AjaxRequestAttributes attributes) {
+ super.updateAjaxAttributes(attributes);
+
+ IAjaxCallListener ajaxCallListener = new AjaxCallListener() {
+
+ private static final long serialVersionUID = 7160235486520935153L;
+
+ @Override
+ public CharSequence getPrecondition(final Component component) {
+ return "if (!confirm('" + getString("confirmDelete") + "')) return false;";
+ }
+ };
+ attributes.getAjaxCallListeners().add(ajaxCallListener);
+ }
+ });
+
+ final DropDownChoice<String> schemaChoice = new DropDownChoice<String>("schema",
+ new PropertyModel<String>(attributeTO, "schema"), derSchemas);
+ schemaChoice.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_BLUR) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ attributeTO.setSchema(schemaChoice.getModelObject());
+ }
+ });
+ schemaChoice.setRequired(true);
+ schemaChoice.setOutputMarkupId(true);
+ schemaChoice.setRequired(true);
+ item.add(schemaChoice);
+
+ final List<String> values = attributeTO.getValues();
+ if (values == null || values.isEmpty()) {
+ item.add(new TextField<String>("value",
+ new Model<String>(null)).setVisible(false));
+ } else {
+ item.add(new TextField<String>("value",
+ new Model<String>(values.get(0))).setEnabled(false));
+ }
+ }
+ };
+ attributesContainer.add(attributes);
+ }
+
+ @Override
+ public void onEvent(final IEvent<?> event) {
+ if ((event.getPayload() instanceof GroupAttrTemplatesChange)) {
+ final GroupAttrTemplatesChange update = (GroupAttrTemplatesChange) event.getPayload();
+ if (attrTemplates != null && update.getType() == AttrTemplatesPanel.Type.gDerAttrTemplates) {
+ update.getTarget().add(this);
+ }
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/EventSelectionPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/EventSelectionPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/EventSelectionPanel.java
new file mode 100644
index 0000000..5332cb5
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/EventSelectionPanel.java
@@ -0,0 +1,243 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.wicket.markup.html.list.AltListView;
+import org.apache.syncope.common.lib.to.EventCategoryTO;
+import org.apache.syncope.common.lib.types.AuditElements;
+import org.apache.syncope.common.lib.types.AuditLoggerName;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormChoiceComponentUpdatingBehavior;
+import org.apache.wicket.event.Broadcast;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Check;
+import org.apache.wicket.markup.html.form.CheckGroup;
+import org.apache.wicket.markup.html.form.CheckGroupSelector;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.ResourceModel;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public abstract class EventSelectionPanel extends Panel {
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(EventSelectionPanel.class);
+
+ private static final long serialVersionUID = 752233163798301002L;
+
+ private final Set<String> selected = new HashSet<String>();
+
+ public EventSelectionPanel(
+ final String id, final EventCategoryTO eventCategoryTO, final IModel<List<String>> model) {
+ super(id);
+ setOutputMarkupId(true);
+
+ final List<String> events = getEvents(eventCategoryTO);
+
+ // needed to avoid model reset: model have to be managed into SelectedEventsPanel
+ selected.addAll(model.getObject());
+
+ final CheckGroup<String> successGroup = new CheckGroup<String>(
+ "successGroup",
+ selected);
+
+ successGroup.add(new AjaxFormChoiceComponentUpdatingBehavior() {
+
+ private static final long serialVersionUID = -151291731388673682L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+
+ final Set<String> toBeRemoved = new HashSet<>();
+ final Set<String> toBeAdded = new HashSet<>();
+
+ for (String event : getEvents(eventCategoryTO)) {
+ final String eventString = AuditLoggerName.buildEvent(
+ eventCategoryTO.getType(),
+ eventCategoryTO.getCategory(),
+ eventCategoryTO.getSubcategory(),
+ event,
+ AuditElements.Result.SUCCESS);
+
+ if (successGroup.getModelObject().contains(eventString)) {
+ toBeAdded.add(eventString);
+ } else {
+ toBeRemoved.add(eventString);
+ }
+ }
+
+ send(EventSelectionPanel.this.getPage(), Broadcast.BREADTH,
+ new SelectedEventsPanel.EventSelectionChanged(target, toBeAdded, toBeRemoved));
+ }
+ });
+
+ successGroup.setVisible(!events.isEmpty());
+ add(successGroup);
+
+ add(new Label("successLabel", new ResourceModel("Success", "Success"))).setVisible(!events.isEmpty());
+
+ final CheckGroupSelector successSelector = new CheckGroupSelector("successSelector", successGroup);
+ successSelector.setVisible(!events.isEmpty());
+ add(successSelector);
+
+ final ListView<String> categoryView = new AltListView<String>("categoryView", events) {
+
+ private static final long serialVersionUID = 4949588177564901031L;
+
+ @Override
+ protected void populateItem(final ListItem<String> item) {
+ final String subcategory = item.getModelObject();
+
+ item.add(new Label("subcategory", new ResourceModel(subcategory, subcategory)));
+ }
+ };
+ add(categoryView);
+
+ final ListView<String> successView = new AltListView<String>("successView", events) {
+
+ private static final long serialVersionUID = 4949588177564901031L;
+
+ @Override
+ protected void populateItem(final ListItem<String> item) {
+ final String event = item.getModelObject();
+
+ final Check<String> successCheck = new Check<>("successCheck",
+ new Model<String>(AuditLoggerName.buildEvent(
+ eventCategoryTO.getType(),
+ eventCategoryTO.getCategory(),
+ eventCategoryTO.getSubcategory(),
+ event,
+ AuditElements.Result.SUCCESS)),
+ successGroup);
+ item.add(successCheck);
+ }
+ };
+ successGroup.add(successView);
+
+ final CheckGroup<String> failureGroup = new CheckGroup<String>(
+ "failureGroup",
+ selected);
+
+ failureGroup.add(new AjaxFormChoiceComponentUpdatingBehavior() {
+
+ private static final long serialVersionUID = -151291731388673682L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+
+ final Set<String> toBeRemoved = new HashSet<>();
+ final Set<String> toBeAdded = new HashSet<>();
+
+ for (String event : getEvents(eventCategoryTO)) {
+ final String eventString = AuditLoggerName.buildEvent(
+ eventCategoryTO.getType(),
+ eventCategoryTO.getCategory(),
+ eventCategoryTO.getSubcategory(),
+ event,
+ AuditElements.Result.FAILURE);
+
+ if (failureGroup.getModelObject().contains(eventString)) {
+ toBeAdded.add(eventString);
+ } else {
+ toBeRemoved.add(eventString);
+ }
+ }
+
+ send(EventSelectionPanel.this.getPage(), Broadcast.BREADTH,
+ new SelectedEventsPanel.EventSelectionChanged(target, toBeAdded, toBeRemoved));
+ }
+ });
+
+ failureGroup.setVisible(!events.isEmpty());
+ add(failureGroup);
+
+ add(new Label("failureLabel", new ResourceModel("Failure", "Failure"))).setVisible(!events.isEmpty());
+
+ final CheckGroupSelector failureSelector = new CheckGroupSelector("failureSelector", failureGroup);
+ failureSelector.setVisible(!events.isEmpty());
+ add(failureSelector);
+
+ final ListView<String> failureView = new AltListView<String>("failureView", events) {
+
+ private static final long serialVersionUID = 4949588177564901031L;
+
+ @Override
+ protected void populateItem(final ListItem<String> item) {
+ final String event = item.getModelObject();
+
+ final Check<String> failureCheck = new Check<>("failureCheck",
+ new Model<String>(AuditLoggerName.buildEvent(
+ eventCategoryTO.getType(),
+ eventCategoryTO.getCategory(),
+ eventCategoryTO.getSubcategory(),
+ event,
+ AuditElements.Result.FAILURE)),
+ failureGroup);
+ item.add(failureCheck);
+ }
+ };
+ failureGroup.add(failureView);
+ }
+
+ private List<String> getEvents(final EventCategoryTO eventCategoryTO) {
+ final List<String> res;
+
+ res = eventCategoryTO.getEvents();
+
+ if (res.isEmpty()) {
+ if ((AuditElements.EventCategoryType.PROPAGATION == eventCategoryTO.getType()
+ || AuditElements.EventCategoryType.SYNCHRONIZATION == eventCategoryTO.getType()
+ || AuditElements.EventCategoryType.PUSH == eventCategoryTO.getType())
+ && StringUtils.isEmpty(eventCategoryTO.getCategory())) {
+ res.add(eventCategoryTO.getType().toString());
+ } else if (AuditElements.EventCategoryType.TASK == eventCategoryTO.getType()
+ && StringUtils.isNotEmpty(eventCategoryTO.getCategory())) {
+ res.add(eventCategoryTO.getCategory());
+ }
+ } else {
+ Collections.sort(res);
+ }
+
+ return res;
+ }
+
+ /**
+ * To be extended in order to add actions on events.
+ *
+ * @param event event.
+ */
+ protected abstract void onEventAction(final IEvent<?> event);
+
+ @Override
+ public void onEvent(final IEvent<?> event) {
+ onEventAction(event);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupDetailsPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupDetailsPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupDetailsPanel.java
new file mode 100644
index 0000000..7662e4a
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/GroupDetailsPanel.java
@@ -0,0 +1,435 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.JexlHelpUtils;
+import org.apache.syncope.client.console.pages.GroupSelectModalPage;
+import org.apache.syncope.client.console.pages.UserOwnerSelectModalPage;
+import org.apache.syncope.client.console.panels.AttrTemplatesPanel.GroupAttrTemplatesChange;
+import org.apache.syncope.client.console.panels.AttrTemplatesPanel.Type;
+import org.apache.syncope.client.console.rest.GroupRestClient;
+import org.apache.syncope.client.console.rest.UserRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.wicket.Page;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.event.Broadcast;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.panel.Fragment;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class GroupDetailsPanel extends Panel {
+
+ private static final long serialVersionUID = 855618618337931784L;
+
+ /**
+ * Logger.
+ */
+ protected static final Logger LOG = LoggerFactory.getLogger(GroupDetailsPanel.class);
+
+ @SpringBean
+ private UserRestClient userRestClient;
+
+ @SpringBean
+ private GroupRestClient groupRestClient;
+
+ private final Fragment parentFragment;
+
+ private final WebMarkupContainer ownerContainer;
+
+ private final OwnerModel userOwnerModel;
+
+ private final OwnerModel groupOwnerModel;
+
+ private ParentModel parentModel;
+
+ public GroupDetailsPanel(final String id, final GroupTO groupTO, final boolean templateMode) {
+ super(id);
+
+ ownerContainer = new WebMarkupContainer("ownerContainer");
+ ownerContainer.setOutputMarkupId(true);
+ this.add(ownerContainer);
+
+ final ModalWindow userOwnerSelectWin = new ModalWindow("userOwnerSelectWin");
+ userOwnerSelectWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ userOwnerSelectWin.setCookieName("create-userOwnerSelect-modal");
+ this.add(userOwnerSelectWin);
+ final ModalWindow groupOwnerSelectWin = new ModalWindow("groupOwnerSelectWin");
+ groupOwnerSelectWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ groupOwnerSelectWin.setCookieName("create-groupOwnerSelect-modal");
+ this.add(groupOwnerSelectWin);
+ final ModalWindow parentSelectWin = new ModalWindow("parentSelectWin");
+ parentSelectWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ parentSelectWin.setCookieName("create-parentSelect-modal");
+ this.add(parentSelectWin);
+
+ if (templateMode) {
+ parentFragment = new Fragment("parent", "parentFragment", this);
+
+ parentModel = new ParentModel(groupTO);
+ @SuppressWarnings("unchecked")
+ final AjaxTextFieldPanel parent = new AjaxTextFieldPanel("parent", "parent", parentModel);
+ parent.setReadOnly(true);
+ parent.setOutputMarkupId(true);
+ parentFragment.add(parent);
+ final AjaxLink<Void> parentSelect = new IndicatingAjaxLink<Void>("parentSelect") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ parentSelectWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new GroupSelectModalPage(getPage().getPageReference(), parentSelectWin,
+ ParentSelectPayload.class);
+ }
+ });
+ parentSelectWin.show(target);
+ }
+ };
+ parentFragment.add(parentSelect);
+ final IndicatingAjaxLink<Void> parentReset = new IndicatingAjaxLink<Void>("parentReset") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ parentModel.setObject(null);
+ target.add(parent);
+ }
+ };
+ parentFragment.add(parentReset);
+ } else {
+ parentFragment = new Fragment("parent", "emptyFragment", this);
+ }
+ parentFragment.setOutputMarkupId(true);
+ this.add(parentFragment);
+
+ final AjaxTextFieldPanel name =
+ new AjaxTextFieldPanel("name", "name", new PropertyModel<String>(groupTO, "key"));
+
+ final WebMarkupContainer jexlHelp = JexlHelpUtils.getJexlHelpWebContainer("jexlHelp");
+
+ final AjaxLink<Void> questionMarkJexlHelp = JexlHelpUtils.getAjaxLink(jexlHelp, "questionMarkJexlHelp");
+ this.add(questionMarkJexlHelp);
+ questionMarkJexlHelp.add(jexlHelp);
+
+ if (!templateMode) {
+ name.addRequiredLabel();
+ questionMarkJexlHelp.setVisible(false);
+ }
+ this.add(name);
+
+ userOwnerModel = new OwnerModel(groupTO, AttributableType.USER);
+ @SuppressWarnings("unchecked")
+ final AjaxTextFieldPanel userOwner = new AjaxTextFieldPanel("userOwner", "userOwner", userOwnerModel);
+ userOwner.setReadOnly(true);
+ userOwner.setOutputMarkupId(true);
+ ownerContainer.add(userOwner);
+ final AjaxLink<Void> userOwnerSelect = new IndicatingAjaxLink<Void>("userOwnerSelect") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ userOwnerSelectWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new UserOwnerSelectModalPage(getPage().getPageReference(), userOwnerSelectWin);
+ }
+ });
+ userOwnerSelectWin.show(target);
+ }
+ };
+ ownerContainer.add(userOwnerSelect);
+ final IndicatingAjaxLink<Void> userOwnerReset = new IndicatingAjaxLink<Void>("userOwnerReset") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ userOwnerModel.setObject(null);
+ target.add(userOwner);
+ }
+ };
+ ownerContainer.add(userOwnerReset);
+
+ groupOwnerModel = new OwnerModel(groupTO, AttributableType.GROUP);
+ @SuppressWarnings("unchecked")
+ final AjaxTextFieldPanel groupOwner = new AjaxTextFieldPanel("groupOwner", "groupOwner", groupOwnerModel);
+ groupOwner.setReadOnly(true);
+ groupOwner.setOutputMarkupId(true);
+ ownerContainer.add(groupOwner);
+ final AjaxLink<Void> groupOwnerSelect = new IndicatingAjaxLink<Void>("groupOwnerSelect") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ parentSelectWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new GroupSelectModalPage(getPage().getPageReference(), parentSelectWin,
+ GroupOwnerSelectPayload.class);
+ }
+ });
+ parentSelectWin.show(target);
+ }
+ };
+ ownerContainer.add(groupOwnerSelect);
+ final IndicatingAjaxLink<Void> groupOwnerReset = new IndicatingAjaxLink<Void>("groupOwnerReset") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ groupOwnerModel.setObject(null);
+ target.add(groupOwner);
+ }
+ };
+ ownerContainer.add(groupOwnerReset);
+
+ final AjaxCheckBoxPanel inhOwner = new AjaxCheckBoxPanel("inheritOwner", "inheritOwner",
+ new PropertyModel<Boolean>(groupTO, "inheritOwner"));
+ this.add(inhOwner);
+
+ final AjaxCheckBoxPanel inhTemplates = new AjaxCheckBoxPanel("inheritTemplates", "inheritTemplates",
+ new PropertyModel<Boolean>(groupTO, "inheritTemplates"));
+ inhTemplates.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ send(getPage(), Broadcast.BREADTH, new GroupAttrTemplatesChange(Type.gPlainAttrTemplates, target));
+ send(getPage(), Broadcast.BREADTH, new GroupAttrTemplatesChange(Type.gDerAttrTemplates, target));
+ send(getPage(), Broadcast.BREADTH, new GroupAttrTemplatesChange(Type.gVirAttrTemplates, target));
+ }
+ });
+ this.add(inhTemplates);
+ }
+
+ /**
+ * This is waiting for events from opened modal windows: first to get the selected user / group, then to update the
+ * respective text panel.
+ *
+ * {@inheritDoc }
+ */
+ @Override
+ public void onEvent(final IEvent<?> event) {
+ super.onEvent(event);
+
+ if (event.getPayload() instanceof ParentSelectPayload) {
+ parentModel.setObject(((ParentSelectPayload) event.getPayload()).getGroupId());
+ }
+ if (event.getPayload() instanceof UserOwnerSelectPayload) {
+ userOwnerModel.setObject(((UserOwnerSelectPayload) event.getPayload()).getUserId());
+ }
+ if (event.getPayload() instanceof GroupOwnerSelectPayload) {
+ groupOwnerModel.setObject(((GroupOwnerSelectPayload) event.getPayload()).getGroupId());
+ }
+
+ if (event.getPayload() instanceof AjaxRequestTarget) {
+ ((AjaxRequestTarget) event.getPayload()).add(parentFragment);
+ ((AjaxRequestTarget) event.getPayload()).add(ownerContainer);
+ }
+ }
+
+ private class OwnerModel implements IModel {
+
+ private static final long serialVersionUID = -3865621970810102714L;
+
+ private final GroupTO groupTO;
+
+ private final AttributableType type;
+
+ public OwnerModel(final GroupTO groupTO, final AttributableType type) {
+ this.groupTO = groupTO;
+ this.type = type;
+ }
+
+ @Override
+ public Object getObject() {
+ String object = null;
+
+ switch (type) {
+ case USER:
+ if (groupTO.getUserOwner() != null) {
+ UserTO user = null;
+ try {
+ user = userRestClient.read(groupTO.getUserOwner());
+ } catch (Exception e) {
+ LOG.warn("Could not find user with id {}, ignoring", groupTO.getUserOwner(), e);
+ }
+ if (user == null) {
+ groupTO.setUserOwner(null);
+ } else {
+ object = user.getKey() + " " + user.getUsername();
+ }
+ }
+ break;
+
+ case GROUP:
+ GroupTO group = null;
+ if (groupTO.getGroupOwner() != null) {
+ try {
+ group = groupRestClient.read(groupTO.getGroupOwner());
+ } catch (Exception e) {
+ LOG.warn("Could not find group with id {}, ignoring", groupTO.getGroupOwner(), e);
+ }
+ if (group == null) {
+ groupTO.setGroupOwner(null);
+ } else {
+ object = group.getDisplayName();
+ }
+ }
+ break;
+
+ case MEMBERSHIP:
+ default:
+ }
+
+ return object;
+ }
+
+ @Override
+ public void setObject(final Object object) {
+ switch (type) {
+ case USER:
+ groupTO.setUserOwner((Long) object);
+ break;
+
+ case GROUP:
+ groupTO.setGroupOwner((Long) object);
+ break;
+
+ case MEMBERSHIP:
+ default:
+ }
+ }
+
+ @Override
+ public void detach() {
+ // ignore
+ }
+ }
+
+ private class ParentModel implements IModel {
+
+ private static final long serialVersionUID = 1006546156848990721L;
+
+ private final GroupTO groupTO;
+
+ public ParentModel(final GroupTO groupTO) {
+ this.groupTO = groupTO;
+ }
+
+ @Override
+ public Object getObject() {
+ Object object = null;
+ if (groupTO.getParent() != 0) {
+ GroupTO parent = null;
+ try {
+ parent = groupRestClient.read(groupTO.getParent());
+ } catch (Exception e) {
+ LOG.warn("Could not find group with id {}, ignoring", groupTO.getParent(), e);
+ }
+ if (parent == null) {
+ groupTO.setParent(0);
+ } else {
+ object = parent.getDisplayName();
+ }
+ }
+ return object;
+ }
+
+ @Override
+ public void setObject(final Object object) {
+ groupTO.setParent((object instanceof Long) ? ((Long) object) : 0);
+ }
+
+ @Override
+ public void detach() {
+ // ignore
+ }
+ }
+
+ public static class UserOwnerSelectPayload {
+
+ private final Long userId;
+
+ public UserOwnerSelectPayload(final Long userId) {
+ this.userId = userId;
+ }
+
+ public Long getUserId() {
+ return userId;
+ }
+ }
+
+ public static class GroupOwnerSelectPayload {
+
+ private final Long groupId;
+
+ public GroupOwnerSelectPayload(final Long groupId) {
+ this.groupId = groupId;
+ }
+
+ public Long getGroupId() {
+ return groupId;
+ }
+ }
+
+ public static class ParentSelectPayload {
+
+ private final Long groupId;
+
+ public ParentSelectPayload(final Long groupId) {
+ this.groupId = groupId;
+ }
+
+ public Long getGroupId() {
+ return groupId;
+ }
+ }
+}
[35/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/ActionLinksPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/ActionLinksPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/ActionLinksPanel.java
deleted file mode 100644
index 35e4a65..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/ActionLinksPanel.java
+++ /dev/null
@@ -1,586 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.markup.html.form;
-
-import org.apache.syncope.client.console.commons.XMLRolesReader;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.IndicatingOnConfirmAjaxLink;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.markup.html.panel.Fragment;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-/**
- * This empty class must exist because there not seems to be alternative to provide specialized HTML for edit links.
- */
-public class ActionLinksPanel extends Panel {
-
- private static final long serialVersionUID = 322966537010107771L;
-
- /**
- * Role reader for authorizations management.
- */
- @SpringBean
- protected XMLRolesReader xmlRolesReader;
-
- private final PageReference pageRef;
-
- public ActionLinksPanel(final String componentId, final IModel<?> model, final PageReference pageRef) {
- super(componentId, model);
- this.pageRef = pageRef;
-
- super.add(new Fragment("panelClaim", "emptyFragment", this));
- super.add(new Fragment("panelManageResources", "emptyFragment", this));
- super.add(new Fragment("panelManageUsers", "emptyFragment", this));
- super.add(new Fragment("panelManageGroups", "emptyFragment", this));
- super.add(new Fragment("panelCreate", "emptyFragment", this));
- super.add(new Fragment("panelEdit", "emptyFragment", this));
- super.add(new Fragment("panelReset", "emptyFragment", this));
- super.add(new Fragment("panelUserTemplate", "emptyFragment", this));
- super.add(new Fragment("panelGroupTemplate", "emptyFragment", this));
- super.add(new Fragment("panelEnable", "emptyFragment", this));
- super.add(new Fragment("panelSearch", "emptyFragment", this));
- super.add(new Fragment("panelDelete", "emptyFragment", this));
- super.add(new Fragment("panelExecute", "emptyFragment", this));
- super.add(new Fragment("panelDryRun", "emptyFragment", this));
- super.add(new Fragment("panelSelect", "emptyFragment", this));
- super.add(new Fragment("panelExport", "emptyFragment", this));
- super.add(new Fragment("panelSuspend", "emptyFragment", this));
- super.add(new Fragment("panelReactivate", "emptyFragment", this));
- super.add(new Fragment("panelReload", "emptyFragment", this));
- super.add(new Fragment("panelChangeView", "emptyFragment", this));
- super.add(new Fragment("panelUnlink", "emptyFragment", this));
- super.add(new Fragment("panelLink", "emptyFragment", this));
- super.add(new Fragment("panelUnassign", "emptyFragment", this));
- super.add(new Fragment("panelAssign", "emptyFragment", this));
- super.add(new Fragment("panelDeprovision", "emptyFragment", this));
- super.add(new Fragment("panelProvision", "emptyFragment", this));
- }
-
- public void add(
- final ActionLink link, final ActionLink.ActionType type, final String pageId, final String actionId) {
-
- addWithRoles(link, type, xmlRolesReader.getEntitlement(pageId, actionId), true);
- }
-
- public void add(
- final ActionLink link, final ActionLink.ActionType type, final String pageId) {
-
- add(link, type, pageId, true);
- }
-
- public void add(
- final ActionLink link, final ActionLink.ActionType type, final String pageId, final boolean enabled) {
-
- addWithRoles(link, type, xmlRolesReader.getEntitlement(pageId, type.getActionId()), enabled);
- }
-
- public void addWithRoles(
- final ActionLink link, final ActionLink.ActionType type, final String roles) {
-
- addWithRoles(link, type, roles, true);
- }
-
- public void addWithRoles(
- final ActionLink link, final ActionLink.ActionType type, final String roles, final boolean enabled) {
-
- Fragment fragment = null;
-
- switch (type) {
-
- case CLAIM:
- fragment = new Fragment("panelClaim", "fragmentClaim", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("claimLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case MANAGE_RESOURCES:
- fragment = new Fragment("panelManageResources", "fragmentManageResources", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("manageResourcesLink", pageRef) {
-
- private static final long serialVersionUID = -6957616042924610291L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case MANAGE_USERS:
- fragment = new Fragment("panelManageUsers", "fragmentManageUsers", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("manageUsersLink", pageRef) {
-
- private static final long serialVersionUID = -6957616042924610292L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case MANAGE_GROUPS:
- fragment = new Fragment("panelManageGroups", "fragmentManageGroups", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("manageGroupsLink", pageRef) {
-
- private static final long serialVersionUID = -6957616042924610293L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case CREATE:
- fragment = new Fragment("panelCreate", "fragmentCreate", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("createLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case RESET:
- fragment = new Fragment("panelReset", "fragmentReset", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("resetLink", pageRef) {
-
- private static final long serialVersionUID = -6957616042924610290L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- });
- break;
-
- case EDIT:
- fragment = new Fragment("panelEdit", "fragmentEdit", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("editLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case USER_TEMPLATE:
- fragment = new Fragment("panelUserTemplate", "fragmentUserTemplate", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("userTemplateLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case GROUP_TEMPLATE:
- fragment = new Fragment("panelGroupTemplate", "fragmentGroupTemplate", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("groupTemplateLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case ENABLE:
- fragment = new Fragment("panelEnable", "fragmentEnable", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("enableLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case SEARCH:
- fragment = new Fragment("panelSearch", "fragmentSearch", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("searchLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case EXECUTE:
- fragment = new Fragment("panelExecute", "fragmentExecute", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("executeLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case DRYRUN:
- fragment = new Fragment("panelDryRun", "fragmentDryRun", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("dryRunLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case DELETE:
- fragment = new Fragment("panelDelete", "fragmentDelete", this);
-
- fragment.addOrReplace(new IndicatingOnConfirmAjaxLink<Void>("deleteLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
-
- break;
-
- case SELECT:
- fragment = new Fragment("panelSelect", "fragmentSelect", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("selectLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
-
- break;
-
- case EXPORT:
- fragment = new Fragment("panelExport", "fragmentExport", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("exportLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case SUSPEND:
- fragment = new Fragment("panelSuspend", "fragmentSuspend", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("suspendLink", pageRef) {
-
- private static final long serialVersionUID = -6957616042924610291L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case REACTIVATE:
- fragment = new Fragment("panelReactivate", "fragmentReactivate", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("reactivateLink", pageRef) {
-
- private static final long serialVersionUID = -6957616042924610292L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case RELOAD:
- fragment = new Fragment("panelReload", "fragmentReload", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("reloadLink", pageRef) {
-
- private static final long serialVersionUID = -6957616042924610293L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case CHANGE_VIEW:
- fragment = new Fragment("panelChangeView", "fragmentChangeView", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("changeViewLink", pageRef) {
-
- private static final long serialVersionUID = -6957616042924610292L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case UNLINK:
- fragment = new Fragment("panelUnlink", "fragmentUnlink", this);
-
- fragment.addOrReplace(
- new IndicatingOnConfirmAjaxLink<Void>("unlinkLink", pageRef, "confirmUnlink") {
-
- private static final long serialVersionUID = -6957616042924610293L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case LINK:
- fragment = new Fragment("panelLink", "fragmentLink", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("linkLink", pageRef) {
-
- private static final long serialVersionUID = -6957616042924610303L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case UNASSIGN:
- fragment = new Fragment("panelUnassign", "fragmentUnassign", this);
-
- fragment.addOrReplace(
- new IndicatingOnConfirmAjaxLink<Void>("unassignLink", pageRef, "confirmUnassign") {
-
- private static final long serialVersionUID = -6957616042924610294L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case ASSIGN:
- fragment = new Fragment("panelAssign", "fragmentAssign", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("assignLink", pageRef) {
-
- private static final long serialVersionUID = -6957616042924610304L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case DEPROVISION:
- fragment = new Fragment("panelDeprovision", "fragmentDeprovision", this);
-
- fragment.addOrReplace(
- new IndicatingOnConfirmAjaxLink<Void>("deprovisionLink", pageRef, "confirmDeprovision") {
-
- private static final long serialVersionUID = -6957616042924610295L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
-
- case PROVISION:
- fragment = new Fragment("panelProvision", "fragmentProvision", this);
-
- fragment.addOrReplace(new ClearIndicatingAjaxLink<Void>("provisionLink", pageRef) {
-
- private static final long serialVersionUID = -6957616042924610305L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- link.onClick(target);
- }
- }.feedbackPanelAutomaticReload(link.feedbackPanelAutomaticReload()));
- break;
- default:
- // do nothing
- }
-
- if (fragment != null) {
- fragment.setEnabled(enabled);
- MetaDataRoleAuthorizationStrategy.authorize(fragment, ENABLE, roles);
- super.addOrReplace(fragment);
- }
- }
-
- public void remove(final ActionLink.ActionType type) {
- switch (type) {
- case CLAIM:
- super.addOrReplace(new Fragment("panelClaim", "emptyFragment", this));
- break;
-
- case MANAGE_RESOURCES:
- super.addOrReplace(new Fragment("panelManageResources", "emptyFragment", this));
- break;
-
- case MANAGE_USERS:
- super.addOrReplace(new Fragment("panelManageUsers", "emptyFragment", this));
- break;
-
- case MANAGE_GROUPS:
- super.addOrReplace(new Fragment("panelManageGroups", "emptyFragment", this));
- break;
-
- case CREATE:
- super.addOrReplace(new Fragment("panelCreate", "emptyFragment", this));
- break;
-
- case EDIT:
- super.addOrReplace(new Fragment("panelEdit", "emptyFragment", this));
- break;
-
- case USER_TEMPLATE:
- super.addOrReplace(new Fragment("panelUserTemplate", "emptyFragment", this));
- break;
-
- case SEARCH:
- super.addOrReplace(new Fragment("panelSearch", "emptyFragment", this));
- break;
-
- case EXECUTE:
- super.addOrReplace(new Fragment("panelExecute", "emptyFragment", this));
- break;
-
- case DRYRUN:
- super.addOrReplace(new Fragment("panelDryRun", "emptyFragment", this));
- break;
-
- case DELETE:
- super.addOrReplace(new Fragment("panelDelete", "emptyFragment", this));
- break;
-
- case SELECT:
- super.addOrReplace(new Fragment("panelSelect", "emptyFragment", this));
- break;
-
- case EXPORT:
- super.addOrReplace(new Fragment("panelExport", "emptyFragment", this));
- break;
-
- case SUSPEND:
- super.addOrReplace(new Fragment("panelSuspend", "emptyFragment", this));
- break;
-
- case REACTIVATE:
- super.addOrReplace(new Fragment("panelReactivate", "emptyFragment", this));
- break;
-
- case RELOAD:
- super.addOrReplace(new Fragment("panelReload", "emptyFragment", this));
- break;
-
- case CHANGE_VIEW:
- super.addOrReplace(new Fragment("panelChangeView", "emptyFragment", this));
- break;
-
- case UNLINK:
- super.addOrReplace(new Fragment("panelUnlink", "emptyFragment", this));
- break;
-
- case LINK:
- super.addOrReplace(new Fragment("panelLink", "emptyFragment", this));
- break;
-
- case UNASSIGN:
- super.addOrReplace(new Fragment("panelUnassign", "emptyFragment", this));
- break;
-
- case ASSIGN:
- super.addOrReplace(new Fragment("panelAssign", "emptyFragment", this));
- break;
-
- case DEPROVISION:
- super.addOrReplace(new Fragment("panelDeprovision", "emptyFragment", this));
- break;
-
- case PROVISION:
- super.addOrReplace(new Fragment("panelProvision", "emptyFragment", this));
- break;
- default:
- // do nothing
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPalettePanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPalettePanel.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPalettePanel.java
index 91b6306..932948b 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPalettePanel.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPalettePanel.java
@@ -20,7 +20,6 @@ package org.apache.syncope.client.console.wicket.markup.html.form;
import java.util.Collection;
import java.util.List;
-import org.apache.syncope.client.console.commons.SelectChoiceRenderer;
import org.apache.wicket.extensions.markup.html.form.palette.Palette;
import org.apache.wicket.markup.html.form.IChoiceRenderer;
import org.apache.wicket.model.IModel;
@@ -55,7 +54,7 @@ public class AjaxPalettePanel<T> extends AbstractFieldPanel<List<T>> {
protected Palette<T> createPalette(final IModel<List<T>> model, final ListModel<T> choices,
final IChoiceRenderer<T> renderer, final boolean allowOrder, final boolean allowMoveAll) {
- return new NonI18nPalette<T>("paletteField", model, choices, renderer, 8, allowOrder, allowMoveAll);
+ return new NonI18nPalette<>("paletteField", model, choices, renderer, 8, allowOrder, allowMoveAll);
}
@Override
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPasswordFieldPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPasswordFieldPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPasswordFieldPanel.java
index 14fdf9e..2eb11ea 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPasswordFieldPanel.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/AjaxPasswordFieldPanel.java
@@ -33,7 +33,7 @@ public class AjaxPasswordFieldPanel extends FieldPanel<String> {
super(id, model);
field = new PasswordTextField("passwordField", model);
- add(field.setLabel(new Model<String>(name)).setRequired(false).setOutputMarkupId(true));
+ add(field.setLabel(new Model<>(name)).setRequired(false).setOutputMarkupId(true));
if (!isReadOnly()) {
field.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/SelectChoiceRenderer.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/SelectChoiceRenderer.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/SelectChoiceRenderer.java
new file mode 100644
index 0000000..0c79e14
--- /dev/null
+++ b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/SelectChoiceRenderer.java
@@ -0,0 +1,40 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import org.apache.wicket.markup.html.form.IChoiceRenderer;
+
+public class SelectChoiceRenderer<T> implements IChoiceRenderer<T> {
+
+ private static final long serialVersionUID = -3242441544405909243L;
+
+ @Override
+ public Object getDisplayValue(T obj) {
+ if (obj instanceof SelectOption) {
+ return ((SelectOption) obj).getDisplayValue();
+ } else {
+ return obj.toString();
+ }
+ }
+
+ @Override
+ public String getIdValue(T obj, int i) {
+ return obj.toString();
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/SelectOption.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/SelectOption.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/SelectOption.java
new file mode 100644
index 0000000..c667657
--- /dev/null
+++ b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/SelectOption.java
@@ -0,0 +1,72 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.wicket.markup.html.form;
+
+import java.io.Serializable;
+import org.apache.commons.lang3.builder.HashCodeBuilder;
+
+public class SelectOption implements Serializable {
+
+ private static final long serialVersionUID = 2961127533930849828L;
+
+ private String displayValue;
+
+ private String keyValue;
+
+ public SelectOption(final String displayValue, final String keyValue) {
+ this.displayValue = displayValue;
+ this.keyValue = keyValue;
+ }
+
+ public String getDisplayValue() {
+ return displayValue;
+ }
+
+ public void setDisplayValue(final String displayValue) {
+ this.displayValue = displayValue;
+ }
+
+ public String getKeyValue() {
+ return keyValue;
+ }
+
+ public void setKeyValue(final String keyValue) {
+ this.keyValue = keyValue;
+ }
+
+ @Override
+ public boolean equals(final Object obj) {
+ if (obj == null || !(obj instanceof SelectOption)) {
+ return false;
+ }
+
+ return (keyValue == null && ((SelectOption) obj).keyValue == null) || keyValue != null
+ && keyValue.equals(((SelectOption) obj).keyValue);
+ }
+
+ @Override
+ public int hashCode() {
+ return HashCodeBuilder.reflectionHashCode(this);
+ }
+
+ @Override
+ public String toString() {
+ return keyValue;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryCertPreviewer.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryCertPreviewer.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryCertPreviewer.java
index 61589d7..20f2a7b 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryCertPreviewer.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryCertPreviewer.java
@@ -24,7 +24,7 @@ import java.security.cert.X509Certificate;
import javax.naming.ldap.LdapName;
import javax.naming.ldap.Rdn;
import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.BinaryPreview;
+import org.apache.syncope.client.console.annotations.BinaryPreview;
import org.apache.wicket.Component;
import org.apache.wicket.markup.html.basic.Label;
import org.apache.wicket.model.Model;
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryImagePreviewer.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryImagePreviewer.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryImagePreviewer.java
index 35e442e..488caf0 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryImagePreviewer.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryImagePreviewer.java
@@ -18,7 +18,7 @@
*/
package org.apache.syncope.client.console.wicket.markup.html.form.preview;
-import org.apache.syncope.client.console.BinaryPreview;
+import org.apache.syncope.client.console.annotations.BinaryPreview;
import org.apache.wicket.Component;
import org.apache.wicket.extensions.markup.html.image.resource.ThumbnailImageResource;
import org.apache.wicket.markup.html.image.NonCachingImage;
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/link/VeilPopupSettings.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/link/VeilPopupSettings.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/link/VeilPopupSettings.java
deleted file mode 100644
index 51c8ec5..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/link/VeilPopupSettings.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.markup.html.link;
-
-import org.apache.wicket.markup.html.link.PopupSettings;
-
-public class VeilPopupSettings extends PopupSettings {
-
- private static final long serialVersionUID = -2727046117490858226L;
-
- @Override
- public String getPopupJavaScript() {
- return "document.getElementById('veil').style.display = 'block';" + super.getPopupJavaScript();
- }
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/DefaultMutableTreeNodeExpansion.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/DefaultMutableTreeNodeExpansion.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/DefaultMutableTreeNodeExpansion.java
deleted file mode 100644
index fa962bc..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/DefaultMutableTreeNodeExpansion.java
+++ /dev/null
@@ -1,160 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.markup.html.tree;
-
-import java.io.Serializable;
-import java.util.Collection;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.Set;
-import javax.swing.tree.DefaultMutableTreeNode;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.wicket.MetaDataKey;
-import org.apache.wicket.Session;
-
-public class DefaultMutableTreeNodeExpansion implements Set<DefaultMutableTreeNode>, Serializable {
-
- private static final long serialVersionUID = -2864060875425661224L;
-
- private static MetaDataKey<DefaultMutableTreeNodeExpansion> KEY =
- new MetaDataKey<DefaultMutableTreeNodeExpansion>() {
-
- private static final long serialVersionUID = 3109256773218160485L;
-
- };
-
- private Set<Long> ids = new HashSet<Long>();
-
- private boolean inverse;
-
- public void expandAll() {
- ids.clear();
-
- inverse = true;
- }
-
- public void collapseAll() {
- ids.clear();
-
- inverse = false;
- }
-
- @Override
- public boolean add(final DefaultMutableTreeNode node) {
- GroupTO groupTO = (GroupTO) node.getUserObject();
- boolean isAdded;
- if (inverse) {
- isAdded = ids.remove(groupTO.getKey());
- } else {
- isAdded = ids.add(groupTO.getKey());
- }
- return isAdded;
- }
-
- @Override
- public boolean remove(final Object object) {
- DefaultMutableTreeNode node = (DefaultMutableTreeNode) object;
- GroupTO groupTO = (GroupTO) node.getUserObject();
- boolean isRemoved;
- if (inverse) {
- isRemoved = ids.add(groupTO.getKey());
- } else {
- isRemoved = ids.remove(groupTO.getKey());
- }
- return isRemoved;
- }
-
- @Override
- public boolean contains(final Object object) {
- DefaultMutableTreeNode node = (DefaultMutableTreeNode) object;
- GroupTO groupTO = (GroupTO) node.getUserObject();
- boolean isContained;
- if (inverse) {
- isContained = !ids.contains(groupTO.getKey());
- } else {
- isContained = ids.contains(groupTO.getKey());
- }
- return isContained;
- }
-
- @Override
- public void clear() {
- throw new UnsupportedOperationException();
- }
-
- @Override
- public int size() {
- throw new UnsupportedOperationException();
- }
-
- @Override
- public boolean isEmpty() {
- throw new UnsupportedOperationException();
- }
-
- @Override
- public <A> A[] toArray(final A[] a) {
- throw new UnsupportedOperationException();
- }
-
- @Override
- public Iterator<DefaultMutableTreeNode> iterator() {
- throw new UnsupportedOperationException();
- }
-
- @Override
- public Object[] toArray() {
- throw new UnsupportedOperationException();
- }
-
- @Override
- public boolean containsAll(Collection<?> c) {
- throw new UnsupportedOperationException();
- }
-
- @Override
- public boolean addAll(Collection<? extends DefaultMutableTreeNode> c) {
- throw new UnsupportedOperationException();
- }
-
- @Override
- public boolean retainAll(Collection<?> c) {
- throw new UnsupportedOperationException();
- }
-
- @Override
- public boolean removeAll(Collection<?> c) {
- throw new UnsupportedOperationException();
- }
-
- /**
- * Get the expansion for the session.
- *
- * @return expansion
- */
- public static DefaultMutableTreeNodeExpansion get() {
- DefaultMutableTreeNodeExpansion expansion = Session.get().getMetaData(KEY);
- if (expansion == null) {
- expansion = new DefaultMutableTreeNodeExpansion();
-
- Session.get().setMetaData(KEY, expansion);
- }
- return expansion;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/DefaultMutableTreeNodeExpansionModel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/DefaultMutableTreeNodeExpansionModel.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/DefaultMutableTreeNodeExpansionModel.java
deleted file mode 100644
index 1b342bd..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/DefaultMutableTreeNodeExpansionModel.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.markup.html.tree;
-
-import java.util.Set;
-
-import javax.swing.tree.DefaultMutableTreeNode;
-
-import org.apache.wicket.model.AbstractReadOnlyModel;
-
-public class DefaultMutableTreeNodeExpansionModel
- extends AbstractReadOnlyModel<Set<DefaultMutableTreeNode>> {
-
- private static final long serialVersionUID = -3407581132184748054L;
-
- @Override
- public Set<DefaultMutableTreeNode> getObject() {
- return DefaultMutableTreeNodeExpansion.get();
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupPanel.java
deleted file mode 100644
index 0638a73..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupPanel.java
+++ /dev/null
@@ -1,121 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.markup.html.tree;
-
-import javax.swing.tree.DefaultMutableTreeNode;
-import org.apache.syncope.client.console.commons.GroupTreeBuilder;
-import org.apache.syncope.client.console.commons.XMLRolesReader;
-import org.apache.syncope.client.console.pages.Groups.TreeNodeClickUpdate;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.wicket.Component;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.event.Broadcast;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.extensions.markup.html.repeater.tree.DefaultNestedTree;
-import org.apache.wicket.extensions.markup.html.repeater.tree.ITreeProvider;
-import org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree;
-import org.apache.wicket.extensions.markup.html.repeater.tree.content.Folder;
-import org.apache.wicket.extensions.markup.html.repeater.tree.theme.WindowsTheme;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class TreeGroupPanel extends Panel {
-
- private static final long serialVersionUID = 1762003213871836869L;
-
- @SpringBean
- private GroupTreeBuilder groupTreeBuilder;
-
- @SpringBean
- private XMLRolesReader xmlRolesReader;
-
- private WebMarkupContainer treeContainer;
-
- private NestedTree<DefaultMutableTreeNode> tree;
-
- public TreeGroupPanel(final String id) {
- super(id);
-
- treeContainer = new WebMarkupContainer("treeContainer");
- treeContainer.setOutputMarkupId(true);
- add(treeContainer);
- updateTree();
- }
-
- private void updateTree() {
- final ITreeProvider<DefaultMutableTreeNode> treeProvider = new TreeGroupProvider(groupTreeBuilder, true);
- final DefaultMutableTreeNodeExpansionModel treeModel = new DefaultMutableTreeNodeExpansionModel();
-
- tree = new DefaultNestedTree<DefaultMutableTreeNode>("treeTable", treeProvider, treeModel) {
-
- private static final long serialVersionUID = 7137658050662575546L;
-
- @Override
- protected Component newContentComponent(final String id, final IModel<DefaultMutableTreeNode> node) {
- final DefaultMutableTreeNode treeNode = node.getObject();
- final GroupTO groupTO = (GroupTO) treeNode.getUserObject();
-
- return new Folder<DefaultMutableTreeNode>(id, TreeGroupPanel.this.tree, node) {
-
- private static final long serialVersionUID = 9046323319920426493L;
-
- @Override
- protected boolean isClickable() {
- return true;
- }
-
- @Override
- protected IModel<?> newLabelModel(final IModel<DefaultMutableTreeNode> model) {
- return new Model<>(groupTO.getDisplayName());
- }
-
- @Override
- protected void onClick(final AjaxRequestTarget target) {
- super.onClick(target);
-
- send(getPage(), Broadcast.BREADTH, new TreeNodeClickUpdate(target, groupTO.getKey()));
- }
- };
- }
- };
- tree.add(new WindowsTheme());
- tree.setOutputMarkupId(true);
-
- DefaultMutableTreeNodeExpansion.get().expandAll();
-
- MetaDataRoleAuthorizationStrategy.authorize(tree, ENABLE, xmlRolesReader.getEntitlement("Groups", "read"));
-
- treeContainer.addOrReplace(tree);
- }
-
- @Override
- public void onEvent(final IEvent<?> event) {
- super.onEvent(event);
-
- if (event.getPayload() instanceof TreeNodeClickUpdate) {
- final TreeNodeClickUpdate update = (TreeNodeClickUpdate) event.getPayload();
- updateTree();
- update.getTarget().add(treeContainer);
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupProvider.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupProvider.java b/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupProvider.java
deleted file mode 100644
index c0b55c3..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupProvider.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.wicket.markup.html.tree;
-
-import javax.swing.tree.DefaultMutableTreeNode;
-import org.apache.syncope.client.console.commons.GroupTreeBuilder;
-import org.apache.wicket.extensions.markup.html.repeater.util.TreeModelProvider;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-
-public class TreeGroupProvider extends TreeModelProvider<DefaultMutableTreeNode> {
-
- private static final long serialVersionUID = -7741964777100892335L;
-
- public TreeGroupProvider(final GroupTreeBuilder groupTreeBuilder) {
- this(groupTreeBuilder, false);
- }
-
- public TreeGroupProvider(final GroupTreeBuilder groupTreeBuilde, final boolean rootVisible) {
- super(groupTreeBuilde.build(), rootVisible);
- }
-
- @Override
- public IModel<DefaultMutableTreeNode> model(final DefaultMutableTreeNode treeNode) {
- return new Model<DefaultMutableTreeNode>(treeNode);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/bulk.css
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/bulk.css b/client/console/src/main/resources/META-INF/resources/css/bulk.css
deleted file mode 100644
index 1f0e621..0000000
--- a/client/console/src/main/resources/META-INF/resources/css/bulk.css
+++ /dev/null
@@ -1,97 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-th.checkGroupColumn{
- width: 20px;
-}
-
-td.checkGroupColumn{
- text-align: center;
-}
-
-div.bulkAction{
- display:inline-table;
-}
-
-div.bulkActionCell{
- display: table-cell;
- vertical-align: middle;
- text-align: center;
- width: 40px;
- padding-left: 7px;
-}
-
-.pageRowElement{
- display: inline-table;
- width: 95%;
-}
-
-div#selectedObjects{
- text-align: center;
- margin-top: 10px;
-}
-
-div#selectedObjects table {
- margin: 1em 0;
- border-collapse: collapse;
-}
-
-div#selectedObjects table td, div#selectedObjects table th {
- border: 1px solid #eee;
- padding: .6em 10px;
-}
-
-div#actionRow{
- height: 30px;
- overflow: hidden;
- text-align: left;
- margin-top: 10px;
-}
-
-div#actions{
- display: inline-table;
- height: 30px;
- overflow: hidden;
-}
-
-div#actions div#actionPanel{
- display: table-cell;
- height: 30px;
- overflow: hidden;
- cursor: auto;
- background: none;
- padding: 0px 10px;
- vertical-align: middle;
-}
-
-div#actions div#cancelBtmForm{
- display: table-cell;
- height: 30px;
- overflow: hidden;
- vertical-align: middle;
- padding-left: 3px;
-}
-
-div#actions div#cancelBtmForm form{
- padding: 0px;
- margin: 0px;
-}
-
-div#actions div#cancelBtmForm form input#cancel{
- padding: 0.6em 1em;
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/fieldstyle.css
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/fieldstyle.css b/client/console/src/main/resources/META-INF/resources/css/fieldstyle.css
deleted file mode 100644
index 23ef109..0000000
--- a/client/console/src/main/resources/META-INF/resources/css/fieldstyle.css
+++ /dev/null
@@ -1,191 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-.drop_button{
- vertical-align: middle;
-}
-
-.add_button{
- vertical-align: middle;
- margin-left: 6px;
-}
-
-.date_size{
- width: 90px;
-}
-
-.long_dynamicsize{
- width: 80%;
-}
-
-.medium_dynamicsize{
- width: 45%;
-}
-
-.short_dynamicsize{
- width: 35%;
-}
-
-.long_fixedsize{
- width: 500px;
-}
-
-.medium_fixedsize{
- width: 300px;
-}
-
-.short_fixedsize{
- width: 150px;
-}
-
-.veryshort_fixedsize{
- width: 70px;
-}
-
-.all_dynamicsize{
- width: 100%;
-}
-
-div#formtable {
- display: table;
- width: 100%;
-}
-
-div#formtable > span:first-of-type {
- display: table-row-group;
- width: 100%;
-}
-
-div.tablerow {
- display: inline-table;
- padding: 5px;
- width: 99%;
-}
-
-div.tablerow.connectorProp {
- height:22px;
- vertical-align: middle;
- font-size: 12px;
-}
-
-div.tablecolumn_connPropAttr {
- display: table-cell;
- vertical-align: middle;
-}
-
-div.tablerow2 {
- display: inline-table;
- padding: 5px 0px 5px 0px;
- width: 99%;
-}
-
-div.alt {
- background: #eff3ea;
-}
-
-div.tablecolumn_label{
- display: table-cell;
- font-size: 12px;
- vertical-align: middle;
- font-family: Verdana,Tahoma,sans-serif;
- width: 30%;
-}
-
-div.tablecolumn_field{
- display: table-cell;
- vertical-align: middle;
- font-family: Verdana,Tahoma,sans-serif;
- width: 70%;
-}
-
-div.tablecolumn_check{
- display: table-cell;
- margin-right: 5px;
- margin-left: 2px;
- vertical-align: middle;
-}
-
-div.tablecolumn2_label{
- display: table-cell;
- font-size: 12px;
- vertical-align: middle;
- font-family: Verdana,Tahoma,sans-serif;
- padding-left: 5px;
- width: 15%;
-}
-
-div.tablecolumn2_field{
- display: table-cell;
- vertical-align: middle;
- font-family: Verdana,Tahoma,sans-serif;
- width: 35%;
-}
-
-.ui-tabs .ui-tabs-panel {
- background: none repeat scroll 0 0 #FFFFFF;
- border-width: 0;
- display: block;
- overflow: auto;
- padding: 1em 1.4em;
-}
-
-.ui-widget input, .ui-widget select, .ui-widget textarea, .ui-widget button {
- font-family: Verdana,Arial,sans-serif;
- font-size: 12px;
- padding: 2px 4px;
-}
-
-.ui-widget-header {
- border: 1px solid #aaaaaa
- /*{borderColorHeader}*/;
- background: #cccccc
- /*{bgColorHeader}*/
- url(images/ui-bg_highlight-soft_75_cccccc_1x100.png)
- /*{bgImgUrlHeader}*/
- 50%/*{bgHeaderXPos}*/
- 50%/*{bgHeaderYPos}*/
- repeat-x/*{bgHeaderRepeat}*/;
- color: #222222/*{fcHeader}*/;
- font-weight: bold;
- padding: 7px 15px;
-}
-
-.ui-button {
- display: inline-block;
- position: relative;
- margin-right: .1em;
- cursor: pointer;
- text-align: center;
- zoom: 1;
- overflow: visible;
- padding: 7px 15px;
-}
-
-.ui-spinner-button {
- cursor: default;
- display: block;
- font-size: 0.5em;
- height: 50%;
- margin: 0;
- overflow: hidden;
- padding: 0;
- position: absolute;
- right: 0;
- text-align: center;
- width: 16px;
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_diagonals-thick_20_666666_40x40.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_diagonals-thick_20_666666_40x40.png b/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_diagonals-thick_20_666666_40x40.png
deleted file mode 100644
index 64ece57..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_diagonals-thick_20_666666_40x40.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_flat_0_aaaaaa_40x100.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_flat_0_aaaaaa_40x100.png b/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_flat_0_aaaaaa_40x100.png
deleted file mode 100644
index fc9ef06..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_flat_0_aaaaaa_40x100.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_flat_0_aaaaaa_40x100_greennotused.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_flat_0_aaaaaa_40x100_greennotused.png b/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_flat_0_aaaaaa_40x100_greennotused.png
deleted file mode 100644
index b3d1999..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_flat_0_aaaaaa_40x100_greennotused.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_55_fbf9ee_1x400.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_55_fbf9ee_1x400.png b/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_55_fbf9ee_1x400.png
deleted file mode 100644
index ad3d634..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_55_fbf9ee_1x400.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_65_ffffff_1x400.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_65_ffffff_1x400.png b/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_65_ffffff_1x400.png
deleted file mode 100644
index 42ccba2..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_65_ffffff_1x400.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_75_dadada_1x400.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_75_dadada_1x400.png b/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_75_dadada_1x400.png
deleted file mode 100644
index 5a46b47..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_75_dadada_1x400.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_75_e6e6e6_1x400.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_75_e6e6e6_1x400.png b/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_75_e6e6e6_1x400.png
deleted file mode 100644
index 86c2baa..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_75_e6e6e6_1x400.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_95_fef1ec_1x400.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_95_fef1ec_1x400.png b/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_95_fef1ec_1x400.png
deleted file mode 100644
index 4443fdc..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_glass_95_fef1ec_1x400.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100.png b/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100.png
deleted file mode 100644
index 5749fc4..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100_greynotused.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100_greynotused.png b/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100_greynotused.png
deleted file mode 100644
index 7c9fa6c..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100_greynotused.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100_red.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100_red.png b/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100_red.png
deleted file mode 100644
index 4632529..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/css/images/ui-bg_highlight-soft_75_cccccc_1x100_red.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_222222_256x240.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_222222_256x240.png b/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_222222_256x240.png
deleted file mode 100644
index ee039dc..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_222222_256x240.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_2e83ff_256x240.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_2e83ff_256x240.png b/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_2e83ff_256x240.png
deleted file mode 100644
index 45e8928..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_2e83ff_256x240.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_454545_256x240.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_454545_256x240.png b/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_454545_256x240.png
deleted file mode 100644
index 7ec70d1..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_454545_256x240.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_888888_256x240.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_888888_256x240.png b/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_888888_256x240.png
deleted file mode 100644
index 5ba708c..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_888888_256x240.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_cd0a0a_256x240.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_cd0a0a_256x240.png b/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_cd0a0a_256x240.png
deleted file mode 100644
index 7930a55..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/css/images/ui-icons_cd0a0a_256x240.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/css/style.css
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/css/style.css b/client/console/src/main/resources/META-INF/resources/css/style.css
deleted file mode 100644
index 0978141..0000000
--- a/client/console/src/main/resources/META-INF/resources/css/style.css
+++ /dev/null
@@ -1,550 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-body {
- margin: 0px;
- padding: 0px;
- font-family: Verdana, Tahoma, sans-serif;
- color: #333;
- font-size: 62.5%;
-}
-
-/* id */
-#tabs {
- margin: 0px 5px;
- margin-top: 5px;
-}
-#grouptabs {
- margin: 0px 5px;
- margin-top: 5px;
-}
-
-#tabs div {
- /*background-color: #FFF;*/
-}
-
-#logo {
- margin-top: 10px;
- margin-bottom: 6px;
-}
-
-#splash {
- background: url(../img/sf_testa.png) top repeat-x #B9CFB3;
- width: 400px;
- margin-left: auto;
- margin-right: auto;
- margin-top: 100px;
- border: 1px solid #463;
-}
-
-#splash a {
- color: #463;
- text-decoration: none;
- font-size: 14px;
-}
-
-a img {
- border: none;
-}
-
-#splash h2 {
- color: #FFF;
- margin: 0px;
- margin-top: 8px;
- margin-bottom: 20px;
- font-size: 14px;
- text-align: center;
- font-weight: normal;
-}
-
-#splash form {
- margin: 6px auto;
- width: 300px;
- text-align: center;
-}
-
-#splash form label {
- margin-right: 5px;
- display: block;
-}
-
-#splash form label.password {
-}
-
-#splash form input {
- margin-bottom: 15px;
-}
-
-#splash p {
- margin: 6px 16px;
- border-top: 1px solid #463;
- text-align: center;
- padding-top: 8px;
-}
-
-#splash ul {
- height: 320px;
- margin-left: 37px;
- padding-left: 28px;
- margin-top: 25px;
-}
-
-#splash ul li {
- float: left;
- width: 90px;
- text-align: center;
- list-style: none;
- margin: 0px;
-}
-
-input[disabled] {
- background-color: #ddd;
- background-image: none;
-}
-
-select[disabled] {
- background-color: #ddd;
- background-image: none;
-}
-
-#loginFeedbackDiv {
- width: 100%;
-}
-
-#loginFeedbackDiv ul {
- list-style:none outside none;
- margin:0;
- text-align:center;
- width: 100%;
- height: 30px;
- margin-left: 0px;
- padding-left: 0px;
-}
-
-#loginFeedbackDiv ul li{
- border:0 none;
- padding-left: 20px;
- padding: 1%;
- padding-top: 2%;
- list-style:none outside none;
- margin:0;
- text-align:center;
- width: 100%;
-}
-
-#feedbackDiv {
- height: 20px;
- margin: 0px;
- padding: 0px;
-}
-
-#feedbackDiv ul{
- height: 20px !important;
- margin: 0px;
- padding: 0px;
-}
-
-#feedbackDiv li{
- list-style:none outside none;
- margin:0;
- text-align:center;
- width: 100%;
-}
-#feedbackDiv ul li{
- list-style:none outside none;
- margin:0;
- text-align:center;
- width: 100%;
- color: red;
-}
-
-.feedbackPanel {
- padding-left:20pt;
- margin-right:20pt;
-}
-
-#navigationPane {
- background: url(../img/sf_testa.png) top repeat-x #FFF;
-}
-
-#navigationPane a img {
- border: none;
-}
-
-#navigationPane {
- height: 103px;
-}
-
-#navigationPane a {
- color: #FFF;
- text-decoration: none;
-}
-
-#navigationPane a:hover {
- color: #CCC;
-}
-
-#navigationPane ul {
- clear: both;
- padding: 0px;
- margin: 0px;
- margin-left: 280px;
-}
-
-#navigationPane ul li {
- float: left;
- width: 90px;
- text-align: center;
- margin: 0px;
- color: #FFF;
- font-size: 13px;
- list-style: none;
- padding: 1px;
-}
-
-#navigationPane span {
- font-size: 13px;
-}
-
-/* MODAL-FORM */
-div#dialog-form label, div#dialog-form input { display:block; }
-div#dialog-form span.radio label, div#dialog-form span.radio input { margin-top: 4px; margin-bottom: 12px; display:inline; }
-/*div#dialog-form span.checkbox label, div#dialog-form span.checkbox input { margin-top: 4px; margin-bottom: 12px; display:inline; }*/
-div#dialog-form input.text { margin-bottom:12px; width: 95%; padding: .4em; }
-div#dialog-form select.text { margin-bottom:12px; width: auto; padding: .4em; }
-div#dialog-form fieldset { padding:0; border:0; margin-top:25px; }
-div#users-contain { width: 570px; margin-bottom: 20px;}/*width: 350px*/
-div#users-contain table { margin: 1em 0; border-collapse: collapse; width: 100%; }
-div#users-contain table td, div#users-contain table th { border: 1px solid #eee; padding: .6em 10px; }
-div#executions { margin-bottom: 0px;}/*width: 350px*/
-div#executions table { margin: 1em 0; border-collapse: collapse; width: 100%; }
-div#executions table td, div#executions table th { border: 1px solid #eee; padding: .3em 10px; }
-.ui-dialog .ui-state-error { padding: .3em; }
-.validateTips { border: 1px solid transparent; padding: 0.3em; }
-
-/* classi */
-#navigationPane .schema {
- color: #99C;
-}
-
-#navigationPane a img:hover {
- opacity:0.5;
- -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(opacity=50)";
- filter:alpha(opacity=50)
-}
-
-#splash a img:hover {
- opacity:0.5;
- -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(opacity=50)";
- filter:alpha(opacity=50)
-}
-
-#navigationPane .users {
- color: #9C0;
-}
-
-#navigationPane .groups {
- color: #F90;
-}
-
-#navigationPane .resources {
- color: #09F;
-}
-
-#navigationPane .tasks {
- color: #FD0;
-}
-
-#navigationPane .todo {
- color: #F3C98E;
-}
-
-#navigationPane .connectors {
- color: #09F;
-}
-
-#navigationPane .reports {
- color: #F66;
-}
-
-#navigationPane .configuration {
- color: #CCC;
-}
-
-.onerowlabel {
- float: left;
-}
-
-.onerowcheckbox {
- margin-left: 10em;
-}
-
-div#attributes-view label {
- display: block;
- clear: none;
- width: 300px;
- margin-left: 20px;
-}
-
-div#attributes-view input {
- display: block;
- float: left;
- clear: left;
- height: 12px;
- padding: 0;
- margin: 0;
-}
-
-.selectedRow {
- background-color: #eef1f1; /* alternative: LemonChiffon */
-}
-
-/* WICKET DATATABLE HEADERS */
-.headers {
- border: 1px solid #aaaaaa;
- background: #cccccc url(images/ui-bg_highlight-soft_75_cccccc_1x100.png)
- 50% 50% repeat-x;
-}
-
-em {
- font-size: inherit;
- color: gray;
-}
-
-em img {
- opacity:0.4;
- filter:alpha(opacity=40);
-}
-
-th.action{
- width: 140px;
-}
-
-td.action{
- text-align: center;
-}
-
-.navigatorLabel {
- float: left;
-}
-
-.navigator {
- text-align: right;
-}
-
-.group-tree {
- width: 30%;
- display: block;
- float: left;
-}
-
-.groupTable {
- line-height: 1.5em;
-}
-
-.tree-folder-other {
- padding-top: 2px;
- display: block;
- height: 18px;
-}
-
-.tree-folder-open {
- display: block;
- height: 18px;
-}
-
-#versionMP {
- text-align: justify;
- color: #463;
- background: url(../img/sf_testa.png) top repeat-x #B9CFB3;
- border: 1px solid #463;
- padding: 5px;
-}
-
-#versionMP a {
- color: white;
- text-decoration: none;
-}
-
-#versionMP a:hover {
- color: #463;
- text-decoration: none;
-}
-
-a.tooltips {
- position: relative;
- display: inline;
- text-decoration: none;
-}
-
-a.tooltips span {
- position: absolute;
- width:19em;
- color: #000000;
- background: whitesmoke;
- visibility: hidden;
- border-radius: 0px;
- padding: 3px;
-}
-
-a.tooltips span:after {
- position: absolute;
- top: 50%;
- left: 100%;
- margin-top: -8px;
- width: 0;
- height: 0;
-}
-
-a.tooltips span {
- visibility: visible;
- opacity: none;
- right: 100%;
- top: 50%;
- margin-right: 4px;
- margin-top: -11px;
- border: 1px solid black;
- z-index: 1000000;
-}
-
-a.tooltips span a {
- color: #463;
- text-decoration: none;
-}
-
-.tree-junction-expanded {
- display: none;
-}
-
-/* Style for autocomplete field */
-div.wicket-aa {
- font-family: "Lucida Grande","Lucida Sans Unicode",Tahoma,Verdana;
- font-size: 12px;
- background-color: white;
- border-width: 1px;
- border-color: #cccccc;
- border-style: solid;
- padding: 2px;
- margin: 1px 0 0 0;
- text-align:left;
-}
-div.wicket-aa ul {
- list-style:none;
- padding: 2px;
- margin:0;
-}
-div.wicket-aa ul li.selected {
- background-color: #FFFF00;
- padding: 2px;
- margin:0;
-}
-
-.notificationpanel {
- margin: 0px;
- padding: 0px;
- border-radius: 5px;
-}
-
-.notificationpanel_bottom_left {
- bottom: 100px;
- left: 30px;
-}
-
-.notificationpanel_bottom_detail_form {
- top: 540px;
- right: 30px;
-}
-
-.notificationpanel_bottom_right {
- bottom: 100px;
- right: 30px;
-}
-
-.notificationpanel_top_right {
- top: 15px;
- right: 30px;
-}
-
-/* notification panel info style */
-.notificationpanel_border_200 {
- color: green;
- margin: 0px;
- background:url("images/ui-bg_highlight-soft_75_cccccc_1x100.png") repeat-x scroll 50% 50% #CCCCCC;
- -moz-border-radius: 3px;
- -webkit-border-radius: 3px;
- border: 1px solid gray;
- box-shadow: 0px 0px 5px gray;
-}
-
-.notificationpanel_row_INFO {
- list-style-type: none;
- color: green;
-}
-
-.notificationpanel_row_INFO span {
- list-style-type: none;
- color: green;
- background: url("../img/ok.png") no-repeat left;
- border:0 none;
- padding-left: 20px;
-}
-
-/* notification panel warning style */
-.notificationpanel_border_300 {
- border: 1px solid orangered;
- box-shadow: 0px 0px 5px gray;
-}
-
-.notificationpanel_row_WARNING {
- color: orangered;
- list-style-type: none;
- border:0 none;
- padding-left: 20px;
-}
-
-/* notification panel error style */
-.notificationpanel_border_400 {
- color: red;
- -moz-border-radius: 3px;
- -webkit-border-radius: 3px;
- border: 1px solid gray;
- box-shadow: 0px 0px 5px gray;
- border-color: red;
- background-image: -moz-linear-gradient(top, #FF8585 0%, #E60008 100%);
- background-image: -webkit-linear-gradient(top, #FF8585 0%, #E60008 100%);
- background-image: -o-linear-gradient(top, #FF8585 0%, #E60008 100%);
- background-image: -ms-linear-gradient(top, #FF8585 0%, #E60008 100%);
- background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0, #FF8585), color-stop(1, #E60008));
- font-weight: bold;
-}
-
-.notificationpanel_row_ERROR {
- list-style-type: none;
- color: black;
-}
-
-.notificationpanel_row_ERROR span {
- border:0 none;
-}
-pre {
- white-space: -moz-pre-wrap; /* Mozilla, supported since 1999 */
- white-space: -pre-wrap; /* Opera */
- white-space: -o-pre-wrap; /* Opera */
- white-space: pre-wrap; /* CSS3 - Text module (Candidate Recommendation) http://www.w3.org/TR/css3-text/#white-space */
- word-wrap: break-word; /* IE 5.5+ */
-}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/assign-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/assign-icon.png b/client/console/src/main/resources/META-INF/resources/img/actions/assign-icon.png
deleted file mode 100644
index f9f2a33..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/assign-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/both-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/both-icon.png b/client/console/src/main/resources/META-INF/resources/img/actions/both-icon.png
deleted file mode 100644
index 0f98eec..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/both-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/bulk.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/bulk.png b/client/console/src/main/resources/META-INF/resources/img/actions/bulk.png
deleted file mode 100644
index ea6d145..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/bulk.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/claim.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/claim.png b/client/console/src/main/resources/META-INF/resources/img/actions/claim.png
deleted file mode 100644
index 79332c0..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/claim.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/create.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/create.png b/client/console/src/main/resources/META-INF/resources/img/actions/create.png
deleted file mode 100644
index 3f8faf1..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/create.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/delete.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/delete.png b/client/console/src/main/resources/META-INF/resources/img/actions/delete.png
deleted file mode 100644
index 1207d8d..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/delete.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/deprovision-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/deprovision-icon.png b/client/console/src/main/resources/META-INF/resources/img/actions/deprovision-icon.png
deleted file mode 100644
index 4bc2f4e..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/deprovision-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/dryrun.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/dryrun.png b/client/console/src/main/resources/META-INF/resources/img/actions/dryrun.png
deleted file mode 100644
index 910b148..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/dryrun.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/edit.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/edit.png b/client/console/src/main/resources/META-INF/resources/img/actions/edit.png
deleted file mode 100644
index 80e00db..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/edit.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/enable.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/enable.png b/client/console/src/main/resources/META-INF/resources/img/actions/enable.png
deleted file mode 100644
index 39ba0ca..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/enable.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/execute.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/execute.png b/client/console/src/main/resources/META-INF/resources/img/actions/execute.png
deleted file mode 100644
index 443c719..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/execute.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/export.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/export.png b/client/console/src/main/resources/META-INF/resources/img/actions/export.png
deleted file mode 100644
index 038583b..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/export.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/groups-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/groups-icon.png b/client/console/src/main/resources/META-INF/resources/img/actions/groups-icon.png
deleted file mode 100644
index 9669486..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/groups-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/link-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/link-icon.png b/client/console/src/main/resources/META-INF/resources/img/actions/link-icon.png
deleted file mode 100644
index 8c166af..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/link-icon.png and /dev/null differ
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/META-INF/resources/img/actions/manage-icon.png
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/META-INF/resources/img/actions/manage-icon.png b/client/console/src/main/resources/META-INF/resources/img/actions/manage-icon.png
deleted file mode 100644
index 2e8e190..0000000
Binary files a/client/console/src/main/resources/META-INF/resources/img/actions/manage-icon.png and /dev/null differ
[25/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel_pt_BR.properties
deleted file mode 100644
index d4f5693..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/MultiFieldPanel_pt_BR.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-minLength=Tamanho m\u00EDnimo de senha
-maxLength=Tamanho m\u00E1ximo de senha
-historyLength=Tamanho dos hist\u00F3rico de senha
-digitRequired=Senha precisa contar um ou mais d\u00EDgitos
-prefixesNotPermitted=Prefixos de senha n\u00E3o permitidos
-apply=Salvar
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/NonI18nPalette.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/NonI18nPalette.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/NonI18nPalette.html
deleted file mode 100644
index 5800d77..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/NonI18nPalette.html
+++ /dev/null
@@ -1,69 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-<!--
- Licensed to the Apache Software Foundation (ASF) under one or more
- contributor license agreements. See the NOTICE file distributed with
- this work for additional information regarding copyright ownership.
- The ASF licenses this file to You under the Apache License, Version 2.0
- (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
-
- <div style="display: inline-table;">
- <input type="hidden" wicket:id="recorder"/>
-
- <div style="display: table-row">
- <div id="choices" style="display: table-cell; text-align: center; font-weight: bold;">
- <span wicket:id="availableHeader">[available header]</span>
- </div>
-
- <div id="buttons" style="display: table-cell;">
- </div>
-
- <div id="selections" style="display: table-cell; text-align: center; font-weight: bold;">
- <span wicket:id="selectedHeader">[selected header]</span>
- </div>
- </div>
-
- <div style="display: table-row">
- <div id="choices" style="display: table-cell;">
- <select class="choicesSelect" style="min-width: 100px;" wicket:id="choices">[choices]</select>
- </div>
-
- <div id="buttons" style="display: table-cell; width: 30px; text-align: center; vertical-align: middle;">
- <div style="padding-bottom: 2px;">
- <a wicket:id="addAllButton"><img src="img/addAll.png" alt="remove icon"/></a>
- </div>
- <div style="padding-top: 2px; padding-bottom: 2px;">
- <a wicket:id="removeAllButton"><img src="img/removeAll.png" alt="move up icon"/></a>
- </div>
- <div style="padding-top: 2px; padding-bottom: 2px;">
- <a wicket:id="addButton"><img src="img/add.png" alt="add icon"/></a>
- </div>
- <div style="padding-top: 2px; padding-bottom: 2px;">
- <a wicket:id="removeButton"><img src="img/remove.png" alt="remove icon"/></a>
- </div>
- <div style="padding-top: 2px; padding-bottom: 2px;">
- <a wicket:id="moveUpButton"><img src="img/moveUp.png" alt="move up icon"/></a>
- </div>
- <div style="padding-top: 2px;">
- <a wicket:id="moveDownButton"><img src="img/moveDown.png" alt="move down icon"/></a>
- </div>
- </div>
-
- <div id="selections" style="display: table-cell;">
- <select class="selectionSelect" style="min-width: 100px;" wicket:id="selection">[selection]</select>
- </div>
- </div>
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/SpinnerFieldPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/SpinnerFieldPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/SpinnerFieldPanel.html
deleted file mode 100644
index a6f0e51..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/SpinnerFieldPanel.html
+++ /dev/null
@@ -1,29 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <script type="text/javascript" wicket:id="spinnerFieldJS">
- </script>
- <div style="display: inline-table;">
- <div style="display: table-cell;">
- <input wicket:id="spinnerField"/>
- </div>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/preview/AbstractBinaryPreviewer.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/preview/AbstractBinaryPreviewer.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/preview/AbstractBinaryPreviewer.html
deleted file mode 100644
index 81e0797..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/preview/AbstractBinaryPreviewer.html
+++ /dev/null
@@ -1,24 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head></wicket:head>
- <wicket:panel>
- <wicket:child />
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryCertPreviewer.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryCertPreviewer.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryCertPreviewer.html
deleted file mode 100644
index 9733b29..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryCertPreviewer.html
+++ /dev/null
@@ -1,24 +0,0 @@
-<!DOCTYPE html>
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div wicket:id = "certCommonName">[certCommonName]</div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryImagePreviewer.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryImagePreviewer.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryImagePreviewer.html
deleted file mode 100644
index 3b891b0..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/form/preview/BinaryImagePreviewer.html
+++ /dev/null
@@ -1,23 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div><img wicket:id = "previewImage"/></div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupPanel.html
deleted file mode 100644
index 0f202e9..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/wicket/markup/html/tree/TreeGroupPanel.html
+++ /dev/null
@@ -1,25 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div class="groupTable" wicket:id="treeContainer">
- <div wicket:id="treeTable" class="group-tree"/>
- </div>
- </wicket:panel>
-</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/pom.xml
----------------------------------------------------------------------
diff --git a/client/old_console/pom.xml b/client/old_console/pom.xml
new file mode 100644
index 0000000..4b5824b
--- /dev/null
+++ b/client/old_console/pom.xml
@@ -0,0 +1,112 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.apache.syncope</groupId>
+ <artifactId>syncope-client</artifactId>
+ <version>2.0.0-SNAPSHOT</version>
+ </parent>
+
+ <name>Apache Syncope Client OLD Console</name>
+ <description>To keep only until the new console is ready, DOES NOT BUILD</description>
+ <groupId>org.apache.syncope.client</groupId>
+ <artifactId>syncope-client-old_console</artifactId>
+ <packaging>jar</packaging>
+
+ <properties>
+ <rootpom.basedir>${basedir}/../..</rootpom.basedir>
+ </properties>
+
+ <dependencies>
+ <dependency>
+ <groupId>javax.servlet</groupId>
+ <artifactId>javax.servlet-api</artifactId>
+ <scope>provided</scope>
+ </dependency>
+
+ <dependency>
+ <groupId>org.springframework</groupId>
+ <artifactId>spring-web</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.apache.wicket</groupId>
+ <artifactId>wicket</artifactId>
+ <type>pom</type>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.wicket</groupId>
+ <artifactId>wicket-extensions</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.wicket</groupId>
+ <artifactId>wicket-datetime</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.wicket</groupId>
+ <artifactId>wicket-spring</artifactId>
+ <!-- exclude spring framework that wicket pulls in -->
+ <exclusions>
+ <exclusion>
+ <groupId>org.springframework</groupId>
+ <artifactId>spring</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.wicket</groupId>
+ <artifactId>wicket-auth-roles</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.apache.logging.log4j</groupId>
+ <artifactId>log4j-core</artifactId>
+ </dependency>
+
+ <dependency>
+ <groupId>org.apache.syncope.client</groupId>
+ <artifactId>syncope-client-lib</artifactId>
+ <version>${project.version}</version>
+ </dependency>
+ </dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-checkstyle-plugin</artifactId>
+ </plugin>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-pmd-plugin</artifactId>
+ </plugin>
+ </plugins>
+
+ <resources>
+ <resource>
+ <directory>src/main/resources</directory>
+ <filtering>true</filtering>
+ </resource>
+ </resources>
+ </build>
+</project>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/BinaryPreview.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/BinaryPreview.java b/client/old_console/src/main/java/org/apache/syncope/client/console/BinaryPreview.java
new file mode 100644
index 0000000..c499d60
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/BinaryPreview.java
@@ -0,0 +1,34 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console;
+
+import java.lang.annotation.Documented;
+import java.lang.annotation.ElementType;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Target;
+
+@Target({ ElementType.TYPE })
+@Retention(RetentionPolicy.RUNTIME)
+@Documented
+public @interface BinaryPreview {
+
+ public String[] mimeTypes() default {};
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/ExtensionPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/ExtensionPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/ExtensionPanel.java
new file mode 100644
index 0000000..5574926
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/ExtensionPanel.java
@@ -0,0 +1,34 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console;
+
+import java.lang.annotation.Documented;
+import java.lang.annotation.ElementType;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Target;
+
+@Target({ ElementType.TYPE })
+@Retention(RetentionPolicy.RUNTIME)
+@Documented
+public @interface ExtensionPanel {
+
+ public String value();
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/SyncopeApplication.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/SyncopeApplication.java b/client/old_console/src/main/java/org/apache/syncope/client/console/SyncopeApplication.java
new file mode 100644
index 0000000..a1e781d
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/SyncopeApplication.java
@@ -0,0 +1,306 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console;
+
+import java.io.Serializable;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.XMLRolesReader;
+import org.apache.syncope.client.console.pages.Configuration;
+import org.apache.syncope.client.console.pages.InfoModalPage;
+import org.apache.syncope.client.console.pages.Login;
+import org.apache.syncope.client.console.pages.Logout;
+import org.apache.syncope.client.console.pages.Reports;
+import org.apache.syncope.client.console.pages.Resources;
+import org.apache.syncope.client.console.pages.Groups;
+import org.apache.syncope.client.console.pages.Schema;
+import org.apache.syncope.client.console.pages.Tasks;
+import org.apache.syncope.client.console.pages.Todo;
+import org.apache.syncope.client.console.pages.UserSelfModalPage;
+import org.apache.syncope.client.console.pages.Users;
+import org.apache.syncope.client.console.pages.WelcomePage;
+import org.apache.syncope.client.console.resources.FilesystemResource;
+import org.apache.syncope.client.console.resources.WorkflowDefGETResource;
+import org.apache.syncope.client.console.resources.WorkflowDefPUTResource;
+import org.apache.syncope.client.console.rest.UserSelfRestClient;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.Component;
+import org.apache.wicket.Page;
+import org.apache.wicket.RestartResponseAtInterceptPageException;
+import org.apache.wicket.Session;
+import org.apache.wicket.WicketRuntimeException;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.authorization.IUnauthorizedComponentInstantiationListener;
+import org.apache.wicket.authorization.UnauthorizedInstantiationException;
+import org.apache.wicket.authroles.authorization.strategies.role.IRoleCheckingStrategy;
+import org.apache.wicket.authroles.authorization.strategies.role.RoleAuthorizationStrategy;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.WebPage;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.image.Image;
+import org.apache.wicket.markup.html.link.BookmarkablePageLink;
+import org.apache.wicket.protocol.http.WebApplication;
+import org.apache.wicket.request.Request;
+import org.apache.wicket.request.Response;
+import org.apache.wicket.request.resource.ContextRelativeResource;
+import org.apache.wicket.request.resource.IResource;
+import org.apache.wicket.request.resource.ResourceReference;
+import org.apache.wicket.spring.injection.annot.SpringComponentInjector;
+import org.springframework.web.context.support.WebApplicationContextUtils;
+
+/**
+ * SyncopeApplication class.
+ */
+public class SyncopeApplication
+ extends WebApplication
+ implements IUnauthorizedComponentInstantiationListener, IRoleCheckingStrategy, Serializable {
+
+ private static final long serialVersionUID = -2920378752291913495L;
+
+ public static final String IMG_PREFIX = "/img/menu/";
+
+ public static final String IMG_NOTSEL = "notsel/";
+
+ private static final String ACTIVITI_MODELER_CONTEXT = "activiti-modeler";
+
+ private static final int EDIT_PROFILE_WIN_HEIGHT = 550;
+
+ private static final int EDIT_PROFILE_WIN_WIDTH = 800;
+
+ @Override
+ protected void init() {
+ super.init();
+
+ getComponentInstantiationListeners().add(new SpringComponentInjector(this));
+
+ getResourceSettings().setThrowExceptionOnMissingResource(true);
+
+ getSecuritySettings().setAuthorizationStrategy(new RoleAuthorizationStrategy(this));
+ getSecuritySettings().setUnauthorizedComponentInstantiationListener(this);
+
+ getMarkupSettings().setStripWicketTags(true);
+ getMarkupSettings().setCompressWhitespace(true);
+
+ getRequestCycleListeners().add(new SyncopeRequestCycleListener());
+
+ final String activitiModelerDirectory = WebApplicationContextUtils.getWebApplicationContext(
+ WebApplication.get().getServletContext()).getBean("activitiModelerDirectory", String.class);
+ mountResource("/" + ACTIVITI_MODELER_CONTEXT, new ResourceReference(ACTIVITI_MODELER_CONTEXT) {
+
+ private static final long serialVersionUID = -128426276529456602L;
+
+ @Override
+ public IResource getResource() {
+ return new FilesystemResource(ACTIVITI_MODELER_CONTEXT, activitiModelerDirectory);
+ }
+
+ });
+ mountResource("/workflowDefGET", new ResourceReference("workflowDefGET") {
+
+ private static final long serialVersionUID = -128426276529456602L;
+
+ @Override
+ public IResource getResource() {
+ return new WorkflowDefGETResource();
+ }
+ });
+ mountResource("/workflowDefPUT", new ResourceReference("workflowDefPUT") {
+
+ private static final long serialVersionUID = -128426276529456602L;
+
+ @Override
+ public IResource getResource() {
+ return new WorkflowDefPUTResource();
+ }
+ });
+ }
+
+ public void setupNavigationPanel(final WebPage page, final XMLRolesReader xmlRolesReader, final boolean notsel) {
+ final ModalWindow infoModal = new ModalWindow("infoModal");
+ page.add(infoModal);
+ infoModal.setInitialWidth(350);
+ infoModal.setInitialHeight(300);
+ infoModal.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ infoModal.setCookieName("infoModal");
+ infoModal.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new InfoModalPage();
+ }
+ });
+
+ final AjaxLink<Page> infoLink = new AjaxLink<Page>("infoLink") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ infoModal.show(target);
+ }
+ };
+ page.add(infoLink);
+
+ BookmarkablePageLink<Page> schemaLink = new BookmarkablePageLink<>("schema", Schema.class);
+ MetaDataRoleAuthorizationStrategy.authorize(
+ schemaLink, WebPage.ENABLE, xmlRolesReader.getEntitlement("Schema", "list"));
+ page.add(schemaLink);
+ schemaLink.add(new Image("schemaIcon", new ContextRelativeResource(IMG_PREFIX + (notsel
+ ? IMG_NOTSEL
+ : StringUtils.EMPTY) + "schema" + Constants.PNG_EXT)));
+
+ BookmarkablePageLink<Page> usersLink = new BookmarkablePageLink<>("users", Users.class);
+ MetaDataRoleAuthorizationStrategy.authorize(
+ usersLink, WebPage.ENABLE, xmlRolesReader.getEntitlement("Users", "list"));
+ page.add(usersLink);
+ usersLink.add(new Image("usersIcon", new ContextRelativeResource(IMG_PREFIX + (notsel
+ ? IMG_NOTSEL
+ : StringUtils.EMPTY) + "users" + Constants.PNG_EXT)));
+
+ BookmarkablePageLink<Page> groupsLink = new BookmarkablePageLink<>("groups", Groups.class);
+ MetaDataRoleAuthorizationStrategy.authorize(
+ groupsLink, WebPage.ENABLE, xmlRolesReader.getEntitlement("Groups", "list"));
+ page.add(groupsLink);
+ groupsLink.add(new Image("groupsIcon", new ContextRelativeResource(IMG_PREFIX + (notsel
+ ? IMG_NOTSEL
+ : StringUtils.EMPTY) + "groups" + Constants.PNG_EXT)));
+
+ BookmarkablePageLink<Page> resourcesLink = new BookmarkablePageLink<>("resources", Resources.class);
+ MetaDataRoleAuthorizationStrategy.authorize(
+ resourcesLink, WebPage.ENABLE, xmlRolesReader.getEntitlement("Resources", "list"));
+ page.add(resourcesLink);
+ resourcesLink.add(new Image("resourcesIcon", new ContextRelativeResource(IMG_PREFIX + (notsel
+ ? IMG_NOTSEL
+ : StringUtils.EMPTY) + "resources" + Constants.PNG_EXT)));
+
+ BookmarkablePageLink<Page> todoLink = new BookmarkablePageLink<>("todo", Todo.class);
+ MetaDataRoleAuthorizationStrategy.authorize(
+ todoLink, WebPage.ENABLE, xmlRolesReader.getEntitlement("Approval", "list"));
+ page.add(todoLink);
+ todoLink.add(new Image("todoIcon", new ContextRelativeResource(IMG_PREFIX + (notsel
+ ? IMG_NOTSEL
+ : StringUtils.EMPTY) + "todo" + Constants.PNG_EXT)));
+
+ BookmarkablePageLink<Page> reportLink = new BookmarkablePageLink<>("reports", Reports.class);
+ MetaDataRoleAuthorizationStrategy.authorize(
+ reportLink, WebPage.ENABLE, xmlRolesReader.getEntitlement("Reports", "list"));
+ page.add(reportLink);
+ reportLink.add(new Image("reportsIcon", new ContextRelativeResource(IMG_PREFIX + (notsel
+ ? IMG_NOTSEL
+ : StringUtils.EMPTY) + "reports" + Constants.PNG_EXT)));
+
+ BookmarkablePageLink<Page> configurationLink = new BookmarkablePageLink<>("configuration",
+ Configuration.class);
+ MetaDataRoleAuthorizationStrategy.authorize(
+ configurationLink, WebPage.ENABLE, xmlRolesReader.getEntitlement("Configuration", "list"));
+ page.add(configurationLink);
+ configurationLink.add(new Image("configurationIcon", new ContextRelativeResource(IMG_PREFIX + (notsel
+ ? IMG_NOTSEL
+ : StringUtils.EMPTY) + "configuration" + Constants.PNG_EXT)));
+
+ BookmarkablePageLink<Page> taskLink = new BookmarkablePageLink<>("tasks", Tasks.class);
+ MetaDataRoleAuthorizationStrategy.authorize(
+ taskLink, WebPage.ENABLE, xmlRolesReader.getEntitlement("Tasks", "list"));
+ page.add(taskLink);
+ taskLink.add(new Image("tasksIcon", new ContextRelativeResource(IMG_PREFIX + (notsel
+ ? IMG_NOTSEL
+ : StringUtils.EMPTY) + "tasks" + Constants.PNG_EXT)));
+
+ page.add(new BookmarkablePageLink<Page>("logout", Logout.class));
+ }
+
+ public void setupEditProfileModal(final WebPage page, final UserSelfRestClient userSelfRestClient) {
+ // Modal window for editing user profile
+ final ModalWindow editProfileModalWin = new ModalWindow("editProfileModal");
+ editProfileModalWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ editProfileModalWin.setInitialHeight(EDIT_PROFILE_WIN_HEIGHT);
+ editProfileModalWin.setInitialWidth(EDIT_PROFILE_WIN_WIDTH);
+ editProfileModalWin.setCookieName("edit-profile-modal");
+ page.add(editProfileModalWin);
+
+ final AjaxLink<Page> editProfileLink = new AjaxLink<Page>("editProfileLink") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ final UserTO userTO;
+ if (SyncopeSession.get().isAuthenticated()) {
+ try {
+ userTO = userSelfRestClient.read();
+ } catch (Exception e) {
+ throw new WicketRuntimeException(e);
+ }
+ } else {
+ userTO = new UserTO();
+ }
+
+ editProfileModalWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new UserSelfModalPage(page.getPageReference(), editProfileModalWin, userTO);
+ }
+ });
+
+ editProfileModalWin.show(target);
+ }
+ };
+
+ editProfileLink.add(new Label("username", SyncopeSession.get().getUsername()));
+
+ if ("admin".equals(SyncopeSession.get().getUsername())) {
+ editProfileLink.setEnabled(false);
+ }
+
+ page.add(editProfileLink);
+ }
+
+ @Override
+ public Session newSession(final Request request, final Response response) {
+ return new SyncopeSession(request);
+ }
+
+ @Override
+ public Class<? extends Page> getHomePage() {
+ return SyncopeSession.get().isAuthenticated() ? WelcomePage.class : Login.class;
+ }
+
+ @Override
+ public void onUnauthorizedInstantiation(final Component component) {
+ SyncopeSession.get().invalidate();
+
+ if (component instanceof Page) {
+ throw new UnauthorizedInstantiationException(component.getClass());
+ }
+
+ throw new RestartResponseAtInterceptPageException(Login.class);
+ }
+
+ @Override
+ public boolean hasAnyRole(final org.apache.wicket.authroles.authorization.strategies.role.Roles roles) {
+ return SyncopeSession.get().hasAnyRole(roles);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/SyncopeRequestCycleListener.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/SyncopeRequestCycleListener.java b/client/old_console/src/main/java/org/apache/syncope/client/console/SyncopeRequestCycleListener.java
new file mode 100644
index 0000000..8b27260
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/SyncopeRequestCycleListener.java
@@ -0,0 +1,84 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console;
+
+import java.security.AccessControlException;
+import javax.ws.rs.BadRequestException;
+import javax.xml.ws.WebServiceException;
+import org.apache.syncope.client.console.pages.ErrorPage;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.wicket.Page;
+import org.apache.wicket.authorization.UnauthorizedInstantiationException;
+import org.apache.wicket.core.request.handler.PageProvider;
+import org.apache.wicket.core.request.handler.RenderPageRequestHandler;
+import org.apache.wicket.markup.html.pages.ExceptionErrorPage;
+import org.apache.wicket.model.StringResourceModel;
+import org.apache.wicket.protocol.http.PageExpiredException;
+import org.apache.wicket.request.IRequestHandler;
+import org.apache.wicket.request.cycle.AbstractRequestCycleListener;
+import org.apache.wicket.request.cycle.RequestCycle;
+import org.apache.wicket.request.mapper.parameter.PageParameters;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class SyncopeRequestCycleListener extends AbstractRequestCycleListener {
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(SyncopeRequestCycleListener.class);
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public IRequestHandler onException(final RequestCycle cycle, final Exception e) {
+ LOG.error("Exception found", e);
+
+ PageParameters errorParameters = new PageParameters();
+ errorParameters.add("errorTitle", new StringResourceModel("alert", null).getString());
+
+ final Page errorPage;
+ if (e instanceof UnauthorizedInstantiationException) {
+ errorParameters.add("errorMessage",
+ new StringResourceModel("unauthorizedInstantiationException", null).getString());
+
+ errorPage = new ErrorPage(errorParameters);
+ } else if (e.getCause() instanceof AccessControlException) {
+ errorParameters.add("errorMessage", new StringResourceModel("accessControlException", null).getString());
+
+ errorPage = new ErrorPage(errorParameters);
+ } else if (e instanceof PageExpiredException || !(SyncopeSession.get()).isAuthenticated()) {
+ errorParameters.add("errorMessage", new StringResourceModel("pageExpiredException", null).getString());
+
+ errorPage = new ErrorPage(errorParameters);
+ } else if (e.getCause() instanceof BadRequestException || e.getCause() instanceof WebServiceException
+ || e.getCause() instanceof SyncopeClientException) {
+
+ errorParameters.add("errorMessage", new StringResourceModel("restClientException", null).getString());
+
+ errorPage = new ErrorPage(errorParameters);
+ } else {
+ // redirect to default Wicket error page
+ errorPage = new ExceptionErrorPage(e, null);
+ }
+
+ return new RenderPageRequestHandler(new PageProvider(errorPage));
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/SyncopeSession.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/SyncopeSession.java b/client/old_console/src/main/java/org/apache/syncope/client/console/SyncopeSession.java
new file mode 100644
index 0000000..fc7f7b9
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/SyncopeSession.java
@@ -0,0 +1,185 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console;
+
+import java.text.DateFormat;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Locale;
+import java.util.Map;
+import javax.ws.rs.core.EntityTag;
+import javax.ws.rs.core.MediaType;
+import org.apache.commons.lang3.builder.HashCodeBuilder;
+import org.apache.cxf.jaxrs.client.WebClient;
+import org.apache.syncope.client.lib.SyncopeClient;
+import org.apache.syncope.client.lib.SyncopeClientFactoryBean;
+import org.apache.syncope.common.lib.to.SyncopeTO;
+import org.apache.syncope.common.rest.api.service.SyncopeService;
+import org.apache.wicket.Session;
+import org.apache.wicket.authroles.authorization.strategies.role.Roles;
+import org.apache.wicket.protocol.http.WebApplication;
+import org.apache.wicket.protocol.http.WebSession;
+import org.apache.wicket.request.Request;
+import org.springframework.context.ApplicationContext;
+import org.springframework.web.context.support.WebApplicationContextUtils;
+
+/**
+ * Custom Syncope Session class.
+ */
+public class SyncopeSession extends WebSession {
+
+ private static final long serialVersionUID = 7743446298924805872L;
+
+ public static final List<Locale> SUPPORTED_LOCALES = Arrays.asList(new Locale[] {
+ Locale.ENGLISH, Locale.ITALIAN, new Locale("pt", "BR") });
+
+ private String username;
+
+ private String password;
+
+ private String version;
+
+ private Roles roles = new Roles();
+
+ private final SyncopeClientFactoryBean clientFactory;
+
+ private final String anonymousUser;
+
+ private final String anonymousKey;
+
+ private final SyncopeTO syncopeTO;
+
+ private final Map<Integer, SyncopeClient> clients =
+ Collections.synchronizedMap(new HashMap<Integer, SyncopeClient>());
+
+ public static SyncopeSession get() {
+ return (SyncopeSession) Session.get();
+ }
+
+ public SyncopeSession(final Request request) {
+ super(request);
+
+ final ApplicationContext ctx = WebApplicationContextUtils.
+ getWebApplicationContext(WebApplication.get().getServletContext());
+
+ clientFactory = ctx.getBean(SyncopeClientFactoryBean.class).
+ setContentType(SyncopeClientFactoryBean.ContentType.JSON);
+ anonymousUser = ctx.getBean("anonymousUser", String.class);
+ anonymousKey = ctx.getBean("anonymousKey", String.class);
+
+ syncopeTO = clientFactory.create(anonymousUser, anonymousKey).getService(SyncopeService.class).info();
+ }
+
+ public SyncopeTO getSyncopeTO() {
+ return syncopeTO;
+ }
+
+ public void resetClients() {
+ clients.clear();
+ }
+
+ public <T> T getService(final Class<T> service) {
+ return getService(service, this.username, this.password);
+ }
+
+ public <T> T getService(final String etag, final Class<T> service) {
+ T serviceInstance = getService(service, this.username, this.password);
+ WebClient.client(serviceInstance).match(new EntityTag(etag), false);
+
+ return serviceInstance;
+ }
+
+ public <T> void resetClient(final Class<T> service) {
+ T serviceInstance = getService(service, this.username, this.password);
+ WebClient.client(serviceInstance).reset();
+ }
+
+ public <T> T getService(final MediaType mediaType, final Class<T> serviceClass) {
+ T service;
+
+ synchronized (clientFactory) {
+ SyncopeClientFactoryBean.ContentType preType = clientFactory.getContentType();
+
+ clientFactory.setContentType(SyncopeClientFactoryBean.ContentType.fromString(mediaType.toString()));
+ service = clientFactory.create(username, password).getService(serviceClass);
+ clientFactory.setContentType(preType);
+ }
+
+ return service;
+ }
+
+ public <T> T getAnonymousService(final Class<T> serviceClass) {
+ return getService(serviceClass, this.anonymousUser, this.anonymousKey);
+ }
+
+ public <T> T getService(final Class<T> serviceClass, final String username, final String password) {
+ final int clientKey = new HashCodeBuilder().append(username).append(password).toHashCode();
+
+ if (!clients.containsKey(clientKey)) {
+ clients.put(clientKey, clientFactory.create(username, password));
+ }
+
+ return clients.get(clientKey).getService(serviceClass);
+ }
+
+ public String getUsername() {
+ return username;
+ }
+
+ public void setUsername(final String username) {
+ this.username = username;
+ }
+
+ public void setPassword(final String password) {
+ this.password = password;
+ }
+
+ public String getVersion() {
+ return version;
+ }
+
+ public void setVersion(final String version) {
+ this.version = version;
+ }
+
+ public void setEntitlements(final String[] entitlements) {
+ String[] defensiveCopy = entitlements.clone();
+ roles = new Roles(defensiveCopy);
+ }
+
+ public Roles getEntitlements() {
+ return roles;
+ }
+
+ public boolean isAuthenticated() {
+ return getUsername() != null;
+ }
+
+ public boolean hasAnyRole(final Roles roles) {
+ return this.roles.hasAnyRole(roles);
+ }
+
+ public DateFormat getDateFormat() {
+ final Locale locale = getLocale() == null ? Locale.ENGLISH : getLocale();
+
+ return DateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.SHORT, locale);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/ActionTableCheckGroup.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/ActionTableCheckGroup.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/ActionTableCheckGroup.java
new file mode 100644
index 0000000..453e0c0
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/ActionTableCheckGroup.java
@@ -0,0 +1,40 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import java.util.Collection;
+import org.apache.wicket.markup.html.form.CheckGroup;
+import org.apache.wicket.model.IModel;
+
+public class ActionTableCheckGroup<T> extends CheckGroup<T> {
+
+ private static final long serialVersionUID = 1288270558573401394L;
+
+ public ActionTableCheckGroup(final String id, final Collection<T> collection) {
+ super(id, collection);
+ }
+
+ public ActionTableCheckGroup(final String id, final IModel<Collection<T>> model) {
+ super(id, model);
+ }
+
+ public boolean isCheckable(final T element) {
+ return true;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/AttrLayoutType.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/AttrLayoutType.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/AttrLayoutType.java
new file mode 100644
index 0000000..26764b4
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/AttrLayoutType.java
@@ -0,0 +1,105 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import java.util.ArrayList;
+import java.util.List;
+import org.apache.syncope.common.lib.types.AttributableType;
+
+public enum AttrLayoutType {
+
+ ADMIN_USER("admin.user.layout", Mode.ADMIN, AttributableType.USER),
+ SELF_USER("self.user.layout", Mode.SELF, AttributableType.USER),
+ ADMIN_GROUP("admin.group.layout", Mode.ADMIN, AttributableType.GROUP),
+ SELF_GROUP("self.group.layout", Mode.SELF, AttributableType.GROUP),
+ ADMIN_MEMBERSHIP("admin.membership.layout", Mode.ADMIN, AttributableType.MEMBERSHIP),
+ SELF_MEMBERSHIP("self.membership.layout", Mode.SELF, AttributableType.MEMBERSHIP);
+
+ private final String confKey;
+
+ private final Mode mode;
+
+ private final AttributableType attrType;
+
+ AttrLayoutType(final String confKey, final Mode mode, final AttributableType attrType) {
+ this.confKey = confKey;
+ this.mode = mode;
+ this.attrType = attrType;
+ }
+
+ public String getConfKey() {
+ return confKey;
+ }
+
+ public Mode getMode() {
+ return mode;
+ }
+
+ public AttributableType getAttrType() {
+ return attrType;
+ }
+
+ public static List<String> confKeys() {
+ List<String> confKeys = new ArrayList<String>();
+ for (AttrLayoutType value : values()) {
+ confKeys.add(value.getConfKey());
+ }
+
+ return confKeys;
+ }
+
+ public static AttrLayoutType valueOf(final Mode mode, final AttributableType attrType) {
+ AttrLayoutType result = null;
+ if (mode == Mode.ADMIN) {
+ switch (attrType) {
+ case USER:
+ result = ADMIN_USER;
+ break;
+
+ case MEMBERSHIP:
+ result = ADMIN_MEMBERSHIP;
+ break;
+
+ case GROUP:
+ result = ADMIN_GROUP;
+ break;
+
+ default:
+ }
+ } else if (mode == Mode.SELF) {
+ switch (attrType) {
+ case USER:
+ result = SELF_USER;
+ break;
+
+ case MEMBERSHIP:
+ result = SELF_MEMBERSHIP;
+ break;
+
+ case GROUP:
+ result = SELF_GROUP;
+ break;
+
+ default:
+ }
+ }
+
+ return result;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/AttributableDataProvider.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/AttributableDataProvider.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/AttributableDataProvider.java
new file mode 100644
index 0000000..91a797e
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/AttributableDataProvider.java
@@ -0,0 +1,101 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+import org.apache.syncope.client.console.rest.AbstractSubjectRestClient;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.IModel;
+
+public class AttributableDataProvider extends SortableDataProvider<AbstractAttributableTO, String> {
+
+ private static final long serialVersionUID = 6267494272884913376L;
+
+ private final SortableAttributableProviderComparator comparator;
+
+ private String fiql = null;
+
+ private final int paginatorRows;
+
+ private final boolean filtered;
+
+ private final AbstractSubjectRestClient restClient;
+
+ public AttributableDataProvider(final AbstractSubjectRestClient restClient,
+ final int paginatorRows, final boolean filtered) {
+
+ super();
+
+ this.restClient = restClient;
+ this.filtered = filtered;
+ this.paginatorRows = paginatorRows;
+
+ // default sorting
+ setSort("key", SortOrder.ASCENDING);
+
+ this.comparator = new SortableAttributableProviderComparator(this);
+ }
+
+ public void setFIQL(final String fiql) {
+ this.fiql = fiql;
+ }
+
+ @Override
+ public Iterator<? extends AbstractAttributableTO> iterator(final long first, final long count) {
+ List<? extends AbstractAttributableTO> result;
+
+ final int page = ((int) first / paginatorRows);
+
+ if (filtered) {
+ result = fiql == null
+ ? Collections.<AbstractAttributableTO>emptyList()
+ : restClient.search(fiql, (page < 0 ? 0 : page) + 1, paginatorRows, getSort());
+ } else {
+ result = restClient.list((page < 0 ? 0 : page) + 1, paginatorRows, getSort());
+ }
+
+ Collections.sort(result, comparator);
+ return result.iterator();
+ }
+
+ @Override
+ public long size() {
+ long result;
+
+ if (filtered) {
+ result = fiql == null
+ ? 0
+ : restClient.searchCount(fiql);
+ } else {
+ result = restClient.count();
+ }
+
+ return result;
+ }
+
+ @Override
+ public IModel<AbstractAttributableTO> model(final AbstractAttributableTO object) {
+ return new CompoundPropertyModel<>(object);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/CloseOnESCBehavior.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/CloseOnESCBehavior.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/CloseOnESCBehavior.java
new file mode 100644
index 0000000..f3f939c
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/CloseOnESCBehavior.java
@@ -0,0 +1,55 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import org.apache.wicket.Component;
+import org.apache.wicket.ajax.AjaxEventBehavior;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.attributes.AjaxCallListener;
+import org.apache.wicket.ajax.attributes.AjaxRequestAttributes;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+
+public class CloseOnESCBehavior extends AjaxEventBehavior {
+
+ private static final long serialVersionUID = 5826308247642534260L;
+
+ public CloseOnESCBehavior(final String event) {
+ super(event);
+ }
+
+ @Override
+ protected void onEvent(final AjaxRequestTarget target) {
+ ModalWindow.closeCurrent(target);
+ }
+
+ @Override
+ protected void updateAjaxAttributes(final AjaxRequestAttributes attributes) {
+ super.updateAjaxAttributes(attributes);
+
+ attributes.getAjaxCallListeners().add(new AjaxCallListener() {
+
+ private static final long serialVersionUID = 7160235486520935153L;
+
+ @Override
+ public CharSequence getPrecondition(final Component aComponent) {
+ return " if(Wicket.Event.keyCode(attrs.event) != 27){return false;}";
+ }
+ });
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/ConnIdSpecialAttributeName.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/ConnIdSpecialAttributeName.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/ConnIdSpecialAttributeName.java
new file mode 100644
index 0000000..3533172
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/ConnIdSpecialAttributeName.java
@@ -0,0 +1,34 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+public final class ConnIdSpecialAttributeName {
+
+ public static final String ENABLE = "__ENABLE__";
+
+ public static final String NAME = "__NAME__";
+
+ public static final String UID = "__UID__";
+
+ public static final String PASSWORD = "__PASSWORD__";
+
+ private ConnIdSpecialAttributeName() {
+ // private constructor for static utility class
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/Constants.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/Constants.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/Constants.java
new file mode 100644
index 0000000..0b8391a
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/Constants.java
@@ -0,0 +1,110 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+public final class Constants {
+
+ public static final String ON_CLICK = "onclick";
+
+ public static final String ON_CHANGE = "onchange";
+
+ public static final String ON_BLUR = "onblur";
+
+ public static final String PNG_EXT = ".png";
+
+ public static final String FEEDBACK = "feedback";
+
+ public static final String OPERATION_SUCCEEDED = "operation_succeeded";
+
+ public static final String OPERATION_ERROR = "operation_error";
+
+ public static final String SEARCH_ERROR = "search_error";
+
+ public static final String ERROR = "error";
+
+ public static final String PARAM_PASSWORD_RESET_TOKEN = "pwdResetToken";
+
+ public static final String PREF_USERS_DETAILS_VIEW = "users.details.view";
+
+ public static final String PREF_USERS_ATTRIBUTES_VIEW = "users.attributes.view";
+
+ public static final String PREF_USERS_DERIVED_ATTRIBUTES_VIEW = "users.derived.attributes.view";
+
+ public static final String PREF_USERS_VIRTUAL_ATTRIBUTES_VIEW = "users.virtual.attributes.view";
+
+ public static final String PREF_CONF_SCHEMA_PAGINATOR_ROWS = "conf.schema.paginator.rows";
+
+ public static final String PREF_USER_PLAIN_SCHEMA_PAGINATOR_ROWS = "user.schema.paginator.rows";
+
+ public static final String PREF_USER_DER_SCHEMA_PAGINATOR_ROWS = "user.derived.schema.paginator.rows";
+
+ public static final String PREF_USER_VIR_SCHEMA_PAGINATOR_ROWS = "user.virtual.schema.paginator.rows";
+
+ public static final String PREF_GROUP_PLAIN_SCHEMA_PAGINATOR_ROWS = "group.schema.paginator.rows";
+
+ public static final String PREF_GROUP_DER_SCHEMA_PAGINATOR_ROWS = "group.derived.schema.paginator.rows";
+
+ public static final String PREF_GROUP_VIR_SCHEMA_PAGINATOR_ROWS = "group.virtual.schema.paginator.rows";
+
+ public static final String PREF_MEMBERSHIP_PLAIN_SCHEMA_PAGINATOR_ROWS = "membership.schema.paginator.rows";
+
+ public static final String PREF_MEMBERSHIP_DER_SCHEMA_PAGINATOR_ROWS = "membership.derived.aschema.paginator.rows";
+
+ public static final String PREF_MEMBERSHIP_VIR_SCHEMA_PAGINATOR_ROWS = "membership.virtual.aschema.paginator.rows";
+
+ public static final String PREF_USERS_PAGINATOR_ROWS = "users.paginator.rows";
+
+ public static final String PREF_RESOURCES_PAGINATOR_ROWS = "resources.paginator.rows";
+
+ public static final String PREF_CONNECTORS_PAGINATOR_ROWS = "connectors.paginator.rows";
+
+ public static final String PREF_NOTIFICATION_PAGINATOR_ROWS = "notification.paginator.rows";
+
+ public static final String PREF_PROPAGATION_TASKS_PAGINATOR_ROWS = "proagationtasks.paginator.rows";
+
+ public static final String PREF_NOTIFICATION_TASKS_PAGINATOR_ROWS = "notificationtasks.paginator.rows";
+
+ public static final String PREF_SCHED_TASKS_PAGINATOR_ROWS = "schedtasks.paginator.rows";
+
+ public static final String PREF_SYNC_TASKS_PAGINATOR_ROWS = "synctasks.paginator.rows";
+
+ public static final String PREF_TODO_PAGINATOR_ROWS = "todo.paginator.rows";
+
+ public static final String PREF_REPORT_PAGINATOR_ROWS = "report.paginator.rows";
+
+ public static final String PAGEPARAM_CREATE = "CREATE";
+
+ public static final String PAGEPARAM_CURRENT_PAGE = "_current_page";
+
+ public static final String PREF_POLICY_PAGINATOR_ROWS = "policy.paginator.rows";
+
+ /**
+ * ConnId's GuardedString is not in the classpath.
+ */
+ public static final String GUARDED_STRING = "org.identityconnectors.common.security.GuardedString";
+
+ /**
+ * ConnId's GuardedByteArray is not in the classpath.
+ */
+ public static final String GUARDED_BYTE_ARRAY = "org.identityconnectors.common.security.GuardedByteArray";
+
+ private Constants() {
+ // private constructor for static utility class
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/DateFormatROModel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/DateFormatROModel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/DateFormatROModel.java
new file mode 100644
index 0000000..e72b7d0
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/DateFormatROModel.java
@@ -0,0 +1,50 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import java.util.Date;
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.PropertyModel;
+
+public class DateFormatROModel implements IModel<String> {
+
+ private static final long serialVersionUID = 6677274580927636121L;
+
+ private final PropertyModel model;
+
+ public DateFormatROModel(final PropertyModel model) {
+ this.model = model;
+ }
+
+ @Override
+ public String getObject() {
+ return model.getObject() == null
+ ? ""
+ : SyncopeSession.get().getDateFormat().format((Date) model.getObject());
+ }
+
+ @Override
+ public void setObject(final String object) {
+ }
+
+ @Override
+ public void detach() {
+ }
+}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/GroupTreeBuilder.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/GroupTreeBuilder.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/GroupTreeBuilder.java
new file mode 100644
index 0000000..bc7d21b
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/GroupTreeBuilder.java
@@ -0,0 +1,128 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Comparator;
+import java.util.List;
+import javax.swing.tree.DefaultMutableTreeNode;
+import javax.swing.tree.DefaultTreeModel;
+import javax.swing.tree.TreeModel;
+import org.apache.syncope.client.console.rest.GroupRestClient;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.springframework.beans.factory.annotation.Autowired;
+
+public class GroupTreeBuilder {
+
+ @Autowired
+ private GroupRestClient restClient;
+
+ private final GroupTOComparator comparator = new GroupTOComparator();
+
+ private List<GroupTO> allGroups;
+
+ private List<GroupTO> getChildGroups(final long parentGroupId, final List<GroupTO> groups) {
+ List<GroupTO> result = new ArrayList<>();
+ for (GroupTO group : groups) {
+ if (group.getParent() == parentGroupId) {
+ result.add(group);
+ }
+ }
+
+ Collections.sort(result, comparator);
+ return result;
+ }
+
+ private void populateSubtree(final DefaultMutableTreeNode subRoot, final List<GroupTO> groups) {
+ GroupTO group = (GroupTO) subRoot.getUserObject();
+
+ DefaultMutableTreeNode child;
+ for (GroupTO subGroupTO : getChildGroups(group.getKey(), groups)) {
+ child = new DefaultMutableTreeNode(subGroupTO);
+ subRoot.add(child);
+ populateSubtree(child, groups);
+ }
+ }
+
+ public List<GroupTO> getAllGroups() {
+ return this.allGroups;
+ }
+
+ public TreeModel build() {
+ this.allGroups = this.restClient.list();
+ return build(this.allGroups);
+ }
+
+ public TreeModel build(final List<GroupTO> groups) {
+ DefaultMutableTreeNode fakeroot = new DefaultMutableTreeNode(new FakeRootGroupTO());
+
+ populateSubtree(fakeroot, groups);
+
+ return new DefaultTreeModel(fakeroot);
+ }
+
+ public GroupTO findGroup(final long groupKey) {
+ GroupTO found = null;
+ if (getAllGroups() != null) {
+ for (GroupTO groupTO : getAllGroups()) {
+ if (groupTO.getKey() == groupKey) {
+ found = groupTO;
+ }
+ }
+ }
+ return found;
+ }
+
+ private static class GroupTOComparator implements Comparator<GroupTO>, Serializable {
+
+ private static final long serialVersionUID = 7085057398406518811L;
+
+ @Override
+ public int compare(final GroupTO r1, final GroupTO r2) {
+ if (r1.getKey() < r2.getKey()) {
+ return -1;
+ }
+ if (r1.getKey() == r2.getKey()) {
+ return 0;
+ }
+
+ return 1;
+ }
+ }
+
+ private static class FakeRootGroupTO extends GroupTO {
+
+ private static final long serialVersionUID = 4839183625773925488L;
+
+ public FakeRootGroupTO() {
+ super();
+
+ setKey(0);
+ setName("");
+ setParent(-1);
+ }
+
+ @Override
+ public String getDisplayName() {
+ return "";
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/HttpResourceStream.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/HttpResourceStream.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/HttpResourceStream.java
new file mode 100644
index 0000000..feeba85
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/HttpResourceStream.java
@@ -0,0 +1,101 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import java.io.ByteArrayInputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import javax.ws.rs.core.HttpHeaders;
+import javax.ws.rs.core.MediaType;
+import javax.ws.rs.core.Response;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.wicket.util.lang.Bytes;
+import org.apache.wicket.util.resource.AbstractResourceStream;
+import org.apache.wicket.util.resource.IFixedLocationResourceStream;
+import org.apache.wicket.util.resource.ResourceStreamNotFoundException;
+
+public class HttpResourceStream extends AbstractResourceStream implements IFixedLocationResourceStream {
+
+ private static final long serialVersionUID = 5811207817876330189L;
+
+ private transient InputStream inputStream;
+
+ private String contentType;
+
+ private String location;
+
+ private String filename;
+
+ public HttpResourceStream(final Response response) {
+ super();
+
+ Object entity = response.getEntity();
+ if (response.getStatusInfo().getStatusCode() == Response.Status.OK.getStatusCode()
+ && (entity instanceof InputStream)) {
+
+ this.inputStream = (InputStream) entity;
+ this.contentType = response.getHeaderString(HttpHeaders.CONTENT_TYPE);
+ this.location = response.getLocation() == null ? null : response.getLocation().toASCIIString();
+ String contentDisposition = response.getHeaderString(HttpHeaders.CONTENT_DISPOSITION);
+ if (StringUtils.isNotBlank(contentDisposition)) {
+ String[] splitted = contentDisposition.split("=");
+ if (splitted != null && splitted.length > 1) {
+ this.filename = splitted[1].trim();
+ }
+ }
+ }
+ }
+
+ @Override
+ public InputStream getInputStream()
+ throws ResourceStreamNotFoundException {
+
+ return inputStream == null
+ ? new ByteArrayInputStream(new byte[0])
+ : inputStream;
+ }
+
+ @Override
+ public Bytes length() {
+ return inputStream == null
+ ? Bytes.bytes(0)
+ : null;
+ }
+
+ @Override
+ public void close() throws IOException {
+ // No need for explict closing
+ }
+
+ @Override
+ public String locationAsString() {
+ return location;
+ }
+
+ @Override
+ public String getContentType() {
+ return contentType == null
+ ? MediaType.APPLICATION_OCTET_STREAM
+ : contentType;
+ }
+
+ public String getFilename() {
+ return filename;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/JexlHelpUtils.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/JexlHelpUtils.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/JexlHelpUtils.java
new file mode 100644
index 0000000..b29d180
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/JexlHelpUtils.java
@@ -0,0 +1,61 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.link.ExternalLink;
+
+public final class JexlHelpUtils {
+
+ private static final String JEXL_SYNTAX_URL = "http://commons.apache.org/jexl/reference/syntax.html";
+
+ private JexlHelpUtils() {
+ // private constructor for static utility class
+ }
+
+ public static WebMarkupContainer getJexlHelpWebContainer(final String wicketId) {
+ final WebMarkupContainer jexlHelp = new WebMarkupContainer(wicketId);
+ jexlHelp.setVisible(false);
+ jexlHelp.setOutputMarkupPlaceholderTag(true);
+ jexlHelp.setOutputMarkupId(true);
+ jexlHelp.add(new ExternalLink("jexlLink", JEXL_SYNTAX_URL));
+ return jexlHelp;
+ }
+
+ public static AjaxLink<Void> getAjaxLink(final WebMarkupContainer wmc, final String wicketId) {
+ AjaxLink<Void> questionMarkJexlHelp = new AjaxLink<Void>(wicketId) {
+
+ private static final long serialVersionUID = -1838017408000591382L;
+
+ private boolean toogle = false;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ // using bitwise inversion as suggested by
+ // http://pmd.sourceforge.net/pmd-4.2.5/rules/controversial.html#BooleanInversion
+ toogle ^= true;
+ wmc.setVisible(toogle);
+ target.add(wmc);
+ }
+ };
+ return questionMarkJexlHelp;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/MapChoiceRenderer.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/MapChoiceRenderer.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/MapChoiceRenderer.java
new file mode 100644
index 0000000..118db6d
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/MapChoiceRenderer.java
@@ -0,0 +1,43 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import java.util.Map;
+import org.apache.wicket.markup.html.form.IChoiceRenderer;
+
+public class MapChoiceRenderer<T, K> implements IChoiceRenderer<T> {
+
+ private static final long serialVersionUID = -7452881117778186644L;
+
+ private final Map<T, K> map;
+
+ public MapChoiceRenderer(final Map<T, K> map) {
+ this.map = map;
+ }
+
+ @Override
+ public Object getDisplayValue(final T key) {
+ return map.get(key);
+ }
+
+ @Override
+ public String getIdValue(final T key, final int index) {
+ return key.toString();
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/Mode.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/Mode.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/Mode.java
new file mode 100644
index 0000000..27dad64
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/Mode.java
@@ -0,0 +1,27 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+public enum Mode {
+
+ ADMIN,
+ SELF,
+ TEMPLATE;
+
+}
[50/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/SyncopeApplication.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/SyncopeApplication.java b/client/console/src/main/java/org/apache/syncope/client/console/SyncopeApplication.java
deleted file mode 100644
index a1e781d..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/SyncopeApplication.java
+++ /dev/null
@@ -1,306 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console;
-
-import java.io.Serializable;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.XMLRolesReader;
-import org.apache.syncope.client.console.pages.Configuration;
-import org.apache.syncope.client.console.pages.InfoModalPage;
-import org.apache.syncope.client.console.pages.Login;
-import org.apache.syncope.client.console.pages.Logout;
-import org.apache.syncope.client.console.pages.Reports;
-import org.apache.syncope.client.console.pages.Resources;
-import org.apache.syncope.client.console.pages.Groups;
-import org.apache.syncope.client.console.pages.Schema;
-import org.apache.syncope.client.console.pages.Tasks;
-import org.apache.syncope.client.console.pages.Todo;
-import org.apache.syncope.client.console.pages.UserSelfModalPage;
-import org.apache.syncope.client.console.pages.Users;
-import org.apache.syncope.client.console.pages.WelcomePage;
-import org.apache.syncope.client.console.resources.FilesystemResource;
-import org.apache.syncope.client.console.resources.WorkflowDefGETResource;
-import org.apache.syncope.client.console.resources.WorkflowDefPUTResource;
-import org.apache.syncope.client.console.rest.UserSelfRestClient;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.Component;
-import org.apache.wicket.Page;
-import org.apache.wicket.RestartResponseAtInterceptPageException;
-import org.apache.wicket.Session;
-import org.apache.wicket.WicketRuntimeException;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.authorization.IUnauthorizedComponentInstantiationListener;
-import org.apache.wicket.authorization.UnauthorizedInstantiationException;
-import org.apache.wicket.authroles.authorization.strategies.role.IRoleCheckingStrategy;
-import org.apache.wicket.authroles.authorization.strategies.role.RoleAuthorizationStrategy;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.WebPage;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.image.Image;
-import org.apache.wicket.markup.html.link.BookmarkablePageLink;
-import org.apache.wicket.protocol.http.WebApplication;
-import org.apache.wicket.request.Request;
-import org.apache.wicket.request.Response;
-import org.apache.wicket.request.resource.ContextRelativeResource;
-import org.apache.wicket.request.resource.IResource;
-import org.apache.wicket.request.resource.ResourceReference;
-import org.apache.wicket.spring.injection.annot.SpringComponentInjector;
-import org.springframework.web.context.support.WebApplicationContextUtils;
-
-/**
- * SyncopeApplication class.
- */
-public class SyncopeApplication
- extends WebApplication
- implements IUnauthorizedComponentInstantiationListener, IRoleCheckingStrategy, Serializable {
-
- private static final long serialVersionUID = -2920378752291913495L;
-
- public static final String IMG_PREFIX = "/img/menu/";
-
- public static final String IMG_NOTSEL = "notsel/";
-
- private static final String ACTIVITI_MODELER_CONTEXT = "activiti-modeler";
-
- private static final int EDIT_PROFILE_WIN_HEIGHT = 550;
-
- private static final int EDIT_PROFILE_WIN_WIDTH = 800;
-
- @Override
- protected void init() {
- super.init();
-
- getComponentInstantiationListeners().add(new SpringComponentInjector(this));
-
- getResourceSettings().setThrowExceptionOnMissingResource(true);
-
- getSecuritySettings().setAuthorizationStrategy(new RoleAuthorizationStrategy(this));
- getSecuritySettings().setUnauthorizedComponentInstantiationListener(this);
-
- getMarkupSettings().setStripWicketTags(true);
- getMarkupSettings().setCompressWhitespace(true);
-
- getRequestCycleListeners().add(new SyncopeRequestCycleListener());
-
- final String activitiModelerDirectory = WebApplicationContextUtils.getWebApplicationContext(
- WebApplication.get().getServletContext()).getBean("activitiModelerDirectory", String.class);
- mountResource("/" + ACTIVITI_MODELER_CONTEXT, new ResourceReference(ACTIVITI_MODELER_CONTEXT) {
-
- private static final long serialVersionUID = -128426276529456602L;
-
- @Override
- public IResource getResource() {
- return new FilesystemResource(ACTIVITI_MODELER_CONTEXT, activitiModelerDirectory);
- }
-
- });
- mountResource("/workflowDefGET", new ResourceReference("workflowDefGET") {
-
- private static final long serialVersionUID = -128426276529456602L;
-
- @Override
- public IResource getResource() {
- return new WorkflowDefGETResource();
- }
- });
- mountResource("/workflowDefPUT", new ResourceReference("workflowDefPUT") {
-
- private static final long serialVersionUID = -128426276529456602L;
-
- @Override
- public IResource getResource() {
- return new WorkflowDefPUTResource();
- }
- });
- }
-
- public void setupNavigationPanel(final WebPage page, final XMLRolesReader xmlRolesReader, final boolean notsel) {
- final ModalWindow infoModal = new ModalWindow("infoModal");
- page.add(infoModal);
- infoModal.setInitialWidth(350);
- infoModal.setInitialHeight(300);
- infoModal.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- infoModal.setCookieName("infoModal");
- infoModal.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new InfoModalPage();
- }
- });
-
- final AjaxLink<Page> infoLink = new AjaxLink<Page>("infoLink") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- infoModal.show(target);
- }
- };
- page.add(infoLink);
-
- BookmarkablePageLink<Page> schemaLink = new BookmarkablePageLink<>("schema", Schema.class);
- MetaDataRoleAuthorizationStrategy.authorize(
- schemaLink, WebPage.ENABLE, xmlRolesReader.getEntitlement("Schema", "list"));
- page.add(schemaLink);
- schemaLink.add(new Image("schemaIcon", new ContextRelativeResource(IMG_PREFIX + (notsel
- ? IMG_NOTSEL
- : StringUtils.EMPTY) + "schema" + Constants.PNG_EXT)));
-
- BookmarkablePageLink<Page> usersLink = new BookmarkablePageLink<>("users", Users.class);
- MetaDataRoleAuthorizationStrategy.authorize(
- usersLink, WebPage.ENABLE, xmlRolesReader.getEntitlement("Users", "list"));
- page.add(usersLink);
- usersLink.add(new Image("usersIcon", new ContextRelativeResource(IMG_PREFIX + (notsel
- ? IMG_NOTSEL
- : StringUtils.EMPTY) + "users" + Constants.PNG_EXT)));
-
- BookmarkablePageLink<Page> groupsLink = new BookmarkablePageLink<>("groups", Groups.class);
- MetaDataRoleAuthorizationStrategy.authorize(
- groupsLink, WebPage.ENABLE, xmlRolesReader.getEntitlement("Groups", "list"));
- page.add(groupsLink);
- groupsLink.add(new Image("groupsIcon", new ContextRelativeResource(IMG_PREFIX + (notsel
- ? IMG_NOTSEL
- : StringUtils.EMPTY) + "groups" + Constants.PNG_EXT)));
-
- BookmarkablePageLink<Page> resourcesLink = new BookmarkablePageLink<>("resources", Resources.class);
- MetaDataRoleAuthorizationStrategy.authorize(
- resourcesLink, WebPage.ENABLE, xmlRolesReader.getEntitlement("Resources", "list"));
- page.add(resourcesLink);
- resourcesLink.add(new Image("resourcesIcon", new ContextRelativeResource(IMG_PREFIX + (notsel
- ? IMG_NOTSEL
- : StringUtils.EMPTY) + "resources" + Constants.PNG_EXT)));
-
- BookmarkablePageLink<Page> todoLink = new BookmarkablePageLink<>("todo", Todo.class);
- MetaDataRoleAuthorizationStrategy.authorize(
- todoLink, WebPage.ENABLE, xmlRolesReader.getEntitlement("Approval", "list"));
- page.add(todoLink);
- todoLink.add(new Image("todoIcon", new ContextRelativeResource(IMG_PREFIX + (notsel
- ? IMG_NOTSEL
- : StringUtils.EMPTY) + "todo" + Constants.PNG_EXT)));
-
- BookmarkablePageLink<Page> reportLink = new BookmarkablePageLink<>("reports", Reports.class);
- MetaDataRoleAuthorizationStrategy.authorize(
- reportLink, WebPage.ENABLE, xmlRolesReader.getEntitlement("Reports", "list"));
- page.add(reportLink);
- reportLink.add(new Image("reportsIcon", new ContextRelativeResource(IMG_PREFIX + (notsel
- ? IMG_NOTSEL
- : StringUtils.EMPTY) + "reports" + Constants.PNG_EXT)));
-
- BookmarkablePageLink<Page> configurationLink = new BookmarkablePageLink<>("configuration",
- Configuration.class);
- MetaDataRoleAuthorizationStrategy.authorize(
- configurationLink, WebPage.ENABLE, xmlRolesReader.getEntitlement("Configuration", "list"));
- page.add(configurationLink);
- configurationLink.add(new Image("configurationIcon", new ContextRelativeResource(IMG_PREFIX + (notsel
- ? IMG_NOTSEL
- : StringUtils.EMPTY) + "configuration" + Constants.PNG_EXT)));
-
- BookmarkablePageLink<Page> taskLink = new BookmarkablePageLink<>("tasks", Tasks.class);
- MetaDataRoleAuthorizationStrategy.authorize(
- taskLink, WebPage.ENABLE, xmlRolesReader.getEntitlement("Tasks", "list"));
- page.add(taskLink);
- taskLink.add(new Image("tasksIcon", new ContextRelativeResource(IMG_PREFIX + (notsel
- ? IMG_NOTSEL
- : StringUtils.EMPTY) + "tasks" + Constants.PNG_EXT)));
-
- page.add(new BookmarkablePageLink<Page>("logout", Logout.class));
- }
-
- public void setupEditProfileModal(final WebPage page, final UserSelfRestClient userSelfRestClient) {
- // Modal window for editing user profile
- final ModalWindow editProfileModalWin = new ModalWindow("editProfileModal");
- editProfileModalWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- editProfileModalWin.setInitialHeight(EDIT_PROFILE_WIN_HEIGHT);
- editProfileModalWin.setInitialWidth(EDIT_PROFILE_WIN_WIDTH);
- editProfileModalWin.setCookieName("edit-profile-modal");
- page.add(editProfileModalWin);
-
- final AjaxLink<Page> editProfileLink = new AjaxLink<Page>("editProfileLink") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- final UserTO userTO;
- if (SyncopeSession.get().isAuthenticated()) {
- try {
- userTO = userSelfRestClient.read();
- } catch (Exception e) {
- throw new WicketRuntimeException(e);
- }
- } else {
- userTO = new UserTO();
- }
-
- editProfileModalWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new UserSelfModalPage(page.getPageReference(), editProfileModalWin, userTO);
- }
- });
-
- editProfileModalWin.show(target);
- }
- };
-
- editProfileLink.add(new Label("username", SyncopeSession.get().getUsername()));
-
- if ("admin".equals(SyncopeSession.get().getUsername())) {
- editProfileLink.setEnabled(false);
- }
-
- page.add(editProfileLink);
- }
-
- @Override
- public Session newSession(final Request request, final Response response) {
- return new SyncopeSession(request);
- }
-
- @Override
- public Class<? extends Page> getHomePage() {
- return SyncopeSession.get().isAuthenticated() ? WelcomePage.class : Login.class;
- }
-
- @Override
- public void onUnauthorizedInstantiation(final Component component) {
- SyncopeSession.get().invalidate();
-
- if (component instanceof Page) {
- throw new UnauthorizedInstantiationException(component.getClass());
- }
-
- throw new RestartResponseAtInterceptPageException(Login.class);
- }
-
- @Override
- public boolean hasAnyRole(final org.apache.wicket.authroles.authorization.strategies.role.Roles roles) {
- return SyncopeSession.get().hasAnyRole(roles);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/SyncopeConsoleApplication.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/SyncopeConsoleApplication.java b/client/console/src/main/java/org/apache/syncope/client/console/SyncopeConsoleApplication.java
new file mode 100644
index 0000000..d3de8b2
--- /dev/null
+++ b/client/console/src/main/java/org/apache/syncope/client/console/SyncopeConsoleApplication.java
@@ -0,0 +1,60 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console;
+
+import org.apache.syncope.client.console.pages.HomePage;
+import org.apache.wicket.Page;
+import org.apache.wicket.authroles.authentication.AbstractAuthenticatedWebSession;
+import org.apache.wicket.authroles.authentication.AuthenticatedWebApplication;
+import org.apache.wicket.authroles.authentication.pages.SignInPage;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.markup.html.WebPage;
+import org.apache.wicket.spring.injection.annot.SpringComponentInjector;
+
+public class SyncopeConsoleApplication extends AuthenticatedWebApplication {
+
+ @Override
+ protected void init() {
+ super.init();
+
+ getComponentInstantiationListeners().add(new SpringComponentInjector(this));
+ getSecuritySettings().setAuthorizationStrategy(new MetaDataRoleAuthorizationStrategy(this));
+
+ MetaDataRoleAuthorizationStrategy.authorize(getHomePage(), SyncopeConsoleSession.AUTHENTICATED);
+
+ mountPage("/home", HomePage.class);
+ mountPage("/login", SignInPage.class);
+ }
+
+ @Override
+ protected Class<? extends AbstractAuthenticatedWebSession> getWebSessionClass() {
+ return SyncopeConsoleSession.class;
+ }
+
+ @Override
+ protected Class<? extends WebPage> getSignInPageClass() {
+ return SignInPage.class;
+ }
+
+ @Override
+ public Class<? extends Page> getHomePage() {
+ return HomePage.class;
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/SyncopeConsoleSession.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/SyncopeConsoleSession.java b/client/console/src/main/java/org/apache/syncope/client/console/SyncopeConsoleSession.java
new file mode 100644
index 0000000..b63a86a
--- /dev/null
+++ b/client/console/src/main/java/org/apache/syncope/client/console/SyncopeConsoleSession.java
@@ -0,0 +1,179 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console;
+
+import java.text.DateFormat;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Locale;
+import java.util.Map;
+import java.util.Set;
+import javax.ws.rs.core.EntityTag;
+import javax.ws.rs.core.MediaType;
+import org.apache.commons.lang3.tuple.Pair;
+import org.apache.cxf.jaxrs.client.WebClient;
+import org.apache.syncope.client.lib.SyncopeClient;
+import org.apache.syncope.client.lib.SyncopeClientFactoryBean;
+import org.apache.syncope.common.lib.to.SyncopeTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.syncope.common.rest.api.service.SyncopeService;
+import org.apache.wicket.Session;
+import org.apache.wicket.authroles.authentication.AuthenticatedWebSession;
+import org.apache.wicket.authroles.authorization.strategies.role.Roles;
+import org.apache.wicket.protocol.http.WebApplication;
+import org.apache.wicket.request.Request;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.context.ApplicationContext;
+import org.springframework.web.context.support.WebApplicationContextUtils;
+
+public class SyncopeConsoleSession extends AuthenticatedWebSession {
+
+ private static final long serialVersionUID = 747562246415852166L;
+
+ public static final List<Locale> SUPPORTED_LOCALES = Collections.unmodifiableList(Arrays.asList(
+ new Locale[] {
+ Locale.ENGLISH, Locale.ITALIAN, new Locale("pt", "BR")
+ }));
+
+ public static final String AUTHENTICATED = "AUTHENTICATED";
+
+ private static final Logger LOG = LoggerFactory.getLogger(SyncopeConsoleSession.class);
+
+ private final SyncopeClientFactoryBean clientFactory;
+
+ private final String version;
+
+ private final SyncopeTO syncopeTO;
+
+ private final Map<Class<?>, Object> services = Collections.synchronizedMap(new HashMap<Class<?>, Object>());
+
+ private SyncopeClient client;
+
+ private UserTO selfTO;
+
+ private Map<String, Set<String>> auth;
+
+ private Roles roles;
+
+ public static SyncopeConsoleSession get() {
+ return (SyncopeConsoleSession) Session.get();
+ }
+
+ public SyncopeConsoleSession(final Request request) {
+ super(request);
+
+ ApplicationContext ctx = WebApplicationContextUtils.
+ getWebApplicationContext(WebApplication.get().getServletContext());
+
+ clientFactory = ctx.getBean(SyncopeClientFactoryBean.class).
+ setContentType(SyncopeClientFactoryBean.ContentType.JSON);
+ String anonymousUser = ctx.getBean("anonymousUser", String.class);
+ String anonymousKey = ctx.getBean("anonymousKey", String.class);
+
+ version = ctx.getBean("version", String.class);
+
+ syncopeTO = clientFactory.create(anonymousUser, anonymousKey).getService(SyncopeService.class).info();
+ }
+
+ public String getVersion() {
+ return version;
+ }
+
+ public SyncopeTO getSyncopeTO() {
+ return syncopeTO;
+ }
+
+ @Override
+ public boolean authenticate(final String username, final String password) {
+ boolean authenticated = false;
+
+ try {
+ client = clientFactory.create(username, password);
+
+ Pair<Map<String, Set<String>>, UserTO> self = client.self();
+ auth = self.getKey();
+ selfTO = self.getValue();
+
+ authenticated = true;
+ } catch (Exception e) {
+ LOG.error("Authentication failed", e);
+ }
+
+ return authenticated;
+ }
+
+ public UserTO getSelfTO() {
+ return selfTO;
+ }
+
+ @Override
+ public Roles getRoles() {
+ if (isSignedIn() && roles == null && auth != null) {
+ roles = new Roles(auth.keySet().toArray(new String[] {}));
+ roles.add(AUTHENTICATED);
+ }
+
+ return roles;
+ }
+
+ @SuppressWarnings("unchecked")
+ private <T> T getCachedService(final Class<T> serviceClass) {
+ T service;
+ if (services.containsKey(serviceClass)) {
+ service = (T) services.get(serviceClass);
+ } else {
+ service = client.getService(serviceClass);
+ services.put(serviceClass, service);
+ }
+
+ return service;
+ }
+
+ public <T> T getService(final Class<T> serviceClass) {
+ return getCachedService(serviceClass);
+ }
+
+ public <T> T getService(final String etag, final Class<T> serviceClass) {
+ T serviceInstance = getCachedService(serviceClass);
+ WebClient.client(serviceInstance).match(new EntityTag(etag), false);
+
+ return serviceInstance;
+ }
+
+ public <T> T getService(final MediaType mediaType, final Class<T> serviceClass) {
+ T service = client.getService(serviceClass);
+ WebClient.client(service).type(mediaType).accept(mediaType);
+
+ return service;
+ }
+
+ public <T> void resetClient(final Class<T> service) {
+ T serviceInstance = getCachedService(service);
+ WebClient.client(serviceInstance).reset();
+ }
+
+ public DateFormat getDateFormat() {
+ final Locale locale = getLocale() == null ? Locale.ENGLISH : getLocale();
+
+ return DateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.SHORT, locale);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/SyncopeRequestCycleListener.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/SyncopeRequestCycleListener.java b/client/console/src/main/java/org/apache/syncope/client/console/SyncopeRequestCycleListener.java
deleted file mode 100644
index 8b27260..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/SyncopeRequestCycleListener.java
+++ /dev/null
@@ -1,84 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console;
-
-import java.security.AccessControlException;
-import javax.ws.rs.BadRequestException;
-import javax.xml.ws.WebServiceException;
-import org.apache.syncope.client.console.pages.ErrorPage;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.wicket.Page;
-import org.apache.wicket.authorization.UnauthorizedInstantiationException;
-import org.apache.wicket.core.request.handler.PageProvider;
-import org.apache.wicket.core.request.handler.RenderPageRequestHandler;
-import org.apache.wicket.markup.html.pages.ExceptionErrorPage;
-import org.apache.wicket.model.StringResourceModel;
-import org.apache.wicket.protocol.http.PageExpiredException;
-import org.apache.wicket.request.IRequestHandler;
-import org.apache.wicket.request.cycle.AbstractRequestCycleListener;
-import org.apache.wicket.request.cycle.RequestCycle;
-import org.apache.wicket.request.mapper.parameter.PageParameters;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-public class SyncopeRequestCycleListener extends AbstractRequestCycleListener {
-
- /**
- * Logger.
- */
- private static final Logger LOG = LoggerFactory.getLogger(SyncopeRequestCycleListener.class);
-
- /**
- * {@inheritDoc}
- */
- @Override
- public IRequestHandler onException(final RequestCycle cycle, final Exception e) {
- LOG.error("Exception found", e);
-
- PageParameters errorParameters = new PageParameters();
- errorParameters.add("errorTitle", new StringResourceModel("alert", null).getString());
-
- final Page errorPage;
- if (e instanceof UnauthorizedInstantiationException) {
- errorParameters.add("errorMessage",
- new StringResourceModel("unauthorizedInstantiationException", null).getString());
-
- errorPage = new ErrorPage(errorParameters);
- } else if (e.getCause() instanceof AccessControlException) {
- errorParameters.add("errorMessage", new StringResourceModel("accessControlException", null).getString());
-
- errorPage = new ErrorPage(errorParameters);
- } else if (e instanceof PageExpiredException || !(SyncopeSession.get()).isAuthenticated()) {
- errorParameters.add("errorMessage", new StringResourceModel("pageExpiredException", null).getString());
-
- errorPage = new ErrorPage(errorParameters);
- } else if (e.getCause() instanceof BadRequestException || e.getCause() instanceof WebServiceException
- || e.getCause() instanceof SyncopeClientException) {
-
- errorParameters.add("errorMessage", new StringResourceModel("restClientException", null).getString());
-
- errorPage = new ErrorPage(errorParameters);
- } else {
- // redirect to default Wicket error page
- errorPage = new ExceptionErrorPage(e, null);
- }
-
- return new RenderPageRequestHandler(new PageProvider(errorPage));
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/SyncopeSession.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/SyncopeSession.java b/client/console/src/main/java/org/apache/syncope/client/console/SyncopeSession.java
deleted file mode 100644
index fc7f7b9..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/SyncopeSession.java
+++ /dev/null
@@ -1,185 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console;
-
-import java.text.DateFormat;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Locale;
-import java.util.Map;
-import javax.ws.rs.core.EntityTag;
-import javax.ws.rs.core.MediaType;
-import org.apache.commons.lang3.builder.HashCodeBuilder;
-import org.apache.cxf.jaxrs.client.WebClient;
-import org.apache.syncope.client.lib.SyncopeClient;
-import org.apache.syncope.client.lib.SyncopeClientFactoryBean;
-import org.apache.syncope.common.lib.to.SyncopeTO;
-import org.apache.syncope.common.rest.api.service.SyncopeService;
-import org.apache.wicket.Session;
-import org.apache.wicket.authroles.authorization.strategies.role.Roles;
-import org.apache.wicket.protocol.http.WebApplication;
-import org.apache.wicket.protocol.http.WebSession;
-import org.apache.wicket.request.Request;
-import org.springframework.context.ApplicationContext;
-import org.springframework.web.context.support.WebApplicationContextUtils;
-
-/**
- * Custom Syncope Session class.
- */
-public class SyncopeSession extends WebSession {
-
- private static final long serialVersionUID = 7743446298924805872L;
-
- public static final List<Locale> SUPPORTED_LOCALES = Arrays.asList(new Locale[] {
- Locale.ENGLISH, Locale.ITALIAN, new Locale("pt", "BR") });
-
- private String username;
-
- private String password;
-
- private String version;
-
- private Roles roles = new Roles();
-
- private final SyncopeClientFactoryBean clientFactory;
-
- private final String anonymousUser;
-
- private final String anonymousKey;
-
- private final SyncopeTO syncopeTO;
-
- private final Map<Integer, SyncopeClient> clients =
- Collections.synchronizedMap(new HashMap<Integer, SyncopeClient>());
-
- public static SyncopeSession get() {
- return (SyncopeSession) Session.get();
- }
-
- public SyncopeSession(final Request request) {
- super(request);
-
- final ApplicationContext ctx = WebApplicationContextUtils.
- getWebApplicationContext(WebApplication.get().getServletContext());
-
- clientFactory = ctx.getBean(SyncopeClientFactoryBean.class).
- setContentType(SyncopeClientFactoryBean.ContentType.JSON);
- anonymousUser = ctx.getBean("anonymousUser", String.class);
- anonymousKey = ctx.getBean("anonymousKey", String.class);
-
- syncopeTO = clientFactory.create(anonymousUser, anonymousKey).getService(SyncopeService.class).info();
- }
-
- public SyncopeTO getSyncopeTO() {
- return syncopeTO;
- }
-
- public void resetClients() {
- clients.clear();
- }
-
- public <T> T getService(final Class<T> service) {
- return getService(service, this.username, this.password);
- }
-
- public <T> T getService(final String etag, final Class<T> service) {
- T serviceInstance = getService(service, this.username, this.password);
- WebClient.client(serviceInstance).match(new EntityTag(etag), false);
-
- return serviceInstance;
- }
-
- public <T> void resetClient(final Class<T> service) {
- T serviceInstance = getService(service, this.username, this.password);
- WebClient.client(serviceInstance).reset();
- }
-
- public <T> T getService(final MediaType mediaType, final Class<T> serviceClass) {
- T service;
-
- synchronized (clientFactory) {
- SyncopeClientFactoryBean.ContentType preType = clientFactory.getContentType();
-
- clientFactory.setContentType(SyncopeClientFactoryBean.ContentType.fromString(mediaType.toString()));
- service = clientFactory.create(username, password).getService(serviceClass);
- clientFactory.setContentType(preType);
- }
-
- return service;
- }
-
- public <T> T getAnonymousService(final Class<T> serviceClass) {
- return getService(serviceClass, this.anonymousUser, this.anonymousKey);
- }
-
- public <T> T getService(final Class<T> serviceClass, final String username, final String password) {
- final int clientKey = new HashCodeBuilder().append(username).append(password).toHashCode();
-
- if (!clients.containsKey(clientKey)) {
- clients.put(clientKey, clientFactory.create(username, password));
- }
-
- return clients.get(clientKey).getService(serviceClass);
- }
-
- public String getUsername() {
- return username;
- }
-
- public void setUsername(final String username) {
- this.username = username;
- }
-
- public void setPassword(final String password) {
- this.password = password;
- }
-
- public String getVersion() {
- return version;
- }
-
- public void setVersion(final String version) {
- this.version = version;
- }
-
- public void setEntitlements(final String[] entitlements) {
- String[] defensiveCopy = entitlements.clone();
- roles = new Roles(defensiveCopy);
- }
-
- public Roles getEntitlements() {
- return roles;
- }
-
- public boolean isAuthenticated() {
- return getUsername() != null;
- }
-
- public boolean hasAnyRole(final Roles roles) {
- return this.roles.hasAnyRole(roles);
- }
-
- public DateFormat getDateFormat() {
- final Locale locale = getLocale() == null ? Locale.ENGLISH : getLocale();
-
- return DateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.SHORT, locale);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/annotations/BinaryPreview.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/annotations/BinaryPreview.java b/client/console/src/main/java/org/apache/syncope/client/console/annotations/BinaryPreview.java
new file mode 100644
index 0000000..51e22bc
--- /dev/null
+++ b/client/console/src/main/java/org/apache/syncope/client/console/annotations/BinaryPreview.java
@@ -0,0 +1,34 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.annotations;
+
+import java.lang.annotation.Documented;
+import java.lang.annotation.ElementType;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Target;
+
+@Target({ ElementType.TYPE })
+@Retention(RetentionPolicy.RUNTIME)
+@Documented
+public @interface BinaryPreview {
+
+ public String[] mimeTypes() default {};
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/annotations/ExtensionPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/annotations/ExtensionPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/annotations/ExtensionPanel.java
new file mode 100644
index 0000000..26b359f
--- /dev/null
+++ b/client/console/src/main/java/org/apache/syncope/client/console/annotations/ExtensionPanel.java
@@ -0,0 +1,34 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.annotations;
+
+import java.lang.annotation.Documented;
+import java.lang.annotation.ElementType;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Target;
+
+@Target({ ElementType.TYPE })
+@Retention(RetentionPolicy.RUNTIME)
+@Documented
+public @interface ExtensionPanel {
+
+ public String value();
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/commons/ActionTableCheckGroup.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/commons/ActionTableCheckGroup.java b/client/console/src/main/java/org/apache/syncope/client/console/commons/ActionTableCheckGroup.java
deleted file mode 100644
index 453e0c0..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/commons/ActionTableCheckGroup.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.commons;
-
-import java.util.Collection;
-import org.apache.wicket.markup.html.form.CheckGroup;
-import org.apache.wicket.model.IModel;
-
-public class ActionTableCheckGroup<T> extends CheckGroup<T> {
-
- private static final long serialVersionUID = 1288270558573401394L;
-
- public ActionTableCheckGroup(final String id, final Collection<T> collection) {
- super(id, collection);
- }
-
- public ActionTableCheckGroup(final String id, final IModel<Collection<T>> model) {
- super(id, model);
- }
-
- public boolean isCheckable(final T element) {
- return true;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/commons/AttributableDataProvider.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/commons/AttributableDataProvider.java b/client/console/src/main/java/org/apache/syncope/client/console/commons/AttributableDataProvider.java
deleted file mode 100644
index 91a797e..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/commons/AttributableDataProvider.java
+++ /dev/null
@@ -1,101 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.commons;
-
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-import org.apache.syncope.client.console.rest.AbstractSubjectRestClient;
-import org.apache.syncope.common.lib.to.AbstractAttributableTO;
-import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
-import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.IModel;
-
-public class AttributableDataProvider extends SortableDataProvider<AbstractAttributableTO, String> {
-
- private static final long serialVersionUID = 6267494272884913376L;
-
- private final SortableAttributableProviderComparator comparator;
-
- private String fiql = null;
-
- private final int paginatorRows;
-
- private final boolean filtered;
-
- private final AbstractSubjectRestClient restClient;
-
- public AttributableDataProvider(final AbstractSubjectRestClient restClient,
- final int paginatorRows, final boolean filtered) {
-
- super();
-
- this.restClient = restClient;
- this.filtered = filtered;
- this.paginatorRows = paginatorRows;
-
- // default sorting
- setSort("key", SortOrder.ASCENDING);
-
- this.comparator = new SortableAttributableProviderComparator(this);
- }
-
- public void setFIQL(final String fiql) {
- this.fiql = fiql;
- }
-
- @Override
- public Iterator<? extends AbstractAttributableTO> iterator(final long first, final long count) {
- List<? extends AbstractAttributableTO> result;
-
- final int page = ((int) first / paginatorRows);
-
- if (filtered) {
- result = fiql == null
- ? Collections.<AbstractAttributableTO>emptyList()
- : restClient.search(fiql, (page < 0 ? 0 : page) + 1, paginatorRows, getSort());
- } else {
- result = restClient.list((page < 0 ? 0 : page) + 1, paginatorRows, getSort());
- }
-
- Collections.sort(result, comparator);
- return result.iterator();
- }
-
- @Override
- public long size() {
- long result;
-
- if (filtered) {
- result = fiql == null
- ? 0
- : restClient.searchCount(fiql);
- } else {
- result = restClient.count();
- }
-
- return result;
- }
-
- @Override
- public IModel<AbstractAttributableTO> model(final AbstractAttributableTO object) {
- return new CompoundPropertyModel<>(object);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/commons/CloseOnESCBehavior.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/commons/CloseOnESCBehavior.java b/client/console/src/main/java/org/apache/syncope/client/console/commons/CloseOnESCBehavior.java
deleted file mode 100644
index 2e62431..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/commons/CloseOnESCBehavior.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.commons;
-
-import org.apache.wicket.Component;
-import org.apache.wicket.ajax.AjaxEventBehavior;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.attributes.AjaxCallListener;
-import org.apache.wicket.ajax.attributes.AjaxRequestAttributes;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-
-public class CloseOnESCBehavior extends AjaxEventBehavior {
-
- private static final long serialVersionUID = 5826308247642534260L;
-
- public CloseOnESCBehavior(String event) {
- super(event);
- }
-
- @Override
- protected void onEvent(final AjaxRequestTarget target) {
- ModalWindow.closeCurrent(target);
- }
-
- @Override
- protected void updateAjaxAttributes(final AjaxRequestAttributes attributes) {
- super.updateAjaxAttributes(attributes);
-
- attributes.getAjaxCallListeners().add(new AjaxCallListener() {
-
- private static final long serialVersionUID = 7160235486520935153L;
-
- @Override
- public CharSequence getPrecondition(final Component aComponent) {
- return " if(Wicket.Event.keyCode(attrs.event) != 27){return false;}";
- }
- });
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/commons/DateFormatROModel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/commons/DateFormatROModel.java b/client/console/src/main/java/org/apache/syncope/client/console/commons/DateFormatROModel.java
deleted file mode 100644
index e72b7d0..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/commons/DateFormatROModel.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.commons;
-
-import java.util.Date;
-import org.apache.syncope.client.console.SyncopeSession;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.PropertyModel;
-
-public class DateFormatROModel implements IModel<String> {
-
- private static final long serialVersionUID = 6677274580927636121L;
-
- private final PropertyModel model;
-
- public DateFormatROModel(final PropertyModel model) {
- this.model = model;
- }
-
- @Override
- public String getObject() {
- return model.getObject() == null
- ? ""
- : SyncopeSession.get().getDateFormat().format((Date) model.getObject());
- }
-
- @Override
- public void setObject(final String object) {
- }
-
- @Override
- public void detach() {
- }
-}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/commons/GroupTreeBuilder.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/commons/GroupTreeBuilder.java b/client/console/src/main/java/org/apache/syncope/client/console/commons/GroupTreeBuilder.java
deleted file mode 100644
index bc7d21b..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/commons/GroupTreeBuilder.java
+++ /dev/null
@@ -1,128 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.commons;
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.List;
-import javax.swing.tree.DefaultMutableTreeNode;
-import javax.swing.tree.DefaultTreeModel;
-import javax.swing.tree.TreeModel;
-import org.apache.syncope.client.console.rest.GroupRestClient;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.springframework.beans.factory.annotation.Autowired;
-
-public class GroupTreeBuilder {
-
- @Autowired
- private GroupRestClient restClient;
-
- private final GroupTOComparator comparator = new GroupTOComparator();
-
- private List<GroupTO> allGroups;
-
- private List<GroupTO> getChildGroups(final long parentGroupId, final List<GroupTO> groups) {
- List<GroupTO> result = new ArrayList<>();
- for (GroupTO group : groups) {
- if (group.getParent() == parentGroupId) {
- result.add(group);
- }
- }
-
- Collections.sort(result, comparator);
- return result;
- }
-
- private void populateSubtree(final DefaultMutableTreeNode subRoot, final List<GroupTO> groups) {
- GroupTO group = (GroupTO) subRoot.getUserObject();
-
- DefaultMutableTreeNode child;
- for (GroupTO subGroupTO : getChildGroups(group.getKey(), groups)) {
- child = new DefaultMutableTreeNode(subGroupTO);
- subRoot.add(child);
- populateSubtree(child, groups);
- }
- }
-
- public List<GroupTO> getAllGroups() {
- return this.allGroups;
- }
-
- public TreeModel build() {
- this.allGroups = this.restClient.list();
- return build(this.allGroups);
- }
-
- public TreeModel build(final List<GroupTO> groups) {
- DefaultMutableTreeNode fakeroot = new DefaultMutableTreeNode(new FakeRootGroupTO());
-
- populateSubtree(fakeroot, groups);
-
- return new DefaultTreeModel(fakeroot);
- }
-
- public GroupTO findGroup(final long groupKey) {
- GroupTO found = null;
- if (getAllGroups() != null) {
- for (GroupTO groupTO : getAllGroups()) {
- if (groupTO.getKey() == groupKey) {
- found = groupTO;
- }
- }
- }
- return found;
- }
-
- private static class GroupTOComparator implements Comparator<GroupTO>, Serializable {
-
- private static final long serialVersionUID = 7085057398406518811L;
-
- @Override
- public int compare(final GroupTO r1, final GroupTO r2) {
- if (r1.getKey() < r2.getKey()) {
- return -1;
- }
- if (r1.getKey() == r2.getKey()) {
- return 0;
- }
-
- return 1;
- }
- }
-
- private static class FakeRootGroupTO extends GroupTO {
-
- private static final long serialVersionUID = 4839183625773925488L;
-
- public FakeRootGroupTO() {
- super();
-
- setKey(0);
- setName("");
- setParent(-1);
- }
-
- @Override
- public String getDisplayName() {
- return "";
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/commons/JexlHelpUtils.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/commons/JexlHelpUtils.java b/client/console/src/main/java/org/apache/syncope/client/console/commons/JexlHelpUtils.java
deleted file mode 100644
index b29d180..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/commons/JexlHelpUtils.java
+++ /dev/null
@@ -1,61 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.commons;
-
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.link.ExternalLink;
-
-public final class JexlHelpUtils {
-
- private static final String JEXL_SYNTAX_URL = "http://commons.apache.org/jexl/reference/syntax.html";
-
- private JexlHelpUtils() {
- // private constructor for static utility class
- }
-
- public static WebMarkupContainer getJexlHelpWebContainer(final String wicketId) {
- final WebMarkupContainer jexlHelp = new WebMarkupContainer(wicketId);
- jexlHelp.setVisible(false);
- jexlHelp.setOutputMarkupPlaceholderTag(true);
- jexlHelp.setOutputMarkupId(true);
- jexlHelp.add(new ExternalLink("jexlLink", JEXL_SYNTAX_URL));
- return jexlHelp;
- }
-
- public static AjaxLink<Void> getAjaxLink(final WebMarkupContainer wmc, final String wicketId) {
- AjaxLink<Void> questionMarkJexlHelp = new AjaxLink<Void>(wicketId) {
-
- private static final long serialVersionUID = -1838017408000591382L;
-
- private boolean toogle = false;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- // using bitwise inversion as suggested by
- // http://pmd.sourceforge.net/pmd-4.2.5/rules/controversial.html#BooleanInversion
- toogle ^= true;
- wmc.setVisible(toogle);
- target.add(wmc);
- }
- };
- return questionMarkJexlHelp;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/commons/MapChoiceRenderer.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/commons/MapChoiceRenderer.java b/client/console/src/main/java/org/apache/syncope/client/console/commons/MapChoiceRenderer.java
deleted file mode 100644
index 118db6d..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/commons/MapChoiceRenderer.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.commons;
-
-import java.util.Map;
-import org.apache.wicket.markup.html.form.IChoiceRenderer;
-
-public class MapChoiceRenderer<T, K> implements IChoiceRenderer<T> {
-
- private static final long serialVersionUID = -7452881117778186644L;
-
- private final Map<T, K> map;
-
- public MapChoiceRenderer(final Map<T, K> map) {
- this.map = map;
- }
-
- @Override
- public Object getDisplayValue(final T key) {
- return map.get(key);
- }
-
- @Override
- public String getIdValue(final T key, final int index) {
- return key.toString();
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/commons/PreferenceManager.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/commons/PreferenceManager.java b/client/console/src/main/java/org/apache/syncope/client/console/commons/PreferenceManager.java
deleted file mode 100644
index a4e246e..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/commons/PreferenceManager.java
+++ /dev/null
@@ -1,176 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.commons;
-
-import com.fasterxml.jackson.databind.ObjectMapper;
-import com.fasterxml.jackson.core.type.TypeReference;
-import java.io.IOException;
-import java.io.StringWriter;
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-import org.apache.commons.lang3.math.NumberUtils;
-import org.apache.wicket.request.Request;
-import org.apache.wicket.request.Response;
-import org.apache.wicket.util.cookies.CookieDefaults;
-import org.apache.wicket.util.cookies.CookieUtils;
-import org.apache.wicket.util.crypt.Base64;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.springframework.util.StringUtils;
-
-public class PreferenceManager {
-
- /**
- * Logger.
- */
- private static final Logger LOG = LoggerFactory.getLogger(PreferenceManager.class);
-
- private static final String PREFMAN_KEY = "prefMan";
-
- private static final int ONE_YEAR_TIME = 60 * 60 * 24 * 365;
-
- private static final TypeReference<Map<String, String>> MAP_TYPE_REF = new TypeReference<Map<String, String>>() {
- };
-
- private static final List<Integer> PAGINATOR_CHOICES = Arrays.asList(new Integer[] { 10, 25, 50 });
-
- private final ObjectMapper mapper;
-
- private final CookieUtils cookieUtils;
-
- public PreferenceManager() {
- this.mapper = new ObjectMapper();
-
- CookieDefaults cookieDefaults = new CookieDefaults();
- cookieDefaults.setMaxAge(ONE_YEAR_TIME);
- this.cookieUtils = new CookieUtils(cookieDefaults);
- }
-
- public List<Integer> getPaginatorChoices() {
- return PAGINATOR_CHOICES;
- }
-
- private Map<String, String> getPrefs(final String value) {
- Map<String, String> prefs;
- try {
- if (StringUtils.hasText(value)) {
- prefs = mapper.readValue(value, MAP_TYPE_REF);
- } else {
- throw new Exception("Invalid cookie value '" + value + "'");
- }
- } catch (Exception e) {
- LOG.debug("No preferences found", e);
- prefs = new HashMap<String, String>();
- }
-
- return prefs;
- }
-
- private String setPrefs(final Map<String, String> prefs) throws IOException {
- StringWriter writer = new StringWriter();
- mapper.writeValue(writer, prefs);
-
- return writer.toString();
- }
-
- public String get(final Request request, final String key) {
- String result = null;
-
- String prefString = cookieUtils.load(PREFMAN_KEY);
- if (prefString != null) {
- final Map<String, String> prefs = getPrefs(new String(Base64.decodeBase64(prefString.getBytes())));
- result = prefs.get(key);
- }
-
- return result;
- }
-
- public Integer getPaginatorRows(final Request request, final String key) {
- Integer result = getPaginatorChoices().get(0);
-
- String value = get(request, key);
- if (value != null) {
- result = NumberUtils.toInt(value, 10);
- }
-
- return result;
- }
-
- public List<String> getList(final Request request, final String key) {
- final List<String> result = new ArrayList<String>();
-
- final String compound = get(request, key);
-
- if (StringUtils.hasText(compound)) {
- String[] items = compound.split(";");
- result.addAll(Arrays.asList(items));
- }
-
- return result;
- }
-
- public void set(final Request request, final Response response, final Map<String, List<String>> prefs) {
- Map<String, String> current = new HashMap<>();
-
- String prefString = cookieUtils.load(PREFMAN_KEY);
- if (prefString != null) {
- current.putAll(getPrefs(new String(Base64.decodeBase64(prefString.getBytes()))));
- }
-
- // after retrieved previous setting in order to overwrite the key ...
- for (Map.Entry<String, List<String>> entry : prefs.entrySet()) {
- current.put(entry.getKey(), StringUtils.collectionToDelimitedString(entry.getValue(), ";"));
- }
-
- try {
- cookieUtils.save(PREFMAN_KEY, new String(Base64.encodeBase64(setPrefs(current).getBytes())));
- } catch (IOException e) {
- LOG.error("Could not save {} info: {}", getClass().getSimpleName(), current, e);
- }
- }
-
- public void set(final Request request, final Response response, final String key, final String value) {
- String prefString = cookieUtils.load(PREFMAN_KEY);
-
- final Map<String, String> current = new HashMap<>();
- if (prefString != null) {
- current.putAll(getPrefs(new String(Base64.decodeBase64(prefString.getBytes()))));
- }
-
- // after retrieved previous setting in order to overwrite the key ...
- current.put(key, value);
-
- try {
- cookieUtils.save(PREFMAN_KEY, new String(Base64.encodeBase64(setPrefs(current).getBytes())));
- } catch (IOException e) {
- LOG.error("Could not save {} info: {}", getClass().getSimpleName(), current, e);
- }
- }
-
- public void setList(final Request request, final Response response, final String key, final List<String> values) {
- set(request, response, key, StringUtils.collectionToDelimitedString(values, ";"));
- }
-
- public void setList(final Request request, final Response response, final Map<String, List<String>> prefs) {
- set(request, response, prefs);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/commons/SchemaModalPageFactory.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/commons/SchemaModalPageFactory.java b/client/console/src/main/java/org/apache/syncope/client/console/commons/SchemaModalPageFactory.java
deleted file mode 100644
index 38a60fa..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/commons/SchemaModalPageFactory.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.commons;
-
-import org.apache.syncope.client.console.pages.AbstractSchemaModalPage;
-import org.apache.syncope.client.console.pages.DerSchemaModalPage;
-import org.apache.syncope.client.console.pages.PlainSchemaModalPage;
-import org.apache.syncope.client.console.pages.VirSchemaModalPage;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.syncope.common.lib.types.SchemaType;
-
-public final class SchemaModalPageFactory {
-
- private static final long serialVersionUID = -3533177688264693505L;
-
- private SchemaModalPageFactory() {
- // empty constructor for static utility class
- }
-
- @SuppressWarnings("unchecked")
- public static <T extends AbstractSchemaModalPage> T getSchemaModalPage(
- final AttributableType entity, final SchemaType schemaType) {
-
- T page;
-
- switch (schemaType) {
- case DERIVED:
- page = (T) new DerSchemaModalPage(entity);
- break;
-
- case VIRTUAL:
- page = (T) new VirSchemaModalPage(entity);
- break;
-
- default:
- page = (T) new PlainSchemaModalPage(entity);
- break;
- }
-
- return page;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/commons/SelectChoiceRenderer.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/commons/SelectChoiceRenderer.java b/client/console/src/main/java/org/apache/syncope/client/console/commons/SelectChoiceRenderer.java
deleted file mode 100644
index 7b9164d..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/commons/SelectChoiceRenderer.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.commons;
-
-import org.apache.wicket.markup.html.form.IChoiceRenderer;
-
-public class SelectChoiceRenderer<T> implements IChoiceRenderer<T> {
-
- private static final long serialVersionUID = -3242441544405909243L;
-
- @Override
- public Object getDisplayValue(T obj) {
- if (obj instanceof SelectOption) {
- return ((SelectOption) obj).getDisplayValue();
- } else {
- return obj.toString();
- }
- }
-
- @Override
- public String getIdValue(T obj, int i) {
- return obj.toString();
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/commons/SelectOption.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/commons/SelectOption.java b/client/console/src/main/java/org/apache/syncope/client/console/commons/SelectOption.java
deleted file mode 100644
index 839df70..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/commons/SelectOption.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.commons;
-
-import java.io.Serializable;
-import org.apache.commons.lang3.builder.HashCodeBuilder;
-
-public class SelectOption implements Serializable {
-
- private static final long serialVersionUID = 2961127533930849828L;
-
- private String displayValue;
-
- private String keyValue;
-
- public SelectOption(final String displayValue, final String keyValue) {
- this.displayValue = displayValue;
- this.keyValue = keyValue;
- }
-
- public String getDisplayValue() {
- return displayValue;
- }
-
- public void setDisplayValue(final String displayValue) {
- this.displayValue = displayValue;
- }
-
- public String getKeyValue() {
- return keyValue;
- }
-
- public void setKeyValue(final String keyValue) {
- this.keyValue = keyValue;
- }
-
- @Override
- public boolean equals(final Object obj) {
- if (obj == null || !(obj instanceof SelectOption)) {
- return false;
- }
-
- return (keyValue == null && ((SelectOption) obj).keyValue == null) || keyValue != null
- && keyValue.equals(((SelectOption) obj).keyValue);
- }
-
- @Override
- public int hashCode() {
- return HashCodeBuilder.reflectionHashCode(this);
- }
-
- @Override
- public String toString() {
- return keyValue;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/commons/XMLRolesReader.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/commons/XMLRolesReader.java b/client/console/src/main/java/org/apache/syncope/client/console/commons/XMLRolesReader.java
deleted file mode 100644
index 3a0b446..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/commons/XMLRolesReader.java
+++ /dev/null
@@ -1,118 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.commons;
-
-import java.util.HashMap;
-import java.util.Map;
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.commons.lang3.tuple.ImmutablePair;
-import org.apache.commons.lang3.tuple.Pair;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.w3c.dom.Document;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-
-/**
- * XMLRolesReader singleton class.
- */
-public class XMLRolesReader {
-
- /**
- * Logger.
- */
- private static final Logger LOG = LoggerFactory.getLogger(XMLRolesReader.class);
-
- private String authorizations;
-
- private Map<Pair<String, String>, String> authMap;
-
- public void setAuthorizations(final String authorizations) {
- this.authorizations = authorizations;
- }
-
- private void init() {
- authMap = new HashMap<Pair<String, String>, String>();
-
- DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
- dbf.setNamespaceAware(true);
- try {
- DocumentBuilder db = dbf.newDocumentBuilder();
- Document doc = db.parse(getClass().getResource("/" + authorizations).openStream());
- doc.getDocumentElement().normalize();
-
- Node authNode = null;
- NodeList root = doc.getChildNodes();
- for (int i = 0; i < root.getLength() && authNode == null; i++) {
- if ("auth".equals(root.item(i).getNodeName())) {
- authNode = root.item(i);
- }
- }
- if (authNode == null) {
- throw new IllegalArgumentException("Could not find root <auth> node");
- }
-
- NodeList pages = authNode.getChildNodes();
- for (int i = 0; i < pages.getLength(); i++) {
- if ("page".equals(pages.item(i).getNodeName())) {
- String page = pages.item(i).getAttributes().getNamedItem("id").getTextContent();
-
- NodeList actions = pages.item(i).getChildNodes();
- for (int j = 0; j < actions.getLength(); j++) {
- if ("action".equals(actions.item(j).getNodeName())) {
- String action = actions.item(j).getAttributes().getNamedItem("id").getTextContent();
-
- NodeList entitlements = actions.item(j).getChildNodes();
- for (int k = 0; k < entitlements.getLength(); k++) {
- if ("entitlement".equals(entitlements.item(k).getNodeName())) {
- String entitlement = entitlements.item(k).getTextContent();
- authMap.put(new ImmutablePair<String, String>(page, action), entitlement);
- }
- }
- }
- }
- }
- }
- } catch (Exception e) {
- LOG.error("While initializing parsing of {}", authorizations, e);
- }
- }
-
- /**
- * Get entitlement required for page / action.
- *
- * @param pageId page
- * @param actionId action
- * @return entitlement required
- */
- public String getEntitlement(final String pageId, final String actionId) {
- synchronized (this) {
- if (authMap == null) {
- init();
- }
- }
-
- Pair<String, String> key = new ImmutablePair<String, String>(pageId, actionId);
- return authMap.containsKey(key)
- ? authMap.get(key)
- : StringUtils.EMPTY;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/commons/status/AbstractStatusBeanProvider.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/commons/status/AbstractStatusBeanProvider.java b/client/console/src/main/java/org/apache/syncope/client/console/commons/status/AbstractStatusBeanProvider.java
index c10f55c..799b243 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/commons/status/AbstractStatusBeanProvider.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/commons/status/AbstractStatusBeanProvider.java
@@ -36,7 +36,7 @@ public abstract class AbstractStatusBeanProvider extends SortableDataProvider<St
public AbstractStatusBeanProvider(final String sort) {
//Default sorting
setSort(sort, SortOrder.ASCENDING);
- comparator = new SortableDataProviderComparator<StatusBean>(this);
+ comparator = new SortableDataProviderComparator<>(this);
}
@Override
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/commons/status/StatusBean.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/commons/status/StatusBean.java b/client/console/src/main/java/org/apache/syncope/client/console/commons/status/StatusBean.java
index 47d0086..1e92898 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/commons/status/StatusBean.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/commons/status/StatusBean.java
@@ -43,7 +43,7 @@ public class StatusBean implements Serializable {
private boolean linked = true;
- public StatusBean(final AbstractAttributableTO attributable, String resourceName) {
+ public StatusBean(final AbstractAttributableTO attributable, final String resourceName) {
this.attributableKey = attributable.getKey();
this.attributableName = attributable instanceof UserTO
? ((UserTO) attributable).getUsername() : ((GroupTO) attributable).getName();
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/commons/status/StatusUtils.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/commons/status/StatusUtils.java b/client/console/src/main/java/org/apache/syncope/client/console/commons/status/StatusUtils.java
index 391d202..7a4a157 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/commons/status/StatusUtils.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/commons/status/StatusUtils.java
@@ -22,13 +22,11 @@ import java.io.Serializable;
import java.util.ArrayList;
import java.util.Collection;
import java.util.Collections;
-import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
import org.apache.syncope.client.console.commons.ConnIdSpecialAttributeName;
import org.apache.syncope.client.console.commons.Constants;
import org.apache.syncope.client.console.panels.ImagePanel;
-import org.apache.syncope.client.console.panels.StatusPanel;
import org.apache.syncope.client.console.rest.AbstractSubjectRestClient;
import org.apache.syncope.common.lib.mod.StatusMod;
import org.apache.syncope.common.lib.to.AbstractAttributableTO;
@@ -36,7 +34,6 @@ import org.apache.syncope.common.lib.to.AbstractSubjectTO;
import org.apache.syncope.common.lib.to.AttrTO;
import org.apache.syncope.common.lib.to.ConnObjectTO;
import org.apache.wicket.Component;
-import org.apache.wicket.ajax.AjaxRequestTarget;
import org.apache.wicket.behavior.Behavior;
import org.apache.wicket.markup.ComponentTag;
import org.apache.wicket.markup.html.image.Image;
@@ -48,9 +45,6 @@ public class StatusUtils implements Serializable {
private static final long serialVersionUID = 7238009174387184309L;
- /**
- * Logger.
- */
private static final Logger LOG = LoggerFactory.getLogger(StatusUtils.class);
private static final String IMG_PREFIX = "/img/statuses/";
@@ -170,42 +164,6 @@ public class StatusUtils implements Serializable {
return statusMod;
}
- public static void update(
- final AbstractAttributableTO attributable,
- final StatusPanel statusPanel,
- final AjaxRequestTarget target,
- final Collection<String> resourcesToAdd,
- final Collection<String> resourcesToRemove) {
-
- if (statusPanel != null) {
- Map<String, StatusBean> statusMap = new LinkedHashMap<>();
- for (StatusBean statusBean : statusPanel.getStatusBeans()) {
- statusMap.put(statusBean.getResourceName(), statusBean);
- }
-
- for (String resourceName : resourcesToAdd) {
- if (!statusMap.keySet().contains(resourceName)) {
- StatusBean statusBean;
- if (statusPanel.getInitialStatusBeanMap().containsKey(resourceName)) {
- statusBean = statusPanel.getInitialStatusBeanMap().get(resourceName);
- } else {
- statusBean = new StatusBean(attributable, resourceName);
- statusBean.setStatus(Status.NOT_YET_SUBMITTED);
- }
-
- statusMap.put(statusBean.getResourceName(), statusBean);
- }
- }
-
- for (String resource : resourcesToRemove) {
- statusMap.remove(resource);
- }
-
- statusPanel.updateStatusBeans(new ArrayList<>(statusMap.values()));
- target.add(statusPanel);
- }
- }
-
public ConnObjectTO getConnObjectTO(
final Long attributableId, final String resourceName, final List<ConnObjectWrapper> objects) {
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/init/ImplementationClassNamesLoader.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/init/ImplementationClassNamesLoader.java b/client/console/src/main/java/org/apache/syncope/client/console/init/ImplementationClassNamesLoader.java
index 0ff7282..6b0666e 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/init/ImplementationClassNamesLoader.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/init/ImplementationClassNamesLoader.java
@@ -25,7 +25,7 @@ import java.util.List;
import org.apache.commons.lang3.ArrayUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.syncope.client.console.panels.AbstractExtensionPanel;
-import org.apache.syncope.client.console.BinaryPreview;
+import org.apache.syncope.client.console.annotations.BinaryPreview;
import org.apache.syncope.client.console.wicket.markup.html.form.preview.AbstractBinaryPreviewer;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractBasePage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractBasePage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractBasePage.java
index 830f369..38408f9 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractBasePage.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/pages/AbstractBasePage.java
@@ -19,7 +19,6 @@
package org.apache.syncope.client.console.pages;
import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.XMLRolesReader;
import org.apache.syncope.client.console.init.MIMETypesLoader;
import org.apache.syncope.client.console.panels.NotificationPanel;
import org.apache.syncope.client.console.rest.ConfigurationRestClient;
@@ -44,9 +43,6 @@ public class AbstractBasePage extends WebPage {
private static final long serialVersionUID = 8611724965544132636L;
- /**
- * Logger.
- */
protected static final Logger LOG = LoggerFactory.getLogger(AbstractBasePage.class);
protected static final String TASKS = "Tasks";
@@ -62,9 +58,6 @@ public class AbstractBasePage extends WebPage {
protected final HeaderItem meta = new MetaHeaderItem("X-UA-Compatible", "IE=edge");
@SpringBean
- protected XMLRolesReader xmlRolesReader;
-
- @SpringBean
protected UserRestClient userRestClient;
@SpringBean
@@ -118,8 +111,8 @@ public class AbstractBasePage extends WebPage {
return modalResult;
}
- public void setModalResult(final boolean operationResult) {
- this.modalResult = operationResult;
+ public void setModalResult(final boolean modalResult) {
+ this.modalResult = modalResult;
}
@Override
[06/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/authorizations.xml
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/authorizations.xml b/client/old_console/src/main/resources/authorizations.xml
new file mode 100644
index 0000000..8de4a1d
--- /dev/null
+++ b/client/old_console/src/main/resources/authorizations.xml
@@ -0,0 +1,333 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<auth>
+ <page id="Schema">
+ <action id="list">
+ <entitlement>SCHEMA_LIST</entitlement>
+ </action>
+
+ <action id="create">
+ <entitlement>SCHEMA_CREATE</entitlement>
+ </action>
+
+ <action id="read">
+ <entitlement>SCHEMA_READ</entitlement>
+ </action>
+
+ <action id="update">
+ <entitlement>SCHEMA_UPDATE</entitlement>
+ </action>
+
+ <action id="delete">
+ <entitlement>SCHEMA_DELETE</entitlement>
+ </action>
+ </page>
+
+ <page id="Users">
+ <action id="list">
+ <entitlement>USER_LIST</entitlement>
+ </action>
+
+ <action id="create">
+ <entitlement>USER_CREATE</entitlement>
+ </action>
+
+ <action id="read">
+ <entitlement>USER_READ</entitlement>
+ </action>
+
+ <action id="update">
+ <entitlement>USER_UPDATE</entitlement>
+ </action>
+
+ <action id="delete">
+ <entitlement>USER_DELETE</entitlement>
+ </action>
+
+ <action id="changeView">
+ <entitlement>USER_VIEW</entitlement>
+ </action>
+ </page>
+
+ <page id="Groups">
+ <action id="list">
+ <entitlement>GROUP_LIST</entitlement>
+ </action>
+
+ <action id="create">
+ <entitlement>GROUP_CREATE</entitlement>
+ </action>
+
+ <action id="read">
+ <entitlement>GROUP_READ</entitlement>
+ </action>
+
+ <action id="update">
+ <entitlement>GROUP_UPDATE</entitlement>
+ </action>
+
+ <action id="delete">
+ <entitlement>GROUP_DELETE</entitlement>
+ </action>
+ </page>
+
+ <page id="Resources">
+ <action id="list">
+ <entitlement>RESOURCE_LIST</entitlement>
+ </action>
+
+ <action id="create">
+ <entitlement>RESOURCE_CREATE</entitlement>
+ </action>
+
+ <action id="read">
+ <entitlement>RESOURCE_READ</entitlement>
+ </action>
+
+ <action id="update">
+ <entitlement>RESOURCE_UPDATE</entitlement>
+ </action>
+
+ <action id="delete">
+ <entitlement>RESOURCE_DELETE</entitlement>
+ </action>
+
+ <action id="getConnectorObject">
+ <entitlement>RESOURCE_GETCONNECTOROBJECT</entitlement>
+ </action>
+ </page>
+
+ <page id="Reports">
+ <action id="list">
+ <entitlement>REPORT_LIST</entitlement>
+ </action>
+
+ <action id="create">
+ <entitlement>REPORT_CREATE</entitlement>
+ </action>
+
+ <action id="read">
+ <entitlement>REPORT_READ</entitlement>
+ </action>
+
+ <action id="update">
+ <entitlement>REPORT_UPDATE</entitlement>
+ </action>
+
+ <action id="delete">
+ <entitlement>REPORT_DELETE</entitlement>
+ </action>
+
+ <action id="execute">
+ <entitlement>REPORT_EXECUTE</entitlement>
+ </action>
+ </page>
+
+ <page id="Audit">
+ <action id="list">
+ <entitlement>AUDIT_LIST</entitlement>
+ </action>
+
+ <action id="enable">
+ <entitlement>AUDIT_ENABLE</entitlement>
+ </action>
+
+ <action id="disable">
+ <entitlement>AUDIT_DISABLE</entitlement>
+ </action>
+ </page>
+
+ <page id="Connectors">
+ <action id="list">
+ <entitlement>CONNECTOR_LIST</entitlement>
+ </action>
+
+ <action id="create">
+ <entitlement>CONNECTOR_CREATE</entitlement>
+ </action>
+
+ <action id="read">
+ <entitlement>CONNECTOR_READ</entitlement>
+ </action>
+
+ <action id="update">
+ <entitlement>CONNECTOR_UPDATE</entitlement>
+ </action>
+
+ <action id="delete">
+ <entitlement>CONNECTOR_DELETE</entitlement>
+ </action>
+
+ <action id="reload">
+ <entitlement>CONNECTOR_RELOAD</entitlement>
+ </action>
+
+ </page>
+
+ <page id="Approval">
+ <action id="list">
+ <entitlement>WORKFLOW_FORM_LIST</entitlement>
+ </action>
+ <action id="read">
+ <entitlement>WORKFLOW_FORM_READ</entitlement>
+ </action>
+ <action id="claim">
+ <entitlement>WORKFLOW_FORM_CLAIM</entitlement>
+ </action>
+ <action id="submit">
+ <entitlement>WORKFLOW_FORM_SUBMIT</entitlement>
+ </action>
+ </page>
+
+ <page id="Configuration">
+ <action id="list">
+ <entitlement>CONFIGURATION_LIST</entitlement>
+ </action>
+
+ <action id="export">
+ <entitlement>CONFIGURATION_EXPORT</entitlement>
+ </action>
+
+ <action id="set">
+ <entitlement>CONFIGURATION_SET</entitlement>
+ </action>
+
+ <action id="delete">
+ <entitlement>CONFIGURATION_DELETE</entitlement>
+ </action>
+
+ <action id="logList">
+ <entitlement>LOG_LIST</entitlement>
+ </action>
+
+ <action id="logSetLevel">
+ <entitlement>LOG_SET_LEVEL</entitlement>
+ </action>
+
+ <action id="logDelete">
+ <entitlement>LOG_DELETE</entitlement>
+ </action>
+
+ <action id="workflowDefRead">
+ <entitlement>WORKFLOW_DEF_READ</entitlement>
+ </action>
+
+ <action id="workflowDefUpdate">
+ <entitlement>WORKFLOW_DEF_UPDATE</entitlement>
+ </action>
+ </page>
+
+ <page id="Notification">
+ <action id="list">
+ <entitlement>NOTIFICATION_LIST</entitlement>
+ </action>
+
+ <action id="create">
+ <entitlement>NOTIFICATION_CREATE</entitlement>
+ </action>
+
+ <action id="read">
+ <entitlement>NOTIFICATION_READ</entitlement>
+ </action>
+
+ <action id="update">
+ <entitlement>NOTIFICATION_UPDATE</entitlement>
+ </action>
+
+ <action id="delete">
+ <entitlement>NOTIFICATION_DELETE</entitlement>
+ </action>
+ </page>
+
+ <page id="SecurityQuestion">
+ <action id="create">
+ <entitlement>SECURITY_QUESTION_CREATE</entitlement>
+ </action>
+
+ <action id="update">
+ <entitlement>SECURITY_QUESTION_UPDATE</entitlement>
+ </action>
+
+ <action id="delete">
+ <entitlement>SECURITY_QUESTION_DELETE</entitlement>
+ </action>
+ </page>
+
+ <page id="Tasks">
+ <action id="list">
+ <entitlement>TASK_LIST</entitlement>
+ </action>
+
+ <action id="execute">
+ <entitlement>TASK_EXECUTE</entitlement>
+ </action>
+
+ <action id="read">
+ <entitlement>TASK_READ</entitlement>
+ </action>
+
+ <action id="delete">
+ <entitlement>TASK_DELETE</entitlement>
+ </action>
+
+ <action id="create">
+ <entitlement>TASK_CREATE</entitlement>
+ </action>
+
+ <action id="update">
+ <entitlement>TASK_UPDATE</entitlement>
+ </action>
+ </page>
+
+ <page id="Policies">
+ <action id="list">
+ <entitlement>POLICY_LIST</entitlement>
+ </action>
+
+ <action id="read">
+ <entitlement>POLICY_READ</entitlement>
+ </action>
+
+ <action id="delete">
+ <entitlement>POLICY_DELETE</entitlement>
+ </action>
+
+ <action id="create">
+ <entitlement>POLICY_CREATE</entitlement>
+ </action>
+
+ <action id="update">
+ <entitlement>POLICY_UPDATE</entitlement>
+ </action>
+ </page>
+ <page id="CamelRoutes">
+ <action id="list">
+ <entitlement>ROUTE_LIST</entitlement>
+ </action>
+
+ <action id="read">
+ <entitlement>ROUTE_READ</entitlement>
+ </action>
+
+ <action id="update">
+ <entitlement>ROUTE_UPDATE</entitlement>
+ </action>
+ </page>
+</auth>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/console.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/console.properties b/client/old_console/src/main/resources/console.properties
new file mode 100644
index 0000000..3f2667b
--- /dev/null
+++ b/client/old_console/src/main/resources/console.properties
@@ -0,0 +1,22 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+console.directory=${conf.directory}
+scheme=http
+host=localhost
+port=8080
+rootPath=/syncope/rest/
+activitiModelerDirectory=${activiti-modeler.directory}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/consoleContext.xml
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/consoleContext.xml b/client/old_console/src/main/resources/consoleContext.xml
new file mode 100644
index 0000000..1acb7b4
--- /dev/null
+++ b/client/old_console/src/main/resources/consoleContext.xml
@@ -0,0 +1,77 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<beans xmlns="http://www.springframework.org/schema/beans"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xmlns:context="http://www.springframework.org/schema/context"
+ xsi:schemaLocation="http://www.springframework.org/schema/beans
+ http://www.springframework.org/schema/beans/spring-beans.xsd
+ http://www.springframework.org/schema/context
+ http://www.springframework.org/schema/context/spring-context.xsd">
+
+ <context:component-scan base-package="org.apache.syncope.client.console"/>
+
+ <bean id="confDirectoryPropertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
+ <property name="order" value="1"/>
+ <property name="location" value="file:${console.directory}/console.properties"/>
+ <property name="ignoreResourceNotFound" value="true"/>
+ <property name="ignoreUnresolvablePlaceholders" value="true"/>
+ </bean>
+ <bean id="classpathPropertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
+ <property name="location" value="classpath:console.properties"/>
+ </bean>
+
+ <bean id="version" class="java.lang.String">
+ <constructor-arg value="${syncope.version}"/>
+ </bean>
+
+ <bean id="site" class="java.lang.String">
+ <constructor-arg value="${project.parent.url}"/>
+ </bean>
+
+ <bean id="license" class="java.lang.String">
+ <constructor-arg value="${licenseUrl}"/>
+ </bean>
+
+ <bean id="anonymousUser" class="java.lang.String">
+ <constructor-arg value="${anonymousUser}"/>
+ </bean>
+ <bean id="anonymousKey" class="java.lang.String">
+ <constructor-arg value="${anonymousKey}"/>
+ </bean>
+
+ <bean id="activitiModelerDirectory" class="java.lang.String">
+ <constructor-arg value="${activitiModelerDirectory}"/>
+ </bean>
+
+ <bean id="syncopeApplication" class="org.apache.syncope.client.console.SyncopeApplication"/>
+
+ <bean id="preferenceManager" class="org.apache.syncope.client.console.commons.PreferenceManager"/>
+
+ <bean id="xmlRolesReader" class="org.apache.syncope.client.console.commons.XMLRolesReader" scope="singleton">
+ <property name="authorizations" value="authorizations.xml"/>
+ </bean>
+
+ <bean id="groupTreeBuilder" class="org.apache.syncope.client.console.commons.GroupTreeBuilder"/>
+
+ <bean id="syncopeClientFactory" class="org.apache.syncope.client.lib.SyncopeClientFactoryBean">
+ <property name="address" value="${scheme}://${host}:${port}/${rootPath}"/>
+ </bean>
+
+</beans>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication.properties
new file mode 100644
index 0000000..a5fe511
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication.properties
@@ -0,0 +1,55 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+users=Users
+groups=Groups
+configuration=Configuration
+resources=Resources
+connectors=Connectors
+reports=Reports
+tasks=Tasks
+logout=Logout
+schema=Schema
+operation_succeeded=Operation executed successfully
+operation_error=Error occurred during the requested operation
+alert=Alert:
+confirmDelete=Do you really want to delete the selected item(s)?
+confirmUnlink=Do you really want to remove the link between the selected item(s) and the resource?
+confirmUnassign=Do you really want to remove the assignment between the selected item(s) and the resource?
+confirmDeprovision=Do you really want to de-provision the selected item(s)?
+confirmProvision=Do you really want to provision the selected item(s)?
+
+
+unauthorizedInstantiationException=Missing authorization.
+accessControlException=Missing authorization while contacting Syncope core.
+restClientException=Error while contacting Syncope core.
+pageExpiredException=Session expired: please login again.
+
+dropDownChoiceField.nullValid=Choose one
+todo=TODO
+DateTimeField$HoursValidator=Hour value must be in range (1, 12)
+error=Error
+generic_error=An error occurred during the operation
+id=Id
+name=Name
+palette.available=Available
+palette.selected=Selected
+jexl_info=This field expects a JEXL expression, for example:
+jexl_ex1=surname + ',' + firstname
+jexl_ex2='new.' + surname
+jexl_syntax_url=Full JEXL reference
+create=Create
+key=Key
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication_it.properties
new file mode 100644
index 0000000..1f1e827
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication_it.properties
@@ -0,0 +1,54 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+users=Utenti
+groups=Gruppi
+configuration=Configurazione
+resources=Risorse
+connectors=Connettori
+reports=Rapporti
+logout=Logout
+schema=Schema
+tasks=Task
+operation_succeeded=Operazione eseguita con successo
+operation_error=Attenzione si \u00e8 verificato un errore durante l'esecuzione dell'operazione richiesta
+alert=Attenzione:
+confirmDelete=Vuoi davvero procedere con la cancellazione?
+confirmUnlink=Vuoi davvero procedere rimuovendo il link con la risorsa?
+confirmUnassign=Vuoi davvero procedere rimuovendo l'assegnamento sulla risorsa?
+confirmDeprovision=Vuoi davvero procedere con il de-provisioning?
+confirmProvision=Vuoi davvero procedere con il provisioning?
+
+unauthorizedInstantiationException=Autorizzazione mancante.
+accessControlException=Autorizzazione mancante durante la comunicazione con Syncope core.
+restClientException=Errore durante la comunicazione con Syncope core.
+pageExpiredException=Sessione scaduta: eseguire di nuovo l'accesso.
+
+dropDownChoiceField.nullValid=Seleziona
+todo=TODO
+DateTimeField$HoursValidator=L'ora deve essere nell'intervallo (1,12)
+error=Errore
+generic_error=Si \u00e8 verificato un errore durante l'operazione
+id=Id
+name=Nome
+palette.available=Opzioni
+palette.selected=Selezione
+jexl_info=In questo campo possono essere inserite espressioni di tipo JEXL, per esempio:
+jexl_ex1=surname + ',' + firstname
+jexl_ex2='new.' + surname
+jexl_syntax_url=Sintassi JEXL completa
+create=Crea
+key=Chiave
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication_pt_BR.properties
new file mode 100644
index 0000000..de966d2
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/SyncopeApplication_pt_BR.properties
@@ -0,0 +1,54 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+users=Usu\u00e1rios
+groups=Grupos
+configuration=Configura\u00e7\u00f5es
+resources=Recursos
+connectors=Conectores
+reports=Relat\u00f3rios
+tasks=Tarefas
+logout=Sair
+schema=Esquemas
+operation_succeeded=Opera\u00e7\u00e3o executada com sucesso
+operation_error=Um erro ocorreu ao executar esta opera\u00e7\u00e3o
+alert=Alerta:
+confirmDelete=Voc\u00ea realmente deseja apagar este item(s) selecionado?
+confirmUnlink=Voc\u00ea realmente deseja apagar o v\u00ednculo entre o item e de recursos?
+confirmUnassign=Voc\u00ea realmente deseja apagar a atribui\u00e7\u00e3o entre o item e de recursos?
+confirmDeprovision=Voc\u00ea realmente de-provision item?
+confirmProvision=Voc\u00ea realmente provision item?
+
+unauthorizedInstantiationException=Falta de autoriza\u00e7\u00e3o para concluir.
+accessControlException=Falta de autoriza\u00e7\u00e3o ao comunicar-se com o Syncope core.
+restClientException=Erro ao comunicar-se com o Syncope core.
+pageExpiredException=Sess\u00e3o encerrada, favor logar-se novamente.
+
+dropDownChoiceField.nullValid=Escolha um
+todo=A fazer
+DateTimeField$HoursValidator=O seu valor precisa estar entre (1, 12)
+error=Erro
+generic_error=Um erro ocorreu durante a opera\u00e7\u00e3o
+id=Id
+name=Nome
+palette.available=Dispon\u00ed\u00advel
+palette.selected=Selecionado
+jexl_info=Este campo \u00e9 designado a uma express\u00e3o do tipo JEXL, por exemplo\:
+jexl_ex1=sobrenome + ',' + nome
+jexl_ex2='novo.' + sobrenome
+jexl_syntax_url=Refer\u00eancia JEXL completa
+create=Criar
+key=Chave
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage.html
new file mode 100644
index 0000000..0c43c4b
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage.html
@@ -0,0 +1,122 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:head>
+ <link rel="stylesheet" type="text/css" href="css/bulk.css" media="all"/>
+ <style>
+ #dataTableSpan{
+ display: block;
+ clear: both;
+ float: none;
+ margin: 10px;
+ padding-top: 10px;
+ }
+
+ #dataTableSpan table{
+ width: 100%;
+ }
+
+ form#pwdMgtForm {
+ border: 1px solid #AAAAAA;
+ margin:10px;
+ }
+
+ div#changepwd {
+ display: inline-row;
+ margin-top: 5px;
+ }
+
+ div#changepwd div{
+ display: table-cell;
+ }
+
+ div#changepwd div#label{
+ padding-left: 5px;
+ vertical-align: middle;
+ font-family: Verdana,Arial,sans-serif;
+ }
+
+ div#password {
+ display: inline-row;
+ margin: 5px;
+ }
+
+ div#continue {
+ display: inline-row;
+ margin: 5px;
+ }
+
+ div#continue div{
+ display: table-cell;
+ }
+
+ div#cancelBtmForm {
+ padding-left: 5px;
+ }
+ </style>
+ </wicket:head>
+ <wicket:extend>
+ <p class="ui-widget ui-corner-all ui-widget-header">
+ <wicket:message key="title"/> <span wicket:id="displayName"/>
+ </p>
+ <span wicket:id="resourceDatatable" id="dataTableSpan">[resources]</span>
+
+ <span wicket:id="pwdMgtFields">[password management]</span>
+
+ <wicket:fragment wicket:id="pwdMgtFragment">
+ <div wicket:id="pwdMgt">
+ <form wicket:id="pwdMgtForm" id="pwdMgtForm">
+ <div id="changepwd">
+ <div id="value">
+ <span wicket:id="changepwd">[changepwd]</span>
+ </div>
+ <div id="label">
+ <label wicket:id="changePwdLabel">[Change password]</label>
+ </div>
+ </div>
+
+ <div id="password">
+ <input type="password" wicket:id="password" id="password" size="25" style="width: 180px" title="password"/>
+ </div>
+
+ <div id="password">
+ <input type="password" wicket:id="confirm" id="confirm" size="25" style="width: 180px" title="confirm"/>
+ </div>
+
+ <div id="continue">
+ <div id="continueBtmForm">
+ <input type="button" wicket:id="continue" id="continue"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"/>
+ </div>
+
+ <div id="cancelBtmForm">
+ <input type="button" wicket:id="cancel" id="cancel"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"/>
+ </div>
+ </div>
+ </form>
+ </div>
+ </wicket:fragment>
+
+ <wicket:fragment wicket:id="emptyFragment">
+ </wicket:fragment>
+
+ <wicket:child />
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage.properties
new file mode 100644
index 0000000..0f1fcdc
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage.properties
@@ -0,0 +1,19 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Global Status
+changePwdLabel=Password propagation
+passwordMismatch=Password mismatch
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage_it.properties
new file mode 100644
index 0000000..e5619e2
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage_it.properties
@@ -0,0 +1,19 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Stato Globale
+changePwdLabel=Propagazione password
+passwordMismatch=Password non corrispondenti
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage_pt_BR.properties
new file mode 100644
index 0000000..36d86e8
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/AbstractStatusModalPage_pt_BR.properties
@@ -0,0 +1,19 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Estatus Global
+changePwdLabel=Password propagation
+passwordMismatch=Password mismatch
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ActivitiModelerPopupPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ActivitiModelerPopupPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ActivitiModelerPopupPage.html
new file mode 100644
index 0000000..789538f
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ActivitiModelerPopupPage.html
@@ -0,0 +1,65 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:b3mn="http://b3mn.org/2007/b3mn"
+ xmlns:ext="http://b3mn.org/2007/ext"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:atom="http://b3mn.org/2007/atom+xhtml">
+ <head profile="http://purl.org/NET/erdf/profile">
+ <title>Apache Syncope / Activiti Modeler</title>
+ <!-- libraries -->
+ <script src="activiti-modeler/libs/prototype-1.5.1.js" type="text/javascript"></script>
+ <script src="activiti-modeler/libs/path_parser.js" type="text/javascript"></script>
+ <script src="activiti-modeler/libs/ext-2.0.2/adapter/ext/ext-base.js" type="text/javascript"></script>
+ <script src="activiti-modeler/libs/ext-2.0.2/ext-all-debug.js" type="text/javascript"></script>
+ <script src="activiti-modeler/libs/ext-2.0.2/color-field.js" type="text/javascript"></script>
+ <link rel="Stylesheet" media="screen" href="activiti-modeler/libs/ext-2.0.2/resources/css/ext-all.css" type="text/css"></link>
+ <link rel="Stylesheet" media="screen" href="activiti-modeler/libs/ext-2.0.2/resources/css/xtheme-darkgray.css" type="text/css"></link>
+ <link rel="Stylesheet" media="screen" href="activiti-modeler/editor/css/theme_norm.css" type="text/css"></link>
+ <link rel="Stylesheet" media="screen" href="activiti-modeler/editor/css/theme_norm_signavio.css" type="text/css"></link>
+ <link rel="Stylesheet" media="screen" href="activiti-modeler/explorer/src/css/xtheme-smoky.css" type="text/css"></link>
+ <link rel="Stylesheet" media="screen" href="activiti-modeler/explorer/src/css/custom-style.css" type="text/css"></link>
+ <!-- oryx editor -->
+ <!-- language files -->
+ <script src="activiti-modeler/editor/i18n/translation_en_us.js" type="text/javascript"></script>
+ <script src="activiti-modeler/editor/i18n/translation_signavio_en_us.js" type="text/javascript"></script>
+ <script src="activiti-modeler/libs/utils.js" type="text/javascript"></script>
+ <script src="activiti-modeler/editor/oryx.debug.js" type="text/javascript"></script>
+ <!-- erdf schemas -->
+ <link rel="schema.dc" href="http://purl.org/dc/elements/1.1/"></link>
+ <link rel="schema.dcTerms" href="http://purl.org/dc/terms/"></link>
+ <link rel="schema.b3mn" href="http://b3mn.org"></link>
+ <link rel="schema.oryx" href="http://oryx-editor.org/"></link>
+ <link rel="schema.raziel" href="http://raziel.org/"></link>
+
+ <script type="text/javascript">
+ window.onunload = refreshParent;
+ function refreshParent() {
+ if (window.opener.location.toString().indexOf('#workflow') === -1) {
+ window.opener.location = window.opener.location + "#workflow";
+ }
+ window.opener.location.reload();
+ }
+ </script>
+ </head>
+ <body style="overflow:hidden;">
+ </body>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage.html
new file mode 100644
index 0000000..be1a4b0
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage.html
@@ -0,0 +1,52 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+ <div style="margin: 5px;">
+ <form wicket:id="form">
+ <div id="formtable">
+ <div class="tablerow" wicket:id="propView">
+ <div class="tablecolumn_label medium_dynamicsize">
+ <span wicket:id="key">[key]</span>
+ </div>
+ <div class="tablecolumn_field medium_dynamicsize">
+ <span wicket:id="value">[value]</span>
+
+ </div>
+ </div>
+ </div>
+
+ <div style="margin: 20px 0">
+ <input type="button"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="userDetails"/>
+ <input type="submit"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="apply"/>
+ <input type="button"
+ accept=""class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="cancel"/>
+ </div>
+
+ </form>
+ <div wicket:id="editUserWin">[Show modal window for editing user under approval]</div>
+ </div>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage.properties
new file mode 100644
index 0000000..547f13f
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage.properties
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Approval form
+userDetails=User details
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage_it.properties
new file mode 100644
index 0000000..a2a7134
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage_it.properties
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Form di approvazione
+userDetails=Dettagli utente
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage_pt_BR.properties
new file mode 100644
index 0000000..954d365
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ApprovalModalPage_pt_BR.properties
@@ -0,0 +1,18 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Formul\u00E1rio de Aprova\u00E7\u00E3o
+userDetails=Detalhes do Usu\u00E1rio
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BaseModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BaseModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BaseModalPage.html
new file mode 100644
index 0000000..57fc8d3
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BaseModalPage.html
@@ -0,0 +1,56 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <head>
+ <title></title>
+
+ <link rel="stylesheet" type="text/css" href="webjars/jquery-ui/${jquery-ui.version}/themes/base/minified/jquery-ui.min.css" media="all"/>
+ <link rel="stylesheet" type="text/css" href="css/style.css" media="all"/>
+ <link rel="stylesheet" type="text/css" href="css/fieldstyle.css" media="all"/>
+
+ <script type="text/javascript" src="webjars/jquery-ui/${jquery-ui.version}/ui/minified/jquery-ui.min.js"></script>
+
+ <script type="text/javascript">
+ $(function() {
+ $("#tabs").tabs();
+ });
+
+ var notificationShownTimes = 0;
+
+ function showNotification(componentId, messagecount) {
+ notificationShownTimes++;
+ timeout = 1700 + (messagecount * 500) + notificationShownTimes * 200;
+ $('div#' + componentId).fadeTo('normal', 1.0);
+ setTimeout("$('div#" + componentId + "').fadeOut('normal')", timeout);
+ }
+ </script>
+
+ <style type="text/css">
+ table.palette td.header {
+ background:url("images/ui-bg_glass_75_e6e6e6_1x400.png")
+ repeat-x scroll 50% 50% #E6E6E6 !important;
+ }
+ </style>
+ </head>
+ <body onload="setTimeout('window.focus();', 0);">
+ <div wicket:id="feedback"/>
+
+ <wicket:child />
+ </body>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BaseModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BaseModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BaseModalPage.properties
new file mode 100644
index 0000000..bf07514
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BaseModalPage.properties
@@ -0,0 +1,20 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+submit=Save
+add=Add
+remove=Delete
+cancel=Cancel
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BaseModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BaseModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BaseModalPage_it.properties
new file mode 100644
index 0000000..9973e99
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BaseModalPage_it.properties
@@ -0,0 +1,20 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+submit=Salva
+add=Aggiungi
+remove=Elimina
+cancel=Annulla
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BaseModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BaseModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BaseModalPage_pt_BR.properties
new file mode 100644
index 0000000..bf17b75
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BaseModalPage_pt_BR.properties
@@ -0,0 +1,20 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+submit=Salvar
+add=Adicionar
+remove=Remover
+cancel=Cancelar
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePage.html
new file mode 100644
index 0000000..8b7349b
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePage.html
@@ -0,0 +1,145 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
+ <meta http-equiv="Content-Style-Type" content="text/css"/>
+ <meta http-equiv="Content-Script-Type" content="text/javascript"/>
+
+ <title>Apache Syncope</title>
+
+ <link rel="shortcut icon" href="img/favicon.png" type="image/png"/>
+
+ <style type="text/css">
+ div.wicket-modal div.w_caption {
+ height: 16px !important;
+ }
+ </style>
+ <link rel="stylesheet" type="text/css" href="webjars/jquery-ui/${jquery-ui.version}/themes/base/minified/jquery-ui.min.css" media="all"/>
+ <link rel="stylesheet" type="text/css" href="css/style.css" media="all"/>
+ <link rel="stylesheet" type="text/css" href="css/fieldstyle.css" />
+
+ <script type="text/javascript" src="webjars/jquery-ui/${jquery-ui.version}/ui/minified/jquery-ui.min.js"></script>
+
+ <script type="text/javascript">
+ $(document).ready(function() {
+ $("#tabs").tabs();
+ });
+
+ /** Add rollover effect to tables supporting Ajax events */
+ $(document).on('mouseover mouseout', 'table.ui-widget.ui-widget-content.table-hover tbody tr',
+ function(event) {
+ if (event.type == 'mouseover') {
+ $(this).addClass('selectedRow');
+ } else if (event.type == 'mouseout') {
+ $(this).removeClass('selectedRow');
+ }
+ });
+
+ var notificationShownTimes = 0;
+
+ function showNotification(componentId, messagecount) {
+ notificationShownTimes++;
+ timeout = 1700 + (messagecount * 500) + notificationShownTimes * 200;
+ $('div#' + componentId).fadeTo('normal', 1.0);
+ setTimeout("$('div#" + componentId + "').fadeOut('normal')", timeout);
+ }
+ </script>
+ </head>
+ <body>
+ <div id="navigationPane">
+ <ul>
+ <li style="position: absolute; left: 0px; top: 10px;width:240px;">
+ <img src="img/logo.png" alt="logo"/><br />
+ </li>
+ <li><span>
+ <a href="#" wicket:id="todo"><img wicket:id="todoIcon" alt="TODO" width="80" height="80" /><br />
+ <wicket:message key="todo"/>
+ </a>
+ </span>
+ </li>
+ <li><span>
+ <a href="#" wicket:id="schema"><img wicket:id="schemaIcon" alt="Schema" width="80" height="80" /><br />
+ <wicket:message key="schema"/>
+ </a>
+ </span>
+ </li>
+ <li><span>
+ <a href="#" wicket:id="users"><img wicket:id="usersIcon" alt="Users" width="80" height="80" /><br />
+ <wicket:message key="users"/>
+ </a>
+ </span>
+ </li>
+ <li><span>
+ <a href="#" wicket:id="groups"><img wicket:id="groupsIcon" alt="Groups" width="80" height="80" /><br />
+ <wicket:message key="groups"/>
+ </a>
+ </span>
+ </li>
+ <li><span>
+ <a href="#" wicket:id="resources"><img wicket:id="resourcesIcon" alt="Resources" width="80" height="80" /><br />
+ <wicket:message key="resources"/>
+ </a>
+ </span>
+ </li>
+ <li><span>
+ <a href="#" wicket:id="tasks"><img wicket:id="tasksIcon" alt="Tasks" width="80" height="80" /><br />
+ <wicket:message key="tasks"/>
+ </a>
+ </span>
+ </li>
+ <li><span>
+ <a href="#" wicket:id="reports"><img wicket:id="reportsIcon" alt="Reports" width="80" height="80" /><br />
+ <wicket:message key="reports"/>
+ </a>
+ </span>
+ </li>
+ <li><span>
+ <a href="#" wicket:id="configuration"><img wicket:id="configurationIcon" alt="Configuration" width="80" height="80" /><br />
+ <wicket:message key="configuration"/>
+ </a></span>
+ </li>
+ <li style="float:right;width:auto;text-align:right;">
+ <a href="#" wicket:id="logout"><img src="img/menu/logout.png" alt="Logout" width="80" height="80" /><br /></a>
+ <div style="display: table-row;">
+ <div id="username" style="padding-right: 5px;width: 100px;cursor: pointer;display: table-cell;">
+ <a href="#" wicket:id="editProfileLink">
+ <span wicket:id="username" style="color: #B9CFB3;font-family: monospace;"/>
+ </a>
+ </div>
+ <div>
+ <div wicket:id="infoModal"/>
+ <a wicket:id="infoLink" style="vertical-align: middle;"><img src="img/info.png" alt="info" style="padding-right: 10px;"/></a>
+ </div>
+ </div>
+ </li>
+ </ul>
+ <div wicket:id="editProfileModal"></div>
+ </div>
+
+ <div wicket:id="feedback"/>
+
+ <wicket:child />
+
+ <div id="veil" style="display:none;position:absolute;top:0;left:0;z-index:99999;background-color:black;width:100%;height:20000px;color:white;opacity:0.3;filter:alpha(opacity=30);">
+ <img src="img/busy.gif" style="position:absolute;top:300px;left:50%;margin-left:-75px;width:150px;"/>
+ </div>
+ </body>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePage.properties
new file mode 100644
index 0000000..c40d8a5
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePage.properties
@@ -0,0 +1,19 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+displayRows=Rows to display:
+home=Home
+version=VERSION
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePage_it.properties
new file mode 100644
index 0000000..8560ce7
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePage_it.properties
@@ -0,0 +1,19 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+displayRows=Righe per pagina:
+home=Home
+version=VERSIONE
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePage_pt_BR.properties
new file mode 100644
index 0000000..97349d4
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePage_pt_BR.properties
@@ -0,0 +1,19 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+displayRows=Linhas para mostrar\:
+home=In\u00EDcio
+version=VERS\u00C3O
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePopupPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePopupPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePopupPage.html
new file mode 100644
index 0000000..fea606c
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BasePopupPage.html
@@ -0,0 +1,51 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <head>
+ <title></title>
+
+ <link rel="stylesheet" type="text/css" href="webjars/jquery-ui/${jquery-ui.version}/themes/base/minified/jquery-ui.min.css" media="all"/>
+ <link rel="stylesheet" type="text/css" href="css/jquery-ui.css" media="all"/>
+ <link rel="stylesheet" type="text/css" href="css/style.css" media="all"/>
+ <link rel="stylesheet" type="text/css" href="css/fieldstyle.css" media="all"/>
+
+ <style type="text/css">
+ table.palette td.header {
+ background:url("images/ui-bg_glass_75_e6e6e6_1x400.png")
+ repeat-x scroll 50% 50% #E6E6E6 !important;
+ }
+ </style>
+
+ <script type="text/javascript">
+ var notificationShownTimes = 0;
+
+ function showNotification(componentId, messagecount) {
+ notificationShownTimes++;
+ timeout = 1700 + (messagecount * 500) + notificationShownTimes * 200;
+ $('div#' + componentId).fadeTo('normal', 1.0);
+ setTimeout("$('div#" + componentId + "').fadeOut('normal')", timeout);
+ }
+ </script>
+ </head>
+ <body onload="setTimeout('window.focus();', 0);">
+ <div wicket:id="feedback"/>
+
+ <wicket:child />
+ </body>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage.html
new file mode 100644
index 0000000..9e5d497
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage.html
@@ -0,0 +1,45 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:head>
+ <link rel="stylesheet" type="text/css" href="css/bulk.css" media="all"/>
+ </wicket:head>
+ <wicket:extend>
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+
+ <div id="selectedObjects">
+ <table class="ui-widget ui-widget-content table-hover pageRowElement" wicket:id="selectedObjects">[DataTable]</table>
+
+ <div id="actionRow" class="pageRowElement">
+ <div id="actions">
+ <div id="actionPanel" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only">
+ <span wicket:id="actions">[Actions]</span>
+ </div>
+
+ <div id="cancelBtmForm">
+ <form wicket:id="form">
+ <input type="button" wicket:id="cancel" id="cancel"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"/>
+ </form>
+ </div>
+ </div>
+ </div>
+ </div>
+ </wicket:extend>
+</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage.properties
new file mode 100644
index 0000000..bd28d80
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage.properties
@@ -0,0 +1,17 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Bulk action
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage_it.properties
new file mode 100644
index 0000000..3989422
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage_it.properties
@@ -0,0 +1,17 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Operazioni di gruppo
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage_pt_BR.properties
new file mode 100644
index 0000000..ec07d02
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionModalPage_pt_BR.properties
@@ -0,0 +1,17 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=A\u00E7\u00E3o Composta
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage.html
new file mode 100644
index 0000000..16dd256
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage.html
@@ -0,0 +1,57 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<wicket:head>
+ <link rel="stylesheet" type="text/css" href="css/bulk.css" media="all"/>
+</wicket:head>
+<wicket:extend>
+ <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
+
+<div id="selectedObjects">
+ <table class="ui-widget ui-widget-content table-hover pageRowElement" wicket:id="selectedObjects">[DataTable]</table>
+
+ <div id="actionRow" class="pageRowElement">
+ <div id="actions">
+ <div id="cancelBtmForm" style="padding: 0px">
+ <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="close">
+ <wicket:message key="close"/>
+ </a>
+ </div>
+ </div>
+ </div>
+</div>
+</wicket:extend>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage.properties
new file mode 100644
index 0000000..7ba550c
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage.properties
@@ -0,0 +1,19 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Bulk Action Result
+close=Close
+bulkActionResultLabel=Result
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage_it.properties
new file mode 100644
index 0000000..4268c00
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage_it.properties
@@ -0,0 +1,19 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Risultato esecuzion Bulk Action
+close=Chiudi
+bulkActionResultLabel=Esito
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage_pt_BR.properties
new file mode 100644
index 0000000..00c3a51
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/BulkActionResultModalPage_pt_BR.properties
@@ -0,0 +1,19 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Resultado da A\u00E7\u00E3o Composta
+close=Fechar
+bulkActionResultLabel=Implantar
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage.html
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage.html b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage.html
new file mode 100644
index 0000000..4ce5575
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage.html
@@ -0,0 +1,39 @@
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <wicket:extend>
+ <div style="margin: 5px;">
+ <p class="ui-widget ui-corner-all ui-widget-header">
+ <wicket:message key="title"/>
+ </p>
+ <form wicket:id="confForm">
+ <span wicket:id="paramAttrs"/>
+
+ <div style="bottom:0;margin:10px">
+ <input type="submit"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="submit"/>
+ <input type="button"
+ class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
+ wicket:id="cancel"/>
+ </div>
+ </form>
+ </div>
+ </wicket:extend>
+</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage.properties
new file mode 100644
index 0000000..363bef4
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage.properties
@@ -0,0 +1,17 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Parameters
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage_it.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage_it.properties
new file mode 100644
index 0000000..0fd85ae
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage_it.properties
@@ -0,0 +1,17 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Parametri
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage_pt_BR.properties b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage_pt_BR.properties
new file mode 100644
index 0000000..e7f3992
--- /dev/null
+++ b/client/old_console/src/main/resources/org/apache/syncope/client/console/pages/ConfModalPage_pt_BR.properties
@@ -0,0 +1,17 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+title=Par\u00e2metros
[42/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/Users.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/Users.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/Users.java
deleted file mode 100644
index 98f93bf..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/Users.java
+++ /dev/null
@@ -1,166 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.panels.AbstractSearchResultPanel;
-import org.apache.syncope.client.console.panels.AbstractSearchResultPanel.EventDataWrapper;
-import org.apache.syncope.client.console.panels.UserSearchPanel;
-import org.apache.syncope.client.console.panels.UserSearchResultPanel;
-import org.apache.syncope.client.console.rest.UserRestClient;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.Page;
-import org.apache.wicket.Session;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.event.Broadcast;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.request.mapper.parameter.PageParameters;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class Users extends BasePage {
-
- private static final long serialVersionUID = 134681165644474568L;
-
- private final static int EDIT_MODAL_WIN_HEIGHT = 550;
-
- private final static int EDIT_MODAL_WIN_WIDTH = 800;
-
- @SpringBean
- private UserRestClient restClient;
-
- public Users(final PageParameters parameters) {
- super(parameters);
-
- // Modal window for editing user attributes
- final ModalWindow editModalWin = new ModalWindow("editModal");
- editModalWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- editModalWin.setInitialHeight(EDIT_MODAL_WIN_HEIGHT);
- editModalWin.setInitialWidth(EDIT_MODAL_WIN_WIDTH);
- editModalWin.setCookieName("edit-modal");
- add(editModalWin);
-
- final AbstractSearchResultPanel searchResult =
- new UserSearchResultPanel("searchResult", true, null, getPageReference(), restClient);
- add(searchResult);
-
- final AbstractSearchResultPanel listResult =
- new UserSearchResultPanel("listResult", false, null, getPageReference(), restClient);
- add(listResult);
-
- // create new user
- final AjaxLink<Void> createLink = new ClearIndicatingAjaxLink<Void>("createLink", getPageReference()) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- editModalWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new EditUserModalPage(Users.this.getPageReference(), editModalWin, new UserTO());
- }
- });
-
- editModalWin.show(target);
- }
- };
- MetaDataRoleAuthorizationStrategy.authorize(
- createLink, ENABLE, xmlRolesReader.getEntitlement("Users", "create"));
- add(createLink);
-
- setWindowClosedReloadCallback(editModalWin);
-
- final Form<?> searchForm = new Form<>("searchForm");
- add(searchForm);
-
- final UserSearchPanel searchPanel = new UserSearchPanel.Builder("searchPanel").build();
- searchForm.add(searchPanel);
-
- final ClearIndicatingAjaxButton searchButton =
- new ClearIndicatingAjaxButton("search", new ResourceModel("search"), getPageReference()) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
- final String fiql = searchPanel.buildFIQL();
- LOG.debug("FIQL: " + fiql);
-
- doSearch(target, fiql, searchResult);
-
- Session.get().getFeedbackMessages().clear();
- searchPanel.getSearchFeedback().refresh(target);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
-
- searchPanel.getSearchFeedback().refresh(target);
- }
- };
-
- searchForm.add(searchButton);
- searchForm.setDefaultButton(searchButton);
- }
-
- private void doSearch(final AjaxRequestTarget target, final String fiql,
- final AbstractSearchResultPanel resultsetPanel) {
-
- if (fiql == null) {
- error(getString(Constants.SEARCH_ERROR));
- return;
- }
-
- resultsetPanel.search(fiql, target);
- }
-
- private void setWindowClosedReloadCallback(final ModalWindow window) {
- window.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
-
- private static final long serialVersionUID = 8804221891699487139L;
-
- @Override
- public void onClose(final AjaxRequestTarget target) {
- final EventDataWrapper data = new EventDataWrapper();
- data.setTarget(target);
- data.setCreate(true);
-
- send(getPage(), Broadcast.BREADTH, data);
-
- if (isModalResult()) {
- // reset modal result
- setModalResult(false);
- // set operation succeeded
- getSession().info(getString(Constants.OPERATION_SUCCEEDED));
- // refresh feedback panel
- feedbackPanel.refresh(target);
- }
- }
- });
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/ViewUserModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/ViewUserModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/ViewUserModalPage.java
deleted file mode 100644
index d47e07f..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/ViewUserModalPage.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.form.Form;
-
-public class ViewUserModalPage extends EditUserModalPage {
-
- private static final long serialVersionUID = -8715255026876951611L;
-
- public ViewUserModalPage(final PageReference callerPageRef, final ModalWindow window, final UserTO userTO) {
- super(callerPageRef, window, userTO);
- form.setEnabled(false);
- form.get(CANCEL).setVisible(false);
- }
-
- @Override
- protected AjaxButton getOnSubmit() {
- AjaxButton submit = super.getOnSubmit();
- submit.setVisible(false);
- return submit;
- }
-
- @Override
- protected void submitAction(final AjaxRequestTarget target, final Form form) {
- // No submit allowed, read-only form
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/VirSchemaModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/VirSchemaModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/VirSchemaModalPage.java
deleted file mode 100644
index 425b9cb..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/VirSchemaModalPage.java
+++ /dev/null
@@ -1,126 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.VirSchemaTO;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-
-/**
- * Modal window with Schema form.
- */
-public class VirSchemaModalPage extends AbstractSchemaModalPage<VirSchemaTO> {
-
- private static final long serialVersionUID = 5979623248182851337L;
-
- public VirSchemaModalPage(final AttributableType kind) {
- super(kind);
- }
-
- @Override
- public void setSchemaModalPage(final PageReference pageRef, final ModalWindow window,
- VirSchemaTO schema, final boolean createFlag) {
-
- if (schema == null) {
- schema = new VirSchemaTO();
- }
-
- final Form<VirSchemaTO> schemaForm = new Form<>(FORM);
-
- schemaForm.setModel(new CompoundPropertyModel<>(schema));
-
- final AjaxTextFieldPanel name =
- new AjaxTextFieldPanel("key", getString("key"), new PropertyModel<String>(schema, "key"));
- name.addRequiredLabel();
-
- name.setEnabled(createFlag);
-
- final AjaxCheckBoxPanel readonly = new AjaxCheckBoxPanel("readonly", getString("readonly"),
- new PropertyModel<Boolean>(schema, "readonly"));
-
- final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(SUBMIT)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- VirSchemaTO schemaTO = (VirSchemaTO) form.getDefaultModelObject();
- try {
- if (createFlag) {
- schemaRestClient.createVirSchema(kind, schemaTO);
- } else {
- schemaRestClient.updateVirSchema(kind, schemaTO);
- }
- if (pageRef.getPage() instanceof BasePage) {
- ((BasePage) pageRef.getPage()).setModalResult(true);
- }
-
- window.close(target);
- } catch (SyncopeClientException e) {
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
-
- final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
- };
-
- cancel.setDefaultFormProcessing(false);
-
- String allowedRoles = createFlag
- ? xmlRolesReader.getEntitlement("Schema", "create")
- : xmlRolesReader.getEntitlement("Schema", "update");
-
- MetaDataRoleAuthorizationStrategy.authorize(submit, ENABLE, allowedRoles);
-
- schemaForm.add(name);
- schemaForm.add(readonly);
-
- schemaForm.add(submit);
- schemaForm.add(cancel);
-
- add(schemaForm);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/WelcomePage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/WelcomePage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/WelcomePage.java
deleted file mode 100644
index d9f884d..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/WelcomePage.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.client.console.SyncopeApplication;
-import org.apache.syncope.client.console.commons.XMLRolesReader;
-import org.apache.syncope.client.console.rest.UserSelfRestClient;
-import org.apache.wicket.markup.html.WebPage;
-import org.apache.wicket.request.mapper.parameter.PageParameters;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-/**
- * Welcome page to display after successful login.
- */
-public class WelcomePage extends WebPage {
-
- private static final long serialVersionUID = 8851399358753120581L;
-
- @SpringBean
- private XMLRolesReader xmlRolesReader;
-
- @SpringBean
- private UserSelfRestClient userSelfRestClient;
-
- public WelcomePage(final PageParameters parameters) {
- super(parameters);
- setupNavigationPanel();
- setupEditProfileModal();
- }
-
- //To prevent warning: "leaking this in constructor java"
- private void setupNavigationPanel() {
- ((SyncopeApplication) getApplication()).setupNavigationPanel(this, xmlRolesReader, false);
- }
-
- private void setupEditProfileModal() {
- ((SyncopeApplication) getApplication()).setupEditProfileModal(this, userSelfRestClient);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/XMLEditorPopupPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/XMLEditorPopupPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/XMLEditorPopupPage.java
deleted file mode 100644
index b5a8d10..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/XMLEditorPopupPage.java
+++ /dev/null
@@ -1,90 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.io.IOException;
-import javax.ws.rs.core.MediaType;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.rest.WorkflowRestClient;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.markup.html.form.Button;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.form.TextArea;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.apache.wicket.util.io.IOUtils;
-
-public class XMLEditorPopupPage extends BasePopupPage {
-
- private static final long serialVersionUID = 5816041644635271734L;
-
- @SpringBean
- private WorkflowRestClient wfRestClient;
-
- public XMLEditorPopupPage() {
- Form wfForm = new Form("workflowDefForm");
-
- String definition;
- try {
- definition = IOUtils.toString(wfRestClient.getDefinition(MediaType.APPLICATION_XML_TYPE));
- } catch (IOException e) {
- LOG.error("Could not get workflow definition", e);
- definition = StringUtils.EMPTY;
- }
- final TextArea<String> workflowDefArea = new TextArea<String>("workflowDefArea", new Model<String>(definition));
- wfForm.add(workflowDefArea);
-
- AjaxButton submit =
- new ClearIndicatingAjaxButton(APPLY, new Model<String>(getString(SUBMIT)), getPageReference()) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
- try {
- wfRestClient.updateDefinition(
- MediaType.APPLICATION_XML_TYPE, workflowDefArea.getModelObject());
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scee) {
- error(getString(Constants.ERROR) + ": " + scee.getMessage());
- }
- feedbackPanel.refresh(target);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
-
- final Button close = new Button("closePage", new Model<String>(getString(CANCEL)));
-
- MetaDataRoleAuthorizationStrategy.authorize(
- submit, ENABLE, xmlRolesReader.getEntitlement("Configuration", "workflowDefUpdate"));
- wfForm.add(submit);
- wfForm.add(close);
- this.add(wfForm);
- }
-
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractExtensionPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractExtensionPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractExtensionPanel.java
index a785e9f..87af2ff 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractExtensionPanel.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractExtensionPanel.java
@@ -18,18 +18,13 @@
*/
package org.apache.syncope.client.console.panels;
-import org.apache.syncope.client.console.commons.XMLRolesReader;
import org.apache.wicket.PageReference;
import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
public abstract class AbstractExtensionPanel extends Panel {
private static final long serialVersionUID = 4627828052717627159L;
- @SpringBean
- protected XMLRolesReader xmlRolesReader;
-
protected PageReference pageref;
public AbstractExtensionPanel(final String id, final PageReference pageref) {
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractProvisioningTasksPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractProvisioningTasksPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractProvisioningTasksPanel.java
deleted file mode 100644
index e066aac..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractProvisioningTasksPanel.java
+++ /dev/null
@@ -1,160 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.pages.PushTaskModalPage;
-import org.apache.syncope.client.console.pages.SyncTaskModalPage;
-import org.apache.syncope.client.console.pages.Tasks;
-import org.apache.syncope.client.console.pages.Tasks.TasksProvider;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
-import org.apache.syncope.common.lib.to.AbstractProvisioningTaskTO;
-import org.apache.syncope.common.lib.to.AbstractTaskTO;
-import org.apache.syncope.common.lib.to.PushTaskTO;
-import org.apache.syncope.common.lib.to.SyncTaskTO;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.request.http.WebResponse;
-
-public abstract class AbstractProvisioningTasksPanel<T extends AbstractProvisioningTaskTO> extends AbstractTasks {
-
- private static final long serialVersionUID = -8674781241465369244L;
-
- private final int paginatorRows;
-
- protected WebMarkupContainer container;
-
- protected ModalWindow window;
-
- protected AjaxDataTablePanel<AbstractTaskTO, String> table;
-
- private final Class<T> reference;
-
- public AbstractProvisioningTasksPanel(final String id, final PageReference pageRef, final Class<T> reference) {
- super(id, pageRef);
-
- this.reference = reference;
-
- container = new WebMarkupContainer("container");
- container.setOutputMarkupId(true);
- add(container);
-
- window = new ModalWindow("taskWin");
- window.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- window.setInitialHeight(WIN_HEIGHT);
- window.setInitialWidth(WIN_WIDTH);
- window.setCookieName(VIEW_TASK_WIN_COOKIE_NAME);
- add(window);
-
- ((Tasks) pageRef.getPage()).setWindowClosedCallback(window, container);
-
- paginatorRows = prefMan.getPaginatorRows(getWebRequest(), Constants.PREF_SYNC_TASKS_PAGINATOR_ROWS);
- }
-
- @Override
- public void onEvent(final IEvent<?> event) {
- if (event.getPayload() instanceof AbstractSearchResultPanel.EventDataWrapper) {
- ((AbstractSearchResultPanel.EventDataWrapper) event.getPayload()).getTarget().add(container);
- }
- }
-
- protected void initTasksTable() {
-
- table = Tasks.updateTaskTable(
- getColumns(),
- new TasksProvider<T>(restClient, paginatorRows, getId(), this.reference),
- container,
- 0,
- this.pageRef,
- restClient);
-
- Form paginatorForm = new Form("PaginatorForm");
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- final DropDownChoice rowsChooser = new DropDownChoice("rowsChooser", new PropertyModel(this, "paginatorRows"),
- prefMan.getPaginatorChoices());
-
- rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- prefMan.set(getWebRequest(), (WebResponse) getResponse(), Constants.PREF_SYNC_TASKS_PAGINATOR_ROWS,
- String.valueOf(paginatorRows));
-
- table = Tasks.updateTaskTable(
- getColumns(),
- new TasksProvider<T>(restClient, paginatorRows, getId(), reference),
- container,
- table == null ? 0 : (int) table.getCurrentPage(),
- pageRef,
- restClient);
-
- target.add(container);
- }
- });
-
- paginatorForm.add(rowsChooser);
- container.add(paginatorForm);
-
- // create new task
- AjaxLink<Void> createLink = new ClearIndicatingAjaxLink<Void>("createLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return reference.equals(SyncTaskTO.class)
- ? new SyncTaskModalPage(window, new SyncTaskTO(), pageRef)
- : new PushTaskModalPage(window, new PushTaskTO(), pageRef);
- }
- });
-
- window.show(target);
- }
- };
-
- MetaDataRoleAuthorizationStrategy.authorize(
- createLink, RENDER, xmlRolesReader.getEntitlement(TASKS, "create"));
-
- add(createLink);
-
- }
-
- protected abstract List<IColumn<AbstractTaskTO, String>> getColumns();
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractSearchPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractSearchPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractSearchPanel.java
deleted file mode 100644
index ba4411e..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractSearchPanel.java
+++ /dev/null
@@ -1,401 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.List;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.commons.lang3.math.NumberUtils;
-import org.apache.cxf.jaxrs.ext.search.ConditionType;
-import org.apache.cxf.jaxrs.ext.search.SearchBean;
-import org.apache.cxf.jaxrs.ext.search.SearchCondition;
-import org.apache.cxf.jaxrs.ext.search.client.CompleteCondition;
-import org.apache.cxf.jaxrs.ext.search.fiql.FiqlParser;
-import org.apache.syncope.client.console.rest.AuthRestClient;
-import org.apache.syncope.client.console.rest.ResourceRestClient;
-import org.apache.syncope.client.console.rest.SchemaRestClient;
-import org.apache.syncope.common.lib.search.GroupFiqlSearchConditionBuilder;
-import org.apache.syncope.common.lib.search.SearchableFields;
-import org.apache.syncope.common.lib.search.SpecialAttr;
-import org.apache.syncope.common.lib.search.AbstractFiqlSearchConditionBuilder;
-import org.apache.syncope.common.lib.search.SyncopeProperty;
-import org.apache.syncope.common.lib.search.UserFiqlSearchConditionBuilder;
-import org.apache.syncope.common.lib.to.ResourceTO;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.syncope.common.lib.types.SubjectType;
-import org.apache.wicket.feedback.FeedbackMessage;
-import org.apache.wicket.feedback.IFeedbackMessageFilter;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-public abstract class AbstractSearchPanel extends Panel {
-
- private static final long serialVersionUID = 5922413053568696414L;
-
- /**
- * Logger.
- */
- protected static final Logger LOG = LoggerFactory.getLogger(AbstractSearchPanel.class);
-
- @SpringBean
- protected SchemaRestClient schemaRestClient;
-
- @SpringBean
- protected ResourceRestClient resourceRestClient;
-
- @SpringBean
- protected AuthRestClient authRestClient;
-
- protected IModel<List<String>> dnames;
-
- protected IModel<List<String>> anames;
-
- protected IModel<List<String>> resourceNames;
-
- protected IModel<List<String>> entitlements;
-
- protected IModel<List<SearchClause.Type>> types;
-
- protected IModel<List<String>> groupNames;
-
- protected NotificationPanel searchFeedback;
-
- protected List<SearchClause> searchClauses;
-
- protected WebMarkupContainer searchFormContainer;
-
- protected AttributableType attributableType;
-
- protected boolean required;
-
- protected AbstractSearchPanel(final String id, final AttributableType attributableType) {
- this(id, attributableType, null, true);
- }
-
- protected AbstractSearchPanel(final String id, final AttributableType attributableType,
- final String fiql, final boolean required) {
-
- super(id);
- populate();
-
- this.attributableType = attributableType;
- this.required = required;
-
- setOutputMarkupId(true);
-
- searchFormContainer = new WebMarkupContainer("searchFormContainer");
- searchFormContainer.setOutputMarkupId(true);
-
- searchFeedback = new NotificationPanel("searchFeedback", "notificationpanel_top_right",
- new IFeedbackMessageFilter() {
-
- private static final long serialVersionUID = 6895024863321391672L;
-
- @Override
- public boolean accept(final FeedbackMessage message) {
- boolean result;
-
- // messages reported on the session have a null reporter
- if (message.getReporter() == null) {
- result = false;
- } else {
- // only accept messages coming from the children of the search form container
- result = searchFormContainer.contains(message.getReporter(), true);
- }
-
- return result;
- }
- });
- searchFeedback.setOutputMarkupId(true);
- add(searchFeedback);
-
- this.searchClauses = new ArrayList<>();
- this.searchClauses.add(new SearchClause());
- if (StringUtils.isNotBlank(fiql)) {
- try {
- FiqlParser<SearchBean> fiqlParser = new FiqlParser<>(
- SearchBean.class, AbstractFiqlSearchConditionBuilder.CONTEXTUAL_PROPERTIES);
- List<SearchClause> parsed = getSearchClauses(fiqlParser.parse(fiql));
-
- this.searchClauses.clear();
- this.searchClauses.addAll(parsed);
- } catch (Exception e) {
- LOG.error("Unparseable FIQL expression '{}'", fiql, e);
- }
- }
-
- searchFormContainer.add(new SearchView("searchView", searchClauses, searchFormContainer, required,
- types, anames, dnames, groupNames, resourceNames, entitlements));
- add(searchFormContainer);
- }
-
- protected void populate() {
- dnames = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- return SearchableFields.get(
- attributableType == AttributableType.USER ? SubjectType.USER : SubjectType.GROUP);
- }
- };
-
- anames = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- return schemaRestClient.getPlainSchemaNames(attributableType);
- }
- };
-
- resourceNames = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- List<ResourceTO> resourceTOs = resourceRestClient.getAll();
-
- List<String> result = new ArrayList<>(resourceTOs.size());
-
- for (ResourceTO resource : resourceTOs) {
- result.add(resource.getKey());
- }
-
- return result;
- }
- };
-
- entitlements = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- List<String> result = authRestClient.getOwnedEntitlements();
- Collections.sort(result);
- return result;
- }
- };
- }
-
- public NotificationPanel getSearchFeedback() {
- return searchFeedback;
- }
-
- private SearchClause getPrimitiveSearchClause(final SearchCondition<SearchBean> sc) {
- SearchClause searchClause = new SearchClause();
-
- String property = sc.getCondition().getKeySet().iterator().next();
- searchClause.setProperty(property);
- String value = sc.getCondition().get(property);
- searchClause.setValue(value);
-
- if (SpecialAttr.GROUPS.toString().equals(property)) {
- searchClause.setType(SearchClause.Type.MEMBERSHIP);
- for (String label : groupNames.getObject()) {
- if (value.equals(label.substring(0, label.indexOf(' ')))) {
- searchClause.setProperty(label);
- }
- }
- } else if (SpecialAttr.RESOURCES.toString().equals(property)) {
- searchClause.setType(SearchClause.Type.RESOURCE);
- } else if (SpecialAttr.ENTITLEMENTS.toString().equals(property)) {
- searchClause.setType(SearchClause.Type.ENTITLEMENT);
- } else {
- searchClause.setType(SearchClause.Type.ATTRIBUTE);
- }
-
- switch (sc.getConditionType()) {
- case EQUALS:
- searchClause.setComparator(SpecialAttr.NULL.toString().equals(value)
- ? SearchClause.Comparator.IS_NULL : SearchClause.Comparator.EQUALS);
- break;
-
- case NOT_EQUALS:
- searchClause.setComparator(SpecialAttr.NULL.toString().equals(value)
- ? SearchClause.Comparator.IS_NOT_NULL : SearchClause.Comparator.NOT_EQUALS);
- break;
-
- case GREATER_OR_EQUALS:
- searchClause.setComparator(SearchClause.Comparator.GREATER_OR_EQUALS);
- break;
-
- case GREATER_THAN:
- searchClause.setComparator(SearchClause.Comparator.GREATER_THAN);
- break;
-
- case LESS_OR_EQUALS:
- searchClause.setComparator(SearchClause.Comparator.LESS_OR_EQUALS);
- break;
-
- case LESS_THAN:
- searchClause.setComparator(SearchClause.Comparator.LESS_THAN);
- break;
-
- default:
- break;
- }
-
- return searchClause;
- }
-
- private List<SearchClause> getCompoundSearchClause(final SearchCondition<SearchBean> sc) {
- List<SearchClause> clauses = new ArrayList<SearchClause>();
-
- for (SearchCondition<SearchBean> searchCondition : sc.getSearchConditions()) {
- if (searchCondition.getStatement() == null) {
- clauses.addAll(getCompoundSearchClause(searchCondition));
- } else {
- SearchClause clause = getPrimitiveSearchClause(searchCondition);
- if (sc.getConditionType() == ConditionType.AND) {
- clause.setOperator(SearchClause.Operator.AND);
- }
- if (sc.getConditionType() == ConditionType.OR) {
- clause.setOperator(SearchClause.Operator.OR);
- }
- clauses.add(clause);
- }
- }
-
- return clauses;
- }
-
- private List<SearchClause> getSearchClauses(final SearchCondition<SearchBean> sc) {
- List<SearchClause> clauses = new ArrayList<SearchClause>();
-
- if (sc.getStatement() == null) {
- clauses.addAll(getCompoundSearchClause(sc));
- } else {
- clauses.add(getPrimitiveSearchClause(sc));
- }
-
- return clauses;
- }
-
- protected abstract AbstractFiqlSearchConditionBuilder getSearchConditionBuilder();
-
- public String buildFIQL() {
- LOG.debug("Generating FIQL from List<SearchClause>: {}", searchClauses);
-
- if (searchClauses.isEmpty() || searchClauses.get(0).getType() == null) {
- return StringUtils.EMPTY;
- }
-
- AbstractFiqlSearchConditionBuilder builder = getSearchConditionBuilder();
-
- CompleteCondition prevCondition;
- CompleteCondition condition = null;
- for (int i = 0; i < searchClauses.size(); i++) {
- prevCondition = condition;
-
- switch (searchClauses.get(i).getType()) {
- case ENTITLEMENT:
- condition = searchClauses.get(i).getComparator() == SearchClause.Comparator.EQUALS
- ? ((GroupFiqlSearchConditionBuilder) builder).
- hasEntitlements(searchClauses.get(i).getProperty())
- : ((GroupFiqlSearchConditionBuilder) builder).
- hasNotEntitlements(searchClauses.get(i).getProperty());
- break;
-
- case MEMBERSHIP:
- Long groupId = NumberUtils.toLong(searchClauses.get(i).getProperty().split(" ")[0]);
- condition = searchClauses.get(i).getComparator() == SearchClause.Comparator.EQUALS
- ? ((UserFiqlSearchConditionBuilder) builder).inGroups(groupId)
- : ((UserFiqlSearchConditionBuilder) builder).notInGroups(groupId);
- break;
-
- case RESOURCE:
- condition = searchClauses.get(i).getComparator() == SearchClause.Comparator.EQUALS
- ? builder.hasResources(searchClauses.get(i).getProperty())
- : builder.hasNotResources(searchClauses.get(i).getProperty());
- break;
-
- case ATTRIBUTE:
- SyncopeProperty property = builder.is(searchClauses.get(i).getProperty());
- switch (searchClauses.get(i).getComparator()) {
- case IS_NULL:
- condition = builder.isNull(searchClauses.get(i).getProperty());
- break;
-
- case IS_NOT_NULL:
- condition = builder.isNotNull(searchClauses.get(i).getProperty());
- break;
-
- case LESS_THAN:
- condition = StringUtils.isNumeric(searchClauses.get(i).getProperty())
- ? property.lessThan(NumberUtils.toDouble(searchClauses.get(i).getValue()))
- : property.lexicalBefore(searchClauses.get(i).getValue());
- break;
-
- case LESS_OR_EQUALS:
- condition = StringUtils.isNumeric(searchClauses.get(i).getProperty())
- ? property.lessOrEqualTo(NumberUtils.toDouble(searchClauses.get(i).getValue()))
- : property.lexicalNotAfter(searchClauses.get(i).getValue());
- break;
-
- case GREATER_THAN:
- condition = StringUtils.isNumeric(searchClauses.get(i).getProperty())
- ? property.greaterThan(NumberUtils.toDouble(searchClauses.get(i).getValue()))
- : property.lexicalAfter(searchClauses.get(i).getValue());
- break;
-
- case GREATER_OR_EQUALS:
- condition = StringUtils.isNumeric(searchClauses.get(i).getProperty())
- ? property.greaterOrEqualTo(NumberUtils.toDouble(searchClauses.get(i).getValue()))
- : property.lexicalNotBefore(searchClauses.get(i).getValue());
- break;
-
- case NOT_EQUALS:
- condition = property.notEqualTo(searchClauses.get(i).getValue());
- break;
-
- case EQUALS:
- default:
- condition = property.equalTo(searchClauses.get(i).getValue());
- break;
- }
- default:
- break;
- }
-
- if (i > 0) {
- if (searchClauses.get(i).getOperator() == SearchClause.Operator.AND) {
- condition = builder.and(prevCondition, condition);
- }
- if (searchClauses.get(i).getOperator() == SearchClause.Operator.OR) {
- condition = builder.or(prevCondition, condition);
- }
- }
- }
-
- String fiql = condition == null ? StringUtils.EMPTY : condition.query();
- LOG.debug("Generated FIQL: {}", fiql);
- return fiql;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractSearchResultPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractSearchResultPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractSearchResultPanel.java
deleted file mode 100644
index 6139ee4..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractSearchResultPanel.java
+++ /dev/null
@@ -1,353 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.Collection;
-import java.util.List;
-import org.apache.syncope.client.console.commons.AttributableDataProvider;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.PreferenceManager;
-import org.apache.syncope.client.console.commons.XMLRolesReader;
-import org.apache.syncope.client.console.pages.AbstractBasePage;
-import org.apache.syncope.client.console.rest.AbstractSubjectRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.common.lib.to.AbstractAttributableTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.event.Broadcast;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.event.IEventSource;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-public abstract class AbstractSearchResultPanel extends Panel implements IEventSource {
-
- private static final long serialVersionUID = -9170191461250434024L;
-
- /**
- * Logger.
- */
- protected static final Logger LOG = LoggerFactory.getLogger(AbstractSearchResultPanel.class);
-
- /**
- * Edit modal window height.
- */
- private final static int EDIT_MODAL_WIN_HEIGHT = 550;
-
- /**
- * Edit modal window width.
- */
- private final static int EDIT_MODAL_WIN_WIDTH = 800;
-
- /**
- * Schemas to be shown modal window height.
- */
- private final static int DISPLAYATTRS_MODAL_WIN_HEIGHT = 550;
-
- /**
- * Schemas to be shown modal window width.
- */
- private final static int DISPLAYATTRS_MODAL_WIN_WIDTH = 550;
-
- /**
- * Schemas to be shown modal window height.
- */
- private final static int STATUS_MODAL_WIN_HEIGHT = 500;
-
- /**
- * Schemas to be shown modal window width.
- */
- private final static int STATUS_MODAL_WIN_WIDTH = 700;
-
- /**
- * Application preferences.
- */
- @SpringBean
- protected PreferenceManager prefMan;
-
- /**
- * Role reader for authorizations management.
- */
- @SpringBean
- protected XMLRolesReader xmlRolesReader;
-
- protected final AbstractSubjectRestClient restClient;
-
- /**
- * Number of rows per page.
- */
- private final int rows;
-
- /**
- * Container used to refresh table.
- */
- protected final WebMarkupContainer container;
-
- /**
- * Feedback panel specified by the caller.
- */
- protected final NotificationPanel feedbackPanel;
-
- /**
- * Specify if results are about a filtered search or not. Using this attribute it is possible to use this panel to
- * show results about user list and user search.
- */
- private final boolean filtered;
-
- /**
- * Filter used in case of filtered search.
- */
- private String fiql;
-
- /**
- * Result table.
- */
- private AjaxDataTablePanel<AbstractAttributableTO, String> resultTable;
-
- /**
- * Data provider used to search for users.
- */
- private AttributableDataProvider dataProvider;
-
- /**
- * Modal window to be used for user profile editing. Global visibility is required ...
- */
- protected final ModalWindow editmodal = new ModalWindow("editModal");
-
- /**
- * Modal window to be used for attributes choosing to display in tables.
- */
- protected final ModalWindow displaymodal = new ModalWindow("displayModal");
-
- /**
- * Modal window to be used for user status management.
- */
- protected final ModalWindow statusmodal = new ModalWindow("statusModal");
-
- /**
- * Owner page.
- */
- protected final AbstractBasePage page;
-
- protected <T extends AbstractAttributableTO> AbstractSearchResultPanel(final String id, final boolean filtered,
- final String fiql, final PageReference pageRef, final AbstractSubjectRestClient restClient) {
-
- super(id);
-
- setOutputMarkupId(true);
-
- this.page = (AbstractBasePage) pageRef.getPage();
-
- this.filtered = filtered;
- this.fiql = fiql;
- this.feedbackPanel = page.getFeedbackPanel();
-
- this.restClient = restClient;
-
- editmodal.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- editmodal.setInitialHeight(EDIT_MODAL_WIN_HEIGHT);
- editmodal.setInitialWidth(EDIT_MODAL_WIN_WIDTH);
- editmodal.setCookieName("edit-modal");
- add(editmodal);
-
- displaymodal.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- displaymodal.setInitialHeight(DISPLAYATTRS_MODAL_WIN_HEIGHT);
- displaymodal.setInitialWidth(DISPLAYATTRS_MODAL_WIN_WIDTH);
- displaymodal.setCookieName("display-modal");
- add(displaymodal);
-
- statusmodal.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- statusmodal.setInitialHeight(STATUS_MODAL_WIN_HEIGHT);
- statusmodal.setInitialWidth(STATUS_MODAL_WIN_WIDTH);
- statusmodal.setCookieName("status-modal");
- add(statusmodal);
-
- // Container for user search result
- container = new WebMarkupContainer("container");
- container.setOutputMarkupId(true);
- add(container);
-
- rows = prefMan.getPaginatorRows(getRequest(), Constants.PREF_USERS_PAGINATOR_ROWS);
- }
-
- protected void initResultTable() {
- // ---------------------------
- // Result table initialization
- // ---------------------------
- updateResultTable(false);
- // ---------------------------
-
- // ---------------------------
- // Rows-per-page selector
- // ---------------------------
- final Form<?> paginatorForm = new Form<>("paginator");
- container.add(paginatorForm);
-
- final DropDownChoice<Integer> rowsChooser = new DropDownChoice<>(
- "rowsChooser", new PropertyModel<Integer>(this, "rows"), prefMan.getPaginatorChoices());
-
- rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- prefMan.set(getRequest(), getResponse(), Constants.PREF_USERS_PAGINATOR_ROWS, String.valueOf(rows));
-
- final EventDataWrapper data = new EventDataWrapper();
- data.setTarget(target);
- data.setRows(rows);
-
- send(getParent(), Broadcast.BREADTH, data);
- }
- });
- paginatorForm.add(rowsChooser);
- // ---------------------------
-
- setWindowClosedReloadCallback(statusmodal);
- setWindowClosedReloadCallback(editmodal);
- setWindowClosedReloadCallback(displaymodal);
- }
-
- public void search(final String fiql, final AjaxRequestTarget target) {
- this.fiql = fiql;
- dataProvider.setFIQL(fiql);
- target.add(container);
- }
-
- private void updateResultTable(final boolean create) {
- updateResultTable(create, rows);
- }
-
- private void updateResultTable(final boolean create, final int rows) {
- dataProvider = new AttributableDataProvider(restClient, rows, filtered);
- dataProvider.setFIQL(fiql);
-
- final int currentPage = resultTable != null
- ? (create
- ? (int) resultTable.getPageCount() - 1
- : (int) resultTable.getCurrentPage())
- : 0;
-
- resultTable = new AjaxDataTablePanel<>(
- "resultTable",
- getColumns(),
- dataProvider,
- rows,
- getBulkActions(),
- restClient,
- "key",
- getPageId(),
- page.getPageReference());
-
- resultTable.setCurrentPage(currentPage);
-
- resultTable.setOutputMarkupId(true);
-
- container.addOrReplace(resultTable);
- }
-
- protected abstract List<IColumn<AbstractAttributableTO, String>> getColumns();
-
- @Override
- public void onEvent(final IEvent<?> event) {
- if (event.getPayload() instanceof EventDataWrapper) {
- final EventDataWrapper data = (EventDataWrapper) event.getPayload();
-
- if (data.getRows() < 1) {
- updateResultTable(data.isCreate());
- } else {
- updateResultTable(data.isCreate(), data.getRows());
- }
-
- data.getTarget().add(container);
- }
- }
-
- private void setWindowClosedReloadCallback(final ModalWindow window) {
- window.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
-
- private static final long serialVersionUID = 8804221891699487139L;
-
- @Override
- public void onClose(final AjaxRequestTarget target) {
- final EventDataWrapper data = new EventDataWrapper();
- data.setTarget(target);
- data.setRows(rows);
-
- send(getParent(), Broadcast.BREADTH, data);
-
- if (page.isModalResult()) {
- // reset modal result
- page.setModalResult(false);
- // set operation succeeded
- getSession().info(getString(Constants.OPERATION_SUCCEEDED));
- // refresh feedback panel
- feedbackPanel.refresh(target);
- }
- }
- });
- }
-
- public static class EventDataWrapper {
-
- private AjaxRequestTarget target;
-
- private boolean create;
-
- private int rows;
-
- public AjaxRequestTarget getTarget() {
- return target;
- }
-
- public void setTarget(final AjaxRequestTarget target) {
- this.target = target;
- }
-
- public boolean isCreate() {
- return create;
- }
-
- public void setCreate(boolean create) {
- this.create = create;
- }
-
- public int getRows() {
- return rows;
- }
-
- public void setRows(int rows) {
- this.rows = rows;
- }
- }
-
- protected abstract <T extends AbstractAttributableTO> Collection<ActionLink.ActionType> getBulkActions();
-
- protected abstract String getPageId();
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractTasks.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractTasks.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractTasks.java
deleted file mode 100644
index 381f878..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/AbstractTasks.java
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import org.apache.syncope.client.console.commons.PreferenceManager;
-import org.apache.syncope.client.console.commons.XMLRolesReader;
-import org.apache.syncope.client.console.rest.TaskRestClient;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public abstract class AbstractTasks extends Panel {
-
- private static final long serialVersionUID = -1190836516156843561L;
-
- protected static final String VIEW_TASK_WIN_COOKIE_NAME = "view-task-win";
-
- protected static final int WIN_HEIGHT = 500;
-
- protected static final int WIN_WIDTH = 700;
-
- protected static final String TASKS = "Tasks";
-
- protected PageReference pageRef;
-
- @SpringBean
- protected TaskRestClient restClient;
-
- @SpringBean
- protected PreferenceManager prefMan;
-
- @SpringBean
- protected XMLRolesReader xmlRolesReader;
-
- public AbstractTasks(final String id, final PageReference pageRef) {
- super(id);
- this.pageRef = pageRef;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/AccountInformationPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/AccountInformationPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/AccountInformationPanel.java
deleted file mode 100644
index 3bc7dd8..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/AccountInformationPanel.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.SyncopeSession;
-import org.apache.syncope.common.lib.to.AbstractAttributableTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.model.Model;
-
-public class AccountInformationPanel extends AnnotatedBeanPanel {
-
- private static final long serialVersionUID = 4228064224811390808L;
-
- public <T extends AbstractAttributableTO> AccountInformationPanel(final String id, final UserTO userTO) {
- super(id, userTO);
-
- // ------------------------
- // Change password date
- // ------------------------
- add(new Label("changePwdDate", new Model<String>(userTO.getChangePwdDate() == null
- ? StringUtils.EMPTY
- : SyncopeSession.get().getDateFormat().format(userTO.getChangePwdDate()))));
- // ------------------------
-
- // ------------------------
- // Last login date
- // ------------------------
- add(new Label("lastLoginDate", new Model<String>(userTO.getLastLoginDate() == null
- ? StringUtils.EMPTY
- : SyncopeSession.get().getDateFormat().format(userTO.getLastLoginDate()))));
- // ------------------------
-
- // ------------------------
- // Failed logins
- // ------------------------
- add(new Label("failedLogins", new Model<Integer>(userTO.getFailedLogins())));
- // ------------------------
-
- // ------------------------
- // Token
- // ------------------------
- add(new Label("token", new Model<String>(userTO.getToken() == null
- ? StringUtils.EMPTY
- : userTO.getToken())));
- // ------------------------
-
- // ------------------------
- // Token expire time
- // ------------------------
- add(new Label("tokenExpireTime", new Model<String>(userTO.getTokenExpireTime() == null
- ? StringUtils.EMPTY
- : SyncopeSession.get().getDateFormat().format(userTO.getTokenExpireTime()))));
- // ------------------------
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/ActionDataTablePanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/ActionDataTablePanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/ActionDataTablePanel.java
deleted file mode 100644
index bfade98..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/ActionDataTablePanel.java
+++ /dev/null
@@ -1,149 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.Collection;
-import java.util.List;
-import org.apache.syncope.client.console.commons.ActionTableCheckGroup;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.CheckGroupColumn;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink.ActionType;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.wicket.AttributeModifier;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormChoiceComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.ISortableDataProvider;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.ResourceModel;
-
-public class ActionDataTablePanel<T, S> extends DataTablePanel<T, S> {
-
- private static final long serialVersionUID = -8826989026203543957L;
-
- private static final String CANCEL = "cancel";
-
- private final Form<T> bulkActionForm;
-
- private final ActionLinksPanel actionPanel;
-
- private final PageReference pageRef;
-
- public ActionDataTablePanel(
- final String id,
- final List<IColumn<T, S>> columns,
- final ISortableDataProvider<T, S> dataProvider,
- final int rowsPerPage,
- final PageReference pageRef) {
-
- super(id);
-
- this.pageRef = pageRef;
-
- bulkActionForm = new Form<T>("groupForm");
- add(bulkActionForm);
-
- group = new ActionTableCheckGroup<T>("checkgroup", model) {
-
- private static final long serialVersionUID = -8667764190925075389L;
-
- @Override
- public boolean isCheckable(final T element) {
- return isElementEnabled(element);
- }
- };
- group.add(new AjaxFormChoiceComponentUpdatingBehavior() {
-
- private static final long serialVersionUID = -151291731388673682L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- // triggers AJAX form submit
- }
- });
- bulkActionForm.add(group);
-
- columns.add(0, new CheckGroupColumn<T, S>(group));
- dataTable = new AjaxFallbackDefaultDataTable<T, S>("dataTable", columns, dataProvider, rowsPerPage);
- group.add(dataTable);
-
- final WebMarkupContainer actionPanelContainer = new WebMarkupContainer("actionPanelContainer");
- bulkActionForm.add(actionPanelContainer);
-
- actionPanel = new ActionLinksPanel("actions", new Model(), pageRef);
- actionPanelContainer.add(actionPanel);
-
- if (dataTable.getRowCount() == 0) {
- actionPanelContainer.add(new AttributeModifier("style", "display: none"));
- }
-
- bulkActionForm.add(new ClearIndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL), pageRef) {
-
- private static final long serialVersionUID = -2341391430136818025L;
-
- @Override
- protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
- // ignore
- }
- }.setVisible(false).setEnabled(false));
- }
-
- public void addAction(final ActionLink action, final ActionType type, final String pageId) {
- actionPanel.add(action, type, pageId);
- }
-
- public void addAction(final ActionLink action, final ActionType type, final String pageId, final String actionId) {
- actionPanel.add(action, type, pageId, actionId);
- }
-
- public void addAction(final ActionLink action, final ActionType type, final String pageId, final boolean enabled) {
- actionPanel.add(action, type, pageId, enabled);
- }
-
- public void addCancelButton(final ModalWindow window) {
-
- final AjaxButton cancel = new ClearIndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL), pageRef) {
-
- private static final long serialVersionUID = -2341391430136818025L;
-
- @Override
- protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
- }.feedbackPanelAutomaticReload(false);
-
- cancel.setDefaultFormProcessing(false);
- bulkActionForm.addOrReplace(cancel);
- }
-
- public Collection<T> getModelObject() {
- return group.getModelObject();
- }
-
- public boolean isElementEnabled(final T element) {
- return true;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/AjaxDataTablePanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/AjaxDataTablePanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/AjaxDataTablePanel.java
deleted file mode 100644
index 563bd17..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/AjaxDataTablePanel.java
+++ /dev/null
@@ -1,142 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.Collection;
-import java.util.List;
-import org.apache.syncope.client.console.rest.BaseRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.panels.AbstractSearchResultPanel.EventDataWrapper;
-import org.apache.syncope.client.console.pages.AbstractBasePage;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.CheckGroupColumn;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
-import org.apache.syncope.client.console.pages.BulkActionModalPage;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormChoiceComponentUpdatingBehavior;
-import org.apache.wicket.event.Broadcast;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.ISortableDataProvider;
-import org.apache.wicket.markup.html.form.CheckGroup;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.panel.Fragment;
-
-public class AjaxDataTablePanel<T, S> extends DataTablePanel<T, S> {
-
- private static final long serialVersionUID = -7264400471578272966L;
-
- public AjaxDataTablePanel(
- final String id,
- final List<IColumn<T, S>> columns,
- final ISortableDataProvider<T, S> dataProvider,
- final int rowsPerPage,
- final Collection<ActionLink.ActionType> actions,
- final BaseRestClient bulkActionExecutor,
- final String itemIdField,
- final String pageId,
- final PageReference pageRef) {
-
- super(id);
-
- final ModalWindow bulkModalWin = new ModalWindow("bulkModal");
- bulkModalWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- bulkModalWin.setInitialHeight(600);
- bulkModalWin.setInitialWidth(900);
- bulkModalWin.setCookieName("bulk-modal");
- add(bulkModalWin);
-
- bulkModalWin.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
-
- private static final long serialVersionUID = 8804221891699487149L;
-
- @Override
- public void onClose(final AjaxRequestTarget target) {
- final EventDataWrapper data = new EventDataWrapper();
- data.setTarget(target);
- data.setRows(rowsPerPage);
-
- send(pageRef.getPage(), Broadcast.BREADTH, data);
-
- final AbstractBasePage page = (AbstractBasePage) pageRef.getPage();
-
- if (page.isModalResult()) {
- // reset modal result
- page.setModalResult(false);
- // set operation succeeded
- getSession().info(getString(Constants.OPERATION_SUCCEEDED));
- // refresh feedback panel
- target.add(page.getFeedbackPanel());
- }
- }
- });
-
- Fragment fragment = new Fragment("tablePanel", "bulkAvailable", this);
- add(fragment);
-
- Form<T> bulkActionForm = new Form<>("groupForm");
- fragment.add(bulkActionForm);
-
- group = new CheckGroup<>("checkgroup", model);
- group.add(new AjaxFormChoiceComponentUpdatingBehavior() {
-
- private static final long serialVersionUID = -151291731388673682L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- // triggers AJAX form submit
- }
- });
- bulkActionForm.add(group);
-
- columns.add(0, new CheckGroupColumn<T, S>(group));
- dataTable = new AjaxFallbackDefaultDataTable<>("dataTable", columns, dataProvider, rowsPerPage);
- group.add(dataTable);
-
- fragment.add(new ClearIndicatingAjaxButton("bulkActionLink", bulkActionForm, pageRef) {
-
- private static final long serialVersionUID = 382302811235019988L;
-
- @Override
- protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
- bulkModalWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690941L;
-
- @Override
- public Page createPage() {
- return new BulkActionModalPage<>(
- bulkModalWin,
- group.getModelObject(),
- columns,
- actions,
- bulkActionExecutor,
- itemIdField,
- pageId);
- }
- });
-
- bulkModalWin.show(target);
- }
- });
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/AnnotatedBeanPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/AnnotatedBeanPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/AnnotatedBeanPanel.java
deleted file mode 100644
index 714cb5f..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/AnnotatedBeanPanel.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import org.apache.syncope.client.console.SyncopeSession;
-import org.apache.syncope.common.lib.to.AbstractAnnotatedBean;
-import org.apache.syncope.common.lib.to.AbstractAttributableTO;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.Model;
-
-public class AnnotatedBeanPanel extends Panel {
-
- private static final long serialVersionUID = 4228064224811390809L;
-
- public <T extends AbstractAttributableTO> AnnotatedBeanPanel(
- final String id, final AbstractAnnotatedBean sysInfoTO) {
-
- super(id);
-
- // ------------------------
- // Creation date
- // ------------------------
- add(new Label("creationDate", new Model<String>(sysInfoTO.getCreationDate() != null
- ? SyncopeSession.get().getDateFormat().format(sysInfoTO.getCreationDate()) : "")));
- // ------------------------
-
- // ------------------------
- // Last change date
- // ------------------------
- add(new Label("lastChangeDate", new Model<String>(sysInfoTO.getLastChangeDate() != null
- ? SyncopeSession.get().getDateFormat().format(sysInfoTO.getCreationDate()) : "")));
- // ------------------------
-
- // ------------------------
- // Creator
- // ------------------------
- add(new Label("creator", new Model<String>(sysInfoTO.getCreator() != null
- ? sysInfoTO.getCreator() : "")));
- // ------------------------
-
- // ------------------------
- // Last modifier
- // ------------------------
- add(new Label("lastModifier", new Model<String>(sysInfoTO.getLastModifier() != null
- ? sysInfoTO.getLastModifier() : "")));
- // ------------------------
-
- }
-}
[11/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/VirAttrsPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/VirAttrsPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/VirAttrsPanel.java
new file mode 100644
index 0000000..84049f0
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/VirAttrsPanel.java
@@ -0,0 +1,294 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.HashSet;
+import java.util.List;
+import java.util.ListIterator;
+import java.util.Map;
+import java.util.Set;
+import java.util.TreeMap;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.panels.AttrTemplatesPanel.GroupAttrTemplatesChange;
+import org.apache.syncope.client.console.rest.GroupRestClient;
+import org.apache.syncope.client.console.rest.SchemaRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDecoratedCheckbox;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.to.AttrTO;
+import org.apache.syncope.common.lib.to.MembershipTO;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.syncope.common.lib.to.VirSchemaTO;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.wicket.Component;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.attributes.AjaxCallListener;
+import org.apache.wicket.ajax.attributes.AjaxRequestAttributes;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.ChoiceRenderer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class VirAttrsPanel extends Panel {
+
+ private static final long serialVersionUID = -7982691107029848579L;
+
+ @SpringBean
+ private SchemaRestClient schemaRestClient;
+
+ @SpringBean
+ private GroupRestClient groupRestClient;
+
+ private final AttrTemplatesPanel attrTemplates;
+
+ private final Map<String, VirSchemaTO> schemas = new TreeMap<String, VirSchemaTO>();
+
+ public <T extends AbstractAttributableTO> VirAttrsPanel(final String id, final T entityTO,
+ final boolean templateMode) {
+
+ this(id, entityTO, templateMode, null);
+ }
+
+ public <T extends AbstractAttributableTO> VirAttrsPanel(final String id, final T entityTO,
+ final boolean templateMode, final AttrTemplatesPanel attrTemplates) {
+
+ super(id);
+ this.attrTemplates = attrTemplates;
+ this.setOutputMarkupId(true);
+
+ final IModel<List<String>> virSchemas = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ private void filter(final List<VirSchemaTO> schemaTOs, final Set<String> allowed) {
+ for (ListIterator<VirSchemaTO> itor = schemaTOs.listIterator(); itor.hasNext();) {
+ VirSchemaTO schema = itor.next();
+ if (!allowed.contains(schema.getKey())) {
+ itor.remove();
+ }
+ }
+ }
+
+ @Override
+ protected List<String> load() {
+ List<VirSchemaTO> schemaTOs;
+
+ if (entityTO instanceof GroupTO) {
+ final GroupTO groupTO = (GroupTO) entityTO;
+
+ schemaTOs = schemaRestClient.getVirSchemas(AttributableType.GROUP);
+ Set<String> allowed;
+ if (attrTemplates == null) {
+ allowed = new HashSet<>(groupTO.getGVirAttrTemplates());
+ } else {
+ allowed = new HashSet<>(attrTemplates.getSelected(AttrTemplatesPanel.Type.gVirAttrTemplates));
+ if (groupTO.isInheritTemplates() && groupTO.getParent() != 0) {
+ allowed.addAll(groupRestClient.read(groupTO.getParent()).getGVirAttrTemplates());
+ }
+ }
+ filter(schemaTOs, allowed);
+ } else if (entityTO instanceof UserTO) {
+ schemaTOs = schemaRestClient.getVirSchemas(AttributableType.USER);
+ } else {
+ schemaTOs = schemaRestClient.getVirSchemas(AttributableType.MEMBERSHIP);
+ Set<String> allowed = new HashSet<String>(
+ groupRestClient.read(((MembershipTO) entityTO).getGroupKey()).getMVirAttrTemplates());
+ filter(schemaTOs, allowed);
+ }
+
+ schemas.clear();
+
+ for (VirSchemaTO schemaTO : schemaTOs) {
+ schemas.put(schemaTO.getKey(), schemaTO);
+ }
+
+ return new ArrayList<>(schemas.keySet());
+ }
+ };
+
+ final WebMarkupContainer attributesContainer = new WebMarkupContainer("virAttrContainer");
+ attributesContainer.setOutputMarkupId(true);
+ add(attributesContainer);
+
+ AjaxButton addAttributeBtn = new IndicatingAjaxButton("addAttributeBtn", new ResourceModel("addAttributeBtn")) {
+
+ private static final long serialVersionUID = -4804368561204623354L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ entityTO.getVirAttrs().add(new AttrTO());
+ target.add(attributesContainer);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ target.add(attributesContainer);
+ }
+ };
+
+ add(addAttributeBtn.setDefaultFormProcessing(Boolean.FALSE));
+
+ ListView<AttrTO> attributes = new ListView<AttrTO>("attrs",
+ new PropertyModel<List<? extends AttrTO>>(entityTO, "virAttrs")) {
+
+ private static final long serialVersionUID = 9101744072914090143L;
+
+ @Override
+ @SuppressWarnings("unchecked")
+ protected void populateItem(final ListItem<AttrTO> item) {
+ final AttrTO attributeTO = item.getModelObject();
+
+ item.add(new AjaxDecoratedCheckbox("toRemove", new Model<Boolean>(Boolean.FALSE)) {
+
+ private static final long serialVersionUID = 7170946748485726506L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ entityTO.getVirAttrs().remove(attributeTO);
+ target.add(attributesContainer);
+ }
+
+ @Override
+ protected void updateAjaxAttributes(final AjaxRequestAttributes attributes) {
+ super.updateAjaxAttributes(attributes);
+
+ final AjaxCallListener ajaxCallListener = new AjaxCallListener() {
+
+ private static final long serialVersionUID = 7160235486520935153L;
+
+ @Override
+ public CharSequence getPrecondition(final Component component) {
+ return "if (!confirm('" + getString("confirmDelete") + "')) return false;";
+ }
+ };
+ attributes.getAjaxCallListeners().add(ajaxCallListener);
+ }
+ });
+
+ if (attributeTO.getValues().isEmpty()) {
+ attributeTO.getValues().add("");
+ }
+
+ if (attributeTO.getSchema() != null) {
+ VirSchemaTO attributeSchema = schemas.get(attributeTO.getSchema());
+ if (attributeSchema != null) {
+ attributeTO.setReadonly(attributeSchema.isReadonly());
+ }
+ }
+
+ final AjaxTextFieldPanel panel;
+ final MultiFieldPanel multiPanel;
+ if (templateMode) {
+ panel = new AjaxTextFieldPanel("values", "values", new Model<String>());
+ panel.setReadOnly(attributeTO.isReadonly());
+ multiPanel = null;
+ } else {
+ panel = new AjaxTextFieldPanel("panel", "values", new Model<String>(null));
+ panel.setReadOnly(attributeTO.isReadonly());
+ multiPanel = new MultiFieldPanel("values",
+ new PropertyModel<List<String>>(attributeTO, "values"), panel);
+ }
+
+ final DropDownChoice<String> schemaChoice = new DropDownChoice<String>("schema",
+ new PropertyModel<String>(attributeTO, "schema"), virSchemas,
+ new ChoiceRenderer<String>() {
+
+ private static final long serialVersionUID = 3109256773218160485L;
+
+ @Override
+ public Object getDisplayValue(final String object) {
+ final StringBuilder text = new StringBuilder(object);
+ if (templateMode) {
+ text.append(" (JEXL)");
+ }
+ return text.toString();
+ }
+ });
+
+ schemaChoice.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_BLUR) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ attributeTO.setSchema(schemaChoice.getModelObject());
+
+ VirSchemaTO virSchema = schemas.get(attributeTO.getSchema());
+ if (virSchema != null) {
+ attributeTO.setReadonly(virSchema.isReadonly());
+ panel.setReadOnly(attributeTO.isReadonly());
+ }
+
+ if (multiPanel != null) {
+ multiPanel.getView().setEnabled(false);
+ }
+ }
+ });
+
+ schemaChoice.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ target.add(attributesContainer);
+ }
+ });
+
+ schemaChoice.setOutputMarkupId(true);
+ schemaChoice.setRequired(true);
+ item.add(schemaChoice);
+
+ if (templateMode) {
+ item.add(panel);
+ } else {
+ item.add(multiPanel);
+ }
+ }
+ };
+
+ attributesContainer.add(attributes);
+ }
+
+ @Override
+ public void onEvent(final IEvent<?> event) {
+ if ((event.getPayload() instanceof GroupAttrTemplatesChange)) {
+ final GroupAttrTemplatesChange update = (GroupAttrTemplatesChange) event.getPayload();
+ if (attrTemplates != null && update.getType() == AttrTemplatesPanel.Type.gVirAttrTemplates) {
+ update.getTarget().add(this);
+ }
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/resources/FilesystemResource.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/resources/FilesystemResource.java b/client/old_console/src/main/java/org/apache/syncope/client/console/resources/FilesystemResource.java
new file mode 100644
index 0000000..8a95de6
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/resources/FilesystemResource.java
@@ -0,0 +1,83 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.resources;
+
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.IOException;
+import org.apache.wicket.request.resource.AbstractResource;
+import org.apache.wicket.util.io.IOUtils;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Mounts directory on local filesystem as subcontext.
+ */
+public class FilesystemResource extends AbstractResource {
+
+ private static final long serialVersionUID = -4791087117785935198L;
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(FilesystemResource.class);
+
+ private final String baseCtx;
+
+ private final String basePath;
+
+ public FilesystemResource(final String baseCtx, final String basePath) {
+ this.baseCtx = baseCtx;
+ this.basePath = basePath;
+ }
+
+ @Override
+ protected ResourceResponse newResourceResponse(final Attributes attributes) {
+ ResourceResponse response = new ResourceResponse();
+
+ final File baseDir = new File(basePath);
+ if (baseDir.exists() && baseDir.canRead() && baseDir.isDirectory()) {
+ String reqPath = attributes.getRequest().getUrl().getPath();
+ final String subPath = reqPath.substring(reqPath.indexOf(baseCtx) + baseCtx.length()).
+ replace('/', File.separatorChar);
+ LOG.debug("Request for {}", subPath);
+
+ response.setWriteCallback(new WriteCallback() {
+
+ @Override
+ public void writeData(final Attributes attributes) throws IOException {
+ FileInputStream resourceIS = null;
+ try {
+ resourceIS = new FileInputStream(new File(baseDir, subPath));
+ IOUtils.copy(resourceIS, attributes.getResponse().getOutputStream());
+ } catch (IOException e) {
+ LOG.error("Could not read from {}", baseDir.getAbsolutePath() + subPath, e);
+ } finally {
+ IOUtils.closeQuietly(resourceIS);
+ }
+ }
+ });
+ } else {
+ LOG.error("{} not found, not readable or not a directory", basePath);
+ }
+
+ return response;
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/resources/WorkflowDefGETResource.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/resources/WorkflowDefGETResource.java b/client/old_console/src/main/java/org/apache/syncope/client/console/resources/WorkflowDefGETResource.java
new file mode 100644
index 0000000..2104745
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/resources/WorkflowDefGETResource.java
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.resources;
+
+import java.io.IOException;
+import javax.ws.rs.core.MediaType;
+import org.apache.syncope.client.console.rest.WorkflowRestClient;
+import org.apache.wicket.protocol.http.WebApplication;
+import org.apache.wicket.request.resource.AbstractResource;
+import org.apache.wicket.util.io.IOUtils;
+import org.springframework.web.context.support.WebApplicationContextUtils;
+
+/**
+ * Mirror REST resource for obtaining user workflow definition in JSON (used by Activiti Modeler).
+ *
+ * @see org.apache.syncope.common.services.WorkflowService#exportDefinition(org.apache.syncope.common.types.SubjectType)
+ */
+public class WorkflowDefGETResource extends AbstractResource {
+
+ private static final long serialVersionUID = 4637304868056148970L;
+
+ @Override
+ protected ResourceResponse newResourceResponse(final Attributes attributes) {
+ ResourceResponse response = new ResourceResponse();
+ response.disableCaching();
+ response.setContentType(MediaType.APPLICATION_JSON);
+
+ response.setWriteCallback(new WriteCallback() {
+
+ @Override
+ public void writeData(final Attributes attributes) throws IOException {
+ IOUtils.copy(WebApplicationContextUtils.getWebApplicationContext(
+ WebApplication.get().getServletContext()).getBean(WorkflowRestClient.class).
+ getDefinition(MediaType.APPLICATION_JSON_TYPE),
+ attributes.getResponse().getOutputStream());
+ }
+ });
+
+ return response;
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/resources/WorkflowDefPUTResource.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/resources/WorkflowDefPUTResource.java b/client/old_console/src/main/java/org/apache/syncope/client/console/resources/WorkflowDefPUTResource.java
new file mode 100644
index 0000000..add6485
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/resources/WorkflowDefPUTResource.java
@@ -0,0 +1,74 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.resources;
+
+import java.io.IOException;
+import javax.servlet.http.HttpServletRequest;
+import javax.ws.rs.core.MediaType;
+import org.apache.cxf.common.util.UrlUtils;
+import org.apache.syncope.client.console.rest.WorkflowRestClient;
+import org.apache.wicket.protocol.http.WebApplication;
+import org.apache.wicket.request.resource.AbstractResource;
+import org.apache.wicket.util.io.IOUtils;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.web.context.support.WebApplicationContextUtils;
+
+/**
+ * Mirror REST resource for putting user workflow definition in JSON (used by Activiti Modeler).
+ *
+ * @see org.apache.syncope.common.services.WorkflowService#importDefinition(
+ * org.apache.syncope.common.types.SubjectType, java.lang.String)
+ */
+public class WorkflowDefPUTResource extends AbstractResource {
+
+ private static final long serialVersionUID = 2964542005207297944L;
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(WorkflowDefPUTResource.class);
+
+ @Override
+ protected ResourceResponse newResourceResponse(final Attributes attributes) {
+ String definition = null;
+ try {
+ HttpServletRequest request = (HttpServletRequest) attributes.getRequest().getContainerRequest();
+ String requestBody = IOUtils.toString(request.getInputStream());
+ String[] split = requestBody.split("&");
+ for (int i = 0; i < split.length && definition == null; i++) {
+ String keyValue = split[i];
+ if (keyValue.startsWith("json_xml=")) {
+ definition = UrlUtils.urlDecode(keyValue.split("=")[1]);
+ }
+ }
+ } catch (IOException e) {
+ LOG.error("Could not extract workflow definition from request", e);
+ }
+
+ WebApplicationContextUtils.getWebApplicationContext(WebApplication.get().getServletContext()).
+ getBean(WorkflowRestClient.class).
+ updateDefinition(MediaType.APPLICATION_JSON_TYPE, definition);
+
+ ResourceResponse response = new ResourceResponse();
+ response.setStatusCode(204);
+ return response;
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/AbstractSubjectRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/AbstractSubjectRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/AbstractSubjectRestClient.java
new file mode 100644
index 0000000..a18a0a9
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/AbstractSubjectRestClient.java
@@ -0,0 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.util.List;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.to.BulkAction;
+import org.apache.syncope.common.lib.to.BulkActionResult;
+import org.apache.syncope.common.lib.to.ConnObjectTO;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortParam;
+
+public abstract class AbstractSubjectRestClient extends BaseRestClient {
+
+ private static final long serialVersionUID = 1962529678091410544L;
+
+ public abstract int count();
+
+ public abstract List<? extends AbstractAttributableTO> list(int page, int size, final SortParam<String> sort);
+
+ public abstract int searchCount(String fiql);
+
+ public abstract List<? extends AbstractAttributableTO> search(String fiql,
+ int page, int size, final SortParam<String> sort);
+
+ public abstract ConnObjectTO getConnectorObject(String resourceName, Long id);
+
+ public abstract AbstractAttributableTO delete(String etag, Long id);
+
+ public abstract BulkActionResult bulkAction(BulkAction action);
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ApprovalRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ApprovalRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ApprovalRestClient.java
new file mode 100644
index 0000000..dc9d12f
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ApprovalRestClient.java
@@ -0,0 +1,45 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.util.List;
+import org.apache.syncope.common.lib.to.WorkflowFormTO;
+import org.apache.syncope.common.rest.api.service.UserWorkflowService;
+import org.springframework.stereotype.Component;
+
+/**
+ * Console client for invoking Rest Todo services.
+ */
+@Component
+public class ApprovalRestClient extends BaseRestClient {
+
+ private static final long serialVersionUID = -4785231164900813921L;
+
+ public List<WorkflowFormTO> getForms() {
+ return getService(UserWorkflowService.class).getForms();
+ }
+
+ public WorkflowFormTO claimForm(final String taskId) {
+ return getService(UserWorkflowService.class).claimForm(taskId);
+ }
+
+ public void submitForm(final WorkflowFormTO form) {
+ getService(UserWorkflowService.class).submitForm(form);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/AuthRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/AuthRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/AuthRestClient.java
new file mode 100644
index 0000000..01e6838
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/AuthRestClient.java
@@ -0,0 +1,44 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.util.ArrayList;
+import java.util.List;
+import org.apache.syncope.common.rest.api.CollectionWrapper;
+import org.apache.syncope.common.rest.api.service.EntitlementService;
+import org.springframework.stereotype.Component;
+
+/**
+ * Console client for invoking Rest Resources services.
+ */
+@Component
+public class AuthRestClient extends BaseRestClient {
+
+ private static final long serialVersionUID = 2999780105004742914L;
+
+ public List<String> getAllEntitlements() {
+ return new ArrayList<>(
+ CollectionWrapper.unwrap(getService(EntitlementService.class).getAllEntitlements()));
+ }
+
+ public List<String> getOwnedEntitlements() {
+ return new ArrayList<>(
+ CollectionWrapper.unwrap(getService(EntitlementService.class).getOwnEntitlements()));
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/BaseRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/BaseRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/BaseRestClient.java
new file mode 100644
index 0000000..ddab7af
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/BaseRestClient.java
@@ -0,0 +1,70 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.io.Serializable;
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.client.lib.SyncopeClient;
+import org.apache.syncope.common.lib.search.OrderByClauseBuilder;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortParam;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public abstract class BaseRestClient implements Serializable {
+
+ /**
+ * Logger.
+ */
+ protected static final Logger LOG = LoggerFactory.getLogger(BaseRestClient.class);
+
+ private static final long serialVersionUID = 1523999867826481989L;
+
+ protected <T> T getAnonymousService(final Class<T> serviceClass) {
+ return SyncopeSession.get().getAnonymousService(serviceClass);
+ }
+
+ protected <T> T getService(final Class<T> serviceClass) {
+ return SyncopeSession.get().getService(serviceClass);
+ }
+
+ protected <T> T getService(final String etag, final Class<T> serviceClass) {
+ return SyncopeSession.get().getService(etag, serviceClass);
+ }
+
+ protected <T> void resetClient(final Class<T> serviceClass) {
+ SyncopeSession.get().resetClient(serviceClass);
+ }
+
+ protected String toOrderBy(final SortParam<String> sort) {
+ OrderByClauseBuilder builder = SyncopeClient.getOrderByClauseBuilder();
+
+ String property = sort.getProperty();
+ if (property.indexOf('#') != -1) {
+ property = property.substring(property.indexOf('#') + 1);
+ }
+
+ if (sort.isAscending()) {
+ builder.asc(property);
+ } else {
+ builder.desc(property);
+ }
+
+ return builder.build();
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ConfigurationRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ConfigurationRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ConfigurationRestClient.java
new file mode 100644
index 0000000..ca00ea8
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ConfigurationRestClient.java
@@ -0,0 +1,97 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.util.Iterator;
+import java.util.List;
+import javax.ws.rs.core.Response;
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.client.console.commons.AttrLayoutType;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.AttrTO;
+import org.apache.syncope.common.lib.to.ConfTO;
+import org.apache.syncope.common.rest.api.service.ConfigurationService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Component;
+
+@Component
+public class ConfigurationRestClient extends BaseRestClient {
+
+ private static final long serialVersionUID = 7692363064029538722L;
+
+ @Autowired
+ private SchemaRestClient schemaRestClient;
+
+ public ConfTO list() {
+ ConfTO conf = getService(ConfigurationService.class).list();
+
+ for (Iterator<AttrTO> it = conf.getPlainAttrs().iterator(); it.hasNext();) {
+ AttrTO attr = it.next();
+ for (AttrLayoutType type : AttrLayoutType.values()) {
+ if (type.getConfKey().equals(attr.getSchema())) {
+ it.remove();
+ }
+ }
+ }
+
+ return conf;
+ }
+
+ public AttrTO read(final String key) {
+ try {
+ return getService(ConfigurationService.class).read(key);
+ } catch (SyncopeClientException e) {
+ LOG.error("While reading a configuration schema", e);
+ }
+ return null;
+ }
+
+ public AttrTO readAttrLayout(final AttrLayoutType type) {
+ if (type == null) {
+ return null;
+ }
+
+ AttrTO attrLayout = read(type.getConfKey());
+ if (attrLayout == null) {
+ attrLayout = new AttrTO();
+ attrLayout.setSchema(type.getConfKey());
+ }
+ if (attrLayout.getValues().isEmpty()) {
+ attrLayout.getValues().addAll(schemaRestClient.getPlainSchemaNames(type.getAttrType()));
+ }
+
+ return attrLayout;
+ }
+
+ public void set(final AttrTO attributeTO) {
+ getService(ConfigurationService.class).set(attributeTO.getSchema(), attributeTO);
+ }
+
+ public void delete(final String key) {
+ getService(ConfigurationService.class).delete(key);
+ }
+
+ public List<String> getMailTemplates() {
+ return SyncopeSession.get().getSyncopeTO().getMailTemplates();
+ }
+
+ public Response dbExport() {
+ return getService(ConfigurationService.class).export();
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ConnectorRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ConnectorRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ConnectorRestClient.java
new file mode 100644
index 0000000..d9a729d
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ConnectorRestClient.java
@@ -0,0 +1,217 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.BulkAction;
+import org.apache.syncope.common.lib.to.BulkActionResult;
+import org.apache.syncope.common.lib.to.ConnBundleTO;
+import org.apache.syncope.common.lib.to.ConnIdObjectClassTO;
+import org.apache.syncope.common.lib.to.ConnInstanceTO;
+import org.apache.syncope.common.lib.to.PlainSchemaTO;
+import org.apache.syncope.common.lib.to.ResourceTO;
+import org.apache.syncope.common.lib.types.ConnConfProperty;
+import org.apache.syncope.common.rest.api.service.ConnectorService;
+import org.apache.syncope.common.rest.api.service.ResourceService;
+import org.springframework.beans.BeanUtils;
+import org.springframework.stereotype.Component;
+
+/**
+ * Console client for invoking Rest Connectors services.
+ */
+@Component
+public class ConnectorRestClient extends BaseRestClient {
+
+ private static final long serialVersionUID = -6870366819966266617L;
+
+ public List<ConnInstanceTO> getAllConnectors() {
+ List<ConnInstanceTO> connectors = Collections.<ConnInstanceTO>emptyList();
+ try {
+ connectors = getService(ConnectorService.class).list(SyncopeSession.get().getLocale().toString());
+ } catch (Exception e) {
+ LOG.error("While reading connectors", e);
+ }
+ return connectors;
+ }
+
+ public void create(final ConnInstanceTO connectorTO) {
+ Set<ConnConfProperty> filteredConf = filterProperties(connectorTO.getConfiguration());
+ connectorTO.getConfiguration().clear();
+ connectorTO.getConfiguration().addAll(filteredConf);
+ getService(ConnectorService.class).create(connectorTO);
+ }
+
+ /**
+ * Load an already existent connector by its name.
+ *
+ * @param connectorInstanceId the id
+ * @return ConnInstanceTO
+ */
+ public ConnInstanceTO read(final Long connectorInstanceId) {
+ ConnInstanceTO connectorTO = null;
+
+ try {
+ connectorTO = getService(ConnectorService.class).read(connectorInstanceId);
+ } catch (SyncopeClientException e) {
+ LOG.error("While reading a connector", e);
+ }
+
+ return connectorTO;
+ }
+
+ public void update(final ConnInstanceTO connectorTO) {
+ Set<ConnConfProperty> filteredConf = filterProperties(connectorTO.getConfiguration());
+ connectorTO.getConfiguration().clear();
+ connectorTO.getConfiguration().addAll(filteredConf);
+ getService(ConnectorService.class).update(connectorTO.getKey(), connectorTO);
+ }
+
+ public ConnInstanceTO delete(final Long id) {
+ ConnInstanceTO instanceTO = getService(ConnectorService.class).read(id);
+ getService(ConnectorService.class).delete(id);
+ return instanceTO;
+ }
+
+ public List<ConnBundleTO> getAllBundles() {
+ List<ConnBundleTO> bundles = Collections.<ConnBundleTO>emptyList();
+
+ try {
+ bundles = getService(ConnectorService.class).getBundles(SyncopeSession.get().getLocale().toString());
+ } catch (SyncopeClientException e) {
+ LOG.error("While getting connector bundles", e);
+ }
+
+ return bundles;
+ }
+
+ /**
+ * Get all configuration properties for the given connector instance.
+ *
+ * @param connectorId the connector id
+ * @return List of ConnConfProperty, or an empty list in case none found
+ */
+ public List<ConnConfProperty> getConnectorProperties(final Long connectorId) {
+ List<ConnConfProperty> properties = null;
+
+ try {
+ properties = getService(ConnectorService.class).getConfigurationProperties(connectorId);
+ } catch (SyncopeClientException e) {
+ LOG.error("While getting connector configuration properties", e);
+ }
+
+ return properties;
+ }
+
+ private Set<ConnConfProperty> filterProperties(final Set<ConnConfProperty> properties) {
+ Set<ConnConfProperty> newProperties = new HashSet<ConnConfProperty>();
+
+ for (ConnConfProperty property : properties) {
+ ConnConfProperty prop = new ConnConfProperty();
+ prop.setSchema(property.getSchema());
+ prop.setOverridable(property.isOverridable());
+
+ final List<Object> parsed = new ArrayList<Object>();
+ if (property.getValues() != null) {
+ for (Object obj : property.getValues()) {
+ if (obj != null && !obj.toString().isEmpty()) {
+ parsed.add(obj);
+ }
+ }
+ }
+ prop.getValues().addAll(parsed);
+ newProperties.add(prop);
+ }
+ return newProperties;
+ }
+
+ /**
+ * Test connector connection.
+ *
+ * @param connectorTO connector
+ * @return Connection status
+ */
+ public boolean check(final ConnInstanceTO connectorTO) {
+ ConnInstanceTO toBeChecked = new ConnInstanceTO();
+ BeanUtils.copyProperties(connectorTO, toBeChecked, new String[] { "configuration", "configurationMap" });
+ toBeChecked.getConfiguration().addAll(filterProperties(connectorTO.getConfiguration()));
+
+ boolean check = false;
+ try {
+ check = getService(ConnectorService.class).check(toBeChecked);
+ } catch (Exception e) {
+ LOG.error("While checking {}", toBeChecked, e);
+ }
+
+ return check;
+ }
+
+ public boolean check(final ResourceTO resourceTO) {
+ boolean check = false;
+ try {
+ check = getService(ResourceService.class).check(resourceTO);
+ } catch (Exception e) {
+ LOG.error("Connector not found {}", resourceTO.getConnectorId(), e);
+ }
+
+ return check;
+ }
+
+ public List<String> getSchemaNames(final ConnInstanceTO connectorTO) {
+ List<String> schemaNames = new ArrayList<String>();
+ try {
+ List<PlainSchemaTO> response = getService(ConnectorService.class).
+ getSchemaNames(connectorTO.getKey(), connectorTO, false);
+ for (PlainSchemaTO schema : response) {
+ schemaNames.add(schema.getKey());
+ }
+ } catch (Exception e) {
+ LOG.error("While getting schema names", e);
+ } finally {
+ // re-order schema names list
+ Collections.sort(schemaNames);
+ }
+
+ return schemaNames;
+ }
+
+ public List<ConnIdObjectClassTO> getSupportedObjectClasses(final ConnInstanceTO connectorTO) {
+ List<ConnIdObjectClassTO> result = Collections.emptyList();
+ try {
+ result = getService(ConnectorService.class).getSupportedObjectClasses(connectorTO.getKey(), connectorTO);
+ } catch (Exception e) {
+ LOG.error("While getting supported object classes", e);
+ }
+
+ return result;
+ }
+
+ public void reload() {
+ getService(ConnectorService.class).reload();
+ }
+
+ public BulkActionResult bulkAction(final BulkAction action) {
+ return getService(ConnectorService.class).bulk(action);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ExecutionRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ExecutionRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ExecutionRestClient.java
new file mode 100644
index 0000000..f78a682
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ExecutionRestClient.java
@@ -0,0 +1,26 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+public interface ExecutionRestClient {
+
+ void startExecution(long executionCollectorId);
+
+ void deleteExecution(long executionId);
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/GroupRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/GroupRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/GroupRestClient.java
new file mode 100644
index 0000000..91634f2
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/GroupRestClient.java
@@ -0,0 +1,184 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.util.List;
+
+import javax.ws.rs.core.Response;
+import org.apache.syncope.client.console.commons.status.StatusBean;
+import org.apache.syncope.client.console.commons.status.StatusUtils;
+import org.apache.syncope.common.lib.mod.GroupMod;
+import org.apache.syncope.common.lib.to.BulkAction;
+import org.apache.syncope.common.lib.to.BulkActionResult;
+import org.apache.syncope.common.lib.to.ConnObjectTO;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.types.ResourceAssociationActionType;
+import org.apache.syncope.common.lib.types.ResourceDeassociationActionType;
+import org.apache.syncope.common.lib.types.SubjectType;
+import org.apache.syncope.common.lib.wrap.ResourceName;
+import org.apache.syncope.common.rest.api.CollectionWrapper;
+import org.apache.syncope.common.rest.api.service.ResourceService;
+import org.apache.syncope.common.rest.api.service.GroupService;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortParam;
+import org.springframework.stereotype.Component;
+
+/**
+ * Console client for invoking Rest Group's services.
+ */
+@Component
+public class GroupRestClient extends AbstractSubjectRestClient {
+
+ private static final long serialVersionUID = -8549081557283519638L;
+
+ @Override
+ public int count() {
+ return getService(GroupService.class).list(1, 1).getTotalCount();
+ }
+
+ public List<GroupTO> list() {
+ return getService(GroupService.class).list(1, 1000).getResult();
+ }
+
+ @Override
+ public List<GroupTO> list(final int page, final int size, final SortParam<String> sort) {
+ return getService(GroupService.class).list(page, size, toOrderBy(sort)).getResult();
+ }
+
+ @Override
+ public int searchCount(final String fiql) {
+ return getService(GroupService.class).search(fiql, 1, 1).getTotalCount();
+ }
+
+ @Override
+ public List<GroupTO> search(final String fiql, final int page, final int size, final SortParam<String> sort) {
+ return getService(GroupService.class).search(fiql, page, size, toOrderBy(sort)).getResult();
+ }
+
+ @Override
+ public ConnObjectTO getConnectorObject(final String resourceName, final Long id) {
+ return getService(ResourceService.class).getConnectorObject(resourceName, SubjectType.GROUP, id);
+ }
+
+ public GroupTO create(final GroupTO groupTO) {
+ Response response = getService(GroupService.class).create(groupTO);
+ return response.readEntity(GroupTO.class);
+ }
+
+ public GroupTO read(final Long id) {
+ return getAnonymousService(GroupService.class).read(id);
+ }
+
+ public GroupTO update(final String etag, final GroupMod groupMod) {
+ GroupTO result;
+ synchronized (this) {
+ GroupService service = getService(etag, GroupService.class);
+ result = service.update(groupMod.getKey(), groupMod).readEntity(GroupTO.class);
+ resetClient(GroupService.class);
+ }
+ return result;
+ }
+
+ @Override
+ public GroupTO delete(final String etag, final Long id) {
+ GroupTO result;
+ synchronized (this) {
+ GroupService service = getService(etag, GroupService.class);
+ result = service.delete(id).readEntity(GroupTO.class);
+ resetClient(GroupService.class);
+ }
+ return result;
+ }
+
+ @Override
+ public BulkActionResult bulkAction(final BulkAction action) {
+ return getService(GroupService.class).bulk(action);
+ }
+
+ public void unlink(final String etag, final long groupId, final List<StatusBean> statuses) {
+ synchronized (this) {
+ GroupService service = getService(etag, GroupService.class);
+ service.bulkDeassociation(groupId, ResourceDeassociationActionType.UNLINK,
+ CollectionWrapper.wrap(StatusUtils.buildStatusMod(statuses).getResourceNames(),
+ ResourceName.class));
+ resetClient(GroupService.class);
+ }
+ }
+
+ public void link(final String etag, final long groupId, final List<StatusBean> statuses) {
+ synchronized (this) {
+ GroupService service = getService(etag, GroupService.class);
+ service.bulkAssociation(groupId, ResourceAssociationActionType.LINK,
+ CollectionWrapper.wrap(StatusUtils.buildStatusMod(statuses).getResourceNames(),
+ ResourceName.class));
+ resetClient(GroupService.class);
+ }
+ }
+
+ public BulkActionResult deprovision(final String etag, final long groupId, final List<StatusBean> statuses) {
+ BulkActionResult result;
+ synchronized (this) {
+ GroupService service = getService(etag, GroupService.class);
+ result = service.bulkDeassociation(groupId, ResourceDeassociationActionType.DEPROVISION,
+ CollectionWrapper.wrap(StatusUtils.buildStatusMod(statuses).getResourceNames(),
+ ResourceName.class)).
+ readEntity(BulkActionResult.class);
+ resetClient(GroupService.class);
+ }
+ return result;
+ }
+
+ public BulkActionResult provision(final String etag, final long groupId, final List<StatusBean> statuses) {
+ BulkActionResult result;
+ synchronized (this) {
+ GroupService service = getService(etag, GroupService.class);
+ result = service.bulkAssociation(groupId, ResourceAssociationActionType.PROVISION,
+ CollectionWrapper.wrap(StatusUtils.buildStatusMod(statuses).getResourceNames(),
+ ResourceName.class)).
+ readEntity(BulkActionResult.class);
+ resetClient(GroupService.class);
+ }
+ return result;
+ }
+
+ public BulkActionResult unassign(final String etag, final long groupId, final List<StatusBean> statuses) {
+ BulkActionResult result;
+ synchronized (this) {
+ GroupService service = getService(etag, GroupService.class);
+ result = service.bulkDeassociation(groupId, ResourceDeassociationActionType.UNASSIGN,
+ CollectionWrapper.wrap(StatusUtils.buildStatusMod(statuses).getResourceNames(),
+ ResourceName.class)).
+ readEntity(BulkActionResult.class);
+ resetClient(GroupService.class);
+ }
+ return result;
+ }
+
+ public BulkActionResult assign(final String etag, final long groupId, final List<StatusBean> statuses) {
+ BulkActionResult result;
+ synchronized (this) {
+ GroupService service = getService(etag, GroupService.class);
+ result = service.bulkAssociation(groupId, ResourceAssociationActionType.ASSIGN,
+ CollectionWrapper.wrap(StatusUtils.buildStatusMod(statuses).getResourceNames(),
+ ResourceName.class)).
+ readEntity(BulkActionResult.class);
+ resetClient(GroupService.class);
+ }
+ return result;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/InvalidPolicyType.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/InvalidPolicyType.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/InvalidPolicyType.java
new file mode 100644
index 0000000..6c7959c
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/InvalidPolicyType.java
@@ -0,0 +1,31 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+public class InvalidPolicyType extends RuntimeException {
+
+ private static final long serialVersionUID = -1230154509336169378L;
+
+ public InvalidPolicyType() {
+ }
+
+ public InvalidPolicyType(final String msg) {
+ super(msg);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/LoggerRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/LoggerRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/LoggerRestClient.java
new file mode 100644
index 0000000..a8b40ac
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/LoggerRestClient.java
@@ -0,0 +1,92 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.util.Collections;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+import org.apache.syncope.common.lib.to.EventCategoryTO;
+import org.apache.syncope.common.lib.to.LoggerTO;
+import org.apache.syncope.common.lib.types.AuditLoggerName;
+import org.apache.syncope.common.lib.types.LoggerLevel;
+import org.apache.syncope.common.lib.types.LoggerType;
+import org.apache.syncope.common.rest.api.CollectionWrapper;
+import org.apache.syncope.common.rest.api.service.LoggerService;
+import org.springframework.stereotype.Component;
+
+@Component
+public class LoggerRestClient extends BaseRestClient {
+
+ private static final long serialVersionUID = 4579786978763032240L;
+
+ public List<LoggerTO> listLogs() {
+ return getService(LoggerService.class).list(LoggerType.LOG);
+ }
+
+ public List<AuditLoggerName> listAudits() {
+ return CollectionWrapper.wrapLogger(getService(LoggerService.class).list(LoggerType.AUDIT));
+ }
+
+ public Map<String, Set<AuditLoggerName>> listAuditsByCategory() {
+ Map<String, Set<AuditLoggerName>> result = new HashMap<String, Set<AuditLoggerName>>();
+ for (AuditLoggerName auditLoggerName : listAudits()) {
+ if (!result.containsKey(auditLoggerName.getCategory())) {
+ result.put(auditLoggerName.getCategory(), new HashSet<AuditLoggerName>());
+ }
+
+ result.get(auditLoggerName.getCategory()).add(auditLoggerName);
+ }
+
+ return result;
+ }
+
+ public void setLogLevel(final String name, final LoggerLevel level) {
+ LoggerTO loggerTO = new LoggerTO();
+ loggerTO.setKey(name);
+ loggerTO.setLevel(level);
+ getService(LoggerService.class).update(LoggerType.LOG, name, loggerTO);
+ }
+
+ public void enableAudit(final AuditLoggerName auditLoggerName) {
+ String name = auditLoggerName.toLoggerName();
+ LoggerTO loggerTO = new LoggerTO();
+ loggerTO.setKey(name);
+ loggerTO.setLevel(LoggerLevel.DEBUG);
+ getService(LoggerService.class).update(LoggerType.AUDIT, name, loggerTO);
+ }
+
+ public void deleteLog(final String name) {
+ getService(LoggerService.class).delete(LoggerType.LOG, name);
+ }
+
+ public void disableAudit(final AuditLoggerName auditLoggerName) {
+ getService(LoggerService.class).delete(LoggerType.AUDIT, auditLoggerName.toLoggerName());
+ }
+
+ public List<EventCategoryTO> listEvents() {
+ try {
+ return getService(LoggerService.class).events();
+ } catch (Exception e) {
+ return Collections.<EventCategoryTO>emptyList();
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/NotificationRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/NotificationRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/NotificationRestClient.java
new file mode 100644
index 0000000..687ade0
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/NotificationRestClient.java
@@ -0,0 +1,50 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.util.List;
+import org.apache.syncope.common.lib.to.NotificationTO;
+import org.apache.syncope.common.rest.api.service.NotificationService;
+import org.springframework.stereotype.Component;
+
+@Component
+public class NotificationRestClient extends BaseRestClient {
+
+ private static final long serialVersionUID = 6328933265096511690L;
+
+ public List<NotificationTO> getAllNotifications() {
+ return getService(NotificationService.class).list();
+ }
+
+ public NotificationTO read(final Long id) {
+ return getService(NotificationService.class).read(id);
+ }
+
+ public void create(final NotificationTO notificationTO) {
+ getService(NotificationService.class).create(notificationTO);
+ }
+
+ public void update(final NotificationTO notificationTO) {
+ getService(NotificationService.class).update(notificationTO.getKey(), notificationTO);
+ }
+
+ public void delete(final Long id) {
+ getService(NotificationService.class).delete(id);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/PolicyRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/PolicyRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/PolicyRestClient.java
new file mode 100644
index 0000000..4409f7c
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/PolicyRestClient.java
@@ -0,0 +1,104 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.util.ArrayList;
+import java.util.List;
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.common.lib.to.AbstractPolicyTO;
+import org.apache.syncope.common.lib.types.PolicyType;
+import org.apache.syncope.common.rest.api.service.PolicyService;
+import org.springframework.stereotype.Component;
+
+/**
+ * Console client for invoking Rest Policy services.
+ */
+@Component
+public class PolicyRestClient extends BaseRestClient {
+
+ private static final long serialVersionUID = -1392090291817187902L;
+
+ public <T extends AbstractPolicyTO<?>> T getGlobalPolicy(final PolicyType type) {
+ T policy = null;
+ try {
+ policy = getService(PolicyService.class).readGlobal(type);
+ } catch (Exception e) {
+ LOG.warn("No global " + type + " policy found", e);
+ }
+ return policy;
+ }
+
+ public <T extends AbstractPolicyTO<?>> T getPolicy(final Long id) {
+ T policy = null;
+ try {
+ policy = getService(PolicyService.class).read(id);
+ } catch (Exception e) {
+ LOG.warn("No policy found for id {}", id, e);
+ }
+ return policy;
+ }
+
+ @SuppressWarnings("unchecked")
+ public <T extends AbstractPolicyTO<?>> List<T> getPolicies(final PolicyType type, final boolean includeGlobal) {
+ final List<T> res = new ArrayList<>();
+
+ try {
+ res.addAll((List<T>) getService(PolicyService.class).list(type));
+ } catch (Exception ignore) {
+ LOG.debug("No policy found", ignore);
+ }
+
+ if (includeGlobal) {
+ try {
+ T globalPolicy = getGlobalPolicy(type);
+ if (globalPolicy != null) {
+ res.add(0, globalPolicy);
+ }
+ } catch (Exception ignore) {
+ LOG.warn("No global policy found", ignore);
+ }
+ }
+
+ return res;
+ }
+
+ public <T extends AbstractPolicyTO<?>> void createPolicy(final T policy) {
+ getService(PolicyService.class).create(policy);
+ }
+
+ public <T extends AbstractPolicyTO<?>> void updatePolicy(final T policy) {
+ getService(PolicyService.class).update(policy.getKey(), policy);
+ }
+
+ public void delete(final Long id, final Class<? extends AbstractPolicyTO<?>> policyClass) {
+ getService(PolicyService.class).delete(id);
+ }
+
+ public List<String> getCorrelationRuleClasses() {
+ List<String> rules = null;
+
+ try {
+ rules = SyncopeSession.get().getSyncopeTO().getSyncCorrelationRules();
+ } catch (Exception e) {
+ LOG.error("While getting all correlation rule classes", e);
+ }
+
+ return rules;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ReportRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ReportRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ReportRestClient.java
new file mode 100644
index 0000000..81b58ac
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ReportRestClient.java
@@ -0,0 +1,108 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.util.ArrayList;
+import java.util.List;
+import javax.ws.rs.core.Response;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.ReportTO;
+import org.apache.syncope.common.lib.types.ReportExecExportFormat;
+import org.apache.syncope.common.lib.wrap.ReportletConfClass;
+import org.apache.syncope.common.rest.api.service.ReportService;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortParam;
+import org.springframework.stereotype.Component;
+
+@Component
+public class ReportRestClient extends BaseRestClient implements ExecutionRestClient {
+
+ private static final long serialVersionUID = 1644689667998953604L;
+
+ public List<String> getReportletConfClasses() {
+ List<String> result = new ArrayList<String>();
+
+ try {
+ List<ReportletConfClass> reportletConfClasses = getService(ReportService.class).getReportletConfClasses();
+ for (ReportletConfClass clazz : reportletConfClasses) {
+ result.add(clazz.getElement());
+ }
+ } catch (SyncopeClientException e) {
+ LOG.error("While getting available reportlet classes", e);
+ }
+
+ return result;
+ }
+
+ public ReportTO read(final Long reportId) {
+ return getService(ReportService.class).read(reportId);
+ }
+
+ public List<ReportTO> list() {
+ return getService(ReportService.class).list().getResult();
+ }
+
+ public List<ReportTO> list(final int page, final int size, final SortParam<String> sort) {
+ return getService(ReportService.class).list(page, size, toOrderBy(sort)).getResult();
+ }
+
+ public int count() {
+ return getService(ReportService.class).list(1, 1).getTotalCount();
+ }
+
+ public void create(final ReportTO reportTO) {
+ getService(ReportService.class).create(reportTO);
+ }
+
+ public void update(final ReportTO reportTO) {
+ getService(ReportService.class).update(reportTO.getKey(), reportTO);
+ }
+
+ /**
+ * Delete specified report.
+ *
+ * @param reportId report to delete
+ */
+ public void delete(final Long reportId) {
+ getService(ReportService.class).delete(reportId);
+ }
+
+ /**
+ * Start execution for the specified report.
+ *
+ * @param reportId report id
+ */
+ @Override
+ public void startExecution(final long reportId) {
+ getService(ReportService.class).execute(reportId);
+ }
+
+ /**
+ * Delete specified report execution.
+ *
+ * @param reportExecId report execution id
+ */
+ @Override
+ public void deleteExecution(final long reportExecId) {
+ getService(ReportService.class).deleteExecution(reportExecId);
+ }
+
+ public Response exportExecutionResult(final Long executionId, final ReportExecExportFormat fmt) {
+ return getService(ReportService.class).exportExecutionResult(executionId, fmt);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ResourceRestClient.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ResourceRestClient.java b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ResourceRestClient.java
new file mode 100644
index 0000000..2c44211
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/rest/ResourceRestClient.java
@@ -0,0 +1,94 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.rest;
+
+import java.util.List;
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.to.BulkAction;
+import org.apache.syncope.common.lib.to.BulkActionResult;
+import org.apache.syncope.common.lib.to.ResourceTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.syncope.common.lib.types.ResourceDeassociationActionType;
+import org.apache.syncope.common.lib.types.SubjectType;
+import org.apache.syncope.common.lib.wrap.SubjectKey;
+import org.apache.syncope.common.rest.api.service.ResourceService;
+import org.springframework.stereotype.Component;
+
+/**
+ * Console client for invoking Rest Resources services.
+ */
+@Component
+public class ResourceRestClient extends BaseRestClient {
+
+ private static final long serialVersionUID = -6898907679835668987L;
+
+ public List<String> getPropagationActionsClasses() {
+ return SyncopeSession.get().getSyncopeTO().getPropagationActions();
+ }
+
+ public List<ResourceTO> getAll() {
+ List<ResourceTO> resources = null;
+
+ try {
+ resources = getService(ResourceService.class).list();
+ } catch (SyncopeClientException e) {
+ LOG.error("While reading all resources", e);
+ }
+
+ return resources;
+ }
+
+ public void create(final ResourceTO resourceTO) {
+ getService(ResourceService.class).create(resourceTO);
+ }
+
+ public ResourceTO read(final String name) {
+ ResourceTO resourceTO = null;
+
+ try {
+ resourceTO = getService(ResourceService.class).read(name);
+ } catch (SyncopeClientException e) {
+ LOG.error("While reading a resource", e);
+ }
+ return resourceTO;
+ }
+
+ public void update(final ResourceTO resourceTO) {
+ getService(ResourceService.class).update(resourceTO.getKey(), resourceTO);
+ }
+
+ public void delete(final String name) {
+ getService(ResourceService.class).delete(name);
+ }
+
+ public BulkActionResult bulkAction(final BulkAction action) {
+ return getService(ResourceService.class).bulk(action);
+ }
+
+ public BulkActionResult bulkAssociationAction(
+ final String resourceName, final Class<? extends AbstractAttributableTO> typeRef,
+ final ResourceDeassociationActionType type, final List<SubjectKey> subjtectIds) {
+
+ return getService(ResourceService.class).bulkDeassociation(resourceName,
+ UserTO.class.isAssignableFrom(typeRef) ? SubjectType.USER : SubjectType.GROUP,
+ type, subjtectIds);
+ }
+}
[19/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.java
new file mode 100644
index 0000000..d8b762f
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.java
@@ -0,0 +1,153 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.Mode;
+import org.apache.syncope.client.console.rest.SecurityQuestionRestClient;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.common.lib.to.SecurityQuestionTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.form.StatelessForm;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class RequestPasswordResetModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = -8419445804421211904L;
+
+ @SpringBean
+ private SecurityQuestionRestClient securityQuestionRestClient;
+
+ public RequestPasswordResetModalPage(final ModalWindow window) {
+ super();
+ setOutputMarkupId(true);
+
+ final boolean handleSecurityQuestion = userSelfRestClient.isPwdResetRequiringSecurityQuestions();
+
+ final StatelessForm<?> form = new StatelessForm<Object>(FORM);
+ form.setOutputMarkupId(true);
+
+ final Label securityQuestionLabel = new Label("securityQuestionLabel", getString("securityQuestion"));
+ securityQuestionLabel.setOutputMarkupPlaceholderTag(true);
+ securityQuestionLabel.setVisible(handleSecurityQuestion);
+ form.add(securityQuestionLabel);
+ final AjaxTextFieldPanel securityQuestion =
+ new AjaxTextFieldPanel("securityQuestion", "securityQuestion", new Model<String>());
+ securityQuestion.setReadOnly(true);
+ securityQuestion.setRequired(true);
+ securityQuestion.getField().setOutputMarkupId(true);
+ securityQuestion.setOutputMarkupPlaceholderTag(true);
+ securityQuestion.setVisible(handleSecurityQuestion);
+ form.add(securityQuestion);
+
+ final AjaxTextFieldPanel username =
+ new AjaxTextFieldPanel("username", "username", new Model<String>());
+ username.setRequired(true);
+ username.getField().setOutputMarkupId(true);
+ if (handleSecurityQuestion) {
+ username.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_BLUR) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ getFeedbackMessages().clear();
+ target.add(feedbackPanel);
+ try {
+ SecurityQuestionTO read = securityQuestionRestClient.readByUser(username.getModelObject());
+ securityQuestion.setModelObject(read.getContent());
+ } catch (Exception e) {
+ LOG.error("While fetching security question for {}", username.getModelObject(), e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ securityQuestion.setModelObject(null);
+ } finally {
+ target.add(securityQuestion);
+ }
+ }
+ });
+ }
+ form.add(username);
+
+ final Label securityAnswerLabel = new Label("securityAnswerLabel", getString("securityAnswer"));
+ securityAnswerLabel.setOutputMarkupPlaceholderTag(true);
+ securityAnswerLabel.setVisible(handleSecurityQuestion);
+ form.add(securityAnswerLabel);
+ final AjaxTextFieldPanel securityAnswer =
+ new AjaxTextFieldPanel("securityAnswer", "securityAnswer", new Model<String>());
+ securityAnswer.setRequired(handleSecurityQuestion);
+ securityAnswer.setOutputMarkupPlaceholderTag(true);
+ securityAnswer.setVisible(handleSecurityQuestion);
+ form.add(securityAnswer);
+
+ final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(SUBMIT, SUBMIT)) {
+
+ private static final long serialVersionUID = -4804368561204623354L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ try {
+ userSelfRestClient.requestPasswordReset(username.getModelObject(), securityAnswer.getModelObject());
+
+ setResponsePage(new ResultStatusModalPage.Builder(window, new UserTO()).
+ mode(Mode.SELF).build());
+ } catch (Exception e) {
+ LOG.error("While requesting password reset for {}", username.getModelObject(), e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+ form.add(submit);
+ form.setDefaultButton(submit);
+
+ final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ // do nothing
+ }
+ };
+ cancel.setDefaultFormProcessing(false);
+ form.add(cancel);
+
+ add(form);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ResourceModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ResourceModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ResourceModalPage.java
new file mode 100644
index 0000000..0becc1a
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ResourceModalPage.java
@@ -0,0 +1,214 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.panels.AnnotatedBeanPanel;
+import org.apache.syncope.client.console.panels.ResourceConnConfPanel;
+import org.apache.syncope.client.console.panels.ResourceDetailsPanel;
+import org.apache.syncope.client.console.panels.ResourceMappingPanel;
+import org.apache.syncope.client.console.panels.ResourceSecurityPanel;
+import org.apache.syncope.common.lib.to.MappingItemTO;
+import org.apache.syncope.common.lib.to.ResourceTO;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.ResourceModel;
+
+/**
+ * Modal window with Resource form.
+ */
+public class ResourceModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = 1734415311027284221L;
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ public ResourceModalPage(final PageReference pageRef, final ModalWindow window, final ResourceTO resourceTO,
+ final boolean createFlag) {
+
+ super();
+
+ this.add(new Label("new", StringUtils.isBlank(resourceTO.getKey())
+ ? new ResourceModel("new")
+ : new Model(StringUtils.EMPTY)));
+ this.add(new Label("name", StringUtils.isBlank(resourceTO.getKey())
+ ? StringUtils.EMPTY
+ : resourceTO.getKey()));
+
+ final Form<ResourceTO> form = new Form<>(FORM);
+ form.setModel(new CompoundPropertyModel<>(resourceTO));
+
+ //--------------------------------
+ // Resource details panel
+ //--------------------------------
+ form.add(new ResourceDetailsPanel("details", resourceTO,
+ resourceRestClient.getPropagationActionsClasses(), createFlag));
+
+ form.add(new AnnotatedBeanPanel("systeminformation", resourceTO));
+ //--------------------------------
+
+ //--------------------------------
+ // Resource mapping panels
+ //--------------------------------
+ form.add(new ResourceMappingPanel("umapping", resourceTO, AttributableType.USER));
+ form.add(new ResourceMappingPanel("gmapping", resourceTO, AttributableType.GROUP));
+ //--------------------------------
+
+ //--------------------------------
+ // Resource connector configuration panel
+ //--------------------------------
+ ResourceConnConfPanel resourceConnConfPanel = new ResourceConnConfPanel("connconf", resourceTO, createFlag);
+ MetaDataRoleAuthorizationStrategy.authorize(
+ resourceConnConfPanel, ENABLE, xmlRolesReader.getEntitlement("Connectors", "read"));
+ form.add(resourceConnConfPanel);
+ //--------------------------------
+
+ //--------------------------------
+ // Resource security panel
+ //--------------------------------
+ form.add(new ResourceSecurityPanel("security", resourceTO));
+ //--------------------------------
+
+ final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(SUBMIT, SUBMIT)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ final ResourceTO resourceTO = (ResourceTO) form.getDefaultModelObject();
+
+ boolean accountIdError = false;
+
+ if (resourceTO.getUmapping() == null || resourceTO.getUmapping().getItems().isEmpty()) {
+ resourceTO.setUmapping(null);
+ } else {
+ int uAccountIdCount = 0;
+ for (MappingItemTO item : resourceTO.getUmapping().getItems()) {
+ if (item.isAccountid()) {
+ uAccountIdCount++;
+ }
+ }
+ accountIdError = uAccountIdCount != 1;
+ }
+
+ if (resourceTO.getGmapping() == null || resourceTO.getGmapping().getItems().isEmpty()) {
+ resourceTO.setGmapping(null);
+ } else {
+ int rAccountIdCount = 0;
+ for (MappingItemTO item : resourceTO.getGmapping().getItems()) {
+ if (item.isAccountid()) {
+ rAccountIdCount++;
+ }
+ }
+ accountIdError |= rAccountIdCount != 1;
+ }
+
+ if (accountIdError) {
+ error(getString("accountIdValidation"));
+ feedbackPanel.refresh(target);
+ } else {
+ try {
+ if (createFlag) {
+ resourceRestClient.create(resourceTO);
+ } else {
+ resourceRestClient.update(resourceTO);
+ }
+
+ if (pageRef != null && pageRef.getPage() instanceof AbstractBasePage) {
+ ((AbstractBasePage) pageRef.getPage()).setModalResult(true);
+ }
+ window.close(target);
+ } catch (Exception e) {
+ LOG.error("Failure managing resource {}", resourceTO, e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+
+ form.add(submit);
+ form.setDefaultButton(submit);
+
+ final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ }
+ };
+
+ cancel.setDefaultFormProcessing(false);
+ form.add(cancel);
+
+ add(form);
+
+ MetaDataRoleAuthorizationStrategy.authorize(
+ submit, ENABLE, xmlRolesReader.getEntitlement("Resources", createFlag ? "create" : "update"));
+ }
+
+ /**
+ * Generic resource event.
+ */
+ public static class ResourceEvent {
+
+ /**
+ * Request target.
+ */
+ private final AjaxRequestTarget target;
+
+ /**
+ * Constructor.
+ *
+ * @param target request target.
+ */
+ public ResourceEvent(final AjaxRequestTarget target) {
+ this.target = target;
+ }
+
+ /**
+ * Target getter.
+ *
+ * @return request target.
+ */
+ public AjaxRequestTarget getTarget() {
+ return target;
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Resources.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Resources.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Resources.java
new file mode 100644
index 0000000..542cc82
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Resources.java
@@ -0,0 +1,723 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.PreferenceManager;
+import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
+import org.apache.syncope.client.console.panels.AbstractSearchResultPanel;
+import org.apache.syncope.client.console.panels.AjaxDataTablePanel;
+import org.apache.syncope.client.console.rest.ConnectorRestClient;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.LinkPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.ConnInstanceTO;
+import org.apache.syncope.common.lib.to.ResourceTO;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.AttributeModifier;
+import org.apache.wicket.Component;
+import org.apache.wicket.Page;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.attributes.AjaxCallListener;
+import org.apache.wicket.ajax.attributes.AjaxRequestAttributes;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.ISortableDataProvider;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.AbstractReadOnlyModel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.StringResourceModel;
+import org.apache.wicket.request.mapper.parameter.PageParameters;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+/**
+ * Resources WebPage.
+ */
+public class Resources extends BasePage {
+
+ private static final long serialVersionUID = -3789252860990261728L;
+
+ private static final int WIN_HEIGHT = 600;
+
+ private static final int WIN_WIDTH = 1100;
+
+ @SpringBean
+ private ConnectorRestClient connectorRestClient;
+
+ @SpringBean
+ private PreferenceManager prefMan;
+
+ private final ModalWindow createResourceWin;
+
+ private final ModalWindow editResourceWin;
+
+ private final ModalWindow createConnectorWin;
+
+ private final ModalWindow editConnectorWin;
+
+ private final int resourcePaginatorRows;
+
+ private final int connectorPaginatorRows;
+
+ private WebMarkupContainer resourceContainer;
+
+ private WebMarkupContainer connectorContainer;
+
+ /**
+ * Modal window to be used for user status management.
+ */
+ protected final ModalWindow statusmodal = new ModalWindow("statusModal");
+
+ /**
+ * Schemas to be shown modal window height.
+ */
+ private final static int STATUS_MODAL_WIN_HEIGHT = 500;
+
+ /**
+ * Schemas to be shown modal window width.
+ */
+ private final static int STATUS_MODAL_WIN_WIDTH = 700;
+
+ public Resources(final PageParameters parameters) {
+ super(parameters);
+
+ add(createResourceWin = new ModalWindow("createResourceWin"));
+ add(editResourceWin = new ModalWindow("editResourceWin"));
+ add(createConnectorWin = new ModalWindow("createConnectorWin"));
+ add(editConnectorWin = new ModalWindow("editConnectorWin"));
+
+ statusmodal.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ statusmodal.setInitialHeight(STATUS_MODAL_WIN_HEIGHT);
+ statusmodal.setInitialWidth(STATUS_MODAL_WIN_WIDTH);
+ statusmodal.setCookieName("status-modal");
+ add(statusmodal);
+
+ AjaxLink<Void> reloadLink = new ClearIndicatingAjaxLink<Void>("reloadLink", getPageReference()) {
+
+ private static final long serialVersionUID = 3109256773218160485L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ try {
+ connectorRestClient.reload();
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (Exception e) {
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ }
+ feedbackPanel.refresh(target);
+ target.add(connectorContainer);
+ }
+
+ @Override
+ protected void updateAjaxAttributes(final AjaxRequestAttributes attributes) {
+ super.updateAjaxAttributes(attributes);
+
+ final AjaxCallListener ajaxCallListener = new AjaxCallListener() {
+
+ private static final long serialVersionUID = 7160235486520935153L;
+
+ @Override
+ public CharSequence getPrecondition(final Component component) {
+ return "if (!confirm('" + getString("confirmReloadConnectors") + "')) "
+ + "{return false;} else {return true;}";
+ }
+ };
+ attributes.getAjaxCallListeners().add(ajaxCallListener);
+ }
+ };
+ MetaDataRoleAuthorizationStrategy.authorize(reloadLink, ENABLE, xmlRolesReader.getEntitlement(
+ "Connectors", "reload"));
+ add(reloadLink);
+
+ resourcePaginatorRows = prefMan.getPaginatorRows(getRequest(), Constants.PREF_RESOURCES_PAGINATOR_ROWS);
+ connectorPaginatorRows = prefMan.getPaginatorRows(getRequest(), Constants.PREF_CONNECTORS_PAGINATOR_ROWS);
+
+ setupResources();
+ setupConnectors();
+ }
+
+ private void setupResources() {
+ List<IColumn<ResourceTO, String>> columns = new ArrayList<>();
+
+ columns.add(new PropertyColumn<ResourceTO, String>(new StringResourceModel("key", this, null), "key", "key"));
+
+ columns.add(new AbstractColumn<ResourceTO, String>(
+ new StringResourceModel("connector", this, null, "connector")) {
+
+ private static final long serialVersionUID = 8263694778917279290L;
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<ResourceTO>> cellItem, final String componentId,
+ final IModel<ResourceTO> rowModel) {
+
+ final AjaxLink<String> editLink =
+ new ClearIndicatingAjaxLink<String>("link", getPageReference()) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+
+ editConnectorWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ConnectorModalPage(Resources.this.getPageReference(),
+ editConnectorWin,
+ connectorRestClient.read(rowModel.getObject().getConnectorId()));
+ }
+ });
+
+ editConnectorWin.show(target);
+ }
+ };
+ editLink.add(new Label("linkTitle", rowModel.getObject().getConnectorDisplayName()));
+
+ LinkPanel editConnPanel = new LinkPanel(componentId);
+ editConnPanel.add(editLink);
+
+ cellItem.add(editConnPanel);
+
+ MetaDataRoleAuthorizationStrategy.authorize(editConnPanel, ENABLE, xmlRolesReader.
+ getEntitlement(
+ "Connectors", "read"));
+ }
+ });
+
+ columns.add(new AbstractColumn<ResourceTO, String>(
+ new StringResourceModel("propagationPrimary", this, null)) {
+
+ private static final long serialVersionUID = -3503023501954863131L;
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<ResourceTO>> item,
+ final String componentId, final IModel<ResourceTO> model) {
+
+ item.add(new Label(componentId, ""));
+ item.add(new AttributeModifier("class", new Model<>(
+ Boolean.toString(model.getObject().isPropagationPrimary()))));
+ }
+
+ @Override
+ public String getCssClass() {
+ return "narrowcolumn";
+ }
+ });
+
+ columns.add(new PropertyColumn<ResourceTO, String>(new StringResourceModel(
+ "propagationPriority", this, null), "propagationPriority", "propagationPriority") {
+
+ @Override
+ public String getCssClass() {
+ return "narrowcolumn";
+ }
+ });
+
+ columns.add(new AbstractColumn<ResourceTO, String>(new StringResourceModel("actions", this, null, "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public String getCssClass() {
+ return "action";
+ }
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<ResourceTO>> cellItem, final String componentId,
+ final IModel<ResourceTO> model) {
+
+ final ResourceTO resourceTO = model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ statusmodal.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ProvisioningModalPage<>(
+ getPageReference(), statusmodal, model.getObject(), UserTO.class);
+ }
+ });
+
+ statusmodal.show(target);
+ }
+ }, ActionLink.ActionType.MANAGE_USERS, "Resources");
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+
+ statusmodal.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ProvisioningModalPage<>(
+ getPageReference(), statusmodal, model.getObject(), GroupTO.class);
+ }
+ });
+
+ statusmodal.show(target);
+ }
+ }, ActionLink.ActionType.MANAGE_GROUPS, "Resources");
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ resourceTO.setUsyncToken(null);
+ resourceTO.setRsyncToken(null);
+ try {
+ resourceRestClient.update(resourceTO);
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException e) {
+ error(getString(Constants.ERROR) + ":" + e.getMessage());
+
+ LOG.error("While resetting sync token from " + resourceTO.getKey(), e);
+ }
+
+ feedbackPanel.refresh(target);
+ target.add(resourceContainer);
+ }
+ }, ActionLink.ActionType.RESET, "Resources");
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ editResourceWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ResourceModalPage(Resources.this.getPageReference(),
+ editResourceWin, resourceTO, false);
+ }
+ });
+
+ editResourceWin.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, "Resources");
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ resourceRestClient.delete(resourceTO.getKey());
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException e) {
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+
+ LOG.error("While deleting resource " + resourceTO.getKey(), e);
+ }
+
+ feedbackPanel.refresh(target);
+ target.add(resourceContainer);
+ }
+ }, ActionLink.ActionType.DELETE, "Resources");
+
+ cellItem.add(panel);
+ }
+ });
+
+ final AjaxDataTablePanel<ResourceTO, String> table = new AjaxDataTablePanel<>(
+ "resourceDatatable",
+ columns,
+ (ISortableDataProvider<ResourceTO, String>) new ResourcesProvider(),
+ resourcePaginatorRows,
+ Arrays.asList(new ActionLink.ActionType[] { ActionLink.ActionType.DELETE }),
+ resourceRestClient,
+ "key",
+ "Resources",
+ getPageReference());
+
+ resourceContainer = new WebMarkupContainer("resourceContainer");
+ resourceContainer.add(table);
+ resourceContainer.setOutputMarkupId(true);
+
+ add(resourceContainer);
+
+ setWindowClosedCallback(createResourceWin, resourceContainer);
+ setWindowClosedCallback(editResourceWin, resourceContainer);
+
+ createResourceWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ createResourceWin.setInitialHeight(WIN_HEIGHT);
+ createResourceWin.setInitialWidth(WIN_WIDTH);
+ createResourceWin.setCookieName("create-res-modal");
+
+ editResourceWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ editResourceWin.setInitialHeight(WIN_HEIGHT);
+ editResourceWin.setInitialWidth(WIN_WIDTH);
+ editResourceWin.setCookieName("edit-res-modal");
+
+ AjaxLink<Void> createResourceLink =
+ new ClearIndicatingAjaxLink<Void>("createResourceLink", getPageReference()) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ createResourceWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ final ResourceModalPage windows = new ResourceModalPage(Resources.this.
+ getPageReference(),
+ editResourceWin, new ResourceTO(), true);
+ return windows;
+ }
+ });
+
+ createResourceWin.show(target);
+ }
+ };
+
+ MetaDataRoleAuthorizationStrategy.authorize(createResourceLink, ENABLE, xmlRolesReader.getEntitlement(
+ "Resources", "create"));
+
+ add(createResourceLink);
+
+ @SuppressWarnings("rawtypes")
+ final Form paginatorForm = new Form("resourcePaginatorForm");
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ final DropDownChoice rowsChooser = new DropDownChoice("rowsChooser", new PropertyModel(this,
+ "resourcePaginatorRows"), prefMan.getPaginatorChoices());
+
+ rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ prefMan.set(getRequest(), getResponse(), Constants.PREF_RESOURCES_PAGINATOR_ROWS,
+ String.valueOf(resourcePaginatorRows));
+
+ table.setItemsPerPage(resourcePaginatorRows);
+ target.add(resourceContainer);
+ }
+ });
+
+ paginatorForm.add(rowsChooser);
+ add(paginatorForm);
+ }
+
+ private void setupConnectors() {
+ List<IColumn<ConnInstanceTO, String>> columns = new ArrayList<>();
+
+ columns.add(new PropertyColumn<ConnInstanceTO, String>(
+ new StringResourceModel("key", this, null), "key", "key"));
+ columns.add(new PropertyColumn<ConnInstanceTO, String>(
+ new StringResourceModel("name", this, null), "connectorName", "connectorName"));
+ columns.add(new PropertyColumn<ConnInstanceTO, String>(
+ new StringResourceModel("displayName", this, null), "displayName", "displayName"));
+ columns.add(new PropertyColumn<ConnInstanceTO, String>(
+ new StringResourceModel("bundleName", this, null), "bundleName", "bundleName"));
+ columns.add(new PropertyColumn<ConnInstanceTO, String>(
+ new StringResourceModel("version", this, null), "version", "version"));
+ columns.add(new AbstractColumn<ConnInstanceTO, String>(new StringResourceModel("actions", this, null, "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public String getCssClass() {
+ return "action";
+ }
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<ConnInstanceTO>> cellItem, final String componentId,
+ final IModel<ConnInstanceTO> model) {
+
+ final ConnInstanceTO connectorTO = model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ editConnectorWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ConnectorModalPage(Resources.this.getPageReference(), editConnectorWin,
+ connectorTO);
+ }
+ });
+
+ editConnectorWin.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, "Connectors");
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ connectorRestClient.delete(connectorTO.getKey());
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException e) {
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+
+ LOG.error("While deleting connector " + connectorTO.getKey(), e);
+ }
+
+ target.add(connectorContainer);
+ feedbackPanel.refresh(target);
+ }
+ }, ActionLink.ActionType.DELETE, "Connectors");
+
+ cellItem.add(panel);
+ }
+ });
+
+ final AjaxDataTablePanel<ConnInstanceTO, String> table = new AjaxDataTablePanel<ConnInstanceTO, String>(
+ "connectorDatatable",
+ columns,
+ (ISortableDataProvider<ConnInstanceTO, String>) new ConnectorsProvider(),
+ connectorPaginatorRows,
+ Arrays.asList(new ActionLink.ActionType[] { ActionLink.ActionType.DELETE }),
+ connectorRestClient,
+ "key",
+ "Connectors",
+ getPageReference());
+
+ connectorContainer = new WebMarkupContainer("connectorContainer");
+ connectorContainer.add(table);
+ connectorContainer.setOutputMarkupId(true);
+
+ MetaDataRoleAuthorizationStrategy.authorize(connectorContainer, RENDER, xmlRolesReader.getEntitlement(
+ "Connectors", "list"));
+
+ add(connectorContainer);
+
+ setWindowClosedCallback(createConnectorWin, connectorContainer);
+ setWindowClosedCallback(editConnectorWin, connectorContainer);
+
+ createConnectorWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ createConnectorWin.setInitialHeight(WIN_HEIGHT);
+ createConnectorWin.setInitialWidth(WIN_WIDTH);
+ createConnectorWin.setCookieName("create-conn-modal");
+
+ editConnectorWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ editConnectorWin.setInitialHeight(WIN_HEIGHT);
+ editConnectorWin.setInitialWidth(WIN_WIDTH);
+ editConnectorWin.setCookieName("edit-conn-modal");
+
+ AjaxLink<Void> createConnectorLink =
+ new ClearIndicatingAjaxLink<Void>("createConnectorLink", getPageReference()) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ createConnectorWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ ConnectorModalPage form = new ConnectorModalPage(Resources.this.getPageReference(),
+ editConnectorWin, new ConnInstanceTO());
+ return form;
+ }
+ });
+
+ createConnectorWin.show(target);
+ }
+ };
+
+ MetaDataRoleAuthorizationStrategy.authorize(createConnectorLink, ENABLE, xmlRolesReader.getEntitlement(
+ "Connectors", "create"));
+
+ add(createConnectorLink);
+
+ @SuppressWarnings("rawtypes")
+ Form paginatorForm = new Form("connectorPaginatorForm");
+
+ MetaDataRoleAuthorizationStrategy.authorize(paginatorForm, RENDER, xmlRolesReader.getEntitlement(
+ "Connectors", "list"));
+
+ final DropDownChoice<Integer> rowsChooser = new DropDownChoice<Integer>(
+ "rowsChooser",
+ new PropertyModel<Integer>(this,
+ "connectorPaginatorRows"),
+ prefMan.getPaginatorChoices());
+
+ rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(AjaxRequestTarget target) {
+ prefMan.set(getRequest(), getResponse(), Constants.PREF_CONNECTORS_PAGINATOR_ROWS,
+ String.valueOf(connectorPaginatorRows));
+ table.setItemsPerPage(connectorPaginatorRows);
+
+ target.add(connectorContainer);
+ }
+ });
+
+ paginatorForm.add(rowsChooser);
+ add(paginatorForm);
+ }
+
+ class ResourcesProvider extends SortableDataProvider<ResourceTO, String> {
+
+ private static final long serialVersionUID = -9055916672926643975L;
+
+ private final SortableDataProviderComparator<ResourceTO> comparator;
+
+ public ResourcesProvider() {
+ super();
+ //Default sorting
+ setSort("key", SortOrder.ASCENDING);
+ comparator = new SortableDataProviderComparator<>(this);
+ }
+
+ @Override
+ public Iterator<ResourceTO> iterator(final long first, final long count) {
+ List<ResourceTO> list = resourceRestClient.getAll();
+
+ Collections.sort(list, comparator);
+
+ return list.subList((int) first, (int) first + (int) count).iterator();
+ }
+
+ @Override
+ public long size() {
+ return resourceRestClient.getAll().size();
+ }
+
+ @Override
+ public IModel<ResourceTO> model(final ResourceTO resource) {
+ return new AbstractReadOnlyModel<ResourceTO>() {
+
+ private static final long serialVersionUID = 8952474152465381634L;
+
+ @Override
+ public ResourceTO getObject() {
+ return resource;
+ }
+ };
+ }
+ }
+
+ private class ConnectorsProvider extends SortableDataProvider<ConnInstanceTO, String> {
+
+ private static final long serialVersionUID = 4445909568349448518L;
+
+ private final SortableDataProviderComparator<ConnInstanceTO> comparator;
+
+ public ConnectorsProvider() {
+ super();
+ //Default sorting
+ setSort("key", SortOrder.ASCENDING);
+ comparator = new SortableDataProviderComparator<>(this);
+ }
+
+ @Override
+ public Iterator<ConnInstanceTO> iterator(long first, long count) {
+ List<ConnInstanceTO> list = connectorRestClient.getAllConnectors();
+
+ Collections.sort(list, comparator);
+
+ return list.subList((int) first, (int) first + (int) count).iterator();
+ }
+
+ @Override
+ public long size() {
+ return connectorRestClient.getAllConnectors().size();
+ }
+
+ @Override
+ public IModel<ConnInstanceTO> model(final ConnInstanceTO connector) {
+
+ return new AbstractReadOnlyModel<ConnInstanceTO>() {
+
+ private static final long serialVersionUID = -6033068018293569398L;
+
+ @Override
+ public ConnInstanceTO getObject() {
+ return connector;
+ }
+ };
+ }
+ }
+
+ @Override
+ public void onEvent(final IEvent<?> event) {
+ if (event.getPayload() instanceof AbstractSearchResultPanel.EventDataWrapper) {
+ ((AbstractSearchResultPanel.EventDataWrapper) event.getPayload()).getTarget().add(resourceContainer);
+ ((AbstractSearchResultPanel.EventDataWrapper) event.getPayload()).getTarget().add(connectorContainer);
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ResultStatusModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ResultStatusModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ResultStatusModalPage.java
new file mode 100644
index 0000000..e5017e3
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ResultStatusModalPage.java
@@ -0,0 +1,424 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.ConnIdSpecialAttributeName;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.Mode;
+import org.apache.syncope.client.console.commons.status.Status;
+import org.apache.syncope.client.console.commons.status.StatusUtils;
+import org.apache.syncope.common.lib.to.AbstractSubjectTO;
+import org.apache.syncope.common.lib.to.AttrTO;
+import org.apache.syncope.common.lib.to.ConnObjectTO;
+import org.apache.syncope.common.lib.to.PropagationStatus;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.syncope.common.lib.types.PropagationTaskExecStatus;
+import org.apache.wicket.Component;
+import org.apache.wicket.Page;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.behavior.Behavior;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.ComponentTag;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.image.Image;
+import org.apache.wicket.markup.html.list.ListItem;
+import org.apache.wicket.markup.html.list.ListView;
+import org.apache.wicket.markup.html.panel.Fragment;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.request.resource.ContextRelativeResource;
+
+/**
+ * Show user or group status after performing a successful operation.
+ */
+public class ResultStatusModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = 2646115294319713723L;
+
+ private static final String IMG_PREFIX = "/img/statuses/";
+
+ private final AbstractSubjectTO subject;
+
+ private final Mode mode;
+
+ /**
+ * Status management utilities.
+ */
+ private final StatusUtils statusUtils;
+
+ public static class Builder implements Serializable {
+
+ private static final long serialVersionUID = 220361441802274899L;
+
+ private ModalWindow window;
+
+ private Mode mode;
+
+ private AbstractSubjectTO subject;
+
+ public Builder(final ModalWindow window, final AbstractSubjectTO attributable) {
+ this.window = window;
+ this.subject = attributable;
+ }
+
+ public ResultStatusModalPage.Builder mode(final Mode mode) {
+ this.mode = mode;
+ return this;
+ }
+
+ public ResultStatusModalPage build() {
+ return new ResultStatusModalPage(this);
+ }
+ }
+
+ private ResultStatusModalPage(final Builder builder) {
+ super();
+ this.subject = builder.subject;
+ statusUtils = new StatusUtils(this.userRestClient);
+ if (builder.mode == null) {
+ this.mode = Mode.ADMIN;
+ } else {
+ this.mode = builder.mode;
+ }
+
+ final BaseModalPage page = this;
+
+ final WebMarkupContainer container = new WebMarkupContainer("container");
+ container.setOutputMarkupId(true);
+ add(container);
+
+ final Fragment fragment = new Fragment("resultFrag", mode == Mode.SELF
+ ? "userSelfResultFrag"
+ : "propagationResultFrag", this);
+ fragment.setOutputMarkupId(true);
+ container.add(fragment);
+
+ if (mode == Mode.ADMIN) {
+ // add Syncope propagation status
+ PropagationStatus syncope = new PropagationStatus();
+ syncope.setResource("Syncope");
+ syncope.setStatus(PropagationTaskExecStatus.SUCCESS);
+
+ List<PropagationStatus> propagations = new ArrayList<PropagationStatus>();
+ propagations.add(syncope);
+ propagations.addAll(subject.getPropagationStatusTOs());
+
+ fragment.add(new Label("info",
+ ((subject instanceof UserTO) && ((UserTO) subject).getUsername() != null)
+ ? ((UserTO) subject).getUsername()
+ : ((subject instanceof GroupTO) && ((GroupTO) subject).getName() != null)
+ ? ((GroupTO) subject).getName()
+ : String.valueOf(subject.getKey())));
+
+ final ListView<PropagationStatus> propRes = new ListView<PropagationStatus>("resources",
+ propagations) {
+
+ private static final long serialVersionUID = -1020475259727720708L;
+
+ @Override
+ protected void populateItem(final ListItem<PropagationStatus> item) {
+ final PropagationStatus propTO = (PropagationStatus) item.getDefaultModelObject();
+
+ final ListView attributes = getConnObjectView(propTO);
+
+ final Fragment attrhead;
+ if (attributes.getModelObject() == null || attributes.getModelObject().isEmpty()) {
+ attrhead = new Fragment("attrhead", "emptyAttrHeadFrag", page);
+ } else {
+ attrhead = new Fragment("attrhead", "attrHeadFrag", page);
+ }
+
+ item.add(attrhead);
+ item.add(attributes);
+
+ attrhead.add(new Label("resource", propTO.getResource()));
+
+ attrhead.add(new Label("propagation", propTO.getStatus() == null
+ ? "UNDEFINED" : propTO.getStatus().toString()));
+
+ final Image image;
+ final String alt, title;
+ final ModalWindow failureWindow = new ModalWindow("failureWindow");
+ final AjaxLink<?> failureWindowLink = new AjaxLink<Void>("showFailureWindow") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(AjaxRequestTarget target) {
+ failureWindow.show(target);
+ }
+ };
+
+ switch (propTO.getStatus()) {
+
+ case SUCCESS:
+ case SUBMITTED:
+ case CREATED:
+ image = new Image("icon",
+ new ContextRelativeResource(IMG_PREFIX + Status.ACTIVE.toString()
+ + Constants.PNG_EXT));
+ alt = "success icon";
+ title = "success";
+ failureWindow.setVisible(false);
+ failureWindowLink.setEnabled(false);
+ break;
+
+ default:
+ image = new Image("icon",
+ new ContextRelativeResource(IMG_PREFIX + Status.SUSPENDED.toString()
+ + Constants.PNG_EXT));
+ alt = "failure icon";
+ title = "failure";
+ }
+
+ image.add(new Behavior() {
+
+ private static final long serialVersionUID = 1469628524240283489L;
+
+ @Override
+ public void onComponentTag(final Component component, final ComponentTag tag) {
+ tag.put("alt", alt);
+ tag.put("title", title);
+ }
+ });
+ final FailureMessageModalPage executionFailureMessagePage;
+ if (propTO.getFailureReason() == null) {
+ executionFailureMessagePage =
+ new FailureMessageModalPage(failureWindow.getContentId(), StringUtils.EMPTY);
+ } else {
+ executionFailureMessagePage =
+ new FailureMessageModalPage(failureWindow.getContentId(), propTO.getFailureReason());
+ }
+
+ failureWindow.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return executionFailureMessagePage;
+ }
+ });
+ failureWindow.setCookieName("failureWindow");
+ failureWindow.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ failureWindowLink.add(image);
+ attrhead.add(failureWindowLink);
+ attrhead.add(failureWindow);
+ }
+ };
+ fragment.add(propRes);
+ }
+
+ final AjaxLink<Void> close = new IndicatingAjaxLink<Void>("close") {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ builder.window.close(target);
+ }
+ };
+ container.add(close);
+
+ setOutputMarkupId(true);
+ }
+
+ /**
+ * Get remote attributes list view.
+ *
+ * @param propTO propagation TO.
+ * @return list view.
+ */
+ private ListView<String> getConnObjectView(final PropagationStatus propTO) {
+ final ConnObjectTO before = propTO.getBeforeObj();
+ final ConnObjectTO after = propTO.getAfterObj();
+
+ // sorted in reversed presentation order
+ final List<String> head = new ArrayList<String>();
+ if (subject instanceof UserTO) {
+ head.add(ConnIdSpecialAttributeName.PASSWORD);
+ head.add(ConnIdSpecialAttributeName.ENABLE);
+ }
+ head.add(ConnIdSpecialAttributeName.UID);
+ head.add(ConnIdSpecialAttributeName.NAME);
+
+ final Map<String, AttrTO> beforeAttrMap = before == null
+ ? Collections.<String, AttrTO>emptyMap()
+ : before.getPlainAttrMap();
+
+ final Map<String, AttrTO> afterAttrMap = after == null
+ ? Collections.<String, AttrTO>emptyMap()
+ : after.getPlainAttrMap();
+
+ final Set<String> attributes = new HashSet<String>();
+ attributes.addAll(beforeAttrMap.keySet());
+ attributes.addAll(afterAttrMap.keySet());
+
+ if (!(subject instanceof UserTO)) {
+ attributes.remove(ConnIdSpecialAttributeName.PASSWORD);
+ attributes.remove(ConnIdSpecialAttributeName.ENABLE);
+ }
+
+ final List<String> profile = new ArrayList<String>();
+ profile.addAll(attributes);
+ profile.removeAll(head);
+ Collections.sort(profile);
+
+ for (String attr : head) {
+ if (attributes.contains(attr)) {
+ profile.add(0, attr);
+ }
+ }
+
+ return new ListView<String>("attrs", profile) {
+
+ private static final long serialVersionUID = 4949588177564901031L;
+
+ @Override
+ protected void populateItem(final ListItem<String> item) {
+ String name = item.getModelObject();
+
+ final Fragment beforeValue;
+ final Fragment afterValue;
+ if (ConnIdSpecialAttributeName.ENABLE.equals(name)) {
+ beforeValue = getStatusIcon("beforeValue", propTO.getResource(), before);
+ afterValue = getStatusIcon("afterValue", propTO.getResource(), after);
+ } else {
+ beforeValue = getLabelValue("beforeValue", name, beforeAttrMap);
+ afterValue = getLabelValue("afterValue", name, afterAttrMap);
+ }
+
+ item.add(new Label("attrName", new ResourceModel(name, name)));
+
+ item.add(beforeValue);
+ item.add(afterValue);
+ }
+ };
+ }
+
+ /**
+ * Get fragment for attribute value (not remote status).
+ *
+ * @param id component id to be replaced with the fragment content.
+ * @param attrName remote attribute name
+ * @param attrMap remote attributes map.
+ * @return fragment.
+ */
+ private Fragment getLabelValue(final String id, final String attrName, final Map<String, AttrTO> attrMap) {
+ final String value;
+
+ final AttrTO attr = attrMap.get(attrName);
+
+ if (attr == null || attr.getValues() == null || attr.getValues().isEmpty()) {
+ value = "";
+ } else {
+ if (ConnIdSpecialAttributeName.PASSWORD.equals(attrName)) {
+ value = "********";
+ } else {
+ value = attr.getValues().size() > 1
+ ? attr.getValues().toString()
+ : attr.getValues().get(0);
+ }
+ }
+
+ Component label = new Label("value", value.length() > 50 ? value.substring(0, 50) + "..." : value).
+ add(new Behavior() {
+
+ private static final long serialVersionUID = 1469628524240283489L;
+
+ @Override
+ public void onComponentTag(final Component component, final ComponentTag tag) {
+ tag.put("title", value);
+ }
+ });
+
+ final Fragment frag = new Fragment(id, "attrValueFrag", this);
+ frag.add(label);
+
+ return frag;
+ }
+
+ /**
+ * Get fragment for user status icon.
+ *
+ * @param id component id to be replaced with the fragment content
+ * @param resourceName resource name
+ * @param objectTO connector object TO
+ * @return fragment.
+ */
+ private Fragment getStatusIcon(final String id, final String resourceName, final ConnObjectTO objectTO) {
+ final Image image;
+ final String alt, title;
+ switch (statusUtils.getStatusBean(subject, resourceName, objectTO, this.subject instanceof GroupTO).getStatus()) {
+
+ case ACTIVE:
+ image = new Image("status",
+ new ContextRelativeResource(IMG_PREFIX + Status.ACTIVE.toString() + Constants.PNG_EXT));
+ alt = "active icon";
+ title = "Enabled";
+ break;
+
+ case SUSPENDED:
+ image = new Image("status",
+ new ContextRelativeResource(IMG_PREFIX + Status.SUSPENDED.toString() + Constants.PNG_EXT));
+ alt = "inactive icon";
+ title = "Disabled";
+ break;
+
+ default:
+ image = null;
+ alt = null;
+ title = null;
+ }
+
+ final Fragment frag;
+ if (image == null) {
+ frag = new Fragment(id, "emptyFrag", this);
+ } else {
+ image.add(new Behavior() {
+
+ private static final long serialVersionUID = 1469628524240283489L;
+
+ @Override
+ public void onComponentTag(final Component component, final ComponentTag tag) {
+ tag.put("alt", alt);
+ tag.put("title", title);
+ tag.put("width", "12px");
+ tag.put("height", "12px");
+ }
+ });
+
+ frag = new Fragment(id, "remoteStatusFrag", this);
+ frag.add(image);
+ }
+
+ return frag;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/SchedTaskModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/SchedTaskModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/SchedTaskModalPage.java
new file mode 100644
index 0000000..6222717
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/SchedTaskModalPage.java
@@ -0,0 +1,68 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.List;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
+import org.apache.syncope.common.lib.to.SchedTaskTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.model.PropertyModel;
+
+/**
+ * Modal window with Task form (to stop and start execution).
+ */
+public class SchedTaskModalPage extends AbstractSchedTaskModalPage {
+
+ private static final long serialVersionUID = -2501860242590060867L;
+
+ public SchedTaskModalPage(final ModalWindow window, final SchedTaskTO taskTO, final PageReference callerPageRef) {
+
+ super(window, taskTO, callerPageRef);
+
+ final IModel<List<String>> classNames = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ return taskRestClient.getJobClasses();
+ }
+ };
+
+ final AjaxDropDownChoicePanel<String> className = new AjaxDropDownChoicePanel<String>("jobClassName",
+ getString("class"), new PropertyModel<String>(taskTO, "jobClassName"));
+ className.setChoices(classNames.getObject());
+ className.addRequiredLabel();
+ className.setEnabled(taskTO.getKey() == 0);
+ className.setStyleSheet("ui-widget-content ui-corner-all long_dynamicsize");
+ profile.add(className);
+ }
+
+ @Override
+ public void submitAction(final SchedTaskTO taskTO) {
+ if (taskTO.getKey() > 0) {
+ taskRestClient.updateSchedTask(taskTO);
+ } else {
+ taskRestClient.createSchedTask(taskTO);
+ }
+ }
+}
[38/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourceMappingPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourceMappingPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourceMappingPanel.java
deleted file mode 100644
index 406676f..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourceMappingPanel.java
+++ /dev/null
@@ -1,644 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.JexlHelpUtils;
-import org.apache.syncope.client.console.panels.ResourceConnConfPanel.ConnConfModEvent;
-import org.apache.syncope.client.console.rest.ConnectorRestClient;
-import org.apache.syncope.client.console.rest.SchemaRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDecoratedCheckbox;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.FieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.MappingPurposePanel;
-import org.apache.syncope.common.lib.to.ConnIdObjectClassTO;
-import org.apache.syncope.common.lib.to.ConnInstanceTO;
-import org.apache.syncope.common.lib.to.MappingItemTO;
-import org.apache.syncope.common.lib.to.MappingTO;
-import org.apache.syncope.common.lib.to.ResourceTO;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.syncope.common.lib.types.ConnConfProperty;
-import org.apache.syncope.common.lib.types.IntMappingType;
-import org.apache.syncope.common.lib.types.MappingPurpose;
-import org.apache.wicket.Component;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.attributes.AjaxCallListener;
-import org.apache.wicket.ajax.attributes.AjaxRequestAttributes;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-/**
- * Resource mapping panel.
- */
-public class ResourceMappingPanel extends Panel {
-
- private static final long serialVersionUID = -7982691107029848579L;
-
- /**
- * Mapping field style sheet.
- */
- private static final String FIELD_STYLE = "ui-widget-content ui-corner-all short_fixedsize";
-
- /**
- * Mapping field style sheet.
- */
- private static final String DEF_FIELD_STYLE = "ui-widget-content ui-corner-all";
-
- /**
- * Mapping field style sheet.
- */
- private static final String SHORT_FIELD_STYLE = "ui-widget-content ui-corner-all veryshort_fixedsize";
-
- /**
- * Schema rest client.
- */
- @SpringBean
- private SchemaRestClient schemaRestClient;
-
- /**
- * ConnInstance rest client.
- */
- @SpringBean
- private ConnectorRestClient connRestClient;
-
- /**
- * Resource schema name.
- */
- private final List<String> schemaNames;
-
- /**
- * Add mapping button.
- */
- private final AjaxButton addMappingBtn;
-
- /**
- * All mappings.
- */
- private final ListView<MappingItemTO> mappings;
-
- /**
- * External resource to be updated.
- */
- private final ResourceTO resourceTO;
-
- /**
- * User / group.
- */
- private final AttributableType attrType;
-
- /**
- * Mapping container.
- */
- private final WebMarkupContainer mappingContainer;
-
- /**
- * AccountLink container.
- */
- private final WebMarkupContainer accountLinkContainer;
-
- private final AjaxCheckBoxPanel accountLinkCheckbox;
-
- private MappingTO getMapping() {
- MappingTO result = null;
-
- if (AttributableType.USER == this.attrType) {
- if (this.resourceTO.getUmapping() == null) {
- this.resourceTO.setUmapping(new MappingTO());
- }
- result = this.resourceTO.getUmapping();
- }
- if (AttributableType.GROUP == this.attrType) {
- if (this.resourceTO.getGmapping() == null) {
- this.resourceTO.setGmapping(new MappingTO());
- }
- result = this.resourceTO.getGmapping();
- }
-
- return result;
- }
-
- /**
- * Attribute Mapping Panel.
- *
- * @param id panel id
- * @param resourceTO external resource
- * @param attrType USER / GROUP
- */
- public ResourceMappingPanel(final String id, final ResourceTO resourceTO, final AttributableType attrType) {
- super(id);
- setOutputMarkupId(true);
-
- this.resourceTO = resourceTO;
- this.attrType = attrType;
-
- this.mappingContainer = new WebMarkupContainer("mappingContainer");
- this.mappingContainer.setOutputMarkupId(true);
- add(this.mappingContainer);
-
- this.accountLinkContainer = new WebMarkupContainer("accountLinkContainer");
- this.accountLinkContainer.setOutputMarkupId(true);
- add(this.accountLinkContainer);
-
- if (this.resourceTO.getConnectorId() != null && this.resourceTO.getConnectorId() > 0) {
- schemaNames = getSchemaNames(this.resourceTO.getConnectorId(), this.resourceTO.getConnConfProperties());
-
- setEnabled();
- } else {
- schemaNames = Collections.<String>emptyList();
- }
-
- final WebMarkupContainer jexlHelp = JexlHelpUtils.getJexlHelpWebContainer("jexlHelp");
-
- AjaxLink<Void> questionMarkJexlHelp = JexlHelpUtils.getAjaxLink(jexlHelp, "questionMarkJexlHelp");
- mappingContainer.add(questionMarkJexlHelp);
- questionMarkJexlHelp.add(jexlHelp);
-
- final Label passwordLabel = new Label("passwordLabel", new ResourceModel("password"));
- mappingContainer.add(passwordLabel);
- if (AttributableType.USER != ResourceMappingPanel.this.attrType) {
- passwordLabel.setVisible(false);
- }
-
- Collections.sort(getMapping().getItems(), new Comparator<MappingItemTO>() {
-
- @Override
- public int compare(final MappingItemTO left, final MappingItemTO right) {
- int compared;
- if (left == null && right == null) {
- compared = 0;
- } else if (left == null) {
- compared = 1;
- } else if (right == null) {
- compared = -1;
- } else if (left.getPurpose() == MappingPurpose.BOTH && right.getPurpose() != MappingPurpose.BOTH) {
- compared = -1;
- } else if (left.getPurpose() != MappingPurpose.BOTH && right.getPurpose() == MappingPurpose.BOTH) {
- compared = 1;
- } else if (left.getPurpose() == MappingPurpose.PROPAGATION
- && (right.getPurpose() == MappingPurpose.SYNCHRONIZATION || right.getPurpose()
- == MappingPurpose.NONE)) {
- compared = -1;
- } else if (left.getPurpose() == MappingPurpose.SYNCHRONIZATION
- && right.getPurpose() == MappingPurpose.PROPAGATION) {
- compared = 1;
- } else if (left.getPurpose() == MappingPurpose.SYNCHRONIZATION
- && right.getPurpose() == MappingPurpose.NONE) {
- compared = -1;
- } else if (left.getPurpose() == MappingPurpose.NONE
- && right.getPurpose() != MappingPurpose.NONE) {
- compared = 1;
- } else if (left.isAccountid()) {
- compared = -1;
- } else if (right.isAccountid()) {
- compared = 1;
- } else if (left.isPassword()) {
- compared = -1;
- } else if (right.isPassword()) {
- compared = 1;
- } else {
- compared = left.getIntAttrName().compareTo(right.getIntAttrName());
- }
- return compared;
- }
- });
-
- mappings = new ListView<MappingItemTO>("mappings", getMapping().getItems()) {
-
- private static final long serialVersionUID = 4949588177564901031L;
-
- @Override
- protected void populateItem(final ListItem<MappingItemTO> item) {
- final MappingItemTO mapItem = item.getModelObject();
- if (mapItem.getPurpose() == null) {
- mapItem.setPurpose(MappingPurpose.BOTH);
- }
-
- AttributableType entity = null;
- if (mapItem.getIntMappingType() != null) {
- entity = mapItem.getIntMappingType().getAttributableType();
- }
-
- final List<IntMappingType> attrTypes = new ArrayList<IntMappingType>(getAttributeTypes(entity));
-
- item.add(new AjaxDecoratedCheckbox("toRemove", new Model<Boolean>(Boolean.FALSE)) {
-
- private static final long serialVersionUID = 7170946748485726506L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- int index = -1;
- for (int i = 0; i < getMapping().getItems().size() && index == -1; i++) {
- if (mapItem.equals(getMapping().getItems().get(i))) {
- index = i;
- }
- }
-
- if (index != -1) {
- getMapping().getItems().remove(index);
- item.getParent().removeAll();
- target.add(ResourceMappingPanel.this);
- }
- }
-
- @Override
- protected void updateAjaxAttributes(final AjaxRequestAttributes attributes) {
- super.updateAjaxAttributes(attributes);
-
- final AjaxCallListener ajaxCallListener = new AjaxCallListener() {
-
- private static final long serialVersionUID = 7160235486520935153L;
-
- @Override
- public CharSequence getPrecondition(final Component component) {
- return "if (!confirm('" + getString("confirmDelete") + "')) return false;";
- }
- };
- attributes.getAjaxCallListeners().add(ajaxCallListener);
- }
- });
-
- final AjaxDropDownChoicePanel<String> intAttrNames =
- new AjaxDropDownChoicePanel<String>("intAttrNames", getString("intAttrNames"),
- new PropertyModel<String>(mapItem, "intAttrName"), false);
- intAttrNames.setChoices(schemaNames);
- intAttrNames.setRequired(true);
- intAttrNames.setStyleSheet(FIELD_STYLE);
- intAttrNames.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- }
- });
- item.add(intAttrNames);
-
- final AjaxDropDownChoicePanel<IntMappingType> intMappingTypes =
- new AjaxDropDownChoicePanel<IntMappingType>("intMappingTypes",
- new ResourceModel("intMappingTypes", "intMappingTypes").getObject(),
- new PropertyModel<IntMappingType>(mapItem, "intMappingType"));
- intMappingTypes.setRequired(true);
- intMappingTypes.setChoices(attrTypes);
- intMappingTypes.setStyleSheet(FIELD_STYLE);
- item.add(intMappingTypes);
-
- final AjaxDropDownChoicePanel<AttributableType> entitiesPanel =
- new AjaxDropDownChoicePanel<AttributableType>("entities",
- new ResourceModel("entities", "entities").getObject(), new Model<AttributableType>(
- entity));
- entitiesPanel.setChoices(attrType == AttributableType.GROUP
- ? Collections.<AttributableType>singletonList(AttributableType.GROUP)
- : Arrays.asList(AttributableType.values()));
- entitiesPanel.setStyleSheet(DEF_FIELD_STYLE);
- entitiesPanel.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- attrTypes.clear();
- attrTypes.addAll(getAttributeTypes(entitiesPanel.getModelObject()));
- intMappingTypes.setChoices(attrTypes);
-
- intAttrNames.setChoices(Collections.<String>emptyList());
-
- target.add(intMappingTypes.getField());
- target.add(intAttrNames.getField());
- }
- });
- item.add(entitiesPanel);
-
- final FieldPanel<String> extAttrNames = new AjaxTextFieldPanel("extAttrName",
- new ResourceModel("extAttrNames", "extAttrNames").getObject(),
- new PropertyModel<String>(mapItem, "extAttrName"));
- ((AjaxTextFieldPanel) extAttrNames).setChoices(schemaNames);
-
- boolean required = false;
- if (mapItem.isPassword()) {
- ((AjaxTextFieldPanel) extAttrNames).setModelObject(null);
- } else {
- required = true;
- }
- extAttrNames.setRequired(required);
- extAttrNames.setEnabled(required);
- extAttrNames.setStyleSheet(FIELD_STYLE);
- item.add(extAttrNames);
-
- final AjaxTextFieldPanel mandatory = new AjaxTextFieldPanel("mandatoryCondition",
- new ResourceModel("mandatoryCondition", "mandatoryCondition").getObject(),
- new PropertyModel<String>(mapItem, "mandatoryCondition"));
- mandatory.setChoices(Arrays.asList(new String[] { "true", "false" }));
- mandatory.setStyleSheet(SHORT_FIELD_STYLE);
- item.add(mandatory);
-
- final AjaxCheckBoxPanel accountId = new AjaxCheckBoxPanel("accountId",
- new ResourceModel("accountId", "accountId").getObject(),
- new PropertyModel<Boolean>(mapItem, "accountid"));
- accountId.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- if (accountId.getModelObject()) {
- mapItem.setMandatoryCondition("true");
- mandatory.setEnabled(false);
- } else {
- mapItem.setMandatoryCondition("false");
- mandatory.setEnabled(true);
- }
- target.add(mandatory);
- }
- });
- item.add(accountId);
-
- final AjaxCheckBoxPanel password = new AjaxCheckBoxPanel("password",
- new ResourceModel("password", "password").getObject(),
- new PropertyModel<Boolean>(mapItem, "password"));
- password.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- extAttrNames.setEnabled(!mapItem.isAccountid() && !password.getModelObject());
- extAttrNames.setModelObject(null);
- extAttrNames.setRequired(!password.getModelObject());
- target.add(extAttrNames);
-
- setAccountId(intMappingTypes.getModelObject(), accountId, password);
- target.add(accountId);
- }
- });
- item.add(password);
- if (AttributableType.USER != ResourceMappingPanel.this.attrType) {
- password.setVisible(false);
- }
-
- final WebMarkupContainer purpose = new WebMarkupContainer("purpose");
- purpose.setOutputMarkupId(Boolean.TRUE);
-
- final MappingPurposePanel panel = new MappingPurposePanel("purposeActions",
- new PropertyModel<MappingPurpose>(mapItem, "purpose"), purpose);
-
- purpose.add(panel);
-
- item.add(purpose);
-
- intMappingTypes.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- setAttrNames(intMappingTypes.getModelObject(), intAttrNames);
- target.add(intAttrNames);
-
- setAccountId(intMappingTypes.getModelObject(), accountId, password);
- target.add(accountId);
- }
- });
-
- setAttrNames(mapItem.getIntMappingType(), intAttrNames);
- setAccountId(mapItem.getIntMappingType(), accountId, password);
- }
- };
-
- mappings.setReuseItems(true);
- mappingContainer.add(mappings);
-
- addMappingBtn = new IndicatingAjaxButton("addMappingBtn", new ResourceModel("add")) {
-
- private static final long serialVersionUID = -4804368561204623354L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- getMapping().getItems().add(new MappingItemTO());
- target.add(ResourceMappingPanel.this);
- }
- };
- addMappingBtn.setDefaultFormProcessing(false);
- addMappingBtn.setEnabled(this.resourceTO.getConnectorId() != null && this.resourceTO.getConnectorId() > 0);
- mappingContainer.add(addMappingBtn);
-
- boolean accountLinkEnabled = false;
- if (getMapping().getAccountLink() != null) {
- accountLinkEnabled = true;
- }
- accountLinkCheckbox = new AjaxCheckBoxPanel("accountLinkCheckbox",
- new ResourceModel("accountLinkCheckbox", "accountLinkCheckbox").getObject(),
- new Model<Boolean>(Boolean.valueOf(accountLinkEnabled)));
- accountLinkCheckbox.setEnabled(true);
-
- accountLinkContainer.add(accountLinkCheckbox);
-
- final AjaxTextFieldPanel accountLink = new AjaxTextFieldPanel("accountLink",
- new ResourceModel("accountLink", "accountLink").getObject(),
- new PropertyModel<String>(getMapping(), "accountLink"));
- accountLink.setEnabled(accountLinkEnabled);
- accountLinkContainer.add(accountLink);
-
- accountLinkCheckbox.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- if (accountLinkCheckbox.getModelObject()) {
- accountLink.setEnabled(Boolean.TRUE);
- accountLink.setModelObject("");
- } else {
- accountLink.setEnabled(Boolean.FALSE);
- accountLink.setModelObject("");
- }
-
- target.add(accountLink);
- }
- });
- }
-
- private List<String> getSchemaNames(final Long connectorId, final Set<ConnConfProperty> conf) {
- final ConnInstanceTO connInstanceTO = new ConnInstanceTO();
- connInstanceTO.setKey(connectorId);
- connInstanceTO.getConfiguration().addAll(conf);
-
- return connRestClient.getSchemaNames(connInstanceTO);
- }
-
- private void setEnabled() {
- final ConnInstanceTO connInstanceTO = new ConnInstanceTO();
- connInstanceTO.setKey(this.resourceTO.getConnectorId());
- connInstanceTO.getConfiguration().addAll(this.resourceTO.getConnConfProperties());
-
- List<ConnIdObjectClassTO> objectClasses = connRestClient.getSupportedObjectClasses(connInstanceTO);
-
- boolean enabled = objectClasses.isEmpty()
- || (AttributableType.USER == attrType && objectClasses.contains(ConnIdObjectClassTO.ACCOUNT))
- || (AttributableType.GROUP == attrType && objectClasses.contains(ConnIdObjectClassTO.GROUP));
- this.mappingContainer.setEnabled(enabled);
- this.mappingContainer.setVisible(enabled);
- this.accountLinkContainer.setEnabled(enabled);
- this.accountLinkContainer.setVisible(enabled);
-
- if (!enabled) {
- getMapping().getItems().clear();
- getMapping().setAccountLink(null);
- if (this.accountLinkCheckbox != null) {
- this.accountLinkCheckbox.setModelObject(null);
- }
- }
- }
-
- @Override
- public void onEvent(final IEvent<?> event) {
- if (event.getPayload() instanceof ConnConfModEvent) {
- final AjaxRequestTarget target = ((ConnConfModEvent) event.getPayload()).getTarget();
-
- final List<ConnConfProperty> conf = ((ConnConfModEvent) event.getPayload()).getConfiguration();
-
- mappings.removeAll();
-
- addMappingBtn.setEnabled(resourceTO.getConnectorId() != null && resourceTO.getConnectorId() > 0);
-
- schemaNames.clear();
- schemaNames.addAll(getSchemaNames(resourceTO.getConnectorId(), new HashSet<ConnConfProperty>(conf)));
-
- setEnabled();
-
- target.add(this);
- }
- }
-
- /**
- * Set attribute names for a drop down choice list.
- *
- * @param type attribute type.
- * @param toBeUpdated drop down choice to be updated.
- */
- private void setAttrNames(final IntMappingType type, final AjaxDropDownChoicePanel<String> toBeUpdated) {
- toBeUpdated.setRequired(true);
- toBeUpdated.setEnabled(true);
-
- if (type == null || type.getAttributableType() == null) {
- toBeUpdated.setChoices(Collections.<String>emptyList());
- } else {
- switch (type) {
- // user attribute names
- case UserPlainSchema:
- case GroupPlainSchema:
- case MembershipPlainSchema:
- toBeUpdated.setChoices(schemaRestClient.getPlainSchemaNames(type.getAttributableType()));
- break;
-
- case UserDerivedSchema:
- case GroupDerivedSchema:
- case MembershipDerivedSchema:
- toBeUpdated.setChoices(schemaRestClient.getDerSchemaNames(type.getAttributableType()));
- break;
-
- case UserVirtualSchema:
- case GroupVirtualSchema:
- case MembershipVirtualSchema:
- toBeUpdated.setChoices(schemaRestClient.getVirSchemaNames(type.getAttributableType()));
- break;
-
- case UserId:
- case Password:
- case Username:
- case GroupId:
- case GroupName:
- default:
- toBeUpdated.setRequired(false);
- toBeUpdated.setEnabled(false);
- toBeUpdated.setChoices(Collections.<String>emptyList());
- }
- }
- }
-
- /**
- * Enable/Disable accountId checkbox.
- *
- * @param type attribute type.
- * @param accountId accountId checkbox.
- * @param password password checkbox.
- */
- private void setAccountId(final IntMappingType type, final AjaxCheckBoxPanel accountId,
- final AjaxCheckBoxPanel password) {
-
- if (type != null && type.getAttributableType() != null) {
- switch (type) {
- case UserVirtualSchema:
- case GroupVirtualSchema:
- case MembershipVirtualSchema:
- // Virtual accountId is not permitted
- case Password:
- // AccountId cannot be derived from password.
- accountId.setReadOnly(true);
- accountId.setModelObject(false);
- break;
-
- default:
- if (password.getModelObject()) {
- accountId.setReadOnly(true);
- accountId.setModelObject(false);
- } else {
- accountId.setReadOnly(false);
- }
- }
- }
- }
-
- /**
- * Get all attribute types from a selected attribute type.
- *
- * @param entity entity.
- * @return all attribute types.
- */
- private List<IntMappingType> getAttributeTypes(final AttributableType entity) {
- final List<IntMappingType> res = new ArrayList<IntMappingType>();
-
- if (entity != null) {
- res.addAll(IntMappingType.getAttributeTypes(AttributableType.valueOf(entity.name())));
- }
-
- return res;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourceSecurityPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourceSecurityPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourceSecurityPanel.java
deleted file mode 100644
index 40e031a..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourceSecurityPanel.java
+++ /dev/null
@@ -1,189 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Map;
-import org.apache.syncope.client.console.rest.PolicyRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.common.lib.to.AbstractPolicyTO;
-import org.apache.syncope.common.lib.to.ResourceTO;
-import org.apache.syncope.common.lib.types.PolicyType;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.ChoiceRenderer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class ResourceSecurityPanel extends Panel {
-
- private static final long serialVersionUID = -7982691107029848579L;
-
- @SpringBean
- private PolicyRestClient policyRestClient;
-
- private IModel<Map<Long, String>> passwordPolicies = null;
-
- private IModel<Map<Long, String>> accountPolicies = null;
-
- private IModel<Map<Long, String>> syncPolicies = null;
-
- public ResourceSecurityPanel(final String id, final ResourceTO resourceTO) {
-
- super(id);
-
- setOutputMarkupId(true);
-
- passwordPolicies = new LoadableDetachableModel<Map<Long, String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected Map<Long, String> load() {
- Map<Long, String> res = new HashMap<>();
- for (AbstractPolicyTO policyTO : policyRestClient.getPolicies(PolicyType.PASSWORD, false)) {
- res.put(policyTO.getKey(), policyTO.getDescription());
- }
- return res;
- }
- };
-
- accountPolicies = new LoadableDetachableModel<Map<Long, String>>() {
-
- private static final long serialVersionUID = -2012833443695917883L;
-
- @Override
- protected Map<Long, String> load() {
- Map<Long, String> res = new HashMap<>();
- for (AbstractPolicyTO policyTO : policyRestClient.getPolicies(PolicyType.ACCOUNT, false)) {
- res.put(policyTO.getKey(), policyTO.getDescription());
- }
- return res;
- }
- };
-
- syncPolicies = new LoadableDetachableModel<Map<Long, String>>() {
-
- private static final long serialVersionUID = -2012833443695917883L;
-
- @Override
- protected Map<Long, String> load() {
- Map<Long, String> res = new HashMap<>();
- for (AbstractPolicyTO policyTO : policyRestClient.getPolicies(PolicyType.SYNC, false)) {
- res.put(policyTO.getKey(), policyTO.getDescription());
- }
- return res;
- }
- };
-
- final WebMarkupContainer securityContainer = new WebMarkupContainer("security");
-
- securityContainer.setOutputMarkupId(true);
- add(securityContainer);
-
- // -------------------------------
- // Password policy specification
- // -------------------------------
- final AjaxDropDownChoicePanel<Long> passwordPolicy = new AjaxDropDownChoicePanel<Long>("passwordPolicy",
- new ResourceModel("passwordPolicy", "passwordPolicy").getObject(), new PropertyModel<Long>(resourceTO,
- "passwordPolicy"));
-
- passwordPolicy.setChoiceRenderer(new PolicyRenderer(PolicyType.PASSWORD));
-
- passwordPolicy.setChoices(new ArrayList<>(passwordPolicies.getObject().keySet()));
-
- ((DropDownChoice<?>) passwordPolicy.getField()).setNullValid(true);
-
- securityContainer.add(passwordPolicy);
- // -------------------------------
-
- // -------------------------------
- // Account policy specification
- // -------------------------------
- final AjaxDropDownChoicePanel<Long> accountPolicy = new AjaxDropDownChoicePanel<Long>("accountPolicy",
- new ResourceModel("accountPolicy", "accountPolicy").getObject(), new PropertyModel<Long>(resourceTO,
- "accountPolicy"));
-
- accountPolicy.setChoiceRenderer(new PolicyRenderer(PolicyType.ACCOUNT));
-
- accountPolicy.setChoices(new ArrayList<Long>(accountPolicies.getObject().keySet()));
-
- ((DropDownChoice<?>) accountPolicy.getField()).setNullValid(true);
-
- securityContainer.add(accountPolicy);
- // -------------------------------
-
- // -------------------------------
- // Sync policy specification
- // -------------------------------
- final AjaxDropDownChoicePanel<Long> syncPolicy = new AjaxDropDownChoicePanel<Long>("syncPolicy",
- new ResourceModel("syncPolicy", "syncPolicy").getObject(), new PropertyModel<Long>(resourceTO,
- "syncPolicy"));
-
- syncPolicy.setChoiceRenderer(new PolicyRenderer(PolicyType.SYNC));
-
- syncPolicy.setChoices(new ArrayList<Long>(syncPolicies.getObject().keySet()));
-
- ((DropDownChoice<?>) syncPolicy.getField()).setNullValid(true);
-
- securityContainer.add(syncPolicy);
- // -------------------------------
- }
-
- private class PolicyRenderer extends ChoiceRenderer<Long> {
-
- private static final long serialVersionUID = 8060500161321947000L;
-
- private PolicyType type;
-
- public PolicyRenderer(final PolicyType type) {
- super();
- this.type = type;
- }
-
- @Override
- public Object getDisplayValue(final Long object) {
- switch (type) {
- case GLOBAL_ACCOUNT:
- case ACCOUNT:
- return accountPolicies.getObject().get(object);
- case GLOBAL_PASSWORD:
- case PASSWORD:
- return passwordPolicies.getObject().get(object);
- case GLOBAL_SYNC:
- case SYNC:
- return syncPolicies.getObject().get(object);
- default:
- return "";
- }
- }
-
- @Override
- public String getIdValue(final Long object, final int index) {
- return String.valueOf(object != null
- ? object
- : 0L);
- }
- };
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourcesPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourcesPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourcesPanel.java
deleted file mode 100644
index 028b3a0..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/ResourcesPanel.java
+++ /dev/null
@@ -1,177 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.GroupTreeBuilder;
-import org.apache.syncope.client.console.commons.SelectChoiceRenderer;
-import org.apache.syncope.client.console.commons.status.StatusUtils;
-import org.apache.syncope.client.console.rest.ResourceRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPalettePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.NonI18nPalette;
-import org.apache.syncope.common.lib.to.AbstractSubjectTO;
-import org.apache.syncope.common.lib.to.MembershipTO;
-import org.apache.syncope.common.lib.to.ResourceTO;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.extensions.markup.html.form.palette.Palette;
-import org.apache.wicket.extensions.markup.html.form.palette.component.Recorder;
-import org.apache.wicket.markup.html.form.IChoiceRenderer;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.util.ListModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class ResourcesPanel extends Panel {
-
- private static final long serialVersionUID = -8728071019777410008L;
-
- @SpringBean
- private ResourceRestClient resourceRestClient;
-
- @SpringBean
- private GroupTreeBuilder groupTreeBuilder;
-
- private final AbstractSubjectTO subjectTO;
-
- private final Set<String> previousResources;
-
- private final List<String> allResources;
-
- public static class Builder implements Serializable {
-
- private static final long serialVersionUID = 8644108944633025494L;
-
- private String id;
-
- private Object to;
-
- private StatusPanel statusPanel;
-
- public Builder(final String id) {
- this.id = id;
- }
-
- public Builder attributableTO(final Object to) {
- this.to = to;
- return this;
- }
-
- public Builder statusPanel(final StatusPanel statusPanel) {
- this.statusPanel = statusPanel;
- return this;
- }
-
- public ResourcesPanel build() {
- return new ResourcesPanel(this);
- }
- }
-
- private ResourcesPanel(final Builder builder) {
- super(builder.id);
- subjectTO = (AbstractSubjectTO) builder.to;
- previousResources = new HashSet<>(subjectTO.getResources());
- allResources = new ArrayList<>();
- for (ResourceTO resourceTO : resourceRestClient.getAll()) {
- allResources.add(resourceTO.getKey());
- }
- Collections.sort(allResources);
-
- AjaxPalettePanel<String> resourcesPalette = null;
-
- if (subjectTO instanceof UserTO) {
- resourcesPalette = new AjaxRecordingPalettePanel<>("resourcesPalette",
- new PropertyModel<List<String>>(subjectTO, "resources"),
- new ListModel<>(allResources), builder.statusPanel);
- } else if (subjectTO instanceof GroupTO) {
- resourcesPalette = new AjaxPalettePanel<>("resourcesPalette",
- new PropertyModel<List<String>>(subjectTO, "resources"), new ListModel<>(allResources));
- }
- add(resourcesPalette);
- }
-
- private class AjaxRecordingPalettePanel<T> extends AjaxPalettePanel<T> {
-
- private static final long serialVersionUID = -4215625881756021988L;
-
- private final StatusPanel statusPanel;
-
- public AjaxRecordingPalettePanel(final String id, final IModel<List<T>> model, final ListModel<T> choices,
- final StatusPanel statusPanel) {
-
- super(id, model, choices, new SelectChoiceRenderer<T>(), false, false);
- this.statusPanel = statusPanel;
- }
-
- @Override
- protected Palette<T> createPalette(final IModel<List<T>> model, final ListModel<T> choices,
- final IChoiceRenderer<T> renderer, final boolean allowOrder, final boolean allowMoveAll) {
-
- return new NonI18nPalette<T>("paletteField", model, choices, renderer, 8, allowOrder, false) {
-
- private static final long serialVersionUID = -3415146226879212841L;
-
- @Override
- protected Recorder<T> newRecorderComponent() {
- Recorder<T> recorder = super.newRecorderComponent();
- recorder.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = 5538299138211283825L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- if (subjectTO instanceof UserTO) {
- UserTO userTO = (UserTO) subjectTO;
-
- Set<String> resourcesToRemove = new HashSet<>(previousResources);
- resourcesToRemove.removeAll(userTO.getResources());
- if (!resourcesToRemove.isEmpty()) {
- Set<String> resourcesAssignedViaMembership = new HashSet<>();
- for (MembershipTO membTO : userTO.getMemberships()) {
- GroupTO groupTO = groupTreeBuilder.findGroup(membTO.getGroupKey());
- if (groupTO != null) {
- resourcesAssignedViaMembership.addAll(groupTO.getResources());
- }
- }
- resourcesToRemove.removeAll(resourcesAssignedViaMembership);
- }
-
- previousResources.clear();
- previousResources.addAll(userTO.getResources());
-
- StatusUtils.update(
- userTO, statusPanel, target, userTO.getResources(), resourcesToRemove);
- }
- }
- });
- return recorder;
- }
- };
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/SchedTasks.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/SchedTasks.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/SchedTasks.java
deleted file mode 100644
index 205bfa5..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/SchedTasks.java
+++ /dev/null
@@ -1,286 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.pages.SchedTaskModalPage;
-import org.apache.syncope.client.console.pages.Tasks;
-import org.apache.syncope.client.console.pages.Tasks.TasksProvider;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.AbstractTaskTO;
-import org.apache.syncope.common.lib.to.SchedTaskTO;
-import org.apache.wicket.Component;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.StringResourceModel;
-import org.apache.wicket.request.http.WebResponse;
-
-public class SchedTasks extends AbstractTasks {
-
- private static final long serialVersionUID = 525486152284253354L;
-
- private int paginatorRows;
-
- private WebMarkupContainer container;
-
- private ModalWindow window;
-
- private AjaxDataTablePanel<AbstractTaskTO, String> table;
-
- public SchedTasks(final String id, final PageReference pageRef) {
- super(id, pageRef);
-
- container = new WebMarkupContainer("container");
- container.setOutputMarkupId(true);
- add(container);
-
- window = new ModalWindow("taskWin");
- window.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- window.setInitialHeight(WIN_HEIGHT);
- window.setInitialWidth(WIN_WIDTH);
- window.setCookieName(VIEW_TASK_WIN_COOKIE_NAME);
- add(window);
-
- ((Tasks) pageRef.getPage()).setWindowClosedCallback(window, container);
-
- paginatorRows = prefMan.getPaginatorRows(getWebRequest(), Constants.PREF_SCHED_TASKS_PAGINATOR_ROWS);
-
- table = Tasks.updateTaskTable(
- getColumns(),
- new TasksProvider<SchedTaskTO>(restClient, paginatorRows, getId(), SchedTaskTO.class),
- container,
- 0,
- pageRef,
- restClient);
-
- container.add(table);
-
- @SuppressWarnings("rawtypes")
- Form paginatorForm = new Form("PaginatorForm");
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- final DropDownChoice rowsChooser = new DropDownChoice("rowsChooser", new PropertyModel(this, "paginatorRows"),
- prefMan.getPaginatorChoices());
-
- rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- prefMan.set(getWebRequest(), (WebResponse) getResponse(), Constants.PREF_SCHED_TASKS_PAGINATOR_ROWS,
- String.valueOf(paginatorRows));
-
- table = Tasks.updateTaskTable(
- getColumns(),
- new TasksProvider<SchedTaskTO>(restClient, paginatorRows, getId(), SchedTaskTO.class),
- container,
- table == null ? 0 : (int) table.getCurrentPage(),
- pageRef,
- restClient);
-
- target.add(container);
- }
- });
-
- paginatorForm.add(rowsChooser);
- add(paginatorForm);
-
- AjaxLink createLink = new ClearIndicatingAjaxLink("createLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new SchedTaskModalPage(window, new SchedTaskTO(), pageRef);
- }
- });
-
- window.show(target);
- }
- };
-
- MetaDataRoleAuthorizationStrategy.authorize(
- createLink, RENDER, xmlRolesReader.getEntitlement(TASKS, "create"));
-
- add(createLink);
- }
-
- private List<IColumn<AbstractTaskTO, String>> getColumns() {
- final List<IColumn<AbstractTaskTO, String>> columns = new ArrayList<IColumn<AbstractTaskTO, String>>();
-
- columns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("key", this, null), "key", "key"));
- columns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("name", this, null), "name", "name"));
- columns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("description", this, null), "description", "description"));
- columns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("class", this, null), "jobClassName", "jobClassName"));
- columns.add(new DatePropertyColumn<AbstractTaskTO>(
- new StringResourceModel("lastExec", this, null), "lastExec", "lastExec"));
- columns.add(new DatePropertyColumn<AbstractTaskTO>(
- new StringResourceModel("nextExec", this, null), "nextExec", "nextExec"));
- columns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("latestExecStatus", this, null), "latestExecStatus", "latestExecStatus"));
-
- columns.add(new ActionColumn<AbstractTaskTO, String>(new StringResourceModel("actions", this, null, "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public ActionLinksPanel getActions(final String componentId, final IModel<AbstractTaskTO> model) {
-
- final SchedTaskTO taskTO = (SchedTaskTO) model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, pageRef);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new SchedTaskModalPage(window, taskTO, pageRef);
- }
- });
-
- window.show(target);
- }
- }, ActionLink.ActionType.EDIT, TASKS);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- restClient.startExecution(taskTO.getKey(), false);
- getSession().info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
-
- ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
- target.add(container);
- }
- }, ActionLink.ActionType.EXECUTE, TASKS);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- restClient.startExecution(taskTO.getKey(), true);
- getSession().info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
-
- ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
- target.add(container);
- }
- }, ActionLink.ActionType.DRYRUN, TASKS);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- restClient.delete(taskTO.getKey(), SchedTaskTO.class);
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
- target.add(container);
- ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
- }
- }, ActionLink.ActionType.DELETE, TASKS);
-
- return panel;
- }
-
- @Override
- public Component getHeader(final String componentId) {
- @SuppressWarnings("rawtypes")
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), pageRef);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- if (target != null) {
- target.add(table);
- }
- }
- }, ActionLink.ActionType.RELOAD, TASKS, "list");
-
- return panel;
- }
- });
- return columns;
- }
-
- @Override
- public void onEvent(final IEvent<?> event) {
- if (event.getPayload() instanceof AbstractSearchResultPanel.EventDataWrapper) {
- ((AbstractSearchResultPanel.EventDataWrapper) event.getPayload()).getTarget().add(container);
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/SearchClause.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/SearchClause.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/SearchClause.java
deleted file mode 100644
index 488a2cf..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/SearchClause.java
+++ /dev/null
@@ -1,129 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.io.Serializable;
-import org.apache.commons.lang3.builder.EqualsBuilder;
-import org.apache.commons.lang3.builder.HashCodeBuilder;
-import org.apache.commons.lang3.builder.ReflectionToStringBuilder;
-import org.apache.commons.lang3.builder.ToStringStyle;
-
-public class SearchClause implements Serializable {
-
- private static final long serialVersionUID = 2010794463096110104L;
-
- public enum Operator {
-
- AND,
- OR;
-
- }
-
- public enum Type {
-
- ATTRIBUTE,
- MEMBERSHIP,
- RESOURCE,
- ENTITLEMENT;
-
- }
-
- public enum Comparator {
-
- IS_NULL,
- IS_NOT_NULL,
- EQUALS,
- NOT_EQUALS,
- GREATER_OR_EQUALS,
- GREATER_THAN,
- LESS_OR_EQUALS,
- LESS_THAN;
-
- }
-
- private Operator operator;
-
- private Type type;
-
- private String property;
-
- private Comparator comparator;
-
- private String value;
-
- public SearchClause() {
- setOperator(SearchClause.Operator.AND);
- setComparator(SearchClause.Comparator.EQUALS);
- }
-
- public Operator getOperator() {
- return operator;
- }
-
- public void setOperator(final Operator operator) {
- this.operator = operator;
- }
-
- public Type getType() {
- return type;
- }
-
- public void setType(final Type type) {
- this.type = type;
- }
-
- public String getProperty() {
- return property;
- }
-
- public void setProperty(final String property) {
- this.property = property;
- }
-
- public Comparator getComparator() {
- return comparator;
- }
-
- public void setComparator(final Comparator comparator) {
- this.comparator = comparator;
- }
-
- public String getValue() {
- return value;
- }
-
- public void setValue(final String value) {
- this.value = value;
- }
-
- @Override
- public boolean equals(final Object obj) {
- return EqualsBuilder.reflectionEquals(this, obj);
- }
-
- @Override
- public int hashCode() {
- return HashCodeBuilder.reflectionHashCode(this);
- }
-
- @Override
- public String toString() {
- return ReflectionToStringBuilder.toString(this, ToStringStyle.MULTI_LINE_STYLE);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/SearchView.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/SearchView.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/SearchView.java
deleted file mode 100644
index c081cd3..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/SearchView.java
+++ /dev/null
@@ -1,461 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.List;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxLink;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.IChoiceRenderer;
-import org.apache.wicket.markup.html.form.TextField;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.model.PropertyModel;
-
-public class SearchView extends ListView<SearchClause> {
-
- private static final long serialVersionUID = -527351923968737757L;
-
- private final WebMarkupContainer searchFormContainer;
-
- private final boolean required;
-
- private final IModel<List<SearchClause.Type>> types;
-
- private final IModel<List<String>> anames;
-
- private final IModel<List<String>> dnames;
-
- private final IModel<List<String>> groupNames;
-
- private final IModel<List<String>> resourceNames;
-
- private final IModel<List<String>> entitlements;
-
- public SearchView(final String id, final List<? extends SearchClause> list,
- final WebMarkupContainer searchFormContainer,
- final boolean required,
- final IModel<List<SearchClause.Type>> types,
- final IModel<List<String>> anames,
- final IModel<List<String>> dnames,
- final IModel<List<String>> groupNames,
- final IModel<List<String>> resourceNames,
- final IModel<List<String>> entitlements) {
-
- super(id, list);
-
- this.searchFormContainer = searchFormContainer;
- this.required = required;
- this.types = types;
- this.anames = anames;
- this.dnames = dnames;
- this.groupNames = groupNames;
- this.resourceNames = resourceNames;
- this.entitlements = entitlements;
- }
-
- @Override
- protected void populateItem(final ListItem<SearchClause> item) {
- final SearchClause searchClause = item.getModelObject();
-
- final DropDownChoice<SearchClause.Operator> operator = new DropDownChoice<SearchClause.Operator>("operator",
- new PropertyModel<SearchClause.Operator>(searchClause, "operator"),
- Arrays.asList(SearchClause.Operator.values()));
- operator.setOutputMarkupPlaceholderTag(true);
- operator.setNullValid(false);
- operator.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- }
- });
- item.add(operator);
- if (item.getIndex() == 0) {
- operator.setVisible(false);
- }
-
- final DropDownChoice<SearchClause.Type> type = new DropDownChoice<SearchClause.Type>("type",
- new PropertyModel<SearchClause.Type>(searchClause, "type"), types);
- type.setOutputMarkupId(true);
- type.setRequired(required);
- type.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- target.add(searchFormContainer);
- }
- });
- item.add(type);
-
- @SuppressWarnings("unchecked")
- final DropDownChoice<String> property = new DropDownChoice<String>("property",
- new PropertyModel<String>(searchClause, "property"), (IModel) null);
- property.setOutputMarkupId(true);
- property.setRequired(required);
- property.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- }
- });
- item.add(property);
-
- final TextField<String> value = new TextField<String>("value",
- new PropertyModel<String>(searchClause, "value"));
- value.setOutputMarkupId(true);
- value.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- }
- });
- item.add(value);
-
- final DropDownChoice<SearchClause.Comparator> comparator =
- new DropDownChoice<SearchClause.Comparator>("comparator",
- new PropertyModel<SearchClause.Comparator>(searchClause, "comparator"),
- Collections.<SearchClause.Comparator>emptyList());
- comparator.setOutputMarkupId(true);
- comparator.setNullValid(false);
- comparator.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- if (type.getModelObject() == SearchClause.Type.ATTRIBUTE) {
- if (comparator.getModelObject() == SearchClause.Comparator.IS_NULL
- || comparator.getModelObject() == SearchClause.Comparator.IS_NOT_NULL) {
-
- value.setModelObject(null);
- value.setEnabled(false);
- } else {
- value.setEnabled(true);
- }
- target.add(value);
- }
- }
- });
- comparator.setRequired(required);
- item.add(comparator);
-
- AjaxLink<Void> drop = new IndicatingAjaxLink<Void>("drop") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- SearchView.this.getModel().getObject().remove(item.getModelObject());
- target.add(searchFormContainer);
- }
- };
- item.add(drop);
- if (item.getIndex() == 0) {
- drop.setVisible(false);
- drop.setEnabled(false);
- } else {
- drop.setVisible(true);
- drop.setEnabled(true);
- }
-
- final AjaxLink<Void> add = new IndicatingAjaxLink<Void>("add") {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- SearchClause clause = new SearchClause();
- SearchView.this.getModel().getObject().add(clause);
- target.add(searchFormContainer);
- }
- };
- item.add(add);
-
- if (searchClause == null || searchClause.getType() == null) {
- property.setChoices(Collections.<String>emptyList());
- } else {
- switch (searchClause.getType()) {
- case ATTRIBUTE:
- final List<String> names = new ArrayList<String>(dnames.getObject());
- if (anames.getObject() != null && !anames.getObject().isEmpty()) {
- names.addAll(anames.getObject());
- }
- Collections.sort(names);
- property.setChoices(names);
-
- comparator.setChoices(new LoadableDetachableModel<List<SearchClause.Comparator>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<SearchClause.Comparator> load() {
- return Arrays.asList(SearchClause.Comparator.values());
- }
- });
- comparator.setChoiceRenderer(new IChoiceRenderer<SearchClause.Comparator>() {
-
- private static final long serialVersionUID = -9086043750227867686L;
-
- @Override
- public Object getDisplayValue(final SearchClause.Comparator object) {
- String display;
-
- switch (object) {
- case IS_NULL:
- display = "NULL";
- break;
-
- case IS_NOT_NULL:
- display = "NOT NULL";
- break;
-
- case EQUALS:
- display = "==";
- break;
-
- case NOT_EQUALS:
- display = "!=";
- break;
-
- case LESS_THAN:
- display = "<";
- break;
-
- case LESS_OR_EQUALS:
- display = "<=";
- break;
-
- case GREATER_THAN:
- display = ">";
- break;
-
- case GREATER_OR_EQUALS:
- display = ">=";
- break;
-
- default:
- display = StringUtils.EMPTY;
- }
-
- return display;
- }
-
- @Override
- public String getIdValue(final SearchClause.Comparator object, int index) {
- return getDisplayValue(object).toString();
- }
- });
- if (!comparator.isEnabled()) {
- comparator.setEnabled(true);
- comparator.setRequired(true);
- }
-
- if (!value.isEnabled()) {
- value.setEnabled(true);
- }
- break;
-
- case MEMBERSHIP:
- property.setChoices(groupNames);
- property.setChoiceRenderer(new IChoiceRenderer<String>() {
-
- private static final long serialVersionUID = -4288397951948436434L;
-
- @Override
- public Object getDisplayValue(final String object) {
- return object;
- }
-
- @Override
- public String getIdValue(final String object, final int index) {
- return object;
- }
- });
-
- comparator.setChoices(new LoadableDetachableModel<List<SearchClause.Comparator>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<SearchClause.Comparator> load() {
- List<SearchClause.Comparator> comparators = new ArrayList<SearchClause.Comparator>();
- comparators.add(SearchClause.Comparator.EQUALS);
- comparators.add(SearchClause.Comparator.NOT_EQUALS);
- return comparators;
- }
- });
- comparator.setChoiceRenderer(new IChoiceRenderer<SearchClause.Comparator>() {
-
- private static final long serialVersionUID = -9086043750227867686L;
-
- @Override
- public Object getDisplayValue(final SearchClause.Comparator object) {
- String display;
-
- switch (object) {
- case EQUALS:
- display = "IN";
- break;
-
- case NOT_EQUALS:
- display = "NOT IN";
- break;
-
- default:
- display = StringUtils.EMPTY;
- }
-
- return display;
- }
-
- @Override
- public String getIdValue(final SearchClause.Comparator object, final int index) {
- return getDisplayValue(object).toString();
- }
- });
-
- value.setEnabled(false);
- value.setModelObject("");
-
- break;
-
- case RESOURCE:
- property.setChoices(resourceNames);
-
- comparator.setChoices(new LoadableDetachableModel<List<SearchClause.Comparator>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<SearchClause.Comparator> load() {
- List<SearchClause.Comparator> comparators = new ArrayList<SearchClause.Comparator>();
- comparators.add(SearchClause.Comparator.EQUALS);
- comparators.add(SearchClause.Comparator.NOT_EQUALS);
- return comparators;
- }
- });
- comparator.setChoiceRenderer(new IChoiceRenderer<SearchClause.Comparator>() {
-
- private static final long serialVersionUID = -9086043750227867686L;
-
- @Override
- public Object getDisplayValue(final SearchClause.Comparator object) {
- String display;
-
- switch (object) {
- case EQUALS:
- display = "HAS";
- break;
-
- case NOT_EQUALS:
- display = "HAS NOT";
- break;
-
- default:
- display = StringUtils.EMPTY;
- }
-
- return display;
- }
-
- @Override
- public String getIdValue(final SearchClause.Comparator object, final int index) {
- return getDisplayValue(object).toString();
- }
- });
-
- value.setEnabled(false);
- value.setModelObject("");
-
- break;
-
- case ENTITLEMENT:
- property.setChoices(entitlements);
-
- comparator.setChoices(new LoadableDetachableModel<List<SearchClause.Comparator>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<SearchClause.Comparator> load() {
- List<SearchClause.Comparator> comparators = new ArrayList<SearchClause.Comparator>();
- comparators.add(SearchClause.Comparator.EQUALS);
- comparators.add(SearchClause.Comparator.NOT_EQUALS);
- return comparators;
- }
- });
- comparator.setChoiceRenderer(new IChoiceRenderer<SearchClause.Comparator>() {
-
- private static final long serialVersionUID = -9086043750227867686L;
-
- @Override
- public Object getDisplayValue(final SearchClause.Comparator object) {
- String display;
-
- switch (object) {
- case EQUALS:
- display = "HAS";
- break;
-
- case NOT_EQUALS:
- display = "HAS NOT";
- break;
-
- default:
- display = StringUtils.EMPTY;
- }
-
- return display;
- }
-
- @Override
- public String getIdValue(final SearchClause.Comparator object, final int index) {
- return getDisplayValue(object).toString();
- }
- });
-
- value.setEnabled(false);
- value.setModelObject("");
-
- break;
-
- default:
- property.setChoices(Collections.<String>emptyList());
- }
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/SecurityQuestionPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/SecurityQuestionPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/SecurityQuestionPanel.java
deleted file mode 100644
index 8658cf6..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/SecurityQuestionPanel.java
+++ /dev/null
@@ -1,98 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.Map;
-import java.util.TreeMap;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.rest.SecurityQuestionRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.common.lib.to.SecurityQuestionTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.IChoiceRenderer;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class SecurityQuestionPanel extends Panel {
-
- private static final long serialVersionUID = -790642213865180146L;
-
- private final Map<Long, String> questions = new TreeMap<Long, String>();
-
- @SpringBean
- private SecurityQuestionRestClient restClient;
-
- public SecurityQuestionPanel(final String id, final UserTO userTO) {
- super(id);
- setOutputMarkupId(true);
-
- for (SecurityQuestionTO secQues : restClient.list()) {
- questions.put(secQues.getKey(), secQues.getContent());
- }
-
- final AjaxTextFieldPanel securityAnswer = new AjaxTextFieldPanel("securityAnswer", "securityAnswer",
- new PropertyModel<String>(userTO, "securityAnswer"));
- securityAnswer.getField().setOutputMarkupId(true);
- securityAnswer.setEnabled(false);
- add(securityAnswer);
-
- final AjaxDropDownChoicePanel<Long> securityQuestion =
- new AjaxDropDownChoicePanel<>("securityQuestion", "securityQuestion",
- new PropertyModel<Long>(userTO, "securityQuestion"));
- ((DropDownChoice) securityQuestion.getField()).setNullValid(true);
- securityQuestion.setChoices(new ArrayList<>(questions.keySet()));
- securityQuestion.setStyleSheet("ui-widget-content ui-corner-all long_dynamicsize");
- securityQuestion.getField().setOutputMarkupId(true);
- securityQuestion.setChoiceRenderer(new IChoiceRenderer<Long>() {
-
- private static final long serialVersionUID = 2693996850376268294L;
-
- @Override
- public Object getDisplayValue(final Long object) {
- return questions.get(object);
- }
-
- @Override
- public String getIdValue(final Long object, final int index) {
- return questions.get(object);
- }
- });
- securityQuestion.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- if (securityQuestion.getModelObject() == null) {
- securityAnswer.setModelObject(null);
- } else {
- securityAnswer.setEnabled(true);
- }
- target.add(SecurityQuestionPanel.this);
- }
- });
- add(securityQuestion);
- }
-}
[28/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchResultPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchResultPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchResultPanel.html
deleted file mode 100644
index 487165b..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchResultPanel.html
+++ /dev/null
@@ -1,43 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
-
- <div wicket:id="container">
- <span wicket:id="resultTable">[Table]</span>
-
- <span style="float:right">
- <form wicket:id="paginator" style="display:inline">
- <label><wicket:message key="displayRows"/></label>
- <select class="text ui-widget-content ui-corner-all" wicket:id="rowsChooser"/>
- </form>
- </span>
- </div>
-
- <div wicket:id="editModal">
- </div>
-
- <div wicket:id="displayModal">
- </div>
-
- <div wicket:id="statusModal">
- </div>
-
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchResultPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchResultPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchResultPanel.properties
deleted file mode 100644
index 6f016a4..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchResultPanel.properties
+++ /dev/null
@@ -1,30 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-displayRows=Display rows
-
-firstname=Firstname
-surname=Surname
-userId=User Id
-edit=Edit
-delete=Delete
-id=Id
-status=Status
-token=Token
-username=Username
-creationDate=Creation Date
-tokenValued=Valued
-tokenNotValued=Not valued
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchResultPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchResultPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchResultPanel_it.properties
deleted file mode 100644
index 02b3b57..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchResultPanel_it.properties
+++ /dev/null
@@ -1,30 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-displayRows=display rows
-
-firstname=Nome
-surname=Cognome
-userId=User Id
-edit=Edit
-delete=Rimuovi
-id=Id
-status=Stato
-token=Token
-username=Username
-creationDate=Data Creazione
-tokenValued=Valued
-tokenNotValued=Not valued
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchResultPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchResultPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchResultPanel_pt_BR.properties
deleted file mode 100644
index 1591edc..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AbstractSearchResultPanel_pt_BR.properties
+++ /dev/null
@@ -1,30 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-displayRows=Mostrar linhas
-
-firstname=Nome
-surname=Sobrenome
-userId=Identificador do Usu\u00E1rio
-edit=Alterar
-delete=Excluir
-id=Identificador
-status=Estatus
-token=Token
-username=Nome de Usu\u00E1rio
-creationDate=Data de Cria\u00E7\u00E3o
-tokenValued=Atribu\u00EDdo
-tokenNotValued=N\u00E3o Atribu\u00EDdo
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AccountInformationPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AccountInformationPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AccountInformationPanel.html
deleted file mode 100644
index 5e0fe54..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AccountInformationPanel.html
+++ /dev/null
@@ -1,67 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
-
- <div class="infoleft">
- <div class="infolabel">
- <wicket:message key="lastLoginDate"/>:
- </div>
- <div>
- <span wicket:id="lastLoginDate"/>
- </div>
- </div>
-
- <div class="inforight">
- <div class="infolabel">
- <wicket:message key="failedLogins"/>:
- </div>
- <div>
- <span wicket:id="failedLogins"/>
- </div>
- </div>
-
- <div class="infoleft">
- <div class="infolabel">
- <wicket:message key="changePwdDate"/>:
- </div>
- <div>
- <span wicket:id="changePwdDate"/>
- </div>
- </div>
-
- <div class="inforight">
- <div class="infolabel">
- <wicket:message key="tokenExpireTime"/>
- </div>
- <div>
- <span wicket:id="tokenExpireTime"/>
- </div>
- </div>
-
- <div class="inforow">
- <div class="infolabel">
- <wicket:message key="token"/>:
- </div>
- <div style="word-wrap: break-word; width: 550px; margin-left: 155px;">
- <span wicket:id="token"/>
- </div>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AccountInformationPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AccountInformationPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AccountInformationPanel.properties
deleted file mode 100644
index e3ba3f5..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AccountInformationPanel.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-changePwdDate=Last Change Password Date
-lastLoginDate=Last Login Date
-failedLogins=Subsequent Failed Logins
-token=Token
-tokenExpireTime=Token Expire Time
-confirmPassword=Password (confirm)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AccountInformationPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AccountInformationPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AccountInformationPanel_it.properties
deleted file mode 100644
index 844a0c3..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AccountInformationPanel_it.properties
+++ /dev/null
@@ -1,23 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-creationDate=Data Di Creazione
-changePwdDate=Data Ultimo Cambio Password
-lastLoginDate=Data Di Ultimo Login
-failedLogins=Login Consecutivi Falliti
-token=Token
-tokenExpireTime=Scadenza Token
-confirmPassword=Password (conferma)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AccountInformationPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AccountInformationPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AccountInformationPanel_pt_BR.properties
deleted file mode 100644
index 27e99f5..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AccountInformationPanel_pt_BR.properties
+++ /dev/null
@@ -1,23 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-creationDate=Data de Cria\u00E7\u00E3o
-changePwdDate=Data da \u00DAltima Troca de Senha
-lastLoginDate=Data do \u00DAltimo Login
-failedLogins=Falhas Subsequentes de Logins
-token=Token
-tokenExpireTime=Tempo de Expira\u00E7\u00E3o do Token
-confirmPassword=Senha (confirmar)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/ActionDataTablePanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ActionDataTablePanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/ActionDataTablePanel.html
deleted file mode 100644
index 5ad205f..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ActionDataTablePanel.html
+++ /dev/null
@@ -1,45 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <link rel="stylesheet" type="text/css" href="css/bulk.css" media="all"/>
- </wicket:head>
- <wicket:panel>
-
- <form wicket:id="groupForm">
- <span wicket:id="checkgroup">
- <table class="ui-widget ui-widget-content table-hover" wicket:id="dataTable">[Data Table]</table>
- </span>
-
- <div id="actionRow" class="pageRowElement">
- <div id="actions">
- <div id="actionPanel" wicket:id="actionPanelContainer" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only">
- <span wicket:id="actions">[Actions]</span>
- </div>
-
- <div id="cancelBtmForm">
- <input type="button" wicket:id="cancel" id="cancel"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"/>
- </div>
- </div>
- </div>
- </form>
-
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AjaxDataTablePanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AjaxDataTablePanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AjaxDataTablePanel.html
deleted file mode 100644
index f67ba10..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AjaxDataTablePanel.html
+++ /dev/null
@@ -1,47 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <link rel="stylesheet" type="text/css" href="css/bulk.css" media="all"/>
- </wicket:head>
- <wicket:panel>
- <span wicket:id="tablePanel">[Table panel]</span>
- <div wicket:id="bulkModal" />
-
- <wicket:fragment wicket:id="bulkAvailable">
- <form wicket:id="groupForm">
- <span wicket:id="checkgroup">
- <table class="ui-widget ui-widget-content table-hover" wicket:id="dataTable">[DataTable]</table>
- </span>
- </form>
- <div class="bulkAction">
- <div class="bulkActionCell" style="width: 40px">
- <a href="#" wicket:id="bulkActionLink">
- <img src="img/actions/bulk.png" alt="bulk action icon" title="Bulk action"/>
- </a>
- </div>
- </div>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="bulkNotAvailable">
- <table class="ui-widget ui-widget-content table-hover" wicket:id="dataTable">[DataTable]</table>
- </wicket:fragment>
-
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AnnotatedBeanPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AnnotatedBeanPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AnnotatedBeanPanel.html
deleted file mode 100644
index 4d459ce..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AnnotatedBeanPanel.html
+++ /dev/null
@@ -1,98 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html>
- <wicket:head>
- <style>
- div.information{
- margin-top: 30px;
- border: 1px solid #DDDDDD;
- font-size: 8px;
- color: #555555;
- display: inline-table;
- width: 100%;
- clear: both;
- float:none;
- }
-
- div.infolabel{
- margin-left: 5px;
- float:left;
- width: 150px;
- font-weight: bold
- }
-
- div.infoleft{
- float:left;
- display: inline-table;
- width: 50%
- }
-
- div.inforight{
- display: inline-table;
- width: 50%
- }
-
- div.inforow{
- display: inline-table;
- width: 100%
- }
- </style>
- </wicket:head>
- <wicket:panel>
- <div class="information">
- <div class="infoleft">
- <div class="infolabel">
- <wicket:message key="creationDate"/>:
- </div>
- <div>
- <span wicket:id="creationDate" />
- </div>
- </div>
-
- <div class="inforight">
- <div class="infolabel">
- <wicket:message key="lastChangeDate"/>:
- </div>
- <div>
- <span wicket:id="lastChangeDate" />
- </div>
- </div>
-
- <div class="infoleft">
- <div class="infolabel">
- <wicket:message key="creator"/>:
- </div>
- <div>
- <span wicket:id="creator" />
- </div>
- </div>
-
- <div class="inforight">
- <div class="infolabel">
- <wicket:message key="lastModifier"/>:
- </div>
- <div>
- <span wicket:id="lastModifier" />
- </div>
- </div>
-
- <wicket:child />
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AnnotatedBeanPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AnnotatedBeanPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AnnotatedBeanPanel.properties
deleted file mode 100644
index 54a0fcf..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AnnotatedBeanPanel.properties
+++ /dev/null
@@ -1,20 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-creationDate=Creation Date
-creator=Creator
-lastChangeDate=Last change date
-lastModifier=Last modifier
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AnnotatedBeanPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AnnotatedBeanPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AnnotatedBeanPanel_it.properties
deleted file mode 100644
index 7fae3ab..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AnnotatedBeanPanel_it.properties
+++ /dev/null
@@ -1,20 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-creationDate=Data Di Creazione
-creator=Creatore
-lastChangeDate=Data Di Ultima Modifica
-lastModifier=Ultimo Modificatore
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AnnotatedBeanPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AnnotatedBeanPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AnnotatedBeanPanel_pt_BR.properties
deleted file mode 100644
index 689436f..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AnnotatedBeanPanel_pt_BR.properties
+++ /dev/null
@@ -1,20 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-creationDate=Data de Cria\u00e7\u00e3o
-creator=Criador
-lastChangeDate=Data De \u00daltima Altera\u00e7\u00e3o
-lastModifier=\u00daltima Modificador
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AttrTemplatesPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AttrTemplatesPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AttrTemplatesPanel.html
deleted file mode 100644
index 2b7ef52..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AttrTemplatesPanel.html
+++ /dev/null
@@ -1,58 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <script type="text/javascript">
- $(document).ready(function() {
- $("#attrTemplateTabs").tabs();
- });
- </script>
- </wicket:head>
- <wicket:panel>
- <div id="attrTemplateTabs" class="ui-tabs ui-widget ui-widget-content ui-corner-all">
- <ul>
- <li class="tabs-selected"><a href="#rplainattr"><wicket:message key="rplainattr"/></a></li>
- <li><a href="#rderattr"><wicket:message key="rderattr"/></a></li>
- <li><a href="#rvirattr"><wicket:message key="rvirattr"/></a></li>
- <li><a href="#mplainattr"><wicket:message key="mplainattr"/></a></li>
- <li><a href="#mderattr"><wicket:message key="mderattr"/></a></li>
- <li><a href="#mvirattr"><wicket:message key="mvirattr"/></a></li>
- </ul>
-
- <div id="rplainattr">
- <div wicket:id="gPlainAttrTemplates"/>
- </div>
- <div id="rderattr">
- <div wicket:id="gDerAttrTemplates"/>
- </div>
- <div id="rvirattr">
- <div wicket:id="gVirAttrTemplates"/>
- </div>
- <div id="mplainattr">
- <div wicket:id="mPlainAttrTemplates"/>
- </div>
- <div id="mderattr">
- <div wicket:id="mDerAttrTemplates"/>
- </div>
- <div id="mvirattr">
- <div wicket:id="mVirAttrTemplates"/>
- </div>
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AttrTemplatesPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AttrTemplatesPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AttrTemplatesPanel.properties
deleted file mode 100644
index 94da979..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AttrTemplatesPanel.properties
+++ /dev/null
@@ -1,23 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-rplainattr=Plain
-rderattr=Derived
-rvirattr=Virtual
-mplainattr=Plain (Membership)
-mderattr=Derived (Membership)
-mvirattr=Virtual (Membership)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AttrTemplatesPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AttrTemplatesPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AttrTemplatesPanel_it.properties
deleted file mode 100644
index d30ff59..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AttrTemplatesPanel_it.properties
+++ /dev/null
@@ -1,23 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-rplainattr=Normali
-rderattr=Derivati
-rvirattr=Virtuali
-mplainattr=Normali (Membership)
-mderattr=Derivati (Membership)
-mvirattr=Virtuali (Membership)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AttrTemplatesPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AttrTemplatesPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AttrTemplatesPanel_pt_BR.properties
deleted file mode 100644
index 5fd7c3a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AttrTemplatesPanel_pt_BR.properties
+++ /dev/null
@@ -1,23 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-
-rplainattr=Normal
-rderattr=Derivado
-rvirattr=Virtual
-mplainattr=Normal (Membro)
-mderattr=Derivado (Membro)
-mvirattr=Virtual (Membro)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/AuditEventsPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AuditEventsPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/AuditEventsPanel.html
deleted file mode 100644
index c86473a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/AuditEventsPanel.html
+++ /dev/null
@@ -1,122 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <style>
- .container {
- display: block;
- width: 100%;
- }
-
- .label {
- font-size: 12px;
- vertical-align: middle;
- font-family: Verdana,Tahoma,sans-serif;
- display: table-cell;
- width: 300px;
- height: 20px;
- }
-
- .divtableheaderlabel {
- font-weight: bold;
- float: left;
- margin-left: 5px;
- display: table-cell;
- width: 70px;
- }
-
- .divtableheadercell {
- display: inline-table;
- vertical-align: top;
- text-align: right;
- width: 105px;
- height: 20px;
- }
-
- .divtablecheckcolumn {
- display: table-cell;
- vertical-align: top;
- text-align: right;
- width: 105px;
- }
-
- .divtablecheck {
- width: 105px;
- height: 20px;
- }
- </style>
- </wicket:head>
- <wicket:panel>
- <div class="container">
- <div style="display:inline-table;">
- <div class="label">
-
- </div>
- <div style="display: table-cell">
- <div class="divtableheadercell">
- <div class="divtableheaderlabel">
- <label wicket:id="successLabel"/>
- </div>
- <div style="display: table-cell">
- <input type="checkbox" wicket:id="successSelector" style="margin-top: 0px;margin-bottom: 0px;"/>
- </div>
- </div>
- </div>
- <div style="display: table-cell">
- <div class="divtableheadercell">
- <div class="divtableheaderlabel">
- <label wicket:id="failureLabel"/>
- </div>
- <div style="display: table-cell">
- <input type="checkbox" wicket:id="failureSelector" style="margin-top: 0px;margin-bottom: 0px;"/>
- </div>
- </div>
- </div>
- </div>
- </div>
-
- <div class="container">
- <div class="label">
- <div id="divtablerow-label" wicket:id="categoryView">
- <div class="label">
- <span wicket:id="subcategory">[subcategory]</span>
- </div>
- </div>
- </div>
-
- <div id="divtablerow-success" class="divtablecheckcolumn">
- <span wicket:id="successGroup">
- <div wicket:id="successView" class="divtablecheck">
- <div class="divtableheaderlabel"> </div>
- <input type="checkbox" wicket:id="successCheck"/>
- </div>
- </span>
- </div>
-
- <div id="divtablerow-failure" class="divtablecheckcolumn">
- <span wicket:id="failureGroup">
- <div wicket:id="failureView" class="divtablecheck">
- <div class="divtableheaderlabel"> </div>
- <input type="checkbox" wicket:id="failureCheck"/>
- </div>
- </span>
- </div>
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/DerAttrsPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/DerAttrsPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/DerAttrsPanel.html
deleted file mode 100644
index 40d55ee..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/DerAttrsPanel.html
+++ /dev/null
@@ -1,60 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <table class="ui-widget ui-widget-content ui-corner-all"
- style="font-size: 1em;margin-top:2px;"
- width="100%" cellpadding="2px" cellspacing="1px">
- <thead>
- <tr class="ui-widget-header">
- <th><wicket:message key="derAttrToRemove"/></th>
- <th><wicket:message key="derAttrName"/></th>
- <th><wicket:message key="derAttrValue"/></th>
- </tr>
- </thead>
-
- <tfoot>
- <tr>
- <td>
- <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="addAttributeBtn"/>
- </td>
- </tr>
- </tfoot>
-
- <tbody wicket:id="derAttrContainer">
- <tr wicket:id="attrs">
- <td align="center" valign="middle">
- <input type="checkbox" class="text ui-widget-content ui-corner-all" wicket:id="toRemove"/>
- </td>
-
- <td>
- <select class="text ui-widget-content ui-corner-all"
- style="width:100%" wicket:id="schema"/>
- </td>
-
- <td align="center" valign="middle">
- <input type="text"
- style="width:98%; padding-left: 0px; padding-right: 0px" wicket:id="value"/>
- </td>
- </tr>
- </tbody>
- </table>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/DerAttrsPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/DerAttrsPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/DerAttrsPanel.properties
deleted file mode 100644
index a09c0b0..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/DerAttrsPanel.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-addAttributeBtn=Add
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/DerAttrsPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/DerAttrsPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/DerAttrsPanel_it.properties
deleted file mode 100644
index 9a4df9c..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/DerAttrsPanel_it.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-addAttributeBtn=Aggiungi
-
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/DerAttrsPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/DerAttrsPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/DerAttrsPanel_pt_BR.properties
deleted file mode 100644
index a7ac4dc..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/DerAttrsPanel_pt_BR.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-addAttributeBtn=Adicionar
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/EventSelectionPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/EventSelectionPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/EventSelectionPanel.html
deleted file mode 100644
index ac7c9fc..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/EventSelectionPanel.html
+++ /dev/null
@@ -1,125 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <style>
- .container {
- display: block;
- width: 100%;
- }
-
- .label {
- font-size: 12px;
- vertical-align: middle;
- font-family: Verdana,Tahoma,sans-serif;
- display: table-cell;
- width: 300px;
- height: 20px;
- }
-
- .divtableheaderlabel {
- font-weight: bold;
- float: left;
- margin-left: 5px;
- display: table-cell;
- width: 70px;
- }
-
- .divtableheadercell {
- display: inline-table;
- vertical-align: top;
- text-align: right;
- width: 105px;
- height: 20px;
- }
-
- .divtablecheckcolumn {
- display: table-cell;
- vertical-align: top;
- text-align: right;
- width: 105px;
- }
-
- .divtablecheck {
- width: 105px;
- height: 20px;
- }
-
- </style>
- </wicket:head>
- <wicket:panel>
- <div class="eventSelectionWidzard">
- <div class="container">
- <div style="display:inline-table;">
- <div class="label">
-
- </div>
- <div style="display: table-cell">
- <div class="divtableheadercell">
- <div class="divtableheaderlabel">
- <label wicket:id="successLabel"/>
- </div>
- <div style="display: table-cell">
- <input type="checkbox" wicket:id="successSelector" style="margin-top: 0px;margin-bottom: 0px;"/>
- </div>
- </div>
- </div>
- <div style="display: table-cell">
- <div class="divtableheadercell">
- <div class="divtableheaderlabel">
- <label wicket:id="failureLabel"/>
- </div>
- <div style="display: table-cell">
- <input type="checkbox" wicket:id="failureSelector" style="margin-top: 0px;margin-bottom: 0px;"/>
- </div>
- </div>
- </div>
- </div>
- </div>
-
- <div class="container">
- <div class="label">
- <div id="divtablerow-label" wicket:id="categoryView">
- <div class="label">
- <span wicket:id="subcategory">[subcategory]</span>
- </div>
- </div>
- </div>
-
- <div id="divtablerow-success" class="divtablecheckcolumn">
- <span wicket:id="successGroup">
- <div wicket:id="successView" class="divtablecheck">
- <div class="divtableheaderlabel"> </div>
- <input type="checkbox" wicket:id="successCheck"/>
- </div>
- </span>
- </div>
-
- <div id="divtablerow-failure" class="divtablecheckcolumn">
- <span wicket:id="failureGroup">
- <div wicket:id="failureView" class="divtablecheck">
- <div class="divtableheaderlabel"> </div>
- <input type="checkbox" wicket:id="failureCheck"/>
- </div>
- </span>
- </div>
- </div>
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupDetailsPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupDetailsPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupDetailsPanel.html
deleted file mode 100644
index 42bf48f..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupDetailsPanel.html
+++ /dev/null
@@ -1,107 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div id="formtable">
- <span wicket:id="parent">[parent]</span>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <wicket:message key="name"/>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="name"/>
- <a class="tooltips" wicket:id="questionMarkJexlHelp" href="#" alt="Click to help" title="Click to help">
- <img src="img/help.png"/>
- <span wicket:id="jexlHelp" class="tooltips">
- <wicket:message key="jexl_info"/>
- <ul>
- <li><wicket:message key="jexl_ex1"/></li>
- <li><wicket:message key="jexl_ex2"/></li>
- </ul>
- <a href="#" wicket:id="jexlLink" target="_blank"><wicket:message key="jexl_syntax_url"/></a>
- </span>
- </a>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <wicket:message key="inheritOwner"/>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="inheritOwner"/>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <wicket:message key="inheritTemplates"/>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="inheritTemplates"/>
- </div>
- </div>
-
- <div wicket:id="ownerContainer">
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <wicket:message key="userOwner"/>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="userOwner"/>
- <a href="#" wicket:id="userOwnerSelect"><img src="img/actions/search.png" alt="select user owner" title="Search"/></a>
- <a href="#" wicket:id="userOwnerReset"><img src="img/actions/delete.png" alt="reset user owner" title="Delete"/></a>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <wicket:message key="groupOwner"/>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="groupOwner"/>
- <a href="#" wicket:id="groupOwnerSelect"><img src="img/actions/search.png" alt="select group owner" title="Search"/></a>
- <a href="#" wicket:id="groupOwnerReset"><img src="img/actions/delete.png" alt="reset group owner" title="Delete"/></a>
- </div>
- </div>
- </div>
- </div>
-
- <span wicket:id="parentSelectWin"/>
- <span wicket:id="userOwnerSelectWin"/>
- <span wicket:id="groupOwnerSelectWin"/>
-
- <wicket:fragment wicket:id="parentFragment">
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <wicket:message key="parent"/>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="parent"/>
- <a href="#" wicket:id="parentSelect"><img src="img/actions/search.png" alt="select group parent" title="Search"/></a>
- <a href="#" wicket:id="parentReset"><img src="img/actions/delete.png" alt="reset group parent" title="Delete"/></a>
- </div>
- </div>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="emptyFragment">
- </wicket:fragment>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupDetailsPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupDetailsPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupDetailsPanel.properties
deleted file mode 100644
index 52581e5..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupDetailsPanel.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-name=Name
-userOwner=Owner (user)
-groupOwner=Owner (group)
-inheritOwner=Inherit owner
-parent=Parent
-inheritTemplates=Inherit templates
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupDetailsPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupDetailsPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupDetailsPanel_it.properties
deleted file mode 100644
index f7fbc02..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupDetailsPanel_it.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-name=Nome
-userOwner=Proprietario (utente)
-groupOwner=Proprietario (gruppo)
-inheritOwner=Eredita proprietario
-parent=Padre
-inheritTemplates=Eredita modelli
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupDetailsPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupDetailsPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupDetailsPanel_pt_BR.properties
deleted file mode 100644
index 772fc4e..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupDetailsPanel_pt_BR.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-name=Nome
-userOwner=Dono (usu\u00e1rio)
-groupOwner=Dono (grupo)
-inheritOwner=Dono herdado
-parent=Parente
-inheritTemplates=Modelo herdado
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupPanel.html
deleted file mode 100644
index 5783350..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupPanel.html
+++ /dev/null
@@ -1,88 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
-
- <div id="details">
- <span wicket:id="details">[group details]</span>
- <span wicket:id="statuspanel">[Status Panel]</span>
- <span wicket:id="systeminformation">[System Information]</span>
- </div>
-
- <div id="templates">
- <span wicket:id="templates">[templates]</span>
- </div>
-
- <div id="plainAttrs">
- <div id="formtable">
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <wicket:message key="inheritPlainAttrs"/>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="inheritPlainAttrs" />
- </div>
- </div>
-
- <span wicket:id="plainAttrs">[group attributes]</span>
- </div>
- </div>
-
- <div id="derAttrs">
- <div id="formtable">
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <wicket:message key="inheritDerAttrs"/>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="inheritDerAttrs" />
- </div>
- </div>
-
- <span wicket:id="derAttrs">[group derived attributes]</span>
- </div>
- </div>
-
- <div id="virAttrs">
- <div id="formtable">
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <wicket:message key="inheritVirAttrs"/>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="inheritVirAttrs" />
- </div>
- </div>
-
- <span wicket:id="virAttrs">[group virtual attributes]</span>
- </div>
- </div>
-
- <div id="resources">
- <span wicket:id="resources">[resources]</span>
- </div>
- <div id="entitlements">
- <span wicket:id="entitlements">[entitlements]</span>
- </div>
- <div id="security">
- <span wicket:id="security">[security]</span>
- </div>
-
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupPanel.properties
deleted file mode 100644
index 195f8ed..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupPanel.properties
+++ /dev/null
@@ -1,51 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-required_alert=All form fields are required.
-add=+
-drop=-
-error=Generic error occurred during the operation
-name=Name
-firstResourcesList=Group's resources
-secondResourcesList=Available resources
-firstEntitlementsList=Group's entitlements
-secondEntitlementsList=Available entitlements
-
-addAttributeBtn=Add
-required_alert=All form fields are required.
-add=+
-drop=-
-error=Generic error occurred during the operation
-name=Name
-firstResourcesList=Group's resources
-secondResourcesList=Available resources
-firstEntitlementsList=Group's entitlements
-secondEntitlementsList=Available entitlements
-derAttrs=Derived Attributes
-derAttrToRemove=Delete
-derAttrName=Name
-derAttrValue=Derived value
-
-virAttrs=Virtual Attributes
-virAttrToRemove=Delete
-virAttrName=Name
-virAttrValue=Virtual value
-
-addAttributeBtn=Add
-
-inheritPlainAttrs=Inherit plain attributes
-inheritDerAttrs=Inherit derived attributes
-inheritVirAttrs=Inherit virtual attributes
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupPanel_it.properties
deleted file mode 100644
index 7dda4fb..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupPanel_it.properties
+++ /dev/null
@@ -1,53 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-required_alert=All form fields are required.
-add=+
-drop=-
-name=Nome
-error=Errore generico durante l'operazione
-firstResourcesList=Risorse ruolo
-secondResourcesList=Risorse disponibili
-firstResourcesList=Entitlement ruolo
-secondResourcesList=Entitlement disponibili
-
-addAttributeBtn=Aggiungi
-required_alert=Tutti i valori sono richiesti.
-add=+
-drop=-
-name=Nome
-error=Errore generico durante l'operazione
-firstResourcesList=Risorse ruolo
-secondResourcesList=Risorse disponibili
-firstResourcesList=Risorse gruppo
-secondResourcesList=Risorse disponibili
-derAttrs=Attributi derivati
-derAttrToRemove=Rimuovi
-derAttrName=Nome
-derAttrValue=Valore derivato
-
-virAttrs=Attributi virtuali
-virAttrToRemove=Rimuovi
-virAttrName=Nome
-virAttrValue=Valore virtuale
-
-addAttributeBtn=Aggiungi
-
-inheritPlainAttrs=Eredita attributi normali
-inheritDerAttrs=Eredita attributi derivati
-inheritVirAttrs=Eredita attributi virtuali
-firstEntitlementsList=Entitlement grupo
-secondEntitlementsList=Entitlement disponibili
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupPanel_pt_BR.properties
deleted file mode 100644
index e74968a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupPanel_pt_BR.properties
+++ /dev/null
@@ -1,40 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-required_alert=Todos os campos s\u00e3o obrigat\u00f3rios
-add=+
-drop=-
-error=Um erro gen\u00e9rico ocorreu durante a opera\u00e7\u00e3o
-name=Nome
-firstResourcesList=Recursos de Grupo
-secondResourcesList=Recursos Dipon\u00edveis
-firstEntitlementsList=Direitos de Grupo
-secondEntitlementsList=Direitos Dispon\u00edveis
-derAttrs=Atributos Derivados
-derAttrToRemove=Remover
-derAttrName=Nome
-derAttrValue=Valor Derivado
-
-virAttrs=Atributos Virtuais
-virAttrToRemove=Remover
-virAttrName=Nome
-virAttrValue=Valor Virtual
-
-addAttributeBtn=Adicionar
-
-inheritPlainAttrs=Atributos Herdados Normal
-inheritDerAttrs=Atributos Herdados Derivados
-inheritVirAttrs=Atributos Virtuais Herdados
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSecurityPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSecurityPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSecurityPanel.html
deleted file mode 100644
index 61b609e..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSecurityPanel.html
+++ /dev/null
@@ -1,66 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div id="formtable" wicket:id="security">
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="inheritPasswordPolicy"><wicket:message key="inheritPasswordPolicy"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="inheritPasswordPolicy">
- [panel for dynamic input type markup]
- </span>
- </div>
- </div>
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="passwordPolicy"><wicket:message key="passwordPolicy"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="passwordPolicy">
- [panel for dynamic input type markup]
- </span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="inheritAccountPolicy"><wicket:message key="inheritAccountPolicy"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="inheritAccountPolicy">
- [panel for dynamic input type markup]
- </span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="accountPolicy"><wicket:message key="accountPolicy"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="accountPolicy">
- [panel for dynamic input type markup]
- </span>
- </div>
- </div>
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSecurityPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSecurityPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSecurityPanel.properties
deleted file mode 100644
index 167673d..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSecurityPanel.properties
+++ /dev/null
@@ -1,20 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-inheritPasswordPolicy = Inherit password policy
-inheritAccountPolicy = Inherit account policy
-passwordPolicy = Password Policy
-accountPolicy = Account Policy
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSecurityPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSecurityPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSecurityPanel_it.properties
deleted file mode 100644
index 6e7c6ed..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSecurityPanel_it.properties
+++ /dev/null
@@ -1,20 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-inheritPasswordPolicy = Eredita password policy
-inheritAccountPolicy = Eredita account policy
-passwordPolicy = Password Policy
-accountPolicy = Account Policy
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSecurityPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSecurityPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSecurityPanel_pt_BR.properties
deleted file mode 100644
index 5c77adc..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSecurityPanel_pt_BR.properties
+++ /dev/null
@@ -1,20 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-inheritPasswordPolicy = Pol\u00EDtica de Senha Herdada
-inheritAccountPolicy = Pol\u00EDtica de Conta Herdada
-passwordPolicy = Pol\u00EDtica de Senha
-accountPolicy = Pol\u00EDtica de Conta
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSummaryPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSummaryPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSummaryPanel.html
deleted file mode 100644
index 39eead2..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupSummaryPanel.html
+++ /dev/null
@@ -1,39 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
-
- <span wicket:id="groupSummaryPanel">[Group panel]</span>
-
- <wicket:fragment wicket:id="groupViewPanel">
- <span wicket:id="nodeViewPanel"></span>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="rootPanel">
- <div style="float:left; width:70%;">
- <p style="height:15px; margin-top: 0px;" class="ui-widget ui-corner-all ui-widget-header">
- <span style="float:right;" wicket:id="actionLinks"/>
- </p>
- </div>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="fakerootFrag">
- </wicket:fragment>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupTabPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupTabPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupTabPanel.html
deleted file mode 100644
index a05da39..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupTabPanel.html
+++ /dev/null
@@ -1,64 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div style="float:left; width:70%;">
- <script type="text/javascript">
- $(document).ready(function () {
- $("div form #tabs").tabs();
- });
- $(document).ready(function () {
- $("div form #tabs #templates").tabs();
- });
- </script>
- <p style="height:15px; margin-top: 0px;" class="ui-widget ui-corner-all ui-widget-header">
- <wicket:message key="title"/>
- <span wicket:id="displayName"/>
- <span style="float:right;" wicket:id="actionLinks"/>
- </p>
-
- <form wicket:id="groupForm">
- <div id="tabs" style="margin: 0px;">
- <ul>
- <li><a href="#details"><span><wicket:message key="details"/></span></a></li>
- <li><a href="#templates"><span><wicket:message key="templates"/></span></a></li>
- <li><a href="#plainAttrs"><span><wicket:message key="plainAttrs"/></span></a></li>
- <li><a href="#derAttrs"><span><wicket:message key="derAttrs"/></span></a></li>
- <li><a href="#virAttrs"><span><wicket:message key="virAttrs"/></span></a></li>
- <li><a href="#resources"><span><wicket:message key="resources"/></span></a></li>
- <li><a href="#entitlements"><span><wicket:message key="entitlements"/></span></a></li>
- <li><a href="#security"><span><wicket:message key="security"/></span></a></li>
- <li><a href="#users"><span><wicket:message key="users"/></span></a></li>
- </ul>
- <div wicket:id="groupPanel">
- </div>
- <div id="users">
- <div wicket:id="userListContainer">
- <input type="button" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="search"/>
- <div id="users-contain" class="ui-widget" style="width:auto">
- <span wicket:id="userList"> [userList] </span>
- </div>
- </div>
- </div>
- </div>
- </form>
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupTabPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupTabPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupTabPanel.properties
deleted file mode 100644
index 4ee3e36..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupTabPanel.properties
+++ /dev/null
@@ -1,27 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Group
-details=Details
-plainAttrs=Plain attributes
-derAttrs=Derived attributes
-virAttrs=Virtual attributes
-resources=Resources
-entitlements=Entitlements
-security=Security
-users=Users
-search=Get Users
-templates=Templates
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupTabPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupTabPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupTabPanel_it.properties
deleted file mode 100644
index 61e0772..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupTabPanel_it.properties
+++ /dev/null
@@ -1,27 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Gruppo
-details=Dettagli
-plainAttrs=Attributi normali
-derAttrs=Attributi derivati
-virAttrs=Attributi virtuali
-resources=Risorse
-entitlements=Entitlement
-security=Sicurezza
-users=Utenti
-search=Lista Utenti
-templates=Modelli
[32/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ErrorPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ErrorPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ErrorPage.html
deleted file mode 100644
index c1c7407..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ErrorPage.html
+++ /dev/null
@@ -1,53 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<wicket:head>
- <style type="text/css">
- .ui-state-error, .ui-widget-content .ui-state-error, .ui-widget-header .ui-state-error {
- background:url("../../css/images/ui-bg_glass_95_fef1ec_1x400.png") repeat-x scroll 50% 50% #FEF1EC;
- border:1px solid #CD0A0A;
- color:#CD0A0A;
- width: 400px;
- padding: 0px;
- margin-top: 200px;
- margin-left: auto;
- margin-right: auto;
- }
- body {
- background: url("../../css/images/ui-bg_diagonals-thick_20_666666_40x40.png")
- repeat scroll 50% 50% #666666;
- }
- </style>
-</wicket:head>
-<wicket:extend>
-
- <div class="ui-widget">
- <div style="padding: 0pt 0.7em;" class="ui-state-error ui-corner-all">
- <p><span style="float: left; margin-right: 0.3em;"
- class="ui-icon ui-icon-alert"></span>
- <strong><span wicket:id="errorTitle"/></strong>
- <div><span wicket:id="errorMessage"/></div>
- <p>
- <a href="" wicket:id="home">
- <wicket:message key="home"/>
- </a>
- </p>
- </p>
- </div>
- </div>
-</wicket:extend>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ExecMessageModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ExecMessageModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ExecMessageModalPage.html
deleted file mode 100644
index bf00ee4..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ExecMessageModalPage.html
+++ /dev/null
@@ -1,25 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<wicket:extend>
- <div id="dialog">
- <pre wicket:id="message">
- [Task execution's message to show]
- </pre>
- </div>
-</wicket:extend>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/FailureMessageModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/FailureMessageModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/FailureMessageModalPage.html
deleted file mode 100644
index db7c53d..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/FailureMessageModalPage.html
+++ /dev/null
@@ -1,36 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<!DOCTYPE html>
-<style>
- .w_content_3 {
- padding: 0;
- color: #333333;
- font-family: Verdana,Tahoma,sans-serif;
- font-size: 62.5%;
- }
-</style>
-<wicket:extend>
- <div class="w_content_3">
- <div>
- <div style="margin: 1em">
- <pre wicket:id="failureMessage"></pre>
- </div>
- </div>
- </div>
-</wicket:extend>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage.html
deleted file mode 100644
index bbcd878..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage.html
+++ /dev/null
@@ -1,52 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div style="margin: 5px;">
- <p class="ui-widget ui-corner-all ui-widget-header">
- <wicket:message key="title"/> <span wicket:id="displayName"/>
- </p>
- <form wicket:id="groupForm">
- <div id="tabs">
- <div style="display: block; clear: both">
- <ul>
- <li><a href="#details"><span><wicket:message key="details"/></span></a></li>
- <li><a href="#templates"><span><wicket:message key="templates"/></span></a></li>
- <li><a href="#plainAttrs"><span><wicket:message key="plainAttrs"/></span></a></li>
- <li><a href="#derAttrs"><span><wicket:message key="derAttrs"/></span></a></li>
- <li><a href="#virAttrs"><span><wicket:message key="virAttrs"/></span></a></li>
- <li><a href="#resources"><span><wicket:message key="resources"/></span></a></li>
- <li><a href="#entitlements"><span><wicket:message key="entitlements"/></span></a></li>
- <li><a href="#security"><span><wicket:message key="security"/></span></a></li>
- </ul>
- </div>
- <div wicket:id="groupPanel"></div>
- </div>
- <div style="bottom:0;margin:10px">
- <input type="submit"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="submit"/>
- <input type="button"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="cancel"/>
- </div>
- </form>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage.properties
deleted file mode 100644
index 4ffa2fb..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage.properties
+++ /dev/null
@@ -1,48 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-required_alert=All form fields are required.
-title=Group
-details=Details
-plainAttrs=Plain attributes
-tab3=Derived attributes
-tab4=Virtual attributes
-resources=Resources
-entitlements=Entitlements
-security=Security
-add=+
-drop=-
-error=Generic error occurred during the operation
-firstResourcesList=Group's resources
-secondResourcesList=Available resources
-firstEntitlementsList=Group's entitlements
-secondEntitlementsList=Available entitlements
-derAttrs=Derived Attributes
-derAttrToRemove=Delete
-derAttrName=Name
-derAttrValue=Derived value
-
-virAttrs=Virtual Attributes
-virAttrToRemove=Delete
-virAttrName=Name
-virAttrValue=Virtual value
-
-addAttributeBtn=Add
-
-inheritPlainAttrs=Inherit plain attributes
-inheritDerAttrs=Inherit derived attributes
-inheritVirAttrs=Inherit virtual attributes
-templates=Templates
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage_it.properties
deleted file mode 100644
index 1c6efec..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage_it.properties
+++ /dev/null
@@ -1,50 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-required_alert=All form fields are required.
-title=Gruppo
-details=Dettagli
-plainAttrs=Attributi normali
-tab3=Attributi derivati
-tab4=Attributi virtuali
-resources=Risorse
-entitlements=Entitlement
-security=Sicurezza
-add=+
-drop=-
-error=Errore generico durante l'operazione
-firstResourcesList=Risorse ruolo
-secondResourcesList=Risorse disponibili
-firstResourcesList=Risorse gruppo
-secondResourcesList=Risorse disponibili
-derAttrs=Attributi derivati
-derAttrToRemove=Elimina
-derAttrName=Nome
-derAttrValue=Valore derivato
-
-virAttrs=Attributi virtuali
-virAttrToRemove=Elimina
-virAttrName=Nome
-virAttrValue=Valore virtuale
-
-addAttributeBtn=Aggiungi
-
-inheritPlainAttrs=Eredita attributi normali
-inheritDerAttrs=Eredita attributi derivati
-inheritVirAttrs=Eredita attributi virtuali
-templates=Modelo
-secondEntitlementsList=Entitlement disponibili
-firstEntitlementsList=Entitlement gruppo
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage_pt_BR.properties
deleted file mode 100644
index 0649585..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupModalPage_pt_BR.properties
+++ /dev/null
@@ -1,48 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-required_alert=Todos os campos s\u00e3o obrigat\u00f3rios
-title=Grupo
-details=Detalhes
-plainAttrs=Atributos Normal
-tab3=Atributos Derivados
-tab4=Atributos Virtuais
-resources=Recursos
-entitlements=Direitos
-security=Seguran\u00e7a
-add=+
-drop=-
-error=Um erro gen\u00e9rico ocorreu durante a opera\u00e7\u00e3o
-firstResourcesList=Recursos de grupos
-secondResourcesList=Recursos dispon\u00edveis
-firstEntitlementsList=Direitos de grupos
-secondEntitlementsList=Direitos dispon\u00edveis
-derAttrs=Atributos derivados
-derAttrToRemove=Exluir
-derAttrName=Nome
-derAttrValue=Valor Derivado
-
-virAttrs=Atributos Virtuais
-virAttrToRemove=Excluir
-virAttrName=Nome
-virAttrValue=Valor Virtual
-
-addAttributeBtn=Adicionar
-
-inheritPlainAttrs=Atributos Herdados Normal
-inheritDerAttrs=Atributos Derivados Herdados
-inheritVirAttrs=Atributos Virtuais Herdados
-templates=Modelli
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupSelectModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupSelectModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupSelectModalPage.html
deleted file mode 100644
index 203ffa9..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/GroupSelectModalPage.html
+++ /dev/null
@@ -1,24 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div wicket:id="treeTable"
- style="width: 100%;display:block;margin:auto;" class="groupTable group-tree"/>
- </wicket:extend>
-</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Groups.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Groups.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Groups.html
deleted file mode 100644
index a335c28..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Groups.html
+++ /dev/null
@@ -1,80 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <style>
- div.group-tree div.wicket-tree-table a {
- color:black;
- }
- </style>
- <script type="text/javascript">
- $(document).ready(function() {
- $("#grouptabs").tabs();
- });
- </script>
- </wicket:head>
- <wicket:extend>
- <div id="grouptabs">
- <ul>
- <li class="tabs-selected">
- <a href="#tabs-tree">
- <span><wicket:message key="tabs-tree"/>
- </span>
- </a>
- </li>
- <li>
- <a href="#tabs-search">
- <span><wicket:message key="tabs-search"/>
- </span>
- </a>
- </li>
- </ul>
-
- <div id="tabs-tree" >
- <div wicket:id="groupTabsContainer">
- <span wicket:id="treePanel"></span>
- <span wicket:id="summaryPanel"></span>
- </div>
- <div wicket:id="editGroupWin">[Show modal window for create/editing group]</div>
- </div>
-
- <div id="tabs-search">
- <div>
- <form wicket:id="searchForm">
- <span wicket:id="searchPanel">searchPanel</span>
-
- <br/>
- <a wicket:id="search"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only">
- <img src="img/search.png" alt="search"/>
- <wicket:message key="search"/>
- </a>
- </form>
- </div>
-
- <div id="users-contain" class="ui-widget" style="width:auto">
- <span wicket:id="searchResult">[search result]</span>
- </div>
- </div>
-
- </div>
-
- <wicket:child/>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Groups.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Groups.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Groups.properties
deleted file mode 100644
index bfe9385..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Groups.properties
+++ /dev/null
@@ -1,26 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tabs-tree=Tree
-tabs-search=Search
-search=Search
-create_user=Create new user
-search_results_title=Search results
-search_noResults=No matches found.
-reset=Reset
-showingFrom=Showing
-showingTo=to
-showingOf=of
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Groups_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Groups_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Groups_it.properties
deleted file mode 100644
index 76e69f7..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Groups_it.properties
+++ /dev/null
@@ -1,26 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tabs-tree=Albero
-tabs-search=Ricerca
-search=Cerca
-create_user=Crea nuovo utente
-search_results_title=Risultati ricerca:
-search_noResults=Nessuna corrispondenza trovata.
-reset=Reset
-showingFrom=Risultati da
-showingTo=a
-showingOf=di
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Groups_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Groups_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Groups_pt_BR.properties
deleted file mode 100644
index 8d80401..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Groups_pt_BR.properties
+++ /dev/null
@@ -1,26 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tabs-tree=\u00C1rvore
-tabs-search=Buscar
-search=Buscar
-create_user=Criar novo usu\u00E1rio
-search_results_title=Resultados da busca
-search_noResults=N\u00E3o foram encontrados resultados
-reset=Resetar
-showingFrom=Mostrando
-showingTo=para
-showingOf=de
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/HomePage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/HomePage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/HomePage.html
index 2849c44..7e9b91a 100644
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/HomePage.html
+++ b/client/console/src/main/resources/org/apache/syncope/client/console/pages/HomePage.html
@@ -1,4 +1,4 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
@@ -17,18 +17,17 @@ KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
-<html xmlns="http://www.w3.org/1999/xhtml">
-
- <body>
-
- <wicket:extend>
-
- <div>
- <b>Syncope</b> Home-Page!
- </div>
-
- </wicket:extend>
-
- </body>
-
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
+ <meta http-equiv="Content-Style-Type" content="text/css"/>
+ <meta http-equiv="Content-Script-Type" content="text/javascript"/>
+
+ <title>Apache Syncope</title>
+ </head>
+ <body>
+ <h1>Welcome <label wicket:id="username"/></h1>
+
+ <wicket:link><a href="SignOut.html">Sign Out</a></wicket:link>
+ </body>
</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage.html
deleted file mode 100644
index 1124735..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage.html
+++ /dev/null
@@ -1,42 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<wicket:extend>
- <div id="versionMP">
- <div style="text-align: center;">
- <a wicket:id="syncopeLink" target="_blank">
- <img id="logo" src="img/logo.png" alt="syncope" title="syncope"/>
- </a>
- <div style="color: white;font-weight: bold;">Version: <span wicket:id="version"/></div>
- </div>
- <br/>
- <div>
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
- </div>
- <a wicket:id="licenseLink" target="_blank">http://www.apache.org/licenses/LICENSE-2.0</a>
- <div>
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
- </div>
- </div>
-</wicket:extend>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage.properties
deleted file mode 100644
index 5f0020a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-info=Information
-syncopeSite=Apache Syncope Site
-version=Version
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage_it.properties
deleted file mode 100644
index 5a2beea..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage_it.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-info=Informazioni
-syncopeSite=Sito di Apache Syncope
-version=Versione
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage_pt_BR.properties
deleted file mode 100644
index abd4055..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/InfoModalPage_pt_BR.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-info=Informa\u00E7\u00E3o
-syncopeSite=Site do Apache Syncope
-version=Vers\u00E3o
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Login.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Login.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Login.html
deleted file mode 100644
index 78436de..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Login.html
+++ /dev/null
@@ -1,89 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml">
- <head>
- <meta http-equiv="X-UA-Compatible" content="IE=edge"/>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
- <meta http-equiv="Content-Style-Type" content="text/css"/>
-
- <title>Apache Syncope - Login</title>
-
- <link rel="shortcut icon" href="img/favicon.png" type="image/png"/>
- <link rel="stylesheet" href="css/style.css" type="text/css" media="all"/>
-
- <script type="text/javascript">
-
- var notificationShownTimes = 0;
-
- function showNotification(componentId, messagecount) {
- notificationShownTimes++;
- timeout = 1700 + (messagecount * 500) + notificationShownTimes * 200;
- $('div#' + componentId).fadeTo('normal', 1.0);
- setTimeout("$('div#" + componentId + "').fadeOut('normal')", timeout);
- }
- </script>
-
- </head>
- <body style="text-align:center">
- <div id="splash">
- <img src="img/logo.png" alt="syncope" title="syncope" id="logo" />
- <p style="border: none"> </p>
- <div id="loginFeedbackDiv">
- <div wicket:id="feedback">feedbackmessages will be put here</div>
- </div>
- <form wicket:id="login">
- <label for="userId">
- <wicket:message key="userId"/>
- </label>
- <input type="text" wicket:id="userId" id="userId" size="25" style="width: 180px" />
- <br />
- <label for="password" class="password">
- <wicket:message key="password"/>
- </label>
- <input type="password" wicket:id="password" id="password" size="25" style="width: 180px" />
- <br />
- <select wicket:id="language" id="language"/>
- <br />
- <br />
- <input type="submit" wicket:id="submit"/>
- </form>
-
- <div style="display: inline-table; margin: 10px; width:380px;">
- <div style="display: inline-table-cell; text-align: left; float: left;" wicket:id="selfRegistration"/>
- <div style="display: inline-table-cell; text-align: left; float: right;" wicket:id="passwordReset"/>
- </div>
-
- <wicket:fragment wicket:id="selfRegNotAllowed"/>
- <wicket:fragment wicket:id="selfRegAllowed">
- <span wicket:id="selfRegistration"/>
- </wicket:fragment>
-
- <div wicket:id="selfRegModal"></div>
-
- <wicket:fragment wicket:id="pwdResetNotAllowed"/>
- <wicket:fragment wicket:id="pwdResetAllowed">
- <span wicket:id="passwordReset"/>
- </wicket:fragment>
-
- <div wicket:id="pwdResetReqModal"></div>
- <div wicket:id="pwdResetConfModal"></div>
- </div>
- </body>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Login.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Login.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Login.properties
deleted file mode 100644
index 9b31e6e..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Login.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-userId=Username
-password=Password
-submit=Login
-login-error=Wrong username and/or password
-selfRegistration=Self registration
-passwordReset=Password reset
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Login_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Login_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Login_it.properties
deleted file mode 100644
index 40f8c34..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Login_it.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-userId=Username
-password=Password
-submit=Login
-login-error=Username e/o password errati
-selfRegistration=Registrati
-passwordReset=Password smarrita
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Login_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Login_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Login_pt_BR.properties
deleted file mode 100644
index fd312c4..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Login_pt_BR.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-userId=Usu\u00e1rio
-password=Senha
-submit=Login
-login-error=Usu\u00e1rio ou senha incorretos
-selfRegistration=Registrar-se
-passwordReset=Redefini\u00e7\u00e3o de senha
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage.html
deleted file mode 100644
index 9bc8cb7..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage.html
+++ /dev/null
@@ -1,55 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
- <form wicket:id="MembershipForm">
- <div id="tabs">
- <ul>
- <li><a href="#tabs-1"><span><wicket:message key="tab1"/></span></a></li>
- <li><a href="#tabs-2"><span><wicket:message key="tab2"/></span></a></li>
- <li><a href="#tabs-3"><span><wicket:message key="tab3"/></span></a></li>
- </ul>
- <div id="tabs-1">
- <div id="formtable">
- <span wicket:id="plainAttrs">[membership plain attributes]</span>
- <span wicket:id="systeminformation">[System Information]</span>
- </div>
-
- <script type="text/javascript">
- $(function() {
- $('#formtable div.tablerow:even').addClass("alt");
- });
- </script>
- </div>
- <div id="tabs-2">
- <span wicket:id="derAttrs">[membership derived attributes]</span>
- </div>
-
- <div id="tabs-3">
- <span wicket:id="virAttrs">[membership virtual attributes]</span>
- </div>
- </div>
- <div style="margin: 20px 10px 0">
- <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="submit"/>
- <input type="button" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="cancel"/>
- </div>
- </form>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage.properties
deleted file mode 100644
index bd02e50..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage.properties
+++ /dev/null
@@ -1,35 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=Plain attributes
-tab2=Derived attributes
-tab3=Virtual attributes
-title=Groups
-add=+
-drop=-
-edit=Edit
-delete=Delete
-derAttrs=Derived Attributes
-derAttrToRemove=Delete
-derAttrName=Name
-derAttrValue=Derived value
-
-virAttrs=Virtual Attributes
-virAttrToRemove=Delete
-virAttrName=Name
-virAttrValue=Virtual value
-
-addAttributeBtn=Add
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage_it.properties
deleted file mode 100644
index ebcfd3c..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage_it.properties
+++ /dev/null
@@ -1,35 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=Attributi normali
-tab2=Attributi derivati
-tab3=Attributi virtuali
-title=Gruppi
-add=+
-drop=-
-edit=Edit
-delete=Rimuovi
-derAttrs=Attributi derivati
-derAttrToRemove=Elimina
-derAttrName=Nome
-derAttrValue=Valore derivato
-
-virAttrs=Attributi virtuali
-virAttrToRemove=Elimina
-virAttrName=Nome
-virAttrValue=Valore virtuale
-
-addAttributeBtn=Aggiungi
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage_pt_BR.properties
deleted file mode 100644
index 15e115d..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/MembershipModalPage_pt_BR.properties
+++ /dev/null
@@ -1,35 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=Atributos Normal
-tab2=Atributos Derivados
-tab3=Atributos Virtuais
-title=Grupos
-add=+
-drop=-
-edit=Alterar
-delete=Excluir
-derAttrs=Atributos Derivados
-derAttrToRemove=Excluir
-derAttrName=Nome
-derAttrValue=Valor Derivado
-
-virAttrs=Atributos Virtuais
-virAttrToRemove=Excluir
-virAttrName=Nome
-virAttrValue=Valor Virtual
-
-addAttributeBtn=Adicionar
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage.html
deleted file mode 100644
index 655778b..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage.html
+++ /dev/null
@@ -1,234 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <style>
- div#tabs div#events{
- min-width: 970px;
- overflow: hidden;
- }
-
- div#userFilter {
- border: 1px solid #DDDDDD;
- }
-
- div#userFilter div#title {
- margin: 10px 0px 0px 8px;
- }
-
- div#userFilter div#warning {
- margin: 1px 0px 5px 8px;
- }
-
- div#userFilter div#title label {
- font-weight: bold;
- }
-
- div#userFilter div#warning label {
- color: #E00000;
- font-size: 8px;
- }
- </style>
- </wicket:head>
- <wicket:extend>
- <div style="margin: 5px;">
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
- <form wicket:id="form">
- <div id="tabs">
- <ul>
- <li class="tabs-selected"><a href="#notification"><span><wicket:message key="notification"/></span></a></li>
- <li><a href="#events"><span><wicket:message key="events"/></span></a></li>
- <li><a href="#about"><span><wicket:message key="about"/></span></a></li>
- <li><a href="#recipients"><span><wicket:message key="recipients"/></span></a></li>
- </ul>
-
- <div id="notification">
- <div id="formtable">
- <div class="tablerow alt">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="sender"><wicket:message key="sender"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="sender">[sender]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="subject"><wicket:message key="subject"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="subject">[subject]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="recipientAttrType"><wicket:message key="recipientAttrType"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="recipientAttrType">[recipientAttrType]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="recipientAttrName"><wicket:message key="recipientAttrName"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="recipientAttrName">[recipientAttrName]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="template"><wicket:message key="template"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="template">[template]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="traceLevel"><wicket:message key="traceLevel"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="traceLevel">[traceLevel]</span>
- </div>
- </div>
- <div class="tablerow alt">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="isActive"><wicket:message key="isActive"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="isActive">[isActive]</span>
- </div>
- </div>
- </div>
- </div>
-
- <div id="events">
- <span wicket:id="eventSelection"/>
- </div>
-
- <div id="about">
- <span wicket:id="aboutContainer">
- <div class="tablerow" style="width: auto;">
- <div class="tablecolumn_field" style="width: auto; padding-right: 5px;">
- <span wicket:id="checkAbout">[checkAbout]</span>
- </div>
- <div class="tablecolumn_label" style="width: 100%">
- <label for="checkAbout"><wicket:message key="checkAbout"/></label>
- </div>
- </div>
- <div class="tablerow" style="width: auto;">
- <div class="tablecolumn_field" style="width: auto; padding-right: 5px;">
- <span wicket:id="checkUserAbout">[checkUserAbout]</span>
- </div>
- <div class="tablecolumn_label" style="width: auto;">
- <label for="checkUserAbout"><wicket:message key="checkUserAbout"/></label>
- </div>
- </div>
- <div id="userFilter">
- <div id="title">
- <label for="userFilter"><wicket:message key="userFilter"/></label>
- </div>
- <div id="warning">
- <label for="userFilter"><wicket:message key="userFilterWarning"/></label>
- </div>
- <div id="condition">
- <span wicket:id="userAbout"/>
- </div>
- </div>
- <div class="tablerow" style="width: auto;">
- <div class="tablecolumn_field" style="width: auto; padding-right: 5px;">
- <span wicket:id="checkGroupAbout">[checkGroupAbout]</span>
- </div>
- <div class="tablecolumn_label" style="width: auto;">
- <label for="checkGroupAbout"><wicket:message key="checkGroupAbout"/></label>
- </div>
- </div>
- <div id="userFilter">
- <div id="title">
- <label for="groupFilter"><wicket:message key="groupFilter"/></label>
- </div>
- <div id="warning">
- <label for="groupFilter"><wicket:message key="groupFilterWarning"/></label>
- </div>
- <div id="condition">
- <span wicket:id="groupAbout"/>
- </div>
- </div>
- </span>
- </div>
-
- <div id="recipients">
- <div class="tablerow alt">
- <div class="tablecolumn_label medium_dynamicsize">
- <span wicket:id="checkStaticRecipients">[checkStaticRecipients]</span>
- <label for="recipients"><wicket:message key="recipients"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="staticRecipients">[staticRecipients]</span>
- </div>
- </div>
-
- <span wicket:id="recipientsContainer">
- <div class="tablerow" style="width: auto;">
- <div class="tablecolumn_field" style="width: auto; padding-right: 5px;">
- <span wicket:id="checkRecipients">[checkRecipients]</span>
- </div>
- <div class="tablecolumn_label" style="width: auto;">
- <label for="checkRecipients"><wicket:message key="checkRecipients"/></label>
- </div>
- </div>
- <span wicket:id="recipients"/>
- </span>
- <div id="userFilter">
- <div id="title">
- <label for="userNotifications"><wicket:message key="userNotifications"/></label>
- </div>
- <div id="warning">
- <label for="userNotificationsWarning"><wicket:message key="userNotificationsWarning"/></label>
- </div>
- <div class="tablerow" style="width: auto;">
- <div class="tablecolumn_field" style="width: auto; padding-right: 5px;">
- <span wicket:id="selfAsRecipient">[selfAsRecipient]</span>
- </div>
- <div class="tablecolumn_label" style="width: auto;">
- <label for="selfAsRecipient"><wicket:message key="selfAsRecipient"/></label>
- </div>
- </div>
- </div>
- </div>
- </div>
-
- <div style="margin: 20px 10px 0">
- <input type="submit"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="apply"/>
- <input type="button"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="cancel"/>
- </div>
- </form>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage.properties
deleted file mode 100644
index 99b7dca..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage.properties
+++ /dev/null
@@ -1,40 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Edit notification
-submit=Save
-subject=Subject
-sender=Sender
-template=Template
-traceLevel=Trace level
-notification=Notification
-about=About
-events=Events
-recipients=Recipients
-selfAsRecipient=Include users matching About
-recipientAttrType=Recipients e-mail attribute type
-recipientAttrName=Recipients e-mail attribute schema
-checkRecipients=Search recipients
-checkAbout=All
-userFilter=User filter
-userFilterWarning=Do not use this filter unless events are not targeted at users
-userNotifications=User notifications
-userNotificationsWarning=Do not select this checkbox unless events are not targeted at users
-groupFilter=Group filter
-groupFilterWarning=Do not use this filter unless events are not targeted at groups
-isActive=Enabled
-checkUserAbout=Users
-checkGroupAbout=Groups
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage_it.properties
deleted file mode 100644
index 6015c91..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage_it.properties
+++ /dev/null
@@ -1,40 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Gestisci notifiche
-submit=Salva
-subject=Oggetto
-sender=Mittente
-template=Modello
-traceLevel=Livello di tracciamento
-notification=Notifica
-about=Soggetti
-events=Eventi
-recipients=Destinatari
-selfAsRecipient=Includi i soggetti
-recipientAttrType=Tipo attributo e-mail destinatari
-recipientAttrName=Schema attributo e-mail destinatari
-checkRecipients=Cerca i destinatari
-checkAbout=Tutto
-userFilter=Filtro utenti
-userFilterWarning=Non usare questo filtro se gli eventi catturati non riguardano espressamente utenti
-userNotifications=Notifiche utente
-userNotificationsWarning=Non selezionare questa checkbox se gli eventi catturati non riguardano espressamente utenti
-groupFilter=Filtro gruppi
-groupFilterWarning=Non usare questo filtro se gli eventi catturati non riguardano espressamente i ruoli
-isActive=Abilitata
-checkUserAbout=Utenti
-checkGroupAbout=Gruppi
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage_pt_BR.properties
deleted file mode 100644
index 867b98b..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationModalPage_pt_BR.properties
+++ /dev/null
@@ -1,40 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Alterar Notifica\u00e7\u00e3o
-submit=Salvar
-subject=Assunto
-sender=Remetente
-template=Template
-traceLevel=N\u00edvel de Trace
-notification=Notifica\u00e7\u00e3o
-about=Sobre
-events=Eventos
-recipients=Destinat\u00e1rios
-selfAsRecipient=Incluir usu\u00e1rios relacionados Sobre
-recipientAttrType=Tipo de atributo de destinat\u00e1rio de email.
-recipientAttrName=Destinat\u00e1rios de e-mail para atributos de esquema
-checkRecipients=Buscar Destinat\u00e1rios
-checkAbout=Todos
-userFilter=Filtro de Usu\u00e1rio
-userFilterWarning=N\u00e3o use este filtro n\u00e3o ser que os eventos n\u00e3o s\u00e3o direcionados a usu\u00e1rios
-userNotifications=Notifica\u00e7\u00f5es do usu\u00e1rio
-userNotificationsWarning=N\u00e3o selecione esta op\u00e7\u00e3o a menos que os eventos n\u00e3o s\u00e3o direcionados a usu\u00e1rios
-isActive=Ativada
-checkUserAbout=Usu\u00e1rio
-checkGroupAbout=Grupos
-groupFilter=Filtro de Grupo
-groupFilterWarning=N\u00e3o use este filtro, a menos que os eventos n\u00e3o s\u00e3o dirigidas a grupos
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage.html
deleted file mode 100644
index c406ce9..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage.html
+++ /dev/null
@@ -1,111 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div id="dialog-form">
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
- <form wicket:id="form">
- <div id="tabs">
- <ul>
- <li class="tabs-selected"><a href="#profile"><span><wicket:message key="profile"/></span></a></li>
- <li><a href="#executions"><span><wicket:message key="executions"/></span></a></li>
- </ul>
- <div id="profile">
- <div id="users-contain" class="ui-widget">
- <span wicket:id="profile">
- <div id="formtable">
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <span wicket:id="idLabel">[Id]</span>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="key">[key]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="sender"><wicket:message key="sender"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="sender">[sender]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="recipients"><wicket:message key="recipients"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="recipients">[recipients]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="subject"><wicket:message key="subject"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="subject">[subject]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="textBody"><wicket:message key="textBody"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <textarea wicket:id="textBody" cols="40" rows="10">[textBody]</textarea>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="htmlBody"><wicket:message key="htmlBody"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <textarea wicket:id="htmlBody" cols="40" rows="10">[textBody]</textarea>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="traceLevel"><wicket:message key="traceLevel"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="traceLevel">[traceLevel]</span>
- </div>
- </div>
- </div>
- </span>
- </div>
- </div>
- <div id="executions" class="ui-widget">
- <span wicket:id="executionContainer" id="executionContainer">
- <table class="ui-widget ui-widget-content"
- wicket:id="executionsTable" style="width: 100%"/>
- </span>
- </div>
- </div>
- </form>
- </div>
- <div wicket:id="taskExecMessageWin"/>
- </wicket:extend>
-</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage.properties
deleted file mode 100644
index e9a3120..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage.properties
+++ /dev/null
@@ -1,32 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Profile
-executions=Executions
-title=Title
-startDate=Start date
-endDate=End date
-status=Status
-message=Message
-taskExecutions=Task executions
-delete=Delete
-showMessage=Show message
-sender=Sender
-subject=Subject
-recipients=Recipients
-traceLevel=Trace level
-htmlBody=E-mail body (HTML)
-textBody=E-mail body (TEXT)
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage_it.properties
deleted file mode 100644
index c0fa5bd..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage_it.properties
+++ /dev/null
@@ -1,32 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Profilo
-executions=Esecuzioni
-title=Task
-startDate=Data di avvio
-endDate=Data di conclusione
-status=Stato
-message=Messaggio
-taskExecutions=Esecuzione del task
-delete=Rimozione
-showMessage=Mostra
-sender=Mittente
-subject=Oggetto
-recipients=Destinatari
-traceLevel=Livello di tracciamento
-htmlBody=Corpo e-mail (HTML)
-textBody=Corpo e-mail (testo)
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage_pt_BR.properties
deleted file mode 100644
index 91aa59d..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/NotificationTaskModalPage_pt_BR.properties
+++ /dev/null
@@ -1,32 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Perfil
-executions=Execu\u00E7\u00F5es
-title=T\u00EDtulo
-startDate=Data Inicial
-endDate=Data Final
-status=Estatus
-message=Mensagem
-taskExecutions=Execu\u00E7\u00E3o de Tarefas
-delete=Excluir
-showMessage=Exibir Mensagem
-sender=Rementente
-subject=Assunto
-recipients=Destinat\u00E1rios
-traceLevel=N\u00EDvel de Trace
-htmlBody=Corpo do e-mail (HTML)
-textBody=Corpo do E-mail (TEXT)
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage.html
deleted file mode 100644
index 154419f..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/PlainSchemaModalPage.html
+++ /dev/null
@@ -1,172 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
- <div style="margin: 5px;">
- <form wicket:id="form">
- <div id="formtable">
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="key"><wicket:message key="key"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="key">[name]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="type"><wicket:message key="type"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="type">[type]</span>
- </div>
- </div>
-
- <div wicket:id="conversionParams">
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="conversionPattern"><wicket:message key="conversionPattern"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="conversionPattern">[conversionPattern]</span>
- </div>
- </div>
- </div>
-
- <div wicket:id="typeParams">
- <div wicket:id="enumParams">
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="enumerationValues"><wicket:message key="enumerationValues"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="enumerationValues">[enumerationValues]</span>
- </div>
- </div>
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="enumerationKeys"><wicket:message key="enumerationKeys"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="enumerationKeys">[enumerationKeys]</span>
- </div>
- </div>
- </div>
- <div wicket:id="encryptedParams">
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="secretKey"><wicket:message key="secretKey"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="secretKey">[secretKey]</span>
- </div>
- </div>
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="cipherAlgorithm"><wicket:message key="cipherAlgorithm"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="cipherAlgorithm">[cipherAlgorithm]</span>
- </div>
- </div>
- </div>
- <div wicket:id="binaryParams">
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="mimeType"><wicket:message key="mimeType"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="mimeType">[mimeType]</span>
- </div>
- </div>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="validatorClass"><wicket:message key="validatorClass"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="validatorClass">[validatorClass]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="mandatoryCondition"><wicket:message key="mandatoryCondition"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <input type="text" class="ui-widget-content ui-corner-all"
- id="mandatoryCondition" wicket:id="mandatoryCondition"/>
- <a class="tooltips" wicket:id="questionMarkJexlHelp" href="#" alt="Click to help" title="Click to help">
- <img src="img/help.png"/>
- <span wicket:id="jexlHelp" class="tooltips">
- <wicket:message key="jexl_info"/>
- <ul>
- <li><wicket:message key="jexl_ex1"/></li>
- <li><wicket:message key="jexl_ex2"/></li>
- </ul>
- <a href="#" wicket:id="jexlLink" target="_blank"><wicket:message key="jexl_syntax_url"/></a>
- </span>
- </a>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="uniqueConstraint" class="onerowlabel"><wicket:message key="uniqueConstraint"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="uniqueConstraint">[uniqueConstraint]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="multivalue" class="onerowlabel"><wicket:message key="multivalue"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="multivalue">[multivalue]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="readonly" class="onerowlabel"><wicket:message key="readonly"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="readonly">[readonly]</span>
- </div>
- </div>
- </div>
-
- <div style="margin: 10px 0px 0;">
- <input type="submit"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="apply"/>
- <input type="button"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="cancel"/>
- </div>
- </form>
- </div>
- </wicket:extend>
-</html>
[30/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Reports_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Reports_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Reports_it.properties
deleted file mode 100644
index 24b62ba..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Reports_it.properties
+++ /dev/null
@@ -1,24 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-audit=Audit
-lastExec=Ultima Esecuzione
-nextExec=Prossima Esecuzione
-latestExecStatus=Ultimo stato
-category=Categoria
-subcategory=Sottocategoria
-startDate=Data di avvio
-endDate=Data di conclusione
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Reports_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Reports_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Reports_pt_BR.properties
deleted file mode 100644
index c688a06..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Reports_pt_BR.properties
+++ /dev/null
@@ -1,24 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-audit=Auditar
-lastExec=\u00daltima Execu\u00e7\u00e3o
-nextExec=Pr\u00f3xima Execu\u00e7\u00e3o
-latestExecStatus=\u00daltimo Estatus
-category=Categoria
-subcategory=Subcategoria
-startDate=Data de in\u00edcio
-endDate=Data Final
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.html
deleted file mode 100644
index 90b4da8..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.html
+++ /dev/null
@@ -1,64 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div>
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
- <form wicket:id="form">
- <div id="formtable">
- <div class="tablerow alt">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="username"><wicket:message key="username"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="username">[username]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="securityQuestion"><span wicket:id="securityQuestionLabel"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="securityQuestion">[securityQuestion]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="securityAnswer"><span wicket:id="securityAnswerLabel"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="securityAnswer">[securityAnswer]</span>
- </div>
- </div>
- </div>
-
- <div style="margin: 20px 10px 0">
- <input type="submit"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="apply"/>
- <input type="button"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="cancel"/>
- </div>
- </form>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.properties
deleted file mode 100644
index 4cc999a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage.properties
+++ /dev/null
@@ -1,21 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-securityQuestion=Security question
-title=Password reset
-username=User
-securityAnswer=Security answer
-submit=Submit
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage_it.properties
deleted file mode 100644
index 77c1dd4..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage_it.properties
+++ /dev/null
@@ -1,21 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-securityQuestion=Domanda di sicurezza
-title=Password smarrita
-username=Utente
-securityAnswer=Risposta di sicurezza
-submit=Invia
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage_pt_BR.properties
deleted file mode 100644
index 27728db..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RequestPasswordResetModalPage_pt_BR.properties
+++ /dev/null
@@ -1,21 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-securityQuestion=Pergunta de seguran\u00e7a
-title=Redefini\u00e7\u00e3o de senha
-username=Usu\u00e1rio
-securityAnswer=Resposta de seguran\u00e7a
-submit=Apresentar
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage.html
deleted file mode 100644
index 8f2cdab..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage.html
+++ /dev/null
@@ -1,64 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div style="margin: 5px;">
- <p class="ui-widget ui-corner-all ui-widget-header">
- <span wicket:id="new"/> <wicket:message key="title"/> <span wicket:id="name"/>
- </p>
-
- <form wicket:id="form">
- <div id="tabs">
- <ul>
- <li class="tabs-selected"><a href="#resource"><span><wicket:message key="resource"/></span></a></li>
- <li><a href="#umapping"><span><wicket:message key="umapping"/></span></a></li>
- <li><a href="#gmapping"><span><wicket:message key="gmapping"/></span></a></li>
- <li><a href="#connectorProperties"><span><wicket:message key="connectorProperties"/></span></a></li>
- <li><a href="#security"><span><wicket:message key="security"/></span></a></li>
- </ul>
- <div id="resource">
- <span wicket:id="details">[details]</span>
- <span wicket:id="systeminformation">[System Information]</span>
- </div>
- <div id="umapping">
- <span wicket:id="umapping">[umapping]</span>
- </div>
- <div id="gmapping">
- <span wicket:id="gmapping">[gmapping]</span>
- </div>
- <div id="connectorProperties">
- <span wicket:id="connconf">[connconf]</span>
- </div>
- <div id="security">
- <span wicket:id="security">[security]</span>
- </div>
- </div>
-
- <div style="margin: 20px 10px 0">
- <input type="submit"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="apply"/>
- <input type="button"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="cancel"/>
- </div>
- </form>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage.properties
deleted file mode 100644
index 69e6e0a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage.properties
+++ /dev/null
@@ -1,60 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-resource=Resource details
-umapping=User mapping
-connectorProperties=Connector properties
-security=Security
-required_alert=All form fields are required
-connector=Connector
-existing_resources=Existing resources
-action=Action
-edit_attribute=Edit resource
-title=Resource
-extAttrNames=External attributes
-intMappingTypes=Internal mapping types
-entity=Entity
-groupSchema=Group Schema
-accountId=AccountId
-mandatoryCondition=Mandatory
-password=Password
-purpose=Purpose
-mappingUserSchema=Mapping User Schema
-mappingGroupSchema=Mapping Group Schema
-delete=Delete
-intAttrNames=Internal attributes
-enforceMandatoryCondition=Enforce mandatory condition
-fieldName=Field name
-
-accountIdValidation=There must be exactly one AccountId
-propagationMode=Propagation mode
-accountLink=Account link
-enable=Enable
-
-createTraceLevel=Create trace level
-updateTraceLevel=Update trace level
-deleteTraceLevel=Delete trace level
-syncTraceLevel=Synchronization trace level
-propagationPriority=Propagation priority
-propagationPrimary=Propagation primary
-
-success_connection=Successful connection
-error_connection=Connection failure
-check=Check connection
-actionsClasses=Actions classes
-gmapping=Group mapping
-new=New
-randomPwdIfNotProvided=Generate random passwords when missing
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage_it.properties
deleted file mode 100644
index a7b33b8..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage_it.properties
+++ /dev/null
@@ -1,60 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-resource=Dettagli Risorsa
-umapping=Mapping utenti
-connectorProperties=Propriet\u00e0\u00a0 Connettore
-security=Sicurezza
-required_alert=Tutti i campi sono richiesti
-connector=Connettore
-existing_resources=Risorse esistenti
-action=Azione
-edit_attribute=Modifica risorsa
-title=Risorsa
-extAttrNames=Attributi esterni
-intMappingTypes=Tipo mapping interno
-entity=Entità
-groupSchema=Schema Gruppo
-accountId=AccountId
-mandatoryCondition=Obbligatorio
-password=Password
-purpose=Scopo
-mappingUserSchema=Mapping User Schema
-mappingGroupSchema=Mapping Group Schema
-delete=Rimuovi
-intAttrNames=Attributi interni
-enforceMandatoryCondition=Abilita mandatory condition
-fieldName=Nome campo
-
-accountIdValidation=Deve essere definito esattamente un AccountId
-propagationMode=Modalit\u00e0 di propagazione
-accountLink=Account link
-enable=Abilita
-
-createTraceLevel=Livello di tracciamento delle creazioni
-updateTraceLevel=Livello di tracciamento degli aggiornamenti
-deleteTraceLevel=Livello di tracciamento delle cancellazioni
-syncTraceLevel=Livello di tracciamento delle sincronizzazioni
-propagationPriority=Priorit\u00e0 in propagazione
-propagationPrimary=Primaria in propagazione
-
-success_connection=Connessione avvenuta con successo
-error_connection=Connessione non riuscita
-check=Verifica connessione
-actionsClasses=Classi azioni
-gmapping=Mapping gruppi
-new=Nuova
-randomPwdIfNotProvided=Genera password casuali se mancanti
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage_pt_BR.properties
deleted file mode 100644
index be08c73..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResourceModalPage_pt_BR.properties
+++ /dev/null
@@ -1,60 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-resource=Detalhes de Recursos
-umapping=Mapeamento de usu\u00e1rios
-connectorProperties=Propriedades de Conectores
-security=Seguran\u00e7a
-required_alert=Todos os campos deste formul\u00e1rio s\u00e3o obrigat\u00f3rios
-connector=Conector
-existing_resources=Recursos Existentes
-action=A\u00e7\u00e3o
-edit_attribute=Alterar Recurso
-title=Recurso
-extAttrNames=Atributos Externos
-intMappingTypes=Tipos internos de mapeamentos
-entity=Entidade
-groupSchema=Esquema de Grupo
-accountId=Identificador da Conta
-mandatoryCondition=Obrigat\u00f3rio
-password=Senha
-purpose=Prop\u00f3sito
-mappingUserSchema=Esquema de mapeamento de usu\u00e1rio
-mappingGroupSchema=Esquema de mapeamento de grupo
-delete=Excluir
-intAttrNames=Atributos internos
-enforceMandatoryCondition=Aplicar condi\u00e7\u00e3o obrigat\u00f3ria
-fieldName=Nome do Campo
-
-accountIdValidation=Precisa ser exatamente um Identificador de Conta
-propagationMode=Modo de propaga\u00e7\u00e3o
-accountLink=Link de Conta
-enable=Habilitado
-
-createTraceLevel=Criar n\u00edvel de trace
-updateTraceLevel=Atualizar n\u00edvel de trace
-deleteTraceLevel=Excluir n\u00edvel de trace
-syncTraceLevel=N\u00edvel de trace de sincroniza\u00e7\u00e3o
-propagationPriority=Prioridade de propaga\u00e7\u00e3o
-propagationPrimary=Propaga\u00e7\u00e3o prim\u00e1ria
-
-success_connection=Conex\u00e3o com sucesso
-error_connection=Conex\u00e3o sem sucesso
-check=Verificar a conex\u00e3o
-actionsClasses=Classes de a\u00e7\u00f5es
-gmapping=Mapeamento de grupos
-new=Novo
-randomPwdIfNotProvided=Gerar senhas aleat\u00f3rias quando n\u00e3o houver
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Resources.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Resources.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Resources.html
deleted file mode 100644
index 6486a0e..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Resources.html
+++ /dev/null
@@ -1,99 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <style type="text/css">
- .true {
- background-image: url(../../img/ok.png);
- background-position: center center;
- background-repeat: no-repeat;
- height: 18px;
- width: 65px;
- }
- .false {
- width: 65px;
- }
- .narrowcolumn {
- width: 120px;
- }
- </style>
- </wicket:head>
- <wicket:extend>
-
- <div id="tabs">
- <ul>
- <li class="tabs-selected">
- <a href="#tabs-1"><span><wicket:message key="tab1"/></span></a>
- </li>
- <li><a href="#tabs-2"><span><wicket:message key="tab2"/></span></a></li>
- </ul>
- <div id="tabs-1">
- <div id="users-contain" class="ui-widget" style="width:inherit">
- <span wicket:id="resourceContainer">
- <span wicket:id="resourceDatatable">[resources]</span>
- </span>
-
- <span style="float:right">
- <form wicket:id="resourcePaginatorForm" style="display:inline">
- <label><wicket:message key="displayRows"/></label>
- <select class="text ui-widget-content ui-corner-all" wicket:id="rowsChooser"/>
- </form>
- </span>
- </div>
-
- <div wicket:id="statusModal">[Show modal window for provisioning status]</div>
- <div wicket:id="createResourceWin">[Show modal window for creating resource]</div>
- <div wicket:id="editResourceWin">[Show modal window for editing resource]</div>
-
- <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="createResourceLink">
- <wicket:message key="create-resource"/>
- </a>
- </div>
- <div id="tabs-2">
- <div id="users-contain" class="ui-widget" style="width:inherit">
- <span wicket:id="connectorContainer">
- <span wicket:id="connectorDatatable">[connectors]</span>
- </span>
-
- <span style="float:right">
- <form wicket:id="connectorPaginatorForm" style="display:inline">
- <label><wicket:message key="displayRows"/></label>
- <select class="text ui-widget-content ui-corner-all" wicket:id="rowsChooser"/>
- </form>
- </span>
- </div>
-
- <div wicket:id="createConnectorWin">[Show modal window for creating connector]</div>
- <div wicket:id="editConnectorWin">[Show modal window for editing connector]</div>
-
- <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="createConnectorLink">
- <wicket:message key="create-connector"/>
- </a>
- </div>
-
- <div>
- <a href="#" style="position: absolute; top: 4px; right:20px;" wicket:id="reloadLink">
- <img src="img/reload_30.png" width="25" height="25"
- alt="Reload connectors" title="title" wicket:message="title:reloadConnectors"/>
- </a>
- </div>
- </div>
-
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Resources.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Resources.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Resources.properties
deleted file mode 100644
index fb6b8a1..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Resources.properties
+++ /dev/null
@@ -1,34 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=Resources
-edit=Edit
-delete=Delete
-create-resource=Create
-propagationPriority=Propagation priority
-propagationPrimary=Propagation primary
-
-tab2=Connectors
-displayName=Display name
-version=Version
-bundleName=Bundle name
-edit=Edit
-delete=Delete
-create-connector=Create
-delete_error=Operation forbidden:the connector you're trying to delete is connected to a Resource
-connector=Connector
-reloadConnectors=Reload connectors
-confirmReloadConnectors=This request is potentially dangerous for running operations, continue?
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Resources_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Resources_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Resources_it.properties
deleted file mode 100644
index 80a5185..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Resources_it.properties
+++ /dev/null
@@ -1,34 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=Risorse
-edit=Modifica
-delete=Rimuovi
-create-resource=Crea
-propagationPriority=Priorit\u00e0 in propagazione
-propagationPrimary=Primaria in propagazione
-
-tab2=Connettori
-create-connector=Crea
-version=Versione
-bundleName=Bundle name
-edit=Modifica
-delete=Elimina
-delete_error=Operazione vietata: il connettore che si desidera rimuovere \u00e8 correlato ad una risorsa
-displayName=Nome visualizzato
-connector=Connettore
-reloadConnectors=Ricarica connettori
-confirmReloadConnectors=Questa richiesta \u00e8 potenzialmente dannosa per le operazioni in corso, proseguire?
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Resources_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Resources_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Resources_pt_BR.properties
deleted file mode 100644
index a631352..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Resources_pt_BR.properties
+++ /dev/null
@@ -1,32 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-tab1=Recursos
-edit=Alterar
-delete=Excluir
-create-resource=Criar
-propagationPriority=Prioridade de propaga\u00e7\u00e3o
-propagationPrimary=Propaga\u00e7\u00e3o prim\u00e1ria
-
-tab2=Conectores
-displayName=Mostar
-version=Vers\u00e3o
-bundleName=Nome do Pacote
-create-connector=Criar
-delete_error=Opera\u00e7\u00e3o n\u00e3o permitida\: o conector que voc\u00ea est\u00e1 tentando excluir est\u00e1 conectado a um recurso
-connector=Conector
-reloadConnectors=Carregar Conector
-confirmReloadConnectors=Esta requis\u00e7\u00e3o \u00e9 potencialmente perigosa para opera\u00e7\u00f5es em execu\u00e7\u00e3o, prosseguir?
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage.html
deleted file mode 100644
index 647a311..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage.html
+++ /dev/null
@@ -1,226 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <style>
- div#propagation {
- font-size: 8px;
- height: auto;
- margin-top: 3px;
- text-align: left;
- }
-
- div#status {
- float: left;
- height: 25px;
- margin-top: 3px;
- text-align: center;
- width: 8%;
- }
-
- div.assignment {
- border: 1px solid #DDDDDD;
- display: inline-table;
- margin-bottom: 20px;
- width: 100%;
- }
-
- div.assignments {
- color: #555555;
- display: inline-table;
- margin-top: 20px;
- width: 100%;
- }
-
- div.header {
- display: inline-table;
- margin: 5px;
- width: 98%;
- }
-
- div.profile div#row{
- display: inline-table;
- width:100%;
- vertical-align: middle;
- }
-
- div.profile {
- background-color: #EEEEEE;
- color: #555555;
- display: inline-table;
- margin: 0px 5px 5px 5px;
- width: 98%;
- }
-
- div#name {
- border-bottom: 1px solid #DDDDDD;
- display: table-cell;
- height: 15px;
- width: 220px;
- padding: 0px 5px 0px 5px;
- vertical-align: middle;
- }
-
- div#value {
- border-bottom: 1px solid #DDDDDD;
- border-left: 1px solid #DDDDDD;
- display: table-cell;
- height: 15px;
- width: 38%;
- padding: 0px 5px 0px 5px;
- overflow: hidden;
- vertical-align: middle;
- }
-
- div#resource {
- display: table-cell;
- width: 220px;
- height: 30px;
- padding: 10px 0px 5px 0px;
- }
-
- div#resource img{
- width: 12px;
- height: 12px;
- position: relative;
- left: 3px;
- top: 1px;
- opacity: 1;
- }
-
- div#attrhead {
- display: table-cell;
- border-left: 1px solid #DDDDDD;
- width: 38%;
- height: 30px;
- padding: 3px 0px 5px 0px;
- text-align: center;
- vertical-align: middle;
- font-size: 11px;
- }
- </style>
- </wicket:head>
- <wicket:extend>
-
- <wicket:fragment wicket:id="propagationResultFrag">
- <p class="ui-widget ui-corner-all ui-widget-header">
- <wicket:message key="operationResult"/> <span wicket:id="info"/>
- </p>
-
- <div class="assignments">
- <div wicket:id="resources" class="assignment">
-
- <span wicket:id="attrhead">[Attributes head]</span>
-
- <div class="profile">
- <span wicket:id="attrs">
- <div id="row">
- <div id="name">
- <span wicket:id="attrName">[Attribute name]</span>
- </div>
- <div id="value">
- <span wicket:id="beforeValue">[Before value]</span>
- </div>
- <div id="value">
- <span wicket:id="afterValue">[After value]</span>
- </div>
- </div>
- </span>
- </div>
- </div>
- </div>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="userSelfResultFrag">
- <p><wicket:message key="selfResult"/></p>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="remoteStatusFrag">
- <img wicket:id="status"/>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="attrValueFrag">
- <span wicket:id="value">[After value]</span>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="attrHeadFrag">
- <div class="header alt">
- <div id="resource">
- <div>
- <span wicket:id="resource">[resource name]</span>
- <a wicket:id="showFailureWindow" href="#">
- <img wicket:id="icon"/>
- </a>
-
- <div id="propagation">
- <wicket:message key="propresult">[propagation result message]</wicket:message>
-
- <span wicket:id="propagation">[propagation result]</span>
- </div>
-
- <div wicket:id="failureWindow"></div>
-
- </div>
- </div>
-
- <div id="attrhead">
- <wicket:message key="before">[before]</wicket:message>
- </div>
-
- <div id="attrhead">
- <wicket:message key="after">[after]</wicket:message>
- </div>
- </div>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="emptyAttrHeadFrag">
- <div class="header alt">
- <div id="resource">
- <div>
- <span wicket:id="resource">[resource name]</span>
- <a wicket:id="showFailureWindow" href="#">
- <img wicket:id="icon"/>
- </a>
-
- <div id="propagation">
- <wicket:message key="propresult">[propagation result message]</wicket:message>
-
- <span wicket:id="propagation">[propagation result]</span>
- <div wicket:id="failureWindow"></div>
-
- </div>
-
- </div>
- </div>
- </div>
- </wicket:fragment>
-
- <wicket:fragment wicket:id="emptyFrag">
- </wicket:fragment>
-
- <div wicket:id="container" id="users-contain" class="ui-widget" style="margin:30px; width:inherit">
-
- <span wicket:id="resultFrag"/>
-
- <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="close">
- <wicket:message key="close"/>
- </a>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage.properties
deleted file mode 100644
index 3ee25f8..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage.properties
+++ /dev/null
@@ -1,26 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-operationResult=Operation result for
-close=Close
-selfResult=Your request has been registered: depending on configuration, approval might be required.
-__NAME__=Account Link
-__UID__=Account Id
-__PASSWORD__=Password
-__ENABLE__=Enabled
-propresult=Propagation:
-before=Before propagation
-after=After propagation
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage_it.properties
deleted file mode 100644
index 92ee70e..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage_it.properties
+++ /dev/null
@@ -1,26 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-operationResult=Risultato dell'operazione per
-close=Chiudi
-selfResult=La sua richiesta \u00e8 stata presa in carico: se la configurazione lo prevede, sar\u00e0 necessaria l'approvazione.
-__NAME__=Account Link
-__UID__=Account Id
-__PASSWORD__=Password
-__ENABLE__=Abilitato
-propresult=Propagazione:
-before=Prima della propagazione
-after=Dopo la propagazione
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage_pt_BR.properties
deleted file mode 100644
index 319d1c9..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/ResultStatusModalPage_pt_BR.properties
+++ /dev/null
@@ -1,26 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-operationResult=Resultado de opera\u00E7\u00E3o para\:
-close=Fechar
-selfResult=Sua requis\u00E7\u00E3o foi registrada e ser\u00E1 encaminhada ao administrador respons\u00E1vel. Obrigado
-__NAME__=Link de conta
-__UID__=Identificador de Conta
-__PASSWORD__=Senha
-__ENABLE__=Habilitado
-propresult=Propaga\u00E7\u00E3o
-before=Antes da Propaga\u00E7\u00E3o
-after=Depois da Propaga\u00E7\u00E3o
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage.html
deleted file mode 100644
index a237c27..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage.html
+++ /dev/null
@@ -1,49 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <link rel="stylesheet" type="text/css" href="webjars/codemirror/${codemirror.version}/lib/codemirror.css"/>
-
- <script type="text/javascript" src="webjars/codemirror/${codemirror.version}/lib/codemirror.js"></script>
- <script type="text/javascript" src="webjars/codemirror/${codemirror.version}/mode/xml/xml.js"></script>
- <script type="text/javascript">
- function updateTextArea(editor) {
- document.getElementById("routeDefForm").elements["routeContent"].value = editor.getValue();
- }
- </script>
- </wicket:head>
- <wicket:extend>
- <form wicket:id="routeDefForm" id="routeDefForm">
- <textarea wicket:id="routeContent" id="routeContent" name="routeContent" style="width: 100%; height: 350px;">
- </textarea>
- <div style="margin: 10px;">
- <input type="submit"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="apply"
- onclick=""/>
- </div>
- </form>
- <script>
- window.onload = function(){
- var editor = CodeMirror.fromTextArea(document.getElementById("routeContent"),{lineNumbers: true});
- editor.on("change", updateTextArea);
- }
- </script>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage.properties
deleted file mode 100644
index 8ac2655..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Edit route
-id=id
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage_it.properties
deleted file mode 100644
index 44663f7..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage_it.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Modifica le rotte
-id=id
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage_pt_BR.properties
deleted file mode 100644
index a6395a0..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/RouteModalPage_pt_BR.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Editar rotas
-id=id
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage.html
deleted file mode 100644
index 2d25618..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage.html
+++ /dev/null
@@ -1,136 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div style="margin: 5px;">
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
- <form wicket:id="form">
- <div id="tabs">
- <ul>
- <li class="tabs-selected"><a href="#profile"><span><wicket:message key="profile"/></span></a></li>
- <li><a href="#crontab"><span><wicket:message key="crontab"/></span></a></li>
- <li><a href="#executions"><span><wicket:message key="executions"/></span></a></li>
- </ul>
- <div id="profile">
- <div id="users-contain" class="ui-widget">
- <span wicket:id="profile">
- <div id="formtable">
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <span wicket:id="idLabel">[Id]</span>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="key">[key]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="name"><wicket:message key="name"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="name">[name]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="description"><wicket:message key="description"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="description">[description]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="jobClassName"><wicket:message key="class"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="jobClassName">[jobClassName]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="lastExec"><wicket:message key="lastExec"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="lastExec">[lastExec]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="nextExec"><wicket:message key="nextExec"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="nextExec">[nextExec]</span>
- </div>
- </div>
- </div>
-
- <script type="text/javascript">
- $(function () {
- $('#formtable div.tablerow:even').addClass("alt");
- });
- </script>
- </span>
- </div>
- </div>
- <div id="crontab">
- <span wicket:id="crontab">
- <div id="formtable">
- <div class="tablerow alt">
- <label for="cron"><wicket:message key="cron"/></label>
- </div>
- <div class="tablerow">
- <input type="text" id="seconds" class="text ui-widget-content ui-corner-all" wicket:id="seconds" style="width: 50px;float: left" />
- <input type="text" id="minutes" class="text ui-widget-content ui-corner-all" wicket:id="minutes" style="width: 50px;float: left" />
- <input type="text" id="hours" class="text ui-widget-content ui-corner-all" wicket:id="hours" style="width: 50px;float: left" />
- <input type="text" id="daysOfMonth" class="text ui-widget-content ui-corner-all" wicket:id="daysOfMonth" style="width: 50px;float: left" />
- <input type="text" id="months" class="text ui-widget-content ui-corner-all" wicket:id="months" style="width: 50px;float: left" />
- <input type="text" id="daysOfWeek" class="text ui-widget-content ui-corner-all" wicket:id="daysOfWeek" style="width: 50px" />
- </div>
- <div class="tablerow alt">
- <label for="cronExpression"><wicket:message key="templates"/></label>
- </div>
- <div class="tablerow">
- <select class="text ui-widget-content ui-corner-all" wicket:id="cronTemplateChooser" style="width: 250px"/>
- </div>
- </div>
- </span>
- </div>
- <div id="executions" class="ui-widget">
- <span wicket:id="executionContainer" id="executionContainer">
- <table class="ui-widget ui-widget-content"
- wicket:id="executionsTable" style="width: 100%"/>
- </span>
- </div>
- </div>
- <div style="margin: 20px 10px 0">
- <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="apply"/>
- <input type="button" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="cancel"/>
- </div>
- </form>
- </div>
- <div wicket:id="taskExecMessageWin"/>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage.properties
deleted file mode 100644
index 3e0f41c..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage.properties
+++ /dev/null
@@ -1,36 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Profile
-crontab=Schedule
-executions=Executions
-title=Task
-class=Class
-name=Name
-description=Description
-lastExec=Last Execution
-nextExec=Next Execution
-cron=Schedule (seconds, minutes, hours, days of month, months, days of week)
-templates=Remove task from scheduler / Use a template to schedule
-apply=Save
-startDate=Start date
-endDate=End date
-status=Status
-message=Message
-taskExecutions=Task executions
-delete=Delete
-showMessage=Show
-chooseForTemplate=Use A Template
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage_it.properties
deleted file mode 100644
index fefc847..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage_it.properties
+++ /dev/null
@@ -1,36 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Profilo
-crontab=Schedule
-executions=Esecuzioni
-title=Task
-class=Classe
-name=Nome
-description=Descrizione
-lastExec=Ultima Esecuzione
-nextExec=Prossima Esecuzione
-cron=Schedule (secondi, minuti, ore, giorni del mese, mesi, giorni della settimana)
-templates=Rimuovi task dallo scheduler / Utilizza un template per schedulare
-apply=Salva
-startDate=Data di avvio
-endDate=Data di conclusione
-status=Stato
-message=Messaggio
-taskExecutions=Esecuzione del task
-delete=Rimozione
-showMessage=Mostra
-chooseForTemplate=Usa Un Template
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage_pt_BR.properties
deleted file mode 100644
index 36738b8..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SchedTaskModalPage_pt_BR.properties
+++ /dev/null
@@ -1,36 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-profile=Perfil
-crontab=Agenda
-executions=Execu\u00E7\u00F5es
-title=Tarefa
-class=Classe
-name=Nome
-description=Descri\u00E7\u00E3o
-lastExec=\u00DAltima execu\u00E7\u00E3o
-nextExec=Pr\u00F3xima Execu\u00E7\u00E3o
-cron=Agendar (segundos, minutos, horas, dias do m\u00EAs, meses, dias da semana)
-templates=Remover tarefa do agendamento / Usar template para agendar
-apply=Salvar
-startDate=Data de In\u00EDcio
-endDate=Data de Conclus\u00E3o
-status=Estatus
-message=Mensagem
-taskExecutions=Execu\u00E7\u00E3o de Tarefas
-delete=Excluir
-showMessage=Mostrar
-chooseForTemplate=Usar um template
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema$SchemaTypePanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema$SchemaTypePanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema$SchemaTypePanel.html
deleted file mode 100644
index acc761e..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema$SchemaTypePanel.html
+++ /dev/null
@@ -1,41 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div wicket:id="schemaWrapContainer" id="users-contain" class="ui-widget">
- <span wicket:id="schemaContainer">
- <table class="ui-widget ui-widget-content table-hover" wicket:id="datatable"/>
- </span>
-
- <span style="float:right">
- <form wicket:id="paginatorForm" style="display:inline">
- <label><wicket:message key="displayRows"/></label>
- <select class="text ui-widget-content ui-corner-all" wicket:id="rowsChooser"/>
- </form>
- </span>
- </div>
-
- <div wicket:id="editSchemaWin">[Show modal window for editing schema]</div>
-
- <a wicket:id="createSchemaLink"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only">
- <wicket:message key="create"/>
- </a>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema.html
deleted file mode 100644
index af0b83f..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema.html
+++ /dev/null
@@ -1,59 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <style type="text/css">
- .true {
- background-image: url(../../img/ok.png);
- background-position: center center;
- background-repeat: no-repeat;
- height: 18px;
- width: 65px;
- }
- .false {
- width: 65px;
- }
- </style>
- </wicket:head>
- <wicket:extend>
-
- <div id="tabs">
- <ul>
- <li class="tabs-selected"><a href="#cschema"><wicket:message key="configuration"/></a></li>
- <li><a href="#uschema"><wicket:message key="user"/></a></li>
- <li><a href="#mschema"><wicket:message key="membership"/></a></li>
- <li><a href="#gschema"><wicket:message key="group"/></a></li>
- </ul>
-
- <div id="cschema">
- <div wicket:id="configurationTabs"/>
- </div>
- <div id="uschema">
- <div wicket:id="userTabs"/>
- </div>
- <div id="mschema">
- <div wicket:id="membershipTabs"/>
- </div>
- <div id="gschema">
- <div wicket:id="groupTabs"/>
- </div>
- </div>
-
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema.properties
deleted file mode 100644
index 920d29c..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema.properties
+++ /dev/null
@@ -1,35 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-user=User
-group=Group
-membership=Membership
-required_alert=All fields are required
-mandatory=Mandatory
-multivalue=Multivalue
-type=Type
-validatorClass=Validator class
-conversionPattern=Conversion pattern
-edit=Edit
-delete=Delete
-attributes=Attributes
-expression=Expression
-plain=Plain
-derived=Derived
-virtual=Virtual
-mandatoryCondition=Mandatory
-uniqueConstraint=Unique
-readonly=Read-only
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema_it.properties
deleted file mode 100644
index 186b540..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema_it.properties
+++ /dev/null
@@ -1,35 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-user=Utente
-group=Gruppo
-membership=Membership
-required_alert=Tutti i campi sono richiesti.
-mandatory=Obbligatorio
-multivalue=Multivalore
-type=Tipo
-validatorClass=Validator class
-conversionPattern=Pattern di conversione
-edit=Modifica
-delete=Rimuovi
-attributes=Attributi
-expression=Expression
-plain=Normali
-derived=Derivati
-virtual=Virtuali
-mandatoryCondition=Obbligatorio
-uniqueConstraint=Univoco
-readonly=Sola lettura
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema_pt_BR.properties
deleted file mode 100644
index 8c41db6..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/Schema_pt_BR.properties
+++ /dev/null
@@ -1,35 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-user=Usu\u00e1rio
-group=Grupo
-membership=Membro
-required_alert=Todos os campos s\u00e3o requeridos
-mandatory=Obrigat\u00f3rio
-multivalue=Multivalorado
-type=Tipo
-validatorClass=classe de Valida\u00e7\u00e3o
-conversionPattern=Padr\u00e3o de Convers\u00e3o
-edit=Editar
-delete=Remover
-attributes=Atributos
-expression=Express\u00e3o
-plain=Normal
-derived=Derivado
-virtual=Virtual
-mandatoryCondition=Mandat\u00f3rio
-uniqueConstraint=\u00danico
-readonly=Apenas leitura
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.html
deleted file mode 100644
index fe4fad4..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.html
+++ /dev/null
@@ -1,46 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:extend>
- <div>
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="title"/></p>
- <form wicket:id="form">
- <div id="formtable">
- <div class="tablerow alt">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="content"><wicket:message key="content"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="content">[content]</span>
- </div>
- </div>
- </div>
-
- <div style="margin: 20px 10px 0">
- <input type="submit"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="apply"/>
- <input type="button"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="cancel"/>
- </div>
- </form>
- </div>
- </wicket:extend>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.properties
deleted file mode 100644
index 3f7ab40..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Security question
-content=Text
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage_it.properties
deleted file mode 100644
index 6324e64..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage_it.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Domanda di sicurezza
-content=Testo
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage_pt_BR.properties
deleted file mode 100644
index 511b4ad..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SecurityQuestionModalPage_pt_BR.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Pergunta de seguran\u00e7a
-content=Texto
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/pages/SignOut.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/pages/SignOut.html b/client/console/src/main/resources/org/apache/syncope/client/console/pages/SignOut.html
new file mode 100644
index 0000000..6ced70a
--- /dev/null
+++ b/client/console/src/main/resources/org/apache/syncope/client/console/pages/SignOut.html
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied. See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
+ <head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
+ <meta http-equiv="Content-Style-Type" content="text/css"/>
+ <meta http-equiv="Content-Script-Type" content="text/javascript"/>
+
+ <title>Apache Syncope</title>
+ </head>
+ <body>
+ <h1>Goodbye!</h1>
+
+ <wicket:link><a href="HomePage.html">Home</a></wicket:link>
+ </body>
+</html>
[40/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupTabPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupTabPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupTabPanel.java
deleted file mode 100644
index 9615554..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/GroupTabPanel.java
+++ /dev/null
@@ -1,195 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.Mode;
-import org.apache.syncope.client.console.commons.XMLRolesReader;
-import org.apache.syncope.client.console.pages.ResultStatusModalPage;
-import org.apache.syncope.client.console.pages.GroupModalPage;
-import org.apache.syncope.client.console.pages.Groups;
-import org.apache.syncope.client.console.pages.StatusModalPage;
-import org.apache.syncope.client.console.rest.GroupRestClient;
-import org.apache.syncope.client.console.rest.UserRestClient;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.client.lib.SyncopeClient;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class GroupTabPanel extends Panel {
-
- private static final long serialVersionUID = 859236186975983959L;
-
- @SpringBean
- private XMLRolesReader xmlRolesReader;
-
- @SpringBean
- private GroupRestClient groupRestClient;
-
- @SpringBean
- private UserRestClient userRestClient;
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- public GroupTabPanel(final String id, final GroupTO selectedNode, final ModalWindow window,
- final PageReference pageRef) {
-
- super(id);
-
- this.add(new Label("displayName", selectedNode.getDisplayName()));
-
- final ActionLinksPanel links = new ActionLinksPanel("actionLinks", new Model(), pageRef);
- links.setOutputMarkupId(true);
- this.add(links);
- links.addWithRoles(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- GroupTO groupTO = new GroupTO();
- groupTO.setParent(selectedNode.getKey());
- return new GroupModalPage(pageRef, window, groupTO);
- }
- });
-
- window.show(target);
- }
- }, ActionLink.ActionType.CREATE, xmlRolesReader.getEntitlement("Groups", "create"));
- links.addWithRoles(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new StatusModalPage<GroupTO>(pageRef, window, groupRestClient.read(selectedNode.getKey()));
- }
- });
-
- window.show(target);
- }
- }, ActionLink.ActionType.MANAGE_RESOURCES, xmlRolesReader.getEntitlement("Groups", "update"));
- links.addWithRoles(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- GroupTO groupTO = groupRestClient.read(selectedNode.getKey());
- return new GroupModalPage(pageRef, window, groupTO);
- }
- });
-
- window.show(target);
- }
- }, ActionLink.ActionType.EDIT, xmlRolesReader.getEntitlement("Groups", "update"));
- links.addWithRoles(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- final GroupTO groupTO = groupRestClient.delete(selectedNode.getETagValue(), selectedNode.getKey());
-
- ((Groups) pageRef.getPage()).setModalResult(true);
-
- window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ResultStatusModalPage.Builder(window, groupTO).build();
- }
- });
-
- window.show(target);
- } catch (SyncopeClientException e) {
- error(getString(Constants.OPERATION_ERROR) + ": " + e.getMessage());
- ((Groups) pageRef.getPage()).getFeedbackPanel().refresh(target);
- }
- }
- }, ActionLink.ActionType.DELETE, xmlRolesReader.getEntitlement("Groups", "delete"));
-
- final Form form = new Form("groupForm");
- form.setModel(new CompoundPropertyModel(selectedNode));
- form.setOutputMarkupId(true);
-
- final GroupPanel groupPanel = new GroupPanel.Builder("groupPanel").
- form(form).groupTO(selectedNode).groupModalPageMode(Mode.ADMIN).build();
- groupPanel.setEnabled(false);
- form.add(groupPanel);
-
- final WebMarkupContainer userListContainer = new WebMarkupContainer("userListContainer");
-
- userListContainer.setOutputMarkupId(true);
- userListContainer.setEnabled(true);
- userListContainer.add(new UserSearchResultPanel("userList", true, null, pageRef, userRestClient));
- userListContainer.add(new ClearIndicatingAjaxButton("search", new ResourceModel("search"), pageRef) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
- userListContainer.replace(new UserSearchResultPanel("userList",
- true,
- SyncopeClient.getUserSearchConditionBuilder().inGroups(selectedNode.getKey()).query(),
- pageRef,
- userRestClient));
-
- target.add(userListContainer);
- }
- });
-
- form.add(userListContainer);
- add(form);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/JQueryUITabbedPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/JQueryUITabbedPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/JQueryUITabbedPanel.java
deleted file mode 100644
index d898ba6..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/JQueryUITabbedPanel.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.List;
-import org.apache.wicket.extensions.ajax.markup.html.tabs.AjaxTabbedPanel;
-import org.apache.wicket.extensions.markup.html.tabs.ITab;
-
-/**
- * AjaxTabbedPanel with JQueryUI styling.
- */
-public class JQueryUITabbedPanel<T extends ITab> extends AjaxTabbedPanel<T> {
-
- private static final long serialVersionUID = -5059184710433341333L;
-
- public JQueryUITabbedPanel(final String id, final List<T> tabs) {
- super(id, tabs);
- }
-
- @Override
- protected String getTabContainerCssClass() {
- return "";
- }
-
- @Override
- protected String getSelectedTabCssClass() {
- return "ui-state-active selected";
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/LayoutsPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/LayoutsPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/LayoutsPanel.java
deleted file mode 100644
index 26f1894..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/LayoutsPanel.java
+++ /dev/null
@@ -1,130 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.List;
-import org.apache.syncope.client.console.commons.AttrLayoutType;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.SelectChoiceRenderer;
-import org.apache.syncope.client.console.commons.XMLRolesReader;
-import org.apache.syncope.client.console.rest.ConfigurationRestClient;
-import org.apache.syncope.client.console.rest.SchemaRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPalettePanel;
-import org.apache.syncope.common.lib.to.AttrTO;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.model.util.ListModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-
-public class LayoutsPanel extends Panel {
-
- /**
- * Logger.
- */
- private static final Logger LOG = LoggerFactory.getLogger(LayoutsPanel.class);
-
- private static final long serialVersionUID = -6804066913177804275L;
-
- private static final String CANCEL = "cancel";
-
- private static final String APPLY = "apply";
-
- @SpringBean
- protected XMLRolesReader xmlRolesReader;
-
- @SpringBean
- private SchemaRestClient schemaRestClient;
-
- @SpringBean
- private ConfigurationRestClient confRestClient;
-
- @SuppressWarnings("unchecked")
- public LayoutsPanel(final String id, final AttrLayoutType attrLayoutType, final NotificationPanel feedbackPanel) {
- super(id);
-
- final WebMarkupContainer container = new WebMarkupContainer("container");
- container.setOutputMarkupId(true);
-
- final Form<String> form = new Form<String>("form");
- form.setOutputMarkupId(true);
-
- final AttrTO attrLayout = confRestClient.readAttrLayout(attrLayoutType);
- form.setModel(new CompoundPropertyModel(attrLayout.getValues()));
-
- final List<String> fields = schemaRestClient.getPlainSchemaNames(attrLayoutType.getAttrType());
- final ListModel<String> selectedFields =
- new ListModel<String>(attrLayout.getValues().isEmpty() ? fields : attrLayout.getValues());
- final ListModel<String> availableFields = new ListModel<String>(fields);
-
- form.add(new AjaxPalettePanel<String>("fields", selectedFields, availableFields,
- new SelectChoiceRenderer<String>(), true, true));
-
- final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(APPLY)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- try {
- confRestClient.set(attrLayout);
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (Exception e) {
- LOG.error("While saving layout configuration", e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- }
- feedbackPanel.refresh(target);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- error(getString(Constants.ERROR) + ": While saving layout configuration");
- feedbackPanel.refresh(target);
- }
- };
-
- form.add(submit);
-
- final IndicatingAjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- target.add(container);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- }
- };
-
- cancel.setDefaultFormProcessing(false);
- form.add(cancel);
- container.add(form);
- add(container);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/LoggerCategoryPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/LoggerCategoryPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/LoggerCategoryPanel.java
deleted file mode 100644
index 70e0361..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/LoggerCategoryPanel.java
+++ /dev/null
@@ -1,461 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Set;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.commons.lang3.tuple.Pair;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.panels.SelectedEventsPanel.EventSelectionChanged;
-import org.apache.syncope.client.console.panels.SelectedEventsPanel.InspectSelectedEvent;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.common.lib.to.EventCategoryTO;
-import org.apache.syncope.common.lib.types.AuditElements;
-import org.apache.syncope.common.lib.types.AuditElements.EventCategoryType;
-import org.apache.syncope.common.lib.types.AuditLoggerName;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.event.Broadcast;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.IChoiceRenderer;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-
-public abstract class LoggerCategoryPanel extends Panel {
-
- private static final long serialVersionUID = 6429053774964787734L;
-
- private final List<EventCategoryTO> eventCategoryTOs;
-
- private final EventCategoryTO eventCategoryTO = new EventCategoryTO();
-
- private final WebMarkupContainer categoryContainer;
-
- private final WebMarkupContainer eventsContainer;
-
- private final SelectedEventsPanel selectedEventsPanel;
-
- private final AjaxDropDownChoicePanel<EventCategoryType> type;
-
- private final AjaxDropDownChoicePanel<String> category;
-
- private final AjaxDropDownChoicePanel<String> subcategory;
-
- private final AjaxTextFieldPanel custom;
-
- private final ActionLinksPanel actionPanel;
-
- private final IModel<List<String>> model;
-
- public LoggerCategoryPanel(
- final String id,
- final List<EventCategoryTO> eventCategoryTOs,
- final IModel<List<String>> model,
- final PageReference pageReference,
- final String pageId) {
- super(id);
-
- this.model = model;
- selectedEventsPanel = new SelectedEventsPanel("selectedEventsPanel", model);
- add(selectedEventsPanel);
-
- this.eventCategoryTOs = eventCategoryTOs;
-
- categoryContainer = new WebMarkupContainer("categoryContainer");
- categoryContainer.setOutputMarkupId(true);
- add(categoryContainer);
-
- eventsContainer = new WebMarkupContainer("eventsContainer");
- eventsContainer.setOutputMarkupId(true);
- add(eventsContainer);
-
- authorizeList();
- authorizeChanges();
-
- categoryContainer.add(new Label("typeLabel", new ResourceModel("type", "type")));
-
- type = new AjaxDropDownChoicePanel<EventCategoryType>(
- "type",
- "type",
- new PropertyModel<EventCategoryType>(eventCategoryTO, "type"),
- false);
- type.setChoices(Arrays.asList(EventCategoryType.values()));
- type.setStyleSheet("ui-widget-content ui-corner-all");
- type.setChoiceRenderer(new IChoiceRenderer<EventCategoryType>() {
-
- private static final long serialVersionUID = 2317134950949778735L;
-
- @Override
- public String getDisplayValue(final EventCategoryType eventCategoryType) {
- return eventCategoryType.name();
- }
-
- @Override
- public String getIdValue(final EventCategoryType eventCategoryType, final int i) {
- return eventCategoryType.name();
- }
- });
- categoryContainer.add(type);
-
- type.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- send(LoggerCategoryPanel.this, Broadcast.EXACT, new ChangeCategoryEvent(target, type));
- }
- });
-
- categoryContainer.add(new Label("categoryLabel", new ResourceModel("category", "category")));
-
- category = new AjaxDropDownChoicePanel<String>(
- "category",
- "category",
- new PropertyModel<String>(eventCategoryTO, "category"),
- false);
- category.setChoices(filter(eventCategoryTOs, type.getModelObject()));
- category.setStyleSheet("ui-widget-content ui-corner-all");
- categoryContainer.add(category);
-
- category.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306811L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- send(LoggerCategoryPanel.this, Broadcast.EXACT, new ChangeCategoryEvent(target, category));
- }
- });
-
- categoryContainer.add(new Label("subcategoryLabel", new ResourceModel("subcategory", "subcategory")));
-
- subcategory = new AjaxDropDownChoicePanel<String>(
- "subcategory",
- "subcategory",
- new PropertyModel<String>(eventCategoryTO, "subcategory"),
- false);
- subcategory.setChoices(filter(eventCategoryTOs, type.getModelObject(), category.getModelObject()));
- subcategory.setStyleSheet("ui-widget-content ui-corner-all");
- categoryContainer.add(subcategory);
-
- subcategory.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306812L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- send(LoggerCategoryPanel.this, Broadcast.EXACT, new ChangeCategoryEvent(target, subcategory));
- }
- });
-
- categoryContainer.add(new Label("customLabel", new ResourceModel("custom", "custom")).setVisible(false));
-
- custom = new AjaxTextFieldPanel("custom", "custom", new Model<String>(null));
- custom.setStyleSheet("ui-widget-content ui-corner-all short_fixedsize");
- custom.setVisible(false);
- custom.setEnabled(false);
-
- categoryContainer.add(custom);
-
- actionPanel = new ActionLinksPanel("customActions", new Model(), pageReference);
- categoryContainer.add(actionPanel);
-
- actionPanel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- if (StringUtils.isNotBlank(custom.getModelObject())) {
- final Pair<EventCategoryTO, AuditElements.Result> parsed =
- AuditLoggerName.parseEventCategory(custom.getModelObject());
-
- final String eventString = AuditLoggerName.buildEvent(
- parsed.getKey().getType(),
- null,
- null,
- parsed.getKey().getEvents().isEmpty()
- ? StringUtils.EMPTY : parsed.getKey().getEvents().iterator().next(),
- parsed.getValue());
-
- custom.setModelObject(StringUtils.EMPTY);
- send(LoggerCategoryPanel.this.getPage(), Broadcast.BREADTH, new EventSelectionChanged(
- target,
- Collections.<String>singleton(eventString),
- Collections.<String>emptySet()));
- target.add(categoryContainer);
- }
- }
- }, ActionLink.ActionType.CREATE, pageId, true);
-
- actionPanel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435502L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- if (StringUtils.isNotBlank(custom.getModelObject())) {
- Pair<EventCategoryTO, AuditElements.Result> parsed =
- AuditLoggerName.parseEventCategory(custom.getModelObject());
-
- String eventString = AuditLoggerName.buildEvent(
- parsed.getKey().getType(),
- null,
- null,
- parsed.getKey().getEvents().isEmpty()
- ? StringUtils.EMPTY : parsed.getKey().getEvents().iterator().next(),
- parsed.getValue());
-
- custom.setModelObject(StringUtils.EMPTY);
- send(LoggerCategoryPanel.this.getPage(), Broadcast.BREADTH, new EventSelectionChanged(
- target,
- Collections.<String>emptySet(),
- Collections.<String>singleton(eventString)));
- target.add(categoryContainer);
- }
- }
- }, ActionLink.ActionType.DELETE, pageId, true);
-
- actionPanel.setVisible(false);
- actionPanel.setEnabled(false);
-
- eventsContainer.add(new EventSelectionPanel("eventsPanel", eventCategoryTO, model) {
-
- private static final long serialVersionUID = 3513194801190026082L;
-
- @Override
- protected void onEventAction(final IEvent<?> event) {
- LoggerCategoryPanel.this.onEventAction(event);
- }
- });
- }
-
- private List<String> filter(
- final List<EventCategoryTO> eventCategoryTOs, final EventCategoryType type) {
- final Set<String> res = new HashSet<String>();
-
- for (EventCategoryTO eventCategory : eventCategoryTOs) {
- if (type == eventCategory.getType() && StringUtils.isNotEmpty(eventCategory.getCategory())) {
- res.add(eventCategory.getCategory());
- }
- }
-
- final List<String> filtered = new ArrayList<String>(res);
- Collections.sort(filtered);
- return filtered;
- }
-
- private List<String> filter(
- final List<EventCategoryTO> eventCategoryTOs, final EventCategoryType type, final String category) {
- final Set<String> res = new HashSet<String>();
-
- for (EventCategoryTO eventCategory : eventCategoryTOs) {
- if (type == eventCategory.getType() && StringUtils.equals(category, eventCategory.getCategory())
- && StringUtils.isNotEmpty(eventCategory.getSubcategory())) {
- res.add(eventCategory.getSubcategory());
- }
- }
-
- final List<String> filtered = new ArrayList<String>(res);
- Collections.sort(filtered);
- return filtered;
- }
-
- @Override
- @SuppressWarnings("unchecked")
- public void onEvent(final IEvent<?> event) {
- if (event.getPayload() instanceof ChangeCategoryEvent) {
- // update objects ....
- eventCategoryTO.getEvents().clear();
-
- final ChangeCategoryEvent change = (ChangeCategoryEvent) event.getPayload();
-
- final Panel changedPanel = change.getChangedPanel();
- if ("type".equals(changedPanel.getId())) {
- eventCategoryTO.setType(type.getModelObject());
- eventCategoryTO.setCategory(null);
- eventCategoryTO.setSubcategory(null);
-
- if (type.getModelObject() == EventCategoryType.CUSTOM) {
- category.setChoices(Collections.<String>emptyList());
- subcategory.setChoices(Collections.<String>emptyList());
- category.setEnabled(false);
- subcategory.setEnabled(false);
- custom.setVisible(true);
- custom.setEnabled(true);
- actionPanel.setVisible(true);
- actionPanel.setEnabled(true);
-
- } else {
- category.setChoices(filter(eventCategoryTOs, type.getModelObject()));
- subcategory.setChoices(Collections.<String>emptyList());
- category.setEnabled(true);
- subcategory.setEnabled(true);
- custom.setVisible(false);
- custom.setEnabled(false);
- actionPanel.setVisible(false);
- actionPanel.setEnabled(false);
- }
- change.getTarget().add(categoryContainer);
- } else if ("category".equals(changedPanel.getId())) {
- subcategory.setChoices(filter(eventCategoryTOs, type.getModelObject(), category.getModelObject()));
- eventCategoryTO.setCategory(category.getModelObject());
- eventCategoryTO.setSubcategory(null);
- change.getTarget().add(categoryContainer);
- } else {
- eventCategoryTO.setSubcategory(subcategory.getModelObject());
- }
-
- updateEventsContainer(change.getTarget());
- } else if (event.getPayload() instanceof InspectSelectedEvent) {
- // update objects ....
- eventCategoryTO.getEvents().clear();
-
- InspectSelectedEvent inspectSelectedEvent = (InspectSelectedEvent) event.getPayload();
-
- Pair<EventCategoryTO, AuditElements.Result> categoryEvent =
- AuditLoggerName.parseEventCategory(inspectSelectedEvent.getEvent());
-
- eventCategoryTO.setType(categoryEvent.getKey().getType());
- category.setChoices(filter(eventCategoryTOs, type.getModelObject()));
-
- eventCategoryTO.setCategory(categoryEvent.getKey().getCategory());
- subcategory.setChoices(filter(eventCategoryTOs, type.getModelObject(), category.getModelObject()));
-
- eventCategoryTO.setSubcategory(categoryEvent.getKey().getSubcategory());
-
- if (categoryEvent.getKey().getType() == EventCategoryType.CUSTOM) {
- custom.setModelObject(AuditLoggerName.buildEvent(
- categoryEvent.getKey().getType(),
- categoryEvent.getKey().getCategory(),
- categoryEvent.getKey().getSubcategory(),
- categoryEvent.getKey().getEvents().isEmpty()
- ? StringUtils.EMPTY : categoryEvent.getKey().getEvents().iterator().next(),
- categoryEvent.getValue()));
-
- category.setEnabled(false);
- subcategory.setEnabled(false);
- custom.setVisible(true);
- custom.setEnabled(true);
- actionPanel.setVisible(true);
- actionPanel.setEnabled(true);
- } else {
- category.setEnabled(true);
- subcategory.setEnabled(true);
- custom.setVisible(false);
- custom.setEnabled(false);
- actionPanel.setVisible(false);
- actionPanel.setEnabled(false);
- }
-
- inspectSelectedEvent.getTarget().add(categoryContainer);
- updateEventsContainer(inspectSelectedEvent.getTarget());
- }
- }
-
- private void setEvents() {
- final Iterator<EventCategoryTO> itor = eventCategoryTOs.iterator();
- while (itor.hasNext() && eventCategoryTO.getEvents().isEmpty()) {
- final EventCategoryTO eventCategory = itor.next();
- if (eventCategory.getType() == eventCategoryTO.getType()
- && StringUtils.equals(eventCategory.getCategory(), eventCategoryTO.getCategory())
- && StringUtils.equals(eventCategory.getSubcategory(), eventCategoryTO.getSubcategory())) {
- eventCategoryTO.getEvents().addAll(eventCategory.getEvents());
- }
- }
- }
-
- private class ChangeCategoryEvent {
-
- private final AjaxRequestTarget target;
-
- private final Panel changedPanel;
-
- public ChangeCategoryEvent(final AjaxRequestTarget target, final Panel changedPanel) {
- this.target = target;
- this.changedPanel = changedPanel;
- }
-
- public AjaxRequestTarget getTarget() {
- return target;
- }
-
- public Panel getChangedPanel() {
- return changedPanel;
- }
- }
-
- /**
- * To be extended in order to add actions on events.
- *
- * @param event event.
- */
- protected void onEventAction(final IEvent<?> event) {
- // nothing by default
- }
-
- private void authorizeList() {
- for (String role : getListRoles()) {
- MetaDataRoleAuthorizationStrategy.authorize(selectedEventsPanel, RENDER, role);
- }
- }
-
- private void authorizeChanges() {
- for (String role : getChangeRoles()) {
- MetaDataRoleAuthorizationStrategy.authorize(categoryContainer, RENDER, role);
- MetaDataRoleAuthorizationStrategy.authorize(eventsContainer, RENDER, role);
- }
- }
-
- private void updateEventsContainer(final AjaxRequestTarget target) {
- setEvents();
-
- eventsContainer.addOrReplace(new EventSelectionPanel("eventsPanel", eventCategoryTO, model) {
-
- private static final long serialVersionUID = 3513194801190026082L;
-
- @Override
- public void onEventAction(final IEvent<?> event) {
- LoggerCategoryPanel.this.onEventAction(event);
- }
- });
- target.add(eventsContainer);
- }
-
- protected abstract String[] getListRoles();
-
- protected abstract String[] getChangeRoles();
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/MembershipsPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/MembershipsPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/MembershipsPanel.java
deleted file mode 100644
index fa0a9bc..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/MembershipsPanel.java
+++ /dev/null
@@ -1,255 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.Collections;
-import java.util.HashSet;
-import java.util.List;
-import java.util.Set;
-import javax.swing.tree.DefaultMutableTreeNode;
-import org.apache.syncope.client.console.commons.Mode;
-import org.apache.syncope.client.console.commons.GroupTreeBuilder;
-import org.apache.syncope.client.console.commons.status.StatusUtils;
-import org.apache.syncope.client.console.pages.MembershipModalPage;
-import org.apache.syncope.client.console.pages.UserModalPage;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.IndicatingOnConfirmAjaxLink;
-import org.apache.syncope.client.console.wicket.markup.html.tree.DefaultMutableTreeNodeExpansion;
-import org.apache.syncope.client.console.wicket.markup.html.tree.DefaultMutableTreeNodeExpansionModel;
-import org.apache.syncope.client.console.wicket.markup.html.tree.TreeGroupProvider;
-import org.apache.syncope.common.lib.to.MembershipTO;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.Component;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.markup.html.repeater.tree.DefaultNestedTree;
-import org.apache.wicket.extensions.markup.html.repeater.tree.ITreeProvider;
-import org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree;
-import org.apache.wicket.extensions.markup.html.repeater.tree.content.Folder;
-import org.apache.wicket.extensions.markup.html.repeater.tree.theme.WindowsTheme;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.list.ListView;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class MembershipsPanel extends Panel {
-
- private static final long serialVersionUID = -2559791301973107191L;
-
- @SpringBean
- private GroupTreeBuilder groupTreeBuilder;
-
- private final ListView<MembershipTO> membView;
-
- private final UserTO userTO;
-
- private final StatusPanel statusPanel;
-
- private final NestedTree<DefaultMutableTreeNode> tree;
-
- public MembershipsPanel(final String id, final UserTO userTO, final Mode mode,
- final StatusPanel statusPanel, final PageReference pageRef) {
-
- super(id);
- this.userTO = userTO;
- this.statusPanel = statusPanel;
-
- final WebMarkupContainer membershipsContainer = new WebMarkupContainer("membershipsContainer");
- membershipsContainer.setOutputMarkupId(true);
- add(membershipsContainer);
-
- final ModalWindow membWin = new ModalWindow("membershipWin");
- membWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- membWin.setCookieName("create-membership-modal");
- add(membWin);
-
- final ITreeProvider<DefaultMutableTreeNode> treeProvider = new TreeGroupProvider(groupTreeBuilder, true);
- final DefaultMutableTreeNodeExpansionModel treeModel = new DefaultMutableTreeNodeExpansionModel();
-
- tree = new DefaultNestedTree<DefaultMutableTreeNode>("treeTable", treeProvider, treeModel) {
-
- private static final long serialVersionUID = 7137658050662575546L;
-
- @Override
- protected Component newContentComponent(final String id, final IModel<DefaultMutableTreeNode> node) {
- final DefaultMutableTreeNode treeNode = node.getObject();
- final GroupTO groupTO = (GroupTO) treeNode.getUserObject();
-
- return new Folder<DefaultMutableTreeNode>(id, MembershipsPanel.this.tree, node) {
-
- private static final long serialVersionUID = 9046323319920426493L;
-
- @Override
- protected boolean isClickable() {
- return true;
- }
-
- @Override
- protected IModel<?> newLabelModel(final IModel<DefaultMutableTreeNode> model) {
- return new Model<String>(groupTO.getDisplayName());
- }
-
- @Override
- protected void onClick(final AjaxRequestTarget target) {
- if (groupTO.getKey() > 0) {
- membWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = 7661763358801821185L;
-
- @Override
- public Page createPage() {
- PageReference pageRef = getPage().getPageReference();
-
- for (MembershipTO membTO : membView.getList()) {
- if (membTO.getGroupKey() == groupTO.getKey()) {
- return new MembershipModalPage(pageRef, membWin, membTO, mode);
- }
- }
- MembershipTO membTO = new MembershipTO();
- membTO.setGroupKey(groupTO.getKey());
- membTO.setGroupName(groupTO.getName());
-
- return new MembershipModalPage(pageRef, membWin, membTO, mode);
- }
- });
- membWin.show(target);
- }
- }
- };
- }
- };
- tree.add(new WindowsTheme());
- tree.setOutputMarkupId(true);
-
- DefaultMutableTreeNodeExpansion.get().expandAll();
-
- this.add(tree);
-
- membView = new ListView<MembershipTO>("memberships",
- new PropertyModel<List<? extends MembershipTO>>(userTO, "memberships")) {
-
- private static final long serialVersionUID = 9101744072914090143L;
-
- @Override
- protected void populateItem(final ListItem<MembershipTO> item) {
- final MembershipTO membershipTO = (MembershipTO) item.getDefaultModelObject();
-
- item.add(new Label("groupId", new Model<Long>(membershipTO.getGroupKey())));
- item.add(new Label("groupName", new Model<String>(membershipTO.getGroupName())));
-
- AjaxLink editLink = new ClearIndicatingAjaxLink("editLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- membWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new MembershipModalPage(getPage().getPageReference(), membWin,
- membershipTO, mode);
-
- }
- });
- membWin.show(target);
- }
- };
- item.add(editLink);
-
- AjaxLink deleteLink = new IndicatingOnConfirmAjaxLink("deleteLink", pageRef) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- userTO.getMemberships().remove(membershipTO);
- ((UserModalPage) getPage()).getUserTO().getMemberships().remove(membershipTO);
- target.add(membershipsContainer);
-
- GroupTO groupTO = groupTreeBuilder.findGroup(membershipTO.getGroupKey());
- Set<String> resourcesToRemove = groupTO == null
- ? Collections.<String>emptySet() : groupTO.getResources();
- if (!resourcesToRemove.isEmpty()) {
- Set<String> resourcesAssignedViaMembership = new HashSet<>();
- for (MembershipTO membTO : userTO.getMemberships()) {
- groupTO = groupTreeBuilder.findGroup(membTO.getGroupKey());
- if (groupTO != null) {
- resourcesAssignedViaMembership.addAll(groupTO.getResources());
- }
- }
- resourcesToRemove.removeAll(resourcesAssignedViaMembership);
- resourcesToRemove.removeAll(userTO.getResources());
- }
-
- StatusUtils.update(
- userTO, statusPanel, target, Collections.<String>emptySet(), resourcesToRemove);
- }
- };
- item.add(deleteLink);
- }
- };
-
- membershipsContainer.add(membView);
-
- setWindowClosedCallback(membWin, membershipsContainer);
- }
-
- private void setWindowClosedCallback(final ModalWindow window, final WebMarkupContainer container) {
- window.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
-
- private static final long serialVersionUID = 8804221891699487139L;
-
- @Override
- public void onClose(final AjaxRequestTarget target) {
- final UserTO updatedUserTO = ((UserModalPage) getPage()).getUserTO();
- if (!userTO.equals(updatedUserTO)) {
- if (updatedUserTO.getMemberships().size() > userTO.getMemberships().size()) {
- Set<Long> diff = new HashSet<Long>(updatedUserTO.getMembershipMap().keySet());
- diff.removeAll(userTO.getMembershipMap().keySet());
-
- Set<String> resourcesToAdd = new HashSet<>();
- for (Long diffMembId : diff) {
- long groupId = updatedUserTO.getMembershipMap().get(diffMembId).getGroupKey();
- GroupTO groupTO = groupTreeBuilder.findGroup(groupId);
- resourcesToAdd.addAll(groupTO.getResources());
- StatusUtils.update(
- userTO, statusPanel, target, resourcesToAdd, Collections.<String>emptySet());
- }
- }
-
- MembershipsPanel.this.userTO.getMemberships().clear();
- MembershipsPanel.this.userTO.getMemberships().addAll(updatedUserTO.getMemberships());
- target.add(container);
- }
- }
- });
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/NotificationPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/NotificationPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/NotificationPanel.java
index 8624d26..f203d92 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/NotificationPanel.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/panels/NotificationPanel.java
@@ -67,8 +67,8 @@ public class NotificationPanel extends FeedbackPanel {
setOutputMarkupId(true);
// Add the additional cssClass and hide the element by default
- add(new AttributeModifier("class", new Model<String>(CSS_CLASS + " " + this.additionalCSSClass)));
- add(new AttributeModifier("style", new Model<String>("opacity: 0;")));
+ add(new AttributeModifier("class", new Model<>(CSS_CLASS + " " + this.additionalCSSClass)));
+ add(new AttributeModifier("style", new Model<>("opacity: 0;")));
}
/**
@@ -95,7 +95,7 @@ public class NotificationPanel extends FeedbackPanel {
// add the css classes to the notification panel,
// including the border css which represents the highest level of feedback
add(new AttributeModifier("class",
- new Model<String>(CSS_CLASS
+ new Model<>(CSS_CLASS
+ " " + additionalCSSClass
+ " notificationpanel_border_" + highestFeedbackLevel)));
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/NotificationTasks.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/NotificationTasks.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/NotificationTasks.java
deleted file mode 100644
index d7f52e1..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/NotificationTasks.java
+++ /dev/null
@@ -1,254 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.pages.NotificationTaskModalPage;
-import org.apache.syncope.client.console.pages.Tasks;
-import org.apache.syncope.client.console.pages.Tasks.TasksProvider;
-import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.ActionColumn;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.AbstractTaskTO;
-import org.apache.syncope.common.lib.to.NotificationTaskTO;
-import org.apache.wicket.Component;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.StringResourceModel;
-import org.apache.wicket.request.http.WebResponse;
-
-public class NotificationTasks extends AbstractTasks {
-
- private static final long serialVersionUID = 4984337552918213290L;
-
- private int paginatorRows;
-
- private WebMarkupContainer container;
-
- private boolean operationResult = false;
-
- private ModalWindow window;
-
- private AjaxDataTablePanel<AbstractTaskTO, String> table;
-
- public NotificationTasks(final String id, final PageReference pageRef) {
- super(id, pageRef);
-
- container = new WebMarkupContainer("container");
- container.setOutputMarkupId(true);
- add(container);
-
- add(window = new ModalWindow("taskWin"));
-
- paginatorRows = prefMan.getPaginatorRows(getWebRequest(), Constants.PREF_NOTIFICATION_TASKS_PAGINATOR_ROWS);
-
- table = Tasks.updateTaskTable(
- getColumns(),
- new TasksProvider<NotificationTaskTO>(restClient, paginatorRows, getId(), NotificationTaskTO.class),
- container,
- 0,
- pageRef,
- restClient);
-
- container.add(table);
-
- window.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
-
- private static final long serialVersionUID = 8804221891699487139L;
-
- @Override
- public void onClose(final AjaxRequestTarget target) {
- target.add(container);
- if (operationResult) {
- info(getString(Constants.OPERATION_SUCCEEDED));
- target.add(getPage().get(Constants.FEEDBACK));
- operationResult = false;
- }
- }
- });
-
- window.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- window.setInitialHeight(WIN_HEIGHT);
- window.setInitialWidth(WIN_WIDTH);
- window.setCookieName(VIEW_TASK_WIN_COOKIE_NAME);
-
- @SuppressWarnings("rawtypes")
- final Form paginatorForm = new Form("PaginatorForm");
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- final DropDownChoice rowsChooser = new DropDownChoice("rowsChooser", new PropertyModel(this, "paginatorRows"),
- prefMan.getPaginatorChoices());
-
- rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- prefMan.set(getWebRequest(), (WebResponse) getResponse(),
- Constants.PREF_NOTIFICATION_TASKS_PAGINATOR_ROWS, String.valueOf(paginatorRows));
-
- table = Tasks.updateTaskTable(
- getColumns(),
- new TasksProvider<NotificationTaskTO>(restClient, paginatorRows, getId(),
- NotificationTaskTO.class),
- container,
- table == null ? 0 : (int) table.getCurrentPage(),
- pageRef,
- restClient);
-
- target.add(container);
- }
- });
-
- paginatorForm.add(rowsChooser);
- add(paginatorForm);
- }
-
- private List<IColumn<AbstractTaskTO, String>> getColumns() {
- final List<IColumn<AbstractTaskTO, String>> columns = new ArrayList<>();
-
- columns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("key", this, null), "key", "key"));
- columns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("sender", this, null), "sender", "sender"));
- columns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("recipients", this, null), "recipients", "recipients"));
- columns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("subject", this, null), "subject", "subject"));
- columns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("traceLevel", this, null), "traceLevel", "traceLevel"));
- columns.add(new PropertyColumn<AbstractTaskTO, String>(
- new StringResourceModel("latestExecStatus", this, null), "latestExecStatus", "latestExecStatus"));
-
- columns.add(new ActionColumn<AbstractTaskTO, String>(new StringResourceModel("actions", this, null, "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public ActionLinksPanel getActions(final String componentId, final IModel<AbstractTaskTO> model) {
-
- final AbstractTaskTO taskTO = model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, pageRef);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
-
- window.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new NotificationTaskModalPage(taskTO);
- }
- });
-
- window.show(target);
- }
- }, ActionLink.ActionType.EDIT, TASKS);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- restClient.startExecution(taskTO.getKey(), false);
- getSession().info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
-
- ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
- target.add(container);
- }
- }, ActionLink.ActionType.EXECUTE, TASKS);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- restClient.delete(taskTO.getKey(), NotificationTaskTO.class);
- info(getString(Constants.OPERATION_SUCCEEDED));
- } catch (SyncopeClientException scce) {
- error(scce.getMessage());
- }
- target.add(container);
- ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
- }
- }, ActionLink.ActionType.DELETE, TASKS);
-
- return panel;
- }
-
- @Override
- public Component getHeader(String componentId) {
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, new Model(), pageRef);
-
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- if (target != null) {
- target.add(table);
- }
- }
- }, ActionLink.ActionType.RELOAD, TASKS, "list");
-
- return panel;
- }
- });
-
- return columns;
- }
-
- @Override
- public void onEvent(final IEvent<?> event) {
- if (event.getPayload() instanceof AbstractSearchResultPanel.EventDataWrapper) {
- ((AbstractSearchResultPanel.EventDataWrapper) event.getPayload()).getTarget().add(container);
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/panels/PlainAttrsPanel.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/panels/PlainAttrsPanel.java b/client/console/src/main/java/org/apache/syncope/client/console/panels/PlainAttrsPanel.java
deleted file mode 100644
index b0517b0..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/panels/PlainAttrsPanel.java
+++ /dev/null
@@ -1,395 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.panels;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Comparator;
-import java.util.Date;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.LinkedHashMap;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-import java.util.TreeMap;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.commons.AttrLayoutType;
-import org.apache.syncope.client.console.commons.JexlHelpUtils;
-import org.apache.syncope.client.console.commons.Mode;
-import org.apache.syncope.client.console.panels.AttrTemplatesPanel.GroupAttrTemplatesChange;
-import org.apache.syncope.client.console.rest.ConfigurationRestClient;
-import org.apache.syncope.client.console.rest.GroupRestClient;
-import org.apache.syncope.client.console.rest.SchemaRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.BinaryFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.DateTextFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.DateTimeFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.FieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.SpinnerFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.list.AltListView;
-import org.apache.syncope.common.lib.SyncopeConstants;
-import org.apache.syncope.common.lib.to.AbstractAttributableTO;
-import org.apache.syncope.common.lib.to.AttrTO;
-import org.apache.syncope.common.lib.to.ConfTO;
-import org.apache.syncope.common.lib.to.MembershipTO;
-import org.apache.syncope.common.lib.to.PlainSchemaTO;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.syncope.common.lib.types.AttrSchemaType;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.form.IChoiceRenderer;
-import org.apache.wicket.markup.html.list.ListItem;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class PlainAttrsPanel extends Panel {
-
- private static final long serialVersionUID = 552437609667518888L;
-
- @SpringBean
- private SchemaRestClient schemaRestClient;
-
- @SpringBean
- private ConfigurationRestClient confRestClient;
-
- @SpringBean
- private GroupRestClient groupRestClient;
-
- private final AbstractAttributableTO entityTO;
-
- private final Mode mode;
-
- private final AttrTemplatesPanel attrTemplates;
-
- private Map<String, PlainSchemaTO> schemas = new LinkedHashMap<>();
-
- public <T extends AbstractAttributableTO> PlainAttrsPanel(final String id, final T entityTO,
- final Form<?> form, final Mode mode) {
-
- this(id, entityTO, form, mode, null);
- }
-
- public <T extends AbstractAttributableTO> PlainAttrsPanel(final String id, final T entityTO,
- final Form<?> form, final Mode mode, final AttrTemplatesPanel attrTemplates) {
-
- super(id);
- this.entityTO = entityTO;
- this.mode = mode;
- this.attrTemplates = attrTemplates;
- this.setOutputMarkupId(true);
-
- setSchemas();
- setAttrs();
-
- add(new AltListView<AttrTO>("schemas", new PropertyModel<List<? extends AttrTO>>(entityTO, "attrs")) {
-
- private static final long serialVersionUID = 9101744072914090143L;
-
- @Override
- @SuppressWarnings({ "unchecked", "rawtypes" })
- protected void populateItem(final ListItem<AttrTO> item) {
- final AttrTO attributeTO = (AttrTO) item.getDefaultModelObject();
-
- final WebMarkupContainer jexlHelp = JexlHelpUtils.getJexlHelpWebContainer("jexlHelp");
-
- final AjaxLink<Void> questionMarkJexlHelp = JexlHelpUtils.getAjaxLink(jexlHelp, "questionMarkJexlHelp");
- item.add(questionMarkJexlHelp);
- questionMarkJexlHelp.add(jexlHelp);
-
- if (mode != Mode.TEMPLATE) {
- questionMarkJexlHelp.setVisible(false);
- }
-
- item.add(new Label("name", attributeTO.getSchema()));
-
- final FieldPanel panel = getFieldPanel(schemas.get(attributeTO.getSchema()), form, attributeTO);
-
- if (mode == Mode.TEMPLATE || !schemas.get(attributeTO.getSchema()).isMultivalue()) {
- item.add(panel);
- } else {
- item.add(new MultiFieldPanel<String>(
- "panel", new PropertyModel<List<String>>(attributeTO, "values"), panel));
- }
- }
- }
- );
- }
-
- private void setSchemas() {
- AttrTO attrLayout = null;
- List<PlainSchemaTO> schemaTOs;
-
- if (entityTO instanceof GroupTO) {
- final GroupTO groupTO = (GroupTO) entityTO;
-
- attrLayout = confRestClient.readAttrLayout(AttrLayoutType.valueOf(mode, AttributableType.GROUP));
- schemaTOs = schemaRestClient.getSchemas(AttributableType.GROUP);
- Set<String> allowed;
- if (attrTemplates == null) {
- allowed = new HashSet<>(groupTO.getGPlainAttrTemplates());
- } else {
- allowed = new HashSet<>(attrTemplates.getSelected(AttrTemplatesPanel.Type.gPlainAttrTemplates));
- if (groupTO.isInheritTemplates() && groupTO.getParent() != 0) {
- allowed.addAll(groupRestClient.read(groupTO.getParent()).getGPlainAttrTemplates());
- }
- }
- schemaRestClient.filter(schemaTOs, allowed, true);
- } else if (entityTO instanceof UserTO) {
- attrLayout = confRestClient.readAttrLayout(AttrLayoutType.valueOf(mode, AttributableType.USER));
- schemaTOs = schemaRestClient.getSchemas(AttributableType.USER);
- } else if (entityTO instanceof MembershipTO) {
- attrLayout = confRestClient.readAttrLayout(AttrLayoutType.valueOf(mode, AttributableType.MEMBERSHIP));
- schemaTOs = schemaRestClient.getSchemas(AttributableType.MEMBERSHIP);
- Set<String> allowed = new HashSet<>(
- groupRestClient.read(((MembershipTO) entityTO).getGroupKey()).getMPlainAttrTemplates());
- schemaRestClient.filter(schemaTOs, allowed, true);
- } else {
- schemas = new TreeMap<>();
- schemaTOs = schemaRestClient.getSchemas(AttributableType.CONFIGURATION);
- for (Iterator<PlainSchemaTO> it = schemaTOs.iterator(); it.hasNext();) {
- PlainSchemaTO schemaTO = it.next();
- for (AttrLayoutType type : AttrLayoutType.values()) {
- if (type.getConfKey().equals(schemaTO.getKey())) {
- it.remove();
- }
- }
- }
- }
-
- schemas.clear();
-
- if (attrLayout != null && mode != Mode.TEMPLATE && !(entityTO instanceof ConfTO)) {
- // 1. remove attributes not selected for display
- schemaRestClient.filter(schemaTOs, attrLayout.getValues(), true);
- // 2. sort remainig attributes according to configuration, e.g. attrLayout
- final Map<String, Integer> attrLayoutMap = new HashMap<>(attrLayout.getValues().size());
- for (int i = 0; i < attrLayout.getValues().size(); i++) {
- attrLayoutMap.put(attrLayout.getValues().get(i), i);
- }
- Collections.sort(schemaTOs, new Comparator<PlainSchemaTO>() {
-
- @Override
- public int compare(final PlainSchemaTO schema1, final PlainSchemaTO schema2) {
- int value = 0;
-
- if (attrLayoutMap.get(schema1.getKey()) > attrLayoutMap.get(schema2.getKey())) {
- value = 1;
- } else if (attrLayoutMap.get(schema1.getKey()) < attrLayoutMap.get(schema2.getKey())) {
- value = -1;
- }
-
- return value;
- }
- });
- }
- for (PlainSchemaTO schemaTO : schemaTOs) {
- schemas.put(schemaTO.getKey(), schemaTO);
- }
- }
-
- private void setAttrs() {
- final List<AttrTO> entityData = new ArrayList<>();
-
- final Map<String, AttrTO> attrMap = entityTO.getPlainAttrMap();
-
- for (PlainSchemaTO schema : schemas.values()) {
- final AttrTO attributeTO = new AttrTO();
- attributeTO.setSchema(schema.getKey());
-
- if (attrMap.get(schema.getKey()) == null || attrMap.get(schema.getKey()).getValues().isEmpty()) {
- attributeTO.getValues().add("");
-
- // is important to set readonly only after values setting
- attributeTO.setReadonly(schema.isReadonly());
- } else {
- attributeTO.getValues().addAll(attrMap.get(schema.getKey()).getValues());
- }
- entityData.add(attributeTO);
- }
-
- entityTO.getPlainAttrs().clear();
- entityTO.getPlainAttrs().addAll(entityData);
- }
-
- @SuppressWarnings({ "rawtypes", "unchecked" })
- private FieldPanel getFieldPanel(final PlainSchemaTO schemaTO, final Form form, final AttrTO attributeTO) {
- final boolean required = mode == Mode.TEMPLATE
- ? false
- : schemaTO.getMandatoryCondition().equalsIgnoreCase("true");
-
- final boolean readOnly = mode == Mode.TEMPLATE ? false : schemaTO.isReadonly();
-
- final AttrSchemaType type = mode == Mode.TEMPLATE ? AttrSchemaType.String : schemaTO.getType();
-
- final FieldPanel panel;
- switch (type) {
- case Boolean:
- panel = new AjaxCheckBoxPanel("panel", schemaTO.getKey(), new Model<Boolean>());
- panel.setRequired(required);
- break;
-
- case Date:
- final String dataPattern = schemaTO.getConversionPattern() == null
- ? SyncopeConstants.DEFAULT_DATE_PATTERN
- : schemaTO.getConversionPattern();
-
- if (dataPattern.contains("H")) {
- panel = new DateTimeFieldPanel("panel", schemaTO.getKey(), new Model<Date>(), dataPattern);
-
- if (required) {
- panel.addRequiredLabel();
- ((DateTimeFieldPanel) panel).setFormValidator(form);
- }
- panel.setStyleSheet("ui-widget-content ui-corner-all");
- } else {
- panel = new DateTextFieldPanel("panel", schemaTO.getKey(), new Model<Date>(), dataPattern);
-
- if (required) {
- panel.addRequiredLabel();
- }
- }
- break;
-
- case Enum:
- panel = new AjaxDropDownChoicePanel<String>("panel", schemaTO.getKey(), new Model<String>());
- ((AjaxDropDownChoicePanel<String>) panel).setChoices(getEnumeratedValues(schemaTO));
-
- if (StringUtils.isNotBlank(schemaTO.getEnumerationKeys())) {
- ((AjaxDropDownChoicePanel) panel).setChoiceRenderer(new IChoiceRenderer<String>() {
-
- private static final long serialVersionUID = -3724971416312135885L;
-
- private final Map<String, String> valueMap = getEnumeratedKeyValues(schemaTO);
-
- @Override
- public String getDisplayValue(final String value) {
- return valueMap.get(value) == null ? value : valueMap.get(value);
- }
-
- @Override
- public String getIdValue(final String value, final int i) {
- return value;
- }
- });
- }
-
- if (required) {
- panel.addRequiredLabel();
- }
- break;
-
- case Long:
- panel = new SpinnerFieldPanel<Long>("panel", schemaTO.getKey(),
- Long.class, new Model<Long>(), null, null);
-
- if (required) {
- panel.addRequiredLabel();
- }
- break;
-
- case Double:
- panel = new SpinnerFieldPanel<Double>("panel", schemaTO.getKey(),
- Double.class, new Model<Double>(), null, null);
-
- if (required) {
- panel.addRequiredLabel();
- }
- break;
-
- case Binary:
- panel = new BinaryFieldPanel("panel", schemaTO.getKey(), new Model<String>(),
- schemas.containsKey(schemaTO.getKey())
- ? schemas.get(schemaTO.getKey()).getMimeType()
- : null);
-
- if (required) {
- panel.addRequiredLabel();
- }
- break;
-
- default:
- panel = new AjaxTextFieldPanel("panel", schemaTO.getKey(), new Model<String>());
-
- if (required) {
- panel.addRequiredLabel();
- }
- }
-
- panel.setReadOnly(readOnly);
- panel.setNewModel(attributeTO.getValues());
-
- return panel;
- }
-
- private Map<String, String> getEnumeratedKeyValues(final PlainSchemaTO schemaTO) {
- final Map<String, String> res = new HashMap<>();
-
- final String[] values = StringUtils.isBlank(schemaTO.getEnumerationValues())
- ? new String[0]
- : schemaTO.getEnumerationValues().split(SyncopeConstants.ENUM_VALUES_SEPARATOR);
-
- final String[] keys = StringUtils.isBlank(schemaTO.getEnumerationKeys())
- ? new String[0]
- : schemaTO.getEnumerationKeys().split(SyncopeConstants.ENUM_VALUES_SEPARATOR);
-
- for (int i = 0; i < values.length; i++) {
- res.put(values[i].trim(), keys.length > i ? keys[i].trim() : null);
- }
-
- return res;
- }
-
- private List<String> getEnumeratedValues(final PlainSchemaTO schemaTO) {
- final List<String> res = new ArrayList<>();
-
- final String[] values = StringUtils.isBlank(schemaTO.getEnumerationValues())
- ? new String[0]
- : schemaTO.getEnumerationValues().split(SyncopeConstants.ENUM_VALUES_SEPARATOR);
-
- for (String value : values) {
- res.add(value.trim());
- }
-
- return res;
- }
-
- @Override
- public void onEvent(final IEvent<?> event) {
- if ((event.getPayload() instanceof GroupAttrTemplatesChange)) {
- final GroupAttrTemplatesChange update = (GroupAttrTemplatesChange) event.getPayload();
- if (attrTemplates != null && update.getType() == AttrTemplatesPanel.Type.gPlainAttrTemplates) {
- setSchemas();
- setAttrs();
- update.getTarget().add(this);
- }
- }
- }
-}
[46/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/PlainSchemaModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/PlainSchemaModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/PlainSchemaModalPage.java
deleted file mode 100644
index 3adba7d..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/PlainSchemaModalPage.java
+++ /dev/null
@@ -1,456 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.JexlHelpUtils;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.SyncopeConstants;
-import org.apache.syncope.common.lib.to.PlainSchemaTO;
-import org.apache.syncope.common.lib.types.AttrSchemaType;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.syncope.common.lib.types.CipherAlgorithm;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.autocomplete.AutoCompleteTextField;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.LoadableDetachableModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.util.string.Strings;
-
-/**
- * Modal window with Schema form.
- */
-public class PlainSchemaModalPage extends AbstractSchemaModalPage<PlainSchemaTO> {
-
- private static final long serialVersionUID = -5991561277287424057L;
-
- public PlainSchemaModalPage(final AttributableType kind) {
- super(kind);
- }
-
- @Override
- public void setSchemaModalPage(final PageReference pageRef, final ModalWindow window,
- final PlainSchemaTO schemaTO, final boolean createFlag) {
-
- final PlainSchemaTO schema = schemaTO == null
- ? new PlainSchemaTO()
- : schemaTO;
-
- final Form<PlainSchemaTO> schemaForm = new Form<>(FORM);
-
- schemaForm.setModel(new CompoundPropertyModel<>(schema));
- schemaForm.setOutputMarkupId(true);
-
- final AjaxTextFieldPanel name =
- new AjaxTextFieldPanel("key", getString("key"), new PropertyModel<String>(schema, "key"));
- name.addRequiredLabel();
- name.setEnabled(createFlag);
- schemaForm.add(name);
-
- final AjaxDropDownChoicePanel<AttrSchemaType> type = new AjaxDropDownChoicePanel<>(
- "type", getString("type"), new PropertyModel<AttrSchemaType>(schema, "type"));
- type.setChoices(Arrays.asList(AttrSchemaType.values()));
- type.addRequiredLabel();
- schemaForm.add(type);
-
- // -- long, double, date
- final AjaxTextFieldPanel conversionPattern = new AjaxTextFieldPanel("conversionPattern",
- getString("conversionPattern"), new PropertyModel<String>(schema, "conversionPattern"));
- schemaForm.add(conversionPattern);
-
- final WebMarkupContainer conversionParams = new WebMarkupContainer("conversionParams");
- conversionParams.setOutputMarkupPlaceholderTag(true);
- conversionParams.add(conversionPattern);
- schemaForm.add(conversionParams);
-
- final WebMarkupContainer typeParams = new WebMarkupContainer("typeParams");
- typeParams.setOutputMarkupPlaceholderTag(true);
- // -- enum
- final AjaxTextFieldPanel enumerationValuesPanel =
- new AjaxTextFieldPanel("panel", "enumerationValues", new Model<String>(null));
- @SuppressWarnings({ "unchecked", "rawtypes" })
- final MultiFieldPanel<String> enumerationValues = new MultiFieldPanel<>("enumerationValues",
- new Model(),
- enumerationValuesPanel);
- enumerationValues.setModelObject(getEnumValuesAsList(schema.getEnumerationValues()));
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- final MultiFieldPanel<String> enumerationKeys = new MultiFieldPanel<>("enumerationKeys",
- new Model(),
- new AjaxTextFieldPanel("panel", "enumerationKeys", new Model<String>(null)));
- enumerationKeys.setModelObject(getEnumValuesAsList(schema.getEnumerationKeys()));
-
- final WebMarkupContainer enumParams = new WebMarkupContainer("enumParams");
- enumParams.setOutputMarkupPlaceholderTag(true);
- enumParams.add(enumerationValues);
- enumParams.add(enumerationKeys);
- typeParams.add(enumParams);
-
- // -- encrypted
- final AjaxTextFieldPanel secretKey = new AjaxTextFieldPanel("secretKey",
- getString("secretKey"), new PropertyModel<String>(schema, "secretKey"));
-
- final AjaxDropDownChoicePanel<CipherAlgorithm> cipherAlgorithm = new AjaxDropDownChoicePanel<>(
- "cipherAlgorithm", getString("cipherAlgorithm"),
- new PropertyModel<CipherAlgorithm>(schema, "cipherAlgorithm"));
- cipherAlgorithm.setChoices(Arrays.asList(CipherAlgorithm.values()));
-
- final WebMarkupContainer encryptedParams = new WebMarkupContainer("encryptedParams");
- encryptedParams.setOutputMarkupPlaceholderTag(true);
- encryptedParams.add(secretKey);
- encryptedParams.add(cipherAlgorithm);
- typeParams.add(encryptedParams);
-
- // -- binary
- final AjaxTextFieldPanel mimeType = new AjaxTextFieldPanel("mimeType",
- getString("mimeType"), new PropertyModel<String>(schema, "mimeType"));
- mimeType.setChoices(mimeTypesInitializer.getMimeTypes());
-
- final WebMarkupContainer binaryParams = new WebMarkupContainer("binaryParams");
- binaryParams.setOutputMarkupPlaceholderTag(true);
- binaryParams.add(mimeType);
- typeParams.add(binaryParams);
-
- schemaForm.add(typeParams);
-
- // -- show or hide
- showHide(schema, type,
- conversionParams, conversionPattern,
- enumParams, enumerationValuesPanel, enumerationValues, enumerationKeys,
- encryptedParams, secretKey, cipherAlgorithm,
- binaryParams, mimeType);
- type.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- PlainSchemaModalPage.this.showHide(schema, type,
- conversionParams, conversionPattern,
- enumParams, enumerationValuesPanel, enumerationValues, enumerationKeys,
- encryptedParams, secretKey, cipherAlgorithm,
- binaryParams, mimeType);
- target.add(typeParams);
- }
- });
-
- final IModel<List<String>> validatorsList = new LoadableDetachableModel<List<String>>() {
-
- private static final long serialVersionUID = 5275935387613157437L;
-
- @Override
- protected List<String> load() {
- return schemaRestClient.getAllValidatorClasses();
- }
- };
- final AjaxDropDownChoicePanel<String> validatorClass = new AjaxDropDownChoicePanel<>("validatorClass",
- getString("validatorClass"), new PropertyModel<String>(schema, "validatorClass"));
- ((DropDownChoice) validatorClass.getField()).setNullValid(true);
- validatorClass.setChoices(validatorsList.getObject());
- schemaForm.add(validatorClass);
-
- final AutoCompleteTextField<String> mandatoryCondition =
- new AutoCompleteTextField<String>("mandatoryCondition") {
-
- private static final long serialVersionUID = -2428903969518079100L;
-
- @Override
- protected Iterator<String> getChoices(final String input) {
- List<String> choices = new ArrayList<String>();
-
- if (Strings.isEmpty(input)) {
- choices = Collections.emptyList();
- } else if ("true".startsWith(input.toLowerCase())) {
- choices.add("true");
- } else if ("false".startsWith(input.toLowerCase())) {
- choices.add("false");
- }
-
- return choices.iterator();
- }
- };
- mandatoryCondition.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- }
- });
- schemaForm.add(mandatoryCondition);
-
- final WebMarkupContainer pwdJexlHelp = JexlHelpUtils.getJexlHelpWebContainer("jexlHelp");
-
- final AjaxLink<Void> pwdQuestionMarkJexlHelp = JexlHelpUtils.getAjaxLink(pwdJexlHelp, "questionMarkJexlHelp");
- schemaForm.add(pwdQuestionMarkJexlHelp);
- pwdQuestionMarkJexlHelp.add(pwdJexlHelp);
-
- final AjaxCheckBoxPanel multivalue = new AjaxCheckBoxPanel("multivalue", getString("multivalue"),
- new PropertyModel<Boolean>(schema, "multivalue"));
- schemaForm.add(multivalue);
-
- final AjaxCheckBoxPanel readonly = new AjaxCheckBoxPanel("readonly", getString("readonly"),
- new PropertyModel<Boolean>(schema, "readonly"));
- schemaForm.add(readonly);
-
- final AjaxCheckBoxPanel uniqueConstraint = new AjaxCheckBoxPanel("uniqueConstraint",
- getString("uniqueConstraint"), new PropertyModel<Boolean>(schema, "uniqueConstraint"));
- schemaForm.add(uniqueConstraint);
-
- final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(SUBMIT)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- final PlainSchemaTO schemaTO = (PlainSchemaTO) form.getDefaultModelObject();
-
- schemaTO.setEnumerationValues(getEnumValuesAsString(enumerationValues.getView().getModelObject()));
- schemaTO.setEnumerationKeys(getEnumValuesAsString(enumerationKeys.getView().getModelObject()));
-
- if (schemaTO.isMultivalue() && schemaTO.isUniqueConstraint()) {
- error(getString("multivalueAndUniqueConstr.validation"));
- feedbackPanel.refresh(target);
- return;
- }
-
- try {
- if (createFlag) {
- schemaRestClient.createPlainSchema(kind, schemaTO);
- } else {
- schemaRestClient.updatePlainSchema(kind, schemaTO);
- }
- if (pageRef.getPage() instanceof BasePage) {
- ((BasePage) pageRef.getPage()).setModalResult(true);
- }
-
- window.close(target);
- } catch (SyncopeClientException e) {
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
- schemaForm.add(submit);
-
- final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
- };
- cancel.setDefaultFormProcessing(false);
- schemaForm.add(cancel);
-
- String allowedRoles = createFlag
- ? xmlRolesReader.getEntitlement("Schema", "create")
- : xmlRolesReader.getEntitlement("Schema", "update");
-
- MetaDataRoleAuthorizationStrategy.authorize(submit, ENABLE, allowedRoles);
-
- add(schemaForm);
- }
-
- private void showHide(final PlainSchemaTO schema, final AjaxDropDownChoicePanel<AttrSchemaType> type,
- final WebMarkupContainer conversionParams, final AjaxTextFieldPanel conversionPattern,
- final WebMarkupContainer enumParams, final AjaxTextFieldPanel enumerationValuesPanel,
- final MultiFieldPanel<String> enumerationValues, final MultiFieldPanel<String> enumerationKeys,
- final WebMarkupContainer encryptedParams,
- final AjaxTextFieldPanel secretKey, final AjaxDropDownChoicePanel<CipherAlgorithm> cipherAlgorithm,
- final WebMarkupContainer binaryParams, final AjaxTextFieldPanel mimeType) {
-
- final int typeOrdinal = Integer.parseInt(type.getField().getValue());
- if (AttrSchemaType.Long.ordinal() == typeOrdinal
- || AttrSchemaType.Double.ordinal() == typeOrdinal
- || AttrSchemaType.Date.ordinal() == typeOrdinal) {
-
- conversionParams.setVisible(true);
-
- enumParams.setVisible(false);
- if (enumerationValuesPanel.isRequired()) {
- enumerationValuesPanel.removeRequiredLabel();
- }
- enumerationValues.setModelObject(getEnumValuesAsList(null));
- enumerationKeys.setModelObject(getEnumValuesAsList(null));
-
- encryptedParams.setVisible(false);
- if (secretKey.isRequired()) {
- secretKey.removeRequiredLabel();
- }
- secretKey.setModelObject(null);
- if (cipherAlgorithm.isRequired()) {
- cipherAlgorithm.removeRequiredLabel();
- }
- cipherAlgorithm.setModelObject(null);
-
- binaryParams.setVisible(false);
- mimeType.setModelObject(null);
- } else if (AttrSchemaType.Enum.ordinal() == typeOrdinal) {
- conversionParams.setVisible(false);
- conversionPattern.setModelObject(null);
-
- enumParams.setVisible(true);
- if (!enumerationValuesPanel.isRequired()) {
- enumerationValuesPanel.addRequiredLabel();
- }
- enumerationValues.setModelObject(getEnumValuesAsList(schema.getEnumerationValues()));
- enumerationKeys.setModelObject(getEnumValuesAsList(schema.getEnumerationKeys()));
-
- encryptedParams.setVisible(false);
- if (secretKey.isRequired()) {
- secretKey.removeRequiredLabel();
- }
- secretKey.setModelObject(null);
- if (cipherAlgorithm.isRequired()) {
- cipherAlgorithm.removeRequiredLabel();
- }
- cipherAlgorithm.setModelObject(null);
-
- binaryParams.setVisible(false);
- mimeType.setModelObject(null);
- } else if (AttrSchemaType.Encrypted.ordinal() == typeOrdinal) {
- conversionParams.setVisible(false);
- conversionPattern.setModelObject(null);
-
- enumParams.setVisible(false);
- if (enumerationValuesPanel.isRequired()) {
- enumerationValuesPanel.removeRequiredLabel();
- }
- enumerationValues.setModelObject(getEnumValuesAsList(null));
- enumerationKeys.setModelObject(getEnumValuesAsList(null));
-
- encryptedParams.setVisible(true);
- if (!secretKey.isRequired()) {
- secretKey.addRequiredLabel();
- }
- if (cipherAlgorithm.isRequired()) {
- cipherAlgorithm.addRequiredLabel();
- }
-
- binaryParams.setVisible(false);
- mimeType.setModelObject(null);
- } else if (AttrSchemaType.Binary.ordinal() == typeOrdinal) {
- conversionParams.setVisible(false);
- conversionPattern.setModelObject(null);
-
- enumParams.setVisible(false);
- if (enumerationValuesPanel.isRequired()) {
- enumerationValuesPanel.removeRequiredLabel();
- }
- enumerationValues.setModelObject(getEnumValuesAsList(null));
- enumerationKeys.setModelObject(getEnumValuesAsList(null));
-
- encryptedParams.setVisible(false);
- if (secretKey.isRequired()) {
- secretKey.removeRequiredLabel();
- }
- secretKey.setModelObject(null);
- if (cipherAlgorithm.isRequired()) {
- cipherAlgorithm.removeRequiredLabel();
- }
- cipherAlgorithm.setModelObject(null);
-
- binaryParams.setVisible(true);
- } else {
- conversionParams.setVisible(false);
- conversionPattern.setModelObject(null);
-
- enumParams.setVisible(false);
- if (enumerationValuesPanel.isRequired()) {
- enumerationValuesPanel.removeRequiredLabel();
- }
- enumerationValues.setModelObject(getEnumValuesAsList(null));
- enumerationKeys.setModelObject(getEnumValuesAsList(null));
-
- encryptedParams.setVisible(false);
- if (secretKey.isRequired()) {
- secretKey.removeRequiredLabel();
- }
- secretKey.setModelObject(null);
- if (cipherAlgorithm.isRequired()) {
- cipherAlgorithm.removeRequiredLabel();
- }
- cipherAlgorithm.setModelObject(null);
-
- binaryParams.setVisible(false);
- mimeType.setModelObject(null);
- }
- }
-
- private String getEnumValuesAsString(final List<String> enumerationValues) {
- final StringBuilder builder = new StringBuilder();
-
- for (String str : enumerationValues) {
- if (StringUtils.isNotBlank(str)) {
- if (builder.length() > 0) {
- builder.append(SyncopeConstants.ENUM_VALUES_SEPARATOR);
- }
-
- builder.append(str.trim());
- }
- }
-
- return builder.toString();
- }
-
- private List<String> getEnumValuesAsList(final String enumerationValues) {
- final List<String> values = new ArrayList<String>();
-
- if (StringUtils.isNotBlank(enumerationValues)) {
- for (String value : enumerationValues.split(SyncopeConstants.ENUM_VALUES_SEPARATOR)) {
- values.add(value.trim());
- }
- } else {
- values.add(StringUtils.EMPTY);
- }
-
- return values;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/PolicyModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/PolicyModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/PolicyModalPage.java
deleted file mode 100644
index ead376a..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/PolicyModalPage.java
+++ /dev/null
@@ -1,450 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.panels.NotificationPanel;
-import org.apache.syncope.client.console.panels.PolicyBeanPanel;
-import org.apache.syncope.client.console.rest.PolicyRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxPalettePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.common.lib.to.AbstractPolicyTO;
-import org.apache.syncope.common.lib.to.AccountPolicyTO;
-import org.apache.syncope.common.lib.to.PasswordPolicyTO;
-import org.apache.syncope.common.lib.to.ResourceTO;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.syncope.common.lib.to.SyncPolicyTO;
-import org.apache.syncope.common.lib.types.AccountPolicySpec;
-import org.apache.syncope.common.lib.types.PasswordPolicySpec;
-import org.apache.syncope.common.lib.types.PolicySpec;
-import org.apache.syncope.common.lib.types.PolicyType;
-import org.apache.syncope.common.lib.types.SyncPolicySpec;
-import org.apache.wicket.Page;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.ISortableDataProvider;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.ChoiceRenderer;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.panel.Fragment;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.model.StringResourceModel;
-import org.apache.wicket.model.util.ListModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-/**
- * Modal window with Resource form.
- */
-public class PolicyModalPage<T extends AbstractPolicyTO<?>> extends BaseModalPage {
-
- private static final long serialVersionUID = -7325772767481076679L;
-
- private static final int WIN_HEIGHT = 600;
-
- private static final int WIN_WIDTH = 1100;
-
- @SpringBean
- private PolicyRestClient policyRestClient;
-
- public PolicyModalPage(final PageReference pageRef, final ModalWindow window, final T policyTO) {
- super();
-
- final Form<?> form = new Form<>(FORM);
- form.setOutputMarkupId(true);
- add(form);
-
- final AjaxTextFieldPanel policyid =
- new AjaxTextFieldPanel("key", "key", new PropertyModel<String>(policyTO, "key"));
- policyid.setEnabled(false);
- policyid.setStyleSheet("ui-widget-content ui-corner-all short_fixedsize");
- form.add(policyid);
-
- final AjaxTextFieldPanel description = new AjaxTextFieldPanel("description", "description",
- new PropertyModel<String>(policyTO, "description"));
- description.addRequiredLabel();
- description.setStyleSheet("ui-widget-content ui-corner-all medium_dynamicsize");
- form.add(description);
-
- final AjaxDropDownChoicePanel<PolicyType> type =
- new AjaxDropDownChoicePanel<>("type", "type", new PropertyModel<PolicyType>(policyTO, "type"));
- switch (policyTO.getType()) {
- case GLOBAL_ACCOUNT:
- case ACCOUNT:
- type.setChoices(Arrays.asList(new PolicyType[] { PolicyType.GLOBAL_ACCOUNT, PolicyType.ACCOUNT }));
- break;
-
- case GLOBAL_PASSWORD:
- case PASSWORD:
- type.setChoices(Arrays.asList(new PolicyType[] { PolicyType.GLOBAL_PASSWORD, PolicyType.PASSWORD }));
- break;
-
- case GLOBAL_SYNC:
- case SYNC:
- type.setChoices(Arrays.asList(new PolicyType[] { PolicyType.GLOBAL_SYNC, PolicyType.SYNC }));
-
- default:
- }
- type.setChoiceRenderer(new PolicyTypeRenderer());
- type.addRequiredLabel();
- form.add(type);
-
- // Authentication resources - only for AccountPolicyTO
- Fragment fragment;
- if (policyTO instanceof AccountPolicyTO) {
- fragment = new Fragment("forAccountOnly", "authResourcesFragment", form);
-
- final List<String> resourceNames = new ArrayList<>();
- for (ResourceTO resource : resourceRestClient.getAll()) {
- resourceNames.add(resource.getKey());
- }
- fragment.add(new AjaxPalettePanel<>("authResources",
- new PropertyModel<List<String>>(policyTO, "resources"),
- new ListModel<>(resourceNames)));
- } else {
- fragment = new Fragment("forAccountOnly", "emptyFragment", form);
- }
- form.add(fragment);
- //
-
- final PolicySpec policy = getPolicySpecification(policyTO);
-
- form.add(new PolicyBeanPanel("panel", policy));
-
- final ModalWindow mwindow = new ModalWindow("metaEditModalWin");
- mwindow.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- mwindow.setInitialHeight(WIN_HEIGHT);
- mwindow.setInitialWidth(WIN_WIDTH);
- mwindow.setCookieName("meta-edit-modal");
- add(mwindow);
-
- List<IColumn<String, String>> resColumns = new ArrayList<>();
- resColumns.add(new AbstractColumn<String, String>(new StringResourceModel("name", this, null, "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public void populateItem(final Item<ICellPopulator<String>> cellItem,
- final String componentId, final IModel<String> rowModel) {
-
- cellItem.add(new Label(componentId, rowModel.getObject()));
- }
- });
- resColumns.add(new AbstractColumn<String, String>(new StringResourceModel("actions", this, null, "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public String getCssClass() {
- return "action";
- }
-
- @Override
- public void populateItem(final Item<ICellPopulator<String>> cellItem, final String componentId,
- final IModel<String> model) {
-
- final String resource = model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- mwindow.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new ResourceModalPage(PolicyModalPage.this.getPageReference(),
- mwindow, resourceRestClient.read(resource), false);
- }
- });
-
- mwindow.show(target);
- }
- }, ActionLink.ActionType.EDIT, "Resources");
-
- cellItem.add(panel);
- }
- });
- ISortableDataProvider<String, String> resDataProvider = new SortableDataProvider<String, String>() {
-
- private static final long serialVersionUID = 8263758912838836438L;
-
- @Override
- public Iterator<? extends String> iterator(final long first, final long count) {
- return policyTO.getKey() == 0
- ? Collections.<String>emptyList().iterator()
- : policyRestClient.getPolicy(policyTO.getKey()).
- getUsedByResources().subList((int) first, (int) first + (int) count).iterator();
- }
-
- @Override
- public long size() {
- return policyTO.getKey() == 0
- ? 0
- : policyRestClient.getPolicy(policyTO.getKey()).
- getUsedByResources().size();
- }
-
- @Override
- public IModel<String> model(final String object) {
- return new Model<>(object);
- }
- };
- final AjaxFallbackDefaultDataTable<String, String> resources =
- new AjaxFallbackDefaultDataTable<>("resources", resColumns, resDataProvider, 10);
- form.add(resources);
-
- List<IColumn<GroupTO, String>> groupColumns = new ArrayList<>();
- groupColumns.add(new PropertyColumn<GroupTO, String>(new ResourceModel("key", "key"), "key", "key"));
- groupColumns.add(new PropertyColumn<GroupTO, String>(new ResourceModel("name", "name"), "name", "name"));
- groupColumns.add(new AbstractColumn<GroupTO, String>(new StringResourceModel("actions", this, null, "")) {
-
- private static final long serialVersionUID = 2054811145491901166L;
-
- @Override
- public String getCssClass() {
- return "action";
- }
-
- @Override
- public void populateItem(final Item<ICellPopulator<GroupTO>> cellItem, final String componentId,
- final IModel<GroupTO> model) {
-
- final GroupTO group = model.getObject();
-
- final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
- panel.add(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- mwindow.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- return new GroupModalPage(PolicyModalPage.this.getPageReference(), mwindow, group);
- }
- });
-
- mwindow.show(target);
- }
- }, ActionLink.ActionType.EDIT, "Groups");
-
- cellItem.add(panel);
- }
- });
- ISortableDataProvider<GroupTO, String> groupDataProvider = new SortableDataProvider<GroupTO, String>() {
-
- private static final long serialVersionUID = 8263758912838836438L;
-
- @Override
- public Iterator<? extends GroupTO> iterator(final long first, final long count) {
- List<GroupTO> groups = new ArrayList<>();
-
- if (policyTO.getKey() > 0) {
- for (Long groupId : policyRestClient.getPolicy(policyTO.getKey()).getUsedByGroups().
- subList((int) first, (int) first + (int) count)) {
-
- groups.add(groupRestClient.read(groupId));
- }
- }
-
- return groups.iterator();
- }
-
- @Override
- public long size() {
- return policyTO.getKey() == 0
- ? 0
- : policyRestClient.getPolicy(policyTO.getKey()).getUsedByGroups().size();
- }
-
- @Override
- public IModel<GroupTO> model(final GroupTO object) {
- return new Model<>(object);
- }
- };
- final AjaxFallbackDefaultDataTable<GroupTO, String> groups =
- new AjaxFallbackDefaultDataTable<>("groups", groupColumns, groupDataProvider, 10);
- form.add(groups);
-
- mwindow.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
-
- private static final long serialVersionUID = 8804221891699487139L;
-
- @Override
- public void onClose(final AjaxRequestTarget target) {
- target.add(resources);
- target.add(groups);
- if (isModalResult()) {
- info(getString(Constants.OPERATION_SUCCEEDED));
- feedbackPanel.refresh(target);
- setModalResult(false);
- }
- }
- });
-
- final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(APPLY)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- setPolicySpecification(policyTO, policy);
-
- try {
- if (policyTO.getKey() > 0) {
- policyRestClient.updatePolicy(policyTO);
- } else {
- policyRestClient.createPolicy(policyTO);
- }
- ((BasePage) pageRef.getPage()).setModalResult(true);
-
- window.close(target);
- } catch (Exception e) {
- LOG.error("While creating policy", e);
-
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- ((NotificationPanel) getPage().get(Constants.FEEDBACK)).refresh(target);
- }
- };
- form.add(submit);
-
- final IndicatingAjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- }
- };
- cancel.setDefaultFormProcessing(false);
- form.add(cancel);
- }
-
- private PolicySpec getPolicySpecification(final AbstractPolicyTO policyTO) {
- PolicySpec spec;
-
- switch (policyTO.getType()) {
- case GLOBAL_ACCOUNT:
- case ACCOUNT:
- spec = ((AccountPolicyTO) policyTO).getSpecification() != null
- ? ((AccountPolicyTO) policyTO).getSpecification()
- : new AccountPolicySpec();
- break;
-
- case GLOBAL_PASSWORD:
- case PASSWORD:
- spec = ((PasswordPolicyTO) policyTO).getSpecification() != null
- ? ((PasswordPolicyTO) policyTO).getSpecification()
- : new PasswordPolicySpec();
- break;
-
- case GLOBAL_SYNC:
- case SYNC:
- default:
- spec = ((SyncPolicyTO) policyTO).getSpecification() != null
- ? ((SyncPolicyTO) policyTO).getSpecification()
- : new SyncPolicySpec();
- }
-
- return spec;
- }
-
- private void setPolicySpecification(final AbstractPolicyTO policyTO, final PolicySpec specification) {
- switch (policyTO.getType()) {
- case GLOBAL_ACCOUNT:
- case ACCOUNT:
- if (!(specification instanceof AccountPolicySpec)) {
- throw new ClassCastException("policy is type Account, but spec is not: "
- + specification.getClass().getName());
- }
- ((AccountPolicyTO) policyTO).setSpecification((AccountPolicySpec) specification);
- break;
-
- case GLOBAL_PASSWORD:
- case PASSWORD:
- if (!(specification instanceof PasswordPolicySpec)) {
- throw new ClassCastException("policy is type Password, but spec is not: "
- + specification.getClass().getName());
- }
- ((PasswordPolicyTO) policyTO).setSpecification((PasswordPolicySpec) specification);
- break;
-
- case GLOBAL_SYNC:
- case SYNC:
- if (!(specification instanceof SyncPolicySpec)) {
- throw new ClassCastException("policy is type Sync, but spec is not: "
- + specification.getClass().getName());
- }
- ((SyncPolicyTO) policyTO).setSpecification((SyncPolicySpec) specification);
-
- default:
- }
- }
-
- private class PolicyTypeRenderer extends ChoiceRenderer<PolicyType> {
-
- private static final long serialVersionUID = -8993265421104002134L;
-
- @Override
- public Object getDisplayValue(final PolicyType object) {
- return getString(object.name());
- }
- };
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/PropagationTaskModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/PropagationTaskModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/PropagationTaskModalPage.java
deleted file mode 100644
index 5a6779f..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/PropagationTaskModalPage.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.common.lib.to.AbstractTaskTO;
-import org.apache.wicket.model.PropertyModel;
-
-/**
- * Modal window with Task form (to stop and start execution).
- */
-public class PropagationTaskModalPage extends TaskModalPage {
-
- private static final long serialVersionUID = 523379887023786151L;
-
- public PropagationTaskModalPage(final AbstractTaskTO taskTO) {
- super(taskTO);
-
- final AjaxTextFieldPanel accountId = new AjaxTextFieldPanel("accountId", getString("accountId"),
- new PropertyModel<String>(taskTO, "accountId"));
- accountId.setEnabled(false);
- profile.add(accountId);
-
- final AjaxTextFieldPanel resource = new AjaxTextFieldPanel("resource", getString("resource"),
- new PropertyModel<String>(taskTO, "resource"));
- resource.setEnabled(false);
- profile.add(resource);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/ProvisioningModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/ProvisioningModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/ProvisioningModalPage.java
deleted file mode 100644
index 6418d61..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/ProvisioningModalPage.java
+++ /dev/null
@@ -1,249 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.LinkedHashMap;
-import java.util.List;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.status.AbstractStatusBeanProvider;
-import org.apache.syncope.client.console.commons.status.ConnObjectWrapper;
-import org.apache.syncope.client.console.commons.status.StatusBean;
-import org.apache.syncope.client.console.commons.status.StatusUtils;
-import org.apache.syncope.client.console.panels.ActionDataTablePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
-import org.apache.syncope.client.lib.SyncopeClient;
-import org.apache.syncope.common.lib.to.AbstractAttributableTO;
-import org.apache.syncope.common.lib.to.AbstractSubjectTO;
-import org.apache.syncope.common.lib.to.BulkActionResult;
-import org.apache.syncope.common.lib.to.ResourceTO;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.syncope.common.lib.types.ResourceDeassociationActionType;
-import org.apache.syncope.common.lib.wrap.AbstractWrappable;
-import org.apache.syncope.common.lib.wrap.SubjectKey;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.ISortableDataProvider;
-import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
-import org.apache.wicket.extensions.markup.html.repeater.util.SortParam;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.repeater.Item;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.StringResourceModel;
-
-public class ProvisioningModalPage<T extends AbstractAttributableTO> extends AbstractStatusModalPage {
-
- private static final long serialVersionUID = -4285220460543213901L;
-
- private static final int ROWS_PER_PAGE = 10;
-
- private final ResourceTO resourceTO;
-
- private final Class<? extends AbstractAttributableTO> typeRef;
-
- private final PageReference pageRef;
-
- private final ModalWindow window;
-
- private final StatusUtils statusUtils;
-
- public ProvisioningModalPage(
- final PageReference pageRef,
- final ModalWindow window,
- final ResourceTO resourceTO,
- final Class<T> typeRef) {
-
- super();
-
- this.pageRef = pageRef;
- this.window = window;
- this.resourceTO = resourceTO;
- this.typeRef = typeRef;
-
- statusUtils = new StatusUtils((UserTO.class.isAssignableFrom(typeRef) ? userRestClient : groupRestClient));
-
- add(new Label("displayName", StringUtils.EMPTY));
-
- final List<IColumn<StatusBean, String>> columns = new ArrayList<>();
- columns.add(new PropertyColumn<StatusBean, String>(
- new StringResourceModel("key", this, null, "Attributable key"),
- "attributableKey", "attributableKey"));
- columns.add(new PropertyColumn<StatusBean, String>(
- new StringResourceModel("name", this, null, "Attributable name"),
- "attributableName", "attributableName"));
- columns.add(new PropertyColumn<StatusBean, String>(
- new StringResourceModel("resourceName", this, null, "Resource name"),
- "resourceName", "resourceName"));
- columns.add(new PropertyColumn<StatusBean, String>(
- new StringResourceModel("accountLink", this, null, "Account link"),
- "accountLink", "accountLink"));
- columns.add(new AbstractColumn<StatusBean, String>(
- new StringResourceModel("status", this, null, "")) {
-
- private static final long serialVersionUID = -3503023501954863131L;
-
- @Override
- public String getCssClass() {
- return "action";
- }
-
- @Override
- public void populateItem(
- final Item<ICellPopulator<StatusBean>> cellItem,
- final String componentId,
- final IModel<StatusBean> model) {
- cellItem.
- add(statusUtils.getStatusImagePanel(componentId, model.getObject().getStatus()));
- }
- });
-
- final ActionDataTablePanel<StatusBean, String> table = new ActionDataTablePanel<>(
- "resourceDatatable",
- columns,
- (ISortableDataProvider<StatusBean, String>) new StatusBeanProvider(),
- ROWS_PER_PAGE,
- pageRef);
-
- final String pageId = "Resources";
-
- table.addAction(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- bulkAssociationAction(target, ResourceDeassociationActionType.UNLINK, table, columns);
- } catch (Exception e) {
- LOG.error("Error unlinkink resources", e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
- }, ActionLink.ActionType.UNLINK, pageId);
-
- table.addAction(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- bulkAssociationAction(target, ResourceDeassociationActionType.DEPROVISION, table, columns);
- } catch (Exception e) {
- LOG.error("Error de-provisioning user", e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
- }, ActionLink.ActionType.DEPROVISION, pageId);
-
- table.addAction(new ActionLink() {
-
- private static final long serialVersionUID = -3722207913631435501L;
-
- @Override
- public void onClick(final AjaxRequestTarget target) {
- try {
- bulkAssociationAction(target, ResourceDeassociationActionType.UNASSIGN, table, columns);
- } catch (Exception e) {
- LOG.error("Error unassigning resources", e);
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
- }, ActionLink.ActionType.UNASSIGN, pageId);
-
- table.addCancelButton(window);
-
- add(table);
- }
-
- private class StatusBeanProvider extends AbstractStatusBeanProvider {
-
- private static final long serialVersionUID = 4287357360778016173L;
-
- public StatusBeanProvider() {
- super("accountLink");
- }
-
- @SuppressWarnings("unchecked")
- @Override
- public List<StatusBean> getStatusBeans() {
- final String fiql = SyncopeClient.getUserSearchConditionBuilder().hasResources(resourceTO.getKey()).query();
-
- final List<T> subjects = new ArrayList<>();
- if (UserTO.class.isAssignableFrom(typeRef)) {
- subjects.addAll((List<T>) userRestClient.search(fiql, 1, ROWS_PER_PAGE, new SortParam<>("key", true)));
- } else {
- subjects.addAll((List<T>) groupRestClient.search(fiql, 1, ROWS_PER_PAGE, new SortParam<>("key", true)));
- }
-
- final List<ConnObjectWrapper> connObjects = statusUtils.getConnectorObjects(
- (List<AbstractSubjectTO>) subjects, Collections.<String>singleton(resourceTO.getKey()));
-
- final List<StatusBean> statusBeans = new ArrayList<>(connObjects.size() + 1);
- final LinkedHashMap<String, StatusBean> initialStatusBeanMap = new LinkedHashMap<>(connObjects.size());
-
- for (ConnObjectWrapper entry : connObjects) {
- final StatusBean statusBean = statusUtils.getStatusBean(entry.getAttributable(),
- entry.getResourceName(),
- entry.getConnObjectTO(),
- GroupTO.class.isAssignableFrom(typeRef));
-
- initialStatusBeanMap.put(entry.getResourceName(), statusBean);
- statusBeans.add(statusBean);
- }
-
- return statusBeans;
- }
- }
-
- private void bulkAssociationAction(
- final AjaxRequestTarget target,
- final ResourceDeassociationActionType type,
- final ActionDataTablePanel<StatusBean, String> table,
- final List<IColumn<StatusBean, String>> columns) {
-
- final List<StatusBean> beans = new ArrayList<>(table.getModelObject());
- List<SubjectKey> subjectKeys = new ArrayList<>();
- for (StatusBean bean : beans) {
- LOG.debug("Selected bean {}", bean);
- subjectKeys.add(AbstractWrappable.getInstance(SubjectKey.class, bean.getAttributableId()));
- }
-
- if (beans.isEmpty()) {
- window.close(target);
- } else {
- final BulkActionResult res = resourceRestClient.bulkAssociationAction(
- resourceTO.getKey(), typeRef, type, subjectKeys);
-
- ((BasePage) pageRef.getPage()).setModalResult(true);
-
- setResponsePage(new BulkActionResultModalPage<>(window, beans, columns, res, "attributableKey"));
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/PushTaskModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/PushTaskModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/PushTaskModalPage.java
deleted file mode 100644
index 51852be..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/PushTaskModalPage.java
+++ /dev/null
@@ -1,135 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.panels.GroupSearchPanel;
-import org.apache.syncope.client.console.panels.UserSearchPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
-import org.apache.syncope.common.lib.to.PushTaskTO;
-import org.apache.syncope.common.lib.to.SchedTaskTO;
-import org.apache.syncope.common.lib.types.MatchingRule;
-import org.apache.syncope.common.lib.types.UnmatchingRule;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.model.Model;
-
-/**
- * Modal window with Push Task form.
- */
-public class PushTaskModalPage extends AbstractSyncTaskModalPage {
-
- private static final long serialVersionUID = 2148403203517274669L;
-
- private final UserSearchPanel userFilter;
-
- private final GroupSearchPanel groupFilter;
-
- private final AjaxCheckBoxPanel checkUserFilter;
-
- private final AjaxCheckBoxPanel checkGroupFilter;
-
- @Override
- protected List<String> getSyncActions() {
- return taskRestClient.getPushActionsClasses();
- }
-
- public PushTaskModalPage(final ModalWindow window, final PushTaskTO taskTO, final PageReference pageRef) {
-
- super(window, taskTO, pageRef);
-
- // set default Matching rule
- ((DropDownChoice) matchingRule.getField()).setDefaultModelObject(taskTO.getMatchingRule() == null
- ? MatchingRule.UPDATE
- : taskTO.getMatchingRule());
- profile.add(matchingRule);
-
- // set default Unmatching rule
- ((DropDownChoice) unmatchingRule.getField()).setDefaultModelObject(taskTO.getUnmatchingRule() == null
- ? UnmatchingRule.ASSIGN
- : taskTO.getUnmatchingRule());
- profile.add(unmatchingRule);
-
- final WebMarkupContainer filterContainer = new WebMarkupContainer("filterContainer");
- filterContainer.setOutputMarkupId(true);
-
- checkUserFilter = new AjaxCheckBoxPanel("checkUserFilter", "checkUserFilter",
- new Model<>(taskTO.getUserFilter() != null));
- filterContainer.add(checkUserFilter);
-
- checkGroupFilter = new AjaxCheckBoxPanel("checkGroupFilter", "checkGroupFilter",
- new Model<>(taskTO.getGroupFilter() != null));
- filterContainer.add(checkGroupFilter);
-
- userFilter = new UserSearchPanel.Builder("userFilter").fiql(taskTO.getUserFilter()).build();
- userFilter.setEnabled(checkUserFilter.getModelObject());
-
- filterContainer.add(userFilter);
-
- groupFilter = new GroupSearchPanel.Builder("groupFilter").fiql(taskTO.getGroupFilter()).build();
- groupFilter.setEnabled(checkGroupFilter.getModelObject());
- filterContainer.add(groupFilter);
-
- checkUserFilter.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- userFilter.setEnabled(checkUserFilter.getModelObject());
- target.add(filterContainer);
- }
- });
-
- checkGroupFilter.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- groupFilter.setEnabled(checkGroupFilter.getModelObject());
- target.add(filterContainer);
- }
- });
-
- profile.add(filterContainer);
- }
-
- @Override
- public void submitAction(final SchedTaskTO taskTO) {
- setFilters((PushTaskTO) taskTO);
- if (taskTO.getKey() > 0) {
- taskRestClient.updateSchedTask((PushTaskTO) taskTO);
- } else {
- taskRestClient.createSchedTask((PushTaskTO) taskTO);
- }
- }
-
- private void setFilters(final PushTaskTO pushTaskTO) {
- // set user filter if enabled
- pushTaskTO.setUserFilter(checkUserFilter.getModelObject() ? userFilter.buildFIQL() : null);
- // set group filter if enabled
- pushTaskTO.setGroupFilter(checkGroupFilter.getModelObject() ? groupFilter.buildFIQL() : null);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.java
deleted file mode 100644
index c6b57d2..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/ReportExecResultDownloadModalPage.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.Arrays;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.common.lib.types.ReportExecExportFormat;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.form.IChoiceRenderer;
-import org.apache.wicket.model.Model;
-
-public class ReportExecResultDownloadModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = 3163146190501510888L;
-
- public ReportExecResultDownloadModalPage(final ModalWindow window, final PageReference callerPageRef) {
-
- final AjaxDropDownChoicePanel<ReportExecExportFormat> format =
- new AjaxDropDownChoicePanel<>("format", "format", new Model<ReportExecExportFormat>());
-
- format.setChoices(Arrays.asList(ReportExecExportFormat.values()));
-
- format.setChoiceRenderer(new IChoiceRenderer<ReportExecExportFormat>() {
-
- private static final long serialVersionUID = -3941271550163141339L;
-
- @Override
- public Object getDisplayValue(final ReportExecExportFormat object) {
- return object.name();
- }
-
- @Override
- public String getIdValue(final ReportExecExportFormat object, final int index) {
-
- return object.name();
- }
- });
-
- format.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- format.getField();
-
- ((ReportModalPage) callerPageRef.getPage()).setExportFormat(format.getField().getModelObject());
- window.close(target);
- }
- });
- add(format);
- }
-}
[27/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupTabPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupTabPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupTabPanel_pt_BR.properties
deleted file mode 100644
index 7e751b2..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/GroupTabPanel_pt_BR.properties
+++ /dev/null
@@ -1,27 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-title=Grupo
-details=Detalhes
-plainAttrs=Atributos Normal
-derAttrs=Atributos Derivados
-virAttrs=Atributos Virtuais
-resources=Recursos
-entitlements=Direitos
-security=Seguran\u00e7a
-users=Usu\u00e1rios
-search=Obter Usu\u00e1rios
-templates=Modelo
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/ImagePanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ImagePanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/ImagePanel.html
deleted file mode 100644
index 63a568e..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ImagePanel.html
+++ /dev/null
@@ -1,23 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <img wicket:id="img" />
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/JQueryUITabbedPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/JQueryUITabbedPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/JQueryUITabbedPanel.html
deleted file mode 100644
index 9f66972..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/JQueryUITabbedPanel.html
+++ /dev/null
@@ -1,41 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <style>
- li.selected {
- margin-bottom: -1px !important;
- padding-bottom: 1px !important;
- }
- </style>
- </wicket:head>
- <wicket:panel xmlns:wicket="http://wicket.apache.org">
- <div>
- <span wicket:id="tabs-container">
- <ul class="ui-tabs-nav ui-helper-reset ui-helper-clearfix ui-widget-header ui-corner-all">
- <li wicket:id="tabs" class="ui-state-default ui-corner-top">
- <a class="ui-tabs-anchor" href="#" wicket:id="link"><span wicket:id="title">[[tab title]]</span></a>
- </li>
- </ul>
- </span>
- <div wicket:id="panel" class="ui-tabs-panel ui-widget-content ui-corner-bottom"
- style="border-width: 1px;border-top-width: 0px;">[panel]</div>
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/LayoutsPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/LayoutsPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/LayoutsPanel.html
deleted file mode 100644
index 51840f4..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/LayoutsPanel.html
+++ /dev/null
@@ -1,41 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div>
- <div id="users-contain" class="ui-widget">
- <span wicket:id="container">
- <form wicket:id="form">
- <div id="fields">
- <span wicket:id="fields">[fields]</span>
- </div>
- <div style="margin: 20px 0px 0">
- <input type="submit" style="padding: 7px 15px;"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="apply"/>
- <input type="button" style="padding: 7px 15px;"
- class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="cancel"/>
- </div>
- </form>
- </span>
- </div>
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/LayoutsPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/LayoutsPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/LayoutsPanel.properties
deleted file mode 100644
index a7a1683..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/LayoutsPanel.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-apply=Save
-cancel=Cancel
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/LayoutsPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/LayoutsPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/LayoutsPanel_it.properties
deleted file mode 100644
index a7a1683..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/LayoutsPanel_it.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-apply=Save
-cancel=Cancel
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/LayoutsPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/LayoutsPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/LayoutsPanel_pt_BR.properties
deleted file mode 100644
index a7a1683..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/LayoutsPanel_pt_BR.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-apply=Save
-cancel=Cancel
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/LoggerCategoryPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/LoggerCategoryPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/LoggerCategoryPanel.html
deleted file mode 100644
index c98dcb5..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/LoggerCategoryPanel.html
+++ /dev/null
@@ -1,106 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:head>
- <style>
-
- .events{
- display: table-row;
- width: 990px;
- }
-
- .selectedEvents{
- display: inline-block;
- height: 100px;
- margin: 10px 10px 0 10px;
- overflow-y: auto;
- }
-
- .eventSelection{
- display: inline-table;
- float: right;
- width: 380px;
- min-width: 380px;
- }
-
- .eventSelection div#eventElement{
- display: table-row;
- width:100%;
- }
- .eventSelection div#eventElement div#label{
- display: table-cell;
- }
-
- .eventSelection div#eventElement div#value{
- display: table-cell;
- padding: 0 0 0 10px;
- }
- </style>
- </wicket:head>
- <wicket:panel>
-
- <div class="events">
- <div class="selectedEvents">
- <span wicket:id="selectedEventsPanel">[selected events panel]</span>
- </div>
-
- <div class="eventSelection">
- <div wicket:id="categoryContainer" style="display: block; margin: 10px 0px 20px 0px">
- <div id="eventElement">
- <div id="label">
- <label wicket:id="typeLabel"/>
- </div>
- <div id="value">
- <span wicket:id="type">[type]</span>
- </div>
- </div>
- <div id="eventElement">
- <div id="label">
- <label wicket:id="categoryLabel"/>
- </div>
- <div id="value">
- <span wicket:id="category">[category]</span>
- </div>
- </div>
- <div id="eventElement">
- <div id="label">
- <label wicket:id="subcategoryLabel"/>
- </div>
- <div id="value">
- <span wicket:id="subcategory">[sub-category]</span>
- </div>
- </div>
- <div id="eventElement">
- <div id="label">
- <label wicket:id="customLabel"/>
- </div>
- <div id="value">
- <span wicket:id="custom">[custom]</span>
- <span wicket:id="customActions">[actions]</span>
- </div>
- </div>
- </div>
- <div wicket:id="eventsContainer" style="display: block">
- <span wicket:id="eventsPanel">[events panel]</span>
- </div>
- </div>
- </div>
-
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/MembershipsPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/MembershipsPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/MembershipsPanel.html
deleted file mode 100644
index cac787d..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/MembershipsPanel.html
+++ /dev/null
@@ -1,66 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <p class="ui-widget ui-corner-all ui-widget-header">
- <wicket:message key="membership_availability"/>
- </p>
-
- <div wicket:id="treeTable" style="float: left; width: 100%; margin:auto;" class="group-tree groupTable"/>
-
- <div style="float: left; width: 100%;">
- <p class="ui-widget ui-corner-all ui-widget-header"><wicket:message key="membership_text"/></p>
-
- <table id="users" class="membershipTable"
- style="font-size:1.1em" wicket:id="membershipsContainer"
- cellpadding="5px" cellspacing="2px">
- <thead>
- <tr class="ui-widget-header">
- <th><wicket:message key="id"/></th>
- <th><wicket:message key="name"/></th>
- <th><wicket:message key="edit"/></th>
- <th><wicket:message key="delete"/></th>
- </tr>
- </thead>
- <tbody>
- <tr wicket:id="memberships">
- <td>
- <span wicket:id="groupId"/>
- </td>
- <td>
- <span wicket:id="groupName"/>
- </td>
- <td>
- <a href="#" wicket:id="editLink">
- <wicket:message key="edit"/>
- </a>
- </td>
- <td>
- <a href="#" wicket:id="deleteLink">
- <wicket:message key="delete"/>
- </a>
- </td>
- </tr>
- </tbody>
- </table>
- </div>
-
- <div wicket:id="membershipWin"/>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/MembershipsPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/MembershipsPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/MembershipsPanel.properties
deleted file mode 100644
index 16b7c36..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/MembershipsPanel.properties
+++ /dev/null
@@ -1,23 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Group Id
-name=Group Name
-edit=Edit
-delete=Delete
-
-membership_availability=Available groups
-membership_text=Selected groups
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/MembershipsPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/MembershipsPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/MembershipsPanel_it.properties
deleted file mode 100644
index 86864a1..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/MembershipsPanel_it.properties
+++ /dev/null
@@ -1,24 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Id Gruppo
-edit=Modifica
-delete=Rimuovi
-name=Nome Gruppo
-
-membership_availability=Gruppi disponibili
-membership_text=Gruppi selezionati
-
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/MembershipsPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/MembershipsPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/MembershipsPanel_pt_BR.properties
deleted file mode 100644
index 5a41e98..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/MembershipsPanel_pt_BR.properties
+++ /dev/null
@@ -1,23 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Identificador da Grupo
-name=Nome da Grupo
-edit=Alterar
-delete=Excluir
-
-membership_availability=Grupos dispon\u00edveis
-membership_text=Grupos selecionadas
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/NotificationTasks.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/NotificationTasks.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/NotificationTasks.html
deleted file mode 100644
index 68cec92..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/NotificationTasks.html
+++ /dev/null
@@ -1,38 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div id="users-contain" class="ui-widget" style="width:auto">
- <span wicket:id="container">
- <span wicket:id="datatable">[datatable]</span>
- </span>
-
- <span style="float:right">
- <form wicket:id="PaginatorForm" style="display:inline">
- <label><wicket:message key="displayRows"/></label>
- <select class="text ui-widget-content ui-corner-all"
- wicket:id="rowsChooser"/>
- </form>
- </span>
- </div>
- <div wicket:id="taskWin">
- [Show modal window for viewing task]
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/NotificationTasks.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/NotificationTasks.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/NotificationTasks.properties
deleted file mode 100644
index d6bbd36..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/NotificationTasks.properties
+++ /dev/null
@@ -1,26 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Id
-execute=Execute
-detail=Detail
-delete=Delete
-edit=Edit
-sender=Sender
-recipients=Recipients
-traceLevel=Trace level
-subject=Subject
-latestExecStatus=Last status
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/NotificationTasks_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/NotificationTasks_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/NotificationTasks_it.properties
deleted file mode 100644
index da12f15..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/NotificationTasks_it.properties
+++ /dev/null
@@ -1,26 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Id
-execute=Esegui
-detail=Dettagli
-delete=Rimuovi
-edit=Modifica
-sender=Mittente
-recipients=Destinatari
-traceLevel=Livello di tracciamento
-subject=Oggetto
-latestExecStatus=Ultimo stato
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/NotificationTasks_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/NotificationTasks_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/NotificationTasks_pt_BR.properties
deleted file mode 100644
index abed229..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/NotificationTasks_pt_BR.properties
+++ /dev/null
@@ -1,26 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Identificador
-execute=Executar
-detail=Detalhe
-delete=Excluir
-edit=Alterar
-sender=Enviar
-recipients=Destinat\u00E1rios
-traceLevel=N\u00EDvel do Trace
-subject=Assunto
-latestExecStatus=\u00DAltimo Estatus
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/PlainAttrsPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PlainAttrsPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/PlainAttrsPanel.html
deleted file mode 100644
index 61f699d..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PlainAttrsPanel.html
+++ /dev/null
@@ -1,44 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div class="tablerow" wicket:id="schemas">
- <div class="tablecolumn_label short_dynamicsize">
- <span wicket:id="name"/>
- </div>
-
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="panel">
- [panel for dynamic input type markup]
- </span>
- <a class="tooltips" wicket:id="questionMarkJexlHelp" href="#" alt="Click to help" title="Click to help">
- <img src="img/help.png"/>
- <span wicket:id="jexlHelp" class="tooltips">
- <wicket:message key="jexl_info"/>
- <ul>
- <li><wicket:message key="jexl_ex1"/></li>
- <li><wicket:message key="jexl_ex2"/></li>
- </ul>
- <a href="#" wicket:id="jexlLink" target="_blank"><wicket:message key="jexl_syntax_url"/></a>
- </span>
- </a>
- </div>
- </div>
- </wicket:panel>
-</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/PoliciesPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PoliciesPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/PoliciesPanel.html
deleted file mode 100644
index 8bae2f9..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PoliciesPanel.html
+++ /dev/null
@@ -1,42 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div>
- <div id="users-contain" class="ui-widget">
- <span wicket:id="container">
- <table class="ui-widget ui-widget-content table-hover" wicket:id="datatable"/>
- </span>
-
- <span style="float:right">
- <form wicket:id="PaginatorForm" style="display:inline">
- <label><wicket:message key="displayRows"/></label>
- <select class="text ui-widget-content ui-corner-all" wicket:id="rowsChooser"/>
- </form>
- </span>
- </div>
-
- <div wicket:id="editModalWin">[Show modal window for creating/editing password policy]</div>
-
- <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only" wicket:id="createLink">
- <wicket:message key="create"/>
- </a>
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/PoliciesPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PoliciesPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/PoliciesPanel.properties
deleted file mode 100644
index afab11d..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PoliciesPanel.properties
+++ /dev/null
@@ -1,34 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Id
-description=Description
-type=Type
-title=Account Policies
-delete=Delete
-edit=Edit
-displayRows=Rows per page
-
-#-----------------------------
-# Policy Type
-#-----------------------------
-ACCOUNT=Account Policy
-GLOBAL_ACCOUNT=Global Account Policy
-PASSWORD=Password Policy
-GLOBAL_PASSWORD=Password Global Policy
-SYNC=Synchronization Policy
-GLOBAL_SYNC=Global Synchronization Policy
-#-----------------------------
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/PoliciesPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PoliciesPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/PoliciesPanel_it.properties
deleted file mode 100644
index fcbd7c2..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PoliciesPanel_it.properties
+++ /dev/null
@@ -1,34 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Id
-description=Descrizione
-type=Tipo
-title=Account Policy
-delete=Rimuovi
-edit=Modifica
-displayRows=Righe per pagina
-
-#-----------------------------
-# Policy Type
-#-----------------------------
-ACCOUNT=Account Policy
-GLOBAL_ACCOUNT=Account Policy globale
-PASSWORD=Password policy
-GLOBAL_PASSWORD=Password policy globale
-SYNC=Policy di sincronizzazione
-GLOBAL_SYNC=Policy di sincronizzazione globale
-#-----------------------------
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/PoliciesPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PoliciesPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/PoliciesPanel_pt_BR.properties
deleted file mode 100644
index caa7ae2..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PoliciesPanel_pt_BR.properties
+++ /dev/null
@@ -1,34 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Identificador
-description=Descri\u00e7\u00e3o
-type=Tipo
-title=Pol\u00edticas de Conta
-delete=Excluir
-edit=Modificar
-displayRows=Linhas por p\u00e1gina
-
-#-----------------------------
-# Policy Type
-#-----------------------------
-ACCOUNT=Pol\u00edtica de Conta
-GLOBAL_ACCOUNT=Pol\u00edtica Global de Conta
-PASSWORD=Pol\u00edtica de Senha
-GLOBAL_PASSWORD=Pol\u00edtica Global de Senha
-SYNC=Pol\u00edtica de Sincroniza\u00e7\u00e3o
-GLOBAL_SYNC=Pol\u00edtica Global de Sincroniza\u00e7\u00e3o
-#-----------------------------
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/PolicyBeanPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PolicyBeanPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/PolicyBeanPanel.html
deleted file mode 100644
index b9df63e..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PolicyBeanPanel.html
+++ /dev/null
@@ -1,39 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
-
- <div id="policyBeanTable">
- <div class="tablerow" wicket:id="policies">
- <div class="tablecolumn_check">
- <span wicket:id="check">[check]</span>
- </div>
- <div class="tablecolumn_label short_dynamicsize">
- <label for="label">
- <span wicket:id="label">[label]</span>
- </label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="field">[field]</span>
- </div>
- </div>
- </div>
-
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/PropagationTasks.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PropagationTasks.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/PropagationTasks.html
deleted file mode 100644
index cb8a564..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PropagationTasks.html
+++ /dev/null
@@ -1,37 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div id="users-contain" class="ui-widget" style="width:auto">
- <span wicket:id="container">
- <span wicket:id="datatable">[datatable]</span>
- </span>
- <span style="float:right">
- <form wicket:id="PaginatorForm" style="display:inline">
- <label><wicket:message key="displayRows"/></label>
- <select class="text ui-widget-content ui-corner-all"
- wicket:id="rowsChooser"/>
- </form>
- </span>
- </div>
- <div wicket:id="taskWin">
- [Show modal window for viewing task]
- </div>
- </wicket:panel>
-</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/PropagationTasks.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PropagationTasks.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/PropagationTasks.properties
deleted file mode 100644
index e800242..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PropagationTasks.properties
+++ /dev/null
@@ -1,28 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Id
-accountId=Account Id
-resource=Resource
-execute=Execute
-detail=Detail
-delete=Delete
-edit=Edit
-propagationMode=Propagation Mode
-propagationOperation=Propagation Operation
-latestExecStatus=Last status
-startDate=Start date
-endDate=End date
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/PropagationTasks_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PropagationTasks_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/PropagationTasks_it.properties
deleted file mode 100644
index 62f0177..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PropagationTasks_it.properties
+++ /dev/null
@@ -1,28 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Id
-accountId=Account Id
-resource=Risorsa
-execute=Esegui
-detail=Dettagli
-delete=Rimuovi
-edit=Modifica
-propagationMode=Propagazione
-propagationOperation=Operazione
-latestExecStatus=Ultimo stato
-startDate=Data di avvio
-endDate=Data di conclusione
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/PropagationTasks_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PropagationTasks_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/PropagationTasks_pt_BR.properties
deleted file mode 100644
index 709dc9c..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PropagationTasks_pt_BR.properties
+++ /dev/null
@@ -1,28 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Identificador
-accountId=Identificador da Conta
-resource=Recurso
-execute=Executar
-detail=Detalhe
-delete=Excluir
-edit=Alterar
-propagationMode=Mode de Propaga\u00E7\u00E3o
-propagationOperation=Opera\u00E7\u00E3o de Propaga\u00E7\u00E3o
-latestExecStatus=\u00DAltimo Estatus
-startDate=Data inicial
-endDate=Data Final
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/PushTasksPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PushTasksPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/PushTasksPanel.properties
deleted file mode 100644
index 497da5a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PushTasksPanel.properties
+++ /dev/null
@@ -1,29 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Id
-name=Name
-description=Description
-resourceName=Resource Name
-lastExec=Last Execution
-nextExec=Next Execution
-detail=Detail
-delete=Delete
-edit=Edit
-execute=Execute
-executeDryRun=Dry run
-userTemplate=User template
-latestExecStatus=Last status
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/PushTasksPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PushTasksPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/PushTasksPanel_it.properties
deleted file mode 100644
index abb82a4..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PushTasksPanel_it.properties
+++ /dev/null
@@ -1,29 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Id
-name=Nome
-description=Descrizione
-resourceName=Nome Risorsa
-lastExec=Ultima Esecuzione
-nextExec=Prossima Esecuzione
-detail=Dettagli
-delete=Rimuovi
-edit=Modifica
-execute=Esegui
-executeDryRun=Esecuzione simulata
-userTemplate=Modello utente
-latestExecStatus=Ultimo stato
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/PushTasksPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PushTasksPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/PushTasksPanel_pt_BR.properties
deleted file mode 100644
index 054af39..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/PushTasksPanel_pt_BR.properties
+++ /dev/null
@@ -1,29 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Identificador
-name=Nome
-description=Descri\u00e7\u00e3o
-resourceName=Nome do Recurso
-lastExec=\u00daltima Execu\u00e7\u00e3o
-nextExec=Pr\u00f3xima Execu\u00e7\u00e3o
-detail=Detalhe
-delete=Remove
-edit=Alterar
-execute=Executar
-executeDryRun=Executar (Ensaio)
-userTemplate=Usar Template
-latestExecStatus=\u00daltimo Estatus
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceConnConfPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceConnConfPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceConnConfPanel.html
deleted file mode 100644
index d4b0e16..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceConnConfPanel.html
+++ /dev/null
@@ -1,41 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <span wicket:id="connectorPropertiesContainer">
- <div id="formtable">
- <div class="tablerow" wicket:id="connectorProperties">
- <div class="tablecolumn_label medium_fixedsize">
- <span wicket:id="connPropAttrSchema">[connPropAttrSchema]</span>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="panel">[connPropAttrValue]</span>
- </div>
- </div>
- </div>
-
- <div>
- <a style="position: absolute; top: 2px; right:20px;" wicket:id="check">
- <img src="img/ping.png"width="30" height="30"
- alt="ping" title="title" wicket:message="title:check"/>
- </a>
- </div>
- </span>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceDetailsPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceDetailsPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceDetailsPanel.html
deleted file mode 100644
index cd8c4ea..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceDetailsPanel.html
+++ /dev/null
@@ -1,137 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div id="formtable">
- <div class="tablerow alt">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="name"><wicket:message key="name"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="name">[name]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="connector"><wicket:message key="connector"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="connector">[connector]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="enforceMandatoryCondition"><wicket:message key="enforceMandatoryCondition"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="enforceMandatoryCondition">[enforceMandatoryCondition]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="propagationPrimary"><wicket:message key="propagationPrimary"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="propagationPrimary">[propagationPrimary]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="propagationPriority"><wicket:message key="propagationPriority"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="propagationPriority">[propagationPriority]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="propagationMode"><wicket:message key="propagationMode"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="propagationMode">[propagationMode]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="randomPwdIfNotProvided"><wicket:message key="randomPwdIfNotProvided"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="randomPwdIfNotProvided">[randomPwdIfNotProvided]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="propagationActionsClassNames"><wicket:message key="actionsClasses"/></label>
- </div>
- <span wicket:id="propagationActionsClassNames">
- <span wicket:id="actionsClasses">
- <select class="text ui-widget-content ui-corner-all" wicket:id="actionsClass"/>
- <a wicket:id="drop"><img src="img/minus-icon.png" alt="remove icon" class="drop_button"/></a>
- <a wicket:id="add"><img src="img/plus-icon.png" alt="add icon" class="add_button"/></a>
- <br/>
- </span>
- <a wicket:id="first"><img src="img/plus-icon.png" alt="add icon" class="add_button"/></a>
- </span>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="createTraceLevel"><wicket:message key="createTraceLevel"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="createTraceLevel">[createTraceLevel]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="updateTraceLevel"><wicket:message key="updateTraceLevel"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="updateTraceLevel">[updateTraceLevel]</span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="deleteTraceLevel"><wicket:message key="deleteTraceLevel"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="deleteTraceLevel">[deleteTraceLevel]</span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label medium_fixedsize">
- <label for="syncTraceLevel"><wicket:message key="syncTraceLevel"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="syncTraceLevel">[syncTraceLevel]</span>
- </div>
- </div>
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceMappingPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceMappingPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceMappingPanel.html
deleted file mode 100644
index 8338fd4..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceMappingPanel.html
+++ /dev/null
@@ -1,125 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div>
- <table id="mappings"
- class="ui-widget ui-widget-content ui-corner-all"
- style="font-size: 1em;margin-top:2px;"
- width="100%" cellpadding="2px" cellspacing="1px"
- wicket:id="mappingContainer">
- <thead>
- <tr class="ui-widget-header">
- <th><wicket:message key="delete"/></th>
- <th><wicket:message key="entity"/></th>
- <th><wicket:message key="intMappingTypes"/></th>
- <th><wicket:message key="intAttrNames"/></th>
- <th><wicket:message key="extAttrNames"/></th>
- <th><wicket:message key="mandatoryCondition"/>
- <a class="tooltips" wicket:id="questionMarkJexlHelp" href="#" alt="Click to help" title="Click to help"><img src="img/help.png"/>
- <span wicket:id="jexlHelp" class="tooltips">
- <wicket:message key="jexl_info"/>
- <ul>
- <li><wicket:message key="jexl_ex1"/></li>
- <li><wicket:message key="jexl_ex2"/></li>
- </ul>
- <a href="#" wicket:id="jexlLink" target="_blank"><wicket:message key="jexl_syntax_url"/></a>
- </span>
- </a>
- </th>
- <th><wicket:message key="accountId"/></th>
- <th><label wicket:id="passwordLabel"/></th>
- <th><wicket:message key="purpose"/></th>
- </tr>
- </thead>
- <tfoot>
- <tr>
- <td colspan="7" style="padding: 5px">
- <input type="submit" class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="addMappingBtn" />
- </td>
- </tr>
- </tfoot>
- <tbody>
- <tr wicket:id="mappings" class="tablerow">
- <td align="center" valign="middle">
- <input type="checkbox" class="text ui-widget-content ui-corner-all" wicket:id="toRemove"/>
- </td>
- <td align="center" valign="middle">
- <span wicket:id="entities">[entities]</span>
- </td>
- <td align="center" valign="middle">
- <span wicket:id="intMappingTypes">[intMappingTypes]</span>
- </td>
- <td align="center" valign="middle">
- <span wicket:id="intAttrNames">[intAttrNames]</span>
- </td>
- <td align="center" valign="middle">
- <span wicket:id="extAttrName">[extAttrName]</span>
- </td>
- <td align="center" valign="middle">
- <span wicket:id="mandatoryCondition">[mandatoryCondition]</span>
- </td>
- <td align="center" valign="middle">
- <span wicket:id="accountId">[accountId]</span>
- </td>
- <td align="center" valign="middle">
- <span wicket:id="password">[password]</span>
- </td>
- <td align="center" valign="middle">
- <span wicket:id="purpose">
- <span wicket:id="purposeActions">[purpose]</span>
- </span>
- </td>
- </tr>
- </tbody>
- </table>
-
- <script type="text/javascript">
- $(function() {
- $('table#mappings tbody tr.tablerow:even').addClass("alt");
- });
- </script>
-
- <table id="accountLinkTable"
- class="ui-widget ui-widget-content ui-corner-all"
- style="font-size: 1em;margin-top:2px;"
- border-width="1px;" border-color="#cccccc;" border-style="solid;"
- width="100%" cellpadding="2px" cellspacing="1px"
- wicket:id="accountLinkContainer">
- <thead>
- <tr class="ui-widget-header">
- <th width="10%" align="left"><wicket:message key="enable"/></th>
- <th align="left"><wicket:message key="accountLink"/></th>
- </tr>
- </thead>
- <tbody>
- <tr>
- <td width="10%" align="left" valign="middle">
- <span wicket:id="accountLinkCheckbox">[accountLinkCheckbox]</span>
- </td>
- <td align="left" valign="middle">
- <span wicket:id="accountLink">[accountLink]</span>
- </td>
- </tr>
- </tbody>
- </table>
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceSecurityPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceSecurityPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceSecurityPanel.html
deleted file mode 100644
index ddabe05..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceSecurityPanel.html
+++ /dev/null
@@ -1,56 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div id="formtable" wicket:id="security">
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="passwordPolicy"><wicket:message key="passwordPolicy"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="passwordPolicy">
- [panel for dynamic input type markup]
- </span>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="accountPolicy"><wicket:message key="accountPolicy"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="accountPolicy">
- [panel for dynamic input type markup]
- </span>
- </div>
- </div>
-
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <label for="syncPolicy"><wicket:message key="syncPolicy"/></label>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="syncPolicy">
- [panel for dynamic input type markup]
- </span>
- </div>
- </div>
- </div>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceSecurityPanel.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceSecurityPanel.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceSecurityPanel.properties
deleted file mode 100644
index a38237e..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceSecurityPanel.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-passwordPolicy = Password Policy
-accountPolicy = Account Policy
-syncPolicy = Sync Policy
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceSecurityPanel_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceSecurityPanel_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceSecurityPanel_it.properties
deleted file mode 100644
index f7fd440..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceSecurityPanel_it.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-passwordPolicy = Password Policy
-accountPolicy = Account Policy
-syncPolicy = Sync Policy
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceSecurityPanel_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceSecurityPanel_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceSecurityPanel_pt_BR.properties
deleted file mode 100644
index 3933167..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourceSecurityPanel_pt_BR.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-passwordPolicy = Pol\u00EDtica de Senha
-accountPolicy = Pol\u00EDtica de Conta
-syncPolicy = Pol\u00EDtica de Sincroniza\u00E7\u00E3o
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourcesPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourcesPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourcesPanel.html
deleted file mode 100644
index d5d155a..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/ResourcesPanel.html
+++ /dev/null
@@ -1,23 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <span wicket:id="resourcesPalette">[palette]</span>
- </wicket:panel>
-</html>
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/SchedTasks.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SchedTasks.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/SchedTasks.html
deleted file mode 100644
index 7ac78ad..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SchedTasks.html
+++ /dev/null
@@ -1,42 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div id="users-contain" class="ui-widget" style="width:auto">
- <span wicket:id="container">
- <span wicket:id="datatable">[datatable]</span>
- </span>
-
- <span style="float:right">
- <form wicket:id="PaginatorForm" style="display:inline">
- <label><wicket:message key="displayRows"/></label>
- <select class="text ui-widget-content ui-corner-all"
- wicket:id="rowsChooser"/>
- </form>
- </span>
- </div>
- <div wicket:id="taskWin">
- [Show modal window for viewing task]
- </div>
- <a class="ui-button ui-widget ui-state-default ui-corner-all ui-button-text-only"
- wicket:id="createLink">
- <wicket:message key="create"/>
- </a>
- </wicket:panel>
-</html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/SchedTasks.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SchedTasks.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/SchedTasks.properties
deleted file mode 100644
index 98b50fe..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SchedTasks.properties
+++ /dev/null
@@ -1,28 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Id
-name=Name
-description=Description
-class=Class
-lastExec=Last Execution
-nextExec=Next Execution
-detail=Detail
-delete=Delete
-edit=Edit
-execute=Execute
-executeDryRun=Dry run
-latestExecStatus=Last status
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/SchedTasks_it.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SchedTasks_it.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/SchedTasks_it.properties
deleted file mode 100644
index f023310..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SchedTasks_it.properties
+++ /dev/null
@@ -1,28 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Id
-name=Nome
-description=Descrizione
-class=Classs
-lastExec=Ultima Esecuzione
-nextExec=Prossima Esecuzione
-detail=Dettagli
-delete=Rimuovi
-edit=Modifica
-execute=Esegui
-executeDryRun=Esecuzione simulata
-latestExecStatus=Ultimo stato
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/SchedTasks_pt_BR.properties
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SchedTasks_pt_BR.properties b/client/console/src/main/resources/org/apache/syncope/client/console/panels/SchedTasks_pt_BR.properties
deleted file mode 100644
index 0bca81c..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SchedTasks_pt_BR.properties
+++ /dev/null
@@ -1,28 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you under the Apache License, Version 2.0 (the
-# "License"); you may not use this file except in compliance
-# with the License. You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing,
-# software distributed under the License is distributed on an
-# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-# KIND, either express or implied. See the License for the
-# specific language governing permissions and limitations
-# under the License.
-id=Identificador
-name=Nome
-description=Descri\u00e7\u00e3o
-class=Classe
-lastExec=\u00daltima Execu\u00e7\u00e3o
-nextExec=Pr\u00f3xima Execu\u00e7\u00e3o
-detail=Detalhe
-delete=Remover
-edit=Editar
-execute=Executar
-executeDryRun=Executar (Ensaio)
-latestExecStatus=\u00daltimo Estatus
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/resources/org/apache/syncope/client/console/panels/SecurityQuestionPanel.html
----------------------------------------------------------------------
diff --git a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SecurityQuestionPanel.html b/client/console/src/main/resources/org/apache/syncope/client/console/panels/SecurityQuestionPanel.html
deleted file mode 100644
index d9668a0..0000000
--- a/client/console/src/main/resources/org/apache/syncope/client/console/panels/SecurityQuestionPanel.html
+++ /dev/null
@@ -1,41 +0,0 @@
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you under the Apache License, Version 2.0 (the
-"License"); you may not use this file except in compliance
-with the License. You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing,
-software distributed under the License is distributed on an
-"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
-KIND, either express or implied. See the License for the
-specific language governing permissions and limitations
-under the License.
--->
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org">
- <wicket:panel>
- <div id="formtable">
- <div class="tablerow alt">
- <div class="tablecolumn_label short_dynamicsize">
- <wicket:message key="securityQuestion"/>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="securityQuestion"/>
- </div>
- </div>
-
- <div class="tablerow">
- <div class="tablecolumn_label short_dynamicsize">
- <wicket:message key="securityAnswer"/>
- </div>
- <div class="tablecolumn_field medium_dynamicsize">
- <span wicket:id="securityAnswer"/>
- </div>
- </div>
- </div>
- </wicket:panel>
-</html>
\ No newline at end of file
[47/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/EditUserModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/EditUserModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/EditUserModalPage.java
deleted file mode 100644
index af502d2..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/EditUserModalPage.java
+++ /dev/null
@@ -1,105 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import org.apache.commons.lang3.SerializationUtils;
-import org.apache.syncope.client.console.commons.Mode;
-import org.apache.syncope.client.console.commons.status.StatusBean;
-import org.apache.syncope.client.console.panels.AccountInformationPanel;
-import org.apache.syncope.client.console.panels.MembershipsPanel;
-import org.apache.syncope.client.console.panels.ResourcesPanel;
-import org.apache.syncope.client.console.panels.StatusPanel;
-import org.apache.syncope.common.lib.AttributableOperations;
-import org.apache.syncope.common.lib.mod.UserMod;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.ResourceModel;
-
-/**
- * Modal window with User form.
- */
-public class EditUserModalPage extends UserModalPage {
-
- private static final long serialVersionUID = -6479209496805705739L;
-
- protected Form form;
-
- private final UserTO initialUserTO;
-
- private StatusPanel statusPanel;
-
- public EditUserModalPage(final PageReference pageRef, final ModalWindow window, final UserTO userTO) {
- super(pageRef, window, userTO, Mode.ADMIN, true);
-
- this.initialUserTO = SerializationUtils.clone(userTO);
-
- form = setupEditPanel();
-
- // add resource assignment details in case of update
- if (userTO.getKey() != 0) {
- form.addOrReplace(new Label("pwdChangeInfo", new ResourceModel("pwdChangeInfo")));
-
- statusPanel = new StatusPanel("statuspanel", userTO, new ArrayList<StatusBean>(), getPageReference());
- statusPanel.setOutputMarkupId(true);
- MetaDataRoleAuthorizationStrategy.authorize(
- statusPanel, RENDER, xmlRolesReader.getEntitlement("Resources", "getConnectorObject"));
- form.addOrReplace(statusPanel);
-
- form.addOrReplace(new AccountInformationPanel("accountinformation", userTO));
-
- form.addOrReplace(new ResourcesPanel.Builder("resources").attributableTO(userTO).
- statusPanel(statusPanel).build());
-
- form.addOrReplace(new MembershipsPanel("memberships", userTO, mode, statusPanel, getPageReference()));
- }
- }
-
- @SuppressWarnings("rawtypes")
- @Override
- protected void submitAction(final AjaxRequestTarget target, final Form form) {
- final UserTO updatedUserTO = (UserTO) form.getModelObject();
-
- if (updatedUserTO.getKey() == 0) {
- userTO = userRestClient.create(updatedUserTO, storePassword.getModelObject());
- } else {
- final UserMod userMod = AttributableOperations.diff(updatedUserTO, initialUserTO);
-
- if (statusPanel != null) {
- userMod.setPwdPropRequest(statusPanel.getStatusMod());
- }
-
- // update user just if it is changed
- if (!userMod.isEmpty()) {
- userTO = userRestClient.update(initialUserTO.getETagValue(), userMod);
- }
- }
- }
-
- @SuppressWarnings("rawtypes")
- @Override
- protected void closeAction(final AjaxRequestTarget target, final Form form) {
- setResponsePage(new ResultStatusModalPage.Builder(window, userTO).mode(mode).build());
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/ErrorPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/ErrorPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/ErrorPage.java
deleted file mode 100644
index db46171..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/ErrorPage.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.wicket.Page;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.link.BookmarkablePageLink;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.request.mapper.parameter.PageParameters;
-
-/**
- * Error WebPage.
- */
-public class ErrorPage extends BasePage {
-
- private static final long serialVersionUID = -390761262038796657L;
-
- public ErrorPage(final PageParameters parameters) {
- super(parameters);
-
- add(new Label("errorTitle", new Model<String>(parameters.get("errorTitle").toString())));
- add(new Label("errorMessage", new Model<String>(parameters.get("errorMessage").toString())));
-
- add(new BookmarkablePageLink<Page>("home", getApplication().getHomePage()));
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/ExecMessageModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/ExecMessageModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/ExecMessageModalPage.java
deleted file mode 100644
index e39f3fc..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/ExecMessageModalPage.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.model.Model;
-
-public class ExecMessageModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = 3163146190501510888L;
-
- public ExecMessageModalPage(final String message) {
- final Label dialogContent = new Label("message", new Model<String>(message));
- add(dialogContent.setOutputMarkupId(true));
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/FailureMessageModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/FailureMessageModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/FailureMessageModalPage.java
deleted file mode 100644
index c0ee7ec..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/FailureMessageModalPage.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.model.Model;
-
-public class FailureMessageModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = 9216117990503199258L;
-
- public FailureMessageModalPage(final String message, final String failureMessage) {
- final Label executionFailureMessage;
- if (!failureMessage.isEmpty()) {
- executionFailureMessage = new Label("failureMessage", new Model<String>(failureMessage));
- } else {
- executionFailureMessage = new Label("failureMessage");
- }
- add(executionFailureMessage.setOutputMarkupId(true));
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/GroupModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/GroupModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/GroupModalPage.java
deleted file mode 100644
index 8b4daa9..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/GroupModalPage.java
+++ /dev/null
@@ -1,164 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import java.util.List;
-import org.apache.commons.lang3.SerializationUtils;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.commons.Mode;
-import org.apache.syncope.client.console.panels.GroupPanel;
-import org.apache.syncope.common.lib.AttributableOperations;
-import org.apache.syncope.common.lib.mod.GroupMod;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.ResourceModel;
-
-/**
- * Modal window with Group form.
- */
-public class GroupModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = -1732493223434085205L;
-
- protected final PageReference pageRef;
-
- protected final ModalWindow window;
-
- protected final Mode mode;
-
- protected final boolean createFlag;
-
- protected final GroupPanel groupPanel;
-
- protected GroupTO originalGroupTO;
-
- public GroupModalPage(final PageReference pageRef, final ModalWindow window, final GroupTO groupTO) {
- this(pageRef, window, groupTO, Mode.ADMIN);
- }
-
- @SuppressWarnings({ "unchecked", "rawtypes" })
- public GroupModalPage(
- final PageReference pageRef, final ModalWindow window, final GroupTO groupTO, final Mode mode) {
-
- super();
-
- this.pageRef = pageRef;
- this.window = window;
- this.mode = mode;
-
- this.createFlag = groupTO.getKey() == 0;
- if (!createFlag) {
- originalGroupTO = SerializationUtils.clone(groupTO);
- }
-
- final Form<GroupTO> form = new Form<GroupTO>("groupForm");
- form.setMultiPart(true);
-
- add(new Label("displayName", groupTO.getKey() == 0 ? "" : groupTO.getDisplayName()));
-
- form.setModel(new CompoundPropertyModel<GroupTO>(groupTO));
-
- this.groupPanel = new GroupPanel.Builder("groupPanel").
- form(form).groupTO(groupTO).groupModalPageMode(mode).pageRef(getPageReference()).build();
- form.add(groupPanel);
-
- final AjaxButton submit = new IndicatingAjaxButton(SUBMIT, new ResourceModel(SUBMIT)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- try {
- submitAction(target, form);
-
- if (pageRef.getPage() instanceof BasePage) {
- ((BasePage) pageRef.getPage()).setModalResult(true);
- }
-
- closeAction(target, form);
- } catch (Exception e) {
- error(getString(Constants.ERROR) + ": " + e.getMessage());
- feedbackPanel.refresh(target);
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
- form.add(submit);
- form.setDefaultButton(submit);
-
- final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- closeAction(target, form);
- }
- };
- cancel.setDefaultFormProcessing(false);
- form.add(cancel);
-
- MetaDataRoleAuthorizationStrategy.authorize(submit, ENABLE, xmlRolesReader.getEntitlement("Groups",
- createFlag
- ? "create"
- : "update"));
-
- add(form);
- }
-
- protected void submitAction(final AjaxRequestTarget target, final Form<?> form) {
- final GroupTO groupTO = (GroupTO) form.getDefaultModelObject();
- final List<String> entitlementList = new ArrayList<String>(groupPanel.getSelectedEntitlements());
- groupTO.getEntitlements().clear();
- groupTO.getEntitlements().addAll(entitlementList);
-
- GroupTO result;
- if (createFlag) {
- result = groupRestClient.create(groupTO);
- } else {
- GroupMod groupMod = AttributableOperations.diff(groupTO, originalGroupTO);
-
- // update group just if it is changed
- if (groupMod.isEmpty()) {
- result = groupTO;
- } else {
- result = groupRestClient.update(originalGroupTO.getETagValue(), groupMod);
- }
- }
-
- setResponsePage(new ResultStatusModalPage.Builder(window, result).build());
- }
-
- protected void closeAction(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/GroupSelectModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/GroupSelectModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/GroupSelectModalPage.java
deleted file mode 100644
index 97b7abf..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/GroupSelectModalPage.java
+++ /dev/null
@@ -1,105 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.lang.reflect.Constructor;
-import javax.swing.tree.DefaultMutableTreeNode;
-import org.apache.syncope.client.console.commons.GroupTreeBuilder;
-import org.apache.syncope.client.console.wicket.markup.html.tree.DefaultMutableTreeNodeExpansion;
-import org.apache.syncope.client.console.wicket.markup.html.tree.DefaultMutableTreeNodeExpansionModel;
-import org.apache.syncope.client.console.wicket.markup.html.tree.TreeGroupProvider;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.wicket.Component;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.event.Broadcast;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.extensions.markup.html.repeater.tree.DefaultNestedTree;
-import org.apache.wicket.extensions.markup.html.repeater.tree.ITreeProvider;
-import org.apache.wicket.extensions.markup.html.repeater.tree.NestedTree;
-import org.apache.wicket.extensions.markup.html.repeater.tree.content.Folder;
-import org.apache.wicket.extensions.markup.html.repeater.tree.theme.WindowsTheme;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class GroupSelectModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = 2106489458494696439L;
-
- @SpringBean
- private GroupTreeBuilder groupTreeBuilder;
-
- private final NestedTree<DefaultMutableTreeNode> tree;
-
- public GroupSelectModalPage(final PageReference pageRef, final ModalWindow window, final Class<?> payloadClass) {
- super();
-
- final ITreeProvider<DefaultMutableTreeNode> treeProvider = new TreeGroupProvider(groupTreeBuilder, true);
- final DefaultMutableTreeNodeExpansionModel treeModel = new DefaultMutableTreeNodeExpansionModel();
-
- tree = new DefaultNestedTree<DefaultMutableTreeNode>("treeTable", treeProvider, treeModel) {
-
- private static final long serialVersionUID = 7137658050662575546L;
-
- @Override
- protected Component newContentComponent(final String id, final IModel<DefaultMutableTreeNode> node) {
- final DefaultMutableTreeNode treeNode = node.getObject();
- final GroupTO groupTO = (GroupTO) treeNode.getUserObject();
-
- return new Folder<DefaultMutableTreeNode>(id, GroupSelectModalPage.this.tree, node) {
-
- private static final long serialVersionUID = 9046323319920426493L;
-
- @Override
- protected boolean isClickable() {
- return true;
- }
-
- @Override
- protected IModel<?> newLabelModel(final IModel<DefaultMutableTreeNode> model) {
- return new Model<>(groupTO.getDisplayName());
- }
-
- @Override
- protected void onClick(final AjaxRequestTarget target) {
- super.onClick(target);
-
- try {
- Constructor<?> constructor = payloadClass.getConstructor(Long.class);
- Object payload = constructor.newInstance(groupTO.getKey());
-
- send(pageRef.getPage(), Broadcast.BREADTH, payload);
- } catch (Exception e) {
- LOG.error("Could not send group select event", e);
- }
-
- window.close(target);
- }
- };
- }
- };
- tree.add(new WindowsTheme());
- tree.setOutputMarkupId(true);
-
- DefaultMutableTreeNodeExpansion.get().expandAll();
-
- this.add(tree);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/GroupTemplateModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/GroupTemplateModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/GroupTemplateModalPage.java
deleted file mode 100644
index 293e402..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/GroupTemplateModalPage.java
+++ /dev/null
@@ -1,50 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.client.console.commons.Mode;
-import org.apache.syncope.common.lib.to.GroupTO;
-import org.apache.syncope.common.lib.to.SyncTaskTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.form.Form;
-
-public class GroupTemplateModalPage extends GroupModalPage {
-
- private static final long serialVersionUID = -3849135555203409845L;
-
- private final SyncTaskTO syncTaskTO;
-
- public GroupTemplateModalPage(final PageReference callerPageRef, final ModalWindow window,
- final SyncTaskTO syncTaskTO) {
-
- super(callerPageRef, window, syncTaskTO.getGroupTemplate() == null
- ? new GroupTO()
- : syncTaskTO.getGroupTemplate(), Mode.TEMPLATE);
-
- this.syncTaskTO = syncTaskTO;
- }
-
- @Override
- protected void submitAction(final AjaxRequestTarget target, final Form form) {
- syncTaskTO.setGroupTemplate((GroupTO) form.getModelObject());
- taskRestClient.updateSyncTask(syncTaskTO);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/Groups.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/Groups.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/Groups.java
deleted file mode 100644
index 2e92940..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/Groups.java
+++ /dev/null
@@ -1,186 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.panels.AbstractSearchResultPanel;
-import org.apache.syncope.client.console.panels.GroupSearchPanel;
-import org.apache.syncope.client.console.panels.GroupSearchResultPanel;
-import org.apache.syncope.client.console.panels.GroupSummaryPanel;
-import org.apache.syncope.client.console.rest.GroupRestClient;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
-import org.apache.syncope.client.console.wicket.markup.html.tree.TreeGroupPanel;
-import org.apache.wicket.Session;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.event.Broadcast;
-import org.apache.wicket.event.IEvent;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.request.mapper.parameter.PageParameters;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-/**
- * Groups WebPage.
- */
-public class Groups extends BasePage {
-
- private static final long serialVersionUID = -2147758241610831969L;
-
- private static final int WIN_HEIGHT = 500;
-
- private static final int WIN_WIDTH = 800;
-
- @SpringBean
- private GroupRestClient restClient;
-
- private final ModalWindow editGroupWin;
-
- private final WebMarkupContainer groupTabsContainer;
-
- public Groups(final PageParameters parameters) {
- super(parameters);
-
- groupTabsContainer = new WebMarkupContainer("groupTabsContainer");
- groupTabsContainer.setOutputMarkupId(true);
- add(groupTabsContainer);
-
- editGroupWin = new ModalWindow("editGroupWin");
- editGroupWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- editGroupWin.setInitialHeight(WIN_HEIGHT);
- editGroupWin.setInitialWidth(WIN_WIDTH);
- editGroupWin.setCookieName("edit-group-modal");
- add(editGroupWin);
-
- final TreeGroupPanel treePanel = new TreeGroupPanel("treePanel");
- treePanel.setOutputMarkupId(true);
- groupTabsContainer.add(treePanel);
-
- final GroupSummaryPanel summaryPanel = new GroupSummaryPanel.Builder("summaryPanel")
- .window(editGroupWin).callerPageRef(Groups.this.getPageReference()).build();
- groupTabsContainer.add(summaryPanel);
-
- editGroupWin.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
-
- private static final long serialVersionUID = 8804221891699487139L;
-
- @Override
- public void onClose(final AjaxRequestTarget target) {
- final GroupSummaryPanel summaryPanel = (GroupSummaryPanel) groupTabsContainer.get("summaryPanel");
-
- final TreeNodeClickUpdate data = new TreeNodeClickUpdate(target,
- summaryPanel == null || summaryPanel.getSelectedNode() == null
- ? 0
- : summaryPanel.getSelectedNode().getKey());
-
- send(getPage(), Broadcast.BREADTH, data);
-
- if (modalResult) {
- getSession().info(getString(Constants.OPERATION_SUCCEEDED));
- feedbackPanel.refresh(target);
- modalResult = false;
- }
-
- }
- });
-
- final AbstractSearchResultPanel searchResult =
- new GroupSearchResultPanel("searchResult", true, null, getPageReference(), restClient);
- add(searchResult);
-
- final Form searchForm = new Form("searchForm");
- add(searchForm);
-
- final GroupSearchPanel searchPanel = new GroupSearchPanel.Builder("searchPanel").build();
- searchForm.add(searchPanel);
-
- searchForm.add(new ClearIndicatingAjaxButton("search", new ResourceModel("search"), getPageReference()) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
- final String fiql = searchPanel.buildFIQL();
- LOG.debug("Node condition {}", fiql);
-
- doSearch(target, fiql, searchResult);
-
- Session.get().getFeedbackMessages().clear();
- searchPanel.getSearchFeedback().refresh(target);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- searchPanel.getSearchFeedback().refresh(target);
- }
- });
- }
-
- private void doSearch(final AjaxRequestTarget target, final String fiql,
- final AbstractSearchResultPanel resultsetPanel) {
-
- if (fiql == null) {
- error(getString(Constants.SEARCH_ERROR));
- return;
- }
-
- resultsetPanel.search(fiql, target);
- }
-
- @Override
- public void onEvent(final IEvent<?> event) {
- super.onEvent(event);
-
- if (event.getPayload() instanceof TreeNodeClickUpdate) {
- final TreeNodeClickUpdate update = (TreeNodeClickUpdate) event.getPayload();
-
- final GroupSummaryPanel summaryPanel = new GroupSummaryPanel.Builder("summaryPanel")
- .window(editGroupWin).callerPageRef(Groups.this.getPageReference())
- .selectedNodeId(update.getSelectedNodeId()).build();
-
- groupTabsContainer.addOrReplace(summaryPanel);
- update.getTarget().add(groupTabsContainer);
- }
- }
-
- public static class TreeNodeClickUpdate {
-
- private final AjaxRequestTarget target;
-
- private Long selectedNodeId;
-
- public TreeNodeClickUpdate(final AjaxRequestTarget target, final Long selectedNodeId) {
- this.target = target;
- this.selectedNodeId = selectedNodeId;
- }
-
- public AjaxRequestTarget getTarget() {
- return target;
- }
-
- public Long getSelectedNodeId() {
- return selectedNodeId;
- }
-
- public void setSelectedNodeId(final Long selectedNodeId) {
- this.selectedNodeId = selectedNodeId;
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/HomePage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/HomePage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/HomePage.java
index 7b4ba68..6fa6b16 100644
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/HomePage.java
+++ b/client/console/src/main/java/org/apache/syncope/client/console/pages/HomePage.java
@@ -18,16 +18,17 @@
*/
package org.apache.syncope.client.console.pages;
+import org.apache.syncope.client.console.SyncopeConsoleSession;
+import org.apache.wicket.markup.html.basic.Label;
import org.apache.wicket.request.mapper.parameter.PageParameters;
-/**
- * Syncope Home-Page.
- */
public class HomePage extends BasePage {
- private static final long serialVersionUID = -6712990478380766293L;
+ private static final long serialVersionUID = -1100228004207271270L;
public HomePage(final PageParameters parameters) {
super(parameters);
+
+ add(new Label("username", SyncopeConsoleSession.get().getSelfTO().getUsername()));
}
}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/InfoModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/InfoModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/InfoModalPage.java
deleted file mode 100644
index 83e0163..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/InfoModalPage.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.client.console.SyncopeSession;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.link.ExternalLink;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-public class InfoModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = 5558354927844399580L;
-
- @SpringBean(name = "site")
- private String siteUrl;
-
- @SpringBean(name = "license")
- private String licenseUrl;
-
- public InfoModalPage() {
- super();
-
- add(new ExternalLink("syncopeLink", siteUrl));
- add(new ExternalLink("licenseLink", licenseUrl));
- add(new Label("version", SyncopeSession.get().getVersion()));
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/Login.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/Login.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/Login.java
deleted file mode 100644
index deaa359..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/Login.java
+++ /dev/null
@@ -1,365 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.security.AccessControlException;
-import java.util.List;
-import java.util.Locale;
-import org.apache.commons.lang3.StringUtils;
-import org.apache.syncope.client.console.SyncopeSession;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.panels.NotificationPanel;
-import org.apache.syncope.client.console.rest.UserSelfRestClient;
-import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
-import org.apache.syncope.client.console.wicket.markup.html.form.LinkPanel;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.syncope.common.lib.wrap.EntitlementTO;
-import org.apache.syncope.common.rest.api.CollectionWrapper;
-import org.apache.syncope.common.rest.api.service.EntitlementService;
-import org.apache.wicket.Component;
-import org.apache.wicket.Page;
-import org.apache.wicket.ajax.AbstractDefaultAjaxBehavior;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.AjaxLink;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.head.IHeaderResponse;
-import org.apache.wicket.markup.head.JavaScriptHeaderItem;
-import org.apache.wicket.markup.html.WebPage;
-import org.apache.wicket.markup.html.basic.Label;
-import org.apache.wicket.markup.html.form.ChoiceRenderer;
-import org.apache.wicket.markup.html.form.DropDownChoice;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.markup.html.form.PasswordTextField;
-import org.apache.wicket.markup.html.form.StatelessForm;
-import org.apache.wicket.markup.html.form.TextField;
-import org.apache.wicket.markup.html.panel.Fragment;
-import org.apache.wicket.markup.html.panel.Panel;
-import org.apache.wicket.model.IModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.request.cycle.RequestCycle;
-import org.apache.wicket.request.mapper.parameter.PageParameters;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-
-/**
- * Syncope Login page.
- */
-public class Login extends WebPage {
-
- private static final long serialVersionUID = -3744389270366566218L;
-
- private final static int SELF_REG_WIN_HEIGHT = 550;
-
- private final static int SELF_REG_WIN_WIDTH = 800;
-
- private final static int PWD_RESET_WIN_HEIGHT = 300;
-
- private final static int PWD_RESET_WIN_WIDTH = 800;
-
- @SpringBean(name = "version")
- private String version;
-
- @SpringBean(name = "anonymousUser")
- private String anonymousUser;
-
- @SpringBean(name = "anonymousKey")
- private String anonymousKey;
-
- @SpringBean
- private UserSelfRestClient userSelfRestClient;
-
- private final StatelessForm<Void> form;
-
- private final TextField<String> userIdField;
-
- private final TextField<String> passwordField;
-
- private final DropDownChoice<Locale> languageSelect;
-
- private final NotificationPanel feedbackPanel;
-
- public Login(final PageParameters parameters) {
- super(parameters);
- setStatelessHint(true);
-
- feedbackPanel = new NotificationPanel(Constants.FEEDBACK);
- add(feedbackPanel);
-
- form = new StatelessForm<Void>("login");
-
- userIdField = new TextField<String>("userId", new Model<String>());
- userIdField.setMarkupId("userId");
- form.add(userIdField);
-
- passwordField = new PasswordTextField("password", new Model<String>());
- passwordField.setMarkupId("password");
- form.add(passwordField);
-
- languageSelect = new LocaleDropDown("language");
-
- form.add(languageSelect);
-
- AjaxButton submitButton = new AjaxButton("submit", new Model<String>(getString("submit"))) {
-
- private static final long serialVersionUID = 429178684321093953L;
-
- @Override
- protected void onSubmit(AjaxRequestTarget target, Form<?> form) {
- try {
- if (anonymousUser.equals(userIdField.getRawInput())) {
- throw new AccessControlException("Illegal username");
- }
-
- authenticate(userIdField.getRawInput(), passwordField.getRawInput());
-
- setResponsePage(WelcomePage.class, parameters);
- } catch (AccessControlException e) {
- error(getString("login-error"));
- feedbackPanel.refresh(target);
- SyncopeSession.get().resetClients();
- }
- }
- };
-
- submitButton.setDefaultFormProcessing(false);
- form.add(submitButton);
-
- add(form);
-
- // Modal window for self registration
- final ModalWindow selfRegModalWin = new ModalWindow("selfRegModal");
- selfRegModalWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- selfRegModalWin.setInitialHeight(SELF_REG_WIN_HEIGHT);
- selfRegModalWin.setInitialWidth(SELF_REG_WIN_WIDTH);
- selfRegModalWin.setCookieName("self-reg-modal");
- add(selfRegModalWin);
-
- Fragment selfRegFrag;
- if (userSelfRestClient.isSelfRegistrationAllowed()) {
- selfRegFrag = new Fragment("selfRegistration", "selfRegAllowed", this);
-
- final AjaxLink<Void> selfRegLink = new ClearIndicatingAjaxLink<Void>("link", getPageReference()) {
-
- private static final long serialVersionUID = -7978723352517770644L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- selfRegModalWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- // anonymous authentication needed for self-registration
- authenticate(anonymousUser, anonymousKey);
-
- return new UserSelfModalPage(Login.this.getPageReference(), selfRegModalWin, new UserTO());
- }
- });
-
- selfRegModalWin.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
-
- private static final long serialVersionUID = 251794406325329768L;
-
- @Override
- public void onClose(final AjaxRequestTarget target) {
- SyncopeSession.get().invalidate();
- }
- });
-
- selfRegModalWin.show(target);
- }
- };
- selfRegLink.add(new Label("linkTitle", getString("selfRegistration")));
-
- Panel panel = new LinkPanel("selfRegistration", new ResourceModel("selfRegistration"));
- panel.add(selfRegLink);
- selfRegFrag.add(panel);
- } else {
- selfRegFrag = new Fragment("selfRegistration", "selfRegNotAllowed", this);
- }
- add(selfRegFrag);
-
- // Modal window for password reset request
- final ModalWindow pwdResetReqModalWin = new ModalWindow("pwdResetReqModal");
- pwdResetReqModalWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- pwdResetReqModalWin.setInitialHeight(PWD_RESET_WIN_HEIGHT);
- pwdResetReqModalWin.setInitialWidth(PWD_RESET_WIN_WIDTH);
- pwdResetReqModalWin.setCookieName("pwd-reset-req-modal");
- add(pwdResetReqModalWin);
-
- Fragment pwdResetFrag;
- if (userSelfRestClient.isPasswordResetAllowed()) {
- pwdResetFrag = new Fragment("passwordReset", "pwdResetAllowed", this);
-
- final AjaxLink<Void> pwdResetLink = new ClearIndicatingAjaxLink<Void>("link", getPageReference()) {
-
- private static final long serialVersionUID = -6957616042924610290L;
-
- @Override
- protected void onClickInternal(final AjaxRequestTarget target) {
- pwdResetReqModalWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- // anonymous authentication needed for password reset request
- authenticate(anonymousUser, anonymousKey);
-
- return new RequestPasswordResetModalPage(pwdResetReqModalWin);
- }
- });
-
- pwdResetReqModalWin.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
-
- private static final long serialVersionUID = 8804221891699487139L;
-
- @Override
- public void onClose(final AjaxRequestTarget target) {
- SyncopeSession.get().invalidate();
- setResponsePage(Login.class);
- }
- });
-
- pwdResetReqModalWin.show(target);
- }
- };
- pwdResetLink.add(new Label("linkTitle", getString("passwordReset")));
-
- Panel panel = new LinkPanel("passwordReset", new ResourceModel("passwordReset"));
- panel.add(pwdResetLink);
- pwdResetFrag.add(panel);
- } else {
- pwdResetFrag = new Fragment("passwordReset", "pwdResetNotAllowed", this);
- }
- add(pwdResetFrag);
-
- // Modal window for password reset confirm - automatically shown when token is available as request parameter
- final String pwdResetToken = RequestCycle.get().getRequest().getRequestParameters().
- getParameterValue(Constants.PARAM_PASSWORD_RESET_TOKEN).toOptionalString();
- final ModalWindow pwdResetConfModalWin = new ModalWindow("pwdResetConfModal");
- if (StringUtils.isNotBlank(pwdResetToken)) {
- pwdResetConfModalWin.add(new AbstractDefaultAjaxBehavior() {
-
- private static final long serialVersionUID = 3109256773218160485L;
-
- @Override
- protected void respond(final AjaxRequestTarget target) {
- ModalWindow window = (ModalWindow) getComponent();
- window.show(target);
- }
-
- @Override
- public void renderHead(final Component component, final IHeaderResponse response) {
- response.render(JavaScriptHeaderItem.forScript(getCallbackScript(), null));
- }
- });
- }
- pwdResetConfModalWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
- pwdResetConfModalWin.setInitialHeight(PWD_RESET_WIN_HEIGHT);
- pwdResetConfModalWin.setInitialWidth(PWD_RESET_WIN_WIDTH);
- pwdResetConfModalWin.setCookieName("pwd-reset-conf-modal");
- pwdResetConfModalWin.setPageCreator(new ModalWindow.PageCreator() {
-
- private static final long serialVersionUID = -7834632442532690940L;
-
- @Override
- public Page createPage() {
- // anonymous authentication needed for password reset confirm
- authenticate(anonymousUser, anonymousKey);
-
- return new ConfirmPasswordResetModalPage(pwdResetConfModalWin, pwdResetToken);
- }
- });
- pwdResetConfModalWin.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
-
- private static final long serialVersionUID = 8804221891699487139L;
-
- @Override
- public void onClose(final AjaxRequestTarget target) {
- SyncopeSession.get().invalidate();
- setResponsePage(Login.class);
- }
- });
- add(pwdResetConfModalWin);
- }
-
- private void authenticate(final String username, final String password) {
- List<EntitlementTO> entitlements = SyncopeSession.get().
- getService(EntitlementService.class, username, password).getOwnEntitlements();
-
- SyncopeSession.get().setUsername(username);
- SyncopeSession.get().setPassword(password);
- SyncopeSession.get().setEntitlements(CollectionWrapper.unwrap(entitlements).toArray(new String[0]));
- SyncopeSession.get().setVersion(version);
- }
-
- /**
- * Inner class which implements (custom) Locale DropDownChoice component.
- */
- private class LocaleDropDown extends DropDownChoice<Locale> {
-
- private static final long serialVersionUID = 2349382679992357202L;
-
- private class LocaleRenderer extends ChoiceRenderer<Locale> {
-
- private static final long serialVersionUID = -3657529581555164741L;
-
- @Override
- public String getDisplayValue(final Locale locale) {
- return locale.getDisplayName(getLocale());
- }
- }
-
- public LocaleDropDown(final String id) {
- super(id, SyncopeSession.SUPPORTED_LOCALES);
-
- setChoiceRenderer(new LocaleRenderer());
- setModel(new IModel<Locale>() {
-
- private static final long serialVersionUID = -6985170095629312963L;
-
- @Override
- public Locale getObject() {
- return getSession().getLocale();
- }
-
- @Override
- public void setObject(final Locale object) {
- getSession().setLocale(object);
- }
-
- @Override
- public void detach() {
- // Empty.
- }
- });
-
- // set default value to English
- getModel().setObject(Locale.ENGLISH);
- }
-
- @Override
- protected boolean wantOnSelectionChangedNotifications() {
- return true;
- }
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/Logout.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/Logout.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/Logout.java
deleted file mode 100644
index acf313b..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/Logout.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.client.console.SyncopeSession;
-import org.apache.wicket.request.mapper.parameter.PageParameters;
-
-/**
- * Syncope Logout.
- */
-public class Logout extends BasePage {
-
- private static final long serialVersionUID = -2143007520243939450L;
-
- public Logout(final PageParameters parameters) {
- super(parameters);
-
- SyncopeSession.get().invalidate();
-
- setResponsePage(getApplication().getHomePage());
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/MembershipModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/MembershipModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/MembershipModalPage.java
deleted file mode 100644
index f2e2189..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/MembershipModalPage.java
+++ /dev/null
@@ -1,114 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import org.apache.syncope.client.console.commons.Mode;
-import org.apache.syncope.client.console.panels.AnnotatedBeanPanel;
-import org.apache.syncope.client.console.panels.DerAttrsPanel;
-import org.apache.syncope.client.console.panels.PlainAttrsPanel;
-import org.apache.syncope.client.console.panels.VirAttrsPanel;
-import org.apache.syncope.common.lib.to.MembershipTO;
-import org.apache.syncope.common.lib.to.UserTO;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.ResourceModel;
-
-public class MembershipModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = -4360802478081432549L;
-
- private final AjaxButton submit;
-
- public MembershipModalPage(final PageReference pageRef, final ModalWindow window, final MembershipTO membershipTO,
- final Mode mode) {
-
- final Form<MembershipTO> form = new Form<MembershipTO>("MembershipForm");
-
- final UserTO userTO = ((UserModalPage) pageRef.getPage()).getUserTO();
-
- form.setModel(new CompoundPropertyModel<MembershipTO>(membershipTO));
-
- submit = new AjaxButton(SUBMIT, new ResourceModel(SUBMIT)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form form) {
- userTO.getMemberships().remove(membershipTO);
- userTO.getMemberships().add(membershipTO);
-
- ((UserModalPage) pageRef.getPage()).setUserTO(userTO);
-
- window.close(target);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
-
- form.add(submit);
- form.setDefaultButton(submit);
-
- final IndicatingAjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- ((UserModalPage) pageRef.getPage()).setUserTO(userTO);
- window.close(target);
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- }
- };
-
- cancel.setDefaultFormProcessing(false);
- form.add(cancel);
-
- //--------------------------------
- // Attributes panel
- //--------------------------------
- form.add(new PlainAttrsPanel("plainAttrs", membershipTO, form, mode));
- form.add(new AnnotatedBeanPanel("systeminformation", membershipTO));
- //--------------------------------
-
- //--------------------------------
- // Derived attributes container
- //--------------------------------
- form.add(new DerAttrsPanel("derAttrs", membershipTO));
- //--------------------------------
-
- //--------------------------------
- // Virtual attributes container
- //--------------------------------
- form.add(new VirAttrsPanel("virAttrs", membershipTO, mode == Mode.TEMPLATE));
- //--------------------------------
-
- add(form);
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/NotificationModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/NotificationModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/NotificationModalPage.java
deleted file mode 100644
index 98d8862..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/NotificationModalPage.java
+++ /dev/null
@@ -1,441 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collections;
-import java.util.EnumSet;
-import java.util.List;
-import org.apache.syncope.client.console.commons.Constants;
-import org.apache.syncope.client.console.panels.LoggerCategoryPanel;
-import org.apache.syncope.client.console.panels.GroupSearchPanel;
-import org.apache.syncope.client.console.panels.UserSearchPanel;
-import org.apache.syncope.client.console.rest.LoggerRestClient;
-import org.apache.syncope.client.console.rest.NotificationRestClient;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxDropDownChoicePanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.client.console.wicket.markup.html.form.MultiFieldPanel;
-import org.apache.syncope.common.lib.SyncopeClientException;
-import org.apache.syncope.common.lib.to.NotificationTO;
-import org.apache.syncope.common.lib.types.AttributableType;
-import org.apache.syncope.common.lib.types.IntMappingType;
-import org.apache.syncope.common.lib.types.TraceLevel;
-import org.apache.wicket.PageReference;
-import org.apache.wicket.ajax.AjaxRequestTarget;
-import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
-import org.apache.wicket.ajax.markup.html.form.AjaxButton;
-import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
-import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
-import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
-import org.apache.wicket.markup.html.WebMarkupContainer;
-import org.apache.wicket.markup.html.form.Form;
-import org.apache.wicket.model.CompoundPropertyModel;
-import org.apache.wicket.model.Model;
-import org.apache.wicket.model.PropertyModel;
-import org.apache.wicket.model.ResourceModel;
-import org.apache.wicket.spring.injection.annot.SpringBean;
-import org.apache.wicket.validation.validator.EmailAddressValidator;
-
-class NotificationModalPage extends BaseModalPage {
-
- private static final long serialVersionUID = -1975312550059578553L;
-
- @SpringBean
- private NotificationRestClient restClient;
-
- @SpringBean
- private LoggerRestClient loggerRestClient;
-
- public NotificationModalPage(final PageReference pageRef, final ModalWindow window,
- final NotificationTO notificationTO, final boolean createFlag) {
-
- final Form<NotificationTO> form =
- new Form<NotificationTO>(FORM, new CompoundPropertyModel<NotificationTO>(notificationTO));
-
- final AjaxTextFieldPanel sender = new AjaxTextFieldPanel("sender", getString("sender"),
- new PropertyModel<String>(notificationTO, "sender"));
- sender.addRequiredLabel();
- sender.addValidator(EmailAddressValidator.getInstance());
- form.add(sender);
-
- final AjaxTextFieldPanel subject = new AjaxTextFieldPanel("subject", getString("subject"),
- new PropertyModel<String>(notificationTO, "subject"));
- subject.addRequiredLabel();
- form.add(subject);
-
- final AjaxDropDownChoicePanel<String> template = new AjaxDropDownChoicePanel<String>(
- "template", getString("template"),
- new PropertyModel<String>(notificationTO, "template"));
- template.setChoices(confRestClient.getMailTemplates());
- template.addRequiredLabel();
- form.add(template);
-
- final AjaxDropDownChoicePanel<TraceLevel> traceLevel = new AjaxDropDownChoicePanel<TraceLevel>(
- "traceLevel", getString("traceLevel"),
- new PropertyModel<TraceLevel>(notificationTO, "traceLevel"));
- traceLevel.setChoices(Arrays.asList(TraceLevel.values()));
- traceLevel.addRequiredLabel();
- form.add(traceLevel);
-
- final AjaxCheckBoxPanel isActive = new AjaxCheckBoxPanel("isActive",
- getString("isActive"), new PropertyModel<Boolean>(notificationTO, "active"));
- if (createFlag) {
- isActive.getField().setDefaultModelObject(Boolean.TRUE);
- }
- form.add(isActive);
-
- final WebMarkupContainer aboutContainer = new WebMarkupContainer("aboutContainer");
- aboutContainer.setOutputMarkupId(true);
-
- form.add(aboutContainer);
-
- final AjaxCheckBoxPanel checkAbout = new AjaxCheckBoxPanel("checkAbout", "checkAbout", new Model<Boolean>(
- notificationTO.getUserAbout() == null && notificationTO.getGroupAbout() == null));
- aboutContainer.add(checkAbout);
-
- final AjaxCheckBoxPanel checkUserAbout = new AjaxCheckBoxPanel("checkUserAbout", "checkUserAbout",
- new Model<Boolean>(notificationTO.getUserAbout() != null));
- aboutContainer.add(checkUserAbout);
-
- final AjaxCheckBoxPanel checkGroupAbout = new AjaxCheckBoxPanel("checkGroupAbout", "checkGroupAbout",
- new Model<Boolean>(notificationTO.getGroupAbout() != null));
- aboutContainer.add(checkGroupAbout);
-
- final UserSearchPanel userAbout =
- new UserSearchPanel.Builder("userAbout").fiql(notificationTO.getUserAbout()).build();
- aboutContainer.add(userAbout);
- userAbout.setEnabled(checkUserAbout.getModelObject());
-
- final GroupSearchPanel groupAbout =
- new GroupSearchPanel.Builder("groupAbout").fiql(notificationTO.getGroupAbout()).build();
- aboutContainer.add(groupAbout);
- groupAbout.setEnabled(checkGroupAbout.getModelObject());
-
- checkAbout.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- if (checkAbout.getModelObject()) {
- checkUserAbout.setModelObject(Boolean.FALSE);
- checkGroupAbout.setModelObject(Boolean.FALSE);
- userAbout.setEnabled(Boolean.FALSE);
- groupAbout.setEnabled(Boolean.FALSE);
- } else {
- checkAbout.setModelObject(Boolean.TRUE);
- }
- target.add(aboutContainer);
- }
- });
-
- checkUserAbout.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- if (checkUserAbout.getModelObject()) {
- checkAbout.setModelObject(!checkUserAbout.getModelObject());
- checkGroupAbout.setModelObject(!checkUserAbout.getModelObject());
- groupAbout.setEnabled(Boolean.FALSE);
- } else {
- checkUserAbout.setModelObject(Boolean.TRUE);
- }
- userAbout.setEnabled(Boolean.TRUE);
- target.add(aboutContainer);
- }
- });
-
- checkGroupAbout.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- if (checkGroupAbout.getModelObject()) {
- checkAbout.setModelObject(Boolean.FALSE);
- checkUserAbout.setModelObject(Boolean.FALSE);
- userAbout.setEnabled(Boolean.FALSE);
- } else {
- checkGroupAbout.setModelObject(Boolean.TRUE);
- }
- groupAbout.setEnabled(Boolean.TRUE);
- target.add(aboutContainer);
- }
- });
-
- final AjaxDropDownChoicePanel<IntMappingType> recipientAttrType = new AjaxDropDownChoicePanel<IntMappingType>(
- "recipientAttrType", new ResourceModel("recipientAttrType", "recipientAttrType").getObject(),
- new PropertyModel<IntMappingType>(notificationTO, "recipientAttrType"));
- recipientAttrType.setChoices(new ArrayList<IntMappingType>(
- IntMappingType.getAttributeTypes(AttributableType.USER,
- EnumSet.of(IntMappingType.UserId, IntMappingType.Password))));
- recipientAttrType.addRequiredLabel();
- form.add(recipientAttrType);
-
- final AjaxDropDownChoicePanel<String> recipientAttrName = new AjaxDropDownChoicePanel<String>(
- "recipientAttrName", new ResourceModel("recipientAttrName", "recipientAttrName").getObject(),
- new PropertyModel<String>(notificationTO, "recipientAttrName"));
- recipientAttrName.setChoices(getSchemaNames(recipientAttrType.getModelObject()));
- recipientAttrName.addRequiredLabel();
- form.add(recipientAttrName);
-
- recipientAttrType.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- recipientAttrName.setChoices(getSchemaNames(recipientAttrType.getModelObject()));
- target.add(recipientAttrName);
- }
- });
-
- form.add(new LoggerCategoryPanel(
- "eventSelection",
- loggerRestClient.listEvents(),
- new PropertyModel<List<String>>(notificationTO, "events"),
- getPageReference(),
- "Notification") {
-
- private static final long serialVersionUID = 6429053774964787735L;
-
- @Override
- protected String[] getListRoles() {
- return new String[] {};
- }
-
- @Override
- protected String[] getChangeRoles() {
- return new String[] {};
- }
- });
-
- final WebMarkupContainer recipientsContainer = new WebMarkupContainer("recipientsContainer");
- recipientsContainer.setOutputMarkupId(true);
-
- form.add(recipientsContainer);
-
- final AjaxCheckBoxPanel checkStaticRecipients = new AjaxCheckBoxPanel("checkStaticRecipients",
- "recipients", new Model<Boolean>(!notificationTO.getStaticRecipients().isEmpty()));
- form.add(checkStaticRecipients);
-
- if (createFlag) {
- checkStaticRecipients.getField().setDefaultModelObject(Boolean.FALSE);
- }
-
- final AjaxTextFieldPanel staticRecipientsFieldPanel =
- new AjaxTextFieldPanel("panel", "staticRecipients", new Model<String>(null));
- staticRecipientsFieldPanel.addValidator(EmailAddressValidator.getInstance());
- staticRecipientsFieldPanel.setRequired(checkStaticRecipients.getModelObject());
-
- if (notificationTO.getStaticRecipients().isEmpty()) {
- notificationTO.getStaticRecipients().add(null);
- }
-
- final MultiFieldPanel<String> staticRecipients = new MultiFieldPanel<String>("staticRecipients",
- new PropertyModel<List<String>>(notificationTO, "staticRecipients"), staticRecipientsFieldPanel);
- staticRecipients.setEnabled(checkStaticRecipients.getModelObject());
- form.add(staticRecipients);
-
- final AjaxCheckBoxPanel checkRecipients =
- new AjaxCheckBoxPanel("checkRecipients", "checkRecipients",
- new Model<Boolean>(notificationTO.getRecipients() == null ? false : true));
- recipientsContainer.add(checkRecipients);
-
- if (createFlag) {
- checkRecipients.getField().setDefaultModelObject(Boolean.TRUE);
- }
-
- final UserSearchPanel recipients =
- new UserSearchPanel.Builder("recipients").fiql(notificationTO.getRecipients()).build();
-
- recipients.setEnabled(checkRecipients.getModelObject());
- recipientsContainer.add(recipients);
-
- final AjaxCheckBoxPanel selfAsRecipient = new AjaxCheckBoxPanel("selfAsRecipient",
- getString("selfAsRecipient"), new PropertyModel<Boolean>(notificationTO, "selfAsRecipient"));
- form.add(selfAsRecipient);
-
- if (createFlag) {
- selfAsRecipient.getField().setDefaultModelObject(Boolean.FALSE);
- }
-
- selfAsRecipient.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- if (!selfAsRecipient.getModelObject()
- && !checkRecipients.getModelObject()
- && !checkStaticRecipients.getModelObject()) {
-
- checkRecipients.getField().setDefaultModelObject(Boolean.TRUE);
- target.add(checkRecipients);
- recipients.setEnabled(checkRecipients.getModelObject());
- target.add(recipients);
- target.add(recipientsContainer);
- }
- }
- });
-
- checkRecipients.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- if (!checkRecipients.getModelObject()
- && !selfAsRecipient.getModelObject()
- && !checkStaticRecipients.getModelObject()) {
-
- checkStaticRecipients.getField().setDefaultModelObject(Boolean.TRUE);
- target.add(checkStaticRecipients);
- staticRecipients.setEnabled(Boolean.TRUE);
- target.add(staticRecipients);
- staticRecipientsFieldPanel.setRequired(Boolean.TRUE);
- target.add(staticRecipientsFieldPanel);
- }
- recipients.setEnabled(checkRecipients.getModelObject());
- target.add(recipients);
- target.add(recipientsContainer);
- }
- });
-
- checkStaticRecipients.getField().add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
-
- private static final long serialVersionUID = -1107858522700306810L;
-
- @Override
- protected void onUpdate(final AjaxRequestTarget target) {
- if (!checkStaticRecipients.getModelObject()
- && !selfAsRecipient.getModelObject()
- && !checkRecipients.getModelObject()) {
- checkRecipients.getField().setDefaultModelObject(Boolean.TRUE);
- checkRecipients.setEnabled(Boolean.TRUE);
- target.add(checkRecipients);
- }
- staticRecipients.setEnabled(checkStaticRecipients.getModelObject());
- staticRecipientsFieldPanel.setRequired(checkStaticRecipients.getModelObject());
- recipients.setEnabled(checkRecipients.getModelObject());
- target.add(staticRecipientsFieldPanel);
- target.add(staticRecipients);
- target.add(recipients);
- target.add(recipientsContainer);
- }
- });
-
- AjaxButton submit = new IndicatingAjaxButton(APPLY, new Model<String>(getString(SUBMIT))) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- notificationTO.setUserAbout(
- !checkAbout.getModelObject() && checkUserAbout.getModelObject() ? userAbout.buildFIQL() : null);
- notificationTO.setGroupAbout(
- !checkAbout.getModelObject()
- && checkGroupAbout.getModelObject() ? groupAbout.buildFIQL() : null);
- notificationTO.setRecipients(checkRecipients.getModelObject() ? recipients.buildFIQL() : null);
- notificationTO.getStaticRecipients().removeAll(Collections.singleton(null));
-
- try {
- if (createFlag) {
- restClient.create(notificationTO);
- } else {
- restClient.update(notificationTO);
- }
- info(getString(Constants.OPERATION_SUCCEEDED));
-
- Configuration callerPage = (Configuration) pageRef.getPage();
- callerPage.setModalResult(true);
-
- window.close(target);
- } catch (SyncopeClientException scee) {
- error(getString(Constants.ERROR) + ": " + scee.getMessage());
- feedbackPanel.refresh(target);
- }
- }
-
- @Override
- protected void onError(final AjaxRequestTarget target, final Form<?> form) {
- feedbackPanel.refresh(target);
- }
- };
-
- final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
-
- private static final long serialVersionUID = -958724007591692537L;
-
- @Override
- protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
- window.close(target);
- }
- };
-
- cancel.setDefaultFormProcessing(false);
-
- String allowedRoles = createFlag
- ? xmlRolesReader.getEntitlement("Notification", "create")
- : xmlRolesReader.getEntitlement("Notification", "update");
- MetaDataRoleAuthorizationStrategy.authorize(submit, ENABLE, allowedRoles);
-
- form.add(submit);
- form.setDefaultButton(submit);
-
- form.add(cancel);
-
- add(form);
- }
-
- private List<String> getSchemaNames(final IntMappingType type) {
- final List<String> result;
-
- if (type == null) {
- result = Collections.<String>emptyList();
- } else {
- switch (type) {
- case UserPlainSchema:
- result = schemaRestClient.getPlainSchemaNames(AttributableType.USER);
- break;
-
- case UserDerivedSchema:
- result = schemaRestClient.getDerSchemaNames(AttributableType.USER);
- break;
-
- case UserVirtualSchema:
- result = schemaRestClient.getVirSchemaNames(AttributableType.USER);
- break;
-
- case Username:
- result = Collections.singletonList("Username");
- break;
-
- default:
- result = Collections.<String>emptyList();
- }
- }
-
- return result;
- }
-}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/console/src/main/java/org/apache/syncope/client/console/pages/NotificationTaskModalPage.java
----------------------------------------------------------------------
diff --git a/client/console/src/main/java/org/apache/syncope/client/console/pages/NotificationTaskModalPage.java b/client/console/src/main/java/org/apache/syncope/client/console/pages/NotificationTaskModalPage.java
deleted file mode 100644
index 70f63d6..0000000
--- a/client/console/src/main/java/org/apache/syncope/client/console/pages/NotificationTaskModalPage.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.syncope.client.console.pages;
-
-import java.util.ArrayList;
-import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
-import org.apache.syncope.common.lib.to.AbstractTaskTO;
-import org.apache.syncope.common.lib.to.NotificationTaskTO;
-import org.apache.wicket.markup.html.form.ListMultipleChoice;
-import org.apache.wicket.markup.html.form.TextArea;
-import org.apache.wicket.model.PropertyModel;
-
-public class NotificationTaskModalPage extends TaskModalPage {
-
- private static final long serialVersionUID = -4399606755452034216L;
-
- public NotificationTaskModalPage(final AbstractTaskTO taskTO) {
- super(taskTO);
-
- final AjaxTextFieldPanel sender = new AjaxTextFieldPanel("sender", getString("sender"),
- new PropertyModel<String>(taskTO, "sender"));
- sender.setEnabled(false);
- profile.add(sender);
-
- if (taskTO instanceof NotificationTaskTO) {
- final ListMultipleChoice<String> recipients = new ListMultipleChoice<>("recipients",
- new ArrayList<>(((NotificationTaskTO) taskTO).getRecipients()));
- recipients.setMaxRows(5);
- recipients.setEnabled(false);
- profile.add(recipients);
- }
-
- final AjaxTextFieldPanel subject = new AjaxTextFieldPanel("subject", getString("subject"),
- new PropertyModel<String>(taskTO, "subject"));
- subject.setEnabled(false);
- profile.add(subject);
-
- final TextArea<String> textBody = new TextArea<String>("textBody",
- new PropertyModel<String>(taskTO, "textBody"));
- textBody.setEnabled(false);
- profile.add(textBody);
-
- final TextArea<String> htmlBody = new TextArea<String>("htmlBody",
- new PropertyModel<String>(taskTO, "htmlBody"));
- htmlBody.setEnabled(false);
- profile.add(htmlBody);
-
- final AjaxTextFieldPanel traceLevel = new AjaxTextFieldPanel("traceLevel", getString("traceLevel"),
- new PropertyModel<String>(taskTO, "traceLevel"));
- traceLevel.setEnabled(false);
- profile.add(traceLevel);
- }
-}
[24/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/PreferenceManager.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/PreferenceManager.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/PreferenceManager.java
new file mode 100644
index 0000000..a4e246e
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/PreferenceManager.java
@@ -0,0 +1,176 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import com.fasterxml.jackson.databind.ObjectMapper;
+import com.fasterxml.jackson.core.type.TypeReference;
+import java.io.IOException;
+import java.io.StringWriter;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import org.apache.commons.lang3.math.NumberUtils;
+import org.apache.wicket.request.Request;
+import org.apache.wicket.request.Response;
+import org.apache.wicket.util.cookies.CookieDefaults;
+import org.apache.wicket.util.cookies.CookieUtils;
+import org.apache.wicket.util.crypt.Base64;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.util.StringUtils;
+
+public class PreferenceManager {
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(PreferenceManager.class);
+
+ private static final String PREFMAN_KEY = "prefMan";
+
+ private static final int ONE_YEAR_TIME = 60 * 60 * 24 * 365;
+
+ private static final TypeReference<Map<String, String>> MAP_TYPE_REF = new TypeReference<Map<String, String>>() {
+ };
+
+ private static final List<Integer> PAGINATOR_CHOICES = Arrays.asList(new Integer[] { 10, 25, 50 });
+
+ private final ObjectMapper mapper;
+
+ private final CookieUtils cookieUtils;
+
+ public PreferenceManager() {
+ this.mapper = new ObjectMapper();
+
+ CookieDefaults cookieDefaults = new CookieDefaults();
+ cookieDefaults.setMaxAge(ONE_YEAR_TIME);
+ this.cookieUtils = new CookieUtils(cookieDefaults);
+ }
+
+ public List<Integer> getPaginatorChoices() {
+ return PAGINATOR_CHOICES;
+ }
+
+ private Map<String, String> getPrefs(final String value) {
+ Map<String, String> prefs;
+ try {
+ if (StringUtils.hasText(value)) {
+ prefs = mapper.readValue(value, MAP_TYPE_REF);
+ } else {
+ throw new Exception("Invalid cookie value '" + value + "'");
+ }
+ } catch (Exception e) {
+ LOG.debug("No preferences found", e);
+ prefs = new HashMap<String, String>();
+ }
+
+ return prefs;
+ }
+
+ private String setPrefs(final Map<String, String> prefs) throws IOException {
+ StringWriter writer = new StringWriter();
+ mapper.writeValue(writer, prefs);
+
+ return writer.toString();
+ }
+
+ public String get(final Request request, final String key) {
+ String result = null;
+
+ String prefString = cookieUtils.load(PREFMAN_KEY);
+ if (prefString != null) {
+ final Map<String, String> prefs = getPrefs(new String(Base64.decodeBase64(prefString.getBytes())));
+ result = prefs.get(key);
+ }
+
+ return result;
+ }
+
+ public Integer getPaginatorRows(final Request request, final String key) {
+ Integer result = getPaginatorChoices().get(0);
+
+ String value = get(request, key);
+ if (value != null) {
+ result = NumberUtils.toInt(value, 10);
+ }
+
+ return result;
+ }
+
+ public List<String> getList(final Request request, final String key) {
+ final List<String> result = new ArrayList<String>();
+
+ final String compound = get(request, key);
+
+ if (StringUtils.hasText(compound)) {
+ String[] items = compound.split(";");
+ result.addAll(Arrays.asList(items));
+ }
+
+ return result;
+ }
+
+ public void set(final Request request, final Response response, final Map<String, List<String>> prefs) {
+ Map<String, String> current = new HashMap<>();
+
+ String prefString = cookieUtils.load(PREFMAN_KEY);
+ if (prefString != null) {
+ current.putAll(getPrefs(new String(Base64.decodeBase64(prefString.getBytes()))));
+ }
+
+ // after retrieved previous setting in order to overwrite the key ...
+ for (Map.Entry<String, List<String>> entry : prefs.entrySet()) {
+ current.put(entry.getKey(), StringUtils.collectionToDelimitedString(entry.getValue(), ";"));
+ }
+
+ try {
+ cookieUtils.save(PREFMAN_KEY, new String(Base64.encodeBase64(setPrefs(current).getBytes())));
+ } catch (IOException e) {
+ LOG.error("Could not save {} info: {}", getClass().getSimpleName(), current, e);
+ }
+ }
+
+ public void set(final Request request, final Response response, final String key, final String value) {
+ String prefString = cookieUtils.load(PREFMAN_KEY);
+
+ final Map<String, String> current = new HashMap<>();
+ if (prefString != null) {
+ current.putAll(getPrefs(new String(Base64.decodeBase64(prefString.getBytes()))));
+ }
+
+ // after retrieved previous setting in order to overwrite the key ...
+ current.put(key, value);
+
+ try {
+ cookieUtils.save(PREFMAN_KEY, new String(Base64.encodeBase64(setPrefs(current).getBytes())));
+ } catch (IOException e) {
+ LOG.error("Could not save {} info: {}", getClass().getSimpleName(), current, e);
+ }
+ }
+
+ public void setList(final Request request, final Response response, final String key, final List<String> values) {
+ set(request, response, key, StringUtils.collectionToDelimitedString(values, ";"));
+ }
+
+ public void setList(final Request request, final Response response, final Map<String, List<String>> prefs) {
+ set(request, response, prefs);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/PreviewUtils.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/PreviewUtils.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/PreviewUtils.java
new file mode 100644
index 0000000..12c93d4
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/PreviewUtils.java
@@ -0,0 +1,62 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import java.lang.reflect.InvocationTargetException;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.init.ImplementationClassNamesLoader;
+import org.apache.syncope.client.console.wicket.markup.html.form.preview.AbstractBinaryPreviewer;
+import org.apache.wicket.Component;
+import org.apache.wicket.util.crypt.Base64;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.util.ClassUtils;
+
+@org.springframework.stereotype.Component
+public class PreviewUtils {
+
+ @Autowired
+ private ImplementationClassNamesLoader implementationClassNamesLoader;
+
+ public Component getPreviewer(final String mimeType, final String file)
+ throws InstantiationException, IllegalAccessException, InvocationTargetException {
+
+ final Class<? extends AbstractBinaryPreviewer> previewer = StringUtils.isBlank(file)
+ ? null
+ : implementationClassNamesLoader.getPreviewerClass(mimeType);
+
+ return previewer == null
+ ? null
+ : ClassUtils.getConstructorIfAvailable(previewer, String.class, String.class, byte[].class).
+ newInstance(new Object[] { "previewer", mimeType, Base64.decodeBase64(file) }).
+ preview();
+ }
+
+ public Component getPreviewer(final String mimeType, final byte[] file)
+ throws InstantiationException, IllegalAccessException, InvocationTargetException {
+
+ final Class<? extends AbstractBinaryPreviewer> previewer =
+ implementationClassNamesLoader.getPreviewerClass(mimeType);
+
+ return previewer == null
+ ? null
+ : ClassUtils.getConstructorIfAvailable(previewer, String.class, String.class, byte[].class).
+ newInstance(new Object[] { "previewer", mimeType, file }).
+ preview();
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SchemaModalPageFactory.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SchemaModalPageFactory.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SchemaModalPageFactory.java
new file mode 100644
index 0000000..38a60fa
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SchemaModalPageFactory.java
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import org.apache.syncope.client.console.pages.AbstractSchemaModalPage;
+import org.apache.syncope.client.console.pages.DerSchemaModalPage;
+import org.apache.syncope.client.console.pages.PlainSchemaModalPage;
+import org.apache.syncope.client.console.pages.VirSchemaModalPage;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.syncope.common.lib.types.SchemaType;
+
+public final class SchemaModalPageFactory {
+
+ private static final long serialVersionUID = -3533177688264693505L;
+
+ private SchemaModalPageFactory() {
+ // empty constructor for static utility class
+ }
+
+ @SuppressWarnings("unchecked")
+ public static <T extends AbstractSchemaModalPage> T getSchemaModalPage(
+ final AttributableType entity, final SchemaType schemaType) {
+
+ T page;
+
+ switch (schemaType) {
+ case DERIVED:
+ page = (T) new DerSchemaModalPage(entity);
+ break;
+
+ case VIRTUAL:
+ page = (T) new VirSchemaModalPage(entity);
+ break;
+
+ default:
+ page = (T) new PlainSchemaModalPage(entity);
+ break;
+ }
+
+ return page;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SelectChoiceRenderer.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SelectChoiceRenderer.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SelectChoiceRenderer.java
new file mode 100644
index 0000000..7b9164d
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SelectChoiceRenderer.java
@@ -0,0 +1,40 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import org.apache.wicket.markup.html.form.IChoiceRenderer;
+
+public class SelectChoiceRenderer<T> implements IChoiceRenderer<T> {
+
+ private static final long serialVersionUID = -3242441544405909243L;
+
+ @Override
+ public Object getDisplayValue(T obj) {
+ if (obj instanceof SelectOption) {
+ return ((SelectOption) obj).getDisplayValue();
+ } else {
+ return obj.toString();
+ }
+ }
+
+ @Override
+ public String getIdValue(T obj, int i) {
+ return obj.toString();
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SelectOption.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SelectOption.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SelectOption.java
new file mode 100644
index 0000000..839df70
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SelectOption.java
@@ -0,0 +1,72 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import java.io.Serializable;
+import org.apache.commons.lang3.builder.HashCodeBuilder;
+
+public class SelectOption implements Serializable {
+
+ private static final long serialVersionUID = 2961127533930849828L;
+
+ private String displayValue;
+
+ private String keyValue;
+
+ public SelectOption(final String displayValue, final String keyValue) {
+ this.displayValue = displayValue;
+ this.keyValue = keyValue;
+ }
+
+ public String getDisplayValue() {
+ return displayValue;
+ }
+
+ public void setDisplayValue(final String displayValue) {
+ this.displayValue = displayValue;
+ }
+
+ public String getKeyValue() {
+ return keyValue;
+ }
+
+ public void setKeyValue(final String keyValue) {
+ this.keyValue = keyValue;
+ }
+
+ @Override
+ public boolean equals(final Object obj) {
+ if (obj == null || !(obj instanceof SelectOption)) {
+ return false;
+ }
+
+ return (keyValue == null && ((SelectOption) obj).keyValue == null) || keyValue != null
+ && keyValue.equals(((SelectOption) obj).keyValue);
+ }
+
+ @Override
+ public int hashCode() {
+ return HashCodeBuilder.reflectionHashCode(this);
+ }
+
+ @Override
+ public String toString() {
+ return keyValue;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SortableAttributableProviderComparator.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SortableAttributableProviderComparator.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SortableAttributableProviderComparator.java
new file mode 100644
index 0000000..e82b9bb
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SortableAttributableProviderComparator.java
@@ -0,0 +1,122 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import java.util.Arrays;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.to.AttrTO;
+import org.apache.syncope.common.lib.types.SchemaType;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
+import org.apache.wicket.model.AbstractReadOnlyModel;
+
+public class SortableAttributableProviderComparator extends SortableDataProviderComparator<AbstractAttributableTO> {
+
+ private static final long serialVersionUID = 1775967163571699258L;
+
+ private static final Set<String> INLINE_PROPS = new HashSet<>(Arrays.asList(
+ new String[] { "key", "status", "token", "username" }));
+
+ public SortableAttributableProviderComparator(final SortableDataProvider<AbstractAttributableTO, String> provider) {
+ super(provider);
+ }
+
+ @Override
+ public int compare(final AbstractAttributableTO attributable1, AbstractAttributableTO attributable2) {
+ if (INLINE_PROPS.contains(provider.getSort().getProperty())) {
+ return super.compare(attributable1, attributable2);
+ }
+
+ return super.compare(new AttrModel(attributable1), new AttrModel(attributable2));
+ }
+
+ @SuppressWarnings("rawtypes")
+ private class AttrModel extends AbstractReadOnlyModel<Comparable> {
+
+ private static final long serialVersionUID = -7856686374020091808L;
+
+ private final Map<String, AttrTO> attrs;
+
+ private final Map<String, AttrTO> derAttrs;
+
+ private final Map<String, AttrTO> virAttrs;
+
+ public AttrModel(final AbstractAttributableTO attributableTO) {
+ super();
+
+ this.attrs = attributableTO.getPlainAttrMap();
+ this.derAttrs = attributableTO.getDerAttrMap();
+ this.virAttrs = attributableTO.getVirAttrMap();
+ }
+
+ /**
+ * @see UserAttrColumn constructor
+ */
+ @Override
+ public Comparable getObject() {
+ int hashPos = provider.getSort().getProperty().indexOf('#');
+
+ SchemaType schemaType = null;
+ final String schema;
+ if (hashPos == -1) {
+ schema = provider.getSort().getProperty();
+ } else {
+ String[] splitted = provider.getSort().getProperty().split("#");
+ try {
+ schemaType = SchemaType.valueOf(splitted[0]);
+ } catch (IllegalArgumentException e) {
+ // this should never happen
+ }
+ schema = provider.getSort().getProperty().substring(hashPos + 1);
+ }
+
+ final AttrTO attr;
+ if (schemaType == null) {
+ attr = this.attrs.get(schema);
+ } else {
+ switch (schemaType) {
+ case PLAIN:
+ default:
+ attr = this.attrs.get(schema);
+ break;
+
+ case DERIVED:
+ attr = this.derAttrs.get(schema);
+ break;
+
+ case VIRTUAL:
+ attr = this.virAttrs.get(schema);
+ break;
+ }
+ }
+
+ Comparable result = null;
+
+ List<String> values = attr == null ? null : attr.getValues();
+ if (values != null && !values.isEmpty()) {
+ result = values.iterator().next();
+ }
+
+ return result;
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SortableDataProviderComparator.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SortableDataProviderComparator.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SortableDataProviderComparator.java
new file mode 100644
index 0000000..bc4357d
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/SortableDataProviderComparator.java
@@ -0,0 +1,66 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import java.io.Serializable;
+import java.util.Comparator;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.PropertyModel;
+
+public class SortableDataProviderComparator<T> implements Comparator<T>, Serializable {
+
+ private static final long serialVersionUID = -8897687699977460543L;
+
+ protected final SortableDataProvider<T, String> provider;
+
+ public SortableDataProviderComparator(final SortableDataProvider<T, String> provider) {
+ this.provider = provider;
+ }
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ protected int compare(final IModel<Comparable> model1, final IModel<Comparable> model2) {
+ int result;
+
+ if (model1.getObject() == null && model2.getObject() == null) {
+ result = 0;
+ } else if (model1.getObject() == null) {
+ result = 1;
+ } else if (model2.getObject() == null) {
+ result = -1;
+ } else {
+ result = model1.getObject().compareTo(model2.getObject());
+ }
+
+ result = provider.getSort().isAscending()
+ ? result
+ : -result;
+
+ return result;
+ }
+
+ @SuppressWarnings("rawtypes")
+ @Override
+ public int compare(final T object1, final T object2) {
+ IModel<Comparable> model1 = new PropertyModel<>(object1, provider.getSort().getProperty());
+ IModel<Comparable> model2 = new PropertyModel<>(object2, provider.getSort().getProperty());
+
+ return compare(model1, model2);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/XMLRolesReader.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/XMLRolesReader.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/XMLRolesReader.java
new file mode 100644
index 0000000..3a0b446
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/XMLRolesReader.java
@@ -0,0 +1,118 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons;
+
+import java.util.HashMap;
+import java.util.Map;
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.commons.lang3.tuple.ImmutablePair;
+import org.apache.commons.lang3.tuple.Pair;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.w3c.dom.Document;
+import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
+
+/**
+ * XMLRolesReader singleton class.
+ */
+public class XMLRolesReader {
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(XMLRolesReader.class);
+
+ private String authorizations;
+
+ private Map<Pair<String, String>, String> authMap;
+
+ public void setAuthorizations(final String authorizations) {
+ this.authorizations = authorizations;
+ }
+
+ private void init() {
+ authMap = new HashMap<Pair<String, String>, String>();
+
+ DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
+ dbf.setNamespaceAware(true);
+ try {
+ DocumentBuilder db = dbf.newDocumentBuilder();
+ Document doc = db.parse(getClass().getResource("/" + authorizations).openStream());
+ doc.getDocumentElement().normalize();
+
+ Node authNode = null;
+ NodeList root = doc.getChildNodes();
+ for (int i = 0; i < root.getLength() && authNode == null; i++) {
+ if ("auth".equals(root.item(i).getNodeName())) {
+ authNode = root.item(i);
+ }
+ }
+ if (authNode == null) {
+ throw new IllegalArgumentException("Could not find root <auth> node");
+ }
+
+ NodeList pages = authNode.getChildNodes();
+ for (int i = 0; i < pages.getLength(); i++) {
+ if ("page".equals(pages.item(i).getNodeName())) {
+ String page = pages.item(i).getAttributes().getNamedItem("id").getTextContent();
+
+ NodeList actions = pages.item(i).getChildNodes();
+ for (int j = 0; j < actions.getLength(); j++) {
+ if ("action".equals(actions.item(j).getNodeName())) {
+ String action = actions.item(j).getAttributes().getNamedItem("id").getTextContent();
+
+ NodeList entitlements = actions.item(j).getChildNodes();
+ for (int k = 0; k < entitlements.getLength(); k++) {
+ if ("entitlement".equals(entitlements.item(k).getNodeName())) {
+ String entitlement = entitlements.item(k).getTextContent();
+ authMap.put(new ImmutablePair<String, String>(page, action), entitlement);
+ }
+ }
+ }
+ }
+ }
+ }
+ } catch (Exception e) {
+ LOG.error("While initializing parsing of {}", authorizations, e);
+ }
+ }
+
+ /**
+ * Get entitlement required for page / action.
+ *
+ * @param pageId page
+ * @param actionId action
+ * @return entitlement required
+ */
+ public String getEntitlement(final String pageId, final String actionId) {
+ synchronized (this) {
+ if (authMap == null) {
+ init();
+ }
+ }
+
+ Pair<String, String> key = new ImmutablePair<String, String>(pageId, actionId);
+ return authMap.containsKey(key)
+ ? authMap.get(key)
+ : StringUtils.EMPTY;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/AbstractStatusBeanProvider.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/AbstractStatusBeanProvider.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/AbstractStatusBeanProvider.java
new file mode 100644
index 0000000..c10f55c
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/AbstractStatusBeanProvider.java
@@ -0,0 +1,69 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons.status;
+
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
+import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
+import org.apache.wicket.model.AbstractReadOnlyModel;
+import org.apache.wicket.model.IModel;
+
+public abstract class AbstractStatusBeanProvider extends SortableDataProvider<StatusBean, String> {
+
+ private static final long serialVersionUID = 4287357360778016173L;
+
+ private SortableDataProviderComparator<StatusBean> comparator;
+
+ public AbstractStatusBeanProvider(final String sort) {
+ //Default sorting
+ setSort(sort, SortOrder.ASCENDING);
+ comparator = new SortableDataProviderComparator<StatusBean>(this);
+ }
+
+ @Override
+ public Iterator<StatusBean> iterator(final long first, final long count) {
+ List<StatusBean> list = getStatusBeans();
+ Collections.sort(list, comparator);
+ return list.subList((int) first, (int) first + (int) count).iterator();
+ }
+
+ @Override
+ public long size() {
+ return getStatusBeans().size();
+ }
+
+ @Override
+ public IModel<StatusBean> model(final StatusBean resource) {
+ return new AbstractReadOnlyModel<StatusBean>() {
+
+ private static final long serialVersionUID = -7802635613997243712L;
+
+ @Override
+ public StatusBean getObject() {
+ return resource;
+ }
+ };
+ }
+
+ public abstract List<StatusBean> getStatusBeans();
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/ConnObjectWrapper.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/ConnObjectWrapper.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/ConnObjectWrapper.java
new file mode 100644
index 0000000..be038db
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/ConnObjectWrapper.java
@@ -0,0 +1,55 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons.status;
+
+import java.io.Serializable;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.to.ConnObjectTO;
+
+public class ConnObjectWrapper implements Serializable {
+
+ private static final long serialVersionUID = 9083721948999924299L;
+
+ private final AbstractAttributableTO attributable;
+
+ private final String resourceName;
+
+ private final ConnObjectTO connObjectTO;
+
+ public ConnObjectWrapper(final AbstractAttributableTO attributable, final String resourceName,
+ final ConnObjectTO connObjectTO) {
+
+ this.attributable = attributable;
+ this.resourceName = resourceName;
+ this.connObjectTO = connObjectTO;
+ }
+
+ public AbstractAttributableTO getAttributable() {
+ return attributable;
+ }
+
+ public String getResourceName() {
+ return resourceName;
+ }
+
+ public ConnObjectTO getConnObjectTO() {
+ return connObjectTO;
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/Status.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/Status.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/Status.java
new file mode 100644
index 0000000..7198c2c
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/Status.java
@@ -0,0 +1,45 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons.status;
+
+public enum Status {
+
+ NOT_YET_SUBMITTED(""),
+ CREATED("created"),
+ ACTIVE("active"),
+ SUSPENDED("inactive"),
+ UNDEFINED("undefined"),
+ OBJECT_NOT_FOUND("objectnotfound");
+
+ public boolean isActive() {
+ return this == ACTIVE;
+ }
+
+ private Status(final String name) {
+ this.name = name;
+ }
+
+ private final String name;
+
+ @Override
+ public String toString() {
+ return name;
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/StatusBean.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/StatusBean.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/StatusBean.java
new file mode 100644
index 0000000..47d0086
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/StatusBean.java
@@ -0,0 +1,103 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons.status;
+
+import java.io.Serializable;
+import org.apache.commons.lang3.builder.EqualsBuilder;
+import org.apache.commons.lang3.builder.HashCodeBuilder;
+import org.apache.commons.lang3.builder.ReflectionToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.to.GroupTO;
+import org.apache.syncope.common.lib.to.UserTO;
+
+public class StatusBean implements Serializable {
+
+ private static final long serialVersionUID = -5207260204921071129L;
+
+ private final Long attributableKey;
+
+ private final String attributableName;
+
+ private final String resourceName;
+
+ private String accountLink = null;
+
+ private Status status = Status.OBJECT_NOT_FOUND;
+
+ private boolean linked = true;
+
+ public StatusBean(final AbstractAttributableTO attributable, String resourceName) {
+ this.attributableKey = attributable.getKey();
+ this.attributableName = attributable instanceof UserTO
+ ? ((UserTO) attributable).getUsername() : ((GroupTO) attributable).getName();
+ this.resourceName = resourceName;
+ }
+
+ public String getAccountLink() {
+ return accountLink;
+ }
+
+ public void setAccountLink(final String accountLink) {
+ this.accountLink = accountLink;
+ }
+
+ public String getResourceName() {
+ return resourceName;
+ }
+
+ public Status getStatus() {
+ return status;
+ }
+
+ public void setStatus(final Status status) {
+ this.status = status;
+ }
+
+ public Long getAttributableId() {
+ return attributableKey;
+ }
+
+ public String getAttributableName() {
+ return attributableName;
+ }
+
+ public boolean isLinked() {
+ return linked;
+ }
+
+ public void setLinked(boolean linked) {
+ this.linked = linked;
+ }
+
+ @Override
+ public String toString() {
+ return ReflectionToStringBuilder.toString(this, ToStringStyle.MULTI_LINE_STYLE);
+ }
+
+ @Override
+ public boolean equals(final Object obj) {
+ return EqualsBuilder.reflectionEquals(this, obj);
+ }
+
+ @Override
+ public int hashCode() {
+ return HashCodeBuilder.reflectionHashCode(this);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/StatusUtils.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/StatusUtils.java b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/StatusUtils.java
new file mode 100644
index 0000000..391d202
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/commons/status/StatusUtils.java
@@ -0,0 +1,324 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.commons.status;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.LinkedHashMap;
+import java.util.List;
+import java.util.Map;
+import org.apache.syncope.client.console.commons.ConnIdSpecialAttributeName;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.panels.ImagePanel;
+import org.apache.syncope.client.console.panels.StatusPanel;
+import org.apache.syncope.client.console.rest.AbstractSubjectRestClient;
+import org.apache.syncope.common.lib.mod.StatusMod;
+import org.apache.syncope.common.lib.to.AbstractAttributableTO;
+import org.apache.syncope.common.lib.to.AbstractSubjectTO;
+import org.apache.syncope.common.lib.to.AttrTO;
+import org.apache.syncope.common.lib.to.ConnObjectTO;
+import org.apache.wicket.Component;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.behavior.Behavior;
+import org.apache.wicket.markup.ComponentTag;
+import org.apache.wicket.markup.html.image.Image;
+import org.apache.wicket.request.resource.ContextRelativeResource;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class StatusUtils implements Serializable {
+
+ private static final long serialVersionUID = 7238009174387184309L;
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(StatusUtils.class);
+
+ private static final String IMG_PREFIX = "/img/statuses/";
+
+ private final AbstractSubjectRestClient restClient;
+
+ public StatusUtils(final AbstractSubjectRestClient restClient) {
+ this.restClient = restClient;
+ }
+
+ public List<ConnObjectWrapper> getConnectorObjects(final AbstractSubjectTO subject) {
+ final List<ConnObjectWrapper> objects = new ArrayList<>();
+ objects.addAll(getConnectorObjects(subject, subject.getResources()));
+ return objects;
+ }
+
+ public List<ConnObjectWrapper> getConnectorObjects(
+ final Collection<AbstractSubjectTO> subjects, final Collection<String> resources) {
+
+ final List<ConnObjectWrapper> objects = new ArrayList<>();
+
+ for (AbstractSubjectTO subject : subjects) {
+ objects.addAll(getConnectorObjects(subject, resources));
+ }
+
+ return objects;
+ }
+
+ private List<ConnObjectWrapper> getConnectorObjects(
+ final AbstractSubjectTO subject, final Collection<String> resources) {
+
+ final List<ConnObjectWrapper> objects = new ArrayList<>();
+
+ for (String resourceName : resources) {
+ ConnObjectTO objectTO = null;
+ try {
+ objectTO = restClient.getConnectorObject(resourceName, subject.getKey());
+ } catch (Exception e) {
+ LOG.warn("ConnObject '{}' not found on resource '{}'", subject.getKey(), resourceName);
+ }
+
+ objects.add(new ConnObjectWrapper(subject, resourceName, objectTO));
+ }
+
+ return objects;
+ }
+
+ public StatusBean getStatusBean(
+ final AbstractAttributableTO attributable,
+ final String resourceName,
+ final ConnObjectTO objectTO,
+ final boolean isGroup) {
+
+ final StatusBean statusBean = new StatusBean(attributable, resourceName);
+
+ if (objectTO != null) {
+ final Boolean enabled = isEnabled(objectTO);
+
+ final Status status = enabled == null
+ ? (isGroup ? Status.ACTIVE : Status.UNDEFINED)
+ : enabled
+ ? Status.ACTIVE
+ : Status.SUSPENDED;
+
+ final String accountLink = getAccountLink(objectTO);
+
+ statusBean.setStatus(status);
+ statusBean.setAccountLink(accountLink);
+ }
+
+ return statusBean;
+ }
+
+ private Boolean isEnabled(final ConnObjectTO objectTO) {
+ final Map<String, AttrTO> attributeTOs = objectTO.getPlainAttrMap();
+
+ final AttrTO status = attributeTOs.get(ConnIdSpecialAttributeName.ENABLE);
+
+ return status != null && status.getValues() != null && !status.getValues().isEmpty()
+ ? Boolean.parseBoolean(status.getValues().get(0))
+ : null;
+ }
+
+ private String getAccountLink(final ConnObjectTO objectTO) {
+ final Map<String, AttrTO> attributeTOs = objectTO == null
+ ? Collections.<String, AttrTO>emptyMap()
+ : objectTO.getPlainAttrMap();
+
+ final AttrTO name = attributeTOs.get(ConnIdSpecialAttributeName.NAME);
+
+ return name != null && name.getValues() != null && !name.getValues().isEmpty()
+ ? name.getValues().get(0)
+ : null;
+ }
+
+ public static StatusMod buildStatusMod(final Collection<StatusBean> statuses) {
+ return buildStatusMod(statuses, null);
+ }
+
+ public static StatusMod buildStatusMod(final Collection<StatusBean> statuses, final Boolean enable) {
+ StatusMod statusMod = new StatusMod();
+ statusMod.setOnSyncope(false);
+
+ for (StatusBean status : statuses) {
+ if (enable == null
+ || (enable && !status.getStatus().isActive()) || (!enable && status.getStatus().isActive())) {
+
+ if ("syncope".equalsIgnoreCase(status.getResourceName())) {
+ statusMod.setOnSyncope(true);
+ } else {
+ statusMod.getResourceNames().add(status.getResourceName());
+ }
+
+ }
+ }
+
+ return statusMod;
+ }
+
+ public static void update(
+ final AbstractAttributableTO attributable,
+ final StatusPanel statusPanel,
+ final AjaxRequestTarget target,
+ final Collection<String> resourcesToAdd,
+ final Collection<String> resourcesToRemove) {
+
+ if (statusPanel != null) {
+ Map<String, StatusBean> statusMap = new LinkedHashMap<>();
+ for (StatusBean statusBean : statusPanel.getStatusBeans()) {
+ statusMap.put(statusBean.getResourceName(), statusBean);
+ }
+
+ for (String resourceName : resourcesToAdd) {
+ if (!statusMap.keySet().contains(resourceName)) {
+ StatusBean statusBean;
+ if (statusPanel.getInitialStatusBeanMap().containsKey(resourceName)) {
+ statusBean = statusPanel.getInitialStatusBeanMap().get(resourceName);
+ } else {
+ statusBean = new StatusBean(attributable, resourceName);
+ statusBean.setStatus(Status.NOT_YET_SUBMITTED);
+ }
+
+ statusMap.put(statusBean.getResourceName(), statusBean);
+ }
+ }
+
+ for (String resource : resourcesToRemove) {
+ statusMap.remove(resource);
+ }
+
+ statusPanel.updateStatusBeans(new ArrayList<>(statusMap.values()));
+ target.add(statusPanel);
+ }
+ }
+
+ public ConnObjectTO getConnObjectTO(
+ final Long attributableId, final String resourceName, final List<ConnObjectWrapper> objects) {
+
+ for (ConnObjectWrapper object : objects) {
+ if (attributableId.equals(object.getAttributable().getKey())
+ && resourceName.equalsIgnoreCase(object.getResourceName())) {
+
+ return object.getConnObjectTO();
+ }
+ }
+
+ return null;
+ }
+
+ public Image getStatusImage(final String componentId, final Status status) {
+ final String alt, title, statusName;
+
+ switch (status) {
+
+ case NOT_YET_SUBMITTED:
+ statusName = Status.UNDEFINED.toString();
+ alt = "undefined icon";
+ title = "Not yet submitted";
+ break;
+
+ case ACTIVE:
+ statusName = Status.ACTIVE.toString();
+ alt = "active icon";
+ title = "Enabled";
+ break;
+
+ case UNDEFINED:
+ statusName = Status.UNDEFINED.toString();
+ alt = "undefined icon";
+ title = "Undefined status";
+ break;
+
+ case OBJECT_NOT_FOUND:
+ statusName = Status.OBJECT_NOT_FOUND.toString();
+ alt = "notfound icon";
+ title = "Not found";
+ break;
+
+ default:
+ statusName = Status.SUSPENDED.toString();
+ alt = "inactive icon";
+ title = "Disabled";
+ }
+
+ final Image img = new Image(componentId,
+ new ContextRelativeResource(IMG_PREFIX + statusName + Constants.PNG_EXT));
+ img.add(new Behavior() {
+
+ private static final long serialVersionUID = 1469628524240283489L;
+
+ @Override
+ public void onComponentTag(final Component component, final ComponentTag tag) {
+ tag.put("alt", alt);
+ tag.put("title", title);
+ }
+ });
+
+ return img;
+ }
+
+ public ImagePanel getStatusImagePanel(final String componentId, final Status status) {
+ final String alt, title, statusName;
+
+ switch (status) {
+
+ case NOT_YET_SUBMITTED:
+ statusName = Status.UNDEFINED.toString();
+ alt = "undefined icon";
+ title = "Not yet submitted";
+ break;
+
+ case ACTIVE:
+ statusName = Status.ACTIVE.toString();
+ alt = "active icon";
+ title = "Enabled";
+ break;
+
+ case UNDEFINED:
+ statusName = Status.UNDEFINED.toString();
+ alt = "undefined icon";
+ title = "Undefined status";
+ break;
+
+ case OBJECT_NOT_FOUND:
+ statusName = Status.OBJECT_NOT_FOUND.toString();
+ alt = "notfound icon";
+ title = "Not found";
+ break;
+
+ default:
+ statusName = Status.SUSPENDED.toString();
+ alt = "inactive icon";
+ title = "Disabled";
+ }
+
+ final ImagePanel imagePanel = new ImagePanel(componentId,
+ new ContextRelativeResource(IMG_PREFIX + statusName + Constants.PNG_EXT));
+ imagePanel.add(new Behavior() {
+
+ private static final long serialVersionUID = 1469628524240283489L;
+
+ @Override
+ public void onComponentTag(final Component component, final ComponentTag tag) {
+ tag.put("alt", alt);
+ tag.put("title", title);
+ }
+ });
+
+ return imagePanel;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/init/ConsoleInitializer.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/init/ConsoleInitializer.java b/client/old_console/src/main/java/org/apache/syncope/client/console/init/ConsoleInitializer.java
new file mode 100644
index 0000000..ec51d3e
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/init/ConsoleInitializer.java
@@ -0,0 +1,72 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.init;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Comparator;
+import java.util.List;
+import java.util.Map;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.aop.support.AopUtils;
+import org.springframework.beans.BeansException;
+import org.springframework.beans.factory.BeanFactory;
+import org.springframework.beans.factory.BeanFactoryAware;
+import org.springframework.beans.factory.InitializingBean;
+import org.springframework.beans.factory.support.DefaultListableBeanFactory;
+import org.springframework.stereotype.Component;
+
+/**
+ * Take care of all initializations needed by Syncope Console to run up and safe.
+ */
+@Component
+public class ConsoleInitializer implements InitializingBean, BeanFactoryAware {
+
+ private static final Logger LOG = LoggerFactory.getLogger(ConsoleInitializer.class);
+
+ private DefaultListableBeanFactory beanFactory;
+
+ @Override
+ public void setBeanFactory(final BeanFactory beanFactory) throws BeansException {
+ this.beanFactory = (DefaultListableBeanFactory) beanFactory;
+ }
+
+ @Override
+ public void afterPropertiesSet() {
+ Map<String, SyncopeConsoleLoader> loaderMap = beanFactory.getBeansOfType(SyncopeConsoleLoader.class);
+
+ List<SyncopeConsoleLoader> loaders = new ArrayList<>(loaderMap.values());
+ Collections.sort(loaders, new Comparator<SyncopeConsoleLoader>() {
+
+ @Override
+ public int compare(final SyncopeConsoleLoader o1, final SyncopeConsoleLoader o2) {
+ return o1.getPriority().compareTo(o2.getPriority());
+ }
+ });
+
+ LOG.debug("Starting initialization...");
+ for (SyncopeConsoleLoader loader : loaders) {
+ LOG.debug("Invoking {} with priority {}", AopUtils.getTargetClass(loader).getName(), loader.getPriority());
+ loader.load();
+ }
+ LOG.debug("Initialization completed");
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/init/ImplementationClassNamesLoader.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/init/ImplementationClassNamesLoader.java b/client/old_console/src/main/java/org/apache/syncope/client/console/init/ImplementationClassNamesLoader.java
new file mode 100644
index 0000000..0ff7282
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/init/ImplementationClassNamesLoader.java
@@ -0,0 +1,109 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.init;
+
+import java.lang.reflect.Modifier;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+import org.apache.commons.lang3.ArrayUtils;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.panels.AbstractExtensionPanel;
+import org.apache.syncope.client.console.BinaryPreview;
+import org.apache.syncope.client.console.wicket.markup.html.form.preview.AbstractBinaryPreviewer;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.config.BeanDefinition;
+import org.springframework.context.annotation.ClassPathScanningCandidateComponentProvider;
+import org.springframework.core.type.filter.AssignableTypeFilter;
+import org.springframework.stereotype.Component;
+import org.springframework.util.ClassUtils;
+
+@Component
+public class ImplementationClassNamesLoader implements SyncopeConsoleLoader {
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(ImplementationClassNamesLoader.class);
+
+ private List<Class<? extends AbstractBinaryPreviewer>> previewers;
+
+ private List<Class<? extends AbstractExtensionPanel>> extPanels;
+
+ @Override
+ public Integer getPriority() {
+ return 0;
+ }
+
+ @Override
+ @SuppressWarnings("unchecked")
+ public void load() {
+ previewers = new ArrayList<>();
+ extPanels = new ArrayList<>();
+
+ ClassPathScanningCandidateComponentProvider scanner = new ClassPathScanningCandidateComponentProvider(false);
+ scanner.addIncludeFilter(new AssignableTypeFilter(AbstractBinaryPreviewer.class));
+ scanner.addIncludeFilter(new AssignableTypeFilter(AbstractExtensionPanel.class));
+
+ for (BeanDefinition bd : scanner.findCandidateComponents(StringUtils.EMPTY)) {
+ try {
+ Class<?> clazz = ClassUtils.resolveClassName(
+ bd.getBeanClassName(), ClassUtils.getDefaultClassLoader());
+ boolean isAbsractClazz = Modifier.isAbstract(clazz.getModifiers());
+
+ if (AbstractBinaryPreviewer.class.isAssignableFrom(clazz) && !isAbsractClazz) {
+ previewers.add((Class<? extends AbstractBinaryPreviewer>) clazz);
+ } else if (AbstractExtensionPanel.class.isAssignableFrom(clazz) && !isAbsractClazz) {
+ extPanels.add((Class<? extends AbstractExtensionPanel>) clazz);
+ }
+
+ } catch (Throwable t) {
+ LOG.warn("Could not inspect class {}", bd.getBeanClassName(), t);
+ }
+ }
+ previewers = Collections.unmodifiableList(previewers);
+ extPanels = Collections.unmodifiableList(extPanels);
+
+ LOG.debug("Binary previewers found: {}", previewers);
+ LOG.debug("Extension panels found: {}", extPanels);
+ }
+
+ public Class<? extends AbstractBinaryPreviewer> getPreviewerClass(final String mimeType) {
+ LOG.debug("Searching for previewer class for MIME type: {}", mimeType);
+ Class<? extends AbstractBinaryPreviewer> previewer = null;
+ for (Class<? extends AbstractBinaryPreviewer> candidate : previewers) {
+ LOG.debug("Evaluating previewer class {} for MIME type {}", candidate.getName(), mimeType);
+ if (ArrayUtils.contains(candidate.getAnnotation(BinaryPreview.class).mimeTypes(), mimeType)) {
+ LOG.debug("Found existing previewer for MIME type {}: {}", mimeType, candidate.getName());
+ previewer = candidate;
+ }
+ }
+ return previewer;
+ }
+
+ public List<Class<? extends AbstractBinaryPreviewer>> getPreviewerClasses() {
+ return previewers;
+ }
+
+ public List<Class<? extends AbstractExtensionPanel>> getExtPanelClasses() {
+ return extPanels;
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/init/MIMETypesLoader.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/init/MIMETypesLoader.java b/client/old_console/src/main/java/org/apache/syncope/client/console/init/MIMETypesLoader.java
new file mode 100644
index 0000000..7a2f878
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/init/MIMETypesLoader.java
@@ -0,0 +1,69 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.init;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.wicket.util.io.IOUtils;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.stereotype.Component;
+
+@Component
+public class MIMETypesLoader implements SyncopeConsoleLoader {
+
+ /**
+ * Logger.
+ */
+ private static final Logger LOG = LoggerFactory.getLogger(MIMETypesLoader.class);
+
+ private List<String> mimeTypes;
+
+ @Override
+ public Integer getPriority() {
+ return 10;
+ }
+
+ @Override
+ public void load() {
+ final Set<String> mediaTypes = new HashSet<>();
+ this.mimeTypes = new ArrayList<>();
+ try {
+ final String mimeTypesFile = IOUtils.toString(getClass().getResourceAsStream("/MIMETypes"));
+ for (String fileRow : mimeTypesFile.split("\n")) {
+ if (StringUtils.isNotBlank(fileRow) && !fileRow.startsWith("#")) {
+ mediaTypes.add(fileRow);
+ }
+ }
+ this.mimeTypes.addAll(mediaTypes);
+ Collections.sort(this.mimeTypes);
+ } catch (Exception e) {
+ LOG.error("Error reading file MIMETypes from resources", e);
+ }
+ }
+
+ public List<String> getMimeTypes() {
+ LOG.debug("Returning loaded MIME types list {}", mimeTypes);
+ return mimeTypes;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/init/SyncopeConsoleLoader.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/init/SyncopeConsoleLoader.java b/client/old_console/src/main/java/org/apache/syncope/client/console/init/SyncopeConsoleLoader.java
new file mode 100644
index 0000000..7c4d3d4
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/init/SyncopeConsoleLoader.java
@@ -0,0 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.init;
+
+/**
+ * Marker interface for Syncope console initialization.
+ */
+public interface SyncopeConsoleLoader {
+
+ /**
+ * @return the priority that the implementing class has in the initialization process.
+ */
+ Integer getPriority();
+
+ /**
+ * Perform initialization operations.
+ */
+ void load();
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractBasePage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractBasePage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractBasePage.java
new file mode 100644
index 0000000..830f369
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractBasePage.java
@@ -0,0 +1,131 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.XMLRolesReader;
+import org.apache.syncope.client.console.init.MIMETypesLoader;
+import org.apache.syncope.client.console.panels.NotificationPanel;
+import org.apache.syncope.client.console.rest.ConfigurationRestClient;
+import org.apache.syncope.client.console.rest.ReportRestClient;
+import org.apache.syncope.client.console.rest.ResourceRestClient;
+import org.apache.syncope.client.console.rest.GroupRestClient;
+import org.apache.syncope.client.console.rest.SchemaRestClient;
+import org.apache.syncope.client.console.rest.TaskRestClient;
+import org.apache.syncope.client.console.rest.UserRestClient;
+import org.apache.syncope.client.console.rest.UserSelfRestClient;
+import org.apache.syncope.client.console.wicket.markup.head.MetaHeaderItem;
+import org.apache.wicket.markup.head.HeaderItem;
+import org.apache.wicket.markup.head.IHeaderResponse;
+import org.apache.wicket.markup.head.PriorityHeaderItem;
+import org.apache.wicket.markup.html.WebPage;
+import org.apache.wicket.request.mapper.parameter.PageParameters;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class AbstractBasePage extends WebPage {
+
+ private static final long serialVersionUID = 8611724965544132636L;
+
+ /**
+ * Logger.
+ */
+ protected static final Logger LOG = LoggerFactory.getLogger(AbstractBasePage.class);
+
+ protected static final String TASKS = "Tasks";
+
+ protected static final String FORM = "form";
+
+ protected static final String CANCEL = "cancel";
+
+ protected static final String SUBMIT = "submit";
+
+ protected static final String APPLY = "apply";
+
+ protected final HeaderItem meta = new MetaHeaderItem("X-UA-Compatible", "IE=edge");
+
+ @SpringBean
+ protected XMLRolesReader xmlRolesReader;
+
+ @SpringBean
+ protected UserRestClient userRestClient;
+
+ @SpringBean
+ protected UserSelfRestClient userSelfRestClient;
+
+ @SpringBean
+ protected GroupRestClient groupRestClient;
+
+ @SpringBean
+ protected TaskRestClient taskRestClient;
+
+ @SpringBean
+ protected SchemaRestClient schemaRestClient;
+
+ @SpringBean
+ protected ResourceRestClient resourceRestClient;
+
+ @SpringBean
+ protected ReportRestClient reportRestClient;
+
+ @SpringBean
+ protected ConfigurationRestClient confRestClient;
+
+ @SpringBean
+ protected MIMETypesLoader mimeTypesInitializer;
+
+ protected NotificationPanel feedbackPanel;
+
+ /**
+ * Response flag set by the Modal Window after the operation is completed.
+ */
+ protected boolean modalResult = false;
+
+ public AbstractBasePage() {
+ this(null);
+ }
+
+ public AbstractBasePage(final PageParameters parameters) {
+ super(parameters);
+
+ feedbackPanel = new NotificationPanel(Constants.FEEDBACK);
+ feedbackPanel.setOutputMarkupId(true);
+ add(feedbackPanel);
+ }
+
+ public NotificationPanel getFeedbackPanel() {
+ return feedbackPanel;
+ }
+
+ public boolean isModalResult() {
+ return modalResult;
+ }
+
+ public void setModalResult(final boolean operationResult) {
+ this.modalResult = operationResult;
+ }
+
+ @Override
+ public void renderHead(final IHeaderResponse response) {
+ super.renderHead(response);
+ response.render(new PriorityHeaderItem(meta));
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractSchedTaskModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractSchedTaskModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractSchedTaskModalPage.java
new file mode 100644
index 0000000..78ca906
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractSchedTaskModalPage.java
@@ -0,0 +1,132 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.DateFormatROModel;
+import org.apache.syncope.client.console.wicket.markup.html.CrontabContainer;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.SchedTaskTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.springframework.util.StringUtils;
+
+/**
+ * Modal window with Task form (to stop and start execution).
+ */
+public abstract class AbstractSchedTaskModalPage extends TaskModalPage {
+
+ private static final long serialVersionUID = 2892005971093059242L;
+
+ protected CrontabContainer crontab;
+
+ public AbstractSchedTaskModalPage(final ModalWindow window, final SchedTaskTO taskTO,
+ final PageReference pageRef) {
+
+ super(taskTO);
+
+ crontab = new CrontabContainer("crontab", new PropertyModel<String>(taskTO, "cronExpression"),
+ taskTO.getCronExpression());
+ form.add(crontab);
+
+ final AjaxTextFieldPanel name =
+ new AjaxTextFieldPanel("name", "name", new PropertyModel<String>(taskTO, "name"));
+ name.setEnabled(true);
+ profile.add(name);
+
+ final AjaxTextFieldPanel description = new AjaxTextFieldPanel("description", "description",
+ new PropertyModel<String>(taskTO, "description"));
+ description.setEnabled(true);
+ profile.add(description);
+
+ final AjaxTextFieldPanel lastExec = new AjaxTextFieldPanel("lastExec", getString("lastExec"),
+ new DateFormatROModel(new PropertyModel<String>(taskTO, "lastExec")));
+ lastExec.setEnabled(false);
+ profile.add(lastExec);
+
+ final AjaxTextFieldPanel nextExec = new AjaxTextFieldPanel("nextExec", getString("nextExec"),
+ new DateFormatROModel(new PropertyModel<String>(taskTO, "nextExec")));
+ nextExec.setEnabled(false);
+ profile.add(nextExec);
+
+ final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(APPLY)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ SchedTaskTO taskTO = (SchedTaskTO) form.getModelObject();
+ taskTO.setCronExpression(StringUtils.hasText(taskTO.getCronExpression())
+ ? crontab.getCronExpression()
+ : null);
+
+ try {
+ submitAction(taskTO);
+
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+
+ window.close(target);
+ } catch (SyncopeClientException e) {
+ LOG.error("While creating or updating task", e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+
+ final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+ };
+
+ cancel.setDefaultFormProcessing(false);
+
+ if (taskTO.getKey() > 0) {
+ MetaDataRoleAuthorizationStrategy.authorize(
+ submit, RENDER, xmlRolesReader.getEntitlement(TASKS, "update"));
+ } else {
+ MetaDataRoleAuthorizationStrategy.authorize(
+ submit, RENDER, xmlRolesReader.getEntitlement(TASKS, "create"));
+ }
+
+ form.add(submit);
+ form.add(cancel);
+ }
+
+ protected abstract void submitAction(SchedTaskTO taskTO);
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractSchemaModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractSchemaModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractSchemaModalPage.java
new file mode 100644
index 0000000..1c1bd0f
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractSchemaModalPage.java
@@ -0,0 +1,45 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.common.lib.to.AbstractSchemaTO;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+
+/**
+ * Modal window with Schema form.
+ */
+public abstract class AbstractSchemaModalPage<T extends AbstractSchemaTO> extends BaseModalPage {
+
+ private static final long serialVersionUID = 7369215690388444748L;
+
+ protected AttributableType kind;
+
+ public AbstractSchemaModalPage(final AttributableType kind) {
+ this.kind = kind;
+ }
+
+ public abstract void setSchemaModalPage(PageReference callerPageRef, ModalWindow window, T schema,
+ boolean createFlag);
+
+ public AttributableType getKind() {
+ return kind;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractStatusModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractStatusModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractStatusModalPage.java
new file mode 100644
index 0000000..f5dfbca
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/AbstractStatusModalPage.java
@@ -0,0 +1,30 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.wicket.markup.html.panel.Fragment;
+
+public class AbstractStatusModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = 6633408683036028540L;
+
+ public AbstractStatusModalPage() {
+ add(new Fragment("pwdMgtFields", "emptyFragment", this));
+ }
+}
[17/51] [partial] syncope git commit: [SYNCOPE-156] Preparing place
for new console
Posted by il...@apache.org.
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Todo.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Todo.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Todo.java
new file mode 100644
index 0000000..1329fe4
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Todo.java
@@ -0,0 +1,245 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+import org.apache.syncope.client.console.SyncopeSession;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.PreferenceManager;
+import org.apache.syncope.client.console.commons.SortableDataProviderComparator;
+import org.apache.syncope.client.console.rest.ApprovalRestClient;
+import org.apache.syncope.client.console.wicket.extensions.markup.html.repeater.data.table.DatePropertyColumn;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLink;
+import org.apache.syncope.client.console.wicket.markup.html.form.ActionLinksPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.WorkflowFormTO;
+import org.apache.wicket.Page;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.ajax.markup.html.repeater.data.table.AjaxFallbackDefaultDataTable;
+import org.apache.wicket.extensions.markup.html.repeater.data.grid.ICellPopulator;
+import org.apache.wicket.extensions.markup.html.repeater.data.sort.SortOrder;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.AbstractColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.PropertyColumn;
+import org.apache.wicket.extensions.markup.html.repeater.util.SortableDataProvider;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.repeater.Item;
+import org.apache.wicket.model.AbstractReadOnlyModel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.request.mapper.parameter.PageParameters;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class Todo extends BasePage {
+
+ private static final long serialVersionUID = -7122136682275797903L;
+
+ @SpringBean
+ private ApprovalRestClient restClient;
+
+ @SpringBean
+ private PreferenceManager prefMan;
+
+ private final ModalWindow window;
+
+ private static final int WIN_HEIGHT = 400;
+
+ private static final int WIN_WIDTH = 600;
+
+ private WebMarkupContainer container;
+
+ private int paginatorRows;
+
+ public Todo(final PageParameters parameters) {
+ super(parameters);
+
+ add(window = new ModalWindow("editApprovalWin"));
+
+ container = new WebMarkupContainer("approvalContainer");
+
+ MetaDataRoleAuthorizationStrategy.authorize(
+ container, RENDER, xmlRolesReader.getEntitlement("Approval", "list"));
+
+ paginatorRows = prefMan.getPaginatorRows(getRequest(), Constants.PREF_TODO_PAGINATOR_ROWS);
+
+ List<IColumn<WorkflowFormTO, String>> columns = new ArrayList<IColumn<WorkflowFormTO, String>>();
+ columns.add(new PropertyColumn<WorkflowFormTO, String>(
+ new ResourceModel("taskId"), "taskId", "taskId"));
+ columns.add(new PropertyColumn<WorkflowFormTO, String>(
+ new ResourceModel("key"), "key", "key"));
+ columns.add(new PropertyColumn<WorkflowFormTO, String>(
+ new ResourceModel("description"), "description", "description"));
+ columns.add(new DatePropertyColumn<WorkflowFormTO>(
+ new ResourceModel("createTime"), "createTime", "createTime"));
+ columns.add(new DatePropertyColumn<WorkflowFormTO>(
+ new ResourceModel("dueDate"), "dueDate", "dueDate"));
+ columns.add(new PropertyColumn<WorkflowFormTO, String>(new ResourceModel("owner"), "owner", "owner"));
+ columns.add(new AbstractColumn<WorkflowFormTO, String>(new ResourceModel("actions", "")) {
+
+ private static final long serialVersionUID = 2054811145491901166L;
+
+ @Override
+ public String getCssClass() {
+ return "action";
+ }
+
+ @Override
+ public void populateItem(final Item<ICellPopulator<WorkflowFormTO>> cellItem, final String componentId,
+ final IModel<WorkflowFormTO> model) {
+
+ final WorkflowFormTO formTO = model.getObject();
+
+ final ActionLinksPanel panel = new ActionLinksPanel(componentId, model, getPageReference());
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ try {
+ restClient.claimForm(formTO.getTaskId());
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scee) {
+ error(getString(Constants.ERROR) + ": " + scee.getMessage());
+ }
+ feedbackPanel.refresh(target);
+ target.add(container);
+ }
+ }, ActionLink.ActionType.CLAIM, "Approval");
+
+ panel.add(new ActionLink() {
+
+ private static final long serialVersionUID = -3722207913631435501L;
+
+ @Override
+ public void onClick(final AjaxRequestTarget target) {
+ window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new ApprovalModalPage(Todo.this.getPageReference(), window, formTO);
+ }
+ });
+
+ window.show(target);
+ }
+ }, ActionLink.ActionType.EDIT, "Approval",
+ SyncopeSession.get().getUsername().equals(formTO.getOwner()));
+
+ cellItem.add(panel);
+ }
+ });
+
+ final AjaxFallbackDefaultDataTable<WorkflowFormTO, String> approvalTable =
+ new AjaxFallbackDefaultDataTable<WorkflowFormTO, String>(
+ "approvalTable", columns, new ApprovalProvider(), paginatorRows);
+ container.add(approvalTable);
+
+ container.setOutputMarkupId(true);
+ add(container);
+
+ @SuppressWarnings("rawtypes")
+ Form approvalPaginatorForm = new Form("paginatorForm");
+
+ MetaDataRoleAuthorizationStrategy.authorize(approvalPaginatorForm, RENDER,
+ xmlRolesReader.getEntitlement("Approval", "list"));
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ final DropDownChoice rowsChooser = new DropDownChoice("rowsChooser",
+ new PropertyModel(this, "paginatorRows"), prefMan.getPaginatorChoices());
+
+ rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ prefMan.set(getRequest(), getResponse(), Constants.PREF_TODO_PAGINATOR_ROWS,
+ String.valueOf(paginatorRows));
+ approvalTable.setItemsPerPage(paginatorRows);
+
+ target.add(container);
+ }
+ });
+
+ approvalPaginatorForm.add(rowsChooser);
+ add(approvalPaginatorForm);
+
+ window.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ window.setInitialHeight(WIN_HEIGHT);
+ window.setInitialWidth(WIN_WIDTH);
+ window.setCookieName("edit-approval-modal");
+
+ setWindowClosedCallback(window, container);
+ }
+
+ private class ApprovalProvider extends SortableDataProvider<WorkflowFormTO, String> {
+
+ private static final long serialVersionUID = -2311716167583335852L;
+
+ private final SortableDataProviderComparator<WorkflowFormTO> comparator;
+
+ public ApprovalProvider() {
+ super();
+ //Default sorting
+ setSort("key", SortOrder.ASCENDING);
+ comparator = new SortableDataProviderComparator<WorkflowFormTO>(this);
+ }
+
+ @Override
+ public Iterator<WorkflowFormTO> iterator(final long first, final long count) {
+ final List<WorkflowFormTO> list = restClient.getForms();
+
+ Collections.sort(list, comparator);
+
+ return list.subList((int) first, (int) first + (int) count).iterator();
+ }
+
+ @Override
+ public long size() {
+ return restClient.getForms().size();
+ }
+
+ @Override
+ public IModel<WorkflowFormTO> model(final WorkflowFormTO configuration) {
+ return new AbstractReadOnlyModel<WorkflowFormTO>() {
+
+ private static final long serialVersionUID = -2566070996511906708L;
+
+ @Override
+ public WorkflowFormTO getObject() {
+ return configuration;
+ }
+ };
+ }
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/UserModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/UserModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/UserModalPage.java
new file mode 100644
index 0000000..0835ca2
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/UserModalPage.java
@@ -0,0 +1,229 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.commons.Mode;
+import org.apache.syncope.client.console.panels.DerAttrsPanel;
+import org.apache.syncope.client.console.panels.MembershipsPanel;
+import org.apache.syncope.client.console.panels.PlainAttrsPanel;
+import org.apache.syncope.client.console.panels.ResourcesPanel;
+import org.apache.syncope.client.console.panels.SecurityQuestionPanel;
+import org.apache.syncope.client.console.panels.UserDetailsPanel;
+import org.apache.syncope.client.console.panels.VirAttrsPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.basic.Label;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.panel.Fragment;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.model.ResourceModel;
+
+/**
+ * Modal window with User form.
+ */
+public abstract class UserModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = 5002005009737457667L;
+
+ protected final PageReference pageRef;
+
+ protected final ModalWindow window;
+
+ protected UserTO userTO;
+
+ protected final Mode mode;
+
+ private Fragment fragment = null;
+
+ private final boolean resetPassword;
+
+ protected final AjaxCheckBoxPanel storePassword;
+
+ public UserModalPage(final PageReference callerPageRef, final ModalWindow window, final UserTO userTO,
+ final Mode mode, final boolean resetPassword) {
+
+ super();
+
+ this.pageRef = callerPageRef;
+ this.window = window;
+ this.userTO = userTO;
+ this.mode = mode;
+ this.resetPassword = resetPassword;
+
+ fragment = new Fragment("userModalFrag", "userModalEditFrag", this);
+ fragment.setOutputMarkupId(true);
+ add(fragment);
+
+ storePassword = new AjaxCheckBoxPanel("storePassword", "storePassword",
+ new Model<Boolean>(Boolean.TRUE));
+ }
+
+ public UserTO getUserTO() {
+ return userTO;
+ }
+
+ public void setUserTO(final UserTO userTO) {
+ this.userTO = userTO;
+ }
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ protected Form setupEditPanel() {
+ fragment.add(new Label("id", userTO.getKey() == 0
+ ? StringUtils.EMPTY
+ : userTO.getUsername()));
+
+ fragment.add(new Label("new", userTO.getKey() == 0
+ ? new ResourceModel("new")
+ : new Model(StringUtils.EMPTY)));
+
+ final Form form = new Form("UserForm");
+ form.setModel(new CompoundPropertyModel(userTO));
+
+ //--------------------------------
+ // User details
+ //--------------------------------
+ form.add(new UserDetailsPanel("details", userTO, form, resetPassword, mode == Mode.TEMPLATE));
+
+ form.add(new Label("statuspanel", ""));
+
+ form.add(new Label("pwdChangeInfo", ""));
+
+ form.add(new Label("securityQuestion", ""));
+ form.addOrReplace(new SecurityQuestionPanel("securityQuestion", userTO));
+
+ form.add(new Label("accountinformation", ""));
+ //--------------------------------
+
+ //--------------------------------
+ // Store password internally checkbox
+ //--------------------------------
+ final Fragment storePwdFragment = new Fragment("storePwdFrag", "storePwdCheck", form);
+ storePwdFragment.setOutputMarkupId(true);
+ final Label storePasswordLabel = new Label("storePasswordLabel", new ResourceModel("storePassword"));
+ storePwdFragment.add(storePasswordLabel);
+ storePwdFragment.add(storePassword);
+ form.add(userTO.getKey() == 0 && mode != Mode.TEMPLATE
+ ? storePwdFragment : new Fragment("storePwdFrag", "emptyFragment", form));
+ //--------------------------------
+
+ //--------------------------------
+ // Attributes panel
+ //--------------------------------
+ form.add(new PlainAttrsPanel("plainAttrs", userTO, form, mode));
+ //--------------------------------
+
+ //--------------------------------
+ // Derived attributes panel
+ //--------------------------------
+ form.add(new DerAttrsPanel("derAttrs", userTO));
+ //--------------------------------
+
+ //--------------------------------
+ // Virtual attributes panel
+ //--------------------------------
+ form.add(new VirAttrsPanel("virAttrs", userTO, mode == Mode.TEMPLATE));
+ //--------------------------------
+
+ //--------------------------------
+ // Resources panel
+ //--------------------------------
+ form.add(new ResourcesPanel.Builder("resources").attributableTO(userTO).build());
+ //--------------------------------
+
+ //--------------------------------
+ // Groups panel
+ //--------------------------------
+ form.add(new MembershipsPanel("memberships", userTO, mode, null, getPageReference()));
+ //--------------------------------
+
+ final AjaxButton submit = getOnSubmit();
+
+ if (mode == Mode.ADMIN) {
+ String allowedRoles = userTO.getKey() == 0
+ ? xmlRolesReader.getEntitlement("Users", "create")
+ : xmlRolesReader.getEntitlement("Users", "update");
+ MetaDataRoleAuthorizationStrategy.authorize(submit, RENDER, allowedRoles);
+ }
+
+ fragment.add(form);
+ form.add(submit);
+ form.setDefaultButton(submit);
+
+ final AjaxButton cancel = new AjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = 530608535790823587L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ }
+ };
+
+ cancel.setDefaultFormProcessing(false);
+ form.add(cancel);
+
+ return form;
+ }
+
+ protected AjaxButton getOnSubmit() {
+ return new IndicatingAjaxButton(APPLY, new ResourceModel(SUBMIT)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ try {
+ submitAction(target, form);
+
+ if (pageRef.getPage() instanceof BasePage) {
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+ }
+
+ closeAction(target, form);
+ } catch (Exception e) {
+ LOG.error("While creating or updating user", e);
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+ }
+
+ protected abstract void submitAction(AjaxRequestTarget target, Form<?> form);
+
+ protected abstract void closeAction(AjaxRequestTarget target, Form<?> form);
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage.java
new file mode 100644
index 0000000..ae8a5da
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/UserOwnerSelectModalPage.java
@@ -0,0 +1,81 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.panels.AbstractSearchResultPanel;
+import org.apache.syncope.client.console.panels.SelectOnlyUserSearchResultPanel;
+import org.apache.syncope.client.console.panels.UserSearchPanel;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.Session;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.ResourceModel;
+
+public class UserOwnerSelectModalPage extends BaseModalPage {
+
+ private static final long serialVersionUID = 2106489458494696439L;
+
+ public UserOwnerSelectModalPage(final PageReference pageRef, final ModalWindow window) {
+ super();
+
+ final SelectOnlyUserSearchResultPanel searchResult =
+ new SelectOnlyUserSearchResultPanel("searchResult", true, null, pageRef, window, userRestClient);
+ add(searchResult);
+
+ final Form<?> searchForm = new Form("searchForm");
+ add(searchForm);
+
+ final UserSearchPanel searchPanel = new UserSearchPanel.Builder("searchPanel").build();
+ searchForm.add(searchPanel);
+
+ searchForm.add(new IndicatingAjaxButton("search", new ResourceModel("search")) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ final String searchCond = searchPanel.buildFIQL();
+ doSearch(target, searchCond, searchResult);
+
+ Session.get().getFeedbackMessages().clear();
+ searchPanel.getSearchFeedback().refresh(target);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ searchPanel.getSearchFeedback().refresh(target);
+ }
+ });
+
+ }
+
+ private void doSearch(final AjaxRequestTarget target, final String fiql,
+ final AbstractSearchResultPanel resultsetPanel) {
+
+ if (fiql == null) {
+ error(getString(Constants.SEARCH_ERROR));
+ return;
+ }
+
+ resultsetPanel.search(fiql, target);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/UserSelfModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/UserSelfModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/UserSelfModalPage.java
new file mode 100644
index 0000000..087bd69
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/UserSelfModalPage.java
@@ -0,0 +1,72 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.commons.lang3.SerializationUtils;
+import org.apache.syncope.client.console.commons.Mode;
+import org.apache.syncope.client.console.rest.UserSelfRestClient;
+import org.apache.syncope.common.lib.AttributableOperations;
+import org.apache.syncope.common.lib.mod.UserMod;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+/**
+ * Modal window with User form.
+ */
+public class UserSelfModalPage extends UserModalPage {
+
+ private static final long serialVersionUID = 603212869211672852L;
+
+ @SpringBean
+ private UserSelfRestClient restClient;
+
+ private final UserTO initialUserTO;
+
+ public UserSelfModalPage(final PageReference callerPageRef, final ModalWindow window, final UserTO userTO) {
+ super(callerPageRef, window, userTO, Mode.SELF, userTO.getKey() != 0);
+
+ this.initialUserTO = SerializationUtils.clone(userTO);
+ setupEditPanel();
+ }
+
+ @Override
+ protected void submitAction(final AjaxRequestTarget target, final Form<?> form) {
+ final UserTO updatedUserTO = (UserTO) form.getModelObject();
+
+ if (updatedUserTO.getKey() == 0) {
+ restClient.create(updatedUserTO, storePassword.getModelObject());
+ } else {
+ final UserMod userMod = AttributableOperations.diff(updatedUserTO, initialUserTO);
+
+ // update user only if it has changed
+ if (!userMod.isEmpty()) {
+ restClient.update(userMod);
+ }
+ }
+ }
+
+ @Override
+ protected void closeAction(final AjaxRequestTarget target, final Form<?> form) {
+ setResponsePage(new ResultStatusModalPage.Builder(window, userTO).mode(mode).build());
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/UserTemplateModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/UserTemplateModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/UserTemplateModalPage.java
new file mode 100644
index 0000000..2b04035
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/UserTemplateModalPage.java
@@ -0,0 +1,60 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.commons.Mode;
+import org.apache.syncope.common.lib.to.SyncTaskTO;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.form.Form;
+
+/**
+ * Modal window with User form.
+ */
+public class UserTemplateModalPage extends UserModalPage {
+
+ private static final long serialVersionUID = 511003221213581368L;
+
+ private final SyncTaskTO syncTaskTO;
+
+ public UserTemplateModalPage(final PageReference callerPageRef, final ModalWindow window,
+ final SyncTaskTO syncTaskTO) {
+
+ super(callerPageRef, window, syncTaskTO.getUserTemplate() == null
+ ? new UserTO()
+ : syncTaskTO.getUserTemplate(), Mode.TEMPLATE, true);
+
+ this.syncTaskTO = syncTaskTO;
+
+ setupEditPanel();
+ }
+
+ @Override
+ protected void submitAction(final AjaxRequestTarget target, final Form form) {
+ syncTaskTO.setUserTemplate((UserTO) form.getModelObject());
+ taskRestClient.updateSyncTask(syncTaskTO);
+ }
+
+ @Override
+ protected void closeAction(final AjaxRequestTarget target, final Form form) {
+ window.close(target);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Users.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Users.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Users.java
new file mode 100644
index 0000000..98f93bf
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/Users.java
@@ -0,0 +1,166 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.panels.AbstractSearchResultPanel;
+import org.apache.syncope.client.console.panels.AbstractSearchResultPanel.EventDataWrapper;
+import org.apache.syncope.client.console.panels.UserSearchPanel;
+import org.apache.syncope.client.console.panels.UserSearchResultPanel;
+import org.apache.syncope.client.console.rest.UserRestClient;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.Page;
+import org.apache.wicket.Session;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.event.Broadcast;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.ResourceModel;
+import org.apache.wicket.request.mapper.parameter.PageParameters;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public class Users extends BasePage {
+
+ private static final long serialVersionUID = 134681165644474568L;
+
+ private final static int EDIT_MODAL_WIN_HEIGHT = 550;
+
+ private final static int EDIT_MODAL_WIN_WIDTH = 800;
+
+ @SpringBean
+ private UserRestClient restClient;
+
+ public Users(final PageParameters parameters) {
+ super(parameters);
+
+ // Modal window for editing user attributes
+ final ModalWindow editModalWin = new ModalWindow("editModal");
+ editModalWin.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ editModalWin.setInitialHeight(EDIT_MODAL_WIN_HEIGHT);
+ editModalWin.setInitialWidth(EDIT_MODAL_WIN_WIDTH);
+ editModalWin.setCookieName("edit-modal");
+ add(editModalWin);
+
+ final AbstractSearchResultPanel searchResult =
+ new UserSearchResultPanel("searchResult", true, null, getPageReference(), restClient);
+ add(searchResult);
+
+ final AbstractSearchResultPanel listResult =
+ new UserSearchResultPanel("listResult", false, null, getPageReference(), restClient);
+ add(listResult);
+
+ // create new user
+ final AjaxLink<Void> createLink = new ClearIndicatingAjaxLink<Void>("createLink", getPageReference()) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ editModalWin.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return new EditUserModalPage(Users.this.getPageReference(), editModalWin, new UserTO());
+ }
+ });
+
+ editModalWin.show(target);
+ }
+ };
+ MetaDataRoleAuthorizationStrategy.authorize(
+ createLink, ENABLE, xmlRolesReader.getEntitlement("Users", "create"));
+ add(createLink);
+
+ setWindowClosedReloadCallback(editModalWin);
+
+ final Form<?> searchForm = new Form<>("searchForm");
+ add(searchForm);
+
+ final UserSearchPanel searchPanel = new UserSearchPanel.Builder("searchPanel").build();
+ searchForm.add(searchPanel);
+
+ final ClearIndicatingAjaxButton searchButton =
+ new ClearIndicatingAjaxButton("search", new ResourceModel("search"), getPageReference()) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
+ final String fiql = searchPanel.buildFIQL();
+ LOG.debug("FIQL: " + fiql);
+
+ doSearch(target, fiql, searchResult);
+
+ Session.get().getFeedbackMessages().clear();
+ searchPanel.getSearchFeedback().refresh(target);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+
+ searchPanel.getSearchFeedback().refresh(target);
+ }
+ };
+
+ searchForm.add(searchButton);
+ searchForm.setDefaultButton(searchButton);
+ }
+
+ private void doSearch(final AjaxRequestTarget target, final String fiql,
+ final AbstractSearchResultPanel resultsetPanel) {
+
+ if (fiql == null) {
+ error(getString(Constants.SEARCH_ERROR));
+ return;
+ }
+
+ resultsetPanel.search(fiql, target);
+ }
+
+ private void setWindowClosedReloadCallback(final ModalWindow window) {
+ window.setWindowClosedCallback(new ModalWindow.WindowClosedCallback() {
+
+ private static final long serialVersionUID = 8804221891699487139L;
+
+ @Override
+ public void onClose(final AjaxRequestTarget target) {
+ final EventDataWrapper data = new EventDataWrapper();
+ data.setTarget(target);
+ data.setCreate(true);
+
+ send(getPage(), Broadcast.BREADTH, data);
+
+ if (isModalResult()) {
+ // reset modal result
+ setModalResult(false);
+ // set operation succeeded
+ getSession().info(getString(Constants.OPERATION_SUCCEEDED));
+ // refresh feedback panel
+ feedbackPanel.refresh(target);
+ }
+ }
+ });
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ViewUserModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ViewUserModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ViewUserModalPage.java
new file mode 100644
index 0000000..d47e07f
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/ViewUserModalPage.java
@@ -0,0 +1,49 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.common.lib.to.UserTO;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.form.Form;
+
+public class ViewUserModalPage extends EditUserModalPage {
+
+ private static final long serialVersionUID = -8715255026876951611L;
+
+ public ViewUserModalPage(final PageReference callerPageRef, final ModalWindow window, final UserTO userTO) {
+ super(callerPageRef, window, userTO);
+ form.setEnabled(false);
+ form.get(CANCEL).setVisible(false);
+ }
+
+ @Override
+ protected AjaxButton getOnSubmit() {
+ AjaxButton submit = super.getOnSubmit();
+ submit.setVisible(false);
+ return submit;
+ }
+
+ @Override
+ protected void submitAction(final AjaxRequestTarget target, final Form form) {
+ // No submit allowed, read-only form
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/VirSchemaModalPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/VirSchemaModalPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/VirSchemaModalPage.java
new file mode 100644
index 0000000..425b9cb
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/VirSchemaModalPage.java
@@ -0,0 +1,126 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxCheckBoxPanel;
+import org.apache.syncope.client.console.wicket.markup.html.form.AjaxTextFieldPanel;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.syncope.common.lib.to.VirSchemaTO;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.extensions.ajax.markup.html.IndicatingAjaxButton;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.CompoundPropertyModel;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.model.ResourceModel;
+
+/**
+ * Modal window with Schema form.
+ */
+public class VirSchemaModalPage extends AbstractSchemaModalPage<VirSchemaTO> {
+
+ private static final long serialVersionUID = 5979623248182851337L;
+
+ public VirSchemaModalPage(final AttributableType kind) {
+ super(kind);
+ }
+
+ @Override
+ public void setSchemaModalPage(final PageReference pageRef, final ModalWindow window,
+ VirSchemaTO schema, final boolean createFlag) {
+
+ if (schema == null) {
+ schema = new VirSchemaTO();
+ }
+
+ final Form<VirSchemaTO> schemaForm = new Form<>(FORM);
+
+ schemaForm.setModel(new CompoundPropertyModel<>(schema));
+
+ final AjaxTextFieldPanel name =
+ new AjaxTextFieldPanel("key", getString("key"), new PropertyModel<String>(schema, "key"));
+ name.addRequiredLabel();
+
+ name.setEnabled(createFlag);
+
+ final AjaxCheckBoxPanel readonly = new AjaxCheckBoxPanel("readonly", getString("readonly"),
+ new PropertyModel<Boolean>(schema, "readonly"));
+
+ final AjaxButton submit = new IndicatingAjaxButton(APPLY, new ResourceModel(SUBMIT)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ VirSchemaTO schemaTO = (VirSchemaTO) form.getDefaultModelObject();
+ try {
+ if (createFlag) {
+ schemaRestClient.createVirSchema(kind, schemaTO);
+ } else {
+ schemaRestClient.updateVirSchema(kind, schemaTO);
+ }
+ if (pageRef.getPage() instanceof BasePage) {
+ ((BasePage) pageRef.getPage()).setModalResult(true);
+ }
+
+ window.close(target);
+ } catch (SyncopeClientException e) {
+ error(getString(Constants.ERROR) + ": " + e.getMessage());
+ feedbackPanel.refresh(target);
+ }
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+
+ final AjaxButton cancel = new IndicatingAjaxButton(CANCEL, new ResourceModel(CANCEL)) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmit(final AjaxRequestTarget target, final Form<?> form) {
+ window.close(target);
+ }
+ };
+
+ cancel.setDefaultFormProcessing(false);
+
+ String allowedRoles = createFlag
+ ? xmlRolesReader.getEntitlement("Schema", "create")
+ : xmlRolesReader.getEntitlement("Schema", "update");
+
+ MetaDataRoleAuthorizationStrategy.authorize(submit, ENABLE, allowedRoles);
+
+ schemaForm.add(name);
+ schemaForm.add(readonly);
+
+ schemaForm.add(submit);
+ schemaForm.add(cancel);
+
+ add(schemaForm);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/WelcomePage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/WelcomePage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/WelcomePage.java
new file mode 100644
index 0000000..d9f884d
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/WelcomePage.java
@@ -0,0 +1,55 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import org.apache.syncope.client.console.SyncopeApplication;
+import org.apache.syncope.client.console.commons.XMLRolesReader;
+import org.apache.syncope.client.console.rest.UserSelfRestClient;
+import org.apache.wicket.markup.html.WebPage;
+import org.apache.wicket.request.mapper.parameter.PageParameters;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+/**
+ * Welcome page to display after successful login.
+ */
+public class WelcomePage extends WebPage {
+
+ private static final long serialVersionUID = 8851399358753120581L;
+
+ @SpringBean
+ private XMLRolesReader xmlRolesReader;
+
+ @SpringBean
+ private UserSelfRestClient userSelfRestClient;
+
+ public WelcomePage(final PageParameters parameters) {
+ super(parameters);
+ setupNavigationPanel();
+ setupEditProfileModal();
+ }
+
+ //To prevent warning: "leaking this in constructor java"
+ private void setupNavigationPanel() {
+ ((SyncopeApplication) getApplication()).setupNavigationPanel(this, xmlRolesReader, false);
+ }
+
+ private void setupEditProfileModal() {
+ ((SyncopeApplication) getApplication()).setupEditProfileModal(this, userSelfRestClient);
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/pages/XMLEditorPopupPage.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/pages/XMLEditorPopupPage.java b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/XMLEditorPopupPage.java
new file mode 100644
index 0000000..b5a8d10
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/pages/XMLEditorPopupPage.java
@@ -0,0 +1,90 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.pages;
+
+import java.io.IOException;
+import javax.ws.rs.core.MediaType;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.rest.WorkflowRestClient;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxButton;
+import org.apache.syncope.common.lib.SyncopeClientException;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.markup.html.form.AjaxButton;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.markup.html.form.Button;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.markup.html.form.TextArea;
+import org.apache.wicket.model.Model;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.apache.wicket.util.io.IOUtils;
+
+public class XMLEditorPopupPage extends BasePopupPage {
+
+ private static final long serialVersionUID = 5816041644635271734L;
+
+ @SpringBean
+ private WorkflowRestClient wfRestClient;
+
+ public XMLEditorPopupPage() {
+ Form wfForm = new Form("workflowDefForm");
+
+ String definition;
+ try {
+ definition = IOUtils.toString(wfRestClient.getDefinition(MediaType.APPLICATION_XML_TYPE));
+ } catch (IOException e) {
+ LOG.error("Could not get workflow definition", e);
+ definition = StringUtils.EMPTY;
+ }
+ final TextArea<String> workflowDefArea = new TextArea<String>("workflowDefArea", new Model<String>(definition));
+ wfForm.add(workflowDefArea);
+
+ AjaxButton submit =
+ new ClearIndicatingAjaxButton(APPLY, new Model<String>(getString(SUBMIT)), getPageReference()) {
+
+ private static final long serialVersionUID = -958724007591692537L;
+
+ @Override
+ protected void onSubmitInternal(final AjaxRequestTarget target, final Form<?> form) {
+ try {
+ wfRestClient.updateDefinition(
+ MediaType.APPLICATION_XML_TYPE, workflowDefArea.getModelObject());
+ info(getString(Constants.OPERATION_SUCCEEDED));
+ } catch (SyncopeClientException scee) {
+ error(getString(Constants.ERROR) + ": " + scee.getMessage());
+ }
+ feedbackPanel.refresh(target);
+ }
+
+ @Override
+ protected void onError(final AjaxRequestTarget target, final Form<?> form) {
+ feedbackPanel.refresh(target);
+ }
+ };
+
+ final Button close = new Button("closePage", new Model<String>(getString(CANCEL)));
+
+ MetaDataRoleAuthorizationStrategy.authorize(
+ submit, ENABLE, xmlRolesReader.getEntitlement("Configuration", "workflowDefUpdate"));
+ wfForm.add(submit);
+ wfForm.add(close);
+ this.add(wfForm);
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractExtensionPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractExtensionPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractExtensionPanel.java
new file mode 100644
index 0000000..a785e9f
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractExtensionPanel.java
@@ -0,0 +1,39 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import org.apache.syncope.client.console.commons.XMLRolesReader;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+
+public abstract class AbstractExtensionPanel extends Panel {
+
+ private static final long serialVersionUID = 4627828052717627159L;
+
+ @SpringBean
+ protected XMLRolesReader xmlRolesReader;
+
+ protected PageReference pageref;
+
+ public AbstractExtensionPanel(final String id, final PageReference pageref) {
+ super(id);
+ this.pageref = pageref;
+ }
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractProvisioningTasksPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractProvisioningTasksPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractProvisioningTasksPanel.java
new file mode 100644
index 0000000..e066aac
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractProvisioningTasksPanel.java
@@ -0,0 +1,160 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.List;
+import org.apache.syncope.client.console.commons.Constants;
+import org.apache.syncope.client.console.pages.PushTaskModalPage;
+import org.apache.syncope.client.console.pages.SyncTaskModalPage;
+import org.apache.syncope.client.console.pages.Tasks;
+import org.apache.syncope.client.console.pages.Tasks.TasksProvider;
+import org.apache.syncope.client.console.wicket.ajax.markup.html.ClearIndicatingAjaxLink;
+import org.apache.syncope.common.lib.to.AbstractProvisioningTaskTO;
+import org.apache.syncope.common.lib.to.AbstractTaskTO;
+import org.apache.syncope.common.lib.to.PushTaskTO;
+import org.apache.syncope.common.lib.to.SyncTaskTO;
+import org.apache.wicket.Page;
+import org.apache.wicket.PageReference;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.ajax.form.AjaxFormComponentUpdatingBehavior;
+import org.apache.wicket.ajax.markup.html.AjaxLink;
+import org.apache.wicket.authroles.authorization.strategies.role.metadata.MetaDataRoleAuthorizationStrategy;
+import org.apache.wicket.event.IEvent;
+import org.apache.wicket.extensions.ajax.markup.html.modal.ModalWindow;
+import org.apache.wicket.extensions.markup.html.repeater.data.table.IColumn;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.form.DropDownChoice;
+import org.apache.wicket.markup.html.form.Form;
+import org.apache.wicket.model.PropertyModel;
+import org.apache.wicket.request.http.WebResponse;
+
+public abstract class AbstractProvisioningTasksPanel<T extends AbstractProvisioningTaskTO> extends AbstractTasks {
+
+ private static final long serialVersionUID = -8674781241465369244L;
+
+ private final int paginatorRows;
+
+ protected WebMarkupContainer container;
+
+ protected ModalWindow window;
+
+ protected AjaxDataTablePanel<AbstractTaskTO, String> table;
+
+ private final Class<T> reference;
+
+ public AbstractProvisioningTasksPanel(final String id, final PageReference pageRef, final Class<T> reference) {
+ super(id, pageRef);
+
+ this.reference = reference;
+
+ container = new WebMarkupContainer("container");
+ container.setOutputMarkupId(true);
+ add(container);
+
+ window = new ModalWindow("taskWin");
+ window.setCssClassName(ModalWindow.CSS_CLASS_GRAY);
+ window.setInitialHeight(WIN_HEIGHT);
+ window.setInitialWidth(WIN_WIDTH);
+ window.setCookieName(VIEW_TASK_WIN_COOKIE_NAME);
+ add(window);
+
+ ((Tasks) pageRef.getPage()).setWindowClosedCallback(window, container);
+
+ paginatorRows = prefMan.getPaginatorRows(getWebRequest(), Constants.PREF_SYNC_TASKS_PAGINATOR_ROWS);
+ }
+
+ @Override
+ public void onEvent(final IEvent<?> event) {
+ if (event.getPayload() instanceof AbstractSearchResultPanel.EventDataWrapper) {
+ ((AbstractSearchResultPanel.EventDataWrapper) event.getPayload()).getTarget().add(container);
+ }
+ }
+
+ protected void initTasksTable() {
+
+ table = Tasks.updateTaskTable(
+ getColumns(),
+ new TasksProvider<T>(restClient, paginatorRows, getId(), this.reference),
+ container,
+ 0,
+ this.pageRef,
+ restClient);
+
+ Form paginatorForm = new Form("PaginatorForm");
+
+ @SuppressWarnings({ "unchecked", "rawtypes" })
+ final DropDownChoice rowsChooser = new DropDownChoice("rowsChooser", new PropertyModel(this, "paginatorRows"),
+ prefMan.getPaginatorChoices());
+
+ rowsChooser.add(new AjaxFormComponentUpdatingBehavior(Constants.ON_CHANGE) {
+
+ private static final long serialVersionUID = -1107858522700306810L;
+
+ @Override
+ protected void onUpdate(final AjaxRequestTarget target) {
+ prefMan.set(getWebRequest(), (WebResponse) getResponse(), Constants.PREF_SYNC_TASKS_PAGINATOR_ROWS,
+ String.valueOf(paginatorRows));
+
+ table = Tasks.updateTaskTable(
+ getColumns(),
+ new TasksProvider<T>(restClient, paginatorRows, getId(), reference),
+ container,
+ table == null ? 0 : (int) table.getCurrentPage(),
+ pageRef,
+ restClient);
+
+ target.add(container);
+ }
+ });
+
+ paginatorForm.add(rowsChooser);
+ container.add(paginatorForm);
+
+ // create new task
+ AjaxLink<Void> createLink = new ClearIndicatingAjaxLink<Void>("createLink", pageRef) {
+
+ private static final long serialVersionUID = -7978723352517770644L;
+
+ @Override
+ protected void onClickInternal(final AjaxRequestTarget target) {
+ window.setPageCreator(new ModalWindow.PageCreator() {
+
+ private static final long serialVersionUID = -7834632442532690940L;
+
+ @Override
+ public Page createPage() {
+ return reference.equals(SyncTaskTO.class)
+ ? new SyncTaskModalPage(window, new SyncTaskTO(), pageRef)
+ : new PushTaskModalPage(window, new PushTaskTO(), pageRef);
+ }
+ });
+
+ window.show(target);
+ }
+ };
+
+ MetaDataRoleAuthorizationStrategy.authorize(
+ createLink, RENDER, xmlRolesReader.getEntitlement(TASKS, "create"));
+
+ add(createLink);
+
+ }
+
+ protected abstract List<IColumn<AbstractTaskTO, String>> getColumns();
+}
http://git-wip-us.apache.org/repos/asf/syncope/blob/39f8a069/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractSearchPanel.java
----------------------------------------------------------------------
diff --git a/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractSearchPanel.java b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractSearchPanel.java
new file mode 100644
index 0000000..ba4411e
--- /dev/null
+++ b/client/old_console/src/main/java/org/apache/syncope/client/console/panels/AbstractSearchPanel.java
@@ -0,0 +1,401 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.syncope.client.console.panels;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.commons.lang3.math.NumberUtils;
+import org.apache.cxf.jaxrs.ext.search.ConditionType;
+import org.apache.cxf.jaxrs.ext.search.SearchBean;
+import org.apache.cxf.jaxrs.ext.search.SearchCondition;
+import org.apache.cxf.jaxrs.ext.search.client.CompleteCondition;
+import org.apache.cxf.jaxrs.ext.search.fiql.FiqlParser;
+import org.apache.syncope.client.console.rest.AuthRestClient;
+import org.apache.syncope.client.console.rest.ResourceRestClient;
+import org.apache.syncope.client.console.rest.SchemaRestClient;
+import org.apache.syncope.common.lib.search.GroupFiqlSearchConditionBuilder;
+import org.apache.syncope.common.lib.search.SearchableFields;
+import org.apache.syncope.common.lib.search.SpecialAttr;
+import org.apache.syncope.common.lib.search.AbstractFiqlSearchConditionBuilder;
+import org.apache.syncope.common.lib.search.SyncopeProperty;
+import org.apache.syncope.common.lib.search.UserFiqlSearchConditionBuilder;
+import org.apache.syncope.common.lib.to.ResourceTO;
+import org.apache.syncope.common.lib.types.AttributableType;
+import org.apache.syncope.common.lib.types.SubjectType;
+import org.apache.wicket.feedback.FeedbackMessage;
+import org.apache.wicket.feedback.IFeedbackMessageFilter;
+import org.apache.wicket.markup.html.WebMarkupContainer;
+import org.apache.wicket.markup.html.panel.Panel;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.model.LoadableDetachableModel;
+import org.apache.wicket.spring.injection.annot.SpringBean;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public abstract class AbstractSearchPanel extends Panel {
+
+ private static final long serialVersionUID = 5922413053568696414L;
+
+ /**
+ * Logger.
+ */
+ protected static final Logger LOG = LoggerFactory.getLogger(AbstractSearchPanel.class);
+
+ @SpringBean
+ protected SchemaRestClient schemaRestClient;
+
+ @SpringBean
+ protected ResourceRestClient resourceRestClient;
+
+ @SpringBean
+ protected AuthRestClient authRestClient;
+
+ protected IModel<List<String>> dnames;
+
+ protected IModel<List<String>> anames;
+
+ protected IModel<List<String>> resourceNames;
+
+ protected IModel<List<String>> entitlements;
+
+ protected IModel<List<SearchClause.Type>> types;
+
+ protected IModel<List<String>> groupNames;
+
+ protected NotificationPanel searchFeedback;
+
+ protected List<SearchClause> searchClauses;
+
+ protected WebMarkupContainer searchFormContainer;
+
+ protected AttributableType attributableType;
+
+ protected boolean required;
+
+ protected AbstractSearchPanel(final String id, final AttributableType attributableType) {
+ this(id, attributableType, null, true);
+ }
+
+ protected AbstractSearchPanel(final String id, final AttributableType attributableType,
+ final String fiql, final boolean required) {
+
+ super(id);
+ populate();
+
+ this.attributableType = attributableType;
+ this.required = required;
+
+ setOutputMarkupId(true);
+
+ searchFormContainer = new WebMarkupContainer("searchFormContainer");
+ searchFormContainer.setOutputMarkupId(true);
+
+ searchFeedback = new NotificationPanel("searchFeedback", "notificationpanel_top_right",
+ new IFeedbackMessageFilter() {
+
+ private static final long serialVersionUID = 6895024863321391672L;
+
+ @Override
+ public boolean accept(final FeedbackMessage message) {
+ boolean result;
+
+ // messages reported on the session have a null reporter
+ if (message.getReporter() == null) {
+ result = false;
+ } else {
+ // only accept messages coming from the children of the search form container
+ result = searchFormContainer.contains(message.getReporter(), true);
+ }
+
+ return result;
+ }
+ });
+ searchFeedback.setOutputMarkupId(true);
+ add(searchFeedback);
+
+ this.searchClauses = new ArrayList<>();
+ this.searchClauses.add(new SearchClause());
+ if (StringUtils.isNotBlank(fiql)) {
+ try {
+ FiqlParser<SearchBean> fiqlParser = new FiqlParser<>(
+ SearchBean.class, AbstractFiqlSearchConditionBuilder.CONTEXTUAL_PROPERTIES);
+ List<SearchClause> parsed = getSearchClauses(fiqlParser.parse(fiql));
+
+ this.searchClauses.clear();
+ this.searchClauses.addAll(parsed);
+ } catch (Exception e) {
+ LOG.error("Unparseable FIQL expression '{}'", fiql, e);
+ }
+ }
+
+ searchFormContainer.add(new SearchView("searchView", searchClauses, searchFormContainer, required,
+ types, anames, dnames, groupNames, resourceNames, entitlements));
+ add(searchFormContainer);
+ }
+
+ protected void populate() {
+ dnames = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ return SearchableFields.get(
+ attributableType == AttributableType.USER ? SubjectType.USER : SubjectType.GROUP);
+ }
+ };
+
+ anames = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ return schemaRestClient.getPlainSchemaNames(attributableType);
+ }
+ };
+
+ resourceNames = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ List<ResourceTO> resourceTOs = resourceRestClient.getAll();
+
+ List<String> result = new ArrayList<>(resourceTOs.size());
+
+ for (ResourceTO resource : resourceTOs) {
+ result.add(resource.getKey());
+ }
+
+ return result;
+ }
+ };
+
+ entitlements = new LoadableDetachableModel<List<String>>() {
+
+ private static final long serialVersionUID = 5275935387613157437L;
+
+ @Override
+ protected List<String> load() {
+ List<String> result = authRestClient.getOwnedEntitlements();
+ Collections.sort(result);
+ return result;
+ }
+ };
+ }
+
+ public NotificationPanel getSearchFeedback() {
+ return searchFeedback;
+ }
+
+ private SearchClause getPrimitiveSearchClause(final SearchCondition<SearchBean> sc) {
+ SearchClause searchClause = new SearchClause();
+
+ String property = sc.getCondition().getKeySet().iterator().next();
+ searchClause.setProperty(property);
+ String value = sc.getCondition().get(property);
+ searchClause.setValue(value);
+
+ if (SpecialAttr.GROUPS.toString().equals(property)) {
+ searchClause.setType(SearchClause.Type.MEMBERSHIP);
+ for (String label : groupNames.getObject()) {
+ if (value.equals(label.substring(0, label.indexOf(' ')))) {
+ searchClause.setProperty(label);
+ }
+ }
+ } else if (SpecialAttr.RESOURCES.toString().equals(property)) {
+ searchClause.setType(SearchClause.Type.RESOURCE);
+ } else if (SpecialAttr.ENTITLEMENTS.toString().equals(property)) {
+ searchClause.setType(SearchClause.Type.ENTITLEMENT);
+ } else {
+ searchClause.setType(SearchClause.Type.ATTRIBUTE);
+ }
+
+ switch (sc.getConditionType()) {
+ case EQUALS:
+ searchClause.setComparator(SpecialAttr.NULL.toString().equals(value)
+ ? SearchClause.Comparator.IS_NULL : SearchClause.Comparator.EQUALS);
+ break;
+
+ case NOT_EQUALS:
+ searchClause.setComparator(SpecialAttr.NULL.toString().equals(value)
+ ? SearchClause.Comparator.IS_NOT_NULL : SearchClause.Comparator.NOT_EQUALS);
+ break;
+
+ case GREATER_OR_EQUALS:
+ searchClause.setComparator(SearchClause.Comparator.GREATER_OR_EQUALS);
+ break;
+
+ case GREATER_THAN:
+ searchClause.setComparator(SearchClause.Comparator.GREATER_THAN);
+ break;
+
+ case LESS_OR_EQUALS:
+ searchClause.setComparator(SearchClause.Comparator.LESS_OR_EQUALS);
+ break;
+
+ case LESS_THAN:
+ searchClause.setComparator(SearchClause.Comparator.LESS_THAN);
+ break;
+
+ default:
+ break;
+ }
+
+ return searchClause;
+ }
+
+ private List<SearchClause> getCompoundSearchClause(final SearchCondition<SearchBean> sc) {
+ List<SearchClause> clauses = new ArrayList<SearchClause>();
+
+ for (SearchCondition<SearchBean> searchCondition : sc.getSearchConditions()) {
+ if (searchCondition.getStatement() == null) {
+ clauses.addAll(getCompoundSearchClause(searchCondition));
+ } else {
+ SearchClause clause = getPrimitiveSearchClause(searchCondition);
+ if (sc.getConditionType() == ConditionType.AND) {
+ clause.setOperator(SearchClause.Operator.AND);
+ }
+ if (sc.getConditionType() == ConditionType.OR) {
+ clause.setOperator(SearchClause.Operator.OR);
+ }
+ clauses.add(clause);
+ }
+ }
+
+ return clauses;
+ }
+
+ private List<SearchClause> getSearchClauses(final SearchCondition<SearchBean> sc) {
+ List<SearchClause> clauses = new ArrayList<SearchClause>();
+
+ if (sc.getStatement() == null) {
+ clauses.addAll(getCompoundSearchClause(sc));
+ } else {
+ clauses.add(getPrimitiveSearchClause(sc));
+ }
+
+ return clauses;
+ }
+
+ protected abstract AbstractFiqlSearchConditionBuilder getSearchConditionBuilder();
+
+ public String buildFIQL() {
+ LOG.debug("Generating FIQL from List<SearchClause>: {}", searchClauses);
+
+ if (searchClauses.isEmpty() || searchClauses.get(0).getType() == null) {
+ return StringUtils.EMPTY;
+ }
+
+ AbstractFiqlSearchConditionBuilder builder = getSearchConditionBuilder();
+
+ CompleteCondition prevCondition;
+ CompleteCondition condition = null;
+ for (int i = 0; i < searchClauses.size(); i++) {
+ prevCondition = condition;
+
+ switch (searchClauses.get(i).getType()) {
+ case ENTITLEMENT:
+ condition = searchClauses.get(i).getComparator() == SearchClause.Comparator.EQUALS
+ ? ((GroupFiqlSearchConditionBuilder) builder).
+ hasEntitlements(searchClauses.get(i).getProperty())
+ : ((GroupFiqlSearchConditionBuilder) builder).
+ hasNotEntitlements(searchClauses.get(i).getProperty());
+ break;
+
+ case MEMBERSHIP:
+ Long groupId = NumberUtils.toLong(searchClauses.get(i).getProperty().split(" ")[0]);
+ condition = searchClauses.get(i).getComparator() == SearchClause.Comparator.EQUALS
+ ? ((UserFiqlSearchConditionBuilder) builder).inGroups(groupId)
+ : ((UserFiqlSearchConditionBuilder) builder).notInGroups(groupId);
+ break;
+
+ case RESOURCE:
+ condition = searchClauses.get(i).getComparator() == SearchClause.Comparator.EQUALS
+ ? builder.hasResources(searchClauses.get(i).getProperty())
+ : builder.hasNotResources(searchClauses.get(i).getProperty());
+ break;
+
+ case ATTRIBUTE:
+ SyncopeProperty property = builder.is(searchClauses.get(i).getProperty());
+ switch (searchClauses.get(i).getComparator()) {
+ case IS_NULL:
+ condition = builder.isNull(searchClauses.get(i).getProperty());
+ break;
+
+ case IS_NOT_NULL:
+ condition = builder.isNotNull(searchClauses.get(i).getProperty());
+ break;
+
+ case LESS_THAN:
+ condition = StringUtils.isNumeric(searchClauses.get(i).getProperty())
+ ? property.lessThan(NumberUtils.toDouble(searchClauses.get(i).getValue()))
+ : property.lexicalBefore(searchClauses.get(i).getValue());
+ break;
+
+ case LESS_OR_EQUALS:
+ condition = StringUtils.isNumeric(searchClauses.get(i).getProperty())
+ ? property.lessOrEqualTo(NumberUtils.toDouble(searchClauses.get(i).getValue()))
+ : property.lexicalNotAfter(searchClauses.get(i).getValue());
+ break;
+
+ case GREATER_THAN:
+ condition = StringUtils.isNumeric(searchClauses.get(i).getProperty())
+ ? property.greaterThan(NumberUtils.toDouble(searchClauses.get(i).getValue()))
+ : property.lexicalAfter(searchClauses.get(i).getValue());
+ break;
+
+ case GREATER_OR_EQUALS:
+ condition = StringUtils.isNumeric(searchClauses.get(i).getProperty())
+ ? property.greaterOrEqualTo(NumberUtils.toDouble(searchClauses.get(i).getValue()))
+ : property.lexicalNotBefore(searchClauses.get(i).getValue());
+ break;
+
+ case NOT_EQUALS:
+ condition = property.notEqualTo(searchClauses.get(i).getValue());
+ break;
+
+ case EQUALS:
+ default:
+ condition = property.equalTo(searchClauses.get(i).getValue());
+ break;
+ }
+ default:
+ break;
+ }
+
+ if (i > 0) {
+ if (searchClauses.get(i).getOperator() == SearchClause.Operator.AND) {
+ condition = builder.and(prevCondition, condition);
+ }
+ if (searchClauses.get(i).getOperator() == SearchClause.Operator.OR) {
+ condition = builder.or(prevCondition, condition);
+ }
+ }
+ }
+
+ String fiql = condition == null ? StringUtils.EMPTY : condition.query();
+ LOG.debug("Generated FIQL: {}", fiql);
+ return fiql;
+ }
+}