foodcoops/foodsoft — pull request #222 by wvengen (2013-12-18 21:33:40+00:00)
Title: New receive screen

When the received amounts differ from those ordered, redistribution of changed quantities over members is manual. This pull request adds a "receive" screen in the orders section, where amounts received can be entered, after which products are redistributed over members using the existing algorithm.

Includes the addition of a `units_received` field in `OrderArticle`. An additional `units_billed` field is created as well although it has no user-interface yet (but this is very much similar to this screen).

Where `OrderArticle#units_to_order` was used, you'll probably want to use `OrderArticle#units`, which takes the last entered amount (ordered, billed, received - in that order). Where the amount of units of closed orders is shown, there now is a title attribute showing the history (e.g: "2 ordered, 1 billed, 1 received").

A new convention is introduced: whenever a number is the amount of wholesale units (full boxes, unit_quantities, lot, whatever), a watermark image of a box is shown next to it. I hope this brings clarity to whether numbers are member units or wholesale units.

- [ ] Get feedback on the concept
- [ ] Finish i18n
- [ ] Integration test for ordering and changing received units