fix: ui: transaction: possibly off-by-one valuation date
I'm not sure if it arose in practice, but: ensure TransactionScreen in V mode would correctly use the journal's last day as valuation date, not the day after that.
This commit is contained in:
		
							parent
							
								
									5d2caf3c7f
								
							
						
					
					
						commit
						a681e5329d
					
				| @ -636,8 +636,8 @@ reportPeriodOrJournalLastDay :: ReportSpec -> Journal -> Maybe Day | ||||
| reportPeriodOrJournalLastDay rspec j = reportPeriodLastDay rspec <|> journalOrPriceEnd | ||||
|   where | ||||
|     journalOrPriceEnd = case value_ $ rsOpts rspec of | ||||
|         Just (AtEnd _) -> max (journalEndDate False j) lastPriceDirective | ||||
|         _              -> journalEndDate False j | ||||
|         Just (AtEnd _) -> max (journalLastDay False j) lastPriceDirective | ||||
|         _              -> journalLastDay False j | ||||
|     lastPriceDirective = fmap (addDays 1) . maximumMay . map pddate $ jpricedirectives j | ||||
| 
 | ||||
| -- | Make a name for the given period in a multiperiod report, given | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user