Create LatestReport Page
This commit is contained in:
@@ -0,0 +1,51 @@
|
||||
import 'package:ac_web/Pages/LatestReports.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class MobileView extends StatefulWidget {
|
||||
const MobileView({super.key});
|
||||
|
||||
|
||||
@override
|
||||
State<StatefulWidget> createState() => MobileViewState();
|
||||
}
|
||||
|
||||
class MobileViewState extends State<MobileView> {
|
||||
|
||||
int currentPageIndex = 1;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
backgroundColor: Theme.of(context).colorScheme.inversePrimary,
|
||||
title: Text("AC Control"),
|
||||
),
|
||||
bottomNavigationBar: NavigationBar(
|
||||
onDestinationSelected: (int index) {
|
||||
setState(() {
|
||||
currentPageIndex = index;
|
||||
});
|
||||
},
|
||||
indicatorColor: Theme.of(context).colorScheme.inversePrimary,
|
||||
selectedIndex: currentPageIndex,
|
||||
destinations: [
|
||||
NavigationDestination(icon: Icon(Icons.newspaper), label: 'Reports'),
|
||||
NavigationDestination(icon: Icon(Icons.home), label: 'Latest Reports'),
|
||||
NavigationDestination(icon: Icon(Icons.adb), label: 'Agents')
|
||||
],
|
||||
),
|
||||
body: <Widget>[
|
||||
|
||||
// Homepage
|
||||
Text("Homepage"),
|
||||
|
||||
// Eighteen
|
||||
LatestReports(),
|
||||
|
||||
// Notifications
|
||||
Text("Notifications")
|
||||
][currentPageIndex],
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user