From 2fff1a262b86c9cddacacdf156c6f3b49250aa80 Mon Sep 17 00:00:00 2001 From: Sam Date: Thu, 21 Jan 2021 13:20:25 +0000 Subject: [PATCH] enabled geo app and Company.city --- back_latienda/settings/base.py | 1 + companies/models.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/back_latienda/settings/base.py b/back_latienda/settings/base.py index 10a3aa2..f388324 100644 --- a/back_latienda/settings/base.py +++ b/back_latienda/settings/base.py @@ -41,6 +41,7 @@ INSTALLED_APPS = [ 'django.contrib.staticfiles', 'core', + 'geo', 'companies', 'products', 'history', diff --git a/companies/models.py b/companies/models.py index eb7ea4a..e193968 100644 --- a/companies/models.py +++ b/companies/models.py @@ -24,7 +24,7 @@ class Company(models.Model): platform = models.CharField('Plataforma de tienda online', choices=PLATFORMS, max_length=25, null=True, blank=True) email = models.EmailField('Email', null=True, blank=True) logo = models.ImageField('Logo', upload_to='logos/', null=True, blank=True) - # city = models.ForeignKey('geo.City', null=True, blank=True, on_delete=models.DO_NOTHING) + city = models.ForeignKey('geo.City', null=True, blank=True, on_delete=models.DO_NOTHING) address = models.CharField('Dirección', max_length=1000, null=True, blank=True) geo = models.PointField('Coordenadas', null=True, blank=True ) phone = models.CharField('Teléfono', max_length=25, null=True, blank=True)