feat: basic database functionality
This commit is contained in:
11
lib/data/db/tables/statistic_scope_table.dart
Normal file
11
lib/data/db/tables/statistic_scope_table.dart
Normal file
@@ -0,0 +1,11 @@
|
||||
import 'package:drift/drift.dart';
|
||||
import 'package:tallee/data/db/tables/statistic_table.dart';
|
||||
|
||||
class StatisticScopeTable extends Table {
|
||||
TextColumn get statisticId =>
|
||||
text().references(StatisticTable, #id, onDelete: KeyAction.cascade)();
|
||||
TextColumn get scope => text()();
|
||||
|
||||
@override
|
||||
Set<Column<Object>> get primaryKey => {statisticId, scope};
|
||||
}
|
||||
Reference in New Issue
Block a user