This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'bundler' | |
Bundler.require | |
require 'sqlite3' | |
require 'sinatra/activerecord' | |
require 'active_record' | |
require 'rake' | |
require 'time' | |
require 'date' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Monitor < ActiveRecord::Base | |
has_many :calibrations | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class AddMonitors < ActiveRecord::Migration | |
def change | |
create_table :monitors do |t| | |
t.string :tag | |
t.timestamps null: false | |
has_many :calibrations | |
end | |
end |