Ignore:
Timestamp:
Apr 21, 2010, 5:26:21 PM (14 years ago)
Author:
duh
Message:
  • commented buggy bootstrap code
  • refactored wizard subject page
  • removed wizard:speciesElement from taglibrary
  • changed speciesElement to termElement
  • used SelectAddMore?.js to add dialog functionality to template select elements
  • changed bug report icon
  • added more famfamfam icons
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/grails-app/taglib/dbnp/studycapturing/WizardTagLib.groovy

    r359 r367  
    472472
    473473        /**
    474          * Template form element
    475          * @param Map attributes
    476          * @param Closure help content
    477          */
    478         def speciesElement = {attrs, body ->
    479                 // render template element
    480                 baseElement.call(
    481                         'speciesSelect',
    482                         attrs,
    483                         body
    484                 )
    485         }
    486 
    487         /**
    488          * render a species select element
    489          * @param Map attrs
    490          */
    491         def speciesSelect = {attrs ->
    492                 // fetch the speciesOntology
    493                 // note that this is a bit nasty, probably the ontologyName should
    494                 // be configured in a configuration file... --> TODO: centralize species configuration
    495                 def speciesOntology = Ontology.findByName('NCBI Taxonomy')
    496 
    497                 // fetch all species
    498                 attrs.from = Term.findAllByOntology(speciesOntology)
    499 
    500                 // got a name?
    501                 if (!attrs.name) {
    502                         // nope, use a default name
    503                         attrs.name = 'species'
    504                 }
    505 
    506                 out << select(attrs)
    507         }
    508 
    509         /**
    510474         * Ontology form element
    511475         * @param Map attributes
     
    551515        }
    552516
    553 
    554517        /**
    555518         * render a study select element
     
    581544         */
    582545        def templateElement = {attrs, body ->
     546                // add a rel element if it does not exist
     547                if (!attrs.rel) {
     548                        attrs.rel = 'template'
     549                }
     550               
    583551                // render template element
    584552                baseElement.call(
Note: See TracChangeset for help on using the changeset viewer.