Skip to content

Commit

Permalink
Merge pull request #1534 from ZeusAutomacao/multi-configuracao-redo
Browse files Browse the repository at this point in the history
Ajustes e correções na DAMDFe e correções de validação MDFeInfLocalDescarrega e MDFeInfLocalCarrega
  • Loading branch information
AgnaldoSilva0 committed Jul 4, 2024
2 parents ae27cbb + 8a39bfd commit 79c1c66
Show file tree
Hide file tree
Showing 3 changed files with 177 additions and 87 deletions.
20 changes: 18 additions & 2 deletions MDFe.Classes/Informacoes/MDFeInfLocalCarrega.cs
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,15 @@ public string LatitudeProxy
if (_latitude == null) return null;
return _latitude.ToString();
}
set { _latitude = decimal.Parse(value); }
set
{
if (value == null)
{
_latitude = null;
return;
}
_latitude = decimal.Parse(value);
}
}

[XmlIgnore]
Expand All @@ -76,7 +84,15 @@ public string LongitudeProxy
if (_longitude == null) return null;
return _longitude.ToString();
}
set { _longitude = decimal.Parse(value); }
set
{
if (value == null)
{
_longitude = null;
return;
}
_longitude = decimal.Parse(value);
}
}
}
}
20 changes: 18 additions & 2 deletions MDFe.Classes/Informacoes/MDFeInfLocalDescarrega.cs
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,15 @@ public string LatitudeProxy
if (_latitude == null) return null;
return _latitude.ToString();
}
set { _latitude = decimal.Parse(value); }
set
{
if (value == null)
{
_latitude = null;
return;
}
_latitude = decimal.Parse(value);
}
}

[XmlIgnore]
Expand All @@ -77,7 +85,15 @@ public string LongitudeProxy
if (_longitude == null) return null;
return _longitude.ToString();
}
set { _longitude = decimal.Parse(value); }
set
{
if (value == null)
{
_longitude = null;
return;
}
_longitude = decimal.Parse(value);
}
}
}
}
Loading

0 comments on commit 79c1c66

Please sign in to comment.