Changeset 9161 for src/django_gheat/gheat/management/commands
- Timestamp:
- May 8, 2011, 7:35:49 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/django_gheat/gheat/management/commands/import_droidstumbler.py
r9140 r9161 28 28 from django.core.management.base import BaseCommand 29 29 from optparse import OptionParser, make_option 30 import settings31 setup_environ(settings)32 30 from gheat.models import * 33 31 import datetime … … 44 42 epoch, msg_type, lat, lon, accuracy, ssid, bssid, level, frequency, capabilities, empty = row 45 43 if msg_type == "data" and lat and lon: 46 ap, created = Accespoint.objects.get_or_create(mac=bssid, ssid= "ap-WirelessLeiden-" +ssid, encryptie=capabilities)44 ap, created = Accespoint.objects.get_or_create(mac=bssid, ssid=ssid, encryptie=capabilities) 47 45 if created: 48 46 print "# INFO: New AccessPoint %s (%s)" % (ap.ssid, ap.mac)
Note:
See TracChangeset
for help on using the changeset viewer.