作者 lyh

gx

... ... @@ -37,7 +37,7 @@ class CustomModuleContentController extends BaseController
$data = $this->getAllCategoryName();
foreach ($lists['list'] as $k=>$v){
$v['category_name'] = $this->categoryName($v['category_id'],$data);
$v['image_link'] = getImageUrl($v['image']);
$v['image_link'] = getImageUrl($v['image'],$this->user['project_location'],$this->user['storage_type']);
$v['operator_name'] = (new User())->getName($v['operator_id']);
$lists['list'][$k] = $v;
}
... ...
... ... @@ -25,7 +25,7 @@ class WebSettingImageController extends BaseController
public function lists(WebSettingImage $webSettingImage){
$list = $webSettingImage->list([],'id',['id','image','type']);
foreach ($list as $k=>$v){
$v['image'] = getImageUrl($v['image']);
$v['image'] = getImageUrl($v['image'],$this->user['project_location'],$this->user['storage_type']);
$list[$k] = $v;
}
$this->response('success',Code::SUCCESS,$list);
... ...
... ... @@ -39,7 +39,7 @@ class CustomModuleContentLogic extends BaseLogic
if($info === false){
$this->fail('当前数据不存在或已被删除');
}
$info['image'] = getImageUrl($info['image']);
$info['image'] = getImageUrl($info['image'],$this->user['project_location'],$this->user['storage_type']);
$info['extend'] = $this->getExtendInfo($info['module_id'],$info['id']);
return $this->success($info);
}
... ... @@ -86,14 +86,14 @@ class CustomModuleContentLogic extends BaseLogic
$arr = json_decode($info['values']);
foreach ($arr as $k1=>$v1){
$v1 = (array)$v1;
$v1['url'] = getImageUrl($v1['url']);
$v1['url'] = getImageUrl($v1['url'],$this->user['project_location'],$this->user['storage_type']);
$arr[$k1] = $v1;
}
$v['values'] = $arr;
}elseif($v['type'] == 4){
$arr1 = json_decode($info['values']);
foreach ($arr1 as $k1=>$v1){
$v1 = getFileUrl($v1);
$v1 = getFileUrl($v1,$this->user['project_location'],$this->user['storage_type']);
$arr1[$k1] = $v1;
}
$v['values'] = $arr1;
... ...
... ... @@ -32,7 +32,7 @@ class CategoryLogic extends BaseLogic
foreach ($data as &$v){
$v['url'] = $this->user['domain'] . $v['route'] ;
$v['product_num'] = Category::getProductNum($v['id']);
$v['image_link'] = getImageUrl($v['image']);
$v['image_link'] = getImageUrl($v['image'],$this->user['project_location'],$this->user['storage_type']);
}
if(!$map){
$data = Arr::listToTree($data);
... ...