omeka-s-modules / Collecting

GNU General Public License v3.0
2 stars 6 forks source link

error when sending form (but data sent) #46

Closed pprw closed 4 years ago

pprw commented 5 years ago

I have the following error after fill out a form in Omeka S 2.0.2.

The data is correctly sent however.

Zend\Permissions\Acl\Exception\InvalidArgumentException
Resource 'Omeka\Controller\Site\Collecting' not found

Détails :

Zend\Permissions\Acl\Exception\InvalidArgumentException: Resource 'Omeka\Controller\Site\Collecting' not found in /sites/test/www/web_main/vendor/zendframework/zend-permissions-acl/src/Acl.php:291
Stack trace:
#0 /sites/test/www/web_main/vendor/zendframework/zend-permissions-acl/src/Acl.php(737): Zend\Permissions\Acl\Acl->getResource('Omeka\\Controlle...')
#1 /sites/test/www/web_main/application/src/Permissions/Acl.php(87): Zend\Permissions\Acl\Acl->isAllowed(NULL, 'Omeka\\Controlle...', 'success')
#2 /sites/test/www/web_main/application/src/Mvc/MvcListeners.php(434): Omeka\Permissions\Acl->userIsAllowed('Omeka\\Controlle...', 'success')
#3 /sites/test/www/web_main/vendor/zendframework/zend-eventmanager/src/EventManager.php(322): Omeka\Mvc\MvcListeners->authorizeUserAgainstController(Object(Zend\Mvc\MvcEvent))
#4 /sites/test/www/web_main/vendor/zendframework/zend-eventmanager/src/EventManager.php(179): Zend\EventManager\EventManager->triggerListeners(Object(Zend\Mvc\MvcEvent), Object(Closure))
#5 /sites/test/www/web_main/vendor/zendframework/zend-mvc/src/Application.php(332): Zend\EventManager\EventManager->triggerEventUntil(Object(Closure), Object(Zend\Mvc\MvcEvent))
#6 /sites/test/www/web_main/index.php(21): Zend\Mvc\Application->run()
#7 {main}
jimsafley commented 5 years ago

I can't reproduce this. Do you have a publicly accessible link to the form that I can see?

pprw commented 5 years ago

Yes : https://erudhilor.huma-num.fr/page/ajout_erudit

jimsafley commented 5 years ago

Your site is rewriting the URL to remove the "/s/erudhilor" part of the path. Omeka S does not support this behavior, in part because that part maps to ACL resources that modules add. In your case, the form should end up at "/s/erudhilor/collecting/1/success", but Apache automatically rewrites it to a subdomain, which Omeka does not recognize when resolving the path to the ACL resource.

pprw commented 5 years ago

Ok, so it is a incompatibility between the module OmekaSDomainManager which I use and the collecting module.

What I don't know is which module should be updated to fix this.

jimsafley commented 5 years ago

Ah, then it's likely a routing issue, not a URL rewrite issue, probably something to do with how OmekaSDomainManager (which we don't develop) handles redirects. This is not a bug in the Collecting module.