Commit 3ac3f31f authored by Izol's avatar Izol

Update version SS.11.WWW :

 - added color in balance
 - adjust fontSize
parent 8d279c0f
sdk.dir=/Users/macbookpro/Library/Android/sdk sdk.dir=/Users/macbookpro/Library/Android/sdk
flutter.sdk=/Users/macbookpro/Developer/flutter flutter.sdk=/Users/macbookpro/Developer/flutter
flutter.buildMode=debug flutter.buildMode=debug
flutter.versionName=SS.10.WWW flutter.versionName=SS.11.WWW
flutter.versionCode=3 flutter.versionCode=4
\ No newline at end of file \ No newline at end of file
...@@ -514,14 +514,15 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback { ...@@ -514,14 +514,15 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
dismissOnTouchOutside: false, dismissOnTouchOutside: false,
autoHide: Duration(seconds: 5), autoHide: Duration(seconds: 5),
headerAnimationLoop: true, headerAnimationLoop: true,
title: 'Isi Ulang Anda Berhasil, Saldo Anda Saat Ini $balance', title: 'Isi Ulang Anda Berhasil, Mohon Cek Kembali Saldo Anda!',
titleTextStyle: blackTextStyle.copyWith( titleTextStyle: blackTextStyle.copyWith(
fontSize: 20, fontSize: 20,
fontWeight: bold, fontWeight: bold,
), ),
desc: "Mohon Cek Kembali Saldo Anda!", desc: "Saldo Anda Saat Ini $balance",
descTextStyle: blackTextStyle.copyWith( descTextStyle: blackTextStyle.copyWith(
fontSize: 18, fontSize: 18,
color: Colors.green,
fontWeight: medium, fontWeight: medium,
), ),
...@@ -1317,7 +1318,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback { ...@@ -1317,7 +1318,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
width: 700, width: 700,
child: CustomFilledButton( child: CustomFilledButton(
title: 'lanjut', title: 'lanjut',
subtitle: 'proceed', subtitle: ' / proceed',
onPressed: () { onPressed: () {
if (timer != null) timer?.cancel(); if (timer != null) timer?.cancel();
tapIdle(); tapIdle();
...@@ -1718,7 +1719,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback { ...@@ -1718,7 +1719,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
Expanded( Expanded(
child: CustomFilledButton( child: CustomFilledButton(
title: 'lanjut', title: 'lanjut',
subtitle: 'proceed', subtitle: ' / proceed',
onPressed: () { onPressed: () {
setState(() { setState(() {
if (timer != null) if (timer != null)
...@@ -1966,7 +1967,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback { ...@@ -1966,7 +1967,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
), ),
], ],
) )
: HomeServices( : ButtonQris(
iconUrl: 'assets/cancel.png', iconUrl: 'assets/cancel.png',
title: 'batalkan', title: 'batalkan',
subtitle: 'cancel', subtitle: 'cancel',
...@@ -2044,7 +2045,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback { ...@@ -2044,7 +2045,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
), ),
], ],
) )
: HomeServices( : ButtonQris(
iconUrl: 'assets/check-mark.png', iconUrl: 'assets/check-mark.png',
title: 'Saya Sudah Bayar', title: 'Saya Sudah Bayar',
subtitle: 'i have already paid', subtitle: 'i have already paid',
...@@ -2188,14 +2189,14 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback { ...@@ -2188,14 +2189,14 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
'Sisa Waktu', 'Sisa Waktu',
style: blackTextStyle.copyWith( style: blackTextStyle.copyWith(
fontWeight: bold, fontWeight: bold,
fontSize: 15, fontSize: 22,
), ),
), ),
Text('timeout', Text('timeout',
style: greyTextStyle.copyWith( style: greyTextStyle.copyWith(
fontStyle: FontStyle.italic, fontStyle: FontStyle.italic,
fontWeight: light, fontWeight: light,
fontSize: 8, fontSize: 18,
)), )),
], ],
), ),
...@@ -2534,26 +2535,6 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback { ...@@ -2534,26 +2535,6 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
], ],
), ),
), ),
// Positioned(
// bottom: 20,
// left: 0,
// child: Ink(
// decoration: ShapeDecoration(
// color: Colors.white,
// shape: CircleBorder(),
// ),
// child: InkWell(
// borderRadius: BorderRadius.circular(1000.0),
// onTap: () {
// // aksi yang ingin dilakukan ketika tombol ditekan
// },
// child: Padding(
// padding: const EdgeInsets.all(8.0),
// child: Icon(Icons.settings, size: 28,),
// ),
// ),
// ),
// ),
Positioned( Positioned(
bottom: 30, bottom: 30,
left: 30, left: 30,
...@@ -2640,7 +2621,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback { ...@@ -2640,7 +2621,7 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
child: const HomeServices( child: const HomeServices(
iconUrl: 'assets/ic_topup.png', iconUrl: 'assets/ic_topup.png',
title: 'Isi Ulang', title: 'Isi Ulang',
subtitle: "topup balance", subtitle: " topup balance",
), ),
), ),
TextButton( TextButton(
...@@ -2653,90 +2634,9 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback { ...@@ -2653,90 +2634,9 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
child: const HomeServices( child: const HomeServices(
iconUrl: 'assets/ic_send.png', iconUrl: 'assets/ic_send.png',
title: 'Cek Saldo', title: 'Cek Saldo',
subtitle: 'balance', subtitle: ' balance',
), ),
), ),
// TextButton(
// onPressed: () {
// isShowingDialog = true;
// if (timer != null) timer?.cancel();
// tapIdle();
// showDialog(
// context: context,
// builder: (_) => AlertDialog(
// title: Text('Masukkan Password'),
// content: TextField(
// obscureText: true,
// decoration: InputDecoration(
// hintText: 'Password',
// ),
// ),
// actions: [
// TextButton(
// onPressed: () {
// setState(() {
// isShowingDialog = false;
// });
// Navigator.pop(context);
// if (timer != null) timer?.cancel();
// tapIdle(); },
// child: Text('Batal'),
// ),
// TextButton(
// onPressed: () {
// // Lakukan verifikasi password disini
// Navigator.pop(context);
// // Tampilkan halaman pengaturan jika verifikasi berhasil
// Navigator.push(
// context,
// MaterialPageRoute(
// builder: (context) => SetMerchant(),
// ),
// );
// },
// child: Text('Konfirmasi'),
// ),
// ],
// ),
// );
// },
// child: const HomeServices(
// iconUrl: 'assets/ic_send.png',
// title: 'Pengaturan',
// subtitle: 'setting',
// ),
// ),
// TextButton(
// onPressed: () async{
// var info = {"balance":4004,"cardExpirity":"1706869211","cardNumber":"9876540165008514","cardType":4,"cardUid":"E46B63BA000000000000000000000000","deposit":10000,"isMember":false,"listGate":[],"minBalance":0,"name":"Enzo-08756789987654","point":0,"regDb":"1675333210000000","report":"00000000000000000000000000000000F3003EA8DB630100BB0B0000A40F0000FFFFFFFFFFFFFFFFFFFFFFFF4968968A","ticketExpirity":"1675357199"}.toString();
// print("TestButton Press");
// await StartService.print(
// info,
// "Terminal POS Self Service",
// "Jagakarsa",
// "companyPhone",
// "63dba48c81979",
// "3003",
// "10",
// "10",
// "10",
// "linkaja",
// "Berhasil",
// );
// },
// child: const HomeServices(
// iconUrl: 'assets/ic_send.png',
// title: 'Print test',
// subtitle: 'print',
// ),
// ),
// Container(
// height: 100,
// width: 100,
// color: Colors.greenAccent,
// child: Text("${seconds.idle}"),
// ),
], ],
), ),
) )
...@@ -2744,169 +2644,6 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback { ...@@ -2744,169 +2644,6 @@ class _HomePageState extends State<HomePage> implements AlertDialogCallback {
), ),
], ],
), ),
// child: Column(
// crossAxisAlignment: CrossAxisAlignment.center,
// children: [
// GestureDetector(
// child: Row(
// mainAxisAlignment: MainAxisAlignment.center,
// children: [
// TextButton(
// onPressed: () {
// isShowingDialog = true;
// if (timer != null) timer?.cancel();
// tapIdle();
// amountController?.clear();
// var infoMap = jsonDecode(infoCard);
// plainCardExpirity = infoMap['cardExpirity'];
// var change = DateTime.fromMillisecondsSinceEpoch(
// int.parse(infoMap['cardExpirity']) * 1000);
// dateTimeCardExpirity = change;
// final DateFormat formatter = DateFormat('dd-MMM-yyyy');
// cardExpirity = formatter.format(change);
// deposit = CurrencyFormat.convertToIdr(
// infoMap["deposit"],
// 2,
// );
// cardNumber = infoMap["cardNumber"];
// name = infoMap["name"].toString().split("-")[0];
// int lengthSplit =
// infoMap["name"].toString().split("-").length;
// String subPhone = "";
// if (lengthSplit > 1) {
// String fullPhone =
// infoMap["name"].toString().split("-")[1].trim();
// print("ini nomer telponnya $fullPhone");
// subPhone = fullPhone.substring(
// fullPhone.length - 4, fullPhone.length);
// // Navigator.pop(context);
// // _topUp(outletName, info);
// phone4CharValidation(subPhone, infoCard, idle);
// } else {
// AwesomeDialog(
// context: context,
// dialogType: DialogType.error,
// animType: AnimType.rightSlide,
// headerAnimationLoop: true,
// title: 'Nomor telepon tidak ditemukan !',
// desc: "phone number not found !",
// btnOkOnPress: () {
// setState(() {
// isShowingDialog = false;
// });
// if (timer != null) timer?.cancel();
// tapIdle();
// },
// btnOkIcon: Icons.cancel,
// btnOkColor: Colors.red)
// .show();
// }
// },
// child: const HomeServices(
// iconUrl: 'assets/ic_topup.png',
// title: 'Isi Ulang',
// subtitle: "topup balance",
// ),
// ),
// TextButton(
// onPressed: () {
// timer?.cancel();
// isShowingDialog = true;
// _showTap();
// tapDial();
// },
// child: const HomeServices(
// iconUrl: 'assets/ic_send.png',
// title: 'Cek Saldo',
// subtitle: 'balance',
// ),
// ),
// TextButton(
// onPressed: () {
// isShowingDialog = true;
// if (timer != null) timer?.cancel();
// tapIdle();
// showDialog(
// context: context,
// builder: (_) => AlertDialog(
// title: Text('Masukkan Password'),
// content: TextField(
// obscureText: true,
// decoration: InputDecoration(
// hintText: 'Password',
// ),
// ),
// actions: [
// TextButton(
// onPressed: () {
// setState(() {
// isShowingDialog = false;
// });
// Navigator.pop(context);
// if (timer != null) timer?.cancel();
// tapIdle(); },
// child: Text('Batal'),
// ),
// TextButton(
// onPressed: () {
// // Lakukan verifikasi password disini
// Navigator.pop(context);
// // Tampilkan halaman pengaturan jika verifikasi berhasil
// Navigator.push(
// context,
// MaterialPageRoute(
// builder: (context) => SetMerchant(),
// ),
// );
// },
// child: Text('Konfirmasi'),
// ),
// ],
// ),
// );
// },
// child: const HomeServices(
// iconUrl: 'assets/ic_send.png',
// title: 'Pengaturan',
// subtitle: 'setting',
// ),
// ),
//
// // TextButton(
// // onPressed: () async{
// // var info = {"balance":4004,"cardExpirity":"1706869211","cardNumber":"9876540165008514","cardType":4,"cardUid":"E46B63BA000000000000000000000000","deposit":10000,"isMember":false,"listGate":[],"minBalance":0,"name":"Enzo-08756789987654","point":0,"regDb":"1675333210000000","report":"00000000000000000000000000000000F3003EA8DB630100BB0B0000A40F0000FFFFFFFFFFFFFFFFFFFFFFFF4968968A","ticketExpirity":"1675357199"}.toString();
// // print("TestButton Press");
// // await StartService.print(
// // info,
// // "Terminal POS Self Service",
// // "Jagakarsa",
// // "companyPhone",
// // "63dba48c81979",
// // "3003",
// // "10",
// // "10",
// // "10",
// // "linkaja",
// // "Berhasil",
// // );
// // },
// // child: const HomeServices(
// // iconUrl: 'assets/ic_send.png',
// // title: 'Print test',
// // subtitle: 'print',
// // ),
// // ),
// // Container(
// // height: 100,
// // width: 100,
// // color: Colors.greenAccent,
// // child: Text("${seconds.idle}"),
// // ),
// ],
// ),
// )
// ],
// ),
); );
} }
......
...@@ -31,19 +31,21 @@ class CustomFilledButton extends StatelessWidget { ...@@ -31,19 +31,21 @@ class CustomFilledButton extends StatelessWidget {
borderRadius: BorderRadius.circular(56), borderRadius: BorderRadius.circular(56),
), ),
), ),
child: Column( child: Row(
mainAxisAlignment: MainAxisAlignment.center,
children: [ children: [
Text( Text(
title, title,
style: whiteTextStyle.copyWith( style: whiteTextStyle.copyWith(
fontSize: 18, fontSize: 25,
fontWeight: semiBold, fontWeight: semiBold,
), ),
), ),
SizedBox(width: 5),
Text( Text(
subtitle, subtitle,
style: greyTextStyle.copyWith( style: greyTextStyle.copyWith(
fontSize: 10, fontSize: 18,
fontStyle: FontStyle.italic, fontStyle: FontStyle.italic,
fontWeight: light, fontWeight: light,
), ),
...@@ -51,7 +53,6 @@ class CustomFilledButton extends StatelessWidget { ...@@ -51,7 +53,6 @@ class CustomFilledButton extends StatelessWidget {
), ),
], ],
), ),
), ),
); );
} }
......
...@@ -50,21 +50,99 @@ class HomeServices extends StatelessWidget { ...@@ -50,21 +50,99 @@ class HomeServices extends StatelessWidget {
), ),
), ),
), ),
Text( Row(
title, mainAxisAlignment: MainAxisAlignment.center,
style: blackTextStyle.copyWith( children: [
fontWeight: bold, Text(
fontSize: 15, title,
), style: blackTextStyle.copyWith(
fontWeight: semiBold,
fontSize: 22,
),
),
SizedBox(width: 5,),
Text(
subtitle,
style: greyTextStyle.copyWith(
fontWeight: light,
fontSize: 18,
),
)
],
), ),
Text( ],
subtitle, );
style: greyTextStyle.copyWith( }
fontWeight: light, }
fontStyle: FontStyle.italic,
fontSize: 8 class ButtonQris extends StatelessWidget {
final String iconUrl;
final String title;
final String subtitle;
final VoidCallback? onPressed;
const ButtonQris({
Key? key,
required this.iconUrl,
required this.title,
required this.subtitle,
this.onPressed,
}) : super(key: key);
@override
Widget build(BuildContext context) {
return Column(
children: [
Container(
width: 250,
height: 70,
margin: const EdgeInsets.only(
bottom: 10,
),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(20),
color: purpleColor,
boxShadow: [
BoxShadow(
color: Colors.grey.withOpacity(0.3), //color of shadow
spreadRadius: 3, //spread radius
blurRadius: 7, // blur radius
offset: Offset(3, 3), // changes position of shadow
//first paramerter of offset is left-right
//second parameter is top to down
),
//you can set more BoxShadow() here
],
),
child: Center(
child: Image.asset(
iconUrl,
color: whiteColor,
width: 25,
),
), ),
) ),
Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Text(
title,
style: blackTextStyle.copyWith(
fontWeight: semiBold,
fontSize: 22,
),
),
SizedBox(width: 5,),
Text(
subtitle,
style: greyTextStyle.copyWith(
fontWeight: light,
fontStyle: FontStyle.italic,
fontSize: 18,
),
)
],
),
], ],
); );
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment