Author: david
Date: Wed Oct 12 16:48:19 2011
New Revision: 10054
Log:
Allow unauthenticated users to print file list
Modified:
trunk/apps/qubit/modules/informationobject/actions/reportsAction.class.php
Modified:
trunk/apps/qubit/modules/informationobject/actions/reportsAction.class.php
==============================================================================
--- trunk/apps/qubit/modules/informationobject/actions/reportsAction.class.php
Wed Oct 12 16:45:19 2011 (r10053)
+++ trunk/apps/qubit/modules/informationobject/actions/reportsAction.class.php
Wed Oct 12 16:48:19 2011 (r10054)
@@ -33,9 +33,13 @@
$choices = array(
$this->context->routing->generate(null, array($this->resource,
'module' => 'informationobject', 'action' => 'fileList')) =>
$this->context->i18n->__('File list'),
//$this->context->routing->generate(null, array($this->resource,
'module' => 'informationobject', 'action' => 'itemList')) =>
$this->context->i18n->__('Item list'),
- $this->context->routing->generate(null, array($this->resource,
'module' => 'informationobject', 'action' => 'storageLocations')) =>
$this->context->i18n->__('Physical storage locations'),
);
+ if ($this->getUser()->isAuthenticated())
+ {
+ $choices[$this->context->routing->generate(null,
array($this->resource, 'module' => 'informationobject', 'action' =>
'storageLocations'))] = $this->context->i18n->__('Physical storage locations');
+ }
+
$this->form->setDefault($name, $this->context->routing->generate(null,
array($this->resource, 'module' => 'informationobject', 'action' =>
'fileList')));
$this->form->setValidator($name, new sfValidatorChoice(array('choices'
=> array_keys($choices))));
$this->form->setWidget($name, new sfWidgetFormChoice(array(
@@ -55,11 +59,6 @@
$this->forward404();
}
- if (!$this->getUser()->isAuthenticated())
- {
- $this->redirect($this->context->routing->generate(null,
array($this->resource, 'module' => 'informationobject', 'media' => 'print')));
- }
-
$this->form = new sfForm;
foreach ($this::$NAMES as $name)
--
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.