Skip to content

Commit

Permalink
Added Consitutional Court to Bill Status
Browse files Browse the repository at this point in the history
  • Loading branch information
desafinadude committed Dec 5, 2024
1 parent 5fbeb24 commit fd000a2
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 4 deletions.
1 change: 1 addition & 0 deletions pmg/admin/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1152,6 +1152,7 @@ def __init__(self, *args, **kwargs):
("bill-signed", "Bill signed"),
("bill-enacted", "Bill enacted"),
("bill-act-commenced", "Act commenced"),
("bill-concourt", "Before Constitutional Court")
]

def populate_obj(self, obj, name):
Expand Down
22 changes: 18 additions & 4 deletions pmg/bills.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
"house": "house.png",
"president": "signed-by-president.png",
"unknown": "bill-introduced.png",
"concourt": "bill-concourt.png",
}


Expand All @@ -25,6 +26,12 @@ def get_location(event):
"class": "president",
}

if event.get("type") == "bill-concourt":
return {
"name": "Constitutional Court",
"class": "concourt",
}

if event.get("house"):
return {
"name": event["house"]["name"],
Expand Down Expand Up @@ -78,10 +85,17 @@ def get_agent(event, bill):
}

elif event.get("house"):
info = {
"name": event["house"]["name"],
"type": "house",
}

if event["house"]["short_name"] == "concourt":
info = {
"name": "Constitutional Court",
"type": "concourt",
}
else:
info = {
"name": event["house"]["name"],
"type": "house",
}
else:
info = {"name": "Unknown", "type": "unknown"}

Expand Down
3 changes: 3 additions & 0 deletions pmg/models/resources.py
Original file line number Diff line number Diff line change
Expand Up @@ -594,6 +594,9 @@ class BillCommenced(Event):
class BillUpdate(Event):
__mapper_args__ = {"polymorphic_identity": "bill-updated"}

class BillConcourt(Event):
__mapper_args__ = {"polymorphic_identity": "bill-concourt"}


class MembershipType(db.Model):

Expand Down
12 changes: 12 additions & 0 deletions pmg/static/resources/css/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -852,6 +852,18 @@ mark {
}
}

.bill-location.concourt {
border-color: #fcec56;

.panel-heading {
border-color: #fcec56;
background-color: #fcec56;
}
}




.media-body {
li {
display: table;
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit fd000a2

Please sign in to comment.