Elgg
Version 6.1
Main Page
Related Pages
Namespaces
Classes
Files
Examples
File List
File Members
engine
schema
migrations
20170728073540_create_access_collection_membership_table.php
Go to the documentation of this file.
1
<?php
2
3
use
Phinx\Migration\AbstractMigration
;
4
use
Phinx\Db\Adapter\MysqlAdapter
;
5
6
class
CreateAccessCollectionMembershipTable
extends
AbstractMigration {
14
public
function
change
() {
15
16
if
($this->hasTable(
"access_collection_membership"
)) {
17
return
;
18
}
19
20
$table
= $this->table(
"access_collection_membership"
, [
21
'id'
=>
false
,
22
'primary_key'
=> [
23
"user_guid"
,
24
"access_collection_id"
25
],
26
'engine'
=>
"InnoDB"
,
27
'encoding'
=>
"utf8mb4"
,
28
'collation'
=>
"utf8mb4_general_ci"
,
29
]);
30
31
$table
->addColumn(
'user_guid'
,
'integer'
, [
32
'null'
=>
false
,
33
'limit'
=> MysqlAdapter::INT_BIG,
34
'precision'
=> 20,
35
'signed'
=>
false
,
36
]);
37
38
$table
->addColumn(
'access_collection_id'
,
'integer'
, [
39
'null'
=>
false
,
40
'limit'
=> MysqlAdapter::INT_REGULAR,
41
'precision'
=> 11,
42
]);
43
44
$table
->save();
45
46
}
47
}
CreateAccessCollectionMembershipTable\change
change()
CREATE TABLE prefix_access_collection_membership ( user_guid bigint(20) unsigned NOT NULL...
Definition:
20170728073540_create_access_collection_membership_table.php:14
MysqlAdapter
CreateAccessCollectionMembershipTable
Definition:
20170728073540_create_access_collection_membership_table.php:6
$table
$table
Definition:
user.php:37
AbstractMigration
Generated on Wed Dec 4 2024 00:00:22 for Elgg by
1.8.11