Jelajahi Sumber

Merge 1.10.x

Julio 8 tahun lalu
induk
melakukan
e3403516b2

+ 0 - 1
app/Migrations/Schema/V110/Version110.php

@@ -85,7 +85,6 @@ class Version110 extends AbstractMigrationChamilo
                 array('default' => 0, 'unsigned' => true)
             );
         }
-
         $sessionTable = $schema->getTable('session');
         if (!$sessionTable->hasColumn('duration')) {
             $this->addSql("ALTER TABLE session ADD COLUMN duration int");

+ 3 - 2
documentation/optimization.html

@@ -422,9 +422,10 @@ alter table c_quiz_rel_question ADD INDEX idx_cqrq_qid (question_id);
 alter table c_quiz_rel_question ADD INDEX idx_cqrq_cid (c_id);
 alter table c_quiz_answer add index idx_qa_cidqid (c_id, question_id);
 </pre>
-In Chamilo 1.10.6, an additional query was confirmed to still have effect a considerable effect:
+In Chamilo 1.10.6, two additional queries were confirmed to still have effect a considerable effect:
 <pre>
-alter table c_quiz_question_rel_category add index idx_qqrc_qid (question_id);
+ALTER TABLE c_quiz_question_rel_category ADD INDEX idx_qqrc_qid (question_id);
+ALTER TABLE c_lp_item_view ADD INDEX idx_clpiv_c_i_v (c_id, id, view_count);
 </pre>
 <hr />
 <h2><a name="3.Indexes-caching"></a>3. Indexes caching</h2>

+ 10 - 4
main/inc/lib/pdf.lib.php

@@ -250,7 +250,10 @@ class PDF
             if (empty($file) && !empty($html_title)) {
                 //this is a chapter, print title & skip the rest
                 if ($print_title) {
-                    $this->pdf->WriteHTML('<html><body><h3>'.$html_title.'</h3></body></html>'.$page_break);
+                    $this->pdf->WriteHTML(
+                        '<html><body><h3>'.$html_title.'</h3></body></html>'.$page_break,
+                        2
+                    );
                 }
                 continue;
             }
@@ -269,7 +272,10 @@ class PDF
 
             //it's not a chapter but the file exists, print its title
             if ($print_title) {
-                $this->pdf->WriteHTML('<html><body><h3>' . $html_title . '</h3></body></html>');
+                $this->pdf->WriteHTML(
+                    '<html><body><h3>' . $html_title . '</h3></body></html>',
+                    2
+                );
             }
 
             $file_info = pathinfo($file);
@@ -370,12 +376,12 @@ class PDF
                     $title = $filename; // Here file name is expected to contain ASCII symbols only.
                 }
                 if (!empty($document_html)) {
-                    $this->pdf->WriteHTML($document_html.$page_break);
+                    $this->pdf->WriteHTML($document_html.$page_break, 2);
                 }
             } elseif (in_array($extension, array('jpg','jpeg','png','gif'))) {
                 //Images
                 $image = Display::img($file);
-                $this->pdf->WriteHTML('<html><body>'.$image.'</body></html>'.$page_break);
+                $this->pdf->WriteHTML('<html><body>'.$image.'</body></html>'.$page_break, 2);
             }
         }