@@ -0,0 +1,1259 @@
+from django.contrib.gis.geos import Point%0Afrom data_collection.management.commands import BaseCsvStationsJsonDistrictsImporter%0A%0Aclass Command(BaseCsvStationsJsonDistrictsImporter):%0A    srid = 27700%0A    districts_srid = 27700%0A    council_id = 'E07000089'%0A    districts_name = 'Hart Polling Districts-fixed.geojson'%0A    stations_name = 'Hart Polling Stations 2017.csv'%0A    elections = %5B'local.hampshire.2017-05-04'%5D%0A%0A    def district_record_to_dict(self, record):%0A        name = str(record%5B'properties'%5D%5B'Name'%5D).strip()%0A        code = name.split(' ')%5B1%5D%0A        return %7B%0A            'internal_council_id': code,%0A            'name': name,%0A        %7D%0A%0A    def station_record_to_dict(self, record):%0A        location = Point(float(record.easting), float(record.northing), srid=self.srid)%0A        stations = %5B%5D%0A        district_ids = record.districts.split(',')%0A        district_ids = %5Bd.strip() for d in district_ids%5D%0A        for district_id in district_ids:%0A            stations.append(%7B%0A                'internal_council_id': district_id,%0A                'address' : record.polling_place,%0A                'postcode': record.postcode,%0A                'polling_district_id': district_id,%0A                'location': location,%0A            %7D)%0A        return stations%0A

add import script for Hart