Skip to content

Instantly share code, notes, and snippets.

@jcreed
Created May 5, 2025 17:50
Show Gist options
  • Save jcreed/8c97b8fede1a9888dd60a9e1e74e095b to your computer and use it in GitHub Desktop.
Save jcreed/8c97b8fede1a9888dd60a9e1e74e095b to your computer and use it in GitHub Desktop.
holistic review error
When 2 hours ago
Message undefined method `[]' for nil
URL POST. https://admin.webadmit.org/admin/holistic_review?association_id=4743
File app/models/holistic_domain.rb:113
app/models/holistic_domain.rb:113 in block in <class:HolisticDomain>
111: SQL
112: query = sanitize_sql_array([q, {parent:, child:}])
113: HolisticDomain.connection.exec_query(query).first['position']
114: }
app/models/holistic_domain.rb:168 in dynamic_order
166:
when is_domain?
167:
root_order = parent_id * root_spacing
168:
domain_order = self.class.position_within_parent(parent_id, id) * domain_spacing
169:
root_order + domain_order
170:
when is_subdomain?
app/models/holistic_domain.rb:15 in block in <class:HolisticDomain>
13:
identifier: dynamic_identifier,
14:
name: dynamic_name,
15:
order: dynamic_order,
16:
allow_many: true,
17:
scorable: true,
lib/dynamic_fields.rb:147 in instance_exec
145:
records = is_through ? send(options[:through]) : [self]
146:
records.each do |record|
147:
attributes = instance_exec record, &attr_proc
148:
foreign_key = record.class.base_class.field_class_name.foreign_key
149:
conditions = {
lib/dynamic_fields.rb:147 in block (2 levels) in update_dynamic_fields
145:
records = is_through ? send(options[:through]) : [self]
146:
records.each do |record|
147:
attributes = instance_exec record, &attr_proc
148:
foreign_key = record.class.base_class.field_class_name.foreign_key
149:
conditions = {
lib/dynamic_fields.rb:146 in each
144:
is_through = options.has_key? :through
145:
records = is_through ? send(options[:through]) : [self]
146:
records.each do |record|
147:
attributes = instance_exec record, &attr_proc
148:
foreign_key = record.class.base_class.field_class_name.foreign_key
lib/dynamic_fields.rb:146 in block in update_dynamic_fields
144:
is_through = options.has_key? :through
145:
records = is_through ? send(options[:through]) : [self]
146:
records.each do |record|
147:
attributes = instance_exec record, &attr_proc
148:
foreign_key = record.class.base_class.field_class_name.foreign_key
lib/dynamic_fields.rb:143 in each
141:
fields_to_update = args.delete(:fields) || {}
142:
order = set_start_order
143:
dynamic_fields(fields_to_update).each do |relation_name, field_name, options, attr_proc|
144:
is_through = options.has_key? :through
145:
records = is_through ? send(options[:through]) : [self]
lib/dynamic_fields.rb:143 in update_dynamic_fields
141:
fields_to_update = args.delete(:fields) || {}
142:
order = set_start_order
143:
dynamic_fields(fields_to_update).each do |relation_name, field_name, options, attr_proc|
144:
is_through = options.has_key? :through
145:
records = is_through ? send(options[:through]) : [self]
Parameters
{
"_submit": "1",
"action": "create",
"association_id": "4743",
"authenticity_token": "JyMEjmqIP17988aZ66IrVjUvYwwkw0JURlDx8vzJPgbhHboAKzWI7pLsgXE5miiIGkqfWAbvuoClpog6njZohg",
"controller": "admin/holistic_reviews",
"domains": [
{
"name": "Socioeconomic Background",
"subdomains": [
{
"identifier": "NUMBER_OF_LANGUAGES_SCORE",
"name": "Number of Languages"
}
]
},
{
"id": "105",
"name": "MCAT",
"subdomains": [
{
"id": "106",
"identifier": "MCAT_RECENT_TOTAL_SCORE",
"name": "Total Recent"
}
]
},
{
"id": "107",
"name": "Undergrad Background",
"subdomains": [
{
"id": "108",
"identifier": "UNDERGRADUATE_GPA_SCORE",
"name": "UG Overall GPA"
}
]
},
{
"id": "109",
"name": "Grad Background",
"subdomains": [
{
"id": "110",
"identifier": "GRADUATE_GPA_SCORE",
"name": "Grad Overall GPA"
}
]
},
{
"id": "111",
"name": "Experiences",
"subdomains": [
{
"id": "112",
"identifier": "EXTRACURRICULAR_ACTIVITIES_EXPERIENCE_SCORE",
"name": "Extracurricular Activities"
}
]
}
],
"root": {
"name": "AACOM Holistic Model"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment