Skip to content

Commit

Permalink
Remove the no-longer-used "public" field on Policy.
Browse files Browse the repository at this point in the history
  • Loading branch information
CM Lubinski committed Feb 28, 2018
1 parent 15c9798 commit b716bbd
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 4 deletions.
3 changes: 1 addition & 2 deletions api/reqs/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,14 @@ class PolicyAdmin(EReqsVersionAdmin):
actions = None
list_display = ('workflow_phase', '__str__', 'issuance')
list_display_links = ('__str__',)
list_filter = ['public', 'workflow_phase']
list_filter = ['workflow_phase']
ordering = ['-issuance', '-pk']
search_fields = ['title', 'omb_policy_id']
fields = [
'title',
'omb_policy_id',
'issuance',
'sunset',
'public',
'workflow_phase',
]

Expand Down
19 changes: 19 additions & 0 deletions api/reqs/migrations/0015_remove_policy_public.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.11.5 on 2018-02-28 15:39
from __future__ import unicode_literals

from django.db import migrations


class Migration(migrations.Migration):

dependencies = [
('reqs', '0014_auto_20180131_2223'),
]

operations = [
migrations.RemoveField(
model_name='policy',
name='public',
),
]
3 changes: 1 addition & 2 deletions api/reqs/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,10 +120,9 @@ class Meta:
slug = models.SlugField(max_length=title.max_length)
issuance = models.DateField()
sunset = models.DateField(blank=True, null=True)
public = models.BooleanField(default=True)
workflow_phase = models.CharField(
max_length=32, choices=[(e.name, e.value) for e in WorkflowPhases],
default=WorkflowPhases.no_doc.name
default=WorkflowPhases.no_doc.name,
)

# Legacy data fields
Expand Down

0 comments on commit b716bbd

Please sign in to comment.