# HG changeset patch # User Andre Heinecke # Date 1359372424 -3600 # Node ID 89a8764cabcceb1950c2957331674bb409d45258 # Parent b457532dae631d9bf5517d92ca49b314dafee525 Importer: Only show imported fields if copy_fields is used diff -r b457532dae63 -r 89a8764cabcc flys-backend/contrib/shpimporter/importer.py --- a/flys-backend/contrib/shpimporter/importer.py Mon Jan 28 12:25:24 2013 +0100 +++ b/flys-backend/contrib/shpimporter/importer.py Mon Jan 28 12:27:04 2013 +0100 @@ -15,6 +15,7 @@ self.dest_srs = osr.SpatialReference() self.dest_srs.ImportFromEPSG(config.target_srs) self.handled_fields = [] + self.tracking_import = False def getKind(self, path): raise NotImplementedError("Importer.getKind is abstract!") @@ -93,6 +94,7 @@ The Key is the attribute of the source feature to be copied into the target attribute named by the dict's value. """ + self.tracking_import = True self.handled_fields.extend(mapping.keys()) for key, value in mapping.items(): if src.GetFieldIndex(key) == -1: