0

I'm using collective.transmogrifier.sections.folders pipeline section to create parent folders of content I'm importing into Plone.

My problem is those folders are created without a title and are not being published.

How can I solve that?

hvelarde
  • 2,875
  • 14
  • 34

1 Answers1

1

Try adding this sections to your pipeline (you may already have the second one):

# Publish all folders 
[publish_all_folders]
blueprint = collective.transmogrifier.sections.inserter
key = string:_transitions
value = string:publish
condition = python:item.get('_type') == "Folder"

# Actually run the given transition to update the workflow state
[workflowupdater]
blueprint = plone.app.transmogrifier.workflowupdater
hvelarde
  • 2,875
  • 14
  • 34
Danimal
  • 1,208
  • 10
  • 21
  • that won't work on a second iteration when folders are already created; I'll test now creating content all over again. seems to me a similar approach can be used for the title. – hvelarde Jul 31 '15 at 15:02
  • Ah, oops - forgot about the title. I do wonder whether [sitewalker](https://github.com/collective/quintagroup.transmogrifier/blob/master/quintagroup/transmogrifier/sitewalker.py#L17) from qg.tm would be enough to kick start a 2nd iteration for you? (Note you can specify it to only bring back Folders) But it wouldn't know which title to add – Danimal Jul 31 '15 at 15:09
  • I guess the title is just a capitalized id? otherwise you haven't said how it should be defined & you may have to fix it manually. – Danimal Jul 31 '15 at 15:11