10111: Better labels on collection on the provenance graph.
[arvados.git] / apps / workbench / app / helpers / version_helper.rb
index 0d021fa0de07b01101f7eb736fdb3475456037ed..5c15986601e1b9b69d772d5391b88146fbec33c9 100644 (file)
@@ -1,17 +1,12 @@
 module VersionHelper
-  include ArvadosApiClientHelper
-
-  def api_version()
+  # Get the source_version given in the API server's discovery
+  # document.
+  def api_source_version
     arvados_api_client.discovery[:source_version]
   end
 
-  def wb_version()
-    Rails.configuration.source_version
-  end
-
-  def wb_version_text()
-    wbv = wb_version
-    wbv += Rails.configuration.local_modified if Rails.configuration.local_modified
-    wbv
+  # URL for browsing source code for the given version.
+  def version_link_target version
+    "https://arvados.org/projects/arvados/repository/changes?rev=#{version.sub(/-.*/, "")}"
   end
 end