Add & Display Flights

This commit is contained in:
2022-01-15 16:05:31 -05:00
parent 796a070af4
commit 022b63fc1a
26 changed files with 395 additions and 0 deletions

12
app/models/aircraft.rb Normal file
View File

@@ -0,0 +1,12 @@
class Aircraft < ApplicationRecord
has_one :inspection
has_many :engine
has_many :flights
validates :reg, presence: true
validates :serial, presence: true
def to_s
return reg
end
end