modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/bundle/create/BundleGroupsStep.java | 77 ++++------ modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/bundle/create/BundleSummaryStep.java | 15 + modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages.properties | 5 modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_cs.properties | 3 modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_de.properties | 3 modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_ja.properties | 3 modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_ko.properties | 10 + modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_pt.properties | 7 modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_ru.properties | 19 ++ modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_zh.properties | 5 modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/bundle/BundleManagerBean.java | 8 + 11 files changed, 96 insertions(+), 59 deletions(-)
New commits: commit 05c9e5dc5ef852b94774daa8e080a00b4bd3bd90 Author: Jay Shaughnessy jshaughn@redhat.com Date: Wed Aug 21 10:26:39 2013 -0400
more work on the create bundle wizard, initial bundle version path
diff --git a/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/bundle/create/BundleGroupsStep.java b/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/bundle/create/BundleGroupsStep.java index 6b3b29c..46c6ace 100644 --- a/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/bundle/create/BundleGroupsStep.java +++ b/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/bundle/create/BundleGroupsStep.java @@ -30,13 +30,10 @@ import java.util.Set;
import com.google.gwt.user.client.rpc.AsyncCallback; import com.smartgwt.client.types.Alignment; -import com.smartgwt.client.types.Overflow; import com.smartgwt.client.types.TitleOrientation; import com.smartgwt.client.widgets.Canvas; import com.smartgwt.client.widgets.form.DynamicForm; -import com.smartgwt.client.widgets.form.fields.FormItem; import com.smartgwt.client.widgets.form.fields.RadioGroupItem; -import com.smartgwt.client.widgets.form.fields.SpacerItem; import com.smartgwt.client.widgets.form.fields.StaticTextItem; import com.smartgwt.client.widgets.form.fields.events.ChangedEvent; import com.smartgwt.client.widgets.form.fields.events.ChangedHandler; @@ -79,53 +76,37 @@ public class BundleGroupsStep extends AbstractWizardStep { || this.wizard.getBundleVersion().getVersionOrder() == 0;
if (isInitialVersion) { - canvas = getInitialVersionCanvas(); + prepareInitialVersionCanvas(canvas); } else { - canvas = getNonInitialVersionCanvas(); + prepareNonInitialVersionCanvas(canvas); }
return canvas; }
- private EnhancedVLayout getInitialVersionCanvas() { + private void prepareInitialVersionCanvas(final EnhancedVLayout canvas) { BundleGroupAssignmentComposite composite = wizard.getBundleGroupAssignmentComposite(); final Map<BundleGroup, Boolean> map = composite.getBundleGroupMap();
if (composite.isCanBeUnassigned()) { radioForm = new DynamicForm(); radioForm.setNumCols(1); + radioForm.setColWidths(350); // These settings (as opposed to setWidth100()) allow for contextual help to be better placed - radioForm.setAutoWidth(); - radioForm.setOverflow(Overflow.VISIBLE); - - List<FormItem> formItems = new ArrayList<FormItem>(); - - // Make the radio item title a separate item in the form in order to add contextual help - // to the right of the title text. We could also add it to the radio item but then it floats to - // the right of the last radio button option (I'll leave that commented below if for some reason - // we want to switch to that approach. - StaticTextItem radioTitleItem = new StaticTextItem("RadioTitle"); - radioTitleItem.setShowTitle(false); - radioTitleItem.setTitleOrientation(TitleOrientation.TOP); - radioTitleItem.setAlign(Alignment.LEFT); - // The css style "formTitle" is what should work here, but for some reason I wasn't getting the - // proper color. So instead I grabbed the color from the smartgwt css and declared it explicitly. - //radioTitleItem.setCellStyle("formTitle"); - radioTitleItem.setValue("<span style="font-weight: bold; color: #003168">" - + MSG.view_bundle_createWizard_groupsStep_radioTitle() + " :</span>"); - FormUtility.addContextualHelp(radioTitleItem, MSG.view_bundle_createWizard_groupsStep_help()); - formItems.add(radioTitleItem); + //radioForm.setAutoWidth(); + //radioForm.setOverflow(Overflow.VISIBLE);
RadioGroupItem radioGroupItem = new RadioGroupItem("RadioOptions"); - radioGroupItem.setShowTitle(false); + radioGroupItem.setTitleOrientation(TitleOrientation.TOP); + radioGroupItem.setTitle(MSG.view_bundle_createWizard_groupsStep_radioTitle()); radioGroupItem.setRequired(true); radioGroupItem.setAlign(Alignment.LEFT); + LinkedHashMap<String, String> valueMap = new LinkedHashMap<String, String>(); - if (wizard.getBundleGroupAssignmentComposite().isCanBeUnassigned()) { - valueMap.put("unassigned", MSG.view_bundle_createWizard_groupsStep_leaveUnassigned()); - } + valueMap.put("unassigned", MSG.view_bundle_createWizard_groupsStep_leaveUnassigned()); valueMap.put("assign", MSG.view_bundle_createWizard_groupsStep_assign()); radioGroupItem.setValueMap(valueMap); + radioGroupItem.setValue("assign");
radioGroupItem.addChangedHandler(new ChangedHandler() { public void onChanged(ChangedEvent event) { @@ -142,16 +123,15 @@ public class BundleGroupsStep extends AbstractWizardStep { canvas.markForRedraw(); } }); + FormUtility.addContextualHelp(radioGroupItem, MSG.view_bundle_createWizard_groupsStep_help());
- formItems.add(radioGroupItem); - formItems.add(new SpacerItem()); - radioForm.setItems(formItems.toArray(new FormItem[formItems.size()])); + radioForm.setItems(radioGroupItem); canvas.addMember(radioForm);
selector = getSelector(map, false); selector.setTitle(MSG.view_bundle_createWizard_groupsStep_assign()); selector.setTooltip(MSG.view_bundle_createWizard_groupsStep_help()); - selector.disable(); + selector.enable(); canvas.addMember(selector);
} else if (!map.isEmpty()) { @@ -163,11 +143,9 @@ public class BundleGroupsStep extends AbstractWizardStep { } else { throw new IllegalStateException(MSG.view_bundle_createWizard_groupsStep_noAssignable()); } - - return canvas; }
- private EnhancedVLayout getNonInitialVersionCanvas() { + private void prepareNonInitialVersionCanvas(EnhancedVLayout canvas) { BundleGroupAssignmentComposite composite = wizard.getBundleGroupAssignmentComposite(); final Map<BundleGroup, Boolean> map = composite.getBundleGroupMap();
@@ -193,8 +171,6 @@ public class BundleGroupsStep extends AbstractWizardStep { selector.setTooltip(MSG.view_bundle_createWizard_groupsStep_help()); canvas.addMember(selector); } - - return canvas; }
private BundleGroupSelector getSelector(final Map<BundleGroup, Boolean> map, boolean readOnly) { @@ -230,12 +206,21 @@ public class BundleGroupsStep extends AbstractWizardStep { }
public boolean nextPage() { + wizard.getView().hideMessage(); + if (isInitialVersion) { - BundleGroupAssignmentComposite composite = wizard.getBundleGroupAssignmentComposite();
- if (!composite.isCanBeUnassigned() && selector.getSelectedItems().isEmpty()) { - wizard.getView().showMessage(MSG.view_bundle_createWizard_groupsStep_noneAssigned()); - return false; + if (selector.isDisabled()) { + // if the user chooses to leave unassigned and the bundle version has already been created, we're done + if (null != wizard.getBundleVersion()) { + return true; + } + } else { + // make sure at least one group is selected if the selector is active + if (selector.getSelectedItems().isEmpty()) { + wizard.getView().showMessage(MSG.view_bundle_createWizard_groupsStep_noneAssigned()); + return false; + } } }
@@ -351,6 +336,12 @@ public class BundleGroupsStep extends AbstractWizardStep { }); }
+ @Override + public boolean previousPage() { + wizard.getView().hideMessage(); + return true; + } + public String getName() { return MSG.common_title_bundleGroups(); } diff --git a/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/bundle/create/BundleSummaryStep.java b/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/bundle/create/BundleSummaryStep.java index 04906d7..01f8460 100644 --- a/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/bundle/create/BundleSummaryStep.java +++ b/modules/enterprise/gui/coregui/src/main/java/org/rhq/enterprise/gui/coregui/client/bundle/create/BundleSummaryStep.java @@ -18,6 +18,8 @@ */ package org.rhq.enterprise.gui.coregui.client.bundle.create;
+import java.util.Set; + import com.smartgwt.client.types.Alignment; import com.smartgwt.client.types.VerticalAlignment; import com.smartgwt.client.widgets.Canvas; @@ -86,11 +88,16 @@ public class BundleSummaryStep extends AbstractWizardStep { bundleGroupsLabel.setTitleAlign(Alignment.LEFT); bundleGroupsLabel.setAlign(Alignment.LEFT); bundleGroupsLabel.setWrap(false); - StringBuilder bundleGroupsValueStr = new StringBuilder(); - for (BundleGroup bundleGroup : wizard.getInitialBundleGroups()) { - bundleGroupsValueStr.append(bundleGroup.getName() + "<br/>\n"); + Set<BundleGroup> initialBundleGroups = wizard.getInitialBundleGroups(); + if (null == initialBundleGroups || initialBundleGroups.isEmpty()) { + bundleGroupsLabel.setValue(MSG.view_bundle_createWizard_unassigned()); + } else { + StringBuilder bundleGroupsValueStr = new StringBuilder(); + for (BundleGroup bundleGroup : wizard.getInitialBundleGroups()) { + bundleGroupsValueStr.append(bundleGroup.getName() + "<br/>\n"); + } + bundleGroupsLabel.setValue(bundleGroupsValueStr.toString()); } - bundleGroupsLabel.setValue(bundleGroupsValueStr.toString());
form.setFields(bundleTypeLabel, nameLabel, versionLabel, descriptionLabel, filesLabel, bundleGroupsLabel);
diff --git a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages.properties b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages.properties index fc6b050..5d53e3e 100644 --- a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages.properties +++ b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages.properties @@ -1228,7 +1228,7 @@ view_bundle_createWizard_groupsStep_help = A new bundle is created when uploadin view_bundle_createWizard_groupsStep_leaveUnassigned = Leave the new bundle unsassigned. view_bundle_createWizard_groupsStep_noAssignable = Unable to create initial bundle version because the user has no bundle groups to which it can be assigned. Please cancel the create wizard and notify your RHQ administrator. view_bundle_createWizard_groupsStep_noneAssigned = The new bundle version must be assigned to at least one bundle group! -view_bundle_createWizard_groupsStep_radioTitle = Initial bundle group assignment for the new bundle: +view_bundle_createWizard_groupsStep_radioTitle = Initial bundle group assignment for the new bundle view_bundle_createWizard_groupsStep_unassigned = The new bundle version is for an existing bundle and inherits its bundle group assignments. The bundle in not currently assigned to any bundle groups. view_bundle_createWizard_loadBundleFileFailure = Cannot obtain bundle file information from server view_bundle_createWizard_noAdditionalFilesNeeded = No additional files need to be uploaded for this bundle @@ -1237,6 +1237,7 @@ view_bundle_createWizard_noBundleTypesSupported = No bundle types are supported view_bundle_createWizard_provideBundleDistro = Provide a Bundle Distribution view_bundle_createWizard_recipeOption = Recipe view_bundle_createWizard_title = Create Bundle +view_bundle_createWizard_unassigned = unassigned view_bundle_createWizard_uploadInProgress = Upload is in progress... This can take several minutes for large files view_bundle_createWizard_uploadOption = Upload view_bundle_createWizard_uploadStepName = Upload Bundle Files @@ -1244,7 +1245,7 @@ view_bundle_createWizard_urlOption = URL view_bundle_createWizard_urlPassword = Password view_bundle_createWizard_urlTooltip = User name and password can optionally be specified for HTTP and HTTPS URLs. view_bundle_createWizard_urlUserName = User name -view_bundle_createWizard_windowTitle = Bundle Creation Wizard +view_bundle_createWizard_windowTitle = Bundle Creation Wizard view_bundle_createWizard_youMustChooseOne = You must choose one option in order to create a bundle! view_bundle_deleteConfirm = Are you sure you want to delete this bundle? All versions, destinations and deployments for this bundle will also be deleted. However, this will not remove any content from remote machines. view_bundle_deploy = Deploy diff --git a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_cs.properties b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_cs.properties index 7bf260a..c8f56fe 100644 --- a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_cs.properties +++ b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_cs.properties @@ -1242,7 +1242,7 @@ view_bundle_createWizard_failedToUploadFile = Nepodařilo se nahrát soubor bal ##view_bundle_createWizard_groupsStep_leaveUnassigned = Leave the new bundle unsassigned. ##view_bundle_createWizard_groupsStep_noAssignable = Unable to create initial bundle version because the user has no bundle groups to which it can be assigned. Please cancel the create wizard and notify your RHQ administrator. ##view_bundle_createWizard_groupsStep_noneAssigned = The new bundle version must be assigned to at least one bundle group! -##view_bundle_createWizard_groupsStep_radioTitle = Initial bundle group assignment for the new bundle: +##view_bundle_createWizard_groupsStep_radioTitle = Initial bundle group assignment for the new bundle ##view_bundle_createWizard_groupsStep_unassigned = The new bundle version is for an existing bundle and inherits its bundle group assignments. The bundle in not currently assigned to any bundle groups. view_bundle_createWizard_loadBundleFileFailure = Nepodařilo se získat soubor s informacemi o balíku ze serveru view_bundle_createWizard_noAdditionalFilesNeeded = Žádné dodatečné soubory nejsou potřeba pro tento balík @@ -1251,6 +1251,7 @@ view_bundle_createWizard_noBundleTypesSupported = Nejsou podporovány žádné t view_bundle_createWizard_provideBundleDistro = Poskytnout distribuci balíku view_bundle_createWizard_recipeOption = Recept view_bundle_createWizard_title = Vytvořit balík +##view_bundle_createWizard_unassigned = unassigned view_bundle_createWizard_uploadInProgress = Upload probíhá... Pro velké soubory to může trvat několik minut view_bundle_createWizard_uploadOption = Nahrát view_bundle_createWizard_uploadStepName = Nahrát soubory balíku diff --git a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_de.properties b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_de.properties index 757ea3b..797eae4 100644 --- a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_de.properties +++ b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_de.properties @@ -1145,7 +1145,7 @@ view_bundle_bundleVersions = Bundle-Versionen ##view_bundle_createWizard_groupsStep_leaveUnassigned = Leave the new bundle unsassigned. ##view_bundle_createWizard_groupsStep_noAssignable = Unable to create initial bundle version because the user has no bundle groups to which it can be assigned. Please cancel the create wizard and notify your RHQ administrator. ##view_bundle_createWizard_groupsStep_noneAssigned = The new bundle version must be assigned to at least one bundle group! -##view_bundle_createWizard_groupsStep_radioTitle = Initial bundle group assignment for the new bundle: +##view_bundle_createWizard_groupsStep_radioTitle = Initial bundle group assignment for the new bundle ##view_bundle_createWizard_groupsStep_unassigned = The new bundle version is for an existing bundle and inherits its bundle group assignments. The bundle in not currently assigned to any bundle groups. ##view_bundle_createWizard_loadBundleFileFailure = Cannot obtain bundle file information from server ##view_bundle_createWizard_noAdditionalFilesNeeded = No additional files need to be uploaded for this bundle @@ -1154,6 +1154,7 @@ view_bundle_bundleVersions = Bundle-Versionen view_bundle_createWizard_provideBundleDistro = Stellen Sie eine Bundle-Distribution bereit ##view_bundle_createWizard_recipeOption = Recipe view_bundle_createWizard_title = Bundle anlegen +##view_bundle_createWizard_unassigned = unassigned view_bundle_createWizard_uploadInProgress = Datei wird hochgeladen ... Dies kann für große Dateien mehrere Minuten dauern view_bundle_createWizard_uploadOption = Hochladen view_bundle_createWizard_uploadStepName = Bundle-Dateien hochladen diff --git a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_ja.properties b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_ja.properties index c57ede1..8dce44d 100644 --- a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_ja.properties +++ b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_ja.properties @@ -1217,7 +1217,7 @@ view_bundle_createWizard_failedToUploadFile = バンドルファイルのアッ ##view_bundle_createWizard_groupsStep_leaveUnassigned = Leave the new bundle unsassigned. ##view_bundle_createWizard_groupsStep_noAssignable = Unable to create initial bundle version because the user has no bundle groups to which it can be assigned. Please cancel the create wizard and notify your RHQ administrator. ##view_bundle_createWizard_groupsStep_noneAssigned = The new bundle version must be assigned to at least one bundle group! -##view_bundle_createWizard_groupsStep_radioTitle = Initial bundle group assignment for the new bundle: +##view_bundle_createWizard_groupsStep_radioTitle = Initial bundle group assignment for the new bundle ##view_bundle_createWizard_groupsStep_unassigned = The new bundle version is for an existing bundle and inherits its bundle group assignments. The bundle in not currently assigned to any bundle groups. view_bundle_createWizard_loadBundleFileFailure = サーバーからバンドルファイル情報の取得ができません view_bundle_createWizard_noAdditionalFilesNeeded = このバンドルのためにアップロードされる必要がある追加ファイルはありません @@ -1226,6 +1226,7 @@ view_bundle_createWizard_noBundleTypesSupported = バンドルタイプは一つ view_bundle_createWizard_provideBundleDistro = バンドル配布の提供 view_bundle_createWizard_recipeOption = レシピ view_bundle_createWizard_title = バンドル作成 +##view_bundle_createWizard_unassigned = unassigned view_bundle_createWizard_uploadInProgress = アップロード中です... この操作は大きいファイルの場合には数分かかることもあります view_bundle_createWizard_uploadOption = アップロード view_bundle_createWizard_uploadStepName = バンドルファイルのアップロード diff --git a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_ko.properties b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_ko.properties index 3781e74..d4da3f7 100644 --- a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_ko.properties +++ b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_ko.properties @@ -1092,17 +1092,25 @@ view_bundle_createWizard_enterUrl = Please enter a valid URL from where the bund ##view_bundle_createWizard_groupsStep_leaveUnassigned = Leave the new bundle unsassigned. ##view_bundle_createWizard_groupsStep_noAssignable = Unable to create initial bundle version because the user has no bundle groups to which it can be assigned. Please cancel the create wizard and notify your RHQ administrator. ##view_bundle_createWizard_groupsStep_noneAssigned = The new bundle version must be assigned to at least one bundle group! -##view_bundle_createWizard_groupsStep_radioTitle = Initial bundle group assignment for the new bundle: +##view_bundle_createWizard_groupsStep_radioTitle = Initial bundle group assignment for the new bundle ##view_bundle_createWizard_groupsStep_unassigned = The new bundle version is for an existing bundle and inherits its bundle group assignments. The bundle in not currently assigned to any bundle groups. view_bundle_createWizard_loadBundleFileFailure = 서버에서 번들 파일 정보를 획득 할 수 없습니다 +##view_bundle_createWizard_noAdditionalFilesNeeded = No additional files need to be uploaded for this bundle +##view_bundle_createWizard_noBundleTypesAvail = No bundle types are available +##view_bundle_createWizard_noBundleTypesSupported = No bundle types are supported - you must deploy a valid plugin that supports bundle deployments view_bundle_createWizard_provideBundleDistro = 번들 배포 제공 view_bundle_createWizard_recipeOption = 레시피 view_bundle_createWizard_title = 번들 작성 +##view_bundle_createWizard_unassigned = unassigned +##view_bundle_createWizard_uploadInProgress = Upload is in progress... This can take several minutes for large files +##view_bundle_createWizard_uploadOption = Upload +##view_bundle_createWizard_uploadStepName = Upload Bundle Files view_bundle_createWizard_urlOption = URL ##view_bundle_createWizard_urlPassword = Password ##view_bundle_createWizard_urlTooltip = User name and password can optionally be specified for HTTP and HTTPS URLs. ##view_bundle_createWizard_urlUserName = User name view_bundle_createWizard_windowTitle = 번들 생성 마법사 +##view_bundle_createWizard_youMustChooseOne = You must choose one option in order to create a bundle! view_bundle_deploy = 배포 view_bundle_deployDir = 배포 디렉토리 ##view_bundle_deployWizard_createGroup_error_1 = The group was not created. Group for deployment cannot be empty. diff --git a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_pt.properties b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_pt.properties index 579420b..7b5564b 100644 --- a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_pt.properties +++ b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_pt.properties @@ -1230,17 +1230,18 @@ view_bundle_createWizard_failedToUploadFile = Falha ao fazer o upload do bundle ##view_bundle_createWizard_groupsStep_leaveUnassigned = Leave the new bundle unsassigned. ##view_bundle_createWizard_groupsStep_noAssignable = Unable to create initial bundle version because the user has no bundle groups to which it can be assigned. Please cancel the create wizard and notify your RHQ administrator. ##view_bundle_createWizard_groupsStep_noneAssigned = The new bundle version must be assigned to at least one bundle group! -##view_bundle_createWizard_groupsStep_radioTitle = Initial bundle group assignment for the new bundle: +##view_bundle_createWizard_groupsStep_radioTitle = Initial bundle group assignment for the new bundle ##view_bundle_createWizard_groupsStep_unassigned = The new bundle version is for an existing bundle and inherits its bundle group assignments. The bundle in not currently assigned to any bundle groups. view_bundle_createWizard_loadBundleFileFailure = N\u00E3o foi poss\u00EDvel obter infoma\u00E7\u00F5es sobre o arquivo de bundle view_bundle_createWizard_noAdditionalFilesNeeded = N\u00E3o \u00E9 necess\u00E1rio fazer upload de mais arquivos para este bundle view_bundle_createWizard_noBundleTypesAvail = Tipos de bundle n\u00E3o dispon\u00EDveis view_bundle_createWizard_noBundleTypesSupported = N\u00E3o h\u00E1 suporte para tipos de bundle - voc\u00EA deve fazer o deploy de um plugin v\u00E1lido para este tipo de implanta\u00E7\u00E3o view_bundle_createWizard_provideBundleDistro = Forne\u00E7a um pacote de distribui\u00E7\u00E3o para o Bundle -view_bundle_createWizard_recipeOption = Script +##view_bundle_createWizard_recipeOption = Recipe view_bundle_createWizard_title = Criar um Bundle +##view_bundle_createWizard_unassigned = unassigned view_bundle_createWizard_uploadInProgress = Realizando o upload... Esta opera\u00E7\u00E3o pede demorar alguns minutos para arquivos grandes -view_bundle_createWizard_uploadOption = Upload +##view_bundle_createWizard_uploadOption = Upload view_bundle_createWizard_uploadStepName = Fa\u00E7a o upload dos arquivos do Bundle view_bundle_createWizard_urlOption = URL ##view_bundle_createWizard_urlPassword = Password diff --git a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_ru.properties b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_ru.properties index 466c408..e25eabc 100644 --- a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_ru.properties +++ b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_ru.properties @@ -2792,8 +2792,25 @@ view_admin_systemSettings_LDAPBindPW_name = Пароль ##view_bundle_createWizard_groupsStep_leaveUnassigned = Leave the new bundle unsassigned. ##view_bundle_createWizard_groupsStep_noAssignable = Unable to create initial bundle version because the user has no bundle groups to which it can be assigned. Please cancel the create wizard and notify your RHQ administrator. ##view_bundle_createWizard_groupsStep_noneAssigned = The new bundle version must be assigned to at least one bundle group! -##view_bundle_createWizard_groupsStep_radioTitle = Initial bundle group assignment for the new bundle: +##view_bundle_createWizard_groupsStep_radioTitle = Initial bundle group assignment for the new bundle ##view_bundle_createWizard_groupsStep_unassigned = The new bundle version is for an existing bundle and inherits its bundle group assignments. The bundle in not currently assigned to any bundle groups. +##view_bundle_createWizard_loadBundleFileFailure = Cannot obtain bundle file information from server +##view_bundle_createWizard_noAdditionalFilesNeeded = No additional files need to be uploaded for this bundle +##view_bundle_createWizard_noBundleTypesAvail = No bundle types are available +##view_bundle_createWizard_noBundleTypesSupported = No bundle types are supported - you must deploy a valid plugin that supports bundle deployments +##view_bundle_createWizard_provideBundleDistro = Provide a Bundle Distribution +##view_bundle_createWizard_recipeOption = Recipe +##view_bundle_createWizard_title = Create Bundle +##view_bundle_createWizard_unassigned = unassigned +##view_bundle_createWizard_uploadInProgress = Upload is in progress... This can take several minutes for large files +##view_bundle_createWizard_uploadOption = Upload +##view_bundle_createWizard_uploadStepName = Upload Bundle Files +view_bundle_createWizard_urlOption = URL +##view_bundle_createWizard_urlPassword = Password +##view_bundle_createWizard_urlTooltip = User name and password can optionally be specified for HTTP and HTTPS URLs. +##view_bundle_createWizard_urlUserName = User name +##view_bundle_createWizard_windowTitle = Bundle Creation Wizard +##view_bundle_createWizard_youMustChooseOne = You must choose one option in order to create a bundle! ##view_bundle_fail_existingName = Failed to create [{0}]. The name is already being used. Please try another name. ##view_bundle_list_deletesFailure = Failed to delete the bundles ##view_bundle_list_deletesSuccessful = You successfully deleted the bundles diff --git a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_zh.properties b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_zh.properties index c74decb..8928006 100644 --- a/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_zh.properties +++ b/modules/enterprise/gui/coregui/src/main/resources/org/rhq/enterprise/gui/coregui/client/Messages_zh.properties @@ -1214,15 +1214,16 @@ view_bundle_createWizard_failedToUploadFile = \u4e0a\u4f20bundle\u6587\u4ef6\u59 ##view_bundle_createWizard_groupsStep_leaveUnassigned = Leave the new bundle unsassigned. ##view_bundle_createWizard_groupsStep_noAssignable = Unable to create initial bundle version because the user has no bundle groups to which it can be assigned. Please cancel the create wizard and notify your RHQ administrator. ##view_bundle_createWizard_groupsStep_noneAssigned = The new bundle version must be assigned to at least one bundle group!: -##view_bundle_createWizard_groupsStep_radioTitle = Initial bundle group assignment for the new bundle: +##view_bundle_createWizard_groupsStep_radioTitle = Initial bundle group assignment for the new bundle ##view_bundle_createWizard_groupsStep_unassigned = The new bundle version is for an existing bundle and inherits its bundle group assignments. The bundle in not currently assigned to any bundle groups. view_bundle_createWizard_loadBundleFileFailure = \u65e0\u6cd5\u4ece\u670d\u52a1\u5668\u83b7\u5f97bundle\u6587\u4ef6\u4fe1\u606f view_bundle_createWizard_noAdditionalFilesNeeded = No additional files need to be uploaded for this bundle view_bundle_createWizard_noBundleTypesAvail = \u65e0\u6709\u6548bundle\u7c7b\u578b -view_bundle_createWizard_noBundleTypesSupported = No bundle types are supported - you must deploy a valid plugin that supports bundle deployments +##view_bundle_createWizard_noBundleTypesSupported = No bundle types are supported - you must deploy a valid plugin that supports bundle deployments view_bundle_createWizard_provideBundleDistro = \u63d0\u4f9b\u4e00\u4e2aBundle\u53d1\u5e03\u5305 view_bundle_createWizard_recipeOption = Recipe view_bundle_createWizard_title = \u521b\u5efaBundle +##view_bundle_createWizard_unassigned = unassigned view_bundle_createWizard_uploadInProgress = \u4e0a\u4f20\u4e2d...\u5927\u6587\u4ef6\u8981\u82b1\u8d39\u6570\u5206\u949f view_bundle_createWizard_uploadOption = \u4e0a\u4f20 view_bundle_createWizard_uploadStepName = \u4e0a\u4f20Bundle\u6587\u4ef6 diff --git a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/bundle/BundleManagerBean.java b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/bundle/BundleManagerBean.java index 886e118..386b4c3 100644 --- a/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/bundle/BundleManagerBean.java +++ b/modules/enterprise/server/jar/src/main/java/org/rhq/enterprise/server/bundle/BundleManagerBean.java @@ -2011,6 +2011,10 @@ public class BundleManagerBean implements BundleManagerLocal, BundleManagerRemot
@Override public void assignBundlesToBundleGroups(Subject subject, int bundleGroupIds[], int[] bundleIds) { + if (null == bundleGroupIds || null == bundleIds) { + return; + } + for (int bundleGroupId : bundleGroupIds) { BundleGroup bundleGroup = entityManager.find(BundleGroup.class, bundleGroupId); if (null == bundleGroup) { @@ -2106,6 +2110,10 @@ public class BundleManagerBean implements BundleManagerLocal, BundleManagerRemot
@Override public void unassignBundlesFromBundleGroups(Subject subject, int[] bundleGroupIds, int[] bundleIds) { + if (null == bundleGroupIds || null == bundleIds) { + return; + } + for (int bundleGroupId : bundleGroupIds) { BundleGroup bundleGroup = entityManager.find(BundleGroup.class, bundleGroupId); if (null == bundleGroup) {
rhq-commits@lists.fedorahosted.org