41 Posts
mlep
6 years ago
9
Topic

Hi everybody,

I have upgraded Seblod (3.10.0 -> 3.11.2), no-core fields and JB Slicked list (3.0.1 to 3.1.2).

I had a list of elements (with JB slicked list template) called by a SEBLOD List field in a container list (with JB slicked list too). It is to render elements created per month.

Before upgrade, I had this :


<div class="my-slick-class">
<div class=" ">
<h2>Biographies de mai </h2>
<label class="label">COM_CCK_MPLF_Liste_fiches</label>
<div class="cck_module_list">
<div>
<div>
<div >
<button data-role="none" aria-label="<" role="button" style="display: block;"><</button>
<div aria-live="polite">
+ <div style="opacity: 1; width: 3850px; transform: translate3d(-2200px, 0px, 0px);" role="listbox">
+ <div style="width: 275px;" data-slick-index="-4" aria-hidden="true" tabindex="-1">
+ <div style="width: 275px;" data-slick-index="-3" aria-hidden="true" tabindex="-1">
+ <div style="width: 275px;" data-slick-index="-2" aria-hidden="true" tabindex="-1">
+ <div style="width: 275px;" data-slick-index="-1" aria-hidden="true" tabindex="-1">
+ <div style="width: 275px;" data-slick-index="0" aria-hidden="true" tabindex="-1" role="option" aria-describedby="slick-slide00">
+ <div style="width: 275px;" data-slick-index="1" aria-hidden="true" tabindex="-1" role="option" aria-describedby="slick-slide01">
+ <div style="width: 275px;" data-slick-index="2" aria-hidden="true" tabindex="-1" role="option" aria-describedby="slick-slide02">
+ <div style="width: 275px;" data-slick-index="3" aria-hidden="true" tabindex="-1" role="option" aria-describedby="slick-slide03">
+ <div style="width: 275px;" data-slick-index="4" aria-hidden="false" tabindex="-1" role="option" aria-describedby="slick-slide04">
+ <div style="width: 275px;" data-slick-index="5" aria-hidden="false" tabindex="-1" role="option" aria-describedby="slick-slide05">
+ <div style="width: 275px;" data-slick-index="6" aria-hidden="false" tabindex="-1">
+ <div style="width: 275px;" data-slick-index="7" aria-hidden="false" tabindex="-1">
+ <div style="width: 275px;" data-slick-index="8" aria-hidden="true" tabindex="-1">
+ <div style="width: 275px;" data-slick-index="9" aria-hidden="true" tabindex="-1">
</div>
<button data-role="none" aria-label=">" role="button" style="display: block;">></button>
</div>
<div style="display: none;"></div>
</div>
</div>
</div>
</div>
...

and after upgrade :

<div class="my-slick-class">
<div " ">
<h2>Biographies de mai </h2>
<label class="label">COM_CCK_MPLF_Liste_fiches</label>
<div class="cck_module_list">
<div></div>
</div>
</div>

....

My container list is still there but not my elements list. However I can see it in administrator by clicking the eye icon before my list name (List items using this search). I have checked every field and template config...

Could someone give me an idea ?

Thanks a lot

Marion

Get a VIP membership
4229 Posts
Kadministrator
6 years ago
5
Level 1

Bucklash is the one that should answer this

41 Posts
mlep
6 years ago
4
Level 2

Jon, where are you ? 😉

1283 Posts
Bucklash
6 years ago
3
Level 3

Hi

I will have a look, hopefully today or tomorrow. 

Have you tried with Seb List to compare results?

1283 Posts
Bucklash
6 years ago
2
Level 4

Hello Mlep

I've recreated your scenario, and it works...

Parent List

  • List Field in 'List' View
  • Field with name 'some_parent_field' in 'List View'
  • List Field Config = Fields set as [some_child_field=some_parent_field]
  • Slick On with slick class applied, plus the other slick settings

Child View

  • Field with name 'some_child_field' in 'Search Form' View
  • Slick Off

I also have tried with Search Form Above and Below, in each case it works fine.

I know Seblod has replaced the use of Helper_Include to JCckDev but that class isn't used in the template.

I had a few overrides than needed changing because of that change but other than ideas like that, I'm not sure what the problem could be.

If the nested list does not show with Seb List then that will help narrow the search

Will keep digging in the mean time.

41 Posts
mlep
6 years ago
1
Level 5

Thanks a lot Jon for helping.

In my case, slick is OFF on parent view and ON on child view. So I have tried to replace slicked template of Parent view with seblist one. It does not work better. I have my correct parent list but not child one (<div> </div>).

I have set this in before render field of element :

echo($fields['mplf_date_debut_mois']->value);
echo($fields['mplf_date_fin_mois']->value);

and the result is correct :

2017-05-012017-05-312017-04-012017-04-302017-03-012017-03-312017-02-012017-02-282017-01-012017-01-312016-12-012016-12-31

In SEBLOD list field config, the child=parent fields are :

mplf_publication_mois_max=mplf_date_fin_mois

mplf_publication_mois_min=mplf_date_debut_mois

To test child slicked list I have created a menu with this overide :

MPLF Publication mois min -> 2017-05-01

MPLF Publication mois max -> 2017-05-31

and this slick is ok.

So, it seems like Seblod list field does not find the child list. I have checked the name of list and child=parent fields...

I don't understand why !!!! However it works fine before update (Seblod, fields and templates an Joomla 3.7.2).

Thanks again, Bucklash

1283 Posts
Bucklash
6 years ago
0
Level 6

Hi

Hmmm..

I have just reversed the order, so 

  • OFF: Parent Slick
  • ON: Child Slick
  • RESULT: I see results and it is 'Slicked'
  • MODAL: Modal was not liking that as the same modal class names was being used for each group of items i.e modal-trigger-1, modal-trigger-2, modal-trigger-3....  but that seems fair enough to me.

I will dig a bit bit more....

-------

Just tested with date as value and all is good (I modified dates in the db so that I would have results) art_modified=art_publish_up.

-------

So, I wonder where the problem/conflict/issue starts, with upgrade of Joomla, Seblod or Slicked List?

41 Posts
mlep
6 years ago
2
Level 1

I have not solved my problem. I think the problem is not a template list issue (JB slick list)

In my parent list I have a before render code :

$x = $fields['fic_mois']->value;
$sDateDebut = date("Y-m-d", mktime(0,0,0,date("m")-$x,1,date("Y")));
$sDateFin = date("Y-m-d", mktime(0,0,0,date("m")+1-$x,0,date("Y")));
$mois = date("F", mktime(0,0,0,date("m")-$x,1,date("Y")));

$fields['mplf_date_debut_mois']->value = $sDateDebut;
$fields['mplf_date_fin_mois']->value = $sDateFin;
$fields['fic_mois_lettres']->value = '
<h2>Biographies de '.JText::_($mois).'
</h2>
';

where fic_mois values are 1, 2, 3... 12

If I add an echo($fields['mplf_date_debut_mois']->value); echo($fields['mplf_date_fin_mois']->value);

values are ok :  2017-05-012017-05-31...

I added mplf_date_debut_mois, mplf_date_fin_mois and fic_mois fields in hidden position)

In parent list, I inserted a child list with a Seblod list field with this options :

mplf_publication_mois_max=mplf_date_fin_mois

mplf_publication_mois_min=mplf_date_debut_mois

where mplf_publication_mois_max and mplf_publication_mois_min are article created (and are added to child search form view)

But, if I put the debugging in child list, I get this :

SELECT t0.id AS pid,t0.pk AS pk,t0.pkb AS pkb,t0.parent_id AS parent,t0.author_id AS author,t0.cck AS cck,t0.storage_location AS loc,tt.id AS type_id,tt.alias AS type_alias
FROM `#__cck_core` AS t0
LEFT JOIN `#__content` AS t1 ON t1.id = t0.pk
LEFT JOIN `#__cck_core_types` AS tt ON tt.name = t0.cck
WHERE t1.state = 1
AND t1.access IN (1,1,2,3,6,7)
AND ( t1.publish_up = '0000-00-00 00:00:00' OR t1.publish_up <= '2017-06-12 11:07' )
AND ( t1.publish_down = '0000-00-00 00:00:00' OR t1.publish_down >= '2017-06-12 11:07' )
AND t1.created >= '2016-10-27 16:40:50'
AND t1.created < '2016-10-27 16:40:50'

AND t0.cck = 'mplf'
ORDER BY t1.title ASC

SELECT COUNT(t0.id)
FROM `#__cck_core` AS t0
LEFT JOIN `#__content` AS t1 ON t1.id = t0.pk
LEFT JOIN `#__cck_core_types` AS tt ON tt.name = t0.cck
WHERE t1.state = 1
AND t1.access IN (1,1,2,3,6,7)
AND ( t1.publish_up = '0000-00-00 00:00:00' OR t1.publish_up <= '2017-06-12 11:07' )
AND ( t1.publish_down = '0000-00-00 00:00:00' OR t1.publish_down >= '2017-06-12 11:07' )
AND t1.created >= '2016-10-27 16:40:50'
AND t1.created < '2016-10-27 16:40:50'

AND t0.cck = 'mplf'

and, of course no result because of created date (first article created date).

So what is the problem : before render field ? seblod list field ? Why mplf_publication_mois_max and mplf_publication_mois_min values are not those calculated by before render code ?

Before the update, it worked perfectly : Did I miss something ?

Thanks anyone could help me !

1283 Posts
Bucklash
6 years ago
1
Level 2

Hi

I think it might be worth reposting as a different question, with focus on debugging info. 

Glad it down' seem to be the template, shame no closer to solving. 

Jon

41 Posts
mlep
6 years ago
0
Level 3

Thanks Jon, I will do.

Get a Book for SEBLOD