取消实名回复#1622
This commit is contained in:
parent
e68900b9a0
commit
8c81346ffb
|
@ -47,7 +47,6 @@ class WordsController < ApplicationController
|
|||
# 删除留言功能要调用destroy,也记得在destroy.js中修改
|
||||
|
||||
# deny api. api useless
|
||||
@show_real_name = params[:show_real_name] || false
|
||||
parent_id = params[:reference_id]
|
||||
author_id = User.current.id
|
||||
reply_user_id = params[:reference_user_id]
|
||||
|
|
|
@ -46,7 +46,7 @@
|
|||
</div>
|
||||
<div style="clear: both;"></div>
|
||||
<div>
|
||||
<%= render :partial => "words/journal_reply", :locals => {:journal => jour,:show_name=> show_name, :show_real_name => true } %>
|
||||
<%= render :partial => "words/journal_reply", :locals => {:journal => jour,:show_name=> show_name} %>
|
||||
</div>
|
||||
</div>
|
||||
<div class="cl"></div>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
<% show_real_name ||= false %>
|
||||
<% reply_allow = JournalsForMessage.create_by_user? User.current %>
|
||||
<% ids_r = 'reply_respond_form_'+ reply.id.to_s %>
|
||||
<div class="recall" id='word_li_<%=reply.id.to_s%>' onmouseover="$('#<%= ids_r %>').show()" onmouseout="$('#<%= ids_r %>').hide()">
|
||||
|
@ -15,11 +14,7 @@
|
|||
回复
|
||||
<% parent_jour = JournalsForMessage.find reply.m_reply_id %>
|
||||
<% if show_name && parent_jour %>
|
||||
<% if show_real_name%>
|
||||
<%= link_to parent_jour.user.lastname+parent_jour.user.firstname, user_path(parent_jour.user) %>
|
||||
<% else %>
|
||||
<%= link_to parent_jour.user.name, user_path(parent_jour.user) %>
|
||||
<% end %>
|
||||
<% else %>
|
||||
<%= l(:label_anonymous) %>
|
||||
<% end %>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<% if @save_succ %>
|
||||
var pre_append = $('<%= j(
|
||||
render :partial => "journal_reply_items",
|
||||
:locals => {:reply => @jfm, :journal => @jfm.parent, :m_reply_id => @jfm, :show_real_name => true}
|
||||
:locals => {:reply => @jfm, :journal => @jfm.parent, :m_reply_id => @jfm}
|
||||
) %>').hide();
|
||||
$('#journal_reply_ul_<%=@jfm.m_parent_id%>').append(pre_append);
|
||||
pre_append.fadeIn(600);
|
||||
|
|
|
@ -1,8 +1,7 @@
|
|||
|
||||
<% id = "journal_reply_ul_" + journal.id.to_s%>
|
||||
<% show_real_name ||= false%>
|
||||
<div id = '<%= id %>' >
|
||||
<% fetch_user_leaveWord_reply(journal).each do |reply|%>
|
||||
<%= render :partial => "words/journal_reply_items", :locals => {:reply => reply, :journal => journal, :m_reply_id => reply,:show_name=> show_name, :show_real_name => show_real_name} %>
|
||||
<%= render :partial => "words/journal_reply_items", :locals => {:reply => reply, :journal => journal, :m_reply_id => reply,:show_name=> show_name} %>
|
||||
<% end %>
|
||||
</div>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
<% show_real_name ||= false %>
|
||||
<% reply_allow = JournalsForMessage.create_by_user? User.current %>
|
||||
<% ids_r = 'reply_respond_form_'+ reply.id.to_s %>
|
||||
<div class="recall" id='word_li_<%=reply.id.to_s%>' onmouseover="$('#<%= ids_r %>').show()" onmouseout="$('#<%= ids_r %>').hide()">
|
||||
|
@ -11,19 +10,11 @@
|
|||
</div>
|
||||
<div class="recall_con">
|
||||
<% id = 'project_respond_form_'+ reply.id.to_s %>
|
||||
<% if show_real_name%>
|
||||
<%= link_to reply.user.lastname+reply.user.firstname, user_path(reply.user) %>
|
||||
<% else %>
|
||||
<%= link_to reply.user.name, user_path(reply.user) %>
|
||||
<% end %>
|
||||
回复
|
||||
<% parent_jour = JournalsForMessage.find reply.m_reply_id %>
|
||||
<% if show_name && parent_jour %>
|
||||
<% if show_real_name%>
|
||||
<%= link_to parent_jour.user.lastname+parent_jour.user.firstname, user_path(parent_jour.user) %>
|
||||
<% else %>
|
||||
<%= link_to parent_jour.user.name, user_path(parent_jour.user) %>
|
||||
<% end %>
|
||||
<% else %>
|
||||
<%= l(:label_anonymous) %>
|
||||
<% end %>
|
||||
|
@ -51,7 +42,7 @@
|
|||
</div>
|
||||
<div id='<%=id%>' class="respond-form">
|
||||
<% if reply_allow %>
|
||||
<%= render :partial => "words/new_respond", :locals => {:journal => journal, :m_reply_id => m_reply_id,:show_name => show_name, :show_real_name => show_real_name} %>
|
||||
<%= render :partial => "words/new_respond", :locals => {:journal => journal, :m_reply_id => m_reply_id,:show_name => show_name} %>
|
||||
<% end %>
|
||||
</div>
|
||||
<div style="clear: both;"></div>
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
<% show_real_name ||= false%>
|
||||
<%= form_tag(words_create_reply_path(:show_real_name=>show_real_name), :remote => true) do %>
|
||||
<%= form_tag(words_create_reply_path, :remote => true) do %>
|
||||
<%= text_area_tag 'user_notes', "", :class => 'noline',
|
||||
:style => "resize: none;", :rows => 4,
|
||||
:placeholder => l(:label_projects_feedback_respond_content),
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
<% if @save_succ %>
|
||||
var pre_append = $('<%= j(
|
||||
render :partial => "words/journal_reply_items",
|
||||
:locals => {:reply => @jfm, :journal => @jfm.parent, :m_reply_id => @jfm,:show_name => @show_name, :show_real_name=>@show_real_name}
|
||||
:locals => {:reply => @jfm, :journal => @jfm.parent, :m_reply_id => @jfm,:show_name => @show_name}
|
||||
) %>').hide();
|
||||
$('#journal_reply_ul_<%=@jfm.m_parent_id%>').append(pre_append);
|
||||
pre_append.fadeIn(600);
|
||||
|
|
Loading…
Reference in New Issue