Handle "*" in NationalCode assignment gracefully
Updated the `NationalCode` assignment in the `CreateInstitutionContractLegalPartyRequest` object to replace `"*"` with an empty string (`string.Empty`). This ensures compliance with business rules where `"*"` is not considered a valid value for `NationalCode`. Retains the original value otherwise.
This commit is contained in:
@@ -1999,7 +1999,7 @@ public class InstitutionContractRepository : RepositoryBase<long, InstitutionCon
|
||||
{
|
||||
legalPartyRequest = new CreateInstitutionContractLegalPartyRequest()
|
||||
{
|
||||
NationalCode = contractingParty.Nationalcode,
|
||||
NationalCode = contractingParty.Nationalcode=="*"?string.Empty:contractingParty.Nationalcode,
|
||||
BirthDateFa = contractingParty.DateOfBirth.ToFarsi(),
|
||||
PhoneNumber = contractingParty.Phone,
|
||||
FatherName = contractingParty.FatherName,
|
||||
|
||||
Reference in New Issue
Block a user