[arvados] created: 2.6.0-557-g178013be0c
git repository hosting
git at public.arvados.org
Fri Sep 1 21:42:19 UTC 2023
at 178013be0ccd804cb0579942ba50faa7cc68d52e (commit)
commit 178013be0ccd804cb0579942ba50faa7cc68d52e
Author: Peter Amstutz <peter.amstutz at curii.com>
Date: Fri Sep 1 17:26:28 2023 -0400
20850: Add deprecation notice & wb2 redirect to every page
Arvados-DCO-1.1-Signed-off-by: Peter Amstutz <peter.amstutz at curii.com>
diff --git a/apps/workbench/app/assets/stylesheets/application.css.scss b/apps/workbench/app/assets/stylesheets/application.css.scss
index 1f21c39729..547e23a41f 100644
--- a/apps/workbench/app/assets/stylesheets/application.css.scss
+++ b/apps/workbench/app/assets/stylesheets/application.css.scss
@@ -353,3 +353,14 @@ div.awesomplete {
color: #262626;
background-color: #f5f5f5;
}
+
+#deprecation-notice {
+ padding-top: 20px;
+ padding-left: 15px;
+ padding-right: 15px;
+ padding-bottom: 0px;
+}
+
+#deprecation-notice form {
+ display: inline;
+}
diff --git a/apps/workbench/app/views/layouts/body.html.erb b/apps/workbench/app/views/layouts/body.html.erb
index ed19d51d25..46af0f2d88 100644
--- a/apps/workbench/app/views/layouts/body.html.erb
+++ b/apps/workbench/app/views/layouts/body.html.erb
@@ -85,12 +85,13 @@ SPDX-License-Identifier: AGPL-3.0 %>
<% if Rails.configuration.Services.Workbench2.ExternalURL != URI("") %>
<li role="menuitem">
<%
- wb2_url = Rails.configuration.Services.Workbench2.ExternalURL.to_s
- wb2_url += '/' if wb2_url[-1] != '/'
- wb2_url += 'token'
+ wb2_url = Rails.configuration.Services.Workbench2.ExternalURL.to_s
+ if wb2_url[-1] == '/'
+ wb2_url = wb2_url.chop
+ end
+ wb2_url += request.fullpath
%>
<form action="<%= wb2_url %>" method="GET">
- <input type="hidden" name="api_token" value="<%= Thread.current[:arvados_api_token] %>">
<button role="menuitem" type="submit">
<i class="fa fa-lg fa-share-square fa-fw"></i> Go to Workbench 2
</button>
@@ -244,6 +245,22 @@ SPDX-License-Identifier: AGPL-3.0 %>
<% end %>
<% end %>
+ <div id="deprecation-notice" class="row">
+ <div class="col-md-12">
+ <div class="alert alert-block alert-warning">
+ <button type="button" class="close" data-dismiss="alert">×</button>
+ <span>You are using the <a href="https://doc.arvados.org/user/topics/workbench-migration.html">deprecated workbench application</a>
+ to access Arvados. A newer workbench application is available.
+ <form action="<%= wb2_url %>" method="GET">
+ <button type="submit">
+ <i class="fa fa-lg fa-share-square fa-fw"></i> Go to Workbench 2
+ </button>
+ </form>
+ </span>
+ </div>
+ </div>
+ </div>
+
<%= render partial: 'browser_unsupported' %><%# requires JS support below %>
<%= render partial: 'getting_started/getting_started_popup' %>
-----------------------------------------------------------------------
hooks/post-receive
--
More information about the arvados-commits
mailing list