Database Migrations & Running the Project

This section provides steps to set up database migrations and run the project locally.

Database Migrations

To set up the database, follow these steps:

  1. Generate migration files:

    python manage.py makemigrations
    

  1. Apply migrations:

    python manage.py migrate
    

After successfully migration there is a file created name rdmc.db.sqlite3.

Load Demo Data (Optional)

To populate the database with sample data, use the following command:

python manage.py loaddata rdmc/fixtures/data.json

Note

Before loading the demo data, make sure to run the makemigrations and migrate commands. These steps ensure that your database schema is up-to-date and that the demo data is correctly loaded. Skipping migrations may lead to schema errors or prevent the data from being loaded correctly.

Run the Project

Once the database is set up, start the server using:

python manage.py runserver

Now, open the project in your browser: