-
Notifications
You must be signed in to change notification settings - Fork 284
Conversation
…error-handling # Conflicts: # src/xcode/ENA/ENA/Source/Scenes/ExposureSubmission/ExposureSubmissionCoordinator.swift
…predondition alert.
src/xcode/ENA/ENA/Source/Scenes/ExposureSubmission/ExposureSubmissionCoordinator.swift
Outdated
Show resolved
Hide resolved
src/xcode/ENA/ENA/Source/Scenes/ExposureSubmission/ExposureSubmissionCoordinator.swift
Outdated
Show resolved
Hide resolved
Some comments on the suggested actions on the pop-ups: "Sind Sie sicher, dass Sie jetzt andere Personen, mit denen Sie in letzter Zeit Kontakt hatten, warnen wollen?" -> Here I would expect "Andere Warnen" to be in bold (=the suggested actions) and not "Abbrechen". "Warn-Vorgang abbrechen" -> Here I would expect "Warnen fortsetzten" to be in bold and not "Abbrechen". |
…missionCoordinator.swift Co-authored-by: Puneet Mahali <[email protected]>
…missionCoordinator.swift Co-authored-by: Puneet Mahali <[email protected]>
You're right, and I have implemented that. The screenshots are updated as well. Thank you! |
Thank you very much @flxschmidt! |
…error-handling # Conflicts: # src/xcode/ENA/ENA/Resources/Localization/de.lproj/Localizable.strings # src/xcode/ENA/ENA/Source/Scenes/ExposureSubmission/ExposureSubmissionCoordinator.swift # src/xcode/ENA/ENA/Source/Scenes/ExposureSubmission/ExposureSubmissionCoordinatorModel.swift # src/xcode/ENA/ENA/Source/Services/PPAccessControl/Model/SRSError.swift # src/xcode/ENA/ENA/Source/View Helpers/AppStrings.swift
…-warn-app/cwa-app-ios into task/14315-error-handling
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just some minor comments and I think one finding that might be critical, marked it with a
src/xcode/ENA/ENA/Source/Scenes/ExposureSubmission/ExposureSubmissionCoordinator.swift
Outdated
Show resolved
Hide resolved
src/xcode/ENA/ENA/Source/Scenes/ExposureSubmission/ExposureSubmissionCoordinator.swift
Outdated
Show resolved
Hide resolved
src/xcode/ENA/ENA/Source/Scenes/ExposureSubmission/ExposureSubmissionCoordinator.swift
Outdated
Show resolved
Hide resolved
|
||
alert.preferredAction = confirmAction | ||
|
||
viewController.present(alert, animated: true) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Couldn't you present on the navigation controller as we do in other places? Then you could get rid of the view controller reference and even get rid of the implicitly unwrapped view controller in this place I think 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That was my first approach, but unfortunately that was not possible, because nav controller is already presenting a VC. Wo don't know which VC is the top most one. I also tried some SOF approaches, but the simplest way is, to give the VC as an associated value to the type.
src/xcode/ENA/ENA/Source/Scenes/ExposureSubmission/ExposureSubmissionCoordinatorModel.swift
Outdated
Show resolved
Hide resolved
src/xcode/ENA/ENA/Source/Services/Exposure Submission/ExposureSubmissionService.swift
Outdated
Show resolved
Hide resolved
src/xcode/ENA/ENA/Source/Services/PPAccessControl/Model/SRSError.swift
Outdated
Show resolved
Hide resolved
src/xcode/ENA/ENA/Source/Services/PPAccessControl/Model/SRSErrorAlert.swift
Show resolved
Hide resolved
src/xcode/ENA/ENA/Source/Services/PPAccessControl/Model/SRSPreconditionError.swift
Outdated
Show resolved
Hide resolved
Add dev menu toggle for prechecks
Description
Implements a API in
ExposureSubmissionCoordinator
to show alerts regarding SRS Self Report Flow.Usage
You only have to call
showSRSFlowAlert(for:isLoading:)
, for example by a callback handler of a SRSFlow ViewController.The method expect a type of an
SRSFlowAlert
that can be:.preconditionFailed
(like app usage time).consent
(like cancel to warn, or confirm to warn).error
(for multiple errors)Regarding Errors
The
.error(error)
expects as an associated value, the regardingError
type, to show the regarding SRS Error alert with the specific alert message for that. Errors to give in, have to be conformable to two protocols:SRSErrorAlertProviding
andErrorCodeProviding
The following Error types are now conformable to that:
SRSError
PPACError
OTPError
Example
Open Points
showCheckinsScreen
dismiss handlerLink to Jira
https://jira-ibs.wbs.net.sap/browse/EXPOSUREAPP-14315
Screenshots
SRS Precondition was failed
Some Errors on Screens
Consent Confirm Warn Others
Updated
Consent Cancel Warn Others
Updated