diff --git a/src/main/java/org/gcube/portlets/user/td/client/resource/TabularDataResources.java b/src/main/java/org/gcube/portlets/user/td/client/resource/TabularDataResources.java index ca509e2..e8ab342 100644 --- a/src/main/java/org/gcube/portlets/user/td/client/resource/TabularDataResources.java +++ b/src/main/java/org/gcube/portlets/user/td/client/resource/TabularDataResources.java @@ -159,13 +159,24 @@ public interface TabularDataResources extends ClientBundle { @Source("rule-share_32.png") ImageResource ruleShare32(); + @Source("rule-column-add.png") + ImageResource ruleColumnAdd(); + @Source("rule-column-add_32.png") + ImageResource ruleColumnAdd32(); + + @Source("rule-column-apply.png") + ImageResource ruleColumnApply(); + + @Source("rule-column-apply_32.png") + ImageResource ruleColumnApply32(); + + @Source("rule-tabularresource.png") + ImageResource ruleTabularResource(); + + @Source("rule-tabularresource_32.png") + ImageResource ruleTabularResource32(); - @Source("rules.png") - ImageResource rules(); - - @Source("rules_32.png") - ImageResource rules32(); @Source("table-filter_32.png") ImageResource filter32(); diff --git a/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-add.png b/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-add.png new file mode 100644 index 0000000..15e8736 Binary files /dev/null and b/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-add.png differ diff --git a/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-add_32.png b/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-add_32.png new file mode 100644 index 0000000..230cb1b Binary files /dev/null and b/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-add_32.png differ diff --git a/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-apply.png b/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-apply.png new file mode 100644 index 0000000..1148d23 Binary files /dev/null and b/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-apply.png differ diff --git a/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-apply_32.png b/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-apply_32.png new file mode 100644 index 0000000..212fda5 Binary files /dev/null and b/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-apply_32.png differ diff --git a/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-close.png b/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-close.png new file mode 100644 index 0000000..90c75ed Binary files /dev/null and b/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-close.png differ diff --git a/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-close_32.png b/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-close_32.png new file mode 100644 index 0000000..fb3b6e4 Binary files /dev/null and b/src/main/java/org/gcube/portlets/user/td/client/resource/rule-column-close_32.png differ diff --git a/src/main/java/org/gcube/portlets/user/td/client/resource/rule-tabularresource.png b/src/main/java/org/gcube/portlets/user/td/client/resource/rule-tabularresource.png new file mode 100644 index 0000000..f0cd78c Binary files /dev/null and b/src/main/java/org/gcube/portlets/user/td/client/resource/rule-tabularresource.png differ diff --git a/src/main/java/org/gcube/portlets/user/td/client/resource/rule-tabularresource_32.png b/src/main/java/org/gcube/portlets/user/td/client/resource/rule-tabularresource_32.png new file mode 100644 index 0000000..1d53f7d Binary files /dev/null and b/src/main/java/org/gcube/portlets/user/td/client/resource/rule-tabularresource_32.png differ diff --git a/src/main/java/org/gcube/portlets/user/td/client/resource/rules.png b/src/main/java/org/gcube/portlets/user/td/client/resource/rules.png deleted file mode 100644 index 80dbcf7..0000000 Binary files a/src/main/java/org/gcube/portlets/user/td/client/resource/rules.png and /dev/null differ diff --git a/src/main/java/org/gcube/portlets/user/td/client/resource/rules_32.png b/src/main/java/org/gcube/portlets/user/td/client/resource/rules_32.png deleted file mode 100644 index 60c9feb..0000000 Binary files a/src/main/java/org/gcube/portlets/user/td/client/resource/rules_32.png and /dev/null differ diff --git a/src/main/java/org/gcube/portlets/user/td/client/ribbon/RuleToolBar.java b/src/main/java/org/gcube/portlets/user/td/client/ribbon/RuleToolBar.java index 393bf26..2a9f569 100644 --- a/src/main/java/org/gcube/portlets/user/td/client/ribbon/RuleToolBar.java +++ b/src/main/java/org/gcube/portlets/user/td/client/ribbon/RuleToolBar.java @@ -36,13 +36,13 @@ public class RuleToolBar { private EventBus eventBus; private ToolBar toolBar; - //Rules + // Rules private TextButton ruleNewButton; private TextButton ruleOpenButton; private TextButton ruleDeleteButton; private TextButton ruleApplyButton; - //private TextButton ruleShareButton; - + + // private TextButton ruleShareButton; public RuleToolBar(EventBus eventBus) { this.eventBus = eventBus; @@ -55,40 +55,22 @@ public class RuleToolBar { protected void build() { RuleToolBarMessages msgs = GWT.create(RuleToolBarMessages.class); - + toolBar = new ToolBar(); toolBar.setSpacing(1); toolBar.setEnableOverflow(false); - + // Rules ButtonGroup rulesGroup = new ButtonGroup(); rulesGroup.setId("Manage"); rulesGroup.setStyleName("ribbon"); rulesGroup.setHeadingText(msgs.ruleGroupHeadingText()); - //templateGroup.disable(); + // templateGroup.disable(); toolBar.add(rulesGroup); FlexTable ruleLayout = new FlexTable(); rulesGroup.add(ruleLayout); - ruleNewButton = new TextButton(msgs.ruleNewButton(), - TabularDataResources.INSTANCE.ruleAdd32()); - ruleNewButton.enable(); - ruleNewButton.setToolTip(msgs.ruleNewButtonToolTip()); - ruleNewButton.setScale(ButtonScale.LARGE); - ruleNewButton.setIconAlign(IconAlign.TOP); - ruleNewButton.setArrowAlign(ButtonArrowAlign.BOTTOM); - ruleNewButton.addSelectHandler(new SelectHandler() { - - public void onSelect(SelectEvent event) { - eventBus.fireEvent(new RibbonEvent( - RibbonType.RULE_NEW)); - } - }); - - ruleLayout.setWidget(0, 0, ruleNewButton); - ruleLayout.getFlexCellFormatter().setRowSpan(0, 0, 2); - ruleOpenButton = new TextButton(msgs.ruleOpenButton(), TabularDataResources.INSTANCE.ruleEdit32()); ruleOpenButton.enable(); @@ -99,15 +81,13 @@ public class RuleToolBar { ruleOpenButton.addSelectHandler(new SelectHandler() { public void onSelect(SelectEvent event) { - eventBus.fireEvent(new RibbonEvent( - RibbonType.RULE_MODIFY)); + eventBus.fireEvent(new RibbonEvent(RibbonType.RULE_MODIFY)); } }); - ruleLayout.setWidget(0, 1, ruleOpenButton); - ruleLayout.getFlexCellFormatter().setRowSpan(0, 1, 2); - - + ruleLayout.setWidget(0, 0, ruleOpenButton); + ruleLayout.getFlexCellFormatter().setRowSpan(0, 0, 2); + ruleDeleteButton = new TextButton(msgs.ruleDeleteButton(), TabularDataResources.INSTANCE.ruleDelete32()); ruleDeleteButton.enable(); @@ -118,17 +98,64 @@ public class RuleToolBar { ruleDeleteButton.addSelectHandler(new SelectHandler() { public void onSelect(SelectEvent event) { - eventBus.fireEvent(new RibbonEvent( - RibbonType.RULE_DELETE)); + eventBus.fireEvent(new RibbonEvent(RibbonType.RULE_DELETE)); + } + }); + + ruleLayout.setWidget(0, 1, ruleDeleteButton); + ruleLayout.getFlexCellFormatter().setRowSpan(0, 1, 2); + + + + /* + * ruleShareButton = new TextButton(msgs.ruleShareButton(), + * TabularDataResources.INSTANCE.ruleShare32()); + * ruleShareButton.enable(); + * ruleShareButton.setScale(ButtonScale.LARGE); + * ruleShareButton.setIconAlign(IconAlign.TOP); + * ruleShareButton.setToolTip(msgs.ruleShareButtonToolTip()); + * ruleShareButton.setArrowAlign(ButtonArrowAlign.BOTTOM); + * ruleShareButton.addSelectHandler(new SelectHandler() { + * + * public void onSelect(SelectEvent event) { eventBus.fireEvent(new + * RibbonEvent(RibbonType.RULE_SHARE)); } }); + * + * ruleLayout.setWidget(0, 3, ruleShareButton); + * ruleLayout.getFlexCellFormatter().setRowSpan(0, 3, 2); + */ + + cleanCells(ruleLayout.getElement()); + + // Column Rules + ButtonGroup ruleOnColumnGroup = new ButtonGroup(); + ruleOnColumnGroup.setId("On Column"); + ruleOnColumnGroup.setStyleName("ribbon"); + ruleOnColumnGroup.setHeadingText(msgs.ruleOnColumnGroupHeadingText()); + + toolBar.add(ruleOnColumnGroup); + + FlexTable ruleOnColumnLayout = new FlexTable(); + ruleOnColumnGroup.add(ruleOnColumnLayout); + + ruleNewButton = new TextButton(msgs.ruleNewButton(), + TabularDataResources.INSTANCE.ruleColumnAdd32()); + ruleNewButton.enable(); + ruleNewButton.setToolTip(msgs.ruleNewButtonToolTip()); + ruleNewButton.setScale(ButtonScale.LARGE); + ruleNewButton.setIconAlign(IconAlign.TOP); + ruleNewButton.setArrowAlign(ButtonArrowAlign.BOTTOM); + ruleNewButton.addSelectHandler(new SelectHandler() { + + public void onSelect(SelectEvent event) { + eventBus.fireEvent(new RibbonEvent(RibbonType.RULE_NEW)); } }); - ruleLayout.setWidget(0, 2, ruleDeleteButton); - ruleLayout.getFlexCellFormatter().setRowSpan(0, 2, 2); - + ruleOnColumnLayout.setWidget(0, 0, ruleNewButton); + ruleOnColumnLayout.getFlexCellFormatter().setRowSpan(0, 0, 2); ruleApplyButton = new TextButton(msgs.ruleApplyButton(), - TabularDataResources.INSTANCE.ruleApply32()); + TabularDataResources.INSTANCE.ruleColumnApply32()); ruleApplyButton.disable(); ruleApplyButton.setScale(ButtonScale.LARGE); ruleApplyButton.setIconAlign(IconAlign.TOP); @@ -141,27 +168,8 @@ public class RuleToolBar { } }); - ruleLayout.setWidget(0, 3, ruleApplyButton); - ruleLayout.getFlexCellFormatter().setRowSpan(0, 3, 2); - - /* - ruleShareButton = new TextButton(msgs.ruleShareButton(), - TabularDataResources.INSTANCE.ruleShare32()); - ruleShareButton.enable(); - ruleShareButton.setScale(ButtonScale.LARGE); - ruleShareButton.setIconAlign(IconAlign.TOP); - ruleShareButton.setToolTip(msgs.ruleShareButtonToolTip()); - ruleShareButton.setArrowAlign(ButtonArrowAlign.BOTTOM); - ruleShareButton.addSelectHandler(new SelectHandler() { - - public void onSelect(SelectEvent event) { - eventBus.fireEvent(new RibbonEvent(RibbonType.RULE_SHARE)); - } - }); - - ruleLayout.setWidget(0, 4, ruleShareButton); - ruleLayout.getFlexCellFormatter().setRowSpan(0, 4, 2); - */ + ruleOnColumnLayout.setWidget(0, 1, ruleApplyButton); + ruleOnColumnLayout.getFlexCellFormatter().setRowSpan(0, 1, 2); cleanCells(ruleLayout.getElement()); @@ -196,31 +204,31 @@ public class RuleToolBar { ruleNewButton.enable(); ruleDeleteButton.enable(); ruleApplyButton.disable(); - //ruleShareButton.enable(); + // ruleShareButton.enable(); break; case TR_CLOSE: - case TR_READONLY: + case TR_READONLY: ruleOpenButton.enable(); ruleNewButton.enable(); ruleDeleteButton.enable(); ruleApplyButton.disable(); - //ruleShareButton.enable(); + // ruleShareButton.enable(); break; case TR_OPEN: case TABLEUPDATE: - case TABLECURATION: + case TABLECURATION: ruleOpenButton.enable(); ruleNewButton.enable(); ruleDeleteButton.enable(); ruleApplyButton.enable(); - //ruleShareButton.enable(); + // ruleShareButton.enable(); break; case WIZARD_OPEN: ruleOpenButton.disable(); ruleNewButton.disable(); ruleDeleteButton.disable(); ruleApplyButton.disable(); - //ruleShareButton.disable(); + // ruleShareButton.disable(); break; default: break; diff --git a/src/main/java/org/gcube/portlets/user/td/client/ribbon/RuleToolBarMessages.java b/src/main/java/org/gcube/portlets/user/td/client/ribbon/RuleToolBarMessages.java index 3652d54..83cdff7 100644 --- a/src/main/java/org/gcube/portlets/user/td/client/ribbon/RuleToolBarMessages.java +++ b/src/main/java/org/gcube/portlets/user/td/client/ribbon/RuleToolBarMessages.java @@ -12,13 +12,7 @@ public interface RuleToolBarMessages extends Messages { @DefaultMessage("Manage") String ruleGroupHeadingText(); - - @DefaultMessage("New") - String ruleNewButton(); - - @DefaultMessage("New") - String ruleNewButtonToolTip(); - + @DefaultMessage("Open") String ruleOpenButton(); @@ -30,6 +24,22 @@ public interface RuleToolBarMessages extends Messages { @DefaultMessage("Delete") String ruleDeleteButtonToolTip(); + + @DefaultMessage("Share") + String ruleShareButton(); + + @DefaultMessage("Share") + String ruleShareButtonToolTip(); + + + @DefaultMessage("On Column") + String ruleOnColumnGroupHeadingText(); + + @DefaultMessage("New") + String ruleNewButton(); + + @DefaultMessage("New") + String ruleNewButtonToolTip(); @DefaultMessage("Apply") String ruleApplyButton(); @@ -37,11 +47,7 @@ public interface RuleToolBarMessages extends Messages { @DefaultMessage("Apply") String ruleApplyButtonToolTip(); - @DefaultMessage("Share") - String ruleShareButton(); - - @DefaultMessage("Share") - String ruleShareButtonToolTip(); + } \ No newline at end of file diff --git a/src/main/java/org/gcube/portlets/user/td/client/rule/RuleApplyDialog.java b/src/main/java/org/gcube/portlets/user/td/client/rule/RuleApplyDialog.java index c0b7f63..96e2c93 100644 --- a/src/main/java/org/gcube/portlets/user/td/client/rule/RuleApplyDialog.java +++ b/src/main/java/org/gcube/portlets/user/td/client/rule/RuleApplyDialog.java @@ -5,7 +5,7 @@ import org.gcube.portlets.user.td.expressionwidget.client.rpc.ExpressionServiceA import org.gcube.portlets.user.td.gwtservice.shared.exception.TDGWTIsFinalException; import org.gcube.portlets.user.td.gwtservice.shared.exception.TDGWTIsLockedException; import org.gcube.portlets.user.td.gwtservice.shared.exception.TDGWTSessionExpiredException; -import org.gcube.portlets.user.td.gwtservice.shared.rule.RulesOnColumnApplySession; +import org.gcube.portlets.user.td.gwtservice.shared.rule.ApplyColumnRulesSession; import org.gcube.portlets.user.td.monitorwidget.client.MonitorDialog; import org.gcube.portlets.user.td.monitorwidget.client.MonitorDialogListener; import org.gcube.portlets.user.td.tablewidget.client.util.UtilsGXT3; @@ -40,9 +40,9 @@ public class RuleApplyDialog extends Window implements this.eventBus = eventBus; initWindow(); - RuleApplyPanel templateApplyPanel = new RuleApplyPanel(this, + RuleApplyPanel ruleApplyPanel = new RuleApplyPanel(this, trId, eventBus); - add(templateApplyPanel); + add(ruleApplyPanel); } protected void initWindow() { @@ -50,11 +50,11 @@ public class RuleApplyDialog extends Window implements setHeight(HEIGHT); setBodyBorder(false); setResizable(false); - setHeadingText("Apply Template"); + setHeadingText("Apply Column Rule"); setClosable(true); setModal(true); forceLayoutOnResize = true; - getHeader().setIcon(TabularDataResources.INSTANCE.ruleApply()); + getHeader().setIcon(TabularDataResources.INSTANCE.ruleColumnApply()); } @@ -78,8 +78,8 @@ public class RuleApplyDialog extends Window implements hide(); } - protected void applyRules(RulesOnColumnApplySession ruleOnColumnApplySession) { - ExpressionServiceAsync.INSTANCE.startRulesOnColumnApply(ruleOnColumnApplySession, new AsyncCallback() { + protected void applyRules(ApplyColumnRulesSession applyColumnRulesSession) { + ExpressionServiceAsync.INSTANCE.startApplyColumnRules(applyColumnRulesSession, new AsyncCallback() { @Override public void onFailure(Throwable caught) { diff --git a/src/main/java/org/gcube/portlets/user/td/client/rule/RuleApplyPanel.java b/src/main/java/org/gcube/portlets/user/td/client/rule/RuleApplyPanel.java index 8017a32..b58ee15 100644 --- a/src/main/java/org/gcube/portlets/user/td/client/rule/RuleApplyPanel.java +++ b/src/main/java/org/gcube/portlets/user/td/client/rule/RuleApplyPanel.java @@ -11,8 +11,8 @@ import org.gcube.portlets.user.td.gwtservice.client.rpc.TDGWTServiceAsync; import org.gcube.portlets.user.td.gwtservice.shared.exception.TDGWTIsFinalException; import org.gcube.portlets.user.td.gwtservice.shared.exception.TDGWTIsLockedException; import org.gcube.portlets.user.td.gwtservice.shared.exception.TDGWTSessionExpiredException; +import org.gcube.portlets.user.td.gwtservice.shared.rule.ApplyColumnRulesSession; import org.gcube.portlets.user.td.gwtservice.shared.rule.RuleDescriptionData; -import org.gcube.portlets.user.td.gwtservice.shared.rule.RulesOnColumnApplySession; import org.gcube.portlets.user.td.tablewidget.client.util.UtilsGXT3; import org.gcube.portlets.user.td.widgetcommonevent.client.event.SessionExpiredEvent; import org.gcube.portlets.user.td.widgetcommonevent.client.type.SessionExpiredType; @@ -36,12 +36,15 @@ import com.sencha.gxt.data.shared.LabelProvider; import com.sencha.gxt.data.shared.ListStore; import com.sencha.gxt.dnd.core.client.GridDragSource; import com.sencha.gxt.dnd.core.client.GridDropTarget; +import com.sencha.gxt.widget.core.client.Dialog; +import com.sencha.gxt.widget.core.client.Dialog.PredefinedButton; import com.sencha.gxt.widget.core.client.FramedPanel; import com.sencha.gxt.widget.core.client.button.TextButton; import com.sencha.gxt.widget.core.client.container.BoxLayoutContainer.BoxLayoutData; import com.sencha.gxt.widget.core.client.container.BoxLayoutContainer.BoxLayoutPack; import com.sencha.gxt.widget.core.client.container.HBoxLayoutContainer; import com.sencha.gxt.widget.core.client.container.HBoxLayoutContainer.HBoxLayoutAlign; +import com.sencha.gxt.widget.core.client.container.MarginData; import com.sencha.gxt.widget.core.client.container.VerticalLayoutContainer; import com.sencha.gxt.widget.core.client.container.VerticalLayoutContainer.VerticalLayoutData; import com.sencha.gxt.widget.core.client.event.SelectEvent; @@ -49,12 +52,17 @@ import com.sencha.gxt.widget.core.client.event.SelectEvent.SelectHandler; import com.sencha.gxt.widget.core.client.form.ComboBox; import com.sencha.gxt.widget.core.client.form.FieldLabel; import com.sencha.gxt.widget.core.client.form.FieldSet; +import com.sencha.gxt.widget.core.client.form.TextArea; +import com.sencha.gxt.widget.core.client.form.TextField; import com.sencha.gxt.widget.core.client.grid.ColumnConfig; import com.sencha.gxt.widget.core.client.grid.ColumnModel; import com.sencha.gxt.widget.core.client.grid.Grid; import com.sencha.gxt.widget.core.client.grid.filters.GridFilters; import com.sencha.gxt.widget.core.client.grid.filters.StringFilter; import com.sencha.gxt.widget.core.client.info.Info; +import com.sencha.gxt.widget.core.client.menu.Item; +import com.sencha.gxt.widget.core.client.menu.Menu; +import com.sencha.gxt.widget.core.client.menu.MenuItem; /** * @@ -81,26 +89,23 @@ public class RuleApplyPanel extends FramedPanel { private ColumnData column; private ArrayList applicableRules; private ArrayList appliesRules; - - + private TextButton btnApply; private TextButton btnClose; - + private ComboBox comboColumns; private ListStore applicableRulesStore; private Grid gridApplicableRules; private ListStore appliesRulesStore; private Grid gridAppliesRules; - - - public RuleApplyPanel(RuleApplyDialog parent, TRId trId, EventBus eventBus) { + public RuleApplyPanel(RuleApplyDialog parent, TRId trId, EventBus eventBus) { this.parent = parent; this.trId = trId; - applicableRules=new ArrayList(); - appliesRules=new ArrayList(); - - Log.debug("TemplateApplyPanel"); + applicableRules = new ArrayList(); + appliesRules = new ArrayList(); + + Log.debug("RuleApplyPanel"); setWidth(WIDTH); setHeight(HEIGHT); setHeaderVisible(false); @@ -191,11 +196,6 @@ public class RuleApplyPanel extends FramedPanel { new VerticalLayoutData(1, -1, new Margins(0))); // Rules - // IdentityValueProvider identity = new - // IdentityValueProvider(); - // CheckBoxSelectionModel sm = new - // CheckBoxSelectionModel( - // identity); RuleDescriptionDataProperties propsRules = GWT .create(RuleDescriptionDataProperties.class); @@ -212,6 +212,8 @@ public class RuleApplyPanel extends FramedPanel { sb.append(ruleApplyTemplates.format(value)); } }); + + ColumnConfig descriptionCol = new ColumnConfig( propsRules.description(), 120, "Description"); @@ -258,10 +260,11 @@ public class RuleApplyPanel extends FramedPanel { ColumnModel cm = new ColumnModel( l); - - StringFilter nameFilter = new StringFilter(propsRules.name()); - StringFilter descriptionFilter = new StringFilter(propsRules.description()); - + + StringFilter nameFilter = new StringFilter( + propsRules.name()); + StringFilter descriptionFilter = new StringFilter( + propsRules.description()); // Applicable Rules applicableRulesStore = new ListStore( @@ -278,21 +281,19 @@ public class RuleApplyPanel extends FramedPanel { gridApplicableRules.setColumnReordering(true); gridApplicableRules.setColumnResize(true); gridApplicableRules.getView().setAutoExpandColumn(descriptionCol); - - + GridFilters filtersApplicableRules = new GridFilters(); filtersApplicableRules.initPlugin(gridApplicableRules); filtersApplicableRules.setLocal(true); filtersApplicableRules.addFilter(nameFilter); filtersApplicableRules.addFilter(descriptionFilter); - + + createContextMenu(gridApplicableRules); // Applies Rules - appliesRulesStore = new ListStore( - propsRules.id()); + appliesRulesStore = new ListStore(propsRules.id()); - gridAppliesRules = new Grid( - appliesRulesStore, cm); + gridAppliesRules = new Grid(appliesRulesStore, cm); gridAppliesRules.setHeight(RULES_GRID_HEIGHT); gridAppliesRules.getView().setStripeRows(true); gridAppliesRules.getView().setColumnLines(true); @@ -302,41 +303,43 @@ public class RuleApplyPanel extends FramedPanel { gridAppliesRules.setColumnReordering(true); gridAppliesRules.setColumnResize(true); gridAppliesRules.getView().setAutoExpandColumn(descriptionCol); - + GridFilters filtersAppliesRules = new GridFilters(); filtersAppliesRules.initPlugin(gridAppliesRules); filtersAppliesRules.setLocal(true); filtersAppliesRules.addFilter(nameFilter); filtersAppliesRules.addFilter(descriptionFilter); - - // - - new GridDragSource(gridApplicableRules).setGroup(SET_RULES); - new GridDragSource(gridAppliesRules).setGroup(SET_RULES); + createContextMenu(gridAppliesRules); - new GridDropTarget(gridApplicableRules).setGroup(SET_RULES); - new GridDropTarget(gridAppliesRules).setGroup(SET_RULES); - - - - // - FieldLabel rulesApplicableLabel = new FieldLabel(gridApplicableRules, "Applicable Rules"); + + new GridDragSource(gridApplicableRules) + .setGroup(SET_RULES); + new GridDragSource(gridAppliesRules) + .setGroup(SET_RULES); + + new GridDropTarget(gridApplicableRules) + .setGroup(SET_RULES); + new GridDropTarget(gridAppliesRules) + .setGroup(SET_RULES); + + // + FieldLabel rulesApplicableLabel = new FieldLabel(gridApplicableRules, + "Applicable Rules"); configurationFieldSetLayout.add(rulesApplicableLabel, new VerticalLayoutData(1, -1, new Margins(0))); - - - FieldLabel rulesAppliesLabel = new FieldLabel(gridAppliesRules, "Applies Rules"); - + + FieldLabel rulesAppliesLabel = new FieldLabel(gridAppliesRules, + "Applies Rules"); + configurationFieldSetLayout.add(rulesAppliesLabel, new VerticalLayoutData(1, -1, new Margins(0))); - // Button btnApply = new TextButton("Apply"); - btnApply.setIcon(TabularDataResources.INSTANCE.ruleApply()); + btnApply.setIcon(TabularDataResources.INSTANCE.ruleColumnApply()); btnApply.setIconAlign(IconAlign.RIGHT); btnApply.setToolTip("Apply Template"); btnApply.addSelectHandler(new SelectHandler() { @@ -398,11 +401,10 @@ public class RuleApplyPanel extends FramedPanel { protected void updateRulesInGrids(ColumnData columnData) { column = columnData; getApplicableBaseColumnRules(); - } - - protected void getApplicableBaseColumnRules(){ + + protected void getApplicableBaseColumnRules() { ExpressionServiceAsync.INSTANCE.getApplicableBaseColumnRules(column, new AsyncCallback>() { @@ -423,15 +425,15 @@ public class RuleApplyPanel extends FramedPanel { @Override public void onSuccess(ArrayList result) { Log.trace("loaded " + result.size() + " Rules"); - applicableRules=result; + applicableRules = result; getAppliesBaseColumnRules(); - + } }); } - protected void getAppliesBaseColumnRules(){ + protected void getAppliesBaseColumnRules() { ExpressionServiceAsync.INSTANCE.getApplicableBaseColumnRules(column, new AsyncCallback>() { @@ -447,18 +449,21 @@ public class RuleApplyPanel extends FramedPanel { UtilsGXT3.alert("Error retrieving rules", "Error retrieving applicable rules"); } - } @Override public void onSuccess(ArrayList result) { Log.trace("loaded " + result.size() + " Rules"); - appliesRules=result; + appliesRules = result; applicableRulesStore.clear(); - applicableRulesStore.addAll(applicableRules); + applicableRulesStore + .addAll(new ArrayList( + applicableRules)); appliesRulesStore.clear(); - appliesRulesStore.addAll(appliesRules); + appliesRulesStore + .addAll(new ArrayList( + appliesRules)); forceLayout(); } @@ -474,12 +479,26 @@ public class RuleApplyPanel extends FramedPanel { } protected void apply() { - ArrayList selectedRules = getSelectedItems(); ColumnData column = comboColumns.getCurrentValue(); if (column != null) { - RulesOnColumnApplySession rulesOnColumnApplySession = new RulesOnColumnApplySession( - trId, column, selectedRules); - parent.applyRules(rulesOnColumnApplySession); + ArrayList selectedRules = getSelectedItems(); + ArrayList rulesToBeApplied = new ArrayList(); + for (RuleDescriptionData ruleSelected : selectedRules) { + boolean ruleApplied = false; + for (RuleDescriptionData ruleAlreadyApplied : appliesRules) { + if (ruleSelected.getId() == ruleAlreadyApplied.getId()) { + ruleApplied = true; + break; + } + } + if (ruleApplied == false) { + rulesToBeApplied.add(ruleSelected); + } + } + + ApplyColumnRulesSession applyColumnRulesSession = new ApplyColumnRulesSession( + trId, column, rulesToBeApplied); + parent.applyRules(applyColumnRulesSession); } else { Log.error("No column selected"); UtilsGXT3.alert("Attention", "Select a column"); @@ -490,4 +509,96 @@ public class RuleApplyPanel extends FramedPanel { parent.close(); } + protected void requestInfo(RuleDescriptionData rule) { + + final Dialog infoRuleDialog = new Dialog(); + infoRuleDialog.setHeadingText("Info Rule"); + infoRuleDialog.getHeader().setIcon( + TabularDataResources.INSTANCE.information()); + infoRuleDialog.setPredefinedButtons(PredefinedButton.OK); + + FieldSet configurationFieldSet = new FieldSet(); + configurationFieldSet.setHeadingText("Configuration"); + configurationFieldSet.setCollapsible(false); + configurationFieldSet.setBorders(true); + + VerticalLayoutContainer configurationFieldSetLayout = new VerticalLayoutContainer(); + configurationFieldSet.add(configurationFieldSetLayout, + new MarginData(0)); + + TextField ruleName = new TextField(); + ruleName.setToolTip("Rule Name"); + ruleName.setValue(rule.getName()); + ruleName.setReadOnly(true); + FieldLabel ruleNameLabel = new FieldLabel(ruleName, "Name"); + configurationFieldSetLayout.add(ruleNameLabel, new VerticalLayoutData( + 1, -1, new Margins(0))); + + TextField ruleScope = new TextField(); + ruleScope.setToolTip("Rule Scope"); + ruleScope.setValue(rule.getScopeLabel()); + ruleScope.setReadOnly(true); + FieldLabel ruleScopeLabel = new FieldLabel(ruleScope, "Scope"); + configurationFieldSetLayout.add(ruleScopeLabel, new VerticalLayoutData( + 1, -1, new Margins(0))); + + TextArea ruleDescription = new TextArea(); + ruleDescription.setToolTip("Rule Description"); + ruleDescription.setValue(rule.getDescription()); + ruleDescription.setReadOnly(true); + FieldLabel ruleDescriptionLabel = new FieldLabel(ruleDescription, + "Description"); + configurationFieldSetLayout.add(ruleDescriptionLabel, + new VerticalLayoutData(1, -1, new Margins(0))); + + TextField ruleOwner = new TextField(); + ruleOwner.setToolTip("Rule Owner"); + ruleOwner.setValue(rule.getOwner()); + ruleOwner.setReadOnly(true); + FieldLabel ruleOwnerLabel = new FieldLabel(ruleOwner, "Owner"); + configurationFieldSetLayout.add(ruleOwnerLabel, new VerticalLayoutData( + 1, -1, new Margins(0))); + + TextArea ruleExpression = new TextArea(); + ruleExpression.setToolTip("Rule Expression"); + ruleExpression.setValue(rule.getReadableExpression()); + ruleExpression.setReadOnly(true); + ruleExpression.setHeight("82px"); + FieldLabel ruleExpressionLabel = new FieldLabel(ruleExpression, + "Expression"); + configurationFieldSetLayout.add(ruleExpressionLabel, + new VerticalLayoutData(1, -1, new Margins(0))); + + infoRuleDialog.add(configurationFieldSet, new MarginData(0)); + infoRuleDialog.setHideOnButtonClick(true); + infoRuleDialog.setButtonAlign(BoxLayoutPack.CENTER); + infoRuleDialog.setWidth(500); + + infoRuleDialog.show(); + + } + + protected void createContextMenu(final Grid grid) { + Menu contextMenu = new Menu(); + + MenuItem infoItem = new MenuItem(); + infoItem.setText("Info"); + infoItem.setIcon(TabularDataResources.INSTANCE.information()); + infoItem.addSelectionHandler(new SelectionHandler() { + + @Override + public void onSelection(SelectionEvent event) { + RuleDescriptionData selected = grid.getSelectionModel() + .getSelectedItem(); + Log.debug(selected.toString()); + requestInfo(selected); + } + }); + + contextMenu.add(infoItem); + + grid.setContextMenu(contextMenu); + + } + } diff --git a/src/main/java/org/gcube/portlets/user/td/client/rule/RuleDeleteDialog.java b/src/main/java/org/gcube/portlets/user/td/client/rule/RuleDeleteDialog.java index c8c55ac..b911717 100644 --- a/src/main/java/org/gcube/portlets/user/td/client/rule/RuleDeleteDialog.java +++ b/src/main/java/org/gcube/portlets/user/td/client/rule/RuleDeleteDialog.java @@ -27,14 +27,15 @@ public class RuleDeleteDialog extends Window { private static final String WIDTH = "720px"; private static final String HEIGHT = "530px"; private EventBus eventBus; + private RuleDeletePanel ruleDeletePanel; public RuleDeleteDialog(EventBus eventBus) { this.eventBus = eventBus; initWindow(); - RuleDeletePanel templateDeletePanel = new RuleDeletePanel(this, + ruleDeletePanel = new RuleDeletePanel(this, eventBus); - add(templateDeletePanel); + add(ruleDeletePanel); } protected void initWindow() { @@ -80,7 +81,7 @@ public class RuleDeleteDialog extends Window { public void onSuccess(Void v) { Log.debug("Rule is deleted!"); UtilsGXT3.info("Delete Rule", "The rule is deleted!"); - + ruleDeletePanel.gridReload(); } @Override diff --git a/src/main/java/org/gcube/portlets/user/td/client/rule/RuleDeletePanel.java b/src/main/java/org/gcube/portlets/user/td/client/rule/RuleDeletePanel.java index 29aa9a2..3ae6748 100644 --- a/src/main/java/org/gcube/portlets/user/td/client/rule/RuleDeletePanel.java +++ b/src/main/java/org/gcube/portlets/user/td/client/rule/RuleDeletePanel.java @@ -43,14 +43,14 @@ import com.sencha.gxt.data.shared.loader.ListLoadResultBean; import com.sencha.gxt.data.shared.loader.ListLoader; import com.sencha.gxt.data.shared.loader.LoadResultListStoreBinding; import com.sencha.gxt.widget.core.client.Dialog; -import com.sencha.gxt.widget.core.client.FramedPanel; import com.sencha.gxt.widget.core.client.Dialog.PredefinedButton; +import com.sencha.gxt.widget.core.client.FramedPanel; import com.sencha.gxt.widget.core.client.button.TextButton; import com.sencha.gxt.widget.core.client.container.BoxLayoutContainer.BoxLayoutData; import com.sencha.gxt.widget.core.client.container.BoxLayoutContainer.BoxLayoutPack; import com.sencha.gxt.widget.core.client.container.HBoxLayoutContainer; -import com.sencha.gxt.widget.core.client.container.MarginData; import com.sencha.gxt.widget.core.client.container.HBoxLayoutContainer.HBoxLayoutAlign; +import com.sencha.gxt.widget.core.client.container.MarginData; import com.sencha.gxt.widget.core.client.container.VerticalLayoutContainer; import com.sencha.gxt.widget.core.client.container.VerticalLayoutContainer.VerticalLayoutData; import com.sencha.gxt.widget.core.client.event.SelectEvent; @@ -72,16 +72,15 @@ import com.sencha.gxt.widget.core.client.toolbar.ToolBar; public class RuleDeletePanel extends FramedPanel { private static final String WIDTH = "630px"; private static final String HEIGHT = "520px"; - + interface RuleDeleteTemplates extends XTemplates { @XTemplate("{value}") SafeHtml format(String value); } - + private EventBus eventBus; private RuleDeleteDialog parent; - private TextButton btnDelete; private TextButton btnClose; @@ -134,6 +133,19 @@ public class RuleDeletePanel extends FramedPanel { } }); + ColumnConfig scopeCol = new ColumnConfig( + props.scopeLabel(), 40, "Scope"); + + nameCol.setCell(new AbstractCell() { + + @Override + public void render(Context context, String value, SafeHtmlBuilder sb) { + RuleDeleteTemplates ruleDeleteTemplates = GWT + .create(RuleDeleteTemplates.class); + sb.append(ruleDeleteTemplates.format(value)); + } + }); + ColumnConfig descriptionCol = new ColumnConfig( props.description(), 120, "Description"); descriptionCol.setCell(new AbstractCell() { @@ -145,7 +157,7 @@ public class RuleDeletePanel extends FramedPanel { sb.append(ruleDeleteTemplates.format(value)); } }); - + ColumnConfig ownerCol = new ColumnConfig( props.owner(), 70, "Owner"); ownerCol.setCell(new AbstractCell() { @@ -170,9 +182,10 @@ public class RuleDeletePanel extends FramedPanel { sb.append(ruleDeleteTemplates.format(value)); } }); - + List> l = new ArrayList>(); l.add(nameCol); + l.add(scopeCol); l.add(descriptionCol); l.add(ownerCol); l.add(readableExpressionCol); @@ -253,9 +266,9 @@ public class RuleDeletePanel extends FramedPanel { grid.setColumnReordering(true); grid.setColumnResize(true); grid.getView().setAutoExpandColumn(descriptionCol); - + createContextMenu(); - + ToolBar toolBar = new ToolBar(); toolBar.add(grid); toolBar.addStyleName(ThemeStyles.get().style().borderTop()); @@ -392,59 +405,71 @@ public class RuleDeletePanel extends FramedPanel { final Dialog infoRuleDialog = new Dialog(); infoRuleDialog.setHeadingText("Info Rule"); - infoRuleDialog.getHeader().setIcon(TabularDataResources.INSTANCE.information()); + infoRuleDialog.getHeader().setIcon( + TabularDataResources.INSTANCE.information()); infoRuleDialog.setPredefinedButtons(PredefinedButton.OK); - - + FieldSet configurationFieldSet = new FieldSet(); configurationFieldSet.setHeadingText("Configuration"); configurationFieldSet.setCollapsible(false); configurationFieldSet.setBorders(true); VerticalLayoutContainer configurationFieldSetLayout = new VerticalLayoutContainer(); - configurationFieldSet.add(configurationFieldSetLayout, new MarginData(0)); - + configurationFieldSet.add(configurationFieldSetLayout, + new MarginData(0)); + TextField ruleName = new TextField(); ruleName.setToolTip("Rule Name"); ruleName.setValue(rule.getName()); ruleName.setReadOnly(true); FieldLabel ruleNameLabel = new FieldLabel(ruleName, "Name"); - configurationFieldSetLayout.add(ruleNameLabel,new VerticalLayoutData(1, -1, new Margins(0))); - - + configurationFieldSetLayout.add(ruleNameLabel, new VerticalLayoutData( + 1, -1, new Margins(0))); + + TextField ruleScope = new TextField(); + ruleScope.setToolTip("Rule Scope"); + ruleScope.setValue(rule.getScopeLabel()); + ruleScope.setReadOnly(true); + FieldLabel ruleScopeLabel = new FieldLabel(ruleScope, "Scope"); + configurationFieldSetLayout.add(ruleScopeLabel, new VerticalLayoutData( + 1, -1, new Margins(0))); + TextArea ruleDescription = new TextArea(); ruleDescription.setToolTip("Rule Description"); ruleDescription.setValue(rule.getDescription()); ruleDescription.setReadOnly(true); - FieldLabel ruleDescriptionLabel = new FieldLabel(ruleDescription, "Description"); - configurationFieldSetLayout.add(ruleDescriptionLabel,new VerticalLayoutData(1, -1, new Margins(0))); - + FieldLabel ruleDescriptionLabel = new FieldLabel(ruleDescription, + "Description"); + configurationFieldSetLayout.add(ruleDescriptionLabel, + new VerticalLayoutData(1, -1, new Margins(0))); + TextField ruleOwner = new TextField(); ruleOwner.setToolTip("Rule Owner"); ruleOwner.setValue(rule.getOwner()); ruleOwner.setReadOnly(true); FieldLabel ruleOwnerLabel = new FieldLabel(ruleOwner, "Owner"); - configurationFieldSetLayout.add(ruleOwnerLabel,new VerticalLayoutData(1, -1, new Margins(0))); - + configurationFieldSetLayout.add(ruleOwnerLabel, new VerticalLayoutData( + 1, -1, new Margins(0))); + TextArea ruleExpression = new TextArea(); ruleExpression.setToolTip("Rule Expression"); ruleExpression.setValue(rule.getReadableExpression()); ruleExpression.setReadOnly(true); ruleExpression.setHeight("82px"); - FieldLabel ruleExpressionLabel = new FieldLabel(ruleExpression, "Expression"); - configurationFieldSetLayout.add(ruleExpressionLabel,new VerticalLayoutData(1, -1, new Margins(0))); + FieldLabel ruleExpressionLabel = new FieldLabel(ruleExpression, + "Expression"); + configurationFieldSetLayout.add(ruleExpressionLabel, + new VerticalLayoutData(1, -1, new Margins(0))); - infoRuleDialog.add(configurationFieldSet, new MarginData(0)); infoRuleDialog.setHideOnButtonClick(true); infoRuleDialog.setButtonAlign(BoxLayoutPack.CENTER); infoRuleDialog.setWidth(500); - + infoRuleDialog.show(); - + } - protected void createContextMenu() { Menu contextMenu = new Menu(); @@ -455,17 +480,17 @@ public class RuleDeletePanel extends FramedPanel { @Override public void onSelection(SelectionEvent event) { - RuleDescriptionData selected = grid.getSelectionModel().getSelectedItem(); + RuleDescriptionData selected = grid.getSelectionModel() + .getSelectedItem(); Log.debug(selected.toString()); requestInfo(selected); } }); - + contextMenu.add(infoItem); grid.setContextMenu(contextMenu); - + } - - + } diff --git a/src/main/java/org/gcube/portlets/user/td/client/rule/RuleOpenPanel.java b/src/main/java/org/gcube/portlets/user/td/client/rule/RuleOpenPanel.java index 2969307..6f53336 100644 --- a/src/main/java/org/gcube/portlets/user/td/client/rule/RuleOpenPanel.java +++ b/src/main/java/org/gcube/portlets/user/td/client/rule/RuleOpenPanel.java @@ -42,7 +42,6 @@ import com.sencha.gxt.data.shared.loader.ListLoadResult; import com.sencha.gxt.data.shared.loader.ListLoadResultBean; import com.sencha.gxt.data.shared.loader.ListLoader; import com.sencha.gxt.data.shared.loader.LoadResultListStoreBinding; -import com.sencha.gxt.widget.core.client.ContentPanel; import com.sencha.gxt.widget.core.client.Dialog; import com.sencha.gxt.widget.core.client.Dialog.PredefinedButton; import com.sencha.gxt.widget.core.client.FramedPanel; @@ -140,6 +139,19 @@ public class RuleOpenPanel extends FramedPanel { } }); + ColumnConfig scopeCol = new ColumnConfig( + props.scopeLabel(), 40, "Scope"); + + nameCol.setCell(new AbstractCell() { + + @Override + public void render(Context context, String value, SafeHtmlBuilder sb) { + RuleOpenTemplates ruleOpenTemplates = GWT + .create(RuleOpenTemplates.class); + sb.append(ruleOpenTemplates.format(value)); + } + }); + ColumnConfig descriptionCol = new ColumnConfig( props.description(), 120, "Description"); descriptionCol.setCell(new AbstractCell() { @@ -179,6 +191,7 @@ public class RuleOpenPanel extends FramedPanel { List> l = new ArrayList>(); l.add(nameCol); + l.add(scopeCol); l.add(descriptionCol); l.add(ownerCol); l.add(readableExpressionCol); @@ -261,7 +274,7 @@ public class RuleOpenPanel extends FramedPanel { grid.getView().setAutoExpandColumn(descriptionCol); createContextMenu(); - + ToolBar toolBar = new ToolBar(); toolBar.add(grid); toolBar.addStyleName(ThemeStyles.get().style().borderTop()); @@ -400,59 +413,71 @@ public class RuleOpenPanel extends FramedPanel { final Dialog infoRuleDialog = new Dialog(); infoRuleDialog.setHeadingText("Info Rule"); - infoRuleDialog.getHeader().setIcon(TabularDataResources.INSTANCE.information()); + infoRuleDialog.getHeader().setIcon( + TabularDataResources.INSTANCE.information()); infoRuleDialog.setPredefinedButtons(PredefinedButton.OK); - - + FieldSet configurationFieldSet = new FieldSet(); configurationFieldSet.setHeadingText("Configuration"); configurationFieldSet.setCollapsible(false); configurationFieldSet.setBorders(true); VerticalLayoutContainer configurationFieldSetLayout = new VerticalLayoutContainer(); - configurationFieldSet.add(configurationFieldSetLayout, new MarginData(0)); - + configurationFieldSet.add(configurationFieldSetLayout, + new MarginData(0)); + TextField ruleName = new TextField(); ruleName.setToolTip("Rule Name"); ruleName.setValue(rule.getName()); ruleName.setReadOnly(true); FieldLabel ruleNameLabel = new FieldLabel(ruleName, "Name"); - configurationFieldSetLayout.add(ruleNameLabel,new VerticalLayoutData(1, -1, new Margins(0))); - - + configurationFieldSetLayout.add(ruleNameLabel, new VerticalLayoutData( + 1, -1, new Margins(0))); + + TextField ruleScope = new TextField(); + ruleScope.setToolTip("Rule Scope"); + ruleScope.setValue(rule.getScopeLabel()); + ruleScope.setReadOnly(true); + FieldLabel ruleScopeLabel = new FieldLabel(ruleScope, "Scope"); + configurationFieldSetLayout.add(ruleScopeLabel, new VerticalLayoutData( + 1, -1, new Margins(0))); + TextArea ruleDescription = new TextArea(); ruleDescription.setToolTip("Rule Description"); ruleDescription.setValue(rule.getDescription()); ruleDescription.setReadOnly(true); - FieldLabel ruleDescriptionLabel = new FieldLabel(ruleDescription, "Description"); - configurationFieldSetLayout.add(ruleDescriptionLabel,new VerticalLayoutData(1, -1, new Margins(0))); - + FieldLabel ruleDescriptionLabel = new FieldLabel(ruleDescription, + "Description"); + configurationFieldSetLayout.add(ruleDescriptionLabel, + new VerticalLayoutData(1, -1, new Margins(0))); + TextField ruleOwner = new TextField(); ruleOwner.setToolTip("Rule Owner"); ruleOwner.setValue(rule.getOwner()); ruleOwner.setReadOnly(true); FieldLabel ruleOwnerLabel = new FieldLabel(ruleOwner, "Owner"); - configurationFieldSetLayout.add(ruleOwnerLabel,new VerticalLayoutData(1, -1, new Margins(0))); - + configurationFieldSetLayout.add(ruleOwnerLabel, new VerticalLayoutData( + 1, -1, new Margins(0))); + TextArea ruleExpression = new TextArea(); ruleExpression.setToolTip("Rule Expression"); ruleExpression.setValue(rule.getReadableExpression()); ruleExpression.setReadOnly(true); ruleExpression.setHeight("82px"); - FieldLabel ruleExpressionLabel = new FieldLabel(ruleExpression, "Expression"); - configurationFieldSetLayout.add(ruleExpressionLabel,new VerticalLayoutData(1, -1, new Margins(0))); + FieldLabel ruleExpressionLabel = new FieldLabel(ruleExpression, + "Expression"); + configurationFieldSetLayout.add(ruleExpressionLabel, + new VerticalLayoutData(1, -1, new Margins(0))); - infoRuleDialog.add(configurationFieldSet, new MarginData(0)); infoRuleDialog.setHideOnButtonClick(true); infoRuleDialog.setButtonAlign(BoxLayoutPack.CENTER); infoRuleDialog.setWidth(500); - + infoRuleDialog.show(); - + } - protected void createContextMenu() { Menu contextMenu = new Menu(); @@ -463,15 +488,16 @@ public class RuleOpenPanel extends FramedPanel { @Override public void onSelection(SelectionEvent event) { - RuleDescriptionData selected = grid.getSelectionModel().getSelectedItem(); + RuleDescriptionData selected = grid.getSelectionModel() + .getSelectedItem(); Log.debug(selected.toString()); requestInfo(selected); } }); - + contextMenu.add(infoItem); grid.setContextMenu(contextMenu); - + } } diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-apply.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-apply.png new file mode 100644 index 0000000..edf83f0 Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-apply.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-apply_32.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-apply_32.png new file mode 100644 index 0000000..3ea6ae5 Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-apply_32.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-close.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-close.png new file mode 100644 index 0000000..3f05d50 Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-close.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-close_32.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-close_32.png new file mode 100644 index 0000000..34fd2c2 Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-close_32.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-add.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-add.png new file mode 100644 index 0000000..15e8736 Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-add.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-add_32.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-add_32.png new file mode 100644 index 0000000..230cb1b Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-add_32.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-apply.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-apply.png new file mode 100644 index 0000000..1148d23 Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-apply.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-apply_32.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-apply_32.png new file mode 100644 index 0000000..212fda5 Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-apply_32.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-close.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-close.png new file mode 100644 index 0000000..90c75ed Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-close.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-close_32.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-close_32.png new file mode 100644 index 0000000..fb3b6e4 Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-column-close_32.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-delete.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-delete.png new file mode 100644 index 0000000..744f6d8 Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-delete.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-delete_32.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-delete_32.png new file mode 100644 index 0000000..9ace2f1 Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-delete_32.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-edit.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-edit.png new file mode 100644 index 0000000..bcefe15 Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-edit.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-edit_32.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-edit_32.png new file mode 100644 index 0000000..86f0848 Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-edit_32.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-share.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-share.png new file mode 100644 index 0000000..5e8164d Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-share.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-share_32.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-share_32.png new file mode 100644 index 0000000..04b84b1 Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-share_32.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-tabularresource.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-tabularresource.png new file mode 100644 index 0000000..f0cd78c Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-tabularresource.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-tabularresource_32.png b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-tabularresource_32.png new file mode 100644 index 0000000..1d53f7d Binary files /dev/null and b/src/main/resources/org/gcube/portlets/user/td/client/resource/rule-tabularresource_32.png differ diff --git a/src/main/resources/org/gcube/portlets/user/td/client/ribbon/RuleToolBarMessages.properties b/src/main/resources/org/gcube/portlets/user/td/client/ribbon/RuleToolBarMessages.properties index 0bb2ed2..c1fcde0 100644 --- a/src/main/resources/org/gcube/portlets/user/td/client/ribbon/RuleToolBarMessages.properties +++ b/src/main/resources/org/gcube/portlets/user/td/client/ribbon/RuleToolBarMessages.properties @@ -1,11 +1,12 @@ ruleGroupHeadingText = Manage -ruleNewButton = New -ruleNewButtonToolTip = New -ruleEditButton = Edit -ruleEditButtonToolTip = Edit +ruleEditButton = Open +ruleEditButtonToolTip = Open ruleDeleteButton = Delete ruleDeleteButtonToolTip = Delete +ruleShareButton = Share +ruleShareButtonToolTip = Share +ruleOnColumnGroupHeadingText = On Column +ruleNewButton = New +ruleNewButtonToolTip = New ruleApplyButton = Apply ruleApplyButtonToolTip = Apply -ruleShareButton = Share -ruleShareButtonToolTip = Share \ No newline at end of file diff --git a/src/main/resources/org/gcube/portlets/user/td/client/ribbon/RuleToolBarMessages_es.properties b/src/main/resources/org/gcube/portlets/user/td/client/ribbon/RuleToolBarMessages_es.properties index ae0deaa..8550090 100644 --- a/src/main/resources/org/gcube/portlets/user/td/client/ribbon/RuleToolBarMessages_es.properties +++ b/src/main/resources/org/gcube/portlets/user/td/client/ribbon/RuleToolBarMessages_es.properties @@ -1,11 +1,12 @@ ruleGroupHeadingText = Gestionar -ruleNewButton = Nuevo -ruleNewButtonToolTip = Nuevo -ruleEditButton = Editar -ruleEditButtonToolTip = Editar +ruleEditButton = Abre +ruleEditButtonToolTip = Abre ruleDeleteButton = Borrar ruleDeleteButtonToolTip = Borrar -ruleApplyButton = Aplicar -ruleApplyButtonToolTip = Aplicar ruleShareButton = Cuota -ruleShareButtonToolTip = Cuota \ No newline at end of file +ruleShareButtonToolTip = Cuota +ruleOnColumnGroupHeadingText = On Columna +ruleNewButton = Nuevo +ruleNewButtonToolTip = Nuevo +ruleApplyButton = Aplicar +ruleApplyButtonToolTip = Aplicar \ No newline at end of file diff --git a/src/main/resources/org/gcube/portlets/user/td/client/ribbon/RuleToolBarMessages_it.properties b/src/main/resources/org/gcube/portlets/user/td/client/ribbon/RuleToolBarMessages_it.properties index 9beee28..2df7daa 100644 --- a/src/main/resources/org/gcube/portlets/user/td/client/ribbon/RuleToolBarMessages_it.properties +++ b/src/main/resources/org/gcube/portlets/user/td/client/ribbon/RuleToolBarMessages_it.properties @@ -1,11 +1,12 @@ ruleGroupHeadingText = Gestisci -ruleNewButton = Nuovo -ruleNewButtonToolTip = Nuovo -ruleEditButton = Modifica -ruleEditButtonToolTip = Modifica +ruleEditButton = Apri +ruleEditButtonToolTip = Apri ruleDeleteButton = Elimina ruleDeleteButtonToolTip = Elimina -ruleApplyButton = Applica -ruleApplyButtonToolTip = Applica ruleShareButton = Condividi -ruleShareButtonToolTip = Condividi \ No newline at end of file +ruleShareButtonToolTip = Condividi +ruleOnColumnGroupHeadingText = Su Colonna +ruleNewButton = Nuova +ruleNewButtonToolTip = Nuova +ruleApplyButton = Applica +ruleApplyButtonToolTip = Applica \ No newline at end of file