Ignore:
Timestamp:
Feb 8, 2010, 12:42:46 PM (7 years ago)
Author:
keesvb
Message:

added first version of importer data model, added helper methods to domain class for getting all entity fields, added study template fields

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/grails-app/domain/dbnp/studycapturing/Subject.groovy

    r162 r176  
    5353                }
    5454        }
     55
     56        def setFieldValue(String fieldName, value) {
     57                this.properties.each { println it}
     58                if (this.properties.containsKey(fieldName)) {
     59                        this[fieldName] = value
     60                }
     61                else if (templateStringFields.containsKey(fieldName) && value.class == String) {
     62                        this.templateStringFields[fieldName] = value
     63                }
     64                else {
     65                        println "Field ${fieldName} not found"
     66                }
     67        }
    5568}
Note: See TracChangeset for help on using the changeset viewer.