Ignore:
Timestamp:
Jul 20, 2010, 4:21:50 PM (11 years ago)
Author:
tabma
Message:
  • added "Don' t import" functionality which ignores columns
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/grails-app/controllers/dbnp/importer/ImporterController.groovy

    r661 r669  
    119119            table.each { entity ->
    120120                entity.giveFields().each { field ->
    121                     print ":" + params["entity_" + entity.hashCode() + "_" + field.escapedName()]
     121                    //print ":" + params["entity_" + entity.hashCode() + "_" + field.escapedName()]
    122122                    entity.setFieldValue (field.toString(), params["entity_" + entity.hashCode() + "_" + field.escapedName()])
    123123                }               
     
    223223                // Store the selected property for this column into the column map for the ImporterService
    224224                session.importer_header[columnindex.toInteger()].property = property
     225
    225226                // Look up the template field type of the target TemplateField and store it also in the map
    226                 session.importer_header[columnindex.toInteger()].templatefieldtype = entityObj.getFieldType(property)
     227                session.importer_header[columnindex.toInteger()].templatefieldtype = entityObj.giveFieldType(property)
     228
     229                // Is a "Don't import" property assigned to the column?
     230                session.importer_header[columnindex.toInteger()].dontimport = (property=="dontimport") ? true : false
    227231
    228232                //if it's an identifier set the mapping column true or false
Note: See TracChangeset for help on using the changeset viewer.