fix: risk profile
This commit is contained in:
parent
9da1675250
commit
eb1eb83d52
|
@ -60,14 +60,6 @@ class SubmitBankAccount extends StatelessWidget {
|
||||||
color: ColorPalette.slate400,
|
color: ColorPalette.slate400,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
// const Spacer(),
|
|
||||||
// ButtonView(
|
|
||||||
// name: 'Next',
|
|
||||||
// onPressed: () {
|
|
||||||
// provider.nextSubmission(context);
|
|
||||||
// routePush(context, page: const ConfirmBankAccount());
|
|
||||||
// },
|
|
||||||
// )
|
|
||||||
],
|
],
|
||||||
);
|
);
|
||||||
}),
|
}),
|
||||||
|
|
|
@ -1,19 +1,17 @@
|
||||||
import 'package:cims_apps/application/assets/path_assets.dart';
|
|
||||||
import 'package:cims_apps/application/component/button/back_button_view.dart';
|
import 'package:cims_apps/application/component/button/back_button_view.dart';
|
||||||
import 'package:cims_apps/application/component/button/button_view.dart';
|
import 'package:cims_apps/application/component/button/button_view.dart';
|
||||||
import 'package:cims_apps/application/component/image/image_view.dart';
|
|
||||||
import 'package:cims_apps/application/theme/color_palette.dart';
|
import 'package:cims_apps/application/theme/color_palette.dart';
|
||||||
import 'package:cims_apps/core/route/route.dart';
|
import 'package:cims_apps/core/route/route.dart';
|
||||||
import 'package:cims_apps/core/utils/size_config.dart';
|
import 'package:cims_apps/core/utils/size_config.dart';
|
||||||
import 'package:cims_apps/features/auth/registration/view/registration_password_view.dart';
|
import 'package:cims_apps/features/auth/registration/view/registration_password_view.dart';
|
||||||
import 'package:cims_apps/features/auth/registration/view/submission_data/risk_profile/risk_profile_view_model/risk_profile_view_model.dart';
|
import 'package:cims_apps/features/auth/registration/view/submission_data/risk_profile/risk_profile_view_model/risk_profile_view_model.dart';
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:provider/provider.dart';
|
|
||||||
|
|
||||||
class ResultsView extends StatelessWidget {
|
class ResultsView extends StatelessWidget {
|
||||||
final String totalScore;
|
final String totalScore;
|
||||||
final RiskProfileResult typeResult;
|
final RiskProfileResult typeResult;
|
||||||
const ResultsView({super.key, required this.typeResult, required this.totalScore});
|
const ResultsView(
|
||||||
|
{super.key, required this.typeResult, required this.totalScore});
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
|
@ -28,14 +26,11 @@ class ResultsView extends StatelessWidget {
|
||||||
children: [
|
children: [
|
||||||
BackButtonView(),
|
BackButtonView(),
|
||||||
const Text('Risk Profile', textAlign: TextAlign.center),
|
const Text('Risk Profile', textAlign: TextAlign.center),
|
||||||
SizedBox(
|
SizedBox(width: SizeConfig.width * 0.1)
|
||||||
width: SizeConfig.width * 0.1
|
|
||||||
)
|
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
shape: const RoundedRectangleBorder(
|
shape: const RoundedRectangleBorder(
|
||||||
side: BorderSide(color: ColorPalette.slate200)
|
side: BorderSide(color: ColorPalette.slate200)),
|
||||||
),
|
|
||||||
),
|
),
|
||||||
body: SingleChildScrollView(
|
body: SingleChildScrollView(
|
||||||
padding: EdgeInsets.all(24),
|
padding: EdgeInsets.all(24),
|
||||||
|
@ -46,9 +41,10 @@ class ResultsView extends StatelessWidget {
|
||||||
borderRadius: BorderRadius.circular(8),
|
borderRadius: BorderRadius.circular(8),
|
||||||
child: Container(
|
child: Container(
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
color: typeResult.color,
|
color: typeResult.color,
|
||||||
image: DecorationImage(image: AssetImage(typeResult.img), alignment: Alignment.centerRight)
|
image: DecorationImage(
|
||||||
),
|
image: AssetImage(typeResult.img),
|
||||||
|
alignment: Alignment.centerRight)),
|
||||||
child: Row(
|
child: Row(
|
||||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
children: [
|
children: [
|
||||||
|
@ -60,25 +56,26 @@ class ResultsView extends StatelessWidget {
|
||||||
Text(
|
Text(
|
||||||
typeResult.type,
|
typeResult.type,
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
fontSize: 24,
|
fontSize: 24,
|
||||||
color: ColorPalette.white
|
color: ColorPalette.white),
|
||||||
),
|
|
||||||
),
|
),
|
||||||
SizedBox(height: 16,),
|
SizedBox(
|
||||||
Text('Total Score :',
|
height: 16,
|
||||||
|
),
|
||||||
|
Text(
|
||||||
|
'Total Score :',
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
fontSize: 16,
|
fontSize: 16,
|
||||||
color: ColorPalette.white
|
color: ColorPalette.white),
|
||||||
),
|
|
||||||
),
|
),
|
||||||
Text(totalScore,
|
Text(
|
||||||
|
totalScore,
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
fontSize: 28,
|
fontSize: 28,
|
||||||
color: ColorPalette.white
|
color: ColorPalette.white),
|
||||||
),
|
|
||||||
)
|
)
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
|
@ -90,23 +87,17 @@ class ResultsView extends StatelessWidget {
|
||||||
SizedBox(
|
SizedBox(
|
||||||
height: 24,
|
height: 24,
|
||||||
),
|
),
|
||||||
Text(
|
Text(typeResult.desc,
|
||||||
typeResult.desc,
|
style: TextStyle(color: ColorPalette.slate500, fontSize: 16)),
|
||||||
style: TextStyle(
|
|
||||||
color: ColorPalette.slate500,
|
|
||||||
fontSize: 16
|
|
||||||
)
|
|
||||||
),
|
|
||||||
SizedBox(
|
SizedBox(
|
||||||
height: 24,
|
height: 24,
|
||||||
),
|
),
|
||||||
Text(
|
Text(
|
||||||
'Suitable Product',
|
'Suitable Product',
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
color: ColorPalette.slate800,
|
color: ColorPalette.slate800,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
fontSize: 16
|
fontSize: 16),
|
||||||
),
|
|
||||||
),
|
),
|
||||||
SizedBox(
|
SizedBox(
|
||||||
height: 16,
|
height: 16,
|
||||||
|
@ -123,24 +114,24 @@ class ResultsView extends StatelessWidget {
|
||||||
child: Row(
|
child: Row(
|
||||||
children: [
|
children: [
|
||||||
Container(
|
Container(
|
||||||
padding: EdgeInsets.all(8),
|
padding: EdgeInsets.all(8),
|
||||||
alignment: Alignment.center,
|
alignment: Alignment.center,
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
shape: BoxShape.circle,
|
shape: BoxShape.circle,
|
||||||
color: typeResult.color.withOpacity(0.1)
|
color: typeResult.color.withOpacity(0.1)),
|
||||||
),
|
child: Image.asset(e['icon'],
|
||||||
child: Image.asset(e['icon'], width: SizeConfig.width * 0.07, color: typeResult.color)
|
width: SizeConfig.width * 0.07,
|
||||||
),
|
color: typeResult.color)),
|
||||||
SizedBox(
|
SizedBox(
|
||||||
width: 12,
|
width: 12,
|
||||||
),
|
),
|
||||||
Expanded(
|
Expanded(
|
||||||
child: Text(e['desc'],
|
child: Text(
|
||||||
|
e['desc'],
|
||||||
style: TextStyle(
|
style: TextStyle(
|
||||||
fontSize: 16,
|
fontSize: 16,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
color: ColorPalette.slate800
|
color: ColorPalette.slate800),
|
||||||
),
|
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
],
|
],
|
||||||
|
@ -153,8 +144,7 @@ class ResultsView extends StatelessWidget {
|
||||||
),
|
),
|
||||||
ButtonView(
|
ButtonView(
|
||||||
name: 'Re-test',
|
name: 'Re-test',
|
||||||
onPressed: () {
|
onPressed: () {},
|
||||||
},
|
|
||||||
marginVertical: 0,
|
marginVertical: 0,
|
||||||
backgroundColor: ColorPalette.white,
|
backgroundColor: ColorPalette.white,
|
||||||
textColor: ColorPalette.primary,
|
textColor: ColorPalette.primary,
|
||||||
|
@ -171,6 +161,7 @@ class ResultsView extends StatelessWidget {
|
||||||
ButtonView(
|
ButtonView(
|
||||||
name: 'Confirm',
|
name: 'Confirm',
|
||||||
onPressed: () {
|
onPressed: () {
|
||||||
|
//TODO route ke terms condition
|
||||||
routePush(context, page: DialogSuccess());
|
routePush(context, page: DialogSuccess());
|
||||||
},
|
},
|
||||||
marginVertical: 0,
|
marginVertical: 0,
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
import 'package:cims_apps/application/assets/path_assets.dart';
|
import 'package:cims_apps/application/assets/path_assets.dart';
|
||||||
import 'package:cims_apps/application/component/button/back_button_view.dart';
|
|
||||||
import 'package:cims_apps/application/component/button/button_view.dart';
|
import 'package:cims_apps/application/component/button/button_view.dart';
|
||||||
import 'package:cims_apps/application/component/image/image_view.dart';
|
import 'package:cims_apps/application/component/image/image_view.dart';
|
||||||
import 'package:cims_apps/application/theme/color_palette.dart';
|
import 'package:cims_apps/application/theme/color_palette.dart';
|
||||||
|
@ -13,93 +12,75 @@ class RiskProfileView extends StatelessWidget {
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Scaffold(
|
return Container(
|
||||||
appBar: AppBar(
|
width: SizeConfig.width,
|
||||||
toolbarHeight: 70,
|
height: SizeConfig.height,
|
||||||
backgroundColor: Colors.white,
|
padding: EdgeInsets.all(24),
|
||||||
surfaceTintColor: Colors.white,
|
child: Column(
|
||||||
automaticallyImplyLeading: false,
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
title: Row(
|
children: [
|
||||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
Column(
|
||||||
children: [
|
children: [
|
||||||
BackButtonView(),
|
ImageView(image: PathAssets.imgDataReport),
|
||||||
const Text('Risk Profile', textAlign: TextAlign.center),
|
SizedBox(
|
||||||
SizedBox(width: SizeConfig.width * 0.1)
|
height: 24,
|
||||||
],
|
),
|
||||||
),
|
Text(
|
||||||
shape: const RoundedRectangleBorder(
|
'Know Your Risk Profile',
|
||||||
side: BorderSide(color: ColorPalette.slate200)),
|
textAlign: TextAlign.center,
|
||||||
),
|
style: TextStyle(
|
||||||
body: Container(
|
color: ColorPalette.slate800,
|
||||||
width: SizeConfig.width,
|
fontWeight: FontWeight.bold,
|
||||||
height: SizeConfig.height,
|
fontSize: 24),
|
||||||
padding: EdgeInsets.all(24),
|
),
|
||||||
child: Column(
|
SizedBox(
|
||||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
height: 12,
|
||||||
children: [
|
),
|
||||||
Column(
|
Text(
|
||||||
children: [
|
'We will provide recommendations that match your profile and risk tolerance level.',
|
||||||
ImageView(image: PathAssets.imgDataReport),
|
textAlign: TextAlign.center,
|
||||||
SizedBox(
|
style: TextStyle(
|
||||||
height: 24,
|
fontSize: 16,
|
||||||
),
|
fontWeight: FontWeight.w600,
|
||||||
Text(
|
color: ColorPalette.slate500),
|
||||||
'Know Your Risk Profile',
|
),
|
||||||
textAlign: TextAlign.center,
|
],
|
||||||
style: TextStyle(
|
),
|
||||||
color: ColorPalette.slate800,
|
Column(
|
||||||
fontWeight: FontWeight.bold,
|
children: [
|
||||||
fontSize: 24),
|
Row(
|
||||||
),
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
SizedBox(
|
children: [
|
||||||
height: 12,
|
ImageView(
|
||||||
),
|
image: PathAssets.iconShield,
|
||||||
Text(
|
width: 20,
|
||||||
'We will provide recommendations that match your profile and risk tolerance level.',
|
height: 22,
|
||||||
textAlign: TextAlign.center,
|
),
|
||||||
style: TextStyle(
|
SizedBox(
|
||||||
fontSize: 16,
|
width: 8,
|
||||||
fontWeight: FontWeight.w600,
|
),
|
||||||
color: ColorPalette.slate500),
|
Text(
|
||||||
),
|
'Your data is secure and encrypted',
|
||||||
],
|
style: TextStyle(
|
||||||
),
|
fontWeight: FontWeight.w600,
|
||||||
Column(
|
color: ColorPalette.primary,
|
||||||
children: [
|
fontSize: 16),
|
||||||
Row(
|
)
|
||||||
mainAxisAlignment: MainAxisAlignment.center,
|
],
|
||||||
children: [
|
),
|
||||||
ImageView(
|
SizedBox(
|
||||||
image: PathAssets.iconShield,
|
height: 24,
|
||||||
width: 20,
|
),
|
||||||
height: 22,
|
ButtonView(
|
||||||
),
|
name: "Let's Start",
|
||||||
SizedBox(
|
onPressed: () {
|
||||||
width: 8,
|
routePush(context, page: QuestionView());
|
||||||
),
|
},
|
||||||
Text(
|
marginVertical: 0,
|
||||||
'Your data is secure and encrypted',
|
)
|
||||||
style: TextStyle(
|
],
|
||||||
fontWeight: FontWeight.w600,
|
)
|
||||||
color: ColorPalette.primary,
|
],
|
||||||
fontSize: 16),
|
|
||||||
)
|
|
||||||
],
|
|
||||||
),
|
|
||||||
SizedBox(
|
|
||||||
height: 24,
|
|
||||||
),
|
|
||||||
ButtonView(
|
|
||||||
name: "Let's Start",
|
|
||||||
onPressed: () {
|
|
||||||
routePush(context, page: QuestionView());
|
|
||||||
},
|
|
||||||
marginVertical: 0,
|
|
||||||
)
|
|
||||||
],
|
|
||||||
)
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
@ -60,9 +60,7 @@ class _SubmissionParentState extends State<SubmissionParent> {
|
||||||
case 8:
|
case 8:
|
||||||
return const RiskProfileView();
|
return const RiskProfileView();
|
||||||
case 9:
|
case 9:
|
||||||
return Container(
|
return const Text("Step 9");
|
||||||
child: Text("Step 9"),
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -142,7 +140,8 @@ class _SubmissionParentState extends State<SubmissionParent> {
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
provider.getCurrentStep == 3 ||
|
provider.getCurrentStep == 3 ||
|
||||||
provider.getCurrentStep == 4
|
provider.getCurrentStep == 4 ||
|
||||||
|
provider.getCurrentStep == 8
|
||||||
? const SizedBox()
|
? const SizedBox()
|
||||||
: Align(
|
: Align(
|
||||||
alignment: Alignment.bottomCenter,
|
alignment: Alignment.bottomCenter,
|
||||||
|
|
|
@ -18,24 +18,14 @@ class InitialSignature extends StatelessWidget {
|
||||||
)
|
)
|
||||||
],
|
],
|
||||||
builder: (context, child) {
|
builder: (context, child) {
|
||||||
return Column(
|
return const Column(
|
||||||
crossAxisAlignment: CrossAxisAlignment.start,
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
children: [
|
children: [
|
||||||
const TextCaption(title: 'Draw your digital sign'),
|
TextCaption(title: 'Draw your digital sign'),
|
||||||
const ImageView(image: PathAssets.frameSignature),
|
ImageView(image: PathAssets.frameSignature),
|
||||||
const ListTileView(
|
ListTileView(
|
||||||
title:
|
title:
|
||||||
'Make sure the sign you draw is match with your ID Card'),
|
'Make sure the sign you draw is match with your ID Card'),
|
||||||
// Consumer<SubmissionDataViewModel>(
|
|
||||||
// builder: (context, provider, child) {
|
|
||||||
// return ButtonView(
|
|
||||||
// name: 'Next',
|
|
||||||
// onPressed: () {
|
|
||||||
// provider.nextSubmission(context);
|
|
||||||
// routePush(context, page: const SubmitSignature());
|
|
||||||
// },
|
|
||||||
// );
|
|
||||||
// }),
|
|
||||||
],
|
],
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue
Block a user