Add meetings to process and process group home#2713
Conversation
ab5a319 to
200385f
Compare
Codecov Report
@@ Coverage Diff @@
## master #2713 +/- ##
==========================================
+ Coverage 98.86% 98.86% +<.01%
==========================================
Files 1548 1552 +4
Lines 36675 36776 +101
==========================================
+ Hits 36258 36359 +101
Misses 417 417 |
| <%= translated_attribute meeting.title %> | ||
| </h6> | ||
| <span class="text-medium"> | ||
| <%= l meeting.start_time, format: "%d" %> <%= l meeting.start_time, format: "%B %Y" %> - |
There was a problem hiding this comment.
Format should be delegated to i18n files, you cna add your own format there and link the name here:
http://guides.rubyonrails.org/i18n.html#adding-date-time-formats
| </h6> | ||
| <span class="text-medium"> | ||
| <%= l meeting.start_time, format: "%d" %> <%= l meeting.start_time, format: "%B %Y" %> - | ||
| <%= meeting.start_time.strftime("%H:%M") %> - <%= meeting.end_time.strftime("%H:%M") %> |
There was a problem hiding this comment.
Same here about the formats:
http://guides.rubyonrails.org/i18n.html#adding-date-time-formats
josepjaume
left a comment
There was a problem hiding this comment.
Really good job! Check my comments - I think it should be possible to generalize this outside of the participatory processes.
|
|
||
| initializer "decidim_meetings.view_hooks" do | ||
| if defined? Decidim::ParticipatoryProcesses | ||
| Decidim::ParticipatoryProcesses.view_hooks.register(:process_highlighted_elements, priority: Decidim::ViewHooks::HIGH_PRIORITY) do |view_context| |
There was a problem hiding this comment.
Since this is something that probably most participatory spaces will want, what do you think about generalizing this hook so it can be used by any participatory process? Something like participatory_space_highlighted_elements. Then each participatory space can choose whether to render it on its templates or not.
There was a problem hiding this comment.
I guess you can add this view hook to decidim-core instead of just decidim-participatory_processes so everyone can benefit from it. Then, from the preocess view, render the view hook from core 😄
|
@mrcasals @josepjaume can you check if everything is correct now? |
|
I have a question about the change log entry! I need to add two entries, right? One to the participatory processes and another to the meetings, correct? |
|
Hi, I hope not to be late on this. It is not a big issue but "upcoming events" is a much higher value information than "documents" or "related photos" for the process home page. Is it possible to change the order? If this is going to make the PR take considerably longer don't worry. |
|
I already have the If you want, I can change the order and render the view hooks before documents. |
|
@rbngzlv okay for me. Maybe we can move all that to view hooks at some point? |
776327b to
85840bd
Compare
|
@josepjaume Done! @decidim/lot-core It is ready for a second review! |
|
@decidim/lot-core sorry for ping, but I need to also add |
josepjaume
left a comment
There was a problem hiding this comment.
Oh, sorry! I was definitely blocking this. Looks nice the way it is - let's merge this now!
|
Thanks @josepjaume ! |
|
Thank you for your patience! |
🎩 What? Why?
Show past/upcoming meetings in process/process group home
📌 Related Issues
📋 Subtasks
CHANGELOGentry📷 Screenshots