Fixes #261 - parameters now use a single reference_id
This implementation uses STI but the table looks the same for allvariants. This is a little strange but it seems to work.
Also removed obsolete controllers and testsAdded more tests