ErxTask

public struct ErxTask : Identifiable, Equatable, Hashable, Codable
extension ErxTask: Comparable

Represents all information needed by the Erx App to handle profiled Erx Tasks (e.g. Prescriptions).

Variables that only exist locally

  • When the prescription was redeemed (only for scanned tasks)

    Declaration

    Swift

    public var redeemedOn: String?
  • Indicates if the task was fetched from the FHIRClient or scanned by the ScannerDomain

    Declaration

    Swift

    public let source: Source
  • When redeemed via AVSRedeemService a transaction will be produced

    Declaration

    Swift

    public let avsTransactions: [AVSTransaction]

gematik profiled FHIR resources

  • id

    Id of the task

    Declaration

    Swift

    public var id: String { get }
  • Identifier of the task

    Declaration

    Swift

    public let identifier: String
  • Status of the current task

    Declaration

    Swift

    public var status: Status
  • FlowType describes type of task (e.G. Direktzuweisung). Usually the flowtype is identical to the beginning of the task id

    Declaration

    Swift

    public var flowType: FlowType?
  • When the prescription will be expired

    Declaration

    Swift

    public let expiresOn: String?
  • When the prescription was authored

    Declaration

    Swift

    public let authoredOn: String?
  • Date until which a prescription can be redeemed in the pharmacy without paying the entire prescription. Note that acceptDate <= expireDate

    Declaration

    Swift

    public let acceptedUntil: String?
  • Prescription Id of the task

    Declaration

    Swift

    public let prescriptionId: String?
  • Access code authorizing for the task

    Declaration

    Swift

    public let accessCode: String?
  • The full URL composed of id and access code e.g. “https://prescriptionserver.telematik/Task/588780

    Declaration

    Swift

    public let fullUrl: String?

KBV profiled FHIR resources

gematik profiled FHIR resources loaded from additional endpoints

  • List of all communications for the task, sorted by timestamp Every time when redeemed via ErxTaskRepository a Communication will linked to the task

    Declaration

    Swift

    public let communications: [Communication]
  • List of actual medication dispenses

    Declaration

    Swift

    public let medicationDispenses: [ErxMedicationDispense]
  • Changes status of ErxTask and updates the manual changed redeemedOn property Use this method only for scanned ErxTasks that have been manually redeemed by the user

    Declaration

    Swift

    public mutating func update(with redeemedOn: String?)

    Parameters

    redeemedOn

    Date string when the ErxTask has been redeemed. Pass nil to reset the redeem status

  • Acts as the intermediate data model from a communication resource response and the local store representation

    See more

    Declaration

    Swift

    public struct Communication : Equatable, Identifiable, Codable
    extension ErxTask.Communication: Comparable, Hashable
  • All defined states of a task (see gemSysL_eRp chapter 2.4.6 “Konzept Status E-Rezept”)

    See more

    Declaration

    Swift

    public enum Status : Equatable, RawRepresentable, Codable
  • Declaration

    Swift

    public enum CoPaymentStatus : String, Equatable, Codable
  • Declaration

    Swift

    public enum FlowType : Equatable, RawRepresentable, Codable
  • Declaration

    Swift

    public enum Source : String, Codable
  • Declaration

    Swift

    public static func < (lhs: ErxTask, rhs: ErxTask) -> Bool
  • Declaration

    Swift

    public func hash(into hasher: inout Hasher)