2021-05-14 07:23:53 +00:00
|
|
|
import 'package:angel3_model/angel3_model.dart';
|
2018-12-31 00:30:23 +00:00
|
|
|
|
|
|
|
void main() {
|
|
|
|
var todo = Todo(id: '34', isComplete: false);
|
|
|
|
print(todo.idAsInt == 34);
|
|
|
|
}
|
|
|
|
|
|
|
|
class Todo extends Model {
|
2021-03-18 00:15:01 +00:00
|
|
|
String? text;
|
2018-12-31 00:30:23 +00:00
|
|
|
|
2021-08-02 12:20:07 +00:00
|
|
|
bool isComplete;
|
2018-12-31 00:30:23 +00:00
|
|
|
|
|
|
|
Todo(
|
2021-08-02 12:20:07 +00:00
|
|
|
{required String id,
|
2018-12-31 00:30:23 +00:00
|
|
|
this.text,
|
2021-08-02 12:20:07 +00:00
|
|
|
this.isComplete = false,
|
2021-03-18 00:15:01 +00:00
|
|
|
DateTime? createdAt,
|
|
|
|
DateTime? updatedAt})
|
2018-12-31 00:30:23 +00:00
|
|
|
: super(id: id, createdAt: createdAt, updatedAt: updatedAt);
|
|
|
|
}
|