Sha256: d1284d81cb2cd610922fad8f7673b520922c52e0a38cb27fd7f75e068ccec6ad

Contents?: true

Size: 1.68 KB

Versions: 12

Compression:

Stored size: 1.68 KB

Contents

<%= render :partial => "/tr8n/admin/common/header" %>
<%= render :partial => "tabs" %>
<%= tr8n_will_filter(@comments) %>

<%= form_tag("", :id => "comments_form") do %>
  <%= will_filter_table_tag(@comments, :columns => [
    [:checkbox, :comments],    
    [:language_id, lambda{|comment|
      if comment.language
        link_to(comment.language.english_name, :controller => "/tr8n/admin/language", :action => :view, :lang_id => comment.language.id)
      else
         "Deleted Language"    
      end  
    }], 
    [:translator_id, lambda{|comment|
      if comment.translator
        link_to(comment.translator.name, :controller => "/tr8n/admin/translator", :action => :view, :translator_id => comment.translator.id) 
      else
         "Deleted Translator"    
      end  
    }], 
    [:translation_key_id, lambda{|comment|
      html = link_to(comment.key.label[0..30], :action => :view, :key_id => comment.key.id)
      html << "..." if comment.key.label.length > 30
      html
    }], 
    [:message, lambda{|comment|
      comment.toHTML
    }], :created_at,
    [:actions, lambda{|comment|
      link_to("Delete", {:action => :delete_comment, :comment_id => comment.id}, {:confirm => "Are you sure you want to delete this comment?"})
    }]
  ]) %>
<% end %>

<%= will_filter_actions_bar_tag(@comments, [
  ['Delete Selected Comments', 'deleteSelectedComments()'] 
]) %>

<%= render :partial => "/tr8n/admin/common/footer" %>

<script>
  function deleteSelectedComments() {
    if (!confirm('Are you sure you want to run this opperation?'))
       return;
    Tr8n.element('comments_form').action = "/tr8n/admin/translation_key/delete_comment";
    Tr8n.element('comments_form').submit();
  }
</script>

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
tr8n-3.2.3 app/views/tr8n/admin/translation_key/comments.html.erb
tr8n-3.2.2 app/views/tr8n/admin/translation_key/comments.html.erb
tr8n-3.2.1 app/views/tr8n/admin/translation_key/comments.html.erb
tr8n-3.2.0 app/views/tr8n/admin/translation_key/comments.html.erb
tr8n-3.1.8 app/views/tr8n/admin/translation_key/comments.html.erb
tr8n-3.1.7 app/views/tr8n/admin/translation_key/comments.html.erb
tr8n-3.1.6 app/views/tr8n/admin/translation_key/comments.html.erb
tr8n-3.1.5 app/views/tr8n/admin/translation_key/comments.html.erb
tr8n-3.1.4 app/views/tr8n/admin/translation_key/comments.html.erb
tr8n-3.1.3 app/views/tr8n/admin/translation_key/comments.html.erb
tr8n-3.1.2 app/views/tr8n/admin/translation_key/comments.html.erb
tr8n-3.1.1 app/views/tr8n/admin/translation_key/comments.html.erb