ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ProgressBlockUpdateSteps11.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
21namespace ILIAS\Tracking\Setup;
22
26
28{
29 protected ilDBInterface $db;
30
31 public function prepare(ilDBInterface $db): void
32 {
33 $this->db = $db;
34 }
35
39 public function step_1(): void
40 {
41 if ($this->db->tableExists('ut_progress_block')) {
42 return;
43 }
44 $this->db->createTable('ut_progress_block', [
45 'obj_id' => [
46 'type' => ilDBConstants::T_TEXT,
47 'length' => 4,
48 'default' => 0,
49 'notnull' => true
50 ],
51 'show_block' => [
53 'length' => 1,
54 'default' => 0,
55 'notnull' => true
56 ]
57 ]);
58 $this->db->addPrimaryKey('ut_progress_block', ['obj_id']);
59 }
60}
Class ilDBConstants.
Interface ilDBInterface.
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...