Refactor how add and remove criteria works

Remove criteria sends the index as a value, rather
than being encoded in the name.

Combine add and remove criteria into one method
that's called from the create/update method.