Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions apps/dashboard/app/helpers/batch_connect/sessions_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ def relaunch(session)

user_context = session.user_context
params = batch_connect_app.attributes.map{|attribute| ["batch_connect_session_context[#{attribute.id}]", user_context.fetch(attribute.id, nil)]}.to_h.compact
title = "#{t('dashboard.batch_connect_sessions_relaunch_title')} #{session.title} #{t('dashboard.batch_connect_sessions_word')}"
title = t('dashboard.batch_connect_sessions_relaunch_full_title', title: session.title)
button_to(
batch_connect_session_contexts_path(token: batch_connect_app.token),
method: :post,
Expand Down Expand Up @@ -139,7 +139,7 @@ def cancel_or_delete(session)
end

def delete(session)
title = "#{t('dashboard.batch_connect_sessions_delete_title')} #{session.title} #{t('dashboard.batch_connect_sessions_word')}"
title = t('dashboard.batch_connect_sessions_delete_full_title', title: session.title)
button_to(
batch_connect_session_path(session.id),
method: :delete,
Expand All @@ -153,7 +153,7 @@ def delete(session)
end

def cancel(session)
title = "#{t('dashboard.batch_connect_sessions_cancel_title')} #{session.title} #{t('dashboard.batch_connect_sessions_word')}"
title = t('dashboard.batch_connect_sessions_cancel_full_title', title: session.title)
button_to(
batch_connect_cancel_session_path(session.id),
method: :post,
Expand Down
12 changes: 6 additions & 6 deletions apps/dashboard/app/helpers/files_helper.rb
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
# Helper for /files pages.
module FilesHelper
include ApplicationHelper

def files_browse_page_title(path)
prefix = "#{t('dashboard.files_title')} - #{@user_configuration.dashboard_title}"
return prefix if path.blank?

dir_segment = (path.to_s == '/') ? 'Root' : path.basename.to_s
"#{prefix} - #{dir_segment}"
def files_browse_page_title(path)
site = @user_configuration.dashboard_title
page = t('dashboard.files_title')
return t('dashboard.page_title', page: page, site: site) unless path.present?
dir_segment = path.to_s == '/' ? t('dashboard.root') : path.basename.to_s
t('dashboard.page_title_with_dir', page: page, site: site, dir: dir_segment)
end

def path_segment_with_slash(filesystem, segment, counter, total)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<% content_for :title, "#{t('dashboard.breadcrumbs_my_sessions')} - #{@user_configuration.dashboard_title}" %>
<% content_for :title, t('dashboard.page_title', page: t('dashboard.breadcrumbs_my_sessions'), site: @user_configuration.dashboard_title) %>
<%-
any_apps = (@sys_app_groups + @usr_app_groups + @dev_app_groups).any?
-%>
Expand Down
2 changes: 1 addition & 1 deletion apps/dashboard/app/views/module_browser/index.html.erb
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<% content_for :title, "#{t('dashboard.module_browser_title')} - #{@user_configuration.dashboard_title}" %>
<% content_for :title, t('dashboard.page_title', page: t('dashboard.module_browser_title'), site: @user_configuration.dashboard_title) %>

<h1 class="mb-4 d-flex justify-content-between">
<%= t('dashboard.module_browser_title') %>
Expand Down
2 changes: 1 addition & 1 deletion apps/dashboard/app/views/projects/show.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@
</div>
<div class="col-12 col-lg-7 jobs-files-item">
<div id="directory_browser" class="border border-2 px-1 py-3 mt-3 mb-5 bg-white rounded">
<h2 class="lead fw-bolder d-flex justify-content-center"><%= "#{t('dashboard.project')} #{t('dashboard.directory')}" %>: &nbsp<i><%= @project.id %></i></h2>
<h2 class="lead fw-bolder d-flex justify-content-center"><%= t('dashboard.project_directory') %>: &nbsp<i><%= @project.id %></i></h2>
<hr>
<%= turbo_frame_tag 'project_directory',
src: directory_frame_path(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
</div>
<ul class="list-unstyled mb-2">
<li>
<%= quota.to_s %><%= ". #{t('dashboard.quota_additional_message')}" %>
<%= t('dashboard.quota_message', quota: quota.to_s, additional_message: t('dashboard.quota_additional_message')) %>
</li>
<li>
<%=
Expand Down
9 changes: 9 additions & 0 deletions apps/dashboard/config/locales/en-CA.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,12 +69,14 @@ en-CA:
batch_connect_sandbox: " [Sandbox]"
batch_connect_sessions_cancel_confirm: Are you sure?
batch_connect_sessions_cancel_title: Cancel
batch_connect_sessions_cancel_full_title: "Cancel %{title} Session"
batch_connect_sessions_data_html: |
The %{title} session data for this session can be accessed
under the %{data_link_tag}.
batch_connect_sessions_delete_confirm: Are you sure?
batch_connect_sessions_delete_hover: Delete Session
batch_connect_sessions_delete_title: Delete
batch_connect_sessions_delete_full_title: "Delete %{title} Session"
batch_connect_sessions_edit_title: Edit new %{title} with this session parameters
batch_connect_sessions_error_invalid_job_name_html: |
If this job failed to submit because of an invalid job name
Expand All @@ -87,6 +89,7 @@ en-CA:
batch_connect_sessions_path_selector_forbidden_error: You do not have permission to select that directory or file.
batch_connect_sessions_relaunch_title: Relaunch
batch_connect_sessions_staged_root: staged root directory
batch_connect_sessions_relaunch_full_title: "Relaunch %{title} Session"
batch_connect_sessions_stats_created_at: 'Created at:'
batch_connect_sessions_stats_host: 'Host:'
batch_connect_sessions_stats_session_id: 'Session ID:'
Expand Down Expand Up @@ -225,6 +228,10 @@ en-CA:
mode: Mode
module_browser_last_updated: 'Last updated: %{last_updated}'
module_browser_title: Module Browser
files_title: File browsing
page_title: "%{page} - %{site}"
page_title_with_dir: "%{page} - %{site} - %{dir}"
root: Root
motd_erb_render_error: 'MOTD was not parsed or rendered correctly: %{error_message}'
motd_title: Message of the Day
name: Name
Expand Down Expand Up @@ -256,10 +263,12 @@ en-CA:
pinned_apps_category: Apps
pinned_apps_title: Pinned Apps
project: Project
project_directory: Project Directory
project_balances: Project Balances
project_zip_error_message: 'Error creating ZIP file: %{error}'
project_zip_success_message: 'SUCCESS: project.zip was created in your project directory.'
quota_additional_message: Consider deleting or archiving files to free up disk space.
quota_message: "%{quota}. %{additional_message}"
quota_block: Using %{used} of quota %{available}
quota_block_shared: "(%{used_exclusive} are yours)"
quota_file: Using %{used} files of quota %{available} files
Expand Down
8 changes: 8 additions & 0 deletions apps/dashboard/config/locales/en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,12 +70,14 @@ en:
batch_connect_sandbox: " [Sandbox]"
batch_connect_sessions_cancel_confirm: Are you sure?
batch_connect_sessions_cancel_title: Cancel
batch_connect_sessions_cancel_full_title: "Cancel %{title} Session"
batch_connect_sessions_data_html: |
The %{title} session data for this session can be accessed
under the %{data_link_tag}.
batch_connect_sessions_delete_confirm: Are you sure?
batch_connect_sessions_delete_hover: Delete Session
batch_connect_sessions_delete_title: Delete
batch_connect_sessions_delete_full_title: "Delete %{title} Session"
batch_connect_sessions_edit_title: Edit new %{title} with this session parameters
batch_connect_sessions_error_invalid_job_name_html: |
If this job failed to submit because of an invalid job name
Expand All @@ -87,6 +89,7 @@ en:
batch_connect_sessions_novnc_view_only: View Only (Share-able Link)
batch_connect_sessions_path_selector_forbidden_error: You do not have permission to select that directory or file.
batch_connect_sessions_relaunch_title: Relaunch
batch_connect_sessions_relaunch_full_title: "Relaunch %{title} Session"
batch_connect_sessions_staged_root: staged root directory
batch_connect_sessions_stats_created_at: 'Created at:'
batch_connect_sessions_stats_host: 'Host:'
Expand Down Expand Up @@ -251,6 +254,9 @@ en:
module_browser_last_updated: 'Last updated: %{last_updated}'
module_browser_title: Module Browser
files_title: File browsing
page_title: "%{page} - %{site}"
page_title_with_dir: "%{page} - %{site} - %{dir}"
root: Root
motd_erb_render_error: 'MOTD was not parsed or rendered correctly: %{error_message}'
motd_title: Message of the Day
name: Name
Expand Down Expand Up @@ -282,10 +288,12 @@ en:
pinned_apps_category: Apps
pinned_apps_title: Pinned Apps
project: Project
project_directory: Project Directory
project_balances: Project Balances
project_zip_error_message: 'Error creating ZIP file: %{error}'
project_zip_success_message: 'Success: project.zip has been created in your project directory.'
quota_additional_message: Consider deleting or archiving files to free up disk space.
quota_message: "%{quota}. %{additional_message}"
quota_block: Using %{used} of quota %{available}
quota_block_shared: "(%{used_exclusive} are yours)"
quota_file: Using %{used} files of quota %{available} files
Expand Down
9 changes: 9 additions & 0 deletions apps/dashboard/config/locales/fr-CA.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,12 +69,14 @@ fr-CA:
batch_connect_sandbox: " [Bac à sable]"
batch_connect_sessions_cancel_confirm: Êtes-vous sûr ?
batch_connect_sessions_cancel_title: Annuler
batch_connect_sessions_cancel_full_title: "Annuler la session %{title}"
batch_connect_sessions_data_html: |
Les données de session %{title} pour cette session sont accessibles
sous %{data_link_tag}.
batch_connect_sessions_delete_confirm: Êtes-vous sûr ?
batch_connect_sessions_delete_hover: Supprimer la session
batch_connect_sessions_delete_title: Supprimer
batch_connect_sessions_delete_full_title: "Supprimer la session %{title}"
batch_connect_sessions_edit_title: Modifier %{title} avec les paramètres de cette session
batch_connect_sessions_error_invalid_job_name_html: |
Si ce travail a échoué en raison d'un nom de travail invalide,
Expand All @@ -86,6 +88,7 @@ fr-CA:
batch_connect_sessions_novnc_view_only: Vue seule (Lien partageable)
batch_connect_sessions_path_selector_forbidden_error: Vous n'avez pas la permission de sélectionner ce répertoire ou fichier.
batch_connect_sessions_relaunch_title: Relancer
batch_connect_sessions_relaunch_full_title: "Relancer la session %{title}"
batch_connect_sessions_staged_root: répertoire racine mis en scène
batch_connect_sessions_stats_created_at: 'Créé le :'
batch_connect_sessions_stats_host: 'Hôte :'
Expand Down Expand Up @@ -226,6 +229,10 @@ fr-CA:
module_browser_last_updated: 'Dernière mise à jour : %{last_updated}'
module_browser_title: Navigateur de modules
motd_erb_render_error: 'Le MOTD n’a pas été analysé ou rendu correctement : %{error_message}'
files_title: Navigation de fichiers
page_title: "%{page} - %{site}"
page_title_with_dir: "%{page} - %{site} - %{dir}"
root: Racine
motd_title: Message du jour
name: Nom
nav_all_apps: Toutes les applications
Expand Down Expand Up @@ -256,10 +263,12 @@ fr-CA:
pinned_apps_category: Applications
pinned_apps_title: Applications épinglées
project: Projet
project_directory: Répertoire du projet
project_balances: Soldes de projet
project_zip_error_message: 'Erreur lors de la création du fichier ZIP : %{error}'
project_zip_success_message: 'SUCCÈS : project.zip a été créé dans votre répertoire de projet.'
quota_additional_message: Envisagez de supprimer ou d’archiver des fichiers pour libérer de l’espace disque.
quota_message: "%{quota}. %{additional_message}"
quota_block: Utilisation de %{used} sur quota %{available}
quota_block_shared: "(%{used_exclusive} vous appartiennent)"
quota_file: Utilisation de %{used} fichiers sur quota %{available} fichiers
Expand Down
9 changes: 9 additions & 0 deletions apps/dashboard/config/locales/ja_JP.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,12 +67,14 @@ ja_JP:
batch_connect_sandbox: " [サンドボックス]"
batch_connect_sessions_cancel_confirm: 本当によろしいですか?
batch_connect_sessions_cancel_title: キャンセル
batch_connect_sessions_cancel_full_title: "%{title} セッションをキャンセル"
batch_connect_sessions_data_html: |
このセッションの %{title} セッションデータは
%{data_link_tag} の下でアクセスできます。
batch_connect_sessions_delete_confirm: 本当によろしいですか?
batch_connect_sessions_delete_hover: セッションを削除
batch_connect_sessions_delete_title: 削除
batch_connect_sessions_delete_full_title: "%{title} セッションを削除"
batch_connect_sessions_edit_title: このセッションパラメータで新しい%{title}を編集
batch_connect_sessions_error_invalid_job_name_html: '無効なジョブ名のためにこのジョブの提出に失敗した場合は、管理者に依頼して OnDemand を構成し、環境変数 OOD_JOB_NAME_ILLEGAL_CHARS を設定してください。

Expand All @@ -83,6 +85,7 @@ ja_JP:
batch_connect_sessions_novnc_view_only: 表示専用(共有可能なリンク)
batch_connect_sessions_path_selector_forbidden_error: そのディレクトリまたはファイルを選択する権限がありません。
batch_connect_sessions_relaunch_title: 再起動
batch_connect_sessions_relaunch_full_title: "%{title} セッションを再起動"
batch_connect_sessions_staged_root: ステージングルートディレクトリ
batch_connect_sessions_stats_created_at: 作成日時:
batch_connect_sessions_stats_host: ホスト:
Expand Down Expand Up @@ -222,6 +225,10 @@ ja_JP:
mode: モード
module_browser_last_updated: '最終更新日: %{last_updated}'
module_browser_title: モジュールブラウザ
files_title: ファイルブラウジング
page_title: "%{page} - %{site}"
page_title_with_dir: "%{page} - %{site} - %{dir}"
root: ルート
motd_erb_render_error: 'MOTD が正しく解析またはレンダリングされませんでした: %{error_message}'
motd_title: 今日のメッセージ
name: 名前
Expand Down Expand Up @@ -253,10 +260,12 @@ ja_JP:
pinned_apps_category: アプリ
pinned_apps_title: ピン留めされたアプリ
project: プロジェクト
project_directory: プロジェクトディレクトリ
project_balances: プロジェクト残高
project_zip_error_message: 'ZIP ファイルの作成中にエラーが発生しました: %{error}'
project_zip_success_message: '成功: project.zip がプロジェクトディレクトリに作成されました。'
quota_additional_message: ディスクスペースを空けるためにファイルを削除またはアーカイブすることを検討してください。
quota_message: "%{quota}。%{additional_message}"
quota_block: クォータ %{available} のうち %{used} を使用中
quota_block_shared: "(%{used_exclusive} はあなたのものです)"
quota_file: クォータ %{available} ファイルのうち %{used} ファイルを使用中
Expand Down
9 changes: 9 additions & 0 deletions apps/dashboard/config/locales/zh-CN.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,12 @@ zh-CN:
batch_connect_sandbox: " [沙盒]"
batch_connect_sessions_cancel_confirm: 你确定吗?
batch_connect_sessions_cancel_title: 取消
batch_connect_sessions_cancel_full_title: "取消 %{title} 会话"
batch_connect_sessions_data_html: 你可以通过%{data_link_tag}来获取会话数据%{title}。
batch_connect_sessions_delete_confirm: 你确定吗?
batch_connect_sessions_delete_hover: 删除会话
batch_connect_sessions_delete_title: 删除
batch_connect_sessions_delete_full_title: "删除 %{title} 会话"
batch_connect_sessions_edit_title: 使用此会话参数编辑新的 %{title}
batch_connect_sessions_error_invalid_job_name_html: 如果由于作业名称无效而导致该作业提交失败,请要求管理员配置OnDemand来设置环境变量OOD_JOB_NAME_ILLEGAL_CHARS。
batch_connect_sessions_errors_staging: 无法调用模板,并显示以下错误:
Expand All @@ -78,6 +80,7 @@ zh-CN:
batch_connect_sessions_novnc_view_only: 只读 (共享链接)
batch_connect_sessions_path_selector_forbidden_error: 您没有权限选择该目录或文件。
batch_connect_sessions_relaunch_title: 重新启动
batch_connect_sessions_relaunch_full_title: "重新启动 %{title} 会话"
batch_connect_sessions_staged_root: 暂存根目录
batch_connect_sessions_stats_created_at: 创建于:
batch_connect_sessions_stats_host: 主机:
Expand Down Expand Up @@ -211,6 +214,10 @@ zh-CN:
mode: 模式
module_browser_last_updated: 最后更新:%{last_updated}
module_browser_title: 模块浏览器
files_title: 文件浏览
page_title: "%{page} - %{site}"
page_title_with_dir: "%{page} - %{site} - %{dir}"
root: 根目录
motd_erb_render_error: MOTD 未正确解析或渲染:%{error_message}
motd_title: 每日信息
name: 名称
Expand Down Expand Up @@ -242,10 +249,12 @@ zh-CN:
pinned_apps_category: 应用
pinned_apps_title: 固定应用
project: 项目
project_directory: 项目目录
project_balances: 项目余额
project_zip_error_message: 创建 ZIP 文件时出错:%{error}
project_zip_success_message: 成功:project.zip 已在您的项目目录中创建。
quota_additional_message: 考虑删除或归档文件以释放磁盘空间。
quota_message: "%{quota}。%{additional_message}"
quota_block: 配额使用量%{used} 可用 %{available}
quota_block_shared: "(您的配额%{used_exclusive} )"
quota_file: 文件配额使用量%{used} 可用 %{available}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ class BatchConnect::SessionsHelperTest < ActionView::TestCase
assert_equal true, form['class'].include?('relaunch')

button = html.at_css('button')
assert_equal 'Relaunch AppName Session', button['title']
assert_equal I18n.t('dashboard.batch_connect_sessions_relaunch_full_title', title: 'AppName'), button['title']
assert_equal true, button['class'].include?('relaunch')
end

Expand All @@ -80,10 +80,10 @@ def create_session(state = :running, valid: true)
end

def cancel_session_title
"#{I18n.t('dashboard.batch_connect_sessions_cancel_title')} AppName #{I18n.t('dashboard.batch_connect_sessions_word')}"
I18n.t('dashboard.batch_connect_sessions_cancel_full_title', title: 'AppName')
end

def delete_session_title
"#{I18n.t('dashboard.batch_connect_sessions_delete_title')} AppName #{I18n.t('dashboard.batch_connect_sessions_word')}"
I18n.t('dashboard.batch_connect_sessions_delete_full_title', title: 'AppName')
end
end
4 changes: 4 additions & 0 deletions spec/e2e/dex_no_proxy_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@ def browser

after(:all) do
browser.close
upload_portal_config('portal.yml')
update_ood_portal
restart_apache
restart_dex
end

describe port(8080) do
Expand Down
3 changes: 3 additions & 0 deletions spec/e2e/e2e_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ def browser_login(browser)
browser.text_field(id: 'username').set 'ood@localhost'
browser.text_field(id: 'password').set 'password'
browser.button(id: 'submit-login').click
Watir::Wait.until(timeout: 90, interval: 1) do
browser.title == 'Dashboard - Open OnDemand'
end
end

def hook_fixture(file)
Expand Down
Loading