Extended the change in commit 779c8f5253aabe6cff88e36e9c2a410ffb30b92e to all uses of the $filter angularjs service.

There were still some places in which  the $filter service was being used in such a way that it actually checked for substring matching instead of id equality to find an object in a list. This meant that in some cases the wrong object was "found" and returned, as explained in the above commit.

This should fix some hard-to-trace errors.