Updated model

- Added indexes
- Added repositories