Changeset 1791

Show
Ignore:
Timestamp:
27-04-11 12:10:16 (3 years ago)
Author:
work@…
Message:

RE-committed Robert's change after the SVN was fixed, original commit log was:

- Added environmental ontology (1069) to the subject.species field, to fix issue #353

Location:
trunk/grails-app
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • trunk/grails-app/conf/BootStrap.groovy

    r1669 r1791  
    8484                 * @see dbnp.studycapturing.Sample 
    8585                 */ 
    86                 TemplateEntity.getField(Subject.domainFields, 'species').ontologies = [Ontology.getOrCreateOntologyByNcboId(1132)] 
    87                 TemplateEntity.getField(Sample.domainFields, 'material').ontologies = [Ontology.getOrCreateOntologyByNcboId(1005)] 
     86                TemplateEntity.getField(Subject.domainFields, 'species').ontologies = [ 
     87                        Ontology.getOrCreateOntologyByNcboId(1132),             // NCBI Organismal Classification 
     88                        Ontology.getOrCreateOntologyByNcboId(1069)              // Environmental Ontology 
     89                ] 
     90                TemplateEntity.getField(Sample.domainFields, 'material').ontologies = [ 
     91                        Ontology.getOrCreateOntologyByNcboId(1005)              // BRENDA Tissue / enzyme source 
     92                ] 
    8893        } 
    8994 
  • trunk/grails-app/views/studyWizard/pages/_subjects.gsp

    r1461 r1791  
    1414 * $Date$ 
    1515 */ 
     16 
     17def speciesOntologies = dbnp.studycapturing.Subject.giveDomainFields().find { it.name == 'species' }.ontologies.collect { it.ncboId } 
    1618%> 
    1719<af:page> 
     
    3133                The species of the subjects you would like to add to your study 
    3234        </af:termElement> 
    33         <af:templateElement name="template" description="with template" value="${values?.template}" error="template" entity="${dbnp.studycapturing.Subject}" ontologies="1132" addDummy="true"> 
     35        <af:templateElement name="template" description="with template" value="${values?.template}" error="template" entity="${dbnp.studycapturing.Subject}" ontologies="${speciesOntologies.join( ',' )}" addDummy="true"> 
    3436                The template to use for these subjects 
    3537        </af:templateElement>