1

I am getting a very weird problem when attempted to cut-and-paste folders from one place to another in our intranet Plone site. The paste operation returned the error "Nothing in the clipboard". However it had gone and removed the folder from where it had originally been, and it looks as though it hasn't been inserted yet into the new location. Showing the Content view of the folder in which the paste happened does not show the pasted folder. However, through the ZMI interface I can see that the paste has happened. Clearly something threw an error before the pasted content was moved successfully, and it is left in a weird state.

For example the site search can find the content in the new pasted location, and the bread-crumbs show that those content pages are beneath the folder which is otherwise invisible to Plone.

Is it possible - maybe through the ZMI - to get this folder to be visible in the Plone world?

luke.tunmer
  • 183
  • 6
  • 2
    If you run out of other things to try: clear and rebuild the catalog (ZMI -> portal_catalog -> Advanced). – Ulrich Schwarz Apr 30 '12 at 16:26
  • Thanks, Ulrich - I'll try that. I solved the immediate crisis by visiting every folder underneath the problematic one (by typing in the URL determined by walking the tree though the ZMI), editing it and saving it. I had to do it at every folder rather than just the top one. There must be some weird finalization of folders that didn't happen that made Plone ignore them all. – luke.tunmer May 01 '12 at 09:56
  • The only question wait for Yes/No answer. Please edit it / rephrase it to have real answer to your real need (mean debug stuff). You should also add information like Plone version, system and give us enough information to reproduce the problem (best should give us the database). – toutpt May 01 '12 at 15:30
  • if you enabled multiple languages and do copy/cut/paste between different languages the pasted content does not show up because plone only shows content of the currently selected language. if that's the case you can type in the items url (eg yourplonesite/en/some-document-pasted-from-another-language/edit) and fix the language settings – fRiSi May 02 '12 at 12:39
  • toutpt: The version of Plone is: Plone 4111, CMF 2.2.4, Zope 2.13.8. What I was hoping for was a recognition of an known problem, but clearly this is not the case. Sadly I cannot supply the database due to it being a company intranet and containing confidential information, so I do recognize that this makes it less likely that others can reproduce this. I saw no exceptions in the log fiel relevant to this action. fRiSi: no other languages have been enabled on the site. – luke.tunmer May 02 '12 at 16:38

2 Answers2

0

That is a weird bug. The quick solution to get the folder to display in Plone is to go to the ZMI, then visit portal_catalog, then locate (in one of the tabs) the button to rebuild the catalog. This ought to regenerate the catalog indexes (which may have failed to be updated when you did the cut/paste, through no fault of your own) and thus all the views (folder listings, etc) in Plone will display the new index (the views use the catalog to know what to display).

Rudd-O
  • 116
  • 1
  • 3
0

The same problem as I copied a folder from one language folder to an other the pasted object was only visible in ZMI

As fRiSi said the problem was the language category in Categorization tab > Language

Because I had many subobjects inside a folder I run the script below to change the language categorization recursively

Based on Convert LinguaPlone sub-language back to language for all content?

path = '/'.join(context.getPhysicalPath())

for brain in context.portal_catalog(path={'query': path, 'depth': 1000}, Language="it"):
    obj = brain.getObject()
    obj.setLanguage('en')
    obj.reindexObject(idxs=['Language'])

    print brain.getURL()

return printed
Community
  • 1
  • 1
Robbo
  • 101
  • 1
  • 3