This commit is contained in:
@@ -96,10 +96,10 @@ public partial class AF_CatTiposServiciosActividades : ClsPaginas
|
||||
}
|
||||
else
|
||||
{
|
||||
if (ObjAF.UpdateActividades(DdlActividades.SelectedValue.ToEntero(),TxtDuracion.Text.ToEntero(),TxtObservaciones.Text))
|
||||
{
|
||||
Alert("Se actualizó la Actividad del Tipo de Servicio correctamente");
|
||||
}
|
||||
//if (ObjAF.UpdateActividades(DdlActividades.SelectedValue.ToEntero(),TxtDuracion.Text.ToEntero(),TxtObservaciones.Text,))
|
||||
//{
|
||||
// Alert("Se actualizó la Actividad del Tipo de Servicio correctamente");
|
||||
//}
|
||||
}
|
||||
ObjAF.Dispose();
|
||||
CargaDatos();
|
||||
|
||||
@@ -47,21 +47,21 @@ Partial Class AF_ValesCombustible
|
||||
DdlSubProyecto.DataBind()
|
||||
DdlSubProyecto.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
|
||||
If UsuarioActual.Empresa.GralSoloProyecto Then
|
||||
'If UsuarioActual.Empresa.GralSoloProyecto Then
|
||||
|
||||
LtlSubProyecto.Text = "Proyecto"
|
||||
DdlSubProyecto.Items.Clear()
|
||||
DdlSubProyecto.DataSource = If(UsuarioActual.Empresa.Funcionalidad(102) = "1" AndAlso Not UsuarioActual.TienePermisoProceso(110), GlobalDTSubProyectosUsuarios(UsuarioActual.CveUsuario, -1, UsuarioActual.CveEmpresa, -1, 1), GlobalDTSubProyectos(-1, -1, UsuarioActual.CveEmpresa, 1))
|
||||
DdlSubProyecto.DataBind()
|
||||
DdlSubProyecto.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
DivProyecto.Visible = False
|
||||
'DdlProyecto.Items(0).Text = ""
|
||||
Else
|
||||
DivProyecto.Visible = True
|
||||
DdlProyecto.DataSource = GlobalDTProyectos(UsuarioActual.CveEmpresa)
|
||||
DdlProyecto.DataBind()
|
||||
DdlProyecto.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
End If
|
||||
' LtlSubProyecto.Text = "Proyecto"
|
||||
' DdlSubProyecto.Items.Clear()
|
||||
' DdlSubProyecto.DataSource = If(UsuarioActual.Empresa.Funcionalidad(102) = "1" AndAlso Not UsuarioActual.TienePermisoProceso(110), GlobalDTSubProyectosUsuarios(UsuarioActual.CveUsuario, -1, UsuarioActual.CveEmpresa, -1, 1), GlobalDTSubProyectos(-1, -1, UsuarioActual.CveEmpresa, 1))
|
||||
' DdlSubProyecto.DataBind()
|
||||
' DdlSubProyecto.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
' DivProyecto.Visible = False
|
||||
' 'DdlProyecto.Items(0).Text = ""
|
||||
'Else
|
||||
DivProyecto.Visible = True
|
||||
DdlProyecto.DataSource = GlobalDTProyectos(UsuarioActual.CveEmpresa)
|
||||
DdlProyecto.DataBind()
|
||||
DdlProyecto.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
'End If
|
||||
|
||||
|
||||
DdlCombustible.DataSource = GlobalDTCombustibles(UsuarioActual.CveEmpresa)
|
||||
|
||||
@@ -7881,6 +7881,7 @@ Public Class ClsPaginas
|
||||
|
||||
ImgCBB = String.Format("{0}://{1}:{2}/Empresas/{3}/CBB/Nomina/{4}.jpg", Request.Url.Scheme, Request.Url.Host, Request.Url.Port, UsuarioActual.CveEmpresa, ObjNomina.SerieFolio)
|
||||
|
||||
Dim cQr As Byte() = Nothing
|
||||
Try
|
||||
Dim CadenaOriginalCFD As String = "||1.0|" + FolioFiscal + "|" + FechaCertificacion.ToString("yyyy-MM-dd") + "T" + FechaCertificacion.ToString("HH:mm:ss") + "|" + SelloCFDi + "|" + NoSerieCertificado + "||"
|
||||
|
||||
@@ -7897,7 +7898,7 @@ Public Class ClsPaginas
|
||||
RptParametro.Add(New ReportParameter("RFC", ObjPersonal.RFC))
|
||||
RptParametro.Add(New ReportParameter("CURP", ObjPersonal.CURP))
|
||||
|
||||
RptParametro.Add(New ReportParameter("NombreCompleto", ObjPersonal.NombreCompleto))
|
||||
RptParametro.Add(New ReportParameter("NombreCompleto", String.Format("{0} {1} {2}", ObjPersonal.Nombres, ObjPersonal.APaterno, ObjPersonal.AMaterno).Trim()))
|
||||
RptParametro.Add(New ReportParameter("Regimen", ObjPersonal.RegimenContratacion))
|
||||
RptParametro.Add(New ReportParameter("RiesgoPuesto", ObjPersonal.RiesgoPuesto))
|
||||
|
||||
@@ -7924,23 +7925,18 @@ Public Class ClsPaginas
|
||||
RptParametro.Add(New ReportParameter("Periodo", ObjNomina.TipoPeriodo))
|
||||
|
||||
RptParametro.Add(New ReportParameter("DiasPagados", ObjNomina.DiasPagados.ToString))
|
||||
RptParametro.Add(New ReportParameter("MetodoPago", ObjNomina.MetodoPago))
|
||||
RptParametro.Add(New ReportParameter("FormaPago", ObjNomina.FormaPago))
|
||||
RptParametro.Add(New ReportParameter("MetodoPago", """PUE"" (Pago en una sola exhibición)"))
|
||||
RptParametro.Add(New ReportParameter("FormaPago", """99"" (Por definir)"))
|
||||
|
||||
RptParametro.Add(New ReportParameter("Cantidad", "1"))
|
||||
RptParametro.Add(New ReportParameter("Unidad", "SERVICIO"))
|
||||
RptParametro.Add(New ReportParameter("Unidad", "ACT"))
|
||||
RptParametro.Add(New ReportParameter("Descripcion", "PAGO DE NÓMINA"))
|
||||
RptParametro.Add(New ReportParameter("PU", ObjNomina.SubTotal.ToString))
|
||||
RptParametro.Add(New ReportParameter("Importe", ObjNomina.SubTotal.ToString))
|
||||
|
||||
RptParametro.Add(New ReportParameter("SubTotal", ObjNomina.SubTotal.ToString))
|
||||
RptParametro.Add(New ReportParameter("Descuentos", ObjNomina.Descuento.ToString))
|
||||
RptParametro.Add(New ReportParameter("ISR", ObjNomina.RetISR.ToString))
|
||||
RptParametro.Add(New ReportParameter("Total", ObjNomina.Total.ToString))
|
||||
|
||||
RptParametro.Add(New ReportParameter("Total", ObjNomina.Total.ToString()))
|
||||
|
||||
Dim CBB As New ClbNegBICFDv3_2.ClsNegCBBGenerar()
|
||||
cQr = CBB.GenerarCBBBytes(UsuarioActual.Empresa.RFC, ObjPersonal.RFC, ObjNomina.Total.ToString().ToDecimal(), FolioFiscal)
|
||||
RptParametro.Add(New ReportParameter("ImporteLetra", ObjNomina.Total.ToString.ToDouble.Texto2Letras))
|
||||
RptParametro.Add(New ReportParameter("Clave", ""))
|
||||
RptParametro.Add(New ReportParameter("Clave", "84111505"))
|
||||
Else
|
||||
TieneError = True
|
||||
End If
|
||||
@@ -7957,7 +7953,28 @@ Public Class ClsPaginas
|
||||
End If
|
||||
End If
|
||||
|
||||
'PERCECIONES - DEDUCCIONES
|
||||
If ObjNomina.GetNom_NominasDetalles(CveNomina, CvePersonal, CvePeriodo, "-1") Then
|
||||
DTPercepciones = ObjNomina.DtResultados.FiltraParametros("(Tipo = 'P' OR (Tipo = 'D' AND Importe <0)) AND Importe <>0 AND EsPadre = 1 AND SoloVisible =0")
|
||||
DTDeducciones = ObjNomina.DtResultados.FiltraParametros("Tipo = 'D' AND Importe >0 AND EsPadre = 1 AND SoloVisible =0")
|
||||
For Each row As DataRow In DTPercepciones.Rows
|
||||
If row("Tipo").ToString() = "D" Then
|
||||
row("Codigo") = row("Codigo").ToString().Replace("D", "OP")
|
||||
row("Importe") = row("Importe").ToString().ToDecimal() * -1
|
||||
End If
|
||||
Next
|
||||
|
||||
Else
|
||||
DTPercepciones = Nothing
|
||||
DTDeducciones = Nothing
|
||||
End If
|
||||
|
||||
RptParametro.Add(New ReportParameter("PU", DTPercepciones.SUM("Importe").ToString()))
|
||||
RptParametro.Add(New ReportParameter("Importe", DTPercepciones.SUM("Importe").ToString()))
|
||||
|
||||
RptParametro.Add(New ReportParameter("SubTotal", DTPercepciones.SUM("Importe").ToString()))
|
||||
RptParametro.Add(New ReportParameter("Descuentos", DTDeducciones.SUM("Importe", "SATCveConcepto <> '002'").ToString()))
|
||||
RptParametro.Add(New ReportParameter("ISR", DTDeducciones.SUM("Importe", "SATCveConcepto = '002'").ToString()))
|
||||
'Timbrado
|
||||
RptParametro.Add(New ReportParameter("FolioFiscal", FolioFiscal))
|
||||
RptParametro.Add(New ReportParameter("CertificadoSAT", NoSerieCertificado))
|
||||
@@ -7967,16 +7984,18 @@ Public Class ClsPaginas
|
||||
RptParametro.Add(New ReportParameter("CadenaOriginal", CadenaOriginalCFD))
|
||||
RptParametro.Add(New ReportParameter("QR", ImgCBB.ToString))
|
||||
|
||||
'PERCECIONES - DEDUCCIONES
|
||||
If ObjNomina.GetNom_NominasDetalles(CveNomina, CvePersonal, CvePeriodo, "-1") Then
|
||||
DTPercepciones = ObjNomina.DtResultados.FiltraParametros("Tipo = 'P' AND EsPadre = 1")
|
||||
DTDeducciones = ObjNomina.DtResultados.FiltraParametros("Tipo = 'D' AND EsPadre = 1")
|
||||
Else
|
||||
DTPercepciones = Nothing
|
||||
DTDeducciones = Nothing
|
||||
End If
|
||||
|
||||
Dim LSRds As New List(Of ReportDataSource)
|
||||
|
||||
|
||||
Dim rds2 = New ReportDataSource()
|
||||
Dim limagenes = New List(Of utilImage)()
|
||||
limagenes.Add(New utilImage(cQr))
|
||||
rds2.Name = "dsImagenes"
|
||||
rds2.Value = limagenes
|
||||
LSRds.Add(rds2)
|
||||
|
||||
|
||||
Dim RptDS As New ReportDataSource
|
||||
RptDS.Name = "DsOC"
|
||||
RptDS.Value = DTPercepciones
|
||||
@@ -8002,7 +8021,7 @@ Public Class ClsPaginas
|
||||
End Try
|
||||
End If
|
||||
Else
|
||||
ImprimirPDF(String.Format("{0}\Formatos\Nomina.rdlc", RutaEmpresa), LSRds, RptParametro, ObjNomina.SerieFolio)
|
||||
'ImprimirPDF(String.Format("{0}\Formatos\Nomina.rdlc", RutaEmpresa), LSRds, RptParametro, ObjNomina.SerieFolio)
|
||||
End If
|
||||
Else
|
||||
Alert("Ocurrio un error al obtener los datos de la Nomina")
|
||||
@@ -8018,6 +8037,13 @@ Public Class ClsPaginas
|
||||
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
Public Class utilImage
|
||||
Public Sub New(imagenByte As Byte())
|
||||
Me.ImagenByte = imagenByte
|
||||
End Sub
|
||||
Public Property ImagenByte As Byte()
|
||||
End Class
|
||||
#End Region
|
||||
|
||||
#Region "PDF PAGOS"
|
||||
|
||||
@@ -1,3 +0,0 @@
|
||||
Log tareas:
|
||||
Llamada de consulta: 11 minutos
|
||||
Temperatura comienzo: 7 pm
|
||||
@@ -249,13 +249,16 @@ Public Class LogicNominas
|
||||
|
||||
If DtDeducciones IsNot Nothing AndAlso DtDeducciones.Rows.Count > 0 Then
|
||||
For Each Row As DataRow In DtDeducciones.Rows
|
||||
If Row("Importe").ToString().ToDecimal > 0 Then
|
||||
If Row("Importe").ToString().ToDecimal <> 0 Then
|
||||
|
||||
If Row("CveSATConcepto").ToString() = "" Then cfdi.AddMsg(String.Format("Concepto No registrado ({0})", Row("Concepto").ToString())) : Exit For
|
||||
If Row("SATCveConcepto").ToString().ToEntero().ToEntero() = 17 Then
|
||||
|
||||
ObjPercepciones.Add(New CFDINominaPercepciones With {.TipoPercepcion = Row("SATCveConcepto").ToString(), .Clave = Row("Codigo").ToString(), .Concepto = Row("Concepto").ToString(),
|
||||
.ImporteGravado = Row("ImporteGravado").ToString().ToDecimal(), .ImporteExento = Row("ImporteExento").ToString().ToDecimal()})
|
||||
ElseIf Row("Importe").ToString().ToDecimal() < 0 AndAlso Row("Concepto").ToString() = "Ajuste al neto" Then
|
||||
ObjOtrosPagos.Add(New CFDINominaOtrosPagos With {.TipoOtroPago = "999", .Clave = Row("Codigo").ToString(), .Concepto = Row("Concepto").ToString(),
|
||||
.Importe = Row("Importe").ToString().ToDecimal() * -1})
|
||||
Else
|
||||
ObjDeducciones.Add(New CFDINominaDeducciones With {.TipoDeduccion = Row("SATCveConcepto").ToString(),
|
||||
.Clave = Row("Codigo").ToString(),
|
||||
|
||||
@@ -250,7 +250,7 @@
|
||||
<asp:TemplateField HeaderText="Agregar">
|
||||
<ItemTemplate>
|
||||
<%--<asp:Image ID="ImgAgregar" runat="server" Style="cursor: pointer;" Visible='<%# Eval("CveProveedor").ToString <> "" %>' ToolTip="Agregar Factura" ImageUrl="/Imagenes/Nota.gif" Height="18px" />--%>
|
||||
<asp:HyperLink ID="HplAgregar" runat="server" CssClass="btn btn-circle btn-sm green" Visible='<%# Eval("CveProveedor").ToString <> "" %>' data-toggle="tooltip" title="Agregar Factura" Target="_blank"><i class="fa fa-plus"></i></asp:HyperLink>
|
||||
<asp:HyperLink ID="HplAgregar" runat="server" CssClass="btn btn-circle btn-sm green" Visible='<%# Eval("CveProveedor").ToString <> "" %>' data-toggle="tooltip" title="Agregar Factura" rel="opener" Target="_blank"><i class="fa fa-plus"></i></asp:HyperLink>
|
||||
<asp:LinkButton ID="LnkAgregarPago" runat="server" OnClick="LnkAgregarPago_Click" CssClass="btn btn-sm blue" Visible="false" data-toggle="tooltip" title="Vincular Pago"><i class="fa fa-check"></i></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
|
||||
@@ -204,8 +204,13 @@ Partial Class LogIn
|
||||
ADSSessionConfig.sessionUser = Usuario
|
||||
ADSSessionConfig.sessionDpage = False
|
||||
ObjUsuario.Dispose()
|
||||
|
||||
If Usuario IsNot Nothing Then
|
||||
Dim isgps = Request.Url.Host.ToUpper().Contains("SIGNALSGPS".ToUpper())
|
||||
If Usuario IsNot Nothing AndAlso (
|
||||
Usuario.CveRol = 1 OrElse (
|
||||
(isgps AndAlso (Usuario.CvePlataforma = 3 OrElse Usuario.CveRol = 1200)) OrElse
|
||||
((Not isgps) AndAlso (Usuario.CvePlataforma <> 3 AndAlso Usuario.CveRol <> 1200))
|
||||
)
|
||||
) Then
|
||||
If Not Usuario.AutorizadoxIP OrElse (HddAdsCodex.Text.Length > 0 AndAlso Usuario.CodigoAutorizado = HddAdsCodex.Text) Then
|
||||
|
||||
CreaObjetoEmpresa(Usuario)
|
||||
@@ -265,7 +270,6 @@ Partial Class LogIn
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub CreaObjetoEmpresa(ByRef UsuarioActual As Usuario)
|
||||
|
||||
Dim ObjEmpresa As New ClsSisEmpresas()
|
||||
|
||||
@@ -319,6 +319,7 @@ public partial class Nomina_Nomina2 : ClsPaginas
|
||||
protected void DdlTipoPeriodo_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
cargaPeriodos();
|
||||
DdlEjercicios.AutoPostBack = true;
|
||||
}
|
||||
|
||||
protected void DdlPeriodo_SelectedIndexChanged(object sender, EventArgs e)
|
||||
@@ -3974,7 +3975,9 @@ public partial class Nomina_Nomina2 : ClsPaginas
|
||||
{
|
||||
|
||||
bool continuar = true;
|
||||
DataTable dtr = dtempleados.FiltraParametros(string.Format("(CvePersonal={0} OR {0}=-1) AND CvePersonal > 0 AND NomAutorizado =0", FiltroCvePersonal), "", new string[] { "CvePersonal", "CveMetodoPago" });
|
||||
string[] getcolumnas = new string[] { "CvePersonal", "CveMetodoPago", "SumaPercepciones", "Total", "SalarioDiario", "SalarioDiarioIMSS", "SalarioDiarioIntegrado", "DiasLaborados", "DiasFaltados", "DiasVacaciones", "DiasIncapacidad" };
|
||||
|
||||
DataTable dtr = dtempleados.FiltraParametros(string.Format("(CvePersonal={0} OR {0}=-1) AND CvePersonal > 0 AND NomAutorizado =0", FiltroCvePersonal), "", getcolumnas);
|
||||
DataTable dtconp = null;
|
||||
int CvePeriodoSeleccionado = DdlPeriodo.SelectedValue.ToEntero();//cambiar reparar
|
||||
#region PropNomina
|
||||
@@ -4003,7 +4006,6 @@ public partial class Nomina_Nomina2 : ClsPaginas
|
||||
Total = rtemp["Total"].ToString().ToDouble();
|
||||
if (CvePersonal > 0)
|
||||
{
|
||||
|
||||
if (continuar)
|
||||
{
|
||||
if (objNomina.GetNom_Nominas(-1, CvePersonal, CvePeriodoSeleccionado, -1, UsuarioActual.CveEmpresa))
|
||||
|
||||
@@ -943,17 +943,26 @@ Partial Class RH_Personal
|
||||
DdlClienteAsistenciaC.Attributes.Add("onclick", "CargaClientes();")
|
||||
DdlClienteAsistenciaA.Attributes.Add("onclick", "CargaClientes();")
|
||||
CargaClientes()
|
||||
|
||||
Dim fechainicioasistencia As String
|
||||
Dim fechaFinasistencia As String
|
||||
If Now.Day >= 15 Then
|
||||
fechainicioasistencia = String.Format("{0:01/MM/yyyy}", Now)
|
||||
fechaFinasistencia = String.Format("{0:15/MM/yyyy}", Now)
|
||||
Else
|
||||
Dim dateendasis As DateTime = String.Format("{0:01/MM/yyyy}", Now).ToDateTime().AddDays(-1)
|
||||
fechainicioasistencia = String.Format("{0:16/MM/yyyy}", dateendasis)
|
||||
fechaFinasistencia = String.Format("{0:dd/MM/yyyy}", dateendasis)
|
||||
End If
|
||||
If Request("FechaI") IsNot Nothing AndAlso IsDate(Request("FechaI")) Then
|
||||
txtFechaI.Text = Request("FechaI")
|
||||
Else
|
||||
txtFechaI.Text = Now.ToShortDateString
|
||||
txtFechaI.Text = fechainicioasistencia
|
||||
End If
|
||||
|
||||
If Request("FechaF") IsNot Nothing AndAlso IsDate(Request("FechaF")) Then
|
||||
txtFechaF.Text = Request("FechaF")
|
||||
Else
|
||||
txtFechaF.Text = Now.ToShortDateString
|
||||
txtFechaF.Text = fechaFinasistencia
|
||||
End If
|
||||
|
||||
If Request("CveSubProyecto") IsNot Nothing AndAlso IsNumeric(Request("CveSubProyecto")) Then
|
||||
@@ -3177,13 +3186,14 @@ Partial Class RH_Personal
|
||||
#End Region
|
||||
|
||||
|
||||
#Region "I M P R I M I R N O M I N A"
|
||||
#Region "I M P R I M I R N O M I N A"
|
||||
|
||||
Protected Sub LbPDF_Click(sender As Object, e As EventArgs)
|
||||
|
||||
Dim LB = CType(sender, LinkButton)
|
||||
|
||||
ImprimirbytesPDF(GeneraPDFNomina(CvePersonal, LB.CommandArgument.ToEntero, UsuarioActual.CveEmpresa, UsuarioActual.Empresa.Ruta), "Recibo")
|
||||
|
||||
Dim LB = CType(sender, LinkButton)
|
||||
ImprimirbytesPDF(GeneraPDFNomina(CvePersonal, LB.CommandArgument.ToEntero, UsuarioActual.CveEmpresa, UsuarioActual.Empresa.Ruta), "recibo")
|
||||
ImprimirbytesPDF(GeneraPDFNomina(CvePersonal, LB.CommandArgument.ToEntero, UsuarioActual.CveEmpresa, UsuarioActual.Empresa.Ruta), "recibo")
|
||||
|
||||
End Sub
|
||||
|
||||
#End Region
|
||||
|
||||
@@ -172,6 +172,8 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user