Changes between Version 6 and Version 7 of django_gheat


Ignore:
Timestamp:
Apr 14, 2011, 4:30:58 PM (15 years ago)
Author:
rick
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • django_gheat

    v6 v7  
    3434Get the latest django_gheat from the [http://svn.wirelessleiden.nl/svn/projects/Heatmap/src/ repository]
    3535
    36 Open /samples/persisted/settings.py, look for the 'DATABASES' section and edit the following lines:
     36Open {{{./settings.py}}}, look for the 'DATABASES' section and edit the following lines:
    3737{{{
    3838# If you are using MySQL with MySQLdb, don't edit this line.
     
    6969== Populating the database ==
    7070The 'syncdb' command added the following tables to the database:
    71 {{{
    72 BEGIN;
    73 CREATE TABLE `gheat_accespoint` (
    74     `id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY,
    75     `mac` varchar(17) NOT NULL,
    76     `ssid` varchar(64) NOT NULL,
    77     `encryptie` bool NOT NULL
    78 )
    79 ;
    80 CREATE TABLE `gheat_gebruiker` (
    81     `id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY,
    82     `naam` varchar(64) NOT NULL,
    83     `email` varchar(64) NOT NULL
    84 )
    85 ;
    86 CREATE TABLE `gheat_apparatuur` (
    87     `id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY,
    88     `antenne` varchar(64) NOT NULL,
    89     `kaart` varchar(64) NOT NULL
    90 )
    91 ;
    92 CREATE TABLE `gheat_meetrondje` (
    93     `id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY,
    94     `datum` datetime NOT NULL,
    95     `naam` varchar(60) NOT NULL,
    96     `gebruiker_id` integer NOT NULL,
    97     `apparatuur_id` integer NOT NULL
    98 )
    99 ;
    100 ALTER TABLE `gheat_meetrondje` ADD CONSTRAINT `apparatuur_id_refs_id_5e2d317` FOREIGN KEY (`apparatuur_id`) REFERENCES `gheat_apparatuur` (`id`);
    101 ALTER TABLE `gheat_meetrondje` ADD CONSTRAINT `gebruiker_id_refs_id_3b558609` FOREIGN KEY (`gebruiker_id`) REFERENCES `gheat_gebruiker` (`id`);
    102 CREATE TABLE `gheat_meting` (
    103     `id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY,
    104     `meetrondje_id` integer NOT NULL,
    105     `accespoint_id` integer NOT NULL,
    106     `lat` double precision NOT NULL,
    107     `lng` double precision NOT NULL,
    108     `signaal` integer NOT NULL
    109 )
    110 ;
    111 ALTER TABLE `gheat_meting` ADD CONSTRAINT `accespoint_id_refs_id_49f1ad5c` FOREIGN KEY (`accespoint_id`) REFERENCES `gheat_accespoint` (`id`);
    112 ALTER TABLE `gheat_meting` ADD CONSTRAINT `meetrondje_id_refs_id_6c4042fe` FOREIGN KEY (`meetrondje_id`) REFERENCES `gheat_meetrondje` (`id`);
    113 COMMIT;
     71
     72Generated by installing [https://github.com/django-extensions/django-extensions django_extentions] and the command: {{{./manage.py graph_models gheat | dot -Tpng -o model.png}}}
    11473
    11574}}}
    116 Note that on this moment only the gheat_meting(lat, lng, signaal) are used for generating heatmaps, so make sure you atleast put some data in those columns.
     75Note that on this moment only the gheat_meting(lat, lng, signaal) are used for generating heatmaps, so make sure you at least put some data in those columns.
    11776
    11877== Prerender heatmap ==