mirror of
https://github.com/maybe-finance/maybe.git
synced 2025-08-09 15:35:22 +02:00
Downcase resource for confirmation
This commit is contained in:
parent
1fb39f78ee
commit
c882f08390
2 changed files with 4 additions and 4 deletions
|
@ -6,9 +6,9 @@ class CustomConfirm
|
|||
new(
|
||||
destructive: true,
|
||||
high_severity: high_severity,
|
||||
title: "Delete #{resource_name}?",
|
||||
body: "Are you sure you want to delete #{resource_name}? This is not reversible.",
|
||||
btn_text: "Delete #{resource_name}"
|
||||
title: "Delete #{resource_name.downcase}?",
|
||||
body: "Are you sure you want to delete #{resource_name.downcase}? This is not reversible.",
|
||||
btn_text: "Delete #{resource_name.downcase}"
|
||||
)
|
||||
end
|
||||
end
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
href: destroy_all_categories_path,
|
||||
method: :delete,
|
||||
icon: "trash-2",
|
||||
confirm: CustomConfirm.for_resource_deletion("All categories", high_severity: true)) %>
|
||||
confirm: CustomConfirm.for_resource_deletion("all categories", high_severity: true)) %>
|
||||
<% end %>
|
||||
|
||||
<%= render LinkComponent.new(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue