web: avoid spaces before commas in register account links

This commit is contained in:
Henning Thielemann 2019-06-08 10:22:51 +02:00 committed by Simon Michael
parent ac96bcfdf0
commit adbdbf002c
2 changed files with 4 additions and 5 deletions

View File

@ -34,8 +34,8 @@ getRegisterR = do
acctQuery = fromMaybe Any (inAccountQuery qopts)
acctlink acc = (RegisterR, [("q", accountQuery acc)])
otherTransAccounts =
zip ("" : repeat (","::T.Text)) .
preferReal . otherTransactionAccounts m acctQuery
addCommas . preferReal . otherTransactionAccounts m acctQuery
addCommas xs = zip xs $ tail $ (","<$xs) ++ [T.empty]
r@(balancelabel,items) = accountTransactionsReport ropts j m acctQuery
balancelabel' = if isJust (inAccount qopts) then balancelabel else "Total"
defaultLayout $ do

View File

@ -26,10 +26,9 @@
<td>
#{textElideRight 30 (tdescription tacct)}
<td .account>
$forall (comma, Posting { paccount = acc }) <- otherTransAccounts torig
#{comma}
$forall (Posting { paccount = acc }, comma) <- otherTransAccounts torig
<a href="@?{acctlink acc}##{tindex torig}" title="#{acc}">
#{accountSummarisedName acc}
#{accountSummarisedName acc}</a>#{comma}
<td .amount style="text-align:right; white-space:nowrap;">
$if not split || not (isZeroMixedAmount amt)
^{mixedAmountAsHtml amt}