* Test WIP
* WIP
* port getComponents to Eloquent
* port more
* simpler creation
* change to explicit arrays
* add missed file
* restore commented code
* fix inserting null value for component prefs
* Fix some bugs in setCompenentPrefs
Can't create tests without fixing bugs first :D
* another test
* another test
* Modernize setComponentPrefs
* Test for event log entries
* Fix delete event
* fix invalid values for component toggles
* status log too
* Use Setters to work around bad data, $casts doesn't do what we want.
* Device Cache
also some additional device related models
* attribs from cache
* replace common attribute functions
* remove legacy cache usage
tidy up some collection manipulation
remove some unused or single use functions
* cleanup some items
* always return a device, to prevent bugs
* clear device cache when testing after each test
* fix double assignment
* Clean up function to take advantage of null object