diff --git a/app/models/customer.rb b/app/models/customer.rb index e5dfb668..4e25c9bc 100644 --- a/app/models/customer.rb +++ b/app/models/customer.rb @@ -64,7 +64,7 @@ class Customer < ApplicationRecord def self.search(search) if search # find(:all, :conditions => ['name LIKE ? OR contact_no LIKE ?', "%#{search}%", "%#{search}%"]) - where("name LIKE ? OR contact_no LIKE ? OR card_no LIKE ?", "%#{search}%", "%#{search}%",) + where("name LIKE ? OR contact_no LIKE ? OR card_no LIKE ?", "%#{search}%", "%#{search}%", "%#{search}%",) else find(:all) end