Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shared feed import validation message: Format URLs using Markdown #1897

Merged
merged 2 commits into from
May 22, 2024
Merged
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
2 changes: 1 addition & 1 deletion app/models/cluster.rb
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ def import_medias_to_team(team, claim_title, claim_context, parent_id = nil)
existing_items << existing_item
existing_item.nil?
end
raise ActiveRecord::RecordNotUnique.new(I18n.t(:shared_feed_imported_media_already_exist, urls: existing_items.map(&:full_url).uniq.compact_blank.join(', '))) if from_project_media.nil?
raise ActiveRecord::RecordNotUnique.new(I18n.t(:shared_feed_imported_media_already_exist, urls: existing_items.uniq.compact_blank.collect{ |pm| "•︎ [#{pm.title}](#{pm.full_url})" }.join("\n"))) if from_project_media.nil?
parent = nil
if parent_id.nil?
parent = self.import_media_to_team(team, from_project_media, claim_title, claim_context)
Expand Down
5 changes: 4 additions & 1 deletion config/locales/en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -822,7 +822,10 @@ en:
send_every_must_be_a_list_of_days_of_the_week: must be a list of days of the week.
send_on_must_be_in_the_future: can't be in the past.
cant_delete_default_folder: The default folder can't be deleted
shared_feed_imported_media_already_exist: "No media to import. All media items from this item already exist in your workspace: %{urls}"
shared_feed_imported_media_already_exist: |-
No media eligible to be imported into your workspace.
The media selected to import already exist in your workspace in the following items:
%{urls}
info:
messages:
sent_to_trash_by_rule: '"%{item_title}" has been sent to trash by an automation
Expand Down
Loading