Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
90 commits
Select commit Hold shift + click to select a range
dddd618
Update app/models/collection.rb
sugandhaa Oct 17, 2012
73ab9d6
Update app/models/accession.rb
sugandhaa Oct 18, 2012
93a1260
Update app/models/location.rb
sugandhaa Oct 18, 2012
05973e1
Update app/models/collection_creator_relationship.rb
sugandhaa Oct 18, 2012
d1a79d9
Update app/models/collection.rb
sugandhaa Oct 18, 2012
0a38b86
Update app/models/creator.rb
sugandhaa Oct 18, 2012
33851e6
Update app/models/creator.rb
sugandhaa Oct 18, 2012
1aac6a6
Update app/models/book.rb
sugandhaa Oct 18, 2012
3663b6d
Update app/models/creator.rb
sugandhaa Oct 18, 2012
43d0af1
Update app/models/digital_content.rb
sugandhaa Oct 18, 2012
40ee7db
Update app/models/collection.rb
sugandhaa Oct 18, 2012
a10ba46
Update app/models/collection.rb
sugandhaa Oct 18, 2012
87ef58b
Update app/models/accession.rb
sugandhaa Oct 18, 2012
4e4cb5f
Update app/models/book.rb
sugandhaa Oct 18, 2012
d719d5b
Update app/models/creator.rb
sugandhaa Oct 18, 2012
972e2e5
Update app/models/digital_content.rb
sugandhaa Oct 18, 2012
ac3935d
Update app/models/location.rb
sugandhaa Oct 18, 2012
2e0cdf0
Update app/models/accession.rb
sugandhaa Oct 19, 2012
f35033b
Update app/models/book.rb
sugandhaa Oct 19, 2012
cad45f1
Update app/models/collection.rb
sugandhaa Oct 19, 2012
fc143f3
Update app/models/creator.rb
sugandhaa Oct 19, 2012
25f66f9
Update app/models/digital_content.rb
sugandhaa Oct 19, 2012
9b71e35
Update app/models/location.rb
sugandhaa Oct 19, 2012
eccf023
Update app/models/accession.rb
sugandhaa Oct 19, 2012
243c82f
Update app/models/research_appointment_material.rb
sugandhaa Oct 19, 2012
12b477a
Update app/models/research_appointment.rb
sugandhaa Oct 19, 2012
8a6ad52
Update app/models/user_field.rb
sugandhaa Oct 19, 2012
1137108
Update app/models/subject.rb
sugandhaa Oct 19, 2012
d83b830
Update app/models/research_appointment_purpose.rb
sugandhaa Oct 19, 2012
58226f6
Update app/models/research_appointment.rb
sugandhaa Oct 19, 2012
e69b75a
Update app/models/collection.rb
sugandhaa Oct 19, 2012
05ac80b
Update app/models/accession.rb
sugandhaa Nov 20, 2012
7a79ab7
Update app/models/extent_unit.rb
sugandhaa Nov 20, 2012
37a11b5
Update app/models/processing_priority.rb
sugandhaa Nov 20, 2012
b5f7998
Update app/models/accession.rb
sugandhaa Nov 20, 2012
bb12690
Update app/models/accession.rb
sugandhaa Nov 20, 2012
3d7978d
Update app/models/accession.rb
sugandhaa Nov 20, 2012
3e9c8ba
Update app/models/subject.rb
sugandhaa Nov 20, 2012
693cece
Update app/models/creator.rb
sugandhaa Nov 20, 2012
c802164
Update app/models/creator.rb
sugandhaa Nov 20, 2012
503f9a7
Update app/models/subject.rb
sugandhaa Nov 20, 2012
f2904f9
Update app/models/collection.rb
sugandhaa Nov 20, 2012
6824d5d
Update app/models/collection.rb
sugandhaa Nov 20, 2012
0d93b87
Update app/models/classification.rb
sugandhaa Nov 20, 2012
53e166d
Update app/models/classification.rb
sugandhaa Nov 20, 2012
96627f8
Update app/models/collection.rb
sugandhaa Nov 20, 2012
360e946
Update app/models/collection.rb
sugandhaa Nov 21, 2012
789f91d
Update app/models/collection.rb
sugandhaa Nov 21, 2012
692ed1d
Update app/models/subject.rb
sugandhaa Nov 21, 2012
5708251
Update app/models/subject.rb
sugandhaa Nov 21, 2012
fd3442c
Update app/models/user_field.rb
sugandhaa Nov 21, 2012
d43d487
Update app/models/collection_content.rb
sugandhaa Nov 21, 2012
22764e0
Update app/models/creator.rb
sugandhaa Nov 21, 2012
e271928
Update app/models/collection_location_entry.rb
sugandhaa Nov 21, 2012
235da25
Update app/models/extent_unit.rb
sugandhaa Nov 21, 2012
a84ad57
Update app/models/extent_unit.rb
sugandhaa Nov 21, 2012
b24ae01
Update app/models/location.rb
sugandhaa Nov 21, 2012
97c51fc
Update app/models/repository.rb
sugandhaa Nov 21, 2012
8ef1d46
Update app/models/material_type.rb
sugandhaa Nov 21, 2012
c0437c3
Update app/models/user_field.rb
sugandhaa Nov 21, 2012
808a784
Update app/models/repository.rb
sugandhaa Nov 21, 2012
a8cc015
Update app/models/creator.rb
sugandhaa Nov 21, 2012
f707ced
Update app/models/creator.rb
sugandhaa Nov 21, 2012
f4d3976
Update app/models/creator_relationship.rb
sugandhaa Nov 21, 2012
1f8ea41
Update app/models/digital_content.rb
sugandhaa Nov 21, 2012
72b1e32
Update app/models/subject.rb
sugandhaa Nov 21, 2012
603183a
Update app/models/digital_content.rb
sugandhaa Nov 21, 2012
5acc70e
Update app/models/subject.rb
sugandhaa Nov 21, 2012
a228dc5
added new models
sugandhaa Nov 26, 2012
0bb4035
json objects added
sugandhaa Nov 26, 2012
0211522
Update app/models/creator_relationship_type.rb
sugandhaa Nov 26, 2012
36c271e
Update app/models/creator_type.rb
sugandhaa Nov 26, 2012
5e9a8ce
Update app/models/script.rb
sugandhaa Nov 26, 2012
847cbb1
Update app/models/language.rb
sugandhaa Nov 26, 2012
da39c9f
Update app/models/ead_element.rb
sugandhaa Nov 26, 2012
1c3c413
Update app/models/language.rb
sugandhaa Nov 26, 2012
9b656e6
Update app/models/repository.rb
sugandhaa Nov 26, 2012
ed52220
Update app/models/descriptive_rule.rb
sugandhaa Nov 26, 2012
8c726f0
updated activehash models
sugandhaa Nov 28, 2012
a2bfed3
removed data files
sugandhaa Nov 28, 2012
647ed1c
Update app/models/language.rb
sugandhaa Nov 28, 2012
f42de3d
Update app/models/script.rb
sugandhaa Nov 28, 2012
d032858
Update app/models/subject_type.rb
sugandhaa Nov 28, 2012
a48c55d
Update app/models/phrase_type.rb
sugandhaa Nov 28, 2012
cdeb54c
Update app/models/ead_element.rb
sugandhaa Nov 28, 2012
45a3958
eadelement deleted
dneralla Nov 29, 2012
e36920c
Update app/models/user.rb
sugandhaa Dec 7, 2012
384bebf
Update app/models/user.rb
sugandhaa Dec 7, 2012
27d4266
Update db/migrate/20120917093802_create_repositories.rb
sugandhaa Jan 2, 2013
c71c9b4
Update db/migrate/20120918014229_create_books.rb
sugandhaa Jan 2, 2013
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions app/models/accession.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
class Accession < ActiveRecord::Base
attr_accessible :accession_date, :comments, :donor, :donor_contact_info, :donor_notes, :enabled, :expected_completion_date, :identifier, :inclusive_dates, :material_type_id, :physical_description, :processing_priority_id, :received_extent, :received_extent_unit_id, :scope_content, :title, :unprocessed_extent, :unprocessed_extent_unit_id
belongs_to :material_type
has_many :accessionLocationEntries
has_many :creator_accession_relationships
belongs_to :processing_priority
belongs_to :extent_unit
has_many :accession_location_entries ,:dependent => :destroy
has_many :creator_accession_relationships,:dependent => :destroy
has_many :accession_subject_relationships, :dependent => :destroy
has_many :accession_collection_relationships, :dependent => :destroy
has_many :locations, :through => :accession_location_entries
has_many :subjects, :through => :accession_subject_relationships
has_many :creators, :through => :creator_accession_relationships
has_many :collections, :through => :accession_collection_relationships

end
5 changes: 5 additions & 0 deletions app/models/accession_collection_relationship.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
class AccessionCollectionRelationship < ActiveRecord::Base
belongs_to :accessions
belongs_to :collections
belongs_to :classifications
end
4 changes: 4 additions & 0 deletions app/models/accession_subject_relationship.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
class AccessionSubjectRelationship < ActiveRecord::Base
belongs_to :accession
belongs_to :subject
end
3 changes: 2 additions & 1 deletion app/models/book.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
class Book < ActiveRecord::Base
attr_accessible :copy_edition, :description, :edition, :notes, :number_of_pages, :place_of_publication, :publication_date, :publisher, :series, :title
belongs_to :collection
has_many :creatorBookRelationships
has_many :creator_book_relationships ,:dependent => :destroy
has_many :creators , :through => :creator_book_relationships
end
3 changes: 3 additions & 0 deletions app/models/classification.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
class Classification < ActiveRecord::Base
attr_accessible :classification_identifier, :creator_id, :description, :parent_id, :title
belongs_to :creator
belongs_to :classification, :foreign_key => "parent_id"
has_many :collections
has_many :accession_collection_relationships, :dependent => :destroy
has_many :accessions, :through => :accession_collection_relationships
end
25 changes: 19 additions & 6 deletions app/models/collection.rb
Original file line number Diff line number Diff line change
@@ -1,10 +1,23 @@
class Collection < ActiveRecord::Base
attr_accessible :abstract, :access_restrictions, :accrual_info, :acquisition_date, :acquisition_method, :acquisition_source, :alt_extent_statement, :appraisal_info, :arrangement, :biog_hist, :biog_hist_author, :classification_id, :collection_identifier, :custodial_history, :descpriptive_rules_id, :enabled, :extent, :extent_unit_id, :finding_aid_author, :finding_language_id, :inclusive_dates, :material_type_id, :normal_date_begin, :normal_date_end, :orig_copies_note, :orig_copies_url, :other_note, :other_url, :physical_access, :predominant_dates, :preferred_citation, :processing_info, :publication_date, :publication_note, :related_materials, :related_materials_url, :related_publications, :repository_id, :revision_history, :scope, :separated_materials, :sort_title, :technical_access, :title, :use_restrictions
has_many :collection_contents
has_many :collection_contents, :dependent => :destroy
belongs_to :classification
has_one :collection_creator_relationship
has_one :collectionLocationEntry
has_many :digitalContents
has_many :resarchCarts
belongs_to :repository
belongs_to :material_type
belongs_to :language
belongs_to :extent_unit
belongs_to :descriptive_rule
has_many :collection_creator_relationships, :dependent => :destroy
has_one :collection_location_entry,:dependent => :destroy
has_many :accession_collection_relationships, :dependent => :destroy
has_many :collection_subject_relationships, :dependent => :destroy
has_many :collection_language_relationships, :dependent => :destroy
has_many :digital_contents
has_many :resarch_carts
has_many :research_appointment_materials
end
has_many :subjects, :through => :collection_subject_relationships
has_many :languages, :through => :collection_language_relationships
has_many :locations, :through => :collection_location_entries
has_many :creators, :through => :collection_creator_relationships
has_many :accessions, :through => :accession_collection_relationships
end
9 changes: 7 additions & 2 deletions app/models/collection_content.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,13 @@ class CollectionContent < ActiveRecord::Base
attr_accessible :collection_id, :contains_content, :date, :description, :enabled, :level_container_id, :level_container_identifier, :parent_id, :private_title, :root_content_id, :sort_order, :title
belongs_to :collection
belongs_to :level_container
belongs_to :collection_content, :foreign_key="parent_id"
has_many :digitalContents
has_many :resarchCarts
has_many :resarch_carts
has_many :research_appointment_materials
has_one :userField
has_one :user_field, :dependent => :destroy
has_many :collection_content_subject_relationships, :dependent => :destroy
has_many :collection_content_creator_relationships, :dependent => :destroy
has_many :subjects, :through => :collection_content_subject_relationships
has_many :creators, :through => :collection_content_creator_relationships
end
4 changes: 4 additions & 0 deletions app/models/collection_content_creator_relationship.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
class CollectionContentCreatorRelationship < ActiveRecord::Base
belongs_to :collection_content
belongs_to :creator
end
4 changes: 4 additions & 0 deletions app/models/collection_content_subject_relationship.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
class CollectionContentSubjectRelationship < ActiveRecord::Base
belongs_to :collection_content
belongs_to :subject
end
4 changes: 2 additions & 2 deletions app/models/collection_creator_relationship.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
class CollectionCreatorRelationship < ActiveRecord::Base
attr_accessible :collection_id, :creator_id, :primary_creator
has_one :collection
has_one :creator
belongs_to :collection
belongs_to :creator
validates_presence_of :collection_id
validates_presence_of :creator_id
end
4 changes: 4 additions & 0 deletions app/models/collection_language_relationship.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
class CollectionLanguageRelationship < ActiveRecord::Base
belongs_to :collection
belongs_to :language
end
7 changes: 3 additions & 4 deletions app/models/collection_location_entry.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
class CollectionLocationEntry < ActiveRecord::Base
attr_accessible :collection_id, :content, :extent, :extent_unit_id, :location_id, :range_value, :section, :shelf
has_one :location
has_one :collection
validates_presence_of :location
validates_presence_of :collection
belongs_to :location
belongs_to :collection
belongs_to :extent_unit
end
4 changes: 4 additions & 0 deletions app/models/collection_subject_relationship.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
class CollectionSubjectRelationship < ActiveRecord::Base
belongs_to :collection
belongs_to :subject
end
Loading