GNOME Bugzilla – Bug 432457
Security/stock import should follow tutorial regarding Account Name
Last modified: 2018-06-29 21:33:41 UTC
Create a new file Add Investments to the Common accounts in the wizard Click through to the Accounts window Choose File/Import/Import OFX/QFX... Select the file newstock.ofx Click Import Select security/currency dialog appears Click New Click OK in New security dialog Click OK in Select security/currency dialog In Select Account dialog, navigate to Assets:Investments:Brokerage Account, and click OK Select Account dialog appears again to pick an account for Red Hat stock Navigate to Assets:Investments:Brokerage Account:Stock Click New Account At this point, the New Account dialog shows up with 'Stock account for security "RED HAT INC COM"' in the Account Name slot. (Current.png) There is also nothing in the Description slot. There is only one string being bandied about in the code, and that's for the Select Account dialog header. I contend that absolutely no one is going to start all their stock account names with the phrase "Stock account for security..." However, other information is readily available in the now defined security. The help files suggest that the user assign the stock ticker symbol as the account name. There isn't any strong guidance in the tutorial about what the description should be, but I think a good default is the full name of the security. The attached patch (stockimport.patch) accomplishes my request (fixed.png), as long as one navigates to the right Stock parent account before Clicking New Account. If you just click New Account as soon as the second Select Account dialog appears (oops.png), gnucash doesn't remember the commodity, nor even the fact that it is a stock instead of a bank account. But it still puts in my proposed contents for the Account Name and Description. Obviously, I didn't insert my changes at the right spot for a general case. But I can't figure out where it should go.
Created attachment 86815 [details] sample ofx file
Created attachment 86816 [details] [review] patch to change New Account dialog entries
Created attachment 86817 [details] New Account dialog as it comes up now
Created attachment 86818 [details] New account dialog as proposed
Created attachment 86819 [details] New Account dialog with new code but without guidance on parent
Committed to trunk, r17657, awaiting back-port. Thanks a lot!
GnuCash bug tracking has moved to a new Bugzilla host. This bug has been copied to https://bugs.gnucash.org/show_bug.cgi?id=432457. Please update any external references or bookmarks.