-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathPaymentConfiguration.cs
More file actions
44 lines (39 loc) · 1.54 KB
/
PaymentConfiguration.cs
File metadata and controls
44 lines (39 loc) · 1.54 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
using System;
using Unity.Payments.Domain.AccountCodings;
using Volo.Abp.Domain.Entities.Auditing;
using Volo.Abp.MultiTenancy;
namespace Unity.Payments.Domain.PaymentConfigurations
{
public class PaymentConfiguration : FullAuditedAggregateRoot<Guid>, IMultiTenant
{
public Guid? TenantId { get; set; }
public string PaymentIdPrefix { get; set; } = string.Empty;
public decimal? PaymentThreshold { get; set; }
public string? MinistryClient { get; private set; }
public string? Responsibility { get; private set; }
public string? ServiceLine { get; private set; }
public string? Stob { get; private set; }
public string? ProjectNumber { get; private set; }
protected PaymentConfiguration()
{
/* This constructor is for ORMs to be used while getting the entity from the database. */
}
public PaymentConfiguration(
decimal? paymentThreshold,
string paymentIdPrefix,
AccountCoding accountCoding)
{
PaymentThreshold = paymentThreshold;
PaymentIdPrefix = paymentIdPrefix;
SetAccountCoding(accountCoding);
}
public void SetAccountCoding(AccountCoding accountCoding)
{
MinistryClient = accountCoding.MinistryClient;
Responsibility = accountCoding.Responsibility;
ServiceLine = accountCoding.ServiceLine;
Stob = accountCoding.Stob;
ProjectNumber = accountCoding.ProjectNumber;
}
}
}