-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #549 from oat-sa/release-5.5.0
Release 5.5.0
- Loading branch information
Showing
1 changed file
with
21 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -35,16 +35,16 @@ | |
* @author Jean-S�bastien Conan <[email protected]> | ||
*/ | ||
class Updater extends \common_ext_ExtensionUpdater { | ||
|
||
/** | ||
* | ||
* | ||
* @param string $initialVersion | ||
* @return string $versionUpdatedTo | ||
*/ | ||
public function update($initialVersion) { | ||
|
||
$currentVersion = $initialVersion; | ||
|
||
// add testrunner config | ||
if ($currentVersion == '2.6') { | ||
|
||
|
@@ -59,15 +59,15 @@ public function update($initialVersion) { | |
|
||
$currentVersion = '2.6.1'; | ||
} | ||
|
||
if ($currentVersion == '2.6.1') { | ||
$config = \common_ext_ExtensionsManager::singleton()->getExtensionById('taoQtiTest')->getConfig('testRunner'); | ||
$config['exitButton'] = false; | ||
\common_ext_ExtensionsManager::singleton()->getExtensionById('taoQtiTest')->setConfig('testRunner', $config); | ||
|
||
$currentVersion = '2.6.2'; | ||
} | ||
|
||
// add testrunner review screen config | ||
if ($currentVersion == '2.6.2') { | ||
$extension = \common_ext_ExtensionsManager::singleton()->getExtensionById('taoQtiTest'); | ||
|
@@ -81,7 +81,7 @@ public function update($initialVersion) { | |
|
||
$currentVersion = '2.6.3'; | ||
} | ||
|
||
// adjust testrunner config | ||
if ($currentVersion == '2.6.3') { | ||
$defaultConfig = array( | ||
|
@@ -118,13 +118,13 @@ public function update($initialVersion) { | |
// add markForReview button | ||
if ($currentVersion === '2.7.0') { | ||
$registry = TestRunnerClientConfigRegistry::getRegistry(); | ||
|
||
$registry->registerQtiTools('markForReview', array( | ||
'label' => 'Mark for review', | ||
'icon' => 'anchor', | ||
'hook' => 'taoQtiTest/testRunner/actionBar/markForReview' | ||
)); | ||
|
||
$currentVersion = '2.8.0'; | ||
} | ||
|
||
|
@@ -143,7 +143,7 @@ public function update($initialVersion) { | |
// adjust testrunner config: set the "can collapse" option | ||
if ($currentVersion == '2.9.0') { | ||
$registry = TestRunnerClientConfigRegistry::getRegistry(); | ||
|
||
$registry->registerQtiTools('collapseReview', array( | ||
'title' => 'Show/Hide the review screen', | ||
'label' => 'Review', | ||
|
@@ -184,7 +184,7 @@ public function update($initialVersion) { | |
|
||
$currentVersion = '2.12.0'; | ||
} | ||
|
||
// update the test taker review action buttons | ||
if ($currentVersion == '2.12.0') { | ||
$registry = TestRunnerClientConfigRegistry::getRegistry(); | ||
|
@@ -217,7 +217,7 @@ public function update($initialVersion) { | |
|
||
$currentVersion = '2.14.0'; | ||
} | ||
|
||
if ($currentVersion === '2.14.0') { | ||
try { | ||
$this->getServiceManager()->get('taoQtiTest/SessionStateService'); | ||
|
@@ -239,7 +239,7 @@ public function update($initialVersion) { | |
|
||
$currentVersion = '2.16.0'; | ||
} | ||
|
||
$this->setVersion($currentVersion); | ||
|
||
if ($this->isBetween('2.16.0','2.17.0')) { | ||
|
@@ -255,12 +255,12 @@ public function update($initialVersion) { | |
|
||
$this->getServiceManager()->register(QtiRunnerService::CONFIG_ID, $service); | ||
} | ||
|
||
$this->setVersion('2.17.0'); | ||
} | ||
|
||
$this->skip('2.17.0','2.19.1'); | ||
|
||
if ($this->isVersion('2.19.1')) { | ||
// sets default plugin options | ||
$extension = \common_ext_ExtensionsManager::singleton()->getExtensionById('taoQtiTest'); | ||
|
@@ -293,7 +293,7 @@ public function update($initialVersion) { | |
|
||
$this->setVersion('2.23.0'); | ||
} | ||
|
||
$this->skip('2.23.0','2.24.0'); | ||
|
||
if ($this->isVersion('2.24.0')) { | ||
|
@@ -325,7 +325,7 @@ public function update($initialVersion) { | |
|
||
$this->setVersion('2.26.0'); | ||
} | ||
|
||
$this->skip('2.26.0', '2.27.0'); | ||
|
||
if ($this->isVersion('2.27.0')) { | ||
|
@@ -427,10 +427,10 @@ public function update($initialVersion) { | |
'params' => [] | ||
], | ||
]); | ||
|
||
$extension->setConfig('testRunner', $config); | ||
} | ||
|
||
$this->setVersion('2.31.1'); | ||
} | ||
|
||
|
@@ -518,9 +518,9 @@ public function update($initialVersion) { | |
$this->setVersion('5.0.0'); | ||
} | ||
|
||
$this->skip('5.0.0', '5.3.0'); | ||
$this->skip('5.0.0', '5.4.0'); | ||
|
||
if ($this->isVersion('5.3.0')) { | ||
if ($this->isVersion('5.4.0')) { | ||
|
||
$extension = \common_ext_ExtensionsManager::singleton()->getExtensionById('taoQtiTest'); | ||
$config = $extension->getConfig('testRunner'); | ||
|