Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo
It'd be useful to be able to define some rules to automatically select accounts for imported transactions.
This way you don't have to select accounts for imported instances of recurring payments/income.
As an initial implementation, we could just match the 'memo' field with a regex. I'd be willing to give this a shot. Right now I think it should look something like this:
Data model: add an 'ImportPattern' StoredObject with the pattern/regex, the Account those lines should be linked to, and an index (because this should be an ordered list).
Logic: The logic could be called in ImportTwo#getSettings(). Instead of just attaching the 'default' account, first walk though the ImportPattern to see if any of those match.
UI: A 'Patterns...' button could be added to the 'Modify Transactions', the second tab of the 'import' wizard. It would open a popup in which ImportPatterns can be modified, reordered, deleted and added. It could have 'close' and 'apply' buttons: the former would just close the window, the latter would execute the automatic linkage logic again.
Does this sound like a reasonable approach?
Preliminary patch: defining an applying works, but the UI needs work, patterns are not yet saved to the database and not applied initially