Remove Windows-specific files and configurations for the rental income tracker project, including CMakeLists, resource files, and generated plugin registrants. This cleanup eliminates unnecessary dependencies and prepares the project for a more streamlined build process.
Signed-off-by: Hans Kokx <hans.d.kokx@gmail.com>
This commit is contained in:
@@ -201,7 +201,9 @@ class NotificationService {
|
||||
iOS: DarwinNotificationDetails(categoryIdentifier: 'rent_actions'),
|
||||
),
|
||||
payload: payload,
|
||||
androidScheduleMode: AndroidScheduleMode.exactAllowWhileIdle,
|
||||
// Best-effort delivery avoids the exact alarm permission requirement on
|
||||
// recent Android versions while still allowing reminders during idle.
|
||||
androidScheduleMode: AndroidScheduleMode.inexactAllowWhileIdle,
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -38,6 +38,8 @@ class RentTableRow {
|
||||
}
|
||||
|
||||
class RentController extends ChangeNotifier {
|
||||
static const int _notificationScheduleHorizonMonths = 24;
|
||||
|
||||
RentController({
|
||||
StorageService? storageService,
|
||||
ForexRateApiService? exchangeService,
|
||||
@@ -611,22 +613,29 @@ class RentController extends ChangeNotifier {
|
||||
|
||||
Future<void> _syncNotificationScheduleForCurrentMonth() async {
|
||||
final now = DateTime.now();
|
||||
final key = TimeService.monthKey(now.year, now.month);
|
||||
final isPaid = _records.containsKey(key);
|
||||
for (
|
||||
var offset = 0;
|
||||
offset < _notificationScheduleHorizonMonths;
|
||||
offset++
|
||||
) {
|
||||
final scheduledMonth = DateTime(now.year, now.month + offset, 1);
|
||||
final year = scheduledMonth.year;
|
||||
final month = scheduledMonth.month;
|
||||
final key = TimeService.monthKey(year, month);
|
||||
final isPaid = _records.containsKey(key);
|
||||
|
||||
if (!_settings.occupied ||
|
||||
_isNotOccupiedMonth(now.year, now.month) ||
|
||||
isPaid) {
|
||||
await _notificationService.cancelForMonth(now.year, now.month);
|
||||
return;
|
||||
if (!_settings.occupied || _isNotOccupiedMonth(year, month) || isPaid) {
|
||||
await _notificationService.cancelForMonth(year, month);
|
||||
continue;
|
||||
}
|
||||
|
||||
await _notificationService.scheduleForMonth(
|
||||
year: year,
|
||||
month: month,
|
||||
quietHourStart: _settings.localQuietHourStart,
|
||||
fallbackHour: _settings.localFallbackHour,
|
||||
);
|
||||
}
|
||||
|
||||
await _notificationService.scheduleForMonth(
|
||||
year: now.year,
|
||||
month: now.month,
|
||||
quietHourStart: _settings.localQuietHourStart,
|
||||
fallbackHour: _settings.localFallbackHour,
|
||||
);
|
||||
}
|
||||
|
||||
void _setLoading(bool value) {
|
||||
|
||||
Reference in New Issue
Block a user