source: trunk/grails-app/domain/dbnp/importer/MappingColumn.groovy @ 1103

Last change on this file since 1103 was 1103, checked in by t.w.abma@…, 10 years ago
  • added error page for importer
  • empty ontologies detected in Excel still should be shown as "unknown" fields in the failed ontology-mapping step
  • Property svn:keywords set to Author Date Rev
File size: 977 bytes
Line 
1package dbnp.importer
2import dbnp.studycapturing.TemplateField
3
4/**
5* name: column name (in Excel)
6* templatefieldtype: GSCF field type
7* entity: GSCF entity class
8* property: GSCF template field
9* index: column index
10* value: column value (optional, normally only name is used)
11* identifier: true if this column is identifying (unique/primary key)
12*/
13class MappingColumn {
14
15        String name
16        dbnp.studycapturing.TemplateFieldType templatefieldtype
17        Class entity
18        String property
19        Integer index
20        String value
21        Boolean identifier
22        Boolean dontimport
23
24    static transients = [ "templatefieldtype", "entity" ]
25
26    static constraints = {
27            name(unique: true)
28            dontimport(default:false)
29    }
30
31    static mapping = {
32            tablePerHierarchy false
33    }
34
35    String toString() {
36        return "Name:" + name + "/TemplateFieldType:" + templatefieldtype + "/Entity:" + entity + "/Property:" + property + "/Index:" + index + "/Value:" + value + "/Identifier:" + identifier
37    }
38}
Note: See TracBrowser for help on using the repository browser.