2014-11-04 18:30:45 +08:00
|
|
|
<% reply_allow = JournalsForMessage.create_by_user? User.current %>
|
|
|
|
<% if journals.size > 0 %>
|
|
|
|
<% for journal in journals %>
|
|
|
|
<div class="ping_C" id='word_li_<%= journal.id.to_s %>'>
|
2014-12-24 09:30:45 +08:00
|
|
|
<div class="ping_dispic">
|
2015-03-26 17:41:25 +08:00
|
|
|
<%= link_to image_tag(url_to_avatar(journal.user),:width => '46',:height => '46'), user_path(journal.user) %>
|
2014-12-24 09:30:45 +08:00
|
|
|
</div>
|
2015-04-10 17:36:21 +08:00
|
|
|
<div class="ping_discon upload_img" style="width: 610px;">
|
2014-11-04 18:30:45 +08:00
|
|
|
<div class="ping_distop">
|
|
|
|
<!-- <a style=" font-weight:bold; color:#15bccf; margin-right:30px; background:none;" target="_blank" href="#">gugu01</a> -->
|
2014-12-24 09:30:45 +08:00
|
|
|
<span>
|
2015-07-03 15:20:53 +08:00
|
|
|
<%= link_to "#{journal.user.show_name}(#{journal.user.login})", user_path(journal.user),:class => 'c_blue fb fl mb10', :target => "_blank"%>
|
2014-12-24 09:30:45 +08:00
|
|
|
</span>
|
2015-03-26 17:41:25 +08:00
|
|
|
<span class="c_grey fr">
|
2014-12-24 09:30:45 +08:00
|
|
|
<%= format_time(journal.created_on) %>
|
|
|
|
</span>
|
2014-11-04 18:30:45 +08:00
|
|
|
<div class="cl"></div>
|
2015-04-10 17:36:21 +08:00
|
|
|
<p>
|
2015-04-08 17:58:53 +08:00
|
|
|
<%= journal.notes.html_safe %>
|
2014-12-24 09:30:45 +08:00
|
|
|
</p>
|
2015-06-26 16:27:55 +08:00
|
|
|
<div class="cl"></div>
|
2014-11-04 18:30:45 +08:00
|
|
|
</div>
|
|
|
|
<div class="ping_disfoot">
|
|
|
|
<% ids = 'project_respond_form_'+ journal.id.to_s%>
|
2015-03-24 19:51:03 +08:00
|
|
|
|
2014-12-24 09:30:45 +08:00
|
|
|
<% if journal.user == User.current|| User.current.admin? || (@course && User.current.allowed_to?(:as_teacher,@course)) %>
|
2014-11-04 18:30:45 +08:00
|
|
|
<%= link_to(l(:label_bid_respond_delete),
|
|
|
|
{:controller => 'words', :action => 'destroy', :object_id => journal, :user_id => @user},
|
|
|
|
:remote => true, :confirm => l(:text_are_you_sure), :method => 'delete',
|
|
|
|
:class => "delete", :title => l(:button_delete)) %>
|
|
|
|
<% end %>
|
|
|
|
<% if reply_allow %>
|
2015-06-12 16:31:29 +08:00
|
|
|
<%#= link_to l(:label_bid_respond_quote),'',
|
2015-06-11 16:24:09 +08:00
|
|
|
{:focus => 'project_respond',:nhname=>"reply_btn", :onclick => "toggleAndSettingWordsVal($('##{ids}'), $('##{ids} textarea')); $('##{ids} textarea') ;return false;"} %>
|
2015-06-12 16:31:29 +08:00
|
|
|
<%= link_to l(:label_bid_respond_quote),'javascript:;',{:nhname=>"reply_btn"} %>
|
2014-11-04 18:30:45 +08:00
|
|
|
<% end %>
|
|
|
|
</div>
|
2015-03-24 19:51:03 +08:00
|
|
|
<div class="cl"></div>
|
2014-11-04 18:30:45 +08:00
|
|
|
<% ids = 'project_respond_form_'+ journal.id.to_s%>
|
|
|
|
<% if reply_allow %>
|
|
|
|
<div id='<%= ids %>' class="respond-form">
|
2015-03-24 20:15:14 +08:00
|
|
|
<%= render :partial => 'words/new_respond_course', :locals => {:journal => journal, :m_reply_id => journal,:show_name => true} %>
|
2014-11-04 18:30:45 +08:00
|
|
|
</div>
|
|
|
|
<% end %>
|
2015-03-24 19:51:03 +08:00
|
|
|
<div class="cl"></div>
|
|
|
|
|
|
|
|
<%= render :partial => "words/journal_reply", :locals => {:journal => journal, :show_name => true, :allow_delete => @course && User.current.allowed_to?(:as_teacher,@course)} %>
|
|
|
|
|
2014-11-04 18:30:45 +08:00
|
|
|
</div>
|
|
|
|
<div class="cl"></div>
|
|
|
|
</div>
|
|
|
|
<% end %>
|
|
|
|
<% end %>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|