Skip to content

Commit 1c4beba

Browse files
author
Mikhail Kalatchev
committed
v0.3.0 released
1 parent 23857ee commit 1c4beba

File tree

20 files changed

+137
-158
lines changed

20 files changed

+137
-158
lines changed

EventsModel/Assets/README.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,5 @@
11
# LIS iLab Events Data Model
2-
Data model of LIS iLab event system
2+
3+
Data model of LIS iLab event system.
4+
5+
Messages from LIS iLab are sent and consumed as JSON encoded objects, defined in this library. Every message object has a default address (queue or topic).

EventsModel/BgNhis/Certificate.cs

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -17,20 +17,10 @@ public class Certificate
1717
public string SerialNumber { get; set; }
1818

1919
/// <summary>
20-
/// Frendly name of the Rila record
20+
/// Frendly name of the Rila record or Subject of the certificate
2121
/// </summary>
2222
public string FriendlyName { get; set; }
2323

24-
/// <summary>
25-
/// Doctor's UIN (according to Bulgarian BMA)
26-
/// </summary>
27-
public string Uin { get; set; }
28-
29-
/// <summary>
30-
/// Practice number associated with this record
31-
/// </summary>
32-
public string PracticeNumber { get; set; }
33-
3424
}
3525

3626
}
Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,37 @@
1-
using System;
1+
using Skyware.Lis.EventsModel.Orders;
2+
using System;
23
using System.Collections.Generic;
34
using System.Text;
45

56
namespace Skyware.Lis.EventsModel.BgNhis
67
{
78

89
/// <summary>
9-
/// Event. Occurs when <see cref="Referral"/> is imported or removed
10-
/// Deafualt address: topic://bg-nhis/ref-import
10+
/// Event. Occurs when action with a <see cref="Referral"/> is made
11+
/// Deafualt address: topic://topic://bg-nhis/referrals
1112
/// </summary>
12-
public class ReferralImport : BaseMessage
13+
public class ReferralAction : BaseMessage
1314
{
1415

1516
/// <summary>
1617
/// Default address where messages are produced
1718
/// </summary>
18-
public override string DefaultAddress => "topic://bg-nhis/ref-import";
19+
public override string DefaultAddress => "topic://bg-nhis/referrals";
1920

2021
/// <summary>
21-
/// Operation indicator - true for import and false for removal
22+
/// Action made with the referral, according to <see cref="ReferralEvents"/>
2223
/// </summary>
23-
public bool IsRemoval { get; set; } = false;
24+
public string Action { get; set; }
2425

2526
/// <summary>
26-
/// Sale to which referral is imported or from which is removed
27+
/// Sale to which referral is imported
2728
/// </summary>
28-
public int SaleId { get; set; }
29+
public int? SaleId { get; set; }
2930

3031
/// <summary>
31-
/// Sale scehma of the Sale
32+
/// Sale scehma of the Sale to which referral is imported
3233
/// </summary>
33-
public int SchemaId { get; set; }
34+
public int? SchemaId { get; set; }
3435

3536
/// <summary>
3637
/// Imported/Removed <see cref="Referral"/>
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
using System;
2+
using System.Collections.Generic;
3+
using System.Text;
4+
5+
namespace Skyware.Lis.EventsModel.BgNhis
6+
{
7+
8+
/// <summary>
9+
/// Well-known values for referral events
10+
/// </summary>
11+
public class ReferralEvents
12+
{
13+
14+
/// <summary>
15+
/// New referral is imported
16+
/// </summary>
17+
public const string IMPORTD = "Importd";
18+
19+
/// <summary>
20+
/// The imported referral is locked in NHIS
21+
/// </summary>
22+
public const string LOCKED = "Locked";
23+
24+
/// <summary>
25+
/// The imported referral is unlocked in NHIS
26+
/// </summary>
27+
public const string UNLOCKED = "Unlocked";
28+
29+
/// <summary>
30+
/// Referral is removed (deleted)
31+
/// </summary>
32+
public const string REMOVED = "Removed";
33+
34+
}
35+
36+
}

EventsModel/BgNhis/ReferralLock.cs

Lines changed: 0 additions & 42 deletions
This file was deleted.

EventsModel/BgNhis/ReferralSearch.cs

Lines changed: 0 additions & 57 deletions
This file was deleted.

EventsModel/BgNhis/Session.cs

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,21 @@ namespace Skyware.Lis.EventsModel.BgNhis
66
{
77

88
/// <summary>
9-
/// Event. Represent attempt for session creation
10-
/// Default address: topic://bg-rila/session
9+
/// Event. Represent attempt for creation of session in NHIS
10+
/// Default address: topic://bg-nhis/sessions
1111
/// </summary>
1212
public class Session : BaseMessage
1313
{
1414

1515
/// <summary>
1616
/// Default address where messages are produced
1717
/// </summary>
18-
public override string DefaultAddress => "topic://bg-nhis/session";
18+
public override string DefaultAddress => "topic://bg-nhis/sessions";
19+
20+
/// <summary>
21+
/// If session is made from Arda library (false means Rila server)
22+
/// </summary>
23+
public bool IsArda { get; set; } = true;
1924

2025
/// <summary>
2126
/// If session was successfully created
@@ -27,6 +32,16 @@ public class Session : BaseMessage
2732
/// </summary>
2833
public Certificate Certificate { get; set; }
2934

35+
/// <summary>
36+
/// Doctor's UIN (according to Bulgarian BMA)
37+
/// </summary>
38+
public string Uin { get; set; }
39+
40+
/// <summary>
41+
/// Practice number associated with this record
42+
/// </summary>
43+
public string PracticeNumber { get; set; }
44+
3045
/// <summary>
3146
/// Description of the error, in case of creation failure
3247
/// </summary>

EventsModel/BgNra/InsuranceCheck.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,15 @@ namespace Skyware.Lis.EventsModel.BgNra
77

88
/// <summary>
99
/// Event. Occurs when Health Insurance (Bulgaria, Nra) is checked
10-
/// Default address: topic://bg-nra/insurance
10+
/// Default address: topic://bg-nra/insurance-checks
1111
/// </summary>
1212
public class InsuranceCheck : BaseMessage
1313
{
1414

1515
/// <summary>
1616
/// Default address where messages are produced
1717
/// </summary>
18-
public override string DefaultAddress => "topic://bg-nra/insurance";
18+
public override string DefaultAddress => "topic://bg-nra/insurance-checks";
1919

2020
/// <summary>
2121
/// Visit to which the patient is associated in the check

EventsModel/Common/Examination.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ public class Examination
2929
/// <summary>
3030
/// True if the examination is a panel (profile)
3131
/// </summary>
32-
public bool IsPanel { get; set; }
32+
public bool? IsPanel { get; set; }
3333

3434
}
3535

EventsModel/Common/Patient.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,12 @@ public class Patient : Person
1919
/// <summary>
2020
/// Type Id in LIS iLab
2121
/// </summary>
22-
public string IdentifierTypeId { get; set; }
22+
public int IdentifierTypeId { get; set; }
2323

2424
/// <summary>
2525
/// Type of well-known identifier of the patient
2626
/// </summary>
27-
public string IdentifierType { get; set; }
27+
public string IdentifierTypeName { get; set; }
2828

2929
/// <summary>
3030
/// Identifier of the, such as SSN, EGN, etc.

0 commit comments

Comments
 (0)