adds active record extension for media, tests, updates views