Base Item not working
7 years 3 months ago #46445
by ferpa3000
Base Item not working was created by ferpa3000
Hello!
I love this extension, but I found a bug that is really annoying.
The base item selection is not working as it should. As I understand, the base item should show only the marked items on the selected pages. But instead, it shows the selected marked items plus the items relative the active page.
For instance, this is a a menu from a site I've made: (vivacitas.com.br)
SERVIÇOS (parent - this is set as base item and start level 2. It shows this menu at all pages, that is ok)
- Coaching
- Consultoria
- Gestão de Pessoas
- Recrutamento e Seleção
- Treinamentos e Programas
- Mapa Sistêmico
BLOG (parent)
- Carreira
- Consultoria e Treinamentos
- Conflito de Gerações
- Etiqueta Empresarial
- Desenvolvimento de Equipes
Now, if I visit the "Coaching" page, under SERVICOS, the result is correct. The menu shows only the links under SERVICOS.
But, when I visit a page that is under BLOG, it show both the items under SERVICOS and BLOG.
If I visit the page "Carreira" this is what the menu shows:
- Coaching
- Consultoria
- Gestão de Pessoas
- Recrutamento e Seleção
- Treinamentos e Programas
- Mapa Sistêmico
- Carreira
- Consultoria e Treinamentos
- Conflito de Gerações
- Etiqueta Empresarial
- Desenvolvimento de Equipes
It just adds the current page relatives to the menu.
Can you help me figure this out?
Thanks.
Fernando
I love this extension, but I found a bug that is really annoying.
The base item selection is not working as it should. As I understand, the base item should show only the marked items on the selected pages. But instead, it shows the selected marked items plus the items relative the active page.
For instance, this is a a menu from a site I've made: (vivacitas.com.br)
SERVIÇOS (parent - this is set as base item and start level 2. It shows this menu at all pages, that is ok)
- Coaching
- Consultoria
- Gestão de Pessoas
- Recrutamento e Seleção
- Treinamentos e Programas
- Mapa Sistêmico
BLOG (parent)
- Carreira
- Consultoria e Treinamentos
- Conflito de Gerações
- Etiqueta Empresarial
- Desenvolvimento de Equipes
Now, if I visit the "Coaching" page, under SERVICOS, the result is correct. The menu shows only the links under SERVICOS.
But, when I visit a page that is under BLOG, it show both the items under SERVICOS and BLOG.
If I visit the page "Carreira" this is what the menu shows:
- Coaching
- Consultoria
- Gestão de Pessoas
- Recrutamento e Seleção
- Treinamentos e Programas
- Mapa Sistêmico
- Carreira
- Consultoria e Treinamentos
- Conflito de Gerações
- Etiqueta Empresarial
- Desenvolvimento de Equipes
It just adds the current page relatives to the menu.
Can you help me figure this out?
Thanks.
Fernando
Please Log in or Create an account to join the conversation.
7 years 3 months ago #46447
by ced1870
Joomlack Webmaster and Developer
Replied by ced1870 on topic Base Item not working
Hi
if you use a native joomla menu module, do you have the same behavior or not ?
CEd
if you use a native joomla menu module, do you have the same behavior or not ?
CEd
Joomlack Webmaster and Developer
Please Log in or Create an account to join the conversation.
7 years 3 months ago #46500
by ferpa3000
Replied by ferpa3000 on topic Base Item not working
No. With the native joomla menu module it works correctly.
Please Log in or Create an account to join the conversation.
7 years 3 months ago #46504
by ced1870
Joomlack Webmaster and Developer
Replied by ced1870 on topic Base Item not working
please remind me next week, I will check that
Joomlack Webmaster and Developer
Please Log in or Create an account to join the conversation.
7 years 3 months ago #46598
by ferpa3000
Replied by ferpa3000 on topic Base Item not working
Hello CEd, just reminding you about this problem.
Please Log in or Create an account to join the conversation.
7 years 2 months ago - 7 years 2 months ago #46727
by ced1870
Joomlack Webmaster and Developer
Replied by ced1870 on topic Base Item not working
Hi
please edit the file modules/mod_accordeonck/helper.php
line 49 to 60
replace it with
then check if it works
please edit the file modules/mod_accordeonck/helper.php
line 49 to 60
Code:
if (($start && $start > $item->level)
|| ($end && $item->level > $end)
|| (!$showAll && $item->level > 1
&& (!in_array($item->parent_id, $path) && !in_array($item->parent_id, $pathActive))
)
//|| ($maxdepth && $item->level > $maxdepth)
|| ($start > 1 && !in_array($item->tree[$start - 2], $path)
&& $start > 1 && !in_array($item->tree[$start - 2], $pathActive))
) {
unset($items[$i]);
continue;
}
Code:
if (($start && $start > $item->level)
|| ($end && $item->level > $end)
|| (!$showAll && $item->level > 1 && !in_array($item->parent_id, $path))
|| ($start > 1 && !in_array($item->tree[$start - 2], $path)))
{
unset($items[$i]);
continue;
}
then check if it works
Joomlack Webmaster and Developer
Last edit: 7 years 2 months ago by ced1870.
Please Log in or Create an account to join the conversation.
Time to create page: 0.209 seconds