datamade / django-councilmatic

:heartpulse: Django app providing core functions for *.councilmatic.org
http://councilmatic.org
MIT License
26 stars 16 forks source link

Modify how we use urlencode as a filter to account for double encoding with PIC #136

Open reginafcompton opened 7 years ago

reginafcompton commented 7 years ago

Two things

Look at the filter here: https://github.com/datamade/django-councilmatic/blob/master/councilmatic_core/templates/councilmatic_core/legislation.html#L372

Add an explanatory note here: https://github.com/datamade/django-councilmatic/blob/master/councilmatic_core/models.py#L336

-OR-

We might think about how to standard full_text_doc_url for all Councilmatics, rather than expecting the city-specific Councilmatic to customize this. @fgregg, thoughts?

fgregg commented 7 years ago

seems like a standard full_text_doc_url would be the way to go, particularly since the PIC url should be moved to settings variable

reginafcompton commented 7 years ago

It looks like this model property varies among the Councilmatics (e.g., Chicago renders a PDF, but NYC does not). It seems like it would be best to allow for this type of flexibility and, instead, make the updates to Chicago and LA Metro, which need the double URL encoding.

https://github.com/datamade/django-councilmatic/blob/master/councilmatic_core/models.py#L336