|
...
|
...
|
@@ -71,4 +71,36 @@ class TemplateModule extends Base |
|
|
|
}
|
|
|
|
return $value;
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @remark :写入器images
|
|
|
|
* @name :setImageAttribute
|
|
|
|
* @author :lyh
|
|
|
|
* @method :post
|
|
|
|
* @time :2023/8/3 16:17
|
|
|
|
*/
|
|
|
|
public function setVideoAttribute($value){
|
|
|
|
$arr = explode(',',trim($value,','));
|
|
|
|
$arr_images = [];
|
|
|
|
foreach ($arr as $v){
|
|
|
|
$arr_images[] = basename($v);
|
|
|
|
}
|
|
|
|
$this->attributes['video'] = implode(',',$arr_images);
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @remark :获取器images
|
|
|
|
* @name :getImageAttribute
|
|
|
|
* @author :lyh
|
|
|
|
* @method :post
|
|
|
|
* @time :2023/8/3 16:17
|
|
|
|
*/
|
|
|
|
public function getVideoAttribute($value){
|
|
|
|
$arr = explode(',',$value);
|
|
|
|
$value = [];
|
|
|
|
foreach ($arr as $v){
|
|
|
|
$value[] = getImageUrl($v);
|
|
|
|
}
|
|
|
|
return $value;
|
|
|
|
}
|
|
|
|
} |
...
|
...
|
|