mirror of
https://github.com/maybe-finance/maybe.git
synced 2025-07-24 15:49:39 +02:00
* Fix #921 * Fix linter errors * Fix test failure * Remove unused keys * Add back html rendering * Remove .tool-versions from repository * Fix failing test
This commit is contained in:
parent
3d4def59d6
commit
9e1d8a753b
3 changed files with 11 additions and 8 deletions
|
@ -15,7 +15,10 @@ class Account::TransactionsController < ApplicationController
|
|||
@transaction.update! transaction_params
|
||||
@transaction.sync_account_later
|
||||
|
||||
redirect_back_or_to account_transaction_url(@transaction.account, @transaction), notice: t(".success")
|
||||
respond_to do |format|
|
||||
format.html { redirect_back_or_to account_transaction_path(@account, @transaction), notice: t(".success") }
|
||||
format.turbo_stream { render turbo_stream: turbo_stream.replace(@transaction) }
|
||||
end
|
||||
end
|
||||
|
||||
def destroy
|
||||
|
@ -39,6 +42,6 @@ class Account::TransactionsController < ApplicationController
|
|||
end
|
||||
|
||||
def transaction_params
|
||||
params.require(:transaction).permit(:name, :date, :amount, :currency, :notes, :excluded, :category_id, :merchant_id, tag_ids: [])
|
||||
params.require(:account_transaction).permit(:name, :date, :amount, :currency, :notes, :excluded, :category_id, :merchant_id, tag_ids: [])
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue