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

Public Member Functions

 prepare (ilDBInterface $db)
 
 step_1 ()
 
- 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 23 of file ilNotificationUpdateSteps11.php.

Member Function Documentation

◆ prepare()

ilNotificationUpdateSteps11::prepare ( ilDBInterface  $db)

Definition at line 27 of file ilNotificationUpdateSteps11.php.

27 : void
28 {
29 $this->db = $db;
30 }

References $db.

◆ step_1()

ilNotificationUpdateSteps11::step_1 ( )

Definition at line 32 of file ilNotificationUpdateSteps11.php.

32 : void
33 {
34 if (!$this->db->tableExists('push_subscriptions')) {
35 $this->db->createTable(
36 'push_subscriptions',
37 [
38 "endpoint" => [
39 'type' => ilDBConstants::T_TEXT,
40 'notnull' => true,
41 ],
42 "user_id" => [
44 'notnull' => true,
45 ],
46 "p256dh" => [
47 'type' => ilDBConstants::T_TEXT,
48 'notnull' => true,
49 'length' => 87
50 ],
51 "auth" => [
52 'type' => ilDBConstants::T_TEXT,
53 'notnull' => true,
54 'length' => 22
55 ],
56 ]
57 );
58 $this->db->addIndex('push_subscriptions', ['user_id'], 'i1');
59 $this->db->addPrimaryKey('push_subscriptions', ['auth']);
60 }
61 }

References ilDBConstants\T_INTEGER, and ilDBConstants\T_TEXT.

Field Documentation

◆ $db

ilDBInterface ilNotificationUpdateSteps11::$db
protected

Definition at line 25 of file ilNotificationUpdateSteps11.php.

Referenced by prepare().


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