Skip to content

feat: multi-select notifications with batch delete and mark as read#297

Open
deaflynx wants to merge 10 commits intothingsboard:devfrom
deaflynx:feat/notifications-multi-select
Open

feat: multi-select notifications with batch delete and mark as read#297
deaflynx wants to merge 10 commits intothingsboard:devfrom
deaflynx:feat/notifications-multi-select

Conversation

@deaflynx
Copy link
Copy Markdown

@deaflynx deaflynx commented May 1, 2026

Summary

  • Adds multi-select mode to the Notifications tab (long-press to enter)
  • App bar switches to show selected count, Select all loaded checkbox, and close button
  • Bottom action bar with batch Delete and Mark as Read buttons
  • Confirmation dialogs and determinate progress indicator for batch operations
  • Slidable swipe actions are disabled during selection mode
  • Selection mode exits on back press, filter change, or pull-to-refresh
  • Cancellable batch operations with failure count feedback
  • Mark as Read disabled when all selected items are already read

This brings the multi-select feature from CE (deaflynx/flutter_thingsboard_app#241).

Test plan

  • Long-press a notification → enters selection mode with item checked
  • Tap notifications to toggle selection checkboxes
  • Tap "Select all loaded" → all loaded items selected
  • Tap "Delete" → confirmation dialog, then selected notifications deleted, badge count updated
  • Tap "Mark as Read" → confirmation dialog, then selected unread notifications marked as read
  • Press X or system back → exits selection mode
  • Switch between All/Unread filter → exits selection mode
  • Pull-to-refresh → exits selection mode
  • Exiting during a running batch operation cancels it

deaflynx and others added 10 commits April 8, 2026 15:21
Show the label field as secondary italic text below the entity name
in device and asset list cards. The label is only displayed when
non-empty, preserving the existing layout for entities without labels.

Closes thingsboard#216
The API expects comment as a JSON object {text: ...} but the mobile app
was sending raw strings, causing NoSuchMethodError on .edited/.text
access. Normalize comment field in datasource for both Map and legacy
String formats.
Comment parsing (Map/String → AlarmCommentJsonNode) is now handled in
thingsboard_client's AlarmComment.fromJson, so the datasource becomes a
clean pass-through again.
Use S.of(context) via NavigationHelper.getLocalizedTitle so bottom-nav
and More-list entries respect the active locale instead of showing the
English defaultLabel stored on NavigationItemData.
Change EntitiesBase.title and noItemsFoundText from getters returning
hardcoded English to methods taking BuildContext so each module can
return S.of(context).X. Applies to customers, assets, tenants, devices,
device profiles, and audit logs pages. Adds missing arb keys: tenants,
noCustomersFound, noAssetsFound, noTenantsFound, noDevicesFound,
noAuditLogsFound.
…asset-label-in-list

feat: display entity label in device and asset list cards
…ions

fix: localize navigation titles and entity list pages
fix: alarm comment crash and wrong display format
…tifications

Long-press a notification to enter selection mode with checkboxes.
Select All loaded via app bar checkbox, then batch Delete or Mark as Read
from the bottom action bar with confirmation and progress feedback.
Brings the multi-select notifications feature from CE: long-press to enter
selection mode, batch delete and mark as read with confirmation dialogs,
progress indicator, and cancellation support. Also adopts CE's localized
navigation and more-menu titles via NavigationHelper.getLocalizedTitle.

Conflict resolution:
- navigation_page.dart: kept PE structure, adopted CE's localized titles
- more_page.dart: kept PE's SafeArea wrapping, adopted CE's localized titles
- 12 ARB files: kept PE-specific keys, appended CE's multi-select keys
- Generated messages_*.dart regenerated from resolved ARBs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant