Show files from subcategory

Phoca Download - download manager
mrRiddle
Phoca Newbie
Phoca Newbie
Posts: 2
Joined: 02 Nov 2020, 00:10

Show files from subcategory

Post by mrRiddle »

Hi!

I want to show some documents only to specific users. I have one category for public files that everyone should see and some subcategories, each for one user (who is set in category access rights). There I want put some invoices, contracts etc.

Is it possible to create one module which will show to user only what he is supposed to see?
I've tried to do this by custom module and Phoca download plugin. I've just put there tags for every categories like this:
{phocadownload view=filelist|id=6} <-- This one is for everyone
{phocadownload view=filelist|id=7} <-- This one is for user A only
{phocadownload view=filelist|id=8} <-- This one is for user B only
In that way everybody see everything although in file settings I've set not to display inaccessible files. I also noticed that plugin always show file even it's unpublished.
I use Joomla 3.9.22 and up to date plugin and component
What am I doing wrong?
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48550
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Show files from subcategory

Post by Jan »

Hi, if you need to manage access rights with Phoca Download, you should use component only. Component manages rights - so if you set some category will be accessible only for someone, it will be not displayed for public.

If you are using plugin, then all access rights are managed by the article, by com_content component, not by Phoca Download component.

Jan
If you find Phoca extensions useful, please support the project
mrRiddle
Phoca Newbie
Phoca Newbie
Posts: 2
Joined: 02 Nov 2020, 00:10

Re: Show files from subcategory

Post by mrRiddle »

So is there any way to show this as a module with other content on page?
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48550
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: Show files from subcategory

Post by Jan »

mrRiddle wrote: 02 Nov 2020, 23:59 So is there any way to show this as a module with other content on page?
Sorry, I don't understand.

If you will use component, the rights are managed by component, if you will use plugin or module inside the article, then the rights are just managed by the whole article.

Jan
If you find Phoca extensions useful, please support the project
Post Reply