montanha:montanha.git
4 years agoChanging imports and variables from Camara to CamaraFederal camara
Estêvão Samuel Procópio Amaral [Wed, 18 Sep 2013 03:29:55 +0000 (00:29 -0300)]
Changing imports and variables from Camara to CamaraFederal

4 years agoEnlightening CamaraFederal collector comment
Estêvão Samuel Procópio Amaral [Wed, 18 Sep 2013 03:26:23 +0000 (00:26 -0300)]
Enlightening CamaraFederal collector comment

4 years agoRenaming CamaraFederal private functions
Estêvão Samuel Procópio Amaral [Wed, 18 Sep 2013 03:18:31 +0000 (00:18 -0300)]
Renaming CamaraFederal private functions

4 years agoMaking CamaraFederal a new-style class
Estêvão Samuel Procópio Amaral [Wed, 18 Sep 2013 03:13:39 +0000 (00:13 -0300)]
Making CamaraFederal a new-style class

This was needed in order to make paralel helper functions @staticmethods.

4 years agoRenaming files and classes from Camara to CamaraFederal
Estêvão Samuel Procópio Amaral [Wed, 18 Sep 2013 02:45:41 +0000 (23:45 -0300)]
Renaming files and classes from Camara to CamaraFederal

4 years agoCamara Federal collector now defines the amount of paralel processes using cpu_count
Estêvão Samuel Procópio Amaral [Wed, 18 Sep 2013 02:31:52 +0000 (23:31 -0300)]
Camara Federal collector now defines the amount of paralel processes using cpu_count

4 years agoFixing import order in Camara Federal collector
Estêvão Samuel Procópio Amaral [Wed, 18 Sep 2013 02:29:44 +0000 (23:29 -0300)]
Fixing import order in Camara Federal collector

4 years agoAdding initial implementation of Camara collector
Estêvão Samuel Procópio [Thu, 12 Sep 2013 19:44:57 +0000 (16:44 -0300)]
Adding initial implementation of Camara collector

4 years agoMaking possible to import * from basecollector
Estêvão Samuel Procópio [Wed, 11 Sep 2013 14:35:18 +0000 (11:35 -0300)]
Making possible to import * from basecollector

4 years agoAdding intitution to ExpenseNature model
Estêvão Samuel Procópio [Wed, 11 Sep 2013 13:30:41 +0000 (10:30 -0300)]
Adding intitution to ExpenseNature model

4 years agoAdding original_id to Legislature model
Estêvão Samuel Procópio [Wed, 4 Sep 2013 15:22:48 +0000 (12:22 -0300)]
Adding original_id to Legislature model

4 years agoUsing the minified version of flot
Marcelo Jorge Vieira [Sun, 11 Aug 2013 19:05:38 +0000 (16:05 -0300)]
Using the minified version of flot

4 years agoContact Us: Removed unnecessary space in success message
Marcelo Jorge Vieira [Sun, 11 Aug 2013 18:44:15 +0000 (15:44 -0300)]
Contact Us: Removed unnecessary space in success message

4 years agoCreated contact us page
Marcelo Jorge Vieira [Sat, 10 Aug 2013 05:36:23 +0000 (02:36 -0300)]
Created contact us page

4 years agoCreated 'what is expenses?' page
Marcelo Jorge Vieira [Sat, 10 Aug 2013 05:27:26 +0000 (02:27 -0300)]
Created 'what is expenses?' page

4 years agoHeader: Fixed order of </form>
Marcelo Jorge Vieira [Sat, 10 Aug 2013 05:12:14 +0000 (02:12 -0300)]
Header: Fixed order of </form>

4 years agoRenaming menu_items.html to submenu_items.html
Marcelo Jorge Vieira [Sat, 10 Aug 2013 05:07:34 +0000 (02:07 -0300)]
Renaming menu_items.html to submenu_items.html

4 years agoImprove pagination for all expenses
Gustavo Noronha Silva [Sat, 10 Aug 2013 06:16:39 +0000 (03:16 -0300)]
Improve pagination for all expenses

Separate the bootstrap span setup from the row, so it's properly aligned, and
add another pagination widget to the top.

4 years agoAdd a legend box to the per-nature graph
Gustavo Noronha Silva [Sat, 10 Aug 2013 06:04:12 +0000 (03:04 -0300)]
Add a legend box to the per-nature graph

This change also includes a bunch of fixes to make the UI make more sense
with the new tabbed layout.

4 years agoUpdating index page
Marcelo Jorge Vieira [Sat, 10 Aug 2013 05:01:51 +0000 (02:01 -0300)]
Updating index page

Added Lu Scuarcialupi's text

4 years agoRefactoring layout
Marcelo Jorge Vieira [Sat, 10 Aug 2013 04:33:49 +0000 (01:33 -0300)]
Refactoring layout

4 years agoUpdate bootstrap to 2.3.2
Marcelo Jorge Vieira [Sat, 10 Aug 2013 04:33:38 +0000 (01:33 -0300)]
Update bootstrap to 2.3.2

4 years agoMore basic information on the details page
Gustavo Noronha Silva [Wed, 7 Aug 2013 04:04:15 +0000 (01:04 -0300)]
More basic information on the details page

4 years agoFix JS syntax
Gustavo Noronha Silva [Wed, 7 Aug 2013 03:49:58 +0000 (00:49 -0300)]
Fix JS syntax

4 years agoAdded more interesting information in the supplier's detail page
Gustavo Noronha Silva [Wed, 7 Aug 2013 03:30:03 +0000 (00:30 -0300)]
Added more interesting information in the supplier's detail page

This change adds a per-party graph (code shared with the per-party view),
a table showing the top buyers for that supplier. This will be later
reorganized to be saner for viewing (see ticket #11).

4 years agoAdd supplier details view (fixes #5)
Gustavo Noronha Silva [Wed, 7 Aug 2013 02:51:19 +0000 (23:51 -0300)]
Add supplier details view (fixes #5)

4 years agoGenerate th tag attributes instead of the whole tab in our sortable template tag
Gustavo Noronha Silva [Wed, 7 Aug 2013 02:40:14 +0000 (23:40 -0300)]
Generate th tag attributes instead of the whole tab in our sortable template tag

4 years agoAdd support for sorting columns in all and per-supplier views
Gustavo Noronha Silva [Wed, 31 Jul 2013 03:09:26 +0000 (00:09 -0300)]
Add support for sorting columns in all and per-supplier views

Adds a new templatetag sortable_th, which is able to add a th pair of
tags with an ID and appropriate CSS class. The JS code supporting the
sorting is in a new file, and it uses the deserialize jQuery plugin,
which is also being added by this commit.

4 years agoFixed the per-party view to use the django ORM
Gustavo Noronha Silva [Wed, 31 Jul 2013 00:43:46 +0000 (21:43 -0300)]
Fixed the per-party view to use the django ORM

This change also correctly filters disabled institutions. Fixes ticket #7.

4 years agoAdd a color generator to create the array of colors
Pablo Aguiar [Mon, 29 Jul 2013 17:39:31 +0000 (14:39 -0300)]
Add a color generator to create the array of colors

4 years agoLegislator detail: Fixed menu selection
Marcelo Jorge Vieira [Tue, 30 Jul 2013 22:09:18 +0000 (19:09 -0300)]
Legislator detail: Fixed menu selection

4 years agoActually filter expenses by the legislator in the details view
Gustavo Noronha Silva [Tue, 30 Jul 2013 01:37:22 +0000 (22:37 -0300)]
Actually filter expenses by the legislator in the details view

4 years agoFix arguments for showing legislator details
Gustavo Noronha Silva [Tue, 30 Jul 2013 01:35:44 +0000 (22:35 -0300)]
Fix arguments for showing legislator details

4 years agoMajor rework of narrowing down the data that is showed
Gustavo Noronha Silva [Tue, 30 Jul 2013 01:12:54 +0000 (22:12 -0300)]
Major rework of narrowing down the data that is showed

Instead of allowing selection of a single legislative house, we now have
a dropdown in the top menu that allows excluding houses or legislatures.
Legislature is a new model/concept, that is like the 'class' for a mandate,
it is tied to the institution instead of being tied to the legislator.

This change also adapts the collectors to use this new structure.

4 years agoMake it easier to debug failing URIs
Gustavo Noronha Silva [Tue, 30 Jul 2013 01:12:25 +0000 (22:12 -0300)]
Make it easier to debug failing URIs

4 years agoFixed political party logo in the per legislator template
Marcelo Jorge Vieira [Mon, 29 Jul 2013 17:11:46 +0000 (14:11 -0300)]
Fixed political party logo in the per legislator template

Replaced 'political-party-mini' with 'mini'

4 years agoRenamed thumbnail alias to be more general
Gustavo Noronha Silva [Sun, 28 Jul 2013 17:58:36 +0000 (14:58 -0300)]
Renamed thumbnail alias to be more general

4 years agoAdd an icon to show which institution is currently being shown
Gustavo Noronha Silva [Sun, 28 Jul 2013 01:54:46 +0000 (22:54 -0300)]
Add an icon to show which institution is currently being shown

4 years agoAllow selecting the institution from the main page
Gustavo Noronha Silva [Sat, 27 Jul 2013 17:52:17 +0000 (14:52 -0300)]
Allow selecting the institution from the main page

4 years agoAdd CMBH collector and apply changes to make it possible
Gustavo Noronha Silva [Thu, 25 Jul 2013 15:49:09 +0000 (12:49 -0300)]
Add CMBH collector and apply changes to make it possible

Along with the new collector, this change makes a number of model fields
optional, given the data to fill them out is not available in the CMBH
web site. It also removes the hack to make the graph in the per nature
totals view be the same height as the table, since the table is now much
taller.

4 years agoRefactor collector code to have each object on their own file
Gustavo Noronha Silva [Thu, 25 Jul 2013 01:50:23 +0000 (22:50 -0300)]
Refactor collector code to have each object on their own file

4 years agoDefault to post-processing URI data as an HTML page
Gustavo Noronha Silva [Thu, 25 Jul 2013 01:29:03 +0000 (22:29 -0300)]
Default to post-processing URI data as an HTML page

Most sites are HTML pages that we scrape, so make the collector's
base post-process the contents of the download like the old base
did, and override that for ALMG.

4 years agoFix construction of new institutions
Gustavo Noronha Silva [Thu, 25 Jul 2013 01:28:37 +0000 (22:28 -0300)]
Fix construction of new institutions

4 years agoAdded get_legislator_picture.py
Marcelo Jorge Vieira [Wed, 24 Jul 2013 04:19:20 +0000 (01:19 -0300)]
Added get_legislator_picture.py

This script get the current picture of ALMG legislators

4 years agoAdded 'picture' attribute in Legislator class
Marcelo Jorge Vieira [Wed, 24 Jul 2013 04:18:51 +0000 (01:18 -0300)]
Added 'picture' attribute in Legislator class

4 years agoFixed get_wikipedia_data.py
Marcelo Jorge Vieira [Wed, 24 Jul 2013 03:01:01 +0000 (00:01 -0300)]
Fixed get_wikipedia_data.py

Removed unnecessary dependency (simplejson)

4 years agoFooter: Fixed typo
Marcelo Jorge Vieira [Wed, 24 Jul 2013 02:48:59 +0000 (23:48 -0300)]
Footer: Fixed typo

Replaced 'exucutando' with 'executando'

4 years agoUpdating README
Marcelo Jorge Vieira [Wed, 24 Jul 2013 02:43:16 +0000 (23:43 -0300)]
Updating README

Added Python PIL as dependency

4 years agoRemoving pre-django files
Gustavo Noronha Silva [Wed, 24 Jul 2013 02:38:00 +0000 (23:38 -0300)]
Removing pre-django files

4 years agoReset ticks to force rendering the first one
Pablo Aguiar [Sun, 14 Jul 2013 22:40:49 +0000 (19:40 -0300)]
Reset ticks to force rendering the first one

Workaround for Flot issue number 795 (https://github.com/flot/flot/issues/795)

4 years agoFixed PoliticalParty class
Marcelo Jorge Vieira [Wed, 24 Jul 2013 02:15:07 +0000 (23:15 -0300)]
Fixed PoliticalParty class

Allow null for name and logo attributes

4 years agoAdded templates for error 404 and 500
Marcelo Jorge Vieira [Wed, 24 Jul 2013 01:48:27 +0000 (22:48 -0300)]
Added templates for error 404 and 500

4 years agoFixed scripts/get_wikipedia_politicalparty_logo.py
Marcelo Jorge Vieira [Mon, 22 Jul 2013 22:35:01 +0000 (19:35 -0300)]
Fixed scripts/get_wikipedia_politicalparty_logo.py

Added BeautifulSoup as dependency

4 years agoTranslating many strings to pt_BR
Marcelo Jorge Vieira [Mon, 22 Jul 2013 22:28:06 +0000 (19:28 -0300)]
Translating many strings to pt_BR

4 years agoAdded author, description and keywords to HTML header
Marcelo Jorge Vieira [Mon, 22 Jul 2013 21:49:08 +0000 (18:49 -0300)]
Added author, description and keywords to HTML header

4 years agoTranslating many strings to pt_BR
Marcelo Jorge Vieira [Mon, 22 Jul 2013 21:33:07 +0000 (18:33 -0300)]
Translating many strings to pt_BR

4 years agoCreated scripts directory
Marcelo Jorge Vieira [Mon, 22 Jul 2013 20:28:41 +0000 (17:28 -0300)]
Created scripts directory

This directory has two scripts to get political party data from wikipedia

4 years agoAdded 'wikipedia' attribute to the PoliticalParty model
Marcelo Jorge Vieira [Mon, 22 Jul 2013 20:28:22 +0000 (17:28 -0300)]
Added 'wikipedia' attribute to the PoliticalParty model

4 years agoAdded 'logo' attribute to the PoliticalParty model
Marcelo Jorge Vieira [Sun, 21 Jul 2013 14:26:02 +0000 (11:26 -0300)]
Added 'logo' attribute to the PoliticalParty model

Added easy_thumbnails as dependency

4 years agoAll expenses view
Gustavo Noronha Silva [Mon, 22 Jul 2013 03:14:55 +0000 (00:14 -0300)]
All expenses view

4 years agoDetail legislator view
Gustavo Noronha Silva [Mon, 22 Jul 2013 03:08:06 +0000 (00:08 -0300)]
Detail legislator view

4 years agoAdapt collector to the changes in the Institution model
Gustavo Noronha Silva [Mon, 22 Jul 2013 02:29:39 +0000 (23:29 -0300)]
Adapt collector to the changes in the Institution model

4 years agoAdded 'siglum' attribute to the Institution model
Marcelo Jorge Vieira [Sun, 21 Jul 2013 13:30:04 +0000 (10:30 -0300)]
Added 'siglum' attribute to the Institution model

4 years agoAdded __unicode__() method to the Institution object
Marcelo Jorge Vieira [Sun, 21 Jul 2013 13:14:55 +0000 (10:14 -0300)]
Added __unicode__() method to the Institution object

Now the Institution object has an human-readable representation,
it is displayed by name.

4 years agoSetting pt_BR.UTF-8 as default locale for monetary
Marcelo Jorge Vieira [Sun, 21 Jul 2013 13:08:56 +0000 (10:08 -0300)]
Setting pt_BR.UTF-8 as default locale for monetary

4 years agoAdded some models to the Admin site
Marcelo Jorge Vieira [Sun, 21 Jul 2013 13:05:31 +0000 (10:05 -0300)]
Added some models to the Admin site

Models:

  * PoliticalParty
  * Institution

4 years agoResizing Graphs automatically
Marcelo Jorge Vieira [Sun, 21 Jul 2013 03:26:43 +0000 (00:26 -0300)]
Resizing Graphs automatically

Setting graph's width with the same width of parent (eg: span6)

4 years agoAdded 'active' style class for selected menu item
Marcelo Jorge Vieira [Sun, 21 Jul 2013 03:07:37 +0000 (00:07 -0300)]
Added 'active' style class for selected menu item

4 years agoIncrease the threshold a little bit
Gustavo Noronha Silva [Sun, 21 Jul 2013 03:06:29 +0000 (00:06 -0300)]
Increase the threshold a little bit

4 years agoMake per-party graph merrier and more useful
Gustavo Noronha Silva [Sun, 21 Jul 2013 02:40:59 +0000 (23:40 -0300)]
Make per-party graph merrier and more useful

This avoids the over-combination of parties in the graph by making
it use a lower threshold. And now we are using the same colors as the
ones being used in the per-nature view.

4 years agoOnly show the average in the per-party view
Gustavo Noronha Silva [Sun, 21 Jul 2013 02:12:44 +0000 (23:12 -0300)]
Only show the average in the per-party view

Hide totals and number of legislators by default, and allow showing it with
a link.

4 years agoMake this template work with older django
Gustavo Noronha Silva [Sun, 21 Jul 2013 00:54:10 +0000 (21:54 -0300)]
Make this template work with older django

4 years agoMake the pagination more functional
Gustavo Noronha Silva [Sun, 21 Jul 2013 00:16:39 +0000 (21:16 -0300)]
Make the pagination more functional

This change also documents the fact that we are using a custom branch of
django-bootstrap-toolkit, while the changes we did are considered upstream.

4 years agoRefactoring Menu
Marcelo Jorge Vieira [Sat, 20 Jul 2013 23:11:02 +0000 (20:11 -0300)]
Refactoring Menu

Now footer and header has the same menu

4 years agoMake the per-nature graph cummulative and stacked area
Gustavo Noronha Silva [Sat, 20 Jul 2013 21:26:10 +0000 (18:26 -0300)]
Make the per-nature graph cummulative and stacked area

4 years agoLoad url from future to support earlier django versions
Gustavo Noronha Silva [Fri, 12 Jul 2013 13:32:46 +0000 (10:32 -0300)]
Load url from future to support earlier django versions

4 years agoUse a bars graph for per nature and add the colors to the table for easy matching
Gustavo Noronha Silva [Fri, 12 Jul 2013 01:58:24 +0000 (22:58 -0300)]
Use a bars graph for per nature and add the colors to the table for easy matching

4 years agoImprove graphing in the per-nature view
Gustavo Noronha Silva [Mon, 8 Jul 2013 11:44:20 +0000 (08:44 -0300)]
Improve graphing in the per-nature view

Change the graph to a time series, make it an area graph showing absolute
values, try to align it with the table showing the data.

4 years agoAdd per-supplier total view
Gustavo Noronha Silva [Mon, 8 Jul 2013 11:42:50 +0000 (08:42 -0300)]
Add per-supplier total view

4 years agoDo not tilt the graph, it looks ugly
Gustavo Noronha Silva [Sat, 6 Jul 2013 18:19:44 +0000 (15:19 -0300)]
Do not tilt the graph, it looks ugly

4 years agoProper formatting of currency
Gustavo Noronha Silva [Sat, 6 Jul 2013 17:47:46 +0000 (14:47 -0300)]
Proper formatting of currency

4 years agoAdd per-party total view
Gustavo Noronha Silva [Sat, 6 Jul 2013 15:25:57 +0000 (12:25 -0300)]
Add per-party total view

4 years agoKill dead markup
Gustavo Noronha Silva [Sat, 6 Jul 2013 15:25:40 +0000 (12:25 -0300)]
Kill dead markup

4 years agoPer-legislator expenses view
Gustavo Noronha Silva [Fri, 5 Jul 2013 22:39:58 +0000 (19:39 -0300)]
Per-legislator expenses view

4 years agoAdd initial collector for ALMG as a command to manage.py
Gustavo Noronha Silva [Fri, 5 Jul 2013 22:09:59 +0000 (19:09 -0300)]
Add initial collector for ALMG as a command to manage.py

This new collector uses the newly added webservice APIs to gather legislators
and expenses in JSON format. To collect:

  $ ./manage.py collect almg

You can also add 'debug' to the command line to make the collection verbose.
By default the collector will gather data for the current year. To gather all
years for a given legislature add 'full-scan' to the command line. The
following example will gather all years with verbose output:

  $ ./manage.py collect debug full-scan almg

4 years agoper nature
Marcelo Jorge Vieira [Mon, 17 Jun 2013 00:52:31 +0000 (21:52 -0300)]
per nature

5 years agoFixed Indent style
Marcelo Jorge Vieira [Mon, 17 Jun 2013 00:52:17 +0000 (21:52 -0300)]
Fixed Indent style

5 years agoIntial version of new Layout
Marcelo Jorge Vieira [Sun, 16 Jun 2013 23:07:11 +0000 (20:07 -0300)]
Intial version of new Layout

5 years agoFixed typo in ExpenseNature model
Marcelo Jorge Vieira [Sun, 16 Jun 2013 22:29:27 +0000 (19:29 -0300)]
Fixed typo in ExpenseNature model

Replaced 'sellf' with 'self'

5 years agoAdded PoliticalParty model
Marcelo Jorge Vieira [Sun, 16 Jun 2013 20:20:46 +0000 (17:20 -0300)]
Added PoliticalParty model

Changing party attr in the Mandate model to be a ForeignKey to PoliticalParty

5 years agoAdded 'django.contrib.admin' in INSTALLED_APPS
Marcelo Jorge Vieira [Fri, 14 Jun 2013 22:36:53 +0000 (19:36 -0300)]
Added 'django.contrib.admin' in INSTALLED_APPS

5 years agoAdded 'montanha' in INSTALLED_APPS
Marcelo Jorge Vieira [Fri, 14 Jun 2013 22:28:46 +0000 (19:28 -0300)]
Added 'montanha' in INSTALLED_APPS

5 years agoAdded copyright holders and license to urls.py
Marcelo Jorge Vieira [Fri, 14 Jun 2013 22:27:12 +0000 (19:27 -0300)]
Added copyright holders and license to urls.py

5 years agoAdded README
Marcelo Jorge Vieira [Fri, 14 Jun 2013 22:21:14 +0000 (19:21 -0300)]
Added README

Initial README version with sections:
  * About
  * Generate secret key
  * License

5 years agoBeginning djangoization
Gustavo Noronha Silva [Thu, 13 Jun 2013 06:59:32 +0000 (03:59 -0300)]
Beginning djangoization

5 years agoMake descriptions unicode explicitely vintage pre-djangoization
Gustavo Noronha Silva [Thu, 13 Jun 2013 03:09:34 +0000 (00:09 -0300)]
Make descriptions unicode explicitely

5 years agoAdapting Camara collector to retrieve expenses per category
Estêvão Samuel Procópio [Mon, 15 Apr 2013 05:16:12 +0000 (02:16 -0300)]
Adapting Camara collector to retrieve expenses per category

5 years agoExperimental cache implementation on Camara collector
Estêvão Samuel Procópio [Mon, 15 Apr 2013 01:00:48 +0000 (22:00 -0300)]
Experimental cache implementation on Camara collector

5 years agoFix duplicate trivia showing up
Gustavo Noronha Silva [Sun, 19 Aug 2012 14:58:31 +0000 (11:58 -0300)]
Fix duplicate trivia showing up

5 years agoUpdate CMBH collector to changes in the site
Gustavo Noronha Silva [Sat, 18 Aug 2012 23:59:54 +0000 (20:59 -0300)]
Update CMBH collector to changes in the site