Tweak return value for /customers API
This commit is contained in:
parent
de46dfc4a2
commit
56974ce30f
|
@ -26,6 +26,8 @@ Tailbone Web API - Customer Views
|
|||
|
||||
from __future__ import unicode_literals, absolute_import
|
||||
|
||||
import six
|
||||
|
||||
from rattail.db import model
|
||||
|
||||
from cornice.resource import resource, view
|
||||
|
@ -41,6 +43,7 @@ class CustomerView(APIMasterView):
|
|||
def normalize(self, customer):
|
||||
return {
|
||||
'uuid': customer.uuid,
|
||||
'_str': six.text_type(customer),
|
||||
'id': customer.id,
|
||||
'name': customer.name,
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue