Fix devices_path route helper in native devices partial
The manage devices link used `devices_path` but the route is defined in the saas engine, so it needs `saas.devices_path`. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -5,7 +5,7 @@
|
||||
<p class="txt-small">
|
||||
You have <%= pluralize(Current.identity.devices.count, "mobile device") %> registered for push notifications.
|
||||
</p>
|
||||
<%= link_to "Manage devices", devices_path, class: "btn txt-small" %>
|
||||
<%= link_to "Manage devices", saas.devices_path, class: "btn txt-small" %>
|
||||
<% else %>
|
||||
<p class="txt-small color-secondary">
|
||||
No mobile devices registered. Install the iOS or Android app to receive push notifications on your phone.
|
||||
|
||||
@@ -25,6 +25,14 @@ class DevicesControllerTest < ActionDispatch::IntegrationTest
|
||||
assert_select "p", /No devices registered/
|
||||
end
|
||||
|
||||
test "show notification settings with registered devices" do
|
||||
@identity.devices.create!(token: "test_token", platform: "apple", name: "iPhone 15 Pro")
|
||||
|
||||
get notifications_settings_path
|
||||
|
||||
assert_response :success
|
||||
end
|
||||
|
||||
test "index requires authentication" do
|
||||
sign_out
|
||||
|
||||
|
||||
Reference in New Issue
Block a user