alnv / contao-catalog-manager-bundle

Catalog Manager
https://catalog-manager.org/
5 stars 0 forks source link

PHP8 Warning :: Undefined array key "order" #5

Open contaoacademy opened 1 year ago

contaoacademy commented 1 year ago

ErrorException: Warning: Undefined array key "order"

  at vendor/alnv/catalog-manager-bundle/src/Helper/Toolkit.php:290
  at Alnv\ContaoCatalogManagerBundle\Helper\Toolkit::Alnv\ContaoCatalogManagerBundle\Helper\{closure}(array('field' => 'sorting'))
  at array_map(object(Closure), array(array('field' => 'sorting')))
     (vendor/alnv/catalog-manager-bundle/src/Helper/Toolkit.php:286)
  at Alnv\ContaoCatalogManagerBundle\Helper\Toolkit::getOrderByStatementFromArray(array(array('field' => 'sorting')))
     (vendor/alnv/catalog-manager-bundle/src/Modules/Listing.php:190)
  at Alnv\ContaoCatalogManagerBundle\Modules\Listing->setOrder()
     (vendor/alnv/catalog-manager-bundle/src/Modules/Listing.php:46)
  at Alnv\ContaoCatalogManagerBundle\Modules\Listing->setOptions()
     (vendor/alnv/catalog-manager-bundle/src/Modules/Listing.php:77)
  at Alnv\ContaoCatalogManagerBundle\Modules\Listing->compile()
     (vendor/contao/core-bundle/src/Resources/contao/classes/Hybrid.php:230)
  at Contao\Hybrid->generate()
     (vendor/alnv/catalog-manager-bundle/src/Modules/Listing.php:40)
  at Alnv\ContaoCatalogManagerBundle\Modules\Listing->generate()
     (vendor/alnv/catalog-manager-bundle/src/Elements/ContentListView.php:25)
  at Alnv\ContaoCatalogManagerBundle\Elements\ContentListView->generate()
     (vendor/contao/core-bundle/src/Resources/contao/library/Contao/Controller.php:621)
  at Contao\Controller::getContentElement(object(ContentModel), 'main')
     (vendor/contao/core-bundle/src/Resources/contao/modules/ModuleArticle.php:197)
  at Contao\ModuleArticle->compile()
     (vendor/contao/core-bundle/src/Resources/contao/modules/Module.php:214)
  at Contao\Module->generate()
     (vendor/contao/core-bundle/src/Resources/contao/modules/ModuleArticle.php:70)
  at Contao\ModuleArticle->generate(false)
     (vendor/contao/core-bundle/src/Resources/contao/library/Contao/Controller.php:549)
  at Contao\Controller::getArticle(object(ArticleModel), true, false, 'main')
     (vendor/contao/core-bundle/src/Resources/contao/library/Contao/Controller.php:391)
  at Contao\Controller::getFrontendModule('0', 'main')
     (vendor/contao/core-bundle/src/Resources/contao/pages/PageRegular.php:190)
  at Contao\PageRegular->prepare(object(PageModel))
     (vendor/contao/core-bundle/src/Resources/contao/pages/PageRegular.php:60)
  at Contao\PageRegular->getResponse(object(PageModel), true)
     (vendor/contao/core-bundle/src/Resources/contao/controllers/FrontendIndex.php:320)
  at Contao\FrontendIndex->renderPage(object(PageModel))
     (vendor/symfony/http-kernel/HttpKernel.php:163)
  at Symfony\Component\HttpKernel\HttpKernel->handleRaw(object(Request), 1)
     (vendor/symfony/http-kernel/HttpKernel.php:75)
  at Symfony\Component\HttpKernel\HttpKernel->handle(object(Request), 1, true)
     (vendor/symfony/http-kernel/Kernel.php:202)
  at Symfony\Component\HttpKernel\Kernel->handle(object(Request))
     (public/index.php:44)

Hier meine Konfiguration: screen-20230323_ewzaaoRP

asaage commented 4 months ago

Similar problem here: FE-Warninng in debugmode: Warning: Undefined array key "order" Config like this: image I can eliminate the warning if i add a sorting-direction (ASC/DESC). image But then there the draghandles for manual sorting in the BE are gone.