-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #117 from basedosdados/missing_empty_models
New models: `analysis`, `quality_check`
- Loading branch information
Showing
11 changed files
with
777 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
# -*- coding: utf-8 -*- | ||
# Generated by Django 4.2.1 on 2023-05-06 18:26 | ||
|
||
from django.db import migrations, models | ||
import django.db.models.deletion | ||
import uuid | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
("v1", "0007_alter_entitycategory_options_and_more"), | ||
] | ||
|
||
operations = [ | ||
migrations.CreateModel( | ||
name="Analysis", | ||
fields=[ | ||
( | ||
"id", | ||
models.UUIDField( | ||
default=uuid.uuid4, primary_key=True, serialize=False | ||
), | ||
), | ||
( | ||
"analysis_type", | ||
models.ForeignKey( | ||
on_delete=django.db.models.deletion.CASCADE, | ||
related_name="analyses", | ||
to="v1.analysistype", | ||
), | ||
), | ||
], | ||
options={ | ||
"verbose_name": "Analysis", | ||
"verbose_name_plural": "Analyses", | ||
"db_table": "analysis", | ||
"ordering": ["id"], | ||
}, | ||
), | ||
] |
30 changes: 30 additions & 0 deletions
30
...api/api/v1/migrations/0009_remove_analysistype_tag_remove_analysistype_tag_en_and_more.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# -*- coding: utf-8 -*- | ||
# Generated by Django 4.2.1 on 2023-05-06 18:38 | ||
|
||
from django.db import migrations | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
("v1", "0008_analysis"), | ||
] | ||
|
||
operations = [ | ||
migrations.RemoveField( | ||
model_name="analysistype", | ||
name="tag", | ||
), | ||
migrations.RemoveField( | ||
model_name="analysistype", | ||
name="tag_en", | ||
), | ||
migrations.RemoveField( | ||
model_name="analysistype", | ||
name="tag_es", | ||
), | ||
migrations.RemoveField( | ||
model_name="analysistype", | ||
name="tag_pt", | ||
), | ||
] |
61 changes: 61 additions & 0 deletions
61
...osdados_api/api/v1/migrations/0010_analysis_tags_analysis_themes_analysis_url_and_more.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
# -*- coding: utf-8 -*- | ||
# Generated by Django 4.2.1 on 2023-05-06 19:00 | ||
|
||
from django.db import migrations, models | ||
import django.db.models.deletion | ||
|
||
|
||
class Migration(migrations.Migration): | ||
|
||
dependencies = [ | ||
("v1", "0009_remove_analysistype_tag_remove_analysistype_tag_en_and_more"), | ||
] | ||
|
||
operations = [ | ||
migrations.AddField( | ||
model_name="analysis", | ||
name="tags", | ||
field=models.ManyToManyField( | ||
blank=True, | ||
help_text="Tags are used to group analyses by topic", | ||
related_name="analyses", | ||
to="v1.tag", | ||
), | ||
), | ||
migrations.AddField( | ||
model_name="analysis", | ||
name="themes", | ||
field=models.ManyToManyField( | ||
help_text="Themes are used to group analyses by topic", | ||
related_name="analyses", | ||
to="v1.theme", | ||
), | ||
), | ||
migrations.AddField( | ||
model_name="analysis", | ||
name="url", | ||
field=models.URLField(blank=True, max_length=255, null=True), | ||
), | ||
migrations.AddField( | ||
model_name="coverage", | ||
name="analysis", | ||
field=models.ForeignKey( | ||
blank=True, | ||
null=True, | ||
on_delete=django.db.models.deletion.CASCADE, | ||
related_name="coverages", | ||
to="v1.analysis", | ||
), | ||
), | ||
migrations.AddField( | ||
model_name="observationlevel", | ||
name="analysis", | ||
field=models.ForeignKey( | ||
blank=True, | ||
null=True, | ||
on_delete=django.db.models.deletion.CASCADE, | ||
related_name="observation_levels", | ||
to="v1.analysis", | ||
), | ||
), | ||
] |
Oops, something went wrong.