Fix issue #1085: Draft search ignores discounts.

Note: the actual error isn't _NOT_ showing discounts (the transactions
  are posted with the discounts applied), but rather double counting
  (and a test-case where the discount is 50%).
moving assembly stocking to sproc, adding recording of details for future reporting
Fixing the problems Erik found on review
Merge pull request #67 from einhverfr/assembly_stock_recording

ensuring that assembly stocking gets recorded
Merge pull request #12 from ledgersmb/master

Pull assembly stock recording
Merge pull request #69 from ehuelsmann/master

Fix #1085: Draft searches not showing discounts.
Merge remote-tracking branch 'upstream/master'
test