├── budget_app ├── __init__.py ├── admin.py ├── management │ ├── __init__.py │ └── commands │ │ ├── __init__.py │ │ ├── clear_cache_local.py │ │ ├── load_stats.py │ │ ├── load_glossary.py │ │ ├── load_budget_data.py │ │ ├── load_entities.py │ │ ├── load_payments.py │ │ ├── load_execution.py │ │ └── load_budget.py ├── static │ ├── assets │ │ ├── big-intro.png │ │ ├── icomoon.svg │ │ ├── cc.png │ │ ├── social.png │ │ ├── waves.png │ │ ├── favicon.png │ │ ├── icomoon.eot │ │ ├── icomoon.ttf │ │ ├── icomoon.woff │ │ ├── select2.png │ │ ├── select2x2.png │ │ ├── sepAcces.gif │ │ ├── flag-waves.png │ │ ├── option-tax.png │ │ ├── pignatelli.jpg │ │ ├── slick │ │ │ ├── sort.png │ │ │ ├── collapse.png │ │ │ ├── expand.png │ │ │ ├── sort-asc.png │ │ │ └── sort-desc.png │ │ ├── wait16trans.gif │ │ ├── cornerAccess.gif │ │ ├── entity--chart.png │ │ ├── logoAragonEs.gif │ │ ├── logoAragonEs.png │ │ ├── option-global.png │ │ ├── option-terms.png │ │ ├── reuse inverso2.png │ │ ├── unionEuropea.gif │ │ ├── busget-stream-1.png │ │ ├── busget-stream-2.png │ │ ├── busget-stream-3.png │ │ ├── jslider │ │ │ ├── jslider.png │ │ │ ├── jslider.blue.png │ │ │ ├── jslider.round.png │ │ │ ├── jslider.plastic.png │ │ │ ├── jslider.presus.png │ │ │ └── jslider.round.plastic.png │ │ ├── logoFooterAragon.gif │ │ ├── option-payments.png │ │ ├── option-policies.png │ │ ├── select2-spinner.gif │ │ ├── select2 │ │ │ ├── select2.png │ │ │ ├── select2x2.png │ │ │ └── select2-spinner.gif │ │ ├── sticky-note-text.png │ │ ├── logoAragonOpenData.png │ │ ├── logo-gobierno-aragon.png │ │ ├── logoAragonOpenBudget.png │ │ ├── busget-stream-question.png │ │ ├── comparison__entity--chart.png │ │ ├── busget-stream-question-hover.png │ │ ├── bootstrap │ │ │ ├── glyphicons-halflings.png │ │ │ └── glyphicons-halflings-white.png │ │ └── jquery-ui │ │ │ ├── ui-icons_222222_256x240.png │ │ │ ├── ui-icons_2e83ff_256x240.png │ │ │ ├── ui-icons_454545_256x240.png │ │ │ ├── ui-icons_888888_256x240.png │ │ │ ├── ui-icons_cd0a0a_256x240.png │ │ │ ├── ui-bg_flat_0_aaaaaa_40x100.png │ │ │ ├── ui-bg_flat_75_ffffff_40x100.png │ │ │ ├── ui-bg_glass_55_fbf9ee_1x400.png │ │ │ ├── ui-bg_glass_65_ffffff_1x400.png │ │ │ ├── ui-bg_glass_75_dadada_1x400.png │ │ │ ├── ui-bg_glass_75_e6e6e6_1x400.png │ │ │ ├── ui-bg_glass_75_ffffff_1x400.png │ │ │ ├── ui-bg_inset-soft_95_fef1ec_1x100.png │ │ │ └── ui-bg_highlight-soft_75_cccccc_1x100.png │ ├── stylesheets │ │ ├── variables.less │ │ ├── jslider │ │ │ ├── jslider.blue.less │ │ │ ├── jslider.plastic.less │ │ │ ├── jslider.round.less │ │ │ ├── jslider.round.plastic.less │ │ │ ├── jslider.presus.less │ │ │ └── jslider.less │ │ ├── bootstrap │ │ │ ├── layouts.less │ │ │ ├── component-animations.less │ │ │ ├── utilities.less │ │ │ ├── breadcrumbs.less │ │ │ ├── grid.less │ │ │ ├── hero-unit.less │ │ │ ├── responsive-768px-979px.less │ │ │ ├── wells.less │ │ │ ├── responsive-1200px-min.less │ │ │ ├── close.less │ │ │ ├── pager.less │ │ │ ├── accordion.less │ │ │ ├── scaffolding.less │ │ │ ├── responsive.less │ │ │ ├── responsive-utilities.less │ │ │ ├── thumbnails.less │ │ │ ├── alerts.less │ │ │ ├── code.less │ │ │ ├── pagination.less │ │ │ ├── bootstrap.less │ │ │ ├── tooltip.less │ │ │ ├── labels-badges.less │ │ │ ├── modals.less │ │ │ └── carousel.less │ │ ├── vis │ │ │ ├── infobox.less │ │ │ ├── policies.index.less │ │ │ ├── budget.index.less │ │ │ └── map.less │ │ ├── fonts.less │ │ ├── main.less │ │ ├── print.less │ │ ├── patches.less │ │ ├── colors.less │ │ ├── reset.less │ │ ├── alerts.less │ │ ├── grid.less │ │ └── home.less │ └── javascripts │ │ ├── leaflet │ │ └── images │ │ │ ├── layers.png │ │ │ ├── layers-2x.png │ │ │ ├── marker-icon.png │ │ │ ├── marker-icon-2x.png │ │ │ └── marker-shadow.png │ │ ├── utils.js │ │ ├── comparator.js │ │ ├── select2_locale_es.js │ │ ├── jquery.cookie.min.js │ │ ├── css_browser_selector.js │ │ ├── jslider │ │ ├── tmpl.js │ │ └── jquery.dependClass-0.1.js │ │ ├── icons-lte-ie7.js │ │ ├── grid_controls.js │ │ ├── bootstrap │ │ ├── bootstrap-transition.js │ │ ├── bootstrap-alert.js │ │ └── bootstrap-button.js │ │ ├── vis │ │ └── budget-summary.js │ │ └── breakpoints.js ├── views │ ├── reuse.py │ ├── propertiesLoader.py │ ├── terms.py │ ├── tax_receipt.py │ ├── payments.py │ ├── __init__.py │ ├── welcome.py │ ├── budgets.py │ ├── towns.py │ └── counties.py ├── loaders │ ├── __init__.py │ ├── entity_loader.py │ ├── glossary_loader.py │ └── stat_loader.py ├── models │ ├── __init__.py │ ├── funding_category.py │ ├── institutional_category.py │ ├── glossary_term.py │ ├── inflation_stat.py │ ├── entity.py │ ├── economic_category.py │ ├── population_stat.py │ ├── functional_category.py │ ├── budget_breakdown.py │ └── payment.py └── tests.py ├── project ├── __init__.py ├── middleware.py └── wsgi.py ├── django_jasmine ├── __init__.py ├── templates │ └── jasmine │ │ ├── index.html │ │ └── base.html ├── static │ ├── jasmine-latest │ │ ├── jasmine_favicon.png │ │ └── MIT.LICENSE │ ├── jasmine-1.1.0.rc1 │ │ ├── jasmine_favicon.png │ │ ├── MIT.LICENSE │ │ └── jasmine.css │ └── jasmine-1.0.1 │ │ ├── MIT.LICENSE │ │ └── jasmine.css ├── urls.py └── views.py ├── theme-aragon ├── __init__.py ├── static │ ├── .do_not_remove │ ├── sitemaps │ │ ├── Gobierno.xml │ │ ├── Home.xml │ │ └── VisionGlobal.xml │ ├── robots.txt │ └── sitemap.xml ├── loaders │ └── __init__.py ├── .gitignore ├── data │ ├── comunidad │ │ ├── 2014 │ │ │ ├── gastos.csv │ │ │ ├── ingresos.csv │ │ │ ├── estructura_economica.csv │ │ │ ├── estructura_funcional.csv │ │ │ ├── estructura_organica.csv │ │ │ └── estructura_financiacion.csv │ │ └── 2021 │ │ │ ├── gastos.csv │ │ │ ├── ingresos.csv │ │ │ ├── estructura_economica.csv │ │ │ ├── estructura_funcional.csv │ │ │ ├── estructura_organica.csv │ │ │ └── estructura_financiacion.csv │ ├── inflacion.csv │ └── inspect.rb ├── templates │ └── shared │ │ └── meta.html ├── settings.py └── scripts │ └── carga_nuevos_datos.sh ├── templates ├── payments │ └── payments_intro.html ├── shared │ ├── fonts.html │ ├── data_controllers_select.html │ ├── analytics.html │ ├── meta.html │ ├── payment_tab.html │ ├── entity_select.html │ ├── breakdown_tab.html │ ├── chromeframe.html │ ├── pagination.html │ ├── social_sharing.html │ ├── footer.html │ ├── data_controllers.html │ ├── data_sources.html │ └── header.html ├── 500.html ├── entities │ └── totals.html ├── robots.txt ├── terms │ └── index.html └── budgets │ ├── budgets_intro.html │ ├── budgets_indicators.html │ └── budgets_update_indicators.html ├── docs ├── Memoria Fase 1.pdf ├── Memoria Fase 2.pdf └── Documentación Técnica.pdf ├── etls └── presupuestos_locales │ ├── project │ └── AOD_PREL.zip │ └── doc │ ├── [AOD]_Manual de ejecución_v1.0.0.docx │ ├── [AOD]_Extracción y carga de presupuestos locales_v1.0.0.docx │ └── carga_datos_presupuestos.md ├── requirements.txt ├── .gitignore ├── manage.py ├── tests ├── files.json └── spec │ ├── tax_calculator_spec.js │ └── grid_formatters_spec.js ├── local_settings.py-example ├── properties.py └── CHANGELOG.md /budget_app/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /budget_app/admin.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /project/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /django_jasmine/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /theme-aragon/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /budget_app/management/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /budget_app/static/assets/big-intro.png: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /budget_app/management/commands/__init__.py: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /theme-aragon/static/.do_not_remove: -------------------------------------------------------------------------------- 1 | .do_not_remove -------------------------------------------------------------------------------- /budget_app/static/stylesheets/variables.less: -------------------------------------------------------------------------------- 1 | /* Variables */ -------------------------------------------------------------------------------- /budget_app/static/assets/icomoon.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /django_jasmine/templates/jasmine/index.html: -------------------------------------------------------------------------------- 1 | {% extends "jasmine/base.html" %} 2 | -------------------------------------------------------------------------------- /theme-aragon/loaders/__init__.py: -------------------------------------------------------------------------------- 1 | from aragon_budget_loader import AragonBudgetLoader 2 | -------------------------------------------------------------------------------- /theme-aragon/.gitignore: -------------------------------------------------------------------------------- 1 | data/municipio 2 | data/comarca 3 | data/comunidad 4 | data_summary.py -------------------------------------------------------------------------------- /templates/payments/payments_intro.html: -------------------------------------------------------------------------------- 1 |
{{ _('Gastos del año vigente') }}
-------------------------------------------------------------------------------- /docs/Memoria Fase 1.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/docs/Memoria Fase 1.pdf -------------------------------------------------------------------------------- /docs/Memoria Fase 2.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/docs/Memoria Fase 2.pdf -------------------------------------------------------------------------------- /budget_app/static/assets/cc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/cc.png -------------------------------------------------------------------------------- /docs/Documentación Técnica.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/docs/Documentación Técnica.pdf -------------------------------------------------------------------------------- /budget_app/static/assets/social.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/social.png -------------------------------------------------------------------------------- /budget_app/static/assets/waves.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/waves.png -------------------------------------------------------------------------------- /budget_app/static/assets/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/favicon.png -------------------------------------------------------------------------------- /budget_app/static/assets/icomoon.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/icomoon.eot -------------------------------------------------------------------------------- /budget_app/static/assets/icomoon.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/icomoon.ttf -------------------------------------------------------------------------------- /budget_app/static/assets/icomoon.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/icomoon.woff -------------------------------------------------------------------------------- /budget_app/static/assets/select2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/select2.png -------------------------------------------------------------------------------- /budget_app/static/assets/select2x2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/select2x2.png -------------------------------------------------------------------------------- /budget_app/static/assets/sepAcces.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/sepAcces.gif -------------------------------------------------------------------------------- /budget_app/static/assets/flag-waves.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/flag-waves.png -------------------------------------------------------------------------------- /budget_app/static/assets/option-tax.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/option-tax.png -------------------------------------------------------------------------------- /budget_app/static/assets/pignatelli.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/pignatelli.jpg -------------------------------------------------------------------------------- /budget_app/static/assets/slick/sort.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/slick/sort.png -------------------------------------------------------------------------------- /budget_app/static/assets/wait16trans.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/wait16trans.gif -------------------------------------------------------------------------------- /budget_app/static/assets/cornerAccess.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/cornerAccess.gif -------------------------------------------------------------------------------- /budget_app/static/assets/entity--chart.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/entity--chart.png -------------------------------------------------------------------------------- /budget_app/static/assets/logoAragonEs.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/logoAragonEs.gif -------------------------------------------------------------------------------- /budget_app/static/assets/logoAragonEs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/logoAragonEs.png -------------------------------------------------------------------------------- /budget_app/static/assets/option-global.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/option-global.png -------------------------------------------------------------------------------- /budget_app/static/assets/option-terms.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/option-terms.png -------------------------------------------------------------------------------- /budget_app/static/assets/reuse inverso2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/reuse inverso2.png -------------------------------------------------------------------------------- /budget_app/static/assets/slick/collapse.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/slick/collapse.png -------------------------------------------------------------------------------- /budget_app/static/assets/slick/expand.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/slick/expand.png -------------------------------------------------------------------------------- /budget_app/static/assets/slick/sort-asc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/slick/sort-asc.png -------------------------------------------------------------------------------- /budget_app/static/assets/unionEuropea.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/unionEuropea.gif -------------------------------------------------------------------------------- /theme-aragon/data/comunidad/2014/gastos.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/theme-aragon/data/comunidad/2014/gastos.csv -------------------------------------------------------------------------------- /theme-aragon/data/comunidad/2021/gastos.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/theme-aragon/data/comunidad/2021/gastos.csv -------------------------------------------------------------------------------- /budget_app/static/assets/busget-stream-1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/busget-stream-1.png -------------------------------------------------------------------------------- /budget_app/static/assets/busget-stream-2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/busget-stream-2.png -------------------------------------------------------------------------------- /budget_app/static/assets/busget-stream-3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/busget-stream-3.png -------------------------------------------------------------------------------- /budget_app/static/assets/jslider/jslider.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jslider/jslider.png -------------------------------------------------------------------------------- /budget_app/static/assets/logoFooterAragon.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/logoFooterAragon.gif -------------------------------------------------------------------------------- /budget_app/static/assets/option-payments.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/option-payments.png -------------------------------------------------------------------------------- /budget_app/static/assets/option-policies.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/option-policies.png -------------------------------------------------------------------------------- /budget_app/static/assets/select2-spinner.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/select2-spinner.gif -------------------------------------------------------------------------------- /budget_app/static/assets/select2/select2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/select2/select2.png -------------------------------------------------------------------------------- /budget_app/static/assets/slick/sort-desc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/slick/sort-desc.png -------------------------------------------------------------------------------- /budget_app/static/assets/sticky-note-text.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/sticky-note-text.png -------------------------------------------------------------------------------- /theme-aragon/data/comunidad/2014/ingresos.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/theme-aragon/data/comunidad/2014/ingresos.csv -------------------------------------------------------------------------------- /theme-aragon/data/comunidad/2021/ingresos.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/theme-aragon/data/comunidad/2021/ingresos.csv -------------------------------------------------------------------------------- /budget_app/static/assets/logoAragonOpenData.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/logoAragonOpenData.png -------------------------------------------------------------------------------- /budget_app/static/assets/select2/select2x2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/select2/select2x2.png -------------------------------------------------------------------------------- /etls/presupuestos_locales/project/AOD_PREL.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/etls/presupuestos_locales/project/AOD_PREL.zip -------------------------------------------------------------------------------- /budget_app/static/assets/jslider/jslider.blue.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jslider/jslider.blue.png -------------------------------------------------------------------------------- /budget_app/static/assets/jslider/jslider.round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jslider/jslider.round.png -------------------------------------------------------------------------------- /budget_app/static/assets/logo-gobierno-aragon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/logo-gobierno-aragon.png -------------------------------------------------------------------------------- /budget_app/static/assets/logoAragonOpenBudget.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/logoAragonOpenBudget.png -------------------------------------------------------------------------------- /budget_app/static/assets/busget-stream-question.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/busget-stream-question.png -------------------------------------------------------------------------------- /budget_app/static/assets/jslider/jslider.plastic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jslider/jslider.plastic.png -------------------------------------------------------------------------------- /budget_app/static/assets/jslider/jslider.presus.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jslider/jslider.presus.png -------------------------------------------------------------------------------- /budget_app/static/assets/select2/select2-spinner.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/select2/select2-spinner.gif -------------------------------------------------------------------------------- /budget_app/static/assets/comparison__entity--chart.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/comparison__entity--chart.png -------------------------------------------------------------------------------- /budget_app/static/javascripts/leaflet/images/layers.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/javascripts/leaflet/images/layers.png -------------------------------------------------------------------------------- /budget_app/static/assets/busget-stream-question-hover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/busget-stream-question-hover.png -------------------------------------------------------------------------------- /budget_app/static/assets/jslider/jslider.round.plastic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jslider/jslider.round.plastic.png -------------------------------------------------------------------------------- /budget_app/static/javascripts/leaflet/images/layers-2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/javascripts/leaflet/images/layers-2x.png -------------------------------------------------------------------------------- /budget_app/static/stylesheets/jslider/jslider.blue.less: -------------------------------------------------------------------------------- 1 | .jslider_blue .jslider-bg i, .jslider_blue .jslider-pointer {background-image: url(../assets/jslider/jslider.blue.png);} -------------------------------------------------------------------------------- /django_jasmine/static/jasmine-latest/jasmine_favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/django_jasmine/static/jasmine-latest/jasmine_favicon.png -------------------------------------------------------------------------------- /theme-aragon/data/comunidad/2014/estructura_economica.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/theme-aragon/data/comunidad/2014/estructura_economica.csv -------------------------------------------------------------------------------- /theme-aragon/data/comunidad/2014/estructura_funcional.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/theme-aragon/data/comunidad/2014/estructura_funcional.csv -------------------------------------------------------------------------------- /theme-aragon/data/comunidad/2014/estructura_organica.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/theme-aragon/data/comunidad/2014/estructura_organica.csv -------------------------------------------------------------------------------- /theme-aragon/data/comunidad/2021/estructura_economica.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/theme-aragon/data/comunidad/2021/estructura_economica.csv -------------------------------------------------------------------------------- /theme-aragon/data/comunidad/2021/estructura_funcional.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/theme-aragon/data/comunidad/2021/estructura_funcional.csv -------------------------------------------------------------------------------- /theme-aragon/data/comunidad/2021/estructura_organica.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/theme-aragon/data/comunidad/2021/estructura_organica.csv -------------------------------------------------------------------------------- /budget_app/static/assets/bootstrap/glyphicons-halflings.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/bootstrap/glyphicons-halflings.png -------------------------------------------------------------------------------- /budget_app/static/javascripts/leaflet/images/marker-icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/javascripts/leaflet/images/marker-icon.png -------------------------------------------------------------------------------- /django_jasmine/static/jasmine-1.1.0.rc1/jasmine_favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/django_jasmine/static/jasmine-1.1.0.rc1/jasmine_favicon.png -------------------------------------------------------------------------------- /theme-aragon/data/comunidad/2014/estructura_financiacion.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/theme-aragon/data/comunidad/2014/estructura_financiacion.csv -------------------------------------------------------------------------------- /theme-aragon/data/comunidad/2021/estructura_financiacion.csv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/theme-aragon/data/comunidad/2021/estructura_financiacion.csv -------------------------------------------------------------------------------- /budget_app/static/assets/jquery-ui/ui-icons_222222_256x240.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jquery-ui/ui-icons_222222_256x240.png -------------------------------------------------------------------------------- /budget_app/static/assets/jquery-ui/ui-icons_2e83ff_256x240.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jquery-ui/ui-icons_2e83ff_256x240.png -------------------------------------------------------------------------------- /budget_app/static/assets/jquery-ui/ui-icons_454545_256x240.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jquery-ui/ui-icons_454545_256x240.png -------------------------------------------------------------------------------- /budget_app/static/assets/jquery-ui/ui-icons_888888_256x240.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jquery-ui/ui-icons_888888_256x240.png -------------------------------------------------------------------------------- /budget_app/static/assets/jquery-ui/ui-icons_cd0a0a_256x240.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jquery-ui/ui-icons_cd0a0a_256x240.png -------------------------------------------------------------------------------- /budget_app/static/javascripts/leaflet/images/marker-icon-2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/javascripts/leaflet/images/marker-icon-2x.png -------------------------------------------------------------------------------- /budget_app/static/javascripts/leaflet/images/marker-shadow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/javascripts/leaflet/images/marker-shadow.png -------------------------------------------------------------------------------- /budget_app/static/assets/bootstrap/glyphicons-halflings-white.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/bootstrap/glyphicons-halflings-white.png -------------------------------------------------------------------------------- /budget_app/static/assets/jquery-ui/ui-bg_flat_0_aaaaaa_40x100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jquery-ui/ui-bg_flat_0_aaaaaa_40x100.png -------------------------------------------------------------------------------- /budget_app/static/stylesheets/jslider/jslider.plastic.less: -------------------------------------------------------------------------------- 1 | .jslider_plastic .jslider-bg i, .jslider_plastic .jslider-pointer {background-image: url(../assets/jslider/jslider.plastic.png);} 2 | -------------------------------------------------------------------------------- /budget_app/static/assets/jquery-ui/ui-bg_flat_75_ffffff_40x100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jquery-ui/ui-bg_flat_75_ffffff_40x100.png -------------------------------------------------------------------------------- /budget_app/static/assets/jquery-ui/ui-bg_glass_55_fbf9ee_1x400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jquery-ui/ui-bg_glass_55_fbf9ee_1x400.png -------------------------------------------------------------------------------- /budget_app/static/assets/jquery-ui/ui-bg_glass_65_ffffff_1x400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jquery-ui/ui-bg_glass_65_ffffff_1x400.png -------------------------------------------------------------------------------- /budget_app/static/assets/jquery-ui/ui-bg_glass_75_dadada_1x400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jquery-ui/ui-bg_glass_75_dadada_1x400.png -------------------------------------------------------------------------------- /budget_app/static/assets/jquery-ui/ui-bg_glass_75_e6e6e6_1x400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jquery-ui/ui-bg_glass_75_e6e6e6_1x400.png -------------------------------------------------------------------------------- /budget_app/static/assets/jquery-ui/ui-bg_glass_75_ffffff_1x400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jquery-ui/ui-bg_glass_75_ffffff_1x400.png -------------------------------------------------------------------------------- /etls/presupuestos_locales/doc/[AOD]_Manual de ejecución_v1.0.0.docx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/etls/presupuestos_locales/doc/[AOD]_Manual de ejecución_v1.0.0.docx -------------------------------------------------------------------------------- /templates/shared/fonts.html: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /budget_app/static/assets/jquery-ui/ui-bg_inset-soft_95_fef1ec_1x100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jquery-ui/ui-bg_inset-soft_95_fef1ec_1x100.png -------------------------------------------------------------------------------- /budget_app/static/assets/jquery-ui/ui-bg_highlight-soft_75_cccccc_1x100.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/budget_app/static/assets/jquery-ui/ui-bg_highlight-soft_75_cccccc_1x100.png -------------------------------------------------------------------------------- /etls/presupuestos_locales/doc/[AOD]_Extracción y carga de presupuestos locales_v1.0.0.docx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/aragonopendata/presupuesto/HEAD/etls/presupuestos_locales/doc/[AOD]_Extracción y carga de presupuestos locales_v1.0.0.docx -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- 1 | Coffin==0.3.7 2 | Django==1.4.3 3 | django-appconf==1.0.1 4 | django-compressor==1.4 5 | django-jasmine==0.4.1 6 | Jinja2==2.6 7 | MarkupSafe==1.0 8 | psycopg2-binary==2.8.4 9 | Pygments==2.4.2 10 | six==1.12.0 11 | xlwt==0.7.5 12 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | db 2 | *pyc 3 | .DS_Store 4 | /static 5 | local_settings*py 6 | /project/settings.py 7 | fabfile.* 8 | presupuesto-* 9 | *config.codekit 10 | 11 | budget_app/static/stylesheets/config.codekit 12 | /.gitignore 13 | /.project 14 | /.pydevproject -------------------------------------------------------------------------------- /templates/500.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 |Volvemos en unos minutos.
10 | 11 | -------------------------------------------------------------------------------- /budget_app/static/stylesheets/jslider/jslider.round.less: -------------------------------------------------------------------------------- 1 | .jslider_round .jslider-bg i, .jslider_round .jslider-pointer {background-image: url(../assets/jslider/jslider.round.png);} 2 | .jslider_round .jslider-pointer {width: 17px; height: 17px; top: -6px; margin-left: -8px;} -------------------------------------------------------------------------------- /budget_app/management/commands/clear_cache_local.py: -------------------------------------------------------------------------------- 1 | from django.core.management.base import BaseCommand 2 | from django.core.cache import cache 3 | 4 | class Command(BaseCommand): 5 | def handle(self, *args, **kwargs): 6 | cache.clear() 7 | self.stdout.write('Cleared cache\n') 8 | -------------------------------------------------------------------------------- /manage.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | import os 3 | import sys 4 | 5 | if __name__ == "__main__": 6 | os.environ.setdefault("DJANGO_SETTINGS_MODULE", "project.settings") 7 | 8 | from django.core.management import execute_from_command_line 9 | 10 | execute_from_command_line(sys.argv) 11 | -------------------------------------------------------------------------------- /budget_app/static/stylesheets/jslider/jslider.round.plastic.less: -------------------------------------------------------------------------------- 1 | .jslider_round_plastic .jslider-bg i, .jslider_round_plastic .jslider-pointer {background-image: url(../assets/jslider/jslider.round.plastic.png);} 2 | .jslider_round_plastic .jslider-pointer {width: 18px; height: 18px; top: -7px; margin-left: -8px;} -------------------------------------------------------------------------------- /budget_app/views/reuse.py: -------------------------------------------------------------------------------- 1 | from coffin.shortcuts import render_to_response 2 | from django.utils.translation import ugettext as _ 3 | from helpers import * 4 | 5 | 6 | def reuse(request): 7 | c = get_context(request, css_class='body-reuse', title=_('Inicio')) 8 | return render_to_response('reuse/index.html', c) 9 | -------------------------------------------------------------------------------- /budget_app/loaders/__init__.py: -------------------------------------------------------------------------------- 1 | from aragon_bulk_budget_loader import AragonBulkBudgetLoader 2 | from budget_loader import BudgetLoader 3 | from simple_budget_loader import SimpleBudgetLoader 4 | from glossary_loader import GlossaryLoader 5 | from stat_loader import StatLoader 6 | from entity_loader import EntityLoader 7 | from payments_loader import PaymentsLoader -------------------------------------------------------------------------------- /budget_app/models/__init__.py: -------------------------------------------------------------------------------- 1 | from entity import * 2 | from budget import * 3 | from economic_category import * 4 | from functional_category import * 5 | from funding_category import * 6 | from budget_item import * 7 | from budget_breakdown import * 8 | from glossary_term import * 9 | from institutional_category import * 10 | from inflation_stat import * 11 | from population_stat import * 12 | from payment import * -------------------------------------------------------------------------------- /budget_app/static/stylesheets/bootstrap/layouts.less: -------------------------------------------------------------------------------- 1 | // 2 | // Layouts 3 | // -------------------------------------------------- 4 | 5 | 6 | // Container (centered, fixed-width layouts) 7 | .container { 8 | .container-fixed(); 9 | } 10 | 11 | // Fluid layouts (left aligned, with sidebar, min- & max-width content) 12 | .container-fluid { 13 | padding-right: @gridGutterWidth; 14 | padding-left: @gridGutterWidth; 15 | .clearfix(); 16 | } -------------------------------------------------------------------------------- /templates/shared/data_controllers_select.html: -------------------------------------------------------------------------------- 1 | 9 | -------------------------------------------------------------------------------- /budget_app/tests.py: -------------------------------------------------------------------------------- 1 | """ 2 | This file demonstrates writing tests using the unittest module. These will pass 3 | when you run "manage.py test". 4 | 5 | Replace this with more appropriate tests for your application. 6 | """ 7 | 8 | from django.test import TestCase 9 | 10 | 11 | class SimpleTest(TestCase): 12 | def test_basic_addition(self): 13 | """ 14 | Tests that 1 + 1 always equals 2. 15 | """ 16 | self.assertEqual(1 + 1, 2) 17 | -------------------------------------------------------------------------------- /tests/files.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Main Test Suite", 3 | "js_files": [ 4 | "../static/javascripts/jquery-1.8.3.min.js", 5 | "../static/javascripts/grid_controls.js", 6 | "../static/javascripts/grid_formatters.js", 7 | "../static/javascripts/grid_helpers.js", 8 | "../static/javascripts/numeral.min.js", 9 | "../static/javascripts/numeral-languages.min.js", 10 | "../static/javascripts/tax_calculator.js" 11 | ], 12 | "media_files": [ 13 | ] 14 | } -------------------------------------------------------------------------------- /budget_app/static/stylesheets/vis/infobox.less: -------------------------------------------------------------------------------- 1 | // INFOBOX 2 | #pop-up { 3 | display: none; 4 | position:absolute; 5 | color: white; 6 | line-height: 1.1; 7 | background: rgba(0,0,0,0.7); 8 | padding: 5px 10px 5px 10px; 9 | -moz-border-radius: 8px 8px; 10 | border-radius: 8px 8px; 11 | pointer-events: none; 12 | } 13 | 14 | #pop-up-title { 15 | font-size: 14px; 16 | margin-bottom: 4px; 17 | font-weight: bolder; 18 | } 19 | 20 | #pop-up-content { 21 | font-size: 12px; 22 | } -------------------------------------------------------------------------------- /budget_app/static/javascripts/utils.js: -------------------------------------------------------------------------------- 1 | function countReused() { 2 | var cnt_aragon = $('#adm_aragon li').length; 3 | var cnt_spain = $('#adm_spain li').length; 4 | var cnt_orgs = $('#emp_org li').length; 5 | var cnt_int = $('#adm_int li').length; 6 | $('#adm_count_text').text('Ya sois ' + cnt_aragon + ' administraciones en Aragón, ' + cnt_spain + ' en España, ' 7 | + cnt_orgs + ' empresas y organizaciones y ' + cnt_int + ' entidad internacional. Y al resto de administraciones, ¡os esperamos!'); 8 | } -------------------------------------------------------------------------------- /budget_app/static/stylesheets/bootstrap/component-animations.less: -------------------------------------------------------------------------------- 1 | // 2 | // Component animations 3 | // -------------------------------------------------- 4 | 5 | 6 | .fade { 7 | opacity: 0; 8 | .transition(opacity .15s linear); 9 | &.in { 10 | opacity: 1; 11 | } 12 | } 13 | 14 | .collapse { 15 | position: relative; 16 | height: 0; 17 | overflow: hidden; 18 | overflow: visible \9; 19 | .transition(height .35s ease); 20 | &.in { 21 | height: auto; 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /budget_app/static/stylesheets/bootstrap/utilities.less: -------------------------------------------------------------------------------- 1 | // 2 | // Utility classes 3 | // -------------------------------------------------- 4 | 5 | 6 | // Quick floats 7 | .pull-right { 8 | float: right; 9 | } 10 | .pull-left { 11 | float: left; 12 | } 13 | 14 | // Toggling content 15 | .hide { 16 | display: none; 17 | } 18 | .show { 19 | display: block; 20 | } 21 | 22 | // Visibility 23 | .invisible { 24 | visibility: hidden; 25 | } 26 | 27 | // For Affix plugin 28 | .affix { 29 | position: fixed; 30 | } 31 | -------------------------------------------------------------------------------- /budget_app/static/stylesheets/fonts.less: -------------------------------------------------------------------------------- 1 | // Titillium Web 2 | // URL: http://www.google.com/fonts/specimen/Titillium+Web 3 | // Titillium+Web:400,200,200italic,300,300italic,400italic,600,600italic,700,700italic:latin 4 | // Styles (+ their italics): 5 | // Extra Light 200 6 | // Light 300 7 | // Normal 400 8 | // Semi-Bold 600 9 | // Bold 700 10 | body, label, input, select, optgroup, option, textarea, button {font-family: @baseFontFamily;} 11 | em, i, q, blockquote, cite, caption {font-family: @serifFontFamily;} -------------------------------------------------------------------------------- /templates/shared/analytics.html: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /budget_app/static/stylesheets/jslider/jslider.presus.less: -------------------------------------------------------------------------------- 1 | .jslider_presus .jslider-bg i, .jslider_presus .jslider-pointer {background-image: url(../assets/jslider/jslider.presus.png);} 2 | .jslider_presus .jslider-pointer {background-position: 0 -36px; height: 40px; margin-left: -27px; top: -16px; width: 56px; z-index: 2;} 3 | .jslider_presus .jslider-pointer-hover {background-position: -56px -36px;} 4 | .jslider_presus .jslider-value {top: -2.65em;} 5 | .jslider_presus .jslider-scale ins {top: 12px;} 6 | .jslider_presus .jslider-scale span {height: 12px;} -------------------------------------------------------------------------------- /templates/entities/totals.html: -------------------------------------------------------------------------------- 1 |
3 |
4 |
5 | {{ _('Presupuestados') }}
6 |
8 |
9 |
10 | {{ _('Presupuestados') }}
11 |
¿Quieres comparar {{ 'esta comarca con otra' if current_entity.level == 'comarca' else 'este municipio con otro' }}?
4 | 15 |9 | {{ _('Descarga la tabla de') }} {{title}} en {{name}} 10 | 11 | CSV 12 | 13 | o 14 | 15 | Excel 16 | 17 |
18 |{{ _('¡Atención!') }}
4 |{{ _('Este sitio web no va a funcionar correctamente en tu navegador. La visualización de datos de esta página requieren un navegador con funciones adicionales, como') }} IE9, Firefox, Chrome o Safari. {{ _('Si quieres continuar usando Internet Explorer') }} {{ _('puedes instalar el plugin de Google Chrome Frame') }} {{ _('en unos minutos') }}.
5 |{{ _('Se realiza a través de impuestos directos - como el IRPF y el impuesto de sociedades - y de impuestos indirectos - el IVA e impuestos sobre el tabaco, el alcohol o la gasolina -.')|safe }}
7 |{{ _('Una parte del dinero recaudado se queda en la Administración General del Estado, mientras que otra parte se transfiere al Gobierno de Aragón')|safe }}.
13 |{{ _('El Gobierno de Aragón utiliza el dinero recaudado, junto con otras fuentes de financiación como puede ser la deuda, para mantener los servicios públicos')|safe }}.
19 |{{ _('Cantidades actualizadas con la inflación a fecha 1 de enero de') }} {{ last_inflation_year }}. {{ _('El cálculo de los indicadores utiliza las cifras del presupuesto aprobado') }}.
-------------------------------------------------------------------------------- /budget_app/static/stylesheets/bootstrap/responsive-utilities.less: -------------------------------------------------------------------------------- 1 | // 2 | // Responsive: Utility classes 3 | // -------------------------------------------------- 4 | 5 | 6 | // Hide from screenreaders and browsers 7 | // Credit: HTML5 Boilerplate 8 | .hidden { 9 | display: none; 10 | visibility: hidden; 11 | } 12 | 13 | // Visibility utilities 14 | 15 | // For desktops 16 | .visible-phone { display: none !important; } 17 | .visible-tablet { display: none !important; } 18 | .hidden-phone { } 19 | .hidden-tablet { } 20 | .hidden-desktop { display: none !important; } 21 | .visible-desktop { display: inherit !important; } 22 | 23 | // Tablets & small desktops only 24 | @media (min-width: 768px) and (max-width: 979px) { 25 | // Hide everything else 26 | .hidden-desktop { display: inherit !important; } 27 | .visible-desktop { display: none !important ; } 28 | // Show 29 | .visible-tablet { display: inherit !important; } 30 | // Hide 31 | .hidden-tablet { display: none !important; } 32 | } 33 | 34 | // Phones only 35 | @media (max-width: 767px) { 36 | // Hide everything else 37 | .hidden-desktop { display: inherit !important; } 38 | .visible-desktop { display: none !important; } 39 | // Show 40 | .visible-phone { display: inherit !important; } // Use inherit to restore previous behavior 41 | // Hide 42 | .hidden-phone { display: none !important; } 43 | } 44 | -------------------------------------------------------------------------------- /budget_app/static/stylesheets/bootstrap/thumbnails.less: -------------------------------------------------------------------------------- 1 | // 2 | // Thumbnails 3 | // -------------------------------------------------- 4 | 5 | 6 | // Note: `.thumbnails` and `.thumbnails > li` are overriden in responsive files 7 | 8 | // Make wrapper ul behave like the grid 9 | .thumbnails { 10 | margin-left: -@gridGutterWidth; 11 | list-style: none; 12 | .clearfix(); 13 | } 14 | // Fluid rows have no left margin 15 | .row-fluid .thumbnails { 16 | margin-left: 0; 17 | } 18 | 19 | // Float li to make thumbnails appear in a row 20 | .thumbnails > li { 21 | float: left; // Explicity set the float since we don't require .span* classes 22 | margin-bottom: @baseLineHeight; 23 | margin-left: @gridGutterWidth; 24 | } 25 | 26 | // The actual thumbnail (can be `a` or `div`) 27 | .thumbnail { 28 | display: block; 29 | padding: 4px; 30 | line-height: @baseLineHeight; 31 | border: 1px solid #ddd; 32 | .border-radius(4px); 33 | .box-shadow(0 1px 3px rgba(0,0,0,.055)); 34 | .transition(all .2s ease-in-out); 35 | } 36 | // Add a hover state for linked versions only 37 | a.thumbnail:hover { 38 | border-color: @linkColor; 39 | .box-shadow(0 1px 4px rgba(0,105,214,.25)); 40 | } 41 | 42 | // Images and captions 43 | .thumbnail > img { 44 | display: block; 45 | max-width: 100%; 46 | margin-left: auto; 47 | margin-right: auto; 48 | } 49 | .thumbnail .caption { 50 | padding: 9px; 51 | color: @gray; 52 | } 53 | -------------------------------------------------------------------------------- /budget_app/static/stylesheets/bootstrap/alerts.less: -------------------------------------------------------------------------------- 1 | // 2 | // Alerts 3 | // -------------------------------------------------- 4 | 5 | 6 | // Base styles 7 | // ------------------------- 8 | 9 | .alert { 10 | padding: 8px 35px 8px 14px; 11 | margin-bottom: @baseLineHeight; 12 | text-shadow: 0 1px 0 rgba(255,255,255,.5); 13 | background-color: @warningBackground; 14 | border: 1px solid @warningBorder; 15 | .border-radius(4px); 16 | color: @warningText; 17 | } 18 | .alert h4 { 19 | margin: 0; 20 | } 21 | 22 | // Adjust close link position 23 | .alert .close { 24 | position: relative; 25 | top: -2px; 26 | right: -21px; 27 | line-height: @baseLineHeight; 28 | } 29 | 30 | 31 | // Alternate styles 32 | // ------------------------- 33 | 34 | .alert-success { 35 | background-color: @successBackground; 36 | border-color: @successBorder; 37 | color: @successText; 38 | } 39 | .alert-danger, 40 | .alert-error { 41 | background-color: @errorBackground; 42 | border-color: @errorBorder; 43 | color: @errorText; 44 | } 45 | .alert-info { 46 | background-color: @infoBackground; 47 | border-color: @infoBorder; 48 | color: @infoText; 49 | } 50 | 51 | 52 | // Block alerts 53 | // ------------------------- 54 | 55 | .alert-block { 56 | padding-top: 14px; 57 | padding-bottom: 14px; 58 | } 59 | .alert-block > p, 60 | .alert-block > ul { 61 | margin-bottom: 0; 62 | } 63 | .alert-block p + p { 64 | margin-top: 5px; 65 | } 66 | -------------------------------------------------------------------------------- /templates/shared/data_controllers.html: -------------------------------------------------------------------------------- 1 |{{ _('Ingresos y gastos') }}
6 |{{ _('Cantidades') }}
20 | {% include 'shared/data_controllers_select.html' %} 21 |{{ _('Año') }}
29 | 32 |'+mostRecentYear+'
'); 34 | } 35 | } 36 | 37 | function getUIState() { 38 | return { 39 | field: getActiveButton('#btn-field') == 'income' ? 'income' : 'expense', 40 | view: getActiveButton('#btn-field'), 41 | format: $('#select-format').val(), 42 | year: $("#year-selection").val() 43 | } 44 | } 45 | 46 | function sameUIState(a, b) { 47 | return a.view==b.view && a.field==b.field && a.year==b.year && a.format==b.format; 48 | } -------------------------------------------------------------------------------- /budget_app/models/population_stat.py: -------------------------------------------------------------------------------- 1 | from django.db import models 2 | from budget_app.models import Entity, InflationStat 3 | 4 | 5 | class PopulationStatManager(models.Manager): 6 | def get_entity_table(self, entity): 7 | table = {} 8 | stats = self.filter(entity=entity).order_by('year') 9 | for stat in stats: 10 | table[stat.year] = stat.population 11 | 12 | # Now populate the returned table up to the latest year, filling in the gaps. 13 | # We need to do this because population data is often incomplete or not up to date. 14 | last_year = InflationStat.objects.get_last_year() 15 | last_valid_population = None 16 | for year in range(stats[0].year, last_year+3): # Some extra years to avoid breaking every year 17 | if year in table: 18 | last_valid_population = table[year] 19 | table[year] = last_valid_population 20 | return table 21 | 22 | def get_level_table(self, level): 23 | table = {} 24 | for entity in Entity.objects.entities(level): 25 | table[entity.name] = self.get_entity_table(entity) 26 | return table 27 | 28 | def get_last_year(self): 29 | return self.order_by('-year').all()[0].year 30 | 31 | 32 | class PopulationStat(models.Model): 33 | entity = models.ForeignKey('Entity', db_column='entity_id') 34 | year = models.IntegerField() 35 | population = models.IntegerField() 36 | updated_at = models.DateTimeField(auto_now=True) 37 | created_at = models.DateTimeField(auto_now_add=True) 38 | 39 | objects = PopulationStatManager() 40 | 41 | class Meta: 42 | app_label = "budget_app" 43 | db_table = "population_stats" 44 | 45 | def __unicode__(self): 46 | return self.year 47 | -------------------------------------------------------------------------------- /budget_app/views/budgets.py: -------------------------------------------------------------------------------- 1 | # -*- coding: UTF-8 -*- 2 | 3 | from coffin.shortcuts import render_to_response 4 | from django.conf import settings 5 | from budget_app.models import Budget, BudgetBreakdown, BudgetItem 6 | from helpers import * 7 | from properties import * 8 | 9 | 10 | def budgets(request): 11 | # Get request context 12 | c = get_context(request, css_class='body-summary', title='') 13 | 14 | # Retrieve the entity to display 15 | main_entity = get_main_entity(c) 16 | 17 | # Income/expense breakdown 18 | c['functional_breakdown'] = BudgetBreakdown(['policy', 'programme']) 19 | c['economic_breakdown'] = BudgetBreakdown(['article', 'heading']) 20 | c['chapter_breakdown'] = BudgetBreakdown(['chapter']) # Used for indicators 21 | c['include_financial_chapters'] = hasattr(settings, 'INCLUDE_FINANCIAL_CHAPTERS_IN_BREAKDOWNS') and settings.INCLUDE_FINANCIAL_CHAPTERS_IN_BREAKDOWNS 22 | for item in BudgetItem.objects.each_denormalized("e.id = %s", [main_entity.id]): 23 | column_name = year_column_name(item) 24 | c['chapter_breakdown'].add_item(column_name, item) 25 | if c['include_financial_chapters'] or not item.is_financial(): 26 | c['functional_breakdown'].add_item(column_name, item) 27 | c['economic_breakdown'].add_item(column_name, item) 28 | 29 | # Additional data needed by the view 30 | populate_stats(c) 31 | populate_descriptions(c) 32 | populate_budget_statuses(c, main_entity) 33 | populate_years(c, 'functional_breakdown') 34 | 35 | c['income_nodes'] = json.dumps(settings.OVERVIEW_INCOME_NODES) 36 | c['expense_nodes'] = json.dumps(settings.OVERVIEW_EXPENSE_NODES) 37 | 38 | c['draftBudgetYear'] = draftBudgetYear 39 | c['draftBudgetYear_2'] = draftBudgetYear_2 40 | 41 | return render_to_response('budgets/index.html', c) 42 | -------------------------------------------------------------------------------- /budget_app/static/stylesheets/bootstrap/bootstrap.less: -------------------------------------------------------------------------------- 1 | /*! 2 | * Bootstrap v2.1.0 3 | * 4 | * Copyright 2012 Twitter, Inc 5 | * Licensed under the Apache License v2.0 6 | * http://www.apache.org/licenses/LICENSE-2.0 7 | * 8 | * Designed and built with all the love in the world @twitter by @mdo and @fat. 9 | */ 10 | 11 | // CSS Reset 12 | // @import "reset.less"; 13 | 14 | // Core variables and mixins 15 | @import "variables.less"; // Modify this for custom colors, font-sizes, etc 16 | @import "mixins.less"; 17 | 18 | // Grid system and page structure 19 | // @import "scaffolding.less"; 20 | @import "grid.less"; 21 | @import "layouts.less"; 22 | @import "responsive.less"; 23 | 24 | // Base CSS 25 | /* 26 | @import "type.less"; 27 | @import "code.less"; 28 | @import "forms.less"; 29 | @import "tables.less"; 30 | */ 31 | 32 | // Components: common 33 | /* 34 | @import "sprites.less"; 35 | @import "dropdowns.less"; 36 | @import "wells.less"; 37 | @import "component-animations.less"; 38 | @import "close.less"; 39 | */ 40 | 41 | // Components: Buttons & Alerts 42 | @import "buttons.less"; 43 | @import "button-groups.less"; 44 | @import "alerts.less"; // Note: alerts share common CSS with buttons and thus have styles in buttons.less 45 | 46 | 47 | // Components: Nav 48 | /* 49 | @import "navs.less"; 50 | @import "navbar.less"; 51 | @import "breadcrumbs.less"; 52 | @import "pagination.less"; 53 | @import "pager.less"; 54 | */ 55 | 56 | // Components: Popovers 57 | @import "modals.less"; 58 | @import "tooltip.less"; 59 | @import "popovers.less"; 60 | 61 | // Components: Misc 62 | /* 63 | @import "thumbnails.less"; 64 | @import "labels-badges.less"; 65 | @import "progress-bars.less"; 66 | @import "accordion.less"; 67 | @import "carousel.less"; 68 | @import "hero-unit.less"; 69 | */ 70 | 71 | // Utility classes 72 | // @import "utilities.less"; // Has to be last to override when necessary 73 | -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | # Change Log 2 | All notable changes to this project will be documented in this file. 3 | 4 | The format is based on [Keep a Changelog](http://keepachangelog.com/) 5 | and this project adheres to [Semantic Versioning](http://semver.org/). 6 | 7 | ## [Unreleased] 8 | ### Changed 9 | - New system of error pages like 404, 500, etc. 10 | 11 | ### Added 12 | - New section with the budgets of the University of Zaragoza. 13 | 14 | ## [1.0.5] - 2017-08-17 15 | ### Added 16 | - New link to the page of Junta de Comunidades de Castilla la Mancha. 17 | 18 | 19 | ## [1.0.4] - 2017-05-22 20 | ### Added 21 | - AOD PREL Talend Process (ETL). 22 | - Talend Process documentation. 23 | - Manual of execution for developers. 24 | 25 | 26 | ## [1.0.3] - 2017-05-16 27 | ### Changed 28 | - Inflation information updated at footer section. 29 | 30 | 31 | ## [1.0.2] - 2017-04-11 32 | ### Added 33 | - New items added to the reuse section. 34 | - New counter of reused code for every section. 35 | 36 | 37 | ## [1.0.1] - 2017-04-05 38 | ### Added 39 | - New link to the page of Ayuntamiento de Madrid. 40 | 41 | 42 | ## [1.0.0] - 2017-04-04 43 | ### Added 44 | - New CHANGELOG file necessary to follow the changes of the application in the new versioning system. 45 | 46 | ### Changed 47 | - Initial version of the new versioning system of the application. 48 | 49 | 50 | [Unreleased]: https://github.com/aragonopendata/presupuesto/compare/master...develop 51 | [1.0.5]: https://github.com/aragonopendata/presupuesto/compare/v1.0.4...v1.0.5 52 | [1.0.4]: https://github.com/aragonopendata/presupuesto/compare/v1.0.3...v1.0.4 53 | [1.0.3]: https://github.com/aragonopendata/presupuesto/compare/v1.0.2...v1.0.3 54 | [1.0.2]: https://github.com/aragonopendata/presupuesto/compare/v1.0.1...v1.0.2 55 | [1.0.1]: https://github.com/aragonopendata/presupuesto/compare/v1.0.0...v1.0.1 56 | [1.0.0]: https://github.com/aragonopendata/presupuesto/releases/tag/v1.0.0 -------------------------------------------------------------------------------- /tests/spec/tax_calculator_spec.js: -------------------------------------------------------------------------------- 1 | describe("An average tax-payer", function() { 2 | var calc; 3 | var averageVATRate = 0.17657172; // Calculated by hand with Excel 4 | 5 | beforeEach(function() { 6 | calc = new TaxCalculator(); 7 | }); 8 | 9 | it("pays no income tax if she has no income", function() { 10 | expect(calc.getIncomeTaxPaid(0)).toBe(0); 11 | }); 12 | 13 | it("pays nothing up to a certain minimum (3000 euros deduction)", function() { 14 | expect(calc.getIncomeTaxPaid(6000)).toBe(0); 15 | }); 16 | 17 | it("pays 24.75% in the first bracket", function() { 18 | expect(calc.getIncomeTaxPaid(14000)).toBe(14000 * 0.2475 - 3000); 19 | }); 20 | 21 | it("pays 52% in the last bracket (100K extra)", function() { 22 | var taxBefore = calc.getIncomeTaxPaid(1000000); 23 | var taxAfter = calc.getIncomeTaxPaid(1100000); 24 | expect(taxAfter-taxBefore).toBe(100000 * 0.52); 25 | }); 26 | 27 | it("pays a fixed amount in excise (tobacco, alcohol...)", function() { 28 | expect(calc.getExciseTaxPaid().toFixed(2)).toBe('1062.18'); 29 | }); 30 | 31 | it("pays no VAT if there's no consumption", function() { 32 | expect(calc.getVATPaid(0)).toBe(0); 33 | }); 34 | 35 | it("pays a constant % of the amount saved", function() { 36 | expect(calc.getVATPaid(10000).toFixed(2)).toBe(Number(averageVATRate * 10000).toFixed(2)); 37 | expect(calc.getVATPaid(200).toFixed(2)).toBe(Number(averageVATRate * 200).toFixed(2)); 38 | }); 39 | 40 | it("pays total tax made up of VAT, income tax and excise", function() { 41 | // Results calculated with Excel by hand 42 | expect(calc.getIncomeTaxPaid(26000).toFixed(2)).toBe("3870.38"); 43 | expect(calc.getVATPaid(26000-3870.38).toFixed(2)).toBe(((26000 - 3870.38) * averageVATRate).toFixed(2)); // 3448.38 44 | expect(calc.getTaxPaid(26000).total.toFixed(2)).toBe((3870.38 + calc.getExciseTaxPaid() + 3448.38).toFixed(2)); 45 | }); 46 | }); -------------------------------------------------------------------------------- /budget_app/static/stylesheets/bootstrap/tooltip.less: -------------------------------------------------------------------------------- 1 | // 2 | // Tooltips 3 | // -------------------------------------------------- 4 | 5 | 6 | // Base class 7 | .tooltip { 8 | position: absolute; 9 | z-index: @zindexTooltip; 10 | display: block; 11 | visibility: visible; 12 | padding: 5px; 13 | font-size: 11px; 14 | .opacity(0); 15 | &.in { .opacity(80); } 16 | &.top { margin-top: -3px; } 17 | &.right { margin-left: 3px; } 18 | &.bottom { margin-top: 3px; } 19 | &.left { margin-left: -3px; } 20 | } 21 | 22 | // Wrapper for the tooltip content 23 | .tooltip-inner { 24 | max-width: 200px; 25 | padding: 3px 8px; 26 | color: @tooltipColor; 27 | text-align: center; 28 | text-decoration: none; 29 | background-color: @tooltipBackground; 30 | .border-radius(4px); 31 | } 32 | 33 | // Arrows 34 | .tooltip-arrow { 35 | position: absolute; 36 | width: 0; 37 | height: 0; 38 | border-color: transparent; 39 | border-style: solid; 40 | } 41 | .tooltip { 42 | &.top .tooltip-arrow { 43 | bottom: 0; 44 | left: 50%; 45 | margin-left: -@tooltipArrowWidth; 46 | border-width: @tooltipArrowWidth @tooltipArrowWidth 0; 47 | border-top-color: @tooltipArrowColor; 48 | } 49 | &.right .tooltip-arrow { 50 | top: 50%; 51 | left: 0; 52 | margin-top: -@tooltipArrowWidth; 53 | border-width: @tooltipArrowWidth @tooltipArrowWidth @tooltipArrowWidth 0; 54 | border-right-color: @tooltipArrowColor; 55 | } 56 | &.left .tooltip-arrow { 57 | top: 50%; 58 | right: 0; 59 | margin-top: -@tooltipArrowWidth; 60 | border-width: @tooltipArrowWidth 0 @tooltipArrowWidth @tooltipArrowWidth; 61 | border-left-color: @tooltipArrowColor; 62 | } 63 | &.bottom .tooltip-arrow { 64 | top: 0; 65 | left: 50%; 66 | margin-left: -@tooltipArrowWidth; 67 | border-width: 0 @tooltipArrowWidth @tooltipArrowWidth; 68 | border-bottom-color: @tooltipArrowColor; 69 | } 70 | } 71 | -------------------------------------------------------------------------------- /budget_app/loaders/stat_loader.py: -------------------------------------------------------------------------------- 1 | # -*- coding: UTF-8 -*- 2 | from budget_app.models import InflationStat, PopulationStat, Entity 3 | import csv 4 | import re 5 | import os.path 6 | 7 | 8 | class StatLoader: 9 | def load(self, path): 10 | self._delete_all() 11 | self.load_inflation(os.path.join(path, 'inflacion.csv')) 12 | self.load_population(os.path.join(path, 'poblacion.csv')) 13 | 14 | def load_inflation(self, filename): 15 | print "Cargando estadísticas oficiales de inflación de %s..." % filename 16 | reader = csv.reader(open(filename, 'rb')) 17 | for index, line in enumerate(reader): 18 | if re.match("^#", line[0]): # Ignore comments 19 | continue 20 | 21 | print " Cargando inflación para el año %s..." % line[0] 22 | stat = InflationStat(year=line[0], inflation=line[1]) 23 | stat.save() 24 | 25 | def load_population(self, filename): 26 | print "Cargando estadísticas oficiales de población de %s..." % filename 27 | reader = csv.reader(open(filename, 'rb')) 28 | for index, line in enumerate(reader): 29 | if re.match("^#", line[0]): # Ignore comments 30 | continue 31 | 32 | code = line[0] 33 | name = line[1] 34 | year = line[2] 35 | population = line[3] 36 | 37 | print " Cargando población para %s (%s)..." % (name, year) 38 | entity = self._get_entity(code, name) 39 | stat = PopulationStat(entity=entity, year=year, population=population) 40 | stat.save() 41 | 42 | def _delete_all(self): 43 | InflationStat.objects.all().delete() 44 | PopulationStat.objects.all().delete() 45 | 46 | def _get_entity(self, code, name): 47 | entity = Entity.objects.filter(code=code) 48 | if not entity: 49 | raise Exception("Entity (%s/%s) not found" % (code, name)) 50 | return entity[0] 51 | -------------------------------------------------------------------------------- /django_jasmine/views.py: -------------------------------------------------------------------------------- 1 | import logging 2 | import os 3 | 4 | import django 5 | from django.conf import settings 6 | from django.shortcuts import render_to_response 7 | from django.template import RequestContext 8 | 9 | if django.VERSION >= (1, 5): 10 | import json as simplejson 11 | else: 12 | from django.utils import simplejson 13 | 14 | logger = logging.getLogger("django_jasmine") 15 | 16 | 17 | def run_tests(request, path): 18 | """Run the jasmine tests and render index.html""" 19 | root = os.path.join(settings.JASMINE_TEST_DIRECTORY, path) 20 | # Get all files in spec dir and subdirs 21 | all_files = [] 22 | for curpath, dirs, files in os.walk(os.path.join(root, "spec")): 23 | for name in files: 24 | if not name.startswith("."): 25 | "We want to avoid .file.js.swp and co" 26 | curpath = curpath.replace(os.path.join(root, "spec"), "") 27 | all_files.append(os.path.join(curpath, name)) 28 | 29 | suite = {} 30 | 31 | # defaults 32 | suite['js_files'] = [] 33 | suite['static_files'] = [] 34 | 35 | # load files.json if present 36 | if os.path.exists(os.path.join(root, "files.json")): 37 | file = open(os.path.join(root, 'files.json'), 'r') 38 | json = file.read() 39 | try: 40 | json = simplejson.loads(json) 41 | except ValueError: 42 | logger.info("You might have a syntax error in your files.json, " 43 | "like a surplus comma") 44 | # Trick to call back the django handler500, couldn't find a way to 45 | # customize the Exception Type field in the debug Traceback 46 | json = simplejson.loads(json) 47 | suite.update(json) 48 | 49 | data = { 50 | 'files': [path + file for file in all_files if file.endswith('js')], 51 | 'suite': suite, 52 | } 53 | 54 | return render_to_response('jasmine/index.html', data, 55 | context_instance=RequestContext(request)) 56 | -------------------------------------------------------------------------------- /django_jasmine/templates/jasmine/base.html: -------------------------------------------------------------------------------- 1 | {% load url from future %} 2 | 3 | 4 | 5 | 6 |{{ _('Nota') }}
13 |