fix category heading
This commit is contained in:
parent
a339ae4c7c
commit
23b38b5a46
2 changed files with 3 additions and 3 deletions
|
@ -7,12 +7,12 @@ class ArticlesController < ApplicationController
|
|||
sort = case params['sort']
|
||||
when "name" then "articles.name"
|
||||
when "unit" then "articles.unit"
|
||||
when "category" then "article_categories.name"
|
||||
when "article_category" then "article_categories.name"
|
||||
when "note" then "articles.note"
|
||||
when "availability" then "articles.availability"
|
||||
when "name_reverse" then "articles.name DESC"
|
||||
when "unit_reverse" then "articles.unit DESC"
|
||||
when "category_reverse" then "article_categories.name DESC"
|
||||
when "article_category_reverse" then "article_categories.name DESC"
|
||||
when "note_reverse" then "articles.note DESC"
|
||||
when "availability_reverse" then "articles.availability DESC"
|
||||
end
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
%th
|
||||
%th= sort_link_helper heading_helper(Article, :name), "name"
|
||||
%th
|
||||
%th= sort_link_helper heading_helper(Article, :category), "category"
|
||||
%th= sort_link_helper heading_helper(Article, :article_category), "article_category"
|
||||
%th= sort_link_helper heading_helper(Article, :unit), "unit"
|
||||
%th= sort_link_helper heading_helper(Article, :note), "note"
|
||||
%th{:style => "width: 4em;"}= heading_helper Article, :unit_quantity, short: true
|
||||
|
|
Loading…
Reference in a new issue