Groups let people keep each other honest: create one or join with a six-letter invite code. Each group has shared goals split into measurable objectives (km, sessions, words) that every member logs toward, a leaderboard of kept rate and streak with nudges, and a group chat where check-ins and nudges appear as cards beside the talk. The open chat polls for new messages. Reached from a new Groups tab (Training moves into the day rail), a Home "Your groups" rail that opens the chat, and a Group tile in the add sheet. Mock mode seeds two groups, a joinable one and members who reply. The water tracker is removed; it did not fit the app. Bottom sheets are now square app-wide via the theme. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KhQh614DMeYoQEH9SoMRUw
25 lines
579 B
Dart
25 lines
579 B
Dart
/// Logs an amount against one objective of a shared goal.
|
|
class ObjectiveProgressRequest {
|
|
String groupId;
|
|
|
|
String goalId;
|
|
|
|
String objectiveId;
|
|
|
|
double amount;
|
|
|
|
String note;
|
|
|
|
ObjectiveProgressRequest({this.groupId = "", this.goalId = "", this.objectiveId = "", this.amount = 0, this.note = ""});
|
|
|
|
Map<String, dynamic> toJson() {
|
|
final Map<String, dynamic> data = <String, dynamic>{};
|
|
data['groupId'] = groupId;
|
|
data['goalId'] = goalId;
|
|
data['objectiveId'] = objectiveId;
|
|
data['amount'] = amount;
|
|
data['note'] = note;
|
|
return data;
|
|
}
|
|
}
|