Merge branch 'MDL-49842-master' of git://github.com/xow/moodle

This commit is contained in:
Dan Poltawski 2015-04-16 10:30:28 +01:00
commit 1d81e1afc0
2 changed files with 5 additions and 0 deletions

View File

@ -69,6 +69,7 @@ Options:
--prefix=STRING Table prefix for above database tables. Default is mdl_
--fullname=STRING The fullname of the site
--shortname=STRING The shortname of the site
--summary=STRING The summary to be displayed on the front page
--adminuser=USERNAME Username for the moodle admin account. Default is admin
--adminpass=PASSWORD Password for the moodle admin account,
required in non-interactive mode.
@ -252,6 +253,7 @@ list($options, $unrecognized) = cli_get_params(
'prefix' => 'mdl_',
'fullname' => '',
'shortname' => '',
'summary' => '',
'adminuser' => 'admin',
'adminpass' => '',
'adminemail' => '',

View File

@ -517,4 +517,7 @@ function install_cli_database(array $options, $interactive) {
if (isset($options['fullname']) and $options['fullname'] !== '') {
$DB->set_field('course', 'fullname', $options['fullname'], array('format' => 'site'));
}
if (isset($options['summary'])) {
$DB->set_field('course', 'summary', $options['summary'], array('format' => 'site'));
}
}