News:

Support for jDownloads 3 has been ended
Since 17 August 2023 Joomla.org has discontinued support for Joomla 3.x. Therefore, we will no longer offer official support for our Joomla 3 jDownloads version 3.9.x from January 2024.
Please update your website to the latest Joomla version (Joomla 4 or Joomla 5) as soon as possible. Afterwards, please update jDownloads to the latest published version. The longer you delay, the more difficult the upgrade process for your website is likely to be.

Main Menu
Support-Forum

jDownloads Tree - list files in categories

Started by pixelhexe, 20.02.2019 17:21:36

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

pixelhexe

I am looking for a possibility to use the jDownloads Tree Module not only to show categories, but also to list files after expanding a category.

I thought I could customize it within the jdownloadstree.php with

echo "{jd_file category==".$this->elementArray[$parentID][$no][0]."}";

inside the "function drawSubNode(...", but in frontend I only see

{jd_file category==[number of my category]}

So unfortunately there is no possibility to use content plugins in the jDownloads Tree module?

Or is there another possibility to show a category tree and list files after click of category name? Sort of accordion effect.

Thanks for any advise!
  •  

ColinM

Hi
HiThe Tree module itself does only show categories.  It also can show the total number of sub cats and Downloads in that section of the tree.  Presently if you click on a category then the contents of that category, including sub categories and Downloads, are shown in the main area.  I think this goes a long way towards what you are suggesting.  Probably a selectable choice of Layout approprawould be very much
I have assumed you are displaying the Tree Module in a side panel or similar.

There is an attraction in extending it to show Downloads but in many cases there would be quite a large number.  Your suggestion of an 'accordian' view is interesting.  It would mean quite a lot of extra coding.  The other approach is to have an associated 'panel' displayed also in the same side panel - say below it that shows just the Downloads in the current sub cat.  Such a panel could have a vertical scroll bar.
Presently we are working on the next major release of jD so could you perhaps add to Suggestions with a suitable scheme.
ThanksColin
Colin M
  •  

pixelhexe

I would like to thank you for your quick reply! And I would like to give you also a quick reply:


I finally found a solution without the Tree Module (whose layout does not fit my needs).  I used the {listbox} with several template overrides to simulate a category navigation. In addition I developed  overrides for using font icons -  see attachment. The jdownloads code needs to be optimized for multilingual sites - I had to change jdownloadshelper.php for example:
  $cat->title = str_repeat('- ', $repeat) . $cat->title;
->
$cat->title = str_repeat('» ', $repeat) . JText::_(''.$cat->title.'');
Also in the templates, of course,  but this was manageable.
My customer is quite happy with the result and so am I. :)

Nevertheless an accordion option would be great in a future version of jDownloads.  Thanks for the good work.

[gelöscht durch Administrator]
  •  

ColinM

Hi
That looks very nice! Will certainly bring to Arno's attention.And thanks for tip about multi lingual.

Colin
Colin M
  •  

Arno

Hi pixelhexe.
QuoteI finally found a solution without the Tree Module (whose layout does not fit my needs).  I used the {listbox} with several template overrides to simulate a category navigation.

Leider verstehe ich nicht wovon du hier sprichst. Was meinst du mit dem Platzhalter {listbox}? Ist das ein Modul? Oder ein Content plugin?

Optisch gefällt mir deine Lösung sehr, daher wären ein paar mehr detailierte Infos hilfreich.
Best Regards / Gruß
Arno
Please make a Donation for jDownloads and/or write a review on the Joomla! Extensions directory!
  •