mirror of
https://github.com/ae-utbm/sith.git
synced 2024-11-21 21:53:30 +00:00
Improve product display
This commit is contained in:
parent
7fdcb0c815
commit
63217b2ead
@ -75,7 +75,7 @@ class ProductsLookup(RightManagedLookupChannel):
|
||||
self.model.objects.filter(code__icontains=q)).filter(archived=False)[:50]
|
||||
|
||||
def format_item_display(self, item):
|
||||
return item.name
|
||||
return "%s (%s)" % (item.name, item.code)
|
||||
|
||||
@register('club_accounts')
|
||||
class ClubAccountLookup(RightManagedLookupChannel):
|
||||
|
@ -113,7 +113,7 @@ class Product(models.Model):
|
||||
return False
|
||||
|
||||
def __str__(self):
|
||||
return self.name
|
||||
return "%s (%s)" % (self.name, self.code)
|
||||
|
||||
def get_absolute_url(self):
|
||||
return reverse('counter:product_list')
|
||||
|
Loading…
Reference in New Issue
Block a user