-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #10 from es-wolters-kluwer/features/InvoiceAdditio…
…nalData InvoiceAdditionalData v 2.14.0
- Loading branch information
Showing
22 changed files
with
596 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 23 additions & 0 deletions
23
...Importia.SDK.Implementations/Entities/InvoiceAdditionalData/InputInvoiceAdditionalData.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
namespace a3innuva.TAA.Migration.SDK.Implementations | ||
{ | ||
using a3innuva.TAA.Migration.SDK.Interfaces; | ||
using System; | ||
|
||
public class InputInvoiceAdditionalData : IInputInvoiceAdditionalData | ||
{ | ||
public string Description { get; set; } | ||
public DateTime RegistryDate { get; set; } | ||
public string DuaDocumentId { get; set; } | ||
public bool InvoicesInSpecialRegime { get; set; } | ||
public decimal TaxableIncomeAtCost { get; set; } | ||
public string InitialNumberOfDocument { get; set; } | ||
public string LastNumberOfDocument { get; set; } | ||
public TypeOfDocumentAdditionalDataEnum TypeOfDocument { get; set; } | ||
public FundamentalAdditionalDataEnum Fundamental { get; set; } | ||
public Guid Id { get; set; } | ||
public int Line { get; set; } | ||
public string Source { get; set; } | ||
|
||
public string Identity() => string.Empty; | ||
} | ||
} |
25 changes: 25 additions & 0 deletions
25
...mportia.SDK.Implementations/Entities/InvoiceAdditionalData/OutputInvoiceAdditionalData.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
namespace a3innuva.TAA.Migration.SDK.Implementations | ||
{ | ||
using a3innuva.TAA.Migration.SDK.Interfaces; | ||
using System; | ||
|
||
public class OutputInvoiceAdditionalData : IOutputInvoiceAdditionalData | ||
{ | ||
public string Description { get; set; } | ||
public bool InvoiceByThird { get; set; } | ||
public bool MultipleRecipients { get; set; } | ||
public bool CouponsBonusesOrDiscounts { get; set; } | ||
public bool InvoicesInSpecialRegime { get; set; } | ||
public decimal TaxableIncomeAtCost { get; set; } | ||
public string InitialNumberOfDocument { get; set; } | ||
public string LastNumberOfDocument { get; set; } | ||
public bool NotIncludedInCensus { get; set; } | ||
public TypeOfDocumentAdditionalDataEnum TypeOfDocument { get; set; } | ||
public FundamentalAdditionalDataEnum Fundamental { get; set; } | ||
public Guid Id { get; set; } | ||
public int Line { get; set; } | ||
public string Source { get; set; } | ||
|
||
public string Identity() => string.Empty; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
18 changes: 18 additions & 0 deletions
18
...Implementations/Validations/InvoiceAdditionalData/InputInvoiceAdditionalDataValidation.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
namespace a3innuva.TAA.Migration.SDK.Implementations | ||
{ | ||
using a3innuva.TAA.Migration.SDK.Interfaces; | ||
public class InputInvoiceAdditionalDataValidation : Validation<IInputInvoiceAdditionalData> | ||
{ | ||
protected override void SetupValidations() | ||
{ | ||
this.CreateRule(x => this.Validate(x.Id), "Id"); | ||
|
||
this.CreateRule(x => x.Description.Length <= 500, this.ReplaceInMessage(ValidationMessages.InvalidLength, "'Descripción'")); | ||
|
||
this.CreateRule(x => x.DuaDocumentId.Length <= 18, this.ReplaceInMessage(ValidationMessages.InvalidLength, "'Número de DUA'")); | ||
|
||
this.CreateRule(x => x.InitialNumberOfDocument.Length <= 60, this.ReplaceInMessage(ValidationMessages.InvalidLength, "'Número de documento inicial'")); | ||
this.CreateRule(x => x.LastNumberOfDocument.Length <= 60, this.ReplaceInMessage(ValidationMessages.InvalidLength, "'Número de documento final'")); | ||
} | ||
} | ||
} |
16 changes: 16 additions & 0 deletions
16
...mplementations/Validations/InvoiceAdditionalData/OutputInvoiceAdditionalDataValidation.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
namespace a3innuva.TAA.Migration.SDK.Implementations | ||
{ | ||
using a3innuva.TAA.Migration.SDK.Interfaces; | ||
public class OutputInvoiceAdditionalDataValidation : Validation<IOutputInvoiceAdditionalData> | ||
{ | ||
protected override void SetupValidations() | ||
{ | ||
this.CreateRule(x => this.Validate(x.Id), "Id"); | ||
|
||
this.CreateRule(x => x.Description.Length <= 500, this.ReplaceInMessage(ValidationMessages.InvalidLength, "'Descripción'")); | ||
|
||
this.CreateRule(x => x.InitialNumberOfDocument.Length <= 60, this.ReplaceInMessage(ValidationMessages.InvalidLength, "'Número de documento inicial'")); | ||
this.CreateRule(x => x.LastNumberOfDocument.Length <= 60, this.ReplaceInMessage(ValidationMessages.InvalidLength, "'Número de documento final'")); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 30 additions & 0 deletions
30
...a.Importia.SDK.Interfaces/Entities/InvoiceAdditionalData/FundamentalAdditionalDataEnum.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
namespace a3innuva.TAA.Migration.SDK.Interfaces | ||
{ | ||
public enum FundamentalAdditionalDataEnum | ||
{ | ||
None, | ||
|
||
IssuedNotCorrectiveGeneralRegime, | ||
IssuedNotCorrectiveSpecialRegimeForTravelAgencies, | ||
IssuedNotCorrectiveThirdPartyFeeCollections, | ||
IssuedNotCorrectiveCertificatesOfWorkToThePublicAdministration, | ||
IssuedNotCorrectiveSuccessiveTractOperations, | ||
IssuedNotCorrectiveTravelAgencyServicesAsMediator, | ||
IssuedCorrectiveGeneralRegime, | ||
IssuedCorrectiveSpecialRegimeForTravelAgencies, | ||
IssuedCorrectiveThirdPartyFeeCollections, | ||
IssuedCorrectiveCertificatesOfWorkToThePublicAdministration, | ||
IssuedCorrectiveSuccessiveTractOperations, | ||
IssuedCorrectiveTravelAgencyServicesAsMediator, | ||
|
||
|
||
|
||
InputNotCorrectiveGeneralRegime, | ||
InputNotCorrectiveSpecialRegimeForTravelAgencies, | ||
InputNotCorrectivePurchaseTravelAgencyServicesAsMediator, | ||
InputCorrectiveGeneralRegime, | ||
InputCorrectiveSpecialRegimeForTravelAgencies, | ||
InputCorrectivePurchaseTravelAgencyServicesAsMediator, | ||
InputCorrectiveTravelAgenciesServices | ||
} | ||
} |
43 changes: 43 additions & 0 deletions
43
...uva.Importia.SDK.Interfaces/Entities/InvoiceAdditionalData/IInputInvoiceAdditionalData.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
namespace a3innuva.TAA.Migration.SDK.Interfaces | ||
{ | ||
using System; | ||
public interface IInputInvoiceAdditionalData : IMigrationEntity, IMigrationSourceInfo | ||
{ | ||
/// <summary> | ||
/// Description | ||
/// </summary> | ||
string Description { get; set;} | ||
/// <summary> | ||
/// Date of registry of AEAT | ||
/// </summary> | ||
DateTime RegistryDate { get; set; } | ||
/// <summary> | ||
/// Dua document id | ||
/// </summary> | ||
string DuaDocumentId { get; set; } | ||
/// <summary> | ||
/// Invoice in special regime | ||
/// </summary> | ||
bool InvoicesInSpecialRegime { get; set; } | ||
/// <summary> | ||
/// Taxable income at cost | ||
/// </summary> | ||
decimal TaxableIncomeAtCost { get; set; } | ||
/// <summary> | ||
/// Initial number of document | ||
/// </summary> | ||
string InitialNumberOfDocument { get; set; } | ||
/// <summary> | ||
/// Last number of document | ||
/// </summary> | ||
string LastNumberOfDocument { get; set; } | ||
/// <summary> | ||
/// Type of document additional data | ||
/// </summary> | ||
TypeOfDocumentAdditionalDataEnum TypeOfDocument { get; set; } | ||
/// <summary> | ||
/// Fundamental additional data | ||
/// </summary> | ||
FundamentalAdditionalDataEnum Fundamental { get; set; } | ||
} | ||
} |
51 changes: 51 additions & 0 deletions
51
...va.Importia.SDK.Interfaces/Entities/InvoiceAdditionalData/IOutputInvoiceAdditionalData.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
namespace a3innuva.TAA.Migration.SDK.Interfaces | ||
{ | ||
using System; | ||
public interface IOutputInvoiceAdditionalData : IMigrationEntity, IMigrationSourceInfo | ||
{ | ||
/// <summary> | ||
/// Description | ||
/// </summary> | ||
string Description { get; set;} | ||
/// <summary> | ||
/// Invoice by third | ||
/// </summary> | ||
bool InvoiceByThird { get; set; } | ||
/// <summary> | ||
/// Multiple recipients | ||
/// </summary> | ||
bool MultipleRecipients { get; set; } | ||
/// <summary> | ||
/// Coupons, bonuses or discounts | ||
/// </summary> | ||
bool CouponsBonusesOrDiscounts { get; set; } | ||
/// <summary> | ||
/// Invoice in special regime | ||
/// </summary> | ||
bool InvoicesInSpecialRegime { get; set; } | ||
/// <summary> | ||
/// Taxable income at cost | ||
/// </summary> | ||
decimal TaxableIncomeAtCost { get; set; } | ||
/// <summary> | ||
/// Initial number of document | ||
/// </summary> | ||
string InitialNumberOfDocument { get; set; } | ||
/// <summary> | ||
/// Last number of document | ||
/// </summary> | ||
string LastNumberOfDocument { get; set; } | ||
/// <summary> | ||
/// Not included in census | ||
/// </summary> | ||
bool NotIncludedInCensus { get; set; } | ||
/// <summary> | ||
/// Type of document additional data | ||
/// </summary> | ||
TypeOfDocumentAdditionalDataEnum TypeOfDocument { get; set; } | ||
/// <summary> | ||
/// Fundamental additional data | ||
/// </summary> | ||
FundamentalAdditionalDataEnum Fundamental { get; set; } | ||
} | ||
} |
27 changes: 27 additions & 0 deletions
27
...mportia.SDK.Interfaces/Entities/InvoiceAdditionalData/TypeOfDocumentAdditionalDataEnum.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
namespace a3innuva.TAA.Migration.SDK.Interfaces | ||
{ | ||
public enum TypeOfDocumentAdditionalDataEnum | ||
{ | ||
None = 0, | ||
|
||
IssuedNotCorrectiveInvoice = 10, | ||
IssuedNotCorrectiveSimplifiedInvoice = 11, | ||
IssuedNotCorrectiveInvoiceWithoutObligation = 12, | ||
IssuedCorrectiveErrorFundado = 20, | ||
IssuedCorrectiveConcurso = 21, | ||
IssuedCorrectiveDeudaIncobrable = 22, | ||
IssuedCorrectiveResto = 23, | ||
IssuedCorrectiveSimplificadas = 24, | ||
|
||
|
||
|
||
InputNotCorrectiveInvoice = 30, | ||
InputNotCorrectiveSimplifiedInvoice = 31, | ||
InputNotCorrectiveJustificantesContables = 32, | ||
InputCorrectiveErrorFundado = 40, | ||
InputCorrectiveConcurso = 41, | ||
InputCorrectiveDeudaIncobrable = 42, | ||
InputCorrectiveResto = 43, | ||
InputCorrectiveSimplificadas = 44 | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.