Implemented the models and tables for userpermissions