Commit 10e73d8d authored by Uditha Prabhasha 's avatar Uditha Prabhasha

update uditha

parent 4019eb83
No preview for this file type
...@@ -668,13 +668,13 @@ ...@@ -668,13 +668,13 @@
"languageVersion": "3.0" "languageVersion": "3.0"
}, },
{ {
"name": "jema_app", "name": "mobile_application_kids",
"rootUri": "../", "rootUri": "../",
"packageUri": "lib/", "packageUri": "lib/",
"languageVersion": "3.0" "languageVersion": "3.0"
} }
], ],
"generated": "2024-03-09T19:18:50.460515Z", "generated": "2024-03-17T10:38:35.142846Z",
"generator": "pub", "generator": "pub",
"generatorVersion": "3.0.1" "generatorVersion": "3.0.1"
} }
...@@ -442,8 +442,8 @@ xdg_directories ...@@ -442,8 +442,8 @@ xdg_directories
3.0 3.0
file:///Users/avishkanew/.pub-cache/hosted/pub.dev/xdg_directories-1.0.4/ file:///Users/avishkanew/.pub-cache/hosted/pub.dev/xdg_directories-1.0.4/
file:///Users/avishkanew/.pub-cache/hosted/pub.dev/xdg_directories-1.0.4/lib/ file:///Users/avishkanew/.pub-cache/hosted/pub.dev/xdg_directories-1.0.4/lib/
jema_app mobile_application_kids
3.0 3.0
file:///Users/avishkanew/Desktop/Avishk678/monitoring-and-recommendations-for-early-childhood-development/ file:///Users/avishkanew/Documents/Jema678/monitoring-and-recommendations-for-early-childhood-development/
file:///Users/avishkanew/Desktop/Avishk678/monitoring-and-recommendations-for-early-childhood-development/lib/ file:///Users/avishkanew/Documents/Jema678/monitoring-and-recommendations-for-early-childhood-development/lib/
2 2
{"info":"This is a generated file; do not edit or check into version control.","plugins":{"ios":[{"name":"cloud_firestore","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore-4.13.6/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_auth","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth-4.15.3/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_core","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core-2.24.2/","native_build":true,"dependencies":[]},{"name":"firebase_storage","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage-11.6.0/","native_build":true,"dependencies":["firebase_core"]},{"name":"image_picker_ios","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_ios-0.8.9+1/","native_build":true,"dependencies":[]},{"name":"path_provider_foundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_foundation-2.3.2/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","native_build":true,"dependencies":[]},{"name":"shared_preferences_foundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_foundation-2.3.5/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"sqflite","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/sqflite-2.3.2/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"url_launcher_ios","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_ios-6.2.4/","native_build":true,"dependencies":[]},{"name":"video_player_avfoundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/video_player_avfoundation-2.4.11/","native_build":true,"dependencies":[]}],"android":[{"name":"cloud_firestore","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore-4.13.6/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_auth","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth-4.15.3/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_core","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core-2.24.2/","native_build":true,"dependencies":[]},{"name":"firebase_storage","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage-11.6.0/","native_build":true,"dependencies":["firebase_core"]},{"name":"flutter_plugin_android_lifecycle","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/flutter_plugin_android_lifecycle-2.0.17/","native_build":true,"dependencies":[]},{"name":"image_picker_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_android-0.8.9+3/","native_build":true,"dependencies":["flutter_plugin_android_lifecycle"]},{"name":"path_provider_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_android-2.2.2/","native_build":true,"dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","native_build":true,"dependencies":[]},{"name":"shared_preferences_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_android-2.2.1/","native_build":true,"dependencies":[]},{"name":"sqflite","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/sqflite-2.3.2/","native_build":true,"dependencies":[]},{"name":"url_launcher_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_android-6.3.0/","native_build":true,"dependencies":[]},{"name":"video_player_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/video_player_android-2.4.11/","native_build":true,"dependencies":[]}],"macos":[{"name":"cloud_firestore","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore-4.13.6/","native_build":true,"dependencies":["firebase_core"]},{"name":"file_selector_macos","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/file_selector_macos-0.9.3+3/","native_build":true,"dependencies":[]},{"name":"firebase_auth","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth-4.15.3/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_core","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core-2.24.2/","native_build":true,"dependencies":[]},{"name":"firebase_storage","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage-11.6.0/","native_build":true,"dependencies":["firebase_core"]},{"name":"image_picker_macos","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_macos-0.2.1+1/","native_build":false,"dependencies":["file_selector_macos"]},{"name":"path_provider_foundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_foundation-2.3.2/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","native_build":true,"dependencies":[]},{"name":"shared_preferences_foundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_foundation-2.3.5/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"sqflite","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/sqflite-2.3.2/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"url_launcher_macos","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_macos-3.1.0/","native_build":true,"dependencies":[]}],"linux":[{"name":"file_selector_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/file_selector_linux-0.9.2+1/","native_build":true,"dependencies":[]},{"name":"image_picker_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_linux-0.2.1+1/","native_build":false,"dependencies":["file_selector_linux"]},{"name":"path_provider_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_linux-2.2.1/","native_build":false,"dependencies":[]},{"name":"shared_preferences_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_linux-2.3.2/","native_build":false,"dependencies":["path_provider_linux"]},{"name":"url_launcher_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_linux-3.1.1/","native_build":true,"dependencies":[]}],"windows":[{"name":"cloud_firestore","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore-4.13.6/","native_build":true,"dependencies":["firebase_core"]},{"name":"file_selector_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/file_selector_windows-0.9.3+1/","native_build":true,"dependencies":[]},{"name":"firebase_auth","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth-4.15.3/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_core","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core-2.24.2/","native_build":true,"dependencies":[]},{"name":"firebase_storage","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage-11.6.0/","native_build":true,"dependencies":["firebase_core"]},{"name":"image_picker_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_windows-0.2.1+1/","native_build":false,"dependencies":["file_selector_windows"]},{"name":"path_provider_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_windows-2.2.1/","native_build":false,"dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","native_build":true,"dependencies":[]},{"name":"shared_preferences_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_windows-2.3.2/","native_build":false,"dependencies":["path_provider_windows"]},{"name":"url_launcher_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_windows-3.1.1/","native_build":true,"dependencies":[]}],"web":[{"name":"cloud_firestore_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore_web-3.8.10/","dependencies":["firebase_core_web"]},{"name":"firebase_auth_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth_web-5.8.12/","dependencies":["firebase_core_web"]},{"name":"firebase_core_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core_web-2.10.0/","dependencies":[]},{"name":"firebase_storage_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage_web-3.6.17/","dependencies":["firebase_core_web"]},{"name":"image_picker_for_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_for_web-2.2.0/","dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","dependencies":[]},{"name":"shared_preferences_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_web-2.2.1/","dependencies":[]},{"name":"url_launcher_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_web-2.0.19/","dependencies":[]},{"name":"video_player_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/video_player_web-2.0.17/","dependencies":[]}]},"dependencyGraph":[{"name":"cloud_firestore","dependencies":["cloud_firestore_web","firebase_core"]},{"name":"cloud_firestore_web","dependencies":["firebase_core","firebase_core_web"]},{"name":"file_selector_linux","dependencies":[]},{"name":"file_selector_macos","dependencies":[]},{"name":"file_selector_windows","dependencies":[]},{"name":"firebase_auth","dependencies":["firebase_auth_web","firebase_core"]},{"name":"firebase_auth_web","dependencies":["firebase_core","firebase_core_web"]},{"name":"firebase_core","dependencies":["firebase_core_web"]},{"name":"firebase_core_web","dependencies":[]},{"name":"firebase_storage","dependencies":["firebase_core","firebase_storage_web"]},{"name":"firebase_storage_web","dependencies":["firebase_core","firebase_core_web"]},{"name":"flutter_plugin_android_lifecycle","dependencies":[]},{"name":"image_picker","dependencies":["image_picker_android","image_picker_for_web","image_picker_ios","image_picker_linux","image_picker_macos","image_picker_windows"]},{"name":"image_picker_android","dependencies":["flutter_plugin_android_lifecycle"]},{"name":"image_picker_for_web","dependencies":[]},{"name":"image_picker_ios","dependencies":[]},{"name":"image_picker_linux","dependencies":["file_selector_linux"]},{"name":"image_picker_macos","dependencies":["file_selector_macos"]},{"name":"image_picker_windows","dependencies":["file_selector_windows"]},{"name":"path_provider","dependencies":["path_provider_android","path_provider_foundation","path_provider_linux","path_provider_windows"]},{"name":"path_provider_android","dependencies":[]},{"name":"path_provider_foundation","dependencies":[]},{"name":"path_provider_linux","dependencies":[]},{"name":"path_provider_windows","dependencies":[]},{"name":"rive_common","dependencies":[]},{"name":"shared_preferences","dependencies":["shared_preferences_android","shared_preferences_foundation","shared_preferences_linux","shared_preferences_web","shared_preferences_windows"]},{"name":"shared_preferences_android","dependencies":[]},{"name":"shared_preferences_foundation","dependencies":[]},{"name":"shared_preferences_linux","dependencies":["path_provider_linux"]},{"name":"shared_preferences_web","dependencies":[]},{"name":"shared_preferences_windows","dependencies":["path_provider_windows"]},{"name":"sqflite","dependencies":[]},{"name":"url_launcher","dependencies":["url_launcher_android","url_launcher_ios","url_launcher_linux","url_launcher_macos","url_launcher_web","url_launcher_windows"]},{"name":"url_launcher_android","dependencies":[]},{"name":"url_launcher_ios","dependencies":[]},{"name":"url_launcher_linux","dependencies":[]},{"name":"url_launcher_macos","dependencies":[]},{"name":"url_launcher_web","dependencies":[]},{"name":"url_launcher_windows","dependencies":[]},{"name":"video_player","dependencies":["video_player_android","video_player_avfoundation","video_player_web"]},{"name":"video_player_android","dependencies":[]},{"name":"video_player_avfoundation","dependencies":[]},{"name":"video_player_web","dependencies":[]}],"date_created":"2024-03-10 00:48:50.540132","version":"3.10.1"} {"info":"This is a generated file; do not edit or check into version control.","plugins":{"ios":[{"name":"cloud_firestore","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore-4.13.6/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_auth","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth-4.15.3/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_core","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core-2.24.2/","native_build":true,"dependencies":[]},{"name":"firebase_storage","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage-11.6.0/","native_build":true,"dependencies":["firebase_core"]},{"name":"image_picker_ios","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_ios-0.8.9+1/","native_build":true,"dependencies":[]},{"name":"path_provider_foundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_foundation-2.3.2/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","native_build":true,"dependencies":[]},{"name":"shared_preferences_foundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_foundation-2.3.5/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"sqflite","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/sqflite-2.3.2/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"url_launcher_ios","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_ios-6.2.4/","native_build":true,"dependencies":[]},{"name":"video_player_avfoundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/video_player_avfoundation-2.4.11/","native_build":true,"dependencies":[]}],"android":[{"name":"cloud_firestore","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore-4.13.6/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_auth","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth-4.15.3/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_core","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core-2.24.2/","native_build":true,"dependencies":[]},{"name":"firebase_storage","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage-11.6.0/","native_build":true,"dependencies":["firebase_core"]},{"name":"flutter_plugin_android_lifecycle","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/flutter_plugin_android_lifecycle-2.0.17/","native_build":true,"dependencies":[]},{"name":"image_picker_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_android-0.8.9+3/","native_build":true,"dependencies":["flutter_plugin_android_lifecycle"]},{"name":"path_provider_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_android-2.2.2/","native_build":true,"dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","native_build":true,"dependencies":[]},{"name":"shared_preferences_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_android-2.2.1/","native_build":true,"dependencies":[]},{"name":"sqflite","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/sqflite-2.3.2/","native_build":true,"dependencies":[]},{"name":"url_launcher_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_android-6.3.0/","native_build":true,"dependencies":[]},{"name":"video_player_android","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/video_player_android-2.4.11/","native_build":true,"dependencies":[]}],"macos":[{"name":"cloud_firestore","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore-4.13.6/","native_build":true,"dependencies":["firebase_core"]},{"name":"file_selector_macos","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/file_selector_macos-0.9.3+3/","native_build":true,"dependencies":[]},{"name":"firebase_auth","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth-4.15.3/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_core","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core-2.24.2/","native_build":true,"dependencies":[]},{"name":"firebase_storage","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage-11.6.0/","native_build":true,"dependencies":["firebase_core"]},{"name":"image_picker_macos","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_macos-0.2.1+1/","native_build":false,"dependencies":["file_selector_macos"]},{"name":"path_provider_foundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_foundation-2.3.2/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","native_build":true,"dependencies":[]},{"name":"shared_preferences_foundation","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_foundation-2.3.5/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"sqflite","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/sqflite-2.3.2/","shared_darwin_source":true,"native_build":true,"dependencies":[]},{"name":"url_launcher_macos","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_macos-3.1.0/","native_build":true,"dependencies":[]}],"linux":[{"name":"file_selector_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/file_selector_linux-0.9.2+1/","native_build":true,"dependencies":[]},{"name":"image_picker_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_linux-0.2.1+1/","native_build":false,"dependencies":["file_selector_linux"]},{"name":"path_provider_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_linux-2.2.1/","native_build":false,"dependencies":[]},{"name":"shared_preferences_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_linux-2.3.2/","native_build":false,"dependencies":["path_provider_linux"]},{"name":"url_launcher_linux","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_linux-3.1.1/","native_build":true,"dependencies":[]}],"windows":[{"name":"cloud_firestore","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore-4.13.6/","native_build":true,"dependencies":["firebase_core"]},{"name":"file_selector_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/file_selector_windows-0.9.3+1/","native_build":true,"dependencies":[]},{"name":"firebase_auth","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth-4.15.3/","native_build":true,"dependencies":["firebase_core"]},{"name":"firebase_core","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core-2.24.2/","native_build":true,"dependencies":[]},{"name":"firebase_storage","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage-11.6.0/","native_build":true,"dependencies":["firebase_core"]},{"name":"image_picker_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_windows-0.2.1+1/","native_build":false,"dependencies":["file_selector_windows"]},{"name":"path_provider_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/path_provider_windows-2.2.1/","native_build":false,"dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","native_build":true,"dependencies":[]},{"name":"shared_preferences_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_windows-2.3.2/","native_build":false,"dependencies":["path_provider_windows"]},{"name":"url_launcher_windows","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_windows-3.1.1/","native_build":true,"dependencies":[]}],"web":[{"name":"cloud_firestore_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/cloud_firestore_web-3.8.10/","dependencies":["firebase_core_web"]},{"name":"firebase_auth_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_auth_web-5.8.12/","dependencies":["firebase_core_web"]},{"name":"firebase_core_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_core_web-2.10.0/","dependencies":[]},{"name":"firebase_storage_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/firebase_storage_web-3.6.17/","dependencies":["firebase_core_web"]},{"name":"image_picker_for_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/image_picker_for_web-2.2.0/","dependencies":[]},{"name":"rive_common","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/rive_common-0.2.7/","dependencies":[]},{"name":"shared_preferences_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/shared_preferences_web-2.2.1/","dependencies":[]},{"name":"url_launcher_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/url_launcher_web-2.0.19/","dependencies":[]},{"name":"video_player_web","path":"/Users/avishkanew/.pub-cache/hosted/pub.dev/video_player_web-2.0.17/","dependencies":[]}]},"dependencyGraph":[{"name":"cloud_firestore","dependencies":["cloud_firestore_web","firebase_core"]},{"name":"cloud_firestore_web","dependencies":["firebase_core","firebase_core_web"]},{"name":"file_selector_linux","dependencies":[]},{"name":"file_selector_macos","dependencies":[]},{"name":"file_selector_windows","dependencies":[]},{"name":"firebase_auth","dependencies":["firebase_auth_web","firebase_core"]},{"name":"firebase_auth_web","dependencies":["firebase_core","firebase_core_web"]},{"name":"firebase_core","dependencies":["firebase_core_web"]},{"name":"firebase_core_web","dependencies":[]},{"name":"firebase_storage","dependencies":["firebase_core","firebase_storage_web"]},{"name":"firebase_storage_web","dependencies":["firebase_core","firebase_core_web"]},{"name":"flutter_plugin_android_lifecycle","dependencies":[]},{"name":"image_picker","dependencies":["image_picker_android","image_picker_for_web","image_picker_ios","image_picker_linux","image_picker_macos","image_picker_windows"]},{"name":"image_picker_android","dependencies":["flutter_plugin_android_lifecycle"]},{"name":"image_picker_for_web","dependencies":[]},{"name":"image_picker_ios","dependencies":[]},{"name":"image_picker_linux","dependencies":["file_selector_linux"]},{"name":"image_picker_macos","dependencies":["file_selector_macos"]},{"name":"image_picker_windows","dependencies":["file_selector_windows"]},{"name":"path_provider","dependencies":["path_provider_android","path_provider_foundation","path_provider_linux","path_provider_windows"]},{"name":"path_provider_android","dependencies":[]},{"name":"path_provider_foundation","dependencies":[]},{"name":"path_provider_linux","dependencies":[]},{"name":"path_provider_windows","dependencies":[]},{"name":"rive_common","dependencies":[]},{"name":"shared_preferences","dependencies":["shared_preferences_android","shared_preferences_foundation","shared_preferences_linux","shared_preferences_web","shared_preferences_windows"]},{"name":"shared_preferences_android","dependencies":[]},{"name":"shared_preferences_foundation","dependencies":[]},{"name":"shared_preferences_linux","dependencies":["path_provider_linux"]},{"name":"shared_preferences_web","dependencies":[]},{"name":"shared_preferences_windows","dependencies":["path_provider_windows"]},{"name":"sqflite","dependencies":[]},{"name":"url_launcher","dependencies":["url_launcher_android","url_launcher_ios","url_launcher_linux","url_launcher_macos","url_launcher_web","url_launcher_windows"]},{"name":"url_launcher_android","dependencies":[]},{"name":"url_launcher_ios","dependencies":[]},{"name":"url_launcher_linux","dependencies":[]},{"name":"url_launcher_macos","dependencies":[]},{"name":"url_launcher_web","dependencies":[]},{"name":"url_launcher_windows","dependencies":[]},{"name":"video_player","dependencies":["video_player_android","video_player_avfoundation","video_player_web"]},{"name":"video_player_android","dependencies":[]},{"name":"video_player_avfoundation","dependencies":[]},{"name":"video_player_web","dependencies":[]}],"date_created":"2024-03-17 16:08:35.268387","version":"3.10.1"}
\ No newline at end of file \ No newline at end of file
...@@ -214,7 +214,9 @@ class MessageBubble extends StatelessWidget { ...@@ -214,7 +214,9 @@ class MessageBubble extends StatelessWidget {
alignment: isCurrentUser ? Alignment.centerRight : Alignment.centerLeft, alignment: isCurrentUser ? Alignment.centerRight : Alignment.centerLeft,
child: Container( child: Container(
decoration: BoxDecoration( decoration: BoxDecoration(
color: isCurrentUser ? Colors.blue : Colors.green, color: isCurrentUser
? Color.fromARGB(36, 85, 193, 255)
: const Color.fromARGB(255, 240, 240, 240),
borderRadius: BorderRadius.circular(12.0), borderRadius: BorderRadius.circular(12.0),
), ),
padding: EdgeInsets.all(12.0), padding: EdgeInsets.all(12.0),
...@@ -228,12 +230,18 @@ class MessageBubble extends StatelessWidget { ...@@ -228,12 +230,18 @@ class MessageBubble extends StatelessWidget {
imageUrl!, imageUrl!,
width: 200, width: 200,
), ),
if (message.isNotEmpty) Text(message), if (message.isNotEmpty)
Text(
message,
style: TextStyle(
fontSize: 18,
),
),
Text( Text(
userName, userName,
style: TextStyle( style: TextStyle(
color: Color.fromARGB(255, 248, 4, 4), color: Color.fromARGB(255, 29, 51, 243),
fontSize: 8, fontSize: 12,
), ),
) )
], ],
......
...@@ -86,7 +86,7 @@ class CheckKidsPage extends StatelessWidget { ...@@ -86,7 +86,7 @@ class CheckKidsPage extends StatelessWidget {
stream: _usersStream, stream: _usersStream,
builder: (context, snapshot) { builder: (context, snapshot) {
print("--------------------------------------"); print("--------------------------------------");
print(snapshot.data!.docs.length); // print(snapshot.data!.docs.length);
if (snapshot.connectionState == ConnectionState.waiting) { if (snapshot.connectionState == ConnectionState.waiting) {
return CircularProgressIndicator(); return CircularProgressIndicator();
} }
......
...@@ -116,9 +116,9 @@ class ChildrenActivity extends StatelessWidget { ...@@ -116,9 +116,9 @@ class ChildrenActivity extends StatelessWidget {
decoration: BoxDecoration( decoration: BoxDecoration(
image: DecorationImage( image: DecorationImage(
image: AssetImage( image: AssetImage(
'lib/assets/ac1.png'), // Replace 'path/to/your/image.jpg' with your image path 'lib/assets/ac1.png'),
fit: BoxFit fit: BoxFit
.cover, // Adjust this according to your needs .cover,
)), )),
), ),
), ),
...@@ -136,9 +136,9 @@ class ChildrenActivity extends StatelessWidget { ...@@ -136,9 +136,9 @@ class ChildrenActivity extends StatelessWidget {
decoration: BoxDecoration( decoration: BoxDecoration(
image: DecorationImage( image: DecorationImage(
image: AssetImage( image: AssetImage(
'lib/assets/ac2.png'), // Replace 'path/to/your/image.jpg' with your image path 'lib/assets/ac2.png'),
fit: BoxFit fit: BoxFit
.cover, // Adjust this according to your needs .cover,
)), )),
), ),
), ),
...@@ -158,9 +158,9 @@ class ChildrenActivity extends StatelessWidget { ...@@ -158,9 +158,9 @@ class ChildrenActivity extends StatelessWidget {
decoration: BoxDecoration( decoration: BoxDecoration(
image: DecorationImage( image: DecorationImage(
image: AssetImage( image: AssetImage(
'lib/assets/ac3.png'), // Replace 'path/to/your/image.jpg' with your image path 'lib/assets/ac7.png'),
fit: BoxFit fit: BoxFit
.cover, // Adjust this according to your needs .cover,
)), )),
), ),
), ),
...@@ -180,9 +180,9 @@ class ChildrenActivity extends StatelessWidget { ...@@ -180,9 +180,9 @@ class ChildrenActivity extends StatelessWidget {
decoration: BoxDecoration( decoration: BoxDecoration(
image: DecorationImage( image: DecorationImage(
image: AssetImage( image: AssetImage(
'lib/assets/ac4.png'), // Replace 'path/to/your/image.jpg' with your image path 'lib/assets/ac4.png'),
fit: BoxFit fit: BoxFit
.cover, // Adjust this according to your needs .cover,
)), )),
), ),
), ),
...@@ -202,9 +202,9 @@ class ChildrenActivity extends StatelessWidget { ...@@ -202,9 +202,9 @@ class ChildrenActivity extends StatelessWidget {
decoration: BoxDecoration( decoration: BoxDecoration(
image: DecorationImage( image: DecorationImage(
image: AssetImage( image: AssetImage(
'lib/assets/ac5.png'), // Replace 'path/to/your/image.jpg' with your image path 'lib/assets/ac6.png'),
fit: BoxFit fit: BoxFit
.cover, // Adjust this according to your needs .cover,
)), )),
), ),
), ),
......
...@@ -138,7 +138,7 @@ class ChildrenHomePage extends StatelessWidget { ...@@ -138,7 +138,7 @@ class ChildrenHomePage extends StatelessWidget {
stream: _usersStream, stream: _usersStream,
builder: (context, snapshot) { builder: (context, snapshot) {
print("--------------------------------------"); print("--------------------------------------");
print(snapshot.data!.docs.length); // print(snapshot.data!.docs.length);
if (snapshot.connectionState == ConnectionState.waiting) { if (snapshot.connectionState == ConnectionState.waiting) {
return CircularProgressIndicator(); return CircularProgressIndicator();
} }
...@@ -198,7 +198,7 @@ class ChildrenHomePage extends StatelessWidget { ...@@ -198,7 +198,7 @@ class ChildrenHomePage extends StatelessWidget {
Navigator.of(context).push( Navigator.of(context).push(
MaterialPageRoute( MaterialPageRoute(
builder: (_) => builder: (_) =>
ChildrenProfilePage(document), ChildrenProfilePage(document, 'C'),
), ),
); );
}, },
......
...@@ -26,7 +26,7 @@ class _ParentLoginPage extends State<ParentLoginPage> { ...@@ -26,7 +26,7 @@ class _ParentLoginPage extends State<ParentLoginPage> {
Widget build(BuildContext context) { Widget build(BuildContext context) {
return Scaffold( return Scaffold(
appBar: AppBar( appBar: AppBar(
backgroundColor: Colors.transparent, backgroundColor: Colors.white,
elevation: 0, elevation: 0,
leading: IconButton( leading: IconButton(
icon: const Icon( icon: const Icon(
...@@ -135,15 +135,16 @@ class _ParentLoginPage extends State<ParentLoginPage> { ...@@ -135,15 +135,16 @@ class _ParentLoginPage extends State<ParentLoginPage> {
child: Container( child: Container(
width: double.infinity, width: double.infinity,
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.circular(10.0), borderRadius: BorderRadius.circular(8.0),
color: Colors.green, color: Colors.blueAccent,
), ),
child: Center( child: Center(
child: Padding( child: Padding(
padding: const EdgeInsets.all(10.0), padding: const EdgeInsets.all(12.0),
child: Text( child: Text(
'Login', 'Login',
style: TextStyle(color: Colors.black), style:
TextStyle(color: Colors.white, fontSize: 18),
), ),
), ),
), ),
......
import 'package:cloud_firestore/cloud_firestore.dart'; import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart'; import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:mobile_application_kids/games.dart';
import 'package:mobile_application_kids/login.dart'; import 'package:mobile_application_kids/login.dart';
import 'package:mobile_application_kids/teacherchat.dart'; import 'package:mobile_application_kids/teacherchat.dart';
import 'package:mobile_application_kids/teacherhome.dart'; import 'package:mobile_application_kids/teacherhome.dart';
...@@ -108,7 +107,7 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> { ...@@ -108,7 +107,7 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> {
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
Text( Text(
'Bright Sparkle ', 'Bright Sparkle',
style: TextStyle( style: TextStyle(
color: Color(0xFF11324D), color: Color(0xFF11324D),
fontSize: 24, fontSize: 24,
...@@ -155,7 +154,7 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> { ...@@ -155,7 +154,7 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> {
SizedBox( SizedBox(
width: 148, width: 148,
child: Text( child: Text(
'Bright Spark', ' ',
style: TextStyle( style: TextStyle(
color: Color(0xFF473D7F), color: Color(0xFF473D7F),
fontSize: 23, fontSize: 23,
...@@ -478,7 +477,7 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> { ...@@ -478,7 +477,7 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> {
], ],
), ),
), ),
bottomNavigationBar: BottomNavigationBar( bottomNavigationBar: BottomNavigationBar(
items: const [ items: const [
BottomNavigationBarItem( BottomNavigationBarItem(
icon: Icon(Icons.home), icon: Icon(Icons.home),
...@@ -488,54 +487,33 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> { ...@@ -488,54 +487,33 @@ class _TeacherProfilePageState extends State<TeacherProfilePage> {
icon: Icon(Icons.chat), icon: Icon(Icons.chat),
label: 'Chat', label: 'Chat',
), ),
BottomNavigationBarItem(
icon: Icon(Icons.videogame_asset),
label: 'Games',
),
BottomNavigationBarItem( BottomNavigationBarItem(
icon: Icon(Icons.person), icon: Icon(Icons.person),
label: 'Profile', label: 'Profile',
), ),
], ],
selectedItemColor: Color(0xFF7A1FA0), selectedItemColor: Colors.blue,
unselectedItemColor: Color(0xFFA9ABAD), currentIndex: 2,
selectedLabelStyle: TextStyle(color: Color(0xFF7A1FA0)),
unselectedLabelStyle: TextStyle(color: Color.fromARGB(0, 197, 16, 16)),
currentIndex: 3,
onTap: (index) { onTap: (index) {
switch (index) { // Handle bottom navigation item tap
case 0: if (index == 0) {
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute(builder: (context) => TeacherHomePage()), MaterialPageRoute(builder: (context) => TeacherHomePage()),
); );
break; }
case 1: if (index == 1) {
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute(builder: (context) => ChatScreen()), MaterialPageRoute(builder: (context) => ChatScreen()),
); );
break; }
case 2: if (index == 2) {
// Handle Game Navigator.push(
Navigator.push( context,
context, MaterialPageRoute(
MaterialPageRoute( builder: (context) => TeacherProfilePage(uid: user?.uid)),
builder: (context) => GamesPage( );
),
),
);
break;
case 3:
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => TeacherProfilePage(
uid: user?.uid,
),
),
);
break;
} }
}, },
), ),
......
...@@ -44,7 +44,7 @@ class ActivitiesPage extends StatelessWidget { ...@@ -44,7 +44,7 @@ class ActivitiesPage extends StatelessWidget {
children: [ children: [
Expanded( Expanded(
child: ActivityBox( child: ActivityBox(
title: 'Social Activities', title: 'Coloring Book',
icon: Icons.group, icon: Icons.group,
), ),
), ),
...@@ -62,7 +62,7 @@ class ActivitiesPage extends StatelessWidget { ...@@ -62,7 +62,7 @@ class ActivitiesPage extends StatelessWidget {
children: [ children: [
Expanded( Expanded(
child: ActivityBox( child: ActivityBox(
title: 'Kid Activity', title: 'Environment',
icon: Icons.child_care, icon: Icons.child_care,
), ),
), ),
...@@ -170,4 +170,4 @@ class CameraScreen extends StatelessWidget { ...@@ -170,4 +170,4 @@ class CameraScreen extends StatelessWidget {
), ),
); );
} }
} }
\ No newline at end of file
...@@ -68,11 +68,11 @@ class _AddClassroomPageState extends State<AddClassroomPage> { ...@@ -68,11 +68,11 @@ class _AddClassroomPageState extends State<AddClassroomPage> {
), ),
SizedBox(height: 20), SizedBox(height: 20),
Container( Container(
height: 50.0, height: 48.0,
width: 150.0, width: 200.0,
decoration: BoxDecoration( decoration: BoxDecoration(
color: Color.fromARGB(203, 164, 88, 177), color: Colors.blueAccent,
borderRadius: BorderRadius.circular(4.0), borderRadius: BorderRadius.circular(8.0),
), ),
child: TextButton( child: TextButton(
onPressed: () { onPressed: () {
......
import 'package:cloud_firestore/cloud_firestore.dart'; import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart'; import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:jema_app/progressReport.dart'; import 'package:mobile_application_kids/progressReport.dart';
import 'package:jema_app/teacherchat.dart'; import 'package:mobile_application_kids/teacherchat.dart';
import 'package:jema_app/classroomview.dart'; import 'package:mobile_application_kids/classroomview.dart';
import 'package:jema_app/addclassroom.dart'; import 'package:mobile_application_kids/addclassroom.dart';
import 'package:jema_app/teacherhome.dart'; import 'package:mobile_application_kids/teacherhome.dart';
import 'package:url_launcher/url_launcher.dart'; import 'package:url_launcher/url_launcher.dart';
import 'ActivitiesView.dart'; import 'ActivitiesView.dart';
...@@ -17,8 +17,11 @@ class ChildrenProfilePage extends StatelessWidget { ...@@ -17,8 +17,11 @@ class ChildrenProfilePage extends StatelessWidget {
late User? user; late User? user;
late final Stream<QuerySnapshot> _usersStream, _usersStream2; late final Stream<QuerySnapshot> _usersStream, _usersStream2;
int _age = 0; int _age = 0;
String role = '';
late final userDetails; late final userDetails;
ChildrenProfilePage(document) { ChildrenProfilePage(document, role) {
print(role);
this.role = role;
this.userDetails = document; this.userDetails = document;
user = FirebaseAuth.instance.currentUser; user = FirebaseAuth.instance.currentUser;
initializeStreams(); initializeStreams();
...@@ -558,75 +561,82 @@ class ChildrenProfilePage extends StatelessWidget { ...@@ -558,75 +561,82 @@ class ChildrenProfilePage extends StatelessWidget {
mainAxisAlignment: MainAxisAlignment.start, mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
children: [ children: [
Container( role == "P"
width: 359, ? Container(
height: 178,
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Container(
width: 359, width: 359,
height: 128, height: 178,
clipBehavior: Clip.antiAlias, child: Column(
decoration: ShapeDecoration(
image: DecorationImage(
image: AssetImage("lib/assets/banner.png"),
fit: BoxFit.cover,
),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(10),
),
shadows: [
BoxShadow(
color: Color(0x19000000),
blurRadius: 20,
offset: Offset(0, 2),
spreadRadius: 0,
)
],
),
),
const SizedBox(height: 14),
Container(
child: Row(
mainAxisSize: MainAxisSize.min, mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start, mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.center,
children: [ children: [
Container( Container(
padding: const EdgeInsets.symmetric( width: 359,
horizontal: 40, vertical: 12), height: 128,
clipBehavior: Clip.antiAlias,
decoration: ShapeDecoration( decoration: ShapeDecoration(
color: Color(0xFF48B62C), image: DecorationImage(
image:
AssetImage("lib/assets/banner.png"),
fit: BoxFit.cover,
),
shape: RoundedRectangleBorder( shape: RoundedRectangleBorder(
borderRadius: borderRadius: BorderRadius.circular(10),
BorderRadius.circular(4)), ),
shadows: [ shadows: [
BoxShadow( BoxShadow(
color: Color(0x3F000000), color: Color(0x19000000),
blurRadius: 4, blurRadius: 20,
offset: Offset(0, 1), offset: Offset(0, 2),
spreadRadius: 0, spreadRadius: 0,
) )
], ],
), ),
),
const SizedBox(height: 14),
Container(
child: Row( child: Row(
mainAxisSize: MainAxisSize.min, mainAxisSize: MainAxisSize.min,
mainAxisAlignment: mainAxisAlignment:
MainAxisAlignment.center, MainAxisAlignment.start,
crossAxisAlignment: crossAxisAlignment:
CrossAxisAlignment.center, CrossAxisAlignment.start,
children: [ children: [
Text( Container(
'Play Here ', padding: const EdgeInsets.symmetric(
style: TextStyle( horizontal: 40, vertical: 12),
color: Colors.white, decoration: ShapeDecoration(
fontSize: 14, color: Color(0xFF48B62C),
fontFamily: 'Poppins', shape: RoundedRectangleBorder(
fontWeight: FontWeight.w600, borderRadius:
height: 0.06, BorderRadius.circular(4)),
shadows: [
BoxShadow(
color: Color(0x3F000000),
blurRadius: 4,
offset: Offset(0, 1),
spreadRadius: 0,
)
],
),
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment.center,
crossAxisAlignment:
CrossAxisAlignment.center,
children: [
Text(
'Play Here ',
style: TextStyle(
color: Colors.white,
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
height: 0.06,
),
),
],
), ),
), ),
], ],
...@@ -634,10 +644,8 @@ class ChildrenProfilePage extends StatelessWidget { ...@@ -634,10 +644,8 @@ class ChildrenProfilePage extends StatelessWidget {
), ),
], ],
), ),
), )
], : Container(),
),
),
SizedBox( SizedBox(
height: 10, height: 10,
), ),
...@@ -652,228 +660,236 @@ class ChildrenProfilePage extends StatelessWidget { ...@@ -652,228 +660,236 @@ class ChildrenProfilePage extends StatelessWidget {
), ),
), ),
const SizedBox(height: 20), const SizedBox(height: 20),
SingleChildScrollView( Padding(
child: Row( padding: EdgeInsets.only(
mainAxisSize: MainAxisSize.min, left: MediaQuery.of(context).size.width * 0.04),
mainAxisAlignment: MainAxisAlignment.start, child: SingleChildScrollView(
crossAxisAlignment: CrossAxisAlignment.start, child: Row(
children: [ mainAxisSize: MainAxisSize.min,
GestureDetector( mainAxisAlignment: MainAxisAlignment.start,
onTap: () { crossAxisAlignment: CrossAxisAlignment.start,
Navigator.push( children: [
context, GestureDetector(
MaterialPageRoute( onTap: () {
builder: (context) => ReportKidsViewPage( Navigator.push(
sid: userDetails.id)), context,
); MaterialPageRoute(
}, builder: (context) =>
child: Container( ReportKidsViewPage(
width: MediaQuery.of(context).size.width * 0.4, sid: userDetails.id)),
height: 135, );
child: Stack( },
children: [ child: Container(
Positioned( width:
left: 0, MediaQuery.of(context).size.width * 0.4,
top: 0, height: 135,
child: Container( child: Stack(
width: children: [
MediaQuery.of(context).size.width, Positioned(
height: 135, left: 0,
decoration: ShapeDecoration( top: 0,
color: Color(0xFFF1EFFF), child: Container(
shape: RoundedRectangleBorder( width:
borderRadius: MediaQuery.of(context).size.width,
BorderRadius.circular(8.44), height: 135,
decoration: ShapeDecoration(
color: Color(0xFFF1EFFF),
shape: RoundedRectangleBorder(
borderRadius:
BorderRadius.circular(8.44),
),
), ),
), ),
), ),
), Positioned(
Positioned( left: 16,
left: 16, top: 17,
top: 17, child: Container(
child: Container( width: 119.18,
width: 119.18, height: 100.88,
height: 100.88, child: Column(
child: Column( mainAxisSize: MainAxisSize.min,
mainAxisSize: MainAxisSize.min, mainAxisAlignment:
mainAxisAlignment: MainAxisAlignment.start,
MainAxisAlignment.start, crossAxisAlignment:
crossAxisAlignment: CrossAxisAlignment.start,
CrossAxisAlignment.start, children: [
children: [ Padding(
Padding( padding:
padding: const EdgeInsets.fromLTRB(
const EdgeInsets.fromLTRB( 0, 0, 0, 10),
0, 0, 0, 10), child: Container(
child: Container( width: 16.88,
width: 16.88, height: 16.88,
height: 16.88, clipBehavior: Clip.antiAlias,
clipBehavior: Clip.antiAlias, decoration: BoxDecoration(),
decoration: BoxDecoration(), child: Stack(children: [
child: Stack(children: [ Icon(
Icon( Icons.book,
Icons.book, color: Colors.black26,
color: Colors.black26, ),
), ]),
]), ),
), ),
), const SizedBox(height: 1),
const SizedBox(height: 1), SizedBox(
SizedBox( width: 119.18,
width: 119.18, child: Text.rich(
child: Text.rich( TextSpan(
TextSpan( children: [
children: [ TextSpan(
TextSpan( text: 'Monthly \n ',
text: 'Monthly \n ', style: TextStyle(
style: TextStyle( color:
color: Color(0xFF403572),
Color(0xFF403572), fontSize: 14,
fontSize: 14, fontFamily: 'Roboto',
fontFamily: 'Roboto', fontWeight:
fontWeight: FontWeight.w500,
FontWeight.w500, height: 0.09,
height: 0.09, ),
), ),
), ],
], ),
), ),
), ),
), const SizedBox(height: 12),
const SizedBox(height: 12), SizedBox(
SizedBox( width: 119.18,
width: 119.18, child: Opacity(
child: Opacity( opacity: 0.70,
opacity: 0.70, child: Text(
child: Text( 'Some short description of this type of report.',
'Some short description of this type of report.', style: TextStyle(
style: TextStyle( color: Color(0xFF8DAEAE),
color: Color(0xFF8DAEAE), fontSize: 10.55,
fontSize: 10.55, fontFamily: 'Roboto',
fontFamily: 'Roboto', fontWeight:
fontWeight: FontWeight.w400, FontWeight.w400,
height: 0, height: 0,
),
), ),
), ),
), ),
), ],
], ),
), ),
), ),
), ],
], ),
), ),
), ),
), SizedBox(
SizedBox( width: 10,
width: 10, ),
), GestureDetector(
GestureDetector( onTap: () {
onTap: () { Navigator.push(
Navigator.push( context,
context, MaterialPageRoute(
MaterialPageRoute( builder: (context) =>
builder: (context) => progressReport()));
progressReport())); },
}, child: Container(
child: Container( width: 150,
width: 150, height: 135,
height: 135, child: Stack(
child: Stack( children: [
children: [ Positioned(
Positioned( left: 0,
left: 0, top: 0,
top: 0, child: Container(
child: Container( width: 170,
width: 170, height: 135,
height: 135, decoration: ShapeDecoration(
decoration: ShapeDecoration( color: Color(0xFFC4F3F3),
color: Color(0xFFC4F3F3), shape: RoundedRectangleBorder(
shape: RoundedRectangleBorder( borderRadius:
borderRadius: BorderRadius.circular(8.44),
BorderRadius.circular(8.44), ),
), ),
), ),
), ),
), Positioned(
Positioned( left: 16,
left: 16, top: 17,
top: 17, child: Container(
child: Container( width: 119.18,
width: 119.18, height: 100.88,
height: 100.88, child: Column(
child: Column( mainAxisSize: MainAxisSize.min,
mainAxisSize: MainAxisSize.min, mainAxisAlignment:
mainAxisAlignment: MainAxisAlignment.start,
MainAxisAlignment.start, crossAxisAlignment:
crossAxisAlignment: CrossAxisAlignment.start,
CrossAxisAlignment.start, children: [
children: [ Padding(
Padding( padding:
padding: const EdgeInsets.fromLTRB(
const EdgeInsets.fromLTRB( 0, 0, 0, 10),
0, 0, 0, 10), child: Container(
child: Container( width: 16.88,
width: 16.88, height: 16.88,
height: 16.88, clipBehavior: Clip.antiAlias,
clipBehavior: Clip.antiAlias, decoration: BoxDecoration(),
decoration: BoxDecoration(), child: Stack(children: [
child: Stack(children: [ Icon(
Icon( Icons.book,
Icons.book, color: Colors.black26,
color: Colors.black26, ),
), ]),
]), ),
), ),
), const SizedBox(height: 1),
const SizedBox(height: 1), SizedBox(
SizedBox( width: 119.18,
width: 119.18, child: Text.rich(
child: Text.rich( TextSpan(
TextSpan( children: [
children: [ TextSpan(
TextSpan( text: 'Monthly \n',
text: 'Monthly \n', style: TextStyle(
style: TextStyle( color:
color: Color(0xFF479696),
Color(0xFF479696), fontSize: 14,
fontSize: 14, fontFamily: 'Roboto',
fontFamily: 'Roboto', fontWeight:
fontWeight: FontWeight.w500,
FontWeight.w500, height: 0.09,
height: 0.09, ),
), ),
), ],
], ),
), ),
), ),
), const SizedBox(height: 12),
const SizedBox(height: 12), SizedBox(
SizedBox( width: 119.18,
width: 119.18, child: Opacity(
child: Opacity( opacity: 0.70,
opacity: 0.70, child: Text(
child: Text( 'Some short description of this type of report.',
'Some short description of this type of report.', style: TextStyle(
style: TextStyle( color: Color(0xFF8DAEAE),
color: Color(0xFF8DAEAE), fontSize: 10.55,
fontSize: 10.55, fontFamily: 'Roboto',
fontFamily: 'Roboto', fontWeight:
fontWeight: FontWeight.w400, FontWeight.w400,
height: 0, height: 0,
),
), ),
), ),
), ),
), ],
], ),
), ),
), ),
), ],
], ),
), ),
), ),
), ],
], ),
), ),
), ),
], ],
......
...@@ -54,64 +54,112 @@ class ClassroomViewPage extends StatelessWidget { ...@@ -54,64 +54,112 @@ class ClassroomViewPage extends StatelessWidget {
), ),
), ),
SizedBox(height: 10), SizedBox(height: 10),
Container( Center(
height: 35.0, child: Padding(
width: 120.0, padding: const EdgeInsets.all(8.0),
decoration: BoxDecoration( child: Container(
color: Color.fromARGB(203, 164, 88, 177), width: MediaQuery.of(context).size.width * 0.9,
borderRadius: BorderRadius.circular(4.0), height: MediaQuery.of(context).size.height / 20,
), child: SingleChildScrollView(
child: TextButton( scrollDirection: Axis.horizontal,
onPressed: () { child: Row(
Navigator.push( mainAxisSize: MainAxisSize.min,
context, mainAxisAlignment: MainAxisAlignment.start,
MaterialPageRoute( crossAxisAlignment: CrossAxisAlignment.end,
builder: (context) => children: [
AddStudentPage(classname: documents)), Container(
); child: SingleChildScrollView(
}, scrollDirection: Axis
child: Text( .horizontal, // Enable horizontal scrolling
'Add Student', child: Container(
style: TextStyle( width: 333,
color: Colors.white, padding: const EdgeInsets.symmetric(
), horizontal: 56, vertical: 5),
), decoration: ShapeDecoration(
), color: Color.fromARGB(255, 255, 255, 255),
), shape: RoundedRectangleBorder(
SizedBox(height: 10), borderRadius: BorderRadius.circular(6)),
Padding( shadows: [
padding: EdgeInsets.fromLTRB(width * 0.1, 20, width * 0.1, 20), BoxShadow(
child: Container( color: Color(0x3F000000),
width: 293, blurRadius: 6,
height: 44, offset: Offset(0, 1),
decoration: ShapeDecoration( spreadRadius: 0,
color: Colors.white, )
shape: RoundedRectangleBorder( ],
borderRadius: BorderRadius.circular(8), ),
), child: Row(
shadows: [ mainAxisAlignment: MainAxisAlignment.center,
BoxShadow( crossAxisAlignment: CrossAxisAlignment.center,
color: Color(0x3F000000), children: [
blurRadius: 4, Container(
offset: Offset(0, 1), width: 32,
spreadRadius: 0, height: 32,
), decoration: ShapeDecoration(
], image: DecorationImage(
), image: AssetImage(
child: TextField( 'lib/assets/Vector 2.png'),
controller: _searchController, fit: BoxFit.fill,
onChanged: (value) { ),
_searchTermController.add(value); shape: OvalBorder(),
}, ),
decoration: InputDecoration( ),
hintText: 'Search', const SizedBox(width: 40),
border: InputBorder.none, FutureBuilder<String>(
icon: Padding( future: getStudentCount(),
padding: const EdgeInsets.all(8.0), builder: (context, snapshot) {
child: Icon(Icons.search), if (snapshot.connectionState ==
ConnectionState.waiting) {
return CircularProgressIndicator(); // Show loading indicator
}
if (snapshot.hasError) {
return Text(
'Error: ${snapshot.error}'); // Show error message
}
// Use the result of getStudentCount
return Text(
'Children ' +
(snapshot.data ??
'0'), // Default to '0' if data is null
style: TextStyle(
color: Colors.black,
fontSize: 12,
fontFamily: 'Poppins',
fontWeight: FontWeight.w400,
),
);
},
),
const SizedBox(width: 8),
GestureDetector(
onTap: () => Navigator.push(
context,
MaterialPageRoute(
builder: (context) =>
AddStudentPage(
classname: documents)),
),
child: Container(
margin: EdgeInsets.only(left: 8.0),
decoration: BoxDecoration(
color:
Color.fromARGB(203, 164, 88, 177),
borderRadius:
BorderRadius.circular(4.20),
),
child: Icon(
Icons.add,
color: Colors.white,
),
),
),
],
),
),
),
),
],
), ),
suffixIcon: Icon(Icons.mic),
contentPadding: EdgeInsets.all(8),
), ),
), ),
), ),
...@@ -646,4 +694,20 @@ class ClassroomViewPage extends StatelessWidget { ...@@ -646,4 +694,20 @@ class ClassroomViewPage extends StatelessWidget {
), ),
); );
} }
Future<String> getStudentCount() async {
try {
final QuerySnapshot<Map<String, dynamic>> snapshot =
await FirebaseFirestore.instance
.collection('students')
.where('className', isEqualTo: documents)
.get();
final int count = snapshot.size;
return count.toString();
} catch (e) {
print("Error getting student count: $e");
return '0';
}
}
} }
...@@ -2,78 +2,78 @@ import 'package:awesome_dialog/awesome_dialog.dart'; ...@@ -2,78 +2,78 @@ import 'package:awesome_dialog/awesome_dialog.dart';
import 'package:cloud_firestore/cloud_firestore.dart'; import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart'; import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
class KidsReportPage extends StatefulWidget { class KidsReportPage extends StatefulWidget {
String id; String id;
KidsReportPage({required this.id}); KidsReportPage({required this.id});
@override @override
_KidsReportPageState createState() => _KidsReportPageState(id: id); _KidsReportPageState createState() => _KidsReportPageState(id: id);
} }
class _KidsReportPageState extends State<KidsReportPage> { class _KidsReportPageState extends State<KidsReportPage> {
String id; String id;
_KidsReportPageState({required this.id}); _KidsReportPageState({required this.id});
List<String> dropdownValues = ['Select', '1', '2', '3', '4', '5']; List<String> dropdownValues = ['Select', '1', '2', '3', '4', '5'];
Map<String, String?> understandingDropdownMap = { Map<String, String?> understandingDropdownMap = {
'Understanding commands': 'Select', 'Understanding commands': 'Select',
'Answer questions': 'Select', 'Answer questions': 'Select',
'Keeping eye contact': 'Select', 'Keeping eye contact': 'Select',
'Following rules': 'Select', 'Following rules': 'Select',
}; };
Map<String, String?> movementsDropdownMap = { Map<String, String?> movementsDropdownMap = {
'Motor activities': 'Select', 'Motor activities': 'Select',
'Correct posture': 'Select', 'Correct posture': 'Select',
}; };
Map<String, String?> manipulatingDropdownMap = { Map<String, String?> manipulatingDropdownMap = {
'Can build/create new things': 'Select', 'Can build/create new things': 'Select',
'Knows how to handle accessories': 'Select', 'Knows how to handle accessories': 'Select',
}; };
Map<String, String?> socializingDropdownMap = { Map<String, String?> socializingDropdownMap = {
'Play with groups': 'Select', 'Play with groups': 'Select',
'Help each other': 'Select', 'Help each other': 'Select',
'Friendly towards peers': 'Select', 'Friendly towards peers': 'Select',
'Close to teacher': 'Select', 'Close to teacher': 'Select',
}; };
Map<String, String?> speechDropdownMap = { Map<String, String?> speechDropdownMap = {
'Communicate well': 'Select', 'Communicate well': 'Select',
'Like singing': 'Select', 'Like singing': 'Select',
}; };
Map<String, String?> recognitionDropdownMap = { Map<String, String?> recognitionDropdownMap = {
'Can express with pictures and words': 'Select', 'Can express with pictures and words': 'Select',
'Identify shapes': 'Select', 'Identify shapes': 'Select',
'Knows Primary colors.': 'Select', 'Knows Primary colors.': 'Select',
'Identify basic objects in the environment': 'Select', 'Identify basic objects in the environment': 'Select',
}; };
Map<String, String?> habitsDropdownMap = { Map<String, String?> habitsDropdownMap = {
'Organized': 'Select', 'Organized': 'Select',
'Have good eating habits': 'Select', 'Have good eating habits': 'Select',
'Taking care of own needs': 'Select', 'Taking care of own needs': 'Select',
}; };
Map<String, String?> personalHygieneDropdownMap = { Map<String, String?> personalHygieneDropdownMap = {
'Stay clean': 'Select', 'Stay clean': 'Select',
'Keep the workplace and environment clean': 'Select', 'Keep the workplace and environment clean': 'Select',
}; };
Map<String, String?> personalityDropdownMap = { Map<String, String?> personalityDropdownMap = {
'Act according to the situation': 'Select', 'Act according to the situation': 'Select',
'Finish allocated work': 'Select', 'Finish allocated work': 'Select',
'More active': 'Select', 'More active': 'Select',
'Less active': 'Select', 'Less active': 'Select',
}; };
final _formkey = GlobalKey<FormState>(); final _formkey = GlobalKey<FormState>();
final _auth = FirebaseAuth.instance; final _auth = FirebaseAuth.instance;
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
return Scaffold( return Scaffold(
...@@ -190,7 +190,7 @@ class _KidsReportPageState extends State<KidsReportPage> { ...@@ -190,7 +190,7 @@ class _KidsReportPageState extends State<KidsReportPage> {
), ),
); );
} }
Widget _buildDropdownSection({ Widget _buildDropdownSection({
required String title, required String title,
required Map<String, String?> dropdownMap, required Map<String, String?> dropdownMap,
...@@ -257,16 +257,16 @@ class _KidsReportPageState extends State<KidsReportPage> { ...@@ -257,16 +257,16 @@ class _KidsReportPageState extends State<KidsReportPage> {
], ],
); );
} }
postDetailsToFirestore(context) async { postDetailsToFirestore(context) async {
FirebaseFirestore firebaseFirestore = FirebaseFirestore.instance; FirebaseFirestore firebaseFirestore = FirebaseFirestore.instance;
var user = _auth.currentUser; var user = _auth.currentUser;
CollectionReference ref = CollectionReference ref =
FirebaseFirestore.instance.collection('reports'); FirebaseFirestore.instance.collection('reports');
// Constructing the data to be saved // Constructing the data to be saved
Map<String, dynamic> data = {}; Map<String, dynamic> data = {};
understandingDropdownMap.forEach((key, value) { understandingDropdownMap.forEach((key, value) {
...@@ -297,9 +297,9 @@ class _KidsReportPageState extends State<KidsReportPage> { ...@@ -297,9 +297,9 @@ class _KidsReportPageState extends State<KidsReportPage> {
data[key] = value; data[key] = value;
}); });
data['sId'] = id; data['sId'] = id;
await ref.doc(id).set(data); await ref.doc(id).set(data);
AwesomeDialog( AwesomeDialog(
context: context, context: context,
dialogType: DialogType.success, dialogType: DialogType.success,
...@@ -308,5 +308,4 @@ class _KidsReportPageState extends State<KidsReportPage> { ...@@ -308,5 +308,4 @@ class _KidsReportPageState extends State<KidsReportPage> {
btnOkOnPress: () {}, btnOkOnPress: () {},
)..show(); )..show();
} }
} }
\ No newline at end of file
import 'package:cloud_firestore/cloud_firestore.dart'; import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:mobile_application_kids/teacherhome.dart';
import 'ChatScreen.dart';
import 'TeacherProfile.dart';
import 'kidsReport.dart'; // Import the AddClassroomPage file
class ReportKidsViewPage extends StatelessWidget { class ReportKidsViewPage extends StatelessWidget {
late User? user; late final Stream<QuerySnapshot> _reportsStream;
late final Stream<QuerySnapshot> _usersStream;
late String sid; late String sid;
ReportKidsViewPage({sid}) {
this.sid = sid; ReportKidsViewPage({required this.sid}) {
print(sid);
user = FirebaseAuth.instance.currentUser;
initializeStreams(); initializeStreams();
} }
void initializeStreams() { void initializeStreams() {
_usersStream = FirebaseFirestore.instance _reportsStream = FirebaseFirestore.instance
.collection('reports') .collection('reports')
.where('sId', isEqualTo: sid) .where('sId', isEqualTo: sid)
.snapshots(); .snapshots();
...@@ -27,325 +18,80 @@ class ReportKidsViewPage extends StatelessWidget { ...@@ -27,325 +18,80 @@ class ReportKidsViewPage extends StatelessWidget {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
return WillPopScope( return Scaffold(
onWillPop: () async { appBar: AppBar(
// Disable the back button press title: Text('Student Report'),
return false; ),
}, body: StreamBuilder<QuerySnapshot>(
child: Scaffold( stream: _reportsStream,
appBar: AppBar( builder: (context, snapshot) {
leading: IconButton( if (snapshot.connectionState == ConnectionState.waiting) {
icon: Icon(Icons.arrow_back), return Center(child: CircularProgressIndicator());
onPressed: () { }
Navigator.of(context).pop();
},
),
actions: [
Text(
'Report ',
style: TextStyle(
color: Color(0xFF554994),
fontSize: 24,
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
height: 0.04,
letterSpacing: -0.96,
),
)
],
),
body: Padding(
padding: const EdgeInsets.all(16.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
'Report View',
style: TextStyle(
color: Color(0xFF21205B),
fontSize: 16,
fontFamily: 'Poppins',
fontWeight: FontWeight.w500,
height: 0.06,
),
),
SizedBox(height: 30),
Expanded(
child: StreamBuilder<QuerySnapshot>(
stream: _usersStream,
builder: (context, snapshot) {
print("--------------------------------------");
print(snapshot.data!.docs.length);
if (snapshot.connectionState == ConnectionState.waiting) {
return CircularProgressIndicator();
}
if (snapshot.hasError) {
return Text('Error: ${snapshot.error}');
}
var itemCount = snapshot.data!.docs.length;
return GridView.builder(
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
crossAxisCount:
1, // Adjust this value to control the number of items per row
crossAxisSpacing:
8.0, // Adjust spacing between items horizontally
mainAxisSpacing:
8.0, // Adjust spacing between items vertically
),
itemCount: itemCount,
itemBuilder: (context, index) {
var document = snapshot.data!.docs[index];
index++;
var _valu = document['q' + index.toString()];
return Container( if (snapshot.hasError) {
color: Color(0xFFE5E5E5), return Center(child: Text('Error: ${snapshot.error}'));
child: SingleChildScrollView( }
padding: const EdgeInsets.all(8.0),
child: Column(
children: [
Container(
// decoration: BoxDecoration(
// borderRadius: BorderRadius.circular(20),
// boxShadow: [
// BoxShadow(
// color: Colors.black,
// offset: const Offset(
// 3.0,
// 3.0,
// ), //Offset
// blurRadius: 10.0,
// spreadRadius: 2.0,
// ), //BoxShadow
// BoxShadow(
// color: Colors.white,
// offset: const Offset(0.0, 0.0),
// blurRadius: 0.0,
// spreadRadius: 0.0,
// ), //BoxShadow
// ],
// ), //BoxDecoration
/** CheckboxListTile Widget **/ var docs = snapshot.data!.docs;
child: CheckboxListTile( if (docs.isEmpty) {
title: const Text('Understanding'), return Center(child: Text('No report data available'));
subtitle: const Text( }
'Understanding commands, Answer questions, Keeping eye contact, Following rules.'),
// secondary: CircleAvatar(
// backgroundImage: NetworkImage(
// "https://pbs.twimg.com/profile_images/1304985167476523008/QNHrwL2q_400x400.jpg"), //NetworkImage
// radius: 20,
// ),
autofocus: false,
isThreeLine: true,
activeColor: Colors.green,
checkColor: Colors.white,
selected: document["q1"],
value: document["q1"],
onChanged: (bool? value) {
// setState(() {
// _valu1 = value ?? false;
// });
},
), //CheckboxListTile
),
SizedBox(height: 20),
Container(
// decoration: BoxDecoration(
// borderRadius: BorderRadius.circular(20),
// boxShadow: [
// BoxShadow(
// color: Colors.black,
// offset: const Offset(
// 3.0,
// 3.0,
// ), //Offset
// blurRadius: 10.0,
// spreadRadius: 2.0,
// ), //BoxShadow
// BoxShadow(
// color: Colors.white,
// offset: const Offset(0.0, 0.0),
// blurRadius: 0.0,
// spreadRadius: 0.0,
// ), //BoxShadow
// ],
// ), //BoxDecoration
/** CheckboxListTile Widget **/ return ListView.builder(
child: CheckboxListTile( itemCount: docs.length,
title: const Text('Movements'), itemBuilder: (context, index) {
subtitle: const Text( var document = docs[index].data() as Map<String, dynamic>;
'Motor activities, Correct posture.'), return _buildReportItem('Report ${index + 1}', document);
// secondary: CircleAvatar( },
// backgroundImage: NetworkImage( );
// "https://pbs.twimg.com/profile_images/1304985167476523008/QNHrwL2q_400x400.jpg"), //NetworkImage },
// radius: 20, ),
// ), );
autofocus: false, }
isThreeLine: true,
activeColor: Colors.green,
checkColor: Colors.white,
selected: document["q2"],
value: document["q2"],
onChanged: (bool? value) {
// setState(() {
// _valu2 = value ?? false;
// });
},
), //CheckboxListTile
),
SizedBox(height: 20),
Container(
// decoration: BoxDecoration(
// borderRadius: BorderRadius.circular(20),
// boxShadow: [
// BoxShadow(
// color: Colors.black,
// offset: const Offset(
// 3.0,
// 3.0,
// ), //Offset
// blurRadius: 10.0,
// spreadRadius: 2.0,
// ), //BoxShadow
// BoxShadow(
// color: Colors.white,
// offset: const Offset(0.0, 0.0),
// blurRadius: 0.0,
// spreadRadius: 0.0,
// ), //BoxShadow
// ],
// ), //BoxDecoration
/** CheckboxListTile Widget **/ Widget _buildReportItem(String title, Map<String, dynamic> data) {
child: CheckboxListTile( // Exclude the 'sId' field from the data
title: const Text('Manipulating'), data.remove('sId');
subtitle: const Text(
'Can build/create new things, Knows how to handle accessories'),
// secondary: CircleAvatar(
// backgroundImage: NetworkImage(
// "https://pbs.twimg.com/profile_images/1304985167476523008/QNHrwL2q_400x400.jpg"), //NetworkImage
// radius: 20,
// ),
autofocus: false,
isThreeLine: true,
activeColor: Colors.green,
checkColor: Colors.white,
selected: document["q3"],
value: document["q3"],
onChanged: (bool? value) {
// setState(() {
// _valu3 = value ?? false;
// });
},
), //CheckboxListTile
),
SizedBox(height: 20),
Container(
// decoration: BoxDecoration(
// borderRadius: BorderRadius.circular(20),
// boxShadow: [
// BoxShadow(
// color: Colors.black,
// offset: const Offset(
// 3.0,
// 3.0,
// ), //Offset
// blurRadius: 10.0,
// spreadRadius: 2.0,
// ), //BoxShadow
// BoxShadow(
// color: Colors.white,
// offset: const Offset(0.0, 0.0),
// blurRadius: 0.0,
// spreadRadius: 0.0,
// ), //BoxShadow
// ],
// ), //BoxDecoration
/** CheckboxListTile Widget **/ return Card(
child: CheckboxListTile( margin: EdgeInsets.symmetric(vertical: 8, horizontal: 16),
title: const Text('Socializing'), child: Padding(
subtitle: const Text( padding: EdgeInsets.all(16),
'Play with groups, Help each other, Friendly towards peers.'), child: Column(
// secondary: CircleAvatar( crossAxisAlignment: CrossAxisAlignment.start,
// backgroundImage: NetworkImage( children: [
// "https://pbs.twimg.com/profile_images/1304985167476523008/QNHrwL2q_400x400.jpg"), //NetworkImage Text(
// radius: 20, title,
// ), style: TextStyle(
autofocus: false, fontSize: 18,
isThreeLine: true, fontWeight: FontWeight.bold,
activeColor: Colors.green, ),
checkColor: Colors.white, ),
selected: document["q4"], SizedBox(height: 8),
value: document["q4"], Column(
onChanged: (bool? value) { crossAxisAlignment: CrossAxisAlignment.start,
// setState(() { children: data.entries.map((entry) {
// _valu4 = value ?? false; return Padding(
// }); padding: EdgeInsets.symmetric(vertical: 4),
}, child: Row(
), //CheckboxListTile mainAxisAlignment: MainAxisAlignment.spaceBetween,
), children: [
], Text(
), entry.key,
), style: TextStyle(
); fontWeight: FontWeight.bold,
}, ),
); ),
}, Text(entry.value ?? 'Not provided'),
],
), ),
), );
], }).toList(),
), ),
), ],
bottomNavigationBar: BottomNavigationBar(
items: const [
BottomNavigationBarItem(
icon: Icon(Icons.home),
label: 'Home',
),
BottomNavigationBarItem(
icon: Icon(Icons.chat),
label: 'Chat',
),
BottomNavigationBarItem(
icon: Icon(Icons.person),
label: 'Profile',
),
],
selectedItemColor: Colors.blue,
onTap: (index) {
switch (index) {
case 0:
Navigator.push(
context,
MaterialPageRoute(builder: (context) => TeacherHomePage()),
);
break;
case 1:
// Navigate to Chat
Navigator.push(
context,
MaterialPageRoute(builder: (context) => ChatScreen()),
);
break;
case 2:
// Navigate to Profile
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => TeacherProfilePage(
uid: user?.uid,
)),
);
break;
}
},
),
), ),
); ),
} );
} }
}
\ No newline at end of file
import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart';
import 'package:mobile_application_kids/teacherchat.dart';
import 'package:mobile_application_kids/classroomview.dart';
import 'package:mobile_application_kids/addclassroom.dart';
import 'package:mobile_application_kids/teacherhome.dart';
import 'package:pie_chart/pie_chart.dart';
import 'package:shared_preferences/shared_preferences.dart';
import 'package:charts_flutter/flutter.dart' as charts;
import 'ChatScreen.dart';
import 'TeacherProfile.dart';
class progressReport extends StatefulWidget {
@override
_progressReportState createState() => _progressReportState();
}
class _progressReportState extends State<progressReport> {
late User? user;
late final Stream<QuerySnapshot> _usersStream;
int absCount = 0;
int preCount = 0;
@override
void initState() {
super.initState();
user = FirebaseAuth.instance.currentUser;
initializeStreams();
getAllStudentCountPresentAbs();
}
Map<String, double> dataMap = {
"Good": 0,
"Netural": 0,
"Week": 0,
};
void initializeStreams() {
_usersStream = FirebaseFirestore.instance
.collection('students')
.where('user', isEqualTo: user?.uid)
.snapshots();
}
@override
Widget build(BuildContext context) {
return WillPopScope(
onWillPop: () async {
// Disable the back button press
return false;
},
child: Scaffold(
appBar: AppBar(
leading: IconButton(
icon: Icon(Icons.arrow_back),
onPressed: () {
Navigator.of(context).pop();
},
),
actions: [
Text(
'Progress Report ',
style: TextStyle(
color: Color(0xFF554994),
fontSize: 24,
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
height: 0.04,
letterSpacing: -0.96,
),
)
],
),
body: SingleChildScrollView(
child: Padding(
padding: const EdgeInsets.all(16.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
// Text(
// 'Activity Scale ',
// style: TextStyle(
// color: Color(0xFF11324D),
// fontSize: 24,
// fontFamily: 'Poppins',
// fontWeight: FontWeight.w500,
// height: 0.04,
// letterSpacing: -0.96,
// ),
// ),
Padding(
padding: const EdgeInsets.fromLTRB(5, 5, 0, 5),
child: Container(
width: 358,
height: 362,
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Container(
width: double.infinity,
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
'Activity Scale ',
style: TextStyle(
color: Color(0xFF21205B),
fontSize: 16,
fontFamily: 'Poppins',
fontWeight: FontWeight.w500,
height: 0.06,
),
),
],
),
),
const SizedBox(height: 30),
Container(
width: double.infinity,
height: 316,
padding: const EdgeInsets.only(
top: 16,
left: 18,
right: 17,
bottom: 18,
),
clipBehavior: Clip.antiAlias,
decoration: ShapeDecoration(
color: Colors.white,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(8)),
shadows: [
BoxShadow(
color: Color(0x3F000000),
blurRadius: 3,
offset: Offset(0, 1),
spreadRadius: 0,
)
],
),
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Container(
width: 300,
height: 282,
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Container(
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.center,
children: [
SizedBox(
width: 157,
height: 13,
child: Text(
' ',
style: TextStyle(
color: Color(0xFF2B3674),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
height: 0.07,
letterSpacing: -0.28,
),
),
),
],
),
),
Center(
child: Container(
width: 300,
height: 250,
child: Stack(
children: [
PieChart(
dataMap: dataMap,
chartType: ChartType.disc,
chartRadius:
MediaQuery.of(context)
.size
.width /
2.2,
colorList: [
Color(0xFFFFD452),
Color(0xFFCE7BB0),
Color(0xFFFF8080)
],
legendOptions: LegendOptions(
showLegendsInRow: true,
legendPosition:
LegendPosition.bottom,
showLegends: true,
legendTextStyle: TextStyle(
fontWeight:
FontWeight.bold),
),
chartValuesOptions:
ChartValuesOptions(
showChartValueBackground:
true,
showChartValues: true,
showChartValuesInPercentage:
true,
showChartValuesOutside: false,
),
),
],
),
),
),
],
),
),
],
),
),
],
),
)),
SizedBox(
width: 10,
),
Padding(
padding: const EdgeInsets.fromLTRB(5, 5, 0, 5),
child: Container(
width: 358,
height: 362,
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Container(
width: double.infinity,
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
'LD Director ',
style: TextStyle(
color: Color(0xFF21205B),
fontSize: 16,
fontFamily: 'Poppins',
fontWeight: FontWeight.w500,
height: 0.06,
),
),
],
),
),
const SizedBox(height: 30),
Container(
width: double.infinity,
height: 316,
padding: const EdgeInsets.only(
top: 16,
left: 18,
right: 17,
bottom: 18,
),
clipBehavior: Clip.antiAlias,
decoration: ShapeDecoration(
color: Colors.white,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(8)),
shadows: [
BoxShadow(
color: Color(0x3F000000),
blurRadius: 3,
offset: Offset(0, 1),
spreadRadius: 0,
)
],
),
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Container(
width: 300,
height: 282,
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Container(
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.center,
children: [
SizedBox(
width: 157,
height: 13,
child: Text(
' ',
style: TextStyle(
color: Color(0xFF2B3674),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
height: 0.07,
letterSpacing: -0.28,
),
),
),
],
),
),
Center(
child: Container(
width: 300,
height: 250,
child: Stack(
children: [
charts.BarChart(
_createSampleData(),
animate: true,
vertical:
true, // To display horizontal bar chart
barRendererDecorator:
charts.BarLabelDecorator<
String>(),
domainAxis:
charts.OrdinalAxisSpec(),
),
],
),
),
),
],
),
),
],
),
),
],
),
)),
Padding(
padding: const EdgeInsets.fromLTRB(5, 5, 0, 5),
child: Container(
width: 358,
height: 362,
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Container(
width: double.infinity,
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
'Assement Progress ',
style: TextStyle(
color: Color(0xFF21205B),
fontSize: 16,
fontFamily: 'Poppins',
fontWeight: FontWeight.w500,
height: 0.06,
),
),
],
),
),
const SizedBox(height: 30),
Container(
width: double.infinity,
height: 316,
padding: const EdgeInsets.only(
top: 16,
left: 18,
right: 17,
bottom: 18,
),
clipBehavior: Clip.antiAlias,
decoration: ShapeDecoration(
color: Colors.white,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(8)),
shadows: [
BoxShadow(
color: Color(0x3F000000),
blurRadius: 3,
offset: Offset(0, 1),
spreadRadius: 0,
)
],
),
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Container(
width: 300,
height: 282,
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.start,
children: [
Container(
child: Row(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment:
MainAxisAlignment.start,
crossAxisAlignment:
CrossAxisAlignment.center,
children: [
SizedBox(
width: 157,
height: 13,
child: Text(
' ',
style: TextStyle(
color: Color(0xFF2B3674),
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w600,
height: 0.07,
letterSpacing: -0.28,
),
),
),
],
),
),
Center(
child: Container(
width: 300,
height: 250,
child: Stack(
children: [
charts.BarChart(
_createSampleData(),
animate: true,
vertical:
true, // To display horizontal bar chart
barRendererDecorator:
charts.BarLabelDecorator<
String>(),
domainAxis:
charts.OrdinalAxisSpec(),
),
],
),
),
),
],
),
),
],
),
),
],
),
)),
],
),
),
),
bottomNavigationBar: BottomNavigationBar(
items: const [
BottomNavigationBarItem(
icon: Icon(Icons.home),
label: 'Home',
),
BottomNavigationBarItem(
icon: Icon(Icons.chat),
label: 'Chat',
),
BottomNavigationBarItem(
icon: Icon(Icons.person),
label: 'Profile',
),
],
selectedItemColor: Colors.blue,
onTap: (index) async {
final prefs = await SharedPreferences.getInstance();
String rool = prefs.get('rool').toString();
// Handle bottom navigation item tap
if (index == 0) {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => TeacherHomePage()),
);
}
if (index == 1) {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => ChatScreen()),
);
}
if (index == 2) {
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => TeacherProfilePage(uid: user?.uid)),
);
}
},
),
),
);
}
Stream<QuerySnapshot> getStudentsStream(String genderFilter, int isCheck) {
return FirebaseFirestore.instance
.collection('students')
.where('user', isEqualTo: user?.uid)
.where('Sex', isEqualTo: genderFilter)
.where('isCheck', isEqualTo: isCheck)
.snapshots();
}
Future<String> getMaleStudentCount(String sex, int isCheck) async {
try {
QuerySnapshot snapshot = await getStudentsStream(sex, isCheck).first;
return snapshot.size.toString();
} catch (e) {
print('Error getting male student count: $e');
return '0';
}
}
Stream<QuerySnapshot> getAllStudentsStream(int isCheck) {
return FirebaseFirestore.instance
.collection('students')
.where('user', isEqualTo: user?.uid)
.where('isCheck', isEqualTo: isCheck)
.snapshots();
}
Future<String> getAllStudentCount(int isCheck) async {
try {
QuerySnapshot snapshot = await getAllStudentsStream(isCheck).first;
print('size' + snapshot.size.toString());
return snapshot.size.toString();
} catch (e) {
print('Error getting male student count: $e');
return '0';
}
}
Stream<QuerySnapshot> getAllStudentsStreams() {
return FirebaseFirestore.instance
.collection('students')
.where('user', isEqualTo: user?.uid)
.snapshots();
}
Future<void> getAllStudentCountPresentAbs() async {
try {
QuerySnapshot snapshot2 = await getAllStudentsStreams().first;
QuerySnapshot snapshot = await getAllStudentsStream(0).first;
QuerySnapshot snapshotAbs = await getAllStudentsStream(1).first;
preCount = snapshot.size;
absCount = snapshotAbs.size;
var pre = (snapshot.size / snapshot2.size) * 100;
var abs = (snapshotAbs.size / snapshot2.size) * 100;
setState(() {
dataMap["Good"] = 25.0;
dataMap["Netural"] = 35.0;
dataMap["Week"] = 40.0;
});
print("ss" + preCount.round().toString());
} catch (e) {
print('Error getting male student count: $e');
}
}
List<charts.Series<SymptomData, String>> _createSampleData() {
final data = [
SymptomData('Dyslexia', 90, Colors.pink),
SymptomData('DCD', 3, Colors.purple),
SymptomData('ADHD', 5, Colors.green),
SymptomData('ASD', 2, Colors.blue),
];
return [
charts.Series<SymptomData, String>(
id: 'Symptoms',
domainFn: (SymptomData symptoms, _) => symptoms.symptom,
measureFn: (SymptomData symptoms, _) => symptoms.percentage,
colorFn: (SymptomData symptoms, _) => symptoms.color,
data: data,
labelAccessorFn: (SymptomData row, _) => '${row.percentage}%',
)
];
}
}
class SymptomData {
final String symptom;
final int percentage;
final charts.Color color;
SymptomData(this.symptom, this.percentage, Color color)
: this.color = charts.Color(
r: color.red,
g: color.green,
b: color.blue,
a: color.alpha,
);
}
...@@ -25,7 +25,7 @@ class _LoginPage extends State<LoginPage> { ...@@ -25,7 +25,7 @@ class _LoginPage extends State<LoginPage> {
Widget build(BuildContext context) { Widget build(BuildContext context) {
return Scaffold( return Scaffold(
appBar: AppBar( appBar: AppBar(
backgroundColor: Colors.transparent, backgroundColor: Colors.white,
elevation: 0, elevation: 0,
leading: IconButton( leading: IconButton(
icon: const Icon( icon: const Icon(
...@@ -135,14 +135,15 @@ class _LoginPage extends State<LoginPage> { ...@@ -135,14 +135,15 @@ class _LoginPage extends State<LoginPage> {
width: double.infinity, width: double.infinity,
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.circular(10.0), borderRadius: BorderRadius.circular(10.0),
color: Colors.green, color: Colors.blueAccent,
), ),
child: Center( child: Center(
child: Padding( child: Padding(
padding: const EdgeInsets.all(10.0), padding: const EdgeInsets.all(15.0),
child: Text( child: Text(
'Login', 'Login',
style: TextStyle(color: Colors.black), style:
TextStyle(color: Colors.white, fontSize: 16),
), ),
), ),
), ),
......
...@@ -61,14 +61,14 @@ class _MyHomePageState extends State<MyHomePage> { ...@@ -61,14 +61,14 @@ class _MyHomePageState extends State<MyHomePage> {
@override @override
void initState() { void initState() {
super.initState(); super.initState();
Timer.periodic(Duration(milliseconds: 500), (timer) { Timer.periodic(Duration(milliseconds: 800), (timer) {
setState(() { setState(() {
// Toggle between zoom in and zoom out // Toggle between zoom in and zoom out
scaleFactor = scaleFactor == 1.0 ? 1.05 : 1.0; scaleFactor = scaleFactor == 1.0 ? 1.05 : 1.0;
}); });
}); });
Future.delayed(Duration(seconds: 3), () { Future.delayed(Duration(seconds: 2), () {
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute( MaterialPageRoute(
......
...@@ -67,12 +67,12 @@ class ParentTeacherPage extends StatelessWidget { ...@@ -67,12 +67,12 @@ class ParentTeacherPage extends StatelessWidget {
child: Container( child: Container(
width: 200, width: 200,
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.circular(10.0), borderRadius: BorderRadius.circular(8.0),
color: Color.fromARGB(220, 164, 68, 215), color: Colors.blueAccent,
), ),
child: Center( child: Center(
child: Padding( child: Padding(
padding: const EdgeInsets.all(10.0), padding: const EdgeInsets.all(12.0),
child: Text( child: Text(
'Parent', 'Parent',
style: TextStyle(color: Colors.white), style: TextStyle(color: Colors.white),
...@@ -100,12 +100,12 @@ class ParentTeacherPage extends StatelessWidget { ...@@ -100,12 +100,12 @@ class ParentTeacherPage extends StatelessWidget {
child: Container( child: Container(
width: 200, width: 200,
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.circular(10.0), borderRadius: BorderRadius.circular(8.0),
color: Color.fromARGB(220, 164, 68, 215), color: Colors.blueAccent,
), ),
child: Center( child: Center(
child: Padding( child: Padding(
padding: const EdgeInsets.all(10.0), padding: const EdgeInsets.all(12.0),
child: Text( child: Text(
'Teacher', 'Teacher',
style: TextStyle(color: Colors.white), style: TextStyle(color: Colors.white),
......
...@@ -67,12 +67,12 @@ class ParentTeacherSignUpPage extends StatelessWidget { ...@@ -67,12 +67,12 @@ class ParentTeacherSignUpPage extends StatelessWidget {
child: Container( child: Container(
width: 200, width: 200,
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.circular(10.0), borderRadius: BorderRadius.circular(8.0),
color: Color.fromARGB(220, 164, 68, 215), color: Colors.blueAccent,
), ),
child: Center( child: Center(
child: Padding( child: Padding(
padding: const EdgeInsets.all(10.0), padding: const EdgeInsets.all(12.0),
child: Text( child: Text(
'Parent', 'Parent',
style: TextStyle(color: Colors.white), style: TextStyle(color: Colors.white),
...@@ -98,12 +98,12 @@ class ParentTeacherSignUpPage extends StatelessWidget { ...@@ -98,12 +98,12 @@ class ParentTeacherSignUpPage extends StatelessWidget {
child: Container( child: Container(
width: 200, width: 200,
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.circular(10.0), borderRadius: BorderRadius.circular(8.0),
color: Color.fromARGB(220, 164, 68, 215), color: Colors.blueAccent,
), ),
child: Center( child: Center(
child: Padding( child: Padding(
padding: const EdgeInsets.all(10.0), padding: const EdgeInsets.all(12.0),
child: Text( child: Text(
'Teacher', 'Teacher',
style: TextStyle(color: Colors.white), style: TextStyle(color: Colors.white),
......
import 'package:cloud_firestore/cloud_firestore.dart'; import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart'; import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:mobile_application_kids/addclassroom.dart';
import 'package:mobile_application_kids/childrenProfile.dart';
import 'package:mobile_application_kids/classroomview.dart'; import 'package:mobile_application_kids/classroomview.dart';
import 'package:mobile_application_kids/addclassroom.dart';
import 'package:mobile_application_kids/games.dart'; import 'package:mobile_application_kids/games.dart';
import 'package:mobile_application_kids/teacherchat.dart'; import 'package:mobile_application_kids/teacherchat.dart';
import 'ChatScreen.dart'; import 'ChatScreen.dart';
import 'TeacherProfile.dart'; import 'TeacherProfile.dart';
import 'childrenProfile.dart';
class ParentHomePage extends StatelessWidget { class ParentHomePage extends StatelessWidget {
late User? user; late User? user;
late final Stream<QuerySnapshot> _usersStream; late final Stream<QuerySnapshot> _usersStream;
late String phoneNo; late String phoneNo;
late String role; late String role;
ParentHomePage(param0, role) { ParentHomePage(param0, role) {
this.role = role; this.role = role;
this.phoneNo = param0; this.phoneNo = param0;
...@@ -30,6 +29,7 @@ class ParentHomePage extends StatelessWidget { ...@@ -30,6 +29,7 @@ class ParentHomePage extends StatelessWidget {
.snapshots(); .snapshots();
} }
// Define a TextStyle with the Poppins font
final TextStyle poppinsTextStyle = TextStyle( final TextStyle poppinsTextStyle = TextStyle(
fontFamily: 'Poppins', fontFamily: 'Poppins',
); );
...@@ -38,14 +38,24 @@ class ParentHomePage extends StatelessWidget { ...@@ -38,14 +38,24 @@ class ParentHomePage extends StatelessWidget {
Widget build(BuildContext context) { Widget build(BuildContext context) {
return WillPopScope( return WillPopScope(
onWillPop: () async { onWillPop: () async {
// Disable the back button press
return false; return false;
}, },
child: Scaffold( child: Scaffold(
appBar: AppBar( appBar: AppBar(
// leading: Flexible(
// child: Image.asset(
// 'lib/assets/logo.png',
// fit: BoxFit.contain,
// height: 150, // Adjust the height to make the logo bigger
// ),
// ),
actions: [ actions: [
IconButton( IconButton(
icon: Icon(Icons.notifications), icon: Icon(Icons.notifications),
onPressed: () {}, onPressed: () {
// Handle notification icon press
},
), ),
], ],
), ),
...@@ -58,6 +68,7 @@ class ParentHomePage extends StatelessWidget { ...@@ -58,6 +68,7 @@ class ParentHomePage extends StatelessWidget {
Text( Text(
'Explore, learn, and play in our magical world of wonder!', 'Explore, learn, and play in our magical world of wonder!',
style: poppinsTextStyle.copyWith( style: poppinsTextStyle.copyWith(
// fontWeight: FontWeight.bold,
fontSize: 13, fontSize: 13,
), ),
), ),
...@@ -74,9 +85,11 @@ class ParentHomePage extends StatelessWidget { ...@@ -74,9 +85,11 @@ class ParentHomePage extends StatelessWidget {
children: [ children: [
TextButton( TextButton(
onPressed: () { onPressed: () {
// Navigate to the AddClassroomPage
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute(builder: (context) => AddClassroomPage()), MaterialPageRoute(
builder: (context) => AddClassroomPage()),
); );
}, },
child: Row( child: Row(
...@@ -99,6 +112,7 @@ class ParentHomePage extends StatelessWidget { ...@@ -99,6 +112,7 @@ class ParentHomePage extends StatelessWidget {
child: StreamBuilder<QuerySnapshot>( child: StreamBuilder<QuerySnapshot>(
stream: _usersStream, stream: _usersStream,
builder: (context, snapshot) { builder: (context, snapshot) {
print("--------------------------------------");
if (snapshot.connectionState == ConnectionState.waiting) { if (snapshot.connectionState == ConnectionState.waiting) {
return CircularProgressIndicator(); return CircularProgressIndicator();
} }
...@@ -106,6 +120,7 @@ class ParentHomePage extends StatelessWidget { ...@@ -106,6 +120,7 @@ class ParentHomePage extends StatelessWidget {
if (snapshot.hasError) { if (snapshot.hasError) {
return Text('Error: ${snapshot.error}'); return Text('Error: ${snapshot.error}');
} }
var itemcount = snapshot.data!.docs.length;
return ListView.builder( return ListView.builder(
itemCount: snapshot.data!.docs.length, itemCount: snapshot.data!.docs.length,
...@@ -113,13 +128,16 @@ class ParentHomePage extends StatelessWidget { ...@@ -113,13 +128,16 @@ class ParentHomePage extends StatelessWidget {
var document = snapshot.data!.docs[index]; var document = snapshot.data!.docs[index];
var className = document['className']; var className = document['className'];
var name = document['Firstname']; var name = document['Firstname'];
print(document);
return Padding( return Padding(
padding: const EdgeInsets.only(bottom: 8.0), padding: const EdgeInsets.only(
bottom: 8.0), // Adjust the spacing as needed
child: ListTile( child: ListTile(
leading: CircleAvatar( leading: CircleAvatar(
radius: 27.0, radius: 27.0,
backgroundImage: AssetImage('lib/assets/classlogo.png'), backgroundImage:
AssetImage('lib/assets/classlogo.png'),
), ),
title: Column( title: Column(
crossAxisAlignment: CrossAxisAlignment.start, crossAxisAlignment: CrossAxisAlignment.start,
...@@ -153,12 +171,13 @@ class ParentHomePage extends StatelessWidget { ...@@ -153,12 +171,13 @@ class ParentHomePage extends StatelessWidget {
), ),
child: TextButton( child: TextButton(
onPressed: () { onPressed: () {
print(document);
// Handle view class button press
Navigator.push( Navigator.push(
context, context,
MaterialPageRoute( MaterialPageRoute(
builder: (context) => ChildrenProfilePage( builder: (context) =>
document, ChildrenProfilePage(document, "P"),
),
), ),
); );
}, },
...@@ -180,6 +199,50 @@ class ParentHomePage extends StatelessWidget { ...@@ -180,6 +199,50 @@ class ParentHomePage extends StatelessWidget {
], ],
), ),
), ),
// bottomNavigationBar: BottomNavigationBar(
// items: const [
// BottomNavigationBarItem(
// icon: Icon(Icons.home),
// label: 'Home',
// ),
// BottomNavigationBarItem(
// icon: Icon(Icons.chat),
// label: 'Chat',
// ),
// BottomNavigationBarItem(
// icon: Icon(Icons.person),
// label: 'Profile',
// ),
// ],
// selectedItemColor: Colors.blue,
// onTap: (index) {
// // Handle bottom navigation item tap
// switch (index) {
// case 0:
// break;
// case 1:
// // Navigate to Chat
// Navigator.push(
// context,
// MaterialPageRoute(builder: (context) => ChatScreen()),
// );
// break;
// case 2:
// // Navigate to Profile
// Navigator.push(
// context,
// MaterialPageRoute(
// builder: (context) => TeacherProfilePage(
// uid: user?.uid,
// )),
// );
// break;
// }
// },
// ),
bottomNavigationBar: BottomNavigationBar( bottomNavigationBar: BottomNavigationBar(
items: const [ items: const [
BottomNavigationBarItem( BottomNavigationBarItem(
......
import 'package:cloud_firestore/cloud_firestore.dart'; import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart'; import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:jema_app/teacherchat.dart'; import 'package:mobile_application_kids/teacherchat.dart';
import 'package:jema_app/classroomview.dart'; import 'package:mobile_application_kids/classroomview.dart';
import 'package:jema_app/addclassroom.dart'; import 'package:mobile_application_kids/addclassroom.dart';
import 'package:jema_app/teacherhome.dart'; import 'package:mobile_application_kids/teacherhome.dart';
import 'package:pie_chart/pie_chart.dart'; import 'package:pie_chart/pie_chart.dart';
import 'package:shared_preferences/shared_preferences.dart'; import 'package:shared_preferences/shared_preferences.dart';
......
import 'package:cloud_firestore/cloud_firestore.dart'; import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart'; import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:jema_app/teacherchat.dart'; import 'package:mobile_application_kids/teacherchat.dart';
import 'package:jema_app/classroomview.dart'; import 'package:mobile_application_kids/classroomview.dart';
import 'package:jema_app/addclassroom.dart'; import 'package:mobile_application_kids/addclassroom.dart';
import 'package:jema_app/teacherhome.dart'; import 'package:mobile_application_kids/teacherhome.dart';
import 'package:pie_chart/pie_chart.dart'; import 'package:pie_chart/pie_chart.dart';
import 'package:shared_preferences/shared_preferences.dart'; import 'package:shared_preferences/shared_preferences.dart';
import 'package:charts_flutter/flutter.dart' as charts; import 'package:charts_flutter/flutter.dart' as charts;
......
...@@ -49,12 +49,12 @@ class SignInUpPage extends StatelessWidget { ...@@ -49,12 +49,12 @@ class SignInUpPage extends StatelessWidget {
child: Container( child: Container(
width: 200, width: 200,
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.circular(10.0), borderRadius: BorderRadius.circular(8.0),
color: Color.fromARGB(255, 96, 188, 99), color: Color.fromARGB(255, 96, 188, 99),
), ),
child: Center( child: Center(
child: Padding( child: Padding(
padding: const EdgeInsets.all(10.0), padding: const EdgeInsets.all(12.0),
child: Text( child: Text(
'Sign Up', 'Sign Up',
style: TextStyle(color: Colors.white), style: TextStyle(color: Colors.white),
...@@ -83,12 +83,12 @@ class SignInUpPage extends StatelessWidget { ...@@ -83,12 +83,12 @@ class SignInUpPage extends StatelessWidget {
child: Container( child: Container(
width: 200, width: 200,
decoration: BoxDecoration( decoration: BoxDecoration(
borderRadius: BorderRadius.circular(10.0), borderRadius: BorderRadius.circular(8.0),
color: const Color.fromARGB(255, 213, 80, 236), color: Colors.blueAccent,
), ),
child: Center( child: Center(
child: Padding( child: Padding(
padding: const EdgeInsets.all(10.0), padding: const EdgeInsets.all(12.0),
child: Text( child: Text(
'Sign In', 'Sign In',
style: TextStyle(color: Colors.white), style: TextStyle(color: Colors.white),
......
...@@ -97,10 +97,10 @@ class TeacherHomePage extends StatelessWidget { ...@@ -97,10 +97,10 @@ class TeacherHomePage extends StatelessWidget {
), ),
), ),
Container( Container(
margin: EdgeInsets.only(left: 8.0), margin: EdgeInsets.only(left: 20.0),
padding: EdgeInsets.all(8.0), padding: EdgeInsets.all(8.0),
decoration: BoxDecoration( decoration: BoxDecoration(
color: Color.fromARGB(203, 164, 88, 177), color: Colors.blueAccent,
borderRadius: BorderRadius.circular(8.0), borderRadius: BorderRadius.circular(8.0),
), ),
child: Icon( child: Icon(
...@@ -118,7 +118,7 @@ class TeacherHomePage extends StatelessWidget { ...@@ -118,7 +118,7 @@ class TeacherHomePage extends StatelessWidget {
Text( Text(
'Class Rooms', 'Class Rooms',
style: poppinsTextStyle.copyWith( style: poppinsTextStyle.copyWith(
fontSize: 16, fontSize: 18,
fontWeight: FontWeight.bold, fontWeight: FontWeight.bold,
), ),
), ),
...@@ -169,18 +169,18 @@ class TeacherHomePage extends StatelessWidget { ...@@ -169,18 +169,18 @@ class TeacherHomePage extends StatelessWidget {
Text( Text(
'Class $index', 'Class $index',
style: poppinsTextStyle.copyWith( style: poppinsTextStyle.copyWith(
fontSize: 12.0), fontSize: 14.0),
), ),
], ],
), ),
], ],
), ),
trailing: Container( trailing: Container(
height: 35.0, height: 40.0,
width: 80.0, width: 100.0,
decoration: BoxDecoration( decoration: BoxDecoration(
color: Color.fromARGB(203, 164, 88, 177), color: Colors.blueAccent,
borderRadius: BorderRadius.circular(4.0), borderRadius: BorderRadius.circular(8.0),
), ),
child: TextButton( child: TextButton(
onPressed: () { onPressed: () {
......
name: jema_app name: mobile_application_kids
description: A new Flutter project. description: A new Flutter project.
# The following line prevents the package from being accidentally published to # The following line prevents the package from being accidentally published to
# pub.dev using `flutter pub publish`. This is preferred for private packages. # pub.dev using `flutter pub publish`. This is preferred for private packages.
...@@ -96,7 +96,9 @@ flutter: ...@@ -96,7 +96,9 @@ flutter:
- lib/assets/ac4.png - lib/assets/ac4.png
- lib/assets/ac5.png - lib/assets/ac5.png
- lib/assets/banner.png - lib/assets/banner.png
- lib/assets/ac6.png
- lib/assets/ac7.png
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment