dimagi/phonelog — pull request #4 by kennknowles (2013-02-04 21:20:55+00:00)
Title: Incorporate new user_subreport into device log report filters

High-level ChangeLog:

1. In CouchDB views `phonelog/devicelog_data_users` and `phonelog/device_log_users`, emit all the users from the `` if available, in addition to all users according to previous behavior. These are used to populate very selection boxes, etc.
2. In CouchDB view `phonelog/devicelog_data`, include the new users as `device_users` on each entry.
3. In the Python report, no longer filter by users at all, but append all affiliated device ids as determined by `phonelog/device_log_users` (this includes the prior behavior, since `phonelog/devicelog_data` determines the logged in user the same way)

Notes:

- I believe the CouchDB view `phonelog/devicelog_data` no longer needs to emit any documents with usernames in it, which should reduce the volume a bit.
- In `phonelog.reports.DeviceLogDetailsReports`, it may be that we want the intersection of `selected_devices` and `devices_for_users` rather than the union.