Use schemaDef when checking database structure

This commit is contained in:
Mikael Nordfeldth 2013-10-30 14:17:54 +01:00
parent 603d2d3891
commit 5efff58213

View File

@ -80,39 +80,7 @@ class BookmarkPlugin extends MicroAppPlugin
{ {
$schema = Schema::get(); $schema = Schema::get();
// For storing user-submitted flags on profiles $schema->ensureTable('bookmark', Bookmark::schemaDef());
$schema->ensureTable('bookmark',
array(new ColumnDef('id',
'char',
36,
false,
'PRI'),
new ColumnDef('profile_id',
'integer',
null,
false,
'MUL'),
new ColumnDef('url',
'varchar',
255,
false,
'MUL'),
new ColumnDef('title',
'varchar',
255),
new ColumnDef('description',
'text'),
new ColumnDef('uri',
'varchar',
255,
false,
'UNI'),
new ColumnDef('created',
'datetime',
null,
false,
'MUL')));
return true; return true;
} }