9 Commits

Author SHA1 Message Date
316e95b81d Remove length from SchemaBuilderTrait::text.
close #9307
2015-08-05 22:50:46 +02:00
41b25e94b0 improved parameter naming and documentation of schemabuilder
changes according to #9191
close #9191
2015-08-04 11:58:41 +02:00
681db52ba6 refactored SchemaBuilder
- rename class to ColumnSchemaBuilder as this is more appropriate
- changed internal organisation to match how the rest of schema related classes work
  - the ColumnSchemaBuilder is now created the same way as QueryBuilder is
- removed static call magic and method annotations, now real methods are called as they are
- the whole code works on objects in a db context now instead of setting database connection in global state
- trait is now used by Migration by default but can be used in other contexts as well

Migration usage is now as follows:

```php
$this->createTable('example_table', [
  'id' => $this->primaryKey(),
  'name' => $this->string(64)->notNull(),
  'type' => $this->integer()->notNull()->defaultValue(10),
  'description' => $this->text(),
  'rule_name' => $this->string(64),
  'data' => $this->text(),
  'created_at' => $this->datetime()->notNull(),
  'updated_at' => $this->datetime(),
]);
```
2015-08-03 23:25:50 +02:00
a2568d1ec8 updated some comments and @since annotations 2015-08-02 19:56:49 +02:00
6d9fe671de various code style and whitespace adjustments 2015-08-02 00:27:19 +02:00
8e1d982da4 Cleanup, added ->unique(), changelog 2015-07-08 15:55:09 +03:00
da941a7675 Improved SchemaBuilder implementation 2015-07-08 15:40:09 +03:00
3f7ffd6707 Improved SchemaBuilder docs, refactored code 2015-07-08 15:39:34 +03:00
b456f699cc Implemented SchemaBuilder 2015-07-08 15:38:21 +03:00