AssetImage using

This commit is contained in:
2024-05-11 22:48:46 +03:00
parent b4092837d2
commit 57ff8a59e8
5 changed files with 28 additions and 12 deletions

View File

@@ -89,7 +89,10 @@ class _OrderConfirmationPageState extends State<OrderConfirmationPage> {
final item = cartItems[index];
return OrderConfirmItemCard(
name: item['name'],
image: Image.asset(item['image'], width: 50, height: 50),
image: Image(
image: AssetImage('assets/${item['image']}'),
width: 50,
height: 50),
price: double.parse(item['price']),
count: item['count'],
);
@@ -126,7 +129,16 @@ class _OrderConfirmationPageState extends State<OrderConfirmationPage> {
),
ElevatedButton(
onPressed: () {
debugPrint('Order confirmed');
print('debugprint');
// if (kIsWeb) {
// Navigator.of(context).push(
// MaterialPageRoute(
// builder: (context) => const OrderPayPage(),
// ),
// );
// } else {
// debugPrint('test');
// }
},
style: ElevatedButton.styleFrom(
backgroundColor: Theme.of(context).primaryColor,