diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/generic/client/web/client/application/CommonViewContext.java b/openbis/source/java/ch/systemsx/cisd/openbis/generic/client/web/client/application/CommonViewContext.java index 50e693a29fd8c339c96b965686116093e58848d2..631e0790c969353c8348ead1f80d5c9772220464 100644 --- a/openbis/source/java/ch/systemsx/cisd/openbis/generic/client/web/client/application/CommonViewContext.java +++ b/openbis/source/java/ch/systemsx/cisd/openbis/generic/client/web/client/application/CommonViewContext.java @@ -17,7 +17,6 @@ package ch.systemsx.cisd.openbis.generic.client.web.client.application; import ch.systemsx.cisd.openbis.generic.client.web.client.ICommonClientServiceAsync; -import ch.systemsx.cisd.openbis.generic.client.web.client.application.util.CompositeMessageProvider; import ch.systemsx.cisd.openbis.generic.client.web.client.application.util.DictonaryBasedMessageProvider; import ch.systemsx.cisd.openbis.generic.client.web.client.application.util.IMessageProvider; @@ -28,8 +27,7 @@ import ch.systemsx.cisd.openbis.generic.client.web.client.application.util.IMess */ public final class CommonViewContext implements IViewContext<ICommonClientServiceAsync> { - // We use here 'generic' because we did not split the javascript dictionary yet. - private static final String TECHNOLOGY_NAME = "generic"; + private static final String TECHNOLOGY_NAME = "common"; private final ICommonClientServiceAsync service; @@ -48,9 +46,7 @@ public final class CommonViewContext implements IViewContext<ICommonClientServic final IPageController pageController) { this.service = service; - this.messageProvider = - new CompositeMessageProvider(new DictonaryBasedMessageProvider(TECHNOLOGY_NAME), - messageProvider); + this.messageProvider = new DictonaryBasedMessageProvider(TECHNOLOGY_NAME); this.imageBundle = imageBundle; this.pageController = pageController; viewModel = new GenericViewModel(); diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/generic/client/web/public/generic-dictionary.js b/openbis/source/java/ch/systemsx/cisd/openbis/generic/client/web/public/generic-dictionary.js index 33aae2042a080480d65f266bc07f48e443636788..83db1cdb095f133024ddb99cad20434e3707aaf0 100644 --- a/openbis/source/java/ch/systemsx/cisd/openbis/generic/client/web/public/generic-dictionary.js +++ b/openbis/source/java/ch/systemsx/cisd/openbis/generic/client/web/public/generic-dictionary.js @@ -1,87 +1,18 @@ -// Generic dictionary +// Generic plugin dictionary var generic = { - welcome: "Welcome to " + common["applicationName"], - footer: common["applicationName"] + " (Version {0})", - - // - // LoginWidget - // - - login_invitation: "Please login to start your session:", - login_userLabel: "User", - login_passwordLabel: "Password", - login_buttonLabel: "login", - login_failed: "Sorry, you entered an invalid username or password. Please try again.", - - // - // AbstractAsyncCallback - // - - exception_invocationMessage: "Failed to contact service.", - exception_withoutMessage: "Unknown failure has occurred (ask administrator):<br>{0}", - + // - // Header + // Sample Viewer // - header_userWithoutHomegroup: "{0} (no home group)", - header_userWithHomegroup: "{0} (home group: {1})", - header_logoutButtonLabel: "logout", - - personsView_heading: "Persons", - groupsView_heading: "Groups", - rolesView_heading: "Roles", - sample_properties_heading: "Sample Properties", part_of_heading: "Components", external_data_heading: "External Data", - - // - // Sample - // - - sample: "Sample", - sample_type: "Sample Type", - database_instance: "Instance", - sample_identifier: "Identifier", - is_instance_sample: "Shared?", - is_invalid: "Invalid?", - group: "Group", - project: "Project", - experiment: "Experiment", - experiment_identifier: "Experiment Identifier", - generated_samples: "Generated Samples", - generated_from: "Parent {0}", - part_of: "Container {0}", - - // - // Invalidation - // - invalidation: "Invalidation", invalidation_template: "Invalidated by: {0}<br>Invalidation Date: {1}<br>Invalidation Reason: {2}", - - // - // External data - // - location: "Location", file_format_type: "File Format", - // - // Search - // - - search_button: "Search", - global_search: "[{0}]: '{1}'", - identifier: "Identifier", - no_match: "No results found for '{0}'.", - entity_type: "Entity Type", - entity_kind: "Entity Kind", - matching_text: "Matching Text", - matching_field: "Matching Field", - too_generic: "Query string '{0}' is too generic.", - // LAST LINE: KEEP IT AT THE END lastline: "" // we need a line without a comma }; \ No newline at end of file diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/plugin/generic/client/web/client/application/GenericViewContext.java b/openbis/source/java/ch/systemsx/cisd/openbis/plugin/generic/client/web/client/application/GenericViewContext.java index a71d3155c82be2d92f5796705748c57a1b938da3..ac6d452113051428273ad494dad27eedfb44f796 100644 --- a/openbis/source/java/ch/systemsx/cisd/openbis/plugin/generic/client/web/client/application/GenericViewContext.java +++ b/openbis/source/java/ch/systemsx/cisd/openbis/plugin/generic/client/web/client/application/GenericViewContext.java @@ -7,6 +7,8 @@ import ch.systemsx.cisd.openbis.generic.client.web.client.ICommonClientServiceAs import ch.systemsx.cisd.openbis.generic.client.web.client.application.AbstractPluginViewContext; import ch.systemsx.cisd.openbis.generic.client.web.client.application.GenericConstants; import ch.systemsx.cisd.openbis.generic.client.web.client.application.IViewContext; +import ch.systemsx.cisd.openbis.generic.client.web.client.application.util.CompositeMessageProvider; +import ch.systemsx.cisd.openbis.generic.client.web.client.application.util.DictonaryBasedMessageProvider; import ch.systemsx.cisd.openbis.generic.client.web.client.application.util.IMessageProvider; import ch.systemsx.cisd.openbis.plugin.generic.client.web.client.IGenericClientService; import ch.systemsx.cisd.openbis.plugin.generic.client.web.client.IGenericClientServiceAsync; @@ -27,11 +29,9 @@ public final class GenericViewContext extends AbstractPluginViewContext<IGeneric public GenericViewContext(final IViewContext<ICommonClientServiceAsync> commonViewContext) { super(commonViewContext); - // We currently use the message provider of the common view context. - // this.messageProvider = - // new CompositeMessageProvider(new DictonaryBasedMessageProvider(TECHNOLOGY_NAME), - // commonViewContext.getMessageProvider()); - this.messageProvider = commonViewContext.getMessageProvider(); + this.messageProvider = + new CompositeMessageProvider(new DictonaryBasedMessageProvider(TECHNOLOGY_NAME), + commonViewContext.getMessageProvider()); this.service = createScreeningClientService(); } diff --git a/openbis/source/java/ch/systemsx/cisd/openbis/public/common-dictionary.js b/openbis/source/java/ch/systemsx/cisd/openbis/public/common-dictionary.js index 592d70bae2e1b26fe83e1cd7d37b50d0235d580a..fc35df539f863cb48902a70b2474db2dee3eb33a 100644 --- a/openbis/source/java/ch/systemsx/cisd/openbis/public/common-dictionary.js +++ b/openbis/source/java/ch/systemsx/cisd/openbis/public/common-dictionary.js @@ -1,9 +1,12 @@ // Common dictionary var common = { + applicationName: "openBIS", + welcome: "Welcome to openBIS", + footer: "openBIS (Version {0})", // - // Labels + // Common Labels // code: "Code", @@ -17,6 +20,71 @@ var common = { messagebox_error: "Error", messagebox_warning: "Warning", messagebox_info: "Info", + + // + // LoginWidget + // + + login_invitation: "Please login to start your session:", + login_userLabel: "User", + login_passwordLabel: "Password", + login_buttonLabel: "login", + login_failed: "Sorry, you entered an invalid username or password. Please try again.", + + // + // AbstractAsyncCallback + // + + exception_invocationMessage: "Failed to contact service.", + exception_withoutMessage: "Unknown failure has occurred (ask administrator):<br>{0}", + + // + // Header + // + + header_userWithoutHomegroup: "{0} (no home group)", + header_userWithHomegroup: "{0} (home group: {1})", + header_logoutButtonLabel: "logout", + + // + // Authorization Management Console + // + + personsView_heading: "Persons", + groupsView_heading: "Groups", + rolesView_heading: "Roles", + + // + // Search + // + + search_button: "Search", + global_search: "[{0}]: '{1}'", + identifier: "Identifier", + no_match: "No results found for '{0}'.", + entity_type: "Entity Type", + entity_kind: "Entity Kind", + matching_text: "Matching Text", + matching_field: "Matching Field", + too_generic: "Query string '{0}' is too generic.", + + // + // Sample Browser + // + + sample: "Sample", + sample_type: "Sample Type", + database_instance: "Instance", + sample_identifier: "Identifier", + is_instance_sample: "Shared?", + is_invalid: "Invalid?", + group: "Group", + project: "Project", + experiment: "Experiment", + experiment_identifier: "Experiment Identifier", + generated_samples: "Generated Samples", + generated_from: "Parent {0}", + part_of: "Container {0}", // LAST LINE: KEEP IT AT THE END lastline: "" // we need a line without a comma