From: vincent@cubedesigners.com Date: Wed, 20 Jun 2018 13:41:57 +0000 (+0000) Subject: fix #2107 @0.5 X-Git-Url: http://git.cubedesigners.com/?a=commitdiff_plain;h=be9f44388f2a36f2c53b2ff93725cd95d42f3d5c;p=cubeextranet.git fix #2107 @0.5 --- diff --git a/inc/ws/Controlleur/class.ws.flash.php b/inc/ws/Controlleur/class.ws.flash.php index 3ee1599c4..4796c9a3b 100644 --- a/inc/ws/Controlleur/class.ws.flash.php +++ b/inc/ws/Controlleur/class.ws.flash.php @@ -383,7 +383,11 @@ class wsFlash extends cubeFlashGateway $this->jsonDatas['pages'][] = array($info['document_id'], $info['document_page']); } $docs = array_unique($docs); - $this->jsonDatas['documents'] = array_unique($docs); + $this->jsonDatas['documents'] = $docs; + $this->jsonDatas['documents_path'] = []; + foreach ($docs as $document_id) { + $this->jsonDatas['documents_path'][$document_id] = str_replace(WS_FILES, '', wsDocument::getDir($document_id, true)); + } if (is_null($book->numerotation) || !$book->numerotation || $book->numerotation == 'null') { $this->jsonDatas['numerotation'] = $defaultNum; diff --git a/inc/ws/Metier/class.ws.document.php b/inc/ws/Metier/class.ws.document.php index 317020356..1e6798826 100644 --- a/inc/ws/Metier/class.ws.document.php +++ b/inc/ws/Metier/class.ws.document.php @@ -1046,7 +1046,7 @@ class wsDocument extends cubeMetier return self::$_docsDir[$id]; } - $new = WS_DOCS . '/' . $id . '/'; + $new = WS_FILES . '/docs/' . $id . '/'; $old = WS_FILES . '/docs1/' . $id . '/'; $veryold = WS_FILES . '/docs2/' . $id . '/';