Skip to main content

Design Plone Policy

Pacchetto di policy per un sito Plone AGID.

python version ci

Features

Installando questo pacchetto, si inizializza un sito Plone Agid.

Creazione struttura del sito

All’installazione di questo prodotto, oltre che l’installazione di tutte le dipendenze, viene anche eseguita la creazione in automatico di una serie di cartelle utili per la gestione dei contenuti richiesta da Agid.

Tipi ricercabili

Installando questo prodotto, si disabilitano alcuni tipi ricercabili (così non vengon mostrati in @search-filters).

Customer satisfaction

Viene installato un plugin aggiuntivo (rer.customersatisfaction) per poter esprimere voti sulle pagine del portale Agid.

Per poter usare questo prodotto, va salvata la chiave privata per recaptcha v3 in una variabile d’ambiente (RECAPTCHA_PRIVATE_KEY). La chiave pubblica viene usata dal client Volto.

Endpoint per plone.restapi

@search-filters

Questo endpoint serve al frontend di Volto, per popolare il menu e i filtri per la ricerca:

> curl -i http://localhost:8080/Plone/@search-filters -H 'Accept: application/json'

Ritorna un json con le sezioni principali, la lista degli argomenti e i tipi di contenuto ricercabili (tradotti):

{
    "sections":{
        "amministrazione":{
            "@id": "",
            "path": "",
            "title": "",
            "items": [
                {
                    "@id": "",
                    "path": "",
                    "title": "",
                },
                ...
            ]
        }
        "documenti-e-dati": {...}
        "novita": {...}
        "servizi": {...}
    },
    "topics": [
        {
            "@id": "",
            "path": "",
            "title": "",
        },
        ...
    ],
    "portal_types": [
        ...
        {
          "label": "Document",
          "id": "Page"
        }
        ...
    ]
}

@search-bandi-filters

Questo endpoint serve al frontend di Volto, per popolare il menu e i filtri per la ricerca dei bandi:

> curl -i http://localhost:8080/Plone/@search-bandi-filters -H 'Accept: application/json'

Ritorna un json con la lista degli uffici (UO) referenziati da almeno un Bando e la lista delle parole chiave utilizzate dai Bandi:

{
  "offices": [
    {
      "key": "87bb96d90b6e42ee9db01ab2ab7543d5",
      "label": "uo 1"
    }
  ],
  "subjects": [
    "bar",
    "foo"
  ]
}

@send-action-form

Questo endpoint va chiamato su un contesto con i blocchi abilitati e serve al frontend di Volto, per inviare via mail il form compilato:

> curl -i -X POST http://localhost:8080/Plone/document/@send-action-form -H 'Accept: application/json' -H 'Content-Type: application/json' --data-raw '{"from": "john@doe.com", "message": "Just want to say hi.", "block_id": "123456"}'

All’endpoint vanno passati i seguenti parametri:

  • block_id [obbligatorio]: l’id del blocco di tipo “form” che è stato compilato

  • message [obbligatorio]: il messaggio da inviare

  • from: l’indirizzo email del mittente. Se non presente, viene utilizzato il campo default_from del blocco

  • subject: l’oggetto della mail. Se non presente, viene utilizzato il campo default_subject del blocco

  • attachments: eventuali allegati riferiti a campi “file upload” inseriti nel form.

La struttura degli attachments è la seguente:

{
    "block_id": "foo",
    ...
    "attachments": {
        "field_id": {
            "data": "the content of the file",
            "content-type": "application/pdf",
            "filename": "example.pdf"
        }
    }
}

Se l’invio va a buon fine, viene tornata una risposta con 204.

Amministrazione trasparente

La vista “crea_area_trasparenza” crea la struttura per l’area “Amministrazione Trasparente”. Si può lanciare dalla root del sito.

Vocabolari per gli anonimi

redturtle.volto permette di esporre dei vocabolari anche agli utenti anonimi.

In questo prodotto aggiungiamo quelli che servono per io-comune.

Installazione

Per installare design.plone.policy bisogna per prima cosa aggiungerlo al buildout:

[buildout]

...

eggs =
    design.plone.policy

e poi lanciare il buildout con bin/buildout.

Successivamente va installato dal pannello di controllo di Plone.

Forzare autenticazione

Se le richieste arrivano con un header X-ForceAuth Plone forza l’autenticazione per quelle richieste, il meccanismo è utile ad esempiop se si vuole fare accedere alla ZMI o alle interfacce Plone legacy senza però esporle pubblicamente.

Test con Volto standalone

Si può usare questo prodotto anche da solo, per fare delle demo veloci di Volto, senza dover per forza creare un nuovo progetto/buildout.

E’ presente un file buildout.cfg anche in questo prodotto, quindi basta lanciare il buildout ed avviare l’istanza.

Il sito Plone sarà esposto sulla porta standard (8080) ed è già configurato per accettare chiamate dalla porta 3000 (quindi Volto dovrà girare su quella porta, che poi è il suo default).

Contribuisci

Licenza

Questo progetto è rilasciato con licenza GPLv2.

Autori

Questo progetto è stato sviluppato da RedTurtle Technology.

RedTurtle Technology Site

Contributors

Changelog

4.0.12 (2026-10-14)

  • Resize (max 1600px) and convert to WebP the base64 images stored inline in “testo_riquadro_immagine” and “alert” blocks, on save and with an upgrade step for existing contents, to reduce the page payload (backport of #90). [mamico]

4.0.11 (2024-09-05)

4.0.10 (2024-07-12)

  • search_sections in IDesignPloneSettings has a new filed in each section: expandItems that is a boolean to decide if the items of the section should be expanded or not (default is True). [mamico]

4.0.9 (2024-04-11)

  • @bandi-search-filters: if called on a specific folder returns only related offices of bandi inside that folder. [daniele]

4.0.8 (2024-02-21)

  • @bandi-search-filters: registered for a more generic interface. [daniele]

4.0.7 (2024-02-20)

  • @bandi-search-filters: if called on a specific folder returns only tipologies and subjects of bandi inside that folder. [daniele]

4.0.6 (2023-09-08)

  • Fixed to 2022 upgrade step. [folix-01]

4.0.5 (2023-08-16)

  • Upgrade step to remove the twitter feeds [folix-01]

  • Set plone.base.interfaces.syndication.ISiteSyndicationSettings.show_author_info to False by default. [folix-01]

  • Add X-ForceAuth header and iw.rejectanonymous backport from 5.0.0 #48 [mamico]

  • Remove twitter feeds. [folix-01]

4.0.4 (2023-07-07)

  • Remove twitter feeds. [folix-01]

4.0.3 (2023-04-05)

  • Fix test dependencies. [cekk]

  • Customize Access inactive portal content permission. [cekk]

4.0.2 (2023-01-30)

  • Aggiunto ordinamento per il filtro “Argomenti” nella pagina di ricerca. [lucabel]

4.0.1 (2022-12-07)

  • Add “data-element” to custom attributes in html filters. [cekk]

4.0.0 (2022-11-07)

  • Fix formsupport dependency to use honeypot and upgrade-step to set it in forms. [cekk]

3.0.0 (2022-08-16)

  • Remove unused dependency in tests. [cekk]

2.12.0 (2022-07-05)

  • scrub sensitive information for sentry [mamico]

  • Improve @bandi-search-filters speed. [cekk]

2.11.3 (2022-01-27)

  • Fix upgrade-step. [cekk]

2.11.2 (2022-01-27)

  • Fix image miniature with 65536. [cekk]

2.11.1 (2022-01-27)

  • Add new image miniature (midi). [cekk]

2.11.0 (2021-12-27)

  • Add default blocks to automatically created pages. [cekk]

2.10.0 (2021-12-01)

  • Remove enabled_vocabularies implementation because in recent plone.restapi (>8.15.2) there is a standard way. [cekk]

2.9.1 (2021-11-04)

  • Install redturtle.faq by default. [cekk]

2.9.0 (2021-11-03)

  • Add redturtle.faq dependency (it will not be installed by default). [cekk]

2.8.0 (2021-10-22)

  • Add rer.customersatisfaction dependency. [cekk]

2.7.0 (2021-10-11)

  • p.a.caching rules for rest api services. [cekk]

2.6.1 (2021-10-01)

  • Updated blocks generation for “crea_area_trasparenza” view. [daniele]

2.6.0 (2021-09-29)

  • Remove limited content-types in initial structure creation. [cekk]

2.5.0 (2021-09-20)

  • Refactored search filters endpoints to be more efficient. [cekk]

  • Can also add “Persona” in Politici folder. [cekk]

  • Add collective.volto.subfooter as dependency. [cekk]

2.4.0 (2021-08-24)

  • Add list of available vocabularies for Anonymous. [cekk]

2.3.0 (2021-07-07)

  • Install collective.volto.subsites by default and add a set of colors. [cekk]

2.2.0 (2021-06-08)

  • [new] @search-bandi-filters endpoint. [cekk]

2.1.2 (2021-05-14)

  • [new] Content type ‘Bando’ is admitted by default in ‘Documenti e dati’ folder. [arsenico13]

2.1.1 (2021-05-04)

  • Fix upgrade-step. [cekk]

2.1.0 (2021-05-04)

  • Handle multiple twitter accounts in twitter endpoint. [cekk]

  • Change twitter token field in registry (now is managed with interface). [cekk]

2.0.0 (2021-04-30)

  • Update with new settings values from design.plone.contenttypes (version 3.0.0). [cekk]

  • [dev] Fix CI [arsenico13]

  • Add custom image scales [nzambello]

  • search-filters endpoint now return also a list of searchable portal_types. [cekk]

  • Disable some types from types_not_searched. [cekk]

1.1.0 (2021-03-24)

  • Remove form route and add collective.volto.formsupport dependency. [cekk]

1.0.8 (2021-02-25)

  • On install, set default search sections. [cekk]

1.0.7 (2021-02-19)

  • Fix typo. [cekk]

1.0.6 (2021-02-19)

  • Do not run dependencies when upgrading plone.app.registry. [cekk]

1.0.5 (2021-02-11)

  • Install collective.volto.socialsettings by default. [cekk]

1.0.4 (2021-02-05)

  • Add collective.volto.secondarymenu dependency. [cekk]

  • Enable sitemap by default. [cekk]

1.0.3 (2021-01-28)

  • Handle Unauthorized in search-filters endpoint. [cekk]

1.0.2 (2021-01-11)

  • Manage also attachments in @send-action-form endpoint. [cekk]

1.0.1 (2020-12-18)

  • Added view to create trasparenza structure. [daniele]

  • Fixed folders creation when installing. [daniele]

  • Add twitter-feed endpoint. [cekk]

1.0.0 (2020-12-07)

  • Initial release. [cekk]

Metadata

Release files for design.plone.policy 4.0.12

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for design.plone.policy 4.0.12
File Size Uploaded
design_plone_policy-4.0.12.tar.gz 51.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for design.plone.policy 4.0.12
File Interpreter ABI Platform
design_plone_policy-4.0.12-py3-none-any.whl Python 3 none any Details

Total release size: 107.1 kB

Release files / design_plone_policy-4.0.12.tar.gz

Download URL design_plone_policy-4.0.12.tar.gz
Size 51.9 kB
Tags Source
SHA-256 checksum
How to use checksums
d04b6d950bf680fed6eeab3d9a040e9936f2dab2736f91ed37338721edde3d3b
BLAKE2b-256 checksum
How to use checksums
830ca4b0d812a560f644d08de51f9fdde63636767d474b30a63213003c506758
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.14

Release files / design_plone_policy-4.0.12-py3-none-any.whl

Download URL design_plone_policy-4.0.12-py3-none-any.whl
Size 55.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
21273dacc74120110234b0b00e58da7cb2c452a41cc0b9ee8c3c9630a85488de
BLAKE2b-256 checksum
How to use checksums
4fb0e369f374a3a29d2c2e609037ba9940ce1d51329f1ac0876a776851d6fc3c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.14

Release history Release notifications | RSS feed

5.0.21

2 release files

5.0.20

2 release files

5.0.19

2 release files

5.0.12

2 release files

5.0.9

1 release file

5.0.8

2 release files

5.0.7

2 release files

5.0.6

1 release file

5.0.5

1 release file

5.0.4

1 release file

5.0.3

1 release file

5.0.2

1 release file

5.0.1

1 release file

5.0.0

1 release file

This release

4.0.12 This release

2 release files

4.0.10

2 release files

4.0.9

1 release file

4.0.8

1 release file

4.0.7

1 release file

4.0.6

1 release file

4.0.5

1 release file

4.0.4

1 release file

4.0.3

1 release file

4.0.2

1 release file

4.0.1

1 release file

4.0.0

1 release file

3.0.0

1 release file

2.12.0

1 release file

2.11.3

1 release file

2.11.2

1 release file

2.11.0

1 release file

2.10.0

1 release file

2.9.1

1 release file

2.9.0

1 release file

2.8.0

1 release file

2.7.0

1 release file

2.6.1

1 release file

2.6.0

1 release file

2.5.0

1 release file

2.4.0

1 release file

2.3.0

1 release file

2.2.0

1 release file

2.1.2

1 release file

2.1.1

1 release file

2.1.0

1 release file

2.0.0

1 release file

1.1.0

1 release file

1.0.8

1 release file

1.0.7

1 release file

1.0.6

1 release file

1.0.5

1 release file

1.0.4

1 release file

1.0.3

1 release file

1.0.2

1 release file

1.0.1

1 release file

1.0.0

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page