Skip to main content

zope.formlib datetime widget used by Horae

Project description

Introduction

horae.datetime provides zope.formlib input widgets for Date and Datetime fields of zope.schema. Both widgets use the datepicker widget of jQuery UI to select the date. The Datetime widget additionally provides two input fields to enter the hour and minute for the time. The hour and minute fields are enhanced by the Spinbox jQuery plugin.

Usage

The widgets may either be registered through ZCML as new default input widgets for Date and Datetime fields or by defining the widget as custom_widget on a zope.formlib form. Registration as default widget has to be done either in an overrides.zcml or the registrations have to be bound to a specific browser layer.

Registration using the overrides.zcml would look like this:

<configure xmlns='http://namespaces.zope.org/zope'>

  <view
      type="zope.publisher.interfaces.browser.IBrowserRequest"
      for="zope.schema.interfaces.IDatetime"
      provides="zope.app.form.interfaces.IInputWidget"
      factory="horae.datetime.widget.DatetimeWidget"
      permission="zope.Public"
      />

  <view
      type="zope.publisher.interfaces.browser.IBrowserRequest"
      for="zope.schema.interfaces.IDate"
      provides="zope.app.form.interfaces.IInputWidget"
      factory="horae.datetime.widget.DateWidget"
      permission="zope.Public"
      />

</configure>

Dependencies

Changelog

1.0a1 (2012-01-16)

  • Initial release

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

horae.datetime-1.0a1.tar.gz (10.3 kB view details)

Uploaded Source

File details

Details for the file horae.datetime-1.0a1.tar.gz.

File metadata

File hashes

Hashes for horae.datetime-1.0a1.tar.gz
Algorithm Hash digest
SHA256 8881aee722fc1252cb016f5498a35f65a0f8372862e6940fb92a1553b3afef95
MD5 5bc7c7b2d1d3edf75cd7ee4e2d9ec450
BLAKE2b-256 9e474983c2cb8d6bbf3eb45a00b0c875bd3f37ace04638495bfe699275039b0c

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page