]> _ Git - cubeextranet.git/commitdiff
wait #3637 @1.5
authorvincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Tue, 12 May 2020 16:28:12 +0000 (16:28 +0000)
committervincent@cubedesigners.com <vincent@cubedesigners.com@f5622870-0f3c-0410-866d-9cb505b7a8ef>
Tue, 12 May 2020 16:28:12 +0000 (16:28 +0000)
inc/ws/Metier/class.ws.book.parametres.php
inc/ws/Util/html5/master/class.ws.html5.compiler.php

index dddeca664d1db5d91726ae4556c756eb02c423d9..8223d3c0910f7c5df7cdaa1927b5a97024feff96 100644 (file)
@@ -651,9 +651,10 @@ class wsBookParametres extends wsParametres
         $this->fields['scorm_quizdata'] = array('type' => 'freefile', 'editable' => true, 'default' => '', 'label' => __('Données de quiz'));
         $this->fields['scorm_complete_on_exit'] = ['type' => 'boolean', 'default' => false, 'label' => 'Marquer le cours comme "Complete" à la fermeture de la fenêtre', 'editable' => true];
         $this->fields['scorm_complete_on_last_page'] = ['type' => 'boolean', 'default' => false, 'label' => 'Marquer le cours comme "Complete" lorsque le visiteur atteint la dernière page', 'editable' => true];
+        $this->fields['scorm_force_attempts'] = ['type' => 'boolean', 'default' => false, 'label' => __('Forcer la création d\'un "attempt" à chaque ouverture'), 'editable' => true];
 
         $this->forms['scorm'] = array('label' => __('SCORM'),
-            'fieldsnames' => array('scorm_enable', 'scorm_version', 'scorm_id', 'scorm_org', 'scorm_title', 'scorm_variables', '|', 'scorm_complete_on_exit', 'scorm_complete_on_last_page', '|', 'scorm_quizdata', 'scorm_score', 'scorm_score_min', 'scorm_quiz_as_questionnaire'));
+            'fieldsnames' => array('scorm_enable', 'scorm_version', 'scorm_id', 'scorm_org', 'scorm_title', 'scorm_variables', '|', 'scorm_complete_on_exit', 'scorm_complete_on_last_page', '|', 'scorm_quizdata', 'scorm_score', 'scorm_score_min', 'scorm_quiz_as_questionnaire', '|', 'scorm_force_attempts'));
 
 
         $this->fields['ongletsXML'] = array('type' => 'textarea', 'default' => '', 'editable' => true, 'label' => __('XML de configuration des onglets'), 'grade' => 5);
index 958a1e108f9c17d9038520472b914571e4ffd2ba..438bb93f186f7ac38092cae36a131228835b1893 100644 (file)
@@ -936,9 +936,10 @@ class wsHTML5Compiler
 
             $splash = '';
             $splashstyles = '';
-            if ($this->book->parametres->splashImage) {
-                $this->vdir->copy($this->wdir . '/' . $this->book->parametres->splashImage, 'data/images/' . $this->book->parametres->splashImage);
-                $splashstyles = 'background-image:url(' . 'data/images/' . $this->book->parametres->splashImage . ');background-size:contain;background-position:50% 50%;';
+            $img = $this->book->parametres->splashImage;
+            if ($img) {
+                $this->vdir->copy($this->wdir . '/' . $img, 'data/images/' . $img);
+                $splashstyles = 'background-image:url(' . 'data/images/' . $img . ');background-size:contain;background-position:50% 50%;';
                 if ($this->book->parametres->splashURL !== '') {
                     $splash = '<a href="' . $this->book->parametres->splashURL . '" style="display:block;position:absolute;top:0;left;0;width:100%;height:100%"></a>';
                 }