aimeos / aimeos

Integrated online shop based on Laravel 10 and the Aimeos e-commerce framework for ultra-fast online shops, scalable marketplaces, complex B2B applications and #gigacommerce

Home Page:https://aimeos.org/Laravel

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Page item not foundf: admin/default/jqadm/search/dashboard?locale=en

cgcmart opened this issue · comments

Aimeos  \  MShop  \  Exception
No item found for conditions: Array ( [locale.site.code] => default )
App \ Http \ Middleware \ SetLocale: 25 handle
return $next($request);

aimeos_error1

aimeos_error1-1

commented

Either the Aimoes setup failed or you've removed the default site or renamed the default site without configuring the new site name with should be used by default.

Did you get any errors during setup?

no, setup smoothly. I successfully logged in admin and familiarized with aimeos for a while. and changed home page colors.
front pages look good and impressive.
a couple of days ago I installed extensions "aimeos/ai-cms-grapesjs", "aimeos/ai-cache", "aimeos/ai-catsuggest", and "aimeos/ai-filesystem"

Today, I wanted to log in admin and do something cms contents. But either admin or front has the same exception error.

@aimeos The issue indicated the related file app/Http/Middleware/SetLocale.php
Does this involve a recent php 8.2.4 update?

root@instance-3:~# locale
LANG=
LANGUAGE=
LC_CTYPE="POSIX"
LC_NUMERIC="POSIX"
LC_TIME="POSIX"
LC_COLLATE="POSIX"
LC_MONETARY="POSIX"
LC_MESSAGES="POSIX"
LC_PAPER="POSIX"
LC_NAME="POSIX"
LC_ADDRESS="POSIX"
LC_TELEPHONE="POSIX"
LC_MEASUREMENT="POSIX"
LC_IDENTIFICATION="POSIX"
LC_ALL=
root@instance-3:~# locale -a
C
C.UTF-8
POSIX
wenbo@instance-3:~$ locale
LANG=
LANGUAGE=
LC_CTYPE="POSIX"
LC_NUMERIC="POSIX"
LC_TIME="POSIX"
LC_COLLATE="POSIX"
LC_MONETARY="POSIX"
LC_MESSAGES="POSIX"
LC_PAPER="POSIX"
LC_NAME="POSIX"
LC_ADDRESS="POSIX"
LC_TELEPHONE="POSIX"
LC_MEASUREMENT="POSIX"
LC_IDENTIFICATION="POSIX"
LC_ALL=
wenbo@instance-3:~$ locale -a
C
C.UTF-8
POSIX
wenbo@instance-3:~/wenbo/public$ locale
LANG=
LANGUAGE=
LC_CTYPE="POSIX"
LC_NUMERIC="POSIX"
LC_TIME="POSIX"
LC_COLLATE="POSIX"
LC_MONETARY="POSIX"
LC_MESSAGES="POSIX"
LC_PAPER="POSIX"
LC_NAME="POSIX"
LC_ADDRESS="POSIX"
LC_TELEPHONE="POSIX"
LC_MEASUREMENT="POSIX"
LC_IDENTIFICATION="POSIX"
LC_ALL=
wenbo@instance-3:~/wenbo/public$ locale -a
C
C.UTF-8
POSIX

According to php manual setlocalce:

locales

If locales is the empty string "", the locale names will be set from the values of environment variables with the same names as the above categories, or from "LANG".

If locales is "0", the locale setting is not affected, only the current setting is returned.

If locales is followed by additional parameters then each parameter is tried to be set as new locale until success. This is useful if a locale is known under different names on different systems or for providing a fallback for a possibly not available locale.

locale_array

Each array element is tried to be set as new locale until success. This is useful if a locale is known under different names on different systems or for providing a fallback for a possibly not available locale.
commented

The SetLocale middleware is only the first one which fetches the default site item. Check the rows in the mshop_locale_site table what is available there and post it's contents, please.

The SetLocale middleware is only the first one which fetches the default site item. Check the rows in the mshop_locale_site table what is available there and post it's contents, please.

There is 1 row:

`mshop_locale_site` (`id`, `parentid`, `siteid`, `code`, `label`, `icon`, `logo`, `config`, `refid`, `theme`, `level`, `rating`, `ratings`, `invoiceno`, `nleft`, `nright`, `status`, `mtime`, `ctime`, `editor`) VALUES
(1, 0, '1.', 'wenbo.world', 'Wenbo', '1.d/icon.png', '{\"1\":\"1.d\\/logo.png\"}', '{\"resource\":{\"email\":{\"from-email\":\"dotcom@china-guide.com\",\"from-name\":\"Wenbo\"}},\"theme\":{\"default\":{\"--ai-product-image-ratio\":\"3\\/4\",\"--ai-bg\":\"#ffffff\",\"--ai-bg-alt\":\"#ffffcc\",\"--ai-primary\":\"#669933\",\"--ai-primary-alt\":\"#99cc33\",\"--ai-secondary\":\"#99cc66\",\"--ai-secondary-alt\":\"#7d7d2d\",\"--ai-tertiary\":\"#f7a586\",\"--ai-tertiary-alt\":\"#f6f6f6\",\"--ai-danger\":\"#a00000\",\"--ai-success\":\"#006000\",\"--ai-warning\":\"#ffa500\",\"--ai-radius\":\"0\"}}}', '', 'default', 0, '0.00', 0, 1, 1, 2, 1, '2023-03-18 20:12:16', '2023-03-12 16:28:20', 'dotcom@china-guide.com');
commented

You've renamed the site code from default to wenbo.world. This is only OK if you configure:

@aimeos Thank you very much! aimeos does a wonderful job. I prefer aimeos to typo3.