◆ getDefaultAmountOfStepsPerRun()
ilGlossaryCollectionMigration::getDefaultAmountOfStepsPerRun |
( |
| ) |
|
◆ getLabel()
ilGlossaryCollectionMigration::getLabel |
( |
| ) |
|
◆ getPreconditions()
ilGlossaryCollectionMigration::getPreconditions |
( |
Environment |
$environment | ) |
|
◆ getRemainingAmountOfSteps()
ilGlossaryCollectionMigration::getRemainingAmountOfSteps |
( |
| ) |
|
Definition at line 96 of file class.ilGlossaryCollectionMigration.php.
98 $set = $this->db->query(
99 "SELECT glossary.virtual FROM glossary " .
100 " WHERE glossary.virtual = 'level' OR glossary.virtual = 'subtree'" 102 if ($rec = $this->db->fetchAssoc($set)) {
◆ log()
ilGlossaryCollectionMigration::log |
( |
string |
$str | ) |
|
|
protected |
◆ prepare()
ilGlossaryCollectionMigration::prepare |
( |
Environment |
$environment | ) |
|
◆ step()
ilGlossaryCollectionMigration::step |
( |
Environment |
$environment | ) |
|
Definition at line 56 of file class.ilGlossaryCollectionMigration.php.
References ILIAS\Repository\int(), and log().
58 $set = $this->db->query(
59 "SELECT glossary.id AS glossary_id, glossary.virtual, glossary_term.id AS term_id, glossary_term.glo_id " .
60 " FROM glossary LEFT JOIN glossary_term ON glossary.id = glossary_term.glo_id " .
61 " WHERE glossary.virtual = 'level' OR glossary.virtual = 'subtree' " .
62 " ORDER BY glossary.id" 65 while ($rec = $this->db->fetchAssoc($set)) {
66 $glo_id = (
int) $rec[
"glossary_id"];
67 $term_id = (
int) $rec[
"term_id"];
68 if ($glo_id === $tmp_id) {
72 $this->db->manipulate(
73 "UPDATE glossary SET " .
74 " glossary.virtual = " . $this->db->quote(
"none",
"text") .
75 " WHERE glossary.id = " . $this->db->quote($glo_id,
"integer")
77 $this->
log(
"Convert glossary with id " . $glo_id .
" into Standard Glossary.");
79 $this->db->manipulate(
80 "UPDATE glossary SET " .
81 " glossary.virtual = " . $this->db->quote(
"coll",
"text") .
82 " WHERE glossary.id = " . $this->db->quote($glo_id,
"integer")
84 $this->
log(
"Convert glossary with id " . $glo_id .
" into Collection Glossary.");
◆ $db
The documentation for this class was generated from the following file: