{ "info": { "author": "Alfredo Saglimbeni", "author_email": "alfredo.saglimbeni@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Environment :: Web Environment", "Framework :: Django", "Intended Audience :: Developers", "License :: OSI Approved :: BSD License", "Operating System :: OS Independent", "Programming Language :: Python", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "django-datetime-widget\n======================\n\n.. image:: https://pypip.in/v/django-datetime-widget/badge.png\n :target: https://crate.io/packages/django-datetime-widget\n.. image:: https://pypip.in/d/django-datetime-widget/badge.png\n :target: https://crate.io/packages/django-datetime-widget\n\n``django-datetime-widget`` is a simple and clean picker widget for DateField, Timefiled and DateTimeField in Django framework. It is based on `Bootstrap datetime picker\n`_, supports both Bootstrap 3 and Bootstrap 2 .\n\n``django-datetime-widget`` is perfect when you use a DateField, TimeField or DateTimeField in your model/form where is necessary to display the corresponding picker with a specific date/time format. Now it support django localization.\n\nAvailable widgets\n-----------------\n\n* **DateTimeWidget** : display the input with the calendar and time picker.\n* **DateWidget** : display the input only with the calendar picker.\n* **TimeWidget** : display the input only with the time picker.\n\n`See Demo page `_\n\nRequirements\n------------\n* `Bootstrap `_ 2.0.4+ and 3.2.0\n* `jQuery `_ 1.7.1+\n\nScreenshots\n===========\n\n* Decade year view\n\n.. image:: https://raw.github.com/smalot/bootstrap-datetimepicker/master/screenshot/standard_decade.png\n\nThis view allows to select the year in a range of 10 years.\n\n* Year view\n\n.. image:: https://raw.github.com/smalot/bootstrap-datetimepicker/master/screenshot/standard_year.png\n\nThis view allows to select the month in the selected year.\n\n* Month view\n\n.. image:: https://raw.github.com/smalot/bootstrap-datetimepicker/master/screenshot/standard_month.png\n\nThis view allows to select the day in the selected month.\n\n* Day view\n\n.. image:: https://raw.github.com/smalot/bootstrap-datetimepicker/master/screenshot/standard_day.png\n\nThis view allows to select the hour in the selected day.\n\n* Hour view\n\n.. image:: https://raw.github.com/smalot/bootstrap-datetimepicker/master/screenshot/standard_hour.png\n\nThis view allows to select the preset of minutes in the selected hour.\nThe range of 5 minutes (by default) has been selected to restrict buttons quantity to an acceptable value, but it can be overrided by the minuteStep property.\n\n* Day view - meridian\n\n.. image:: https://raw.github.com/smalot/bootstrap-datetimepicker/master/screenshot/standard_day_meridian.png\n\nMeridian is supported in both the day and hour views.\nTo use it, just enable the showMeridian property.\n\n* Hour view - meridian\n\n.. image:: https://raw.github.com/smalot/bootstrap-datetimepicker/master/screenshot/standard_hour_meridian.png\n\n\nInstallation\n------------\n\n#. Install django-datetime-widget using pip. For example::\n\n pip install django-datetime-widget\n\n#. Add ``datetimewidget`` to your INSTALLED_APPS.\n\nIf you want to use localization:\n\n#. Set USE_L10N = True, USE_TZ = True and USE_I18N = True in settings.py\n\n#. Add 'django.middleware.locale.LocaleMiddleware' to MIDDLEWARE_CLASSES in settings.py\n\n#. When you create the widget add usel10n = True like attribute : DateTimeWidget(usel10n=True)\n\nBasic Configuration\n-------------------\n#. Create your model-form and set DateTimeWidget widget to your DateTimeField ::\n\n from datetimewidget.widgets import DateTimeWidget\n\n class yourForm(forms.ModelForm):\n class Meta:\n model = yourModel\n widgets = {\n #Use localization and bootstrap 3\n 'datetime': DateTimeWidget(attrs={'id':\"yourdatetimeid\"}, usel10n = True, bootstrap_version=3)\n }\n\n#. Download `twitter bootstrap `_ to your static file folder.\n\n#. Add in your form template links to jquery, bootstrap and form.media::\n\n \n ....\n \n \n \n {{ form.media }}\n\n ....\n \n \n
\n {% csrf_token %}\n {{ form.as_table }}\n \n
\n \n\n\n#. Optional: you can add option dictionary to DatetimeWidget to customize your input, for example to have date time with meridian::\n\n\n dateTimeOptions = {\n 'format': 'dd/mm/yyyy HH:ii P',\n 'autoclose': True,\n 'showMeridian' : True\n }\n widgets = {\n #NOT Use localization and set a default format\n 'datetime': DateTimeWidget(options = dateTimeOptions)\n }\n\n!!! If you add 'format' into options and in the same time set usel10n as True the first one is ignored. !!!\n\nOptions\n=======\nThe options attribute can accept the following:\n* format\n\nString. Default: 'dd/mm/yyyy hh:ii'\n\nThe date format, combination of P, hh, HH , ii, ss, dd, yy, yyyy.\n\n * P : meridian in upper case ('AM' or 'PM') - according to locale file\n * ss : seconds, 2 digits with leading zeros\n * ii : minutes, 2 digits with leading zeros\n * hh : hour, 2 digits with leading zeros - 24-hour format\n * HH : hour, 2 digits with leading zeros - 12-hour format\n * dd : day of the month, 2 digits with leading zeros\n * yy : two digit representation of a year\n * yyyy : full numeric representation of a year, 4 digits\n\n* weekStart\n\nInteger. Default: 0\n\nDay of the week start. '0' (Sunday) to '6' (Saturday)\n\n* startDate\n\nDate. Default: Beginning of time\n\nThe earliest date that may be selected; all earlier dates will be disabled.\n\n* endDate\n\nDate. Default: End of time\n\nThe latest date that may be selected; all later dates will be disabled.\n\n* daysOfWeekDisabled\n\nString. Default: ''\n\nDays of the week that should be disabled. Values are 0 (Sunday) to 6 (Saturday). Multiple values should be comma-separated. Example: disable weekends: '0,6'.\n\n* autoclose\n\nString. Default: 'true'\n\nWhether or not to close the datetimepicker immediately when a date is selected.\n\n* startView\n\nInteger. Default: 2\n\nThe view that the datetimepicker should show when it is opened.\nAccepts values of :\n * '0' for the hour view\n * '1' for the day view\n * '2' for month view (the default)\n * '3' for the 12-month overview\n * '4' for the 10-year overview. Useful for date-of-birth datetimepickers.\n\n* minView\n\nInteger. Default: 0\n\nThe lowest view that the datetimepicker should show.\n\n* maxView\n\nInteger. Default: 4\n\nThe highest view that the datetimepicker should show.\n\n* todayBtn\n\nBoolean. Default: False\n\nIf true , displays a \"Today\" button at the bottom of the datetimepicker to select the current date. If true, the \"Today\" button will only move the current date into view.\n\n* todayHighlight\n\nBoolean. Default: False\n\nIf true, highlights the current date.\n\n* minuteStep\n\nInteger. Default: 5\n\nThe increment used to build the hour view. A button is created for each minuteStep minutes.\n\n* pickerPosition\n\nString. Default: 'bottom-right' (other supported value : 'bottom-left')\n\nThis option allows to place the picker just under the input field for the component implementation instead of the default position which is at the bottom right of the button.\n\n* showMeridian\n\nBoolean. Default: False\n\nThis option will enable meridian views for day and hour views.\n\n* clearBtn\n\nBoolean. Default: False\n\nIf true, displays a \"Clear\" button at the rigth side of the input value.\n\nCHANGELOG\n---------\n* 0.9.3V\n \n * FIX #48 \n * Python 3 support \n\n* 0.9.2V\n\n * FIX #46\n\n* 0.9.1V\n\n * python options are correct converted to the javascript options.\n\n * FIX #38 #40.\n\n * code refactor and bug fixes.\n\n* 0.9V\n \n * Update bootstrap datetime picker to the last version.\n \n * CLOSE #20 (support bootstrap 2 and 3).\n \n * CLOSE #17 TimeWidget.\n \n * CLOSE #16 DateWidget.\n \n * new clear button at the rigth side of the input value.\n \n * add dateTimeExample django project.\n\n* 0.6V\n \n * Add Clear button\n \n * Fix TypeError bug\n \n * Support localization\n \n * Update static file with last commit of bootstrap-datetime-picker\n \n * update js lib, native localization, thanks to @quantum13\n \n * autoclose is true by default\n\nContribute\n----------\n\n1. Check for open issues or open a fresh issue to start a discussion around a feature idea or a bug. There is a `Contributor Friendly`_ tag for issues that should be ideal for people who are not very familiar with the codebase yet.\n \n * If you feel uncomfortable or uncertain about an issue or your changes, feel free to email @asaglimbeni and he will happily help you via email, Skype, remote pairing or whatever you are comfortable with.\n\n2. Fork develop branch from `the repository`_ on GitHub to start making your changes to the **develop** branch (or branch off of it).\n3. Please, shows that the bug was fixed or that the feature works as expected.\n4. Send a pull request and bug the maintainer until it gets merged and published. :)\n5. Your changes will be released on the next version of django_datetime_widget!\n\n.. _`the repository`: https://github.com/asaglimbeni/django-datetime-widget\n.. _Contributor Friendly: https://github.com/asaglimbeni/django-datetime-widget/issues?direction=desc&labels=Contributor+Friendly&page=1&sort=updated&state=open\n\n\nTODO\n----\n#. widget for DateTime range.", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "UNKNOWN", "keywords": null, "license": "BSD", "maintainer": null, "maintainer_email": null, "name": "django-datetime-widget", "package_url": "https://pypi.org/project/django-datetime-widget/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/django-datetime-widget/", "project_urls": { "Download": "UNKNOWN", "Homepage": "UNKNOWN" }, "release_url": "https://pypi.org/project/django-datetime-widget/0.9.3/", "requires_dist": null, "requires_python": null, "summary": "Django-datetime-widget is a simple and clean widget for DateField, Timefiled and DateTimeField in Django framework. It is based on Bootstrap datetime picker, supports both Bootstrap 3 and Bootstrap 2", "version": "0.9.3" }, "last_serial": 1327854, "releases": { "0.5": [ { "comment_text": "", "digests": { "md5": "640ba65b689e8a9e40c65b19cdbe8082", "sha256": "04f9f7961450c2c2cc93d74012ad452c2f0dc49205bbd16cfe164f603c276af1" }, "downloads": -1, "filename": "django-datetime-widget-0.5.tar.gz", "has_sig": false, "md5_digest": "640ba65b689e8a9e40c65b19cdbe8082", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 20517, "upload_time": "2013-03-08T15:46:34", "url": "https://files.pythonhosted.org/packages/0c/43/c8cb24d85463faf27b0dfdef7b5d0f38ff45a12e8b25c8ba5566819354ad/django-datetime-widget-0.5.tar.gz" } ], "0.5.3a": [ { "comment_text": "", "digests": { "md5": "4be80b891a13daf323a0e1eb08ea1971", "sha256": "28164d1771d4b8533da6919424899b5c3066ef111dbf9fa690ac31598eff3f61" }, "downloads": -1, "filename": "django-datetime-widget-0.5.3a.tar.gz", "has_sig": false, "md5_digest": "4be80b891a13daf323a0e1eb08ea1971", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 20637, "upload_time": "2013-05-30T12:32:25", "url": "https://files.pythonhosted.org/packages/35/f6/fe2e89dbdfac46661320998030689fa1b04bf985735cc1710fbb2c7b04b5/django-datetime-widget-0.5.3a.tar.gz" } ], "0.6": [ { "comment_text": "", "digests": { "md5": "f9a3c8f04443ea366ab2a1db4a0d570d", "sha256": "361aefed56793d11553ae07975814a1b7df87e21a55c9650d2762571981171b2" }, "downloads": -1, "filename": "django-datetime-widget-0.6.tar.gz", "has_sig": false, "md5_digest": "f9a3c8f04443ea366ab2a1db4a0d570d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 34292, "upload_time": "2013-09-05T17:30:36", "url": "https://files.pythonhosted.org/packages/37/ce/05b2b2a0a7ba5d0a780cedb4c1f95fbba6b822f68bfa75eec66a57be4c87/django-datetime-widget-0.6.tar.gz" } ], "0.9": [ { "comment_text": "", "digests": { "md5": "0cf87fbca0ce15ec2e88354de9464cd0", "sha256": "492b975485b85bc031f7478193aba8ca2393c7d52fda89687277df9c19d0e1bf" }, "downloads": -1, "filename": "django-datetime-widget-0.9.tar.gz", "has_sig": false, "md5_digest": "0cf87fbca0ce15ec2e88354de9464cd0", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 36701, "upload_time": "2014-07-30T14:59:47", "url": "https://files.pythonhosted.org/packages/0a/59/0a7d471f6776812d33b340fee98914823b36c0ed2ce1a5430cb17707abb3/django-datetime-widget-0.9.tar.gz" } ], "0.9.1": [ { "comment_text": "", "digests": { "md5": "3d08b16d3c7e7daf465b82bb511a9dc0", "sha256": "a727eacdccda3a1e0194d99be039026a213c3582dc56226026b75e2596e9ad00" }, "downloads": -1, "filename": "django-datetime-widget-0.9.1.tar.gz", "has_sig": false, "md5_digest": "3d08b16d3c7e7daf465b82bb511a9dc0", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 34350, "upload_time": "2014-10-09T10:44:31", "url": "https://files.pythonhosted.org/packages/f4/8f/aa494d739f990b250523467dc5c4f5b6ad4c566a1475e3ac5c28611da341/django-datetime-widget-0.9.1.tar.gz" } ], "0.9.2": [ { "comment_text": "", "digests": { "md5": "994b59c2e0b631ec0f082d979c2aebfa", "sha256": "ca79f289800612fbc30f702885378c89be0f7777cfd0fc3651f1d1d5e7b72974" }, "downloads": -1, "filename": "django-datetime-widget-0.9.2.tar.gz", "has_sig": false, "md5_digest": "994b59c2e0b631ec0f082d979c2aebfa", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 37466, "upload_time": "2014-10-14T15:11:32", "url": "https://files.pythonhosted.org/packages/35/ce/f17e4f6b344620cfe27ea76d1076fb9b47132e1a716581be5c804badd990/django-datetime-widget-0.9.2.tar.gz" } ], "0.9.3": [ { "comment_text": "", "digests": { "md5": "72ec2dd3c2d2f9e324bae6052e38cd7f", "sha256": "bd727b466b7f4bbc23f3a9ec571ef1e2e9977ef1b83a296eb7b796580a168ced" }, "downloads": -1, "filename": "django-datetime-widget-0.9.3.tar.gz", "has_sig": false, "md5_digest": "72ec2dd3c2d2f9e324bae6052e38cd7f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 37510, "upload_time": "2014-12-02T09:58:47", "url": "https://files.pythonhosted.org/packages/8f/db/d6442e04c20a9dbf6e453b3c6ccf80ebf2677fb5e55eccd3122726facbf2/django-datetime-widget-0.9.3.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "72ec2dd3c2d2f9e324bae6052e38cd7f", "sha256": "bd727b466b7f4bbc23f3a9ec571ef1e2e9977ef1b83a296eb7b796580a168ced" }, "downloads": -1, "filename": "django-datetime-widget-0.9.3.tar.gz", "has_sig": false, "md5_digest": "72ec2dd3c2d2f9e324bae6052e38cd7f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 37510, "upload_time": "2014-12-02T09:58:47", "url": "https://files.pythonhosted.org/packages/8f/db/d6442e04c20a9dbf6e453b3c6ccf80ebf2677fb5e55eccd3122726facbf2/django-datetime-widget-0.9.3.tar.gz" } ] }