Bug #67533
closedLegacy uploadfolder does not work correct in workspaces
0%
Description
When I use the workspace with my extension, I get an error message when I select an image or a relation-element:
1: The destination (/var/www/html/xyz/uploads/tx_myquizpoll) or the source file (/var/www/html/xyz/uploads/tx_myquizpoll/2563) does not exist. (tx_myquizpoll_question:484:image)
Or:
"router: router Element "tx_myquizpoll_category:197" does not exist"
When I select a template-file (via flexform) there is a similar problem: the FAL-number is not replaced by the path to the template. See image.
This problems occurs only when I use the workspace.
This is the configuration for the db-table:
$TCA['tx_myquizpoll_question'] = array ( 'ctrl' => array ( 'title' => 'LLL:EXT:myquizpoll/locallang_db.xml:tx_myquizpoll_question', 'label' => 'title', 'tstamp' => 'tstamp', 'crdate' => 'crdate', 'cruser_id' => 'cruser_id', 'versioningWS' => TRUE, 'origUid' => 't3_origuid', 'languageField' => 'sys_language_uid', 'transOrigPointerField' => 'l10n_parent', 'transOrigDiffSourceField' => 'l10n_diffsource', 'sortby' => 'sorting', 'delete' => 'deleted', 'enablecolumns' => array ( 'disabled' => 'hidden', 'fe_group' => 'fe_group', ), 'dynamicConfigFile' => t3lib_extMgm::extPath($_EXTKEY).'tca.php', 'iconfile' => t3lib_extMgm::extRelPath($_EXTKEY).'icon_tx_myquizpoll_question.gif', ), );
What can I do?
Files
Updated by Wouter Wolters about 9 years ago
- Status changed from New to Needs Feedback
Can you retry this with latest TYPO3 CMS 6.2 version?
Updated by Kurt Gusbeth about 9 years ago
- File select-file.png select-file.png added
- File select-image.png select-image.png added
I used TYPO3 6.2.15 for testing. Problems are still there in the workspace-mode. See new images...
Updated by Oliver Hader about 9 years ago
Can you provide a repository link to the source code of your extension? Otherwise it's getting difficult to guess your configuration and things you maybe are doing there. Thx.
Updated by Oliver Hader about 9 years ago
And please provide a short step-by-step guide on how to reproduce this behavior in a particular scenario (with your extension probably).
Updated by Oliver Hader about 9 years ago
The "Element ... does not exist" thingy seems to be related to #67676 (deleted child elements in a workspace).
Updated by Kurt Gusbeth about 9 years ago
Problem 1 is a general problem. It occurs always (not only in the workspace mode). When I select a file with this FlexForm
<templateFile> <TCEforms> <label>Template file</label> <config> <type>input</type> <default></default> <wizards type="array"> <_PADDING>2</_PADDING> <link type="array"> <type>popup</type> <title>Link</title> <icon>link_popup.gif</icon> <script>browse_links.php?mode=wizard&act=file</script> <params type="array"> <blindLinkOptions>page,url,mail,spec</blindLinkOptions> <allowedExtensions>htm,html,tmpl,tpl</allowedExtensions> </params> <JSopenParams>height=300,width=500,status=0,menubar=0,scrollbars=1</JSopenParams> </link> </wizards> </config> </TCEforms> </templateFile>
then only "file:3453" will be stored in the FlexForm data.
templateFile should contain the path to the file - like in TYPO3 4.x - and not only "file:3453".
Is that a bug or do I need to chance the FlexForms?
Updated by Kurt Gusbeth about 9 years ago
Problem 2: when I am in the Draft workspace and select a uploaded file with this code:
$TCA['tx_myquizpoll_question'] = array ( 'ctrl' => $TCA['tx_myquizpoll_question']['ctrl'], 'interface' => array ( 'showRecordFieldList' => 'sys_language_uid,l10n_parent,l10n_diffsource,hidden,fe_group,title,title_hide,name,...,image,alt_text' ), 'columns' => array ( 't3ver_label' => array ( 'label' => 'LLL:EXT:lang/locallang_general.xml:LGL.versionLabel', 'config' => array ( 'type' => 'input', 'size' => '30', 'max' => '30', ) ), 'sys_language_uid' => array ( 'exclude' => 1, 'label' => 'LLL:EXT:lang/locallang_general.xml:LGL.language', 'config' => array ( 'type' => 'select', 'foreign_table' => 'sys_language', 'foreign_table_where' => 'ORDER BY sys_language.title', 'items' => array( array('LLL:EXT:lang/locallang_general.xml:LGL.allLanguages', -1), array('LLL:EXT:lang/locallang_general.xml:LGL.default_value', 0) ) ) ), 'l10n_parent' => array ( 'displayCond' => 'FIELD:sys_language_uid:>:0', 'exclude' => 1, 'label' => 'LLL:EXT:lang/locallang_general.xml:LGL.l18n_parent', 'config' => array ( 'type' => 'select', 'items' => array ( array('', 0), ), 'foreign_table' => 'tx_myquizpoll_question', 'foreign_table_where' => 'AND tx_myquizpoll_question.pid=###CURRENT_PID### AND tx_myquizpoll_question.sys_language_uid IN (-1,0)', ) ), 'l10n_diffsource' => array ( 'config' => array ( 'type' => 'passthrough' ) ), ... 'image' => array ( 'exclude' => 1, 'label' => 'LLL:EXT:myquizpoll/locallang_db.xml:tx_myquizpoll_question.image', 'config' => array ( 'type' => 'group', 'internal_type' => 'file', 'allowed' => 'gif,png,jpeg,jpg', 'max_size' => $GLOBALS['TYPO3_CONF_VARS']['BE']['maxFileSize'], 'uploadfolder' => 'uploads/tx_myquizpoll', 'show_thumbs' => 1, 'size' => 1, 'minitems' => 0, 'maxitems' => 1, ) ), ... ), 'types' => array ( '0' => array('showitem' => 'sys_language_uid;;;;1-1-1, l10n_parent, l10n_diffsource, hidden;;1, title;;2;;2-2-2, name;;;richtext[paste|bold|italic|underline|formatblock|class|left|center|right|orderedlist|unorderedlist|outdent|indent|link|image]:rte_transform[mode=ts];3-3-3, image;;18, qtype;;3, answer1;;4, correct1;;5, answer2;;6, correct2;;7, answer3;;8, correct3;;9, answer4;;10, correct4;;11, answer5;;12, correct5;;13, answer6;;14, correct6;;15, points;;16, explanation;;17;richtext[paste|bold|italic|underline|formatblock|class|left|center|right|orderedlist|unorderedlist|outdent|indent|link|image]:rte_transform[mode=ts]') ), 'palettes' => array ( ... ) );
I often get this error message:
1: The destination (/var/www/html/server/uploads/tx_myquizpoll) or the source file (/var/www/html/server/uploads/tx_myquizpoll/5011) does not exist. (tx_myquizpoll_question:505:image)
When I save the same file again, it works.
5011 is a file-entry in sys_file. 5011 should be replaced by "fileadmin/" and the field identifier of the table sys_file.
You find the extension here:
[[http://typo3.org/extensions/repository/view/myquizpoll]]
Updated by Oliver Hader almost 9 years ago
Kurt Gusbeth wrote:
Problem 1 is a general problem. It occurs always (not only in the workspace mode). When I select a file with this FlexForm
[...]
then only "file:3453" will be stored in the FlexForm data.
templateFile should contain the path to the file - like in TYPO3 4.x - and not only "file:3453".
Is that a bug or do I need to chance the FlexForms?
That's the effect of the file abstraction layer (FAL). Only references to a file entity are stored, not the full path anymore.
If you put "file:1234" to ResourceFactory::retrieveFileOrFolderObject() you get the accordant file entity.
Thus, that's not a bug, but something that needs to be changed in the processing logic of your extension.
Updated by Oliver Hader almost 9 years ago
- Subject changed from FAL does not work with workspaces correct to Legacy uploadfolder does not work correct in workspaces
Updated by Alexander Opitz over 8 years ago
- Status changed from Needs Feedback to New
- Assignee set to Oliver Hader
Updated by Riccardo De Contardi almost 7 years ago
- Status changed from New to Closed
- Assignee deleted (
Oliver Hader)
Sorry for the so late answer; I close this issue as it is not related to the core and moreover there has been no activity on it since more than 1 year.
If you think that this is the wrong decision, please reopen it or open a new issue with a reference to this one. Thank you.