|
|
@@ -133,12 +133,13 @@ class business
|
|
|
public static function formatUserAvatar($info)
|
|
|
{
|
|
|
$imgUrl = isset($info['avatar']) ? $info['avatar'] : '';
|
|
|
+ $prefixImgUrl = Yii::$app->params['imgHost'];
|
|
|
if (empty($imgUrl)) {
|
|
|
- $info['avatarUrl'] = '';
|
|
|
- $info['smallAvatarUrl'] = '';
|
|
|
+ $defaultImg = $prefixImgUrl . '/retail/default-img.png';
|
|
|
+ $info['avatarUrl'] = $defaultImg;
|
|
|
+ $info['smallAvatarUrl'] = $defaultImg;
|
|
|
return $info;
|
|
|
}
|
|
|
- $prefixImgUrl = Yii::$app->params['imgHost'];
|
|
|
$smallImg = self::getSmallImg($imgUrl);
|
|
|
$small = $prefixImgUrl . $smallImg;
|
|
|
$info['smallAvatarUrl'] = $small;
|