minor fixes
git-svn-id: http://svn.d4science-ii.research-infrastructures.eu/gcube/trunk/portlets/widgets/ckan-metadata-publisher-widget@131465 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
2f791c50a6
commit
742710c041
|
@ -26,7 +26,6 @@ import org.gcube.portlets.widgets.ckandatapublisherwidget.shared.OrganizationBea
|
|||
|
||||
import com.github.gwtbootstrap.client.ui.AlertBlock;
|
||||
import com.github.gwtbootstrap.client.ui.Button;
|
||||
import com.github.gwtbootstrap.client.ui.CheckBox;
|
||||
import com.github.gwtbootstrap.client.ui.ControlGroup;
|
||||
import com.github.gwtbootstrap.client.ui.Form;
|
||||
import com.github.gwtbootstrap.client.ui.Icon;
|
||||
|
@ -45,7 +44,6 @@ import com.github.gwtbootstrap.client.ui.resources.Bootstrap.Tabs;
|
|||
import com.google.gwt.core.client.GWT;
|
||||
import com.google.gwt.dom.client.Element;
|
||||
import com.google.gwt.dom.client.Style.Cursor;
|
||||
import com.google.gwt.dom.client.Style.Display;
|
||||
import com.google.gwt.event.dom.client.ChangeEvent;
|
||||
import com.google.gwt.event.dom.client.ChangeHandler;
|
||||
import com.google.gwt.event.dom.client.ClickEvent;
|
||||
|
@ -121,7 +119,6 @@ public class CreateDatasetForm extends Composite{
|
|||
@UiField Paragraph selectedProfile;
|
||||
@UiField Button goToDatasetButton;
|
||||
@UiField Button addResourcesButton;
|
||||
@UiField CheckBox addResourcesCheckBox;
|
||||
@UiField SimplePanel workspaceResourcesContainer;
|
||||
@UiField Button continueThirdStep;
|
||||
@UiField Button goBackButtonFirstStep;
|
||||
|
@ -317,8 +314,6 @@ public class CreateDatasetForm extends Composite{
|
|||
|
||||
if(isWorkspaceRequest){
|
||||
|
||||
// enable manage resources checkbox
|
||||
addResourcesCheckBox.getElement().getStyle().setDisplay(Display.INLINE_BLOCK);
|
||||
resourcesTable = new ResourcesTable(bean.getResources());
|
||||
|
||||
// if there are not resources, for now just checked it ( and hide so that the step will be skipped) TODO
|
||||
|
@ -1155,7 +1150,6 @@ public class CreateDatasetForm extends Composite{
|
|||
licenseListbox.setEnabled(false);
|
||||
organizationsListbox.setEnabled(false);
|
||||
addCustomFieldButton.setEnabled(false);
|
||||
addResourcesCheckBox.setEnabled(false);
|
||||
|
||||
// freeze tags
|
||||
for(int i = 0; i < tagsList.size(); i++){
|
||||
|
@ -1206,19 +1200,6 @@ public class CreateDatasetForm extends Composite{
|
|||
}
|
||||
}
|
||||
|
||||
@UiHandler("addResourcesCheckBox")
|
||||
void onAddResourcesCheckboxPress(ClickEvent e){
|
||||
|
||||
// we need to set all resources to be added if checkbox value is true
|
||||
if(addResourcesCheckBox.getValue()){
|
||||
|
||||
GWT.log("Set all resources to be add");
|
||||
resourcesTable.checkAllResources(true);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@UiHandler("licenseListbox")
|
||||
void onSelectedLicenseChange(ChangeEvent c){
|
||||
|
||||
|
|
|
@ -55,7 +55,7 @@
|
|||
<b:AlertBlock type="INFO" close="false" animation="true"
|
||||
visible="false" ui:field="infoBlock" styleName="{style.block-alert-style}"></b:AlertBlock>
|
||||
|
||||
<b:ControlGroup ui:field="productTitleGroup" >
|
||||
<b:ControlGroup ui:field="productTitleGroup">
|
||||
<b:ControlLabel for="title" title="Product title">
|
||||
<font color="red">*</font>
|
||||
Title :
|
||||
|
@ -296,19 +296,8 @@
|
|||
<b:Legend styleName="{style.legend-style}">
|
||||
Manage Resources
|
||||
</b:Legend>
|
||||
|
||||
<!-- If the user checks this box, the resources will be automatically
|
||||
added, otherwise he has to manage them -->
|
||||
<b:ControlGroup>
|
||||
<b:ControlLabel for="resourcesAddCheckBox"
|
||||
title="Automatically add all resources to product">Product
|
||||
Resources:</b:ControlLabel>
|
||||
<b:Controls>
|
||||
<b:CheckBox b:id="resourcesAddCheckBox" width="60%"
|
||||
title="Automatically add the folder content to the product as resource"
|
||||
checked="true" ui:field="addResourcesCheckBox">
|
||||
<b>Add folder content as resources</b>
|
||||
</b:CheckBox>
|
||||
<span style="float:right; width:5%; color: #aaaaaa;">
|
||||
<b:Popover ui:field="popoverResources" html="true"
|
||||
animation="true" placement="LEFT">
|
||||
|
|
|
@ -52,7 +52,7 @@ public class InfoIconsLabels {
|
|||
// RESOURCES
|
||||
public static final String RESOURCES_INFO_ID_POPUP = "resouces-popup-panel-info";
|
||||
public static final String RESOURCES_INFO_CAPTION = "Product Resources";
|
||||
public static final String RESOURCES_INFO_TEXT = "Automatically add folder content as resources of the product";
|
||||
public static final String RESOURCES_INFO_TEXT = "Folder content will be added as resources of the product";
|
||||
|
||||
// CUSTOM FIELDS
|
||||
public static final String CUSTOM_FIELDS_INFO_ID_POPUP = "custom-fields-popup-panel-info";
|
||||
|
|
|
@ -320,6 +320,8 @@ public class Utils {
|
|||
// check the scope we need to discover
|
||||
String scopeInWhichDiscover = (scope != null && !scope.isEmpty()) ? scope : aslSession.getScope();
|
||||
|
||||
logger.debug("Discovering into scope " + scopeInWhichDiscover);
|
||||
|
||||
// scope in which we need to discover
|
||||
String keyPerScope = UtilMethods.concatenateSessionKeyScope(SessionCatalogueAttributes.CKAN_PROFILES_KEY, scopeInWhichDiscover);
|
||||
|
||||
|
@ -359,6 +361,7 @@ public class Utils {
|
|||
wrapperObj.setValidator(validator.getRegularExpression());
|
||||
|
||||
MetadataVocabulary vocabulary = metadataField.getVocabulary();
|
||||
|
||||
if(vocabulary != null){
|
||||
wrapperObj.setVocabulary(vocabulary.getVocabularyFields());
|
||||
wrapperObj.setMultiSelection(vocabulary.isMultiSelection());
|
||||
|
|
Loading…
Reference in New Issue