diff --git a/App_Code/Modelos.vb b/App_Code/Modelos.vb
index f72a279b9..ab0e74c3a 100644
--- a/App_Code/Modelos.vb
+++ b/App_Code/Modelos.vb
@@ -10371,6 +10371,8 @@ Namespace Modelos
Telefono = ""
UTCOffsetVerano = -7
UTCOffsetInvierno = -7
+ Acum_PortalUsuario = ""
+ Acum_PortalContrasena = ""
End Sub
Public Sub New()
MyBase.New()
@@ -10409,6 +10411,8 @@ Namespace Modelos
Public Property ImprimeNombre As String
Public Property UTCOffsetVerano As Integer
Public Property UTCOffsetInvierno As Integer
+ Public Property Acum_PortalUsuario As String
+ Public Property Acum_PortalContrasena As String
End Class
diff --git a/Nomina/ReportedeAcumulados.aspx b/Nomina/ReportedeAcumulados.aspx
index 65f0577e0..3bcd6de90 100644
--- a/Nomina/ReportedeAcumulados.aspx
+++ b/Nomina/ReportedeAcumulados.aspx
@@ -299,8 +299,8 @@
-
+
@@ -316,6 +316,20 @@
+
+ Sucursal
+
+
+
+
+
+
+ Registro Patronal
+
+
+
+
+
diff --git a/Nomina/ReportedeAcumulados.aspx.cs b/Nomina/ReportedeAcumulados.aspx.cs
index bb9b21d2e..af8ad6723 100644
--- a/Nomina/ReportedeAcumulados.aspx.cs
+++ b/Nomina/ReportedeAcumulados.aspx.cs
@@ -196,7 +196,7 @@ public partial class Nomina_ReportedeAcumulados : ClsPaginas
//string ctipo = "P";
- int CurrentColumn = 2;
+ int CurrentColumn = 4;
BoundField bf;
foreach (DataRow row in dtConceptos.FiltraParametros("Tipo IN ('P') AND EsPadre = 1 ").Rows)
{
@@ -700,6 +700,8 @@ public partial class Nomina_ReportedeAcumulados : ClsPaginas
if (e.Row.RowType == DataControlRowType.DataRow)
{
Literal LtlNombre = e.Row.FCLiteral("LtlNombre");
+ Literal LtlSucursal = e.Row.FCLiteral("LtlSucursal");
+ Literal LtlRegistroPatronal = e.Row.FCLiteral("LtlRegistroPatronal");
int cvePersonal = e.Row.DataKey("CvePersonal").ToEntero();
string Nombre = e.Row.DataKey("Nombre").ToString();
string Codigo = e.Row.DataKey("Codigo").ToString();
@@ -710,6 +712,8 @@ public partial class Nomina_ReportedeAcumulados : ClsPaginas
{
LtlNombre.Text = String.Format("{2} {1}", cvePersonal, Nombre, Codigo);
+ LtlSucursal.Text = String.Format("{0}", e.Row.DataKey("SubProyecto"));
+ LtlRegistroPatronal.Text = String.Format("{0}", e.Row.DataKey("RegistroPatronal"));
}
else
{
diff --git a/RH/CalculoSBC.aspx b/RH/CalculoSBC.aspx
index 3c4ccae4a..dcd58395c 100644
--- a/RH/CalculoSBC.aspx
+++ b/RH/CalculoSBC.aspx
@@ -4,11 +4,11 @@
@@ -91,23 +91,34 @@
+ DataKeyNames="CvePersonal,Codigo,Nombre,FechaInicio,Antiguedad,Incapacitado,NumeroSS,CveTipodeSalario,TipodeSalario,SalarioDiario,SDINuevo,SalarioVariableNuevo,SalarioDiarioSSNuevo,SDI,SalarioVariable,SalarioDiarioSS,PorPrimaVacacional,NumDiasAguinaldo,Acumulado,diasBimestre,Faltas,Incapaciadad,diaslaborados,Movtotxt,RegistroPatronal">
-
+ HyperLink
-
+ HyperLink
+
+
+
+
+
+
+
+
+
+
+
diff --git a/RH/CalculoSBC.aspx.cs b/RH/CalculoSBC.aspx.cs
index eee48ed84..95af6c01e 100644
--- a/RH/CalculoSBC.aspx.cs
+++ b/RH/CalculoSBC.aspx.cs
@@ -62,6 +62,7 @@ public partial class RH_CalculoSBC : ClsPaginas
string concater = "";
//string MovtosAfil = "";
string MovtosmodSalario = "";
+ string Script = "";
//string movtosBajas = "";
using (ClsRH ObjPersonal = new ClsRH())
{
@@ -85,19 +86,48 @@ public partial class RH_CalculoSBC : ClsPaginas
// concater = "\\r\\n";
// contador++;
//}
+ string oldRegistroPatronal = "-1";
foreach (GridViewRow item in GVCalculosSBC.Rows)
{
double SalarioDiarioSSNuevo = Math.Round(item.DataKey("SalarioDiarioSSNuevo").ToDouble(), 2);
double SalarioDiarioSS = Math.Round(item.DataKey("SalarioDiarioSS").ToDouble(), 2);
+ string RegistroPatronal = item.DataKey("RegistroPatronal");
+ if(oldRegistroPatronal != "-1" && oldRegistroPatronal != RegistroPatronal)
+ {
+ MovtosmodSalario = string.Format("{0}{1}{2}", MovtosmodSalario, concater,
+ $"************* 00{(contador < 1000 ? "0" : "")}{(contador < 100 ? "0" : "")}{(contador < 10 ? "0" : "")}{contador} 00001 9");
+
+ Script =string.Format("{0}SaveCsv(\"Movtos{3}_{2:ddMMMyyyy}.txt\", '{1}');", Script, MovtosmodSalario, TxtFechaPago.Text.ToDateTimeExcat("dd/MM/yyyy"), oldRegistroPatronal);
+
+ MovtosmodSalario = "";
+ concater = "";
+ contador = 0;
+ }
if (SalarioDiarioSSNuevo != SalarioDiarioSS)
{
MovtosmodSalario = string.Format("{0}{1}{2}", MovtosmodSalario, concater, item.DataKey("Movtotxt"));
concater = "\\r\\n";
contador++;
}
+ oldRegistroPatronal = RegistroPatronal;
+
+
}
+ //if (oldRegistroPatronal != "-1" && oldRegistroPatronal != RegistroPatronal)
+ {
+ MovtosmodSalario = string.Format("{0}{1}{2}", MovtosmodSalario, concater,
+ $"************* 00{(contador < 1000 ? "0" : "")}{(contador < 100 ? "0" : "")}{(contador < 10 ? "0" : "")}{contador} 00001 9");
+
+ Script = string.Format("{0}SaveCsv(\"Movtos{3}_{2:ddMMMyyyy}.txt\", '{1}');", Script, MovtosmodSalario, TxtFechaPago.Text.ToDateTimeExcat("dd/MM/yyyy"), oldRegistroPatronal);
+
+ MovtosmodSalario = "";
+ concater = "";
+ contador = 0;
+ }
+ /*
MovtosmodSalario = string.Format("{0}{1}{2}", MovtosmodSalario, concater,
$"************* 00{(contador < 1000 ? "0" : "")}{(contador < 100 ? "0" : "")}{(contador < 10 ? "0" : "")}{contador} 00001 9");
+ */
////03: movtosBajas
//concater = "";
//foreach (var item in ObjPersonal.DtResultados.Select("Tipo=3"))
@@ -133,9 +163,9 @@ public partial class RH_CalculoSBC : ClsPaginas
}
catch (Exception) { }
}
+ RegistraScript(Script);
-
- RegistraScript(string.Format("SaveCsv(\"MovtosmodSalario{1:ddMMMyyyy}.txt\", '{0}');", MovtosmodSalario, TxtFechaPago.Text.ToDateTimeExcat("dd/MM/yyyy")));
+ // RegistraScript(string.Format("SaveCsv(\"MovtosmodSalario{1:ddMMMyyyy}.txt\", '{0}');", MovtosmodSalario, TxtFechaPago.Text.ToDateTimeExcat("dd/MM/yyyy")));
//RegistraScript(string.Format("SaveCsv(\"MovtosAfil.txt\", '{0}');SaveCsv(\"MovtosmodSalario.txt\", '{1}');SaveCsv(\"movtosBajas.txt\", '{2}');", MovtosAfil.Replace("'", "\\'"), MovtosmodSalario.Replace("'", "\\'"), movtosBajas.Replace("'", "\\'")));
//RegistraScript("$('#DmodalGetSua').modal('hide');");
}
diff --git a/Ventas/Ventas.aspx.vb b/Ventas/Ventas.aspx.vb
index a23023adf..f29d85d84 100644
--- a/Ventas/Ventas.aspx.vb
+++ b/Ventas/Ventas.aspx.vb
@@ -8,6 +8,7 @@ Imports System.IO
Imports System.Net.Http
Imports System.Security.Cryptography.X509Certificates
Imports System.Xml
+Imports ADSTimbrado
Imports Extensiones
Imports Microsoft.Reporting.WebForms
Imports Newtonsoft.Json.Linq
@@ -33070,8 +33071,8 @@ Partial Class Ventas
obj.used_sale_date = FechaUsado
End If
-
- EnviarPolizaVentaWS(obj, CvePolizaVirtual)
+ ObjFactura.SetSubProyecto()
+ EnviarPolizaVentaWS(obj, CvePolizaVirtual, ObjFactura.SubProyecto.Acum_PortalUsuario, ObjFactura.SubProyecto.Acum_PortalContrasena)
End If
Next
@@ -33082,16 +33083,16 @@ Partial Class Ventas
End Sub
- Protected Function EnviarPolizaVentaWS(obj As Modelos.MPolizaVentaWS, CvePolizaVirtual As Integer) As Boolean
+ Protected Function EnviarPolizaVentaWS(obj As Modelos.MPolizaVentaWS, CvePolizaVirtual As Integer, Usuario As String, Contraseña As String) As Boolean
Dim Retorno As Boolean = False
Dim Respuesta As String = "[]"
- Dim User As String = ""
- Dim Password As String = ""
+ Dim User As String
+ Dim Password As String
If UsuarioActual.Empresa.FacturaProduccion Then
- User = "cslth.2809@jcilink.com"
- Password = "ff31580a95f36b51ad27f970428b77a5a9245076"
+ User = Usuario '"cslth.2809@jcilink.com"
+ Password = Contraseña ' "ff31580a95f36b51ad27f970428b77a5a9245076"
Else
User = "cslth.7777@lth.com"
Password = "ff31580a95f36b51ad27f970428b77a5a9245076"
@@ -33146,19 +33147,14 @@ Partial Class Ventas
If resp(0)("Codigo").ToString().Contiene("500", "501", "502", "503", "504", "505", "506", "507", "508", "510") Then
Retorno = True
- Dim ObjAcum As New ClsAcumuladores
- If ObjAcum.UpdateEnvioPolizaVirtual(CvePolizaVirtual, True, Now, obj.product_unique_code, resp(0)("Descripcion").ToString()) Then
- Alert(Msg.ToString(), TipoMensaje.MsgInformacion)
- End If
- ObjAcum.Dispose()
- Else
- Dim ObjAcum As New ClsAcumuladores
- If ObjAcum.UpdateEnvioPolizaVirtual(CvePolizaVirtual, False, Now, obj.product_unique_code, resp(0)("Descripcion").ToString()) Then
- Alert(Msg.ToString(), TipoMensaje.MsgAdvertencia)
- End If
- ObjAcum.Dispose()
End If
+ Dim ObjAcum As New ClsAcumuladores
+ If ObjAcum.UpdateEnvioPolizaVirtual(CvePolizaVirtual, Retorno, Now, obj.product_unique_code, resp(0)("Descripcion").ToString()) Then
+ Alert(Msg.ToString(), TipoMensaje.MsgInformacion)
+ End If
+ ObjAcum.Dispose()
+
Dim ObjEventos As New ClsOIEventos()
If Not ObjEventos.AddEventoBitacora(Msg.ToString(), "-1", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CveVenta:=Me.CveVenta) Then
ErrorList.Add("Ocurrió un error al agregar la bitacora de Póliza Virtual.")