BUG: Fix ManyManyList->removeAll() when filters are applied to the query

In order to be cross-database compatible and support filters, the IDs to
delete must be retrieved in a sub-query.
Merge pull request #1247 from ajshort/mml-remove-filtered

BUG: Fix ManyManyList->removeAll() when filters are applied to the query