Skip to content
Snippets Groups Projects
Commit 5b73c08a authored by Anthony Borghi's avatar Anthony Borghi
Browse files

Ajout de la copie des photos pour le downloader

parent 66282b27
Branches
Tags
No related merge requests found
...@@ -164,6 +164,12 @@ class Networkmanagers extends Dtnet { ...@@ -164,6 +164,12 @@ class Networkmanagers extends Dtnet {
if($aPath[0] !== ""){ if($aPath[0] !== ""){
$this->aValues["icon"] = $aPath[0]; $this->aValues["icon"] = $aPath[0];
if(!empty($this->aProperties['pushForProxyDownloads']) && !empty($this->aProperties['mainUrlProxyDownloads'])){
if(!is_dir($this->aProperties['pushForProxyDownloads'] . "/dtnet/networkmanager/" . $this->aValues['my_vitis_id'])){
mkdir($this->aProperties['pushForProxyDownloads'] . "/dtnet/networkmanager/" . $this->aValues['my_vitis_id']);
}
copy($this->aProperties["ws_data_dir"] . "/dtnet/networkmanager/" . $this->aValues['my_vitis_id']."/".$this->aValues['icon_name'], $this->aProperties['pushForProxyDownloads'] . "/dtnet/networkmanager/" . $this->aValues['my_vitis_id']."/".$this->aValues['icon_name']);
}
} }
if($aPath[1] !== ""){ if($aPath[1] !== ""){
......
...@@ -191,6 +191,12 @@ class Unr_networkmanagers extends Dtnet { ...@@ -191,6 +191,12 @@ class Unr_networkmanagers extends Dtnet {
$sPath = $this->pictureResampler($sPath, $this->aValues["icon_width"], $this->aValues["icon_height"]); $sPath = $this->pictureResampler($sPath, $this->aValues["icon_width"], $this->aValues["icon_height"]);
$aPath = explode("/", $sPath); $aPath = explode("/", $sPath);
$this->aValues["icon"] = $sDirectoryPath . "/" . $aPath[count($aPath) - 1]; $this->aValues["icon"] = $sDirectoryPath . "/" . $aPath[count($aPath) - 1];
if(!empty($this->aProperties['pushForProxyDownloads']) && !empty($this->aProperties['mainUrlProxyDownloads'])){
if(!is_dir($this->aProperties['pushForProxyDownloads'] . "/dtnet/networkmanager/" . $this->aValues['networkmanager_id'])){
mkdir($this->aProperties['pushForProxyDownloads'] . "/dtnet/networkmanager/" . $this->aValues['networkmanager_id']);
}
copy($this->aProperties["ws_data_dir"] . "/dtnet/networkmanager/" . $this->aValues['networkmanager_id']."/".$aPath[count($aPath) - 1], $this->aProperties['pushForProxyDownloads'] . "/dtnet/networkmanager/" . $this->aValues['networkmanager_id']."/".$aPath[count($aPath) - 1]);
}
} }
if(!empty($this->aProperties["colorFill"])){ if(!empty($this->aProperties["colorFill"])){
...@@ -362,6 +368,12 @@ class Unr_networkmanagers extends Dtnet { ...@@ -362,6 +368,12 @@ class Unr_networkmanagers extends Dtnet {
if($aPath[0] !== ""){ if($aPath[0] !== ""){
$this->aValues["icon"] = $aPath[0]; $this->aValues["icon"] = $aPath[0];
if(!empty($this->aProperties['pushForProxyDownloads']) && !empty($this->aProperties['mainUrlProxyDownloads'])){
if(!is_dir($this->aProperties['pushForProxyDownloads'] . "/dtnet/networkmanager/" . $this->aValues['my_vitis_id'])){
mkdir($this->aProperties['pushForProxyDownloads'] . "/dtnet/networkmanager/" . $this->aValues['my_vitis_id']);
}
copy($this->aProperties["ws_data_dir"] . "/dtnet/networkmanager/" . $this->aValues['my_vitis_id']."/".$this->aValues['icon_name'], $this->aProperties['pushForProxyDownloads'] . "/dtnet/networkmanager/" . $this->aValues['my_vitis_id']."/".$this->aValues['icon_name']);
}
} }
if($aPath[1] !== ""){ if($aPath[1] !== ""){
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment