|
|
@ -1,10 +1,14 @@ |
|
|
|
#from django.db import models |
|
|
|
from django.contrib.gis.db import models |
|
|
|
|
|
|
|
from django.contrib.auth.models import User, Group |
|
|
|
import uuid |
|
|
|
# Create your models here. |
|
|
|
|
|
|
|
class Layer(models.Model): |
|
|
|
token = models.CharField(max_length=50) |
|
|
|
id = models.UUIDField(primary_key=True, default=uuid.uuid4, editable=False) |
|
|
|
name = models.CharField(max_length=50) |
|
|
|
created = models.DateTimeField(auto_now_add=True) |
|
|
|
owner = models.ForeignKey(Layer, on_delete=models.CASCADE, null=True) |
|
|
|
|
|
|
|
class Place(models.Model): |
|
|
|
lon = models.FloatField() |
|
|
|