1
0
Fork 0
mirror of https://github.com/maybe-finance/maybe.git synced 2025-08-03 04:25:21 +02:00

Account namespace updates: part 6 (transactions) (#904)

* Move Transaction to Account namespace

* Fix improper routes, improve separation of concerns

* Replace account transactions list partial with view

* Remove logs

* Consolidate transaction views

* Remove unused code

* Transfer style tweaks

* Remove more unused code

* Add back totals by currency helper
This commit is contained in:
Zach Gollwitzer 2024-06-24 11:58:39 -04:00 committed by GitHub
parent cb3fd34f90
commit da18c3d850
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
72 changed files with 575 additions and 522 deletions

View file

@ -0,0 +1,49 @@
---
en:
account:
transactions:
destroy:
success: Transaction deleted successfully
empty:
description: Try adding a transaction, editing filters or refining your search
title: No transactions found
index:
new: New transaction
no_transactions: No transactions for this account yet.
transaction: transaction
transactions: Transactions
loading:
loading: Loading transactions...
selection_bar:
mark_transfers: Mark as transfers?
mark_transfers_confirm: Mark as transfers
mark_transfers_message: By marking transactions as transfers, they will no
longer be included in income or spending calculations.
show:
account_label: Account
account_placeholder: Select an account
additional: Additional
category_label: Category
category_placeholder: Select a category
date_label: Date
delete: Delete
delete_subtitle: This permanently deletes the transaction, affects your historical
balances, and cannot be undone.
delete_title: Delete transaction
exclude_subtitle: This excludes the transaction from any in-app features or
analytics.
exclude_title: Exclude transaction
merchant_label: Merchant
merchant_placeholder: Select a merchant
name_label: Name
note_label: Notes
note_placeholder: Enter a note
overview: Overview
settings: Settings
tags_label: Select one or more tags
transaction:
remove_transfer: Remove transfer
remove_transfer_body: This will remove the transfer from this transaction
remove_transfer_confirm: Confirm
update:
success: Transaction updated successfully

View file

@ -9,7 +9,12 @@ en:
index:
change: change
date: date
new_entry: New entry
no_valuations: No valuations for this account yet
valuations: Value history
value: value
loading:
loading: Loading history...
update:
success: Valuation updated
valuation:

View file

@ -58,12 +58,9 @@ en:
confirm_title: Delete account?
edit: Edit
import: Import transactions
loading_history: Loading account history...
new_entry: New entry
sync_message_missing_rates: Since exchange rates haven't been synced, balance
graphs may not reflect accurate values.
sync_message_unknown_error: An error has occurred during the sync.
valuations: Value history
summary:
new: New account
sync:

View file

@ -24,11 +24,6 @@ en:
success: "%{count} transactions updated"
create:
success: New transaction created successfully
destroy:
success: Transaction deleted successfully
empty:
description: Try adding a transaction, editing filters or refining your search
title: No transactions found
form:
account: Account
account_prompt: Select an Account
@ -52,38 +47,5 @@ en:
success: Marked as transfer
pagination:
rows_per_page: Rows per page
selection_bar:
mark_transfers: Mark as transfers?
mark_transfers_confirm: Mark as transfers
mark_transfers_message: By marking transactions as transfers, they will no longer
be included in income or spending calculations.
show:
account_label: Account
account_placeholder: Select an account
additional: Additional
category_label: Category
category_placeholder: Select a category
date_label: Date
delete: Delete
delete_subtitle: This permanently deletes the transaction, affects your historical
balances, and cannot be undone.
delete_title: Delete transaction
exclude_subtitle: This excludes the transaction from any in-app features or
analytics.
exclude_title: Exclude transaction
merchant_label: Merchant
merchant_placeholder: Select a merchant
name_label: Name
note_label: Notes
note_placeholder: Enter a note
overview: Overview
settings: Settings
tags_label: Select one or more tags
transaction:
remove_transfer: Remove transfer
remove_transfer_body: This will remove the transfer from this transaction
remove_transfer_confirm: Confirm
unmark_transfers:
success: Transfer removed
update:
success: Transaction updated successfully

View file

@ -51,23 +51,12 @@ Rails.application.routes.draw do
resources :merchants, only: %i[ index new create edit update destroy ]
namespace :transaction do
resources :rows, only: %i[ show update ]
resources :rules, only: %i[ index ]
end
resources :transactions do
collection do
post "bulk_delete"
get "bulk_edit"
post "bulk_update"
post "mark_transfers"
post "unmark_transfers"
end
end
namespace :account do
resources :transfers, only: %i[ new create destroy ]
namespace :transaction do
resources :rules, only: %i[ index ]
end
end
resources :accounts do
@ -82,7 +71,22 @@ Rails.application.routes.draw do
scope module: :account do
resource :logo, only: :show
resources :valuations
resources :transactions, only: %i[ index show update destroy ] do
resource :row, only: %i[ show update ], module: :transaction
end
end
end
resources :transactions, only: %i[ index new create ] do
collection do
post "bulk_delete"
get "bulk_edit"
post "bulk_update"
post "mark_transfers"
post "unmark_transfers"
end
end