Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use plone.app.z3cform.widgets.OrderedSelect in Plone 6.1 #171

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:

- name: Setup Plone ${{ matrix.plone }} with Python ${{ matrix.python }}
id: setup
uses: plone/setup-plone@v2.0.0
uses: plone/setup-plone@v3.0.0
with:
python-version: ${{ matrix.python }}
plone-version: ${{ matrix.plone }}
Expand Down
3 changes: 2 additions & 1 deletion CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ New features:

Bug fixes:

- *add item here*
- Use `plone.app.z3cform.widgets.OrderedSelect` in Plone 6.1
[petschki]


3.1.5 (2024-11-05)
Expand Down
8 changes: 7 additions & 1 deletion src/collective/taxonomy/widget.py
Original file line number Diff line number Diff line change
@@ -1,14 +1,20 @@
from collective.taxonomy.interfaces import ITaxonomySelectWidget
from plone.memoize import ram
from z3c.form import interfaces
from z3c.form.browser.orderedselect import OrderedSelectWidget
from z3c.form.widget import FieldWidget

import zope.component
import zope.interface
import zope.schema.interfaces


try:
# Plone 6.1
from plone.app.z3cform.widgets.orderedselect import OrderedSelectWidget
except ImportError:
from z3c.form.browser.orderedselect import OrderedSelectWidget


def _items_cachekey(fun, self):
# try to get modified time of taxonomy utility
try:
Expand Down
Loading
Loading