-
Notifications
You must be signed in to change notification settings - Fork 617
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PortfolioListView: Add column with balance of reference account #4388
PortfolioListView: Add column with balance of reference account #4388
Conversation
Thus, portfolio list view will now have complete information: securities account and its MTM balance, and reference account with its cash balance.
#4325 (comment) describes a usecase. The patch has a non-externalized string. |
@@ -256,6 +258,23 @@ public String getText(Object element) | |||
})); | |||
portfolioColumns.addColumn(column); | |||
|
|||
column = new Column("ref_cash_bal", "Balance of reference account", SWT.RIGHT, 100); //$NON-NLS-1$ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing translations
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if we should re-use the label from the account view: ColumnBalance
It works nicely in German: Depotvolumen vs. Kontostand
But maybe not so well in other languages.
column = new Column("ref_cash_bal", "Balance of reference account", SWT.RIGHT, 100); //$NON-NLS-1$ | ||
column.setLabelProvider(new ColumnLabelProvider() | ||
{ | ||
CurrencyConverter converter = new CurrencyConverterImpl(factory, getClient().getBaseCurrency()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The converter is not used. The balance will be shown in the account currency. Is this intended?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The converter is not used. The balance will be shown in the account currency. Is this intended?
Yeah, it's clearly was a copy-paste issue, where label provider was initially copied from security balance column, but the getText() then was copied from AccountListView, leaving converter unused.
Thanks for taking care of the patch!
Thus, portfolio list view will now have complete information: securities account and its MTM balance, and reference account with its cash balance. Issue: #4388 Signed-off-by: Paul Sokolovsky <[email protected]> [added translations for new label; rebased to master] Signed-off-by: Andreas Buchen <[email protected]>
I added the translations and merged the change. |
Thus, portfolio list view will now have complete information: securities account and its MTM balance, and reference account with its cash balance.