Skip to content

Commit

Permalink
Community name is freed, WIP #210
Browse files Browse the repository at this point in the history
  • Loading branch information
bryan-brancotte committed Feb 18, 2022
1 parent a2301db commit 1129505
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 20 deletions.
18 changes: 18 additions & 0 deletions ifbcat_api/migrations/0179_alter_community_name.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Generated by Django 3.2.5 on 2022-02-18 17:01

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('ifbcat_api', '0178_auto_20220218_1648'),
]

operations = [
migrations.AlterField(
model_name='community',
name='name',
field=models.CharField(help_text="Name of the community, e.g. 'Galaxy'.", max_length=255, unique=True),
),
]
21 changes: 1 addition & 20 deletions ifbcat_api/model/community.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,27 +10,8 @@
class Community(models.Model):
"""Community model: A group of people collaborating on a common scientific or technical topic, including formal ELIXIR Communities, emerging ELIXIR communities, ELXIR focus groups, IFB communities, and others."""

# EventType: Controlled vocabulary of types of events.
class CommunityName(models.TextChoices):
"""Controlled vocabulary of names of communities."""

# NB: Note "BIOINFO not 3D-BIOINFO" because of Python variable name restrictions.
BIOINFO = '3D-BioInfo', _('3D-BioInfo')
GALAXY = 'Galaxy', _('Galaxy')
INTRINSICALLY_DISORDERED_PROTEINS = 'Intrinsically Disordered Proteins', _('Intrinsically Disordered Proteins')
MARINE_METAGENOMICS = 'Marine Metagenomics', _('Marine Metagenomics')
METABOLOMICS = 'Metabolomics', _('Metabolomics')
MICROBIAL_BIOTECHNOLOGY = 'Microbial Biotechnology', _('Microbial Biotechnology')
PLANT_SCIENCES = 'Plant Sciences', _('Plant Sciences')
PROTEOMICS = 'Proteomics', _('Proteomics')
FEDERATED_HUMAN_DATA = 'Federated Human Data', _('Federated Human Data')
HUMAN_COPY_NUMBER_VARIATION = 'Human Copy Number Variation', _('Human Copy Number Variation')
RARE_DISEASES = 'Rare Diseases', _('Rare Diseases')

# name, description & homepage are mandatory
name = models.CharField(
max_length=255, choices=CommunityName.choices, unique=True, help_text="Name of the community, e.g. 'Galaxy'."
)
name = models.CharField(max_length=255, unique=True, help_text="Name of the community, e.g. 'Galaxy'.")

description = models.TextField(help_text="Short description of the community.")
homepage = models.URLField(max_length=255, help_text="Homepage of the community.")
Expand Down

0 comments on commit 1129505

Please sign in to comment.