OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub
Ruby agile-developmentangularbcfboardsbug-trackerganttgantt-chartifcissue-trackerjira-alternativekanbanopenprojectproduct-managementproject-managementproject-planningroadmaprubyscrumtimelineworkflows
Fix reference in ical tokens
Oliver Güntherc22808e331a0
diff --git a/app/views/my/access_tokens/_icalendar_tokens_section.html.erb b/app/views/my/access_tokens/_icalendar_tokens_section.html.erbindex 34bcdd6d8d9..d7935b96bc3 100644--- a/app/views/my/access_tokens/_icalendar_tokens_section.html.erb+++ b/app/views/my/access_tokens/_icalendar_tokens_section.html.erb@@ -34,54 +34,61 @@ See COPYRIGHT and LICENSE files for more details.</div><div><p>- <%= t("my_account.access_tokens.ical.text_hint", path: "https://www.openproject.org/docs/").html_safe %>+ <%=+ link_translate(+ "my_account.access_tokens.ical.text_hint_link",+ links: {+ docs_url: %i[user_guide access_tokens]+ }+ )+ %></p><% if Setting.ical_enabled? %><% if ical_tokens_grouped_by_query.any? %><div class="generic-table--container"><div class="generic-table--results-container"><table class="generic-table" data-controller="table-highlighting">- <%= render partial: "token_table_header",- locals: {- column_headers: [- t("attributes.name"),- Token::ICal.human_attribute_name(:calendar),- WorkPackage.human_attribute_name(:project),- User.human_attribute_name(:created_at),- t("my_account.access_tokens.headers.expiration")- ]- } %>+ <%= render partial: "token_table_header",+ locals: {+ column_headers: [+ t("attributes.name"),+ Token::ICal.human_attribute_name(:calendar),+ WorkPackage.human_attribute_name(:project),+ User.human_attribute_name(:created_at),+ t("my_account.access_tokens.headers.expiration")+ ]+ } %><tbody>- <% ical_tokens_grouped_by_query.each do |query_id, tokens| %>- <% tokens.sort_by(&:created_at).each do |token| %>- <tr>- <td class="-w-rel-20 -mw-abs-200" data-test-selector="ical-token-row-<%= token.id %>-name"><%= token.ical_token_query_assignment.name %></td>- <td class="-w-rel-20 -mw-abs-200" data-test-selector="ical-token-row-<%= token.id %>-query-name">- <%= link_to token.query.name,- project_calendar_url(- id: query_id,- project_id: token.query.project_id- ) %>- </td>- <td class="-w-rel-20 -mw-abs-200" data-test-selector="ical-token-row-<%= token.id %>-project-name">- <%= token.query.project.name %>- </td>- <td>+ <% ical_tokens_grouped_by_query.each do |query_id, tokens| %>+ <% tokens.sort_by(&:created_at).each do |token| %>+ <tr>+ <td class="-w-rel-20 -mw-abs-200" data-test-selector="ical-token-row-<%= token.id %>-name"><%= token.ical_token_query_assignment.name %></td>+ <td class="-w-rel-20 -mw-abs-200" data-test-selector="ical-token-row-<%= token.id %>-query-name">+ <%= link_to token.query.name,+ project_calendar_url(+ id: query_id,+ project_id: token.query.project_id+ ) %>+ </td>+ <td class="-w-rel-20 -mw-abs-200" data-test-selector="ical-token-row-<%= token.id %>-project-name">+ <%= token.query.project.name %>+ </td>+ <td><span title="<%= format_time(token.created_at) %>"><%= format_time(token.created_at.to_s) %></span>- </td>- <td><%= t("my_account.access_tokens.indefinite_expiration") %></td>- <td class="buttons">- <%= link_to "",- { action: "revoke_ical_token", access_token_id: token.id },- data: { confirm: t("my_account.access_tokens.simple_revoke_confirmation"), test_selector: "ical-token-row-#{token.id}-revoke" },- method: :delete,- class: "icon icon-delete" %>- </td>- </tr>- <% end %>+ </td>+ <td><%= t("my_account.access_tokens.indefinite_expiration") %></td>+ <td class="buttons">+ <%= link_to "",+ { action: "revoke_ical_token", access_token_id: token.id },+ data: { confirm: t("my_account.access_tokens.simple_revoke_confirmation"), test_selector: "ical-token-row-#{token.id}-revoke" },+ method: :delete,+ class: "icon icon-delete" %>+ </td>+ </tr><% end %>+ <% end %></tbody></table></div>diff --git a/config/locales/en.yml b/config/locales/en.ymlindex 061b25d7a8a..85b39faac3d 100644--- a/config/locales/en.yml+++ b/config/locales/en.yml@@ -2781,7 +2781,7 @@ en:static_token_name: "API token"ical:title: "iCalendar"- text_hint: 'iCalendar tokens allow users to <a href="%{path}" target="_blank">subscribe to OpenProject calendars</a> and view up-to-date work package information from external clients.'+ text_hint_link: 'iCalendar tokens allow users to [subscribe to OpenProject calendars](docs_url) and view up-to-date work package information from external clients.'disabled_text: "iCalendar subscriptions are not enabled by the administrator. Please contact your administrator to use this feature."empty_text_hint: "To add an iCalendar token, subscribe to a new or existing calendar from within the Calendar module of a project. You must have the necessary permissions."oauth:diff --git a/config/static_links.yml b/config/static_links.ymlindex 3fb591a7a0c..ff9d17b5d13 100644--- a/config/static_links.yml+++ b/config/static_links.yml@@ -213,6 +213,9 @@ upsell_get_quote:user_guides:href: https://www.openproject.org/docs/user-guide/label: homescreen.links.user_guides+user_guide:+ access_tokens:+ href: https://www.openproject.org/docs/user-guide/account-settings/#access-tokenswebinar_videos:href: https://www.youtube.com/watch?v=un6zCm8_FT4website: