Completed refactoring most of the javascript functions in brands.js, and backend color conversion.