diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 8bf3cf28575..24c962df2b3 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -4,7 +4,7 @@ module ApplicationHelper def date_format_options [ [ "DD-MM-YYYY", "%d-%m-%Y" ], - [ "DD.MM.YY", "%d.%m.%Y" ], + [ "DD.MM.YYYY", "%d.%m.%Y" ], [ "MM-DD-YYYY", "%m-%d-%Y" ], [ "YYYY-MM-DD", "%Y-%m-%d" ], [ "DD/MM/YYYY", "%d/%m/%Y" ], diff --git a/app/models/account/holding_calculator.rb b/app/models/account/holding_calculator.rb index b1f6fc2fc44..5f6673deb48 100644 --- a/app/models/account/holding_calculator.rb +++ b/app/models/account/holding_calculator.rb @@ -98,7 +98,7 @@ def gapfill_holdings(holdings) end def trades - @trades ||= account.entries.includes(entryable: :security).account_trades.to_a + @trades ||= account.entries.includes(entryable: :security).account_trades.chronological.to_a end def portfolio_start_date diff --git a/app/models/family.rb b/app/models/family.rb index bae32843561..69ac5eb7ca4 100644 --- a/app/models/family.rb +++ b/app/models/family.rb @@ -1,7 +1,7 @@ class Family < ApplicationRecord include Plaidable, Syncable - DATE_FORMATS = [ "%m-%d-%Y", "%d-%m-%Y", "%Y-%m-%d", "%d/%m/%Y", "%Y/%m/%d", "%m/%d/%Y", "%e/%m/%Y", "%Y.%m.%d" ] + DATE_FORMATS = [ "%m-%d-%Y", "%d.%m.%Y", "%d-%m-%Y", "%Y-%m-%d", "%d/%m/%Y", "%Y/%m/%d", "%m/%d/%Y", "%e/%m/%Y", "%Y.%m.%d" ] include Providable