From a3907ef3a8ffdaaeaa04c53ffd64a5fe6f9c53c0 Mon Sep 17 00:00:00 2001 From: Guilherme de Freitas Date: Mon, 2 Mar 2026 10:26:02 +0000 Subject: [PATCH 1/4] Display message for eBIC shipments if they try to access shipments --- client/src/js/modules/shipment/views/shipments.js | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/client/src/js/modules/shipment/views/shipments.js b/client/src/js/modules/shipment/views/shipments.js index 5542d2c5b..3b6443a3f 100644 --- a/client/src/js/modules/shipment/views/shipments.js +++ b/client/src/js/modules/shipment/views/shipments.js @@ -40,10 +40,12 @@ define(['marionette', return Marionette.LayoutView.extend({ className: 'content', - template: '

Shipments

This page shows a list of shipments associated with the currently selected proposal

In order to register your samples you need to create a shipment. Shipments contain dewars, dewars contain containers, and containers individual samples. These can be created sequentially by viewing a particular shipment

', + template: '

Shipments

eBIC is switching to SCAUP for shipments. Click here to select a session and create a new shipment.

This page shows a list of shipments associated with the currently selected proposal

In order to register your samples you need to create a shipment. Shipments contain dewars, dewars contain containers, and containers individual samples. These can be created sequentially by viewing a particular shipment

', regions: { 'wrap': '.wrapper' }, ui: { add: 'a.add', + ebicBanner: 'div#ebic-banner', + ebicLink: 'a#ebic-link' }, initialize: function(options) { @@ -70,6 +72,11 @@ define(['marionette', onRender: function() { if (app.proposal && app.proposal.get('ACTIVE') != 1) this.ui.add.hide() + if (app.proposal.get("TYPES").includes("em")) { + this.ui.add.hide(); + this.ui.ebicBanner.show(); + this.ui.ebicLink.prop("href", `${app.options.get("redirects").em }/proposals/${app.proposal.get("PROPOSAL")}`); + } this.wrap.show(this.table) } }) From 3d2793a421899f7303789ca8f9f128c460f95a31 Mon Sep 17 00:00:00 2001 From: Guilherme de Freitas Date: Mon, 2 Mar 2026 13:55:21 +0000 Subject: [PATCH 2/4] Do not hide add shipments button --- client/src/js/modules/shipment/views/shipments.js | 1 - 1 file changed, 1 deletion(-) diff --git a/client/src/js/modules/shipment/views/shipments.js b/client/src/js/modules/shipment/views/shipments.js index 3b6443a3f..1ce6379b0 100644 --- a/client/src/js/modules/shipment/views/shipments.js +++ b/client/src/js/modules/shipment/views/shipments.js @@ -73,7 +73,6 @@ define(['marionette', if (app.proposal && app.proposal.get('ACTIVE') != 1) this.ui.add.hide() if (app.proposal.get("TYPES").includes("em")) { - this.ui.add.hide(); this.ui.ebicBanner.show(); this.ui.ebicLink.prop("href", `${app.options.get("redirects").em }/proposals/${app.proposal.get("PROPOSAL")}`); } From 8370e234533ac81a57f8b2963c9ebda3a04c628f Mon Sep 17 00:00:00 2001 From: Guilherme de Freitas Date: Mon, 2 Mar 2026 14:42:05 +0000 Subject: [PATCH 3/4] Check if redirects has "em" before showing banner --- client/src/js/modules/shipment/views/shipments.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/client/src/js/modules/shipment/views/shipments.js b/client/src/js/modules/shipment/views/shipments.js index 1ce6379b0..9e337962e 100644 --- a/client/src/js/modules/shipment/views/shipments.js +++ b/client/src/js/modules/shipment/views/shipments.js @@ -74,7 +74,9 @@ define(['marionette', if (app.proposal.get("TYPES").includes("em")) { this.ui.ebicBanner.show(); + if (app.options.get("redirects").includes("em")) { this.ui.ebicLink.prop("href", `${app.options.get("redirects").em }/proposals/${app.proposal.get("PROPOSAL")}`); + } } this.wrap.show(this.table) } From 14a742a07fd18518773c738b289eae50959929de Mon Sep 17 00:00:00 2001 From: Guilherme Francisco Date: Mon, 2 Mar 2026 15:09:22 +0000 Subject: [PATCH 4/4] Update client/src/js/modules/shipment/views/shipments.js Co-authored-by: Mark W <24956497+ndg63276@users.noreply.github.com> --- client/src/js/modules/shipment/views/shipments.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/client/src/js/modules/shipment/views/shipments.js b/client/src/js/modules/shipment/views/shipments.js index 9e337962e..9aa4f709d 100644 --- a/client/src/js/modules/shipment/views/shipments.js +++ b/client/src/js/modules/shipment/views/shipments.js @@ -72,11 +72,9 @@ define(['marionette', onRender: function() { if (app.proposal && app.proposal.get('ACTIVE') != 1) this.ui.add.hide() - if (app.proposal.get("TYPES").includes("em")) { + if (app.proposal.get("TYPES").includes("em") && "em" in app.options.get("redirects")) { this.ui.ebicBanner.show(); - if (app.options.get("redirects").includes("em")) { this.ui.ebicLink.prop("href", `${app.options.get("redirects").em }/proposals/${app.proposal.get("PROPOSAL")}`); - } } this.wrap.show(this.table) }