{ "info": { "author": "Maik Derstappen", "author_email": "md@derico.de", "bugtrack_url": null, "classifiers": [ "Environment :: Web Environment", "Framework :: Plone", "Framework :: Plone :: 5.1", "Framework :: Plone :: 5.2", "Framework :: Plone :: Addon", "License :: OSI Approved :: GNU General Public License v2 (GPLv2)", "Operating System :: OS Independent", "Programming Language :: Python", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3.7" ], "description": ".. image:: https://secure.travis-ci.org/collective/collective.edtf_behavior.png?branch=master\n :target: http://travis-ci.org/collective/collective.edtf_behavior\n\n.. image:: https://coveralls.io/repos/github/collective/collective.edtf_behavior/badge.svg?branch=master\n :target: https://coveralls.io/github/collective/collective.edtf_behavior?branch=master\n :alt: Coveralls\n\n.. image:: https://img.shields.io/pypi/l/collective.edtf_behavior.svg\n :target: https://pypi.python.org/pypi/collective.edtf_behavior/\n :alt: License\n\n.. image:: https://badges.gitter.im/collective/collective.edtf_behavior.svg\n :alt: Join the chat at https://gitter.im/collective/collective.edtf_behavior\n :target: https://gitter.im/collective/collective.edtf_behavior?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge\n\n\n========================\ncollective.edtf_behavior\n========================\n\nA Plone behavior which provides a `EDTF `_ Date field and some indexes to search and sort on complex and historic dates.\n\nNote: the current implementation of the used library `python-edtf `_ , still uses an earlier draft of the standard: http://www.loc.gov/standards/datetime/pre-submission.html\n\n\nFeatures\n--------\n\n- Allows unspecific dates or date intervals: \"1989-11\" or \"1989-11~\" or \"1989-11-01/1989-11-30\"\n- Seasons: 2001-21 >> Spring, 2001\n- old dates like 03.08.1492\n- Search indexes: date_earliest and date_latest\n- Sort indexes: date_sort_ascending and date_sort_descending\n\n\nInstallation\n------------\n\nInstall collective.edtf_behavior by adding it to your buildout::\n\n [buildout]\n\n ...\n\n eggs =\n collective.edtf_behavior\n\n\nand then running ``bin/buildout``\n\nAfter you activated the add-on in the Plone Add-ons section, you can Enable this behavior on any Dexterity based content type.\n\nQuerying\n--------\n\n.. code-block:: python\n\n from plone import api\n\nfind any document which earliest date is 06.02.1920 or later.\n\n.. code-block:: python\n\n results = api.content.find(\n portal_type='Document',\n date_earliest={\n 'query': datetime.date(1920, 2, 6),\n 'range': 'min',\n },\n )\n\nfind any document which latest date is 11.11.1711 or earlier.\n\n.. code-block:: python\n\n results = api.content.find(\n portal_type='Document',\n date_latest={\n 'query': datetime.date(1711, 11, 11),\n 'range': 'max',\n },\n )\n\nThis package provides a `DateRangeInRangeIndex `_ named ``edtf_start_end_range``.\n\nfind all documents that fall at least with one start/end date of there interval into the range:\n\n.. code-block:: python\n\n results = api.content.find(\n portal_type='Document',\n edtf_start_end_range={\n 'start': datetime.date(1711, 11, 11),\n 'end': datetime.date(1920, 2, 6),\n },\n )\n\nFor more examples how to query the indexes, have a look at the `tests `_ .\n\n\nExtending it\n------------\n\nOne could improve indexing by using a DateRangeIndex, like the effectiveRange index in Plone if needed.\n\n.. code-block:: xml\n\n \n \n\n\nContribute\n----------\n\n- Issue Tracker: https://github.com/collective/collective.edtf_behavior/issues\n- Source Code: https://github.com/collective/collective.edtf_behavior\n\n\nSupport\n-------\n\nIf you are having issues, please let us know.\nYou can reach us on Gitter.\n\n\nLicense\n-------\n\nThe project is licensed under the GPLv2.\n\n\nContributors\n============\n\n- Maik Derstappen, md@derico.de\n\n\nChangelog\n=========\n\n\n1.0.3 (2019-08-26)\n------------------\n\n- Faxed test and test setup, small cleanup\n [MrTango]\n\n\n1.0.2 (2019-03-22)\n------------------\n\n- Add edtf_parseable validator (constraint) to edtf_behavior\n [MrTango]\n\n\n1.0.1 (2019-03-18)\n------------------\n\n- Add absolute_import statement to all files, to improve Py3 support, fix README syntax\n [MrTango]\n\n\n1.0 (2019-03-18)\n----------------\n\n- Add edtf_start_end_range index and document querying in the readme.\n [MrTango]\n\n\n1.0a1 (2019-03-14)\n------------------\n\n- Initial release, with EDTF behavior and 4 main indexes.\n [MrTango]", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://pypi.python.org/pypi/collective.edtf_behavior", "keywords": "Python Plone", "license": "GPL version 2", "maintainer": "", "maintainer_email": "", "name": "collective.edtf-behavior", "package_url": "https://pypi.org/project/collective.edtf-behavior/", "platform": "", "project_url": "https://pypi.org/project/collective.edtf-behavior/", "project_urls": { "Homepage": "https://pypi.python.org/pypi/collective.edtf_behavior" }, "release_url": "https://pypi.org/project/collective.edtf-behavior/1.0.3/", "requires_dist": null, "requires_python": "==2.7, >=3.7", "summary": "A EDTF behavior for Plone.", "version": "1.0.3" }, "last_serial": 5730657, "releases": { "1.0": [ { "comment_text": "", "digests": { "md5": "cb9176e58e8a1245d8ae434c7a429354", "sha256": "1d36d10b2e849c36e8dfe3db24103d3b09e8ce55f8939cc6039c62d0220a27bc" }, "downloads": -1, "filename": "collective.edtf_behavior-1.0.tar.gz", "has_sig": false, "md5_digest": "cb9176e58e8a1245d8ae434c7a429354", "packagetype": "sdist", "python_version": "source", "requires_python": "==2.7, >=3.7", "size": 17021, "upload_time": "2019-03-18T15:27:08", "url": "https://files.pythonhosted.org/packages/da/08/ab5e682719627364635c5d6a44431746add3271c56d31c3c91846a8903b0/collective.edtf_behavior-1.0.tar.gz" } ], "1.0.1": [ { "comment_text": "", "digests": { "md5": "a02b7b4af2d91ef9a778ed8eb8c053e5", "sha256": "8a70a338bcc97b69bd1f674c8f4e7f90961bc8436c7055feec49c44ecbbf2c87" }, "downloads": -1, "filename": "collective.edtf_behavior-1.0.1.tar.gz", "has_sig": false, "md5_digest": "a02b7b4af2d91ef9a778ed8eb8c053e5", "packagetype": "sdist", "python_version": "source", "requires_python": "==2.7, >=3.7", "size": 17135, "upload_time": "2019-03-18T15:47:28", "url": "https://files.pythonhosted.org/packages/88/75/1f33fb18b21f0f610273e6aff1c047a82734c0d2da443d7ff04943bf6db4/collective.edtf_behavior-1.0.1.tar.gz" } ], "1.0.2": [ { "comment_text": "", "digests": { "md5": "fe803364f59da0744adf24a119b44c44", "sha256": "3eaf0fef9f830f2aa110535ceb02dff70e15a9c07df6d7c1b4b030e167a0bcdc" }, "downloads": -1, "filename": "collective.edtf_behavior-1.0.2.tar.gz", "has_sig": false, "md5_digest": "fe803364f59da0744adf24a119b44c44", "packagetype": "sdist", "python_version": "source", "requires_python": "==2.7, >=3.7", "size": 17392, "upload_time": "2019-03-22T17:50:57", "url": "https://files.pythonhosted.org/packages/c2/4a/b8fee29eba6f6812d6280e4c6bb4175d16f73fe02f6fc8cf5ed7b631a1d3/collective.edtf_behavior-1.0.2.tar.gz" } ], "1.0.3": [ { "comment_text": "", "digests": { "md5": "da28d3114e6867ccbb8d0ba9c394ae97", "sha256": "cc99feefe666c0ce353b9556227bf04d746ba6dd933ec169f35e74290395626d" }, "downloads": -1, "filename": "collective.edtf_behavior-1.0.3.tar.gz", "has_sig": false, "md5_digest": "da28d3114e6867ccbb8d0ba9c394ae97", "packagetype": "sdist", "python_version": "source", "requires_python": "==2.7, >=3.7", "size": 18017, "upload_time": "2019-08-26T12:51:30", "url": "https://files.pythonhosted.org/packages/48/ba/f1fd6b1f59e396a5fd6c1adb7d44b5aff3f36aabae8681eeb5e5d0fbab96/collective.edtf_behavior-1.0.3.tar.gz" } ], "1.0a2.dev0": [ { "comment_text": "", "digests": { "md5": "495c2195b534c5b25c5612f1c01ad2d0", "sha256": "53bd0d0ae6d753daf09a3250caca6b8da4805fb05878eeb0bb1207c039d2c213" }, "downloads": -1, "filename": "collective.edtf_behavior-1.0a2.dev0.tar.gz", "has_sig": false, "md5_digest": "495c2195b534c5b25c5612f1c01ad2d0", "packagetype": "sdist", "python_version": "source", "requires_python": "==2.7", "size": 14455, "upload_time": "2019-03-14T13:31:20", "url": "https://files.pythonhosted.org/packages/4c/28/566eb9fa2a3b0eb5863c3f4ac08b3960a2ee2b1e7bec92ae36763eb4ce7d/collective.edtf_behavior-1.0a2.dev0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "da28d3114e6867ccbb8d0ba9c394ae97", "sha256": "cc99feefe666c0ce353b9556227bf04d746ba6dd933ec169f35e74290395626d" }, "downloads": -1, "filename": "collective.edtf_behavior-1.0.3.tar.gz", "has_sig": false, "md5_digest": "da28d3114e6867ccbb8d0ba9c394ae97", "packagetype": "sdist", "python_version": "source", "requires_python": "==2.7, >=3.7", "size": 18017, "upload_time": "2019-08-26T12:51:30", "url": "https://files.pythonhosted.org/packages/48/ba/f1fd6b1f59e396a5fd6c1adb7d44b5aff3f36aabae8681eeb5e5d0fbab96/collective.edtf_behavior-1.0.3.tar.gz" } ] }