]> _ Git - fluidbook_tools.git/commitdiff
wip #5189 @0.25
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Tue, 19 Apr 2022 10:55:38 +0000 (12:55 +0200)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Tue, 19 Apr 2022 10:55:38 +0000 (12:55 +0200)
.idea/deployment.xml
.idea/misc.xml
src/Document.php

index 2b6ae2213823f5edda334413bcd3a5ee5f2c3802..f7220049354d7680631e63ddd10c88717cc60c3d 100644 (file)
@@ -1,6 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <project version="4">
-  <component name="PublishConfigData" autoUpload="Always" serverName="odl.paris.cubedesigners.com" remoteFilesAllowedToDisappearOnAutoupload="false" autoUploadExternalChanges="true" showAutoUploadSettingsWarning="false">
+  <component name="PublishConfigData" autoUpload="Always" serverName="toolbox.fluidbook.com" remoteFilesAllowedToDisappearOnAutoupload="false" confirmBeforeUploading="false" autoUploadExternalChanges="true" showAutoUploadSettingsWarning="false">
+    <option name="confirmBeforeUploading" value="false" />
     <serverData>
       <paths name="batman.cubedesigners.com">
         <serverdata>
       <paths name="toolbox.fluidbook.com">
         <serverdata>
           <mappings>
-            <mapping local="$PROJECT_DIR$" web="/" />
+            <mapping deploy="/vendor/fluidbook/tools" local="$PROJECT_DIR$" web="/" />
           </mappings>
+          <excludedPaths>
+            <excludedPath local="true" path="$PROJECT_DIR$/vendor" />
+          </excludedPaths>
         </serverdata>
       </paths>
       <paths name="workshop.fluidbook.com">
index ff9d5a0175db081a6a47d5c3aff62bb4885cbb31..c391c5f094b2ff48667f1b8e0a469e996e8e4422 100644 (file)
@@ -6,4 +6,9 @@
   <component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" project-jdk-name="JDK17" project-jdk-type="JavaSDK">
     <output url="file://$PROJECT_DIR$/out" />
   </component>
+  <component name="SwUserDefinedSpecifications">
+    <option name="specTypeByUrl">
+      <map />
+    </option>
+  </component>
 </project>
\ No newline at end of file
index 05fa00375734b0f4bcd95b29b05476a75bf94ff3..09c2073f01c1ae509d44d36ce409f42a0d74ae7c 100644 (file)
@@ -13,9 +13,12 @@ class Document extends \Cubist\PDF\Document
      * @param array $pages
      * @param bool $sync
      */
-    public function processPages($files, $pages, $sync = false)
+    public function processPages($files, $pages = [], $sync = false)
     {
         start_measure('Process pages (doc)');
+        if (!count($pages)) {
+            $pages = range(1, $this->getPages());
+        }
         if (!$sync) {
             $pages = array_reverse($pages, true);
         }
@@ -30,6 +33,11 @@ class Document extends \Cubist\PDF\Document
         return Files::mkdir(storage_path('fluidbook/convert/' . $this->getHash() . '/'));
     }
 
+    public function cleanConvertPath()
+    {
+        Files::rmdir($this->getConvertPath());
+    }
+
     /**
      * @param $page int
      * @param $dest string