Hello,
Is there a way to hide the "Files" tab is the user has not purchased any files?

Thanks!

Comments

saurabh.dhariwal’s picture

You can make view with purchased file count. You can also refer view which exists for File tab.

Load your view programatically in your module and get total count of purchased file.

You need to alter menu to remove File tab with view result count.

Refer link of menu alter here.

damienmckenna’s picture

Version: 7.x-2.0-beta1 » 7.x-2.x-dev