├── studfeeServer ├── .gitignore ├── public │ ├── logo.png │ └── logo-icon.ico ├── middleware │ ├── validator.js │ ├── validatorTwo.js │ ├── validatorFour.js │ ├── validatorThree.js │ ├── authenticate.js │ ├── jwt.js │ └── jwt_web.js ├── models │ ├── Payment.js │ ├── Message.js │ ├── Token.js │ ├── ProcessPayment.js │ ├── Admin.js │ └── User.js ├── config │ └── config.js ├── views │ ├── error.pug │ ├── success.pug │ ├── successhtm.html │ ├── resetPassword.pug │ ├── admin │ │ ├── signin.pug │ │ ├── register.pug │ │ ├── paymentlist.pug │ │ ├── dashboard.pug │ │ └── create-form.pug │ └── formmm.html ├── package.json ├── controller │ └── socket.js ├── index.js └── routes │ └── router.js └── studFee_client ├── linux ├── .gitignore ├── main.cc ├── flutter │ ├── generated_plugin_registrant.h │ ├── generated_plugin_registrant.cc │ ├── generated_plugins.cmake │ └── CMakeLists.txt ├── my_application.h └── my_application.cc ├── ios ├── Flutter │ ├── Debug.xcconfig │ ├── Release.xcconfig │ └── AppFrameworkInfo.plist ├── Runner │ ├── Runner-Bridging-Header.h │ ├── Assets.xcassets │ │ ├── LaunchImage.imageset │ │ │ ├── LaunchImage.png │ │ │ ├── LaunchImage@2x.png │ │ │ ├── LaunchImage@3x.png │ │ │ ├── README.md │ │ │ └── Contents.json │ │ └── AppIcon.appiconset │ │ │ ├── Icon-App-20x20@1x.png │ │ │ ├── Icon-App-20x20@2x.png │ │ │ ├── Icon-App-20x20@3x.png │ │ │ ├── Icon-App-29x29@1x.png │ │ │ ├── Icon-App-29x29@2x.png │ │ │ ├── Icon-App-29x29@3x.png │ │ │ ├── Icon-App-40x40@1x.png │ │ │ ├── Icon-App-40x40@2x.png │ │ │ ├── Icon-App-40x40@3x.png │ │ │ ├── Icon-App-50x50@1x.png │ │ │ ├── Icon-App-50x50@2x.png │ │ │ ├── Icon-App-57x57@1x.png │ │ │ ├── Icon-App-57x57@2x.png │ │ │ ├── Icon-App-60x60@2x.png │ │ │ ├── Icon-App-60x60@3x.png │ │ │ ├── Icon-App-72x72@1x.png │ │ │ ├── Icon-App-72x72@2x.png │ │ │ ├── Icon-App-76x76@1x.png │ │ │ ├── Icon-App-76x76@2x.png │ │ │ ├── Icon-App-1024x1024@1x.png │ │ │ ├── Icon-App-83.5x83.5@2x.png │ │ │ └── Contents.json │ ├── AppDelegate.swift │ ├── Base.lproj │ │ ├── Main.storyboard │ │ └── LaunchScreen.storyboard │ └── Info.plist ├── Runner.xcodeproj │ ├── project.xcworkspace │ │ ├── contents.xcworkspacedata │ │ └── xcshareddata │ │ │ ├── WorkspaceSettings.xcsettings │ │ │ └── IDEWorkspaceChecks.plist │ └── xcshareddata │ │ └── xcschemes │ │ └── Runner.xcscheme ├── Runner.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ │ ├── WorkspaceSettings.xcsettings │ │ └── IDEWorkspaceChecks.plist └── .gitignore ├── macos ├── Flutter │ ├── Flutter-Debug.xcconfig │ ├── Flutter-Release.xcconfig │ └── GeneratedPluginRegistrant.swift ├── Runner │ ├── Configs │ │ ├── Debug.xcconfig │ │ ├── Release.xcconfig │ │ ├── Warnings.xcconfig │ │ └── AppInfo.xcconfig │ ├── Assets.xcassets │ │ └── AppIcon.appiconset │ │ │ ├── app_icon_1024.png │ │ │ ├── app_icon_128.png │ │ │ ├── app_icon_16.png │ │ │ ├── app_icon_256.png │ │ │ ├── app_icon_32.png │ │ │ ├── app_icon_512.png │ │ │ ├── app_icon_64.png │ │ │ └── Contents.json │ ├── AppDelegate.swift │ ├── Release.entitlements │ ├── DebugProfile.entitlements │ ├── MainFlutterWindow.swift │ └── Info.plist ├── .gitignore ├── Runner.xcworkspace │ ├── contents.xcworkspacedata │ └── xcshareddata │ │ └── IDEWorkspaceChecks.plist └── Runner.xcodeproj │ ├── project.xcworkspace │ └── xcshareddata │ │ └── IDEWorkspaceChecks.plist │ └── xcshareddata │ └── xcschemes │ └── Runner.xcscheme ├── web ├── favicon.png ├── icons │ ├── Icon-192.png │ ├── Icon-512.png │ ├── Icon-maskable-192.png │ └── Icon-maskable-512.png ├── manifest.json └── index.html ├── android ├── gradle.properties ├── app │ ├── src │ │ ├── main │ │ │ ├── res │ │ │ │ ├── mipmap-hdpi │ │ │ │ │ ├── ic_launcher.png │ │ │ │ │ └── launcher_icon.png │ │ │ │ ├── mipmap-mdpi │ │ │ │ │ ├── ic_launcher.png │ │ │ │ │ └── launcher_icon.png │ │ │ │ ├── mipmap-xhdpi │ │ │ │ │ ├── ic_launcher.png │ │ │ │ │ └── launcher_icon.png │ │ │ │ ├── mipmap-xxhdpi │ │ │ │ │ ├── ic_launcher.png │ │ │ │ │ └── launcher_icon.png │ │ │ │ ├── mipmap-xxxhdpi │ │ │ │ │ ├── ic_launcher.png │ │ │ │ │ └── launcher_icon.png │ │ │ │ ├── drawable │ │ │ │ │ └── launch_background.xml │ │ │ │ ├── drawable-v21 │ │ │ │ │ └── launch_background.xml │ │ │ │ ├── values │ │ │ │ │ └── styles.xml │ │ │ │ └── values-night │ │ │ │ │ └── styles.xml │ │ │ ├── kotlin │ │ │ │ └── com │ │ │ │ │ └── example │ │ │ │ │ └── studfees │ │ │ │ │ └── MainActivity.kt │ │ │ └── AndroidManifest.xml │ │ ├── debug │ │ │ └── AndroidManifest.xml │ │ └── profile │ │ │ └── AndroidManifest.xml │ └── build.gradle ├── gradle │ └── wrapper │ │ └── gradle-wrapper.properties ├── .gitignore ├── settings.gradle └── build.gradle ├── assets ├── icons │ ├── book.png │ ├── user.png │ ├── home-2.png │ ├── payment.png │ └── people.png └── images │ ├── logo.png │ ├── cover.jpg │ ├── profile.png │ └── student.jpg ├── windows ├── runner │ ├── resources │ │ └── app_icon.ico │ ├── resource.h │ ├── utils.h │ ├── runner.exe.manifest │ ├── flutter_window.h │ ├── main.cpp │ ├── CMakeLists.txt │ ├── utils.cpp │ ├── flutter_window.cpp │ ├── Runner.rc │ └── win32_window.h ├── .gitignore ├── flutter │ ├── generated_plugin_registrant.h │ ├── generated_plugin_registrant.cc │ ├── generated_plugins.cmake │ └── CMakeLists.txt └── CMakeLists.txt ├── lib ├── util │ ├── snak_message.dart │ ├── navigator.dart │ ├── config.dart │ ├── routes.dart │ ├── alert_dailog.dart │ └── handle_errors.dart ├── provider │ └── user_provider.dart ├── models │ ├── dictionary_model.dart │ ├── payment_model.dart │ ├── message_model.dart │ ├── books_model.dart │ ├── process_payment_model.dart │ └── user_model.dart ├── screens │ ├── users │ │ ├── books │ │ │ ├── book_services.dart │ │ │ ├── book_reader.dart │ │ │ └── book_search.dart │ │ ├── chat │ │ │ ├── chat_list.dart │ │ │ └── user_list.dart │ │ ├── dictionary │ │ │ ├── dic_service.dart │ │ │ └── dictionary.dart │ │ ├── pdf_reader.dart │ │ └── home_screen.dart │ └── onboad │ │ └── onboard.dart ├── components │ ├── grid_box.dart │ ├── readonly_textfield.dart │ ├── button.dart │ ├── auth_screen.dart │ └── custom_textfield.dart └── main.dart ├── README.md ├── test └── widget_test.dart ├── analysis_options.yaml └── pubspec.yaml /studfeeServer/.gitignore: -------------------------------------------------------------------------------- 1 | .env 2 | /node_modules -------------------------------------------------------------------------------- /studFee_client/linux/.gitignore: -------------------------------------------------------------------------------- 1 | flutter/ephemeral 2 | -------------------------------------------------------------------------------- /studFee_client/ios/Flutter/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Generated.xcconfig" 2 | -------------------------------------------------------------------------------- /studFee_client/ios/Flutter/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "Generated.xcconfig" 2 | -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Runner-Bridging-Header.h: -------------------------------------------------------------------------------- 1 | #import "GeneratedPluginRegistrant.h" 2 | -------------------------------------------------------------------------------- /studFee_client/macos/Flutter/Flutter-Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "ephemeral/Flutter-Generated.xcconfig" 2 | -------------------------------------------------------------------------------- /studFee_client/macos/Flutter/Flutter-Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "ephemeral/Flutter-Generated.xcconfig" 2 | -------------------------------------------------------------------------------- /studFee_client/web/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/web/favicon.png -------------------------------------------------------------------------------- /studfeeServer/public/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studfeeServer/public/logo.png -------------------------------------------------------------------------------- /studfeeServer/public/logo-icon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studfeeServer/public/logo-icon.ico -------------------------------------------------------------------------------- /studFee_client/android/gradle.properties: -------------------------------------------------------------------------------- 1 | org.gradle.jvmargs=-Xmx1536M 2 | android.useAndroidX=true 3 | android.enableJetifier=true 4 | -------------------------------------------------------------------------------- /studFee_client/assets/icons/book.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/assets/icons/book.png -------------------------------------------------------------------------------- /studFee_client/assets/icons/user.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/assets/icons/user.png -------------------------------------------------------------------------------- /studFee_client/assets/images/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/assets/images/logo.png -------------------------------------------------------------------------------- /studFee_client/macos/Runner/Configs/Debug.xcconfig: -------------------------------------------------------------------------------- 1 | #include "../../Flutter/Flutter-Debug.xcconfig" 2 | #include "Warnings.xcconfig" 3 | -------------------------------------------------------------------------------- /studFee_client/web/icons/Icon-192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/web/icons/Icon-192.png -------------------------------------------------------------------------------- /studFee_client/web/icons/Icon-512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/web/icons/Icon-512.png -------------------------------------------------------------------------------- /studFee_client/assets/icons/home-2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/assets/icons/home-2.png -------------------------------------------------------------------------------- /studFee_client/assets/icons/payment.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/assets/icons/payment.png -------------------------------------------------------------------------------- /studFee_client/assets/icons/people.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/assets/icons/people.png -------------------------------------------------------------------------------- /studFee_client/assets/images/cover.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/assets/images/cover.jpg -------------------------------------------------------------------------------- /studFee_client/assets/images/profile.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/assets/images/profile.png -------------------------------------------------------------------------------- /studFee_client/assets/images/student.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/assets/images/student.jpg -------------------------------------------------------------------------------- /studFee_client/macos/Runner/Configs/Release.xcconfig: -------------------------------------------------------------------------------- 1 | #include "../../Flutter/Flutter-Release.xcconfig" 2 | #include "Warnings.xcconfig" 3 | -------------------------------------------------------------------------------- /studFee_client/macos/.gitignore: -------------------------------------------------------------------------------- 1 | # Flutter-related 2 | **/Flutter/ephemeral/ 3 | **/Pods/ 4 | 5 | # Xcode-related 6 | **/dgph 7 | **/xcuserdata/ 8 | -------------------------------------------------------------------------------- /studFee_client/web/icons/Icon-maskable-192.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/web/icons/Icon-maskable-192.png -------------------------------------------------------------------------------- /studFee_client/web/icons/Icon-maskable-512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/web/icons/Icon-maskable-512.png -------------------------------------------------------------------------------- /studFee_client/windows/runner/resources/app_icon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/windows/runner/resources/app_icon.ico -------------------------------------------------------------------------------- /studFee_client/android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /studFee_client/android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /studFee_client/android/app/src/main/res/mipmap-hdpi/launcher_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/android/app/src/main/res/mipmap-hdpi/launcher_icon.png -------------------------------------------------------------------------------- /studFee_client/android/app/src/main/res/mipmap-mdpi/launcher_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/android/app/src/main/res/mipmap-mdpi/launcher_icon.png -------------------------------------------------------------------------------- /studFee_client/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /studFee_client/android/app/src/main/res/mipmap-xhdpi/launcher_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/android/app/src/main/res/mipmap-xhdpi/launcher_icon.png -------------------------------------------------------------------------------- /studFee_client/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /studFee_client/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /studFee_client/android/app/src/main/res/mipmap-xxhdpi/launcher_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/android/app/src/main/res/mipmap-xxhdpi/launcher_icon.png -------------------------------------------------------------------------------- /studFee_client/android/app/src/main/res/mipmap-xxxhdpi/launcher_icon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/android/app/src/main/res/mipmap-xxxhdpi/launcher_icon.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png -------------------------------------------------------------------------------- /studFee_client/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_1024.png -------------------------------------------------------------------------------- /studFee_client/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_128.png -------------------------------------------------------------------------------- /studFee_client/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_16.png -------------------------------------------------------------------------------- /studFee_client/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_256.png -------------------------------------------------------------------------------- /studFee_client/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_32.png -------------------------------------------------------------------------------- /studFee_client/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png -------------------------------------------------------------------------------- /studFee_client/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_64.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-50x50@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-50x50@1x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-50x50@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-50x50@2x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-57x57@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-57x57@1x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-57x57@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-57x57@2x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-72x72@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-72x72@1x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-72x72@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-72x72@2x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png -------------------------------------------------------------------------------- /studFee_client/android/app/src/main/kotlin/com/example/studfees/MainActivity.kt: -------------------------------------------------------------------------------- 1 | package com.students.studfees 2 | 3 | import io.flutter.embedding.android.FlutterActivity 4 | 5 | class MainActivity: FlutterActivity() { 6 | } 7 | -------------------------------------------------------------------------------- /studFee_client/linux/main.cc: -------------------------------------------------------------------------------- 1 | #include "my_application.h" 2 | 3 | int main(int argc, char** argv) { 4 | g_autoptr(MyApplication) app = my_application_new(); 5 | return g_application_run(G_APPLICATION(app), argc, argv); 6 | } 7 | -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hemmyhtec/StudFee_FullStack/HEAD/studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png -------------------------------------------------------------------------------- /studFee_client/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /studFee_client/ios/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /studFee_client/macos/Runner.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 8 | -------------------------------------------------------------------------------- /studFee_client/android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | zipStoreBase=GRADLE_USER_HOME 4 | zipStorePath=wrapper/dists 5 | distributionUrl=https\://services.gradle.org/distributions/gradle-7.4-all.zip 6 | -------------------------------------------------------------------------------- /studFee_client/lib/util/snak_message.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | void showSnackBar(BuildContext context, String test) { 4 | ScaffoldMessenger.of(context).showSnackBar( 5 | SnackBar( 6 | content: Text(test), 7 | ), 8 | ); 9 | } 10 | -------------------------------------------------------------------------------- /studFee_client/macos/Runner/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | import Cocoa 2 | import FlutterMacOS 3 | 4 | @NSApplicationMain 5 | class AppDelegate: FlutterAppDelegate { 6 | override func applicationShouldTerminateAfterLastWindowClosed(_ sender: NSApplication) -> Bool { 7 | return true 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /studFee_client/macos/Runner/Release.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.apple.security.app-sandbox 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /studFee_client/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /studFee_client/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /studFee_client/macos/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /studfeeServer/middleware/validator.js: -------------------------------------------------------------------------------- 1 | const { validationResult } = require('express-validator') 2 | 3 | 4 | module.exports = (req, res, next) => { 5 | const errors = validationResult(req); 6 | if (!errors.isEmpty()) { 7 | return res.render('admin/register', { errors: errors.array() }); 8 | } 9 | next() 10 | } -------------------------------------------------------------------------------- /studfeeServer/middleware/validatorTwo.js: -------------------------------------------------------------------------------- 1 | const { validationResult } = require('express-validator') 2 | 3 | 4 | module.exports = (req, res, next) => { 5 | const errors = validationResult(req); 6 | if (!errors.isEmpty()) { 7 | return res.render('admin/signin', { errors: errors.array() }); 8 | } 9 | next() 10 | } -------------------------------------------------------------------------------- /studfeeServer/middleware/validatorFour.js: -------------------------------------------------------------------------------- 1 | const { validationResult } = require('express-validator') 2 | 3 | 4 | module.exports = (req, res, next) => { 5 | const errors = validationResult(req); 6 | if (!errors.isEmpty()) { 7 | return res.render('resetPassword', { errors: errors.array() }); 8 | } 9 | next() 10 | } -------------------------------------------------------------------------------- /studFee_client/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PreviewsEnabled 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /studfeeServer/middleware/validatorThree.js: -------------------------------------------------------------------------------- 1 | const { validationResult } = require('express-validator') 2 | 3 | 4 | module.exports = (req, res, next) => { 5 | const errors = validationResult(req); 6 | if (!errors.isEmpty()) { 7 | return res.render('admin/create-form', { errors: errors.array() }); 8 | } 9 | next() 10 | } -------------------------------------------------------------------------------- /studFee_client/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /studFee_client/macos/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /studFee_client/lib/util/navigator.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | 3 | void nextScreen(context, page) { 4 | Navigator.push(context, MaterialPageRoute(builder: (context) => page)); 5 | } 6 | 7 | void nextScreenReplace(context, page) { 8 | Navigator.pushReplacement( 9 | context, MaterialPageRoute(builder: (context) => page)); 10 | } 11 | -------------------------------------------------------------------------------- /studFee_client/android/.gitignore: -------------------------------------------------------------------------------- 1 | gradle-wrapper.jar 2 | /.gradle 3 | /captures/ 4 | /gradlew 5 | /gradlew.bat 6 | /local.properties 7 | GeneratedPluginRegistrant.java 8 | 9 | # Remember to never publicly share your keystore. 10 | # See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app 11 | key.properties 12 | **/*.keystore 13 | **/*.jks 14 | -------------------------------------------------------------------------------- /studFee_client/windows/.gitignore: -------------------------------------------------------------------------------- 1 | flutter/ephemeral/ 2 | 3 | # Visual Studio user-specific files. 4 | *.suo 5 | *.user 6 | *.userosscache 7 | *.sln.docstates 8 | 9 | # Visual Studio build-related files. 10 | x64/ 11 | x86/ 12 | 13 | # Visual Studio cache files 14 | # files ending in .cache can be ignored 15 | *.[Cc]ache 16 | # but keep track of directories ending in .cache 17 | !*.[Cc]ache/ 18 | -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md: -------------------------------------------------------------------------------- 1 | # Launch Screen Assets 2 | 3 | You can customize the launch screen with your own desired assets by replacing the image files in this directory. 4 | 5 | You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images. -------------------------------------------------------------------------------- /studFee_client/linux/flutter/generated_plugin_registrant.h: -------------------------------------------------------------------------------- 1 | // 2 | // Generated file. Do not edit. 3 | // 4 | 5 | // clang-format off 6 | 7 | #ifndef GENERATED_PLUGIN_REGISTRANT_ 8 | #define GENERATED_PLUGIN_REGISTRANT_ 9 | 10 | #include 11 | 12 | // Registers Flutter plugins. 13 | void fl_register_plugins(FlPluginRegistry* registry); 14 | 15 | #endif // GENERATED_PLUGIN_REGISTRANT_ 16 | -------------------------------------------------------------------------------- /studFee_client/windows/flutter/generated_plugin_registrant.h: -------------------------------------------------------------------------------- 1 | // 2 | // Generated file. Do not edit. 3 | // 4 | 5 | // clang-format off 6 | 7 | #ifndef GENERATED_PLUGIN_REGISTRANT_ 8 | #define GENERATED_PLUGIN_REGISTRANT_ 9 | 10 | #include 11 | 12 | // Registers Flutter plugins. 13 | void RegisterPlugins(flutter::PluginRegistry* registry); 14 | 15 | #endif // GENERATED_PLUGIN_REGISTRANT_ 16 | -------------------------------------------------------------------------------- /studFee_client/macos/Runner/DebugProfile.entitlements: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | com.apple.security.app-sandbox 6 | 7 | com.apple.security.cs.allow-jit 8 | 9 | com.apple.security.network.server 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /studfeeServer/middleware/authenticate.js: -------------------------------------------------------------------------------- 1 | const passport = require('passport') 2 | 3 | module.exports = (req, res, next)=> { 4 | passport.authenticate('jwt', function(err, user, info){ 5 | if(err) return next(err) 6 | 7 | if(!user) return res.status(401).json({msg: 'Unauthorized Access - No token provided'}) 8 | 9 | req.user = user.id 10 | req.token = token 11 | 12 | next() 13 | 14 | })(req, res, next) 15 | } -------------------------------------------------------------------------------- /studFee_client/android/app/src/debug/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /studFee_client/android/app/src/profile/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /studFee_client/ios/Runner/AppDelegate.swift: -------------------------------------------------------------------------------- 1 | import UIKit 2 | import Flutter 3 | 4 | @UIApplicationMain 5 | @objc class AppDelegate: FlutterAppDelegate { 6 | override func application( 7 | _ application: UIApplication, 8 | didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]? 9 | ) -> Bool { 10 | GeneratedPluginRegistrant.register(with: self) 11 | return super.application(application, didFinishLaunchingWithOptions: launchOptions) 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /studfeeServer/models/Payment.js: -------------------------------------------------------------------------------- 1 | const mongoose = require('mongoose'); 2 | 3 | const paymentSchema = new mongoose.Schema({ 4 | departmentName: { 5 | type: String, 6 | required: true 7 | }, 8 | 9 | levyName: { 10 | type: String, 11 | required: true 12 | }, 13 | feeAmount: { 14 | type: Number, 15 | required: true 16 | }, 17 | 18 | }, { timestamps: true }); 19 | 20 | module.exports = mongoose.model('Payments', paymentSchema); -------------------------------------------------------------------------------- /studFee_client/linux/my_application.h: -------------------------------------------------------------------------------- 1 | #ifndef FLUTTER_MY_APPLICATION_H_ 2 | #define FLUTTER_MY_APPLICATION_H_ 3 | 4 | #include 5 | 6 | G_DECLARE_FINAL_TYPE(MyApplication, my_application, MY, APPLICATION, 7 | GtkApplication) 8 | 9 | /** 10 | * my_application_new: 11 | * 12 | * Creates a new Flutter-based application. 13 | * 14 | * Returns: a new #MyApplication. 15 | */ 16 | MyApplication* my_application_new(); 17 | 18 | #endif // FLUTTER_MY_APPLICATION_H_ 19 | -------------------------------------------------------------------------------- /studFee_client/macos/Runner/MainFlutterWindow.swift: -------------------------------------------------------------------------------- 1 | import Cocoa 2 | import FlutterMacOS 3 | 4 | class MainFlutterWindow: NSWindow { 5 | override func awakeFromNib() { 6 | let flutterViewController = FlutterViewController.init() 7 | let windowFrame = self.frame 8 | self.contentViewController = flutterViewController 9 | self.setFrame(windowFrame, display: true) 10 | 11 | RegisterGeneratedPlugins(registry: flutterViewController) 12 | 13 | super.awakeFromNib() 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /studFee_client/windows/runner/resource.h: -------------------------------------------------------------------------------- 1 | //{{NO_DEPENDENCIES}} 2 | // Microsoft Visual C++ generated include file. 3 | // Used by Runner.rc 4 | // 5 | #define IDI_APP_ICON 101 6 | 7 | // Next default values for new objects 8 | // 9 | #ifdef APSTUDIO_INVOKED 10 | #ifndef APSTUDIO_READONLY_SYMBOLS 11 | #define _APS_NEXT_RESOURCE_VALUE 102 12 | #define _APS_NEXT_COMMAND_VALUE 40001 13 | #define _APS_NEXT_CONTROL_VALUE 1001 14 | #define _APS_NEXT_SYMED_VALUE 101 15 | #endif 16 | #endif 17 | -------------------------------------------------------------------------------- /studFee_client/android/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | 3 | def localPropertiesFile = new File(rootProject.projectDir, "local.properties") 4 | def properties = new Properties() 5 | 6 | assert localPropertiesFile.exists() 7 | localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) } 8 | 9 | def flutterSdkPath = properties.getProperty("flutter.sdk") 10 | assert flutterSdkPath != null, "flutter.sdk not set in local.properties" 11 | apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle" 12 | -------------------------------------------------------------------------------- /studFee_client/android/app/src/main/res/drawable/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /studFee_client/android/app/src/main/res/drawable-v21/launch_background.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "universal", 5 | "filename" : "LaunchImage.png", 6 | "scale" : "1x" 7 | }, 8 | { 9 | "idiom" : "universal", 10 | "filename" : "LaunchImage@2x.png", 11 | "scale" : "2x" 12 | }, 13 | { 14 | "idiom" : "universal", 15 | "filename" : "LaunchImage@3x.png", 16 | "scale" : "3x" 17 | } 18 | ], 19 | "info" : { 20 | "version" : 1, 21 | "author" : "xcode" 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /studFee_client/linux/flutter/generated_plugin_registrant.cc: -------------------------------------------------------------------------------- 1 | // 2 | // Generated file. Do not edit. 3 | // 4 | 5 | // clang-format off 6 | 7 | #include "generated_plugin_registrant.h" 8 | 9 | #include 10 | 11 | void fl_register_plugins(FlPluginRegistry* registry) { 12 | g_autoptr(FlPluginRegistrar) audioplayers_linux_registrar = 13 | fl_plugin_registry_get_registrar_for_plugin(registry, "AudioplayersLinuxPlugin"); 14 | audioplayers_linux_plugin_register_with_registrar(audioplayers_linux_registrar); 15 | } 16 | -------------------------------------------------------------------------------- /studfeeServer/models/Message.js: -------------------------------------------------------------------------------- 1 | const mongoose = require('mongoose') 2 | 3 | const messageSchema = new mongoose.Schema({ 4 | sender: { 5 | type: String, 6 | required: true 7 | }, 8 | receiver: { 9 | type: String, 10 | required: true 11 | }, 12 | message: { 13 | type: String, 14 | required: true 15 | }, 16 | media: { 17 | type: String, 18 | }, 19 | createdAt: { 20 | type: Date, 21 | default: Date.now() 22 | } 23 | }) 24 | 25 | module.exports = mongoose.model('Message', messageSchema ); -------------------------------------------------------------------------------- /studFee_client/windows/flutter/generated_plugin_registrant.cc: -------------------------------------------------------------------------------- 1 | // 2 | // Generated file. Do not edit. 3 | // 4 | 5 | // clang-format off 6 | 7 | #include "generated_plugin_registrant.h" 8 | 9 | #include 10 | #include 11 | 12 | void RegisterPlugins(flutter::PluginRegistry* registry) { 13 | AudioplayersWindowsPluginRegisterWithRegistrar( 14 | registry->GetRegistrarForPlugin("AudioplayersWindowsPlugin")); 15 | FlutterTtsPluginRegisterWithRegistrar( 16 | registry->GetRegistrarForPlugin("FlutterTtsPlugin")); 17 | } 18 | -------------------------------------------------------------------------------- /studFee_client/README.md: -------------------------------------------------------------------------------- 1 | # studfees 2 | 3 | A new Flutter project. 4 | 5 | ## Getting Started 6 | 7 | This project is a starting point for a Flutter application. 8 | 9 | A few resources to get you started if this is your first Flutter project: 10 | 11 | - [Lab: Write your first Flutter app](https://docs.flutter.dev/get-started/codelab) 12 | - [Cookbook: Useful Flutter samples](https://docs.flutter.dev/cookbook) 13 | 14 | For help getting started with Flutter development, view the 15 | [online documentation](https://docs.flutter.dev/), which offers tutorials, 16 | samples, guidance on mobile development, and a full API reference. 17 | -------------------------------------------------------------------------------- /studfeeServer/models/Token.js: -------------------------------------------------------------------------------- 1 | const mongoose = require('mongoose'); 2 | 3 | const tokenSchema = new mongoose.Schema({ 4 | userId: { 5 | type: mongoose.Schema.Types.ObjectId, 6 | ref: 'User', 7 | }, 8 | adminId: { 9 | type: mongoose.Schema.Types.ObjectId, 10 | ref: 'Admin', 11 | 12 | }, 13 | 14 | token: { 15 | type: String, 16 | required: true 17 | }, 18 | 19 | createdAt: { 20 | type: Date, 21 | required: true, 22 | default: Date.now, 23 | expires: 43200 24 | } 25 | 26 | }, { timestamps: true }); 27 | 28 | module.exports = mongoose.model('Tokens', tokenSchema); -------------------------------------------------------------------------------- /studFee_client/macos/Runner/Configs/Warnings.xcconfig: -------------------------------------------------------------------------------- 1 | WARNING_CFLAGS = -Wall -Wconditional-uninitialized -Wnullable-to-nonnull-conversion -Wmissing-method-return-type -Woverlength-strings 2 | GCC_WARN_UNDECLARED_SELECTOR = YES 3 | CLANG_UNDEFINED_BEHAVIOR_SANITIZER_NULLABILITY = YES 4 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE 5 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES 6 | CLANG_WARN_PRAGMA_PACK = YES 7 | CLANG_WARN_STRICT_PROTOTYPES = YES 8 | CLANG_WARN_COMMA = YES 9 | GCC_WARN_STRICT_SELECTOR_MATCH = YES 10 | CLANG_WARN_OBJC_REPEATED_USE_OF_WEAK = YES 11 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES 12 | GCC_WARN_SHADOW = YES 13 | CLANG_WARN_UNREACHABLE_CODE = YES 14 | -------------------------------------------------------------------------------- /studFee_client/lib/provider/user_provider.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:studfees/models/user_model.dart'; 3 | 4 | class UserProvider extends ChangeNotifier { 5 | UserModel _user = UserModel( 6 | id: null, 7 | admissionNumber: '', 8 | password: '', 9 | gender: '', 10 | ugLevel: '', 11 | token: '', 12 | type: '', 13 | fullname: '', 14 | department: '', 15 | yearOfAdmin: '', 16 | email: '', 17 | coverImage: '', 18 | profileImage: '', 19 | ); 20 | 21 | UserModel get user => _user; 22 | void setUser(String user) { 23 | _user = UserModel.fromJson(user); 24 | notifyListeners(); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /studFee_client/macos/Runner/Configs/AppInfo.xcconfig: -------------------------------------------------------------------------------- 1 | // Application-level settings for the Runner target. 2 | // 3 | // This may be replaced with something auto-generated from metadata (e.g., pubspec.yaml) in the 4 | // future. If not, the values below would default to using the project name when this becomes a 5 | // 'flutter create' template. 6 | 7 | // The application's name. By default this is also the title of the Flutter window. 8 | PRODUCT_NAME = studfees 9 | 10 | // The application's bundle identifier 11 | PRODUCT_BUNDLE_IDENTIFIER = com.students.studfees 12 | 13 | // The copyright displayed in application information 14 | PRODUCT_COPYRIGHT = Copyright © 2023 com.example. All rights reserved. 15 | -------------------------------------------------------------------------------- /studfeeServer/config/config.js: -------------------------------------------------------------------------------- 1 | require('dotenv').config() 2 | const mongoose = require('mongoose') 3 | 4 | const connUri = process.env.MONGODB_URI 5 | 6 | 7 | const connectDB = async() => { 8 | mongoose.Promise = global.Promise 9 | mongoose.set('strictQuery', false) 10 | mongoose.connect(connUri, {useNewUrlParser: true, useUnifiedTopology: true }) 11 | 12 | const connection = mongoose.connection 13 | connection.once('open', ()=> console.log('MongoDB -- Dabase Connection Established Successfully!') ) 14 | 15 | connection.on('error', (err) => { 16 | console.log('MongoDB -- Connection error. please try again' + err) 17 | process.exit(); 18 | }) 19 | 20 | } 21 | 22 | module.exports = connectDB; -------------------------------------------------------------------------------- /studFee_client/ios/.gitignore: -------------------------------------------------------------------------------- 1 | **/dgph 2 | *.mode1v3 3 | *.mode2v3 4 | *.moved-aside 5 | *.pbxuser 6 | *.perspectivev3 7 | **/*sync/ 8 | .sconsign.dblite 9 | .tags* 10 | **/.vagrant/ 11 | **/DerivedData/ 12 | Icon? 13 | **/Pods/ 14 | **/.symlinks/ 15 | profile 16 | xcuserdata 17 | **/.generated/ 18 | Flutter/App.framework 19 | Flutter/Flutter.framework 20 | Flutter/Flutter.podspec 21 | Flutter/Generated.xcconfig 22 | Flutter/ephemeral/ 23 | Flutter/app.flx 24 | Flutter/app.zip 25 | Flutter/flutter_assets/ 26 | Flutter/flutter_export_environment.sh 27 | ServiceDefinitions.json 28 | Runner/GeneratedPluginRegistrant.* 29 | 30 | # Exceptions to above rules. 31 | !default.mode1v3 32 | !default.mode2v3 33 | !default.pbxuser 34 | !default.perspectivev3 35 | -------------------------------------------------------------------------------- /studFee_client/android/build.gradle: -------------------------------------------------------------------------------- 1 | buildscript { 2 | ext.kotlin_version = '1.6.10' 3 | repositories { 4 | google() 5 | mavenCentral() 6 | } 7 | 8 | dependencies { 9 | classpath 'com.android.tools.build:gradle:7.1.2' 10 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" 11 | } 12 | } 13 | 14 | allprojects { 15 | repositories { 16 | google() 17 | mavenCentral() 18 | } 19 | } 20 | 21 | rootProject.buildDir = '../build' 22 | subprojects { 23 | project.buildDir = "${rootProject.buildDir}/${project.name}" 24 | } 25 | subprojects { 26 | project.evaluationDependsOn(':app') 27 | } 28 | 29 | task clean(type: Delete) { 30 | delete rootProject.buildDir 31 | } 32 | -------------------------------------------------------------------------------- /studFee_client/lib/util/config.dart: -------------------------------------------------------------------------------- 1 | import 'package:cloudinary_public/cloudinary_public.dart'; 2 | import 'package:flutter/material.dart'; 3 | 4 | // String url = 'http://192.168.101.130:3000'; 5 | String url = 'https://studfees-server.onrender.com'; 6 | 7 | class Config { 8 | // static const appIcon = 'assets/images/logo.png'; 9 | // static const flowerImage = 'assets/images/flower.png'; 10 | // static const onboardScreen = 'assets/images/Girl.jpg'; 11 | static const backgroundColor = Color.fromARGB(255, 24, 36, 48); 12 | static const primaryColor = Color(0xFF3879E9); 13 | static const inputFieldColor = Color.fromARGB(255, 212, 212, 212); 14 | static final cloudinary = 15 | CloudinaryPublic('profiler-app-hemmyhtec', 'ml_default'); 16 | } 17 | -------------------------------------------------------------------------------- /studfeeServer/middleware/jwt.js: -------------------------------------------------------------------------------- 1 | require('dotenv').config 2 | 3 | const jwt = require('jsonwebtoken') 4 | const secretCode = process.env.SECRET_CODE 5 | 6 | const userAuthentication = async (req, res, next) => { 7 | 8 | try { 9 | const token = req.header('x-auth-token') 10 | if(!token) return res.status(403).json({msg: 'No auth token, access denied'}) 11 | 12 | const verified = jwt.verify(token, secretCode) 13 | if(!verified) return res.status(403).json({msg: 'Invalid auth token'}) 14 | 15 | req.user = verified.id 16 | req.token = token 17 | 18 | next() 19 | } catch (error) { 20 | 21 | res.status(500).json({msg: error.message}) 22 | } 23 | } 24 | 25 | module.exports = userAuthentication -------------------------------------------------------------------------------- /studfeeServer/middleware/jwt_web.js: -------------------------------------------------------------------------------- 1 | require('dotenv').config 2 | 3 | const jwt = require('jsonwebtoken'); 4 | 5 | const secretCode = process.env.SECRET_CODE 6 | 7 | function verifyToken(req, res, next) { 8 | try { 9 | const token = req.cookies.token || req.headers.cookie?.split('=')[1]; 10 | 11 | if (!token) { 12 | return res.status(401).send('Unauthorized'); 13 | } 14 | 15 | try { 16 | const user = jwt.verify(token, secretCode); 17 | req.user = user; 18 | next(); 19 | } catch (err) { 20 | return res.status(401).send('Unauthorized'); 21 | } 22 | } catch (err) { 23 | console.log(err) 24 | res.status(401).json({ message: 'Token is not valid' }); 25 | } 26 | } 27 | 28 | 29 | module.exports = verifyToken 30 | -------------------------------------------------------------------------------- /studFee_client/windows/runner/utils.h: -------------------------------------------------------------------------------- 1 | #ifndef RUNNER_UTILS_H_ 2 | #define RUNNER_UTILS_H_ 3 | 4 | #include 5 | #include 6 | 7 | // Creates a console for the process, and redirects stdout and stderr to 8 | // it for both the runner and the Flutter library. 9 | void CreateAndAttachConsole(); 10 | 11 | // Takes a null-terminated wchar_t* encoded in UTF-16 and returns a std::string 12 | // encoded in UTF-8. Returns an empty std::string on failure. 13 | std::string Utf8FromUtf16(const wchar_t* utf16_string); 14 | 15 | // Gets the command line arguments passed in as a std::vector, 16 | // encoded in UTF-8. Returns an empty std::vector on failure. 17 | std::vector GetCommandLineArguments(); 18 | 19 | #endif // RUNNER_UTILS_H_ 20 | -------------------------------------------------------------------------------- /studFee_client/lib/models/dictionary_model.dart: -------------------------------------------------------------------------------- 1 | class ApiResponse { 2 | final String? word; 3 | final String? definition; 4 | final String? example; 5 | final String? pronunciation; 6 | final String? audioUrl; 7 | 8 | ApiResponse({ 9 | required this.word, 10 | required this.definition, 11 | required this.example, 12 | required this.pronunciation, 13 | required this.audioUrl, 14 | }); 15 | 16 | factory ApiResponse.fromJson(Map json) { 17 | return ApiResponse( 18 | word: json['word'], 19 | definition: json['definitions'][0]['definition'], 20 | example: json['definitions'][0]['example'], 21 | pronunciation: json['pronunciation'], 22 | audioUrl: json['phonetics'][0]['audio'], 23 | ); 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /studFee_client/lib/screens/users/books/book_services.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | 3 | import 'package:studfees/models/books_model.dart'; 4 | import 'package:http/http.dart' as http; 5 | 6 | class BookService { 7 | static const _baseUrl = 'https://openlibrary.org'; 8 | 9 | Future> search(String query) async { 10 | http.Response response = 11 | await http.get(Uri.parse('$_baseUrl/search.json?q=$query')); 12 | 13 | if (response.statusCode == 200) { 14 | dynamic data = jsonDecode(response.body); 15 | 16 | final List books = []; 17 | 18 | for (var item in data['docs']) { 19 | final book = Book.fromJson(item); 20 | books.add(book); 21 | } 22 | return books; 23 | } else { 24 | throw Exception('Failed to search books'); 25 | } 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /studFee_client/macos/Flutter/GeneratedPluginRegistrant.swift: -------------------------------------------------------------------------------- 1 | // 2 | // Generated file. Do not edit. 3 | // 4 | 5 | import FlutterMacOS 6 | import Foundation 7 | 8 | import audioplayers_darwin 9 | import flutter_tts 10 | import path_provider_foundation 11 | import shared_preferences_foundation 12 | import sqflite 13 | 14 | func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { 15 | AudioplayersDarwinPlugin.register(with: registry.registrar(forPlugin: "AudioplayersDarwinPlugin")) 16 | FlutterTtsPlugin.register(with: registry.registrar(forPlugin: "FlutterTtsPlugin")) 17 | PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin")) 18 | SharedPreferencesPlugin.register(with: registry.registrar(forPlugin: "SharedPreferencesPlugin")) 19 | SqflitePlugin.register(with: registry.registrar(forPlugin: "SqflitePlugin")) 20 | } 21 | -------------------------------------------------------------------------------- /studFee_client/linux/flutter/generated_plugins.cmake: -------------------------------------------------------------------------------- 1 | # 2 | # Generated file, do not edit. 3 | # 4 | 5 | list(APPEND FLUTTER_PLUGIN_LIST 6 | audioplayers_linux 7 | ) 8 | 9 | list(APPEND FLUTTER_FFI_PLUGIN_LIST 10 | ) 11 | 12 | set(PLUGIN_BUNDLED_LIBRARIES) 13 | 14 | foreach(plugin ${FLUTTER_PLUGIN_LIST}) 15 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/linux plugins/${plugin}) 16 | target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin) 17 | list(APPEND PLUGIN_BUNDLED_LIBRARIES $) 18 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) 19 | endforeach(plugin) 20 | 21 | foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST}) 22 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/linux plugins/${ffi_plugin}) 23 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries}) 24 | endforeach(ffi_plugin) 25 | -------------------------------------------------------------------------------- /studfeeServer/views/error.pug: -------------------------------------------------------------------------------- 1 | doctype html 2 | html(lang='en') 3 | head 4 | meta(charset='utf-8') 5 | meta(name='viewport', content='width=device-width, initial-scale=1') 6 | title Error Message 7 | link(rel='shortcut icon', href='/logo-icon.ico', type='image/x-icon') 8 | link(href='https://cdn.jsdelivr.net/npm/bootstrap@5.2.0/dist/css/bootstrap.min.css', rel='stylesheet', integrity='sha384-gH2yIJqKdNHPEq0n4Mqa/HGKIhSkIHeL5AyhkYV8i59U5AR6csBvApHHNl/vI1Bx', crossorigin='anonymous') 9 | body 10 | img.rounded.mx-auto.d-block(src='/logo.png', alt='StudFee-Logo', width='150px', height='150px') 11 | .alert.alert-danger(role='alert') 12 | | #{msg} 13 | b Retry again please. 14 | script(src='https://cdn.jsdelivr.net/npm/bootstrap@5.2.0/dist/js/bootstrap.bundle.min.js', integrity='sha384-A3rJD856KowSb7dwlZdYEkO39Gagi7vIsF0jrRAoQmDKKtQBHUuLZ9AsSv4jD4Xa', crossorigin='anonymous') -------------------------------------------------------------------------------- /studFee_client/lib/util/routes.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:studfees/components/auth_screen.dart'; 3 | import 'package:studfees/screens/users/profile.dart'; 4 | 5 | Route generateRoute(RouteSettings routeSettings) { 6 | switch (routeSettings.name) { 7 | case AuthScreen.routeName: 8 | return MaterialPageRoute( 9 | settings: routeSettings, 10 | builder: (_) => const AuthScreen(), 11 | ); 12 | case ProfileScreen.routeName: 13 | return MaterialPageRoute( 14 | settings: routeSettings, 15 | builder: (_) => const ProfileScreen(), 16 | ); 17 | default: 18 | return MaterialPageRoute( 19 | settings: routeSettings, 20 | builder: (_) => const Scaffold( 21 | body: Center( 22 | child: Text('Screen does not exit'), 23 | ), 24 | ), 25 | ); 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /studfeeServer/views/success.pug: -------------------------------------------------------------------------------- 1 | doctype html 2 | html(lang='en') 3 | head 4 | meta(charset='utf-8') 5 | meta(name='viewport', content='width=device-width, initial-scale=1') 6 | title Verification Message 7 | link(rel='shortcut icon', href='/logo-icon.ico', type='image/x-icon') 8 | link(href='https://cdn.jsdelivr.net/npm/bootstrap@5.2.0/dist/css/bootstrap.min.css', rel='stylesheet', integrity='sha384-gH2yIJqKdNHPEq0n4Mqa/HGKIhSkIHeL5AyhkYV8i59U5AR6csBvApHHNl/vI1Bx', crossorigin='anonymous') 9 | body 10 | img.rounded.mx-auto.d-block(src='/logo.png', alt='StudFee-Logo', width='150px', height='150px') 11 | .alert.alert-primary(role='alert') 12 | | #{msg} 13 | b Please close this tab 14 | script(src='https://cdn.jsdelivr.net/npm/bootstrap@5.2.0/dist/js/bootstrap.bundle.min.js', integrity='sha384-A3rJD856KowSb7dwlZdYEkO39Gagi7vIsF0jrRAoQmDKKtQBHUuLZ9AsSv4jD4Xa', crossorigin='anonymous') -------------------------------------------------------------------------------- /studFee_client/ios/Flutter/AppFrameworkInfo.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | App 9 | CFBundleIdentifier 10 | io.flutter.flutter.app 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | App 15 | CFBundlePackageType 16 | FMWK 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1.0 23 | MinimumOSVersion 24 | 11.0 25 | 26 | 27 | -------------------------------------------------------------------------------- /studFee_client/windows/flutter/generated_plugins.cmake: -------------------------------------------------------------------------------- 1 | # 2 | # Generated file, do not edit. 3 | # 4 | 5 | list(APPEND FLUTTER_PLUGIN_LIST 6 | audioplayers_windows 7 | flutter_tts 8 | ) 9 | 10 | list(APPEND FLUTTER_FFI_PLUGIN_LIST 11 | ) 12 | 13 | set(PLUGIN_BUNDLED_LIBRARIES) 14 | 15 | foreach(plugin ${FLUTTER_PLUGIN_LIST}) 16 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/windows plugins/${plugin}) 17 | target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin) 18 | list(APPEND PLUGIN_BUNDLED_LIBRARIES $) 19 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) 20 | endforeach(plugin) 21 | 22 | foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST}) 23 | add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/windows plugins/${ffi_plugin}) 24 | list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries}) 25 | endforeach(ffi_plugin) 26 | -------------------------------------------------------------------------------- /studfeeServer/models/ProcessPayment.js: -------------------------------------------------------------------------------- 1 | const mongoose = require('mongoose'); 2 | 3 | const processPaymentSchema = new mongoose.Schema({ 4 | userId: { 5 | type: mongoose.Schema.Types.ObjectId, 6 | ref: 'User', 7 | required: true, 8 | }, 9 | userName: { 10 | type: String, 11 | required: true 12 | }, 13 | userEmail: { 14 | type: String, 15 | required: true 16 | }, 17 | departmentName: { 18 | type: String, 19 | }, 20 | 21 | levyName: { 22 | type: String, 23 | required: true 24 | }, 25 | feeAmount: { 26 | type: Number, 27 | required: true 28 | }, 29 | paymentStatus: { 30 | type: String, 31 | required: true 32 | }, 33 | referenceId: { 34 | type: String, 35 | required: true 36 | }, 37 | 38 | }, { timestamps: true }); 39 | 40 | module.exports = mongoose.model('ProcessPayments', processPaymentSchema); -------------------------------------------------------------------------------- /studFee_client/windows/runner/runner.exe.manifest: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | PerMonitorV2 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /studFee_client/lib/screens/users/chat/chat_list.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:studfees/screens/users/chat/user_list.dart'; 3 | import 'package:studfees/util/config.dart'; 4 | import 'package:studfees/util/navigator.dart'; 5 | 6 | class ChatListScreen extends StatefulWidget { 7 | const ChatListScreen({super.key}); 8 | 9 | @override 10 | State createState() => ChatListScreenState(); 11 | } 12 | 13 | class ChatListScreenState extends State { 14 | @override 15 | Widget build(BuildContext context) { 16 | return Scaffold( 17 | body: ListView( 18 | children: const [ 19 | Center( 20 | child: Text('Chat list'), 21 | ) 22 | ], 23 | ), 24 | floatingActionButton: FloatingActionButton( 25 | backgroundColor: Config.primaryColor, 26 | child: const Icon(Icons.list_sharp), 27 | onPressed: () => nextScreen(context, const UserListScreen()), 28 | ), 29 | ); 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /studfeeServer/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "studfeesserver", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "index.js", 6 | "scripts": { 7 | "start": "node index", 8 | "dev": "cross-env NODE_ENV=development nodemon index" 9 | }, 10 | "keywords": [], 11 | "author": "", 12 | "license": "ISC", 13 | "dependencies": { 14 | "bcrypt": "^5.1.0", 15 | "body-parser": "^1.20.1", 16 | "cookie-parser": "^1.4.6", 17 | "cors": "^2.8.5", 18 | "cross-env": "^7.0.3", 19 | "crypto-js": "^4.1.1", 20 | "dotenv": "^16.0.3", 21 | "express": "^4.18.2", 22 | "express-validator": "^6.15.0", 23 | "fs": "^0.0.1-security", 24 | "http": "^0.0.1-security", 25 | "jwt-simple": "^0.5.6", 26 | "mongoose": "^6.8.4", 27 | "morgan": "^1.10.0", 28 | "nodemailer": "^6.9.0", 29 | "nodemon": "^2.0.20", 30 | "passport": "^0.6.0", 31 | "passport-jwt": "^4.0.1", 32 | "path": "^0.12.7", 33 | "paystack": "^2.0.1", 34 | "pug": "^3.0.2", 35 | "socket.io": "^4.6.0" 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /studFee_client/lib/screens/users/books/book_reader.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_pdfview/flutter_pdfview.dart'; 3 | 4 | class BookReaderScreen extends StatefulWidget { 5 | final String filePath; 6 | 7 | const BookReaderScreen({required this.filePath, Key? key}) : super(key: key); 8 | 9 | @override 10 | // ignore: library_private_types_in_public_api 11 | _BookReaderScreenState createState() => _BookReaderScreenState(); 12 | } 13 | 14 | class _BookReaderScreenState extends State { 15 | // late PDFDocument _document; 16 | late PDFView _pdfView; 17 | 18 | @override 19 | void initState() { 20 | super.initState(); 21 | _loadDocument(); 22 | } 23 | 24 | Future _loadDocument() async { 25 | // final file = File(widget.filePath); 26 | _pdfView = PDFView( 27 | filePath: widget.filePath, 28 | ); 29 | setState(() {}); 30 | } 31 | 32 | @override 33 | Widget build(BuildContext context) { 34 | return Scaffold( 35 | body: _pdfView, 36 | ); 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /studfeeServer/views/successhtm.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Password Reset 8 | 9 | 10 | 11 | 12 | 13 | StudFee-Logo 14 | 17 | 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /studFee_client/web/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "studfees", 3 | "short_name": "studfees", 4 | "start_url": ".", 5 | "display": "standalone", 6 | "background_color": "#0175C2", 7 | "theme_color": "#0175C2", 8 | "description": "A new Flutter project.", 9 | "orientation": "portrait-primary", 10 | "prefer_related_applications": false, 11 | "icons": [ 12 | { 13 | "src": "icons/Icon-192.png", 14 | "sizes": "192x192", 15 | "type": "image/png" 16 | }, 17 | { 18 | "src": "icons/Icon-512.png", 19 | "sizes": "512x512", 20 | "type": "image/png" 21 | }, 22 | { 23 | "src": "icons/Icon-maskable-192.png", 24 | "sizes": "192x192", 25 | "type": "image/png", 26 | "purpose": "maskable" 27 | }, 28 | { 29 | "src": "icons/Icon-maskable-512.png", 30 | "sizes": "512x512", 31 | "type": "image/png", 32 | "purpose": "maskable" 33 | } 34 | ] 35 | } 36 | -------------------------------------------------------------------------------- /studFee_client/windows/runner/flutter_window.h: -------------------------------------------------------------------------------- 1 | #ifndef RUNNER_FLUTTER_WINDOW_H_ 2 | #define RUNNER_FLUTTER_WINDOW_H_ 3 | 4 | #include 5 | #include 6 | 7 | #include 8 | 9 | #include "win32_window.h" 10 | 11 | // A window that does nothing but host a Flutter view. 12 | class FlutterWindow : public Win32Window { 13 | public: 14 | // Creates a new FlutterWindow hosting a Flutter view running |project|. 15 | explicit FlutterWindow(const flutter::DartProject& project); 16 | virtual ~FlutterWindow(); 17 | 18 | protected: 19 | // Win32Window: 20 | bool OnCreate() override; 21 | void OnDestroy() override; 22 | LRESULT MessageHandler(HWND window, UINT const message, WPARAM const wparam, 23 | LPARAM const lparam) noexcept override; 24 | 25 | private: 26 | // The project to run. 27 | flutter::DartProject project_; 28 | 29 | // The Flutter instance hosted by this window. 30 | std::unique_ptr flutter_controller_; 31 | }; 32 | 33 | #endif // RUNNER_FLUTTER_WINDOW_H_ 34 | -------------------------------------------------------------------------------- /studFee_client/android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /studFee_client/android/app/src/main/res/values-night/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 9 | 15 | 18 | 19 | -------------------------------------------------------------------------------- /studFee_client/lib/models/payment_model.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | 3 | // ignore_for_file: public_member_api_docs, sort_constructors_first 4 | class Levy { 5 | final String id; 6 | final String departmentName; 7 | final String levyName; 8 | final int feeAmount; 9 | Levy({ 10 | required this.id, 11 | required this.departmentName, 12 | required this.levyName, 13 | required this.feeAmount, 14 | }); 15 | 16 | Map toMap() { 17 | return { 18 | 'id': id, 19 | 'departmentName': departmentName, 20 | 'levyName': levyName, 21 | 'feeAmount': feeAmount, 22 | }; 23 | } 24 | 25 | factory Levy.fromMap(Map map) { 26 | return Levy( 27 | id: map['_id'] as String, 28 | departmentName: map['departmentName'] as String, 29 | levyName: map['levyName'] as String, 30 | feeAmount: map['feeAmount'] as int, 31 | ); 32 | } 33 | 34 | String toJson() => json.encode(toMap()); 35 | 36 | factory Levy.fromJson(String source) => 37 | Levy.fromMap(json.decode(source) as Map); 38 | } 39 | -------------------------------------------------------------------------------- /studfeeServer/controller/socket.js: -------------------------------------------------------------------------------- 1 | const { Server } = require("socket.io"); 2 | const Message = require("../models/Message"); 3 | 4 | function socket(server) { 5 | const io = new Server(server, { 6 | cors: { 7 | origin: "*", 8 | }, 9 | }); 10 | 11 | io.on("connection", (socket) => { 12 | console.log(`Socket connected: ${socket.id}`); 13 | 14 | socket.on("join", (data) => { 15 | console.log(`User joined: ${data.sender}`); 16 | socket.join(data.sender); 17 | }); 18 | 19 | socket.on("message", async (data) => { 20 | console.log(`Message received: ${data.sender} to ${data.receiver}`); 21 | const message = new Message({ 22 | sender: data.sender, 23 | receiver: data.receiver, 24 | message: data.message, 25 | createdAt: Date.now(), 26 | media: data.media, 27 | }); 28 | await message.save(); 29 | socket.to(data.receiver).emit("message", message); 30 | }); 31 | 32 | socket.on("disconnect", () => { 33 | console.log(`Socket disconnected ${socket.id}`); 34 | }); 35 | }); 36 | } 37 | 38 | module.exports = socket; 39 | -------------------------------------------------------------------------------- /studfeeServer/index.js: -------------------------------------------------------------------------------- 1 | require("dotenv").config(); 2 | 3 | const express = require("express"); 4 | const cors = require("cors"); 5 | const path = require('path'); 6 | const morgan = require("morgan"); 7 | const bodyParser = require("body-parser"); 8 | const connectDB = require("./config/config"); 9 | const routes = require("./routes/router"); 10 | const socket = require("./controller/socket"); 11 | const http = require("http"); 12 | const cookieParser = require("cookie-parser"); 13 | 14 | const app = express(); 15 | const server = http.createServer(app); 16 | socket(server); 17 | 18 | let PORT = process.env.PORT || 3000; 19 | connectDB(); 20 | 21 | app.use(cors()); 22 | app.use(express.json()); 23 | app.use(express.urlencoded({ extended: false })); 24 | app.use(bodyParser.json()); 25 | app.use(cookieParser()); 26 | 27 | app.use(express.static('public')); 28 | 29 | app.set('views', path.join(__dirname, 'views')); 30 | app.set('view engine', 'pug'); 31 | 32 | 33 | if (process.env.NODE_ENV === "development") { 34 | app.use(morgan("dev")); 35 | } 36 | 37 | app.use(routes); 38 | 39 | app.listen(PORT, '0.0.0.0', () => 40 | console.log("Server listening on http://localhost" + PORT + "/") 41 | ); 42 | -------------------------------------------------------------------------------- /studFee_client/test/widget_test.dart: -------------------------------------------------------------------------------- 1 | // This is a basic Flutter widget test. 2 | // 3 | // To perform an interaction with a widget in your test, use the WidgetTester 4 | // utility in the flutter_test package. For example, you can send tap and scroll 5 | // gestures. You can also use WidgetTester to find child widgets in the widget 6 | // tree, read text, and verify that the values of widget properties are correct. 7 | 8 | import 'package:flutter/material.dart'; 9 | import 'package:flutter_test/flutter_test.dart'; 10 | 11 | import 'package:studfees/main.dart'; 12 | 13 | void main() { 14 | testWidgets('Counter increments smoke test', (WidgetTester tester) async { 15 | // Build our app and trigger a frame. 16 | await tester.pumpWidget(const SplashScreen()); 17 | 18 | // Verify that our counter starts at 0. 19 | expect(find.text('0'), findsOneWidget); 20 | expect(find.text('1'), findsNothing); 21 | 22 | // Tap the '+' icon and trigger a frame. 23 | await tester.tap(find.byIcon(Icons.add)); 24 | await tester.pump(); 25 | 26 | // Verify that our counter has incremented. 27 | expect(find.text('0'), findsNothing); 28 | expect(find.text('1'), findsOneWidget); 29 | }); 30 | } 31 | -------------------------------------------------------------------------------- /studFee_client/macos/Runner/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIconFile 10 | 11 | CFBundleIdentifier 12 | $(PRODUCT_BUNDLE_IDENTIFIER) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | $(PRODUCT_NAME) 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | $(FLUTTER_BUILD_NAME) 21 | CFBundleVersion 22 | $(FLUTTER_BUILD_NUMBER) 23 | LSMinimumSystemVersion 24 | $(MACOSX_DEPLOYMENT_TARGET) 25 | NSHumanReadableCopyright 26 | $(PRODUCT_COPYRIGHT) 27 | NSMainNibFile 28 | MainMenu 29 | NSPrincipalClass 30 | NSApplication 31 | 32 | 33 | -------------------------------------------------------------------------------- /studFee_client/lib/models/message_model.dart: -------------------------------------------------------------------------------- 1 | // ignore_for_file: public_member_api_docs, sort_constructors_first 2 | import 'dart:convert'; 3 | 4 | class Message { 5 | final String sender; 6 | final String message; 7 | final String? mediaUrl; 8 | final DateTime? date; 9 | 10 | Message({ 11 | required this.sender, 12 | required this.message, 13 | this.mediaUrl, 14 | required this.date, 15 | }); 16 | 17 | Map toMap() { 18 | return { 19 | 'sender': sender, 20 | 'message': message, 21 | 'mediaUrl': mediaUrl, 22 | 'date': date?.millisecondsSinceEpoch, 23 | }; 24 | } 25 | 26 | factory Message.fromMap(Map map) { 27 | return Message( 28 | sender: map['sender'] as String, 29 | message: map['message'] as String, 30 | mediaUrl: map['mediaUrl'] != null ? map['mediaUrl'] as String : null, 31 | date: map['date'] != null 32 | ? DateTime.fromMillisecondsSinceEpoch(map['date'] as int) 33 | : null, 34 | ); 35 | } 36 | 37 | String toJson() => json.encode(toMap()); 38 | 39 | factory Message.fromJson(String source) => 40 | Message.fromMap(json.decode(source) as Map); 41 | } 42 | -------------------------------------------------------------------------------- /studFee_client/lib/components/grid_box.dart: -------------------------------------------------------------------------------- 1 | // ignore_for_file: public_member_api_docs, sort_constructors_first 2 | import 'package:flutter/material.dart'; 3 | 4 | // ignore: must_be_immutable 5 | class GridBox extends StatelessWidget { 6 | VoidCallback function; 7 | Image image; 8 | String textTitle; 9 | GridBox({ 10 | Key? key, 11 | required this.function, 12 | required this.image, 13 | required this.textTitle, 14 | }) : super(key: key); 15 | 16 | @override 17 | Widget build(BuildContext context) { 18 | return GestureDetector( 19 | onTap: function, 20 | child: Container( 21 | decoration: BoxDecoration( 22 | border: Border.all( 23 | style: BorderStyle.solid, 24 | color: Colors.black12, 25 | ), 26 | borderRadius: BorderRadius.circular(10), 27 | ), 28 | child: Column( 29 | mainAxisAlignment: MainAxisAlignment.center, 30 | children: [ 31 | image, 32 | Text( 33 | textTitle, 34 | textAlign: TextAlign.center, 35 | style: const TextStyle( 36 | fontSize: 15, 37 | fontWeight: FontWeight.w500, 38 | color: Colors.black38, 39 | ), 40 | ), 41 | ], 42 | ), 43 | ), 44 | ); 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /studFee_client/lib/screens/users/dictionary/dic_service.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | import 'package:http/http.dart' as http; 3 | 4 | class DictionaryService { 5 | static const _baseUrl = 6 | 'https://www.dictionaryapi.com/api/v3/references/collegiate/json'; 7 | static const _apiKey = '9c3b151e-629e-49d7-969d-b969c915a8b2'; 8 | 9 | static Future> getAdvancedSearchResults( 10 | String word, { 11 | bool includeSynonyms = false, 12 | bool includeAntonyms = false, 13 | bool includeExamples = false, 14 | }) async { 15 | final queryParams = {'key': _apiKey}; 16 | 17 | if (includeSynonyms) { 18 | queryParams['syn'] = 'true'; 19 | } 20 | 21 | if (includeAntonyms) { 22 | queryParams['ant'] = 'true'; 23 | } 24 | 25 | if (includeExamples) { 26 | queryParams['examples'] = 'true'; 27 | } 28 | 29 | final url = '$_baseUrl/$word?${Uri(queryParameters: queryParams).query}'; 30 | final response = await http.get(Uri.parse(url)); 31 | 32 | if (response.statusCode == 200) { 33 | final jsonResponse = jsonDecode(response.body); 34 | // print(jsonResponse); 35 | if (jsonResponse is List) { 36 | return jsonResponse; 37 | } else { 38 | return [jsonResponse]; 39 | } 40 | } else { 41 | throw Exception('Failed to retrieve search results'); 42 | } 43 | } 44 | 45 | static getWordOfTheDay() {} 46 | } 47 | -------------------------------------------------------------------------------- /studFee_client/lib/components/readonly_textfield.dart: -------------------------------------------------------------------------------- 1 | // ignore_for_file: public_member_api_docs, sort_constructors_first 2 | import 'package:flutter/material.dart'; 3 | 4 | // ignore: must_be_immutable 5 | class ReadOnlyTextField extends StatelessWidget { 6 | TextEditingController controller; 7 | ReadOnlyTextField({ 8 | Key? key, 9 | required this.controller, 10 | }) : super(key: key); 11 | 12 | @override 13 | Widget build(BuildContext context) { 14 | return TextFormField( 15 | controller: controller, 16 | readOnly: true, 17 | decoration: InputDecoration( 18 | suffixStyle: const TextStyle(color: Colors.black54), 19 | labelStyle: const TextStyle(color: Colors.black54, fontSize: 20), 20 | filled: true, 21 | fillColor: const Color.fromARGB(255, 230, 230, 230), 22 | prefixIconColor: Colors.black54, 23 | focusColor: Colors.black, 24 | focusedBorder: UnderlineInputBorder( 25 | borderSide: const BorderSide(color: Colors.white30), 26 | borderRadius: BorderRadius.circular(10)), 27 | errorBorder: UnderlineInputBorder( 28 | borderSide: const BorderSide(color: Colors.red), 29 | borderRadius: BorderRadius.circular(10)), 30 | enabledBorder: UnderlineInputBorder( 31 | borderSide: const BorderSide(color: Colors.white30), 32 | borderRadius: BorderRadius.circular(10)), 33 | ), 34 | ); 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /studFee_client/windows/runner/main.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | 5 | #include "flutter_window.h" 6 | #include "utils.h" 7 | 8 | int APIENTRY wWinMain(_In_ HINSTANCE instance, _In_opt_ HINSTANCE prev, 9 | _In_ wchar_t *command_line, _In_ int show_command) { 10 | // Attach to console when present (e.g., 'flutter run') or create a 11 | // new console when running with a debugger. 12 | if (!::AttachConsole(ATTACH_PARENT_PROCESS) && ::IsDebuggerPresent()) { 13 | CreateAndAttachConsole(); 14 | } 15 | 16 | // Initialize COM, so that it is available for use in the library and/or 17 | // plugins. 18 | ::CoInitializeEx(nullptr, COINIT_APARTMENTTHREADED); 19 | 20 | flutter::DartProject project(L"data"); 21 | 22 | std::vector command_line_arguments = 23 | GetCommandLineArguments(); 24 | 25 | project.set_dart_entrypoint_arguments(std::move(command_line_arguments)); 26 | 27 | FlutterWindow window(project); 28 | Win32Window::Point origin(10, 10); 29 | Win32Window::Size size(1280, 720); 30 | if (!window.CreateAndShow(L"studfees", origin, size)) { 31 | return EXIT_FAILURE; 32 | } 33 | window.SetQuitOnClose(true); 34 | 35 | ::MSG msg; 36 | while (::GetMessage(&msg, nullptr, 0, 0)) { 37 | ::TranslateMessage(&msg); 38 | ::DispatchMessage(&msg); 39 | } 40 | 41 | ::CoUninitialize(); 42 | return EXIT_SUCCESS; 43 | } 44 | -------------------------------------------------------------------------------- /studFee_client/lib/models/books_model.dart: -------------------------------------------------------------------------------- 1 | // ignore_for_file: public_member_api_docs, sort_constructors_first 2 | class Book { 3 | final String title; 4 | final String coverUrl; 5 | final String url; 6 | final String author; 7 | // final List author; 8 | // final String coverId; 9 | // final int publishYear; 10 | // final String language; 11 | // bool bookmarked; 12 | // List recommendedBooks; 13 | 14 | Book({ 15 | required this.url, 16 | required this.title, 17 | required this.author, 18 | // required this.coverId, 19 | required this.coverUrl, 20 | // required this.publishYear, 21 | // required this.language, 22 | // this.bookmarked = false, 23 | // this.recommendedBooks = const [], 24 | }); 25 | 26 | factory Book.fromJson(Map json) { 27 | return Book( 28 | url: json['key'] ?? '', 29 | title: json['title'] ?? '', 30 | author: json['author_name'] != null ? json['author_name'][0] : '', 31 | // author: List.from( 32 | // (json['author_name'] as List).map((name) => name as String)), 33 | // coverId: json['cover_i']?.toString() ?? '', 34 | // publishYear: json['publish_year']?.isNotEmpty == true 35 | // ? int.parse(json['publish_year'][0]) 36 | // : 0, 37 | // language: json['language']?.first ?? '', 38 | coverUrl: json['cover_i'] != null 39 | ? 'https://covers.openlibrary.org/b/id/${json['cover_i']}-M.jpg' 40 | : '', 41 | ); 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /studFee_client/analysis_options.yaml: -------------------------------------------------------------------------------- 1 | # This file configures the analyzer, which statically analyzes Dart code to 2 | # check for errors, warnings, and lints. 3 | # 4 | # The issues identified by the analyzer are surfaced in the UI of Dart-enabled 5 | # IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be 6 | # invoked from the command line by running `flutter analyze`. 7 | 8 | # The following line activates a set of recommended lints for Flutter apps, 9 | # packages, and plugins designed to encourage good coding practices. 10 | include: package:flutter_lints/flutter.yaml 11 | 12 | linter: 13 | # The lint rules applied to this project can be customized in the 14 | # section below to disable rules from the `package:flutter_lints/flutter.yaml` 15 | # included above or to enable additional rules. A list of all available lints 16 | # and their documentation is published at 17 | # https://dart-lang.github.io/linter/lints/index.html. 18 | # 19 | # Instead of disabling a lint rule for the entire project in the 20 | # section below, it can also be suppressed for a single line of code 21 | # or a specific dart file by using the `// ignore: name_of_lint` and 22 | # `// ignore_for_file: name_of_lint` syntax on the line or in the file 23 | # producing the lint. 24 | rules: 25 | # avoid_print: false # Uncomment to disable the `avoid_print` rule 26 | # prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule 27 | 28 | # Additional information about this file can be found at 29 | # https://dart.dev/guides/language/analysis-options 30 | -------------------------------------------------------------------------------- /studFee_client/macos/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "size" : "16x16", 5 | "idiom" : "mac", 6 | "filename" : "app_icon_16.png", 7 | "scale" : "1x" 8 | }, 9 | { 10 | "size" : "16x16", 11 | "idiom" : "mac", 12 | "filename" : "app_icon_32.png", 13 | "scale" : "2x" 14 | }, 15 | { 16 | "size" : "32x32", 17 | "idiom" : "mac", 18 | "filename" : "app_icon_32.png", 19 | "scale" : "1x" 20 | }, 21 | { 22 | "size" : "32x32", 23 | "idiom" : "mac", 24 | "filename" : "app_icon_64.png", 25 | "scale" : "2x" 26 | }, 27 | { 28 | "size" : "128x128", 29 | "idiom" : "mac", 30 | "filename" : "app_icon_128.png", 31 | "scale" : "1x" 32 | }, 33 | { 34 | "size" : "128x128", 35 | "idiom" : "mac", 36 | "filename" : "app_icon_256.png", 37 | "scale" : "2x" 38 | }, 39 | { 40 | "size" : "256x256", 41 | "idiom" : "mac", 42 | "filename" : "app_icon_256.png", 43 | "scale" : "1x" 44 | }, 45 | { 46 | "size" : "256x256", 47 | "idiom" : "mac", 48 | "filename" : "app_icon_512.png", 49 | "scale" : "2x" 50 | }, 51 | { 52 | "size" : "512x512", 53 | "idiom" : "mac", 54 | "filename" : "app_icon_512.png", 55 | "scale" : "1x" 56 | }, 57 | { 58 | "size" : "512x512", 59 | "idiom" : "mac", 60 | "filename" : "app_icon_1024.png", 61 | "scale" : "2x" 62 | } 63 | ], 64 | "info" : { 65 | "version" : 1, 66 | "author" : "xcode" 67 | } 68 | } 69 | -------------------------------------------------------------------------------- /studFee_client/lib/models/process_payment_model.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | 3 | // ignore_for_file: public_member_api_docs, sort_constructors_first 4 | class Payment { 5 | final String? id; 6 | final String? createdAt; 7 | final String? fullName; 8 | final String? userEmail; 9 | final String levyName; 10 | final String? paymentStatus; 11 | final String? referenceId; 12 | final int feeAmount; 13 | Payment({ 14 | this.id, 15 | this.createdAt, 16 | this.fullName, 17 | this.userEmail, 18 | required this.levyName, 19 | this.paymentStatus, 20 | this.referenceId, 21 | required this.feeAmount, 22 | }); 23 | 24 | Map toMap() { 25 | return { 26 | 'id': id, 27 | 'createdAt': createdAt, 28 | 'fullName': fullName, 29 | 'userEmail': userEmail, 30 | 'levyName': levyName, 31 | 'paymentStatus': paymentStatus, 32 | 'referenceId': referenceId, 33 | 'feeAmount': feeAmount, 34 | }; 35 | } 36 | 37 | factory Payment.fromMap(Map map) { 38 | return Payment( 39 | id: map['_id'] as String, 40 | createdAt: map['createdAt'] as String, 41 | fullName: map['userName'] as String, 42 | userEmail: map['userEmail'] as String, 43 | levyName: map['levyName'] as String, 44 | paymentStatus: map['paymentStatus'] as String, 45 | referenceId: map['referenceId'] as String, 46 | feeAmount: map['feeAmount'] as int, 47 | ); 48 | } 49 | 50 | String toJson() => json.encode(toMap()); 51 | 52 | factory Payment.fromJson(String source) => 53 | Payment.fromMap(json.decode(source) as Map); 54 | } 55 | -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Base.lproj/Main.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /studfeeServer/views/resetPassword.pug: -------------------------------------------------------------------------------- 1 | doctype html 2 | html(lang='en') 3 | head 4 | meta(charset='utf-8') 5 | meta(name='viewport', content='width=device-width, initial-scale=1') 6 | title Password Reset 7 | link(rel='shortcut icon', href='/logo-icon.ico', type='image/x-icon') 8 | link(href='https://cdn.jsdelivr.net/npm/bootstrap@5.2.0/dist/css/bootstrap.min.css', rel='stylesheet', integrity='sha384-gH2yIJqKdNHPEq0n4Mqa/HGKIhSkIHeL5AyhkYV8i59U5AR6csBvApHHNl/vI1Bx', crossorigin='anonymous') 9 | body 10 | img.rounded.mx-auto.d-block(src='/logo.png', alt='StudFee-Logo', width='150px', height='150px') 11 | form(method='POST') 12 | .card.shadow-lg.mx-auto(style='width: 90%; margin-top: 50px;') 13 | .card-header 14 | h4 Please enter a new password 15 | .card-body 16 | .mb-3 17 | label.form-label(for='password') New Password 18 | input.form-control(type='password', name='password', aria-describedby='helpId', placeholder='Password') 19 | small#helpId.form-text.text-muted Must be at least 8 chars long 20 | .mb-3 21 | label.form-label(for='confirmpassword') Confirm Password 22 | input.form-control(type='password', name='confirmPassword', aria-describedby='helpId', placeholder='Confirm Password') 23 | small#helpId.form-text.text-muted Confirm Password 24 | .card-footer 25 | button.btn.btn-primary(type='submit') Change Password 26 | if errors 27 | ul 28 | each error in errors 29 | li= error.msg 30 | script(src='https://cdn.jsdelivr.net/npm/bootstrap@5.2.0/dist/js/bootstrap.bundle.min.js', integrity='sha384-A3rJD856KowSb7dwlZdYEkO39Gagi7vIsF0jrRAoQmDKKtQBHUuLZ9AsSv4jD4Xa', crossorigin='anonymous') -------------------------------------------------------------------------------- /studFee_client/lib/components/button.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:google_fonts/google_fonts.dart'; 3 | 4 | import '../util/config.dart'; 5 | 6 | class CustomElevated extends StatefulWidget { 7 | final String buttonText; 8 | final IconData icon; 9 | final VoidCallback function; 10 | 11 | const CustomElevated( 12 | {super.key, 13 | required this.buttonText, 14 | required this.icon, 15 | required this.function}); 16 | 17 | @override 18 | State createState() => _CustomElevatedState(); 19 | } 20 | 21 | class _CustomElevatedState extends State { 22 | bool isLoading = false; 23 | @override 24 | Widget build(BuildContext context) { 25 | return ElevatedButton( 26 | onPressed: widget.function, 27 | style: ElevatedButton.styleFrom( 28 | backgroundColor: Config.primaryColor, 29 | padding: const EdgeInsets.all(20), 30 | shape: RoundedRectangleBorder( 31 | borderRadius: BorderRadius.circular(15), 32 | ), 33 | textStyle: GoogleFonts.inter( 34 | fontSize: 25, 35 | fontWeight: FontWeight.w400, 36 | ), 37 | elevation: 20, 38 | ), 39 | child: isLoading 40 | ? Column( 41 | children: const [ 42 | SizedBox( 43 | height: 15, 44 | ), 45 | CircularProgressIndicator( 46 | color: Colors.black, 47 | ), 48 | ], 49 | ) 50 | : Row( 51 | mainAxisAlignment: MainAxisAlignment.spaceBetween, 52 | children: [ 53 | Text(widget.buttonText), 54 | Icon(widget.icon), 55 | ], 56 | ), 57 | ); 58 | } 59 | } 60 | -------------------------------------------------------------------------------- /studfeeServer/views/admin/signin.pug: -------------------------------------------------------------------------------- 1 | doctype html 2 | html(lang='en') 3 | head 4 | meta(charset='utf-8') 5 | meta(name='viewport', content='width=device-width, initial-scale=1') 6 | title Sign-In Form 7 | link(rel='shortcut icon', href='/logo-icon.ico', type='image/x-icon') 8 | link(href='https://cdn.jsdelivr.net/npm/bootstrap@5.2.0/dist/css/bootstrap.min.css', rel='stylesheet', integrity='sha384-gH2yIJqKdNHPEq0n4Mqa/HGKIhSkIHeL5AyhkYV8i59U5AR6csBvApHHNl/vI1Bx', crossorigin='anonymous') 9 | body 10 | img.rounded.mx-auto.d-block(src='/logo.png', alt='StudFee-Logo', width='150px', height='150px') 11 | .container.my-5 12 | .row.justify-content-center 13 | .col-lg-6.col-md-8 14 | .card.shadow.border-0.rounded-lg.mt-5 15 | .card-header 16 | h3.text-center.font-weight-light.my-4 Sign-In 17 | .card-body 18 | form(method='POST' action="/signin") 19 | .mb-3 20 | label(for='email') Email 21 | input#email.form-control(name='email', type='email', required) 22 | .mb-3 23 | label(for='password') Password 24 | input#password.form-control(name='password', type='password', required) 25 | .mb-3 26 | button.btn.btn-primary.btn-block(type='submit') Login 27 | p.text-center Don't have an account? 28 | a(href='register-admin') Register here 29 | if errors 30 | ul 31 | each error in errors 32 | li= error.msg 33 | 34 | script(src='https://cdn.jsdelivr.net/npm/bootstrap@5.2.0/dist/js/bootstrap.bundle.min.js', integrity='sha384-A3rJD856KowSb7dwlZdYEkO39Gagi7vIsF0jrRAoQmDKKtQBHUuLZ9AsSv4jD4Xa', crossorigin='anonymous') 35 | -------------------------------------------------------------------------------- /studFee_client/windows/runner/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.14) 2 | project(runner LANGUAGES CXX) 3 | 4 | # Define the application target. To change its name, change BINARY_NAME in the 5 | # top-level CMakeLists.txt, not the value here, or `flutter run` will no longer 6 | # work. 7 | # 8 | # Any new source files that you add to the application should be added here. 9 | add_executable(${BINARY_NAME} WIN32 10 | "flutter_window.cpp" 11 | "main.cpp" 12 | "utils.cpp" 13 | "win32_window.cpp" 14 | "${FLUTTER_MANAGED_DIR}/generated_plugin_registrant.cc" 15 | "Runner.rc" 16 | "runner.exe.manifest" 17 | ) 18 | 19 | # Apply the standard set of build settings. This can be removed for applications 20 | # that need different build settings. 21 | apply_standard_settings(${BINARY_NAME}) 22 | 23 | # Add preprocessor definitions for the build version. 24 | target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION=\"${FLUTTER_VERSION}\"") 25 | target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_MAJOR=${FLUTTER_VERSION_MAJOR}") 26 | target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_MINOR=${FLUTTER_VERSION_MINOR}") 27 | target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_PATCH=${FLUTTER_VERSION_PATCH}") 28 | target_compile_definitions(${BINARY_NAME} PRIVATE "FLUTTER_VERSION_BUILD=${FLUTTER_VERSION_BUILD}") 29 | 30 | # Disable Windows macros that collide with C++ standard library functions. 31 | target_compile_definitions(${BINARY_NAME} PRIVATE "NOMINMAX") 32 | 33 | # Add dependency libraries and include directories. Add any application-specific 34 | # dependencies here. 35 | target_link_libraries(${BINARY_NAME} PRIVATE flutter flutter_wrapper_app) 36 | target_include_directories(${BINARY_NAME} PRIVATE "${CMAKE_SOURCE_DIR}") 37 | 38 | # Run the Flutter tool portions of the build. This must not be removed. 39 | add_dependencies(${BINARY_NAME} flutter_assemble) 40 | -------------------------------------------------------------------------------- /studFee_client/android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 8 | 16 | 20 | 21 | 25 | 26 | 27 | 28 | 29 | 30 | 32 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | $(DEVELOPMENT_LANGUAGE) 7 | CFBundleDisplayName 8 | Studfees 9 | CFBundleExecutable 10 | $(EXECUTABLE_NAME) 11 | CFBundleIdentifier 12 | $(PRODUCT_BUNDLE_IDENTIFIER) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | studfees 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | $(FLUTTER_BUILD_NAME) 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | $(FLUTTER_BUILD_NUMBER) 25 | LSRequiresIPhoneOS 26 | 27 | UILaunchStoryboardName 28 | LaunchScreen 29 | UIMainStoryboardFile 30 | Main 31 | UISupportedInterfaceOrientations 32 | 33 | UIInterfaceOrientationPortrait 34 | UIInterfaceOrientationLandscapeLeft 35 | UIInterfaceOrientationLandscapeRight 36 | 37 | UISupportedInterfaceOrientations~ipad 38 | 39 | UIInterfaceOrientationPortrait 40 | UIInterfaceOrientationPortraitUpsideDown 41 | UIInterfaceOrientationLandscapeLeft 42 | UIInterfaceOrientationLandscapeRight 43 | 44 | UIViewControllerBasedStatusBarAppearance 45 | 46 | CADisableMinimumFrameDurationOnPhone 47 | 48 | UIApplicationSupportsIndirectInputEvents 49 | 50 | 51 | 52 | -------------------------------------------------------------------------------- /studFee_client/windows/runner/utils.cpp: -------------------------------------------------------------------------------- 1 | #include "utils.h" 2 | 3 | #include 4 | #include 5 | #include 6 | #include 7 | 8 | #include 9 | 10 | void CreateAndAttachConsole() { 11 | if (::AllocConsole()) { 12 | FILE *unused; 13 | if (freopen_s(&unused, "CONOUT$", "w", stdout)) { 14 | _dup2(_fileno(stdout), 1); 15 | } 16 | if (freopen_s(&unused, "CONOUT$", "w", stderr)) { 17 | _dup2(_fileno(stdout), 2); 18 | } 19 | std::ios::sync_with_stdio(); 20 | FlutterDesktopResyncOutputStreams(); 21 | } 22 | } 23 | 24 | std::vector GetCommandLineArguments() { 25 | // Convert the UTF-16 command line arguments to UTF-8 for the Engine to use. 26 | int argc; 27 | wchar_t** argv = ::CommandLineToArgvW(::GetCommandLineW(), &argc); 28 | if (argv == nullptr) { 29 | return std::vector(); 30 | } 31 | 32 | std::vector command_line_arguments; 33 | 34 | // Skip the first argument as it's the binary name. 35 | for (int i = 1; i < argc; i++) { 36 | command_line_arguments.push_back(Utf8FromUtf16(argv[i])); 37 | } 38 | 39 | ::LocalFree(argv); 40 | 41 | return command_line_arguments; 42 | } 43 | 44 | std::string Utf8FromUtf16(const wchar_t* utf16_string) { 45 | if (utf16_string == nullptr) { 46 | return std::string(); 47 | } 48 | int target_length = ::WideCharToMultiByte( 49 | CP_UTF8, WC_ERR_INVALID_CHARS, utf16_string, 50 | -1, nullptr, 0, nullptr, nullptr); 51 | std::string utf8_string; 52 | if (target_length == 0 || target_length > utf8_string.max_size()) { 53 | return utf8_string; 54 | } 55 | utf8_string.resize(target_length); 56 | int converted_length = ::WideCharToMultiByte( 57 | CP_UTF8, WC_ERR_INVALID_CHARS, utf16_string, 58 | -1, utf8_string.data(), 59 | target_length, nullptr, nullptr); 60 | if (converted_length == 0) { 61 | return std::string(); 62 | } 63 | return utf8_string; 64 | } 65 | -------------------------------------------------------------------------------- /studFee_client/windows/runner/flutter_window.cpp: -------------------------------------------------------------------------------- 1 | #include "flutter_window.h" 2 | 3 | #include 4 | 5 | #include "flutter/generated_plugin_registrant.h" 6 | 7 | FlutterWindow::FlutterWindow(const flutter::DartProject& project) 8 | : project_(project) {} 9 | 10 | FlutterWindow::~FlutterWindow() {} 11 | 12 | bool FlutterWindow::OnCreate() { 13 | if (!Win32Window::OnCreate()) { 14 | return false; 15 | } 16 | 17 | RECT frame = GetClientArea(); 18 | 19 | // The size here must match the window dimensions to avoid unnecessary surface 20 | // creation / destruction in the startup path. 21 | flutter_controller_ = std::make_unique( 22 | frame.right - frame.left, frame.bottom - frame.top, project_); 23 | // Ensure that basic setup of the controller was successful. 24 | if (!flutter_controller_->engine() || !flutter_controller_->view()) { 25 | return false; 26 | } 27 | RegisterPlugins(flutter_controller_->engine()); 28 | SetChildContent(flutter_controller_->view()->GetNativeWindow()); 29 | return true; 30 | } 31 | 32 | void FlutterWindow::OnDestroy() { 33 | if (flutter_controller_) { 34 | flutter_controller_ = nullptr; 35 | } 36 | 37 | Win32Window::OnDestroy(); 38 | } 39 | 40 | LRESULT 41 | FlutterWindow::MessageHandler(HWND hwnd, UINT const message, 42 | WPARAM const wparam, 43 | LPARAM const lparam) noexcept { 44 | // Give Flutter, including plugins, an opportunity to handle window messages. 45 | if (flutter_controller_) { 46 | std::optional result = 47 | flutter_controller_->HandleTopLevelWindowProc(hwnd, message, wparam, 48 | lparam); 49 | if (result) { 50 | return *result; 51 | } 52 | } 53 | 54 | switch (message) { 55 | case WM_FONTCHANGE: 56 | flutter_controller_->engine()->ReloadSystemFonts(); 57 | break; 58 | } 59 | 60 | return Win32Window::MessageHandler(hwnd, message, wparam, lparam); 61 | } 62 | -------------------------------------------------------------------------------- /studFee_client/web/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | studfees 33 | 34 | 35 | 39 | 40 | 41 | 42 | 43 | 57 | 58 | 59 | -------------------------------------------------------------------------------- /studfeeServer/views/admin/register.pug: -------------------------------------------------------------------------------- 1 | doctype html 2 | html(lang='en') 3 | head 4 | meta(charset='utf-8') 5 | meta(name='viewport', content='width=device-width, initial-scale=1') 6 | title Admin Form 7 | link(rel='shortcut icon', href='/logo-icon.ico', type='image/x-icon') 8 | link(href='https://cdn.jsdelivr.net/npm/bootstrap@5.2.0/dist/css/bootstrap.min.css', rel='stylesheet', integrity='sha384-gH2yIJqKdNHPEq0n4Mqa/HGKIhSkIHeL5AyhkYV8i59U5AR6csBvApHHNl/vI1Bx', crossorigin='anonymous') 9 | body 10 | img.rounded.mx-auto.d-block(src='/logo.png', alt='StudFee-Logo', width='150px', height='150px') 11 | .container.my-5 12 | .row.justify-content-center 13 | .col-lg-6.col-md-8 14 | .card.shadow.border-0.rounded-lg.mt-5 15 | .card-header 16 | h3.text-center.font-weight-light.my-4 Register 17 | .card-body 18 | form(method='POST' action="/register-admin") 19 | .mb-3 20 | label(for='name') Full Name 21 | input#name.form-control(name='fullname', type='text', required) 22 | .mb-3 23 | label(for='email') Email 24 | input#email.form-control(name='email', type='email', required) 25 | .mb-3 26 | label(for='password') Password 27 | input#password.form-control(name='password', type='password', required) 28 | .mb-3 29 | label(for='confirmPassword') Confirm Password 30 | input#confirmPassword.form-control(name='confirmPassword', type='password', required) 31 | button.btn.btn-primary.btn-block(type='submit') Register 32 | p.text-center Already have an account? 33 | a(href='/signin') Login here 34 | if errors 35 | ul 36 | each error in errors 37 | li= error.msg 38 | 39 | script(src='https://cdn.jsdelivr.net/npm/bootstrap@5.2.0/dist/js/bootstrap.bundle.min.js', integrity='sha384-A3rJD856KowSb7dwlZdYEkO39Gagi7vIsF0jrRAoQmDKKtQBHUuLZ9AsSv4jD4Xa', crossorigin='anonymous') 40 | -------------------------------------------------------------------------------- /studFee_client/lib/main.dart: -------------------------------------------------------------------------------- 1 | import 'package:easy_splash_screen/easy_splash_screen.dart'; 2 | import 'package:flutter/material.dart'; 3 | import 'package:flutter_dotenv/flutter_dotenv.dart'; 4 | import 'package:google_fonts/google_fonts.dart'; 5 | import 'package:provider/provider.dart'; 6 | import 'package:studfees/components/auth_screen.dart'; 7 | import 'package:studfees/provider/user_provider.dart'; 8 | import 'package:studfees/screens/onboad/onboard.dart'; 9 | import 'package:studfees/services/auth_service.dart'; 10 | import 'package:studfees/util/routes.dart'; 11 | 12 | void main() async { 13 | await dotenv.load(); 14 | runApp( 15 | MultiProvider( 16 | providers: [ 17 | ChangeNotifierProvider( 18 | create: (context) => UserProvider(), 19 | ) 20 | ], 21 | child: const SplashScreen(), 22 | ), 23 | ); 24 | } 25 | 26 | class SplashScreen extends StatefulWidget { 27 | const SplashScreen({super.key}); 28 | 29 | @override 30 | State createState() => _SplashScreenState(); 31 | } 32 | 33 | class _SplashScreenState extends State { 34 | final AuthServiceProvider authServiceProvider = AuthServiceProvider(); 35 | 36 | @override 37 | void initState() { 38 | super.initState(); 39 | authServiceProvider.getUserData(context); 40 | } 41 | 42 | @override 43 | Widget build(BuildContext context) { 44 | return MaterialApp( 45 | theme: ThemeData( 46 | textTheme: GoogleFonts.interTextTheme( 47 | Theme.of(context).textTheme, 48 | ), 49 | ), 50 | onGenerateRoute: (settings) => generateRoute(settings), 51 | home: Provider.of(context).user.token.isNotEmpty 52 | ? const AuthScreen() 53 | : EasySplashScreen( 54 | logo: Image.asset( 55 | 'assets/images/logo.png', 56 | width: 300.0, 57 | height: 300.0, 58 | ), 59 | backgroundColor: Colors.white60, 60 | showLoader: false, 61 | navigator: const OnBoarding(), 62 | durationInSeconds: 5, 63 | ), 64 | ); 65 | } 66 | } 67 | -------------------------------------------------------------------------------- /studfeeServer/views/formmm.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | Password Reset 8 | 9 | 10 | 11 | 12 | 13 | StudFee-Logo 14 |
15 |
16 |
17 |

Please enter a new password

18 |
19 |
20 |
21 | 22 | 23 | Must be at least 8 chars long 24 |
25 |
26 | 27 | 28 | Confirm Password 29 |
30 |
31 | 34 |
35 | 36 |
37 | 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /studFee_client/lib/util/alert_dailog.dart: -------------------------------------------------------------------------------- 1 | // ignore_for_file: public_member_api_docs, sort_constructors_first 2 | import 'package:flutter/material.dart'; 3 | 4 | // ignore: must_be_immutable 5 | class AlertBox extends StatelessWidget { 6 | String alertText; 7 | final VoidCallback callback; 8 | IconData icon; 9 | Color color; 10 | String buttonText; 11 | Color buttonColor; 12 | 13 | AlertBox( 14 | {Key? key, 15 | required this.alertText, 16 | required this.callback, 17 | required this.icon, 18 | required this.color, 19 | required this.buttonText, 20 | required this.buttonColor}) 21 | : super(key: key); 22 | 23 | @override 24 | Widget build(BuildContext context) { 25 | return Dialog( 26 | shape: RoundedRectangleBorder( 27 | borderRadius: BorderRadius.circular(20.0), 28 | ), 29 | child: Padding( 30 | padding: const EdgeInsets.all(8.0), 31 | child: SizedBox( 32 | height: 250, 33 | child: Column( 34 | children: [ 35 | const SizedBox(height: 30), 36 | Icon( 37 | icon, 38 | size: 40, 39 | color: color, 40 | ), 41 | const SizedBox(height: 50), 42 | Center( 43 | child: Text( 44 | alertText, 45 | textAlign: TextAlign.center, 46 | style: const TextStyle( 47 | fontSize: 15.0, 48 | ), 49 | ), 50 | ), 51 | const SizedBox(height: 20), 52 | GestureDetector( 53 | onTap: callback, 54 | child: Container( 55 | height: 50, 56 | width: 100, 57 | decoration: BoxDecoration( 58 | color: buttonColor, 59 | borderRadius: BorderRadius.circular(5), 60 | ), 61 | child: Center( 62 | child: Text( 63 | buttonText, 64 | style: const TextStyle( 65 | color: Colors.white, 66 | ), 67 | ), 68 | ), 69 | ), 70 | ) 71 | ], 72 | ), 73 | ), 74 | ), 75 | ); 76 | } 77 | } 78 | -------------------------------------------------------------------------------- /studfeeServer/views/admin/paymentlist.pug: -------------------------------------------------------------------------------- 1 | doctype html 2 | html(lang="en") 3 | head 4 | meta(charset="UTF-8") 5 | meta(name="viewport", content="width=device-width, initial-scale=1.0") 6 | title Dashboard UI 7 | link(rel="stylesheet", href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css") 8 | script(src="https://code.jquery.com/jquery-3.3.1.slim.min.js") 9 | script(src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js") 10 | script(src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js") 11 | script. 12 | $(function() { 13 | $('#create-fee-btn').click(function() { 14 | $('#content').hide(); 15 | $('#create-form').show(); 16 | }); 17 | $('#payment-list-link').click(function() { 18 | $('#content').hide(); 19 | $('#payment-table').show(); 20 | }); 21 | }); 22 | body 23 | header 24 | nav.navbar.navbar-expand-lg.navbar-light.bg-light 25 | a.navbar-brand(href="#") StudFee 26 | button.navbar-toggler(type="button", data-toggle="collapse", data-target="#navbarNav", aria-controls="navbarNav", aria-expanded="false", aria-label="Toggle navigation") 27 | span.navbar-toggler-icon 28 | div.collapse.navbar-collapse#navbarNav 29 | ul.navbar-nav.ml-auto 30 | li.nav-item.active 31 | a.nav-link(href="./dashboard") Home 32 | span.sr-only (current) 33 | li.nav-item 34 | a.nav-link#create-fee-btn(href="/create-form") Create Fee 35 | li.nav-item 36 | a.nav-link#payment-list-link(href="/admin/paymentlist") Levy List 37 | li.nav-item 38 | form(action="/logout", method="post") 39 | button.btn.btn-primary.nav-item Logout 40 | section.container 41 | .card.mt-4.text-center 42 | .card-header 43 | h3.text-center.font-weight-bold.my-4 Levy Fee List 44 | .card-body 45 | table.table.table-hover 46 | thead 47 | tr 48 | th Department Name 49 | th Levy Name 50 | th Fee Amount 51 | tbody 52 | != paymentTable 53 | section.container#create-form(style="display: none;") 54 | include create-form.pug 55 | footer.footer.py-3 56 | p.text-center Copyright © 2023 57 | -------------------------------------------------------------------------------- /studFee_client/android/app/build.gradle: -------------------------------------------------------------------------------- 1 | def localProperties = new Properties() 2 | def localPropertiesFile = rootProject.file('local.properties') 3 | if (localPropertiesFile.exists()) { 4 | localPropertiesFile.withReader('UTF-8') { reader -> 5 | localProperties.load(reader) 6 | } 7 | } 8 | 9 | def flutterRoot = localProperties.getProperty('flutter.sdk') 10 | if (flutterRoot == null) { 11 | throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") 12 | } 13 | 14 | def flutterVersionCode = localProperties.getProperty('flutter.versionCode') 15 | if (flutterVersionCode == null) { 16 | flutterVersionCode = '1' 17 | } 18 | 19 | def flutterVersionName = localProperties.getProperty('flutter.versionName') 20 | if (flutterVersionName == null) { 21 | flutterVersionName = '1.0' 22 | } 23 | 24 | apply plugin: 'com.android.application' 25 | apply plugin: 'kotlin-android' 26 | apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" 27 | 28 | android { 29 | compileSdkVersion 33 30 | ndkVersion flutter.ndkVersion 31 | 32 | compileOptions { 33 | sourceCompatibility JavaVersion.VERSION_1_8 34 | targetCompatibility JavaVersion.VERSION_1_8 35 | } 36 | 37 | kotlinOptions { 38 | jvmTarget = '1.8' 39 | } 40 | 41 | sourceSets { 42 | main.java.srcDirs += 'src/main/kotlin' 43 | } 44 | 45 | defaultConfig { 46 | // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). 47 | applicationId "com.students.studfees" 48 | // You can update the following values to match your application needs. 49 | // For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-build-configuration. 50 | minSdkVersion 21 51 | targetSdkVersion flutter.targetSdkVersion 52 | versionCode flutterVersionCode.toInteger() 53 | versionName flutterVersionName 54 | } 55 | 56 | buildTypes { 57 | release { 58 | // TODO: Add your own signing config for the release build. 59 | // Signing with the debug keys for now, so `flutter run --release` works. 60 | signingConfig signingConfigs.debug 61 | } 62 | } 63 | } 64 | 65 | flutter { 66 | source '../..' 67 | } 68 | 69 | dependencies { 70 | implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" 71 | } 72 | -------------------------------------------------------------------------------- /studFee_client/lib/components/auth_screen.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:studfees/screens/users/chat/chat_list.dart'; 3 | import 'package:studfees/screens/users/payment.dart'; 4 | import 'package:studfees/screens/users/profile.dart'; 5 | 6 | import '../screens/users/dictionary/dic.dart'; 7 | 8 | class AuthScreen extends StatefulWidget { 9 | static const String routeName = '/auth-screen'; 10 | const AuthScreen({super.key}); 11 | 12 | @override 13 | State createState() => _AuthScreenState(); 14 | } 15 | 16 | class _AuthScreenState extends State { 17 | int index = 0; 18 | final screens = [ 19 | const ProfileScreen(), 20 | const PaymentListScreen(), 21 | DictionaryScreen(), 22 | const ChatListScreen() 23 | ]; 24 | @override 25 | Widget build(BuildContext context) { 26 | return Scaffold( 27 | body: screens[index], 28 | bottomNavigationBar: NavigationBarTheme( 29 | data: NavigationBarThemeData( 30 | labelBehavior: NavigationDestinationLabelBehavior.onlyShowSelected, 31 | indicatorColor: const Color.fromARGB(29, 27, 0, 202), 32 | backgroundColor: Colors.transparent, 33 | labelTextStyle: MaterialStateProperty.all( 34 | const TextStyle( 35 | fontSize: 14, 36 | fontWeight: FontWeight.w500, 37 | ), 38 | ), 39 | ), 40 | child: NavigationBar( 41 | selectedIndex: index, 42 | animationDuration: const Duration(seconds: 3), 43 | onDestinationSelected: (index) => setState(() { 44 | this.index = index; 45 | }), 46 | destinations: const [ 47 | NavigationDestination( 48 | icon: ImageIcon(AssetImage('assets/icons/home-2.png')), 49 | label: 'Home', 50 | ), 51 | NavigationDestination( 52 | icon: ImageIcon(AssetImage('assets/icons/payment.png')), 53 | label: 'Payment', 54 | ), 55 | Center( 56 | child: NavigationDestination( 57 | icon: ImageIcon(AssetImage('assets/icons/book.png')), 58 | label: 'Dictionary', 59 | ), 60 | ), 61 | NavigationDestination( 62 | icon: ImageIcon(AssetImage('assets/icons/people.png')), 63 | label: 'Meet-up', 64 | ), 65 | ], 66 | ), 67 | ), 68 | ); 69 | } 70 | } 71 | -------------------------------------------------------------------------------- /studFee_client/lib/util/handle_errors.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | import 'package:flutter/material.dart'; 3 | import 'package:http/http.dart' as http; 4 | import 'package:studfees/util/snak_message.dart'; 5 | 6 | import 'alert_dailog.dart'; 7 | import 'config.dart'; 8 | 9 | void httpErrorHandle({ 10 | required http.Response response, 11 | required BuildContext context, 12 | required VoidCallback onSuccess, 13 | required VoidCallback onFailed, 14 | }) { 15 | switch (response.statusCode) { 16 | case 200: 17 | showDialog( 18 | context: context, 19 | builder: (BuildContext context) { 20 | return AlertBox( 21 | buttonColor: Config.primaryColor, 22 | buttonText: 'Okay', 23 | color: Config.primaryColor, 24 | alertText: jsonDecode(response.body)['msg'], 25 | callback: onSuccess, 26 | icon: Icons.check, 27 | ); 28 | }, 29 | ); 30 | break; 31 | case 300: 32 | showDialog( 33 | context: context, 34 | builder: (BuildContext context) { 35 | return AlertBox( 36 | buttonColor: Config.primaryColor, 37 | buttonText: 'Okay', 38 | color: Config.primaryColor, 39 | alertText: jsonDecode(response.body)['msg'], 40 | callback: onSuccess, 41 | icon: Icons.check, 42 | ); 43 | }, 44 | ); 45 | break; 46 | case 400: 47 | // showSnackBar(context, jsonDecode(response.body)['msg']); 48 | showDialog( 49 | context: context, 50 | builder: (BuildContext context) { 51 | return AlertBox( 52 | buttonColor: Colors.red, 53 | buttonText: 'Retry', 54 | color: Colors.red, 55 | alertText: jsonDecode(response.body)['msg'], 56 | callback: onFailed, 57 | icon: Icons.sms_failed, 58 | ); 59 | }, 60 | ); 61 | break; 62 | case 500: 63 | showDialog( 64 | context: context, 65 | builder: (BuildContext context) { 66 | return AlertBox( 67 | buttonColor: Colors.red, 68 | buttonText: 'Retry', 69 | color: Colors.red, 70 | alertText: jsonDecode(response.body)['msg'], 71 | callback: onFailed, 72 | icon: Icons.sms_failed, 73 | ); 74 | }, 75 | ); 76 | break; 77 | default: 78 | showSnackBar(context, jsonDecode(response.body)['msg']); 79 | } 80 | } 81 | -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Base.lproj/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /studfeeServer/views/admin/dashboard.pug: -------------------------------------------------------------------------------- 1 | doctype html 2 | html(lang="en") 3 | head 4 | meta(charset="UTF-8") 5 | meta(name="viewport", content="width=device-width, initial-scale=1.0") 6 | title Dashboard UI 7 | link(rel="stylesheet", href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css") 8 | script(src="https://code.jquery.com/jquery-3.3.1.slim.min.js") 9 | script(src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js") 10 | script(src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js") 11 | script. 12 | $(function() { 13 | $('#create-fee-btn').click(function() { 14 | $('#content').hide(); 15 | $('#create-form').show(); 16 | }); 17 | $('#payment-list-link').click(function() { 18 | $('#content').hide(); 19 | $('#payment-table').show(); 20 | }); 21 | }); 22 | body 23 | header 24 | nav.navbar.navbar-expand-lg.navbar-light.bg-light 25 | a.navbar-brand(href="#") StudFee 26 | button.navbar-toggler(type="button", data-toggle="collapse", data-target="#navbarNav", aria-controls="navbarNav", aria-expanded="false", aria-label="Toggle navigation") 27 | span.navbar-toggler-icon 28 | div.collapse.navbar-collapse#navbarNav 29 | ul.navbar-nav.ml-auto 30 | li.nav-item.active 31 | a.nav-link(href="./dashboard") Home 32 | span.sr-only (current) 33 | li.nav-item 34 | a.nav-link#create-fee-btn(href="/create-form") Create Fee 35 | li.nav-item 36 | a.nav-link#payment-list-link(href="/admin/paymentlist") Levy List 37 | li.nav-item 38 | form(action="/logout", method="post") 39 | button.btn.btn-primary.nav-item Logout 40 | section.container 41 | .card.mt-4 42 | .card-header 43 | h3.text-center.font-weight-bold.my-4 Paid Users List 44 | .card-body 45 | table.table.table-hover 46 | thead 47 | tr 48 | th User Name 49 | th User Email 50 | th Levy Name 51 | th Fee Amount 52 | th Payment Status 53 | th Reference Id 54 | tbody 55 | != paidUsersTable 56 | section.container#create-form(style="display: none;") 57 | include create-form.pug 58 | footer.footer.py-3 59 | p.text-center Copyright © 2023 60 | -------------------------------------------------------------------------------- /studFee_client/lib/models/user_model.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | 3 | // ignore_for_file: public_member_api_docs, sort_constructors_first 4 | class UserModel { 5 | final String? id; 6 | final String? fullname; 7 | final String admissionNumber; 8 | final String? department; 9 | final String? yearOfAdmin; 10 | final String? coverImage; 11 | final String? profileImage; 12 | final String password; 13 | final String gender; 14 | final String ugLevel; 15 | final String email; 16 | final String token; 17 | final String type; 18 | UserModel({ 19 | this.id, 20 | this.fullname, 21 | required this.admissionNumber, 22 | this.department, 23 | this.yearOfAdmin, 24 | this.coverImage, 25 | this.profileImage, 26 | required this.password, 27 | required this.gender, 28 | required this.ugLevel, 29 | required this.email, 30 | required this.token, 31 | required this.type, 32 | }); 33 | 34 | Map toMap() { 35 | return { 36 | 'id': id, 37 | 'fullname': fullname, 38 | 'admissionNumber': admissionNumber, 39 | 'department': department, 40 | 'coverImage': coverImage, 41 | 'profileImage': profileImage, 42 | 'yearOfAdmin': yearOfAdmin, 43 | 'password': password, 44 | 'gender': gender, 45 | 'ugLevel': ugLevel, 46 | 'email': email, 47 | 'token': token, 48 | 'type': type, 49 | }; 50 | } 51 | 52 | factory UserModel.fromMap(Map map) { 53 | return UserModel( 54 | id: map['_id'] as String, 55 | fullname: map['fullname'] != null ? map['fullname'] as String : null, 56 | admissionNumber: map['admissionNumber'] as String, 57 | department: 58 | map['department'] != null ? map['department'] as String : null, 59 | coverImage: 60 | map['coverImage'] != null ? map['coverImage'] as String : null, 61 | profileImage: 62 | map['profileImage'] != null ? map['profileImage'] as String : null, 63 | yearOfAdmin: 64 | map['yearOfAdmin'] != null ? map['yearOfAdmin'] as String : null, 65 | password: map['password'] as String, 66 | gender: map['gender'] as String, 67 | ugLevel: map['ugLevel'] as String, 68 | email: map['email'] as String, 69 | token: map['token'] as String, 70 | type: map['type'] as String, 71 | ); 72 | } 73 | 74 | String toJson() => json.encode(toMap()); 75 | 76 | factory UserModel.fromJson(String source) => 77 | UserModel.fromMap(json.decode(source) as Map); 78 | } 79 | -------------------------------------------------------------------------------- /studFee_client/lib/screens/users/pdf_reader.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_pdfview/flutter_pdfview.dart'; 3 | 4 | class PdfViewerWidget extends StatefulWidget { 5 | final String pdfUrl; 6 | 7 | const PdfViewerWidget({Key? key, required this.pdfUrl}) : super(key: key); 8 | 9 | @override 10 | // ignore: library_private_types_in_public_api 11 | _PdfViewerWidgetState createState() => _PdfViewerWidgetState(); 12 | } 13 | 14 | class _PdfViewerWidgetState extends State { 15 | bool _isLoading = true; 16 | int _totalPages = 0; 17 | int _currentPage = 0; 18 | PDFViewController? _pdfViewController; 19 | 20 | @override 21 | Widget build(BuildContext context) { 22 | return Scaffold( 23 | appBar: AppBar(title: const Text('PDF Viewer')), 24 | body: Stack( 25 | children: [ 26 | PDFView( 27 | filePath: widget.pdfUrl, 28 | onRender: (pages) => setState(() { 29 | _isLoading = false; 30 | _totalPages = pages!; 31 | }), 32 | onPageChanged: (page, total) => 33 | setState(() => _currentPage = page!), 34 | onViewCreated: (PDFViewController vc) => _pdfViewController = vc, 35 | ), 36 | if (_isLoading) 37 | const Center(child: CircularProgressIndicator()) 38 | else 39 | Align( 40 | alignment: Alignment.bottomCenter, 41 | child: Container( 42 | height: 40, 43 | margin: const EdgeInsets.only(bottom: 16), 44 | decoration: BoxDecoration( 45 | color: Colors.black.withOpacity(0.5), 46 | borderRadius: BorderRadius.circular(20), 47 | ), 48 | child: Row( 49 | mainAxisAlignment: MainAxisAlignment.center, 50 | children: [ 51 | Text('Page ${_currentPage + 1}/$_totalPages'), 52 | const SizedBox(width: 8), 53 | IconButton( 54 | icon: const Icon(Icons.chevron_left), 55 | onPressed: () => 56 | _pdfViewController?.setPage(_currentPage - 1), 57 | ), 58 | IconButton( 59 | icon: const Icon(Icons.chevron_right), 60 | onPressed: () => 61 | _pdfViewController?.setPage(_currentPage + 1), 62 | ), 63 | ], 64 | ), 65 | ), 66 | ) 67 | ], 68 | ), 69 | ); 70 | } 71 | } 72 | -------------------------------------------------------------------------------- /studFee_client/lib/components/custom_textfield.dart: -------------------------------------------------------------------------------- 1 | // ignore_for_file: public_member_api_docs, sort_constructors_first 2 | import 'package:flutter/material.dart'; 3 | import 'package:google_fonts/google_fonts.dart'; 4 | 5 | // ignore: must_be_immutable 6 | class CustomTextField extends StatefulWidget { 7 | TextEditingController editingController; 8 | TextInputType textInputType; 9 | String labelText; 10 | TextInputAction textInputAction; 11 | // ignore: prefer_typing_uninitialized_variables 12 | var validator; 13 | bool isPassword; 14 | // bool isIcon; 15 | 16 | CustomTextField({ 17 | Key? key, 18 | required this.editingController, 19 | required this.textInputType, 20 | required this.labelText, 21 | required this.textInputAction, 22 | required this.validator, 23 | required this.isPassword, 24 | // required this.isIcon, 25 | }) : super(key: key); 26 | 27 | @override 28 | State createState() => _CustomTextFieldState(); 29 | } 30 | 31 | class _CustomTextFieldState extends State { 32 | bool _obscureText = true; 33 | @override 34 | Widget build(BuildContext context) { 35 | return TextFormField( 36 | validator: widget.validator, 37 | style: GoogleFonts.inter( 38 | color: Colors.black, 39 | fontSize: 20, 40 | ), 41 | textInputAction: widget.textInputAction, 42 | controller: widget.editingController, 43 | keyboardType: widget.textInputType, 44 | obscureText: widget.isPassword ? _obscureText : !_obscureText, 45 | decoration: InputDecoration( 46 | suffixStyle: const TextStyle(color: Colors.black54), 47 | suffixIcon: widget.isPassword 48 | ? GestureDetector( 49 | onTap: () { 50 | setState(() { 51 | _obscureText = !_obscureText; 52 | }); 53 | }, 54 | child: Icon( 55 | !_obscureText ? Icons.visibility_off : Icons.visibility), 56 | ) 57 | : null, 58 | labelStyle: const TextStyle(color: Colors.black54, fontSize: 20), 59 | labelText: widget.labelText, 60 | filled: true, 61 | fillColor: const Color.fromARGB(255, 230, 230, 230), 62 | prefixIconColor: Colors.black54, 63 | focusColor: Colors.black, 64 | focusedBorder: UnderlineInputBorder( 65 | borderSide: const BorderSide(color: Colors.white30), 66 | borderRadius: BorderRadius.circular(10)), 67 | errorBorder: UnderlineInputBorder( 68 | borderSide: const BorderSide(color: Colors.red), 69 | borderRadius: BorderRadius.circular(10)), 70 | enabledBorder: UnderlineInputBorder( 71 | borderSide: const BorderSide(color: Colors.white30), 72 | borderRadius: BorderRadius.circular(10)), 73 | ), 74 | ); 75 | } 76 | } 77 | -------------------------------------------------------------------------------- /studfeeServer/views/admin/create-form.pug: -------------------------------------------------------------------------------- 1 | doctype html 2 | html(lang="en") 3 | head 4 | meta(charset="UTF-8") 5 | meta(name="viewport", content="width=device-width, initial-scale=1.0") 6 | title Dashboard UI 7 | link(rel="stylesheet", href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css") 8 | script(src="https://code.jquery.com/jquery-3.3.1.slim.min.js") 9 | script(src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js") 10 | script(src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js") 11 | script. 12 | $(function() { 13 | $('#create-fee-btn').click(function() { 14 | $('#content').hide(); 15 | $('#create-form').show(); 16 | }); 17 | $('#payment-list-link').click(function() { 18 | $('#content').hide(); 19 | $('#payment-table').show(); 20 | }); 21 | }); 22 | body 23 | header 24 | nav.navbar.navbar-expand-lg.navbar-light.bg-light 25 | a.navbar-brand(href="#") StudFee 26 | button.navbar-toggler(type="button", data-toggle="collapse", data-target="#navbarNav", aria-controls="navbarNav", aria-expanded="false", aria-label="Toggle navigation") 27 | span.navbar-toggler-icon 28 | div.collapse.navbar-collapse#navbarNav 29 | ul.navbar-nav.ml-auto 30 | li.nav-item.active 31 | a.nav-link(href="./dashboard") Home 32 | span.sr-only (current) 33 | li.nav-item 34 | a.nav-link#create-fee-btn(href="/create-form") Create Fee 35 | li.nav-item 36 | a.nav-link#payment-list-link(href="/admin/paymentlist") Levy List 37 | li.nav-item 38 | form(action="/logout", method="post") 39 | button.btn.btn-primary.nav-item Logout 40 | section.container 41 | .container.my-5 42 | .row.justify-content-center 43 | .col-lg-6.col-md-8 44 | .card.shadow.border-0.rounded-lg.mt-5 45 | .card-body 46 | form(method='POST', action='/create-form') 47 | .mb-3 48 | label(for='name') Department Name 49 | input#name.form-control(name='departmentName', type='name', placeholder='Computer Sceince', required) 50 | .mb-3 51 | label(for='name') Levy Name 52 | input#name.form-control(name='levyName', type='name', placeholder='Department Fee', required) 53 | .mb-3 54 | label(for='name') Fee Amount 55 | input#name.form-control(name='feeAmount', type='number', placeholder='#1500', required) 56 | .mb-3 57 | button.btn.btn-primary.btn-block(type='submit') Create 58 | if errors 59 | ul 60 | each error in errors 61 | li= error.msg 62 | footer.footer.py-3 63 | p.text-center Copyright © 2023 64 | -------------------------------------------------------------------------------- /studFee_client/lib/screens/onboad/onboard.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:studfees/components/button.dart'; 3 | import 'package:studfees/screens/auth/login.dart'; 4 | import 'package:studfees/util/navigator.dart'; 5 | 6 | class OnBoarding extends StatefulWidget { 7 | const OnBoarding({super.key}); 8 | 9 | @override 10 | State createState() => _OnBoardingState(); 11 | } 12 | 13 | class _OnBoardingState extends State { 14 | @override 15 | Widget build(BuildContext context) { 16 | return Scaffold( 17 | body: Container( 18 | decoration: const BoxDecoration( 19 | image: DecorationImage( 20 | image: AssetImage('assets/images/student.jpg'), 21 | fit: BoxFit.cover, 22 | ), 23 | ), 24 | child: ListView( 25 | reverse: true, 26 | children: [ 27 | Column( 28 | mainAxisAlignment: MainAxisAlignment.end, 29 | mainAxisSize: MainAxisSize.max, 30 | children: [ 31 | Container( 32 | padding: const EdgeInsets.all(10.0), 33 | decoration: BoxDecoration( 34 | color: const Color.fromARGB(197, 255, 255, 255), 35 | borderRadius: BorderRadius.circular(20), 36 | ), 37 | height: 400.0, 38 | child: Column( 39 | crossAxisAlignment: CrossAxisAlignment.start, 40 | children: [ 41 | const ListTile( 42 | title: Text( 43 | "Student's Levy Payment Solution", 44 | style: TextStyle( 45 | fontSize: 55.0, 46 | fontWeight: FontWeight.w900, 47 | ), 48 | ), 49 | subtitle: Text( 50 | 'This app is designed to make it easy for \nstudents to pay their levies and manage their account.', 51 | style: TextStyle( 52 | fontSize: 20, 53 | fontWeight: FontWeight.w300, 54 | ), 55 | ), 56 | ), 57 | const SizedBox(height: 30), 58 | Padding( 59 | padding: const EdgeInsets.only(left: 15, right: 15), 60 | child: CustomElevated( 61 | buttonText: 'Get Started', 62 | icon: Icons.arrow_forward, 63 | function: () { 64 | nextScreen( 65 | context, 66 | const LoginScreen(), 67 | ); 68 | }, 69 | ), 70 | ) 71 | ], 72 | ), 73 | ) 74 | ], 75 | ), 76 | ], 77 | ), 78 | ), 79 | ); 80 | } 81 | } 82 | -------------------------------------------------------------------------------- /studFee_client/linux/flutter/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # This file controls Flutter-level build steps. It should not be edited. 2 | cmake_minimum_required(VERSION 3.10) 3 | 4 | set(EPHEMERAL_DIR "${CMAKE_CURRENT_SOURCE_DIR}/ephemeral") 5 | 6 | # Configuration provided via flutter tool. 7 | include(${EPHEMERAL_DIR}/generated_config.cmake) 8 | 9 | # TODO: Move the rest of this into files in ephemeral. See 10 | # https://github.com/flutter/flutter/issues/57146. 11 | 12 | # Serves the same purpose as list(TRANSFORM ... PREPEND ...), 13 | # which isn't available in 3.10. 14 | function(list_prepend LIST_NAME PREFIX) 15 | set(NEW_LIST "") 16 | foreach(element ${${LIST_NAME}}) 17 | list(APPEND NEW_LIST "${PREFIX}${element}") 18 | endforeach(element) 19 | set(${LIST_NAME} "${NEW_LIST}" PARENT_SCOPE) 20 | endfunction() 21 | 22 | # === Flutter Library === 23 | # System-level dependencies. 24 | find_package(PkgConfig REQUIRED) 25 | pkg_check_modules(GTK REQUIRED IMPORTED_TARGET gtk+-3.0) 26 | pkg_check_modules(GLIB REQUIRED IMPORTED_TARGET glib-2.0) 27 | pkg_check_modules(GIO REQUIRED IMPORTED_TARGET gio-2.0) 28 | 29 | set(FLUTTER_LIBRARY "${EPHEMERAL_DIR}/libflutter_linux_gtk.so") 30 | 31 | # Published to parent scope for install step. 32 | set(FLUTTER_LIBRARY ${FLUTTER_LIBRARY} PARENT_SCOPE) 33 | set(FLUTTER_ICU_DATA_FILE "${EPHEMERAL_DIR}/icudtl.dat" PARENT_SCOPE) 34 | set(PROJECT_BUILD_DIR "${PROJECT_DIR}/build/" PARENT_SCOPE) 35 | set(AOT_LIBRARY "${PROJECT_DIR}/build/lib/libapp.so" PARENT_SCOPE) 36 | 37 | list(APPEND FLUTTER_LIBRARY_HEADERS 38 | "fl_basic_message_channel.h" 39 | "fl_binary_codec.h" 40 | "fl_binary_messenger.h" 41 | "fl_dart_project.h" 42 | "fl_engine.h" 43 | "fl_json_message_codec.h" 44 | "fl_json_method_codec.h" 45 | "fl_message_codec.h" 46 | "fl_method_call.h" 47 | "fl_method_channel.h" 48 | "fl_method_codec.h" 49 | "fl_method_response.h" 50 | "fl_plugin_registrar.h" 51 | "fl_plugin_registry.h" 52 | "fl_standard_message_codec.h" 53 | "fl_standard_method_codec.h" 54 | "fl_string_codec.h" 55 | "fl_value.h" 56 | "fl_view.h" 57 | "flutter_linux.h" 58 | ) 59 | list_prepend(FLUTTER_LIBRARY_HEADERS "${EPHEMERAL_DIR}/flutter_linux/") 60 | add_library(flutter INTERFACE) 61 | target_include_directories(flutter INTERFACE 62 | "${EPHEMERAL_DIR}" 63 | ) 64 | target_link_libraries(flutter INTERFACE "${FLUTTER_LIBRARY}") 65 | target_link_libraries(flutter INTERFACE 66 | PkgConfig::GTK 67 | PkgConfig::GLIB 68 | PkgConfig::GIO 69 | ) 70 | add_dependencies(flutter flutter_assemble) 71 | 72 | # === Flutter tool backend === 73 | # _phony_ is a non-existent file to force this command to run every time, 74 | # since currently there's no way to get a full input/output list from the 75 | # flutter tool. 76 | add_custom_command( 77 | OUTPUT ${FLUTTER_LIBRARY} ${FLUTTER_LIBRARY_HEADERS} 78 | ${CMAKE_CURRENT_BINARY_DIR}/_phony_ 79 | COMMAND ${CMAKE_COMMAND} -E env 80 | ${FLUTTER_TOOL_ENVIRONMENT} 81 | "${FLUTTER_ROOT}/packages/flutter_tools/bin/tool_backend.sh" 82 | ${FLUTTER_TARGET_PLATFORM} ${CMAKE_BUILD_TYPE} 83 | VERBATIM 84 | ) 85 | add_custom_target(flutter_assemble DEPENDS 86 | "${FLUTTER_LIBRARY}" 87 | ${FLUTTER_LIBRARY_HEADERS} 88 | ) 89 | -------------------------------------------------------------------------------- /studFee_client/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "size" : "20x20", 5 | "idiom" : "iphone", 6 | "filename" : "Icon-App-20x20@2x.png", 7 | "scale" : "2x" 8 | }, 9 | { 10 | "size" : "20x20", 11 | "idiom" : "iphone", 12 | "filename" : "Icon-App-20x20@3x.png", 13 | "scale" : "3x" 14 | }, 15 | { 16 | "size" : "29x29", 17 | "idiom" : "iphone", 18 | "filename" : "Icon-App-29x29@1x.png", 19 | "scale" : "1x" 20 | }, 21 | { 22 | "size" : "29x29", 23 | "idiom" : "iphone", 24 | "filename" : "Icon-App-29x29@2x.png", 25 | "scale" : "2x" 26 | }, 27 | { 28 | "size" : "29x29", 29 | "idiom" : "iphone", 30 | "filename" : "Icon-App-29x29@3x.png", 31 | "scale" : "3x" 32 | }, 33 | { 34 | "size" : "40x40", 35 | "idiom" : "iphone", 36 | "filename" : "Icon-App-40x40@2x.png", 37 | "scale" : "2x" 38 | }, 39 | { 40 | "size" : "40x40", 41 | "idiom" : "iphone", 42 | "filename" : "Icon-App-40x40@3x.png", 43 | "scale" : "3x" 44 | }, 45 | { 46 | "size" : "60x60", 47 | "idiom" : "iphone", 48 | "filename" : "Icon-App-60x60@2x.png", 49 | "scale" : "2x" 50 | }, 51 | { 52 | "size" : "60x60", 53 | "idiom" : "iphone", 54 | "filename" : "Icon-App-60x60@3x.png", 55 | "scale" : "3x" 56 | }, 57 | { 58 | "size" : "20x20", 59 | "idiom" : "ipad", 60 | "filename" : "Icon-App-20x20@1x.png", 61 | "scale" : "1x" 62 | }, 63 | { 64 | "size" : "20x20", 65 | "idiom" : "ipad", 66 | "filename" : "Icon-App-20x20@2x.png", 67 | "scale" : "2x" 68 | }, 69 | { 70 | "size" : "29x29", 71 | "idiom" : "ipad", 72 | "filename" : "Icon-App-29x29@1x.png", 73 | "scale" : "1x" 74 | }, 75 | { 76 | "size" : "29x29", 77 | "idiom" : "ipad", 78 | "filename" : "Icon-App-29x29@2x.png", 79 | "scale" : "2x" 80 | }, 81 | { 82 | "size" : "40x40", 83 | "idiom" : "ipad", 84 | "filename" : "Icon-App-40x40@1x.png", 85 | "scale" : "1x" 86 | }, 87 | { 88 | "size" : "40x40", 89 | "idiom" : "ipad", 90 | "filename" : "Icon-App-40x40@2x.png", 91 | "scale" : "2x" 92 | }, 93 | { 94 | "size" : "76x76", 95 | "idiom" : "ipad", 96 | "filename" : "Icon-App-76x76@1x.png", 97 | "scale" : "1x" 98 | }, 99 | { 100 | "size" : "76x76", 101 | "idiom" : "ipad", 102 | "filename" : "Icon-App-76x76@2x.png", 103 | "scale" : "2x" 104 | }, 105 | { 106 | "size" : "83.5x83.5", 107 | "idiom" : "ipad", 108 | "filename" : "Icon-App-83.5x83.5@2x.png", 109 | "scale" : "2x" 110 | }, 111 | { 112 | "size" : "1024x1024", 113 | "idiom" : "ios-marketing", 114 | "filename" : "Icon-App-1024x1024@1x.png", 115 | "scale" : "1x" 116 | } 117 | ], 118 | "info" : { 119 | "version" : 1, 120 | "author" : "xcode" 121 | } 122 | } 123 | -------------------------------------------------------------------------------- /studFee_client/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 37 | 38 | 39 | 40 | 41 | 42 | 52 | 54 | 60 | 61 | 62 | 63 | 69 | 71 | 77 | 78 | 79 | 80 | 82 | 83 | 86 | 87 | 88 | -------------------------------------------------------------------------------- /studFee_client/macos/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 37 | 38 | 39 | 40 | 41 | 42 | 52 | 54 | 60 | 61 | 62 | 63 | 69 | 71 | 77 | 78 | 79 | 80 | 82 | 83 | 86 | 87 | 88 | -------------------------------------------------------------------------------- /studFee_client/windows/runner/Runner.rc: -------------------------------------------------------------------------------- 1 | // Microsoft Visual C++ generated resource script. 2 | // 3 | #pragma code_page(65001) 4 | #include "resource.h" 5 | 6 | #define APSTUDIO_READONLY_SYMBOLS 7 | ///////////////////////////////////////////////////////////////////////////// 8 | // 9 | // Generated from the TEXTINCLUDE 2 resource. 10 | // 11 | #include "winres.h" 12 | 13 | ///////////////////////////////////////////////////////////////////////////// 14 | #undef APSTUDIO_READONLY_SYMBOLS 15 | 16 | ///////////////////////////////////////////////////////////////////////////// 17 | // English (United States) resources 18 | 19 | #if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU) 20 | LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US 21 | 22 | #ifdef APSTUDIO_INVOKED 23 | ///////////////////////////////////////////////////////////////////////////// 24 | // 25 | // TEXTINCLUDE 26 | // 27 | 28 | 1 TEXTINCLUDE 29 | BEGIN 30 | "resource.h\0" 31 | END 32 | 33 | 2 TEXTINCLUDE 34 | BEGIN 35 | "#include ""winres.h""\r\n" 36 | "\0" 37 | END 38 | 39 | 3 TEXTINCLUDE 40 | BEGIN 41 | "\r\n" 42 | "\0" 43 | END 44 | 45 | #endif // APSTUDIO_INVOKED 46 | 47 | 48 | ///////////////////////////////////////////////////////////////////////////// 49 | // 50 | // Icon 51 | // 52 | 53 | // Icon with lowest ID value placed first to ensure application icon 54 | // remains consistent on all systems. 55 | IDI_APP_ICON ICON "resources\\app_icon.ico" 56 | 57 | 58 | ///////////////////////////////////////////////////////////////////////////// 59 | // 60 | // Version 61 | // 62 | 63 | #if defined(FLUTTER_VERSION_MAJOR) && defined(FLUTTER_VERSION_MINOR) && defined(FLUTTER_VERSION_PATCH) && defined(FLUTTER_VERSION_BUILD) 64 | #define VERSION_AS_NUMBER FLUTTER_VERSION_MAJOR,FLUTTER_VERSION_MINOR,FLUTTER_VERSION_PATCH,FLUTTER_VERSION_BUILD 65 | #else 66 | #define VERSION_AS_NUMBER 1,0,0,0 67 | #endif 68 | 69 | #if defined(FLUTTER_VERSION) 70 | #define VERSION_AS_STRING FLUTTER_VERSION 71 | #else 72 | #define VERSION_AS_STRING "1.0.0" 73 | #endif 74 | 75 | VS_VERSION_INFO VERSIONINFO 76 | FILEVERSION VERSION_AS_NUMBER 77 | PRODUCTVERSION VERSION_AS_NUMBER 78 | FILEFLAGSMASK VS_FFI_FILEFLAGSMASK 79 | #ifdef _DEBUG 80 | FILEFLAGS VS_FF_DEBUG 81 | #else 82 | FILEFLAGS 0x0L 83 | #endif 84 | FILEOS VOS__WINDOWS32 85 | FILETYPE VFT_APP 86 | FILESUBTYPE 0x0L 87 | BEGIN 88 | BLOCK "StringFileInfo" 89 | BEGIN 90 | BLOCK "040904e4" 91 | BEGIN 92 | VALUE "CompanyName", "com.example" "\0" 93 | VALUE "FileDescription", "studfees" "\0" 94 | VALUE "FileVersion", VERSION_AS_STRING "\0" 95 | VALUE "InternalName", "studfees" "\0" 96 | VALUE "LegalCopyright", "Copyright (C) 2023 com.example. All rights reserved." "\0" 97 | VALUE "OriginalFilename", "studfees.exe" "\0" 98 | VALUE "ProductName", "studfees" "\0" 99 | VALUE "ProductVersion", VERSION_AS_STRING "\0" 100 | END 101 | END 102 | BLOCK "VarFileInfo" 103 | BEGIN 104 | VALUE "Translation", 0x409, 1252 105 | END 106 | END 107 | 108 | #endif // English (United States) resources 109 | ///////////////////////////////////////////////////////////////////////////// 110 | 111 | 112 | 113 | #ifndef APSTUDIO_INVOKED 114 | ///////////////////////////////////////////////////////////////////////////// 115 | // 116 | // Generated from the TEXTINCLUDE 3 resource. 117 | // 118 | 119 | 120 | ///////////////////////////////////////////////////////////////////////////// 121 | #endif // not APSTUDIO_INVOKED 122 | -------------------------------------------------------------------------------- /studfeeServer/models/Admin.js: -------------------------------------------------------------------------------- 1 | require('dotenv').config 2 | 3 | const mongoose = require('mongoose') 4 | const Schema = mongoose.Schema 5 | const bcrypt = require('bcrypt') 6 | const jwt = require('jsonwebtoken') 7 | const crypto = require('crypto') 8 | const Token = require('../models/Token') 9 | 10 | 11 | const secretCode = process.env.SECRET_CODE 12 | 13 | 14 | const adminScheme = new Schema({ 15 | fullname: { 16 | type: String, 17 | }, 18 | profileImage: { 19 | type: String, 20 | required: false 21 | }, 22 | password: { 23 | type: String, 24 | require: true, 25 | validate: { 26 | validator: (value) => { 27 | return value.length > 8; 28 | }, 29 | message: 'Your password is less than 8 characters' 30 | } 31 | }, 32 | isVerified: { 33 | type: Boolean, 34 | default: false 35 | }, 36 | email: { 37 | type: String, 38 | unique: true, 39 | required: true, 40 | trim: true, 41 | validate: { 42 | validator: (value) => { 43 | const re = /^(([^<>()[\]\.,;:\s@\"]+(\.[^<>()[\]\.,;:\s@\"]+)*)|(\".+\"))@(([^<>()[\]\.,;:\s@\"]+\.)+[^<>()[\]\.,;:\s@\"]{2,})$/i; 44 | return value.match(re); 45 | }, 46 | message: 'Please enter a valid email' 47 | } 48 | }, 49 | type: { 50 | type: String, 51 | default: 'Admin' 52 | }, 53 | resetPasswordToken: { 54 | type: String, 55 | required: false 56 | }, 57 | 58 | resetPasswordExpires: { 59 | type: Date, 60 | required: false 61 | } 62 | }, { timestamps: true }) 63 | 64 | 65 | //Hashing Users Password 66 | adminScheme.pre('save', function(next) { 67 | var user = this; 68 | if(this.isModified('password') || this.isNew ) { 69 | bcrypt.genSalt(10, function(err, salt) { 70 | if(err) return next(err); 71 | bcrypt.hash(user.password, salt, function(err, hash) { 72 | if(err) return next(err); 73 | user.password = hash; 74 | next() 75 | }) 76 | }) 77 | } else { 78 | return next(); 79 | } 80 | }) 81 | 82 | 83 | //Comparing Password 84 | adminScheme.methods.comparePassword = function(passw, cb){ 85 | bcrypt.compare(passw, this.password, function(err, isMatch){ 86 | if(err) return cb(err) 87 | cb(null, isMatch) 88 | }) 89 | } 90 | 91 | //Set Session 92 | adminScheme.methods.generateJWT = function(){ 93 | const today = new Date() 94 | const expireDate = new Date(today) 95 | 96 | expireDate.setDate(today.getDate() + 5) 97 | 98 | let payload = { 99 | id: this._id, 100 | email: this.email, 101 | fullname: this.fullname, 102 | } 103 | 104 | return jwt.sign(payload, secretCode, { 105 | expiresIn: parseInt(expireDate.getTime() / 1000, 10) 106 | }) 107 | } 108 | 109 | //Reset Password token for user 110 | adminScheme.methods.generatePasswordReset = function(){ 111 | this.resetPasswordToken = crypto.randomBytes(20).toString('hex') 112 | this.resetPasswordExpires = Date.now() + 3600000; //expires in an hour 113 | } 114 | 115 | 116 | //Regenerate verification token for user 117 | adminScheme.methods.generateVerificationToken = function(){ 118 | let payload = { 119 | adminId: this._id, 120 | token: crypto.randomBytes(20).toString('hex') 121 | } 122 | 123 | return new Token(payload) 124 | } 125 | 126 | const Admin = mongoose.model('Admin', adminScheme) 127 | module.exports = Admin -------------------------------------------------------------------------------- /studFee_client/windows/runner/win32_window.h: -------------------------------------------------------------------------------- 1 | #ifndef RUNNER_WIN32_WINDOW_H_ 2 | #define RUNNER_WIN32_WINDOW_H_ 3 | 4 | #include 5 | 6 | #include 7 | #include 8 | #include 9 | 10 | // A class abstraction for a high DPI-aware Win32 Window. Intended to be 11 | // inherited from by classes that wish to specialize with custom 12 | // rendering and input handling 13 | class Win32Window { 14 | public: 15 | struct Point { 16 | unsigned int x; 17 | unsigned int y; 18 | Point(unsigned int x, unsigned int y) : x(x), y(y) {} 19 | }; 20 | 21 | struct Size { 22 | unsigned int width; 23 | unsigned int height; 24 | Size(unsigned int width, unsigned int height) 25 | : width(width), height(height) {} 26 | }; 27 | 28 | Win32Window(); 29 | virtual ~Win32Window(); 30 | 31 | // Creates and shows a win32 window with |title| and position and size using 32 | // |origin| and |size|. New windows are created on the default monitor. Window 33 | // sizes are specified to the OS in physical pixels, hence to ensure a 34 | // consistent size to will treat the width height passed in to this function 35 | // as logical pixels and scale to appropriate for the default monitor. Returns 36 | // true if the window was created successfully. 37 | bool CreateAndShow(const std::wstring& title, 38 | const Point& origin, 39 | const Size& size); 40 | 41 | // Release OS resources associated with window. 42 | void Destroy(); 43 | 44 | // Inserts |content| into the window tree. 45 | void SetChildContent(HWND content); 46 | 47 | // Returns the backing Window handle to enable clients to set icon and other 48 | // window properties. Returns nullptr if the window has been destroyed. 49 | HWND GetHandle(); 50 | 51 | // If true, closing this window will quit the application. 52 | void SetQuitOnClose(bool quit_on_close); 53 | 54 | // Return a RECT representing the bounds of the current client area. 55 | RECT GetClientArea(); 56 | 57 | protected: 58 | // Processes and route salient window messages for mouse handling, 59 | // size change and DPI. Delegates handling of these to member overloads that 60 | // inheriting classes can handle. 61 | virtual LRESULT MessageHandler(HWND window, 62 | UINT const message, 63 | WPARAM const wparam, 64 | LPARAM const lparam) noexcept; 65 | 66 | // Called when CreateAndShow is called, allowing subclass window-related 67 | // setup. Subclasses should return false if setup fails. 68 | virtual bool OnCreate(); 69 | 70 | // Called when Destroy is called. 71 | virtual void OnDestroy(); 72 | 73 | private: 74 | friend class WindowClassRegistrar; 75 | 76 | // OS callback called by message pump. Handles the WM_NCCREATE message which 77 | // is passed when the non-client area is being created and enables automatic 78 | // non-client DPI scaling so that the non-client area automatically 79 | // responsponds to changes in DPI. All other messages are handled by 80 | // MessageHandler. 81 | static LRESULT CALLBACK WndProc(HWND const window, 82 | UINT const message, 83 | WPARAM const wparam, 84 | LPARAM const lparam) noexcept; 85 | 86 | // Retrieves a class instance pointer for |window| 87 | static Win32Window* GetThisFromHandle(HWND const window) noexcept; 88 | 89 | bool quit_on_close_ = false; 90 | 91 | // window handle for top level window. 92 | HWND window_handle_ = nullptr; 93 | 94 | // window handle for hosted content. 95 | HWND child_content_ = nullptr; 96 | }; 97 | 98 | #endif // RUNNER_WIN32_WINDOW_H_ 99 | -------------------------------------------------------------------------------- /studFee_client/windows/flutter/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # This file controls Flutter-level build steps. It should not be edited. 2 | cmake_minimum_required(VERSION 3.14) 3 | 4 | set(EPHEMERAL_DIR "${CMAKE_CURRENT_SOURCE_DIR}/ephemeral") 5 | 6 | # Configuration provided via flutter tool. 7 | include(${EPHEMERAL_DIR}/generated_config.cmake) 8 | 9 | # TODO: Move the rest of this into files in ephemeral. See 10 | # https://github.com/flutter/flutter/issues/57146. 11 | set(WRAPPER_ROOT "${EPHEMERAL_DIR}/cpp_client_wrapper") 12 | 13 | # === Flutter Library === 14 | set(FLUTTER_LIBRARY "${EPHEMERAL_DIR}/flutter_windows.dll") 15 | 16 | # Published to parent scope for install step. 17 | set(FLUTTER_LIBRARY ${FLUTTER_LIBRARY} PARENT_SCOPE) 18 | set(FLUTTER_ICU_DATA_FILE "${EPHEMERAL_DIR}/icudtl.dat" PARENT_SCOPE) 19 | set(PROJECT_BUILD_DIR "${PROJECT_DIR}/build/" PARENT_SCOPE) 20 | set(AOT_LIBRARY "${PROJECT_DIR}/build/windows/app.so" PARENT_SCOPE) 21 | 22 | list(APPEND FLUTTER_LIBRARY_HEADERS 23 | "flutter_export.h" 24 | "flutter_windows.h" 25 | "flutter_messenger.h" 26 | "flutter_plugin_registrar.h" 27 | "flutter_texture_registrar.h" 28 | ) 29 | list(TRANSFORM FLUTTER_LIBRARY_HEADERS PREPEND "${EPHEMERAL_DIR}/") 30 | add_library(flutter INTERFACE) 31 | target_include_directories(flutter INTERFACE 32 | "${EPHEMERAL_DIR}" 33 | ) 34 | target_link_libraries(flutter INTERFACE "${FLUTTER_LIBRARY}.lib") 35 | add_dependencies(flutter flutter_assemble) 36 | 37 | # === Wrapper === 38 | list(APPEND CPP_WRAPPER_SOURCES_CORE 39 | "core_implementations.cc" 40 | "standard_codec.cc" 41 | ) 42 | list(TRANSFORM CPP_WRAPPER_SOURCES_CORE PREPEND "${WRAPPER_ROOT}/") 43 | list(APPEND CPP_WRAPPER_SOURCES_PLUGIN 44 | "plugin_registrar.cc" 45 | ) 46 | list(TRANSFORM CPP_WRAPPER_SOURCES_PLUGIN PREPEND "${WRAPPER_ROOT}/") 47 | list(APPEND CPP_WRAPPER_SOURCES_APP 48 | "flutter_engine.cc" 49 | "flutter_view_controller.cc" 50 | ) 51 | list(TRANSFORM CPP_WRAPPER_SOURCES_APP PREPEND "${WRAPPER_ROOT}/") 52 | 53 | # Wrapper sources needed for a plugin. 54 | add_library(flutter_wrapper_plugin STATIC 55 | ${CPP_WRAPPER_SOURCES_CORE} 56 | ${CPP_WRAPPER_SOURCES_PLUGIN} 57 | ) 58 | apply_standard_settings(flutter_wrapper_plugin) 59 | set_target_properties(flutter_wrapper_plugin PROPERTIES 60 | POSITION_INDEPENDENT_CODE ON) 61 | set_target_properties(flutter_wrapper_plugin PROPERTIES 62 | CXX_VISIBILITY_PRESET hidden) 63 | target_link_libraries(flutter_wrapper_plugin PUBLIC flutter) 64 | target_include_directories(flutter_wrapper_plugin PUBLIC 65 | "${WRAPPER_ROOT}/include" 66 | ) 67 | add_dependencies(flutter_wrapper_plugin flutter_assemble) 68 | 69 | # Wrapper sources needed for the runner. 70 | add_library(flutter_wrapper_app STATIC 71 | ${CPP_WRAPPER_SOURCES_CORE} 72 | ${CPP_WRAPPER_SOURCES_APP} 73 | ) 74 | apply_standard_settings(flutter_wrapper_app) 75 | target_link_libraries(flutter_wrapper_app PUBLIC flutter) 76 | target_include_directories(flutter_wrapper_app PUBLIC 77 | "${WRAPPER_ROOT}/include" 78 | ) 79 | add_dependencies(flutter_wrapper_app flutter_assemble) 80 | 81 | # === Flutter tool backend === 82 | # _phony_ is a non-existent file to force this command to run every time, 83 | # since currently there's no way to get a full input/output list from the 84 | # flutter tool. 85 | set(PHONY_OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/_phony_") 86 | set_source_files_properties("${PHONY_OUTPUT}" PROPERTIES SYMBOLIC TRUE) 87 | add_custom_command( 88 | OUTPUT ${FLUTTER_LIBRARY} ${FLUTTER_LIBRARY_HEADERS} 89 | ${CPP_WRAPPER_SOURCES_CORE} ${CPP_WRAPPER_SOURCES_PLUGIN} 90 | ${CPP_WRAPPER_SOURCES_APP} 91 | ${PHONY_OUTPUT} 92 | COMMAND ${CMAKE_COMMAND} -E env 93 | ${FLUTTER_TOOL_ENVIRONMENT} 94 | "${FLUTTER_ROOT}/packages/flutter_tools/bin/tool_backend.bat" 95 | windows-x64 $ 96 | VERBATIM 97 | ) 98 | add_custom_target(flutter_assemble DEPENDS 99 | "${FLUTTER_LIBRARY}" 100 | ${FLUTTER_LIBRARY_HEADERS} 101 | ${CPP_WRAPPER_SOURCES_CORE} 102 | ${CPP_WRAPPER_SOURCES_PLUGIN} 103 | ${CPP_WRAPPER_SOURCES_APP} 104 | ) 105 | -------------------------------------------------------------------------------- /studFee_client/linux/my_application.cc: -------------------------------------------------------------------------------- 1 | #include "my_application.h" 2 | 3 | #include 4 | #ifdef GDK_WINDOWING_X11 5 | #include 6 | #endif 7 | 8 | #include "flutter/generated_plugin_registrant.h" 9 | 10 | struct _MyApplication { 11 | GtkApplication parent_instance; 12 | char** dart_entrypoint_arguments; 13 | }; 14 | 15 | G_DEFINE_TYPE(MyApplication, my_application, GTK_TYPE_APPLICATION) 16 | 17 | // Implements GApplication::activate. 18 | static void my_application_activate(GApplication* application) { 19 | MyApplication* self = MY_APPLICATION(application); 20 | GtkWindow* window = 21 | GTK_WINDOW(gtk_application_window_new(GTK_APPLICATION(application))); 22 | 23 | // Use a header bar when running in GNOME as this is the common style used 24 | // by applications and is the setup most users will be using (e.g. Ubuntu 25 | // desktop). 26 | // If running on X and not using GNOME then just use a traditional title bar 27 | // in case the window manager does more exotic layout, e.g. tiling. 28 | // If running on Wayland assume the header bar will work (may need changing 29 | // if future cases occur). 30 | gboolean use_header_bar = TRUE; 31 | #ifdef GDK_WINDOWING_X11 32 | GdkScreen* screen = gtk_window_get_screen(window); 33 | if (GDK_IS_X11_SCREEN(screen)) { 34 | const gchar* wm_name = gdk_x11_screen_get_window_manager_name(screen); 35 | if (g_strcmp0(wm_name, "GNOME Shell") != 0) { 36 | use_header_bar = FALSE; 37 | } 38 | } 39 | #endif 40 | if (use_header_bar) { 41 | GtkHeaderBar* header_bar = GTK_HEADER_BAR(gtk_header_bar_new()); 42 | gtk_widget_show(GTK_WIDGET(header_bar)); 43 | gtk_header_bar_set_title(header_bar, "studfees"); 44 | gtk_header_bar_set_show_close_button(header_bar, TRUE); 45 | gtk_window_set_titlebar(window, GTK_WIDGET(header_bar)); 46 | } else { 47 | gtk_window_set_title(window, "studfees"); 48 | } 49 | 50 | gtk_window_set_default_size(window, 1280, 720); 51 | gtk_widget_show(GTK_WIDGET(window)); 52 | 53 | g_autoptr(FlDartProject) project = fl_dart_project_new(); 54 | fl_dart_project_set_dart_entrypoint_arguments(project, self->dart_entrypoint_arguments); 55 | 56 | FlView* view = fl_view_new(project); 57 | gtk_widget_show(GTK_WIDGET(view)); 58 | gtk_container_add(GTK_CONTAINER(window), GTK_WIDGET(view)); 59 | 60 | fl_register_plugins(FL_PLUGIN_REGISTRY(view)); 61 | 62 | gtk_widget_grab_focus(GTK_WIDGET(view)); 63 | } 64 | 65 | // Implements GApplication::local_command_line. 66 | static gboolean my_application_local_command_line(GApplication* application, gchar*** arguments, int* exit_status) { 67 | MyApplication* self = MY_APPLICATION(application); 68 | // Strip out the first argument as it is the binary name. 69 | self->dart_entrypoint_arguments = g_strdupv(*arguments + 1); 70 | 71 | g_autoptr(GError) error = nullptr; 72 | if (!g_application_register(application, nullptr, &error)) { 73 | g_warning("Failed to register: %s", error->message); 74 | *exit_status = 1; 75 | return TRUE; 76 | } 77 | 78 | g_application_activate(application); 79 | *exit_status = 0; 80 | 81 | return TRUE; 82 | } 83 | 84 | // Implements GObject::dispose. 85 | static void my_application_dispose(GObject* object) { 86 | MyApplication* self = MY_APPLICATION(object); 87 | g_clear_pointer(&self->dart_entrypoint_arguments, g_strfreev); 88 | G_OBJECT_CLASS(my_application_parent_class)->dispose(object); 89 | } 90 | 91 | static void my_application_class_init(MyApplicationClass* klass) { 92 | G_APPLICATION_CLASS(klass)->activate = my_application_activate; 93 | G_APPLICATION_CLASS(klass)->local_command_line = my_application_local_command_line; 94 | G_OBJECT_CLASS(klass)->dispose = my_application_dispose; 95 | } 96 | 97 | static void my_application_init(MyApplication* self) {} 98 | 99 | MyApplication* my_application_new() { 100 | return MY_APPLICATION(g_object_new(my_application_get_type(), 101 | "application-id", APPLICATION_ID, 102 | "flags", G_APPLICATION_NON_UNIQUE, 103 | nullptr)); 104 | } 105 | -------------------------------------------------------------------------------- /studFee_client/lib/screens/users/books/book_search.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:flutter_cache_manager/flutter_cache_manager.dart'; 3 | import 'package:studfees/models/books_model.dart'; 4 | 5 | import 'book_reader.dart'; 6 | import 'book_services.dart'; 7 | 8 | class BookSearchScreen extends StatefulWidget { 9 | const BookSearchScreen({super.key}); 10 | 11 | @override 12 | State createState() => _BookSearchScreenState(); 13 | } 14 | 15 | class _BookSearchScreenState extends State { 16 | final BookService _bookService = BookService(); 17 | final TextEditingController _searchController = TextEditingController(); 18 | final ScrollController _scrollController = ScrollController(); 19 | 20 | List _books = []; 21 | bool _isLoading = false; 22 | 23 | @override 24 | void dispose() { 25 | _searchController.dispose(); 26 | _scrollController.dispose(); 27 | super.dispose(); 28 | } 29 | 30 | Future _searchBooks(String query) async { 31 | setState(() => _isLoading = true); 32 | try { 33 | final books = await _bookService.search(query); 34 | setState(() { 35 | _books = books; 36 | }); 37 | } catch (e) { 38 | print(e.toString()); 39 | } finally { 40 | setState(() { 41 | _isLoading = false; 42 | }); 43 | } 44 | } 45 | 46 | Widget _buildSearchBar() { 47 | return Column( 48 | mainAxisAlignment: MainAxisAlignment.center, 49 | children: [ 50 | const SizedBox( 51 | height: 30, 52 | ), 53 | const Text( 54 | 'Search your favourite book...', 55 | style: TextStyle( 56 | fontSize: 30, 57 | color: Colors.black26, 58 | fontWeight: FontWeight.w500, 59 | ), 60 | ), 61 | Padding( 62 | padding: const EdgeInsets.all(20.0), 63 | child: TextFormField( 64 | controller: _searchController, 65 | decoration: InputDecoration( 66 | hintText: 'Search for books', 67 | suffixIcon: IconButton( 68 | icon: const Icon(Icons.search), 69 | onPressed: () => _searchBooks(_searchController.text), 70 | ), 71 | ), 72 | onSaved: ((newValue) => _searchBooks(newValue.toString())), 73 | ), 74 | ), 75 | ], 76 | ); 77 | } 78 | 79 | Widget _buildBookListItem(Book book) { 80 | Future getFilePath() async { 81 | final file = await DefaultCacheManager().getSingleFile(book.url); 82 | // print(file); 83 | return file.path; 84 | } 85 | 86 | return GestureDetector( 87 | onTap: () async { 88 | final filePath = await getFilePath(); 89 | // print(filePath); 90 | // ignore: use_build_context_synchronously 91 | Navigator.push( 92 | context, 93 | MaterialPageRoute( 94 | builder: (context) => BookReaderScreen(filePath: filePath), 95 | ), 96 | ); 97 | }, 98 | child: ListTile( 99 | leading: book.coverUrl.isNotEmpty ? Image.network(book.coverUrl) : null, 100 | title: Text(book.title), 101 | subtitle: Text(book.author), 102 | ), 103 | ); 104 | } 105 | 106 | Widget _buildBookList() { 107 | return ListView.builder( 108 | controller: _scrollController, 109 | itemCount: _books.length, 110 | itemBuilder: (context, index) => _buildBookListItem(_books[index]), 111 | ); 112 | } 113 | 114 | Widget _buildLoadingIndicator() { 115 | return const Center( 116 | child: CircularProgressIndicator(), 117 | ); 118 | } 119 | 120 | @override 121 | Widget build(BuildContext context) { 122 | return Scaffold( 123 | body: Padding( 124 | padding: const EdgeInsets.all(8.0), 125 | child: Column( 126 | children: [ 127 | _buildSearchBar(), 128 | Expanded( 129 | child: _isLoading ? _buildLoadingIndicator() : _buildBookList()) 130 | ], 131 | ), 132 | ), 133 | ); 134 | } 135 | } 136 | -------------------------------------------------------------------------------- /studfeeServer/models/User.js: -------------------------------------------------------------------------------- 1 | require('dotenv').config 2 | 3 | const mongoose = require('mongoose') 4 | const Schema = mongoose.Schema 5 | const bcrypt = require('bcrypt') 6 | const jwt = require('jsonwebtoken') 7 | const crypto = require('crypto') 8 | const Token = require('../models/Token') 9 | 10 | 11 | const secretCode = process.env.SECRET_CODE 12 | 13 | 14 | const userScheme = new Schema({ 15 | fullname: { 16 | type: String, 17 | }, 18 | admissionNumber: { 19 | type: String, 20 | unique: true, 21 | trim: true, 22 | }, 23 | department: { 24 | type: String, 25 | }, 26 | yearOfAdmin: { 27 | type: String, 28 | }, 29 | profileImage: { 30 | type: String, 31 | required: false 32 | }, 33 | coverImage: { 34 | type: String, 35 | required: false 36 | }, 37 | password: { 38 | type: String, 39 | require: true, 40 | validate: { 41 | validator: (value) => { 42 | return value.length > 8; 43 | }, 44 | message: 'Your password is less than 8 characters' 45 | } 46 | }, 47 | gender: { 48 | type: String, 49 | required: false 50 | }, 51 | isVerified: { 52 | type: Boolean, 53 | default: false 54 | }, 55 | ugLevel: { 56 | type: String, 57 | required: false 58 | }, 59 | email: { 60 | type: String, 61 | unique: true, 62 | required: true, 63 | trim: true, 64 | validate: { 65 | validator: (value) => { 66 | const re = /^(([^<>()[\]\.,;:\s@\"]+(\.[^<>()[\]\.,;:\s@\"]+)*)|(\".+\"))@(([^<>()[\]\.,;:\s@\"]+\.)+[^<>()[\]\.,;:\s@\"]{2,})$/i; 67 | return value.match(re); 68 | }, 69 | message: 'Please enter a valid email' 70 | } 71 | }, 72 | type: { 73 | type: String, 74 | default: 'Student' 75 | }, 76 | resetPasswordToken: { 77 | type: String, 78 | required: false 79 | }, 80 | 81 | resetPasswordExpires: { 82 | type: Date, 83 | required: false 84 | } 85 | }, { timestamps: true }) 86 | 87 | 88 | //Hashing Users Password 89 | userScheme.pre('save', function(next) { 90 | var user = this; 91 | if(this.isModified('password') || this.isNew ) { 92 | bcrypt.genSalt(10, function(err, salt) { 93 | if(err) return next(err); 94 | bcrypt.hash(user.password, salt, function(err, hash) { 95 | if(err) return next(err); 96 | user.password = hash; 97 | next() 98 | }) 99 | }) 100 | } else { 101 | return next(); 102 | } 103 | }) 104 | 105 | 106 | //Comparing Password 107 | userScheme.methods.comparePassword = function(passw, cb){ 108 | bcrypt.compare(passw, this.password, function(err, isMatch){ 109 | if(err) return cb(err) 110 | cb(null, isMatch) 111 | }) 112 | } 113 | 114 | //Set Session 115 | userScheme.methods.generateJWT = function(){ 116 | const today = new Date() 117 | const expireDate = new Date(today) 118 | 119 | expireDate.setDate(today.getDate() + 5) 120 | 121 | let payload = { 122 | id: this._id, 123 | admissionNumber: this.admissionNumber, 124 | email: this.email, 125 | fullname: this.fullname, 126 | } 127 | 128 | return jwt.sign(payload, secretCode, { 129 | expiresIn: parseInt(expireDate.getTime() / 1000, 10) 130 | }) 131 | } 132 | 133 | //Reset Password token for user 134 | userScheme.methods.generatePasswordReset = function(){ 135 | this.resetPasswordToken = crypto.randomBytes(20).toString('hex') 136 | this.resetPasswordExpires = Date.now() + 3600000; //expires in an hour 137 | } 138 | 139 | 140 | //Regenerate verification token for user 141 | userScheme.methods.generateVerificationToken = function(){ 142 | let payload = { 143 | userId: this._id, 144 | token: crypto.randomBytes(20).toString('hex') 145 | } 146 | 147 | return new Token(payload) 148 | } 149 | 150 | const User = mongoose.model('User', userScheme) 151 | module.exports = User -------------------------------------------------------------------------------- /studFee_client/windows/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Project-level configuration. 2 | cmake_minimum_required(VERSION 3.14) 3 | project(studfees LANGUAGES CXX) 4 | 5 | # The name of the executable created for the application. Change this to change 6 | # the on-disk name of your application. 7 | set(BINARY_NAME "studfees") 8 | 9 | # Explicitly opt in to modern CMake behaviors to avoid warnings with recent 10 | # versions of CMake. 11 | cmake_policy(SET CMP0063 NEW) 12 | 13 | # Define build configuration option. 14 | get_property(IS_MULTICONFIG GLOBAL PROPERTY GENERATOR_IS_MULTI_CONFIG) 15 | if(IS_MULTICONFIG) 16 | set(CMAKE_CONFIGURATION_TYPES "Debug;Profile;Release" 17 | CACHE STRING "" FORCE) 18 | else() 19 | if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES) 20 | set(CMAKE_BUILD_TYPE "Debug" CACHE 21 | STRING "Flutter build mode" FORCE) 22 | set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS 23 | "Debug" "Profile" "Release") 24 | endif() 25 | endif() 26 | # Define settings for the Profile build mode. 27 | set(CMAKE_EXE_LINKER_FLAGS_PROFILE "${CMAKE_EXE_LINKER_FLAGS_RELEASE}") 28 | set(CMAKE_SHARED_LINKER_FLAGS_PROFILE "${CMAKE_SHARED_LINKER_FLAGS_RELEASE}") 29 | set(CMAKE_C_FLAGS_PROFILE "${CMAKE_C_FLAGS_RELEASE}") 30 | set(CMAKE_CXX_FLAGS_PROFILE "${CMAKE_CXX_FLAGS_RELEASE}") 31 | 32 | # Use Unicode for all projects. 33 | add_definitions(-DUNICODE -D_UNICODE) 34 | 35 | # Compilation settings that should be applied to most targets. 36 | # 37 | # Be cautious about adding new options here, as plugins use this function by 38 | # default. In most cases, you should add new options to specific targets instead 39 | # of modifying this function. 40 | function(APPLY_STANDARD_SETTINGS TARGET) 41 | target_compile_features(${TARGET} PUBLIC cxx_std_17) 42 | target_compile_options(${TARGET} PRIVATE /W4 /WX /wd"4100") 43 | target_compile_options(${TARGET} PRIVATE /EHsc) 44 | target_compile_definitions(${TARGET} PRIVATE "_HAS_EXCEPTIONS=0") 45 | target_compile_definitions(${TARGET} PRIVATE "$<$:_DEBUG>") 46 | endfunction() 47 | 48 | # Flutter library and tool build rules. 49 | set(FLUTTER_MANAGED_DIR "${CMAKE_CURRENT_SOURCE_DIR}/flutter") 50 | add_subdirectory(${FLUTTER_MANAGED_DIR}) 51 | 52 | # Application build; see runner/CMakeLists.txt. 53 | add_subdirectory("runner") 54 | 55 | # Generated plugin build rules, which manage building the plugins and adding 56 | # them to the application. 57 | include(flutter/generated_plugins.cmake) 58 | 59 | 60 | # === Installation === 61 | # Support files are copied into place next to the executable, so that it can 62 | # run in place. This is done instead of making a separate bundle (as on Linux) 63 | # so that building and running from within Visual Studio will work. 64 | set(BUILD_BUNDLE_DIR "$") 65 | # Make the "install" step default, as it's required to run. 66 | set(CMAKE_VS_INCLUDE_INSTALL_TO_DEFAULT_BUILD 1) 67 | if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) 68 | set(CMAKE_INSTALL_PREFIX "${BUILD_BUNDLE_DIR}" CACHE PATH "..." FORCE) 69 | endif() 70 | 71 | set(INSTALL_BUNDLE_DATA_DIR "${CMAKE_INSTALL_PREFIX}/data") 72 | set(INSTALL_BUNDLE_LIB_DIR "${CMAKE_INSTALL_PREFIX}") 73 | 74 | install(TARGETS ${BINARY_NAME} RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}" 75 | COMPONENT Runtime) 76 | 77 | install(FILES "${FLUTTER_ICU_DATA_FILE}" DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" 78 | COMPONENT Runtime) 79 | 80 | install(FILES "${FLUTTER_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_LIB_DIR}" 81 | COMPONENT Runtime) 82 | 83 | if(PLUGIN_BUNDLED_LIBRARIES) 84 | install(FILES "${PLUGIN_BUNDLED_LIBRARIES}" 85 | DESTINATION "${INSTALL_BUNDLE_LIB_DIR}" 86 | COMPONENT Runtime) 87 | endif() 88 | 89 | # Fully re-copy the assets directory on each build to avoid having stale files 90 | # from a previous install. 91 | set(FLUTTER_ASSET_DIR_NAME "flutter_assets") 92 | install(CODE " 93 | file(REMOVE_RECURSE \"${INSTALL_BUNDLE_DATA_DIR}/${FLUTTER_ASSET_DIR_NAME}\") 94 | " COMPONENT Runtime) 95 | install(DIRECTORY "${PROJECT_BUILD_DIR}/${FLUTTER_ASSET_DIR_NAME}" 96 | DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" COMPONENT Runtime) 97 | 98 | # Install the AOT library on non-Debug builds only. 99 | install(FILES "${AOT_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" 100 | CONFIGURATIONS Profile;Release 101 | COMPONENT Runtime) 102 | -------------------------------------------------------------------------------- /studFee_client/pubspec.yaml: -------------------------------------------------------------------------------- 1 | name: studfees 2 | description: A new Flutter project. 3 | 4 | # The following line prevents the package from being accidentally published to 5 | # pub.dev using `flutter pub publish`. This is preferred for private packages. 6 | publish_to: "none" # Remove this line if you wish to publish to pub.dev 7 | 8 | # The following defines the version and build number for your application. 9 | # A version number is three numbers separated by dots, like 1.2.43 10 | # followed by an optional build number separated by a +. 11 | # Both the version and the builder number may be overridden in flutter 12 | # build by specifying --build-name and --build-number, respectively. 13 | # In Android, build-name is used as versionName while build-number used as versionCode. 14 | # Read more about Android versioning at https://developer.android.com/studio/publish/versioning 15 | # In iOS, build-name is used as CFBundleShortVersionString while build-number is used as CFBundleVersion. 16 | # Read more about iOS versioning at 17 | # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html 18 | # In Windows, build-name is used as the major, minor, and patch parts 19 | # of the product and file versions while build-number is used as the build suffix. 20 | version: 1.0.0+1 21 | 22 | environment: 23 | sdk: ">=2.18.0 <3.0.0" 24 | 25 | # Dependencies specify other packages that your package needs in order to work. 26 | # To automatically upgrade your package dependencies to the latest versions 27 | # consider running `flutter pub upgrade --major-versions`. Alternatively, 28 | # dependencies can be manually updated by changing the version numbers below to 29 | # the latest version available on pub.dev. To see which dependencies have newer 30 | # versions available, run `flutter pub outdated`. 31 | dependencies: 32 | cloudinary_public: ^0.20.0 33 | cupertino_icons: ^1.0.2 34 | dropdown_button2: ^1.9.2 35 | easy_splash_screen: ^1.0.4 36 | flutter: 37 | sdk: flutter 38 | flutter_dotenv: ^5.0.2 39 | flutter_paystack: ^1.0.7 40 | google_fonts: ^3.0.1 41 | http: ^0.13.5 42 | image_picker: ^0.8.6+1 43 | provider: ^6.0.5 44 | shared_preferences: ^2.0.17 45 | validators: ^3.0.0 46 | path_provider: ^2.0.12 47 | cached_network_image: ^3.2.3 48 | flutter_pdfview: ^1.2.1 49 | flutter_cache_manager: ^3.3.0 50 | audioplayers: ^3.0.1 51 | flutter_tts: ^3.6.3 52 | file_picker: ^5.2.5 53 | video_player: ^2.5.1 54 | mime: ^1.0.4 55 | 56 | 57 | dev_dependencies: 58 | flutter_lints: ^2.0.0 59 | flutter_test: 60 | sdk: flutter 61 | flutter_launcher_icons: "^0.12.0" 62 | 63 | flutter_icons: 64 | android: "launcher_icon" 65 | ios: true 66 | image_path: "assets/images/logo.png" 67 | 68 | 69 | # For information on the generic Dart part of this file, see the 70 | # following page: https://dart.dev/tools/pub/pubspec 71 | # The following section is specific to Flutter packages. 72 | flutter: 73 | # The following line ensures that the Material Icons font is 74 | # included with your application, so that you can use the icons in 75 | # the material Icons class. 76 | uses-material-design: true 77 | # To add assets to your application, add an assets section, like this: 78 | assets: 79 | - assets/images/logo.png 80 | - assets/images/student.jpg 81 | - assets/images/cover.jpg 82 | - assets/images/profile.png 83 | - assets/icons/book.png 84 | - assets/icons/home-2.png 85 | - assets/icons/people.png 86 | - assets/icons/payment.png 87 | - assets/icons/user.png 88 | - .env 89 | # - images/a_dot_ham.jpeg 90 | # An image asset can refer to one or more resolution-specific "variants", see 91 | # https://flutter.dev/assets-and-images/#resolution-aware 92 | # For details regarding adding assets from package dependencies, see 93 | # https://flutter.dev/assets-and-images/#from-packages 94 | # To add custom fonts to your application, add a fonts section here, 95 | # in this "flutter" section. Each entry in this list should have a 96 | # "family" key with the font family name, and a "fonts" key with a 97 | # list giving the asset and other descriptors for the font. For 98 | # example: 99 | # fonts: 100 | # - family: Schyler 101 | # fonts: 102 | # - asset: fonts/Schyler-Regular.ttf 103 | # - asset: fonts/Schyler-Italic.ttf 104 | # style: italic 105 | # - family: Trajan Pro 106 | # fonts: 107 | # - asset: fonts/TrajanPro.ttf 108 | # - asset: fonts/TrajanPro_Bold.ttf 109 | # weight: 700 110 | # 111 | # For details regarding fonts from package dependencies, 112 | # see https://flutter.dev/custom-fonts/#from-packages 113 | -------------------------------------------------------------------------------- /studFee_client/lib/screens/users/home_screen.dart: -------------------------------------------------------------------------------- 1 | import 'package:flutter/material.dart'; 2 | import 'package:provider/provider.dart'; 3 | import 'package:studfees/components/grid_box.dart'; 4 | import 'package:studfees/provider/user_provider.dart'; 5 | import 'package:studfees/screens/users/payment.dart'; 6 | import 'package:studfees/screens/users/profile.dart'; 7 | import 'package:studfees/util/config.dart'; 8 | import 'package:studfees/util/navigator.dart'; 9 | 10 | class HomeScreen extends StatefulWidget { 11 | static const String routeName = '/auth-screen'; 12 | const HomeScreen({super.key}); 13 | 14 | @override 15 | State createState() => _HomeScreenState(); 16 | } 17 | 18 | class _HomeScreenState extends State { 19 | @override 20 | Widget build(BuildContext context) { 21 | final now = DateTime.now().hour; 22 | 23 | String? greetings; 24 | 25 | if (now < 12) { 26 | greetings = 'Good Morining 🌻'; 27 | } else if (now < 17) { 28 | greetings = 'Good Afternoon 🌞'; 29 | } else { 30 | greetings = 'Good Evening 🌙'; 31 | } 32 | 33 | final user = Provider.of(context).user; 34 | return Scaffold( 35 | body: SafeArea( 36 | child: Padding( 37 | padding: const EdgeInsets.all(12.0), 38 | child: Column( 39 | mainAxisSize: MainAxisSize.max, 40 | children: [ 41 | Row( 42 | children: [ 43 | Expanded( 44 | child: ListTile( 45 | contentPadding: const EdgeInsets.all(0.0), 46 | title: Text( 47 | greetings.toString(), 48 | style: const TextStyle( 49 | fontSize: 30, 50 | fontWeight: FontWeight.w800, 51 | ), 52 | ), 53 | subtitle: Text( 54 | user.fullname.toString(), 55 | style: const TextStyle( 56 | fontSize: 15, 57 | fontWeight: FontWeight.w600, 58 | color: Colors.black54, 59 | ), 60 | ), 61 | ), 62 | ), 63 | const CircleAvatar( 64 | backgroundImage: AssetImage('assets/images/logo.png'), 65 | ) 66 | ], 67 | ), 68 | Flexible( 69 | fit: FlexFit.loose, 70 | child: GridView.extent( 71 | childAspectRatio: (2 / 2), 72 | crossAxisSpacing: 10, 73 | mainAxisSpacing: 10, 74 | maxCrossAxisExtent: 100.0, 75 | children: [ 76 | GridBox( 77 | image: Image.asset( 78 | 'assets/icons/user.png', 79 | width: 40, 80 | height: 40, 81 | color: Config.primaryColor, 82 | ), 83 | textTitle: 'Profile', 84 | function: () { 85 | nextScreen(context, const ProfileScreen()); 86 | }, 87 | ), 88 | GridBox( 89 | image: Image.asset( 90 | 'assets/icons/payment.png', 91 | width: 40, 92 | height: 40, 93 | color: Config.primaryColor, 94 | ), 95 | textTitle: 'Payment', 96 | function: () { 97 | nextScreen(context, const PaymentListScreen()); 98 | }, 99 | ), 100 | GridBox( 101 | image: Image.asset( 102 | 'assets/icons/book.png', 103 | width: 40, 104 | height: 40, 105 | color: Config.primaryColor, 106 | ), 107 | textTitle: 'E-Library', 108 | function: () { 109 | debugPrint('E-Library'); 110 | }, 111 | ), 112 | GridBox( 113 | image: Image.asset( 114 | 'assets/icons/people.png', 115 | width: 40, 116 | height: 40, 117 | color: Config.primaryColor, 118 | ), 119 | textTitle: 'Meet Up', 120 | function: () { 121 | debugPrint('Meet Up'); 122 | }, 123 | ), 124 | ], 125 | ), 126 | ) 127 | ], 128 | ), 129 | )), 130 | ); 131 | } 132 | } 133 | -------------------------------------------------------------------------------- /studFee_client/lib/screens/users/chat/user_list.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | import 'dart:io'; 3 | 4 | import 'package:flutter/material.dart'; 5 | import 'package:http/http.dart' as http; 6 | import 'package:provider/provider.dart'; 7 | import 'package:studfees/util/config.dart'; 8 | import 'package:studfees/util/navigator.dart'; 9 | 10 | import '../../../provider/user_provider.dart'; 11 | import 'chat_screen.dart'; 12 | 13 | class UserListScreen extends StatefulWidget { 14 | const UserListScreen({super.key}); 15 | 16 | @override 17 | State createState() => _UserListScreenState(); 18 | } 19 | 20 | class _UserListScreenState extends State { 21 | final TextEditingController searchAdmissionNumber = TextEditingController(); 22 | 23 | List _users = []; 24 | 25 | @override 26 | void initState() { 27 | _getUsers(); 28 | super.initState(); 29 | } 30 | 31 | void _getUsers() async { 32 | final userProvider = Provider.of(context, listen: false); 33 | 34 | http.Response response = await http.get( 35 | Uri.parse('$url/users'), 36 | headers: { 37 | HttpHeaders.contentTypeHeader: 'application/json', 38 | 'x-auth-token': userProvider.user.token, 39 | }, 40 | ); 41 | final data = jsonDecode(response.body); 42 | setState(() { 43 | _users = data; 44 | }); 45 | } 46 | 47 | void _searchUser() async { 48 | final userProvider = Provider.of(context, listen: false); 49 | 50 | http.Response response = await http.get( 51 | Uri.parse('$url/users/$searchAdmissionNumber'), 52 | headers: { 53 | HttpHeaders.contentTypeHeader: 'application/json', 54 | 'x-auth-token': userProvider.user.token, 55 | }, 56 | ); 57 | final user = response.body; 58 | print(user); 59 | } 60 | 61 | @override 62 | Widget build(BuildContext context) { 63 | return Scaffold( 64 | appBar: AppBar( 65 | foregroundColor: Colors.black, 66 | elevation: 0, 67 | backgroundColor: const Color.fromARGB(255, 230, 230, 230), 68 | title: TextFormField( 69 | controller: searchAdmissionNumber, 70 | textInputAction: TextInputAction.done, 71 | decoration: InputDecoration( 72 | suffixStyle: const TextStyle(color: Colors.black54), 73 | suffixIcon: IconButton( 74 | onPressed: _searchUser, 75 | icon: const Icon(Icons.search), 76 | ), 77 | labelStyle: const TextStyle(color: Colors.black54, fontSize: 20), 78 | labelText: 'Enter admission no', 79 | filled: true, 80 | fillColor: const Color.fromARGB(255, 230, 230, 230), 81 | prefixIconColor: Colors.black54, 82 | focusColor: Colors.black, 83 | focusedBorder: UnderlineInputBorder( 84 | borderSide: const BorderSide(color: Colors.white30), 85 | borderRadius: BorderRadius.circular(10)), 86 | errorBorder: UnderlineInputBorder( 87 | borderSide: const BorderSide(color: Colors.red), 88 | borderRadius: BorderRadius.circular(10)), 89 | enabledBorder: UnderlineInputBorder( 90 | borderSide: const BorderSide(color: Colors.white30), 91 | borderRadius: BorderRadius.circular(10)), 92 | ), 93 | onChanged: (value) { 94 | // setState( 95 | // () { 96 | // _searchAdmissionNumber.text = value; 97 | // }, 98 | // ); 99 | }, 100 | ), 101 | ), 102 | body: ListView.builder( 103 | itemCount: _users.length, 104 | itemBuilder: (context, index) { 105 | final user = _users[index]; 106 | return ListTile( 107 | leading: CircleAvatar( 108 | backgroundColor: Config.primaryColor, 109 | radius: 20, 110 | child: (user['profileImage'] != null) 111 | ? CircleAvatar( 112 | backgroundColor: Colors.white, 113 | radius: 20, 114 | backgroundImage: NetworkImage(user['profileImage'])) 115 | : const CircleAvatar( 116 | backgroundColor: Colors.white, 117 | radius: 15, 118 | backgroundImage: AssetImage('assets/images/profile.png'), 119 | ), 120 | ), 121 | title: Text(user['fullname']), 122 | subtitle: Text(user['admissionNumber']), 123 | onTap: () { 124 | nextScreen( 125 | context, ChatScreen(receiver: user['admissionNumber'])); 126 | }, 127 | ); 128 | }, 129 | ), 130 | ); 131 | } 132 | } 133 | -------------------------------------------------------------------------------- /studFee_client/lib/screens/users/dictionary/dictionary.dart: -------------------------------------------------------------------------------- 1 | import 'dart:convert'; 2 | import 'package:audioplayers/audioplayers.dart'; 3 | import 'package:flutter/material.dart'; 4 | import 'package:http/http.dart' as http; 5 | 6 | import '../../../models/dictionary_model.dart'; 7 | 8 | class DictionaryPage extends StatefulWidget { 9 | const DictionaryPage({Key? key}) : super(key: key); 10 | 11 | @override 12 | _DictionaryPageState createState() => _DictionaryPageState(); 13 | } 14 | 15 | class _DictionaryPageState extends State { 16 | String _searchWord = ''; 17 | ApiResponse? _response; 18 | final player = AudioPlayer(); 19 | 20 | @override 21 | Widget build(BuildContext context) { 22 | return Scaffold( 23 | appBar: AppBar( 24 | elevation: 0, 25 | backgroundColor: Colors.white, 26 | foregroundColor: Colors.black, 27 | centerTitle: true, 28 | title: const Text('Dictionary App'), 29 | ), 30 | body: Padding( 31 | padding: const EdgeInsets.all(16.0), 32 | child: Column( 33 | crossAxisAlignment: CrossAxisAlignment.start, 34 | children: [ 35 | TextField( 36 | decoration: const InputDecoration( 37 | hintText: 'Search for a word', 38 | ), 39 | onChanged: (value) { 40 | _searchWord = value; 41 | }, 42 | ), 43 | ElevatedButton( 44 | onPressed: () async { 45 | ApiResponse response = await fetchWord(_searchWord); 46 | setState(() { 47 | _response = response; 48 | }); 49 | }, 50 | child: const Text('Search'), 51 | ), 52 | const SizedBox(height: 16), 53 | if (_response != null) 54 | Column( 55 | crossAxisAlignment: CrossAxisAlignment.start, 56 | children: [ 57 | Text( 58 | _response!.word!, 59 | style: const TextStyle(fontSize: 24), 60 | ), 61 | const SizedBox(height: 8), 62 | Text( 63 | _response!.definition!, 64 | style: const TextStyle(fontSize: 18), 65 | ), 66 | if (_response!.example!.isNotEmpty) 67 | Padding( 68 | padding: const EdgeInsets.symmetric(vertical: 8), 69 | child: Text( 70 | 'Example: ${_response!.example}', 71 | style: const TextStyle(fontSize: 16), 72 | ), 73 | ), 74 | if (_response!.pronunciation!.isNotEmpty) 75 | Padding( 76 | padding: const EdgeInsets.symmetric(vertical: 8), 77 | child: Text( 78 | 'Pronunciation: /${_response!.pronunciation}/', 79 | style: const TextStyle(fontSize: 16), 80 | ), 81 | ), 82 | if (_response!.audioUrl!.isNotEmpty) 83 | InkWell( 84 | onTap: () async { 85 | final url = _response!.audioUrl; 86 | if (url != null) { 87 | final result = await player.play(UrlSource(url)); 88 | // if (result == 1) { 89 | // // success 90 | // } else { 91 | // // failure 92 | // } 93 | } 94 | }, 95 | child: Row( 96 | children: const [ 97 | Icon(Icons.volume_up), 98 | SizedBox(width: 8), 99 | Text('Play audio'), 100 | ], 101 | ), 102 | ), 103 | ], 104 | ), 105 | ], 106 | ), 107 | ), 108 | ); 109 | } 110 | 111 | Future fetchWord(String word) async { 112 | final response = await http.get( 113 | Uri.parse('https://api.dictionaryapi.dev/api/v2/entries/en_US/$word')); 114 | if (response.statusCode == 200) { 115 | final jsonResponse = json.decode(response.body); 116 | if (jsonResponse != null && jsonResponse.isNotEmpty) { 117 | final wordData = jsonResponse[0]; 118 | return ApiResponse( 119 | word: wordData['word'] ?? '', 120 | definition: wordData['meanings'][0]['definitions'][0]['definition'], 121 | example: wordData['meanings'][0]['definitions'][0]['example'] ?? '', 122 | pronunciation: wordData['phonetics'][0]['text'], 123 | audioUrl: wordData['phonetics'][0]['audio'] ?? '', 124 | ); 125 | } else { 126 | throw Exception('Word not found'); 127 | } 128 | } else { 129 | throw Exception('Failed to load data'); 130 | } 131 | } 132 | } 133 | -------------------------------------------------------------------------------- /studfeeServer/routes/router.js: -------------------------------------------------------------------------------- 1 | const express = require("express"); 2 | const functions = require("../controller/functions"); 3 | const router = express.Router(); 4 | const auth = require("../middleware/jwt"); 5 | const authTwo = require("../middleware/jwt_web"); 6 | const validate = require("../middleware/validator"); 7 | const validateTwo = require("../middleware/validatorTwo"); 8 | const validateThree = require("../middleware/validatorThree"); 9 | const validateFour = require("../middleware/validatorFour"); 10 | const { check } = require("express-validator"); 11 | const adminController = require("../controller/adminController"); 12 | 13 | router.post("/register", functions.verifyUserAndRegister); 14 | 15 | router.get("/verifyUser/:token", functions.verifyUser); 16 | 17 | router.post("/userSign", functions.signUserIn); 18 | 19 | router.post("/tokenIsValid", functions.tokenIsValid); 20 | 21 | router.get("/getUserData", auth, functions.getUserData); 22 | 23 | router.put("/updateData", auth, functions.updateProfile); 24 | 25 | router.get("/payments", auth, functions.getPayment); 26 | 27 | router.post("/paymentsProcess", auth, functions.paymentApi); 28 | 29 | router.get("/paymentsHistory", auth, functions.getPaymentHistory); 30 | 31 | router.get("/users", auth, functions.getAllUsers); 32 | 33 | router.get("/users/:admissionNumber", auth, functions.getUserByAdmission); 34 | 35 | router.post("/createChats", auth, functions.createChat); 36 | 37 | router.get("/chats/:sender:/receiver", auth, functions.getUserChat); 38 | 39 | router.post("/resetPasswordToken", functions.createResetPasswordToken); 40 | 41 | router.get("/reset/:token", functions.reset); 42 | 43 | router.post( 44 | "/reset/:token", 45 | [ 46 | check("password") 47 | .not() 48 | .isEmpty() 49 | .isLength({ min: 9 }) 50 | .withMessage("Must be at least 8 chars long"), 51 | check("confirmPassword", "Passwords do not match").custom( 52 | (value, { req }) => value === req.body.password 53 | ), 54 | ], 55 | validateFour, 56 | functions.resetPassword 57 | ); 58 | 59 | router.get("/success"); 60 | router.get("/error"); 61 | 62 | router.get("/logout", function (req, res) { 63 | res.clearCookie("x-auth-token"); 64 | res.status(200).json({ msg: "Sign-out successful" }); 65 | }); 66 | 67 | router.get("/getUserProfileUrl", auth, functions.getUserProfileImage); 68 | 69 | // Render Admin Registration Form 70 | router.get("/register-admin", (req, res) => { 71 | res.render("admin/register"); 72 | }); 73 | 74 | //Admin Routes 75 | router.post( 76 | "/register-admin", 77 | [ 78 | check("fullname", "Name is required").not().isEmpty(), 79 | check("email", "Please include a valid email").isEmail(), 80 | check( 81 | "password", 82 | "Please enter a password with 8 or more characters" 83 | ).isLength({ min: 8 }), 84 | check("confirmPassword", "Passwords do not match").custom( 85 | (value, { req }) => value === req.body.password 86 | ), 87 | ], 88 | validate, 89 | adminController.registerAdmin 90 | ); 91 | 92 | // Render Admin Registration Form 93 | router.get("/signin", (req, res) => { 94 | res.render("admin/signin"); 95 | }); 96 | 97 | //Admin Routes 98 | router.post( 99 | "/signin", 100 | [ 101 | check("email", "Please include a valid email") 102 | .isEmail() 103 | .withMessage("Invalid email"), 104 | check( 105 | "password", 106 | "Please enter a password with 8 or more characters" 107 | ).isLength({ min: 8 }), 108 | ], 109 | validateTwo, 110 | adminController.signInUser 111 | ); 112 | 113 | router.get('/admin/dashboard', authTwo, adminController.getAllPaidUser, (req, res) => { 114 | res.render('admin/dashboard'); 115 | }); 116 | 117 | router.get('/admin/paymentlist', authTwo, adminController.getAllPaymentList, (req, res) => { 118 | res.render('admin/paymentlist'); 119 | }); 120 | 121 | 122 | // router.get( 123 | // "/admin/dashboard", 124 | // authTwo, 125 | // function (req, res, next) { 126 | // // Create an array of promises for the two methods 127 | // const promises = [ 128 | // adminController.getAllPaidUser(req, res, next), 129 | // adminController.getAllPaymentList(req, res, next), 130 | // ]; 131 | 132 | // // Wait for both promises to resolve before calling next() 133 | // Promise.all(promises) 134 | // .then(() => { 135 | // next(); 136 | // }) 137 | // .catch((err) => { 138 | // next(err); 139 | // }); 140 | // }, 141 | // function (req, res) { 142 | // // Render the page after both methods have finished 143 | // res.render("admin/dashboard"); 144 | // } 145 | // ); 146 | 147 | router.post("/logout", (req, res) => { 148 | res.clearCookie("token"); 149 | res.render("admin/signin"); 150 | }); 151 | 152 | //Admin Routes 153 | router.get("/create-form", (req, res)=>{ 154 | res.render("admin/create-form"); 155 | }) 156 | 157 | router.post( 158 | "/create-form", 159 | [ 160 | check("departmentName", "Department name required").not().isEmpty(), 161 | check("levyName", "Levy name required").not().isEmpty(), 162 | check("feeAmount", "Fee amount required").not().isEmpty(), 163 | ], 164 | validateThree, 165 | authTwo, 166 | adminController.createForm 167 | ); 168 | 169 | router.get("/verifyAdmin/:token", adminController.verifyAdmin); 170 | 171 | module.exports = router; 172 | --------------------------------------------------------------------------------