Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added Consitutional Court to Bill Status #582

Merged
merged 1 commit into from
Dec 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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.
Loading