作者 lyh

gx

@@ -41,7 +41,7 @@ class CategoryController extends BaseController @@ -41,7 +41,7 @@ class CategoryController extends BaseController
41 foreach ($list as $k =>$v){ 41 foreach ($list as $k =>$v){
42 $v['url'] = $this->user['domain'] . $v['route'].'/'; 42 $v['url'] = $this->user['domain'] . $v['route'].'/';
43 $v['product_num'] = Category::getProductNum($v['id']); 43 $v['product_num'] = Category::getProductNum($v['id']);
44 - $v['image_link'] = getImageUrl($v['image'],$this->user['storage_type']); 44 + $v['image_link'] = getImageUrl($v['image'],$this->user['storage_type'],$this->user['project_location']);
45 $v['is_renovation'] = $this->getIsRenovation(BTemplate::SOURCE_PRODUCT,BTemplate::IS_LIST,$template_id,$v['id']); 45 $v['is_renovation'] = $this->getIsRenovation(BTemplate::SOURCE_PRODUCT,BTemplate::IS_LIST,$template_id,$v['id']);
46 $list[$k] = $v; 46 $list[$k] = $v;
47 } 47 }
@@ -78,25 +78,25 @@ class ProductController extends BaseController @@ -78,25 +78,25 @@ class ProductController extends BaseController
78 public function getHandleFileImage($v){ 78 public function getHandleFileImage($v){
79 //ToDo::处理图片及文件 79 //ToDo::处理图片及文件
80 if(!empty($v['thumb']) && !empty($v['thumb']['url'])){ 80 if(!empty($v['thumb']) && !empty($v['thumb']['url'])){
81 - $v['thumb']['url'] = getImageUrl($v['thumb']['url'],$this->user['storage_type'] ?? 0); 81 + $v['thumb']['url'] = getImageUrl($v['thumb']['url'],$this->user['storage_type'] ?? 0,$this->user['project_location']);
82 } 82 }
83 if(!empty($v['gallery'])){ 83 if(!empty($v['gallery'])){
84 foreach ($v['gallery'] as $gallery_k => $gallery_v){ 84 foreach ($v['gallery'] as $gallery_k => $gallery_v){
85 - $gallery_v['url'] = getImageUrl($gallery_v['url'],$this->user['storage_type'] ?? 0); 85 + $gallery_v['url'] = getImageUrl($gallery_v['url'],$this->user['storage_type'] ?? 0,$this->user['project_location']);
86 $v['gallery'][$gallery_k] = $gallery_v; 86 $v['gallery'][$gallery_k] = $gallery_v;
87 } 87 }
88 } 88 }
89 if(!empty($v['icon'])){ 89 if(!empty($v['icon'])){
90 foreach ($v['icon'] as $icon_k => $icon_v){ 90 foreach ($v['icon'] as $icon_k => $icon_v){
91 - $icon_v = getImageUrl($icon_v,$this->user['storage_type'] ?? 0); 91 + $icon_v = getImageUrl($icon_v,$this->user['storage_type'] ?? 0,$this->user['project_location']);
92 $v['icon'][$icon_k] = $icon_v; 92 $v['icon'][$icon_k] = $icon_v;
93 } 93 }
94 } 94 }
95 if(!empty($v['video']) && !empty($v['video']['url'])){ 95 if(!empty($v['video']) && !empty($v['video']['url'])){
96 - $v['video']['url'] = getImageUrl($v['video']['url'],$this->user['storage_type'] ?? 0); 96 + $v['video']['url'] = getImageUrl($v['video']['url'],$this->user['storage_type'] ?? 0,$this->user['project_location']);
97 } 97 }
98 if(!empty($v['files']) && !empty($v['files']['url'])){ 98 if(!empty($v['files']) && !empty($v['files']['url'])){
99 - $v['files']['url'] = getImageUrl($v['files']['url'],$this->user['storage_type'] ?? 0); 99 + $v['files']['url'] = getImageUrl($v['files']['url'],$this->user['storage_type'] ?? 0,$this->user['project_location']);
100 } 100 }
101 return $this->success($v); 101 return $this->success($v);
102 } 102 }