Merge branch '27548-29' of git://github.com/samhemelryk/moodle
authorDan Poltawski <dan@moodle.com>
Mon, 1 Dec 2014 12:21:19 +0000 (12:21 +0000)
committerDan Poltawski <dan@moodle.com>
Mon, 1 Dec 2014 12:21:19 +0000 (12:21 +0000)
Conflicts:
lib/db/install.xml
lib/db/upgrade.php
version.php

1  2 
comment/lib.php
lib/db/install.xml
lib/db/upgrade.php
version.php

diff --cc comment/lib.php
@@@ -241,20 -248,16 +248,21 @@@ class comment 
          }
          // setup variables for non-js interface
          self::$nonjs = optional_param('nonjscomment', '', PARAM_ALPHANUM);
-         self::$comment_itemid  = optional_param('comment_itemid',  '', PARAM_INT);
+         self::$comment_itemid = optional_param('comment_itemid',  '', PARAM_INT);
+         self::$comment_component = optional_param('comment_component', '', PARAM_COMPONENT);
          self::$comment_context = optional_param('comment_context', '', PARAM_INT);
-         self::$comment_page    = optional_param('comment_page',    '', PARAM_INT);
-         self::$comment_area    = optional_param('comment_area',    '', PARAM_AREA);
+         self::$comment_page = optional_param('comment_page',    '', PARAM_INT);
+         self::$comment_area = optional_param('comment_area',    '', PARAM_AREA);
  
 -        $page->requires->string_for_js('addcomment', 'moodle');
 -        $page->requires->string_for_js('deletecomment', 'moodle');
 -        $page->requires->string_for_js('comments', 'moodle');
 -        $page->requires->string_for_js('commentsrequirelogin', 'moodle');
 +        $page->requires->strings_for_js(array(
 +                'addcomment',
 +                'comments',
 +                'commentscount',
 +                'commentsrequirelogin',
 +                'deletecomment',
 +            ),
 +            'moodle'
 +        );
      }
  
      /**
@@@ -1,5 -1,5 +1,5 @@@
  <?xml version="1.0" encoding="UTF-8" ?>
- <XMLDB PATH="lib/db" VERSION="20141117" COMMENT="XMLDB file for core Moodle tables"
 -<XMLDB PATH="lib/db" VERSION="20141113" COMMENT="XMLDB file for core Moodle tables"
++<XMLDB PATH="lib/db" VERSION="20141201" COMMENT="XMLDB file for core Moodle tables"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xsi:noNamespaceSchemaLocation="../../lib/xmldb/xmldb.xsd"
  >
        </KEYS>
      </TABLE>
    </TABLES>
--</XMLDB>
++</XMLDB>
@@@ -4058,21 -4058,20 +4058,34 @@@ function xmldb_main_upgrade($oldversion
      // Moodle v2.8.0 release upgrade line.
      // Put any upgrade step following this.
  
 -    if ($oldversion < 2014112800.00) {
 +    if ($oldversion < 2014120100.00) {
 +
 +        // Define field sslverification to be added to mnet_host.
 +        $table = new xmldb_table('mnet_host');
 +        $field = new xmldb_field('sslverification', XMLDB_TYPE_INTEGER, '1', null, XMLDB_NOTNULL, null, '0', 'applicationid');
 +
 +        // Conditionally launch add field sslverification.
 +        if (!$dbman->field_exists($table, $field)) {
 +            $dbman->add_field($table, $field);
 +        }
 +
 +        // Main savepoint reached.
 +        upgrade_main_savepoint(true, 2014120100.00);
 +    }
 +
++    if ($oldversion < 2014120101.00) {
  
 -        upgrade_main_savepoint(true, 2014112800.00);
+         // Define field component to be added to comments.
+         $table = new xmldb_table('comments');
+         $field = new xmldb_field('component', XMLDB_TYPE_CHAR, '255', null, null, null, null, 'contextid');
+         // Conditionally launch add field component.
+         if (!$dbman->field_exists($table, $field)) {
+             $dbman->add_field($table, $field);
+         }
+         // Main savepoint reached.
 -
++        upgrade_main_savepoint(true, 2014120101.00);
+     }
      return true;
  }
diff --cc version.php
@@@ -29,7 -29,7 +29,7 @@@
  
  defined('MOODLE_INTERNAL') || die();
  
- $version  = 2014120100.00;              // YYYYMMDD      = weekly release date of this DEV branch.
 -$version  = 2014112800.00;              // YYYYMMDD      = weekly release date of this DEV branch.
++$version  = 2014120101.00;              // YYYYMMDD      = weekly release date of this DEV branch.
                                          //         RR    = release increments - 00 in DEV branches.
                                          //           .XX = incremental changes.