Add views for PendingProduct model; also DepartmentWidget

This commit is contained in:
Lance Edgar 2021-11-10 12:39:51 -06:00
parent 7630f504b0
commit 5f9d311cdb
3 changed files with 192 additions and 2 deletions

View file

@ -739,9 +739,11 @@ class MasterView(View):
if obj.emails:
return obj.emails[0].address
def render_product_key_value(self, obj):
def render_product_key_value(self, obj, field=None):
"""
Render the "canonical" product key value for the given object.
nb. the ``field`` kwarg is ignored if present
"""
product_key = self.rattail_config.product_key()
if product_key == 'upc':