4

I create a Extbase Extesion and i would like ingore validation on "showAction".

I define a Model Validation for my Model "Event" and add this annotation over my "showAction" in my "EventController".

/**
     * action show
     *
     * @param \Mab\Oaevents\Domain\Model\Events $events
     * @ignorevalidation $events
     * @return void
     */
public function showAction(\Mab\Oaevents\Domain\Model\Events $events) {
}

But it take no effect, the validation was not ignored. Have someone a hint why this validation not ignored?

smartcoderx
  • 1,021
  • 2
  • 14
  • 32
  • Did you clear the caches in the install tool after changing this? The results from parsing comments are cached, and those caches are not emptied when clearing frontend or general caches. – Jost Jul 30 '15 at 18:33
  • @jost now i clear the caches in install tool, the backend caches and empty the folder typo3temp. But this have no effects. I also try "@dontvalidate" instead of "@ignorevalidation" but this have also no effect. – smartcoderx Jul 30 '15 at 19:06
  • @smartcoderx did you fix that? I get same error( – Oleg V Karun Aug 30 '17 at 10:59
  • Did you tried this? https://docs.typo3.org/m/typo3/book-extbasefluid/master/en-us/9-CrosscuttingConcerns/2-validating-domain-objects.html#case-study-edit-an-existing-object * @Extbase\IgnoreValidation("events") instead of * @ignorevalidation $events – Paul Jun 20 '19 at 18:22

1 Answers1

2

Since TYPO3 9.0 it works like this:

/**
 * action show
 *
 * @param \Mab\Oaevents\Domain\Model\Events $events
 * @TYPO3\CMS\Extbase\Annotation\IgnoreValidation("events")
 * @return void
 */
public function showAction(\Mab\Oaevents\Domain\Model\Events $events)
{
}

Docs

smarvel
  • 40
  • 1
  • 6