Open jywarren opened 4 years ago
Hey @jywarren ,can i work on this?
We'd love help with this, thank you!
On Fri, Dec 27, 2019 at 7:48 AM Mansi Sharma notifications@github.com wrote:
Hey @jywarren https://github.com/jywarren ,can i work on this?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/publiclab/plots2/issues/6953?email_source=notifications&email_token=AAAF6J63CV576JVO4PLY2TTQ2X2QHA5CNFSM4JZUKJMKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHXEIRY#issuecomment-569263175, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAAF6J63CEJ5NRGOOXAQ4QTQ2X2QHANCNFSM4JZUKJMA .
Yes these rules make sense!
https://github.com/publiclab/plots2/issues/7149 should satisfy number 1 and 2 in the list. It does not check for a lead image, however, so we still need to make number 3 work!
Hey @jywaren ,sorry i was inactive form past few days can you just give me some direction to start working on this issue.
Hi @sharmamansi - sorry for the slow reply - so, we have these three conditions, and they are currently wired up in the 2 files I reference above under "CODE". But the conditions are wrong. Can you propose new logic for these templates that would rely on the values as proposed in the 3 rules above? The values are referenced as so:
lat:____
/lon:____
tags: @node.has_power_tag('lat')
place
or place:______
tags: @node.has_tag('place') || @node.has_power_tag('power')
if @node.main_image
Could you try adjusting the conditions in both plots2/app/views/sidebar/_related.html.erb
and plots2/app/views/wiki/_header.html.erb
as the rules above show, using these values? Try opening a pull request with a first attempt, and we can help you make progress. Thanks!
Thanks @jywarren I will open pr shortly.
We have an issue where pages present maps in different places, and we need to standardize a bit. This page, for example, shows 2 maps, redundantly:
https://publiclab.org/wiki/barataria-bay-mapping-project
https://publiclab.org/wiki/puerto-rico
I think the rules should be:
lat:____
/lon:____
tags should have a sidebar mapplace
orplace:______
tags (usingnode.has_power_tag()
for the latter) AND do not have a lead image, get a top-of-page map like thepuerto-rico
example above.How does this sound to folks?
Code
https://github.com/publiclab/plots2/blob/7a6d9316193e1cb5b9318aa49dca665d52c54f27/app/views/wiki/_header.html.erb#L45-L47
https://github.com/publiclab/plots2/blob/7a6d9316193e1cb5b9318aa49dca665d52c54f27/app/views/sidebar/_related.html.erb#L44-L54
Those point to these segments of code:
https://github.com/publiclab/plots2/blob/7a6d9316193e1cb5b9318aa49dca665d52c54f27/app/helpers/application_helper.rb#L93-L99