Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tost message added for student payment report #452

Merged
merged 3 commits into from
Nov 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 22 additions & 19 deletions campus/frontend/lib/avinya/attendance/lib/app.dart
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import 'package:gallery/auth.dart';
import 'package:gallery/data/campus_apps_portal.dart';
import 'package:flutter_localizations/flutter_localizations.dart';
import 'package:month_year_picker/month_year_picker.dart';
import 'package:oktoast/oktoast.dart';

// import 'auth.dart';
import 'routing.dart';
Expand Down Expand Up @@ -90,25 +91,27 @@ class _CampusAttendanceManagementSystemState
notifier: _routeState,
child: SMSAuthScope(
notifier: _auth,
child: MaterialApp.router(
routerDelegate: _routerDelegate,
routeInformationParser: _routeParser,
localizationsDelegates: [
GlobalWidgetsLocalizations.delegate,
GlobalMaterialLocalizations.delegate,
MonthYearPickerLocalizations.delegate,
],
// Revert back to pre-Flutter-2.5 transition behavior:
// https://github.com/flutter/flutter/issues/82053
theme: ThemeData(
pageTransitionsTheme: const PageTransitionsTheme(
builders: {
TargetPlatform.android: FadeUpwardsPageTransitionsBuilder(),
TargetPlatform.iOS: CupertinoPageTransitionsBuilder(),
TargetPlatform.linux: FadeUpwardsPageTransitionsBuilder(),
TargetPlatform.macOS: CupertinoPageTransitionsBuilder(),
TargetPlatform.windows: FadeUpwardsPageTransitionsBuilder(),
},
child: OKToast(
child: MaterialApp.router(
routerDelegate: _routerDelegate,
routeInformationParser: _routeParser,
localizationsDelegates: [
GlobalWidgetsLocalizations.delegate,
GlobalMaterialLocalizations.delegate,
MonthYearPickerLocalizations.delegate,
],
// Revert back to pre-Flutter-2.5 transition behavior:
// https://github.com/flutter/flutter/issues/82053
theme: ThemeData(
pageTransitionsTheme: const PageTransitionsTheme(
builders: {
TargetPlatform.android: FadeUpwardsPageTransitionsBuilder(),
TargetPlatform.iOS: CupertinoPageTransitionsBuilder(),
TargetPlatform.linux: FadeUpwardsPageTransitionsBuilder(),
TargetPlatform.macOS: CupertinoPageTransitionsBuilder(),
TargetPlatform.windows: FadeUpwardsPageTransitionsBuilder(),
},
),
),
),
),
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import 'dart:ui';
import 'package:gallery/widgets/success_message.dart';
import 'package:http/http.dart' as http;
import 'dart:convert';

Expand Down Expand Up @@ -202,6 +203,7 @@ Future<void> createMonthlyLeaveDates({
);

if (response.statusCode >= 200 && response.statusCode < 300) {
showSuccessToast("Monthly Leave Dates Added Successfully!");
print("Leave dates created successfully: ${response.body}");
} else {
throw Exception(
Expand Down Expand Up @@ -244,6 +246,7 @@ Future<void> updateMonthlyLeaveDates({
);

if (response.statusCode >= 200 && response.statusCode < 300) {
showSuccessToast("Monthly Leave Dates Updated Successfully!");
print("Leave dates updated successfully: ${response.body}");
} else {
throw Exception(
Expand Down
2 changes: 1 addition & 1 deletion campus/frontend/lib/avinya/attendance/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ dependencies:
flutter_svg:
fl_chart: 0.60.0
month_year_picker: ^0.3.0+1

oktoast: ^3.4.0
pdf: ^3.6.4

dev_dependencies:
Expand Down
Loading