?
Referenced as Pull Request for: # 6130
avatar aasimali
aasimali
17 Jan 2015

-Go to 'Extension Manager: Manage'
-Select filter: select type>Component
-Select filter: select folder>captcha


Application will display many records, Ideally there should be no records

screen shot 2015-01-17 at 03 28 51

avatar aasimali aasimali - open - 17 Jan 2015
avatar brianteeman
brianteeman - comment - 17 Jan 2015

Confirmed

On 17 January 2015 at 09:29, Aasim Ali notifications@github.com wrote:

-Go to 'Extension Manager: Manage'
-Select filter: select type>Component

-Select filter: select folder>captcha

Application will display many records, Ideally there should be no records

[image: screen shot 2015-01-17 at 03 28 51]
https://camo.githubusercontent.com/d5e3cf4e0edd288303182a6b40d2cdc0da85b882/687474703a2f2f6973737565732e6a6f6f6d6c612e6f72672f75706c6f6164732f312f34366331346630633232616337646531646166373938396339396135393563652e706e67


Reply to this email directly or view it on GitHub
#5781.

Brian Teeman
Co-founder Joomla! and OpenSourceMatters Inc.
http://brian.teeman.net/

avatar brianteeman brianteeman - change - 17 Jan 2015
Labels Added: ?
avatar brianteeman brianteeman - change - 19 Jan 2015
Status New Confirmed
avatar Erftralle
Erftralle - comment - 19 Feb 2015

One can find the reason for this behaviour in the file administrator/components/com_installer/models/manage.php.

In the function getListQuery() lines 326-329 the folder filter is only applied if the type filter has specific values (namely 'plugin', 'library', '').

        if ($group != '' && in_array($type, array('plugin', 'library', '')))
        {
            $query->where('folder=' . $this->_db->quote($group == '*' ? '' : $group));
        }

So, if the type filter is set to 'component' the folder filter is not applied, no matter what is set there.
For me, this behavior is at least unexpected. I'm sure, the one who wrote that code has a different opinion.

It would be easy to change that behaviour by changing the code to

        if ($group != '' )
        {
            $query->where('folder=' . $this->_db->quote($group == '*' ? '' : $group));
        }

Then, regarding to your example filter setting (namely 'component', 'captcha'), no records would be listed.
I'll do a pull request if this solution will be supported.

avatar aasimali
aasimali - comment - 20 Feb 2015

@Erftralle

Hi, I'm not technically sounds like you but your suggestion sounds good. Can you made this change at your testing site and check this thoroughly? If it works nicely, then, you can made the pull request for this.
Thanks for your effort.

avatar infograf768
infograf768 - comment - 20 Feb 2015

I do confirm that the code proposed is fine, Please make a PR.

avatar Erftralle
Erftralle - comment - 20 Feb 2015

Thanks for your feedback. Opened pull request #6130.

avatar zero-24 zero-24 - change - 20 Feb 2015
Status Confirmed Closed
Closed_Date 0000-00-00 00:00:00 2015-02-20 13:40:20
Closed_By zero-24
avatar joomla-cms-bot
joomla-cms-bot - comment - 20 Feb 2015

Set to "closed" on behalf of @zero-24 by The JTracker Application at issues.joomla.org/joomla-cms/5781

avatar joomla-cms-bot joomla-cms-bot - close - 20 Feb 2015
avatar joomla-cms-bot joomla-cms-bot - close - 20 Feb 2015
avatar zero-24
zero-24 - comment - 20 Feb 2015

Closing as we have a PR by @Erftralle Thanks.


This comment was created with the J!Tracker Application at issues.joomla.org/joomla-cms/5781.

Add a Comment

Login with GitHub to post a comment