Billing Stripe, link regia mobile e staff solo trasmissione.
Aggiunge fatturazione club, pagina regia condivisibile senza account, roster squadre e rimuove la modalità controller dall'app (v1.1.0). Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
22
mobile/lib/core/team_selection_storage.dart
Normal file
22
mobile/lib/core/team_selection_storage.dart
Normal file
@@ -0,0 +1,22 @@
|
||||
import 'package:shared_preferences/shared_preferences.dart';
|
||||
|
||||
class TeamSelectionStorage {
|
||||
static const _keySelectedTeamId = 'selected_team_id';
|
||||
|
||||
static Future<String?> load() async {
|
||||
final prefs = await SharedPreferences.getInstance();
|
||||
final id = prefs.getString(_keySelectedTeamId);
|
||||
if (id == null || id.isEmpty) return null;
|
||||
return id;
|
||||
}
|
||||
|
||||
static Future<void> save(String teamId) async {
|
||||
final prefs = await SharedPreferences.getInstance();
|
||||
await prefs.setString(_keySelectedTeamId, teamId);
|
||||
}
|
||||
|
||||
static Future<void> clear() async {
|
||||
final prefs = await SharedPreferences.getInstance();
|
||||
await prefs.remove(_keySelectedTeamId);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user