Skip to content
This repository was archived by the owner on Dec 10, 2018. It is now read-only.

Commit d08b78b

Browse files
committed
Update README
1 parent d29f391 commit d08b78b

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

README.md

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,6 @@ class TestModel extends Model
5050
}
5151
```
5252

53-
5453
If don't like the primary key named `uuid` you can leave off the `HasUuidPrimaryKey` trait and manually specify `$primaryKey`. Don't forget set `$incrementing` to false.
5554

5655
```php
@@ -67,6 +66,21 @@ class TestModel extends Model
6766
}
6867
```
6968

69+
#### A note on the `uuid` blueprint method
70+
71+
Because we're currently not able to add new blueprint methods which can be used without overriding services,
72+
we decided to override the `uuid` behaviour which will create a `BINARY` column instead of a `CHAR(36)` column.
73+
74+
There are some cases in which Laravel's generated code will also use `uuid`, but doesn't support our binary implementation.
75+
An example are database notifications.
76+
To make those work, you'll have to change the migration of those notifications to use `CHAR(36)`.
77+
78+
```php
79+
// $table->uuid('id')->primary();
80+
81+
$table->char('id', 36)->primary();
82+
```
83+
7084

7185
### Creating a model
7286

0 commit comments

Comments
 (0)