Author: david
Date: Tue Nov 9 09:29:12 2010
New Revision: 8806
Log:
Rollback r8781 - performance concerns are handled by the 'See all' behaviour of
the imageflow module.
Modified:
trunk/apps/qubit/modules/digitalobject/actions/imageflowComponent.class.php
Modified:
trunk/apps/qubit/modules/digitalobject/actions/imageflowComponent.class.php
==============================================================================
--- trunk/apps/qubit/modules/digitalobject/actions/imageflowComponent.class.php
Tue Nov 9 00:02:08 2010 (r8805)
+++ trunk/apps/qubit/modules/digitalobject/actions/imageflowComponent.class.php
Tue Nov 9 09:29:12 2010 (r8806)
@@ -38,7 +38,7 @@
}
// Add thumbs
- foreach ($children = $this->resource->getChildren() as $item)
+ foreach ($this->resource->descendants as $item)
{
if (null !== $digitalObject = $item->getDigitalObject())
{
@@ -59,8 +59,17 @@
}
}
- // Get total number of children
- $this->total = count($children);
+ // Get total number of descendant digital objects
+ $this->total = 0;
+ if (isset($this->resource))
+ {
+ $criteria = new Criteria;
+ $criteria->addJoin(QubitInformationObject::ID,
QubitDigitalObject::INFORMATION_OBJECT_ID);
+ $criteria->add(QubitInformationObject::LFT, $this->resource->lft,
Criteria::GREATER_THAN);
+ $criteria->add(QubitInformationObject::RGT, $this->resource->rgt,
Criteria::LESS_THAN);
+
+ $this->total = BasePeer::doCount($criteria)->fetchColumn(0);
+ }
if (2 > count($this->thumbnails))
{
--
You received this message because you are subscribed to the Google Groups
"Qubit Toolkit Commits" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/qubit-commits?hl=en.