项目问题动态回复功能修复
This commit is contained in:
parent
9e7ce0fd6a
commit
c76db2cb24
|
@ -32,8 +32,8 @@
|
|||
<span class="reply_praise_count_<%= comment.id %>">
|
||||
<%= render :partial => "praise_tread/praise", :locals => {:activity => comment, :user_activity_id => comment.id, :type => "reply"} %>
|
||||
</span>
|
||||
|
||||
<span style="position: relative" class="fr mr20">
|
||||
<% if activity.class.to_s == 'TrainingTask' %>
|
||||
<%= link_to(l(:button_reply),
|
||||
{:controller => 'users',
|
||||
:action => 'reply_to',
|
||||
|
@ -45,23 +45,51 @@
|
|||
:remote => true,
|
||||
:method => 'get',
|
||||
:title => l(:button_reply)) %>
|
||||
<% else %>
|
||||
<%= link_to(l(:button_reply),
|
||||
{:controller => 'users',
|
||||
:action => 'reply_to',
|
||||
:reply_id => comment.id,
|
||||
:type => 'Issue',
|
||||
:user_activity_id => user_activity_id,
|
||||
:activity_id => activity.id, :is_project => true},
|
||||
:remote => true,
|
||||
:method => 'get',
|
||||
:title => l(:button_reply)) %>
|
||||
|
||||
<% end %>
|
||||
<span id="reply_iconup_<%= comment.id %>" class="reply_iconup02" style="display: none"> ︿</span>
|
||||
</span>
|
||||
<%= link_to(l(:button_delete),
|
||||
{:controller => 'training_tasks',
|
||||
:action => 'delete_journal',
|
||||
:id => activity.id,
|
||||
:journal_id=>comment.id,
|
||||
:user_activity_id => user_activity_id,
|
||||
:is_project => true},
|
||||
:method => 'get',
|
||||
:confirm => l(:text_are_you_sure),
|
||||
:remote=>true,
|
||||
:id => "delete_reply_#{activity.id}_#{comment.id}",
|
||||
:class => 'fr mr20 undis',
|
||||
:title => l(:button_delete)
|
||||
) if comment.user_id == User.current.id %>
|
||||
|
||||
<% if activity.class.to_s == 'TrainingTask' %>
|
||||
<%= link_to(l(:button_delete),
|
||||
{:controller => 'training_tasks',
|
||||
:action => 'delete_journal',
|
||||
:id => activity.id,
|
||||
:journal_id=>comment.id,
|
||||
:user_activity_id => user_activity_id,
|
||||
:is_project => true},
|
||||
:method => 'get',
|
||||
:confirm => l(:text_are_you_sure),
|
||||
:remote=>true,
|
||||
:id => "delete_reply_#{activity.id}_#{comment.id}",
|
||||
:class => 'fr mr20 undis',
|
||||
:title => l(:button_delete)) if comment.user_id == User.current.id %>
|
||||
<% else %>
|
||||
<%= link_to(
|
||||
l(:button_delete),
|
||||
{:controller => 'issues',
|
||||
:action => 'delete_journal',
|
||||
:id => activity.id,
|
||||
:journal_id=>comment.id,
|
||||
:user_activity_id => user_activity_id,
|
||||
:is_project => true},
|
||||
:method => 'get',
|
||||
:confirm => l(:text_are_you_sure),
|
||||
:remote=>true,
|
||||
:id => "delete_reply_#{activity.id}_#{comment.id}",
|
||||
:class => 'fr mr20 undis',
|
||||
:title => l(:button_delete)) if comment.user_id == User.current.id %>
|
||||
<% end %>
|
||||
</span>
|
||||
<div class="cl"></div>
|
||||
</div>
|
||||
|
@ -79,7 +107,7 @@
|
|||
<div class="reply-content mb10">
|
||||
<% if User.current.logged? %>
|
||||
<div nhname='new_message_<%= user_activity_id %>' style="display:none;">
|
||||
<%= form_for('new_form', :url => add_journal_training_task_path(activity.id, :user_activity_id => user_activity_id, :is_project => true), :method => "post", :remote => true) do |f| %>
|
||||
<%= form_for('new_form', :url => (activity.class.to_s == 'TrainingTask' ? add_journal_training_task_path(activity.id, :user_activity_id => user_activity_id, :is_project => true) : add_journal_issue_path(activity.id, :user_activity_id => user_activity_id, :is_project => true) ), :method => "post", :remote => true) do |f| %>
|
||||
<input type="hidden" name="user_activity_id" value="<%= user_activity_id %>">
|
||||
<div nhname='toolbar_container_<%= user_activity_id %>'></div>
|
||||
<textarea placeholder="有问题或有建议,请直接给我留言吧!" style="display: none" nhname='new_message_textarea_<%= user_activity_id %>' name="notes"></textarea>
|
||||
|
|
Loading…
Reference in New Issue