saveToPreferences method
- SharedPreferences prefs
Guarda las preferencias de notificación en SharedPreferences.
Este método guarda cada una de las configuraciones para que puedan ser recuperadas.
Implementation
Future<void> saveToPreferences(SharedPreferences prefs) async {
await prefs.setBool("isActive", isActive);
await prefs.setBool("dailyNotifications", dailyNotifications);
await prefs.setBool("weeklyMotivation", weeklyMotivation);
await prefs.setBool("newRecordNotification", newRecordNotification);
await prefs.setBool("trainingReminders", trainingReminders);
await prefs.setBool("inactivityNotification", inactivityNotification);
}