plots2 icon indicating copy to clipboard operation
plots2 copied to clipboard

"make a lead page for this topic" button on tag pages

Open jywarren opened this issue 10 years ago • 3 comments

This has been marked as a good candidate for becoming a first-timers-only issue like these, meaning that it's simple, self-contained, and with some extra formatting, could be a great entry point for a new contributor. If you're familiar enough with this code, please consider reformatting or reposting it as a first-timers-only issue, and then ping @jywarren to get it labelled. Or, if this is not your first time, try to solve it yourself!


The new tag pages have a great "intro" section sourced from the first paragraph of the corresponding wiki page, as of #985:

https://publiclab.org/tag/visual-pm

screen shot 2016-11-28 at 3 12 27 pm

But if no corresponding page exists, they do not.

Solution

The code for the check is here: https://github.com/publiclab/plots2/blob/master/app/views/tag/show.html.erb#L4

we should add an else block which shows a message like:

This topic has no lead wiki page. Add one now +

which leads to /wiki/<page-name> -- that way people are prompted to make one.

jywarren avatar Nov 28 '16 20:11 jywarren

@jywarren I have made the required changes in my local. Can you help me with creating a pull request. I have created a new branch in my local for this issue. When I am trying to push that branch to your repository, it return 403 (Unauthorized) error.

manish310794 avatar Nov 29 '16 14:11 manish310794

Hmm, can you tell me the exact steps you take? Do you have your own fork?

Perhaps you have to push to: git push https://github.com/manish310794/plots2.git feature-branch-name

If you can share your exact console steps I can help out, thanks!

jywarren avatar Nov 29 '16 16:11 jywarren

Great! Closed in https://github.com/publiclab/plots2/pull/1029

jywarren avatar Nov 29 '16 19:11 jywarren