memopol merge requestshttps://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests2016-10-03T17:37:44+02:00https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/121Update README.md2016-10-03T17:37:44+02:00okhinokhin@laquadrature.netUpdate README.md*Created by: Ash-Crow*
Fix issue #120 (replace outdated installation instructions with a link to the manual)*Created by: Ash-Crow*
Fix issue #120 (replace outdated installation instructions with a link to the manual)https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/119Quickstart update2016-10-03T17:37:41+02:00okhinokhin@laquadrature.netQuickstart update*Created by: jpic*
- don't exit on failure because documentation recommends to source this script
- print executed commands
- clarify the state of the script
@njoyard does that work for you ?*Created by: jpic*
- don't exit on failure because documentation recommends to source this script
- print executed commands
- clarify the state of the script
@njoyard does that work for you ?https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/117Fix API inconsistencies2016-10-03T17:37:38+02:00njoyardFix API inconsistencies*Created by: njoyard*
Include API fixes from d-r-v and d-r*Created by: njoyard*
Include API fixes from d-r-v and d-rhttps://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/110Add sorting to rep list and dossier list2016-10-03T17:37:36+02:00njoyardAdd sorting to rep list and dossier list*Created by: njoyard*
*Created by: njoyard*
https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/109Add chamber links and refactor contact block a bit2016-07-19T09:08:23+02:00njoyardAdd chamber links and refactor contact block a bit*Created by: njoyard*
*Created by: njoyard*
https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/106Rework icons2016-07-19T08:45:56+02:00njoyardRework icons*Created by: njoyard*
Removed css classes for specific chamber/group icons, now we only need to drop new icon files with the correct name in memopol/static/images.
Added icons for french pol groups in AN/SEN.*Created by: njoyard*
Removed css classes for specific chamber/group icons, now we only need to drop new icon files with the correct name in memopol/static/images.
Added icons for french pol groups in AN/SEN.https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/105Update dependencies2016-10-03T17:37:28+02:00njoyardUpdate dependencies*Created by: njoyard*
Update to d-r/d-r-v with suppressed remote_id and modified slugs (now unique and include birthdate).
Note: this patch will break representatives URLs.*Created by: njoyard*
Update to d-r/d-r-v with suppressed remote_id and modified slugs (now unique and include birthdate).
Note: this patch will break representatives URLs.https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/104Add dossier documents2016-10-03T17:37:26+02:00njoyardAdd dossier documents*Created by: njoyard*
This PR uses the new Documents model added to django-representatives-votes. This allows:
- searching dossiers by chamber
- showing which chambers will/have read a dossier in the dossier list
- showing a list of ...*Created by: njoyard*
This PR uses the new Documents model added to django-representatives-votes. This allows:
- searching dossiers by chamber
- showing which chambers will/have read a dossier in the dossier list
- showing a list of documents in the dossier details pagehttps://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/102Fix underflow #1012016-10-03T17:37:23+02:00njoyardFix underflow #101*Created by: njoyard*
*Created by: njoyard*
https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/99Small update to dossier list/details2016-07-05T22:33:08+02:00njoyardSmall update to dossier list/details*Created by: njoyard*
*Created by: njoyard*
https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/97Add search to dossiers2016-10-03T17:37:18+02:00njoyardAdd search to dossiers*Created by: njoyard*
Add a search form to dossiers, enables searching by title or reference.*Created by: njoyard*
Add a search form to dossiers, enables searching by title or reference.https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/96Configurable scores with exponential decay2016-10-03T17:37:15+02:00njoyardConfigurable scores with exponential decay*Created by: njoyard*
This PR implements exponential decay as shown in #63.
It also introduces a new Setting model to store administration preferences. For now they only contain score decay parameters ; default value are chosen so th...*Created by: njoyard*
This PR implements exponential decay as shown in #63.
It also introduces a new Setting model to store administration preferences. For now they only contain score decay parameters ; default value are chosen so that score calculation stays the same as what we currently have.
There are no tests in the memopol_settings app because there is no business logic, only a model and an admin view. It is a separate app because it will most likely be used by the memopol app in the future (it has no reason to be in representatives_recommendations, but it can't be in memopol because then there would be a circular dependency between representatives_recommendations and memopol).https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/95Switch to pgsql-only2016-10-03T17:37:13+02:00njoyardSwitch to pgsql-only*Created by: njoyard*
This PR switches the project to PostgreSQL only. This is necessary for future updates.
Some views and tests have been fixed to not rely on default database ordering (hence the fixture changes).*Created by: njoyard*
This PR switches the project to PostgreSQL only. This is necessary for future updates.
Some views and tests have been fixed to not rely on default database ordering (hence the fixture changes).https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/92Add filters for representatives2016-10-03T17:37:10+02:00njoyardAdd filters for representatives*Created by: njoyard*
This PR adds a filter form that uses django-filters on the representative list with the following criteria:
* *search*: identical to the previously existing search box, searches representatives by name
* *chamber...*Created by: njoyard*
This PR adds a filter form that uses django-filters on the representative list with the following criteria:
* *search*: identical to the previously existing search box, searches representatives by name
* *chamber*: static drop down list to filter by chamber
* *country*: static drop down list to filter by country
* *group*: autocompleted drop down to filter by all kinds of groups (except chamber and country) : party, committee, delegation, ...
The group URLs (like `/legislature/representatives/committee/European Parliament/Committee on Defense whatever`) are now 301-redirected to an URL with querystring parameters in order to pre-fill the filter form.
TODO:
* [x] fix select2 style to match the rest of the form
* [x] ensure the filter form always submits to the root representative list url instead of the current page url (not really needed but just in case)
* [x] ~~add a checkbox to choose active/inactive meps~~ *postponed until we have an easy way to turn options/selects into a nice bootstrap button group*
* [x] add something more obvious when there are no results
* [x] ~~add a media block to the root template to allow page templates to add to it~~ *not needed, we have a head block already*
* [x] ~~change the way groups are displayed in the ac (add abbreviation, make group type more obvious)~~ *doesn't seem possible currently with select2*
* [x] add filter tests
* [x] check duplicate meps issue again
* [x] fix missing querystring in page links
Preview:
![preview](https://framapic.org/gierm9d1M2ym/dqpVBqKOA2Ud.png)https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/91Fix deps2016-06-14T12:03:38+02:00njoyardFix deps*Created by: njoyard*
* Update to django-representatives and django-representatives-votes with controlled dependencies versions
* Update to responsediff 0.6, with updated fixtures
* Fix some version numbers (no need to depend on stric...*Created by: njoyard*
* Update to django-representatives and django-representatives-votes with controlled dependencies versions
* Update to responsediff 0.6, with updated fixtures
* Fix some version numbers (no need to depend on strict minor revisions)
https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/90Add country flags (and import template tags)2016-10-03T17:37:03+02:00njoyardAdd country flags (and import template tags)*Created by: njoyard*
This PR adds country flags to the Countries page.
It also imports template tags from django-representatives[-votes] so that they can be removed from there later.*Created by: njoyard*
This PR adds country flags to the Countries page.
It also imports template tags from django-representatives[-votes] so that they can be removed from there later.https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/88Allow former meps2016-10-03T17:36:58+02:00njoyardAllow former meps*Created by: njoyard*
This PR enables importing and using inactive MEPs in memopol. Inactive MEPs are shown in grayscale and listing pages have an toggle between showing active MEPs only (default) or all MEPs.
![example](https://fram...*Created by: njoyard*
This PR enables importing and using inactive MEPs in memopol. Inactive MEPs are shown in grayscale and listing pages have an toggle between showing active MEPs only (default) or all MEPs.
![example](https://framapic.org/3rQyc0QeDLXc/WVbq1FMNColc.png)
It also enables pagination on group lists, as well as active vs all filtering.https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/87Remove versioned database and add quickstart script instead2016-10-03T17:36:55+02:00njoyardRemove versioned database and add quickstart script instead*Created by: njoyard*
Everything is in the title :)*Created by: njoyard*
Everything is in the title :)https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/86Move from LESS to SCSS2016-10-03T17:36:53+02:00njoyardMove from LESS to SCSS*Created by: njoyard*
`lesscpy` is not fully LESS-compliant. Instead `django-libsass` relies on `libsass`, which is a fully compliant C/C++ implementation of SASS/SCSS.
The reason for that change: I came across a lesscpy bug while ad...*Created by: njoyard*
`lesscpy` is not fully LESS-compliant. Instead `django-libsass` relies on `libsass`, which is a fully compliant C/C++ implementation of SASS/SCSS.
The reason for that change: I came across a lesscpy bug while adding new style to inactive meps, tried to fix it in lesscpy but seeing how poorly written it was made me change my mind - there is no other less implementation that does not require nodejs (actually there is one, but it is even less compliant).https://git.laquadrature.net/la-quadrature-du-net/memopol/memopol/-/merge_requests/85Integrate views removed from d-r[-v]2016-10-03T17:36:51+02:00njoyardIntegrate views removed from d-r[-v]*Created by: njoyard*
A quick summary of the changes made:
- Gave names to API views because their default names conflicted with other view names
- Added tags to make group/chamber/country URLs (1)
- Moved views each to its own file ...*Created by: njoyard*
A quick summary of the changes made:
- Gave names to API views because their default names conflicted with other view names
- Added tags to make group/chamber/country URLs (1)
- Moved views each to its own file and integrated views removed from d-r[-v]
- Integrated URLs removed from d-r[-v]
- Made URLs more homogenous ~~(allow singular & plural ; all URLs default to singular)~~ : moved /groups/ to /group/ and added 301 redirect from old to new
(1) I prefer using tags instead of using get_absolute_url. As models are defined in a dependency, they cannot "know" what the user application wants to use as the "canonical model url" (for example for groups it may be rep list filtered by this group, or a detail page for the group, or whatever). I could have made inherited models in memopol just to override get_absolute_url, but then making sure foreign keys use overriden models is not made easy AT ALL by django. It's possible, but the code is horrible.