|
@@ -97,12 +97,11 @@ class Loan(models.Model):
|
|
|
loan_date = models.DateField(verbose_name='date de prêt')
|
|
|
loan_date_end = models.DateField(verbose_name='date de fin de prêt',
|
|
|
null=True, blank=True)
|
|
|
- location = models.CharField(max_length=100, verbose_name='emplacement',
|
|
|
- null=True, blank=True)
|
|
|
+ notes = models.TextField(null=True, blank=True)
|
|
|
|
|
|
def __unicode__(self):
|
|
|
- return 'prêt de {item} à {user}'.format(item=self.item,
|
|
|
- user=self.user)
|
|
|
+ return 'prêt de {item} à {user}'.format(
|
|
|
+ item=self.item, user=self.user)
|
|
|
|
|
|
def user_can_close(self, user):
|
|
|
return (not self.item.is_available()) and (self.user == user)
|