Author: david
Date: Fri Oct 14 12:29:23 2011
New Revision: 10094

Log:
Add checkbox to include thumbs

Modified:
   trunk/apps/qubit/modules/informationobject/actions/itemListAction.class.php
   trunk/apps/qubit/modules/informationobject/templates/itemListCriteria.php

Modified: 
trunk/apps/qubit/modules/informationobject/actions/itemListAction.class.php
==============================================================================
--- trunk/apps/qubit/modules/informationobject/actions/itemListAction.class.php 
Fri Oct 14 08:56:20 2011        (r10093)
+++ trunk/apps/qubit/modules/informationobject/actions/itemListAction.class.php 
Fri Oct 14 12:29:23 2011        (r10094)
@@ -31,7 +31,8 @@
   // Arrays not allowed in class constants
   public static
     $NAMES = array(
-      'sortBy'
+      'sortBy',
+      'includeThumbnails'
     );
 
   protected function addField($name)
@@ -57,6 +58,19 @@
           'choices' => $choices)));
 
         break;
+
+      case 'includeThumbnails':
+        $choices = array(
+          '1' => $this->context->i18n->__('Yes')
+        );
+
+        $this->form->setValidator($name, new sfValidatorChoice(array('choices' 
=> array_keys($choices))));
+        $this->form->setWidget($name, new sfWidgetFormChoice(array(
+          'expanded' => true,
+          'multiple' => true,
+          'choices' => $choices)));
+
+        break;
     }
   }
 

Modified: 
trunk/apps/qubit/modules/informationobject/templates/itemListCriteria.php
==============================================================================
--- trunk/apps/qubit/modules/informationobject/templates/itemListCriteria.php   
Fri Oct 14 08:56:20 2011        (r10093)
+++ trunk/apps/qubit/modules/informationobject/templates/itemListCriteria.php   
Fri Oct 14 12:29:23 2011        (r10094)
@@ -10,6 +10,8 @@
 
 <?php echo render_show(__('Sort by'), $form->sortBy) ?>
 
+<?php echo render_show(__('Include thumbnails'), $form->includeThumbnails) ?>
+
 </div>
 
 <div class="actions section">

-- 
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.

Reply via email to