<div class="clearfix diary-comment">
<%= user_thumbnail diary_comment.user %>
- <p class="deemphasize comment-heading" id="comment<%= diary_comment.id %>"><%= raw(t('diary_entry.diary_comment.comment_from', :link_user => (link_to h(diary_comment.user.display_name), :controller => 'user', :action => 'view', :display_name => diary_comment.user.display_name), :comment_created_at => link_to(l(diary_comment.created_at, :format => :friendly), :anchor => "comment#{diary_comment.id}"))) %>
- <p class="deemphasize comment-heading" id="comment<%= diary_comment.id %>"><%= raw(t('diary_entry.diary_comment.comment_from', :link_user => (link_to h(diary_comment.user.display_name), user_path(diary_comment.user)), :comment_created_at => link_to(l(diary_comment.created_at, :format => :friendly), :anchor => "comment#{diary_comment.id}"))) %></p>
++ <p class="deemphasize comment-heading" id="comment<%= diary_comment.id %>"><%= raw(t('diary_entry.diary_comment.comment_from', :link_user => (link_to h(diary_comment.user.display_name), user_path(diary_comment.user)), :comment_created_at => link_to(l(diary_comment.created_at, :format => :friendly), :anchor => "comment#{diary_comment.id}"))) %>
+ <% if current_user and diary_comment.user.id != current_user.id %>
+ | <%= report_link(t(".report"), diary_comment) %>
+ <% end %>
+ </p>
+
<div class="richtext"><%= diary_comment.body.to_html %></div>
<%= if_administrator(:span) do %>
<%= link_to t('diary_entry.diary_comment.hide_link'), hide_diary_comment_path(:display_name => diary_comment.diary_entry.user.display_name, :id => diary_comment.diary_entry.id, :comment => diary_comment.id), :method => :post, :data=> { :confirm => t('diary_entry.diary_comment.confirm') } %>
# diary pages
match "/diary/new" => "diary_entry#new", :via => [:get, :post]
- match "/diary/friends" => "diary_entry#list", :friends => true, :via => :get, :as => "friend_diaries"
- match "/diary/nearby" => "diary_entry#list", :nearby => true, :via => :get, :as => "nearby_diaries"
- match "/user/:display_name/diary/rss" => "diary_entry#rss", :via => :get, :defaults => { :format => :rss }
- match "/diary/:language/rss" => "diary_entry#rss", :via => :get, :defaults => { :format => :rss }
- match "/diary/rss" => "diary_entry#rss", :via => :get, :defaults => { :format => :rss }
- match "/user/:display_name/diary/comments/:page" => "diary_entry#comments", :via => :get, :page => /[1-9][0-9]*/
- match "/user/:display_name/diary/comments/" => "diary_entry#comments", :via => :get
- match "/user/:display_name/diary" => "diary_entry#list", :via => :get
- match "/diary/:language" => "diary_entry#list", :via => :get
- match "/diary" => "diary_entry#list", :via => :get
- match "/user/:display_name/diary/:id" => "diary_entry#view", :via => :get, :id => /\d+/, :as => :diary_entry
- match "/user/:display_name/diary/:id/newcomment" => "diary_entry#comment", :via => :post, :id => /\d+/
+ get "/diary/friends" => "diary_entry#list", :friends => true, :as => "friend_diaries"
+ get "/diary/nearby" => "diary_entry#list", :nearby => true, :as => "nearby_diaries"
+ get "/user/:display_name/diary/rss" => "diary_entry#rss", :defaults => { :format => :rss }
+ get "/diary/:language/rss" => "diary_entry#rss", :defaults => { :format => :rss }
+ get "/diary/rss" => "diary_entry#rss", :defaults => { :format => :rss }
+ get "/user/:display_name/diary/comments/:page" => "diary_entry#comments", :page => /[1-9][0-9]*/
+ get "/user/:display_name/diary/comments/" => "diary_entry#comments"
+ get "/user/:display_name/diary" => "diary_entry#list"
+ get "/diary/:language" => "diary_entry#list"
+ get "/diary" => "diary_entry#list"
- get "/user/:display_name/diary/:id" => "diary_entry#view", :id => /\d+/
++ get "/user/:display_name/diary/:id" => "diary_entry#view", :id => /\d+/, :as => :diary_entry
+ post "/user/:display_name/diary/:id/newcomment" => "diary_entry#comment", :id => /\d+/
match "/user/:display_name/diary/:id/edit" => "diary_entry#edit", :via => [:get, :post], :id => /\d+/
- match "/user/:display_name/diary/:id/hide" => "diary_entry#hide", :via => :post, :id => /\d+/, :as => :hide_diary_entry
- match "/user/:display_name/diary/:id/hidecomment/:comment" => "diary_entry#hidecomment", :via => :post, :id => /\d+/, :comment => /\d+/, :as => :hide_diary_comment
- match "/user/:display_name/diary/:id/subscribe" => "diary_entry#subscribe", :via => :post, :as => :diary_entry_subscribe, :id => /\d+/
- match "/user/:display_name/diary/:id/unsubscribe" => "diary_entry#unsubscribe", :via => :post, :as => :diary_entry_unsubscribe, :id => /\d+/
+ post "/user/:display_name/diary/:id/hide" => "diary_entry#hide", :id => /\d+/, :as => :hide_diary_entry
+ post "/user/:display_name/diary/:id/hidecomment/:comment" => "diary_entry#hidecomment", :id => /\d+/, :comment => /\d+/, :as => :hide_diary_comment
+ post "/user/:display_name/diary/:id/subscribe" => "diary_entry#subscribe", :as => :diary_entry_subscribe, :id => /\d+/
+ post "/user/:display_name/diary/:id/unsubscribe" => "diary_entry#unsubscribe", :as => :diary_entry_unsubscribe, :id => /\d+/
# user pages
- match "/user/:display_name" => "user#view", :via => :get, :as => "user"
+ get "/user/:display_name" => "user#view", :as => "user"
match "/user/:display_name/make_friend" => "user#make_friend", :via => [:get, :post], :as => "make_friend"
match "/user/:display_name/remove_friend" => "user#remove_friend", :via => [:get, :post], :as => "remove_friend"
match "/user/:display_name/account" => "user#account", :via => [:get, :post]
--
- -- Name: id; Type: DEFAULT; Schema: public; Owner: -
+ -- Name: messages id; Type: DEFAULT; Schema: public; Owner: -
--
+ALTER TABLE ONLY issue_comments ALTER COLUMN id SET DEFAULT nextval('issue_comments_id_seq'::regclass);
+
+
+--
+-- Name: id; Type: DEFAULT; Schema: public; Owner: -
+--
+
+ALTER TABLE ONLY issues ALTER COLUMN id SET DEFAULT nextval('issues_id_seq'::regclass);
+
+
+--
+-- Name: id; Type: DEFAULT; Schema: public; Owner: -
+--
+
ALTER TABLE ONLY messages ALTER COLUMN id SET DEFAULT nextval('messages_id_seq'::regclass);
--
- -- Name: id; Type: DEFAULT; Schema: public; Owner: -
+ -- Name: user_blocks id; Type: DEFAULT; Schema: public; Owner: -
--
+ALTER TABLE ONLY reports ALTER COLUMN id SET DEFAULT nextval('reports_id_seq'::regclass);
+
+
+--
+-- Name: id; Type: DEFAULT; Schema: public; Owner: -
+--
+
ALTER TABLE ONLY user_blocks ALTER COLUMN id SET DEFAULT nextval('user_blocks_id_seq'::regclass);
ADD CONSTRAINT gpx_files_pkey PRIMARY KEY (id);
+--
+-- Name: issue_comments_pkey; Type: CONSTRAINT; Schema: public; Owner: -
+--
+
+ALTER TABLE ONLY issue_comments
+ ADD CONSTRAINT issue_comments_pkey PRIMARY KEY (id);
+
+
+--
+-- Name: issues_pkey; Type: CONSTRAINT; Schema: public; Owner: -
+--
+
+ALTER TABLE ONLY issues
+ ADD CONSTRAINT issues_pkey PRIMARY KEY (id);
+
+
--
- -- Name: languages_pkey; Type: CONSTRAINT; Schema: public; Owner: -
+ -- Name: languages languages_pkey; Type: CONSTRAINT; Schema: public; Owner: -
--
ALTER TABLE ONLY languages
ADD CONSTRAINT relations_pkey PRIMARY KEY (relation_id, version);
+--
+-- Name: reports_pkey; Type: CONSTRAINT; Schema: public; Owner: -
+--
+
+ALTER TABLE ONLY reports
+ ADD CONSTRAINT reports_pkey PRIMARY KEY (id);
+
+
--
- -- Name: user_blocks_pkey; Type: CONSTRAINT; Schema: public; Owner: -
+ -- Name: user_blocks user_blocks_pkey; Type: CONSTRAINT; Schema: public; Owner: -
--
ALTER TABLE ONLY user_blocks
ADD CONSTRAINT gpx_files_user_id_fkey FOREIGN KEY (user_id) REFERENCES users(id);
+--
+-- Name: issue_comments_issue_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: -
+--
+
+ALTER TABLE ONLY issue_comments
+ ADD CONSTRAINT issue_comments_issue_id_fkey FOREIGN KEY (issue_id) REFERENCES issues(id);
+
+
+--
+-- Name: issue_comments_user_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: -
+--
+
+ALTER TABLE ONLY issue_comments
+ ADD CONSTRAINT issue_comments_user_id_fkey FOREIGN KEY (user_id) REFERENCES users(id);
+
+
+--
+-- Name: issues_reported_user_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: -
+--
+
+ALTER TABLE ONLY issues
+ ADD CONSTRAINT issues_reported_user_id_fkey FOREIGN KEY (reported_user_id) REFERENCES users(id);
+
+
+--
+-- Name: issues_resolved_by_fkey; Type: FK CONSTRAINT; Schema: public; Owner: -
+--
+
+ALTER TABLE ONLY issues
+ ADD CONSTRAINT issues_resolved_by_fkey FOREIGN KEY (resolved_by) REFERENCES users(id);
+
+
+--
+-- Name: issues_updated_by_fkey; Type: FK CONSTRAINT; Schema: public; Owner: -
+--
+
+ALTER TABLE ONLY issues
+ ADD CONSTRAINT issues_updated_by_fkey FOREIGN KEY (updated_by) REFERENCES users(id);
+
+
--
- -- Name: messages_from_user_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: -
+ -- Name: messages messages_from_user_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: -
--
ALTER TABLE ONLY messages
ADD CONSTRAINT relations_redaction_id_fkey FOREIGN KEY (redaction_id) REFERENCES redactions(id);
+--
+-- Name: reports_issue_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: -
+--
+
+ALTER TABLE ONLY reports
+ ADD CONSTRAINT reports_issue_id_fkey FOREIGN KEY (issue_id) REFERENCES issues(id);
+
+
+--
+-- Name: reports_user_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: -
+--
+
+ALTER TABLE ONLY reports
+ ADD CONSTRAINT reports_user_id_fkey FOREIGN KEY (user_id) REFERENCES users(id);
+
+
--
- -- Name: user_blocks_moderator_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: -
+ -- Name: user_blocks user_blocks_moderator_id_fkey; Type: FK CONSTRAINT; Schema: public; Owner: -
--
ALTER TABLE ONLY user_blocks
('7'),
('8'),
('9');
--
--