Skip to content

Commit

Permalink
Add app for environmental justice
Browse files Browse the repository at this point in the history
  • Loading branch information
code-geek committed Feb 2, 2024
1 parent 099fc39 commit 1c49ef3
Show file tree
Hide file tree
Showing 8 changed files with 110 additions and 0 deletions.
Empty file.
3 changes: 3 additions & 0 deletions environmental_justice/admin.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
from django.contrib import admin # noqa

# Register your models here.
6 changes: 6 additions & 0 deletions environmental_justice/apps.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
from django.apps import AppConfig


class EnvironmentalJusticeConfig(AppConfig):
default_auto_field = "django.db.models.BigAutoField"
name = "environmental_justice"
62 changes: 62 additions & 0 deletions environmental_justice/migrations/0001_initial.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
# Generated by Django 5.0.1 on 2024-02-02 16:40

from django.db import migrations, models


class Migration(migrations.Migration):

initial = True

dependencies = []

operations = [
migrations.CreateModel(
name="EnvironmentalJusticeRow",
fields=[
(
"id",
models.BigAutoField(
auto_created=True,
primary_key=True,
serialize=False,
verbose_name="ID",
),
),
("dataset", models.CharField(verbose_name="Dataset")),
("description", models.CharField(verbose_name="Description")),
(
"description_simplified",
models.CharField(verbose_name="Description Simplified"),
),
("indicators", models.CharField(verbose_name="Indicators")),
("intended_use", models.CharField(verbose_name="Intended Use")),
("latency", models.CharField(verbose_name="Latency")),
("limitations", models.CharField(verbose_name="Limitations")),
("project", models.CharField(verbose_name="Project")),
("source_link", models.CharField(verbose_name="Source Link")),
("strengths", models.CharField(verbose_name="Strengths")),
("format", models.CharField(verbose_name="Format")),
(
"geographic_coverage",
models.CharField(verbose_name="Geographic Coverage"),
),
(
"data_visualization",
models.CharField(verbose_name="Data Visualization"),
),
(
"spatial_resolution",
models.CharField(verbose_name="Spatial Resolution"),
),
("temporal_extent", models.CharField(verbose_name="Temporal Extent")),
(
"temporal_resolution",
models.CharField(verbose_name="Temporal Resolution"),
),
],
options={
"verbose_name": "Environmental Justice Row",
"verbose_name_plural": "Environmental Justice Rows",
},
),
]
Empty file.
33 changes: 33 additions & 0 deletions environmental_justice/models.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
from django.db import models


class EnvironmentalJusticeRow(models.Model):
"""
Environmental Justice data from the spreadsheet
"""

dataset = models.CharField("Dataset")
description = models.CharField("Description")
description_simplified = models.CharField("Description Simplified")
indicators = models.CharField("Indicators")
intended_use = models.CharField("Intended Use")
latency = models.CharField("Latency")
limitations = models.CharField("Limitations")
project = models.CharField("Project")
source_link = models.CharField("Source Link")
strengths = models.CharField("Strengths")

# fields that needs cleaning
format = models.CharField("Format")
geographic_coverage = models.CharField("Geographic Coverage")
data_visualization = models.CharField("Data Visualization")
spatial_resolution = models.CharField("Spatial Resolution")
temporal_extent = models.CharField("Temporal Extent")
temporal_resolution = models.CharField("Temporal Resolution")

class Meta:
verbose_name = "Environmental Justice Row"
verbose_name_plural = "Environmental Justice Rows"

def __str__(self):
return self.name
3 changes: 3 additions & 0 deletions environmental_justice/tests.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
from django.test import TestCase # noqa

# Create your tests here.
3 changes: 3 additions & 0 deletions environmental_justice/views.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
from django.shortcuts import render # noqa

# Create your views here.

0 comments on commit 1c49ef3

Please sign in to comment.