No Description

home.dart 1.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. import 'package:flutter/material.dart';
  2. class Home extends StatefulWidget{
  3. @override
  4. _HomeState createState() => _HomeState();
  5. }
  6. class _HomeState extends State<Home>{
  7. @override
  8. Widget build(BuildContext context){
  9. return Scaffold(
  10. appBar: AppBar(
  11. title: Text('Bienvenido'),
  12. centerTitle: true,
  13. ),
  14. body: Center(
  15. child: Column(
  16. mainAxisAlignment: MainAxisAlignment.spaceEvenly,
  17. children: [
  18. new FlatButton(
  19. minWidth: 300.0,
  20. height: 100.0,
  21. onPressed: (){
  22. Navigator.pushNamed(context, '/verOficinas');
  23. },
  24. child: Text('Ver Oficinas',
  25. style: TextStyle(fontSize: 36),
  26. ),
  27. color: Colors.purple,
  28. ),
  29. new FlatButton(
  30. minWidth: 300.0,
  31. height: 100.0,
  32. onPressed: (){
  33. Navigator.pushNamed(context, '/verOficinas');
  34. },
  35. child: Text('Otro boton',
  36. style: TextStyle(fontSize: 36),
  37. ),
  38. color: Colors.purple,
  39. ),
  40. new FlatButton(
  41. minWidth: 300.0,
  42. height: 100.0,
  43. onPressed: (){
  44. Navigator.pushNamed(context, '/calendario');
  45. },
  46. child: Text('Calendario',
  47. style: TextStyle(fontSize: 36),
  48. ),
  49. color: Colors.purple,
  50. ),
  51. ],
  52. ),
  53. ),
  54. );
  55. }
  56. }