Project

General

Profile

Actions

Bug #72294

closed

Can't delete FAL image in flexform

Added by Armin Vieweg almost 9 years ago. Updated about 7 years ago.

Status:
Closed
Priority:
Should have
Category:
FormEngine aka TCEforms
Target version:
Start date:
2015-12-17
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
7
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

I have got a FAL field with the following configuration.

<config>
    <type>inline</type>
    <foreign_table>sys_file_reference</foreign_table>
    <foreign_field>uid_foreign</foreign_field>
    <foreign_sortby>sorting_foreign</foreign_sortby>
    <foreign_table_field>tablenames</foreign_table_field>
    <foreign_match_fields>
        <fieldname>image</fieldname> <!-- CAUTION!! Replace "fal" with the variable name of this field! -->
    </foreign_match_fields>
    <foreign_label>uid_local</foreign_label>
    <foreign_selector>uid_local</foreign_selector>
    <foreign_selector_fieldTcaOverride>
        <config>
            <appearance>
                <elementBrowserType>file</elementBrowserType>
                <elementBrowserAllowed>gif,jpg,jpeg,tif,tiff,bmp,pcx,tga,png,pdf,ai</elementBrowserAllowed>
            </appearance>
        </config>
    </foreign_selector_fieldTcaOverride>
    <foreign_types type="array">
        <numIndex index="2">
            <showitem>--palette--;LLL:EXT:lang/locallang_tca.xlf:sys_file_reference.imageoverlayPalette;imageoverlayPalette,--palette--;;filePalette</showitem>
        </numIndex>
    </foreign_types>

    <minitems>1</minitems>
    <maxitems>1</maxitems>

    <appearance>
        <useSortable>1</useSortable>
        <headerThumbnail>
            <field>uid_local</field>
            <width>45c</width>
            <height>45</height>
        </headerThumbnail>

        <showPossibleLocalizationRecords>0</showPossibleLocalizationRecords>
        <showRemovedLocalizationRecords>0</showRemovedLocalizationRecords>
        <showSynchronizationLink>0</showSynchronizationLink>
        <useSortable>1</useSortable>
        <enabledControls>
            <info>1</info>
            <new>0</new>
            <dragdrop>0</dragdrop>
            <sort>1</sort>
            <hide>1</hide>
            <delete>1</delete>
            <localize>1</localize>
        </enabledControls>

        <createNewRelationLinkTitle>LLL:EXT:cms/locallang_ttc.xlf:images.addFileReference</createNewRelationLinkTitle>
    </appearance>

    <behaviour>
        <localizationMode>select</localizationMode>
        <localizeChildrenAtParentLocalization>1</localizeChildrenAtParentLocalization>
    </behaviour>
</config>

I am not able to delete the image. Furthermore javascript errors appear. Please see attached screenshot. Occured in TYPO3 7.6.1


Files

2015-12-17_1228.png (49.9 KB) 2015-12-17_1228.png Armin Vieweg, 2015-12-17 12:32

Related issues 2 (0 open2 closed)

Related to TYPO3 Core - Bug #72379: Show button 'add image' after delete inline failsClosedFrank Nägler2015-12-22

Actions
Related to TYPO3 Core - Bug #78479: FAL field (in flexform) with minitems=1 and maxitems=1 has no possibility to add image after deleting the previous oneClosed2016-10-28

Actions
Actions #1

Updated by Armin Vieweg almost 9 years ago

This was the line in JS which caused the error:

document.getElementsByName('cmd' + shortName + '[delete]')[0].disabled = false;

And it is not appearing always. Set minitems and maxitems both to 1 seems to be the reason. I want just one image which is required.

Actions #2

Updated by Armin Vieweg almost 9 years ago

When minitems is 0 you are able to delete the image.
But the row in IRRE does not disappear (fade out). The success of deletion becomes only visible, when you save the whole record.

Actions #3

Updated by Gerrit Code Review almost 9 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/45354

Actions #4

Updated by Andreas Kienast almost 9 years ago

  • Status changed from Under Review to Accepted
Actions #5

Updated by Morton Jonuschat almost 9 years ago

  • Category set to FormEngine aka TCEforms
  • Assignee set to Morton Jonuschat
  • Target version set to 7.6.2
Actions #6

Updated by Gerrit Code Review almost 9 years ago

  • Status changed from Accepted to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/45364

Actions #7

Updated by Gerrit Code Review almost 9 years ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/45364

Actions #8

Updated by Gerrit Code Review almost 9 years ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/45364

Actions #9

Updated by Gerrit Code Review almost 9 years ago

Patch set 1 for branch TYPO3_7-6 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/45401

Actions #10

Updated by Morton Jonuschat almost 9 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
Actions #11

Updated by Riccardo De Contardi about 7 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF