|
|
@@ -30,6 +30,19 @@ class BxReviewsMenuViewActions extends BxBaseModTextMenuViewActions
|
|
|
{
|
|
|
return $this->_getMenuItemByNameActions($aItem);
|
|
|
}
|
|
|
+
|
|
|
+ protected function _isContentPublic($iContentId) {
|
|
|
+ $CNF = &$this->_oModule->_oConfig->CNF;
|
|
|
+
|
|
|
+ if(empty($CNF['FIELD_ALLOW_VIEW_TO']))
|
|
|
+ return true;
|
|
|
+
|
|
|
+ $aContentInfo = $iContentId == $this->_iContentId ? $this->_aContentInfo : $this->_oModule->_oDb->getContentInfoById($iContentId);
|
|
|
+ if(!isset($aContentInfo[$CNF['FIELD_ALLOW_VIEW_TO']]))
|
|
|
+ return true;
|
|
|
+
|
|
|
+ return $aContentInfo[$CNF['FIELD_ALLOW_VIEW_TO']] < 0 || in_array($aContentInfo[$CNF['FIELD_ALLOW_VIEW_TO']], array(BX_DOL_PG_ALL, BX_DOL_PG_MEMBERS));
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
/** @} */
|