Skip to content

Commit 7d6f810

Browse files
committed
some modification
1 parent 91e9320 commit 7d6f810

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

src/design/plone/contenttypes/profiles/default/types/Documento.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
<property name="global_allow">True</property>
2323
<property name="filter_content_types">True</property>
2424
<property name="allowed_content_types">
25+
<element value="Document" />
2526
<element value="Modulo" />
2627
<element value="Link" />
2728
</property>

src/design/plone/contenttypes/restapi/serializers/documento.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ def __call__(self, version=None, include_items=True):
5454
)
5555
# Una via alternativa era l'injection di fullobject nella request ma
5656
# mi pare una cosa cattiva da fare
57-
brain_moduli = [x for x in self.context.getFolderContents()]
57+
brain_moduli = [x for x in self.context.getFolderContents() if x.portal_type != "Document"]
5858
result["moduli_del_documento"] = []
5959
for brain in brain_moduli:
6060
modulo = brain.getObject()

0 commit comments

Comments
 (0)