sdispater / orator

The Orator ORM provides a simple yet beautiful ActiveRecord implementation.
https://orator-orm.com
MIT License
1.43k stars 174 forks source link

Project structure for bigger projects #173

Open paladini opened 7 years ago

paladini commented 7 years ago

Orator documentation teaches about structuring some models using a single .py file, but there's no examples or instructions for who have creating bigger projects, where you cannot put all of your models inside a single .py file. I know that's not Orator fault, since users should be able to make their own project structure / architecture. Anyway, it can help a lot of people that is going to use orator within their projects.

There's some way to document or give some examples about bigger projects just like the folder tree below?

db/
  - migrations/
  - models/
       - __init__.py
       - user.py
       - post.py
  - orator.yml
  - __init__.py
lib/
  - module1/
      - a_file_that_uses_User_model.py
      - a_file_that_uses_all_defined_models.py
   - module2/
       - ...

Thank you!

aelawson commented 7 years ago

Seconding. This would be very helpful.