diff --git a/src/pfwbged/collection/multiactions.py b/src/pfwbged/collection/multiactions.py index 9cb9d11..753bafd 100644 --- a/src/pfwbged/collection/multiactions.py +++ b/src/pfwbged/collection/multiactions.py @@ -15,7 +15,13 @@ class MultiActionsView(BrowserView): for document_id in documents: document = api.content.get(document_id) try: - api.content.transition(document, action) + if action in ('validate', 'refuse'): + for child in reversed(document.values()): + if child.portal_type == 'dmsmainfile': + api.content.transition(child, action) + break + else: + api.content.transition(document, action) except InvalidParameterError: failures.append(document) else: diff --git a/src/pfwbged/collection/searchview.py b/src/pfwbged/collection/searchview.py index a54cce2..1fbfd3e 100644 --- a/src/pfwbged/collection/searchview.py +++ b/src/pfwbged/collection/searchview.py @@ -200,6 +200,8 @@ class ResultsDocumentsTable(ResultsTable): + + """ % {'portal_url': portal_url}