Fixes manual update of profile image
This commit is contained in:
1 parent
cb53489f86
commit
532cab2c6a
1 file changed
+2
-1
+2
-1
@@ -52,7 +52,8 @@ class Transaction(models.Model):
|
|||||||
class UserProfile(models.Model):
|
class UserProfile(models.Model):
|
||||||
user = models.OneToOneField(User)
|
user = models.OneToOneField(User)
|
||||||
balance = models.FloatField(default=0.0)
|
balance = models.FloatField(default=0.0)
|
||||||
image = models.ImageField(upload_to='users', blank=True)
|
#image = models.ImageField(upload_to='users', blank=True)
|
||||||
|
image = models.URLField(blank=True)
|
||||||
|
|
||||||
def last_purchase(self):
|
def last_purchase(self):
|
||||||
if len(self.user.order_set.all()) == 0:
|
if len(self.user.order_set.all()) == 0:
|
||||||
|
|||||||
Reference in new issue
Block a user