Item::getRecommendThumb PHP Method

getRecommendThumb() public method

得到商品推荐缩略图
public getRecommendThumb ( ) : type
return type
    public function getRecommendThumb()
    {
        $img = $this->getMainPicPath();
        if (file_exists(dirname(F::basePath()) . $img)) {
            $img_thumb = F::baseUrl() . ImageHelper::thumb(80, 80, $img, array('method' => 'resize'));
            $img_thumb_now = CHtml::image($img_thumb, $this->title);
            return CHtml::link($img_thumb_now, array('/item/view', 'id' => $this->item_id), array('title' => $this->title));
        } else {
            return CHtml::link(CHtml::image($this->getHolderJs('80', '80')), $this->getUrl(), array('title' => $this->title));
        }
    }