sort products by id, refactor and add constants
fix  deprecation warning
add more utility functions
small tweaks + adding a type flag to transactions
change stock fields to decimals
Merge pull request #141 from dimagi/stock-models

tweaks and fixes for tests