This commit is contained in:
2022-01-20 15:35:45 -07:00
11 changed files with 246 additions and 275 deletions

View File

@@ -5514,16 +5514,13 @@ Public Class ClsInventarios
#End Region #End Region
#Region "Camiones" #Region "Camiones"
Public Function GetCamiones(CveCamion As Integer, CveEmpresa As Integer, Optional CveTipoCamion As Integer = -1) As Boolean Public Function GetCamiones(CveCamion As Integer, CveEmpresa As Integer) As Boolean
Dim Retorno As Boolean = False Dim Retorno As Boolean = False
DataAdapter("PA_Inv_CamionesGet") DataAdapter("PA_Inv_CamionesGet")
With SqlAdapter.SelectCommand.Parameters With SqlAdapter.SelectCommand.Parameters
.Add("@CveCamion", SqlDbType.Int).Value = CveCamion .Add("@CveCamion", SqlDbType.Int).Value = CveCamion
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@CveTipoCamion", SqlDbType.Int).Value = CveTipoCamion
End With End With
Try Try
SqlAdapter.Fill(Data) SqlAdapter.Fill(Data)
@@ -5533,9 +5530,11 @@ Public Class ClsInventarios
End Try End Try
Return Retorno Return Retorno
End Function End Function
Public Function AddCamiones(Placa As String, Especificacion As String, CveEmpresa As Integer, ConfigCartaPorte As String, Anio As Integer, CveTipoPermisoSCT As Integer, NumPermisoSCT As String, NombreAseguradora As String, Public Function AddCamiones(Placa As String, Especificacion As String, CveEmpresa As Integer, ConfigCartaPorte As String, Anio As Integer, CveTipoPermisoSCT As Integer, NumPermisoSCT As String, NombreAseguradora As String,
NumPolizaSeguro As String, CveUsuario As Integer, NombreAseguradoraMedioAmbiente As String, NumPolizaSeguroMedioAmbiente As String, NombreAseguradoraCarga As String, NumPolizaSeguroCarga As String, NumPolizaSeguro As String, CveUsuario As Integer, NombreAseguradoraMedioAmbiente As String, NumPolizaSeguroMedioAmbiente As String, NombreAseguradoraCarga As String, NumPolizaSeguroCarga As String,
Optional CveTipoCamion As Integer = 1, Optional LongitudCaja As String = "", Optional LineaTransportacion As String = "", Optional SCAC As String = "", Optional CAAT As String = "", Optional CveTipoRemolque As Integer = -1) As Boolean Optional CveTipoCamion As Integer = 1, Optional LongitudCaja As String = "", Optional LineaTransportacion As String = "", Optional SCAC As String = "", Optional CAAT As String = "",
Optional CveTipoRemolque As Integer = -1, Optional NumeroTrailer As String = "") As Boolean
Dim Retorno As Boolean = False Dim Retorno As Boolean = False
DataAdapter("PA_Inv_CamionesAdd") DataAdapter("PA_Inv_CamionesAdd")
With SqlAdapter.SelectCommand.Parameters With SqlAdapter.SelectCommand.Parameters
@@ -5555,11 +5554,11 @@ Public Class ClsInventarios
.Add("@NumPolizaSeguroCarga", SqlDbType.VarChar).Value = NumPolizaSeguroCarga .Add("@NumPolizaSeguroCarga", SqlDbType.VarChar).Value = NumPolizaSeguroCarga
.Add("@CveTipoCamion", SqlDbType.Int).Value = CveTipoCamion .Add("@CveTipoCamion", SqlDbType.Int).Value = CveTipoCamion
.Add("@CveTipoRemolque", SqlDbType.Int).Value = CveTipoRemolque .Add("@CveTipoRemolque", SqlDbType.Int).Value = CveTipoRemolque
.Add("@LongitudCaja", SqlDbType.VarChar).Value = LongitudCaja .Add("@LongitudCaja", SqlDbType.VarChar).Value = LongitudCaja
.Add("@LineaTransportacion", SqlDbType.VarChar).Value = LineaTransportacion .Add("@LineaTransportacion", SqlDbType.VarChar).Value = LineaTransportacion
.Add("@SCAC", SqlDbType.VarChar).Value = SCAC .Add("@SCAC", SqlDbType.VarChar).Value = SCAC
.Add("@CAAT", SqlDbType.VarChar).Value = CAAT .Add("@CAAT", SqlDbType.VarChar).Value = CAAT
.Add("@NumeroTrailer", SqlDbType.VarChar).Value = NumeroTrailer
End With End With
Try Try
SqlAdapter.Fill(Data) SqlAdapter.Fill(Data)
@@ -5586,7 +5585,8 @@ Public Class ClsInventarios
End Function End Function
Public Function UpdateCamiones(CveCamion As Integer, Placa As String, Especificacion As String, ConfigCartaPorte As String, Anio As Integer, CveTipoPermisoSCT As Integer, NumPermisoSCT As String, NombreAseguradora As String, Public Function UpdateCamiones(CveCamion As Integer, Placa As String, Especificacion As String, ConfigCartaPorte As String, Anio As Integer, CveTipoPermisoSCT As Integer, NumPermisoSCT As String, NombreAseguradora As String,
NumPolizaSeguro As String, CveUsuario As Integer, CveEmpresa As Integer, NombreAseguradoraMedioAmbiente As String, NumPolizaSeguroMedioAmbiente As String, NombreAseguradoraCarga As String, NumPolizaSeguro As String, CveUsuario As Integer, CveEmpresa As Integer, NombreAseguradoraMedioAmbiente As String, NumPolizaSeguroMedioAmbiente As String, NombreAseguradoraCarga As String,
NumPolizaSeguroCarga As String, Optional CveTipoCamion As Integer = -1, Optional LongitudCaja As String = "", Optional LineaTransportacion As String = "", Optional SCAC As String = "", Optional CAAT As String = "", Optional CveTipoRemolque As Integer = -1) As Boolean NumPolizaSeguroCarga As String, Optional CveTipoCamion As Integer = -1, Optional LongitudCaja As String = "", Optional LineaTransportacion As String = "", Optional SCAC As String = "", Optional CAAT As String = "",
Optional CveTipoRemolque As Integer = -1, Optional NumeroTrailer As String = "") As Boolean
Dim Retorno As Boolean = False Dim Retorno As Boolean = False
DataAdapter("PA_Inv_CamionesUpdate") DataAdapter("PA_Inv_CamionesUpdate")
With SqlAdapter.SelectCommand.Parameters With SqlAdapter.SelectCommand.Parameters
@@ -5606,11 +5606,12 @@ Public Class ClsInventarios
.Add("@NombreAseguradoraCarga", SqlDbType.VarChar).Value = NombreAseguradoraCarga .Add("@NombreAseguradoraCarga", SqlDbType.VarChar).Value = NombreAseguradoraCarga
.Add("@NumPolizaSeguroCarga", SqlDbType.VarChar).Value = NumPolizaSeguroCarga .Add("@NumPolizaSeguroCarga", SqlDbType.VarChar).Value = NumPolizaSeguroCarga
.Add("@CveTipoCamion", SqlDbType.Int).Value = CveTipoCamion .Add("@CveTipoCamion", SqlDbType.Int).Value = CveTipoCamion
.Add("@CveTipoRemolque", SqlDbType.Int).Value = CveTipoRemolque
.Add("@LongitudCaja", SqlDbType.VarChar).Value = LongitudCaja .Add("@LongitudCaja", SqlDbType.VarChar).Value = LongitudCaja
.Add("@LineaTransportacion", SqlDbType.VarChar).Value = LineaTransportacion .Add("@LineaTransportacion", SqlDbType.VarChar).Value = LineaTransportacion
.Add("@SCAC", SqlDbType.VarChar).Value = SCAC .Add("@SCAC", SqlDbType.VarChar).Value = SCAC
.Add("@CAAT", SqlDbType.VarChar).Value = CAAT .Add("@CAAT", SqlDbType.VarChar).Value = CAAT
.Add("@CveTipoRemolque", SqlDbType.Int).Value = CveTipoRemolque .Add("@NumeroTrailer", SqlDbType.VarChar).Value = NumeroTrailer
End With End With
Try Try
SqlAdapter.Fill(Data) SqlAdapter.Fill(Data)
@@ -5622,103 +5623,6 @@ Public Class ClsInventarios
End Function End Function
#End Region #End Region
'#Region "Camiones"
' Public Function GetCamiones(CveCamion As Integer, CveEmpresa As Integer, Optional CveTipoCamion As Integer = -1) As Boolean
' Dim Retorno As Boolean = False
' DataAdapter("PA_Inv_CamionesGet")
' With SqlAdapter.SelectCommand.Parameters
' .Add("@CveCamion", SqlDbType.Int).Value = CveCamion
' .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
' .Add("@CveTipoCamion", SqlDbType.Int).Value = CveTipoCamion
' End With
' Try
' SqlAdapter.Fill(Data)
' Retorno = True
' Catch ex As Exception
' OnError("Ocurrió un error al momento de obtener el listado de camiones", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
' End Try
' Return Retorno
' End Function
' Public Function AddCamiones(Placa As String, Especificacion As String, CveEmpresa As Integer, ConfigCartaPorte As String, Anio As Integer, CveTipoPermisoSCT As Integer, NumPermisoSCT As String, NombreAseguradora As String,
' NumPolizaSeguro As String, CveUsuario As Integer, NombreAseguradoraMedioAmbiente As String, NumPolizaSeguroMedioAmbiente As String, NombreAseguradoraCarga As String, NumPolizaSeguroCarga As String, CveTipoCamion As Integer,
' CveTipoRemolque As Integer) As Boolean
' Dim Retorno As Boolean = False
' DataAdapter("PA_Inv_CamionesAdd")
' With SqlAdapter.SelectCommand.Parameters
' .Add("@Placa", SqlDbType.VarChar).Value = Placa
' .Add("@Especificacion", SqlDbType.VarChar).Value = Especificacion
' .Add("@ConfigCartaPorte", SqlDbType.VarChar).Value = ConfigCartaPorte
' .Add("@Anio", SqlDbType.Int).Value = Anio
' .Add("@CveTipoPermisoSCT", SqlDbType.VarChar).Value = CveTipoPermisoSCT
' .Add("@NumPermisoSCT", SqlDbType.VarChar).Value = NumPermisoSCT
' .Add("@NombreAseguradora", SqlDbType.VarChar).Value = NombreAseguradora
' .Add("@NumPolizaSeguro", SqlDbType.VarChar).Value = NumPolizaSeguro
' .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
' .Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
' .Add("@NombreAseguradoraMedioAmbiente", SqlDbType.VarChar).Value = NombreAseguradoraMedioAmbiente
' .Add("@NumPolizaSeguroMedioAmbiente", SqlDbType.VarChar).Value = NumPolizaSeguroMedioAmbiente
' .Add("@NombreAseguradoraCarga", SqlDbType.VarChar).Value = NombreAseguradoraCarga
' .Add("@NumPolizaSeguroCarga", SqlDbType.VarChar).Value = NumPolizaSeguroCarga
' .Add("@CveTipoCamion", SqlDbType.Int).Value = CveTipoCamion
' .Add("@CveTipoRemolque", SqlDbType.Int).Value = CveTipoRemolque
' End With
' Try
' SqlAdapter.Fill(Data)
' Retorno = True
' Catch ex As Exception
' OnError("Ocurrió un error al momento de insertar el nuevo camion", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
' End Try
' Return Retorno
' End Function
' Public Function RemoveCamiones(CveCamion As Integer, CveEmpresa As Integer) As Boolean
' Dim Retorno As Boolean = False
' DataAdapter("PA_Inv_CamionesRemove")
' With SqlAdapter.SelectCommand.Parameters
' .Add("@CveCamion", SqlDbType.Int).Value = CveCamion
' .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
' End With
' Try
' SqlAdapter.Fill(Data)
' Retorno = True
' Catch ex As Exception
' OnError("Ocurrió un error al momento de eliminar un camion", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
' End Try
' Return Retorno
' End Function
' Public Function UpdateCamiones(CveCamion As Integer, Placa As String, Especificacion As String, ConfigCartaPorte As String, Anio As Integer, CveTipoPermisoSCT As Integer, NumPermisoSCT As String, NombreAseguradora As String,
' NumPolizaSeguro As String, CveUsuario As Integer, CveEmpresa As Integer, NombreAseguradoraMedioAmbiente As String, NumPolizaSeguroMedioAmbiente As String, NombreAseguradoraCarga As String, NumPolizaSeguroCarga As String,
' CveTipoCamion As Integer, CveTipoRemolque As Integer) As Boolean
' Dim Retorno As Boolean = False
' DataAdapter("PA_Inv_CamionesUpdate")
' With SqlAdapter.SelectCommand.Parameters
' .Add("@CveCamion", SqlDbType.Int).Value = CveCamion
' .Add("@Placa", SqlDbType.VarChar).Value = Placa
' .Add("@Especificacion", SqlDbType.VarChar).Value = Especificacion
' .Add("@ConfigCartaPorte", SqlDbType.VarChar).Value = ConfigCartaPorte
' .Add("@Anio", SqlDbType.Int).Value = Anio
' .Add("@CveTipoPermisoSCT", SqlDbType.Int).Value = CveTipoPermisoSCT
' .Add("@NumPermisoSCT", SqlDbType.VarChar).Value = NumPermisoSCT
' .Add("@NombreAseguradora", SqlDbType.VarChar).Value = NombreAseguradora
' .Add("@NumPolizaSeguro", SqlDbType.VarChar).Value = NumPolizaSeguro
' .Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
' .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
' .Add("@NombreAseguradoraMedioAmbiente", SqlDbType.VarChar).Value = NombreAseguradoraMedioAmbiente
' .Add("@NumPolizaSeguroMedioAmbiente", SqlDbType.VarChar).Value = NumPolizaSeguroMedioAmbiente
' .Add("@NombreAseguradoraCarga", SqlDbType.VarChar).Value = NombreAseguradoraCarga
' .Add("@NumPolizaSeguroCarga", SqlDbType.VarChar).Value = NumPolizaSeguroCarga
' .Add("@CveTipoCamion", SqlDbType.Int).Value = CveTipoCamion
' .Add("@CveTipoRemolque", SqlDbType.Int).Value = CveTipoRemolque
' End With
' Try
' SqlAdapter.Fill(Data)
' Retorno = True
' Catch ex As Exception
' OnError("Ocurrió un error al momento de actualizar el camion", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
' End Try
' Return Retorno
' End Function
'#End Region
Public Function GetExistenciasMedRin(CvePS As Integer, CveEmpresa As Integer, CveRinTamaño As Integer, CveMedida As Integer) As Boolean Public Function GetExistenciasMedRin(CvePS As Integer, CveEmpresa As Integer, CveRinTamaño As Integer, CveMedida As Integer) As Boolean
Dim Retorno As Boolean = False Dim Retorno As Boolean = False
DataAdapter("PA_Inv_ExistenciaMedRinGet") DataAdapter("PA_Inv_ExistenciaMedRinGet")
@@ -5742,6 +5646,7 @@ Public Class ClsInventarios
Return Retorno Return Retorno
End Function End Function
'Public Function GetMovimientosDetalleTransitorio(CveMovimiento As Integer, CveEmpresa As Integer) As Boolean 'Public Function GetMovimientosDetalleTransitorio(CveMovimiento As Integer, CveEmpresa As Integer) As Boolean
' Dim Retorno As Boolean = False ' Dim Retorno As Boolean = False
' DataAdapter(" ' DataAdapter("

View File

@@ -174,13 +174,38 @@ Public Class ClsNominas
End Sub End Sub
#End Region #End Region
Public Function AutorizaCalculoAnual(CveEmpresa As Integer, CveUsuario As Integer, PersonalXml As String) As Boolean Public Function ManifiestoForVtaGet(CveEmpresa As Integer, CveUsuario As Integer, PersonalXml As String, CveEmbarqueManifiesto As Integer) As Boolean
Dim retorno As Boolean = False
DataAdapter("PA_Vta_ManifiestoForVtaGet", CommandType.StoredProcedure)
With SqlAdapter.SelectCommand.Parameters
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
.Add("@CveEmbarqueManifiesto", SqlDbType.Int).Value = CveEmbarqueManifiesto
End With
Try
SqlAdapter.Fill(DTSet)
If DTSet.Tables.Count > 0 Then
Data = DTSet.Tables(0)
End If
retorno = True
Catch Ex1 As SqlException
Me.OnError("Ocurrió un error al obtener datos manifiesto.", Ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
Catch ex As Exception
OnError("Ocurrió un error al obtener los datos manifiesto.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
End Try
Return retorno
End Function
Public Function AutorizaCalculoAnual(CveEmpresa As Integer, CveUsuario As Integer, PersonalXml As String, Optional Numpagos As Integer = 1) As Boolean
Dim retorno As Boolean = False Dim retorno As Boolean = False
DataAdapter("PA_Nom_AutorizaCalculoAnual", CommandType.StoredProcedure) DataAdapter("PA_Nom_AutorizaCalculoAnual", CommandType.StoredProcedure)
With SqlAdapter.SelectCommand.Parameters With SqlAdapter.SelectCommand.Parameters
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario .Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
.Add("@PersonalXml", SqlDbType.Xml).Value = If(String.IsNullOrEmpty(PersonalXml), DBNull.Value, DirectCast(PersonalXml, Object)) .Add("@PersonalXml", SqlDbType.Xml).Value = If(String.IsNullOrEmpty(PersonalXml), DBNull.Value, DirectCast(PersonalXml, Object))
.Add("@Numpagos", SqlDbType.Int).Value = Numpagos
End With End With
Try Try
SqlAdapter.Fill(Data) SqlAdapter.Fill(Data)

View File

@@ -30,6 +30,7 @@ public partial class CRM_AsignarVendedorEnProspectos : ClsPaginas
} }
ObjCRM.Dispose(); ObjCRM.Dispose();
GvProspectos.DataBind(); GvProspectos.DataBind();
UpDatos.Update();
} }
private void CargaFiltros() private void CargaFiltros()

View File

@@ -3989,7 +3989,7 @@ Partial Class Compras_Compras
Dim TotalRealDevolucion As Decimal = 0
Dim EstatusCredito As Integer = 0 Dim EstatusCredito As Integer = 0
Dim CveSubProyecto As Integer = 0 Dim CveSubProyecto As Integer = 0
@@ -4689,6 +4689,8 @@ Partial Class Compras_Compras
If DdlTipoComprobante.SelectedValue.Contiene("NC", "DEV") Then If DdlTipoComprobante.SelectedValue.Contiene("NC", "DEV") Then
Devolucion = guardardevolucion(ObjInventario, ObjCompras.CveCompra, TxtSubTotal.Text.ToDecimal, TxtFecha.Text.Trim.ToDate) Devolucion = guardardevolucion(ObjInventario, ObjCompras.CveCompra, TxtSubTotal.Text.ToDecimal, TxtFecha.Text.Trim.ToDate)
TotalRealDevolucion = Devolucion.Total
TieneError = Devolucion.TieneError TieneError = Devolucion.TieneError
End If End If
Dim ErrorDetalles As Boolean = False Dim ErrorDetalles As Boolean = False
@@ -6856,12 +6858,29 @@ Partial Class Compras_Compras
End If End If
Else Else
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, importeMovimiento, Referencia, ConceptoContabilizacionNC, Concepto, FechaMovimiento, IdCtaContable, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=importeMN, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), TipoCambio:=tipoCambioActual, CveMovimientoAlmacen:=CveMovimientoDevolucion, Contabilizable:=SeContabiliza) Then
Dim DiferenciaDevolucion As Decimal = importeMovimiento - TotalRealDevolucion
If Math.Abs(DiferenciaDevolucion) > 0 Then
Dim CveSubProyecto69 As Integer = TmpDT.FiltroPrimeroValor("CveSubProyecto", "CveSubProyecto > 0 ").ToEntero
Dim CveClasificacion69 As Integer = TmpDT.FiltroPrimeroValor("CveClasificacion", "CveClasificacion > 0 ").ToEntero
Dim IdCtaContable69 As Integer = GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltroPrimeroValor("IdCuentaCostos", $"CveClasificacion = {CveClasificacion69}").ToString.ToEntero
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, DiferenciaDevolucion, Referencia, 69, Concepto, FechaMovimiento, IdCtaContable69, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=importeMN, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), TipoCambio:=tipoCambioActual, CveMovimientoAlmacen:=CveMovimientoDevolucion, Contabilizable:=SeContabiliza, CveSubProyecto:=CveSubProyecto69, CveClasificacion:=CveClasificacion69) Then
ErrorPrepoliza = True
End If
End If
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, TotalRealDevolucion, Referencia, ConceptoContabilizacionNC, Concepto, FechaMovimiento, IdCtaContable, -1, CveCompra:=CveCompra, CveProveedor:=CveProveedorConcepto, ImporteMX:=TotalRealDevolucion, ImporteME:=If(tipoCambioActual = 1, 0, importeMovimiento), TipoCambio:=tipoCambioActual, CveMovimientoAlmacen:=CveMovimientoDevolucion, Contabilizable:=SeContabiliza) Then
ErrorPrepoliza = True ErrorPrepoliza = True
End If End If
End If End If
End If End If
@@ -14262,6 +14281,11 @@ Partial Class Compras_Compras
'*se envia true si hubo un error*' '*se envia true si hubo un error*'
Private Function guardardevolucion(ObjInventario As ClsInventarios, CveCompra As Integer, subtotal As Decimal, Fecha As Date) As MMensajeDevolucion Private Function guardardevolucion(ObjInventario As ClsInventarios, CveCompra As Integer, subtotal As Decimal, Fecha As Date) As MMensajeDevolucion
Dim TotalSumaPU As Decimal = 0.0D
Dim ErrorMovInv As Boolean = False Dim ErrorMovInv As Boolean = False
Dim CveAlmacen As Integer = DdlAlmacenDevolucion.SelectedValue.ToEntero() Dim CveAlmacen As Integer = DdlAlmacenDevolucion.SelectedValue.ToEntero()
Dim subtotaldevolucion As Double = 0 Dim subtotaldevolucion As Double = 0
@@ -14271,6 +14295,7 @@ Partial Class Compras_Compras
Dim cantidad As Double = 0.0 Dim cantidad As Double = 0.0
Dim TotalAlmacen As Decimal = 0 Dim TotalAlmacen As Decimal = 0
For Each Dr As GridViewRow In GVDevolucion.Rows For Each Dr As GridViewRow In GVDevolucion.Rows
'CveAlmacen = Dr.DataKey("CveAlmacen").ToString.ToEntero 'CveAlmacen = Dr.DataKey("CveAlmacen").ToString.ToEntero
cantidad = Dr.FCTextBox("TxtCantidad").Text.ToDouble cantidad = Dr.FCTextBox("TxtCantidad").Text.ToDouble
@@ -14309,6 +14334,7 @@ Partial Class Compras_Compras
PU = (((Dr.FCTextBox("TxtCantidad").Text.ToDecimal * Dr.DataKey("PU").ToString.ToDecimal)) + dif) / Dr.FCTextBox("TxtCantidad").Text.ToDecimal PU = (((Dr.FCTextBox("TxtCantidad").Text.ToDecimal * Dr.DataKey("PU").ToString.ToDecimal)) + dif) / Dr.FCTextBox("TxtCantidad").Text.ToDecimal
End If End If
If Not ObjInventario.AddMovimientoDetalle(CveMovimientoEntrada, Dr.FCTextBox("TxtCantidad").Text.ToDouble, Dr.DataKey("CveUM").ToString.ToEntero, Dr.DataKey("CvePS").ToString.ToEntero, PU, -1, CveMovimientoDetalleEntrada:=Dr.DataKey("CveMovimientoDetalle").ToString.ToEntero) Then If Not ObjInventario.AddMovimientoDetalle(CveMovimientoEntrada, Dr.FCTextBox("TxtCantidad").Text.ToDouble, Dr.DataKey("CveUM").ToString.ToEntero, Dr.DataKey("CvePS").ToString.ToEntero, PU, -1, CveMovimientoDetalleEntrada:=Dr.DataKey("CveMovimientoDetalle").ToString.ToEntero) Then
ErrorMovInv = True ErrorMovInv = True
Exit For Exit For
@@ -14323,12 +14349,26 @@ Partial Class Compras_Compras
End If End If
End If End If
If ObjInventario.GetMovimientosDetalle(CveMovimientoEntrada, UsuarioActual.CveEmpresa, -1, -1) Then
For Each drow As DataRow In ObjInventario.DtResultados.Rows
TotalSumaPU = TotalSumaPU + drow("Total").ToString.ToDecimal
Next
End If
Return New MMensajeDevolucion() With Return New MMensajeDevolucion() With
{ {
.CveMovimiento = CveMovimientoEntrada, .CveMovimiento = CveMovimientoEntrada,
.DebeRealizarDevolucion = realizadevolucion, .DebeRealizarDevolucion = realizadevolucion,
.TieneError = ErrorMovInv .TieneError = ErrorMovInv,
.Total = TotalSumaPU
} }
End Function End Function
Private Sub cargaddldevoluciones(CveProveedor As Integer, SubTotal As Double) Private Sub cargaddldevoluciones(CveProveedor As Integer, SubTotal As Double)
@@ -21032,4 +21072,5 @@ Public Class MMensajeDevolucion
Public Property CveMovimiento As Integer Public Property CveMovimiento As Integer
Public Property TieneError As Boolean Public Property TieneError As Boolean
Public Property DebeRealizarDevolucion As Boolean Public Property DebeRealizarDevolucion As Boolean
Public Property Total As Decimal
End Class End Class

View File

@@ -234,7 +234,7 @@ Partial Class PopUpVerFactura
Dim LineaTransportacion As String = "" Dim LineaTransportacion As String = ""
Dim SCAC As String = "" Dim SCAC As String = ""
Dim CAAT As String = "" Dim CAAT As String = ""
Dim NumeroTrailer As String = ""
Dim tablaReporte As New DataTable Dim tablaReporte As New DataTable
@@ -256,13 +256,13 @@ Partial Class PopUpVerFactura
Hora = String.Format("{0:hh }:{0:mm }:{0:ss tt}:", row("FechaIng")) Hora = String.Format("{0:hh }:{0:mm }:{0:ss tt}:", row("FechaIng"))
Chofer = row("Chofer").ToString() Chofer = row("Chofer").ToString()
CamPlaca = row("CamPlaca").ToString() CamPlaca = row("CamPlaca").ToString()
Camion = String.Format("{0} {1}", row("CamAnio"), row("CamEspecificacion")) Camion = String.Format("{0} {1}", row("CamEspecificacion"), row("CamAnio"))
Rem1Placa = row("Rem1Placa").ToString() Rem1Placa = row("Rem1Placa").ToString()
NoFactura = row("NoFactura").ToString() NoFactura = row("NoFactura").ToString()
Remolque1 = String.Format("{0} {1}", row("Rem1Anio"), row("Rem1Especificacion")) Remolque1 = String.Format("{0} ", row("Rem1Especificacion"), row("Rem1Anio"))
Mercado = If(row("AgenciaAduanalUSA").ToString() = "2", "Extranjero", "Nacional") Mercado = If(row("AgenciaAduanalUSA").ToString() = "2", "Extranjero", "Nacional")
NumeroTrailer = row("NumeroTrailer").ToString()
LongitudCaja = row("LongitudCaja").ToString() LongitudCaja = row("LongitudCaja").ToString()
LineaTransportacion = row("LineaTransportacion").ToString() LineaTransportacion = row("LineaTransportacion").ToString()
@@ -306,6 +306,8 @@ Partial Class PopUpVerFactura
params.Add(New ReportParameter("LineaTransportacion", LineaTransportacion)) params.Add(New ReportParameter("LineaTransportacion", LineaTransportacion))
params.Add(New ReportParameter("SCAC", SCAC)) params.Add(New ReportParameter("SCAC", SCAC))
params.Add(New ReportParameter("CAAT", CAAT)) params.Add(New ReportParameter("CAAT", CAAT))
params.Add(New ReportParameter("NumeroTrailer", NumeroTrailer))
params.Add(New ReportParameter("NoFactura", NoFactura)) params.Add(New ReportParameter("NoFactura", NoFactura))
params.Add(New ReportParameter("Mercado", Mercado)) params.Add(New ReportParameter("Mercado", Mercado))

View File

@@ -444,7 +444,9 @@
<TextRuns> <TextRuns>
<TextRun> <TextRun>
<Value>&lt;USDA REGISTRATION&gt;</Value> <Value>&lt;USDA REGISTRATION&gt;</Value>
<Style /> <Style>
<FontSize>9pt</FontSize>
</Style>
</TextRun> </TextRun>
</TextRuns> </TextRuns>
<Style> <Style>
@@ -3117,14 +3119,14 @@
</TablixCell> </TablixCell>
<TablixCell> <TablixCell>
<CellContents> <CellContents>
<Textbox Name="Textbox168"> <Textbox Name="Textbox3">
<CanGrow>true</CanGrow> <CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether> <KeepTogether>true</KeepTogether>
<Paragraphs> <Paragraphs>
<Paragraph> <Paragraph>
<TextRuns> <TextRuns>
<TextRun> <TextRun>
<Value>N° 03</Value> <Value>=Parameters!NumeroTrailer.Value</Value>
<Style> <Style>
<FontSize>8pt</FontSize> <FontSize>8pt</FontSize>
</Style> </Style>
@@ -3133,7 +3135,7 @@
<Style /> <Style />
</Paragraph> </Paragraph>
</Paragraphs> </Paragraphs>
<rd:DefaultName>Textbox168</rd:DefaultName> <rd:DefaultName>Textbox3</rd:DefaultName>
<Style> <Style>
<Border> <Border>
<Style>None</Style> <Style>None</Style>
@@ -3842,7 +3844,6 @@
</Style> </Style>
</Textbox> </Textbox>
<ColSpan>2</ColSpan> <ColSpan>2</ColSpan>
<rd:Selected>true</rd:Selected>
</CellContents> </CellContents>
</TablixCell> </TablixCell>
<TablixCell /> <TablixCell />
@@ -3934,7 +3935,7 @@
<Paragraph> <Paragraph>
<TextRuns> <TextRuns>
<TextRun> <TextRun>
<Value /> <Value>=Parameters!CAAT.Value</Value>
<Style> <Style>
<FontSize>8pt</FontSize> <FontSize>8pt</FontSize>
</Style> </Style>
@@ -3954,42 +3955,10 @@
<PaddingBottom>2pt</PaddingBottom> <PaddingBottom>2pt</PaddingBottom>
</Style> </Style>
</Textbox> </Textbox>
<ColSpan>3</ColSpan>
</CellContents> </CellContents>
</TablixCell> </TablixCell>
<TablixCell> <TablixCell />
<CellContents>
<Textbox Name="Textbox187">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>=Parameters!CAAT.Value</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox187</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<ColSpan>2</ColSpan>
</CellContents>
</TablixCell>
<TablixCell /> <TablixCell />
<TablixCell> <TablixCell>
<CellContents> <CellContents>
@@ -7472,6 +7441,12 @@
<AllowBlank>true</AllowBlank> <AllowBlank>true</AllowBlank>
<Prompt>ReportParameter1</Prompt> <Prompt>ReportParameter1</Prompt>
</ReportParameter> </ReportParameter>
<ReportParameter Name="NumeroTrailer">
<DataType>String</DataType>
<Nullable>true</Nullable>
<AllowBlank>true</AllowBlank>
<Prompt>ReportParameter1</Prompt>
</ReportParameter>
</ReportParameters> </ReportParameters>
<EmbeddedImages> <EmbeddedImages>
<EmbeddedImage Name="logojam"> <EmbeddedImage Name="logojam">

View File

@@ -1,49 +1,46 @@
<%@ Page Title="Catálogo de Unidades" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="CatUnidades.aspx.vb" Inherits="Inventarios_CatUnidades" EnableEventValidation="false" %> <%@ Page Title="Catálogo de Unidades" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="CatUnidades.aspx.vb" Inherits="Inventarios_CatUnidades" EnableEventValidation="false" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %> <%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<asp:Content ID="Content1" ContentPlaceHolderID="CP" Runat="Server"> <asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
</asp:Content> </asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="Css" Runat="Server"> <asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
<style> <style>
#DivAgregarUnidad > div.modal-dialog > div label input { #DivAgregarUnidad > div.modal-dialog > div label input {
padding:0px!important; padding: 0px !important;
} }
</style> </style>
</asp:Content> </asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="E" Runat="Server"> <asp:Content ID="Content3" ContentPlaceHolderID="E" runat="Server">
Catálogo de Unidades Catálogo de Unidades
</asp:Content> </asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="HB" Runat="Server"> <asp:Content ID="Content4" ContentPlaceHolderID="HB" runat="Server">
</asp:Content> </asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="H" Runat="Server"> <asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
<asp:UpdatePanel runat="server" ID="UpAgregar"> <asp:UpdatePanel runat="server" ID="UpAgregar">
<ContentTemplate> <ContentTemplate>
<li> <li>
<asp:LinkButton runat="server" ID="LnkAgregarUnidad" OnClick="LnkAgregarUnidad_Click" data-toggle="tooltip" data-placement="left" title="Agregar Unidad" Text="<i class='fa fa-plus'></i>Agregar Unidad"></asp:LinkButton> <asp:LinkButton runat="server" ID="LnkAgregarUnidad" OnClick="LnkAgregarUnidad_Click" data-toggle="tooltip" data-placement="left" title="Agregar Unidad" Text="<i class='fa fa-plus'></i>Agregar Unidad"></asp:LinkButton>
</li> </li>
</ContentTemplate> </ContentTemplate>
</asp:UpdatePanel> </asp:UpdatePanel>
</asp:Content> </asp:Content>
<asp:Content ID="Content6" ContentPlaceHolderID="HA" Runat="Server"> <asp:Content ID="Content6" ContentPlaceHolderID="HA" runat="Server">
</asp:Content> </asp:Content>
<asp:Content ID="Content7" ContentPlaceHolderID="C" Runat="Server"> <asp:Content ID="Content7" ContentPlaceHolderID="C" runat="Server">
<asp:UpdatePanel ID="UpDatos" runat="server" UpdateMode="Conditional"> <asp:UpdatePanel ID="UpDatos" runat="server" UpdateMode="Conditional">
<ContentTemplate> <ContentTemplate>
<asp:GridView ID="GvDatos" runat="server" AutoGenerateColumns="False" DataKeyNames="CveCamion,Placa,Especificacion,ConfigCartaPorte,Anio,CveTipoCamion,CveTipoPermisoSCT,NumPermisoSCT,NombreAseguradora,NumPolizaSeguro,NombreAseguradoraMedioAmbiente,NumPolizaSeguroMedioAmbiente,NombreAseguradoraCarga,NumPolizaSeguroCarga,LongitudCaja,LineaTransportacion,SCAC,CAAT,CveTipoRemolque" <asp:GridView ID="GvDatos" runat="server" AutoGenerateColumns="False" DataKeyNames="CveCamion,Placa,Especificacion,ConfigCartaPorte,Anio,CveTipoCamion,CveTipoPermisoSCT,NumPermisoSCT,NombreAseguradora,NumPolizaSeguro,NombreAseguradoraMedioAmbiente,NumPolizaSeguroMedioAmbiente,NombreAseguradoraCarga,NumPolizaSeguroCarga,LongitudCaja,LineaTransportacion,SCAC,CAAT,CveTipoRemolque,NumeroTrailer"
EmptyDataText="No se Encontraron Unidades" ToolTip="Listado de Unidades" CssClass="table table-striped table-advance table-hover mysmallbtn " data-sort="true" Style=" width: 100%" GridLines="None"> EmptyDataText="No se Encontraron Unidades" ToolTip="Listado de Unidades" CssClass="table table-striped table-advance table-hover mysmallbtn " data-sort="true" Style="width: 100%" GridLines="None">
<Columns> <Columns>
<asp:BoundField HeaderText="Unidad" DataField="Especificacion" ItemStyle-HorizontalAlign="Left" /> <asp:BoundField HeaderText="Unidad" DataField="Especificacion" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField HeaderText="Placa" DataField="Placa" ItemStyle-HorizontalAlign="Left" /> <asp:BoundField HeaderText="Placa" DataField="Placa" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField HeaderText="Config Carta Porte" DataField="ConfigCartaPorte" ItemStyle-HorizontalAlign="Left" /> <asp:BoundField HeaderText="Config Carta Porte" DataField="ConfigCartaPorte" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField HeaderText="Tipo Permiso SCT" DataField="ClaveTipoPermisoSCT" ItemStyle-HorizontalAlign="Left" /> <asp:BoundField HeaderText="Tipo Permiso SCT" DataField="ClaveTipoPermisoSCT" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField HeaderText="Permiso SCT" DataField="NumPermisoSCT" ItemStyle-HorizontalAlign="Left" /> <asp:BoundField HeaderText="Permiso SCT" DataField="NumPermisoSCT" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField HeaderText="Aseguradora" DataField="NombreAseguradora" ItemStyle-HorizontalAlign="Left" /> <asp:BoundField HeaderText="Aseguradora" DataField="NombreAseguradora" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField HeaderText="Póliza Seguro" DataField="NumPolizaSeguro" ItemStyle-HorizontalAlign="Left" /> <asp:BoundField HeaderText="Póliza Seguro" DataField="NumPolizaSeguro" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField HeaderText="Fecha de Ingreso" ItemStyle-HorizontalAlign="Center" DataField="FechaIng" ItemStyle-Width="5%" DataFormatString="{0:d}" /> <asp:BoundField HeaderText="Fecha de Ingreso" ItemStyle-HorizontalAlign="Center" DataField="FechaIng" ItemStyle-Width="5%" DataFormatString="{0:d}" />
<asp:BoundField HeaderText="Usuario" DataField="Usuario" /> <asp:BoundField HeaderText="Usuario" DataField="Usuario" />
@@ -57,7 +54,7 @@
</asp:GridView> </asp:GridView>
</ContentTemplate> </ContentTemplate>
</asp:UpdatePanel> </asp:UpdatePanel>
<div id="DivAgregarUnidad" class="modal ADS fade" role="dialog"> <div id="DivAgregarUnidad" class="modal ADS fade" role="dialog">
<div class="modal-dialog "> <div class="modal-dialog ">
@@ -71,34 +68,42 @@
<asp:Literal runat="server" ID="LtlTituloModal" Text="Agregar Unidad"></asp:Literal></h4> <asp:Literal runat="server" ID="LtlTituloModal" Text="Agregar Unidad"></asp:Literal></h4>
</div> </div>
<div class="modal-body"> <div class="modal-body">
<div class="row"> <div class="row">
<div class="form-group form-md-line-input input-iconright col-md-12">
<asp:TextBox ID="TxtEspecificacionNuevo" CssClass="form-control" runat="server" MaxLength="100"></asp:TextBox>
<label for="<%= TxtEspecificacionNuevo.ClientID.ToString()%>">Unidad:</label>
<asp:RequiredFieldValidator runat="server" ID="RfvTxtEspecificacionNuevo" ControlToValidate="TxtEspecificacionNuevo" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Especificación''</b> es necesario, por favor ingréselo." ValidationGroup="GrpUnidad"></asp:RequiredFieldValidator>
<i></i>
</div>
<div class="form-group form-md-line-input input-iconright col-md-12">
<div class="form-group form-md-line-input input-iconright col-md-12" runat="server" id="DVTiposRemolque" visible="false"> <asp:TextBox ID="TxtEspecificacionNuevo" CssClass="form-control" runat="server" MaxLength="100"></asp:TextBox>
<asp:DropDownList ID="DdlTiposRemolque" CssClass="form-control input-sm select2me" Width="100%" runat="server" AppendDataBoundItems="true" CausesValidation="true" DataTextField="TipoRemolqueCod" DataValueField="CveTipoRemolque" Style="padding: 0px" > <label for="<%= TxtEspecificacionNuevo.ClientID.ToString()%>">Unidad:</label>
</asp:DropDownList> <asp:RequiredFieldValidator runat="server" ID="RfvTxtEspecificacionNuevo" ControlToValidate="TxtEspecificacionNuevo" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Especificación''</b> es necesario, por favor ingréselo." ValidationGroup="GrpUnidad"></asp:RequiredFieldValidator>
<asp:RequiredFieldValidator ID="RfvDdlTiposRemolque" runat="server" ControlToValidate="DdlTiposRemolque" InitialValue="-1" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Tipo Remolque''</b> es necesario, por favor ingréselo." ValidationGroup="GrpUnidad"></asp:RequiredFieldValidator>
<label for="<%= DdlTiposRemolque.ClientID.ToString()%>">Tipo Remolque:</label>
<i></i> <i></i>
</div> </div>
<div class="col-md-12" runat="server" id="DVTiposRemolque" visible="false">
<div class="form-group form-md-line-input input-iconright ">
<asp:DropDownList ID="DdlTiposRemolque" CssClass="form-control input-sm select2me" Width="100%" runat="server" AppendDataBoundItems="true" CausesValidation="true" DataTextField="TipoRemolqueCod" DataValueField="CveTipoRemolque" Style="padding: 0px">
</asp:DropDownList>
<asp:RequiredFieldValidator ID="RfvDdlTiposRemolque" runat="server" ControlToValidate="DdlTiposRemolque" InitialValue="-1" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Tipo Remolque''</b> es necesario, por favor ingréselo." ValidationGroup="GrpUnidad"></asp:RequiredFieldValidator>
<label for="<%= DdlTiposRemolque.ClientID.ToString()%>">Tipo Remolque:</label>
<i></i>
</div>
</div>
<div class="form-group form-md-line-input input-iconright col-md-12">
<asp:TextBox ID="TxtNumeroTrailer" CssClass="form-control" runat="server" MaxLength="100"></asp:TextBox>
<asp:Label AssociatedControlID="TxtNumeroTrailer" runat="server" Text="NÚMERO DE TRAILER"></asp:Label>
<i></i>
</div>
<div class="form-group form-md-line-input input-iconright col-md-6"> <div class="form-group form-md-line-input input-iconright col-md-6">
<asp:TextBox ID="TxtPlacaNuevo" CssClass="form-control" runat="server" MaxLength="7"></asp:TextBox> <asp:TextBox ID="TxtPlacaNuevo" CssClass="form-control" runat="server" MaxLength="7"></asp:TextBox>
<label for="<%= TxtPlacaNuevo.ClientID.ToString()%>">Placa:</label> <label for="<%= TxtPlacaNuevo.ClientID.ToString()%>">Placa:</label>
<asp:RequiredFieldValidator runat="server" ID="RfvTxtPlacaNuevo" ControlToValidate="TxtPlacaNuevo" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Placa''</b> es necesario, por favor ingréselo." ValidationGroup="GrpUnidad"></asp:RequiredFieldValidator> <asp:RequiredFieldValidator runat="server" ID="RfvTxtPlacaNuevo" ControlToValidate="TxtPlacaNuevo" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Placa''</b> es necesario, por favor ingréselo." ValidationGroup="GrpUnidad"></asp:RequiredFieldValidator>
<asp:RegularExpressionValidator runat="server" ID="RevTxtPlacaNuevo" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Placa''</b> no contiene los caracteres suficientes." ControlToValidate="TxtPlacaNuevo" ValidationExpression="^.{6,8}$" ValidationGroup="GrpUnidad"></asp:RegularExpressionValidator> <asp:RegularExpressionValidator runat="server" ID="RevTxtPlacaNuevo" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Placa''</b> no contiene los caracteres suficientes." ControlToValidate="TxtPlacaNuevo" ValidationExpression="^.{6,8}$" ValidationGroup="GrpUnidad"></asp:RegularExpressionValidator>
<i></i> <i></i>
</div> </div>
<div class="form-group form-md-line-input input-iconright col-md-6" runat="server" id="DVAnio"> <div class="form-group form-md-line-input input-iconright col-md-6" runat="server" id="DVAnio">
<asp:TextBox ID="TxtAnio" CssClass="form-control" runat="server" MaxLength="4"></asp:TextBox> <asp:TextBox ID="TxtAnio" CssClass="form-control" runat="server" MaxLength="4"></asp:TextBox>
<label for="<%= TxtAnio.ClientID.ToString()%>">Año:</label> <label for="<%= TxtAnio.ClientID.ToString()%>">Año:</label>
<ajax:FilteredTextBoxExtender runat="server" TargetControlID="TxtAnio" FilterType="Custom" ValidChars="1234567890" /> <ajax:FilteredTextBoxExtender runat="server" TargetControlID="TxtAnio" FilterType="Custom" ValidChars="1234567890" />
@@ -110,8 +115,8 @@
</div> </div>
<div class="form-group form-md-line-input input-iconright" runat="server" id="DVConfigAuto"> <div class="form-group form-md-line-input input-iconright" runat="server" id="DVConfigAuto">
<asp:DropDownList ID="DdlConfigAuto" CssClass="form-control input-sm select2me" Width="100%" runat="server" AppendDataBoundItems="true" AutoPostBack="false" CausesValidation="true" DataTextField="ClaveConfigAutoTransporteDescripcion" DataValueField="ClaveConfigAutoTransporte" Style="padding: 0px"> <asp:DropDownList ID="DdlConfigAuto" CssClass="form-control input-sm select2me" Width="100%" runat="server" AppendDataBoundItems="true" AutoPostBack="false" CausesValidation="true" DataTextField="ClaveConfigAutoTransporteDescripcion" DataValueField="ClaveConfigAutoTransporte" Style="padding: 0px">
</asp:DropDownList> </asp:DropDownList>
<label for="<%= DdlConfigAuto.ClientID.ToString()%>">Configuración Carta Porte:</label> <label for="<%= DdlConfigAuto.ClientID.ToString()%>">Configuración Carta Porte:</label>
<asp:RequiredFieldValidator ID="RfvDdlConfigAuto" runat="server" ControlToValidate="DdlConfigAuto" InitialValue="-1" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Configuración Carta Porte''</b> es necesario, por favor ingréselo." ValidationGroup="GrpUnidad"></asp:RequiredFieldValidator> <asp:RequiredFieldValidator ID="RfvDdlConfigAuto" runat="server" ControlToValidate="DdlConfigAuto" InitialValue="-1" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Configuración Carta Porte''</b> es necesario, por favor ingréselo." ValidationGroup="GrpUnidad"></asp:RequiredFieldValidator>
@@ -120,7 +125,7 @@
<div class="form-group form-md-line-input input-iconright" runat="server" id="DVTipoPermisoSCT"> <div class="form-group form-md-line-input input-iconright" runat="server" id="DVTipoPermisoSCT">
<asp:DropDownList ID="DdlTipoPermisoSCT" CssClass="form-control input-sm select2me " Width="100%" runat="server" AppendDataBoundItems="true" AutoPostBack="false" CausesValidation="true" DataTextField="ClaveTipoPermisoDescripcion" DataValueField="CveTipoPermisoSCT" Style="padding: 0px"> <asp:DropDownList ID="DdlTipoPermisoSCT" CssClass="form-control input-sm select2me " Width="100%" runat="server" AppendDataBoundItems="true" AutoPostBack="false" CausesValidation="true" DataTextField="ClaveTipoPermisoDescripcion" DataValueField="CveTipoPermisoSCT" Style="padding: 0px">
</asp:DropDownList> </asp:DropDownList>
<label for="<%= DdlTipoPermisoSCT.ClientID.ToString()%>">Tipo Permiso SCT:</label> <label for="<%= DdlTipoPermisoSCT.ClientID.ToString()%>">Tipo Permiso SCT:</label>
@@ -128,10 +133,10 @@
<i></i> <i></i>
</div> </div>
<div class="row" runat="server" id="DVNumermisoSCT" > <div class="row" runat="server" id="DVNumermisoSCT">
<div class="col-md-12"> <div class="col-md-12">
<div class="form-group form-md-line-input input-iconright"> <div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtNumermisoSCT" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox> <asp:TextBox ID="TxtNumermisoSCT" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox>
<label for="<%= TxtNumermisoSCT.ClientID.ToString()%>">Número Permiso SCT:</label> <label for="<%= TxtNumermisoSCT.ClientID.ToString()%>">Número Permiso SCT:</label>
<%--<asp:RequiredFieldValidator runat="server" ID="RfvTxtNumermisoSCT" ControlToValidate="TxtNumermisoSCT" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Numero Permiso SCT''</b> es necesario, por favor ingréselo." ValidationGroup="GrpUnidad"></asp:RequiredFieldValidator>--%> <%--<asp:RequiredFieldValidator runat="server" ID="RfvTxtNumermisoSCT" ControlToValidate="TxtNumermisoSCT" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Numero Permiso SCT''</b> es necesario, por favor ingréselo." ValidationGroup="GrpUnidad"></asp:RequiredFieldValidator>--%>
@@ -140,7 +145,7 @@
</div> </div>
</div> </div>
<div class="row" runat="server" id="DVNombreAseguradora"> <div class="row" runat="server" id="DVNombreAseguradora">
<div class="col-md-6"> <div class="col-md-6">
<div class="form-group form-md-line-input input-iconright"> <div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtNombreAseguradora" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox> <asp:TextBox ID="TxtNombreAseguradora" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox>
@@ -159,85 +164,85 @@
</div> </div>
</div> </div>
<div class="row" runat="server" id="DVNombreAseguradoraMedioAmbiente"> <div class="row" runat="server" id="DVNombreAseguradoraMedioAmbiente">
<div class="col-md-6"> <div class="col-md-6">
<div class="form-group form-md-line-input input-iconright" > <div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtNombreAseguradoraMedioAmbiente" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox> <asp:TextBox ID="TxtNombreAseguradoraMedioAmbiente" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox>
<label for="<%= TxtNombreAseguradoraMedioAmbiente.ClientID.ToString()%>">Aseguradora Medio Ambiente:</label> <label for="<%= TxtNombreAseguradoraMedioAmbiente.ClientID.ToString()%>">Aseguradora Medio Ambiente:</label>
<asp:RequiredFieldValidator runat="server" ID="RequiredFieldValidator1" ControlToValidate="TxtNombreAseguradoraMedioAmbiente" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Aseguradora Medio Ambiente''</b> es necesario, por favor ingréselo." ValidationGroup="GrpUnidad"></asp:RequiredFieldValidator> <asp:RequiredFieldValidator runat="server" ID="RequiredFieldValidator1" ControlToValidate="TxtNombreAseguradoraMedioAmbiente" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Aseguradora Medio Ambiente''</b> es necesario, por favor ingréselo." ValidationGroup="GrpUnidad"></asp:RequiredFieldValidator>
<i></i> <i></i>
</div>
</div> </div>
</div> <div class="col-md-6">
<div class="col-md-6"> <div class="form-group form-md-line-input input-iconright">
<div class="form-group form-md-line-input input-iconright"> <asp:TextBox ID="TxtNumPolizaSeguroMedioAmbiente" CssClass="form-control" runat="server" MaxLength="25"></asp:TextBox>
<asp:TextBox ID="TxtNumPolizaSeguroMedioAmbiente" CssClass="form-control" runat="server" MaxLength="25"></asp:TextBox> <label for="<%= TxtNumPolizaSeguroMedioAmbiente.ClientID.ToString()%>">Número Póliza Medio Ambiente:</label>
<label for="<%= TxtNumPolizaSeguroMedioAmbiente.ClientID.ToString()%>">Número Póliza Medio Ambiente:</label> <asp:RequiredFieldValidator runat="server" ID="RequiredFieldValidator2" ControlToValidate="TxtNumPolizaSeguroMedioAmbiente" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Numero Póliza Medio Ambiente''</b> es necesario, por favor ingréselo." ValidationGroup="GrpUnidad"></asp:RequiredFieldValidator>
<asp:RequiredFieldValidator runat="server" ID="RequiredFieldValidator2" ControlToValidate="TxtNumPolizaSeguroMedioAmbiente" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Numero Póliza Medio Ambiente''</b> es necesario, por favor ingréselo." ValidationGroup="GrpUnidad"></asp:RequiredFieldValidator> <i></i>
<i></i> </div>
</div> </div>
</div>
</div> </div>
<div class="row" runat="server" id="DVNumPolizaSeguroMedioAmbient" > <div class="row" runat="server" id="DVNumPolizaSeguroMedioAmbient">
<div class="col-md-6"> <div class="col-md-6">
<div class="form-group form-md-line-input input-iconright"> <div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtNombreAseguradoraCarga" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox> <asp:TextBox ID="TxtNombreAseguradoraCarga" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox>
<label for="<%= TxtNombreAseguradoraCarga.ClientID.ToString()%>">Aseguradora Carga:</label> <label for="<%= TxtNombreAseguradoraCarga.ClientID.ToString()%>">Aseguradora Carga:</label>
<i></i> <i></i>
</div>
</div> </div>
</div> <div class="col-md-6">
<div class="col-md-6"> <div class="form-group form-md-line-input input-iconright">
<div class="form-group form-md-line-input input-iconright" > <asp:TextBox ID="TxtNumPolizaSeguroCarga" CssClass="form-control" runat="server" MaxLength="25"></asp:TextBox>
<asp:TextBox ID="TxtNumPolizaSeguroCarga" CssClass="form-control" runat="server" MaxLength="25"></asp:TextBox> <label for="<%= TxtNumPolizaSeguroCarga.ClientID.ToString()%>">Número Póliza Seguro:</label>
<label for="<%= TxtNumPolizaSeguroCarga.ClientID.ToString()%>">Número Póliza Seguro:</label> <i></i>
<i></i> </div>
</div> </div>
</div>
</div> </div>
<div class="row">
<div class="col-md-6">
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtLongitudCaja" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox>
<label for="<%= TxtLongitudCaja.ClientID.ToString()%>">Longitud de caja:</label>
<i></i>
</div>
</div>
<div class="col-md-6">
<div class="form-group form-md-line-input input-iconright" >
<asp:TextBox ID="TxtLineaTransportacion" CssClass="form-control" runat="server" MaxLength="25"></asp:TextBox>
<label for="<%= TxtLineaTransportacion.ClientID.ToString()%>">Linea de transportacion:</label>
<i></i>
</div>
</div>
</div>
<div class="row">
<div class="col-md-6">
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtSCAC" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox>
<label for="<%= TxtSCAC.ClientID.ToString()%>">SCAC:</label>
<i></i>
</div>
</div>
<div class="col-md-6">
<div class="form-group form-md-line-input input-iconright" >
<asp:TextBox ID="TxtCAAT" CssClass="form-control" runat="server" MaxLength="25"></asp:TextBox>
<label for="<%= TxtCAAT.ClientID.ToString()%>">CAAT:</label>
<i></i>
</div>
</div>
</div>
<asp:CheckBox ID="ChkesRemolque" Checked="true" TextAlign="Left" Text="¿Es remolque?:" runat="server" AutoPostBack="true" OnCheckedChanged="ChkesRemolque_CheckedChanged" /> <div class="row">
<div class="col-md-6" runat="server" id="DVLongitudCaja" visible="false">
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtLongitudCaja" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox>
<label for="<%= TxtLongitudCaja.ClientID.ToString()%>">Longitud de caja:</label>
<i></i>
</div>
</div>
<div class="col-md-6" runat="server" id="DVLineaTransportacion" visible="false">
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtLineaTransportacion" CssClass="form-control" runat="server" MaxLength="25"></asp:TextBox>
<label for="<%= TxtLineaTransportacion.ClientID.ToString()%>">Linea de transportacion:</label>
<i></i>
</div>
</div>
</div>
<div class="row" runat="server" id="DVSCACCAAT" visible="false">
<div class="col-md-6" >
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtSCAC" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox>
<label for="<%= TxtSCAC.ClientID.ToString()%>">SCAC:</label>
<i></i>
</div>
</div>
<div class="col-md-6">
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtCAAT" CssClass="form-control" runat="server" MaxLength="25"></asp:TextBox>
<label for="<%= TxtCAAT.ClientID.ToString()%>">CAAT:</label>
<i></i>
</div>
</div>
</div>
<asp:CheckBox ID="ChkesRemolque" Checked="true" TextAlign="Left" Text="¿Es remolque?:" runat="server" AutoPostBack="true" OnCheckedChanged="ChkesRemolque_CheckedChanged" />
</div> </div>
@@ -253,13 +258,13 @@
</div> </div>
</div> </div>
</asp:Content> </asp:Content>
<asp:Content ID="Content8" ContentPlaceHolderID="JS" Runat="Server"> <asp:Content ID="Content8" ContentPlaceHolderID="JS" runat="Server">
</asp:Content> </asp:Content>

View File

@@ -95,6 +95,7 @@ Partial Class Inventarios_CatUnidades
TxtNumPolizaSeguroCarga.Text = "" TxtNumPolizaSeguroCarga.Text = ""
TxtLongitudCaja.Text = "" TxtLongitudCaja.Text = ""
TxtLineaTransportacion.Text = "" TxtLineaTransportacion.Text = ""
TxtNumeroTrailer.Text = ""
TxtSCAC.Text = "" TxtSCAC.Text = ""
TxtCAAT.Text = "" TxtCAAT.Text = ""
ChkesRemolque.Checked = False ChkesRemolque.Checked = False
@@ -133,6 +134,7 @@ Partial Class Inventarios_CatUnidades
DdlTiposRemolque.SelectedValueExist(CveTipoRemolque) DdlTiposRemolque.SelectedValueExist(CveTipoRemolque)
TxtNumeroTrailer.Text = GvRow.DataKey("NumeroTrailer")
TxtLongitudCaja.Text = GvRow.DataKey("LongitudCaja") TxtLongitudCaja.Text = GvRow.DataKey("LongitudCaja")
TxtLineaTransportacion.Text = GvRow.DataKey("LineaTransportacion") TxtLineaTransportacion.Text = GvRow.DataKey("LineaTransportacion")
TxtSCAC.Text = GvRow.DataKey("SCAC") TxtSCAC.Text = GvRow.DataKey("SCAC")
@@ -187,15 +189,15 @@ Partial Class Inventarios_CatUnidades
Using ObjInventarios As New ClsInventarios Using ObjInventarios As New ClsInventarios
If CveCamion <= 0 Then If CveCamion <= 0 Then
If ObjInventarios.AddCamiones(TxtPlacaNuevo.Text, TxtEspecificacionNuevo.Text, UsuarioActual.CveEmpresa, DdlConfigAuto.SelectedValue, TxtAnio.Text.ToEntero(), DdlTipoPermisoSCT.SelectedValue.ToEntero, TxtNumermisoSCT.Text, TxtNombreAseguradora.Text, TxtNumPolizaSeguro.Text, UsuarioActual.CveUsuario, If ObjInventarios.AddCamiones(TxtPlacaNuevo.Text, TxtEspecificacionNuevo.Text, UsuarioActual.CveEmpresa, DdlConfigAuto.SelectedValue, TxtAnio.Text.ToEntero(), DdlTipoPermisoSCT.SelectedValue.ToEntero(), TxtNumermisoSCT.Text, TxtNombreAseguradora.Text, TxtNumPolizaSeguro.Text, UsuarioActual.CveUsuario,
TxtNombreAseguradoraMedioAmbiente.Text, TxtNumPolizaSeguroMedioAmbiente.Text, TxtNombreAseguradoraCarga.Text, TxtNumPolizaSeguroCarga.Text, CveTipoCamion, TxtLongitudCaja.Text, TxtLineaTransportacion.Text, TxtSCAC.Text, TxtCAAT.Text, DdlTiposRemolque.SelectedValue.ToEntero) Then TxtNombreAseguradoraMedioAmbiente.Text, TxtNumPolizaSeguroMedioAmbiente.Text, TxtNombreAseguradoraCarga.Text, TxtNumPolizaSeguroCarga.Text, CveTipoCamion, TxtLongitudCaja.Text, TxtLineaTransportacion.Text, TxtSCAC.Text, TxtCAAT.Text, DdlTiposRemolque.SelectedValue.ToEntero(), TxtNumeroTrailer.Text) Then
Alert("Unidad agregada correctamente") Alert("Unidad agregada correctamente")
Else Else
ErrorPrceso = True ErrorPrceso = True
End If End If
Else Else
If ObjInventarios.UpdateCamiones(CveCamion, TxtPlacaNuevo.Text, TxtEspecificacionNuevo.Text, DdlConfigAuto.SelectedValue, TxtAnio.Text.ToEntero(), DdlTipoPermisoSCT.SelectedValue.ToEntero, TxtNumermisoSCT.Text, TxtNombreAseguradora.Text, TxtNumPolizaSeguro.Text, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, If ObjInventarios.UpdateCamiones(CveCamion, TxtPlacaNuevo.Text, TxtEspecificacionNuevo.Text, DdlConfigAuto.SelectedValue, TxtAnio.Text.ToEntero(), DdlTipoPermisoSCT.SelectedValue.ToEntero(), TxtNumermisoSCT.Text, TxtNombreAseguradora.Text, TxtNumPolizaSeguro.Text, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa,
TxtNombreAseguradoraMedioAmbiente.Text, TxtNumPolizaSeguroMedioAmbiente.Text, TxtNombreAseguradoraCarga.Text, TxtNumPolizaSeguroCarga.Text, CveTipoCamion, TxtLongitudCaja.Text, TxtLineaTransportacion.Text, TxtSCAC.Text, TxtCAAT.Text, DdlTiposRemolque.SelectedValue.ToEntero) Then TxtNombreAseguradoraMedioAmbiente.Text, TxtNumPolizaSeguroMedioAmbiente.Text, TxtNombreAseguradoraCarga.Text, TxtNumPolizaSeguroCarga.Text, CveTipoCamion, TxtLongitudCaja.Text, TxtLineaTransportacion.Text, TxtSCAC.Text, TxtCAAT.Text, DdlTiposRemolque.SelectedValue.ToEntero(), TxtNumeroTrailer.Text) Then
Alert("Unidad actualizada correctamente") Alert("Unidad actualizada correctamente")
Else Else
ErrorPrceso = True ErrorPrceso = True
@@ -228,7 +230,11 @@ Partial Class Inventarios_CatUnidades
DVNombreAseguradoraMedioAmbiente.Visible = True DVNombreAseguradoraMedioAmbiente.Visible = True
DVNumPolizaSeguroMedioAmbient.Visible = True DVNumPolizaSeguroMedioAmbient.Visible = True
DVLineaTransportacion.Visible = True
DVSCACCAAT.Visible = True
DVTiposRemolque.Visible = False DVTiposRemolque.Visible = False
DVLongitudCaja.Visible = False
Else Else
DVAnio.Visible = False DVAnio.Visible = False
DVConfigAuto.Visible = False DVConfigAuto.Visible = False
@@ -238,7 +244,11 @@ Partial Class Inventarios_CatUnidades
DVNombreAseguradoraMedioAmbiente.Visible = False DVNombreAseguradoraMedioAmbiente.Visible = False
DVNumPolizaSeguroMedioAmbient.Visible = False DVNumPolizaSeguroMedioAmbient.Visible = False
DVLineaTransportacion.Visible = False
DVSCACCAAT.Visible = False
DVTiposRemolque.Visible = True DVTiposRemolque.Visible = True
DVLongitudCaja.Visible = True
End If End If

View File

@@ -251,6 +251,10 @@
<asp:Label runat="server" Text="Concepto a cargo:" AssociatedControlID=""></asp:Label> <asp:Label runat="server" Text="Concepto a cargo:" AssociatedControlID=""></asp:Label>
<asp:DropDownList ID="DdlConceptoCargo" runat="server" DataTextField="CodigoConcepto" DataValueField="CveConcepto" Class="form-control input-sm select2me" Width="100%" ValidationGroup="GrpGuardar"></asp:DropDownList> <asp:DropDownList ID="DdlConceptoCargo" runat="server" DataTextField="CodigoConcepto" DataValueField="CveConcepto" Class="form-control input-sm select2me" Width="100%" ValidationGroup="GrpGuardar"></asp:DropDownList>
</div> </div>
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtNumerodePagos" Text="1" type="number" min="1" CssClass="form-control" runat="server"></asp:TextBox>
<asp:Label runat="server" Text="Dividir en pagos:" AssociatedControlID="TxtNumerodePagos"></asp:Label>
</div>
<div class="form-group form-md-line-input input-iconright"> <div class="form-group form-md-line-input input-iconright">
<asp:Label runat="server" Text="Concepto a compensar:" AssociatedControlID=""></asp:Label> <asp:Label runat="server" Text="Concepto a compensar:" AssociatedControlID=""></asp:Label>
<asp:DropDownList ID="DdlConceptoCompensar" runat="server" DataTextField="CodigoConcepto" DataValueField="CveConcepto" Class="form-control input-sm select2me" Width="100%" ValidationGroup="GrpGuardar"></asp:DropDownList> <asp:DropDownList ID="DdlConceptoCompensar" runat="server" DataTextField="CodigoConcepto" DataValueField="CveConcepto" Class="form-control input-sm select2me" Width="100%" ValidationGroup="GrpGuardar"></asp:DropDownList>

View File

@@ -231,6 +231,7 @@ public partial class Nomina_CalculoISRAnual : ClsPaginas
protected void LnkAutoriza_Click(object sender, EventArgs e) protected void LnkAutoriza_Click(object sender, EventArgs e)
{ {
bool continuar = true; bool continuar = true;
int numpagos = TxtNumerodePagos.Text.ToEntero();
System.Xml.Linq.XDocument xmlarchivos = new System.Xml.Linq.XDocument(); System.Xml.Linq.XDocument xmlarchivos = new System.Xml.Linq.XDocument();
@@ -249,7 +250,7 @@ public partial class Nomina_CalculoISRAnual : ClsPaginas
using (ClsNominas onom = new ClsNominas()) using (ClsNominas onom = new ClsNominas())
{ {
continuar = onom.AutorizaCalculoAnual(UsuarioActual.CveEmpresa, UsuarioActual.CveUsuario, xmlpeople); continuar = onom.AutorizaCalculoAnual(UsuarioActual.CveEmpresa, UsuarioActual.CveUsuario, xmlpeople, numpagos);
} }
if (continuar) if (continuar)
{ {

View File

@@ -400,6 +400,8 @@