This commit is contained in:
2024-03-04 18:19:04 -07:00
6 changed files with 42 additions and 7 deletions

View File

@@ -180,7 +180,7 @@ Partial Class Contabilidad2_RepLibroDiario
lista.Add(New CrystalParametro("UsuarioImprimio", UsuarioActual.Nombre))
lista.Add(New CrystalParametro("LogoPath", If(Imagen.Exists, $"file://{Imagen.FullName}", "")))
ImprimirbytesPDF(ImprimirPDFCrystal(Server.MapPath("~/Empresas/Grales/Formatos/LibroDiario.rpt"), DtDatos, lista, "LibroDiario", Formato), "LibroDiario", Formato)
ImprimirbytesPDF(ImprimirPDFCrystal(DirectorioEmpresas + "\Grales\Formatos\LibroDiario.rpt", DtDatos, lista, "LibroDiario", Formato), "LibroDiario", Formato)
End Sub
#End Region
End Class

View File

@@ -2321,7 +2321,7 @@
<Paragraph>
<TextRuns>
<TextRun>
<Value>=Fields!Importe.Value</Value>
<Value>=IIf(Fields!Importe.Value = 0.01 ,0.00,Fields!Importe.Value)</Value>
<Style>
<FontFamily>Calibri</FontFamily>
<FontSize>9.64pt</FontSize>
@@ -4108,7 +4108,7 @@
</Border>
</Style>
</Body>
<Width>21.0638cm</Width>
<Width>21.06381cm</Width>
<Page>
<PageFooter>
<Height>0.5327cm</Height>

View File

@@ -1677,7 +1677,7 @@
<Paragraph>
<TextRuns>
<TextRun>
<Value>=Fields!Importe.Value</Value>
<Value>=IIf(Fields!Importe.Value = 0.01 ,0.00,Fields!Importe.Value)</Value>
<Style>
<FontFamily>Myriad Pro</FontFamily>
<FontSize>9.64pt</FontSize>

View File

@@ -359,7 +359,19 @@ Partial Class RH_RepChecadorPreAsistencia
FiltroSubProyecto = $" CveTipoPeriodo = {DdlTipoPeriodo.SelectedValue } {filtroturno} "
End If
DtPersonal = GlobalDTRHPersonal(UsuarioActual.Empresa.CveEmpresa).FiltraParametros(FiltroSubProyecto)
'DtPersonal = GlobalDTRHPersonal(UsuarioActual.Empresa.CveEmpresa).FiltraParametros(FiltroSubProyecto)
Dim DtTempPeriodo As DataTable = DTPeridos.FiltraParametros("CvePeriodo = " & DdlRango.SelectedValue.ToEntero)
Dim FechaInicioPeriodoFiltro = DtTempPeriodo(0)("FechaInicio").ToString().ToDate
Dim FilasFiltradas = From fila In GlobalDTRHPersonal(UsuarioActual.Empresa.CveEmpresa).FiltraParametros(FiltroSubProyecto).AsEnumerable()
Let Inicio = fila.Field(Of Date)("FechaInicio")
Let FechaFinOriginal = fila.Field(Of Date?)("FechaFin")
Let FechaFin = If(FechaFinOriginal.HasValue, FechaFinOriginal.Value, Now)
Where Inicio <= FechaInicioPeriodoFiltro AndAlso FechaInicioPeriodoFiltro <= FechaFin
Select fila
DtPersonal = FilasFiltradas.CopyToDataTable()
If objRH.ChecadorHorariosGet(-1, 1, UsuarioActual.Empresa.CveEmpresa) Then
DTHorarios = objRH.DtResultados
@@ -992,6 +1004,18 @@ Partial Class RH_RepChecadorPreAsistencia
DTAsistenciasInasistencias = objRH.DtResultados
End If
Dim DtTempPeriodo As DataTable = DTPeridos.FiltraParametros("CvePeriodo = " & DdlRango.SelectedValue.ToEntero)
Dim FechaInicioPeriodoFiltro = DtTempPeriodo(0)("FechaInicio").ToString().ToDate
Dim FilasFiltradas = From fila In GlobalDTRHPersonal(UsuarioActual.Empresa.CveEmpresa).FiltraParametros($" CveTipoPeriodo = { DdlTipoPeriodo.SelectedValue} AND CveEstado = 1 " & If(DdlTurno.SelectedValue = "-1", "", $" AND CveTurno = {DdlTurno.SelectedValue}")).AsEnumerable()
Let Inicio = fila.Field(Of Date)("FechaInicio")
Let FechaFinOriginal = fila.Field(Of Date?)("FechaFin")
Let FechaFin = If(FechaFinOriginal.HasValue, FechaFinOriginal.Value, Now)
Where Inicio <= FechaInicioPeriodoFiltro AndAlso FechaInicioPeriodoFiltro <= FechaFin
Select fila
'DtPersonal = FilasFiltradas.CopyToDataTable()
DtPersonal = GlobalDTRHPersonal(UsuarioActual.Empresa.CveEmpresa).FiltraParametros($" CveTipoPeriodo = { DdlTipoPeriodo.SelectedValue} AND CveEstado = 1 " & If(DdlTurno.SelectedValue = "-1", "", $" AND CveTurno = {DdlTurno.SelectedValue}"))
dt.Columns.Add("CvePersonal")

View File

@@ -1386,7 +1386,7 @@
<%--16--%>
<asp:TemplateField ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Literal ID="LtlTotal" runat="server" Text='<%# Eval("TotalImporte", "{0:#,##0.00##}") %>'></asp:Literal>
<asp:Literal ID="LtlTotal" runat="server" Text='<%# If(UsuarioActual.Empresa.Funcionalidad(109) = "1", Eval("TotalConImpuestos", "{0:#,##0.00##}"), Eval("TotalImporte", "{0:#,##0.00##}")) %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<%--17--%>

View File

@@ -8835,6 +8835,7 @@ Partial Class Ventas
TmpDT.Rows(e.RowIndex)("Descuento") = ObjDescuento.ImporteDescuento
TmpDT.Rows(e.RowIndex)("Total") = (Cantidad * PU)
TmpDT.Rows(e.RowIndex)("TotalImporte") = (Cantidad * PU).RoundSQL(NumeroDecimales)
TmpDT.Rows(e.RowIndex)("ImporteIVA") = (TmpDT.Rows(e.RowIndex)("PorcentajeIVA").ToString().ToDecimal * TotalCalculableImpuestosIVA).RoundSQL(NumeroDecimales)
TmpDT.Rows(e.RowIndex)("ImporteIEPS") = (TmpDT.Rows(e.RowIndex)("PorcentajeIEPS").ToString().ToDecimal * TotalCalculableImpuestos).RoundSQL(NumeroDecimales)
TmpDT.Rows(e.RowIndex)("ImporteRetIVA") = (ClienteRetIVA * TotalCalculableImpuestos).RoundSQL(NumeroDecimales)
@@ -8844,6 +8845,8 @@ Partial Class Ventas
TmpDT.Rows(e.RowIndex)("PorcentajeRetISR") = ClienteRetISR
TmpDT.Rows(e.RowIndex)("CuentaPredial") = CuentaPredial
TmpDT.Rows(e.RowIndex)("TotalConImpuestos") = (TmpDT.Rows(e.RowIndex)("Total").ToString().ToDecimal() - TmpDT.Rows(e.RowIndex)("Descuento").ToString().ToDecimal() + TmpDT.Rows(e.RowIndex)("ImporteIVA").ToString().ToDecimal()).RoundSQL(2)
Dim NumTurnos As Decimal = 0
If UsuarioActual.CveEmpresa.Contiene(7, 122) Then
NumTurnos = GvPS.Rows(e.RowIndex).FCTextBox("TxtNumTurnosEditar").Text.ToDecimal()
@@ -16647,6 +16650,7 @@ Partial Class Ventas
dr("ImporteRetISR") = (ClienteRetISR * TotalCalculableImpuestos).RoundSQL(NumeroDecimales)
dr("PorcentajeRetIVA") = ClienteRetIVA
dr("PorcentajeRetISR") = ClienteRetISR
dr("TotalConImpuestos") = (dr("Total").ToString().ToDecimal() - dr("Descuento").ToString().ToDecimal() + dr("ImporteIVA").ToString().ToDecimal()).RoundSQL(2)
Next
@@ -18945,6 +18949,8 @@ Partial Class Ventas
Row("CvePromocionDetalle") = CvePromocionDetalle
Row("Total") = (Cantidad * PU)
Row("TotalImporte") = (Cantidad * PU).RoundSQL(NumeroDecimales)
Row("TotalConImpuestos") = (Row("Total").ToString().ToDecimal() - Row("Descuento").ToString().ToDecimal() + Row("ImporteIVA").ToString().ToDecimal()).RoundSQL(2)
Row("SATClaveProdServ") = DrPS("SATClavePS")
Row("SATClaveUM") = DrPS("SATClaveUnidadMedida")
@@ -19113,6 +19119,7 @@ Partial Class Ventas
DrPoliza("TipoDescuento") = HdnTipoDescuento.Value
DrPoliza("Total") = (DrPoliza("Cantidad").ToString().ToDecimal * PU)
DrPoliza("TotalImporte") = (DrPoliza("Cantidad").ToString().ToDecimal * PU).RoundSQL(NumeroDecimales)
DrPoliza("TotalConImpuestos") = (DrPoliza("Total").ToString().ToDecimal() - DrPoliza("Descuento").ToString().ToDecimal() + DrPoliza("ImporteIVA").ToString().ToDecimal()).RoundSQL(2)
DrPoliza("SATClaveProdServ") = DrPSAdicional("SATClavePS")
DrPoliza("SATClaveUM") = DrPSAdicional("SATClaveUnidadMedida")
DrPoliza("CveActivoFijo") = -1
@@ -19250,6 +19257,8 @@ Partial Class Ventas
'USO PARA COMERCIO EXTERIOR
TmpDT.Columns.Add("CantidadConversion", GetType(Decimal))
TmpDT.Columns("CantidadConversion").DefaultValue = 0
TmpDT.Columns.Add("TotalConImpuestos", GetType(Decimal))
End Sub
Private Sub CreaDTmpC()
DTmpC = New DataTable
@@ -29765,7 +29774,7 @@ Partial Class Ventas
Row("Descuento") = Math.Round(Descuento, NumeroDecimales)
Row("Total") = Math.Round(Total, NumeroDecimales)
Row("TotalImporte") = Math.Round(Total, NumeroDecimales)
Row("TotalConImpuestos") = (Row("Total").ToString().ToDecimal() - Row("Descuento").ToString().ToDecimal() + Row("ImporteIVA").ToString().ToDecimal()).RoundSQL(2)
Row("Serie") = Serie
Row("TiempoEntrega") = TiempoEntrega
@@ -34733,6 +34742,7 @@ Partial Class Ventas
Row("Descuento") = Math.Round(Descuento, 2)
Row("Total") = Math.Round(Total, 2)
Row("TotalImporte") = Math.Round(Total, 2)
Row("TotalConImpuestos") = (Row("Total").ToString().ToDecimal() - Row("Descuento").ToString().ToDecimal() + Row("ImporteIVA").ToString().ToDecimal()).RoundSQL(2)
Row("Serie") = Serie
Row("TiempoEntrega") = TiempoEntrega
@@ -37472,6 +37482,7 @@ Partial Class Ventas
Row("Descuento") = (ObjDescuento.ImporteDescuento).RoundSQL(NumeroDecimales)
Row("Total") = (Cantidad * PU)
Row("TotalImporte") = (Cantidad * PU).RoundSQL(NumeroDecimales)
Row("TotalConImpuestos") = (Row("Total").ToString().ToDecimal() - Row("Descuento").ToString().ToDecimal() + Row("ImporteIVA").ToString().ToDecimal()).RoundSQL(2)
End If
Next