mirror of
https://github.com/we-promise/sure.git
synced 2026-04-19 12:04:08 +00:00
- Handle blank series in trend method to avoid nil errors (#357)
- Add Turbo Stream rendering for SimpleFIN items to address missing content - Update dashboard view to render correctly when trend data is unavailable Co-authored-by: Josh Waldrep <joshua.waldrep5+github@gmail.com>
This commit is contained in:
@@ -515,6 +515,17 @@ class SimplefinItemsController < ApplicationController
|
||||
@simplefin_item = Current.family.simplefin_items.build(setup_token: setup_token)
|
||||
end
|
||||
@error_message = message
|
||||
render context, status: :unprocessable_entity
|
||||
|
||||
if turbo_frame_request?
|
||||
# Re-render the SimpleFIN providers panel in place to avoid "Content missing"
|
||||
@simplefin_items = Current.family.simplefin_items.ordered
|
||||
render turbo_stream: turbo_stream.replace(
|
||||
"simplefin-providers-panel",
|
||||
partial: "settings/providers/simplefin_panel",
|
||||
locals: { simplefin_items: @simplefin_items }
|
||||
), status: :unprocessable_entity
|
||||
else
|
||||
render context, status: :unprocessable_entity
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user