Added the message in the message.properties.

Signed-off-by: Gaurav <gaurav.sahay@in.bosch.com>
This commit is contained in:
Gaurav
2016-08-05 10:49:24 +02:00
parent 9de4a8de69
commit 9bd47a5c55
5 changed files with 8 additions and 9 deletions

View File

@@ -187,9 +187,7 @@ public class SoftwareModuleDetailsTable extends Table {
final Set<SoftwareModule> alreadyAssignedSwModules) { final Set<SoftwareModule> alreadyAssignedSwModules) {
final SoftwareModule unAssignedSw = getSoftwareModule(event.getButton().getId(), alreadyAssignedSwModules); final SoftwareModule unAssignedSw = getSoftwareModule(event.getButton().getId(), alreadyAssignedSwModules);
if (distributionSetManagement.isDistributionSetInUse(distributionSet)) { if (distributionSetManagement.isDistributionSetInUse(distributionSet)) {
uiNotification.displayValidationError( uiNotification.displayValidationError(i18n.get("message.error.notification.ds.target.assigned",distributionSet.getName(), distributionSet.getVersion()));
String.format("Distribution set %s:%s is already assigned to targets and cannot be changed",
distributionSet.getName(), distributionSet.getVersion()));
} else { } else {
final DistributionSet newDistributionSet = distributionSetManagement.unassignSoftwareModule(distributionSet, final DistributionSet newDistributionSet = distributionSetManagement.unassignSoftwareModule(distributionSet,
unAssignedSw); unAssignedSw);

View File

@@ -334,9 +334,7 @@ public class DistributionSetTable extends AbstractNamedVersionTable<Distribution
} }
if (distributionSetManagement.isDistributionSetInUse(ds)) { if (distributionSetManagement.isDistributionSetInUse(ds)) {
notification.displayValidationError( notification.displayValidationError(i18n.get("message.error.notification.ds.target.assigned", ds.getName(), ds.getVersion()));
String.format("Distribution set %s:%s is already assigned to targets and cannot be changed",
ds.getName(), ds.getVersion()));
return false; return false;
} }
return true; return true;
@@ -506,7 +504,7 @@ public class DistributionSetTable extends AbstractNamedVersionTable<Distribution
return columnList; return columnList;
} }
private Button createManageMetadataButton(String nameVersionStr) { private Button createManageMetadataButton(final String nameVersionStr) {
final Button manageMetadataBtn = SPUIComponentProvider.getButton( final Button manageMetadataBtn = SPUIComponentProvider.getButton(
SPUIComponentIdProvider.DS_TABLE_MANAGE_METADATA_ID + "." + nameVersionStr, "", "", null, false, SPUIComponentIdProvider.DS_TABLE_MANAGE_METADATA_ID + "." + nameVersionStr, "", "", null, false,
FontAwesome.LIST_ALT, SPUIButtonStyleSmallNoBorder.class); FontAwesome.LIST_ALT, SPUIButtonStyleSmallNoBorder.class);
@@ -515,8 +513,8 @@ public class DistributionSetTable extends AbstractNamedVersionTable<Distribution
return manageMetadataBtn; return manageMetadataBtn;
} }
private void showMetadataDetails(Long itemId) { private void showMetadataDetails(final Long itemId) {
DistributionSet ds = distributionSetManagement.findDistributionSetByIdWithDetails(itemId); final DistributionSet ds = distributionSetManagement.findDistributionSetByIdWithDetails(itemId);
UI.getCurrent().addWindow(dsMetadataPopupLayout.getWindow(ds,null)); UI.getCurrent().addWindow(dsMetadataPopupLayout.getWindow(ds,null));
} }

View File

@@ -386,6 +386,7 @@ message.metadata.updated = Metadata with key {0} successfully updated !
message.metadata.duplicate.check = Metadata with key {0} already exists, please enter another value message.metadata.duplicate.check = Metadata with key {0} already exists, please enter another value
message.metadata.deleted.successfully = Metadata with key {0} successfully deleted ! message.metadata.deleted.successfully = Metadata with key {0} successfully deleted !
message.confirm.delete.metadata = Are you sure that you want to delete metadata with key {0} ? message.confirm.delete.metadata = Are you sure that you want to delete metadata with key {0} ?
message.error.notification.ds.target.assigned = Distribution set {0}:{1} is already assigned to targets and cannot be changed
# Login view # Login view
notification.login.title=Welcome to Bosch IoT Software Provisioning. notification.login.title=Welcome to Bosch IoT Software Provisioning.

View File

@@ -375,6 +375,7 @@ message.metadata.updated = Metadata with key {0} successfully updated !
message.metadata.duplicate.check = Metadata with key {0} already exists, please enter another value message.metadata.duplicate.check = Metadata with key {0} already exists, please enter another value
message.metadata.deleted.successfully = Metadata with key {0} successfully deleted ! message.metadata.deleted.successfully = Metadata with key {0} successfully deleted !
message.confirm.delete.metadata = Are you sure that you want to delete metadata with key {0} ? message.confirm.delete.metadata = Are you sure that you want to delete metadata with key {0} ?
message.error.notification.ds.target.assigned = Distribution set {0}:{1} is already assigned to targets and cannot be changed
# Login view # Login view

View File

@@ -371,6 +371,7 @@ message.metadata.updated = Metadata with key {0} successfully updated !
message.metadata.duplicate.check = Metadata with key {0} already exists, please enter another value message.metadata.duplicate.check = Metadata with key {0} already exists, please enter another value
message.metadata.deleted.successfully = Metadata with key {0} successfully deleted ! message.metadata.deleted.successfully = Metadata with key {0} successfully deleted !
message.confirm.delete.metadata = Are you sure that you want to delete metadata with key {0} ? message.confirm.delete.metadata = Are you sure that you want to delete metadata with key {0} ?
message.error.notification.ds.target.assigned = Distribution set {0}:{1} is already assigned to targets and cannot be changed
# Login view # Login view
notification.login.title=Welcome to Bosch IoT Software Provisioning. notification.login.title=Welcome to Bosch IoT Software Provisioning.