category fix
This commit is contained in:
parent
96955d968e
commit
6ec3bd1892
|
@ -28,6 +28,8 @@ class FaqsController < ApplicationController
|
|||
|
||||
url_to_edit = OrbitHelper.user_can_edit?(faq) ? "/admin/faqs/#{faq.id.to_s}/edit" : ""
|
||||
|
||||
return {} if (faq.category.disable rescue false)
|
||||
|
||||
faqs_files = faq.qa_files.collect do |f|
|
||||
{
|
||||
"file_url" => f.file.url,
|
||||
|
|
|
@ -10,7 +10,12 @@
|
|||
<% @qas.each do |qa| %>
|
||||
<tr>
|
||||
<td><%= qa.status_for_table %></td>
|
||||
<td><%= qa.category.title %></td>
|
||||
<td>
|
||||
<%= qa.category.title rescue "" %>
|
||||
<% if (qa.category.disable rescue false) %>
|
||||
<span class='label'><%= t(:disabled) %></span>
|
||||
<% end %>
|
||||
</td>
|
||||
<td>
|
||||
<a href="#" target="_blank"><%= qa.title %></a>
|
||||
<div class="quick-edit">
|
||||
|
|
Loading…
Reference in New Issue