summaryrefslogtreecommitdiff
path: root/ishtar_common/models.py
diff options
context:
space:
mode:
Diffstat (limited to 'ishtar_common/models.py')
-rw-r--r--ishtar_common/models.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/ishtar_common/models.py b/ishtar_common/models.py
index a2341abdc..3b3f9d141 100644
--- a/ishtar_common/models.py
+++ b/ishtar_common/models.py
@@ -2276,6 +2276,8 @@ ENCODINGS = [(settings.ENCODING, settings.ENCODING),
class Import(models.Model):
user = models.ForeignKey('IshtarUser')
+ name = models.CharField(_(u"Name"), max_length=500,
+ blank=True, null=True)
importer_type = models.ForeignKey(ImporterType)
imported_file = models.FileField(
_(u"Imported file"), upload_to="upload/imports/", max_length=220)
@@ -2313,8 +2315,7 @@ class Import(models.Model):
verbose_name_plural = _(u"Imports")
def __unicode__(self):
- return u"%s - %s - %d" % (unicode(self.importer_type),
- unicode(self.user), self.pk)
+ return u"{} | {}".format(self.name or u"-", self.importer_type)
def need_matching(self):
return bool(TargetKey.objects.filter(associated_import=self,