Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hotfix/SS-417 #133

Merged
merged 2 commits into from
Oct 25, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions SW-sdk-45/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,5 +32,5 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("0.0.19.10")]
[assembly: AssemblyFileVersion("0.0.19.10")]
[assembly: AssemblyVersion("0.0.19.11")]
[assembly: AssemblyFileVersion("0.0.19.11")]
8 changes: 4 additions & 4 deletions SW-sdk-45/Services/Status/Status.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ public class Status : StatusService
public Status(string url) : base(url)
{
}
internal override Acuse StatusRequest(string rfcEmisor, string rfcReceptor, string total, string uuid)
internal override Acuse StatusRequest(string rfcEmisor, string rfcReceptor, string total, string uuid, string sello)
{
return this.RequestStatus(rfcEmisor, rfcReceptor, total, uuid);
return this.RequestStatus(rfcEmisor, rfcReceptor, total, uuid, sello);
}
public Acuse GetStatusCFDI(string rfcEmisor, string rfcReceptor, string Total, string uuid)
public Acuse GetStatusCFDI(string rfcEmisor, string rfcReceptor, string Total, string uuid, string sello)
{
return StatusRequest(rfcEmisor, rfcReceptor, Total, uuid);
return StatusRequest(rfcEmisor, rfcReceptor, Total, uuid, sello);
}
}
}
6 changes: 3 additions & 3 deletions SW-sdk-45/Services/Status/StatusService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@ protected StatusService(string url) : base(url)
delegate (object sender, X509Certificate certificate, X509Chain chain, System.Net.Security.SslPolicyErrors sslPolicyErrors) { return true; };
_myBinding = GetBinding();
}
internal abstract Acuse StatusRequest(string rfcEmisor, string rfcReceptor, string Total, string uuid);
internal virtual Acuse RequestStatus(string rfcEmisor, string rfcReceptor, string total, string uuid)
internal abstract Acuse StatusRequest(string rfcEmisor, string rfcReceptor, string Total, string uuid, string sello);
internal virtual Acuse RequestStatus(string rfcEmisor, string rfcReceptor, string total, string uuid, string sello)
{
var consulta = "?re=" + rfcEmisor.ToUpper() + "&rr=" + rfcReceptor.ToUpper() + "&tt=" + total + "&id=" + uuid.ToUpper();
var consulta = "?re=" + rfcEmisor.ToUpper() + "&rr=" + rfcReceptor.ToUpper() + "&tt=" + total + "&id=" + uuid.ToUpper() + "&fe=" + sello;
Acuse acuse = null;

for (int i = 0; i < 3; i++)
Expand Down
4 changes: 2 additions & 2 deletions SW-sdk/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("0.0.19.10")]
[assembly: AssemblyFileVersion("0.0.19.10")]
[assembly: AssemblyVersion("0.0.19.11")]
[assembly: AssemblyFileVersion("0.0.19.11")]


8 changes: 4 additions & 4 deletions SW-sdk/Services/Status/Status.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@ public Status(string url) : base(url)
{
}

internal override Acuse StatusRequest(string rfcEmisor, string rfcReceptor, string total, string uuid)
internal override Acuse StatusRequest(string rfcEmisor, string rfcReceptor, string total, string uuid, string sello)
{
return this.RequestStatus(rfcEmisor, rfcReceptor, total, uuid);
return this.RequestStatus(rfcEmisor, rfcReceptor, total, uuid, sello);
}

public Acuse GetStatusCFDI(string rfcEmisor, string rfcReceptor, string Total, string uuid)
public Acuse GetStatusCFDI(string rfcEmisor, string rfcReceptor, string Total, string uuid, string sello)
{
return StatusRequest(rfcEmisor, rfcReceptor, Total, uuid);
return StatusRequest(rfcEmisor, rfcReceptor, Total, uuid, sello);
}
}
}
6 changes: 3 additions & 3 deletions SW-sdk/Services/Status/StatusService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@ protected StatusService(string url) : base(url)

_myBinding = GetBinding();
}
internal abstract Acuse StatusRequest(string rfcEmisor, string rfcReceptor, string Total, string uuid);
internal virtual Acuse RequestStatus(string rfcEmisor, string rfcReceptor, string total, string uuid)
internal abstract Acuse StatusRequest(string rfcEmisor, string rfcReceptor, string Total, string uuid, string sello);
internal virtual Acuse RequestStatus(string rfcEmisor, string rfcReceptor, string total, string uuid, string sello)
{
var consulta = "?re=" + rfcEmisor.ToUpper() + "&rr=" + rfcReceptor.ToUpper() + "&tt=" + total + "&id=" + uuid.ToUpper();
var consulta = "?re=" + rfcEmisor.ToUpper() + "&rr=" + rfcReceptor.ToUpper() + "&tt=" + total + "&id=" + uuid.ToUpper() + "&fe=" + sello;
Acuse acuse = null;

for (int i = 0; i < 3; i++)
Expand Down
8 changes: 4 additions & 4 deletions Test_SW-sdk-45/Services/Status/Status_Test.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,31 +24,31 @@ public void StatusCFDI_Vigente()
{
var build = new BuildSettings();
Status status = new Status(urlSAT);
var response = status.GetStatusCFDI("GOM0809114P5", "LSO1306189R5", "206.85", "021ea2fb-2254-4232-983b-9808c2ed831b");
var response = status.GetStatusCFDI("GOM0809114P5", "LSO1306189R5", "206.85", "021ea2fb-2254-4232-983b-9808c2ed831b", "oxOSjA==");
Assert.IsTrue(response.Estado == "Vigente");
}
[TestMethod]
public void StatusCFDI_NoEncontrado()
{
var build = new BuildSettings();
Status status = new Status(urlSAT);
var response = status.GetStatusCFDI("GOM0809114P5", "LSO1306189R5", "206.85", "021ea2fb-2254-4232-983b-9808c2ed831");
var response = status.GetStatusCFDI("GOM0809114P5", "LSO1306189R5", "206.85", "021ea2fb-2254-4232-983b-9808c2ed831", "oxOSjA==");
Assert.IsTrue(response.CodigoEstatus.Contains("602"));
}
[TestMethod]
public void StatusCFDI_ExpresionNoValida()
{
var build = new BuildSettings();
Status status = new Status(urlSAT);
var response = status.GetStatusCFDI("GOM0809114P5", "LSO1306189R5", "?", "021ea2fb-2254-4232-983b-9808c2ed831");
var response = status.GetStatusCFDI("GOM0809114P5", "LSO1306189R5", "?", "021ea2fb-2254-4232-983b-9808c2ed831", "oxOSjA==");
Assert.IsTrue(response.CodigoEstatus.Contains("601"));
}
[TestMethod]
public void StatusCFDI_Cancelado()
{
var build = new BuildSettings();
Status status = new Status(urlSAT);
var response = status.GetStatusCFDI("LSO1306189R5", "LSO1306189R5", "1.16", "e0aae6b3-43cc-4b9c-b229-7e221000e2bb");
var response = status.GetStatusCFDI("LSO1306189R5", "LSO1306189R5", "1.16", "e0aae6b3-43cc-4b9c-b229-7e221000e2bb", "oxOSjA==");
Assert.IsTrue(response.Estado == "Cancelado");
}
}
Expand Down
8 changes: 4 additions & 4 deletions Test_SW-sdk/Services/Status/Status_Test.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,31 +28,31 @@ public void StatusCFDI_Vigente()
{
var build = new BuildSettings();
Status status = new Status(urlSAT);
var response = status.GetStatusCFDI("GOM0809114P5", "LSO1306189R5", "206.85", "021ea2fb-2254-4232-983b-9808c2ed831b");
var response = status.GetStatusCFDI("GOM0809114P5", "LSO1306189R5", "206.85", "021ea2fb-2254-4232-983b-9808c2ed831b", "oxOSjA==");
Assert.IsTrue(response.Estado == "Vigente");
}
[TestMethod]
public void StatusCFDI_NoEncontrado()
{
var build = new BuildSettings();
Status status = new Status(urlSAT);
var response = status.GetStatusCFDI("GOM0809114P5", "LSO1306189R5", "206.85", "021ea2fb-2254-4232-983b-9808c2ed831");
var response = status.GetStatusCFDI("GOM0809114P5", "LSO1306189R5", "206.85", "021ea2fb-2254-4232-983b-9808c2ed831", "oxOSjA==");
Assert.IsTrue(response.CodigoEstatus.Contains("602"));
}
[TestMethod]
public void StatusCFDI_ExpresionNoValida()
{
var build = new BuildSettings();
Status status = new Status(urlSAT);
var response = status.GetStatusCFDI("GOM0809114P5", "LSO1306189R5", "?", "021ea2fb-2254-4232-983b-9808c2ed831");
var response = status.GetStatusCFDI("GOM0809114P5", "LSO1306189R5", "?", "021ea2fb-2254-4232-983b-9808c2ed831", "oxOSjA==");
Assert.IsTrue(response.CodigoEstatus.Contains("601"));
}
[TestMethod]
public void StatusCFDI_Cancelado()
{
var build = new BuildSettings();
Status status = new Status(urlSAT);
var response = status.GetStatusCFDI("LSO1306189R5", "LSO1306189R5", "1.16", "e0aae6b3-43cc-4b9c-b229-7e221000e2bb");
var response = status.GetStatusCFDI("LSO1306189R5", "LSO1306189R5", "1.16", "e0aae6b3-43cc-4b9c-b229-7e221000e2bb", "oxOSjA==");
Assert.IsTrue(response.Estado == "Cancelado");
}
}
Expand Down