- from zope import schema
- from zope.interface import Interface
- from zope.app.container.constraints import contains
- from zope.app.container.constraints import containers
- from buzz.coupon import couponMessageFactory as _
- class ICoupon(Interface):
- """Online Coupon"""
- # -*- schema definition goes here -*-
- io_num = schema.TextLine(
- title=_(u"Insertion Order"),
- required=True,
- description=_(u"Insertion order number (for tracking)"),
- )
- printmax = schema.Int(
- title=_(u"Print Max"),
- required=False,
- description=_(u"Maximum times that this coupon may be printed"),
- )
- printcount = schema.Int(
- title=_(u"Print Count"),
- required=False,
- description=_(u"The number of times this coupon has been printed"),
- )
- alllocations = schema.Bool(
- title=_(u"All Locations"),
- required=False,
- description=_(u"Will this coupon be available at all locations? (other location fields will be ignored)"),
- )
- criteria = schema.List(
- title=_(u"Criteria"),
- required=False,
- description=_(u"Choose the selction critera types for this coupon to be displayed"),
- )
- clusters = schema.List(
- title=_(u"Clusters"),
- required=False,
- description=_(u"Clusters that this coupon will be available at"),
- )
- locations = schema.List(
- title=_(u"Locations"),
- required=False,
- description=_(u"Locations that this coupon is valid at"),
- )
- bc_image = schema.Bytes(
- title=_(u"Barcode"),
- required=False,
- description=_(u"Barcode image for printing"),
- )
- bc_num = schema.TextLine(
- title=_(u"Barcode Number"),
- required=False,
- description=_(u"Numeric barcode value"),
- )
- scr_hmr = schema.Int(
- title=_(u"Store Classes/Ranks - HMR"),
- required=False,
- description=_(u"The store class/rank minimum for this coupon to show"),
- )
- scr_chilled = schema.Int(
- title=_(u"Store Classes/Ranks - Chilled"),
- required=False,
- description=_(u"The store class/rank minimum for this coupon to show"),
- )
- scr_frozen = schema.Int(
- title=_(u"Store Classes/Ranks - Frozen"),
- required=False,
- description=_(u"The store class/rank minimum for this coupon to show"),
- )
- scr_dry = schema.Int(
- title=_(u"Store Classes/Ranks - Dry"),
- required=False,
- description=_(u"The store class/rank minimum for this coupon to show"),
- )
- brand_image = schema.Bytes(
- title=_(u"Brand"),
- required=False,
- description=_(u"Image or logo of the brand"),
- )
- manufacturer = schema.TextLine(
- title=_(u"Manufacturer"),
- required=False,
- description=_(u"Field description"),
- )
- printimage = schema.Bytes(
- title=_(u"Print Image"),
- required=False,
- description=_(u"Image to be printed as the store coupon"),
- )
- webimage = schema.Bytes(
- title=_(u"Web Image"),
- required=False,
- description=_(u"Image for display on the web"),
- )
- restrictions = schema.Text(
- title=_(u"Restrictions"),
- required=False,
- description=_(u"Restrictions on usage of this coupon (i.e. One per customer)"),
- )
- costvalue = schema.TextLine(
- title=_(u"Value"),
- required=False,
- description=_(u"Coupon value (i.e. 50% Off or $1.00 Off)"),
- )