You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

44 lines
1.4KB

  1. import 'package:farm_tpf/presentation/screens/actions/nursery/sc_nursery.dart';
  2. import 'package:farm_tpf/presentation/screens/actions/plant/sc_plant.dart';
  3. import 'package:farm_tpf/presentation/screens/plot_detail/sc_plot_detail.dart';
  4. import 'package:flutter/material.dart';
  5. class HomePage extends StatelessWidget {
  6. static Route route() {
  7. return MaterialPageRoute<void>(builder: (_) => HomePage());
  8. }
  9. @override
  10. Widget build(BuildContext context) {
  11. return Scaffold(
  12. appBar: AppBar(title: const Text('Home')),
  13. body: Center(
  14. child: Column(
  15. mainAxisSize: MainAxisSize.min,
  16. children: <Widget>[
  17. Text("logged in."),
  18. MaterialButton(
  19. child: Text("Nursery action"),
  20. onPressed: () {
  21. Navigator.of(context).push(
  22. MaterialPageRoute(builder: (_) => ActionNurseryScreen()));
  23. }),
  24. MaterialButton(
  25. child: Text("Plant action"),
  26. onPressed: () {
  27. Navigator.of(context).push(
  28. MaterialPageRoute(builder: (_) => ActionPlantScreen()));
  29. }),
  30. MaterialButton(
  31. child: Text("Chi tiết lô"),
  32. onPressed: () {
  33. Navigator.of(context).push(
  34. MaterialPageRoute(builder: (_) => PlotDetailScreen()));
  35. }),
  36. ],
  37. ),
  38. ),
  39. );
  40. }
  41. }