io-sanita-theme 2.32.0 → 2.33.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/themes.yml +2 -0
- package/CHANGELOG.md +11 -0
- package/RELEASE.md +12 -0
- package/locales/en/LC_MESSAGES/volto.po +36 -1
- package/locales/it/LC_MESSAGES/volto.po +36 -1
- package/locales/volto.pot +37 -2
- package/package.json +1 -1
- package/src/components/Blocks/Listing/Table/TableTemplate.jsx +4 -1
- package/src/components/Blocks/SearchFarmacia/Body.jsx +9 -0
- package/src/components/Blocks/SearchFarmacia/SearchFilters.jsx +72 -69
- package/src/components/Blocks/SearchFarmacia/schema.js +34 -1
- package/src/components/Blocks/SearchMap/Body.jsx +96 -43
- package/src/components/Blocks/SearchMap/schema.js +24 -2
- package/locales/de/LC_MESSAGES/volto.po +0 -4216
- package/locales/de.json +0 -1
- package/locales/es/LC_MESSAGES/volto.po +0 -4218
- package/locales/es.json +0 -1
- package/locales/fr/LC_MESSAGES/volto.po +0 -4218
- package/locales/fr.json +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,16 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [2.33.0](https://github.com/RedTurtle/io-sanita-theme/compare/2.32.0...2.33.0) (2026-06-17)
|
|
4
|
+
|
|
5
|
+
### Features
|
|
6
|
+
|
|
7
|
+
* filtri configurabili (ente territoriale, comune, località) nel blocco Ricerca farmacie ([#154](https://github.com/RedTurtle/io-sanita-theme/issues/154)) ([338eba6](https://github.com/RedTurtle/io-sanita-theme/commit/338eba67fc8760bfdc3191a2474a8497cee8b23c))
|
|
8
|
+
* Search strutture - widget for type filter and description text for searchable text ([#156](https://github.com/RedTurtle/io-sanita-theme/issues/156)) ([625925a](https://github.com/RedTurtle/io-sanita-theme/commit/625925a3fa40299add2dfaa1f31e976ddbe83208))
|
|
9
|
+
|
|
10
|
+
### Maintenance
|
|
11
|
+
|
|
12
|
+
* cleanup unesed locales ([#155](https://github.com/RedTurtle/io-sanita-theme/issues/155)) ([c92e281](https://github.com/RedTurtle/io-sanita-theme/commit/c92e28158b5552dabcbfa20a44e8370dcc69dfbc))
|
|
13
|
+
|
|
3
14
|
## [2.32.0](https://github.com/RedTurtle/io-sanita-theme/compare/2.31.3...2.32.0) (2026-06-12)
|
|
4
15
|
|
|
5
16
|
### Features
|
package/RELEASE.md
CHANGED
|
@@ -41,6 +41,18 @@
|
|
|
41
41
|
- ...
|
|
42
42
|
-->
|
|
43
43
|
|
|
44
|
+
## Versione 2.33.0 (17/06/2026)
|
|
45
|
+
|
|
46
|
+
### Migliorie
|
|
47
|
+
|
|
48
|
+
- Nel blocco "Cerca strutture" è ora possibile personalizzare il testo descrittivo del campo di ricerca libero e se visualizzare il filtro per tipologia come pulsanti (comportamento di default) oppure come menu a tendina.
|
|
49
|
+
|
|
50
|
+
- Nel blocco "Ricerca farmacie" ora è possibile scegliere dalle impostazioni del blocco quali filtri mostrare: ente territoriale, comune e località, sia per la ricerca dei turni che delle ferie. I blocchi esistenti mantengono il comportamento attuale.
|
|
51
|
+
|
|
52
|
+
### Fix
|
|
53
|
+
|
|
54
|
+
- Blocco Listing con template a tabella. Corretta la visualizzazione dei campi con valori multipli (es. "Destinatari") che causavano un errore di rendering. I valori vengono ora mostrati correttamente come etichette separate da virgola.
|
|
55
|
+
|
|
44
56
|
## Versione 2.32.0 (12/06/2026)
|
|
45
57
|
|
|
46
58
|
### Migliorie
|
|
@@ -3067,6 +3067,21 @@ msgstr "Enter the name of the pharmacy"
|
|
|
3067
3067
|
msgid "search_farmacia_searchable_text_label"
|
|
3068
3068
|
msgstr "Pharmacy"
|
|
3069
3069
|
|
|
3070
|
+
#. Default: "Mostra il filtro per ente territoriale"
|
|
3071
|
+
#: components/Blocks/SearchFarmacia/schema
|
|
3072
|
+
msgid "search_farmacia_show_area_territoriale"
|
|
3073
|
+
msgstr "Show the territorial area filter"
|
|
3074
|
+
|
|
3075
|
+
#. Default: "Mostra il filtro per comune"
|
|
3076
|
+
#: components/Blocks/SearchFarmacia/schema
|
|
3077
|
+
msgid "search_farmacia_show_comune"
|
|
3078
|
+
msgstr "Show the municipality filter"
|
|
3079
|
+
|
|
3080
|
+
#. Default: "Mostra il filtro per località"
|
|
3081
|
+
#: components/Blocks/SearchFarmacia/schema
|
|
3082
|
+
msgid "search_farmacia_show_localita"
|
|
3083
|
+
msgstr "Show the location filter"
|
|
3084
|
+
|
|
3070
3085
|
#. Default: "Comune"
|
|
3071
3086
|
#: components/Blocks/SearchFarmacia/Body
|
|
3072
3087
|
msgid "search_farmacia_sort_comune"
|
|
@@ -3207,7 +3222,7 @@ msgstr ""
|
|
|
3207
3222
|
msgid "search_map_Show distretto"
|
|
3208
3223
|
msgstr ""
|
|
3209
3224
|
|
|
3210
|
-
#. Default: "Mostra la
|
|
3225
|
+
#. Default: "Mostra la ricerca libera"
|
|
3211
3226
|
#: components/Blocks/SearchMap/schema
|
|
3212
3227
|
msgid "search_map_Show search bar"
|
|
3213
3228
|
msgstr ""
|
|
@@ -3217,6 +3232,11 @@ msgstr ""
|
|
|
3217
3232
|
msgid "search_map_Show types"
|
|
3218
3233
|
msgstr ""
|
|
3219
3234
|
|
|
3235
|
+
#. Default: "Tutte le tipologie"
|
|
3236
|
+
#: components/Blocks/SearchMap/Body
|
|
3237
|
+
msgid "search_map_all_tipologie"
|
|
3238
|
+
msgstr ""
|
|
3239
|
+
|
|
3220
3240
|
#. Default: "Ricerca con mappa"
|
|
3221
3241
|
#: components/Blocks/SearchMap/schema
|
|
3222
3242
|
msgid "search_map_block_title"
|
|
@@ -3237,6 +3257,11 @@ msgstr "Municipality"
|
|
|
3237
3257
|
msgid "search_map_label_distretto"
|
|
3238
3258
|
msgstr "District"
|
|
3239
3259
|
|
|
3260
|
+
#. Default: "Tipologia"
|
|
3261
|
+
#: components/Blocks/SearchMap/Body
|
|
3262
|
+
msgid "search_map_label_tipologia"
|
|
3263
|
+
msgstr ""
|
|
3264
|
+
|
|
3240
3265
|
#. Default: "Cerca"
|
|
3241
3266
|
#: components/Widgets/SearchBar/SearchBar
|
|
3242
3267
|
msgid "search_map_searchable_text_button"
|
|
@@ -3257,11 +3282,21 @@ msgstr "Search for GPs and pediatricians near you"
|
|
|
3257
3282
|
msgid "search_map_searchable_text_default_label_strutture"
|
|
3258
3283
|
msgstr "Search for facilities near you"
|
|
3259
3284
|
|
|
3285
|
+
#. Default: "Testo descrittivo della barra di ricerca"
|
|
3286
|
+
#: components/Blocks/SearchMap/schema
|
|
3287
|
+
msgid "search_map_text_description"
|
|
3288
|
+
msgstr ""
|
|
3289
|
+
|
|
3260
3290
|
#. Default: "Titolo"
|
|
3261
3291
|
#: components/Blocks/SearchMap/schema
|
|
3262
3292
|
msgid "search_map_title"
|
|
3263
3293
|
msgstr ""
|
|
3264
3294
|
|
|
3295
|
+
#. Default: "Filtra tipologia con menu a tendina"
|
|
3296
|
+
#: components/Blocks/SearchMap/schema
|
|
3297
|
+
msgid "search_map_types_as_select"
|
|
3298
|
+
msgstr ""
|
|
3299
|
+
|
|
3265
3300
|
#. Default: "Tutti i comuni"
|
|
3266
3301
|
#: components/Blocks/SearchMap/Body
|
|
3267
3302
|
msgid "search_mapall_cities"
|
|
@@ -3067,6 +3067,21 @@ msgstr ""
|
|
|
3067
3067
|
msgid "search_farmacia_searchable_text_label"
|
|
3068
3068
|
msgstr ""
|
|
3069
3069
|
|
|
3070
|
+
#. Default: "Mostra il filtro per ente territoriale"
|
|
3071
|
+
#: components/Blocks/SearchFarmacia/schema
|
|
3072
|
+
msgid "search_farmacia_show_area_territoriale"
|
|
3073
|
+
msgstr ""
|
|
3074
|
+
|
|
3075
|
+
#. Default: "Mostra il filtro per comune"
|
|
3076
|
+
#: components/Blocks/SearchFarmacia/schema
|
|
3077
|
+
msgid "search_farmacia_show_comune"
|
|
3078
|
+
msgstr ""
|
|
3079
|
+
|
|
3080
|
+
#. Default: "Mostra il filtro per località"
|
|
3081
|
+
#: components/Blocks/SearchFarmacia/schema
|
|
3082
|
+
msgid "search_farmacia_show_localita"
|
|
3083
|
+
msgstr ""
|
|
3084
|
+
|
|
3070
3085
|
#. Default: "Comune"
|
|
3071
3086
|
#: components/Blocks/SearchFarmacia/Body
|
|
3072
3087
|
msgid "search_farmacia_sort_comune"
|
|
@@ -3207,7 +3222,7 @@ msgstr ""
|
|
|
3207
3222
|
msgid "search_map_Show distretto"
|
|
3208
3223
|
msgstr ""
|
|
3209
3224
|
|
|
3210
|
-
#. Default: "Mostra la
|
|
3225
|
+
#. Default: "Mostra la ricerca libera"
|
|
3211
3226
|
#: components/Blocks/SearchMap/schema
|
|
3212
3227
|
msgid "search_map_Show search bar"
|
|
3213
3228
|
msgstr ""
|
|
@@ -3217,6 +3232,11 @@ msgstr ""
|
|
|
3217
3232
|
msgid "search_map_Show types"
|
|
3218
3233
|
msgstr ""
|
|
3219
3234
|
|
|
3235
|
+
#. Default: "Tutte le tipologie"
|
|
3236
|
+
#: components/Blocks/SearchMap/Body
|
|
3237
|
+
msgid "search_map_all_tipologie"
|
|
3238
|
+
msgstr ""
|
|
3239
|
+
|
|
3220
3240
|
#. Default: "Ricerca con mappa"
|
|
3221
3241
|
#: components/Blocks/SearchMap/schema
|
|
3222
3242
|
msgid "search_map_block_title"
|
|
@@ -3237,6 +3257,11 @@ msgstr ""
|
|
|
3237
3257
|
msgid "search_map_label_distretto"
|
|
3238
3258
|
msgstr ""
|
|
3239
3259
|
|
|
3260
|
+
#. Default: "Tipologia"
|
|
3261
|
+
#: components/Blocks/SearchMap/Body
|
|
3262
|
+
msgid "search_map_label_tipologia"
|
|
3263
|
+
msgstr ""
|
|
3264
|
+
|
|
3240
3265
|
#. Default: "Cerca"
|
|
3241
3266
|
#: components/Widgets/SearchBar/SearchBar
|
|
3242
3267
|
msgid "search_map_searchable_text_button"
|
|
@@ -3257,11 +3282,21 @@ msgstr ""
|
|
|
3257
3282
|
msgid "search_map_searchable_text_default_label_strutture"
|
|
3258
3283
|
msgstr ""
|
|
3259
3284
|
|
|
3285
|
+
#. Default: "Testo descrittivo della barra di ricerca"
|
|
3286
|
+
#: components/Blocks/SearchMap/schema
|
|
3287
|
+
msgid "search_map_text_description"
|
|
3288
|
+
msgstr ""
|
|
3289
|
+
|
|
3260
3290
|
#. Default: "Titolo"
|
|
3261
3291
|
#: components/Blocks/SearchMap/schema
|
|
3262
3292
|
msgid "search_map_title"
|
|
3263
3293
|
msgstr ""
|
|
3264
3294
|
|
|
3295
|
+
#. Default: "Filtra tipologia con menu a tendina"
|
|
3296
|
+
#: components/Blocks/SearchMap/schema
|
|
3297
|
+
msgid "search_map_types_as_select"
|
|
3298
|
+
msgstr ""
|
|
3299
|
+
|
|
3265
3300
|
#. Default: "Tutti i comuni"
|
|
3266
3301
|
#: components/Blocks/SearchMap/Body
|
|
3267
3302
|
msgid "search_mapall_cities"
|
package/locales/volto.pot
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
msgid ""
|
|
2
2
|
msgstr ""
|
|
3
3
|
"Project-Id-Version: Plone\n"
|
|
4
|
-
"POT-Creation-Date: 2026-06-
|
|
4
|
+
"POT-Creation-Date: 2026-06-17T13:05:19.697Z\n"
|
|
5
5
|
"Last-Translator: Plone i18n <plone-i18n@lists.sourceforge.net>\n"
|
|
6
6
|
"Language-Team: Plone i18n <plone-i18n@lists.sourceforge.net>\n"
|
|
7
7
|
"Content-Type: text/plain; charset=utf-8\n"
|
|
@@ -3069,6 +3069,21 @@ msgstr ""
|
|
|
3069
3069
|
msgid "search_farmacia_searchable_text_label"
|
|
3070
3070
|
msgstr ""
|
|
3071
3071
|
|
|
3072
|
+
#. Default: "Mostra il filtro per ente territoriale"
|
|
3073
|
+
#: components/Blocks/SearchFarmacia/schema
|
|
3074
|
+
msgid "search_farmacia_show_area_territoriale"
|
|
3075
|
+
msgstr ""
|
|
3076
|
+
|
|
3077
|
+
#. Default: "Mostra il filtro per comune"
|
|
3078
|
+
#: components/Blocks/SearchFarmacia/schema
|
|
3079
|
+
msgid "search_farmacia_show_comune"
|
|
3080
|
+
msgstr ""
|
|
3081
|
+
|
|
3082
|
+
#. Default: "Mostra il filtro per località"
|
|
3083
|
+
#: components/Blocks/SearchFarmacia/schema
|
|
3084
|
+
msgid "search_farmacia_show_localita"
|
|
3085
|
+
msgstr ""
|
|
3086
|
+
|
|
3072
3087
|
#. Default: "Comune"
|
|
3073
3088
|
#: components/Blocks/SearchFarmacia/Body
|
|
3074
3089
|
msgid "search_farmacia_sort_comune"
|
|
@@ -3209,7 +3224,7 @@ msgstr ""
|
|
|
3209
3224
|
msgid "search_map_Show distretto"
|
|
3210
3225
|
msgstr ""
|
|
3211
3226
|
|
|
3212
|
-
#. Default: "Mostra la
|
|
3227
|
+
#. Default: "Mostra la ricerca libera"
|
|
3213
3228
|
#: components/Blocks/SearchMap/schema
|
|
3214
3229
|
msgid "search_map_Show search bar"
|
|
3215
3230
|
msgstr ""
|
|
@@ -3219,6 +3234,11 @@ msgstr ""
|
|
|
3219
3234
|
msgid "search_map_Show types"
|
|
3220
3235
|
msgstr ""
|
|
3221
3236
|
|
|
3237
|
+
#. Default: "Tutte le tipologie"
|
|
3238
|
+
#: components/Blocks/SearchMap/Body
|
|
3239
|
+
msgid "search_map_all_tipologie"
|
|
3240
|
+
msgstr ""
|
|
3241
|
+
|
|
3222
3242
|
#. Default: "Ricerca con mappa"
|
|
3223
3243
|
#: components/Blocks/SearchMap/schema
|
|
3224
3244
|
msgid "search_map_block_title"
|
|
@@ -3239,6 +3259,11 @@ msgstr ""
|
|
|
3239
3259
|
msgid "search_map_label_distretto"
|
|
3240
3260
|
msgstr ""
|
|
3241
3261
|
|
|
3262
|
+
#. Default: "Tipologia"
|
|
3263
|
+
#: components/Blocks/SearchMap/Body
|
|
3264
|
+
msgid "search_map_label_tipologia"
|
|
3265
|
+
msgstr ""
|
|
3266
|
+
|
|
3242
3267
|
#. Default: "Cerca"
|
|
3243
3268
|
#: components/Widgets/SearchBar/SearchBar
|
|
3244
3269
|
msgid "search_map_searchable_text_button"
|
|
@@ -3259,11 +3284,21 @@ msgstr ""
|
|
|
3259
3284
|
msgid "search_map_searchable_text_default_label_strutture"
|
|
3260
3285
|
msgstr ""
|
|
3261
3286
|
|
|
3287
|
+
#. Default: "Testo descrittivo della barra di ricerca"
|
|
3288
|
+
#: components/Blocks/SearchMap/schema
|
|
3289
|
+
msgid "search_map_text_description"
|
|
3290
|
+
msgstr ""
|
|
3291
|
+
|
|
3262
3292
|
#. Default: "Titolo"
|
|
3263
3293
|
#: components/Blocks/SearchMap/schema
|
|
3264
3294
|
msgid "search_map_title"
|
|
3265
3295
|
msgstr ""
|
|
3266
3296
|
|
|
3297
|
+
#. Default: "Filtra tipologia con menu a tendina"
|
|
3298
|
+
#: components/Blocks/SearchMap/schema
|
|
3299
|
+
msgid "search_map_types_as_select"
|
|
3300
|
+
msgstr ""
|
|
3301
|
+
|
|
3267
3302
|
#. Default: "Tutti i comuni"
|
|
3268
3303
|
#: components/Blocks/SearchMap/Body
|
|
3269
3304
|
msgid "search_mapall_cities"
|
package/package.json
CHANGED
|
@@ -86,7 +86,10 @@ const TableTemplate = (props) => {
|
|
|
86
86
|
c.field_properties ??
|
|
87
87
|
ct_schema?.[c.ct]?.result?.properties?.[c.field] ??
|
|
88
88
|
{};
|
|
89
|
-
|
|
89
|
+
const raw = item[c.field];
|
|
90
|
+
let render_value = Array.isArray(raw)
|
|
91
|
+
? raw.map((v) => v?.title ?? v).join(', ')
|
|
92
|
+
: raw?.title ?? JSON.stringify(raw);
|
|
90
93
|
|
|
91
94
|
if (field_properties) {
|
|
92
95
|
const field = {
|
|
@@ -48,6 +48,12 @@ const Body = ({ isEditMode, data, id }) => {
|
|
|
48
48
|
const intl = useIntl();
|
|
49
49
|
const resultsRef = createRef();
|
|
50
50
|
const searchType = data?.search_type; // type of search, Ferie o Turni ('shifts' or 'vacations')
|
|
51
|
+
// fallback dinamico per i blocchi salvati prima dell'introduzione dei flag:
|
|
52
|
+
// Turni mostrava solo l'ente territoriale, Ferie solo comune e località
|
|
53
|
+
const showAreaTerritoriale =
|
|
54
|
+
data.show_area_territoriale ?? searchType !== 'vacations';
|
|
55
|
+
const showComune = data.show_comune ?? searchType === 'vacations';
|
|
56
|
+
const showLocalita = data.show_localita ?? searchType === 'vacations';
|
|
51
57
|
const b_size = 10; // number of page results to show
|
|
52
58
|
const [currentPage, setCurrentPage] = useState(0);
|
|
53
59
|
const [filters, setFilters] = useState({
|
|
@@ -251,6 +257,9 @@ const Body = ({ isEditMode, data, id }) => {
|
|
|
251
257
|
block_id={id}
|
|
252
258
|
setFilters={setFilters}
|
|
253
259
|
searchType={searchType}
|
|
260
|
+
showAreaTerritoriale={showAreaTerritoriale}
|
|
261
|
+
showComune={showComune}
|
|
262
|
+
showLocalita={showLocalita}
|
|
254
263
|
filters={filters}
|
|
255
264
|
options={filtersOptions}
|
|
256
265
|
ariaControls={resultsWrapperId}
|
|
@@ -36,6 +36,9 @@ const messages = defineMessages({
|
|
|
36
36
|
|
|
37
37
|
const SearchFilters = ({
|
|
38
38
|
searchType,
|
|
39
|
+
showAreaTerritoriale,
|
|
40
|
+
showComune,
|
|
41
|
+
showLocalita,
|
|
39
42
|
filters,
|
|
40
43
|
setFilters,
|
|
41
44
|
options,
|
|
@@ -63,81 +66,81 @@ const SearchFilters = ({
|
|
|
63
66
|
</Col>
|
|
64
67
|
|
|
65
68
|
{searchType === 'shifts' && (
|
|
66
|
-
|
|
67
|
-
<
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
69
|
+
<Col lg="3" className="d-flex flex-column">
|
|
70
|
+
<DatetimeWidget
|
|
71
|
+
id="date_farmacie"
|
|
72
|
+
dateOnly={true}
|
|
73
|
+
resettable={false}
|
|
74
|
+
value={filters['date']}
|
|
75
|
+
onChange={(opt, value) => {
|
|
76
|
+
setFilters({
|
|
77
|
+
...filters,
|
|
78
|
+
date: new Date(value).toISOString(),
|
|
79
|
+
});
|
|
80
|
+
}}
|
|
81
|
+
title=""
|
|
82
|
+
/>
|
|
83
|
+
<small className="ps-2">{intl.formatMessage(messages.date)}</small>{' '}
|
|
84
|
+
</Col>
|
|
85
|
+
)}
|
|
83
86
|
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
87
|
+
{showAreaTerritoriale && (
|
|
88
|
+
<Col lg="3">
|
|
89
|
+
<SelectInput
|
|
90
|
+
id="area_territoriale"
|
|
91
|
+
value={filters.area_territoriale ?? ''}
|
|
92
|
+
placeholder={intl.formatMessage(messages.area_territoriale)}
|
|
93
|
+
onChange={(opt) => {
|
|
94
|
+
setFilters({ ...filters, area_territoriale: opt });
|
|
95
|
+
}}
|
|
96
|
+
options={options.aree_territoriali ?? []}
|
|
97
|
+
isClearable={true}
|
|
98
|
+
isSearchable={true}
|
|
99
|
+
/>
|
|
100
|
+
</Col>
|
|
98
101
|
)}
|
|
99
102
|
|
|
100
|
-
{
|
|
101
|
-
|
|
102
|
-
<
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
filters['comune']
|
|
107
|
-
|
|
108
|
-
label: filters['comune'],
|
|
109
|
-
}
|
|
103
|
+
{showComune && (
|
|
104
|
+
<Col lg="3" className="d-flex align-center">
|
|
105
|
+
<SelectInput
|
|
106
|
+
id="comune"
|
|
107
|
+
value={
|
|
108
|
+
filters['comune'] && {
|
|
109
|
+
value: filters['comune'],
|
|
110
|
+
label: filters['comune'],
|
|
110
111
|
}
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
112
|
+
}
|
|
113
|
+
placeholder={intl.formatMessage(messages.comune)}
|
|
114
|
+
onChange={(opt) => {
|
|
115
|
+
setFilters({ ...filters, comune: opt?.value });
|
|
116
|
+
// checkClearComune(opt);
|
|
117
|
+
}}
|
|
118
|
+
options={options.comuni ?? []}
|
|
119
|
+
isClearable={true}
|
|
120
|
+
isSearchable={true}
|
|
121
|
+
/>
|
|
122
|
+
</Col>
|
|
123
|
+
)}
|
|
121
124
|
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
125
|
+
{showLocalita && (
|
|
126
|
+
<Col lg="3" className="d-flex align-center">
|
|
127
|
+
<SelectInput
|
|
128
|
+
id="localita"
|
|
129
|
+
value={
|
|
130
|
+
filters.localita && {
|
|
131
|
+
value: filters['localita'],
|
|
132
|
+
label: filters['localita'],
|
|
130
133
|
}
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
}
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
134
|
+
}
|
|
135
|
+
placeholder={intl.formatMessage(messages.localita)}
|
|
136
|
+
onChange={(opt) => {
|
|
137
|
+
setFilters({ ...filters, localita: opt?.value });
|
|
138
|
+
}}
|
|
139
|
+
options={options.localita ?? []}
|
|
140
|
+
isClearable={true}
|
|
141
|
+
isSearchable={true}
|
|
142
|
+
/>
|
|
143
|
+
</Col>
|
|
141
144
|
)}
|
|
142
145
|
</Row>
|
|
143
146
|
);
|
|
@@ -13,6 +13,18 @@ const messages = defineMessages({
|
|
|
13
13
|
id: 'search_farmacie_block_title',
|
|
14
14
|
defaultMessage: 'Ricerca Farmacie',
|
|
15
15
|
},
|
|
16
|
+
show_area_territoriale: {
|
|
17
|
+
id: 'search_farmacia_show_area_territoriale',
|
|
18
|
+
defaultMessage: 'Mostra il filtro per ente territoriale',
|
|
19
|
+
},
|
|
20
|
+
show_comune: {
|
|
21
|
+
id: 'search_farmacia_show_comune',
|
|
22
|
+
defaultMessage: 'Mostra il filtro per comune',
|
|
23
|
+
},
|
|
24
|
+
show_localita: {
|
|
25
|
+
id: 'search_farmacia_show_localita',
|
|
26
|
+
defaultMessage: 'Mostra il filtro per località',
|
|
27
|
+
},
|
|
16
28
|
});
|
|
17
29
|
|
|
18
30
|
export function SearchFarmaciaSchema({ formData, intl }) {
|
|
@@ -22,7 +34,13 @@ export function SearchFarmaciaSchema({ formData, intl }) {
|
|
|
22
34
|
{
|
|
23
35
|
id: 'default',
|
|
24
36
|
title: 'Default',
|
|
25
|
-
fields: [
|
|
37
|
+
fields: [
|
|
38
|
+
'title',
|
|
39
|
+
'search_type',
|
|
40
|
+
'show_area_territoriale',
|
|
41
|
+
'show_comune',
|
|
42
|
+
'show_localita',
|
|
43
|
+
],
|
|
26
44
|
},
|
|
27
45
|
],
|
|
28
46
|
properties: {
|
|
@@ -37,6 +55,21 @@ export function SearchFarmaciaSchema({ formData, intl }) {
|
|
|
37
55
|
title: {
|
|
38
56
|
title: intl.formatMessage(messages.title),
|
|
39
57
|
},
|
|
58
|
+
show_area_territoriale: {
|
|
59
|
+
title: intl.formatMessage(messages.show_area_territoriale),
|
|
60
|
+
type: 'boolean',
|
|
61
|
+
default: formData?.search_type !== 'vacations',
|
|
62
|
+
},
|
|
63
|
+
show_comune: {
|
|
64
|
+
title: intl.formatMessage(messages.show_comune),
|
|
65
|
+
type: 'boolean',
|
|
66
|
+
default: formData?.search_type === 'vacations',
|
|
67
|
+
},
|
|
68
|
+
show_localita: {
|
|
69
|
+
title: intl.formatMessage(messages.show_localita),
|
|
70
|
+
type: 'boolean',
|
|
71
|
+
default: formData?.search_type === 'vacations',
|
|
72
|
+
},
|
|
40
73
|
},
|
|
41
74
|
required: [],
|
|
42
75
|
};
|