]> _ Git - cubeextranet.git/commitdiff
done #1652 @0:35
authorvincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Thu, 7 Sep 2017 15:02:16 +0000 (15:02 +0000)
committervincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Thu, 7 Sep 2017 15:02:16 +0000 (15:02 +0000)
inc/ws/Controlleur/class.ws.maintenance.php

index 1294645a0961118ea43094c0f8c8f7a487b8e355..575da1bd65c7b002c3642ee07428ee6935d2b11f 100644 (file)
@@ -693,6 +693,32 @@ class wsMaintenance {
                }
        }
 
+       public static function exportSommaire($args) {
+               global $core;
+               $book_id = $args[0];
+               $dao = new wsDAOBook($core->con);
+               $book = $dao->selectById($book_id);
+
+               header('Content-Type: text/plain');
+               foreach ($book->chapters as $c) {
+                                               echo str_repeat("\t", $c->level);
+                       echo $c->label;
+                       echo ' ' . $c->page;
+                       echo "\n";
+
+               }
+               exit;
+       }
+
+       public static function copySommaire($args) {
+               global $core;
+               $from = $args[0];
+               $to=$args[1];
+               $dao = new wsDAOBook($core->con);
+               $fbook = $dao->selectById($from);
+               $dao->setChapters($to,json_encode($fbook->chapters));
+       }
+
        public static function copyComposition($args) {
                global $core;
 
@@ -1028,7 +1054,6 @@ class wsMaintenance {
                `gzip /home/extranet/www/fluidbook/docs/*/*.txt`;
        }
 
-
        public static function restoreChapters($args) {
                global $core;
 
@@ -1293,7 +1318,7 @@ class wsMaintenance {
        public function testSVG() {
                $test = '/home/extranet/www/fluidbook/docs/115864/html/test.svg';
                copy('/home/extranet/www/fluidbook/docs/115864/html/tp1.svg', $test);
-               wsDocument::cleanSVG($test,true);
+               wsDocument::cleanSVG($test, true);
        }
 
 }