bugfix caching p_product_cat_id

This commit is contained in:
Barnabé 2021-10-19 19:01:02 +02:00
parent 4f799af47a
commit e2e6ff305b

View File

@ -41,7 +41,7 @@ class PProductRef < ApplicationRecord
acts_as_sorting :fields => {
:id => {:name => "Id", :reorder => true},
:p_product_cat => {:name => "Catégorie", :reorder => true},
:p_product_cat => {:name => "Catégorie", :reorder => true, :sort_name => "cc_p_product_cat_id",},
:ref => {:name => "Référence"},
:cc_name => {:name => "Produit"},
# :description => {:name => "Description"},
@ -54,7 +54,7 @@ class PProductRef < ApplicationRecord
:actions => {:name => "Actions", :reorder => false}
}
acts_as_caching :fields => [:sorecop, :deee, :name, :code]
acts_as_caching :fields => [:sorecop, :deee, :name, :code, :p_product_cat_id]
include PgSearch::Model
pg_search_scope :global_search,
against: [:ref, :cc_name],