diff --git a/app/assets/stylesheets/specific/wiki_pages.css.scss b/app/assets/stylesheets/specific/wiki_pages.css.scss index 986f2f636..6c114ec19 100644 --- a/app/assets/stylesheets/specific/wiki_pages.css.scss +++ b/app/assets/stylesheets/specific/wiki_pages.css.scss @@ -3,6 +3,12 @@ div#c-wiki-pages { color: #AAA; } + div.notice { + font-size: 0.8em; + padding: 1em; + margin: 1em 0; + } + del { background: #FCC; text-decoration: none; diff --git a/app/controllers/wiki_pages_controller.rb b/app/controllers/wiki_pages_controller.rb index ba98fefe9..4213af585 100644 --- a/app/controllers/wiki_pages_controller.rb +++ b/app/controllers/wiki_pages_controller.rb @@ -32,6 +32,7 @@ class WikiPagesController < ApplicationController else @wiki_page = WikiPage.find_by_id(params[:id]) end + respond_with(@wiki_page) end diff --git a/app/views/wiki_pages/_secondary_links.html.erb b/app/views/wiki_pages/_secondary_links.html.erb index 223b63ca4..02c8f963c 100644 --- a/app/views/wiki_pages/_secondary_links.html.erb +++ b/app/views/wiki_pages/_secondary_links.html.erb @@ -3,8 +3,13 @@
  • <%= render "wiki_pages/quick_search" %>
  • <%= link_to "Listing", wiki_pages_path %>
  • <%= link_to "Search", search_wiki_pages_path %>
  • -
  • <%= link_to "New", new_wiki_page_path %>
  • + + <% if CurrentUser.is_member? %> +
  • <%= link_to "New", new_wiki_page_path %>
  • + <% end %> +
  • <%= link_to "Help", wiki_pages_path(:search => {:title => "help:wiki"}) %>
  • + <% if @wiki_page %>
  • |
  • <%= link_to "Posts (#{Post.fast_count(@wiki_page.title)})", posts_path(:tags => @wiki_page.title) %>
  • diff --git a/app/views/wiki_pages/new.html.erb b/app/views/wiki_pages/new.html.erb index 10a697a91..c81a54b15 100644 --- a/app/views/wiki_pages/new.html.erb +++ b/app/views/wiki_pages/new.html.erb @@ -4,6 +4,13 @@

    New Wiki Page

    + + <% if @wiki_page.title.present? %> +
    + This wiki page does not yet exist. The form below will allow you to create a new page for <%= @wiki_page.title %>. It will act as an explanation on how to use the tag for other users on the site. +
    + <% end %> + <%= render "form" %>