summaryrefslogtreecommitdiffstats
path: root/library
diff options
context:
space:
mode:
authormichael pereira2011-10-10 02:57:04 +0200
committermichael pereira2011-10-10 02:57:04 +0200
commitb5675c099a8b71584bd319ad5ee7d2d046aeb6e7 (patch)
tree732e2222706bc610c705ecb38bc02a1ce111aecf /library
parentfilter typo (diff)
downloadpbs2-b5675c099a8b71584bd319ad5ee7d2d046aeb6e7.tar.gz
pbs2-b5675c099a8b71584bd319ad5ee7d2d046aeb6e7.tar.xz
pbs2-b5675c099a8b71584bd319ad5ee7d2d046aeb6e7.zip
filter group fix
Diffstat (limited to 'library')
-rw-r--r--library/Pbs/Filter.php19
1 files changed, 11 insertions, 8 deletions
diff --git a/library/Pbs/Filter.php b/library/Pbs/Filter.php
index 145e7f5..219e50e 100644
--- a/library/Pbs/Filter.php
+++ b/library/Pbs/Filter.php
@@ -11,8 +11,7 @@ class Pbs_Filter{
$db = $this->db;
$debuglevel = 3;
- $userIDsNamespace = Zend_Session::namespaceGet('userIDs');
- print_a($userIDsNamespace['membershipID']);
+ $userIDsNamespace = Zend_Session::namespaceGet('userIDs');
$membershipMapper = new Application_Model_MembershipMapper();
$this->membership = new Application_Model_Membership();
@@ -22,6 +21,7 @@ class Pbs_Filter{
else{
$this->membership->setID(null);
}
+
// For Testing Filters
$testFilter = (isset($_POST['submit']))?true:false;
@@ -53,18 +53,21 @@ class Pbs_Filter{
try{
$set = array();
-
$session = new Application_Model_Session();
$sessionmapper = new Application_Model_SessionMapper();
$sessionarray = $sessionmapper->findBy(array('alphasessionID' => $_SESSION['alphasessionID']),true);
$session->setOptions($sessionarray[0]);
$session->setID($sessionarray['sessionID']);
-
- $bootisoMapper = new Application_Model_BootIsoMapper();
- $bootiso = new Application_Model_BootIso();
- $bootisoMapper->find($session->getBootisoID(),$bootiso);
- $groupID = $bootiso->getGroupID();
+
+ if(!isset($userIDsNamespace['membershipID'])){
+ $bootisoMapper = new Application_Model_BootIsoMapper();
+ $bootiso = new Application_Model_BootIso();
+ $bootisoMapper->find($session->getBootisoID(),$bootiso);
+ $groupID = $bootiso->getGroupID();
+ }else{
+ $groupID = $userIDsNamespace['groupID'];
+ }
#########################################################
// IP Adress