On Thu, Mar 16, 2006 at 08:06:11PM -0700, Jeff Shell wrote:
| By the way, isn't it pretty easy to provide straight up values anyways
| for those quick drop-down situations?
| 
|     trip_type = zope.schema.Choice(
|         title=_(u"Trip Type"),
|         description=_(u"Trip Type"),
|         default=u"Business",
|         required=True,
|         values=(u"Business", u"Personal"),
|         )
| 
| replacementOptions = SimpleVocabulary((
|     SimpleTerm(value='none', title='No - keep all current articles'),
|     SimpleTerm(value='matching', title='Only replace matching IDs'),
|     SimpleTerm(value='all', title='Yes - replace all existing articles'),
|     ))
| class ImportSchema(Interface):
|     importfile = zope.schema.Bytes(
|         title=u"Import Zip File",
|         description=u"Zipe file of items to import.",
|         required=True,
|         )
| 
|     replace = zope.schema.Choice(
|         title=u"Replace existing articles?",
|         vocabulary=replacementOptions,
|         default='none',
|         )

Yum Yum. That reminds me of Archetypes-Hum.

-- 
Sidnei da Silva
Enfold Systems, Inc.
http://enfoldsystems.com
_______________________________________________
Zope3-dev mailing list
Zope3-dev@zope.org
Unsub: http://mail.zope.org/mailman/options/zope3-dev/archive%40mail-archive.com

Reply via email to