Page 1 of 1
Undefined property: stdClass::$numsubcat
Posted: 24 Sep 2014, 18:13
by fabo92
Hello,
I'm having this issue in a "List of categories" view.
Code: Select all
Notice: Undefined property: stdClass::$numsubcat in C:\xampp\htdocs\aet\components\com_phocadownload\models\categories.php on line 49
If there are no subcategories it doesn't display this message. Once I create one or more subcategories, this message appear.
I can't figure out what is missing, as $numsubcat should be defined (or not?).
Re: Undefined property: stdClass::$numsubcat
Posted: 26 Sep 2014, 00:14
by Jan
Hi, which version of Phoca Download you are running?
Jan
Re: Undefined property: stdClass::$numsubcat
Posted: 30 Sep 2014, 12:29
by fabo92
Last version, 3.0.5
Re: Undefined property: stdClass::$numsubcat
Posted: 30 Sep 2014, 23:22
by Jan
Hi, I see now, I have it fixed on localhost and will add it to next version, for now please do a quick fix:
Line cca 111 in file: components\com_phocadownload\models\categories.php
FROM:
Code: Select all
$query = " SELECT cc.id, cc.parent_id, cc.title, cc.alias, cc.access, cc.description, cc.accessuserid, COUNT(c.id) AS numdoc"
TO:
Code: Select all
$query = " SELECT cc.id, cc.parent_id, cc.title, cc.alias, cc.access, cc.description, cc.accessuserid, COUNT(c.id) AS numdoc, 0 AS numsubcat"
Jan
Re: Undefined property: stdClass::$numsubcat
Posted: 20 Oct 2014, 19:14
by fabo92
Hi, thank you very much for the reply. This solved my problem!
Re: Undefined property: stdClass::$numsubcat
Posted: 07 Nov 2014, 19:49
by Jan
Fixed in 3.0.6
Jan