bs/is: fix "Ratio has zero denominator" error (take 2) (#535)
This commit is contained in:
		
							parent
							
								
									c8e4bc0098
								
							
						
					
					
						commit
						118bc85726
					
				| @ -531,8 +531,8 @@ balanceReportAsTable opts (MultiBalanceReport (colspans, items, (coltotals,tot,a | ||||
|     addtotalrow | no_total_ opts = id | ||||
|                 | otherwise      = (+----+ (row "" $ | ||||
|                                     coltotals | ||||
|                                     ++ (if row_total_ opts then [tot] else []) | ||||
|                                     ++ (if average_ opts   then [avg] else []) | ||||
|                                     ++ (if row_total_ opts && not (null coltotals) then [tot] else []) | ||||
|                                     ++ (if average_ opts && not (null coltotals)   then [avg] else []) | ||||
|                                     )) | ||||
| 
 | ||||
| -- | Figure out the overall date span of a multicolumn balance report. | ||||
|  | ||||
| @ -148,8 +148,8 @@ balanceviewReport BalanceView{..} CliOpts{command_=cmd, reportopts_=ropts, rawop | ||||
|                   mergedTabl | ||||
|                   +====+ | ||||
|                   row "Total" | ||||
|                       (sumAmts ++ (if row_total_ ropts' then [totsum] else []) | ||||
|                                ++ (if average_ ropts'   then [totavg] else []) | ||||
|                       (sumAmts ++ (if row_total_ ropts' && not (null sumAmts) then [totsum] else []) | ||||
|                                ++ (if average_ ropts' && not (null sumAmts)   then [totavg] else []) | ||||
|                       ) | ||||
|         putStrLn title | ||||
|         putStrLn $ renderBalanceReportTable ropts totTabl | ||||
|  | ||||
		Loading…
	
		Reference in New Issue
	
	Block a user