7 Commits

Author SHA1 Message Date
5d264f7651 added notes for next tasks 2024-03-30 18:33:52 +01:00
a6f7c09671 wip 2024-03-29 21:58:51 +01:00
eaf6d9f547 updated new linter rules 2024-03-29 18:47:54 +01:00
5b34afd6cb Merge branch 'develop' into feature-highEduGraduationCalculator
# Conflicts:
#	lib/view/pages/overhang.dart
2024-03-29 18:32:59 +01:00
25d901d093 WIP lk select dialog 2024-03-29 17:29:31 +01:00
6237a2e9cf Merge branch 'develop' into feature-highEduGraduationCalculator
# Conflicts:
#	lib/view/pages/overhang.dart
2024-03-24 14:21:01 +01:00
c4f5be2205 WIP high education graduation calculator 2024-03-23 15:42:31 +01:00
356 changed files with 4210 additions and 8254 deletions

16
.gitignore vendored
View File

@@ -48,14 +48,14 @@ lib/generated_plugin_registrant.dart
#pubspec.lock
# Android related
materials/screenshots/android/**/gradle-wrapper.jar
materials/screenshots/android/.gradle
materials/screenshots/android/captures/
materials/screenshots/android/gradlew
materials/screenshots/android/gradlew.bat
materials/screenshots/android/key.properties
materials/screenshots/android/local.properties
materials/screenshots/android/**/GeneratedPluginRegistrant.java
**/android/**/gradle-wrapper.jar
**/android/.gradle
**/android/captures/
**/android/gradlew
**/android/gradlew.bat
**/android/key.properties
**/android/local.properties
**/android/**/GeneratedPluginRegistrant.java
# iOS/XCode related
**/ios/**/*.mode1v3

View File

@@ -9,10 +9,6 @@
# packages, and plugins designed to encourage good coding practices.
include: package:flutter_lints/flutter.yaml
analyzer:
errors:
invalid_annotation_target: ignore
linter:
# The lint rules applied to this project can be customized in the
# section below to disable rules from the `package:flutter_lints/flutter.yaml`
@@ -32,13 +28,6 @@ linter:
prefer_relative_imports: true
unnecessary_lambdas: true
prefer_single_quotes: true
prefer_if_elements_to_conditional_expressions: true
prefer_expression_function_bodies: true
omit_local_variable_types: true
eol_at_end_of_file: true
cast_nullable_to_non_nullable: true
avoid_void_async: true
avoid_multiple_declarations_per_line: true
# Additional information about this file can be found at
# https://dart.dev/guides/language/analysis-options

View File

@@ -25,16 +25,15 @@ if (flutterVersionName == null) {
android {
namespace "eu.mhsl.marianum.mobile.client"
compileSdk flutter.compileSdkVersion
ndkVersion "27.0.12077973"
ndkVersion flutter.ndkVersion
compileOptions {
sourceCompatibility JavaVersion.VERSION_17
targetCompatibility JavaVersion.VERSION_17
coreLibraryDesugaringEnabled true
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = '17'
jvmTarget = '1.8'
}
sourceSets {
@@ -42,8 +41,11 @@ android {
}
defaultConfig {
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
applicationId "eu.mhsl.marianum.mobile.client"
minSdkVersion 26
// You can update the following values to match your application needs.
// For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-gradle-build-configuration.
minSdkVersion 19
targetSdkVersion flutter.targetSdkVersion
versionCode flutterVersionCode.toInteger()
versionName flutterVersionName
@@ -64,6 +66,5 @@ flutter {
}
dependencies {
implementation 'com.android.support:multidex:2.0.1'
coreLibraryDesugaring 'com.android.tools:desugar_jdk_libs:2.1.4'
implementation 'com.android.support:multidex:1.0.3'
}

View File

View File

@@ -1,6 +1,3 @@
org.gradle.jvmargs=-Xmx4G
android.useAndroidX=true
android.enableJetifier=true
android.defaults.buildfeatures.buildconfig=true
android.nonTransitiveRClass=false
android.nonFinalResIds=false

View File

@@ -1,7 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.11.1-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.1-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists

View File

@@ -19,9 +19,8 @@ pluginManagement {
plugins {
id "dev.flutter.flutter-plugin-loader" version "1.0.0"
id "com.android.application" version "8.9.1" apply false
id "com.android.library" version "8.9.1" apply false
id "org.jetbrains.kotlin.android" version "2.1.10" apply false
id "com.android.application" version "7.3.0" apply false
id "org.jetbrains.kotlin.android" version "1.7.10" apply false
}
include ":app"

View File

@@ -1,29 +0,0 @@
-----BEGIN CERTIFICATE-----
MIIFBTCCAu2gAwIBAgIQS6hSk/eaL6JzBkuoBI110DANBgkqhkiG9w0BAQsFADBP
MQswCQYDVQQGEwJVUzEpMCcGA1UEChMgSW50ZXJuZXQgU2VjdXJpdHkgUmVzZWFy
Y2ggR3JvdXAxFTATBgNVBAMTDElTUkcgUm9vdCBYMTAeFw0yNDAzMTMwMDAwMDBa
Fw0yNzAzMTIyMzU5NTlaMDMxCzAJBgNVBAYTAlVTMRYwFAYDVQQKEw1MZXQncyBF
bmNyeXB0MQwwCgYDVQQDEwNSMTAwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEK
AoIBAQDPV+XmxFQS7bRH/sknWHZGUCiMHT6I3wWd1bUYKb3dtVq/+vbOo76vACFL
YlpaPAEvxVgD9on/jhFD68G14BQHlo9vH9fnuoE5CXVlt8KvGFs3Jijno/QHK20a
/6tYvJWuQP/py1fEtVt/eA0YYbwX51TGu0mRzW4Y0YCF7qZlNrx06rxQTOr8IfM4
FpOUurDTazgGzRYSespSdcitdrLCnF2YRVxvYXvGLe48E1KGAdlX5jgc3421H5KR
mudKHMxFqHJV8LDmowfs/acbZp4/SItxhHFYyTr6717yW0QrPHTnj7JHwQdqzZq3
DZb3EoEmUVQK7GH29/Xi8orIlQ2NAgMBAAGjgfgwgfUwDgYDVR0PAQH/BAQDAgGG
MB0GA1UdJQQWMBQGCCsGAQUFBwMCBggrBgEFBQcDATASBgNVHRMBAf8ECDAGAQH/
AgEAMB0GA1UdDgQWBBS7vMNHpeS8qcbDpHIMEI2iNeHI6DAfBgNVHSMEGDAWgBR5
tFnme7bl5AFzgAiIyBpY9umbbjAyBggrBgEFBQcBAQQmMCQwIgYIKwYBBQUHMAKG
Fmh0dHA6Ly94MS5pLmxlbmNyLm9yZy8wEwYDVR0gBAwwCjAIBgZngQwBAgEwJwYD
VR0fBCAwHjAcoBqgGIYWaHR0cDovL3gxLmMubGVuY3Iub3JnLzANBgkqhkiG9w0B
AQsFAAOCAgEAkrHnQTfreZ2B5s3iJeE6IOmQRJWjgVzPw139vaBw1bGWKCIL0vIo
zwzn1OZDjCQiHcFCktEJr59L9MhwTyAWsVrdAfYf+B9haxQnsHKNY67u4s5Lzzfd
u6PUzeetUK29v+PsPmI2cJkxp+iN3epi4hKu9ZzUPSwMqtCceb7qPVxEbpYxY1p9
1n5PJKBLBX9eb9LU6l8zSxPWV7bK3lG4XaMJgnT9x3ies7msFtpKK5bDtotij/l0
GaKeA97pb5uwD9KgWvaFXMIEt8jVTjLEvwRdvCn294GPDF08U8lAkIv7tghluaQh
1QnlE4SEN4LOECj8dsIGJXpGUk3aU3KkJz9icKy+aUgA+2cP21uh6NcDIS3XyfaZ
QjmDQ993ChII8SXWupQZVBiIpcWO4RqZk3lr7Bz5MUCwzDIA359e57SSq5CCkY0N
4B6Vulk7LktfwrdGNVI5BsC9qqxSwSKgRJeZ9wygIaehbHFHFhcBaMDKpiZlBHyz
rsnnlFXCb5s8HKn5LsUgGvB24L7sGNZP2CX7dhHov+YhD+jozLW2p9W4959Bz2Ei
RmqDtmiXLnzqTpXbI+suyCsohKRg6Un0RC47+cpiVwHiXZAW+cn8eiNIjqbVgXLx
KPpdzvvtTnOPlC7SQZSYmdunr3Bf9b77AiC/ZidstK36dRILKz7OA54=
-----END CERTIFICATE-----

View File

@@ -1,29 +0,0 @@
-----BEGIN CERTIFICATE-----
MIIFBTCCAu2gAwIBAgIQWgDyEtjUtIDzkkFX6imDBTANBgkqhkiG9w0BAQsFADBP
MQswCQYDVQQGEwJVUzEpMCcGA1UEChMgSW50ZXJuZXQgU2VjdXJpdHkgUmVzZWFy
Y2ggR3JvdXAxFTATBgNVBAMTDElTUkcgUm9vdCBYMTAeFw0yNDAzMTMwMDAwMDBa
Fw0yNzAzMTIyMzU5NTlaMDMxCzAJBgNVBAYTAlVTMRYwFAYDVQQKEw1MZXQncyBF
bmNyeXB0MQwwCgYDVQQDEwNSMTMwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEK
AoIBAQClZ3CN0FaBZBUXYc25BtStGZCMJlA3mBZjklTb2cyEBZPs0+wIG6BgUUNI
fSvHSJaetC3ancgnO1ehn6vw1g7UDjDKb5ux0daknTI+WE41b0VYaHEX/D7YXYKg
L7JRbLAaXbhZzjVlyIuhrxA3/+OcXcJJFzT/jCuLjfC8cSyTDB0FxLrHzarJXnzR
yQH3nAP2/Apd9Np75tt2QnDr9E0i2gB3b9bJXxf92nUupVcM9upctuBzpWjPoXTi
dYJ+EJ/B9aLrAek4sQpEzNPCifVJNYIKNLMc6YjCR06CDgo28EdPivEpBHXazeGa
XP9enZiVuppD0EqiFwUBBDDTMrOPAgMBAAGjgfgwgfUwDgYDVR0PAQH/BAQDAgGG
MB0GA1UdJQQWMBQGCCsGAQUFBwMCBggrBgEFBQcDATASBgNVHRMBAf8ECDAGAQH/
AgEAMB0GA1UdDgQWBBTnq58PLDOgU9NeT3jIsoQOO9aSMzAfBgNVHSMEGDAWgBR5
tFnme7bl5AFzgAiIyBpY9umbbjAyBggrBgEFBQcBAQQmMCQwIgYIKwYBBQUHMAKG
Fmh0dHA6Ly94MS5pLmxlbmNyLm9yZy8wEwYDVR0gBAwwCjAIBgZngQwBAgEwJwYD
VR0fBCAwHjAcoBqgGIYWaHR0cDovL3gxLmMubGVuY3Iub3JnLzANBgkqhkiG9w0B
AQsFAAOCAgEAUTdYUqEimzW7TbrOypLqCfL7VOwYf/Q79OH5cHLCZeggfQhDconl
k7Kgh8b0vi+/XuWu7CN8n/UPeg1vo3G+taXirrytthQinAHGwc/UdbOygJa9zuBc
VyqoH3CXTXDInT+8a+c3aEVMJ2St+pSn4ed+WkDp8ijsijvEyFwE47hulW0Ltzjg
9fOV5Pmrg/zxWbRuL+k0DBDHEJennCsAen7c35Pmx7jpmJ/HtgRhcnz0yjSBvyIw
6L1QIupkCv2SBODT/xDD3gfQQyKv6roV4G2EhfEyAsWpmojxjCUCGiyg97FvDtm/
NK2LSc9lybKxB73I2+P2G3CaWpvvpAiHCVu30jW8GCxKdfhsXtnIy2imskQqVZ2m
0Pmxobb28Tucr7xBK7CtwvPrb79os7u2XP3O5f9b/H66GNyRrglRXlrYjI1oGYL/
f4I1n/Sgusda6WvA6C190kxjU15Y12mHU4+BxyR9cx2hhGS9fAjMZKJss28qxvz6
Axu4CaDmRNZpK/pQrXF17yXCXkmEWgvSOEZy6Z9pcbLIVEGckV/iVeq0AOo2pkg9
p4QRIy0tK2diRENLSF2KysFwbY6B26BFeFs3v1sYVRhFW9nLkOrQVporCS0KyZmf
wVD89qSTlnctLcZnIavjKsKUu1nA1iU0yYMdYepKR7lWbnwhdx3ewok=
-----END CERTIFICATE-----

Binary file not shown.

Before

Width:  |  Height:  |  Size: 101 KiB

After

Width:  |  Height:  |  Size: 108 KiB

View File

@@ -1,7 +0,0 @@
targets:
$default:
builders:
json_serializable:
options:
explicit_to_json: false
generic_argument_factories: true

View File

@@ -1,4 +1 @@
extensions:
- hive_ce: true
- shared_preferences: true
- provider: true

View File

@@ -1,9 +0,0 @@
flutter_launcher_icons:
android: true
ios: true
remove_alpha_ios: true
image_path_android: "assets/logo/icon/ic_launcher.png"
image_path_ios: "assets/logo/icon/1024.png"
adaptive_icon_background: "assets/logo/icon/ic_launcher_adaptive_back.png" # only available for Android 8.0 devices and above
adaptive_icon_foreground: "assets/logo/icon/ic_launcher_adaptive_fore.png" # only available for Android 8.0 devices and above
min_sdk_android: 16 # android min sdk min:16, default 21

View File

Before

Width:  |  Height:  |  Size: 94 KiB

After

Width:  |  Height:  |  Size: 94 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 185 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 154 KiB

View File

Before

Width:  |  Height:  |  Size: 100 KiB

After

Width:  |  Height:  |  Size: 100 KiB

BIN
ios/.DS_Store vendored Normal file

Binary file not shown.

View File

@@ -21,6 +21,6 @@
<key>CFBundleVersion</key>
<string>1.0</string>
<key>MinimumOSVersion</key>
<string>13.0</string>
<string>11.0</string>
</dict>
</plist>

View File

@@ -1,5 +1,5 @@
# Uncomment this line to define a global platform for your project
platform :ios, '15.0'
platform :ios, '11.0'
# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
ENV['COCOAPODS_DISABLE_STATS'] = 'true'
@@ -31,8 +31,6 @@ target 'Runner' do
use_frameworks!
use_modular_headers!
pod 'PhoneNumberKit', '~> 3.7.6'
flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__))
# target 'RunnerTests' do
# inherit! :search_paths

View File

@@ -1,190 +1,185 @@
PODS:
- connectivity_plus (0.0.1):
- better_open_file (0.0.1):
- Flutter
- device_info_plus (0.0.1):
- Flutter
- DKImagePickerController/Core (4.3.9):
- DKImagePickerController/Core (4.3.4):
- DKImagePickerController/ImageDataManager
- DKImagePickerController/Resource
- DKImagePickerController/ImageDataManager (4.3.9)
- DKImagePickerController/PhotoGallery (4.3.9):
- DKImagePickerController/ImageDataManager (4.3.4)
- DKImagePickerController/PhotoGallery (4.3.4):
- DKImagePickerController/Core
- DKPhotoGallery
- DKImagePickerController/Resource (4.3.9)
- DKPhotoGallery (0.0.19):
- DKPhotoGallery/Core (= 0.0.19)
- DKPhotoGallery/Model (= 0.0.19)
- DKPhotoGallery/Preview (= 0.0.19)
- DKPhotoGallery/Resource (= 0.0.19)
- DKImagePickerController/Resource (4.3.4)
- DKPhotoGallery (0.0.17):
- DKPhotoGallery/Core (= 0.0.17)
- DKPhotoGallery/Model (= 0.0.17)
- DKPhotoGallery/Preview (= 0.0.17)
- DKPhotoGallery/Resource (= 0.0.17)
- SDWebImage
- SwiftyGif
- DKPhotoGallery/Core (0.0.19):
- DKPhotoGallery/Core (0.0.17):
- DKPhotoGallery/Model
- DKPhotoGallery/Preview
- SDWebImage
- SwiftyGif
- DKPhotoGallery/Model (0.0.19):
- DKPhotoGallery/Model (0.0.17):
- SDWebImage
- SwiftyGif
- DKPhotoGallery/Preview (0.0.19):
- DKPhotoGallery/Preview (0.0.17):
- DKPhotoGallery/Model
- DKPhotoGallery/Resource
- SDWebImage
- SwiftyGif
- DKPhotoGallery/Resource (0.0.19):
- DKPhotoGallery/Resource (0.0.17):
- SDWebImage
- SwiftyGif
- emoji_picker_flutter (0.0.1):
- Flutter
- fast_rsa (0.7.0):
- fast_rsa (0.6.0):
- Flutter
- file_picker (0.0.1):
- DKImagePickerController/PhotoGallery
- Flutter
- Firebase/CoreOnly (12.4.0):
- FirebaseCore (~> 12.4.0)
- Firebase/InAppMessaging (12.4.0):
- Firebase/CoreOnly (10.12.0):
- FirebaseCore (= 10.12.0)
- Firebase/InAppMessaging (10.12.0):
- Firebase/CoreOnly
- FirebaseInAppMessaging (~> 12.4.0-beta)
- Firebase/Messaging (12.4.0):
- FirebaseInAppMessaging (~> 10.12.0-beta)
- Firebase/Messaging (10.12.0):
- Firebase/CoreOnly
- FirebaseMessaging (~> 12.4.0)
- firebase_core (4.2.1):
- Firebase/CoreOnly (= 12.4.0)
- FirebaseMessaging (~> 10.12.0)
- firebase_core (2.15.1):
- Firebase/CoreOnly (= 10.12.0)
- Flutter
- firebase_in_app_messaging (0.9.0-4):
- Firebase/InAppMessaging (= 12.4.0)
- firebase_in_app_messaging (0.7.3-5):
- Firebase/InAppMessaging (= 10.12.0)
- firebase_core
- Flutter
- firebase_messaging (16.0.4):
- Firebase/Messaging (= 12.4.0)
- firebase_messaging (14.6.6):
- Firebase/Messaging (= 10.12.0)
- firebase_core
- Flutter
- FirebaseABTesting (12.4.0):
- FirebaseCore (~> 12.4.0)
- FirebaseCore (12.4.0):
- FirebaseCoreInternal (~> 12.4.0)
- GoogleUtilities/Environment (~> 8.1)
- GoogleUtilities/Logger (~> 8.1)
- FirebaseCoreInternal (12.4.0):
- "GoogleUtilities/NSData+zlib (~> 8.1)"
- FirebaseInAppMessaging (12.4.0-beta):
- FirebaseABTesting (~> 12.4.0)
- FirebaseCore (~> 12.4.0)
- FirebaseInstallations (~> 12.4.0)
- GoogleUtilities/Environment (~> 8.1)
- GoogleUtilities/UserDefaults (~> 8.1)
- nanopb (~> 3.30910.0)
- FirebaseInstallations (12.4.0):
- FirebaseCore (~> 12.4.0)
- GoogleUtilities/Environment (~> 8.1)
- GoogleUtilities/UserDefaults (~> 8.1)
- PromisesObjC (~> 2.4)
- FirebaseMessaging (12.4.0):
- FirebaseCore (~> 12.4.0)
- FirebaseInstallations (~> 12.4.0)
- GoogleDataTransport (~> 10.1)
- GoogleUtilities/AppDelegateSwizzler (~> 8.1)
- GoogleUtilities/Environment (~> 8.1)
- GoogleUtilities/Reachability (~> 8.1)
- GoogleUtilities/UserDefaults (~> 8.1)
- nanopb (~> 3.30910.0)
- FirebaseABTesting (10.13.0):
- FirebaseCore (~> 10.0)
- FirebaseCore (10.12.0):
- FirebaseCoreInternal (~> 10.0)
- GoogleUtilities/Environment (~> 7.8)
- GoogleUtilities/Logger (~> 7.8)
- FirebaseCoreInternal (10.13.0):
- "GoogleUtilities/NSData+zlib (~> 7.8)"
- FirebaseInAppMessaging (10.12.0-beta):
- FirebaseABTesting (~> 10.0)
- FirebaseCore (~> 10.0)
- FirebaseInstallations (~> 10.0)
- GoogleUtilities/Environment (~> 7.8)
- nanopb (< 2.30910.0, >= 2.30908.0)
- FirebaseInstallations (10.13.0):
- FirebaseCore (~> 10.0)
- GoogleUtilities/Environment (~> 7.8)
- GoogleUtilities/UserDefaults (~> 7.8)
- PromisesObjC (~> 2.1)
- FirebaseMessaging (10.12.0):
- FirebaseCore (~> 10.0)
- FirebaseInstallations (~> 10.0)
- GoogleDataTransport (~> 9.2)
- GoogleUtilities/AppDelegateSwizzler (~> 7.8)
- GoogleUtilities/Environment (~> 7.8)
- GoogleUtilities/Reachability (~> 7.8)
- GoogleUtilities/UserDefaults (~> 7.8)
- nanopb (< 2.30910.0, >= 2.30908.0)
- Flutter (1.0.0)
- flutter_app_badge (2.0.0):
- flutter_app_badger (1.3.0):
- Flutter
- flutter_local_notifications (0.0.1):
- Flutter
- flutter_native_splash (2.4.3):
- flutter_native_splash (0.0.1):
- Flutter
- GoogleDataTransport (10.1.0):
- nanopb (~> 3.30910.0)
- PromisesObjC (~> 2.4)
- GoogleUtilities/AppDelegateSwizzler (8.1.0):
- fluttertoast (0.0.2):
- Flutter
- Toast
- FMDB (2.7.5):
- FMDB/standard (= 2.7.5)
- FMDB/standard (2.7.5)
- GoogleDataTransport (9.2.5):
- GoogleUtilities/Environment (~> 7.7)
- nanopb (< 2.30910.0, >= 2.30908.0)
- PromisesObjC (< 3.0, >= 1.2)
- GoogleUtilities/AppDelegateSwizzler (7.11.5):
- GoogleUtilities/Environment
- GoogleUtilities/Logger
- GoogleUtilities/Network
- GoogleUtilities/Privacy
- GoogleUtilities/Environment (8.1.0):
- GoogleUtilities/Privacy
- GoogleUtilities/Logger (8.1.0):
- GoogleUtilities/Environment (7.11.5):
- PromisesObjC (< 3.0, >= 1.2)
- GoogleUtilities/Logger (7.11.5):
- GoogleUtilities/Environment
- GoogleUtilities/Privacy
- GoogleUtilities/Network (8.1.0):
- GoogleUtilities/Network (7.11.5):
- GoogleUtilities/Logger
- "GoogleUtilities/NSData+zlib"
- GoogleUtilities/Privacy
- GoogleUtilities/Reachability
- "GoogleUtilities/NSData+zlib (8.1.0)":
- GoogleUtilities/Privacy
- GoogleUtilities/Privacy (8.1.0)
- GoogleUtilities/Reachability (8.1.0):
- "GoogleUtilities/NSData+zlib (7.11.5)"
- GoogleUtilities/Reachability (7.11.5):
- GoogleUtilities/Logger
- GoogleUtilities/Privacy
- GoogleUtilities/UserDefaults (8.1.0):
- GoogleUtilities/UserDefaults (7.11.5):
- GoogleUtilities/Logger
- GoogleUtilities/Privacy
- image_picker_ios (0.0.1):
- Flutter
- in_app_review (2.0.0):
- libphonenumber_plugin (0.0.1):
- Flutter
- nanopb (3.30910.0):
- nanopb/decode (= 3.30910.0)
- nanopb/encode (= 3.30910.0)
- nanopb/decode (3.30910.0)
- nanopb/encode (3.30910.0)
- open_filex (0.0.2):
- Flutter
- package_info_plus (0.4.5):
- PhoneNumberKit
- nanopb (2.30909.0):
- nanopb/decode (= 2.30909.0)
- nanopb/encode (= 2.30909.0)
- nanopb/decode (2.30909.0)
- nanopb/encode (2.30909.0)
- package_info (0.0.1):
- Flutter
- path_provider_foundation (0.0.1):
- Flutter
- FlutterMacOS
- PhoneNumberKit (3.7.11):
- PhoneNumberKit/PhoneNumberKitCore (= 3.7.11)
- PhoneNumberKit/UIKit (= 3.7.11)
- PhoneNumberKit/PhoneNumberKitCore (3.7.11)
- PhoneNumberKit/UIKit (3.7.11):
- PhoneNumberKit (3.6.7):
- PhoneNumberKit/PhoneNumberKitCore (= 3.6.7)
- PhoneNumberKit/UIKit (= 3.6.7)
- PhoneNumberKit/PhoneNumberKitCore (3.6.7)
- PhoneNumberKit/UIKit (3.6.7):
- PhoneNumberKit/PhoneNumberKitCore
- PromisesObjC (2.4.0)
- SDWebImage (5.21.2):
- SDWebImage/Core (= 5.21.2)
- SDWebImage/Core (5.21.2)
- PromisesObjC (2.3.1)
- SDWebImage (5.17.0):
- SDWebImage/Core (= 5.17.0)
- SDWebImage/Core (5.17.0)
- share_plus (0.0.1):
- Flutter
- shared_preferences_foundation (0.0.1):
- Flutter
- FlutterMacOS
- sqflite_darwin (0.0.4):
- sqflite (0.0.3):
- Flutter
- FlutterMacOS
- SwiftyGif (5.4.5)
- FMDB (>= 2.7.5)
- SwiftyGif (5.4.4)
- syncfusion_flutter_pdfviewer (0.0.1):
- Flutter
- Toast (4.0.0)
- url_launcher_ios (0.0.1):
- Flutter
DEPENDENCIES:
- connectivity_plus (from `.symlinks/plugins/connectivity_plus/ios`)
- better_open_file (from `.symlinks/plugins/better_open_file/ios`)
- device_info_plus (from `.symlinks/plugins/device_info_plus/ios`)
- emoji_picker_flutter (from `.symlinks/plugins/emoji_picker_flutter/ios`)
- fast_rsa (from `.symlinks/plugins/fast_rsa/ios`)
- file_picker (from `.symlinks/plugins/file_picker/ios`)
- firebase_core (from `.symlinks/plugins/firebase_core/ios`)
- firebase_in_app_messaging (from `.symlinks/plugins/firebase_in_app_messaging/ios`)
- firebase_messaging (from `.symlinks/plugins/firebase_messaging/ios`)
- Flutter (from `Flutter`)
- flutter_app_badge (from `.symlinks/plugins/flutter_app_badge/ios`)
- flutter_app_badger (from `.symlinks/plugins/flutter_app_badger/ios`)
- flutter_local_notifications (from `.symlinks/plugins/flutter_local_notifications/ios`)
- flutter_native_splash (from `.symlinks/plugins/flutter_native_splash/ios`)
- fluttertoast (from `.symlinks/plugins/fluttertoast/ios`)
- image_picker_ios (from `.symlinks/plugins/image_picker_ios/ios`)
- in_app_review (from `.symlinks/plugins/in_app_review/ios`)
- open_filex (from `.symlinks/plugins/open_filex/ios`)
- package_info_plus (from `.symlinks/plugins/package_info_plus/ios`)
- libphonenumber_plugin (from `.symlinks/plugins/libphonenumber_plugin/ios`)
- package_info (from `.symlinks/plugins/package_info/ios`)
- path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/darwin`)
- PhoneNumberKit (~> 3.7.6)
- share_plus (from `.symlinks/plugins/share_plus/ios`)
- shared_preferences_foundation (from `.symlinks/plugins/shared_preferences_foundation/darwin`)
- sqflite_darwin (from `.symlinks/plugins/sqflite_darwin/darwin`)
- sqflite (from `.symlinks/plugins/sqflite/ios`)
- syncfusion_flutter_pdfviewer (from `.symlinks/plugins/syncfusion_flutter_pdfviewer/ios`)
- url_launcher_ios (from `.symlinks/plugins/url_launcher_ios/ios`)
@@ -199,6 +194,7 @@ SPEC REPOS:
- FirebaseInAppMessaging
- FirebaseInstallations
- FirebaseMessaging
- FMDB
- GoogleDataTransport
- GoogleUtilities
- nanopb
@@ -206,14 +202,13 @@ SPEC REPOS:
- PromisesObjC
- SDWebImage
- SwiftyGif
- Toast
EXTERNAL SOURCES:
connectivity_plus:
:path: ".symlinks/plugins/connectivity_plus/ios"
better_open_file:
:path: ".symlinks/plugins/better_open_file/ios"
device_info_plus:
:path: ".symlinks/plugins/device_info_plus/ios"
emoji_picker_flutter:
:path: ".symlinks/plugins/emoji_picker_flutter/ios"
fast_rsa:
:path: ".symlinks/plugins/fast_rsa/ios"
file_picker:
@@ -226,73 +221,74 @@ EXTERNAL SOURCES:
:path: ".symlinks/plugins/firebase_messaging/ios"
Flutter:
:path: Flutter
flutter_app_badge:
:path: ".symlinks/plugins/flutter_app_badge/ios"
flutter_app_badger:
:path: ".symlinks/plugins/flutter_app_badger/ios"
flutter_local_notifications:
:path: ".symlinks/plugins/flutter_local_notifications/ios"
flutter_native_splash:
:path: ".symlinks/plugins/flutter_native_splash/ios"
fluttertoast:
:path: ".symlinks/plugins/fluttertoast/ios"
image_picker_ios:
:path: ".symlinks/plugins/image_picker_ios/ios"
in_app_review:
:path: ".symlinks/plugins/in_app_review/ios"
open_filex:
:path: ".symlinks/plugins/open_filex/ios"
package_info_plus:
:path: ".symlinks/plugins/package_info_plus/ios"
libphonenumber_plugin:
:path: ".symlinks/plugins/libphonenumber_plugin/ios"
package_info:
:path: ".symlinks/plugins/package_info/ios"
path_provider_foundation:
:path: ".symlinks/plugins/path_provider_foundation/darwin"
share_plus:
:path: ".symlinks/plugins/share_plus/ios"
shared_preferences_foundation:
:path: ".symlinks/plugins/shared_preferences_foundation/darwin"
sqflite_darwin:
:path: ".symlinks/plugins/sqflite_darwin/darwin"
sqflite:
:path: ".symlinks/plugins/sqflite/ios"
syncfusion_flutter_pdfviewer:
:path: ".symlinks/plugins/syncfusion_flutter_pdfviewer/ios"
url_launcher_ios:
:path: ".symlinks/plugins/url_launcher_ios/ios"
SPEC CHECKSUMS:
connectivity_plus: cb623214f4e1f6ef8fe7403d580fdad517d2f7dd
device_info_plus: 21fcca2080fbcd348be798aa36c3e5ed849eefbe
DKImagePickerController: 946cec48c7873164274ecc4624d19e3da4c1ef3c
DKPhotoGallery: b3834fecb755ee09a593d7c9e389d8b5d6deed60
emoji_picker_flutter: ece213fc274bdddefb77d502d33080dc54e616cc
fast_rsa: fb70897d51040b094c780d5f1d7358614738b879
file_picker: a0560bc09d61de87f12d246fc47d2119e6ef37be
Firebase: f07b15ae5a6ec0f93713e30b923d9970d144af3e
firebase_core: f1aafb21c14f497e5498f7ffc4dc63cbb52b2594
firebase_in_app_messaging: 04dfc07ab81578ef83bf0c0229be258ddf287c4f
firebase_messaging: c17a29984eafce4b2997fe078bb0a9e0b06f5dde
FirebaseABTesting: c05b5ec9f1d9f21a65909525de301d375032d9a4
FirebaseCore: bb595f3114953664e3c1dc032f008a244147cfd3
FirebaseCoreInternal: d7f5a043c2cd01a08103ab586587c1468047bca6
FirebaseInAppMessaging: 606dd4d4d5590a3d8229f363fdebb485235985b2
FirebaseInstallations: ae9f4902cb5bf1d0c5eaa31ec1f4e5495a0714e2
FirebaseMessaging: d33971b7bb252745ea6cd31ab190d1a1df4b8ed5
Flutter: cabc95a1d2626b1b06e7179b784ebcf0c0cde467
flutter_app_badge: ca742dd659a157c1090ef7cd881cb78f48f3bcdf
flutter_local_notifications: a5a732f069baa862e728d839dd2ebb904737effb
flutter_native_splash: c32d145d68aeda5502d5f543ee38c192065986cf
GoogleDataTransport: aae35b7ea0c09004c3797d53c8c41f66f219d6a7
GoogleUtilities: 00c88b9a86066ef77f0da2fab05f65d7768ed8e1
image_picker_ios: e0ece4aa2a75771a7de3fa735d26d90817041326
in_app_review: 7dd1ea365263f834b8464673f9df72c80c17c937
nanopb: fad817b59e0457d11a5dfbde799381cd727c1275
open_filex: 432f3cd11432da3e39f47fcc0df2b1603854eff1
package_info_plus: af8e2ca6888548050f16fa2f1938db7b5a5df499
path_provider_foundation: bb55f6dbba17d0dccd6737fe6f7f34fbd0376880
PhoneNumberKit: ced55861269312a5e3bc2ef82a58d6255b1c976a
PromisesObjC: f5707f49cb48b9636751c5b2e7d227e43fba9f47
SDWebImage: 9f177d83116802728e122410fb25ad88f5c7608a
share_plus: 50da8cb520a8f0f65671c6c6a99b3617ed10a58a
shared_preferences_foundation: 7036424c3d8ec98dfe75ff1667cb0cd531ec82bb
sqflite_darwin: 20b2a3a3b70e43edae938624ce550a3cbf66a3d0
SwiftyGif: 706c60cf65fa2bc5ee0313beece843c8eb8194d4
syncfusion_flutter_pdfviewer: 90dc48305d2e33d4aa20681d1e98ddeda891bc14
url_launcher_ios: 7a95fa5b60cc718a708b8f2966718e93db0cef1b
better_open_file: 03cf320415d4d3f46b6e00adc4a567d76c1a399d
device_info_plus: 7545d84d8d1b896cb16a4ff98c19f07ec4b298ea
DKImagePickerController: b512c28220a2b8ac7419f21c491fc8534b7601ac
DKPhotoGallery: fdfad5125a9fdda9cc57df834d49df790dbb4179
fast_rsa: f696740d492d562e76f17b0a81dfc8ec3e635374
file_picker: ce3938a0df3cc1ef404671531facef740d03f920
Firebase: 07150e75d142fb9399f6777fa56a187b17f833a0
firebase_core: 4a3246a02f828a01c74a2c26427037786d90f17f
firebase_in_app_messaging: aebdbc10109a0ce44a3294f4ea57ed89ebe1d8bd
firebase_messaging: 13b378c8449cae7ec96c79570170943dd73d4738
FirebaseABTesting: 86ac5a4fc749088bb4d55a1cbfb2c4cb42c6d5de
FirebaseCore: f86a1394906b97ac445ae49c92552a9425831bed
FirebaseCoreInternal: b342e37cd4f5b4454ec34308f073420e7920858e
FirebaseInAppMessaging: dc24f50aebaf81a377f0b8abf360778f94208931
FirebaseInstallations: b28af1b9f997f1a799efe818c94695a3728c352f
FirebaseMessaging: bb2c4f6422a753038fe137d90ae7c1af57251316
Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854
flutter_app_badger: b87fc231847b03b92ce1412aa351842e7e97932f
flutter_local_notifications: 0c0b1ae97e741e1521e4c1629a459d04b9aec743
flutter_native_splash: 52501b97d1c0a5f898d687f1646226c1f93c56ef
fluttertoast: fafc4fa4d01a6a9e4f772ecd190ffa525e9e2d9c
FMDB: 2ce00b547f966261cd18927a3ddb07cb6f3db82a
GoogleDataTransport: 54dee9d48d14580407f8f5fbf2f496e92437a2f2
GoogleUtilities: 13e2c67ede716b8741c7989e26893d151b2b2084
image_picker_ios: 4a8aadfbb6dc30ad5141a2ce3832af9214a705b5
libphonenumber_plugin: e8a7d64a6624a7c25f2c4ab0b7ead2a8e341e35e
nanopb: b552cce312b6c8484180ef47159bc0f65a1f0431
package_info: 873975fc26034f0b863a300ad47e7f1ac6c7ec62
path_provider_foundation: 29f094ae23ebbca9d3d0cec13889cd9060c0e943
PhoneNumberKit: 43b5169526cc417398c8f13f77c97552c1c6ed76
PromisesObjC: c50d2056b5253dadbd6c2bea79b0674bd5a52fa4
SDWebImage: 750adf017a315a280c60fde706ab1e552a3ae4e9
share_plus: 599aa54e4ea31d4b4c0e9c911bcc26c55e791028
shared_preferences_foundation: 5b919d13b803cadd15ed2dc053125c68730e5126
sqflite: 31f7eba61e3074736dff8807a9b41581e4f7f15a
SwiftyGif: 93a1cc87bf3a51916001cf8f3d63835fb64c819f
syncfusion_flutter_pdfviewer: bb9998884b864cfedf72628df3503bdf57e397c0
Toast: 91b396c56ee72a5790816f40d3a94dd357abc196
url_launcher_ios: 08a3dfac5fb39e8759aeb0abbd5d9480f30fc8b4
PODFILE CHECKSUM: e21c9d4c7b9623c73c6784ddc132fd50a603ad93
PODFILE CHECKSUM: 3d89a90682e2cd438911ad748b8ba5992f8b6a0e
COCOAPODS: 1.16.2
COCOAPODS: 1.12.1

View File

@@ -8,8 +8,8 @@
/* Begin PBXBuildFile section */
1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; };
33FDB0982EE9ABDC000B2391 /* GoogleService-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 33FDB0972EE9ABDC000B2391 /* GoogleService-Info.plist */; };
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; };
6483E4432A911EA00063B51E /* GoogleService-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 6483E4422A911EA00063B51E /* GoogleService-Info.plist */; };
74858FAF1ED2DC5600515810 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 74858FAE1ED2DC5600515810 /* AppDelegate.swift */; };
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; };
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
@@ -33,10 +33,10 @@
/* Begin PBXFileReference section */
1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = "<group>"; };
1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = "<group>"; };
33FDB0972EE9ABDC000B2391 /* GoogleService-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = "GoogleService-Info.plist"; sourceTree = "<group>"; };
3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = "<group>"; };
4509EC31CB08BA9BF367AF6C /* Pods-Runner.profile.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.profile.xcconfig"; path = "Target Support Files/Pods-Runner/Pods-Runner.profile.xcconfig"; sourceTree = "<group>"; };
64801C012A9112D500E8B558 /* Runner.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = Runner.entitlements; sourceTree = "<group>"; };
6483E4422A911EA00063B51E /* GoogleService-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = "GoogleService-Info.plist"; path = "../../../../Downloads/GoogleService-Info.plist"; sourceTree = "<group>"; };
74858FAD1ED2DC5600515810 /* Runner-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Runner-Bridging-Header.h"; sourceTree = "<group>"; };
74858FAE1ED2DC5600515810 /* AppDelegate.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = "<group>"; };
@@ -115,12 +115,12 @@
97C146F01CF9000F007C117D /* Runner */ = {
isa = PBXGroup;
children = (
33FDB0972EE9ABDC000B2391 /* GoogleService-Info.plist */,
64801C012A9112D500E8B558 /* Runner.entitlements */,
97C146FA1CF9000F007C117D /* Main.storyboard */,
97C146FD1CF9000F007C117D /* Assets.xcassets */,
97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */,
97C147021CF9000F007C117D /* Info.plist */,
6483E4422A911EA00063B51E /* GoogleService-Info.plist */,
1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */,
1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */,
74858FAE1ED2DC5600515810 /* AppDelegate.swift */,
@@ -144,7 +144,6 @@
9705A1C41CF9048500538489 /* Embed Frameworks */,
3B06AD1E1E4923F5004D2608 /* Thin Binary */,
174B54D80220E5F588BD9737 /* [CP] Embed Pods Frameworks */,
859FAB4E05FAC31B7B1A62D7 /* [CP] Copy Pods Resources */,
);
buildRules = (
);
@@ -162,7 +161,7 @@
isa = PBXProject;
attributes = {
BuildIndependentTargetsInParallel = YES;
LastUpgradeCheck = 1510;
LastUpgradeCheck = 1430;
ORGANIZATIONNAME = "";
TargetAttributes = {
97C146ED1CF9000F007C117D = {
@@ -196,7 +195,7 @@
files = (
97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */,
3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */,
33FDB0982EE9ABDC000B2391 /* GoogleService-Info.plist in Resources */,
6483E4432A911EA00063B51E /* GoogleService-Info.plist in Resources */,
97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */,
97C146FC1CF9000F007C117D /* Main.storyboard in Resources */,
);
@@ -213,14 +212,10 @@
inputFileListPaths = (
"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-input-files.xcfilelist",
);
inputPaths = (
);
name = "[CP] Embed Pods Frameworks";
outputFileListPaths = (
"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks-${CONFIGURATION}-output-files.xcfilelist",
);
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-frameworks.sh\"\n";
@@ -242,27 +237,6 @@
shellPath = /bin/sh;
shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin";
};
859FAB4E05FAC31B7B1A62D7 /* [CP] Copy Pods Resources */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputFileListPaths = (
"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-resources-${CONFIGURATION}-input-files.xcfilelist",
);
inputPaths = (
);
name = "[CP] Copy Pods Resources";
outputFileListPaths = (
"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-resources-${CONFIGURATION}-output-files.xcfilelist",
);
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-Runner/Pods-Runner-resources.sh\"\n";
showEnvVarsInLog = 0;
};
9740EEB61CF901F6004384FC /* Run Script */ = {
isa = PBXShellScriptBuildPhase;
alwaysOutOfDate = 1;
@@ -375,7 +349,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SUPPORTED_PLATFORMS = iphoneos;
@@ -460,7 +434,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
@@ -509,7 +483,7 @@
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 13.0;
IPHONEOS_DEPLOYMENT_TARGET = 11.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
SUPPORTED_PLATFORMS = iphoneos;

View File

@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1510"
LastUpgradeVersion = "1430"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
@@ -26,7 +26,6 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
customLLDBInitFile = "$(SRCROOT)/Flutter/ephemeral/flutter_lldbinit"
shouldUseLaunchSchemeArgsEnv = "YES">
<MacroExpansion>
<BuildableReference
@@ -44,13 +43,11 @@
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
customLLDBInitFile = "$(SRCROOT)/Flutter/ephemeral/flutter_lldbinit"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
enableGPUValidationMode = "1"
allowLocationSimulation = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">

View File

@@ -1,7 +1,7 @@
import UIKit
import Flutter
@main
@UIApplicationMain
@objc class AppDelegate: FlutterAppDelegate {
override func application(
_ application: UIApplication,

View File

@@ -4,5 +4,7 @@ class ApiError {
ApiError(this.message);
@override
String toString() => 'ApiError: $message';
String toString() {
return 'ApiError: $message';
}
}

View File

@@ -5,5 +5,5 @@ abstract class ApiResponse {
late http.Response rawResponse;
@JsonKey(includeIfNull: false)
Map<String, String>? headers;
late Map<String, String>? headers;
}

View File

@@ -1,15 +1,17 @@
import 'dart:convert';
import 'package:http/http.dart' as http;
import 'getHolidaysResponse.dart';
class GetHolidays {
Future<GetHolidaysResponse> query() async {
var response = (await http.get(Uri.parse('https://ferien-api.de/api/v1/holidays/HE'))).body;
var data = jsonDecode(response) as List<dynamic>;
String response = (await http.get(Uri.parse('https://ferien-api.de/api/v1/holidays/HE'))).body;
return GetHolidaysResponse(
List<GetHolidaysResponseObject>.from(
data.map<GetHolidaysResponseObject>((e) => GetHolidaysResponseObject.fromJson(e as Map<String, dynamic>))
jsonDecode(response).map<GetHolidaysResponseObject>(
GetHolidaysResponseObject.fromJson
)
)
);
}

View File

@@ -6,21 +6,24 @@ import 'getHolidaysResponse.dart';
class GetHolidaysCache extends RequestCache<GetHolidaysResponse> {
GetHolidaysCache({onUpdate, renew}) : super(RequestCache.cacheDay, onUpdate, renew: renew) {
start('state-holidays');
start('MarianumMobile', 'state-holidays');
}
@override
GetHolidaysResponse onLocalData(String json) {
List<dynamic> parsedListJson = jsonDecode(json)['data'];
return GetHolidaysResponse(
List<GetHolidaysResponseObject>.from(
parsedListJson.map<GetHolidaysResponseObject>(
(i) => GetHolidaysResponseObject.fromJson(i as Map<String, dynamic>)
List<GetHolidaysResponseObject>.from(
parsedListJson.map<GetHolidaysResponseObject>(
// ignore: unnecessary_lambdas
(dynamic i) => GetHolidaysResponseObject.fromJson(i)
)
)
)
);
}
@override
Future<GetHolidaysResponse> onLoad() => GetHolidays().query();
Future<GetHolidaysResponse> onLoad() {
return GetHolidays().query();
}
}

View File

@@ -8,42 +8,46 @@ part of 'getHolidaysResponse.dart';
GetHolidaysResponse _$GetHolidaysResponseFromJson(Map<String, dynamic> json) =>
GetHolidaysResponse(
(json['data'] as List<dynamic>)
.map(
(e) =>
GetHolidaysResponseObject.fromJson(e as Map<String, dynamic>),
)
.toList(),
)
..headers = (json['headers'] as Map<String, dynamic>?)?.map(
(json['data'] as List<dynamic>)
.map((e) =>
GetHolidaysResponseObject.fromJson(e as Map<String, dynamic>))
.toList(),
)..headers = (json['headers'] as Map<String, dynamic>?)?.map(
(k, e) => MapEntry(k, e as String),
);
Map<String, dynamic> _$GetHolidaysResponseToJson(
GetHolidaysResponse instance,
) => <String, dynamic>{
'headers': ?instance.headers,
'data': instance.data.map((e) => e.toJson()).toList(),
};
Map<String, dynamic> _$GetHolidaysResponseToJson(GetHolidaysResponse instance) {
final val = <String, dynamic>{};
void writeNotNull(String key, dynamic value) {
if (value != null) {
val[key] = value;
}
}
writeNotNull('headers', instance.headers);
val['data'] = instance.data.map((e) => e.toJson()).toList();
return val;
}
GetHolidaysResponseObject _$GetHolidaysResponseObjectFromJson(
Map<String, dynamic> json,
) => GetHolidaysResponseObject(
start: json['start'] as String,
end: json['end'] as String,
year: (json['year'] as num).toInt(),
stateCode: json['stateCode'] as String,
name: json['name'] as String,
slug: json['slug'] as String,
);
Map<String, dynamic> json) =>
GetHolidaysResponseObject(
start: json['start'] as String,
end: json['end'] as String,
year: json['year'] as int,
stateCode: json['stateCode'] as String,
name: json['name'] as String,
slug: json['slug'] as String,
);
Map<String, dynamic> _$GetHolidaysResponseObjectToJson(
GetHolidaysResponseObject instance,
) => <String, dynamic>{
'start': instance.start,
'end': instance.end,
'year': instance.year,
'stateCode': instance.stateCode,
'name': instance.name,
'slug': instance.slug,
};
GetHolidaysResponseObject instance) =>
<String, dynamic>{
'start': instance.start,
'end': instance.end,
'year': instance.year,
'stateCode': instance.stateCode,
'name': instance.name,
'slug': instance.slug,
};

View File

@@ -2,6 +2,7 @@ import 'dart:convert';
import 'dart:io';
import 'package:http/http.dart' as http;
import 'package:http/http.dart';
import '../../../model/accountData.dart';
import '../../../model/endpointData.dart';
@@ -9,7 +10,7 @@ import 'autocompleteResponse.dart';
class AutocompleteApi {
Future<AutocompleteResponse> find(String query) async {
var getParameters = <String, dynamic>{
Map<String, dynamic> getParameters = {
'search': query,
'itemType': ' ',
'itemId': ' ',
@@ -17,15 +18,15 @@ class AutocompleteApi {
'limit': '10',
};
var headers = <String, String>{};
Map<String, String> headers = {};
headers.putIfAbsent('Accept', () => 'application/json');
headers.putIfAbsent('OCS-APIRequest', () => 'true');
var endpoint = Uri.https('${AccountData().buildHttpAuthString()}@${EndpointData().nextcloud().domain}', '${EndpointData().nextcloud().path}/ocs/v2.php/core/autocomplete/get', getParameters);
Uri endpoint = Uri.https('${AccountData().buildHttpAuthString()}@${EndpointData().nextcloud().domain}', '${EndpointData().nextcloud().path}/ocs/v2.php/core/autocomplete/get', getParameters);
var response = await http.get(endpoint, headers: headers);
Response response = await http.get(endpoint, headers: headers);
if(response.statusCode != HttpStatus.ok) throw Exception('Api call failed with ${response.statusCode}: ${response.body}');
var result = response.body;
String result = response.body;
return AutocompleteResponse.fromJson(jsonDecode(result)['ocs']);
}

View File

@@ -18,7 +18,7 @@ class AutocompleteResponseObject {
String label;
String? icon;
String? source;
String? status;
List<String>? status;
String? subline;
String? shareWithDisplayNameUniqe;

View File

@@ -7,39 +7,40 @@ part of 'autocompleteResponse.dart';
// **************************************************************************
AutocompleteResponse _$AutocompleteResponseFromJson(
Map<String, dynamic> json,
) => AutocompleteResponse(
(json['data'] as List<dynamic>)
.map(
(e) => AutocompleteResponseObject.fromJson(e as Map<String, dynamic>),
)
.toList(),
);
Map<String, dynamic> json) =>
AutocompleteResponse(
(json['data'] as List<dynamic>)
.map((e) =>
AutocompleteResponseObject.fromJson(e as Map<String, dynamic>))
.toList(),
);
Map<String, dynamic> _$AutocompleteResponseToJson(
AutocompleteResponse instance,
) => <String, dynamic>{'data': instance.data.map((e) => e.toJson()).toList()};
AutocompleteResponse instance) =>
<String, dynamic>{
'data': instance.data.map((e) => e.toJson()).toList(),
};
AutocompleteResponseObject _$AutocompleteResponseObjectFromJson(
Map<String, dynamic> json,
) => AutocompleteResponseObject(
json['id'] as String,
json['label'] as String,
json['icon'] as String?,
json['source'] as String?,
json['status'] as String?,
json['subline'] as String?,
json['shareWithDisplayNameUniqe'] as String?,
);
Map<String, dynamic> json) =>
AutocompleteResponseObject(
json['id'] as String,
json['label'] as String,
json['icon'] as String?,
json['source'] as String?,
(json['status'] as List<dynamic>?)?.map((e) => e as String).toList(),
json['subline'] as String?,
json['shareWithDisplayNameUniqe'] as String?,
);
Map<String, dynamic> _$AutocompleteResponseObjectToJson(
AutocompleteResponseObject instance,
) => <String, dynamic>{
'id': instance.id,
'label': instance.label,
'icon': instance.icon,
'source': instance.source,
'status': instance.status,
'subline': instance.subline,
'shareWithDisplayNameUniqe': instance.shareWithDisplayNameUniqe,
};
AutocompleteResponseObject instance) =>
<String, dynamic>{
'id': instance.id,
'label': instance.label,
'icon': instance.icon,
'source': instance.source,
'status': instance.status,
'subline': instance.subline,
'shareWithDisplayNameUniqe': instance.shareWithDisplayNameUniqe,
};

View File

@@ -1,6 +1,7 @@
import 'dart:io';
import 'package:http/http.dart' as http;
import 'package:http/http.dart';
import '../../../model/accountData.dart';
import '../../../model/endpointData.dart';
@@ -8,12 +9,12 @@ import 'fileSharingApiParams.dart';
class FileSharingApi {
Future<void> share(FileSharingApiParams query) async {
var headers = <String, String>{};
Map<String, String> headers = {};
headers.putIfAbsent('Accept', () => 'application/json');
headers.putIfAbsent('OCS-APIRequest', () => 'true');
var endpoint = Uri.https('${AccountData().buildHttpAuthString()}@${EndpointData().nextcloud().domain}', '${EndpointData().nextcloud().path}/ocs/v2.php/apps/files_sharing/api/v1/shares', query.toJson().map((key, value) => MapEntry(key, value.toString())));
var response = await http.post(endpoint, headers: headers);
Uri endpoint = Uri.https('${AccountData().buildHttpAuthString()}@${EndpointData().nextcloud().domain}', '${EndpointData().nextcloud().path}/ocs/v2.php/apps/files_sharing/api/v1/shares', query.toJson().map((key, value) => MapEntry(key, value.toString())));
Response response = await http.post(endpoint, headers: headers);
if(response.statusCode != HttpStatus.ok) {
throw Exception('Api call failed with ${response.statusCode}: ${response.body}');

View File

@@ -7,21 +7,21 @@ part of 'fileSharingApiParams.dart';
// **************************************************************************
FileSharingApiParams _$FileSharingApiParamsFromJson(
Map<String, dynamic> json,
) => FileSharingApiParams(
shareType: (json['shareType'] as num).toInt(),
shareWith: json['shareWith'] as String,
path: json['path'] as String,
referenceId: json['referenceId'] as String?,
talkMetaData: json['talkMetaData'] as String?,
);
Map<String, dynamic> json) =>
FileSharingApiParams(
shareType: json['shareType'] as int,
shareWith: json['shareWith'] as String,
path: json['path'] as String,
referenceId: json['referenceId'] as String?,
talkMetaData: json['talkMetaData'] as String?,
);
Map<String, dynamic> _$FileSharingApiParamsToJson(
FileSharingApiParams instance,
) => <String, dynamic>{
'shareType': instance.shareType,
'shareWith': instance.shareWith,
'path': instance.path,
'referenceId': instance.referenceId,
'talkMetaData': instance.talkMetaData,
};
FileSharingApiParams instance) =>
<String, dynamic>{
'shareType': instance.shareType,
'shareWith': instance.shareWith,
'path': instance.path,
'referenceId': instance.referenceId,
'talkMetaData': instance.talkMetaData,
};

View File

@@ -14,9 +14,13 @@ class GetChat extends TalkApi<GetChatResponse> {
GetChat(this.chatToken, this.params) : super('v1/chat/$chatToken', null, getParameters: params.toJson());
@override
assemble(String raw) => GetChatResponse.fromJson(jsonDecode(raw)['ocs']);
assemble(String raw) {
return GetChatResponse.fromJson(jsonDecode(raw)['ocs']);
}
@override
Future<Response> request(Uri uri, Object? body, Map<String, String>? headers) => http.get(uri, headers: headers);
Future<Response> request(Uri uri, Object? body, Map<String, String>? headers) {
return http.get(uri, headers: headers);
}
}

View File

@@ -9,11 +9,12 @@ class GetChatCache extends RequestCache<GetChatResponse> {
String chatToken;
GetChatCache({required onUpdate, required this.chatToken}) : super(RequestCache.cacheNothing, onUpdate) {
start('nc-chat-$chatToken');
start('MarianumMobile', 'nc-chat-$chatToken');
}
@override
Future<GetChatResponse> onLoad() => GetChat(
Future<GetChatResponse> onLoad() {
return GetChat(
chatToken,
GetChatParams(
lookIntoFuture: GetChatParamsSwitch.off,
@@ -21,8 +22,11 @@ class GetChatCache extends RequestCache<GetChatResponse> {
limit: 200,
)
).run();
}
@override
GetChatResponse onLocalData(String json) => GetChatResponse.fromJson(jsonDecode(json));
GetChatResponse onLocalData(String json) {
return GetChatResponse.fromJson(jsonDecode(json));
}
}

View File

@@ -8,35 +8,39 @@ part of 'getChatParams.dart';
GetChatParams _$GetChatParamsFromJson(Map<String, dynamic> json) =>
GetChatParams(
lookIntoFuture: $enumDecode(
_$GetChatParamsSwitchEnumMap,
json['lookIntoFuture'],
),
limit: (json['limit'] as num?)?.toInt(),
lastKnownMessageId: (json['lastKnownMessageId'] as num?)?.toInt(),
lastCommonReadId: (json['lastCommonReadId'] as num?)?.toInt(),
timeout: (json['timeout'] as num?)?.toInt(),
lookIntoFuture:
$enumDecode(_$GetChatParamsSwitchEnumMap, json['lookIntoFuture']),
limit: json['limit'] as int?,
lastKnownMessageId: json['lastKnownMessageId'] as int?,
lastCommonReadId: json['lastCommonReadId'] as int?,
timeout: json['timeout'] as int?,
setReadMarker: $enumDecodeNullable(
_$GetChatParamsSwitchEnumMap,
json['setReadMarker'],
),
_$GetChatParamsSwitchEnumMap, json['setReadMarker']),
includeLastKnown: $enumDecodeNullable(
_$GetChatParamsSwitchEnumMap,
json['includeLastKnown'],
),
_$GetChatParamsSwitchEnumMap, json['includeLastKnown']),
);
Map<String, dynamic> _$GetChatParamsToJson(
GetChatParams instance,
) => <String, dynamic>{
'lookIntoFuture': _$GetChatParamsSwitchEnumMap[instance.lookIntoFuture]!,
'limit': ?instance.limit,
'lastKnownMessageId': ?instance.lastKnownMessageId,
'lastCommonReadId': ?instance.lastCommonReadId,
'timeout': ?instance.timeout,
'setReadMarker': ?_$GetChatParamsSwitchEnumMap[instance.setReadMarker],
'includeLastKnown': ?_$GetChatParamsSwitchEnumMap[instance.includeLastKnown],
};
Map<String, dynamic> _$GetChatParamsToJson(GetChatParams instance) {
final val = <String, dynamic>{
'lookIntoFuture': _$GetChatParamsSwitchEnumMap[instance.lookIntoFuture]!,
};
void writeNotNull(String key, dynamic value) {
if (value != null) {
val[key] = value;
}
}
writeNotNull('limit', instance.limit);
writeNotNull('lastKnownMessageId', instance.lastKnownMessageId);
writeNotNull('lastCommonReadId', instance.lastCommonReadId);
writeNotNull('timeout', instance.timeout);
writeNotNull(
'setReadMarker', _$GetChatParamsSwitchEnumMap[instance.setReadMarker]);
writeNotNull('includeLastKnown',
_$GetChatParamsSwitchEnumMap[instance.includeLastKnown]);
return val;
}
const _$GetChatParamsSwitchEnumMap = {
GetChatParamsSwitch.on: 1,

View File

@@ -16,7 +16,7 @@ class GetChatResponse extends ApiResponse {
Map<String, dynamic> toJson() => _$GetChatResponseToJson(this);
List<GetChatResponseObject> sortByTimestamp() {
var sorted = data.toList();
List<GetChatResponseObject> sorted = data.toList();
sorted.sort((a, b) => a.timestamp.compareTo(b.timestamp));
return sorted;
}
@@ -38,7 +38,6 @@ class GetChatResponseObject {
Map<String, int>? reactions;
List<String>? reactionsSelf;
@JsonKey(fromJson: _fromJson) Map<String, RichObjectString>? messageParameters;
GetChatResponseObject? parent;
GetChatResponseObject(
this.id,
@@ -54,19 +53,19 @@ class GetChatResponseObject {
this.message,
this.messageParameters,
this.reactions,
this.reactionsSelf,
this.parent,
this.reactionsSelf
);
factory GetChatResponseObject.fromJson(Map<String, dynamic> json) => _$GetChatResponseObjectFromJson(json);
Map<String, dynamic> toJson() => _$GetChatResponseObjectToJson(this);
static GetChatResponseObject getDateDummy(int timestamp) {
var elementDate = DateTime.fromMillisecondsSinceEpoch(timestamp * 1000);
DateTime elementDate = DateTime.fromMillisecondsSinceEpoch(timestamp * 1000);
return getTextDummy(Jiffy.parseFromDateTime(elementDate).format(pattern: 'dd.MM.yyyy'));
}
static GetChatResponseObject getTextDummy(String text) => GetChatResponseObject(
static GetChatResponseObject getTextDummy(String text) {
return GetChatResponseObject(
0,
'',
GetRoomResponseObjectMessageActorType.user,
@@ -80,15 +79,15 @@ class GetChatResponseObject {
text,
null,
null,
null,
null,
null
);
}
}
Map<String, RichObjectString>? _fromJson(json) {
if(json is Map<String, dynamic>) {
var data = <String, RichObjectString>{};
Map<String, RichObjectString> data = {};
for (var element in json.keys) {
data.putIfAbsent(element, () => RichObjectString.fromJson(json[element]));
}
@@ -120,5 +119,4 @@ enum RichObjectStringObjectType {
@JsonValue('guest') guest,
@JsonValue('highlight') highlight,
@JsonValue('talk-poll') talkPoll,
@JsonValue('geo-location') geoLocation,
}

View File

@@ -8,72 +8,73 @@ part of 'getChatResponse.dart';
GetChatResponse _$GetChatResponseFromJson(Map<String, dynamic> json) =>
GetChatResponse(
(json['data'] as List<dynamic>)
.map(
(e) => GetChatResponseObject.fromJson(e as Map<String, dynamic>),
)
.toSet(),
)
..headers = (json['headers'] as Map<String, dynamic>?)?.map(
(json['data'] as List<dynamic>)
.map((e) => GetChatResponseObject.fromJson(e as Map<String, dynamic>))
.toSet(),
)..headers = (json['headers'] as Map<String, dynamic>?)?.map(
(k, e) => MapEntry(k, e as String),
);
Map<String, dynamic> _$GetChatResponseToJson(GetChatResponse instance) =>
<String, dynamic>{
'headers': ?instance.headers,
'data': instance.data.map((e) => e.toJson()).toList(),
};
Map<String, dynamic> _$GetChatResponseToJson(GetChatResponse instance) {
final val = <String, dynamic>{};
void writeNotNull(String key, dynamic value) {
if (value != null) {
val[key] = value;
}
}
writeNotNull('headers', instance.headers);
val['data'] = instance.data.map((e) => e.toJson()).toList();
return val;
}
GetChatResponseObject _$GetChatResponseObjectFromJson(
Map<String, dynamic> json,
) => GetChatResponseObject(
(json['id'] as num).toInt(),
json['token'] as String,
$enumDecode(
_$GetRoomResponseObjectMessageActorTypeEnumMap,
json['actorType'],
),
json['actorId'] as String,
json['actorDisplayName'] as String,
(json['timestamp'] as num).toInt(),
json['systemMessage'] as String,
$enumDecode(_$GetRoomResponseObjectMessageTypeEnumMap, json['messageType']),
json['isReplyable'] as bool,
json['referenceId'] as String,
json['message'] as String,
_fromJson(json['messageParameters']),
(json['reactions'] as Map<String, dynamic>?)?.map(
(k, e) => MapEntry(k, (e as num).toInt()),
),
(json['reactionsSelf'] as List<dynamic>?)?.map((e) => e as String).toList(),
json['parent'] == null
? null
: GetChatResponseObject.fromJson(json['parent'] as Map<String, dynamic>),
);
Map<String, dynamic> json) =>
GetChatResponseObject(
json['id'] as int,
json['token'] as String,
$enumDecode(
_$GetRoomResponseObjectMessageActorTypeEnumMap, json['actorType']),
json['actorId'] as String,
json['actorDisplayName'] as String,
json['timestamp'] as int,
json['systemMessage'] as String,
$enumDecode(
_$GetRoomResponseObjectMessageTypeEnumMap, json['messageType']),
json['isReplyable'] as bool,
json['referenceId'] as String,
json['message'] as String,
_fromJson(json['messageParameters']),
(json['reactions'] as Map<String, dynamic>?)?.map(
(k, e) => MapEntry(k, e as int),
),
(json['reactionsSelf'] as List<dynamic>?)
?.map((e) => e as String)
.toList(),
);
Map<String, dynamic> _$GetChatResponseObjectToJson(
GetChatResponseObject instance,
) => <String, dynamic>{
'id': instance.id,
'token': instance.token,
'actorType':
_$GetRoomResponseObjectMessageActorTypeEnumMap[instance.actorType]!,
'actorId': instance.actorId,
'actorDisplayName': instance.actorDisplayName,
'timestamp': instance.timestamp,
'systemMessage': instance.systemMessage,
'messageType':
_$GetRoomResponseObjectMessageTypeEnumMap[instance.messageType]!,
'isReplyable': instance.isReplyable,
'referenceId': instance.referenceId,
'message': instance.message,
'reactions': instance.reactions,
'reactionsSelf': instance.reactionsSelf,
'messageParameters': instance.messageParameters?.map(
(k, e) => MapEntry(k, e.toJson()),
),
'parent': instance.parent?.toJson(),
};
GetChatResponseObject instance) =>
<String, dynamic>{
'id': instance.id,
'token': instance.token,
'actorType':
_$GetRoomResponseObjectMessageActorTypeEnumMap[instance.actorType]!,
'actorId': instance.actorId,
'actorDisplayName': instance.actorDisplayName,
'timestamp': instance.timestamp,
'systemMessage': instance.systemMessage,
'messageType':
_$GetRoomResponseObjectMessageTypeEnumMap[instance.messageType]!,
'isReplyable': instance.isReplyable,
'referenceId': instance.referenceId,
'message': instance.message,
'reactions': instance.reactions,
'reactionsSelf': instance.reactionsSelf,
'messageParameters':
instance.messageParameters?.map((k, e) => MapEntry(k, e.toJson())),
};
const _$GetRoomResponseObjectMessageActorTypeEnumMap = {
GetRoomResponseObjectMessageActorType.deletedUsers: 'deleted_users',
@@ -85,7 +86,6 @@ const _$GetRoomResponseObjectMessageActorTypeEnumMap = {
const _$GetRoomResponseObjectMessageTypeEnumMap = {
GetRoomResponseObjectMessageType.comment: 'comment',
GetRoomResponseObjectMessageType.voiceMessage: 'voice-message',
GetRoomResponseObjectMessageType.deletedComment: 'comment_deleted',
GetRoomResponseObjectMessageType.system: 'system',
GetRoomResponseObjectMessageType.command: 'command',
@@ -116,5 +116,4 @@ const _$RichObjectStringObjectTypeEnumMap = {
RichObjectStringObjectType.guest: 'guest',
RichObjectStringObjectType.highlight: 'highlight',
RichObjectStringObjectType.talkPoll: 'talk-poll',
RichObjectStringObjectType.geoLocation: 'geo-location',
};

View File

@@ -10,7 +10,9 @@ class CreateRoom extends TalkApi {
CreateRoom(this.params) : super('v4/room', params);
@override
assemble(String raw) => null;
assemble(String raw) {
return null;
}
@override
Future<Response>? request(Uri uri, Object? body, Map<String, String>? headers) {

View File

@@ -8,7 +8,7 @@ part of 'createRoomParams.dart';
CreateRoomParams _$CreateRoomParamsFromJson(Map<String, dynamic> json) =>
CreateRoomParams(
roomType: (json['roomType'] as num).toInt(),
roomType: json['roomType'] as int,
invite: json['invite'] as String,
source: json['source'] as String?,
roomName: json['roomName'] as String?,

View File

@@ -10,9 +10,13 @@ class DeleteMessage extends TalkApi {
DeleteMessage(this.chatToken, this.messageId) : super('v1/chat/$chatToken/$messageId', null);
@override
assemble(String raw) => null;
assemble(String raw) {
return null;
}
@override
Future<Response>? request(Uri uri, ApiParams? body, Map<String, String>? headers) => http.delete(uri, headers: headers);
Future<Response>? request(Uri uri, ApiParams? body, Map<String, String>? headers) {
return http.delete(uri, headers: headers);
}
}

View File

@@ -11,7 +11,9 @@ class DeleteReactMessage extends TalkApi {
DeleteReactMessage({required this.chatToken, required this.messageId, required DeleteReactMessageParams params}) : super('v1/reaction/$chatToken/$messageId', params);
@override
assemble(String raw) => null;
assemble(String raw) {
return null;
}
@override
Future<Response>? request(Uri uri, ApiParams? body, Map<String, String>? headers) {

View File

@@ -7,9 +7,13 @@ part of 'deleteReactMessageParams.dart';
// **************************************************************************
DeleteReactMessageParams _$DeleteReactMessageParamsFromJson(
Map<String, dynamic> json,
) => DeleteReactMessageParams(json['reaction'] as String);
Map<String, dynamic> json) =>
DeleteReactMessageParams(
json['reaction'] as String,
);
Map<String, dynamic> _$DeleteReactMessageParamsToJson(
DeleteReactMessageParams instance,
) => <String, dynamic>{'reaction': instance.reaction};
DeleteReactMessageParams instance) =>
<String, dynamic>{
'reaction': instance.reaction,
};

View File

@@ -10,9 +10,13 @@ class GetParticipants extends TalkApi<GetParticipantsResponse> {
GetParticipants(this.token) : super('v4/room/$token/participants', null);
@override
GetParticipantsResponse assemble(String raw) => GetParticipantsResponse.fromJson(jsonDecode(raw)['ocs']);
GetParticipantsResponse assemble(String raw) {
return GetParticipantsResponse.fromJson(jsonDecode(raw)['ocs']);
}
@override
Future<http.Response> request(Uri uri, Object? body, Map<String, String>? headers) => http.get(uri, headers: headers);
Future<http.Response> request(Uri uri, Object? body, Map<String, String>? headers) {
return http.get(uri, headers: headers);
}
}

View File

@@ -8,15 +8,19 @@ class GetParticipantsCache extends RequestCache<GetParticipantsResponse> {
String chatToken;
GetParticipantsCache({required onUpdate, required this.chatToken}) : super(RequestCache.cacheNothing, onUpdate) {
start('nc-chat-participants-$chatToken');
start('MarianumMobile', 'nc-chat-participants-$chatToken');
}
@override
Future<GetParticipantsResponse> onLoad() => GetParticipants(
Future<GetParticipantsResponse> onLoad() {
return GetParticipants(
chatToken,
).run();
}
@override
GetParticipantsResponse onLocalData(String json) => GetParticipantsResponse.fromJson(jsonDecode(json));
GetParticipantsResponse onLocalData(String json) {
return GetParticipantsResponse.fromJson(jsonDecode(json));
}
}

View File

@@ -55,15 +55,12 @@ class GetParticipantsResponseObject {
}
enum GetParticipantsResponseObjectParticipantType {
@JsonValue(1) owner('Besitzer'),
@JsonValue(2) moderator('Moderator'),
@JsonValue(3) user('Teilnehmer'),
@JsonValue(4) guest('Gast'),
@JsonValue(5) userFollowingPublicLink('Teilnehmer über Link'),
@JsonValue(6) guestWithModeratorPermissions('Gast Moderator');
const GetParticipantsResponseObjectParticipantType(this.prettyName);
final String prettyName;
@JsonValue(1) owner,
@JsonValue(2) moderator,
@JsonValue(3) user,
@JsonValue(4) guest,
@JsonValue(5) userFollowingPublicLink,
@JsonValue(6) guestWithModeratorPermissions
}
enum GetParticipantsResponseObjectParticipantsInCallFlags {

View File

@@ -7,77 +7,74 @@ part of 'getParticipantsResponse.dart';
// **************************************************************************
GetParticipantsResponse _$GetParticipantsResponseFromJson(
Map<String, dynamic> json,
) =>
Map<String, dynamic> json) =>
GetParticipantsResponse(
(json['data'] as List<dynamic>)
.map(
(e) => GetParticipantsResponseObject.fromJson(
e as Map<String, dynamic>,
),
)
.toSet(),
)
..headers = (json['headers'] as Map<String, dynamic>?)?.map(
(json['data'] as List<dynamic>)
.map((e) =>
GetParticipantsResponseObject.fromJson(e as Map<String, dynamic>))
.toSet(),
)..headers = (json['headers'] as Map<String, dynamic>?)?.map(
(k, e) => MapEntry(k, e as String),
);
Map<String, dynamic> _$GetParticipantsResponseToJson(
GetParticipantsResponse instance,
) => <String, dynamic>{
'headers': ?instance.headers,
'data': instance.data.map((e) => e.toJson()).toList(),
};
GetParticipantsResponse instance) {
final val = <String, dynamic>{};
void writeNotNull(String key, dynamic value) {
if (value != null) {
val[key] = value;
}
}
writeNotNull('headers', instance.headers);
val['data'] = instance.data.map((e) => e.toJson()).toList();
return val;
}
GetParticipantsResponseObject _$GetParticipantsResponseObjectFromJson(
Map<String, dynamic> json,
) => GetParticipantsResponseObject(
(json['attendeeId'] as num).toInt(),
json['actorType'] as String,
json['actorId'] as String,
json['displayName'] as String,
$enumDecode(
_$GetParticipantsResponseObjectParticipantTypeEnumMap,
json['participantType'],
),
(json['lastPing'] as num).toInt(),
$enumDecode(
_$GetParticipantsResponseObjectParticipantsInCallFlagsEnumMap,
json['inCall'],
),
(json['permissions'] as num).toInt(),
(json['attendeePermissions'] as num).toInt(),
json['sessionId'] as String?,
(json['sessionIds'] as List<dynamic>).map((e) => e as String).toList(),
json['status'] as String?,
json['statusIcon'] as String?,
json['statusMessage'] as String?,
json['roomToken'] as String?,
);
Map<String, dynamic> json) =>
GetParticipantsResponseObject(
json['attendeeId'] as int,
json['actorType'] as String,
json['actorId'] as String,
json['displayName'] as String,
$enumDecode(_$GetParticipantsResponseObjectParticipantTypeEnumMap,
json['participantType']),
json['lastPing'] as int,
$enumDecode(_$GetParticipantsResponseObjectParticipantsInCallFlagsEnumMap,
json['inCall']),
json['permissions'] as int,
json['attendeePermissions'] as int,
json['sessionId'] as String?,
(json['sessionIds'] as List<dynamic>).map((e) => e as String).toList(),
json['status'] as String?,
json['statusIcon'] as String?,
json['statusMessage'] as String?,
json['roomToken'] as String?,
);
Map<String, dynamic> _$GetParticipantsResponseObjectToJson(
GetParticipantsResponseObject instance,
) => <String, dynamic>{
'attendeeId': instance.attendeeId,
'actorType': instance.actorType,
'actorId': instance.actorId,
'displayName': instance.displayName,
'participantType':
_$GetParticipantsResponseObjectParticipantTypeEnumMap[instance
.participantType]!,
'lastPing': instance.lastPing,
'inCall':
_$GetParticipantsResponseObjectParticipantsInCallFlagsEnumMap[instance
.inCall]!,
'permissions': instance.permissions,
'attendeePermissions': instance.attendeePermissions,
'sessionId': instance.sessionId,
'sessionIds': instance.sessionIds,
'status': instance.status,
'statusIcon': instance.statusIcon,
'statusMessage': instance.statusMessage,
'roomToken': instance.roomToken,
};
GetParticipantsResponseObject instance) =>
<String, dynamic>{
'attendeeId': instance.attendeeId,
'actorType': instance.actorType,
'actorId': instance.actorId,
'displayName': instance.displayName,
'participantType': _$GetParticipantsResponseObjectParticipantTypeEnumMap[
instance.participantType]!,
'lastPing': instance.lastPing,
'inCall': _$GetParticipantsResponseObjectParticipantsInCallFlagsEnumMap[
instance.inCall]!,
'permissions': instance.permissions,
'attendeePermissions': instance.attendeePermissions,
'sessionId': instance.sessionId,
'sessionIds': instance.sessionIds,
'status': instance.status,
'statusIcon': instance.statusIcon,
'statusMessage': instance.statusMessage,
'roomToken': instance.roomToken,
};
const _$GetParticipantsResponseObjectParticipantTypeEnumMap = {
GetParticipantsResponseObjectParticipantType.owner: 1,

View File

@@ -1,18 +0,0 @@
import 'dart:convert';
import 'package:http/http.dart' as http;
import '../talkApi.dart';
import 'getPollStateResponse.dart';
class GetPollState extends TalkApi<GetPollStateResponse> {
String token;
int pollId;
GetPollState({required this.token, required this.pollId}) : super('v1/poll/$token/$pollId', null);
@override
GetPollStateResponse assemble(String raw) => GetPollStateResponse.fromJson(jsonDecode(raw)['ocs']);
@override
Future<http.Response> request(Uri uri, Object? body, Map<String, String>? headers) => http.get(uri, headers: headers);
}

View File

@@ -1,50 +0,0 @@
import 'package:json_annotation/json_annotation.dart';
import '../../../apiResponse.dart';
part 'getPollStateResponse.g.dart';
@JsonSerializable(explicitToJson: true)
class GetPollStateResponse extends ApiResponse {
GetPollStateResponseObject data;
GetPollStateResponse(this.data);
factory GetPollStateResponse.fromJson(Map<String, dynamic> json) => _$GetPollStateResponseFromJson(json);
Map<String, dynamic> toJson() => _$GetPollStateResponseToJson(this);
}
@JsonSerializable(explicitToJson: true)
class GetPollStateResponseObject {
int id;
String question;
List<String> options;
dynamic votes;
String actorType;
String actorId;
String actorDisplayName;
int status;
int resultMode;
int maxVotes;
List<int> votedSelf;
int? numVoters;
List<dynamic>? details;
GetPollStateResponseObject(
this.id,
this.question,
this.options,
this.votes,
this.actorType,
this.actorId,
this.actorDisplayName,
this.status,
this.resultMode,
this.maxVotes,
this.votedSelf,
this.numVoters,
this.details);
factory GetPollStateResponseObject.fromJson(Map<String, dynamic> json) => _$GetPollStateResponseObjectFromJson(json);
Map<String, dynamic> toJson() => _$GetPollStateResponseObjectToJson(this);
}

View File

@@ -1,62 +0,0 @@
// GENERATED CODE - DO NOT MODIFY BY HAND
part of 'getPollStateResponse.dart';
// **************************************************************************
// JsonSerializableGenerator
// **************************************************************************
GetPollStateResponse _$GetPollStateResponseFromJson(
Map<String, dynamic> json,
) =>
GetPollStateResponse(
GetPollStateResponseObject.fromJson(
json['data'] as Map<String, dynamic>,
),
)
..headers = (json['headers'] as Map<String, dynamic>?)?.map(
(k, e) => MapEntry(k, e as String),
);
Map<String, dynamic> _$GetPollStateResponseToJson(
GetPollStateResponse instance,
) => <String, dynamic>{
'headers': ?instance.headers,
'data': instance.data.toJson(),
};
GetPollStateResponseObject _$GetPollStateResponseObjectFromJson(
Map<String, dynamic> json,
) => GetPollStateResponseObject(
(json['id'] as num).toInt(),
json['question'] as String,
(json['options'] as List<dynamic>).map((e) => e as String).toList(),
json['votes'],
json['actorType'] as String,
json['actorId'] as String,
json['actorDisplayName'] as String,
(json['status'] as num).toInt(),
(json['resultMode'] as num).toInt(),
(json['maxVotes'] as num).toInt(),
(json['votedSelf'] as List<dynamic>).map((e) => (e as num).toInt()).toList(),
(json['numVoters'] as num?)?.toInt(),
json['details'] as List<dynamic>?,
);
Map<String, dynamic> _$GetPollStateResponseObjectToJson(
GetPollStateResponseObject instance,
) => <String, dynamic>{
'id': instance.id,
'question': instance.question,
'options': instance.options,
'votes': instance.votes,
'actorType': instance.actorType,
'actorId': instance.actorId,
'actorDisplayName': instance.actorDisplayName,
'status': instance.status,
'resultMode': instance.resultMode,
'maxVotes': instance.maxVotes,
'votedSelf': instance.votedSelf,
'numVoters': instance.numVoters,
'details': instance.details,
};

View File

@@ -13,9 +13,13 @@ class GetReactions extends TalkApi<GetReactionsResponse> {
GetReactions({required this.chatToken, required this.messageId}) : super('v1/reaction/$chatToken/$messageId', null);
@override
assemble(String raw) => GetReactionsResponse.fromJson(jsonDecode(raw)['ocs']);
assemble(String raw) {
return GetReactionsResponse.fromJson(jsonDecode(raw)['ocs']);
}
@override
Future<Response>? request(Uri uri, ApiParams? body, Map<String, String>? headers) => http.get(uri, headers: headers);
Future<Response>? request(Uri uri, ApiParams? body, Map<String, String>? headers) {
return http.get(uri, headers: headers);
}
}

View File

@@ -7,53 +7,55 @@ part of 'getReactionsResponse.dart';
// **************************************************************************
GetReactionsResponse _$GetReactionsResponseFromJson(
Map<String, dynamic> json,
) =>
Map<String, dynamic> json) =>
GetReactionsResponse(
(json['data'] as Map<String, dynamic>).map(
(k, e) => MapEntry(
(json['data'] as Map<String, dynamic>).map(
(k, e) => MapEntry(
k,
(e as List<dynamic>)
.map(
(e) => GetReactionsResponseObject.fromJson(
e as Map<String, dynamic>,
),
)
.toList(),
),
),
)
..headers = (json['headers'] as Map<String, dynamic>?)?.map(
.map((e) => GetReactionsResponseObject.fromJson(
e as Map<String, dynamic>))
.toList()),
),
)..headers = (json['headers'] as Map<String, dynamic>?)?.map(
(k, e) => MapEntry(k, e as String),
);
Map<String, dynamic> _$GetReactionsResponseToJson(
GetReactionsResponse instance,
) => <String, dynamic>{
'headers': ?instance.headers,
'data': instance.data.map(
(k, e) => MapEntry(k, e.map((e) => e.toJson()).toList()),
),
};
GetReactionsResponse instance) {
final val = <String, dynamic>{};
void writeNotNull(String key, dynamic value) {
if (value != null) {
val[key] = value;
}
}
writeNotNull('headers', instance.headers);
val['data'] = instance.data
.map((k, e) => MapEntry(k, e.map((e) => e.toJson()).toList()));
return val;
}
GetReactionsResponseObject _$GetReactionsResponseObjectFromJson(
Map<String, dynamic> json,
) => GetReactionsResponseObject(
$enumDecode(_$GetReactionsResponseObjectActorTypeEnumMap, json['actorType']),
json['actorId'] as String,
json['actorDisplayName'] as String,
(json['timestamp'] as num).toInt(),
);
Map<String, dynamic> json) =>
GetReactionsResponseObject(
$enumDecode(
_$GetReactionsResponseObjectActorTypeEnumMap, json['actorType']),
json['actorId'] as String,
json['actorDisplayName'] as String,
json['timestamp'] as int,
);
Map<String, dynamic> _$GetReactionsResponseObjectToJson(
GetReactionsResponseObject instance,
) => <String, dynamic>{
'actorType':
_$GetReactionsResponseObjectActorTypeEnumMap[instance.actorType]!,
'actorId': instance.actorId,
'actorDisplayName': instance.actorDisplayName,
'timestamp': instance.timestamp,
};
GetReactionsResponseObject instance) =>
<String, dynamic>{
'actorType':
_$GetReactionsResponseObjectActorTypeEnumMap[instance.actorType]!,
'actorId': instance.actorId,
'actorDisplayName': instance.actorDisplayName,
'timestamp': instance.timestamp,
};
const _$GetReactionsResponseObjectActorTypeEnumMap = {
GetReactionsResponseObjectActorType.guests: 'guests',

View File

@@ -9,8 +9,12 @@ class LeaveRoom extends TalkApi {
LeaveRoom(this.chatToken) : super('v4/room/$chatToken/participants/self', null);
@override
assemble(String raw) => null;
assemble(String raw) {
return null;
}
@override
Future<Response> request(Uri uri, Object? body, Map<String, String>? headers) => http.delete(uri, headers: headers);
Future<Response> request(Uri uri, Object? body, Map<String, String>? headers) {
return http.delete(uri, headers: headers);
}
}

View File

@@ -11,7 +11,9 @@ class ReactMessage extends TalkApi {
ReactMessage({required this.chatToken, required this.messageId, required ReactMessageParams params}) : super('v1/reaction/$chatToken/$messageId', params);
@override
assemble(String raw) => null;
assemble(String raw) {
return null;
}
@override
Future<Response>? request(Uri uri, ApiParams? body, Map<String, String>? headers) {

View File

@@ -7,7 +7,11 @@ part of 'reactMessageParams.dart';
// **************************************************************************
ReactMessageParams _$ReactMessageParamsFromJson(Map<String, dynamic> json) =>
ReactMessageParams(json['reaction'] as String);
ReactMessageParams(
json['reaction'] as String,
);
Map<String, dynamic> _$ReactMessageParamsToJson(ReactMessageParams instance) =>
<String, dynamic>{'reaction': instance.reaction};
<String, dynamic>{
'reaction': instance.reaction,
};

View File

@@ -14,9 +14,13 @@ class GetRoom extends TalkApi<GetRoomResponse> {
@override
GetRoomResponse assemble(String raw) => GetRoomResponse.fromJson(jsonDecode(raw)['ocs']);
GetRoomResponse assemble(String raw) {
return GetRoomResponse.fromJson(jsonDecode(raw)['ocs']);
}
@override
Future<http.Response> request(Uri uri, Object? body, Map<String, String>? headers) => http.get(uri, headers: headers);
Future<http.Response> request(Uri uri, Object? body, Map<String, String>? headers) {
return http.get(uri, headers: headers);
}
}

View File

@@ -8,16 +8,20 @@ import 'getRoomResponse.dart';
class GetRoomCache extends RequestCache<GetRoomResponse> {
GetRoomCache({onUpdate, renew}) : super(RequestCache.cacheMinute, onUpdate, renew: renew) {
start('nc-rooms');
start('MarianumMobile', 'nc-rooms');
}
@override
GetRoomResponse onLocalData(String json) => GetRoomResponse.fromJson(jsonDecode(json));
GetRoomResponse onLocalData(String json) {
return GetRoomResponse.fromJson(jsonDecode(json));
}
@override
Future<GetRoomResponse> onLoad() => GetRoom(
Future<GetRoomResponse> onLoad() {
return GetRoom(
GetRoomParams(
includeStatus: true,
)
).run();
}
}

View File

@@ -9,20 +9,18 @@ part of 'getRoomParams.dart';
GetRoomParams _$GetRoomParamsFromJson(Map<String, dynamic> json) =>
GetRoomParams(
noStatusUpdate: $enumDecodeNullable(
_$GetRoomParamsStatusUpdateEnumMap,
json['noStatusUpdate'],
),
_$GetRoomParamsStatusUpdateEnumMap, json['noStatusUpdate']),
includeStatus: json['includeStatus'] as bool?,
modifiedSince: (json['modifiedSince'] as num?)?.toInt(),
modifiedSince: json['modifiedSince'] as int?,
);
Map<String, dynamic> _$GetRoomParamsToJson(
GetRoomParams instance,
) => <String, dynamic>{
'noStatusUpdate': _$GetRoomParamsStatusUpdateEnumMap[instance.noStatusUpdate],
'includeStatus': GetRoomParams._format(instance.includeStatus),
'modifiedSince': instance.modifiedSince,
};
Map<String, dynamic> _$GetRoomParamsToJson(GetRoomParams instance) =>
<String, dynamic>{
'noStatusUpdate':
_$GetRoomParamsStatusUpdateEnumMap[instance.noStatusUpdate],
'includeStatus': GetRoomParams._format(instance.includeStatus),
'modifiedSince': instance.modifiedSince,
};
const _$GetRoomParamsStatusUpdateEnumMap = {
GetRoomParamsStatusUpdate.defaults: 0,

View File

@@ -110,7 +110,6 @@ enum GetRoomResponseObjectConversationType {
@JsonValue(3) public,
@JsonValue(4) changelog,
@JsonValue(5) deleted,
@JsonValue(6) noteToSelf,
}
enum GetRoomResponseObjectParticipantNotificationLevel {
@@ -162,7 +161,6 @@ enum GetRoomResponseObjectMessageActorType {
enum GetRoomResponseObjectMessageType {
@JsonValue('comment') comment,
@JsonValue('voice-message') voiceMessage,
@JsonValue('comment_deleted') deletedComment,
@JsonValue('system') system,
@JsonValue('command') command,

View File

@@ -8,97 +8,101 @@ part of 'getRoomResponse.dart';
GetRoomResponse _$GetRoomResponseFromJson(Map<String, dynamic> json) =>
GetRoomResponse(
(json['data'] as List<dynamic>)
.map(
(e) => GetRoomResponseObject.fromJson(e as Map<String, dynamic>),
)
.toSet(),
)
..headers = (json['headers'] as Map<String, dynamic>?)?.map(
(json['data'] as List<dynamic>)
.map((e) => GetRoomResponseObject.fromJson(e as Map<String, dynamic>))
.toSet(),
)..headers = (json['headers'] as Map<String, dynamic>?)?.map(
(k, e) => MapEntry(k, e as String),
);
Map<String, dynamic> _$GetRoomResponseToJson(GetRoomResponse instance) =>
<String, dynamic>{
'headers': ?instance.headers,
'data': instance.data.map((e) => e.toJson()).toList(),
};
Map<String, dynamic> _$GetRoomResponseToJson(GetRoomResponse instance) {
final val = <String, dynamic>{};
void writeNotNull(String key, dynamic value) {
if (value != null) {
val[key] = value;
}
}
writeNotNull('headers', instance.headers);
val['data'] = instance.data.map((e) => e.toJson()).toList();
return val;
}
GetRoomResponseObject _$GetRoomResponseObjectFromJson(
Map<String, dynamic> json,
) => GetRoomResponseObject(
(json['id'] as num).toInt(),
json['token'] as String,
$enumDecode(_$GetRoomResponseObjectConversationTypeEnumMap, json['type']),
json['name'] as String,
json['displayName'] as String,
json['description'] as String,
(json['participantType'] as num).toInt(),
(json['participantFlags'] as num).toInt(),
(json['readOnly'] as num).toInt(),
(json['listable'] as num).toInt(),
(json['lastPing'] as num).toInt(),
json['sessionId'] as String,
json['hasPassword'] as bool,
json['hasCall'] as bool,
(json['callFlag'] as num).toInt(),
json['canStartCall'] as bool,
json['canDeleteConversation'] as bool,
json['canLeaveConversation'] as bool,
(json['lastActivity'] as num).toInt(),
json['isFavorite'] as bool,
$enumDecode(
_$GetRoomResponseObjectParticipantNotificationLevelEnumMap,
json['notificationLevel'],
),
(json['unreadMessages'] as num).toInt(),
json['unreadMention'] as bool,
json['unreadMentionDirect'] as bool,
(json['lastReadMessage'] as num).toInt(),
(json['lastCommonReadMessage'] as num).toInt(),
GetChatResponseObject.fromJson(json['lastMessage'] as Map<String, dynamic>),
json['status'] as String?,
json['statusIcon'] as String?,
json['statusMessage'] as String?,
)..sort = json['sort'] as String?;
Map<String, dynamic> json) =>
GetRoomResponseObject(
json['id'] as int,
json['token'] as String,
$enumDecode(_$GetRoomResponseObjectConversationTypeEnumMap, json['type']),
json['name'] as String,
json['displayName'] as String,
json['description'] as String,
json['participantType'] as int,
json['participantFlags'] as int,
json['readOnly'] as int,
json['listable'] as int,
json['lastPing'] as int,
json['sessionId'] as String,
json['hasPassword'] as bool,
json['hasCall'] as bool,
json['callFlag'] as int,
json['canStartCall'] as bool,
json['canDeleteConversation'] as bool,
json['canLeaveConversation'] as bool,
json['lastActivity'] as int,
json['isFavorite'] as bool,
$enumDecode(_$GetRoomResponseObjectParticipantNotificationLevelEnumMap,
json['notificationLevel']),
json['unreadMessages'] as int,
json['unreadMention'] as bool,
json['unreadMentionDirect'] as bool,
json['lastReadMessage'] as int,
json['lastCommonReadMessage'] as int,
GetChatResponseObject.fromJson(
json['lastMessage'] as Map<String, dynamic>),
json['status'] as String?,
json['statusIcon'] as String?,
json['statusMessage'] as String?,
)..sort = json['sort'] as String?;
Map<String, dynamic> _$GetRoomResponseObjectToJson(
GetRoomResponseObject instance,
) => <String, dynamic>{
'id': instance.id,
'token': instance.token,
'type': _$GetRoomResponseObjectConversationTypeEnumMap[instance.type]!,
'name': instance.name,
'displayName': instance.displayName,
'description': instance.description,
'participantType': instance.participantType,
'participantFlags': instance.participantFlags,
'readOnly': instance.readOnly,
'listable': instance.listable,
'lastPing': instance.lastPing,
'sessionId': instance.sessionId,
'hasPassword': instance.hasPassword,
'hasCall': instance.hasCall,
'callFlag': instance.callFlag,
'canStartCall': instance.canStartCall,
'canDeleteConversation': instance.canDeleteConversation,
'canLeaveConversation': instance.canLeaveConversation,
'lastActivity': instance.lastActivity,
'isFavorite': instance.isFavorite,
'notificationLevel':
_$GetRoomResponseObjectParticipantNotificationLevelEnumMap[instance
.notificationLevel]!,
'unreadMessages': instance.unreadMessages,
'unreadMention': instance.unreadMention,
'unreadMentionDirect': instance.unreadMentionDirect,
'lastReadMessage': instance.lastReadMessage,
'lastCommonReadMessage': instance.lastCommonReadMessage,
'lastMessage': instance.lastMessage.toJson(),
'status': instance.status,
'statusIcon': instance.statusIcon,
'statusMessage': instance.statusMessage,
'sort': instance.sort,
};
GetRoomResponseObject instance) =>
<String, dynamic>{
'id': instance.id,
'token': instance.token,
'type': _$GetRoomResponseObjectConversationTypeEnumMap[instance.type]!,
'name': instance.name,
'displayName': instance.displayName,
'description': instance.description,
'participantType': instance.participantType,
'participantFlags': instance.participantFlags,
'readOnly': instance.readOnly,
'listable': instance.listable,
'lastPing': instance.lastPing,
'sessionId': instance.sessionId,
'hasPassword': instance.hasPassword,
'hasCall': instance.hasCall,
'callFlag': instance.callFlag,
'canStartCall': instance.canStartCall,
'canDeleteConversation': instance.canDeleteConversation,
'canLeaveConversation': instance.canLeaveConversation,
'lastActivity': instance.lastActivity,
'isFavorite': instance.isFavorite,
'notificationLevel':
_$GetRoomResponseObjectParticipantNotificationLevelEnumMap[
instance.notificationLevel]!,
'unreadMessages': instance.unreadMessages,
'unreadMention': instance.unreadMention,
'unreadMentionDirect': instance.unreadMentionDirect,
'lastReadMessage': instance.lastReadMessage,
'lastCommonReadMessage': instance.lastCommonReadMessage,
'lastMessage': instance.lastMessage.toJson(),
'status': instance.status,
'statusIcon': instance.statusIcon,
'statusMessage': instance.statusMessage,
'sort': instance.sort,
};
const _$GetRoomResponseObjectConversationTypeEnumMap = {
GetRoomResponseObjectConversationType.oneToOne: 1,
@@ -106,7 +110,6 @@ const _$GetRoomResponseObjectConversationTypeEnumMap = {
GetRoomResponseObjectConversationType.public: 3,
GetRoomResponseObjectConversationType.changelog: 4,
GetRoomResponseObjectConversationType.deleted: 5,
GetRoomResponseObjectConversationType.noteToSelf: 6,
};
const _$GetRoomResponseObjectParticipantNotificationLevelEnumMap = {

View File

@@ -10,7 +10,9 @@ class SendMessage extends TalkApi {
SendMessage(this.chatToken, SendMessageParams params) : super('v1/chat/$chatToken', params);
@override
assemble(String raw) => null;
assemble(String raw) {
return null;
}
@override
Future<Response>? request(Uri uri, ApiParams? body, Map<String, String>? headers) {

View File

@@ -7,7 +7,7 @@ part 'sendMessageParams.g.dart';
@JsonSerializable(explicitToJson: true, includeIfNull: false)
class SendMessageParams extends ApiParams {
String message;
String? replyTo;
int? replyTo;
SendMessageParams(this.message, {this.replyTo});

View File

@@ -9,11 +9,20 @@ part of 'sendMessageParams.dart';
SendMessageParams _$SendMessageParamsFromJson(Map<String, dynamic> json) =>
SendMessageParams(
json['message'] as String,
replyTo: json['replyTo'] as String?,
replyTo: json['replyTo'] as int?,
);
Map<String, dynamic> _$SendMessageParamsToJson(SendMessageParams instance) =>
<String, dynamic>{
'message': instance.message,
'replyTo': ?instance.replyTo,
};
Map<String, dynamic> _$SendMessageParamsToJson(SendMessageParams instance) {
final val = <String, dynamic>{
'message': instance.message,
};
void writeNotNull(String key, dynamic value) {
if (value != null) {
val[key] = value;
}
}
writeNotNull('replyTo', instance.replyTo);
return val;
}

View File

@@ -11,7 +11,9 @@ class SetFavorite extends TalkApi {
SetFavorite(this.chatToken, this.favoriteState) : super('v4/room/$chatToken/favorite', null);
@override
assemble(String raw) => null;
assemble(String raw) {
return null;
}
@override
Future<Response> request(Uri uri, Object? body, Map<String, String>? headers) {

View File

@@ -15,7 +15,9 @@ class SetReadMarker extends TalkApi {
}
@override
assemble(String raw) => null;
assemble(String raw) {
return null;
}
@override
Future<Response> request(Uri uri, Object? body, Map<String, String>? headers) {

View File

@@ -8,9 +8,11 @@ part of 'setReadMarkerParams.dart';
SetReadMarkerParams _$SetReadMarkerParamsFromJson(Map<String, dynamic> json) =>
SetReadMarkerParams(
lastReadMessage: (json['lastReadMessage'] as num?)?.toInt(),
lastReadMessage: json['lastReadMessage'] as int?,
);
Map<String, dynamic> _$SetReadMarkerParamsToJson(
SetReadMarkerParams instance,
) => <String, dynamic>{'lastReadMessage': instance.lastReadMessage};
SetReadMarkerParams instance) =>
<String, dynamic>{
'lastReadMessage': instance.lastReadMessage,
};

View File

@@ -34,7 +34,7 @@ abstract class TalkApi<T extends ApiResponse?> extends ApiRequest {
getParameters?.update(key, (value) => value.toString());
});
var endpoint = Uri.https('${AccountData().buildHttpAuthString()}@${EndpointData().nextcloud().domain}', '${EndpointData().nextcloud().path}/ocs/v2.php/apps/spreed/api/$path', getParameters);
Uri endpoint = Uri.https('${AccountData().buildHttpAuthString()}@${EndpointData().nextcloud().domain}', '${EndpointData().nextcloud().path}/ocs/v2.php/apps/spreed/api/$path', getParameters);
headers ??= {};
headers?.putIfAbsent('Accept', () => 'application/json');
@@ -58,9 +58,11 @@ abstract class TalkApi<T extends ApiResponse?> extends ApiRequest {
assembled?.headers = data.headers;
return assembled;
} catch (e) {
var message = 'Error assembling Talk API ${T.toString()} message: ${e.toString()} response with request body: $body and request headers: ${headers.toString()}';
log(message);
throw Exception(message);
// TODO report error
log('Error assembling Talk API ${T.toString()} message: ${e.toString()} response on ${endpoint.path} with request body: $body and request headers: ${headers.toString()}');
}
throw Exception('Error assembling Talk API response');
}
}

View File

@@ -6,5 +6,7 @@ class TalkError {
TalkError(this.status, this.code, this.message);
@override
String toString() => 'Talk - $status - ($code): $message';
String toString() {
return 'Talk - $status - ($code): $message';
}
}

View File

@@ -1,26 +0,0 @@
import 'dart:convert';
import 'package:http/http.dart' as http;
import 'package:http/http.dart';
import '../getPoll/getPollStateResponse.dart';
import '../talkApi.dart';
import 'votePollParams.dart';
@Deprecated('VotePoll is broken')
class VotePoll extends TalkApi {
String token;
int pollId;
VotePoll({required this.token, required this.pollId, required VotePollParams params}) : super('v1/poll/$token/$pollId', params);
@override
GetPollStateResponse assemble(String raw) => GetPollStateResponse.fromJson(jsonDecode(raw)['ocs']);
@override
Future<Response>? request(Uri uri, Object? body, Map<String, String>? headers) {
if(body is VotePollParams) {
return http.post(uri, headers: headers, body: body.toJson().toString());
}
return null;
}
}

View File

@@ -1,15 +0,0 @@
import 'package:json_annotation/json_annotation.dart';
import '../../../apiParams.dart';
part 'votePollParams.g.dart';
@JsonSerializable()
@Deprecated('VotePoll is broken')
class VotePollParams extends ApiParams {
List<int> optionIds;
VotePollParams({required this.optionIds});
factory VotePollParams.fromJson(Map<String, dynamic> json) => _$VotePollParamsFromJson(json);
Map<String, dynamic> toJson() => _$VotePollParamsToJson(this);
}

View File

@@ -1,17 +0,0 @@
// GENERATED CODE - DO NOT MODIFY BY HAND
part of 'votePollParams.dart';
// **************************************************************************
// JsonSerializableGenerator
// **************************************************************************
VotePollParams _$VotePollParamsFromJson(Map<String, dynamic> json) =>
VotePollParams(
optionIds: (json['optionIds'] as List<dynamic>)
.map((e) => (e as num).toInt())
.toList(),
);
Map<String, dynamic> _$VotePollParamsToJson(VotePollParams instance) =>
<String, dynamic>{'optionIds': instance.optionIds};

View File

@@ -7,9 +7,13 @@ part of 'downloadFileResponse.dart';
// **************************************************************************
DownloadFileResponse _$DownloadFileResponseFromJson(
Map<String, dynamic> json,
) => DownloadFileResponse(json['path'] as String);
Map<String, dynamic> json) =>
DownloadFileResponse(
json['path'] as String,
);
Map<String, dynamic> _$DownloadFileResponseToJson(
DownloadFileResponse instance,
) => <String, dynamic>{'path': instance.path};
DownloadFileResponse instance) =>
<String, dynamic>{
'path': instance.path,
};

View File

@@ -12,7 +12,7 @@ CacheableFile _$CacheableFileFromJson(Map<String, dynamic> json) =>
isDirectory: json['isDirectory'] as bool,
name: json['name'] as String,
mimeType: json['mimeType'] as String?,
size: (json['size'] as num?)?.toInt(),
size: json['size'] as int?,
eTag: json['eTag'] as String?,
createdAt: json['createdAt'] == null
? null

View File

@@ -13,8 +13,8 @@ class ListFiles extends WebdavApi<ListFilesParams> {
@override
Future<ListFilesResponse> run() async {
var davFiles = (await (await WebdavApi.webdav).propfind(PathUri.parse(params.path))).toWebDavFiles();
var files = davFiles.map(CacheableFile.fromDavFile).toSet();
List<WebDavFile> davFiles = (await (await WebdavApi.webdav).propfind(PathUri.parse(params.path))).toWebDavFiles();
Set<CacheableFile> files = davFiles.map(CacheableFile.fromDavFile).toSet();
// webdav handles subdirectories wrong, this is a fix
// currently this fix is not needed anymore

View File

@@ -11,17 +11,19 @@ class ListFilesCache extends RequestCache<ListFilesResponse> {
ListFilesCache({required onUpdate, required this.path}) : super(RequestCache.cacheNothing, onUpdate) {
var bytes = utf8.encode('MarianumMobile-$path');
var cacheName = md5.convert(bytes).toString();
start('wd-folder-$cacheName');
String cacheName = md5.convert(bytes).toString();
start('MarianumMobile', 'wd-folder-$cacheName');
}
@override
Future<ListFilesResponse> onLoad() async {
var data = await ListFiles(ListFilesParams(path)).run();
ListFilesResponse data = await ListFiles(ListFilesParams(path)).run();
return data;
}
@override
ListFilesResponse onLocalData(String json) => ListFilesResponse.fromJson(jsonDecode(json));
ListFilesResponse onLocalData(String json) {
return ListFilesResponse.fromJson(jsonDecode(json));
}
}

View File

@@ -7,7 +7,11 @@ part of 'listFilesParams.dart';
// **************************************************************************
ListFilesParams _$ListFilesParamsFromJson(Map<String, dynamic> json) =>
ListFilesParams(json['path'] as String);
ListFilesParams(
json['path'] as String,
);
Map<String, dynamic> _$ListFilesParamsToJson(ListFilesParams instance) =>
<String, dynamic>{'path': instance.path};
<String, dynamic>{
'path': instance.path,
};

View File

@@ -8,16 +8,23 @@ part of 'listFilesResponse.dart';
ListFilesResponse _$ListFilesResponseFromJson(Map<String, dynamic> json) =>
ListFilesResponse(
(json['files'] as List<dynamic>)
.map((e) => CacheableFile.fromJson(e as Map<String, dynamic>))
.toSet(),
)
..headers = (json['headers'] as Map<String, dynamic>?)?.map(
(json['files'] as List<dynamic>)
.map((e) => CacheableFile.fromJson(e as Map<String, dynamic>))
.toSet(),
)..headers = (json['headers'] as Map<String, dynamic>?)?.map(
(k, e) => MapEntry(k, e as String),
);
Map<String, dynamic> _$ListFilesResponseToJson(ListFilesResponse instance) =>
<String, dynamic>{
'headers': ?instance.headers,
'files': instance.files.map((e) => e.toJson()).toList(),
};
Map<String, dynamic> _$ListFilesResponseToJson(ListFilesResponse instance) {
final val = <String, dynamic>{};
void writeNotNull(String key, dynamic value) {
if (value != null) {
val[key] = value;
}
}
writeNotNull('headers', instance.headers);
val['files'] = instance.files.map((e) => e.toJson()).toList();
return val;
}

View File

@@ -17,7 +17,11 @@ abstract class WebdavApi<T> extends ApiRequest {
static Future<WebDavClient> webdav = establishWebdavConnection();
static Future<String> webdavConnectString = buildWebdavConnectString();
static Future<WebDavClient> establishWebdavConnection() async => NextcloudClient(Uri.parse('https://${EndpointData().nextcloud().full()}'), password: AccountData().getPassword(), loginName: AccountData().getUsername()).webdav;
static Future<WebDavClient> establishWebdavConnection() async {
return NextcloudClient(Uri.parse('https://${EndpointData().nextcloud().full()}'), password: AccountData().getPassword(), loginName: AccountData().getUsername()).webdav;
}
static Future<String> buildWebdavConnectString() async => 'https://${AccountData().buildHttpAuthString()}@${EndpointData().nextcloud().full()}/remote.php/dav/files/${AccountData().getUsername()}/';
static Future<String> buildWebdavConnectString() async {
return 'https://${AccountData().buildHttpAuthString()}@${EndpointData().nextcloud().full()}/remote.php/dav/files/${AccountData().getUsername()}/';
}
}

View File

@@ -9,9 +9,13 @@ class GetBreakers extends MhslApi<GetBreakersResponse> {
GetBreakers() : super('breaker/');
@override
GetBreakersResponse assemble(String raw) => GetBreakersResponse.fromJson(jsonDecode(raw));
GetBreakersResponse assemble(String raw) {
return GetBreakersResponse.fromJson(jsonDecode(raw));
}
@override
Future<Response>? request(Uri uri) => http.get(uri);
Future<Response>? request(Uri uri) {
return http.get(uri);
}
}

View File

@@ -6,12 +6,16 @@ import 'getBreakersResponse.dart';
class GetBreakersCache extends RequestCache<GetBreakersResponse> {
GetBreakersCache({onUpdate, renew}) : super(RequestCache.cacheMinute, onUpdate, renew: renew) {
start('breakers');
start('MarianumMobile', 'breakers');
}
@override
GetBreakersResponse onLocalData(String json) => GetBreakersResponse.fromJson(jsonDecode(json));
GetBreakersResponse onLocalData(String json) {
return GetBreakersResponse.fromJson(jsonDecode(json));
}
@override
Future<GetBreakersResponse> onLoad() => GetBreakers().run();
Future<GetBreakersResponse> onLoad() {
return GetBreakers().run();
}
}

View File

@@ -8,43 +8,45 @@ part of 'getBreakersResponse.dart';
GetBreakersResponse _$GetBreakersResponseFromJson(Map<String, dynamic> json) =>
GetBreakersResponse(
GetBreakersReponseObject.fromJson(
json['global'] as Map<String, dynamic>,
),
(json['regional'] as Map<String, dynamic>).map(
(k, e) => MapEntry(
k,
GetBreakersReponseObject.fromJson(e as Map<String, dynamic>),
),
),
)
..headers = (json['headers'] as Map<String, dynamic>?)?.map(
GetBreakersReponseObject.fromJson(json['global'] as Map<String, dynamic>),
(json['regional'] as Map<String, dynamic>).map(
(k, e) => MapEntry(
k, GetBreakersReponseObject.fromJson(e as Map<String, dynamic>)),
),
)..headers = (json['headers'] as Map<String, dynamic>?)?.map(
(k, e) => MapEntry(k, e as String),
);
Map<String, dynamic> _$GetBreakersResponseToJson(
GetBreakersResponse instance,
) => <String, dynamic>{
'headers': ?instance.headers,
'global': instance.global.toJson(),
'regional': instance.regional.map((k, e) => MapEntry(k, e.toJson())),
};
Map<String, dynamic> _$GetBreakersResponseToJson(GetBreakersResponse instance) {
final val = <String, dynamic>{};
void writeNotNull(String key, dynamic value) {
if (value != null) {
val[key] = value;
}
}
writeNotNull('headers', instance.headers);
val['global'] = instance.global.toJson();
val['regional'] = instance.regional.map((k, e) => MapEntry(k, e.toJson()));
return val;
}
GetBreakersReponseObject _$GetBreakersReponseObjectFromJson(
Map<String, dynamic> json,
) => GetBreakersReponseObject(
(json['areas'] as List<dynamic>)
.map((e) => $enumDecode(_$BreakerAreaEnumMap, e))
.toList(),
json['message'] as String,
);
Map<String, dynamic> json) =>
GetBreakersReponseObject(
(json['areas'] as List<dynamic>)
.map((e) => $enumDecode(_$BreakerAreaEnumMap, e))
.toList(),
json['message'] as String,
);
Map<String, dynamic> _$GetBreakersReponseObjectToJson(
GetBreakersReponseObject instance,
) => <String, dynamic>{
'areas': instance.areas.map((e) => _$BreakerAreaEnumMap[e]!).toList(),
'message': instance.message,
};
GetBreakersReponseObject instance) =>
<String, dynamic>{
'areas': instance.areas.map((e) => _$BreakerAreaEnumMap[e]!).toList(),
'message': instance.message,
};
const _$BreakerAreaEnumMap = {
BreakerArea.global: 'GLOBAL',

View File

@@ -16,7 +16,7 @@ class AddCustomTimetableEvent extends MhslApi<void> {
@override
Future<Response>? request(Uri uri) {
var body = jsonEncode(params.toJson());
String body = jsonEncode(params.toJson());
return http.post(uri, body: body);
}
}

View File

@@ -7,12 +7,15 @@ part of 'addCustomTimetableEventParams.dart';
// **************************************************************************
AddCustomTimetableEventParams _$AddCustomTimetableEventParamsFromJson(
Map<String, dynamic> json,
) => AddCustomTimetableEventParams(
json['user'] as String,
CustomTimetableEvent.fromJson(json['event'] as Map<String, dynamic>),
);
Map<String, dynamic> json) =>
AddCustomTimetableEventParams(
json['user'] as String,
CustomTimetableEvent.fromJson(json['event'] as Map<String, dynamic>),
);
Map<String, dynamic> _$AddCustomTimetableEventParamsToJson(
AddCustomTimetableEventParams instance,
) => <String, dynamic>{'user': instance.user, 'event': instance.event.toJson()};
AddCustomTimetableEventParams instance) =>
<String, dynamic>{
'user': instance.user,
'event': instance.event.toJson(),
};

View File

@@ -7,29 +7,29 @@ part of 'customTimetableEvent.dart';
// **************************************************************************
CustomTimetableEvent _$CustomTimetableEventFromJson(
Map<String, dynamic> json,
) => CustomTimetableEvent(
id: json['id'] as String,
title: json['title'] as String,
description: json['description'] as String,
startDate: MhslApi.dateTimeFromJson(json['startDate'] as String),
endDate: MhslApi.dateTimeFromJson(json['endDate'] as String),
color: json['color'] as String?,
rrule: json['rrule'] as String,
createdAt: MhslApi.dateTimeFromJson(json['createdAt'] as String),
updatedAt: MhslApi.dateTimeFromJson(json['updatedAt'] as String),
);
Map<String, dynamic> json) =>
CustomTimetableEvent(
id: json['id'] as String,
title: json['title'] as String,
description: json['description'] as String,
startDate: MhslApi.dateTimeFromJson(json['startDate'] as String),
endDate: MhslApi.dateTimeFromJson(json['endDate'] as String),
color: json['color'] as String?,
rrule: json['rrule'] as String,
createdAt: MhslApi.dateTimeFromJson(json['createdAt'] as String),
updatedAt: MhslApi.dateTimeFromJson(json['updatedAt'] as String),
);
Map<String, dynamic> _$CustomTimetableEventToJson(
CustomTimetableEvent instance,
) => <String, dynamic>{
'id': instance.id,
'title': instance.title,
'description': instance.description,
'startDate': MhslApi.dateTimeToJson(instance.startDate),
'endDate': MhslApi.dateTimeToJson(instance.endDate),
'color': instance.color,
'rrule': instance.rrule,
'createdAt': MhslApi.dateTimeToJson(instance.createdAt),
'updatedAt': MhslApi.dateTimeToJson(instance.updatedAt),
};
CustomTimetableEvent instance) =>
<String, dynamic>{
'id': instance.id,
'title': instance.title,
'description': instance.description,
'startDate': MhslApi.dateTimeToJson(instance.startDate),
'endDate': MhslApi.dateTimeToJson(instance.endDate),
'color': instance.color,
'rrule': instance.rrule,
'createdAt': MhslApi.dateTimeToJson(instance.createdAt),
'updatedAt': MhslApi.dateTimeToJson(instance.updatedAt),
};

View File

@@ -12,8 +12,12 @@ class GetCustomTimetableEvent extends MhslApi<GetCustomTimetableEventResponse> {
GetCustomTimetableEvent(this.params) : super('server/timetable/customEvents?user=${params.user}');
@override
GetCustomTimetableEventResponse assemble(String raw) => GetCustomTimetableEventResponse.fromJson({'events': jsonDecode(raw)});
GetCustomTimetableEventResponse assemble(String raw) {
return GetCustomTimetableEventResponse.fromJson({'events': jsonDecode(raw)});
}
@override
Future<Response>? request(Uri uri) => http.get(uri);
Future<Response>? request(Uri uri) {
return http.get(uri);
}
}

View File

@@ -9,12 +9,16 @@ class GetCustomTimetableEventCache extends RequestCache<GetCustomTimetableEventR
GetCustomTimetableEventParams params;
GetCustomTimetableEventCache(this.params, {onUpdate, renew}) : super(RequestCache.cacheMinute, onUpdate, renew: renew) {
start('customTimetableEvents');
start('MarianumMobile', 'customTimetableEvents');
}
@override
Future<GetCustomTimetableEventResponse> onLoad() => GetCustomTimetableEvent(params).run();
Future<GetCustomTimetableEventResponse> onLoad() {
return GetCustomTimetableEvent(params).run();
}
@override
GetCustomTimetableEventResponse onLocalData(String json) => GetCustomTimetableEventResponse.fromJson(jsonDecode(json));
GetCustomTimetableEventResponse onLocalData(String json) {
return GetCustomTimetableEventResponse.fromJson(jsonDecode(json));
}
}

View File

@@ -7,9 +7,13 @@ part of 'getCustomTimetableEventParams.dart';
// **************************************************************************
GetCustomTimetableEventParams _$GetCustomTimetableEventParamsFromJson(
Map<String, dynamic> json,
) => GetCustomTimetableEventParams(json['user'] as String);
Map<String, dynamic> json) =>
GetCustomTimetableEventParams(
json['user'] as String,
);
Map<String, dynamic> _$GetCustomTimetableEventParamsToJson(
GetCustomTimetableEventParams instance,
) => <String, dynamic>{'user': instance.user};
GetCustomTimetableEventParams instance) =>
<String, dynamic>{
'user': instance.user,
};

View File

@@ -7,19 +7,26 @@ part of 'getCustomTimetableEventResponse.dart';
// **************************************************************************
GetCustomTimetableEventResponse _$GetCustomTimetableEventResponseFromJson(
Map<String, dynamic> json,
) =>
Map<String, dynamic> json) =>
GetCustomTimetableEventResponse(
(json['events'] as List<dynamic>)
.map(
(e) => CustomTimetableEvent.fromJson(e as Map<String, dynamic>),
)
.toList(),
)
..headers = (json['headers'] as Map<String, dynamic>?)?.map(
(json['events'] as List<dynamic>)
.map((e) => CustomTimetableEvent.fromJson(e as Map<String, dynamic>))
.toList(),
)..headers = (json['headers'] as Map<String, dynamic>?)?.map(
(k, e) => MapEntry(k, e as String),
);
Map<String, dynamic> _$GetCustomTimetableEventResponseToJson(
GetCustomTimetableEventResponse instance,
) => <String, dynamic>{'headers': ?instance.headers, 'events': instance.events};
GetCustomTimetableEventResponse instance) {
final val = <String, dynamic>{};
void writeNotNull(String key, dynamic value) {
if (value != null) {
val[key] = value;
}
}
writeNotNull('headers', instance.headers);
val['events'] = instance.events;
return val;
}

View File

@@ -15,5 +15,7 @@ class RemoveCustomTimetableEvent extends MhslApi<void> {
void assemble(String raw) {}
@override
Future<Response>? request(Uri uri) => http.delete(uri, body: jsonEncode(params.toJson()));
Future<Response>? request(Uri uri) {
return http.delete(uri, body: jsonEncode(params.toJson()));
}
}

View File

@@ -7,9 +7,13 @@ part of 'removeCustomTimetableEventParams.dart';
// **************************************************************************
RemoveCustomTimetableEventParams _$RemoveCustomTimetableEventParamsFromJson(
Map<String, dynamic> json,
) => RemoveCustomTimetableEventParams(json['id'] as String);
Map<String, dynamic> json) =>
RemoveCustomTimetableEventParams(
json['id'] as String,
);
Map<String, dynamic> _$RemoveCustomTimetableEventParamsToJson(
RemoveCustomTimetableEventParams instance,
) => <String, dynamic>{'id': instance.id};
RemoveCustomTimetableEventParams instance) =>
<String, dynamic>{
'id': instance.id,
};

View File

@@ -15,5 +15,7 @@ class UpdateCustomTimetableEvent extends MhslApi<void> {
void assemble(String raw) {}
@override
Future<Response>? request(Uri uri) => http.patch(uri, body: jsonEncode(params.toJson()));
Future<Response>? request(Uri uri) {
return http.patch(uri, body: jsonEncode(params.toJson()));
}
}

View File

@@ -7,12 +7,15 @@ part of 'updateCustomTimetableEventParams.dart';
// **************************************************************************
UpdateCustomTimetableEventParams _$UpdateCustomTimetableEventParamsFromJson(
Map<String, dynamic> json,
) => UpdateCustomTimetableEventParams(
json['id'] as String,
CustomTimetableEvent.fromJson(json['event'] as Map<String, dynamic>),
);
Map<String, dynamic> json) =>
UpdateCustomTimetableEventParams(
json['id'] as String,
CustomTimetableEvent.fromJson(json['event'] as Map<String, dynamic>),
);
Map<String, dynamic> _$UpdateCustomTimetableEventParamsToJson(
UpdateCustomTimetableEventParams instance,
) => <String, dynamic>{'id': instance.id, 'event': instance.event.toJson()};
UpdateCustomTimetableEventParams instance) =>
<String, dynamic>{
'id': instance.id,
'event': instance.event.toJson(),
};

View File

@@ -0,0 +1,21 @@
import 'dart:convert';
import 'package:http/http.dart' as http;
import '../../mhslApi.dart';
import 'getMessagesResponse.dart';
class GetMessages extends MhslApi<GetMessagesResponse> {
GetMessages() : super('message/messages.json');
@override
GetMessagesResponse assemble(String raw) {
return GetMessagesResponse.fromJson(jsonDecode(raw));
}
@override
Future<http.Response> request(Uri uri) {
return http.get(uri);
}
}

View File

@@ -0,0 +1,21 @@
import 'dart:convert';
import '../../../requestCache.dart';
import 'getMessages.dart';
import 'getMessagesResponse.dart';
class GetMessagesCache extends RequestCache<GetMessagesResponse> {
GetMessagesCache({onUpdate, renew}) : super(RequestCache.cacheMinute, onUpdate, renew: renew) {
start('MarianumMobile', 'message');
}
@override
GetMessagesResponse onLocalData(String json) {
return GetMessagesResponse.fromJson(jsonDecode(json));
}
@override
Future<GetMessagesResponse> onLoad() {
return GetMessages().run();
}
}

View File

@@ -0,0 +1,28 @@
import 'package:json_annotation/json_annotation.dart';
import '../../../apiResponse.dart';
part 'getMessagesResponse.g.dart';
@JsonSerializable(explicitToJson: true)
class GetMessagesResponse extends ApiResponse {
String base;
Set<GetMessagesResponseObject> messages;
GetMessagesResponse(this.base, this.messages);
factory GetMessagesResponse.fromJson(Map<String, dynamic> json) => _$GetMessagesResponseFromJson(json);
Map<String, dynamic> toJson() => _$GetMessagesResponseToJson(this);
}
@JsonSerializable(explicitToJson: true)
class GetMessagesResponseObject {
String name;
String date;
String url;
GetMessagesResponseObject(this.name, this.date, this.url);
factory GetMessagesResponseObject.fromJson(Map<String, dynamic> json) => _$GetMessagesResponseObjectFromJson(json);
Map<String, dynamic> toJson() => _$GetMessagesResponseObjectToJson(this);
}

View File

@@ -0,0 +1,49 @@
// GENERATED CODE - DO NOT MODIFY BY HAND
part of 'getMessagesResponse.dart';
// **************************************************************************
// JsonSerializableGenerator
// **************************************************************************
GetMessagesResponse _$GetMessagesResponseFromJson(Map<String, dynamic> json) =>
GetMessagesResponse(
json['base'] as String,
(json['messages'] as List<dynamic>)
.map((e) =>
GetMessagesResponseObject.fromJson(e as Map<String, dynamic>))
.toSet(),
)..headers = (json['headers'] as Map<String, dynamic>?)?.map(
(k, e) => MapEntry(k, e as String),
);
Map<String, dynamic> _$GetMessagesResponseToJson(GetMessagesResponse instance) {
final val = <String, dynamic>{};
void writeNotNull(String key, dynamic value) {
if (value != null) {
val[key] = value;
}
}
writeNotNull('headers', instance.headers);
val['base'] = instance.base;
val['messages'] = instance.messages.map((e) => e.toJson()).toList();
return val;
}
GetMessagesResponseObject _$GetMessagesResponseObjectFromJson(
Map<String, dynamic> json) =>
GetMessagesResponseObject(
json['name'] as String,
json['date'] as String,
json['url'] as String,
);
Map<String, dynamic> _$GetMessagesResponseObjectToJson(
GetMessagesResponseObject instance) =>
<String, dynamic>{
'name': instance.name,
'date': instance.date,
'url': instance.url,
};

View File

@@ -15,9 +15,9 @@ abstract class MhslApi<T> extends ApiRequest {
T assemble(String raw);
Future<T> run() async {
var endpoint = Uri.parse('https://mhsl.eu/marianum/marianummobile/$subpath');
Uri endpoint = Uri.parse('https://mhsl.eu/marianum/marianummobile/$subpath');
var data = await request(endpoint);
http.Response? data = await request(endpoint);
if(data == null) {
throw ApiError('Request could not be dispatched!');
}
@@ -31,4 +31,5 @@ abstract class MhslApi<T> extends ApiRequest {
static String dateTimeToJson(DateTime time) => Jiffy.parseFromDateTime(time).format(pattern: 'yyyy-MM-dd HH:mm:ss');
static DateTime dateTimeFromJson(String time) => DateTime.parse(time);
}

View File

@@ -19,8 +19,8 @@ class NotifyRegister extends MhslApi<void> {
@override
Future<http.Response> request(Uri uri) {
var requestString = jsonEncode(params.toJson());
log('register at push proxy with username ${params.username}');
String requestString = jsonEncode(params.toJson());
log(requestString);
return http.post(uri, body: requestString);
}
}

View File

@@ -7,17 +7,17 @@ part of 'notifyRegisterParams.dart';
// **************************************************************************
NotifyRegisterParams _$NotifyRegisterParamsFromJson(
Map<String, dynamic> json,
) => NotifyRegisterParams(
username: json['username'] as String,
password: json['password'] as String,
fcmToken: json['fcmToken'] as String,
);
Map<String, dynamic> json) =>
NotifyRegisterParams(
username: json['username'] as String,
password: json['password'] as String,
fcmToken: json['fcmToken'] as String,
);
Map<String, dynamic> _$NotifyRegisterParamsToJson(
NotifyRegisterParams instance,
) => <String, dynamic>{
'username': instance.username,
'password': instance.password,
'fcmToken': instance.fcmToken,
};
NotifyRegisterParams instance) =>
<String, dynamic>{
'username': instance.username,
'password': instance.password,
'fcmToken': instance.fcmToken,
};

Some files were not shown because too many files have changed in this diff Show More