Skip to content

Instantly share code, notes, and snippets.

@fivetwentysix
Created October 6, 2011 10:07
Show Gist options
  • Save fivetwentysix/1267038 to your computer and use it in GitHub Desktop.
Save fivetwentysix/1267038 to your computer and use it in GitHub Desktop.
WARNING: Can't mass-assign protected attributes: weekday, starting_time, closing_time
class WorkDay < ActiveRecord::Base
belongs_to :employment_datum
default_scope :order => "weekday ASC"
attr_accessor :starting_time
attr_accessor :closing_time
attr_accessible [:starting_time, :closing_time, :weekday, :work_days_attributes]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment