work in progress: commerce.product
git-svn-id: svn://svn.cy55.de/Zope3/src/cybertools/trunk@2774 fd906abe-77d9-0310-91a1-e0d9ade77398
This commit is contained in:
parent
64ccc2cc94
commit
f7205891ff
2 changed files with 11 additions and 8 deletions
|
@ -26,7 +26,7 @@ from zope import component
|
||||||
from zope.cachedescriptors.property import Lazy
|
from zope.cachedescriptors.property import Lazy
|
||||||
|
|
||||||
|
|
||||||
class ProcuctView(object):
|
class ProductView(object):
|
||||||
|
|
||||||
def __init__(self, context, request):
|
def __init__(self, context, request):
|
||||||
self.context = context
|
self.context = context
|
||||||
|
|
|
@ -41,7 +41,7 @@ class IShop(Interface):
|
||||||
name = schema.ASCII(
|
name = schema.ASCII(
|
||||||
title=_(u'Shop name'),
|
title=_(u'Shop name'),
|
||||||
description=_(u'An internal name uniquely identifying the shop.'),
|
description=_(u'An internal name uniquely identifying the shop.'),
|
||||||
default=u'',
|
default='',
|
||||||
required=True)
|
required=True)
|
||||||
title = schema.TextLine(
|
title = schema.TextLine(
|
||||||
title=_(u'Title'),
|
title=_(u'Title'),
|
||||||
|
@ -52,9 +52,7 @@ class IShop(Interface):
|
||||||
title=_(u'Description'),
|
title=_(u'Description'),
|
||||||
description=_(u'A medium-length description.'),
|
description=_(u'A medium-length description.'),
|
||||||
default=u'',
|
default=u'',
|
||||||
missing_value=u'',
|
|
||||||
required=False)
|
required=False)
|
||||||
|
|
||||||
products = Attribute(u'The products available in this shop.')
|
products = Attribute(u'The products available in this shop.')
|
||||||
categories = Attribute(u'The product categories provided by this shop.')
|
categories = Attribute(u'The product categories provided by this shop.')
|
||||||
suppliers = Attribute(u'The suppliers providing products for '
|
suppliers = Attribute(u'The suppliers providing products for '
|
||||||
|
@ -71,7 +69,7 @@ class ISupplier(Interface):
|
||||||
name = schema.ASCII(
|
name = schema.ASCII(
|
||||||
title=_(u'Supplier name'),
|
title=_(u'Supplier name'),
|
||||||
description=_(u'An internal name uniquely identifying the supplier.'),
|
description=_(u'An internal name uniquely identifying the supplier.'),
|
||||||
default=u'',
|
default='',
|
||||||
required=True)
|
required=True)
|
||||||
title = schema.TextLine(
|
title = schema.TextLine(
|
||||||
title=_(u'Title'),
|
title=_(u'Title'),
|
||||||
|
@ -96,11 +94,11 @@ class IProduct(Interface):
|
||||||
""" A certain class of similar objects that may be put in a shopping cart.
|
""" A certain class of similar objects that may be put in a shopping cart.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
productId = schema.ASCII(
|
productId = schema.ASCIILine(
|
||||||
title=_(u'Product Identifier'),
|
title=_(u'Product Identifier'),
|
||||||
description=_(u'A name or number uniquely identifiying the '
|
description=_(u'A name or number uniquely identifiying the '
|
||||||
u'product within a shop.'),
|
u'product within a shop.'),
|
||||||
default=u'',
|
default='',
|
||||||
required=True)
|
required=True)
|
||||||
title = schema.TextLine(
|
title = schema.TextLine(
|
||||||
title=_(u'Title'),
|
title=_(u'Title'),
|
||||||
|
@ -113,6 +111,11 @@ class IProduct(Interface):
|
||||||
default=u'',
|
default=u'',
|
||||||
missing_value=u'',
|
missing_value=u'',
|
||||||
required=False)
|
required=False)
|
||||||
|
fullDescription = schema.Text(
|
||||||
|
title=_(u'Full description'),
|
||||||
|
description=_(u'The full description of the object.'),
|
||||||
|
default=u'',
|
||||||
|
required=False)
|
||||||
|
|
||||||
categories = Attribute(u'The product categories this product belongs to.')
|
categories = Attribute(u'The product categories this product belongs to.')
|
||||||
suppliers = Attribute(u'The suppliers (typically only one) providing '
|
suppliers = Attribute(u'The suppliers (typically only one) providing '
|
||||||
|
@ -152,7 +155,7 @@ class ICustomer(Interface):
|
||||||
customerId = schema.ASCII(
|
customerId = schema.ASCII(
|
||||||
title=_(u'Customer Identifier'),
|
title=_(u'Customer Identifier'),
|
||||||
description=_(u'A name or number uniquely identifiying the customer.'),
|
description=_(u'A name or number uniquely identifiying the customer.'),
|
||||||
default=u'',
|
default='',
|
||||||
required=True)
|
required=True)
|
||||||
|
|
||||||
client = Attribute(u'The (real) client object of the customer role.')
|
client = Attribute(u'The (real) client object of the customer role.')
|
||||||
|
|
Loading…
Add table
Reference in a new issue