99 $this->_iAllArtCnt = 0;
103 $this->_iAllArtCnt = $oActiveRecommList->getArtCount();
106 if (
$myConfig->getConfigParam(
'bl_rssRecommListArts')) {
108 $oRss =
oxNew(
'oxrssfeed');
110 $oRss->getRecommListArticlesTitle($oActiveRecommList),
111 $oRss->getRecommListArticlesUrl($this->_oActiveRecommList),
118 $oRecommList =
oxNew(
'oxrecommlist');
119 $this->_iAllArtCnt = $oRecommList->getSearchRecommListCount($this->
getRecommSearch());
127 if ($oList && $oList->count()) {
128 $iNrofCatArticles = (int) $this->
getConfig()->getConfigParam(
'iNrofCatArticles');
129 $iNrofCatArticles = $iNrofCatArticles ? $iNrofCatArticles : 10;
130 $this->_iCntPages = round($this->_iAllArtCnt / $iNrofCatArticles + 0.49);
156 $sAddParams .= ($sAddParams ?
'&' :
'') .
"listtype={$this->_sListType}";
159 $sAddParams .=
"&recommid=" . $oRecommList->getId();
174 $sAddParams .=
"&searchrecomm=" . rawurlencode($sParam);
197 if ($dRating !== null) {
198 $dRating = (int) $dRating;
201 if ($dRating !== null && $dRating >= 1 && $dRating <= 5) {
202 $oRating =
oxNew(
'oxrating');
203 if ($oRating->allowRating($oUser->getId(),
'oxrecommlist', $oRecommList->getId())) {
204 $oRating->oxratings__oxuserid =
new oxField($oUser->getId());
205 $oRating->oxratings__oxtype =
new oxField(
'oxrecommlist');
206 $oRating->oxratings__oxobjectid =
new oxField($oRecommList->getId());
207 $oRating->oxratings__oxrating =
new oxField($dRating);
209 $oRecommList->addToRatingAverage($dRating);
213 if (($sReviewText = trim((
string )
oxRegistry::getConfig()->getRequestParameter(
'rvw_txt',
true)))) {
214 $oReview =
oxNew(
'oxreview');
215 $oReview->oxreviews__oxobjectid =
new oxField($oRecommList->getId());
216 $oReview->oxreviews__oxtype =
new oxField(
'oxrecommlist');
219 $oReview->oxreviews__oxuserid =
new oxField($oUser->getId());
220 $oReview->oxreviews__oxrating =
new oxField(($dRating !== null) ? $dRating : null);
246 if ($this->_aArticleList === null) {
247 $this->_aArticleList =
false;
251 $iActPage = ($iActPage < 0) ? 0 : $iActPage;
254 $iNrofCatArticles = $this->
getConfig()->getConfigParam(
'iNrofCatArticles');
255 $iNrofCatArticles = $iNrofCatArticles ? $iNrofCatArticles : 10;
257 $this->_aArticleList = $oActiveRecommList->getArticles(
258 $iNrofCatArticles * $iActPage,
262 if ($this->_aArticleList && $this->_aArticleList->count()) {
263 foreach ($this->_aArticleList as $oItem) {
264 $oItem->text = $oActiveRecommList->getArtDescription($oItem->getId());
280 if ($this->_oOtherRecommList === null) {
281 $this->_oOtherRecommList =
false;
283 $oRecommLists = $oActiveRecommList->getRecommListsByIds($oList->arrayKeys());
285 unset($oRecommLists[$oActiveRecommList->getId()]);
286 $this->_oOtherRecommList = $oRecommLists;
300 if ($this->_aReviews === null) {
301 $this->_aReviews =
false;
303 $this->_aReviews = $oActiveRecommList->getReviews();
317 return $this->
getConfig()->getConfigParam(
'bl_perfLoadReviews');
327 if ($this->_blRate === null) {
328 $this->_blRate =
false;
330 $oRating =
oxNew(
'oxrating');
332 $this->_blRate = $oRating->allowRating($sUserVariable,
'oxrecommlist', $oActiveRecommList->getId());
346 if ($this->_dRatingValue === null) {
347 $this->_dRatingValue = (double) 0;
349 $this->_dRatingValue = round($oActiveRecommList->oxrecommlists__oxrating->value, 1);
363 if ($this->_iRatingCnt === null) {
364 $this->_iRatingCnt =
false;
366 $this->_iRatingCnt = $oActiveRecommList->oxrecommlists__oxratingcnt->value;
380 if ($this->_oSearchRecommLists === null) {
381 $this->_oSearchRecommLists = array();
384 $oRecommList =
oxNew(
'oxrecommlist');
386 if ($oList && $oList->count()) {
387 $this->_oSearchRecommLists = $oList;
402 if ($this->_sSearch === null) {
403 $this->_sSearch =
false;
405 $this->_sSearch = $sSearch;
421 $aPath[0] =
oxNew(
"oxcategory");
422 $aPath[0]->setLink(
false);
423 $aPath[0]->oxcategories__oxtitle =
new oxField($oLang->translateString(
'RECOMMLIST'));
426 $shopHomeURL = $this->
getConfig()->getShopHomeURL();
427 $sUrl = $shopHomeURL .
"cl=recommlist&searchrecomm=" . rawurlencode($sSearchParam);
428 $sTitle = $oLang->translateString(
'RECOMMLIST_SEARCH') .
' "' . $sSearchParam .
'"';
430 $aPath[1] =
oxNew(
"oxcategory");
431 $aPath[1]->setLink($sUrl);
432 $aPath[1]->oxcategories__oxtitle =
new oxField($sTitle);
447 return $oActiveRecommList->oxrecommlists__oxtitle->value;
461 $sUrl = $oRecomm->getLink();
483 $sUrl = $oRecomm->getBaseSeoLink($iLang, $iPage);
502 $sAddParams .=
"&recommid=" . $oRecomm->getId();
506 $sAddParams .=
"&searchrecomm=" . rawurlencode($sSearch);
522 $sLink = $oRecomm->getLink($iLang);
528 $sLink .= ((strpos($sLink,
'?') ===
false) ?
'?' :
'&') .
"searchrecomm={$sSearch}";
545 $aPath[
'title'] =
oxRegistry::getLang()->translateString(
'LISTMANIA', $iBaseLanguage,
false);
546 $aPath[
'link'] = $this->
getLink();
561 $sTranslatedString = $oLang->translateString(
'LIST_BY', $oLang->getBaseLanguage(),
false);
562 $sTitleField =
'oxrecommlists__oxtitle';
563 $sAuthorField =
'oxrecommlists__oxauthor';
564 $sTitle = $aActiveList->$sTitleField->value .
' (' . $sTranslatedString .
' ' .
565 $aActiveList->$sAuthorField->value .
')';
567 $sTranslatedString = $oLang->translateString(
'HITS_FOR', $oLang->getBaseLanguage(),
false);