inventarios

This commit is contained in:
JORGE LUIS CAUDILLO ESPARZA
2023-07-11 08:30:39 -07:00
parent 37cf561234
commit bff887d808
2 changed files with 46 additions and 4 deletions

View File

@@ -3450,10 +3450,9 @@ Public Class ClsCGame
With SqlAdapter.SelectCommand.Parameters
.Add("@CveEmpresa", SqlDbType.Int).Value = cveEmpresa
.Add("@FechaCalculo", SqlDbType.Date).Value = fechaCalculo
.Add("@ErrorMostrarADS", SqlDbType.VarChar).Direction = ParameterDirection.Output
End With
Try
SqlAdapter.Fill(DTSet)
SqlAdapter.Fill(Data)
retorno = True
Catch ex As Exception
OnError("Ocurrió un error al obtener el reporte de inventario diario.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
@@ -3469,10 +3468,9 @@ Public Class ClsCGame
With SqlAdapter.SelectCommand.Parameters
.Add("@CveEmpresa", SqlDbType.Int).Value = cveEmpresa
.Add("@FechaCalculo", SqlDbType.Date).Value = fechaCalculo
.Add("@ErrorMostrarADS", SqlDbType.VarChar).Direction = ParameterDirection.Output
End With
Try
SqlAdapter.Fill(DTSet)
SqlAdapter.Fill(Data)
retorno = True
Catch ex As Exception
OnError("Ocurrió un error al obtener el reporte de inventario diario.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())

View File

@@ -229,6 +229,9 @@ Partial Class PopUpVerFactura
If Request("onlyPrint").ToString() = "Recibo" Then
ReciboAgropecuaria()
End If
If Request("onlyPrint").ToString() = "CitrusInventarioDiario" Then
imprimirRepcitrusInventarioDiario("")
End If
End If
End If
@@ -336,6 +339,47 @@ Partial Class PopUpVerFactura
Response.End()
End Sub
Private Sub imprimirRepcitrusInventarioDiario(fecha As String)
Dim totalPallets As String = ""
Dim totalBachas As String = ""
Dim fechas As String = ""
Dim totalcajas As String = ""
Dim tablaReportePallets As New DataTable
Dim tablaReporteBins As New DataTable
Using objnom As New ClsCGame
If objnom.REPInventarioDiarioPallets(DateTime.Now, UsuarioActual.CveEmpresa, "") And objnom.DtResultados.Rows.Count > 0 Then
tablaReportePallets = objnom.DtResultados
totalPallets = tablaReportePallets.SUM("Pallets", "GroupId =1").FormatoNumero(0)
totalBachas = tablaReportePallets.SUM("Bachas", "GroupId =1").FormatoNumero(0)
totalcajas = tablaReportePallets.SUM("CajasTotal", "GroupId =1").FormatoNumero(0)
End If
If objnom.REPInventarioDiarioBins(DateTime.Now, UsuarioActual.CveEmpresa, "") And objnom.DtResultados.Rows.Count > 0 Then
tablaReporteBins = objnom.DtResultados
End If
'Remolque 1 12-TF-5E' }, { cveCamion: 2, placa: 'Remolque 2 15-TF-7f
End Using
Dim params As New List(Of ReportParameter)
params.Add(New ReportParameter("totalPallets", totalPallets))
params.Add(New ReportParameter("totalBachas", totalBachas))
params.Add(New ReportParameter("totalcajas", totalcajas))
params.Add(New ReportParameter("Fecha", fechas))
Dim lrds As New List(Of ReportDataSource)
Dim rds As New ReportDataSource With {.Name = "DataSetsPallets", .Value = tablaReportePallets}
lrds.Add(rds)
Dim rds2 As New ReportDataSource With {.Name = "DataSetBins", .Value = tablaReporteBins}
lrds.Add(rds2)
'"D:\\ADSistemas\\Proyectos\\SIG\\SIGIT\\GPS\\PalletEtiqueta.rdlc"
Dim rutardlc = "Formatos\RepAgroInventarioDiario.rdlc"
ImprimirPDF(rutardlc, lrds, params, "Inventario") ', Content_Disposition:="Inline")
End Sub
Private Sub imprimirManifiesto(cveEmbarqueManifiesto As Integer)
Dim NoEmbarque As String = ""
Dim Fecha As String = ""