diff --git a/redturtle/bandi/profiles/default/registry.xml b/redturtle/bandi/profiles/default/registry.xml
index c0e0d3d..c8d61f2 100644
--- a/redturtle/bandi/profiles/default/registry.xml
+++ b/redturtle/bandi/profiles/default/registry.xml
@@ -128,7 +128,7 @@
True
False
- plone.app.querystring.operation.selection.is
+ plone.app.querystring.operation.selection.bando_state_is
redturtle.bandi.vocabularies.bandi_states
Bando
+
+ Is
+ Tip: you can use * to autocomplete.
+ plone.app.querystring.queryparser._equal
+ SelectionWidget
+
+
diff --git a/redturtle/bandi/profiles/to_2300/registry.xml b/redturtle/bandi/profiles/to_2300/registry.xml
new file mode 100644
index 0000000..c776424
--- /dev/null
+++ b/redturtle/bandi/profiles/to_2300/registry.xml
@@ -0,0 +1,37 @@
+
+
+
+ Is
+ Tip: you can use * to autocomplete.
+ plone.app.querystring.queryparser._equal
+ SelectionWidget
+
+
+
+ Stato del bando
+
+ True
+ False
+
+ plone.app.querystring.operation.selection.is
+
+ redturtle.bandi.vocabularies.bandi_states
+ Bando
+
+
+
\ No newline at end of file
diff --git a/redturtle/bandi/upgrades.py b/redturtle/bandi/upgrades.py
index 9e0fc22..4570047 100644
--- a/redturtle/bandi/upgrades.py
+++ b/redturtle/bandi/upgrades.py
@@ -48,10 +48,10 @@ def migrate_to_1100(context):
)
criteria_mapping = {
- u"getTipologia_bando": u"tipologia_bando",
- u"getChiusura_procedimento_bando": u"chiusura_procedimento_bando",
- u"getScadenza_bando": u"scadenza_bando",
- u"getDestinatariBando": u"destinatari_bando",
+ "getTipologia_bando": "tipologia_bando",
+ "getChiusura_procedimento_bando": "chiusura_procedimento_bando",
+ "getScadenza_bando": "scadenza_bando",
+ "getDestinatariBando": "destinatari_bando",
}
collections = api.content.find(portal_type="Collection")
tot_results = len(collections)
@@ -169,7 +169,7 @@ def migrate_to_2101(context):
)
)
bando = brain.getObject()
- bando.reindexObject(idxs=['scadenza_bando'])
+ bando.reindexObject(idxs=["scadenza_bando"])
def migrate_to_2102(context):
@@ -185,4 +185,14 @@ def migrate_to_2102(context):
)
)
bando = brain.getObject()
- bando.reindexObject(idxs=['tipologia_bando_label'])
+ bando.reindexObject(idxs=["tipologia_bando_label"])
+
+
+def migrate_to_2300(context):
+ PROFILE_ID = "profile-redturtle.bandi:to_2300"
+ context.runAllImportStepsFromProfile(PROFILE_ID)
+
+ # update indexes and topics
+ context.runImportStepFromProfile(
+ default_profile, "plone.app.registry", run_dependencies=False
+ )
diff --git a/redturtle/bandi/upgrades.zcml b/redturtle/bandi/upgrades.zcml
index 8127dee..295547c 100644
--- a/redturtle/bandi/upgrades.zcml
+++ b/redturtle/bandi/upgrades.zcml
@@ -72,7 +72,7 @@
description=""
source="2102"
destination="2300"
- handler=".upgrades.update_registry"
+ handler=".upgrades.migrate_to_2300"
profile="redturtle.bandi:default" />