Bug #54670

"Create tag" raises error message: An error occurred while trying to call TYPO3\Media\Controller\AssetController->createTagAction()

Added by Chr is over 1 year ago. Updated over 1 year ago.

Status:Resolved Start date:2014-01-01
Priority:Must have Due date:
Assigned To:Christian Müller % Done:

0%

Category:-
Target version:-

Description

After uploading an image (abcxyz.png) via Neos backend GUI -> Management -> Media I tried to create a tag.

After pressing the "*Create tag*" Button I get an orange Error Message from Neos backend GUI:

An error occurred while trying to call TYPO3\Media\Controller\AssetController->createTagAction()

This happens with a fresh installation of Neos 1.0.1 with an new site OOTB.

NeosCreateTagBug.png - Screenshot Neos "Create tag"-Bug (16.1 kB) Chr is, 2014-01-01 17:16

History

#1 Updated by Chr is over 1 year ago

Screenshot attached.

#2 Updated by Gregor Agnes over 1 year ago

Hi, had the same issue.

Problem is: you have to type in a tag where it says "Enter tag label" and then hit "Create tag". After that you can drag the image on the tags you want or check the boxes in the single view.

#3 Updated by Chr is over 1 year ago

You are right, Gregor!

But this should be intercepted by Neos.

<WARNING: Wild guessing following...>

Packages/Application/TYPO3.Media/Classes/TYPO3/Media/Controller/AssetController.php

...has...

public function createTagAction($label)

...annotated with...

         * @Flow\Validate(argumentName="label", type="NotEmpty")

...assuring label field not being empty.

But if no tag is supplied the resulting error is not handled anywhere.

I read sth. about Flow Validation.

An adopted version of this snippet....

<f:form.validationResults for="label">
  <f:if condition="{validationResults.flattenedErrors}">
    <f:for each="{validationResults.flattenedErrors}" key="propertyPath" as="errors">
        <p>{propertyPath}</p>
        <f:for each="{errors}" as="error">
          <li>{error -> f:translate(key: error.code, arguments: error.arguments, package: 'TYPO3.Flow', source: 'ValidationErrors')}</li>
        </f:for>
    </f:for>
  </f:if>
</f:form.validationResults>

...might help somewhere in

Packages/Application/TYPO3.Media/Resources/Private/Templates/Asset/Index.html

Too bad my coding mojo is not strong enough to sort this out... :-(

#4 Updated by Gerrit Code Review over 1 year ago

  • Status changed from New to Under Review

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

#5 Updated by Christian Müller over 1 year ago

  • Status changed from Under Review to New
  • Assigned To set to Christian Müller

#6 Updated by Christian Müller over 1 year ago

  • Status changed from New to Under Review

#7 Updated by Gerrit Code Review over 1 year ago

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

#8 Updated by Gerrit Code Review over 1 year ago

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

#9 Updated by Christian Müller over 1 year ago

  • Status changed from Under Review to Resolved

Also available in: Atom PDF