venue_management/app/models/venue_management_memorabili...

19 lines
513 B
Ruby
Raw Normal View History

2020-07-30 14:28:57 +00:00
# frozen_string_literal: true
require 'orbit_form_helper'
class VenueManagementMemorabilia
include Mongoid::Document
include Mongoid::Timestamps
include Mongoid::Enum
field :event_date, type: Date, default: Time.now
field :case_no, type: String
field :details, localize: true
belongs_to :venue_management_main
has_many :venue_management_links, :as => :venue_object, :autosave => true, :dependent => :destroy
accepts_nested_attributes_for :venue_management_links, :allow_destroy => true
end