Skip to main content

eea.facetednavigation widget that enables selecting a collection (among several) as base filter

Project description

.. image:: https://travis-ci.org/collective/collective.eeafaceted.collectionwidget.svg
:target: https://travis-ci.org/collective/collective.eeafaceted.collectionwidget


.. image:: https://coveralls.io/repos/collective/collective.eeafaceted.collectionwidget/badge.svg?branch=master&service=github
:target: https://coveralls.io/github/collective/collective.eeafaceted.collectionwidget?branch=master

==========================================================================
collective.eeafaceted.collectionwidget
==========================================================================

Package adding a widget for eea.facetednavigation that list collections as base searches

* `Source code @ GitHub <https://github.com/collective/collective.eeafaceted.collectionwidget>`_
* `Continuous Integration @ Travis-CI <http://travis-ci.org/collective/collective.eeafaceted.collectionwidget>`_

How it works
============

Once installed, a new widget `Collection Link` is available while configuring the faceted navigation.
If you add Collections to a folder on which faceted navigation is enabled, the widget will display
the found Collections and use it as base searches.
A special content DashboardCollection is also provided, it is based on the Collection but use additional
behaviors :
- The 'DashboardCollection' behavior that provides an extra field showNumberOfItems, making it possible
to display the counter on a per DashboardCollection basis;
- The 'TAL condition' behavior that adds a field into which defining a TAL expression that will make it
possible to hide or show a Collection in the widget.

Installation
============

To install `collective.eeafaceted.collectionwidget` you simply add ``collective.eeafaceted.collectionwidget``
to the list of eggs in your buildout, use make run to launch buildout and start Plone.
Then, install `collective.eeafaceted.collectionwidget` using the Add-ons control panel.

Configuration
=============

All that is necessary when adding this kind of widget in a faceted navigation is to enter a name for the displayed widget and to select the vocabulary `collective.eeafaceted.collectionwidget.collectionvocabulary`. It will automatically display the Collections contained in the folder the faceted navigation is configured on. It is also possible to group Collections by category, to do so, instead of adding the Collections directly in the folder, you can create a subfolder that will contain the Collections.

eea.facetednavigation version
=============================

From version 1.0, the widget requires at least `eea.facetednavigation` 10.0 where widget is built using `z3c.form`.
If you are using `eea.facetednavigation` < 10.0, you need to use a version of `collective.eeafaceted.collectionwidget` < 1.0.

Contributors
============

- IMIO, support@imio.be

Changelog
=========


1.0 (2018-06-20)
----------------

- Make widget compatible with `eea.facetednavigation >= 10.0`.
This makes it no more compatible with older version.
[gbastien]
- Make package installable on both Plone4 and Plone5.
[gbastien]
- Rely on `plone.app.contenttypes` instead `plone.app.collection`.
[gbastien]
- Do not break to display the facetednavigation_view if no collection widget
defined, it is the case when just enabling the faceted navigation on a new
folder.
[gbastien]
- Added field `enabled` (default=True) on a DashboardCollection make it possible
to disable it so it is no more displayed in the collection widget (portlet).
We specifically do not use a workflow for DashboardCollection.
[gbastien]

0.9 (2018-05-25)
----------------

- Moved here some methods from imio.dashboard:
_get_criterion, getCollectionLinkCriterion, getCurrentCollection
[sgeulette]
- facetednavigation_view override to manage default collection widget redirection
[sgeulette]
- Added portal attribute on category view.
[sgeulette]

0.8 (2018-05-03)
----------------

- Fix wrong release version 0.7.
[gbastien]

0.7 (2018-05-03)
----------------

- Removed useless parameter `query` from `CollectionVocabulary.__call__`.
[gbastien]
- Use `zope.globalrequest.getRequest` and not `context.REQUEST`
to get the REQUEST.
[gbastien]

0.6 (2016-12-07)
----------------

- Add an option force_redirect_to in CollectionVocabulary to force generating
no_redirect=1 urls for all collections.
[vincentfretin]

- Don't modify the title of the page if the h1 has class dontupdate.
[vincentfretin]

- Fix bug with DateTime in kept_criteria_as_json.
[cedricmessiant]


0.5 (2016-05-13)
----------------

- Added plone.app.collection as a real dependency, this way it is present
and we make sure that the profile is installed.
[gbastien]


0.4 (2016-03-29)
----------------

- Adapted tests for eea.facetednavigation 8.8, moved to the collective,
prepare for release on pypi.python.org.
[gbastien]


0.3 (2016-03-03)
----------------

- Display number of collection items in the term view. Override
display_number_of_items method if you want to alter this behaviour.
[cedricmessiant]


0.2 (2015-09-03)
----------------

- The context for @@render_collection_widget_category is now the category
(folder) and the context for @@render_collection_widget_term is the
collection. (closes #11677)
[vincentfretin]

- When generating link to sub faceted, make sure every default values are
correctly initialized, especially value of the Collection widget for which
the id could be different than current faceted Collection widget id
[gbastien]

- If we use functionnality of sub folders where faceted navigation is enabled,
and the default collection is on one of these subfolders, do not redirect to
this default collection if we use the 'folder_contents' of the root folder or
user is systematically redirected to the subfolder and it is not possible
anymore to access on the root folder
[gbastien]

- Added portal_url attribute in RenderCategoryView
[sgeulette]

0.1 (2015-07-14)
----------------

- Initial release.
[IMIO]

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

File details

Details for the file collective.eeafaceted.collectionwidget-1.0.tar.gz.

File metadata

File hashes

Hashes for collective.eeafaceted.collectionwidget-1.0.tar.gz
Algorithm Hash digest
SHA256 2958008f9860909167a606c4ad64dd8cb9be884a596c47613af7d4d7dede72a8
MD5 6c2a179754328a8f92c136480a74895f
BLAKE2b-256 011ebb0b4556acb8175451c93887e66425f54a9e73a72966390f5b1a598890a0

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