Payment page but not finish yet
This commit is contained in:
parent
11a9d0fb25
commit
48c368b0be
4 changed files with 71 additions and 3 deletions
|
@ -5,6 +5,7 @@ import 'dart:math' as math;
|
|||
import 'package:nekoya_flutter/screens/products.dart';
|
||||
import 'package:nekoya_flutter/screens/register.dart';
|
||||
import 'package:nekoya_flutter/screens/checkout.dart';
|
||||
import 'package:nekoya_flutter/screens/payment.dart';
|
||||
|
||||
class Menu extends StatefulWidget {
|
||||
const Menu({Key? key}) : super(key: key);
|
||||
|
@ -48,7 +49,7 @@ class _MenuState extends State<Menu> {
|
|||
if (index == 0) {
|
||||
_selectedWidget = const Login();
|
||||
} else if (index == 1) {
|
||||
_selectedWidget = const Products();
|
||||
_selectedWidget = const Payment();
|
||||
} else if (index == 2) {
|
||||
_selectedWidget = const Products();
|
||||
} else if (index == 3) {
|
||||
|
|
43
lib/components/payment_body.dart
Normal file
43
lib/components/payment_body.dart
Normal file
|
@ -0,0 +1,43 @@
|
|||
import 'package:flutter/material.dart';
|
||||
|
||||
class PaymentBody extends StatefulWidget {
|
||||
const PaymentBody({Key? key}) : super(key: key);
|
||||
|
||||
@override
|
||||
State<PaymentBody> createState() => _PaymentBodyState();
|
||||
}
|
||||
|
||||
class _PaymentBodyState extends State<PaymentBody> {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Container(
|
||||
constraints: BoxConstraints.expand(height: 150.0),
|
||||
decoration: BoxDecoration(color: Colors.transparent),
|
||||
child: Column(
|
||||
children: [
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
|
||||
children: [
|
||||
Image.asset(
|
||||
'assets/bca.webp',
|
||||
cacheHeight: 40,
|
||||
cacheWidth: 100,
|
||||
),
|
||||
Image.asset(
|
||||
'assets/bni.webp',
|
||||
cacheHeight: 40,
|
||||
cacheWidth: 100,
|
||||
),
|
||||
Image.asset(
|
||||
'assets/bri.webp',
|
||||
cacheHeight: 40,
|
||||
cacheWidth: 100,
|
||||
),
|
||||
],
|
||||
),
|
||||
Row(),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
|
@ -20,7 +20,8 @@ class MyApp extends StatelessWidget {
|
|||
Widget build(BuildContext context) {
|
||||
return MaterialApp(
|
||||
theme: ThemeData(
|
||||
colorScheme: ColorScheme.fromSwatch(accentColor: const Color(0xff8B0000))),
|
||||
colorScheme:
|
||||
ColorScheme.fromSwatch(accentColor: const Color(0xff8B0000))),
|
||||
home: AnimatedSplashScreen(
|
||||
splash: 'assets/logo_transparent.webp',
|
||||
pageTransitionType: PageTransitionType.fade,
|
||||
|
@ -31,4 +32,4 @@ class MyApp extends StatelessWidget {
|
|||
debugShowCheckedModeBanner: false,
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
23
lib/screens/payment.dart
Normal file
23
lib/screens/payment.dart
Normal file
|
@ -0,0 +1,23 @@
|
|||
import 'package:flutter/material.dart';
|
||||
import 'package:nekoya_flutter/components/payment_body.dart';
|
||||
|
||||
class Payment extends StatefulWidget {
|
||||
const Payment({Key? key}) : super(key: key);
|
||||
|
||||
@override
|
||||
State<Payment> createState() => _PaymentState();
|
||||
}
|
||||
|
||||
class _PaymentState extends State<Payment> {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
backgroundColor: const Color(0xff1b1c1e),
|
||||
appBar: AppBar(
|
||||
title: const Text('Payment'),
|
||||
centerTitle: true,
|
||||
backgroundColor: const Color(0xff212226),
|
||||
),
|
||||
body: PaymentBody());
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue