Task #55426
closed
Cleanup listframe cut/copy handling
Added by Bernhard Kraft almost 11 years ago.
Updated almost 9 years ago.
Sprint Focus:
Remote Sprint
Description
The patch which enabled pasting of content elements into empty columns [1] required a fix for reloading the list frame after cut/copy a tt_content element via its clickmenu [2].
The patch [2] introduced a few lines in clickmenu.js which use a relict feature: Ancient times ago the clickmenu was not implemented by AJAX but by reloading the top-frame with some special parameters and Javascript therein generated the clickmenu. Then it was possible to add javascript for reloading the list frame after an element has been cut/copied to the clipboard.
This ancient feature is used again after fix [2] because the clickmenu makes a call to itself for cut/copy.
Eventual solution: Instead of making a call to alt_clickmenu.php for CB cut/copy actions make a call to tce_db.php/tce_file.php. Don't know if this works but alt_clickmenu shouldn't be misused for doing a cut/copy of an element into the clipboard. If this is solved the temporary solution in clickmenu.js could get removed again.
[1] https://review.typo3.org/#/c/25532/
[2] https://review.typo3.org/#/c/25544/
So this is no functional issue but rather a coding style issue.
I just checked tce_db.php and it seems it is possible to resolve this issue by fixing the clickmenu links for cut/copy. They should get generated like the cut/copy links in the list module!!
- Target version set to 7.4 (Backend)
It should get noted, that from the very beginning it was not possible to paste content elements on the clipboard into an empty column. But there were "paste after this element" icons. Somewhen those icons got removed for design reasons - the original bug still persisted and a "paste" operation could only get accomplished using the clickmenu.
I don't know exactly if the transition to AJAX clickmenus happened before or after the removal of paste icons.
The only reason for reloading the page module upon doing a copy/cut operation is to show the paste icons at the top of every column.
I guess the required solution here would be to generate those paste icons anytime but do not show them (css display none). When an element gets copied/pasted to the clipboard they should get enabled but the paste message ~"Do you want to paste element XY into column Z" would have to get carried along with the AJAX reply of the copy/cut operation.
- Sprint Focus set to On Location Sprint
- Status changed from New to Needs Feedback
- Assignee set to Benni Mack
Hey Bernhard, can you see if this still applies? I did some work in this area recently.
- Sprint Focus changed from On Location Sprint to Remote Sprint
- Target version changed from 7.4 (Backend) to 7.5
- Target version deleted (
7.5)
- Status changed from Needs Feedback to Closed
Should be fixed by now. Closing now due to no response. If you still think this applies, please let me know via email or slack.
Also available in: Atom
PDF