salw/salw_admin/pssm_api/migrations/0001_initial.py

68 lines
3.0 KiB
Python
Raw Permalink Normal View History

2024-11-28 15:06:12 +00:00
# Generated by Django 4.2.16 on 2024-10-16 07:58
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
initial = True
dependencies = [
]
operations = [
migrations.CreateModel(
name='African_Countries',
fields=[
('country_id', models.IntegerField(primary_key=True, serialize=False, unique=True)),
('name', models.CharField(max_length=50)),
('iso', models.CharField(default='', max_length=5)),
],
),
migrations.CreateModel(
name='Images',
fields=[
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('title', models.CharField(max_length=200)),
('image', models.ImageField(upload_to='images/')),
('copyright', models.CharField(max_length=200)),
('description', models.TextField(blank=True)),
('uploaded_at', models.DateTimeField(auto_now_add=True)),
],
),
migrations.CreateModel(
name='Impact_Stories',
fields=[
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('title', models.CharField(max_length=200)),
('file', models.FileField(upload_to='impact_stories/')),
('uploaded_at', models.DateTimeField(auto_now_add=True)),
('description', models.TextField(blank=True)),
],
),
migrations.CreateModel(
name='PSSM_Resources',
fields=[
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('title', models.CharField(max_length=200)),
('file', models.FileField(upload_to='pssm_resources/')),
('uploaded_at', models.DateTimeField(auto_now_add=True)),
('description', models.TextField(blank=True)),
],
),
migrations.CreateModel(
name='PSSM_Countries',
fields=[
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('recsa', models.BooleanField(default=False)),
('ecowas', models.BooleanField(default=False)),
('trained_participants', models.IntegerField(help_text='Number of participants trained')),
('pssm_instractors', models.IntegerField(help_text='Number of PSSM instractors')),
('senior_pssm_instractors', models.IntegerField(help_text='Number of senior PSSM instractors')),
('modefied_at', models.DateTimeField(auto_now_add=True)),
('country', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='pssm_api.african_countries')),
],
),
]