Julian Herrero
1ba50c76c4
Use method from Globalizable module
...
Since we have a method defined inside the Globalizable
module we don't need to create the same method in every model
2019-02-13 13:35:09 +01:00
Julian Herrero
922600252c
Make budget headings translatable
2019-02-13 13:35:07 +01:00
Julian Herrero
1c35ec99c1
Make budget groups translatable
2019-02-13 12:30:37 +01:00
Julian Herrero
90d0a6e416
Make budget phases translatable
2019-02-13 11:44:56 +01:00
Julian Herrero
d76782f150
Make budgets translatable
2019-02-13 11:41:58 +01:00
Julian Herrero
5f4a369606
Deleting a booth shift with recounts or partial results.
...
Show a flash message that it's not possible to delete booth shifts
when they have associated recounts or partial results. Before an
execption was raised.
2019-02-12 18:59:51 +01:00
decabeza
6b62ba0e91
Show cached_votes_score on admin legislation proposals
2019-02-12 18:42:44 +01:00
decabeza
0ae1cdfc8c
Replace total votes to cached_votes_score on legislation proposals
...
This show votes_score as result of votes_up minus votes_down
2019-02-12 18:42:41 +01:00
decabeza
4e4804e180
Replace total votes to cached_votes_score on debates
...
This show votes_score as result of votes_up minus votes_down
2019-02-12 18:42:35 +01:00
decabeza
73a0f999ad
Add order to voted headings names
2019-02-12 17:19:36 +01:00
voodoorai2000
f4b8099703
Simplify sql query
2019-02-12 17:18:38 +01:00
Marko Lovic
264c4e747b
Improve User#headings_supported_within_group performance
...
Performs a single DB call instead of 3
2019-02-12 17:16:49 +01:00
Marko Lovic
e47cbe2a10
Extract "supported headings" logic to User method
...
In preparation to use this method from views where
it doesn't make sense for it to be associated with
a specific investment.
2019-02-12 17:16:29 +01:00
Alberto
f9b18667e6
Merge pull request #3280 from consul/next-filters
...
[Backport] Removes next/incoming filters
2019-02-11 20:43:09 +01:00
taitus
9fac661f0c
Create scope by_proposal
...
Add to active_for class method and to active_resources controller method the new scope by_proposal.
- Published proposal: display all actions.
- Draft proposal: only display actions for draft proposals.
2019-02-10 00:18:50 +01:00
decabeza
060a4c684f
Remove legislation processes next filter
2019-02-08 14:29:43 +01:00
decabeza
bc1679550b
Remove incoming polls filter
2019-02-08 14:28:19 +01:00
Julian Herrero
54e59a8a58
LegacyLegislation migration cleanup
...
These legacy models are not used anymore.
2019-02-06 17:07:38 +01:00
decabeza
eb169ca435
Add models tag spec with 160 chars
2019-02-05 17:41:00 +01:00
decabeza
5409db6c55
Show only selected investments on map from publishing prices phase
...
If there are no selected investements show all investments on map.
2019-02-05 14:01:27 +01:00
taitus
054bbc5d7b
Allow zip, png and jpeg on dashboard action.
2019-02-02 15:30:33 +01:00
Alberto
9475a0c6ee
Merge pull request #3249 from consul/custom-pages
...
Refactor processes header colors and custom pages
2019-01-30 20:05:20 +01:00
Julian Nicolas Herrero
0e9fd645e8
Merge pull request #3234 from consul/use_find_instead_of_find_by_id
...
[Backport] Use find instead of find_by_id
2019-01-30 19:46:22 +01:00
decabeza
483182ceed
Refactor scopes on site customization page model
2019-01-30 18:03:58 +01:00
decabeza
41f9ef167d
Refactor hexadecimal color validation
2019-01-30 13:17:04 +01:00
decabeza
2695e19e2f
Fix hound warnings
2019-01-29 17:54:02 +01:00
Julian Nicolas Herrero
81b65ec821
Merge pull request #3202 from consul/sort_legislation_processes_by_start_date
...
Sort Legislation Processes by descending start date
2019-01-29 17:30:02 +01:00
Alberto
41fe1e3922
Merge pull request #3152 from NahiaSolutions/add_image_to_legislation_processes
...
Add image to legislation processes and banner colors
2019-01-29 16:06:54 +01:00
Alberto
ebe5bf13e7
Merge pull request #3149 from NahiaSolutions/add_cards_to_custom_pages
...
Add cards to custom pages
2019-01-29 16:05:47 +01:00
Alberto
78479ff0e7
Merge pull request #3228 from consul/milestones_public_progress_bar
...
[Backport] Add progress bars to milestones public view
2019-01-29 14:12:08 +01:00
Alberto
bd4826b25e
Merge branch 'master' into add_cards_to_custom_pages
2019-01-28 14:49:39 +01:00
Alberto
c297595e49
Merge branch 'master' into add_image_to_legislation_processes
2019-01-28 14:49:19 +01:00
Julian Herrero
3bf2fa1b17
Add method find_by_slug_or_id to Sluggable module
...
Make it easier to find by slug or id for sluggable models. Will return
nil if resource is not found.
2019-01-25 09:08:28 +01:00
Julian Herrero
8f112cf37e
Allow admins delete poll answer documents
2019-01-24 19:19:04 +01:00
Javi Martín
e73f3bd97a
Add progress bars to milestones public view
2019-01-24 17:33:34 +01:00
decabeza
045c4eca64
Allow change map image from admin site customization
...
Also adds on site customization image.rb jpeg content type to allow replace this image.
2019-01-24 14:55:01 +01:00
Julian Herrero
33d6f6c18d
Sort Legislation Processes by descending start date
2019-01-22 18:51:22 +01:00
Manu
b462b7131e
validations were added for the process banner
2019-01-21 12:02:27 -05:00
Manu
bd4e12112d
Add image to legislation processes and banner colors
2019-01-21 12:02:27 -05:00
Javi Martín
2926e4e375
Fix managing widget cards for homepage
...
The condition `params[:page_id] != 0` didn't work properly when editing
the homepage because in that case the parameter was `nil`, and the line
`SiteCustomization::Page.find(@card.site_customization_page_id)` raised
an exception because it couldn't find a page with a `nil` ID.
Fixing the issue while maintaining the check against `0` lead to complex
code, and so allowing `nil` in the database and assuming cards with no
`site_customization_page_id` belonged in the homepage seemed to be the
easiest solution.
2019-01-21 10:40:14 -05:00
Manu
5627d2cf23
added associations between cards and pages models
2019-01-18 09:54:43 -05:00
Manu
2dd953bdfd
added hound corrections and removed wrong tables form the schema.rb
2019-01-18 09:54:43 -05:00
Manu
722a431b54
Add cards to custom pages
2019-01-18 09:54:43 -05:00
Javi Martín
eaea95ccfb
Add progress bar model
2019-01-18 14:17:12 +01:00
decabeza
73637de0d0
Adds homepage phase and tab to legislation processes show
2019-01-15 16:13:38 +01:00
Javi Martín
f8e9566699
Simplify return statement
...
Just the way is usually done in the rest of the code.
2019-01-10 16:11:51 +01:00
Javi Martín
d5d800f75c
Simplify SORTING_OPTIONS usage
...
Using a hash instead of an array of hashes makes accessing its keys and
values much easier.
2019-01-10 16:11:51 +01:00
Anna Anks Nowak
e88acb8905
Make params handling case insensitive
2019-01-10 16:11:51 +01:00
Anna Anks Nowak
e264490bca
Styling and refactor sorting methods and helpers
2019-01-10 16:11:51 +01:00
Anna Anks Nowak
3ab70ff0d8
Move validating params to model
2019-01-10 16:11:51 +01:00