@@ -4,7 +4,15 @@ class BasilController < ApplicationController
44 before_action :require_admin_access , only : [ :review ] , unless : -> { Rails . env . development? }
55
66 def index
7- @enabled_content_types = [ Character , Location ] . map ( &:name )
7+ disabled_content_types = [ Universe ]
8+
9+ @enabled_content_types = [
10+ Character , Location , Item ,
11+ # Building, Condition, Continent, Country,
12+ # Creature, Deity, Flora, Food, Government, Group, Job, Landmark, Language,
13+ # Lore, Magic, Planet, Race, Religion, Scene, School, Sport, Technology,
14+ # Town, Tradition, Vehicle
15+ ] . map ( &:name )
816
917 @content_type = params [ :content_type ] . try ( :humanize ) || 'Character'
1018 if @content_type . nil? || !@enabled_content_types . include? ( @content_type )
@@ -30,6 +38,7 @@ def content
3038 # and format them into an array of [field, value] pairs to pass to the view
3139 @relevant_fields = [ ]
3240
41+ # TODO: either move this to the default field template (metadata for each field) or to a BasilService
3342 case @content_type
3443 when 'Character'
3544 @relevant_fields . push BasilService . include_specific_field ( current_user , @content , 'Overview' , 'Gender' )
@@ -325,16 +334,28 @@ def commission
325334 "Name" ,
326335 "Identifying Marks" ,
327336 "Type" ,
328- "Description"
337+ "Description" ,
338+ "Body Type" ,
339+ "Item type" ,
329340 ] . map ( &:downcase )
330341 field_importance_multipliers = {
331- 'hair' : 1.15 ,
332- 'hair color' : 1.55 ,
333- 'hair style' : 1.10 ,
334- 'skin tone' : 1.05 ,
335- 'race' : 1.10 ,
336- 'eye color' : 1.05 ,
337- 'gender' : 1.15
342+ 'hair' : 1.15 ,
343+ 'hair color' : 1.55 ,
344+ 'hair style' : 1.10 ,
345+ 'skin tone' : 1.05 ,
346+ 'race' : 1.10 ,
347+ 'eye color' : 1.05 ,
348+ 'gender' : 1.15 ,
349+ 'description' : 1.00 ,
350+ 'item type' : 1.55 ,
351+ 'type' : 1.15 ,
352+ 'type of building' : 1.25 ,
353+ 'type of condition' : 1.25 ,
354+ 'type of food' : 1.15 ,
355+ 'type of landmark' : 1.25 ,
356+ 'type of magic' : 1.25 ,
357+ 'type of school' : 1.25 ,
358+ 'type of vehicle' : 1.25
338359 }
339360 label_value_pairs_to_skip_entirely = [
340361 [ 'race' , 'human' ]
0 commit comments