languages fix

This commit is contained in:
harrybomrah committed 2018-01-19 17:07:33 +08:00
1 parent 5711555db0
commit dc7cf82a95
4 files changed
+7 -5

No files matched your search

@@ -1,7 +1,7 @@
class Admin::PageContentsController < OrbitAdminController
before_action ->(module_app = @app_title) { set_variables module_app }
def index
@table_fields = [:page_id, :name,:version,:update_at,:last_modified, :category]
@table_fields = ["page_content.id", :name,:version,:update_at,:last_modified, :category]
@filter_fields = {}
if params[:sort].blank? && params[:keywords].blank?
@pages = get_pages_sorted(Page.root)
@@ -26,7 +26,7 @@
<td><%= User.find(page.page_contexts.last.update_user_id).user_name rescue nil %></td>
<td>
<% if can_edit_or_delete?(page) %>
<%= select_tag("category_id",options_for_select(@categories, (page.category_id.to_s rescue "")), prompt: "Select a category", class: "category_select", style: "margin-bottom:0; width:150px;") %>
<%= select_tag("category_id",options_for_select(@categories, (page.category_id.to_s rescue "")), prompt: t("select_category"), class: "category_select", style: "margin-bottom:0; width:150px;") %>
<button <%= !page.category_id.nil? ? "data-page-category-id=#{page.category_id.to_s}" : "" %> data-page-id="<%= page.id.to_s %>" class="btn btn-primary save_category hide">Save</button>
<% end %>
</td>