|
...
|
...
|
@@ -369,10 +369,10 @@ class ImageController extends Controller |
|
|
|
$settingInfo = $imageSettingModel->read(['project_id'=>$project_id]);
|
|
|
|
if($settingInfo !== false){
|
|
|
|
if($settingInfo['status'] == 1 && !empty($settingInfo['image_data'])){
|
|
|
|
return json_decode($settingInfo['image_data'],true);
|
|
|
|
$settingInfo['image_data'] = json_decode($settingInfo['image_data'],true);
|
|
|
|
}
|
|
|
|
if($settingInfo['status'] == 2 && !empty($settingInfo['str_data'])){
|
|
|
|
return json_decode($settingInfo['str_data'],true);
|
|
|
|
$settingInfo['str_data'] = json_decode($settingInfo['str_data'],true);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
return null;
|
|
...
|
...
|
@@ -652,7 +652,7 @@ class ImageController extends Controller |
|
|
|
$domain = 'http://globalso-v6-1309677403.cos.ap-hongkong.myqcloud.com';//cos域名
|
|
|
|
if($is_image){
|
|
|
|
$param = [
|
|
|
|
'image/'.urlSafeBase64Encode($domain.$data['image'] ?? ''),//图片
|
|
|
|
'image/'.$domain.($data['image'] ?? ''),//图片
|
|
|
|
'gravity/'.($data['gravity'] ?? 'SouthEast'),
|
|
|
|
'dx/'.($data['dx'] ?? 0),
|
|
|
|
'dy/'. ($data['dy'] ?? 0),
|
|
...
|
...
|
@@ -667,13 +667,13 @@ class ImageController extends Controller |
|
|
|
}
|
|
|
|
}else{
|
|
|
|
$param = [
|
|
|
|
'text/'.urlSafeBase64Encode($data['text'] ?? ''),//文字水印名称
|
|
|
|
'text/'.($data['text'] ?? ''),//文字水印名称
|
|
|
|
'gravity/'.($data['gravity'] ?? 'SouthEast'),
|
|
|
|
'dx/'.($data['dx'] ?? 10),
|
|
|
|
'dy/'. ($data['dy'] ?? 10),
|
|
|
|
'font/'.urlSafeBase64Encode($data['font'] ?? 'tahoma.ttf'),//默认宋体
|
|
|
|
'font/'.($data['font'] ?? 'tahoma.ttf'),//默认宋体
|
|
|
|
'fontsize/'.($data['fontsize'] ?? 24),//水印文字字体大小,单位为磅,缺省值13
|
|
|
|
'fill/'.urlSafeBase64Encode($data['fill'] ?? '#3D3D3D'),//颜色
|
|
|
|
'fill/'.($data['fill'] ?? '#3D3D3D'),//颜色
|
|
|
|
'dissolve/'.($data['dissolve'] ?? 50),//透明度
|
|
|
|
'degree/'.($data['degree'] ?? 0),//文字水印的旋转角度设置,取值范围为0 - 360,默认0
|
|
|
|
'batch/'.($data['batch'] ?? 0),//平铺水印功能
|
...
|
...
|
|