Przeglądaj źródła

model add scope

abiao 4 lat temu
rodzic
commit
cb2b5c0275
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      app/models/product.rb

+ 1 - 1
app/models/product.rb

@@ -133,7 +133,7 @@ class Product < ActiveRecord::Base
         list do
 
 
-            if current_admin_user.id==1
+            if @current_admin_user.id==1
                 scopes [:inactive]
             end