TTW way of registering/creating new views for Content Types

Hi,

I am looking for a TTW way of creating and registering views for Content Types...I see this 21. Views II: A Default View for “Talk” — Plone Training 2021 documentation in the mastering plone training

But it only seems to talk about how to define/register it on the zcml side, does that mean that there is no way of doing this purely ttw?

Thanks in advance!

You could try: GitHub - collective/collective.ambidexterity: TTW views, defaults, validators and vocabularies for Dexterity content types.

Attempting to take a look at it,

bin/buildout runs without any issues after adding it to my eggs,

image

But when attempting to start my plone instance (bin/plonectl fg)

I'm getting this error message

ModuleNotFoundError: No module named 'default_script'

in the init.py for ambidexterity,

Plone/buildout-cache/eggs/cp38/collective.ambidexterity-1.0-py3.8.egg/collective/ambidexterity/init.py", line 25, in
from default_script import default # NOQA

Any ideas what may be going on there?

Ambidexterity is for Classic Plone. For Plone 6 (i.e. with Volto) you can look at GitHub - eea/volto-metadata-block: Metadata Block Volto add-on that enables Document metadata insertion within the Blocks area.. Watch the talk: EEA Volto Add-ons — Plone Conference Online 2020, December 5-13, 2020
Maybe @avoinea has a take on if your use-case is possible yet.

Check GitHub - collective/awesome-volto: A curated list of everything that makes Volto awesome for more Volto Addons

2 Likes

Volto has built-in support for dynamic views by using Blocks

If you need more, you can indeed, as @pbauer says, extend it with Volto add-ons

See more Volto add-ons on npm

See also the awesome collection of trainings that will help you extend Plone Backend & Frontend with your own add-ons.

Last but not least Custom View training

Plone Foundation Code of Conduct