An add-on for Plone
Project description
Design Plone Io-Prenoto
This product is designed to integrate redturtle.prenotazioni package with design.plone.contenttypes
PrenotazioniFolder additional fields
There is a behavior that adds some additional fields:
Uffici correlati
Orario di apertura
Rest API
Servizio serializer
There is a customization of Servizio serializer that adds an additional field:
referenced_by_prenotazioni_folder which idicates if it has backreferences to PrenotazioniFolder (design.plone.ioprenoto) throught correlated UO (with “Uffici correlati” field)
PrenotazioniFolder serializer
There is a customization of PrenotazioniFolder serializer that redirects to ‘/prenotazione-appuntamento’ if the user has not design.plone.ioprenoto.ManagePrenotazioni.
@bookable-uo-list
Endpoint that returns a list of UnitaOrganizzativa contents that have at least one PrenotazioniFolder that relates to it (with “Uffici correlati” field).
Parameters:
uid: The uid of a Servizio.
The endpoint can be called with a GET request:
curl -i http://localhost:8080/Plone/@bookable-uo-list -H 'Accept: application/json'
Response:
{ "@id": "http://localhost:8080/Plone/@bookable-uo-list", "items": [ { "@id": "...", "title": "...", "id": "...", "prenotazioni_folder": [ { "@id": "http://localhost:8080/Plone/prenotazioni-folder", "address": { "@id": "http://localhost:8080/Plone/a-venue", "@type": "Venue", "city": "Ferrara", "geolocation": { "latitude": 1111, "longitude": 2222, }, ... } } ], } ] }
If uid parameter is passed, only UnitaOrganizzative related to that Servizio (with canale_fisico relation field) will be returned.
@bookable-list
Endpoint that returns a list of Bookable.
The endpoint can be called with a GET request:
curl -i http://localhost:8080/Plone/@bookable-list -H 'Accept: application/json'
Response:
{ "@id": "http://localhost:8080/Plone/@bookable-list", "items": [ { "@id": "...", "title": "...", "url": "...", "booking_types": [], } ] }
Installation
Install design.plone.ioprenoto by adding it to your buildout:
[buildout] ... eggs = design.plone.ioprenoto
and then running bin/buildout
Contribute
Issue Tracker: https://github.com/RedTurtle/design.plone.ioprenoto/issues
Source Code: https://github.com/RedTurtle/design.plone.ioprenoto
Notes
design.plone.ioprenoto has been tested with Plone 6 and works with Python 3.
Contributors
RedTurtle, info@redturtle.it
Changelog
1.0.6 (2023-06-16)
On message creation use sent state. [folix-01]
1.0.5 (2023-06-16)
Add message on Prenotazione creation (#42314). [folix-01]
1.0.4 (2023-06-14)
Overrides @bookings for booking urls [mamico]
1.0.3 (2023-06-13)
typo “corellati” vs. “correlati” (+ i18n) [mamico]
1.0.2 (2023-06-12)
Fix uo-bookable-list esporta solo le stanze pubbliche [mamico]
Customize some stringinterp adapters to use io-comune frontend view. [cekk]
1.0.1 (2023-04-06)
Fix CI struments configs. [foxtrot-dfm1]
1.0.0 (2023-04-06)
Initial release. [RedTurtle]
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for design.plone.ioprenoto-1.0.6.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7cf11d162bbb700e0795fa4bc35deb0547d56304f27e2e8bb51eaf1761effd5f |
|
MD5 | 143a411cfa6494fc40f210565b42a297 |
|
BLAKE2b-256 | ceabf38aa3f96ca7e0f9cc14e4e7f479aa8775d02c7e17d91f8fcfb4f09b674f |
Hashes for design.plone.ioprenoto-1.0.6-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4712aab5b7c40cc7986fcbd20bd199d2f2ad16ca13b78952965b049a5232baf0 |
|
MD5 | f9be17f3414dc15e6e7f201d84b1ff62 |
|
BLAKE2b-256 | 4f40053c2d3deeebac22bbb2cc32ed9b64fb8397d25f7f41908d01973a6a075f |