eMedit.Webhooks.Receiver 1.0.2

There is a newer version of this package available.
See the version list below for details.
dotnet add package eMedit.Webhooks.Receiver --version 1.0.2
NuGet\Install-Package eMedit.Webhooks.Receiver -Version 1.0.2
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="eMedit.Webhooks.Receiver" Version="1.0.2" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add eMedit.Webhooks.Receiver --version 1.0.2
#r "nuget: eMedit.Webhooks.Receiver, 1.0.2"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install eMedit.Webhooks.Receiver as a Cake Addin
#addin nuget:?package=eMedit.Webhooks.Receiver&version=1.0.2

// Install eMedit.Webhooks.Receiver as a Cake Tool
#tool nuget:?package=eMedit.Webhooks.Receiver&version=1.0.2

eMedit.Webhooks.Receiver

Potrebno je izvršiti implementaciju i naslijeđivanje klase eMeditWebhookHandler. Unutar nove klase mogu se override-ati metode koje predstavljaju događaje koji se dese na eMedit platformi.

 public class MyCustomHandler : eMeditWebHookHandler
    {

        protected override void OnRspIns(eMeditWebhookNotification meditWebhookNotification, ReferralResponse referralResponse)
        {
            base.OnRspIns(meditWebhookNotification, referralResponse);
        }


        protected override void OnRspVer(eMeditWebhookNotification meditWebhookNotification, ReferralResponse referralResponse)
        {
            base.OnRspVer(meditWebhookNotification, referralResponse);
        }

    }

Metode se automatski aktiviraju i proslijeđuje se definisan set parametera koji odgovara trenutnom događaju.

Model eMeditWebhookNotification sadrzi podatke releventne za sam događaj:

namespace eMedit.Webhooks.Utils.Models
{
    public class eMeditWebhookNotification
    {
        public eMeditWebhookNotification();

        public string Id { get; set; }
        public int Attempt { get; set; }
        public IDictionary<string, string> Properties { get; set; }
        public string Username { get; set; }
        public string DateTime { get; set; }
        public string EventCode { get; set; }
        public string JsonParameters { get; set; }

        public string GetActionCode();
        public string GetCabinetCode();
        public string GetInstitutionCode();
    }
}

Pored ovog koriste se jos i sljedeci modeli koji sadrze podatke koje se odnose na resurs nad kojim se desio događaj kao i dodatni set podataka samog resursa ukoliko je doslo do nekih promjena:

 public class ReferralResponse
    {
        public ReferralResponse();

        public string ReferralResponseID { get; set; }
        public string ReferralID { get; set; }
    }

public class Patient
    {
        public string PatientID { get; set; }
    }

  public class Referral
    {
        public string ReferralID { get; set; }
    }

 public class PrescriptionNotification
    {
        public string PrescriptionID { get; set; }
        public PharmacyPatient Patient { get; set; }
        public string AtcCode { get; set; }
        public string MedicationCode { get; set; }
        public string MedicationDescription { get; set; }
        public string Dosage { get; set; }
        public string Quantity { get; set; }
        public bool IsRecommendedBySpecialist { get; set; }
        public bool IsCommercial { get; set; }
        public string PrescriptionType { get; set; }
        public DateTime PrescriptionDate { get; set; }
        public PharmacyDispense Dispense { get; set; }
        public string CaseNumber { get; set; }
        public string MedsolPrescriptionID { get; set; }
    }

    public class PharmacyPatient
    {
        public string Name { get; set; }
        public string Surname { get; set; }
        public string IdentificationCode { get; set; }
        public string IdentificationType { get; set; }
        public DateTime BirthDate { get; set; }
        public string Gender { get; set; }
    }

    public class PharmacyDispense
    {
        public string PharmacyName { get; set; }
        public string Pharmacist { get; set; }
        public DateTime DispenseDate { get; set; }
        public string DispenseQuantity { get; set; }
    }
Product Compatible and additional computed target framework versions.
.NET Framework net461 is compatible.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.0.7 3,762 8/5/2020
1.0.6-rc 310 8/4/2020
1.0.5 3,561 5/13/2020
1.0.4 477 2/4/2020
1.0.3 409 1/30/2020
1.0.2 419 1/16/2020
1.0.1 463 1/9/2020

eMedit Webhooks receiver.