ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ilCmiXapiDatabaseUpdateSteps Class Reference
+ Inheritance diagram for ilCmiXapiDatabaseUpdateSteps:
+ Collaboration diagram for ilCmiXapiDatabaseUpdateSteps:

Public Member Functions

 prepare (ilDBInterface $db)
 
 step_1 ()
 
 step_2 ()
 
 step_3 ()
 
 step_4 ()
 
 step_5 ()
 
 step_6 ()
 
 step_7 ()
 
 step_8 ()
 
 step_9 ()
 
 step_10 ()
 
 step_11 ()
 
 step_12 ()
 
 step_13 ()
 
 step_14 ()
 
 step_15 ()
 
 step_16 ()
 
- Public Member Functions inherited from ilDatabaseUpdateSteps
 prepare (\ilDBInterface $db)
 Prepare the execution of the steps. More...
 

Protected Attributes

ilDBInterface $db
 

Detailed Description

Definition at line 21 of file class.ilCmiXapiDatabaseUpdateSteps.php.

Member Function Documentation

◆ prepare()

ilCmiXapiDatabaseUpdateSteps::prepare ( ilDBInterface  $db)

Definition at line 25 of file class.ilCmiXapiDatabaseUpdateSteps.php.

25 : void
26 {
27 $this->db = $db;
28 }

References $db.

◆ step_1()

ilCmiXapiDatabaseUpdateSteps::step_1 ( )

Definition at line 30 of file class.ilCmiXapiDatabaseUpdateSteps.php.

30 : void
31 {
32 if (!$this->db->tableColumnExists('cmix_users', 'registration')) {
33 $this->db->addTableColumn('cmix_users', 'registration', array(
34 'type' => 'text',
35 'length' => 255,
36 'notnull' => true,
37 'default' => ''
38 ));
39 }
40 }

◆ step_10()

ilCmiXapiDatabaseUpdateSteps::step_10 ( )

Definition at line 135 of file class.ilCmiXapiDatabaseUpdateSteps.php.

135 : void
136 {
137 if (!$this->db->tableColumnExists('cmix_users', 'satisfied')) {
138 $this->db->addTableColumn('cmix_users', 'satisfied', array(
139 'type' => 'integer',
140 'length' => 1,
141 'notnull' => true,
142 'default' => 0
143 ));
144 }
145 }

◆ step_11()

ilCmiXapiDatabaseUpdateSteps::step_11 ( )

Definition at line 147 of file class.ilCmiXapiDatabaseUpdateSteps.php.

147 : void
148 {
149 if (!$this->db->tableColumnExists('cmix_settings', 'switch_to_review')) {
150 $this->db->addTableColumn('cmix_settings', 'switch_to_review', array(
151 'type' => 'integer',
152 'length' => 1,
153 'notnull' => true,
154 'default' => 1
155 ));
156 }
157 }

◆ step_12()

ilCmiXapiDatabaseUpdateSteps::step_12 ( )

Definition at line 159 of file class.ilCmiXapiDatabaseUpdateSteps.php.

159 : void
160 {
161 $this->db->manipulateF('DELETE FROM cmix_users WHERE usr_id = %s', ['integer'], [13]);
162 }

◆ step_13()

ilCmiXapiDatabaseUpdateSteps::step_13 ( )

Definition at line 164 of file class.ilCmiXapiDatabaseUpdateSteps.php.

164 : void
165 {
166 if (!$this->db->tableColumnExists('cmix_lrs_types', 'delete_data')) {
167 $this->db->addTableColumn('cmix_lrs_types', 'delete_data', array(
168 'type' => 'integer',
169 'length' => 1,
170 'notnull' => true,
171 'default' => 0
172 ));
173 }
174 }

◆ step_14()

ilCmiXapiDatabaseUpdateSteps::step_14 ( )

Definition at line 176 of file class.ilCmiXapiDatabaseUpdateSteps.php.

176 : void
177 {
178 if (!$this->db->tableColumnExists('cmix_settings', 'delete_data')) {
179 $this->db->addTableColumn('cmix_settings', 'delete_data', array(
180 'type' => 'integer',
181 'length' => 1,
182 'notnull' => true,
183 'default' => 0
184 ));
185 }
186 }

◆ step_15()

ilCmiXapiDatabaseUpdateSteps::step_15 ( )

Definition at line 188 of file class.ilCmiXapiDatabaseUpdateSteps.php.

188 : void
189 {
190 if (!$this->db->tableExists('cmix_del_user')) {
191 $fields_data = array(
192 'usr_id' => array(
193 'type' => 'integer',
194 'length' => 4,
195 'notnull' => true
196 ),
197 'added' => array(
198 'type' => 'timestamp',
199 'notnull' => true
200 ),
201 'updated' => array(
202 'type' => 'timestamp',
203 'notnull' => false,
204 'default' => null
205 ),
206 );
207 $this->db->createTable("cmix_del_user", $fields_data);
208 $this->db->addPrimaryKey("cmix_del_user", array("usr_id"));
209 }
210 }

◆ step_16()

ilCmiXapiDatabaseUpdateSteps::step_16 ( )

Definition at line 212 of file class.ilCmiXapiDatabaseUpdateSteps.php.

212 : void
213 {
214 if (!$this->db->tableExists('cmix_del_object')) {
215 $fields_data = array(
216 'obj_id' => array(
217 'type' => 'integer',
218 'length' => 4,
219 'notnull' => true
220 ),
221 'type_id' => array(
222 'type' => 'integer',
223 'length' => 4,
224 'notnull' => true
225 ),
226 'activity_id' => array(
227 'type' => 'text',
228 'length' => 128,
229 'notnull' => true,
230 ),
231 'added' => array(
232 'type' => 'timestamp',
233 'notnull' => true
234 ),
235 'updated' => array(
236 'type' => 'timestamp',
237 'notnull' => false,
238 'default' => null
239 ),
240 );
241 $this->db->createTable("cmix_del_object", $fields_data);
242 $this->db->addPrimaryKey("cmix_del_object", array("obj_id", "type_id", "activity_id"));
243 }
244 }

◆ step_2()

ilCmiXapiDatabaseUpdateSteps::step_2 ( )

Definition at line 42 of file class.ilCmiXapiDatabaseUpdateSteps.php.

42 : void
43 {
44 if (!$this->db->tableColumnExists('cmix_settings', 'publisher_id')) {
45 $this->db->addTableColumn('cmix_settings', 'publisher_id', array(
46 'type' => 'text',
47 'length' => 255,
48 'notnull' => true,
49 'default' => ''
50 ));
51 }
52 }

◆ step_3()

ilCmiXapiDatabaseUpdateSteps::step_3 ( )

Definition at line 54 of file class.ilCmiXapiDatabaseUpdateSteps.php.

54 : void
55 {
56 if (!$this->db->tableColumnExists('cmix_settings', 'anonymous_homepage')) {
57 $this->db->addTableColumn('cmix_settings', 'anonymous_homepage', array(
58 'type' => 'integer',
59 'length' => 1,
60 'notnull' => true,
61 'default' => 1
62 ));
63 }
64 }

◆ step_4()

ilCmiXapiDatabaseUpdateSteps::step_4 ( )

Definition at line 66 of file class.ilCmiXapiDatabaseUpdateSteps.php.

66 : void
67 {
68 if (!$this->db->tableColumnExists('cmix_settings', 'moveon')) {
69 $this->db->addTableColumn('cmix_settings', 'moveon', array(
70 'type' => 'text',
71 'length' => 32,
72 'notnull' => true,
73 'default' => ''
74 ));
75 }
76 }

◆ step_5()

ilCmiXapiDatabaseUpdateSteps::step_5 ( )

Definition at line 78 of file class.ilCmiXapiDatabaseUpdateSteps.php.

78 : void
79 {
80 if (!$this->db->tableColumnExists('cmix_token', 'cmi5_session')) {
81 $this->db->addTableColumn("cmix_token", "cmi5_session", [
82 'type' => 'text',
83 'length' => 255,
84 'notnull' => true,
85 'default' => ''
86 ]);
87 }
88 }

◆ step_6()

ilCmiXapiDatabaseUpdateSteps::step_6 ( )

Definition at line 90 of file class.ilCmiXapiDatabaseUpdateSteps.php.

90 : void
91 {
92 if (!$this->db->tableColumnExists('cmix_token', 'returned_for_cmi5_session')) {
93 $this->db->addTableColumn("cmix_token", "returned_for_cmi5_session", [
94 'type' => 'text',
95 'length' => 255,
96 'notnull' => true,
97 'default' => ''
98 ]);
99 }
100 }

◆ step_7()

ilCmiXapiDatabaseUpdateSteps::step_7 ( )

Definition at line 102 of file class.ilCmiXapiDatabaseUpdateSteps.php.

102 : void
103 {
104 if (!$this->db->tableColumnExists('cmix_settings', 'launch_parameters')) {
105 $this->db->addTableColumn('cmix_settings', 'launch_parameters', array(
106 'type' => 'text',
107 'length' => 255,
108 'notnull' => true,
109 'default' => ''
110 ));
111 }
112 }

◆ step_8()

ilCmiXapiDatabaseUpdateSteps::step_8 ( )

Definition at line 114 of file class.ilCmiXapiDatabaseUpdateSteps.php.

114 : void
115 {
116 if (!$this->db->tableColumnExists('cmix_settings', 'entitlement_key')) {
117 $this->db->addTableColumn('cmix_settings', 'entitlement_key', array(
118 'type' => 'text',
119 'length' => 255,
120 'notnull' => true,
121 'default' => ''
122 ));
123 }
124 }

◆ step_9()

ilCmiXapiDatabaseUpdateSteps::step_9 ( )

Definition at line 126 of file class.ilCmiXapiDatabaseUpdateSteps.php.

126 : void
127 {
128 if (!$this->db->tableColumnExists('cmix_token', 'cmi5_session_data')) {
129 $this->db->addTableColumn("cmix_token", "cmi5_session_data", [
130 'type' => 'clob'
131 ]);
132 }
133 }

Field Documentation

◆ $db

ilDBInterface ilCmiXapiDatabaseUpdateSteps::$db
protected

Definition at line 23 of file class.ilCmiXapiDatabaseUpdateSteps.php.

Referenced by prepare().


The documentation for this class was generated from the following file: