Update connection
This commit is contained in:
parent
4a54dda438
commit
e6f1cf3948
1 changed files with 2 additions and 13 deletions
15
README.md
15
README.md
|
@ -9,32 +9,21 @@ Source-generated ORM for use with the Angel framework. Documentation is coming s
|
|||
This ORM can work with virtually any database, thanks to the functionality exposed by
|
||||
`package:query_builder`.
|
||||
|
||||
Your model, courtesy of `package:angel_serialize`:
|
||||
|
||||
```dart
|
||||
library angel_orm.test.models.car;
|
||||
|
||||
import 'package:angel_framework/common.dart';
|
||||
import 'package:angel_orm/angel_orm.dart' as orm;
|
||||
import 'package:angel_serialize/angel_serialize.dart';
|
||||
import 'car.postgres.g.dart';
|
||||
part 'car.g.dart';
|
||||
|
||||
@serializable
|
||||
@orm.model
|
||||
class _Car extends Model {
|
||||
@override
|
||||
String id;
|
||||
|
||||
String manufacturer;
|
||||
|
||||
int year;
|
||||
|
||||
@override
|
||||
@Alias('created_at')
|
||||
DateTime createdAt;
|
||||
|
||||
@override
|
||||
@Alias('updated_at')
|
||||
DateTime updatedAt;
|
||||
}
|
||||
```
|
||||
|
||||
|
|
Loading…
Reference in a new issue