Changed behaviour of acts_as_paraniod. Finder wrapper removed an replaced by simple named_scope 'without_deleted'.
This commit is contained in:
parent
cd9636a650
commit
325d47b22f
18 changed files with 218 additions and 136 deletions
|
|
@ -20,9 +20,9 @@ class Finance::TransactionsController < ApplicationController
|
|||
|
||||
conditions = "name LIKE '%#{params[:query]}%'" unless params[:query].nil?
|
||||
|
||||
@total = Ordergroup.count(:conditions => conditions)
|
||||
@groups = Ordergroup.paginate :conditions => conditions, :page => params[:page],
|
||||
:per_page => @per_page, :order => sort
|
||||
@total = Ordergroup.without_deleted.count(:conditions => conditions)
|
||||
@groups = Ordergroup.without_deleted.paginate :conditions => conditions,
|
||||
:page => params[:page], :per_page => @per_page, :order => sort
|
||||
|
||||
respond_to do |format|
|
||||
format.html
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue