diff options
| -rw-r--r-- | FisheyeGallery.php | 17 | ||||
| -rw-r--r-- | FisheyeImage.php | 20 | ||||
| -rw-r--r-- | admin/schema_inc.php | 3 |
3 files changed, 4 insertions, 36 deletions
diff --git a/FisheyeGallery.php b/FisheyeGallery.php index a96a578..03dcc6e 100644 --- a/FisheyeGallery.php +++ b/FisheyeGallery.php @@ -1,6 +1,6 @@ <?php /** - * @version $Header: /cvsroot/bitweaver/_bit_fisheye/FisheyeGallery.php,v 1.58 2007/06/13 17:33:40 nickpalmer Exp $ + * @version $Header: /cvsroot/bitweaver/_bit_fisheye/FisheyeGallery.php,v 1.59 2007/06/15 01:36:50 spiderr Exp $ * @package fisheye */ @@ -212,12 +212,6 @@ class FisheyeGallery extends FisheyeBase { } } - if( $gBitSystem->isPackageActive( 'gatekeeper' ) ) { - $selectSql .= ' ,ls.`security_id`, ls.`security_description`, ls.`is_private`, ls.`is_hidden`, ls.`access_question`, ls.`access_answer` '; - $joinSql .= " LEFT OUTER JOIN `".BIT_DB_PREFIX."gatekeeper_security_map` cg ON (lc.`content_id`=cg.`content_id`) LEFT OUTER JOIN `".BIT_DB_PREFIX."gatekeeper_security` ls ON (ls.`security_id`=cg.`security_id` )"; -// $where = ' AND (cg.`security_id` IS NULL OR lc.`user_id`=?) '; -// $bindVars[] = $gBitUser->mUserId; - } $this->mItems = array(); $query = "SELECT fgim.*, lc.`content_type_guid`, lc.`user_id`, lct.*, ufm.`favorite_content_id` AS is_favorite $selectSql @@ -619,15 +613,6 @@ vd( $this->mErrors ); $bindVars[] = 'y'; } - if( $gBitSystem->isPackageActive( 'gatekeeper' ) ) { - $selectSql .= ' ,ls.`security_id`, ls.`security_description`, ls.`is_private`, ls.`is_hidden`, ls.`access_question`, ls.`access_answer` '; - $joinSql .= " LEFT OUTER JOIN `".BIT_DB_PREFIX."gatekeeper_security_map` cg ON (lc.`content_id`=cg.`content_id`) LEFT OUTER JOIN `".BIT_DB_PREFIX."gatekeeper_security` ls ON (ls.`security_id`=cg.`security_id` )"; - if( !$gBitUser->isAdmin() ) { - $whereSql .= ' AND (cg.`security_id` IS NULL OR lc.`user_id`=?) '; - $bindVars[] = $gBitUser->mUserId; - } - } - $mapJoin = ""; if( $gBitDbType != 'mysql' ) { // weed out empty galleries if we don't need them. DO NOT get clever and change the IN and EXISTS choices here. diff --git a/FisheyeImage.php b/FisheyeImage.php index c83b5ad..d703c90 100644 --- a/FisheyeImage.php +++ b/FisheyeImage.php @@ -1,6 +1,6 @@ <?php /** - * @version $Header: /cvsroot/bitweaver/_bit_fisheye/FisheyeImage.php,v 1.48 2007/06/14 12:41:52 lsces Exp $ + * @version $Header: /cvsroot/bitweaver/_bit_fisheye/FisheyeImage.php,v 1.49 2007/06/15 01:36:50 spiderr Exp $ * @package fisheye */ @@ -70,11 +70,6 @@ class FisheyeImage extends FisheyeBase { $bindVars[] = $this->mContentId; } -// if( $gBitSystem->isPackageActive( 'gatekeeper' ) ) { -// $gateSql = ' ,ls.`security_id`, ls.`security_description`, ls.`is_private`, ls.`is_hidden`, ls.`access_question`, ls.`access_answer` '; -// $whereSql = " LEFT OUTER JOIN `".BIT_DB_PREFIX."gatekeeper_security_map` cg ON ( lc.`content_id`=cg.`content_id` ) LEFT OUTER JOIN `".BIT_DB_PREFIX."gatekeeper_security` ls ON ( cg.`security_id`=ls.`security_id` ) ".$whereSql; -// } - $this->getServicesSql( 'content_load_sql_function', $selectSql, $joinSql, $whereSql, $bindVars ); $sql = "SELECT fi.*, lc.* $gateSql $selectSql @@ -640,19 +635,6 @@ class FisheyeImage extends FisheyeBase { $bindVars[] = $pListHash['max_age']; } -// $this->debug(); - if( $gBitSystem->isPackageActive( 'gatekeeper' ) ) { - if( $this->mDb->isAdvancedPostgresEnabled() ) { - $mid .= " AND (SELECT ls.`security_id` FROM connectby('fisheye_gallery_image_map', 'gallery_content_id', 'item_content_id', fi.`content_id`, 0, '/') AS t(`cb_gallery_content_id` int, `cb_item_content_id` int, level int, branch text), `".BIT_DB_PREFIX."gatekeeper_security_map` cgm, `".BIT_DB_PREFIX."gatekeeper_security` ls - WHERE ls.`security_id`=cgm.`security_id` AND cgm.`content_id`=`cb_gallery_content_id` LIMIT 1) IS NULL"; - } else { - $select .= ' ,ls.`security_id`, ls.`security_description`, ls.`is_private`, ls.`is_hidden`, ls.`access_question`, ls.`access_answer` '; - $join .= " LEFT OUTER JOIN `".BIT_DB_PREFIX."gatekeeper_security_map` cg ON (lc.`content_id`=cg.`content_id`) LEFT OUTER JOIN `".BIT_DB_PREFIX."gatekeeper_security` ls ON (ls.`security_id`=cg.`security_id` ) LEFT OUTER JOIN `".BIT_DB_PREFIX."fisheye_gallery_image_map` fgim ON (fgim.`item_content_id`=lc.`content_id`) LEFT OUTER JOIN `".BIT_DB_PREFIX."gatekeeper_security_map` tcs2 ON (fgim.`gallery_content_id`=tcs2.`content_id`) LEFT OUTER JOIN `".BIT_DB_PREFIX."gatekeeper_security` ts2 ON (ts2.`security_id`=tcs2.`security_id` )"; - $mid .= ' AND (tcs2.`security_id` IS NULL OR lc.`user_id`=?) '; - $bindVars[] = $gBitUser->mUserId; - } - } - $orderby = ''; if ( !empty( $pListHash['sort_mode'] ) ) { //converted in prepGetList() diff --git a/admin/schema_inc.php b/admin/schema_inc.php index d83a743..8fd5907 100644 --- a/admin/schema_inc.php +++ b/admin/schema_inc.php @@ -25,7 +25,7 @@ $tables = array( width I4, height I4 ", - +/* 'fisheye_exif_data' => " content_id I4 NOTNULL, exif_name C(250) NOTNULL, @@ -33,6 +33,7 @@ $tables = array( exif_value_long X CONSTRAINT ', CONSTRAINT `fisheye_exif_content_ref` FOREIGN KEY (`content_id`) REFERENCES `".BIT_DB_PREFIX."liberty_content` (`content_id`)' " +*/ ); global $gBitInstaller; |
