mirror of
https://github.com/rickbarrette/redmine_qbo.git
synced 2025-11-08 17:04:23 -05:00
Update vehicle.rb
This commit is contained in:
@@ -121,4 +121,9 @@ class Vehicle < ActiveRecord::Base
|
|||||||
v = self.vin[0,11]
|
v = self.vin[0,11]
|
||||||
return v.slice(0,8) + v.slice(9,11)
|
return v.slice(0,8) + v.slice(9,11)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# search for a vin
|
||||||
|
def self.search(search)
|
||||||
|
where("vin LIKE ?", "%#{search}%")
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user