mirror of
https://github.com/fspc/bike-database.git
synced 2026-09-16 08:31:39 -04:00
Louis | Adds page for available freecyclery bikes
This commit is contained in:
@@ -23,4 +23,8 @@ class Bike < ActiveRecord::Base
|
||||
Bike.all.select{|bike| bike.ready_for_pickup?}
|
||||
end
|
||||
|
||||
def self.available_for_freecyclery
|
||||
Bike.all.select{|bike| bike.completion_date && (bike.purpose == "Freecyclery") && !bike.client }
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user