Skip to content

Commit

Permalink
Merge pull request #183 from ia-toki/hotfix/register-quiz-on-button-c…
Browse files Browse the repository at this point in the history
…lick

[HOTFIX]: register quiz on button click
  • Loading branch information
gmochid authored Apr 23, 2024
2 parents 6c9ce08 + 95d1987 commit fd960fd
Showing 1 changed file with 10 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -368,6 +368,7 @@ class _QuizRegistrationPageState extends State<QuizRegistrationPage> {
},
);
}

@override
Widget build(BuildContext context) {
return BebrasScaffold(
Expand Down Expand Up @@ -425,8 +426,15 @@ class _QuizRegistrationPageState extends State<QuizRegistrationPage> {
customButtonColor: const Color(0xFF1BB8E1),
fontSize: 14,
innerVerticalPadding: 14,
onTap: () async {
await context.push('/quiz_download');
onTap: () {
setState(() => selectedWeek = 'running_weekly_quiz');
context
.read<QuizRegistrationCubit>()
.registerParticipant('siaga', selectedWeek);
checkNextWeeklyQuiz();
checkRunningWeeklyQuiz();
selectWeek('');
context.push('/quiz_download');
},
text: 'Kerjakan Latihan Minggu Ini',
),
Expand Down

0 comments on commit fd960fd

Please sign in to comment.