Partial web app support
This commit is contained in:
@@ -86,7 +86,7 @@ class AlarmQueryController extends PageKeyController<AlarmQuery> {
|
||||
|
||||
}
|
||||
|
||||
class AlarmCard extends TbContextWidget<AlarmCard, _AlarmCardState> {
|
||||
class AlarmCard extends TbContextWidget {
|
||||
|
||||
final AlarmInfo alarm;
|
||||
|
||||
@@ -97,7 +97,7 @@ class AlarmCard extends TbContextWidget<AlarmCard, _AlarmCardState> {
|
||||
|
||||
}
|
||||
|
||||
class _AlarmCardState extends TbContextState<AlarmCard, _AlarmCardState> {
|
||||
class _AlarmCardState extends TbContextState<AlarmCard> {
|
||||
|
||||
bool loading = false;
|
||||
AlarmInfo alarm;
|
||||
|
||||
@@ -6,7 +6,7 @@ import 'package:thingsboard_app/widgets/tb_app_bar.dart';
|
||||
|
||||
import 'alarms_list.dart';
|
||||
|
||||
class AlarmsPage extends TbContextWidget<AlarmsPage, _AlarmsPageState> {
|
||||
class AlarmsPage extends TbContextWidget {
|
||||
|
||||
final bool searchMode;
|
||||
|
||||
@@ -17,7 +17,7 @@ class AlarmsPage extends TbContextWidget<AlarmsPage, _AlarmsPageState> {
|
||||
|
||||
}
|
||||
|
||||
class _AlarmsPageState extends TbContextState<AlarmsPage, _AlarmsPageState> with AutomaticKeepAliveClientMixin<AlarmsPage> {
|
||||
class _AlarmsPageState extends TbContextState<AlarmsPage> with AutomaticKeepAliveClientMixin<AlarmsPage> {
|
||||
|
||||
final AlarmQueryController _alarmQueryController = AlarmQueryController();
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ import 'package:thingsboard_app/widgets/tb_app_bar.dart';
|
||||
|
||||
import 'assets_list.dart';
|
||||
|
||||
class AssetsPage extends TbPageWidget<AssetsPage, _AssetsPageState> {
|
||||
class AssetsPage extends TbPageWidget {
|
||||
|
||||
final bool searchMode;
|
||||
|
||||
@@ -17,7 +17,7 @@ class AssetsPage extends TbPageWidget<AssetsPage, _AssetsPageState> {
|
||||
|
||||
}
|
||||
|
||||
class _AssetsPageState extends TbPageState<AssetsPage, _AssetsPageState> {
|
||||
class _AssetsPageState extends TbPageState<AssetsPage> {
|
||||
|
||||
final PageLinkController _pageLinkController = PageLinkController();
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ import 'package:thingsboard_app/modules/audit_log/audit_logs_base.dart';
|
||||
import 'package:thingsboard_app/widgets/tb_app_bar.dart';
|
||||
import 'package:thingsboard_client/thingsboard_client.dart';
|
||||
|
||||
class AuditLogDetailsPage extends TbContextWidget<AuditLogDetailsPage, _AuditLogDetailsPageState> {
|
||||
class AuditLogDetailsPage extends TbContextWidget {
|
||||
|
||||
final AuditLog auditLog;
|
||||
|
||||
@@ -19,7 +19,7 @@ class AuditLogDetailsPage extends TbContextWidget<AuditLogDetailsPage, _AuditLog
|
||||
|
||||
}
|
||||
|
||||
class _AuditLogDetailsPageState extends TbContextState<AuditLogDetailsPage, _AuditLogDetailsPageState> {
|
||||
class _AuditLogDetailsPageState extends TbContextState<AuditLogDetailsPage> {
|
||||
|
||||
final labelTextStyle = TextStyle(
|
||||
color: Color(0xFF757575),
|
||||
|
||||
@@ -72,7 +72,7 @@ mixin AuditLogsBase on EntitiesBase<AuditLog, TimePageLink> {
|
||||
}
|
||||
}
|
||||
|
||||
class AuditLogCard extends TbContextWidget<AuditLogCard, _AuditLogCardState> {
|
||||
class AuditLogCard extends TbContextWidget {
|
||||
|
||||
final AuditLog auditLog;
|
||||
|
||||
@@ -83,7 +83,7 @@ class AuditLogCard extends TbContextWidget<AuditLogCard, _AuditLogCardState> {
|
||||
|
||||
}
|
||||
|
||||
class _AuditLogCardState extends TbContextState<AuditLogCard, _AuditLogCardState> {
|
||||
class _AuditLogCardState extends TbContextState<AuditLogCard> {
|
||||
|
||||
final entityDateFormat = DateFormat('yyyy-MM-dd');
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ import 'package:thingsboard_app/core/entity/entities_base.dart';
|
||||
import 'package:thingsboard_app/modules/audit_log/audit_logs_list.dart';
|
||||
import 'package:thingsboard_app/widgets/tb_app_bar.dart';
|
||||
|
||||
class AuditLogsPage extends TbPageWidget<AuditLogsPage, _AuditLogsPageState> {
|
||||
class AuditLogsPage extends TbPageWidget {
|
||||
|
||||
final bool searchMode;
|
||||
|
||||
@@ -16,7 +16,7 @@ class AuditLogsPage extends TbPageWidget<AuditLogsPage, _AuditLogsPageState> {
|
||||
|
||||
}
|
||||
|
||||
class _AuditLogsPageState extends TbPageState<AuditLogsPage, _AuditLogsPageState> {
|
||||
class _AuditLogsPageState extends TbPageState<AuditLogsPage> {
|
||||
|
||||
final TimePageLinkController _timePageLinkController = TimePageLinkController();
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ import 'package:thingsboard_app/core/entity/entities_base.dart';
|
||||
import 'package:thingsboard_app/modules/customer/customers_list.dart';
|
||||
import 'package:thingsboard_app/widgets/tb_app_bar.dart';
|
||||
|
||||
class CustomersPage extends TbPageWidget<CustomersPage, _CustomersPageState> {
|
||||
class CustomersPage extends TbPageWidget {
|
||||
|
||||
final bool searchMode;
|
||||
|
||||
@@ -16,7 +16,7 @@ class CustomersPage extends TbPageWidget<CustomersPage, _CustomersPageState> {
|
||||
|
||||
}
|
||||
|
||||
class _CustomersPageState extends TbPageState<CustomersPage, _CustomersPageState> {
|
||||
class _CustomersPageState extends TbPageState<CustomersPage> {
|
||||
|
||||
final PageLinkController _pageLinkController = PageLinkController();
|
||||
|
||||
|
||||
@@ -10,6 +10,7 @@ import 'package:thingsboard_app/core/context/tb_context.dart';
|
||||
import 'package:thingsboard_app/core/context/tb_context_widget.dart';
|
||||
import 'package:thingsboard_app/widgets/tb_progress_indicator.dart';
|
||||
import 'package:thingsboard_app/widgets/two_value_listenable_builder.dart';
|
||||
import 'package:universal_platform/universal_platform.dart';
|
||||
import 'package:url_launcher/url_launcher.dart';
|
||||
|
||||
class DashboardController {
|
||||
@@ -65,7 +66,7 @@ typedef DashboardTitleCallback = void Function(String title);
|
||||
|
||||
typedef DashboardControllerCallback = void Function(DashboardController controller);
|
||||
|
||||
class Dashboard extends TbContextWidget<Dashboard, _DashboardState> {
|
||||
class Dashboard extends TbContextWidget {
|
||||
|
||||
final bool? _home;
|
||||
final bool _activeByDefault;
|
||||
@@ -84,7 +85,7 @@ class Dashboard extends TbContextWidget<Dashboard, _DashboardState> {
|
||||
|
||||
}
|
||||
|
||||
class _DashboardState extends TbContextState<Dashboard, _DashboardState> {
|
||||
class _DashboardState extends TbContextState<Dashboard> {
|
||||
|
||||
final Completer<InAppWebViewController> _controller = Completer<InAppWebViewController>();
|
||||
|
||||
@@ -145,21 +146,27 @@ class _DashboardState extends TbContextState<Dashboard, _DashboardState> {
|
||||
'refreshToken': tbClient.getRefreshToken()!
|
||||
}
|
||||
};
|
||||
var controller = await _controller.future;
|
||||
await controller.postWebMessage(message: WebMessage(data: jsonEncode(windowMessage)), targetOrigin: Uri.parse('*'));
|
||||
if (!UniversalPlatform.isWeb) {
|
||||
var controller = await _controller.future;
|
||||
await controller.postWebMessage(
|
||||
message: WebMessage(data: jsonEncode(windowMessage)),
|
||||
targetOrigin: Uri.parse('*'));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Future<bool> _goBack() async {
|
||||
if (_dashboardController.rightLayoutOpened.value) {
|
||||
await _toggleRightLayout();
|
||||
return false;
|
||||
}
|
||||
var controller = await _controller.future;
|
||||
if (await controller.canGoBack()) {
|
||||
await controller.goBack();
|
||||
return false;
|
||||
if (!UniversalPlatform.isWeb) {
|
||||
if (_dashboardController.rightLayoutOpened.value) {
|
||||
await _toggleRightLayout();
|
||||
return false;
|
||||
}
|
||||
var controller = await _controller.future;
|
||||
if (await controller.canGoBack()) {
|
||||
await controller.goBack();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
@@ -188,7 +195,10 @@ class _DashboardState extends TbContextState<Dashboard, _DashboardState> {
|
||||
Future<void> _openDashboard(String dashboardId, {String? state, bool? hideToolbar, bool fullscreen = false}) async {
|
||||
_fullscreen = fullscreen;
|
||||
dashboardLoading.value = true;
|
||||
var controller = await _controller.future;
|
||||
InAppWebViewController? controller;
|
||||
if (!UniversalPlatform.isWeb) {
|
||||
controller = await _controller.future;
|
||||
}
|
||||
var windowMessage = <String, dynamic>{
|
||||
'type': 'openDashboardMessage',
|
||||
'data': <String, dynamic>{
|
||||
@@ -205,7 +215,10 @@ class _DashboardState extends TbContextState<Dashboard, _DashboardState> {
|
||||
windowMessage['data']['hideToolbar'] = true;
|
||||
}
|
||||
var webMessage = WebMessage(data: jsonEncode(windowMessage));
|
||||
await controller.postWebMessage(message: webMessage, targetOrigin: Uri.parse('*'));
|
||||
if (!UniversalPlatform.isWeb) {
|
||||
await controller!.postWebMessage(
|
||||
message: webMessage, targetOrigin: Uri.parse('*'));
|
||||
}
|
||||
}
|
||||
|
||||
Future<void> _toggleRightLayout() async {
|
||||
@@ -239,6 +252,7 @@ class _DashboardState extends TbContextState<Dashboard, _DashboardState> {
|
||||
} else {
|
||||
return Stack(
|
||||
children: [
|
||||
UniversalPlatform.isWeb ? Center(child: Text('Not implemented!')) :
|
||||
InAppWebView(
|
||||
key: webViewKey,
|
||||
initialUrlRequest: URLRequest(url: _initialUrl),
|
||||
@@ -348,7 +362,8 @@ class _DashboardState extends TbContextState<Dashboard, _DashboardState> {
|
||||
action: PermissionRequestResponseAction.GRANT);
|
||||
},
|
||||
),
|
||||
TwoValueListenableBuilder(
|
||||
if (!UniversalPlatform.isWeb)
|
||||
TwoValueListenableBuilder(
|
||||
firstValueListenable: dashboardLoading,
|
||||
secondValueListenable: dashboardActive,
|
||||
builder: (BuildContext context, bool loading, bool active, child) {
|
||||
|
||||
@@ -5,7 +5,7 @@ import 'package:thingsboard_app/core/context/tb_context_widget.dart';
|
||||
import 'package:thingsboard_app/modules/dashboard/dashboard.dart';
|
||||
import 'package:thingsboard_app/widgets/tb_app_bar.dart';
|
||||
|
||||
class DashboardPage extends TbPageWidget<DashboardPage, _DashboardPageState> {
|
||||
class DashboardPage extends TbPageWidget {
|
||||
|
||||
final String? _dashboardTitle;
|
||||
final String? _dashboardId;
|
||||
@@ -24,7 +24,7 @@ class DashboardPage extends TbPageWidget<DashboardPage, _DashboardPageState> {
|
||||
|
||||
}
|
||||
|
||||
class _DashboardPageState extends TbPageState<DashboardPage, _DashboardPageState> {
|
||||
class _DashboardPageState extends TbPageState<DashboardPage> {
|
||||
|
||||
late ValueNotifier<String> dashboardTitleValue;
|
||||
|
||||
|
||||
@@ -127,7 +127,7 @@ mixin DashboardsBase on EntitiesBase<DashboardInfo, PageLink> {
|
||||
|
||||
}
|
||||
|
||||
class DashboardGridCard extends TbContextWidget<DashboardGridCard, _DashboardGridCardState> {
|
||||
class DashboardGridCard extends TbContextWidget {
|
||||
|
||||
final DashboardInfo dashboard;
|
||||
|
||||
@@ -138,7 +138,7 @@ class DashboardGridCard extends TbContextWidget<DashboardGridCard, _DashboardGri
|
||||
|
||||
}
|
||||
|
||||
class _DashboardGridCardState extends TbContextState<DashboardGridCard, _DashboardGridCardState> {
|
||||
class _DashboardGridCardState extends TbContextState<DashboardGridCard> {
|
||||
|
||||
_DashboardGridCardState(): super();
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ import 'package:thingsboard_client/thingsboard_client.dart';
|
||||
|
||||
import 'dashboards_base.dart';
|
||||
|
||||
class DashboardsGridWidget extends TbContextWidget<DashboardsGridWidget, _DashboardsGridWidgetState> {
|
||||
class DashboardsGridWidget extends TbContextWidget {
|
||||
|
||||
DashboardsGridWidget(TbContext tbContext) : super(tbContext);
|
||||
|
||||
@@ -16,7 +16,7 @@ class DashboardsGridWidget extends TbContextWidget<DashboardsGridWidget, _Dashbo
|
||||
|
||||
}
|
||||
|
||||
class _DashboardsGridWidgetState extends TbContextState<DashboardsGridWidget, _DashboardsGridWidgetState> {
|
||||
class _DashboardsGridWidgetState extends TbContextState<DashboardsGridWidget> {
|
||||
|
||||
final PageLinkController _pageLinkController = PageLinkController();
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ import 'package:thingsboard_app/widgets/tb_app_bar.dart';
|
||||
|
||||
import 'dashboards_grid.dart';
|
||||
|
||||
class DashboardsPage extends TbPageWidget<DashboardsPage, _DashboardsPageState> {
|
||||
class DashboardsPage extends TbPageWidget {
|
||||
|
||||
DashboardsPage(TbContext tbContext) : super(tbContext);
|
||||
|
||||
@@ -14,7 +14,7 @@ class DashboardsPage extends TbPageWidget<DashboardsPage, _DashboardsPageState>
|
||||
|
||||
}
|
||||
|
||||
class _DashboardsPageState extends TbPageState<DashboardsPage, _DashboardsPageState> {
|
||||
class _DashboardsPageState extends TbPageState<DashboardsPage> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
||||
@@ -5,7 +5,7 @@ import 'package:thingsboard_app/core/context/tb_context_widget.dart';
|
||||
import 'package:thingsboard_app/modules/dashboard/dashboard.dart';
|
||||
import 'package:thingsboard_app/widgets/tb_app_bar.dart';
|
||||
|
||||
class FullscreenDashboardPage extends TbPageWidget<FullscreenDashboardPage, _FullscreenDashboardPageState> {
|
||||
class FullscreenDashboardPage extends TbPageWidget {
|
||||
|
||||
final String fullscreenDashboardId;
|
||||
final String? _dashboardTitle;
|
||||
@@ -19,7 +19,7 @@ class FullscreenDashboardPage extends TbPageWidget<FullscreenDashboardPage, _Ful
|
||||
|
||||
}
|
||||
|
||||
class _FullscreenDashboardPageState extends TbPageState<FullscreenDashboardPage, _FullscreenDashboardPageState> {
|
||||
class _FullscreenDashboardPageState extends TbPageState<FullscreenDashboardPage> {
|
||||
|
||||
late ValueNotifier<String> dashboardTitleValue;
|
||||
final ValueNotifier<bool> showBackValue = ValueNotifier(false);
|
||||
|
||||
@@ -43,7 +43,7 @@ class MainDashboardPageController {
|
||||
|
||||
}
|
||||
|
||||
class MainDashboardPage extends TbContextWidget<MainDashboardPage, _MainDashboardPageState> {
|
||||
class MainDashboardPage extends TbContextWidget {
|
||||
|
||||
final String? _dashboardTitle;
|
||||
final MainDashboardPageController? _controller;
|
||||
@@ -60,7 +60,7 @@ class MainDashboardPage extends TbContextWidget<MainDashboardPage, _MainDashboar
|
||||
|
||||
}
|
||||
|
||||
class _MainDashboardPageState extends TbContextState<MainDashboardPage, _MainDashboardPageState> with TickerProviderStateMixin {
|
||||
class _MainDashboardPageState extends TbContextState<MainDashboardPage> with TickerProviderStateMixin {
|
||||
|
||||
late ValueNotifier<String> dashboardTitleValue;
|
||||
final ValueNotifier<bool> hasRightLayout = ValueNotifier(false);
|
||||
|
||||
@@ -63,7 +63,7 @@ class RefreshDeviceCounts {
|
||||
Future<void> Function()? onRefresh;
|
||||
}
|
||||
|
||||
class AllDevicesCard extends TbContextWidget<AllDevicesCard, _AllDevicesCardState> {
|
||||
class AllDevicesCard extends TbContextWidget {
|
||||
|
||||
final RefreshDeviceCounts refreshDeviceCounts;
|
||||
|
||||
@@ -74,7 +74,7 @@ class AllDevicesCard extends TbContextWidget<AllDevicesCard, _AllDevicesCardStat
|
||||
|
||||
}
|
||||
|
||||
class _AllDevicesCardState extends TbContextState<AllDevicesCard, _AllDevicesCardState> {
|
||||
class _AllDevicesCardState extends TbContextState<AllDevicesCard> {
|
||||
|
||||
final StreamController<int?> _activeDevicesCount = StreamController.broadcast();
|
||||
final StreamController<int?> _inactiveDevicesCount = StreamController.broadcast();
|
||||
@@ -240,7 +240,7 @@ class _AllDevicesCardState extends TbContextState<AllDevicesCard, _AllDevicesCar
|
||||
|
||||
}
|
||||
|
||||
class DeviceProfileCard extends TbContextWidget<DeviceProfileCard, _DeviceProfileCardState> {
|
||||
class DeviceProfileCard extends TbContextWidget {
|
||||
|
||||
final DeviceProfileInfo deviceProfile;
|
||||
|
||||
@@ -251,7 +251,7 @@ class DeviceProfileCard extends TbContextWidget<DeviceProfileCard, _DeviceProfil
|
||||
|
||||
}
|
||||
|
||||
class _DeviceProfileCardState extends TbContextState<DeviceProfileCard, _DeviceProfileCardState> {
|
||||
class _DeviceProfileCardState extends TbContextState<DeviceProfileCard> {
|
||||
|
||||
late Future<int> activeDevicesCount;
|
||||
late Future<int> inactiveDevicesCount;
|
||||
|
||||
@@ -78,7 +78,7 @@ class DeviceQueryController extends PageKeyController<EntityDataQuery> {
|
||||
|
||||
}
|
||||
|
||||
class DeviceCard extends TbContextWidget<DeviceCard, _DeviceCardState> {
|
||||
class DeviceCard extends TbContextWidget {
|
||||
|
||||
final EntityData device;
|
||||
final bool listWidgetCard;
|
||||
@@ -91,7 +91,7 @@ class DeviceCard extends TbContextWidget<DeviceCard, _DeviceCardState> {
|
||||
|
||||
}
|
||||
|
||||
class _DeviceCardState extends TbContextState<DeviceCard, _DeviceCardState> {
|
||||
class _DeviceCardState extends TbContextState<DeviceCard> {
|
||||
|
||||
final entityDateFormat = DateFormat('yyyy-MM-dd');
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ import 'package:thingsboard_app/modules/device/devices_base.dart';
|
||||
import 'package:thingsboard_app/modules/device/devices_list.dart';
|
||||
import 'package:thingsboard_app/widgets/tb_app_bar.dart';
|
||||
|
||||
class DevicesListPage extends TbPageWidget<DevicesListPage, _DevicesListPageState> {
|
||||
class DevicesListPage extends TbPageWidget {
|
||||
|
||||
final String? deviceType;
|
||||
final bool? active;
|
||||
@@ -18,7 +18,7 @@ class DevicesListPage extends TbPageWidget<DevicesListPage, _DevicesListPageStat
|
||||
|
||||
}
|
||||
|
||||
class _DevicesListPageState extends TbPageState<DevicesListPage, _DevicesListPageState> {
|
||||
class _DevicesListPageState extends TbPageState<DevicesListPage> {
|
||||
|
||||
late final DeviceQueryController _deviceQueryController;
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ import 'package:thingsboard_app/core/entity/entities_base.dart';
|
||||
import 'package:thingsboard_app/modules/device/device_profiles_grid.dart';
|
||||
import 'package:thingsboard_app/widgets/tb_app_bar.dart';
|
||||
|
||||
class DevicesMainPage extends TbContextWidget<DevicesMainPage, _DevicesMainPageState> {
|
||||
class DevicesMainPage extends TbContextWidget {
|
||||
|
||||
DevicesMainPage(TbContext tbContext) : super(tbContext);
|
||||
|
||||
@@ -14,7 +14,7 @@ class DevicesMainPage extends TbContextWidget<DevicesMainPage, _DevicesMainPageS
|
||||
|
||||
}
|
||||
|
||||
class _DevicesMainPageState extends TbContextState<DevicesMainPage, _DevicesMainPageState> with AutomaticKeepAliveClientMixin<DevicesMainPage> {
|
||||
class _DevicesMainPageState extends TbContextState<DevicesMainPage> with AutomaticKeepAliveClientMixin<DevicesMainPage> {
|
||||
|
||||
final PageLinkController _pageLinkController = PageLinkController();
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ import 'package:thingsboard_app/core/entity/entities_base.dart';
|
||||
import 'package:thingsboard_app/modules/device/device_profiles_grid.dart';
|
||||
import 'package:thingsboard_app/widgets/tb_app_bar.dart';
|
||||
|
||||
class DevicesPage extends TbPageWidget<DevicesPage, _DevicesPageState> {
|
||||
class DevicesPage extends TbPageWidget {
|
||||
|
||||
DevicesPage(TbContext tbContext) : super(tbContext);
|
||||
|
||||
@@ -14,7 +14,7 @@ class DevicesPage extends TbPageWidget<DevicesPage, _DevicesPageState> {
|
||||
|
||||
}
|
||||
|
||||
class _DevicesPageState extends TbPageState<DevicesPage, _DevicesPageState> {
|
||||
class _DevicesPageState extends TbPageState<DevicesPage> {
|
||||
|
||||
final PageLinkController _pageLinkController = PageLinkController();
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ import 'package:thingsboard_app/modules/tenant/tenants_widget.dart';
|
||||
import 'package:thingsboard_app/widgets/tb_app_bar.dart';
|
||||
import 'package:thingsboard_client/thingsboard_client.dart';
|
||||
|
||||
class HomePage extends TbContextWidget<HomePage, _HomePageState> {
|
||||
class HomePage extends TbContextWidget {
|
||||
|
||||
HomePage(TbContext tbContext) : super(tbContext);
|
||||
|
||||
@@ -19,7 +19,7 @@ class HomePage extends TbContextWidget<HomePage, _HomePageState> {
|
||||
|
||||
}
|
||||
|
||||
class _HomePageState extends TbContextState<HomePage, _HomePageState> with AutomaticKeepAliveClientMixin<HomePage> {
|
||||
class _HomePageState extends TbContextState<HomePage> with AutomaticKeepAliveClientMixin<HomePage> {
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
@@ -94,7 +94,7 @@ class _HomePageState extends TbContextState<HomePage, _HomePageState> with Autom
|
||||
|
||||
}
|
||||
|
||||
class HomeDashboard extends TbContextWidget<HomeDashboard, _HomeDashboardState> {
|
||||
class HomeDashboard extends TbContextWidget {
|
||||
|
||||
final HomeDashboardInfo dashboard;
|
||||
|
||||
@@ -105,7 +105,7 @@ class HomeDashboard extends TbContextWidget<HomeDashboard, _HomeDashboardState>
|
||||
|
||||
}
|
||||
|
||||
class _HomeDashboardState extends TbContextState<HomeDashboard, _HomeDashboardState> {
|
||||
class _HomeDashboardState extends TbContextState<HomeDashboard> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
||||
@@ -85,7 +85,7 @@ class TbMainNavigationItem {
|
||||
}
|
||||
}
|
||||
|
||||
class MainPage extends TbPageWidget<MainPage, _MainPageState> {
|
||||
class MainPage extends TbPageWidget {
|
||||
|
||||
final String _path;
|
||||
|
||||
@@ -97,7 +97,7 @@ class MainPage extends TbPageWidget<MainPage, _MainPageState> {
|
||||
|
||||
}
|
||||
|
||||
class _MainPageState extends TbPageState<MainPage, _MainPageState> with TbMainState, TickerProviderStateMixin {
|
||||
class _MainPageState extends TbPageState<MainPage> with TbMainState, TickerProviderStateMixin {
|
||||
|
||||
late ValueNotifier<int> _currentIndexNotifier;
|
||||
late final List<TbMainNavigationItem> _tabItems;
|
||||
|
||||
@@ -3,7 +3,7 @@ import 'package:thingsboard_app/core/context/tb_context.dart';
|
||||
import 'package:thingsboard_app/core/context/tb_context_widget.dart';
|
||||
import 'package:thingsboard_client/thingsboard_client.dart';
|
||||
|
||||
class MorePage extends TbContextWidget<MorePage, _MorePageState> {
|
||||
class MorePage extends TbContextWidget {
|
||||
|
||||
MorePage(TbContext tbContext) : super(tbContext);
|
||||
|
||||
@@ -12,7 +12,7 @@ class MorePage extends TbContextWidget<MorePage, _MorePageState> {
|
||||
|
||||
}
|
||||
|
||||
class _MorePageState extends TbContextState<MorePage, _MorePageState> {
|
||||
class _MorePageState extends TbContextState<MorePage> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
||||
@@ -5,7 +5,7 @@ import 'package:thingsboard_app/core/context/tb_context_widget.dart';
|
||||
import 'package:thingsboard_app/widgets/tb_app_bar.dart';
|
||||
import 'package:thingsboard_app/widgets/tb_progress_indicator.dart';
|
||||
|
||||
class ChangePasswordPage extends TbContextWidget<ChangePasswordPage, _ChangePasswordPageState> {
|
||||
class ChangePasswordPage extends TbContextWidget {
|
||||
|
||||
ChangePasswordPage(TbContext tbContext) : super(tbContext);
|
||||
|
||||
@@ -14,7 +14,7 @@ class ChangePasswordPage extends TbContextWidget<ChangePasswordPage, _ChangePass
|
||||
|
||||
}
|
||||
|
||||
class _ChangePasswordPageState extends TbContextState<ChangePasswordPage, _ChangePasswordPageState> {
|
||||
class _ChangePasswordPageState extends TbContextState<ChangePasswordPage> {
|
||||
|
||||
final _isLoadingNotifier = ValueNotifier<bool>(false);
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@ import 'package:thingsboard_app/core/context/tb_context_widget.dart';
|
||||
import 'package:thingsboard_app/widgets/tb_progress_indicator.dart';
|
||||
import 'package:thingsboard_client/thingsboard_client.dart';
|
||||
|
||||
class ProfilePage extends TbPageWidget<ProfilePage, _ProfilePageState> {
|
||||
class ProfilePage extends TbPageWidget {
|
||||
|
||||
final bool _fullscreen;
|
||||
|
||||
@@ -20,7 +20,7 @@ class ProfilePage extends TbPageWidget<ProfilePage, _ProfilePageState> {
|
||||
|
||||
}
|
||||
|
||||
class _ProfilePageState extends TbPageState<ProfilePage, _ProfilePageState> {
|
||||
class _ProfilePageState extends TbPageState<ProfilePage> {
|
||||
|
||||
final _isLoadingNotifier = ValueNotifier<bool>(true);
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@ import 'package:thingsboard_app/widgets/tb_app_bar.dart';
|
||||
|
||||
import 'tenants_list.dart';
|
||||
|
||||
class TenantsPage extends TbPageWidget<TenantsPage, _TenantsPageState> {
|
||||
class TenantsPage extends TbPageWidget {
|
||||
|
||||
final bool searchMode;
|
||||
|
||||
@@ -17,7 +17,7 @@ class TenantsPage extends TbPageWidget<TenantsPage, _TenantsPageState> {
|
||||
|
||||
}
|
||||
|
||||
class _TenantsPageState extends TbPageState<TenantsPage, _TenantsPageState> {
|
||||
class _TenantsPageState extends TbPageState<TenantsPage> {
|
||||
|
||||
final PageLinkController _pageLinkController = PageLinkController();
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@ import 'package:thingsboard_app/core/entity/entities_base.dart';
|
||||
|
||||
import 'tenants_list.dart';
|
||||
|
||||
class TenantsWidget extends TbContextWidget<TenantsWidget, _TenantsWidgetState> {
|
||||
class TenantsWidget extends TbContextWidget {
|
||||
|
||||
TenantsWidget(TbContext tbContext) : super(tbContext);
|
||||
|
||||
@@ -14,7 +14,7 @@ class TenantsWidget extends TbContextWidget<TenantsWidget, _TenantsWidgetState>
|
||||
|
||||
}
|
||||
|
||||
class _TenantsWidgetState extends TbContextState<TenantsWidget, _TenantsWidgetState> {
|
||||
class _TenantsWidgetState extends TbContextState<TenantsWidget> {
|
||||
|
||||
final PageLinkController _pageLinkController = PageLinkController();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user