ticket added
This commit is contained in:
@@ -136,7 +136,7 @@ class AppText {
|
||||
static const String deposit = "Deposit";
|
||||
static const String withdrawal = "Withdrawal";
|
||||
static const String yield = "Yield";
|
||||
static const String refund = "REfund";
|
||||
static const String refund = "Refund";
|
||||
static const String investment = "Investment";
|
||||
static const String walletDetailsTitle = "Details";
|
||||
static const String withdrawalScreenTitle = 'Enter bank details';
|
||||
@@ -155,6 +155,7 @@ class AppText {
|
||||
static const String previewTitle = "Withdrawal confirmation";
|
||||
static const String info1 =
|
||||
'Please confirm the withdrawal amount and verify the accuracy of your bank details.';
|
||||
static const String workingDays = 'Processing times vary from 3-7 working days';
|
||||
static const String balance = 'Wallet balance: ';
|
||||
static const String withdrawTitle = 'Withdrawal';
|
||||
static const String depositTitle = 'Deposit';
|
||||
|
||||
@@ -3,6 +3,7 @@ import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||
import 'package:google_fonts/google_fonts.dart';
|
||||
import 'package:tanami_app/core/routes/routes.dart';
|
||||
import 'package:tanami_app/core/styles/app_text.dart';
|
||||
import 'package:ticket_widget/ticket_widget.dart';
|
||||
|
||||
import '../../../../../core/styles/app_color.dart';
|
||||
import '../../../../../shared/components/button_widget.dart';
|
||||
@@ -33,30 +34,6 @@ class WalletDetails extends StatelessWidget {
|
||||
'FRYU FHDU 1234',
|
||||
];
|
||||
|
||||
// final Map<String, String> data_deposit = {
|
||||
// AppText.paymentMethod: 'Google/Apple Pay',
|
||||
// AppText.accountName: 'Name Surname',
|
||||
// AppText.iban: 'DE 1234 5678 9012 3456',
|
||||
// AppText.beneficiaryAddress: 'Hohenzollernring 58, 95444',
|
||||
// AppText.bankName: 'Bank Name',
|
||||
// AppText.branchAddress: 'Hohenzollernring 58, 95444',
|
||||
// AppText.SWIFTcode: 'BC12345',
|
||||
// AppText.refid: 'FRYU FHDU 1234',
|
||||
// };
|
||||
// final Map<String, String> data_withdraw = {
|
||||
// AppText.status: 'On hold',
|
||||
// AppText.paymentMethod: 'Google/Apple Pay',
|
||||
// AppText.accountName: 'Name Surname',
|
||||
// AppText.iban: 'DE 1234 5678 9012 3456',
|
||||
// AppText.beneficiaryAddress: 'Hohenzollernring 58, 95444',
|
||||
// AppText.bankName: 'Bank Name',
|
||||
// AppText.branchAddress: 'Hohenzollernring 58, 95444',
|
||||
// AppText.SWIFTcode: 'BC12345',
|
||||
// AppText.refid: 'FRYU FHDU 1234',
|
||||
// };
|
||||
// final Map<String, String> data_invest = {
|
||||
// AppText.paymentMethod: 'Google/Apple Pay',
|
||||
// };
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
@@ -100,7 +77,8 @@ class WalletDetails extends StatelessWidget {
|
||||
icon: const Icon(
|
||||
Icons.cancel_outlined,
|
||||
color: Color(0xFF363636),
|
||||
))
|
||||
),
|
||||
)
|
||||
: const SizedBox()
|
||||
],
|
||||
scrolledUnderElevation: 0.0,
|
||||
@@ -116,123 +94,165 @@ class WalletDetails extends StatelessWidget {
|
||||
),
|
||||
),
|
||||
),
|
||||
body: Stack(
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(18.0),
|
||||
child: Container(
|
||||
width: double.infinity,
|
||||
decoration: BoxDecoration(
|
||||
borderRadius: BorderRadius.circular(22.r),
|
||||
color: Colors.white,
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
color: Colors.black.withOpacity(0.15),
|
||||
spreadRadius: 2,
|
||||
blurRadius: 10,
|
||||
offset: const Offset(0, 8), // changes position of shadow
|
||||
),
|
||||
],
|
||||
body: Padding(
|
||||
padding: const EdgeInsets.all(18.0),
|
||||
child: Container(
|
||||
decoration: BoxDecoration(
|
||||
borderRadius: BorderRadius.circular(22.r),
|
||||
color: (type == 'Yield' || type == 'Refund')
|
||||
? Colors.white
|
||||
: Colors.transparent,
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
color: Colors.black.withOpacity(0.15),
|
||||
spreadRadius: 2,
|
||||
blurRadius: 10,
|
||||
offset: const Offset(0, 8), // changes position of shadow
|
||||
),
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.fromLTRB(20.0, 30, 20, 10),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
],
|
||||
),
|
||||
child: (type == 'Yield' || type == 'Refund')
|
||||
? Padding(
|
||||
padding: const EdgeInsets.fromLTRB(20.0, 30, 20, 10),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
children: [
|
||||
getIcon(type),
|
||||
SizedBox(
|
||||
height: 16.h,
|
||||
),
|
||||
Text(
|
||||
type,
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF191B1E),
|
||||
fontSize: 14.sp,
|
||||
fontWeight: FontWeight.w600,
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
height: 4.h,
|
||||
),
|
||||
SizedBox(
|
||||
height: 4.h,
|
||||
),
|
||||
Text(
|
||||
'10/04/2024 22:04',
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF8D8D8D),
|
||||
fontSize: 11.sp,
|
||||
fontWeight: FontWeight.w500,
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
height: 16.h,
|
||||
),
|
||||
Text(
|
||||
'+ SAR 100,000',
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF191B1E),
|
||||
fontSize: 20.sp,
|
||||
fontWeight: FontWeight.w900,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
SizedBox(
|
||||
height: 35.h,
|
||||
),
|
||||
_buildBody(),
|
||||
],
|
||||
),
|
||||
)
|
||||
: TicketWidget(
|
||||
height: (type == 'Investment' || type == "confirm-investment")
|
||||
? 320.h
|
||||
: double.infinity,
|
||||
isCornerRounded: true,
|
||||
width: double.infinity,
|
||||
color: Colors.white,
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.fromLTRB(20.0, 30, 20, 10),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
getIcon(type),
|
||||
SizedBox(
|
||||
height: 16.h,
|
||||
),
|
||||
Text(
|
||||
type == "confirm-investment" ? "Investment" : type,
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF191B1E),
|
||||
fontSize: 14.sp,
|
||||
fontWeight: FontWeight.w600,
|
||||
),
|
||||
Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
children: [
|
||||
getIcon(type),
|
||||
SizedBox(
|
||||
height: 16.h,
|
||||
),
|
||||
Text(
|
||||
type == "confirm-investment"
|
||||
? "Investment"
|
||||
: type,
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF191B1E),
|
||||
fontSize: 14.sp,
|
||||
fontWeight: FontWeight.w600,
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
height: 4.h,
|
||||
),
|
||||
(type == "confirm-investment" ||
|
||||
type == 'Investment')
|
||||
? Text(
|
||||
"Name of investment",
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF191B1E),
|
||||
fontSize: 17.sp,
|
||||
fontWeight: FontWeight.w700,
|
||||
),
|
||||
)
|
||||
: const SizedBox(),
|
||||
SizedBox(
|
||||
height: 4.h,
|
||||
),
|
||||
Text(
|
||||
'10/04/2024 22:04',
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF8D8D8D),
|
||||
fontSize: 11.sp,
|
||||
fontWeight: FontWeight.w500,
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
height: 16.h,
|
||||
),
|
||||
Text(
|
||||
'+ SAR 100,000',
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF191B1E),
|
||||
fontSize: 20.sp,
|
||||
fontWeight: FontWeight.w900,
|
||||
),
|
||||
),
|
||||
(type == "confirm-investment" ||
|
||||
type == 'Investment')
|
||||
? Text(
|
||||
"+ \$100.00",
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF363636),
|
||||
fontSize: 12.sp,
|
||||
fontWeight: FontWeight.w500,
|
||||
),
|
||||
)
|
||||
: const SizedBox(),
|
||||
],
|
||||
),
|
||||
SizedBox(
|
||||
height: 4.h,
|
||||
height: 35.h,
|
||||
),
|
||||
type == "confirm-investment"
|
||||
? Text(
|
||||
"Name of investment",
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF191B1E),
|
||||
fontSize: 17.sp,
|
||||
fontWeight: FontWeight.w700,
|
||||
),
|
||||
)
|
||||
: const SizedBox(),
|
||||
SizedBox(
|
||||
height: 4.h,
|
||||
),
|
||||
Text(
|
||||
'10/04/2024 22:04',
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF8D8D8D),
|
||||
fontSize: 11.sp,
|
||||
fontWeight: FontWeight.w500,
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
height: 16.h,
|
||||
),
|
||||
Text(
|
||||
'+ SAR 100,000',
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF191B1E),
|
||||
fontSize: 20.sp,
|
||||
fontWeight: FontWeight.w900,
|
||||
),
|
||||
),
|
||||
type == "confirm-investment"
|
||||
? Text(
|
||||
"+ \$100.00",
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF363636),
|
||||
fontSize: 12.sp,
|
||||
fontWeight: FontWeight.w500,
|
||||
),
|
||||
)
|
||||
: const SizedBox(),
|
||||
_buildBody(),
|
||||
],
|
||||
),
|
||||
SizedBox(
|
||||
height: 35.h,
|
||||
),
|
||||
_buildBody(),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
// Positioned(
|
||||
// // bottom: 40,
|
||||
// top: 400.h,
|
||||
// // right: 30,
|
||||
// child: Container(
|
||||
// height: 20.r,
|
||||
// decoration: const BoxDecoration(
|
||||
// shape: BoxShape.circle,
|
||||
// color: Colors.red,
|
||||
// ),
|
||||
// ),
|
||||
// ),
|
||||
// Align(
|
||||
// alignment: Alignment.centerLeft,
|
||||
// child: Container(
|
||||
// height: 20.r,
|
||||
// decoration: const BoxDecoration(
|
||||
// shape: BoxShape.circle,
|
||||
// color: Colors.red,
|
||||
// ),
|
||||
// ),
|
||||
// )
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
@@ -340,7 +360,8 @@ class WalletDetails extends StatelessWidget {
|
||||
),
|
||||
);
|
||||
} else {
|
||||
return Expanded(
|
||||
return Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 8.0),
|
||||
child: ListView.builder(
|
||||
physics: const NeverScrollableScrollPhysics(),
|
||||
shrinkWrap: true,
|
||||
|
||||
@@ -1,9 +1,11 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/widgets.dart';
|
||||
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
||||
import 'package:google_fonts/google_fonts.dart';
|
||||
import 'package:tanami_app/core/routes/route_name.dart';
|
||||
import 'package:tanami_app/core/routes/routes.dart';
|
||||
import 'package:tanami_app/core/styles/app_text.dart';
|
||||
import 'package:ticket_widget/ticket_widget.dart';
|
||||
|
||||
class WithdrawalConfirmation extends StatefulWidget {
|
||||
const WithdrawalConfirmation({super.key});
|
||||
@@ -47,7 +49,7 @@ class _WithdrawalConfirmationState extends State<WithdrawalConfirmation> {
|
||||
scrolledUnderElevation: 0.0,
|
||||
centerTitle: true,
|
||||
title: Text(
|
||||
'Withdrawal confirmation',
|
||||
AppText.previewTitle,
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF272727),
|
||||
fontSize: 20.sp,
|
||||
@@ -87,7 +89,7 @@ class _WithdrawalConfirmationState extends State<WithdrawalConfirmation> {
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Text(
|
||||
'Please confirm the withdrawal amount and verify the accuracy of your bank details.',
|
||||
AppText.info1,
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF015698),
|
||||
fontSize: 14.sp,
|
||||
@@ -98,7 +100,7 @@ class _WithdrawalConfirmationState extends State<WithdrawalConfirmation> {
|
||||
height: 4.h,
|
||||
),
|
||||
Text(
|
||||
'Processing times vary from 3-7 working days',
|
||||
AppText.workingDays,
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF015698),
|
||||
fontSize: 12.sp,
|
||||
@@ -120,7 +122,7 @@ class _WithdrawalConfirmationState extends State<WithdrawalConfirmation> {
|
||||
width: double.infinity,
|
||||
decoration: BoxDecoration(
|
||||
borderRadius: BorderRadius.circular(22.r),
|
||||
color: Colors.white,
|
||||
color: Colors.transparent,
|
||||
boxShadow: [
|
||||
BoxShadow(
|
||||
color: Colors.black.withOpacity(0.15),
|
||||
@@ -130,110 +132,114 @@ class _WithdrawalConfirmationState extends State<WithdrawalConfirmation> {
|
||||
),
|
||||
],
|
||||
),
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.fromLTRB(20.0, 30, 20, 10),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
children: [
|
||||
Container(
|
||||
decoration: const BoxDecoration(
|
||||
shape: BoxShape.circle,
|
||||
color: Color(0xFFE6681F),
|
||||
),
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(8.0),
|
||||
child: Image.asset(
|
||||
'assets/images/wallet_screen/withdraw_list.png',
|
||||
height: 25.h,
|
||||
child: TicketWidget(
|
||||
isCornerRounded: true,
|
||||
height: 720.h,
|
||||
width: double.infinity,
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.fromLTRB(30.0, 30, 30, 10),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
children: [
|
||||
Container(
|
||||
decoration: const BoxDecoration(
|
||||
shape: BoxShape.circle,
|
||||
color: Color(0xFFE6681F),
|
||||
),
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
height: 16.h,
|
||||
),
|
||||
Text(
|
||||
'Withdrawal',
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF191B1E),
|
||||
fontSize: 14.sp,
|
||||
fontWeight: FontWeight.w600,
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
height: 4.h,
|
||||
),
|
||||
Text(
|
||||
'10/04/2024 22:04',
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF8D8D8D),
|
||||
fontSize: 11.sp,
|
||||
fontWeight: FontWeight.w500,
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
height: 16.h,
|
||||
),
|
||||
Text(
|
||||
'- SAR 1000',
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF191B1E),
|
||||
fontSize: 20.sp,
|
||||
fontWeight: FontWeight.w900,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
SizedBox(
|
||||
height: 35.h,
|
||||
),
|
||||
ListView.builder(
|
||||
physics: const NeverScrollableScrollPhysics(),
|
||||
shrinkWrap: true,
|
||||
itemCount: titles.length,
|
||||
itemBuilder: (context, index) {
|
||||
return Column(
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(
|
||||
vertical: 12.0),
|
||||
child: Row(
|
||||
mainAxisAlignment:
|
||||
MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
Text(
|
||||
titles[index],
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF535353),
|
||||
fontSize: 14.sp,
|
||||
fontWeight: FontWeight.w500,
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
width: 175.w,
|
||||
child: Text(
|
||||
values[index],
|
||||
textAlign: TextAlign.end,
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF191B1E),
|
||||
fontSize: 14.sp,
|
||||
fontWeight: FontWeight.w600,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(8.0),
|
||||
child: Image.asset(
|
||||
'assets/images/wallet_screen/withdraw_list.png',
|
||||
height: 25.h,
|
||||
),
|
||||
),
|
||||
(index != titles.length - 1)
|
||||
? const Divider()
|
||||
: Container()
|
||||
],
|
||||
);
|
||||
},
|
||||
),
|
||||
],
|
||||
),
|
||||
SizedBox(
|
||||
height: 16.h,
|
||||
),
|
||||
Text(
|
||||
AppText.withdrawal,
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF191B1E),
|
||||
fontSize: 14.sp,
|
||||
fontWeight: FontWeight.w600,
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
height: 4.h,
|
||||
),
|
||||
Text(
|
||||
'10/04/2024 22:04',
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF8D8D8D),
|
||||
fontSize: 11.sp,
|
||||
fontWeight: FontWeight.w500,
|
||||
),
|
||||
),
|
||||
SizedBox(
|
||||
height: 16.h,
|
||||
),
|
||||
Text(
|
||||
'- SAR 1000',
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF191B1E),
|
||||
fontSize: 20.sp,
|
||||
fontWeight: FontWeight.w400,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
SizedBox(
|
||||
height: 35.h,
|
||||
),
|
||||
ListView.builder(
|
||||
physics: const NeverScrollableScrollPhysics(),
|
||||
shrinkWrap: true,
|
||||
itemCount: titles.length,
|
||||
itemBuilder: (context, index) {
|
||||
return Column(
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(
|
||||
vertical: 12.0),
|
||||
child: Row(
|
||||
mainAxisAlignment:
|
||||
MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
Text(
|
||||
titles[index],
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF535353),
|
||||
fontSize: 14.sp,
|
||||
fontWeight: FontWeight.w500,
|
||||
),
|
||||
),
|
||||
Expanded(
|
||||
child: Text(
|
||||
values[index],
|
||||
textAlign: TextAlign.end,
|
||||
style: GoogleFonts.dmSans(
|
||||
color: const Color(0xFF191B1E),
|
||||
fontSize: 14.sp,
|
||||
fontWeight: FontWeight.w600,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
(index != titles.length - 1)
|
||||
? const Divider()
|
||||
: Container()
|
||||
],
|
||||
);
|
||||
},
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
|
||||
@@ -1197,6 +1197,14 @@ packages:
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.6.1"
|
||||
ticket_widget:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: ticket_widget
|
||||
sha256: "82cfcd2296ea83b47ec474a2e55c64ac8cdfc3058ec08f079b2d05e598bdf137"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "1.0.2"
|
||||
timing:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
||||
@@ -83,6 +83,7 @@ dependencies:
|
||||
|
||||
#Expansion Tile
|
||||
expansion_tile_group: ^1.2.4
|
||||
ticket_widget: ^1.0.2
|
||||
|
||||
dev_dependencies:
|
||||
flutter_test:
|
||||
|
||||
Reference in New Issue
Block a user