29
0
mirror of https://github.com/joomla/joomla-cms.git synced 2024-06-27 07:33:41 +00:00

[4.0][admin menu] - fix wrong group by in preset menu (#25938)

* fix wrong group by

* fix wrong group by

* fix wrong group by

* lang_code

* lang_code

* lang_code
This commit is contained in:
Nicola Galgano 2019-08-20 10:21:08 +02:00 committed by infograf768
parent a990c239eb
commit 0df712246f
3 changed files with 6 additions and 6 deletions

View File

@ -134,11 +134,11 @@
type="separator"
title="JSITE"
hidden="false"
sql_select="a.title, a.menutype, CASE COALESCE(SUM(m.home), 0) WHEN 0 THEN '' WHEN 1 THEN CASE m.language WHEN '*' THEN 'class:icon-home' ELSE CONCAT('image:', l.lang_code) END ELSE 'image:mod_languages/icon-16-language.png' END AS icon"
sql_select="a.id, a.title, a.menutype, CASE COALESCE(SUM(m.home), 0) WHEN 0 THEN '' WHEN 1 THEN CASE m.language WHEN '*' THEN 'class:icon-home' ELSE CONCAT('image:', l.lang_code) END ELSE 'image:mod_languages/icon-16-language.png' END AS icon"
sql_from="#__menu_types AS a"
sql_where="a.client_id = 0"
sql_leftjoin="#__menu AS m ON m.menutype = a.menutype AND m.home = 1 LEFT JOIN #__languages AS l ON l.lang_code = m.language"
sql_group="a.id, a.title, a.menutype, m.language, l.image"
sql_group="a.id, a.title, a.menutype, m.language, l.lang_code"
sql_order="a.id DESC"
>
<menuitem

View File

@ -36,11 +36,11 @@
title="JSITE"
icon="desktop"
hidden="false"
sql_select="a.title, a.menutype, CASE COALESCE(SUM(m.home), 0) WHEN 0 THEN '' WHEN 1 THEN CASE m.language WHEN '*' THEN 'class:icon-home' ELSE CONCAT('image:', l.lang_code) END ELSE 'image:mod_languages/icon-16-language.png' END AS icon"
sql_select="a.id, a.title, a.menutype, CASE COALESCE(SUM(m.home), 0) WHEN 0 THEN '' WHEN 1 THEN CASE m.language WHEN '*' THEN 'class:icon-home' ELSE CONCAT('image:', l.lang_code) END ELSE 'image:mod_languages/icon-16-language.png' END AS icon"
sql_from="#__menu_types AS a"
sql_where="a.client_id = 0"
sql_leftjoin="#__menu AS m ON m.menutype = a.menutype AND m.home = 1 LEFT JOIN #__languages AS l ON l.lang_code = m.language"
sql_group="a.id, a.title, a.menutype, m.language, l.image"
sql_group="a.id, a.title, a.menutype, m.language, l.lang_code"
sql_order="a.id DESC"
sql_target="self"
>

View File

@ -191,11 +191,11 @@
type="separator"
title="JSITE"
hidden="false"
sql_select="a.title, a.menutype, CASE COALESCE(SUM(m.home), 0) WHEN 0 THEN '' WHEN 1 THEN CASE m.language WHEN '*' THEN 'class:icon-home' ELSE CONCAT('image:', l.lang_code) END ELSE 'image:mod_languages/icon-16-language.png' END AS icon"
sql_select="a.id, a.title, a.menutype, CASE COALESCE(SUM(m.home), 0) WHEN 0 THEN '' WHEN 1 THEN CASE m.language WHEN '*' THEN 'class:icon-home' ELSE CONCAT('image:', l.lang_code) END ELSE 'image:mod_languages/icon-16-language.png' END AS icon"
sql_from="#__menu_types AS a"
sql_where="a.client_id = 0"
sql_leftjoin="#__menu AS m ON m.menutype = a.menutype AND m.home = 1 LEFT JOIN #__languages AS l ON l.lang_code = m.language"
sql_group="a.id, a.title, a.menutype, m.language, l.image"
sql_group="a.id, a.title, a.menutype, m.language, l.lang_code"
sql_order="a.id DESC">
<menuitem
title="{sql:title} "