|
@@ -7,6 +7,7 @@ import 'package:turquessa_mesas_hoster/utils/widgets/custom_appbar.dart';
|
|
|
import 'package:turquessa_mesas_hoster/mvvm/views/home/categorias_navbar.dart';
|
|
|
import 'package:turquessa_mesas_hoster/mvvm/viewmodels/home_view_model.dart';
|
|
|
import 'package:turquessa_mesas_hoster/utils/widgets/modal_infonegaocio.dart';
|
|
|
+import 'package:turquessa_mesas_hoster/mvvm/views/home/producto/producto_screen.dart';
|
|
|
|
|
|
const List<Map<String, dynamic>> items = [
|
|
|
{
|
|
@@ -124,6 +125,32 @@ class _HomeScreenState extends State<HomeScreen> {
|
|
|
final homeViewModel = Provider.of<HomeViewModel>(context);
|
|
|
final pedidoViewModel = Provider.of<ProductoViewModel>(context);
|
|
|
return Scaffold(
|
|
|
+ bottomNavigationBar: BottomAppBar(
|
|
|
+ color: Colors.black,
|
|
|
+ child: Row(
|
|
|
+ mainAxisAlignment: MainAxisAlignment.spaceAround,
|
|
|
+ children: [
|
|
|
+ IconButton(
|
|
|
+ icon: const Icon(Icons.search, color: Colors.white),
|
|
|
+ onPressed: () {},
|
|
|
+ ),
|
|
|
+ IconButton(
|
|
|
+ icon: const Icon(Icons.menu, color: Colors.white),
|
|
|
+ onPressed: () {},
|
|
|
+ ),
|
|
|
+ const Text(
|
|
|
+ 'Producto',
|
|
|
+ style: TextStyle(
|
|
|
+ color: Colors.cyanAccent,
|
|
|
+ fontWeight: FontWeight.bold,
|
|
|
+ ),
|
|
|
+ ),
|
|
|
+ IconButton(
|
|
|
+ icon: const Icon(Icons.favorite_border, color: Colors.white),
|
|
|
+ onPressed: () {},
|
|
|
+ ),
|
|
|
+ ],
|
|
|
+ )),
|
|
|
backgroundColor: Colors.white,
|
|
|
body: CustomScrollView(
|
|
|
slivers: [
|
|
@@ -191,7 +218,12 @@ class _HomeScreenState extends State<HomeScreen> {
|
|
|
),
|
|
|
const SliverToBoxAdapter(
|
|
|
child: Center(
|
|
|
- child: Text('Coffee', style: TextStyle(fontSize: 30)),
|
|
|
+ child: Text('Coffee',
|
|
|
+ style: TextStyle(
|
|
|
+ fontSize: 40,
|
|
|
+ fontWeight: FontWeight.bold,
|
|
|
+ fontStyle: FontStyle.italic,
|
|
|
+ )),
|
|
|
),
|
|
|
),
|
|
|
SliverList(
|
|
@@ -202,6 +234,7 @@ class _HomeScreenState extends State<HomeScreen> {
|
|
|
items[index]['descripcion'],
|
|
|
items[index]['precio'],
|
|
|
items[index]['imageUrl'],
|
|
|
+ context,
|
|
|
);
|
|
|
},
|
|
|
childCount: items.length,
|
|
@@ -231,10 +264,12 @@ class CategoriasSliverChild extends SliverPersistentHeaderDelegate {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-Widget _buildBurgerItem(
|
|
|
- String nombre, String descripcion, String precio, String imageUrl) {
|
|
|
+Widget _buildBurgerItem(String nombre, String descripcion, String precio,
|
|
|
+ String imageUrl, BuildContext context) {
|
|
|
return GestureDetector(
|
|
|
- onTap: () {},
|
|
|
+ onTap: () {
|
|
|
+ Navigator.of(context).pushNamed('producto');
|
|
|
+ },
|
|
|
child: Column(
|
|
|
children: [
|
|
|
Padding(
|