CarataPorte
This commit is contained in:
@@ -3426,6 +3426,19 @@ Public Class ClsGenerales
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
|
||||
Public Function GetCartaPorteTiposRemolques() As Boolean
|
||||
Dim Retorno As Boolean = False
|
||||
DataAdapter("PA_Gral_CP_TiposRemolqueGet")
|
||||
Try
|
||||
SqlAdapter.Fill(Data)
|
||||
Retorno = True
|
||||
Catch ex As Exception
|
||||
OnError("Ocurrió un error al obtener los tipos de remolque de carta porte.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||
End Try
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
@@ -3835,7 +3848,8 @@ Public Class ClsGenerales
|
||||
End Function
|
||||
|
||||
Public Function AddInvEntregaAlmacenRuta(CveSubProyecto As Integer, CveDireccionOrigen As Integer, CveDireccionDestino As Integer, CveMovimientoAlmacen As Integer, CveChofer As Integer, CveCamion As Integer, FechaEntrega As Date, FechaLlegada As DateTime, Tipo As String,
|
||||
FolioReferencia As String, Referencia As String, FechaLimite As Date, Orden As Integer, Estatus As Integer, Distancia As Integer) As Integer
|
||||
FolioReferencia As String, Referencia As String, FechaLimite As Date, Orden As Integer, Estatus As Integer, Distancia As Integer, Optional ConfigCartaPorte As String = "-1",
|
||||
Optional CveCamionRemolque1 As Integer = -1, Optional CveCamionRemolque2 As Integer = -1) As Integer
|
||||
Dim Retorno As Integer = -1
|
||||
DataAdapter("PA_Inv_EntregaAlmacenRutaAdd")
|
||||
|
||||
@@ -3858,7 +3872,9 @@ Public Class ClsGenerales
|
||||
|
||||
.Add("@FechaLimite", SqlDbType.DateTime).Value = FechaLimite
|
||||
|
||||
|
||||
.Add("@CveCamionRemolque1", SqlDbType.Int).Value = CveCamionRemolque1
|
||||
.Add("@CveCamionRemolque2", SqlDbType.Int).Value = CveCamionRemolque2
|
||||
.Add("@ConfigCartaPorte", SqlDbType.VarChar).Value = ConfigCartaPorte
|
||||
|
||||
.Add("@CveEntregaAlmacen", SqlDbType.Int).Direction = ParameterDirection.Output
|
||||
End With
|
||||
@@ -3872,7 +3888,9 @@ Public Class ClsGenerales
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
Public Function UpdateInvEntregaAlmacenRuta(CveEntregaAlmacen As Integer, CveDireccionOrigen As Integer, CveDireccionDestino As Integer, CveChofer As Integer, CveCamion As Integer, FechaEntrega As Date, CveEmpresa As Integer) As Boolean
|
||||
Public Function UpdateInvEntregaAlmacenRuta(CveEntregaAlmacen As Integer, CveDireccionOrigen As Integer, CveDireccionDestino As Integer, CveChofer As Integer, CveCamion As Integer, FechaEntrega As Date, CveEmpresa As Integer,
|
||||
Optional FechaLlegada As DateTime = MinFecha, Optional CveCamionRemolque1 As Integer = -1, Optional CveCamionRemolque2 As Integer = -1, Optional Distancia As Integer = -1,
|
||||
Optional ConfigCartaPorte As String = "-1") As Boolean
|
||||
Dim Retorno As Boolean = False
|
||||
DataAdapter("PA_Inv_EntregaAlmacenRutaUpdate")
|
||||
|
||||
@@ -3887,6 +3905,12 @@ Public Class ClsGenerales
|
||||
.Add("@FechaEntrega", SqlDbType.DateTime).Value = FechaEntrega
|
||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||
|
||||
.Add("@FechaLlegada", SqlDbType.DateTime).Value = FechaLlegada
|
||||
.Add("@CveCamionRemolque1", SqlDbType.Int).Value = CveCamionRemolque1
|
||||
.Add("@CveCamionRemolque2", SqlDbType.Int).Value = CveCamionRemolque2
|
||||
.Add("@Distancia", SqlDbType.Int).Value = Distancia
|
||||
.Add("@ConfigCartaPorte", SqlDbType.VarChar).Value = ConfigCartaPorte
|
||||
|
||||
End With
|
||||
|
||||
Try
|
||||
@@ -3969,7 +3993,7 @@ Public Class ClsGenerales
|
||||
End Function
|
||||
|
||||
|
||||
Public Function GetInvEntregaAlmacenRutaRep(CveSubProyecto As Integer, CveEmpresa As Integer, Estatus As Integer, FechaInicio As Date, FechaFin As Date, CveChofer As Integer) As Boolean
|
||||
Public Function GetInvEntregaAlmacenRutaRep(CveSubProyecto As Integer, CveEmpresa As Integer, Estatus As Integer, FechaInicio As Date, FechaFin As Date, CveChofer As Integer, Optional CveTimbre As Integer = -1) As Boolean
|
||||
|
||||
Dim Retorno As Boolean = False
|
||||
|
||||
@@ -3983,6 +4007,7 @@ Public Class ClsGenerales
|
||||
.Add("@FechaInicio", SqlDbType.Date).Value = FechaInicio
|
||||
.Add("@FechaFin", SqlDbType.Date).Value = FechaFin
|
||||
.Add("@CveChofer", SqlDbType.Int).Value = CveChofer
|
||||
.Add("@CveTimbre", SqlDbType.Int).Value = CveTimbre
|
||||
|
||||
End With
|
||||
|
||||
|
||||
@@ -5514,13 +5514,16 @@ Public Class ClsInventarios
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
|
||||
#Region "Camiones"
|
||||
Public Function GetCamiones(CveCamion As Integer, CveEmpresa As Integer) As Boolean
|
||||
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)
|
||||
@@ -5531,7 +5534,8 @@ Public Class ClsInventarios
|
||||
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) As Boolean
|
||||
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
|
||||
Dim Retorno As Boolean = False
|
||||
DataAdapter("PA_Inv_CamionesAdd")
|
||||
With SqlAdapter.SelectCommand.Parameters
|
||||
@@ -5549,6 +5553,13 @@ Public Class ClsInventarios
|
||||
.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
|
||||
|
||||
.Add("@LongitudCaja", SqlDbType.VarChar).Value = LongitudCaja
|
||||
.Add("@LineaTransportacion", SqlDbType.VarChar).Value = LineaTransportacion
|
||||
.Add("@SCAC", SqlDbType.VarChar).Value = SCAC
|
||||
.Add("@CAAT", SqlDbType.VarChar).Value = CAAT
|
||||
End With
|
||||
Try
|
||||
SqlAdapter.Fill(Data)
|
||||
@@ -5574,7 +5585,8 @@ Public Class ClsInventarios
|
||||
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) As Boolean
|
||||
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
|
||||
Dim Retorno As Boolean = False
|
||||
DataAdapter("PA_Inv_CamionesUpdate")
|
||||
With SqlAdapter.SelectCommand.Parameters
|
||||
@@ -5593,6 +5605,12 @@ Public Class ClsInventarios
|
||||
.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("@LongitudCaja", SqlDbType.VarChar).Value = LongitudCaja
|
||||
.Add("@LineaTransportacion", SqlDbType.VarChar).Value = LineaTransportacion
|
||||
.Add("@SCAC", SqlDbType.VarChar).Value = SCAC
|
||||
.Add("@CAAT", SqlDbType.VarChar).Value = CAAT
|
||||
.Add("@CveTipoRemolque", SqlDbType.Int).Value = CveTipoRemolque
|
||||
End With
|
||||
Try
|
||||
SqlAdapter.Fill(Data)
|
||||
@@ -5604,6 +5622,103 @@ Public Class ClsInventarios
|
||||
End Function
|
||||
#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
|
||||
Dim Retorno As Boolean = False
|
||||
DataAdapter("PA_Inv_ExistenciaMedRinGet")
|
||||
@@ -5627,7 +5742,6 @@ Public Class ClsInventarios
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
|
||||
'Public Function GetMovimientosDetalleTransitorio(CveMovimiento As Integer, CveEmpresa As Integer) As Boolean
|
||||
' Dim Retorno As Boolean = False
|
||||
' DataAdapter("
|
||||
|
||||
@@ -175,6 +175,17 @@ Public Class Timbres
|
||||
CartaPorte.FiguraTransporte.AutoTransporte.Vehiculo.AnioModeloVM = drT("Anio").ToString.ToEntero
|
||||
|
||||
|
||||
If drT("ClaveTipoRemolque1").ToString <> "" Then
|
||||
Dim Rem1 As New CFDICartaPorteRemolque With {.SubTipoRemolque = drT("ClaveTipoRemolque1"), .Placa = drT("PlacaRemolque1")}
|
||||
CartaPorte.FiguraTransporte.AutoTransporte.Remolques.Add(Rem1)
|
||||
End If
|
||||
|
||||
If drT("ClaveTipoRemolque2").ToString <> "" Then
|
||||
Dim Rem2 As New CFDICartaPorteRemolque With {.SubTipoRemolque = drT("ClaveTipoRemolque2"), .Placa = drT("PlacaRemolque2")}
|
||||
CartaPorte.FiguraTransporte.AutoTransporte.Remolques.Add(Rem2)
|
||||
End If
|
||||
|
||||
|
||||
Dim DomOrigen As CFDICartaPorteDomicilio = Nothing
|
||||
DomOrigen = New CFDICartaPorteDomicilio With {.Calle = drT("DirOriCalle").ToString,
|
||||
.Colonia = drT("DirOriClaveSATColonia").ToString,
|
||||
|
||||
@@ -8500,8 +8500,8 @@ Partial Class Compras_Compras
|
||||
Catch ex As Exception
|
||||
ObjCompras.RollBack()
|
||||
If ObjContaAC IsNot Nothing Then ObjContaAC.RollBack()
|
||||
Alert("Ocurrió un error al registrar la compra y cualquier detalle comuníquese a Soporte Técnico", TipoMensaje.MsgError)
|
||||
GuardaLog($"Ocurrió un error al registrar la compra y cualquier detalle comuníquese a Soporte Técnico : {ex}")
|
||||
Alert("Ocurrió un error al registrar la compra. Cualquier detalle comuníquese a Soporte Técnico", TipoMensaje.MsgError)
|
||||
GuardaLog($"Ocurrió un error al registrar la compra. Cualquier detalle comuníquese a Soporte Técnico : {ex}")
|
||||
ViewState("CveCompra") = -1
|
||||
End Try
|
||||
ObjAcar.Dispose()
|
||||
|
||||
@@ -1108,8 +1108,10 @@ Partial Class PopUpVerFactura
|
||||
Dim NombreAseguradoraCarga As String = ""
|
||||
Dim NumPolizaSeguroCarga As String = ""
|
||||
|
||||
|
||||
|
||||
Dim RemolquePlaca1 As String = ""
|
||||
Dim RemolquePlaca2 As String = ""
|
||||
Dim RemolqueSubtimo1 As String = ""
|
||||
Dim RemolqueSubtimo2 As String = ""
|
||||
|
||||
Dim PlacaVM As String = ""
|
||||
Dim AnioModeloVM As String = ""
|
||||
@@ -1158,6 +1160,9 @@ Partial Class PopUpVerFactura
|
||||
DtMercancias.Columns.Add(New DataColumn("Descripcion", GetType(String)))
|
||||
DtMercancias.Columns.Add(New DataColumn("PesoEnKg", GetType(String)))
|
||||
|
||||
DtMercancias.Columns.Add(New DataColumn("CveMaterialPeligroso", GetType(String)))
|
||||
DtMercancias.Columns.Add(New DataColumn("Embalaje", GetType(String)))
|
||||
|
||||
Dim DtOperadores As New DataTable()
|
||||
DtOperadores.Columns.Add(New DataColumn("RFC", GetType(String)))
|
||||
DtOperadores.Columns.Add(New DataColumn("NumLicencia", GetType(String)))
|
||||
@@ -1264,6 +1269,21 @@ Partial Class PopUpVerFactura
|
||||
NumPolizaSeguroCarga = ValorXML(nodeSeguros, "PolizaCarga", "")
|
||||
End If
|
||||
|
||||
|
||||
Dim nodeRemolques As XmlNode = nodeComp.SelectSingleNode(String.Format("//{0}:Remolques", "cartaporte20"), namespaces)
|
||||
|
||||
If nodeRemolques IsNot Nothing Then
|
||||
If nodeRemolques.ChildNodes.Count = 1 Then
|
||||
RemolquePlaca1 = ValorXML(nodeRemolques.ChildNodes(0), "Placa", "")
|
||||
RemolqueSubtimo1 = ValorXML(nodeRemolques.ChildNodes(0), "SubTipoRem", "")
|
||||
ElseIf nodeRemolques.ChildNodes.Count > 1 Then
|
||||
RemolquePlaca1 = ValorXML(nodeRemolques.ChildNodes(0), "Placa", "")
|
||||
RemolqueSubtimo1 = ValorXML(nodeRemolques.ChildNodes(0), "SubTipoRem", "")
|
||||
RemolquePlaca2 = ValorXML(nodeRemolques.ChildNodes(1), "Placa", "")
|
||||
RemolqueSubtimo2 = ValorXML(nodeRemolques.ChildNodes(1), "SubTipoRem", "")
|
||||
End If
|
||||
End If
|
||||
|
||||
'Dim nodeFiguraTransporte As XmlNode = nodeComp.SelectSingleNode(String.Format("//{0}:FiguraTransporte", "cartaporte20"), namespaces)
|
||||
'If nodeFiguraTransporte IsNot Nothing Then
|
||||
' Dim CveTransporte As String = ValorXML(nodeFiguraTransporte, "TipoFigura", "")
|
||||
@@ -1279,6 +1299,9 @@ Partial Class PopUpVerFactura
|
||||
Row("Descripcion") = ValorXML(node, "Descripcion", "")
|
||||
Row("PesoEnKg") = ValorXML(node, "PesoEnKg", "")
|
||||
|
||||
Row("CveMaterialPeligroso") = ValorXML(node, "CveMaterialPeligroso", "")
|
||||
Row("Embalaje") = ValorXML(node, "Embalaje", "")
|
||||
|
||||
DtMercancias.Rows.Add(Row)
|
||||
Next
|
||||
|
||||
@@ -1410,6 +1433,10 @@ Partial Class PopUpVerFactura
|
||||
params.Add(New ReportParameter("Descuentos", Descuentos.ToString()))
|
||||
params.Add(New ReportParameter("Total", Total.ToString()))
|
||||
|
||||
params.Add(New ReportParameter("RemolquePlaca1", RemolquePlaca1))
|
||||
params.Add(New ReportParameter("RemolqueSubtimo1", RemolqueSubtimo1))
|
||||
params.Add(New ReportParameter("RemolquePlaca2", RemolquePlaca2))
|
||||
params.Add(New ReportParameter("RemolqueSubtimo2", RemolqueSubtimo2))
|
||||
|
||||
|
||||
' [@CertificadoContribuyente]
|
||||
|
||||
@@ -242,39 +242,129 @@
|
||||
|
||||
<asp:UpdatePanel ID="UpPoliza" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="row" visible="false" runat="server" id="DivDatosPoliza">
|
||||
<label class="col-md-1">Tipo Póliza:</label>
|
||||
<div class="col-md-2">
|
||||
<asp:DropDownList ID="DdlTipoPoliza" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="true" Width="100%" ValidationGroup="GrpGuardar">
|
||||
<asp:ListItem Text="Ingreso" Value="1"></asp:ListItem>
|
||||
<asp:ListItem Text="Egreso" Value="2"></asp:ListItem>
|
||||
<asp:ListItem Text="Diario" Value="3"></asp:ListItem>
|
||||
</asp:DropDownList>
|
||||
</div>
|
||||
|
||||
<label class="col-md-1">Fecha:</label>
|
||||
<div class="col-md-2">
|
||||
<div class="input-group input-small date date-picker" data-date-format="dd/mm/yyyy">
|
||||
<asp:TextBox ID="TxtFechaDocumento" runat="server" CssClass="form-control"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton runat="server" ID="ImgCalendarioPoliza" class="btn default"><i class="fa fa-calendar"></i></asp:LinkButton>
|
||||
</span>
|
||||
|
||||
|
||||
<div class="col-md-6" style="margin-top: 20px;">
|
||||
<div class="portlet light bordered xspadding">
|
||||
<div class="portlet-title">
|
||||
<div class="caption font-green">
|
||||
<i class="fa fa-bookmark font-green"></i>
|
||||
<span class="caption-subject bold uppercase"></span>
|
||||
</div>
|
||||
<div class="actions">
|
||||
<div class="btn-group">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="portlet-body form">
|
||||
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox CssClass="form-control" ID="TxtFolio" runat="server" MaxLength="15" Enabled="false"></asp:TextBox>
|
||||
<label for="<%= TxtFolio.ClientID.ToString()%>">Folio: </label>
|
||||
</div>
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:DropDownList ID="DdlTipoPoliza" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="true" Width="100%" ValidationGroup="GrpGuardar">
|
||||
<asp:ListItem Text="Ingreso" Value="1"></asp:ListItem>
|
||||
<asp:ListItem Text="Egreso" Value="2"></asp:ListItem>
|
||||
<asp:ListItem Text="Diario" Value="3"></asp:ListItem>
|
||||
</asp:DropDownList>
|
||||
<label for="<%= DdlTipoPoliza.ClientID.ToString()%>">Tipo Póliza:</label>
|
||||
</div>
|
||||
|
||||
|
||||
<%--<div class="form-group form-md-line-input input-iconright">--%>
|
||||
|
||||
<div class="form-group form-md-line-input input-group input-small date date-picker" data-date-format="dd/mm/yyyy">
|
||||
<br />
|
||||
<asp:TextBox ID="TxtFechaDocumento" runat="server" CssClass="form-control" Width="100px"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton runat="server" ID="ImgCalendarioPoliza" class="btn default" style="margin-top:15px!important"><i class="fa fa-calendar"></i></asp:LinkButton>
|
||||
</span>
|
||||
<ajax:MaskedEditExtender ID="MaskedEditExtender1" runat="server" TargetControlID="TxtFechaDocumento" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender ID="CalendarExtender1" runat="server" TargetControlID="TxtFechaDocumento" PopupButtonID="ImgCalendarioPoliza" PopupPosition="Left" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:RequiredFieldValidator ID="RFVFechaPoliza" runat="server" ControlToValidate="TxtFechaDocumento" Display="None" ErrorMessage="El campo <b>''FechaDocumento''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
||||
<asp:CompareValidator ID="CVFechaPoliza" runat="server" ControlToValidate="TxtFechaDocumento" Display="None" ErrorMessage="El campo <b>''FechaDocumento''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrpGuardar"></asp:CompareValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender1" runat="server" HighlightCssClass="vco" TargetControlID="RFVFechaPoliza" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender2" runat="server" HighlightCssClass="vco" TargetControlID="CVFechaPoliza" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
<label for="<%= TxtFechaDocumento.ClientID.ToString()%>">Fecha:</label>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<%--</div>--%>
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox ID="TxtConcepto" runat="server" Width="100%" CssClass="form-control" Enabled="false"></asp:TextBox>
|
||||
<label for="<%= TxtConcepto.ClientID.ToString()%>">Concepto:</label>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<ajax:MaskedEditExtender ID="MaskedEditExtender1" runat="server" TargetControlID="TxtFechaDocumento" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender ID="CalendarExtender1" runat="server" TargetControlID="TxtFechaDocumento" PopupButtonID="ImgCalendarioPoliza" PopupPosition="Left" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:RequiredFieldValidator ID="RFVFechaPoliza" runat="server" ControlToValidate="TxtFechaDocumento" Display="None" ErrorMessage="El campo <b>''FechaDocumento''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
||||
<asp:CompareValidator ID="CVFechaPoliza" runat="server" ControlToValidate="TxtFechaDocumento" Display="None" ErrorMessage="El campo <b>''FechaDocumento''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrpGuardar"></asp:CompareValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender1" runat="server" HighlightCssClass="vco" TargetControlID="RFVFechaPoliza" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender2" runat="server" HighlightCssClass="vco" TargetControlID="CVFechaPoliza" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
|
||||
</div>
|
||||
|
||||
<label class="col-md-1">Concepto:</label>
|
||||
<div class="col-md-5">
|
||||
<asp:TextBox ID="TxtConcepto" runat="server" Width="100%" CssClass="form-control"></asp:TextBox>
|
||||
|
||||
<div class="col-md-6" style="margin-top: 20px;">
|
||||
<div class="portlet light bordered xspadding">
|
||||
<div class="portlet-title">
|
||||
<div class="caption font-green">
|
||||
<i class="fa fa-bookmark font-green"></i>
|
||||
<span class="caption-subject bold uppercase"></span>
|
||||
</div>
|
||||
<div class="actions">
|
||||
<div class="btn-group">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="portlet-body form">
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox CssClass="form-control" ID="TxtEstatus" runat="server" MaxLength="15" Enabled="false"></asp:TextBox>
|
||||
<label for="<%= TxtEstatus.ClientID.ToString()%>">Estatus: </label>
|
||||
</div>
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox CssClass="form-control" ID="TxtFechaelaboracion" runat="server" MaxLength="15" Enabled="false"></asp:TextBox>
|
||||
<label for="<%= TxtFechaelaboracion.ClientID.ToString()%>">Fecha Elaboracion: </label>
|
||||
</div>
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox CssClass="form-control" ID="TxtUsuarioElaboro" runat="server" MaxLength="15" Enabled="false"></asp:TextBox>
|
||||
<label for="<%= TxtUsuarioElaboro.ClientID.ToString()%>">Usuario Elaboro: </label>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<div class="row" visible="false" runat="server" id="divContabilizada">
|
||||
<label class="col-md-1">Contabilizada:</label>
|
||||
<div class="col-md-2">
|
||||
@@ -285,6 +375,7 @@
|
||||
<asp:Label ID="LblFolio" Font-Bold="true" Font-Size="Large" runat="server"></asp:Label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row" visible="false" runat="server" id="DivTipoGasto">
|
||||
<label class="col-md-1">Tipo Gasto:</label>
|
||||
<div class="col-md-2">
|
||||
@@ -292,6 +383,9 @@
|
||||
</asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
</td>
|
||||
|
||||
@@ -432,6 +432,12 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
TipoPoliza = DdlTipoPoliza.SelectedItem.Text
|
||||
Folio = dr("FolioPoliza").ToString
|
||||
|
||||
TxtFolio.Text = dr("FolioPoliza").ToString
|
||||
TxtUsuarioElaboro.Text = dr("Usuario").ToString
|
||||
TxtFechaelaboracion.Text = dr("FechaIng").ToString.ToDate.ToString("dd/MM/yyyy")
|
||||
TxtEstatus.Text = If(Boolean.Parse(dr("Estatus").ToString), "Activa", "Inactiva")
|
||||
|
||||
|
||||
If UsuarioActual.CveRol = 1 OrElse UsuarioActual.TienePermisoProceso(221) Then
|
||||
'DivAgregarConceptos.Visible = True
|
||||
LnkAddConcepto.Visible = True
|
||||
@@ -2341,18 +2347,27 @@ Partial Class ContabilidadC_RegPrePolizaS
|
||||
params.Add(New ReportParameter("TipoPoliza", dr("TipoPoliza").ToString))
|
||||
params.Add(New ReportParameter("Finicio", dr("Fecha").ToString.ToDate.ToShortDateString))
|
||||
params.Add(New ReportParameter("FFin", dr("Fecha").ToString.ToDate.ToShortDateString))
|
||||
params.Add(New ReportParameter("Fecha", dr("Fecha").ToString.ToDate.ToShortDateString))
|
||||
|
||||
If UsuarioActual.CveEmpresa.Contiene(141) Then
|
||||
params.Add(New ReportParameter("Fecha", dr("Fecha").ToString.ToDate.ToString("dd/MM/yyyy hh:mm:ss")))
|
||||
Else
|
||||
params.Add(New ReportParameter("Fecha", dr("Fecha").ToString.ToDate.ToShortDateString))
|
||||
End If
|
||||
|
||||
|
||||
'params.Add(New ReportParameter("Nombre", dr("Cuenta").ToString))
|
||||
'params.Add(New ReportParameter("Cuenta", dr("Codigo").ToString))
|
||||
params.Add(New ReportParameter("Numero", dr("FolioPoliza").ToString))
|
||||
params.Add(New ReportParameter("Moneda", ""))
|
||||
params.Add(New ReportParameter("CodigoPostal", ""))
|
||||
If UsuarioActual.CveEmpresa = 119 Then
|
||||
|
||||
If UsuarioActual.CveEmpresa.Contiene(119, 141) Then
|
||||
params.Add(New ReportParameter("UsuarioRegistro", GlobalDTUsuarios(dr("CveUsuario").ToString.ToEntero).FiltroPrimeroValor("Nombre")))
|
||||
End If
|
||||
If UsuarioActual.CveEmpresa = 140 Then
|
||||
If UsuarioActual.CveEmpresa.Contiene(140, 141) Then
|
||||
params.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre))
|
||||
End If
|
||||
|
||||
If Archivo.Exists Then
|
||||
ruta = UsuarioActual.Empresa.Ruta & "Formatos/Polizas.rdlc"
|
||||
Else
|
||||
|
||||
@@ -158,14 +158,14 @@
|
||||
</TablixCell>
|
||||
<TablixCell>
|
||||
<CellContents>
|
||||
<Textbox Name="CodigoMaterialPeligroso">
|
||||
<Textbox Name="CveMaterialPeligroso">
|
||||
<CanGrow>true</CanGrow>
|
||||
<KeepTogether>true</KeepTogether>
|
||||
<Paragraphs>
|
||||
<Paragraph>
|
||||
<TextRuns>
|
||||
<TextRun>
|
||||
<Value>=Fields!CodigoMaterialPeligroso.Value</Value>
|
||||
<Value>=Fields!CveMaterialPeligroso.Value</Value>
|
||||
<Style>
|
||||
<FontFamily>Myriad Pro</FontFamily>
|
||||
<FontSize>8pt</FontSize>
|
||||
@@ -177,7 +177,7 @@
|
||||
</Style>
|
||||
</Paragraph>
|
||||
</Paragraphs>
|
||||
<rd:DefaultName>CodigoMaterialPeligroso</rd:DefaultName>
|
||||
<rd:DefaultName>CveMaterialPeligroso</rd:DefaultName>
|
||||
<Style>
|
||||
<Border>
|
||||
<Color>#4f81bd</Color>
|
||||
@@ -687,9 +687,9 @@
|
||||
</Paragraph>
|
||||
</Paragraphs>
|
||||
<rd:DefaultName>Textbox3</rd:DefaultName>
|
||||
<Top>5.80407cm</Top>
|
||||
<Left>0.1841in</Left>
|
||||
<Height>0.5cm</Height>
|
||||
<Top>5.81465cm</Top>
|
||||
<Left>0.19973in</Left>
|
||||
<Height>0.50189cm</Height>
|
||||
<Width>7.52776in</Width>
|
||||
<ZIndex>2</ZIndex>
|
||||
<Style>
|
||||
@@ -1945,9 +1945,9 @@
|
||||
</Paragraph>
|
||||
</Paragraphs>
|
||||
<rd:DefaultName>Textbox2</rd:DefaultName>
|
||||
<Top>1.13111in</Top>
|
||||
<Top>1.09361in</Top>
|
||||
<Left>0.38395cm</Left>
|
||||
<Height>1.08451in</Height>
|
||||
<Height>0.95951in</Height>
|
||||
<Width>3.73231in</Width>
|
||||
<ZIndex>9</ZIndex>
|
||||
<Style>
|
||||
@@ -1955,9 +1955,6 @@
|
||||
<Color>#4f81bd</Color>
|
||||
<Style>Solid</Style>
|
||||
</Border>
|
||||
<RightBorder>
|
||||
<Style>None</Style>
|
||||
</RightBorder>
|
||||
<PaddingLeft>2pt</PaddingLeft>
|
||||
<PaddingRight>2pt</PaddingRight>
|
||||
<PaddingTop>2pt</PaddingTop>
|
||||
@@ -1985,7 +1982,7 @@
|
||||
</Paragraph>
|
||||
</Paragraphs>
|
||||
<rd:DefaultName>Textbox3</rd:DefaultName>
|
||||
<Top>2.33775cm</Top>
|
||||
<Top>2.27425cm</Top>
|
||||
<Left>0.15116in</Left>
|
||||
<Height>0.5cm</Height>
|
||||
<Width>7.5137in</Width>
|
||||
@@ -2159,9 +2156,9 @@
|
||||
</Paragraph>
|
||||
</Paragraphs>
|
||||
<rd:DefaultName>Textbox2</rd:DefaultName>
|
||||
<Top>1.13111in</Top>
|
||||
<Left>9.86403cm</Left>
|
||||
<Height>1.08451in</Height>
|
||||
<Top>1.09361in</Top>
|
||||
<Left>9.91989cm</Left>
|
||||
<Height>0.95951in</Height>
|
||||
<Width>3.78138in</Width>
|
||||
<ZIndex>11</ZIndex>
|
||||
<Style>
|
||||
@@ -2169,9 +2166,6 @@
|
||||
<Color>#4f81bd</Color>
|
||||
<Style>Solid</Style>
|
||||
</Border>
|
||||
<LeftBorder>
|
||||
<Style>None</Style>
|
||||
</LeftBorder>
|
||||
<PaddingLeft>2pt</PaddingLeft>
|
||||
<PaddingRight>2pt</PaddingRight>
|
||||
<PaddingTop>2pt</PaddingTop>
|
||||
@@ -3118,6 +3112,128 @@
|
||||
<PaddingBottom>2pt</PaddingBottom>
|
||||
</Style>
|
||||
</Textbox>
|
||||
<Textbox Name="Textbox38">
|
||||
<CanGrow>true</CanGrow>
|
||||
<KeepTogether>true</KeepTogether>
|
||||
<Paragraphs>
|
||||
<Paragraph>
|
||||
<TextRuns>
|
||||
<TextRun>
|
||||
<Value>Remolque 1</Value>
|
||||
<Style>
|
||||
<FontSize>8pt</FontSize>
|
||||
<FontWeight>Bold</FontWeight>
|
||||
</Style>
|
||||
</TextRun>
|
||||
<TextRun>
|
||||
<Value> Placa: </Value>
|
||||
<Style>
|
||||
<FontSize>8pt</FontSize>
|
||||
</Style>
|
||||
</TextRun>
|
||||
<TextRun>
|
||||
<Value>=Parameters!RemolquePlaca1.Value</Value>
|
||||
<Style>
|
||||
<FontSize>8pt</FontSize>
|
||||
</Style>
|
||||
</TextRun>
|
||||
<TextRun>
|
||||
<Value> Tipo Rem: </Value>
|
||||
<Style>
|
||||
<FontSize>8pt</FontSize>
|
||||
</Style>
|
||||
</TextRun>
|
||||
<TextRun>
|
||||
<Value>=Parameters!RemolqueSubtimo1.Value</Value>
|
||||
<Style>
|
||||
<FontSize>8pt</FontSize>
|
||||
</Style>
|
||||
</TextRun>
|
||||
</TextRuns>
|
||||
<Style />
|
||||
</Paragraph>
|
||||
</Paragraphs>
|
||||
<rd:DefaultName>Textbox38</rd:DefaultName>
|
||||
<Top>5.28548cm</Top>
|
||||
<Left>0.42248cm</Left>
|
||||
<Height>0.45862cm</Height>
|
||||
<Width>9.43197cm</Width>
|
||||
<ZIndex>22</ZIndex>
|
||||
<Visibility>
|
||||
<Hidden>= IIF( len(Parameters!RemolquePlaca1.Value) > 0,False, True)</Hidden>
|
||||
</Visibility>
|
||||
<Style>
|
||||
<Border>
|
||||
<Color>#4f81bd</Color>
|
||||
<Style>Solid</Style>
|
||||
</Border>
|
||||
<PaddingLeft>2pt</PaddingLeft>
|
||||
<PaddingRight>2pt</PaddingRight>
|
||||
<PaddingTop>2pt</PaddingTop>
|
||||
<PaddingBottom>2pt</PaddingBottom>
|
||||
</Style>
|
||||
</Textbox>
|
||||
<Textbox Name="Textbox44">
|
||||
<CanGrow>true</CanGrow>
|
||||
<KeepTogether>true</KeepTogether>
|
||||
<Paragraphs>
|
||||
<Paragraph>
|
||||
<TextRuns>
|
||||
<TextRun>
|
||||
<Value>Remolque 2</Value>
|
||||
<Style>
|
||||
<FontSize>8pt</FontSize>
|
||||
<FontWeight>Bold</FontWeight>
|
||||
</Style>
|
||||
</TextRun>
|
||||
<TextRun>
|
||||
<Value> Placa: </Value>
|
||||
<Style>
|
||||
<FontSize>8pt</FontSize>
|
||||
</Style>
|
||||
</TextRun>
|
||||
<TextRun>
|
||||
<Value>=Parameters!RemolquePlaca2.Value</Value>
|
||||
<Style>
|
||||
<FontSize>8pt</FontSize>
|
||||
</Style>
|
||||
</TextRun>
|
||||
<TextRun>
|
||||
<Value> Tipo Rem: </Value>
|
||||
<Style>
|
||||
<FontSize>8pt</FontSize>
|
||||
</Style>
|
||||
</TextRun>
|
||||
<TextRun>
|
||||
<Value>=Parameters!RemolqueSubtimo2.Value</Value>
|
||||
<Style>
|
||||
<FontSize>8pt</FontSize>
|
||||
</Style>
|
||||
</TextRun>
|
||||
</TextRuns>
|
||||
<Style />
|
||||
</Paragraph>
|
||||
</Paragraphs>
|
||||
<rd:DefaultName>Textbox38</rd:DefaultName>
|
||||
<Top>5.28548cm</Top>
|
||||
<Left>9.94339cm</Left>
|
||||
<Height>0.45862cm</Height>
|
||||
<Width>9.5996cm</Width>
|
||||
<ZIndex>23</ZIndex>
|
||||
<Visibility>
|
||||
<Hidden>= IIF( len(Parameters!RemolquePlaca2.Value) > 0,False, True)</Hidden>
|
||||
</Visibility>
|
||||
<Style>
|
||||
<Border>
|
||||
<Color>#4f81bd</Color>
|
||||
<Style>Solid</Style>
|
||||
</Border>
|
||||
<PaddingLeft>2pt</PaddingLeft>
|
||||
<PaddingRight>2pt</PaddingRight>
|
||||
<PaddingTop>2pt</PaddingTop>
|
||||
<PaddingBottom>2pt</PaddingBottom>
|
||||
</Style>
|
||||
</Textbox>
|
||||
</ReportItems>
|
||||
<Height>7.34222in</Height>
|
||||
<Style />
|
||||
@@ -3701,8 +3817,8 @@
|
||||
<DataField>PesoEnKg</DataField>
|
||||
<rd:TypeName>System.String</rd:TypeName>
|
||||
</Field>
|
||||
<Field Name="CodigoMaterialPeligroso">
|
||||
<DataField>CodigoMaterialPeligroso</DataField>
|
||||
<Field Name="CveMaterialPeligroso">
|
||||
<DataField>CveMaterialPeligroso</DataField>
|
||||
<rd:TypeName>System.String</rd:TypeName>
|
||||
</Field>
|
||||
<Field Name="Embalaje">
|
||||
@@ -3974,6 +4090,30 @@
|
||||
<AllowBlank>true</AllowBlank>
|
||||
<Prompt>ReportParameter1</Prompt>
|
||||
</ReportParameter>
|
||||
<ReportParameter Name="RemolquePlaca1">
|
||||
<DataType>String</DataType>
|
||||
<Nullable>true</Nullable>
|
||||
<AllowBlank>true</AllowBlank>
|
||||
<Prompt>ReportParameter1</Prompt>
|
||||
</ReportParameter>
|
||||
<ReportParameter Name="RemolqueSubtimo1">
|
||||
<DataType>String</DataType>
|
||||
<Nullable>true</Nullable>
|
||||
<AllowBlank>true</AllowBlank>
|
||||
<Prompt>ReportParameter1</Prompt>
|
||||
</ReportParameter>
|
||||
<ReportParameter Name="RemolquePlaca2">
|
||||
<DataType>String</DataType>
|
||||
<Nullable>true</Nullable>
|
||||
<AllowBlank>true</AllowBlank>
|
||||
<Prompt>ReportParameter1</Prompt>
|
||||
</ReportParameter>
|
||||
<ReportParameter Name="RemolqueSubtimo2">
|
||||
<DataType>String</DataType>
|
||||
<Nullable>true</Nullable>
|
||||
<AllowBlank>true</AllowBlank>
|
||||
<Prompt>ReportParameter1</Prompt>
|
||||
</ReportParameter>
|
||||
</ReportParameters>
|
||||
<Language>es-MX</Language>
|
||||
<rd:ReportUnitType>Cm</rd:ReportUnitType>
|
||||
|
||||
Binary file not shown.
@@ -226,11 +226,41 @@
|
||||
<div class="row rowpadding">
|
||||
<label class="col-md-3">Unidad:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList runat="server" ID="DdlUnidadCamion" AutoPostBack="true" Width="100%" AppendDataBoundItems="true" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca"></asp:DropDownList>
|
||||
<asp:DropDownList runat="server" ID="DdlUnidadCamion" AutoPostBack="true" Width="100%" AppendDataBoundItems="true" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca" OnSelectedIndexChanged="DdlUnidadCamionActivoFijo_SelectedIndexChanged" ></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlUnidadCamion" runat="server" Enabled="false" ControlToValidate="DdlUnidadCamion" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Unidad''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VceDdlUnidadCamion" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlUnidadCamion" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row rowpadding" runat="server" id="DvConfiguracionVeiculo" visible="false">
|
||||
<label class="col-md-3">Configuración:</label>
|
||||
<div class="col-md-9">
|
||||
<%--<asp:DropDownList runat="server" ID="DropDownList1" AutoPostBack="true" Width="100%" AppendDataBoundItems="true" CssClass="form-control input-sm select2me" DataValueField="CveActivoFijo" DataTextField="CodigoDescripcion"></asp:DropDownList>--%>
|
||||
<asp:DropDownList ID="DdlConfigAuto" CssClass="form-control input-sm select2me" Width="100%" runat="server" AppendDataBoundItems="true" AutoPostBack="true" OnSelectedIndexChanged="DdlConfigAuto_SelectedIndexChanged" CausesValidation="true" DataTextField="ClaveConfigAutoTransporteDescripcion" DataValueField="ClaveConfigAutoTransporte" Style="padding: 0px">
|
||||
</asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlConfigAuto" runat="server" Enabled="false" ControlToValidate="DdlConfigAuto" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Configuración Carta Porte''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCERfvDdlConfigAuto" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlConfigAuto" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row rowpadding" runat="server" id="DvRemolque1" visible="false">
|
||||
<label class="col-md-3">Remolque 1:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList runat="server" ID="DdlRemolque1" AutoPostBack="true" Width="100%" AppendDataBoundItems="true" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca" OnSelectedIndexChanged="DdlRemolque1_SelectedIndexChanged"></asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row rowpadding" runat="server" id="DvRemolque2" visible="false">
|
||||
<label class="col-md-3">Remolque 2:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList runat="server" ID="DdlRemolque2" AutoPostBack="true" Width="100%" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca" ></asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="row rowpadding">
|
||||
<%--<label class="col-md-3">F. Salida:</label>
|
||||
<div class="col-md-9" style="padding-top: 0px;">
|
||||
@@ -730,7 +760,7 @@
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:DropDownList runat="server" ID="DdlDirClienteLocalidad" CssClass="form-control select2me" DataValueField="CveLocalidad" DataTextField="NombreLocalidad" Width="100%" CausesValidation="true"></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlDirClienteLocalidad" InitialValue="-1" runat="server" CssClass="help-block errorimput" ControlToValidate="DdlDirClienteLocalidad" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Localidad''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>
|
||||
<%--<asp:RequiredFieldValidator ID="RfvDdlDirClienteLocalidad" InitialValue="-1" runat="server" CssClass="help-block errorimput" ControlToValidate="DdlDirClienteLocalidad" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Localidad''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>--%>
|
||||
<label for="<%= DdlDirClienteLocalidad.ClientID.ToString()%>">Localidad:</label>
|
||||
<i></i>
|
||||
</div>
|
||||
|
||||
@@ -362,7 +362,7 @@ Partial Class Inventarios_CartaPorteManual
|
||||
|
||||
DrPS = GlobalDTPS(UsuarioActual.CveEmpresa, CvePS:=CveProducto).FiltroPrimero("") ' Estado = -1
|
||||
|
||||
If DrPS IsNot Nothing Then
|
||||
If DrPS IsNot Nothing AndAlso ValidaPSSAT(DrPS) Then
|
||||
|
||||
'codigo temporal
|
||||
Dim tLote As String
|
||||
@@ -561,7 +561,8 @@ Partial Class Inventarios_CartaPorteManual
|
||||
|
||||
Dim FechallegadaMM As DateTime = (FechaLlegada.ToString("dd/MM/yyyy") & " 23:59:59").ToDateTime
|
||||
|
||||
Dim CveEntregaAlmacen As Integer = ObjGral.AddInvEntregaAlmacenRuta(DdlSubProyecto.SelectedValue.ToEntero, CveDireccionOrigen, CveDireccionDestino, -1, DdlChofer.SelectedValue.ToEntero, DdlUnidadCamion.SelectedValue.ToEntero, FechaSalida, FechallegadaMM, "T", "-1", "-1", FechaLlegada, 1, 1, TxtDistancia.Text.ToEntero)
|
||||
Dim CveEntregaAlmacen As Integer = ObjGral.AddInvEntregaAlmacenRuta(DdlSubProyecto.SelectedValue.ToEntero, CveDireccionOrigen, CveDireccionDestino, -1, DdlChofer.SelectedValue.ToEntero, DdlUnidadCamion.SelectedValue.ToEntero, FechaSalida, FechallegadaMM, "T", "-1", "-1", FechaLlegada, 1, 1, TxtDistancia.Text.ToEntero,
|
||||
ConfigCartaPorte:=DdlConfigAuto.SelectedValue, CveCamionRemolque1:=DdlRemolque1.SelectedValue.ToEntero, CveCamionRemolque2:=DdlRemolque2.SelectedValue.ToEntero)
|
||||
|
||||
If CveEntregaAlmacen > 0 Then
|
||||
|
||||
@@ -946,15 +947,56 @@ Partial Class Inventarios_CartaPorteManual
|
||||
|
||||
|
||||
Public Sub CargarCamiones()
|
||||
|
||||
DdlConfigAuto.Items.Clear()
|
||||
DdlUnidadCamion.Items.Clear()
|
||||
|
||||
DdlUnidadCamion.DataSource = GlobalDTInvCamiones(UsuarioActual.CveEmpresa)
|
||||
'DdlUnidadCamion.DataSource = GlobalDTInvCamiones(UsuarioActual.CveEmpresa)
|
||||
'DdlUnidadCamion.DataBind()
|
||||
|
||||
|
||||
|
||||
Using ObjInv As New ClsInventarios
|
||||
|
||||
If ObjInv.GetCamiones(-1, UsuarioActual.CveEmpresa, 1) Then
|
||||
DdlUnidadCamion.DataSource = ObjInv.DtResultados
|
||||
End If
|
||||
|
||||
|
||||
If ObjInv.GetCamiones(-1, UsuarioActual.CveEmpresa, 2) Then
|
||||
DdlRemolque1.DataSource = ObjInv.DtResultados
|
||||
End If
|
||||
|
||||
End Using
|
||||
|
||||
DdlUnidadCamion.DataBind()
|
||||
|
||||
|
||||
DdlUnidadCamion.Items.Insert(0, New ListItem("Seleccione Uno", "-1"))
|
||||
|
||||
|
||||
DdlRemolque1.DataBind()
|
||||
DdlRemolque1.Items.Insert(0, New ListItem("Seleccione Uno", "-1"))
|
||||
|
||||
|
||||
|
||||
Using ObjGrales As New ClsGenerales
|
||||
|
||||
If ObjGrales.GetCartaPorteConfigAutoTransportes() Then
|
||||
DdlConfigAuto.DataSource = ObjGrales.DtResultados
|
||||
End If
|
||||
|
||||
End Using
|
||||
|
||||
DdlConfigAuto.DataBind()
|
||||
DdlConfigAuto.Items.Insert(0, New ListItem("Seleccione una", "-1"))
|
||||
|
||||
'Using ObjGral As New ClsGenerales
|
||||
' If ObjGral.GetCartaPorteConfigAutoTransportes() Then
|
||||
' DdlConfigAuto.DataSource = ObjGral.DtResultados
|
||||
' End If
|
||||
'End Using
|
||||
|
||||
'DdlConfigAuto.DataBind()
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
@@ -1334,6 +1376,223 @@ Partial Class Inventarios_CartaPorteManual
|
||||
UpModalDVDireccionEnvio.Update()
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
#Region "remolques"
|
||||
|
||||
|
||||
|
||||
|
||||
Protected Sub DdlUnidadCamionActivoFijo_SelectedIndexChanged(sender As Object, e As EventArgs)
|
||||
|
||||
|
||||
DvRemolque1.Visible = False
|
||||
DvRemolque2.Visible = False
|
||||
|
||||
DdlRemolque1.SelectedValueExist(-1)
|
||||
DdlRemolque2.SelectedValueExist(-1)
|
||||
|
||||
If DdlUnidadCamion.SelectedValue.ToEntero > 0 Then
|
||||
|
||||
|
||||
Using ObjInv As New ClsInventarios
|
||||
|
||||
If ObjInv.GetCamiones(DdlUnidadCamion.SelectedValue.ToEntero, UsuarioActual.CveEmpresa, 1) Then
|
||||
DdlConfigAuto.SelectedValueExist(ObjInv.DtResultados.FiltroPrimeroValor("ConfigCartaPorte"))
|
||||
DdlConfigAuto_SelectedIndexChanged(Nothing, Nothing)
|
||||
End If
|
||||
|
||||
End Using
|
||||
|
||||
|
||||
End If
|
||||
|
||||
UpEmitirTransitorio.Update()
|
||||
|
||||
End Sub
|
||||
|
||||
Property RequiereRemolque As Boolean
|
||||
Get
|
||||
If ViewState("RequiereRemolque") Is Nothing Then
|
||||
ViewState("RequiereRemolque") = False
|
||||
End If
|
||||
|
||||
Return Boolean.Parse(ViewState("RequiereRemolque").ToString)
|
||||
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
ViewState("RequiereRemolque") = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
|
||||
Property MostrarRemolques As Boolean
|
||||
Get
|
||||
If ViewState("MostrarRemolques") Is Nothing Then
|
||||
ViewState("MostrarRemolques") = False
|
||||
End If
|
||||
|
||||
Return Boolean.Parse(ViewState("MostrarRemolques").ToString)
|
||||
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
ViewState("MostrarRemolques") = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
|
||||
|
||||
Protected Sub DdlConfigAuto_SelectedIndexChanged(sender As Object, e As EventArgs)
|
||||
ValidaConfiguracionVeiculo()
|
||||
End Sub
|
||||
|
||||
|
||||
Private Sub ValidaConfiguracionVeiculo()
|
||||
DvRemolque1.Visible = False
|
||||
DvRemolque2.Visible = False
|
||||
|
||||
DdlRemolque1.SelectedValueExist(-1)
|
||||
DdlRemolque2.SelectedValueExist(-1)
|
||||
|
||||
If DdlConfigAuto.SelectedIndex > 0 Then
|
||||
|
||||
Using ObjGrales As New ClsGenerales
|
||||
If ObjGrales.GetCartaPorteConfigAutoTransportes() Then
|
||||
Dim Remolque As String = ObjGrales.DtResultados.FiltroPrimeroValor("Remolque", $" ClaveConfigAutoTransporte ='{DdlConfigAuto.SelectedValue}'")
|
||||
|
||||
|
||||
If Remolque = "1" Then
|
||||
RequiereRemolque = True
|
||||
MostrarRemolques = True
|
||||
End If
|
||||
|
||||
If Remolque = "0, 1" Then
|
||||
RequiereRemolque = False
|
||||
MostrarRemolques = True
|
||||
End If
|
||||
|
||||
If Remolque = "0" Then
|
||||
RequiereRemolque = False
|
||||
MostrarRemolques = False
|
||||
End If
|
||||
End If
|
||||
End Using
|
||||
|
||||
Else
|
||||
RequiereRemolque = False
|
||||
MostrarRemolques = False
|
||||
End If
|
||||
|
||||
|
||||
|
||||
|
||||
If RequiereRemolque Or MostrarRemolques Then
|
||||
DvRemolque1.Visible = True
|
||||
End If
|
||||
|
||||
If Not RequiereRemolque Then
|
||||
DvConfiguracionVeiculo.Visible = False
|
||||
Else
|
||||
DvConfiguracionVeiculo.Visible = True
|
||||
End If
|
||||
|
||||
|
||||
UpEmitirTransitorio.Update()
|
||||
End Sub
|
||||
|
||||
Protected Sub DdlRemolque1_SelectedIndexChanged(sender As Object, e As EventArgs)
|
||||
|
||||
DdlRemolque2.Items.Clear()
|
||||
|
||||
If DdlRemolque1.SelectedValue.ToEntero > 0 Then
|
||||
DvRemolque2.Visible = True
|
||||
|
||||
Using ObjInv As New ClsInventarios
|
||||
If ObjInv.GetCamiones(-1, UsuarioActual.CveEmpresa, 2) Then
|
||||
DdlRemolque2.DataSource = ObjInv.DtResultados.FiltraParametros($"CveCamion <> {DdlRemolque1.SelectedValue.ToEntero}")
|
||||
End If
|
||||
End Using
|
||||
|
||||
DdlRemolque2.DataBind()
|
||||
|
||||
|
||||
Else
|
||||
DvRemolque2.Visible = False
|
||||
End If
|
||||
|
||||
DdlRemolque2.Items.Insert(0, New ListItem("Seleccione uno", "-1"))
|
||||
|
||||
UpEmitirTransitorio.Update()
|
||||
|
||||
End Sub
|
||||
|
||||
Private Function validarRemolques() As Boolean
|
||||
Dim Respuesta As Boolean = False
|
||||
|
||||
|
||||
If RequiereRemolque And DdlRemolque1.SelectedValue.ToEntero <= 0 Then
|
||||
Alert("La configuración de la carta porte requiere que seleccione un remolque", TipoMensaje.MsgAdvertencia)
|
||||
End If
|
||||
|
||||
If RequiereRemolque And DdlRemolque1.SelectedValue.ToEntero > 0 Then
|
||||
Respuesta = True
|
||||
End If
|
||||
|
||||
If Not RequiereRemolque Then
|
||||
Respuesta = True
|
||||
End If
|
||||
|
||||
Return Respuesta
|
||||
|
||||
End Function
|
||||
|
||||
|
||||
|
||||
Function ValidaPSSAT(DrPS As DataRow) As Boolean
|
||||
Dim Respuesta As Boolean = False
|
||||
|
||||
Dim CveSATPS As Integer = DrPS("CveSATPS").ToString.ToEntero
|
||||
Dim PesoKg As Decimal = DrPS("PesoKg").ToString.ToDecimal
|
||||
Dim SATClaveUnidadMedida As String = DrPS("SATClaveUnidadMedida").ToString.Trim
|
||||
|
||||
If CveSATPS > 0 And PesoKg > 0 And SATClaveUnidadMedida.Length > 0 Then
|
||||
Respuesta = True
|
||||
Else
|
||||
Respuesta = False
|
||||
Dim SBMensaje As New StringBuilder
|
||||
|
||||
SBMensaje.AppendLine("El producto seleccionado presenta la siguiente situación: <br>")
|
||||
|
||||
If CveSATPS <= 0 Then
|
||||
SBMensaje.AppendLine("-Producto SAT no asignado. <br>")
|
||||
End If
|
||||
|
||||
|
||||
If PesoKg = 0 Then
|
||||
SBMensaje.AppendLine("-Producto sin peso definido. <br>")
|
||||
End If
|
||||
|
||||
|
||||
If SATClaveUnidadMedida.Length = 0 Then
|
||||
SBMensaje.AppendLine("-Producto sin unidad de medida SAT asignada. ")
|
||||
End If
|
||||
|
||||
|
||||
SBMensaje.AppendLine($"<br><br> <strong><a class='texto' target='_blank' href='../Ventas/ProductosServicios.aspx?CvePS={DrPS("CvePS").ToString}' > Corregir Producto </a></strong>")
|
||||
|
||||
|
||||
Alert(SBMensaje.ToString, TipoMensaje.MsgAdvertencia)
|
||||
|
||||
End If
|
||||
|
||||
|
||||
Return Respuesta
|
||||
End Function
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
|
||||
End Class
|
||||
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
<asp:Content ID="Content7" ContentPlaceHolderID="C" Runat="Server">
|
||||
<asp:UpdatePanel ID="UpDatos" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<asp:GridView ID="GvDatos" runat="server" AutoGenerateColumns="False" DataKeyNames="CveCamion,Placa,Especificacion,ConfigCartaPorte,Anio,CveTipoPermisoSCT,NumPermisoSCT,NombreAseguradora,NumPolizaSeguro,NombreAseguradoraMedioAmbiente,NumPolizaSeguroMedioAmbiente,NombreAseguradoraCarga,NumPolizaSeguroCarga"
|
||||
<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"
|
||||
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>
|
||||
<asp:BoundField HeaderText="Unidad" DataField="Especificacion" ItemStyle-HorizontalAlign="Left" />
|
||||
@@ -81,6 +81,15 @@
|
||||
<i></i>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright col-md-12" runat="server" id="DVTiposRemolque" visible="false">
|
||||
<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 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>
|
||||
@@ -89,7 +98,7 @@
|
||||
<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>
|
||||
</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" runat="server" id="DVAnio">
|
||||
<asp:TextBox ID="TxtAnio" CssClass="form-control" runat="server" MaxLength="4"></asp:TextBox>
|
||||
<label for="<%= TxtAnio.ClientID.ToString()%>">Año:</label>
|
||||
<ajax:FilteredTextBoxExtender runat="server" TargetControlID="TxtAnio" FilterType="Custom" ValidChars="1234567890" />
|
||||
@@ -101,7 +110,7 @@
|
||||
</div>
|
||||
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<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>
|
||||
<label for="<%= DdlConfigAuto.ClientID.ToString()%>">Configuración Carta Porte:</label>
|
||||
@@ -111,7 +120,7 @@
|
||||
|
||||
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<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>
|
||||
<label for="<%= DdlTipoPermisoSCT.ClientID.ToString()%>">Tipo Permiso SCT:</label>
|
||||
@@ -119,7 +128,7 @@
|
||||
<i></i>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="row" runat="server" id="DVNumermisoSCT" >
|
||||
<div class="col-md-12">
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
@@ -131,7 +140,7 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="row" runat="server" id="DVNombreAseguradora">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox ID="TxtNombreAseguradora" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox>
|
||||
@@ -150,7 +159,7 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="row" runat="server" id="DVNombreAseguradoraMedioAmbiente">
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="form-group form-md-line-input input-iconright" >
|
||||
@@ -171,7 +180,7 @@
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="row" runat="server" id="DVNumPolizaSeguroMedioAmbient" >
|
||||
<div class="col-md-6">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox ID="TxtNombreAseguradoraCarga" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox>
|
||||
@@ -188,6 +197,46 @@
|
||||
</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>
|
||||
|
||||
@@ -51,11 +51,22 @@ Partial Class Inventarios_CatUnidades
|
||||
If ObjGral.GetCartaPorteTipoPermisoSCT() Then
|
||||
DdlTipoPermisoSCT.DataSource = ObjGral.DtResultados
|
||||
End If
|
||||
|
||||
If ObjGral.GetCartaPorteTiposRemolques() Then
|
||||
DdlTiposRemolque.DataSource = ObjGral.DtResultados
|
||||
End If
|
||||
|
||||
|
||||
End Using
|
||||
|
||||
DdlConfigAuto.DataBind()
|
||||
DdlConfigAuto.Items.Insert(0, New ListItem("Seleccione Uno ", "-1"))
|
||||
|
||||
DdlTipoPermisoSCT.DataBind()
|
||||
DdlTipoPermisoSCT.Items.Insert(0, New ListItem("Seleccione Uno ", "-1"))
|
||||
|
||||
DdlTiposRemolque.DataBind()
|
||||
DdlTiposRemolque.Items.Insert(0, New ListItem("Seleccione Uno ", "-1"))
|
||||
|
||||
UpModalUnidades.Update()
|
||||
|
||||
@@ -82,8 +93,15 @@ Partial Class Inventarios_CatUnidades
|
||||
TxtNumPolizaSeguroMedioAmbiente.Text = ""
|
||||
TxtNombreAseguradoraCarga.Text = ""
|
||||
TxtNumPolizaSeguroCarga.Text = ""
|
||||
|
||||
TxtLongitudCaja.Text = ""
|
||||
TxtLineaTransportacion.Text = ""
|
||||
TxtSCAC.Text = ""
|
||||
TxtCAAT.Text = ""
|
||||
ChkesRemolque.Checked = False
|
||||
LtlTituloModal.Text = "Agregar Unidad"
|
||||
DdlTiposRemolque.SelectedValueExist(-1)
|
||||
|
||||
ChkesRemolque_CheckedChanged(Nothing, Nothing)
|
||||
|
||||
UpModalUnidades.Update()
|
||||
RegistraScript(String.Format("$('#{0}').modal();", "DivAgregarUnidad"))
|
||||
@@ -95,7 +113,7 @@ Partial Class Inventarios_CatUnidades
|
||||
Dim GvRow As GridViewRow = CType(((CType(sender, LinkButton)).NamingContainer), GridViewRow)
|
||||
|
||||
CveCamion = GvRow.DataKey("CveCamion").ToEntero()
|
||||
|
||||
Dim CveTipoRemolque As Integer = GvRow.DataKey("CveTipoRemolque").ToEntero
|
||||
|
||||
TxtPlacaNuevo.Text = GvRow.DataKey("Placa")
|
||||
TxtEspecificacionNuevo.Text = GvRow.DataKey("Especificacion")
|
||||
@@ -113,8 +131,20 @@ Partial Class Inventarios_CatUnidades
|
||||
TxtNombreAseguradoraCarga.Text = GvRow.DataKey("NombreAseguradoraCarga")
|
||||
TxtNumPolizaSeguroCarga.Text = GvRow.DataKey("NumPolizaSeguroCarga")
|
||||
|
||||
DdlTiposRemolque.SelectedValueExist(CveTipoRemolque)
|
||||
|
||||
TxtLongitudCaja.Text = GvRow.DataKey("LongitudCaja")
|
||||
TxtLineaTransportacion.Text = GvRow.DataKey("LineaTransportacion")
|
||||
TxtSCAC.Text = GvRow.DataKey("SCAC")
|
||||
TxtCAAT.Text = GvRow.DataKey("CAAT")
|
||||
|
||||
ChkesRemolque.Checked = (GvRow.DataKey("CveTipoCamion") = "2")
|
||||
|
||||
LtlTituloModal.Text = "Actualizar Unidad"
|
||||
|
||||
ChkesRemolque_CheckedChanged(Nothing, Nothing)
|
||||
|
||||
|
||||
UpModalUnidades.Update()
|
||||
|
||||
RegistraScript(String.Format("$('#{0}').modal();", "DivAgregarUnidad"))
|
||||
@@ -128,18 +158,19 @@ Partial Class Inventarios_CatUnidades
|
||||
|
||||
Dim CveCamionEliminar = GvRow.DataKey("CveCamion").ToEntero()
|
||||
|
||||
Dim ObjInventarios As New ClsInventarios
|
||||
Using ObjInventarios As New ClsInventarios
|
||||
|
||||
If (ObjInventarios.RemoveCamiones(CveCamionEliminar, UsuarioActual.CveEmpresa)) Then
|
||||
|
||||
UpDatos.Update()
|
||||
RegistraScript(String.Format("$('#{0}').modal('hide');", "DivAgregarUnidad"))
|
||||
Alert("Unidad Eliminada Correctamente")
|
||||
Else
|
||||
ErrorAlElimiar = True
|
||||
End If
|
||||
If (ObjInventarios.RemoveCamiones(CveCamionEliminar, UsuarioActual.CveEmpresa)) Then
|
||||
|
||||
UpDatos.Update()
|
||||
RegistraScript(String.Format("$('#{0}').modal('hide');", "DivAgregarUnidad"))
|
||||
Alert("Unidad Eliminada Correctamente")
|
||||
Else
|
||||
ErrorAlElimiar = True
|
||||
End If
|
||||
End Using
|
||||
|
||||
ObjInventarios.Dispose()
|
||||
|
||||
If Not ErrorAlElimiar Then
|
||||
GlobalDTInvCamiones(UsuarioActual.CveEmpresa) = Nothing
|
||||
@@ -152,23 +183,25 @@ Partial Class Inventarios_CatUnidades
|
||||
|
||||
Dim ErrorPrceso As Boolean = False
|
||||
|
||||
Dim ObjInventarios As New ClsInventarios
|
||||
Dim CveTipoCamion As Integer = If(ChkesRemolque.Checked, 2, 1)
|
||||
Using ObjInventarios As New ClsInventarios
|
||||
|
||||
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,
|
||||
TxtNombreAseguradoraMedioAmbiente.Text, TxtNumPolizaSeguroMedioAmbiente.Text, TxtNombreAseguradoraCarga.Text, TxtNumPolizaSeguroCarga.Text) Then
|
||||
Alert("Unidad agregada correctamente")
|
||||
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,
|
||||
TxtNombreAseguradoraMedioAmbiente.Text, TxtNumPolizaSeguroMedioAmbiente.Text, TxtNombreAseguradoraCarga.Text, TxtNumPolizaSeguroCarga.Text, CveTipoCamion, TxtLongitudCaja.Text, TxtLineaTransportacion.Text, TxtSCAC.Text, TxtCAAT.Text, DdlTiposRemolque.SelectedValue.ToEntero) Then
|
||||
Alert("Unidad agregada correctamente")
|
||||
Else
|
||||
ErrorPrceso = True
|
||||
End If
|
||||
Else
|
||||
ErrorPrceso = True
|
||||
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
|
||||
Alert("Unidad actualizada correctamente")
|
||||
Else
|
||||
ErrorPrceso = True
|
||||
End If
|
||||
End If
|
||||
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,
|
||||
TxtNombreAseguradoraMedioAmbiente.Text, TxtNumPolizaSeguroMedioAmbiente.Text, TxtNombreAseguradoraCarga.Text, TxtNumPolizaSeguroCarga.Text) Then
|
||||
Alert("Unidad actualizada correctamente")
|
||||
Else
|
||||
ErrorPrceso = True
|
||||
End If
|
||||
End If
|
||||
End Using
|
||||
|
||||
|
||||
If Not ErrorPrceso Then
|
||||
@@ -183,4 +216,34 @@ Partial Class Inventarios_CatUnidades
|
||||
End Sub
|
||||
|
||||
|
||||
Protected Sub ChkesRemolque_CheckedChanged(sender As Object, e As EventArgs)
|
||||
|
||||
If Not ChkesRemolque.Checked Then
|
||||
|
||||
DVAnio.Visible = True
|
||||
DVConfigAuto.Visible = True
|
||||
DVTipoPermisoSCT.Visible = True
|
||||
DVNumermisoSCT.Visible = True
|
||||
DVNombreAseguradora.Visible = True
|
||||
DVNombreAseguradoraMedioAmbiente.Visible = True
|
||||
DVNumPolizaSeguroMedioAmbient.Visible = True
|
||||
|
||||
DVTiposRemolque.Visible = False
|
||||
Else
|
||||
DVAnio.Visible = False
|
||||
DVConfigAuto.Visible = False
|
||||
DVTipoPermisoSCT.Visible = False
|
||||
DVNumermisoSCT.Visible = False
|
||||
DVNombreAseguradora.Visible = False
|
||||
DVNombreAseguradoraMedioAmbiente.Visible = False
|
||||
DVNumPolizaSeguroMedioAmbient.Visible = False
|
||||
|
||||
DVTiposRemolque.Visible = True
|
||||
End If
|
||||
|
||||
|
||||
DVTiposRemolque.Visible = ChkesRemolque.Checked
|
||||
UpModalUnidades.Update
|
||||
|
||||
End Sub
|
||||
End Class
|
||||
|
||||
@@ -99,7 +99,7 @@
|
||||
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GVDatos.ClientID) %>" style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
|
||||
</div>
|
||||
<asp:GridView ID="GVDatos" runat="server"
|
||||
DataKeyNames="CveEntregaAlmacen,Estatus,CveCliente,CveDireccionOrigen,CveDireccionDestino,CveCamion,CveChofer,FechaEntrega,CveAlmacen,Tipo,AplicaCP,RFCReceptor,RFCEmisor,CveTimbre,CvePAC,FolioFiscal"
|
||||
DataKeyNames="CveEntregaAlmacen,Estatus,CveCliente,CveDireccionOrigen,CveDireccionDestino,CveCamion,CveChofer,FechaEntrega,CveAlmacen,Tipo,AplicaCP,RFCReceptor,RFCEmisor,CveTimbre,CvePAC,FolioFiscal, TimbreTipoDocto,CveMovimiento,FechaLlegada,CveCamionRemolque1,CveCamionRemolque2,Distancia,ConfigCartaPorte,SerieFolio,DireccionOrigen,Direccion"
|
||||
AutoGenerateColumns="False" EmptyDataText="No se encontraron Registros con los filtros especificados" CssClass="table table-striped table-advance table-hover Widthall mysmallbtn ScrollAD" data-sort="true" GridLines="None"
|
||||
EmptyDataRowStyle-HorizontalAlign="Center" OnRowDataBound="GVDatos_RowDataBound">
|
||||
<Columns>
|
||||
@@ -120,7 +120,7 @@
|
||||
|
||||
<asp:BoundField DataField="FechaEntrega" HeaderText="Fecha Entrega" ItemStyle-Width="4%" DataFormatString="{0:dd/MM/yyyy}" ItemStyle-HorizontalAlign="Center" />
|
||||
|
||||
<asp:TemplateField ItemStyle-Width="13%" ItemStyle-HorizontalAlign="Left" HeaderStyle-HorizontalAlign="Left" HeaderText="Opciones">
|
||||
<asp:TemplateField ItemStyle-Width="75px" ItemStyle-HorizontalAlign="Left" HeaderStyle-HorizontalAlign="Left" HeaderText="Opciones">
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton ID="LnkEditar" runat="server" OnClick="imgEditar_Click" AlternateText="Editar" ToolTip="Actualizar" CausesValidation="False" CssClass="btn btn-circle btn-sm blue" Text="<i class='fa fa-pencil'></i>" />
|
||||
<asp:LinkButton ID="LnkTimbrar" runat="server" OnClick="LnkTimbrar_Click" AlternateText="Timbrar" ToolTip="Timbrar" CausesValidation="False" CssClass="btn btn-circle btn-sm green" Text="<i class='fa fa-external-link'></i>" />
|
||||
@@ -128,15 +128,26 @@
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
|
||||
<asp:TemplateField ItemStyle-Width="50px" ItemStyle-HorizontalAlign="Left" HeaderStyle-HorizontalAlign="Center" HeaderText="Direcciones" Visible="false">
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton ID="LnkEditarDirOrigen" Visible="false" runat="server" OnClick="EditDireccionOrigen_Click" AlternateText="Editar" ToolTip="Actualzar dirección Origen" CausesValidation="False" CssClass="btn btn-circle btn-sm blue" Text="<i class='fa fa-location-arrow'></i>" />
|
||||
<asp:LinkButton ID="LnkEditarDirDestino" Visible="false" runat="server" OnClick="EditDireccionDestino_Click" AlternateText="Editar" ToolTip="Actualziar Dierccion Destino" CausesValidation="False" CssClass="btn btn-circle btn-sm green" Text="<i class='fa fa-location-arrow'></i>" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
|
||||
|
||||
<asp:BoundField DataField="Estatus" HeaderText="PDF" ItemStyle-Width="4%" ItemStyle-HorizontalAlign="Center" Visible="true" />
|
||||
<asp:BoundField DataField="Estatus" HeaderText="XML" ItemStyle-Width="4%" ItemStyle-HorizontalAlign="Center" Visible="true" />
|
||||
|
||||
</Columns>
|
||||
</asp:GridView>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<div id="DivEditarEntrega" class="modal ADS fade" role="dialog">
|
||||
<div id="DivEditarEntrega" class="modal ADS fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
<asp:UpdatePanel ID="UpModalEditarentrega" class="modal-content rowpadding" tabindex="-1" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
@@ -146,64 +157,119 @@
|
||||
</button>
|
||||
<h4 class="modal-title" id="H3" runat="server">Editar Entrega</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div class="modal-body">
|
||||
|
||||
<div class="row">
|
||||
<div class="form-group col-md-6 form-md-line-input input-iconright">
|
||||
<asp:DropDownList ID="DdlModalDireccionOrigen" runat="server" Width="100%" AppendDataBoundItems="true" DataTextField="DireccionEnvio" DataValueField="CveDireccionEnvio" Class="table-group-action-input form-control input-inline input-small input-sm select2me"></asp:DropDownList>
|
||||
<label for="<%= DdlModalDireccionOrigen.ClientID.ToString()%>">Dirección Origen:</label>
|
||||
</div>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlModalDireccionOrigen" runat="server" ControlToValidate="DdlModalDireccionOrigen" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Dirección Origen''</b> es necesario." InitialValue="-1" ValidationGroup="GrpModalEditarentrega"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VceDdlModalDireccionOrigen" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlModalDireccionOrigen" Width="250px" PopupPosition="BottomLeft"></ajax:ValidatorCalloutExtender>
|
||||
<label class="col-md-3">Chofer:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList ID="DdlModalChofer" runat="server" DataTextField="Chofer" DataValueField="CveChofer" AutoPostBack="true" CssClass="form-control input-sm select2me" Width="100%"></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlModalChofer" runat="server" Enabled="false" ControlToValidate="DdlModalChofer" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Chofer''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VceRfvDdlModalChofer" runat="server" HighlightCssClass="vco" TargetControlID="rfvDdlModalChofer" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="form-group col-md-6 form-md-line-input input-iconright">
|
||||
<asp:DropDownList ID="DdlModalDireccionDestino" runat="server" Width="100%" AppendDataBoundItems="true" DataTextField="DireccionEnvio" DataValueField="CveDireccionEnvio" Class="table-group-action-input form-control input-inline input-small input-sm select2me"></asp:DropDownList>
|
||||
<label for="<%= DdlModalDireccionDestino.ClientID.ToString()%>">Dirección Destino:</label>
|
||||
</div>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlModalDireccionDestino" runat="server" ControlToValidate="DdlModalDireccionDestino" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Dirección Destino''</b> es necesario." InitialValue="-1" ValidationGroup="GrpModalEditarentrega"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VceDdlModalDireccionDestino" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlModalDireccionDestino" Width="250px" PopupPosition="BottomLeft"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="form-group col-md-6 form-md-line-input input-iconright">
|
||||
<asp:DropDownList ID="DdlModalChofer" runat="server" Width="100%" AppendDataBoundItems="true" DataTextField="Chofer" DataValueField="CveChofer" Class="table-group-action-input form-control input-inline input-small input-sm select2me"></asp:DropDownList>
|
||||
<label for="<%= DdlModalChofer.ClientID.ToString()%>">Chofer:</label>
|
||||
</div>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlModalChofer" runat="server" ControlToValidate="DdlModalChofer" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Chofer''</b> es necesario." InitialValue="-1" ValidationGroup="GrpModalEditarentrega"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VceDdlModalChofer" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlModalChofer" Width="250px" PopupPosition="BottomLeft"></ajax:ValidatorCalloutExtender>
|
||||
<div class="row">
|
||||
<label class="col-md-3">Unidad:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList runat="server" ID="DdlModalCamion" AutoPostBack="true" Width="100%" AppendDataBoundItems="true" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca" OnSelectedIndexChanged="DdlModalCamion_SelectedIndexChanged"></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlUnidadCamionActivoFijo" runat="server" Enabled="false" ControlToValidate="DdlModalCamion" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Unidad''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VceDdlUnidadCamionActivoFijo" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlUnidadCamionActivoFijo" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="form-group col-md-6 form-md-line-input input-iconright">
|
||||
<asp:DropDownList ID="DdlModalCamion" runat="server" Width="100%" AppendDataBoundItems="true" DataTextField="Placa" DataValueField="CveCamion" Class="table-group-action-input form-control input-inline input-small input-sm select2me"></asp:DropDownList>
|
||||
<label for="<%= DdlModalCamion.ClientID.ToString()%>">Unidad:</label>
|
||||
</div>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlModalCamion" runat="server" ControlToValidate="DdlModalCamion" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Unidad''</b> es necesario." InitialValue="-1" ValidationGroup="GrpModalEditarentrega"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VceDdlModalCamion" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlModalCamion" Width="250px" PopupPosition="BottomLeft"></ajax:ValidatorCalloutExtender>
|
||||
<div class="row" runat="server" id="DvConfiguracionVeiculo" visible="false">
|
||||
<label class="col-md-3">Configuración:</label>
|
||||
<div class="col-md-9">
|
||||
<%--<asp:DropDownList runat="server" ID="DropDownList1" AutoPostBack="true" Width="100%" AppendDataBoundItems="true" CssClass="form-control input-sm select2me" DataValueField="CveActivoFijo" DataTextField="CodigoDescripcion"></asp:DropDownList>--%>
|
||||
<asp:DropDownList ID="DdlConfigAuto" CssClass="form-control input-sm select2me" Width="100%" runat="server" AppendDataBoundItems="true" AutoPostBack="true" OnSelectedIndexChanged="DdlConfigAuto_SelectedIndexChanged" CausesValidation="true" DataTextField="ClaveConfigAutoTransporteDescripcion" DataValueField="ClaveConfigAutoTransporte" Style="padding: 0px">
|
||||
</asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlConfigAuto" runat="server" Enabled="false" ControlToValidate="DdlConfigAuto" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Configuración Carta Porte''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCERfvDdlConfigAuto" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlConfigAuto" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row" >
|
||||
|
||||
<div style="margin-left:16px!important">
|
||||
<label for="<%= TxtmodalFechaEntrega.ClientID.ToString()%>">Fecha Entrega:</label>
|
||||
<br />
|
||||
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 138px !important; padding: 0px; margin-bottom: -10px;">
|
||||
<asp:TextBox ID="TxtmodalFechaEntrega" runat="server" CssClass="form-control" CausesValidation="true" Width="98%" MaxLength="10"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton ID="LnkModalTxtmodalFechaEntrega" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||
</span>
|
||||
<div class="row" runat="server" id="DvRemolque1" visible="false">
|
||||
<label class="col-md-3">Remolque 1:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList runat="server" ID="DdlRemolque1" AutoPostBack="true" Width="100%" AppendDataBoundItems="true" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca" OnSelectedIndexChanged="DdlRemolque1_SelectedIndexChanged"></asp:DropDownList>
|
||||
</div>
|
||||
<ajax:MaskedEditExtender ID="METxtmodalFechaEntrega" runat="server" TargetControlID="TxtmodalFechaEntrega" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="CeTxtmodalFechaEntrega" TargetControlID="TxtmodalFechaEntrega" PopupButtonID="LnkModalTxtmodalFechaEntrega" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:RequiredFieldValidator ID="RfvTxtmodalFechaEntrega" runat="server" ControlToValidate="TxtmodalFechaEntrega" Display="None" ErrorMessage="El campo <b>''Fecha de Entrega''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrpModalEditarentrega"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VceTxtmodalFechaEntrega" runat="server" HighlightCssClass="vco" TargetControlID="RfvTxtmodalFechaEntrega" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="row" runat="server" id="DvRemolque2" visible="false">
|
||||
<label class="col-md-3">Remolque 2:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList runat="server" ID="DdlRemolque2" AutoPostBack="true" Width="100%" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca"></asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<asp:UpdatePanel runat="server" ID="UpModalDirecciones" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
|
||||
<div class="row" runat="server" id="DVDireccionOrigen" visible="false">
|
||||
<label class="col-md-3">Dirección Origen:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:LinkButton runat="server" OnClick="EditDireccionOrigen_Click" ID="LnkDireccionOrigen" CssClass="Texto"></asp:LinkButton>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row" runat="server" id="DVDireccionDestino" visible="false">
|
||||
<label class="col-md-3">Dirección Destino:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:LinkButton runat="server" OnClick="EditDireccionDestino_Click" ID="LnkDireccionDestino" CssClass="Texto"></asp:LinkButton>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="row">
|
||||
<label class="col-md-3">F. Salida:</label>
|
||||
<div class="col-md-9" style="padding-top: 0px;">
|
||||
<div class="input-group input-sm input-small date date-picker" data-date-format="dd/mm/yyyy" style="width: 125px !important;">
|
||||
<asp:TextBox ID="TxtFechaEntrega" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10" Width="80px" ClientIDMode="Static"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton runat="server" ID="ImgFechaEntrega" class="btn default"> <i class="fa fa-calendar"></i> </asp:LinkButton>
|
||||
</span>
|
||||
<ajax:MaskedEditExtender ID="MaskedEditExtender2" runat="server" TargetControlID="TxtFechaEntrega" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="CalendarExtender2" TargetControlID="TxtFechaEntrega" PopupButtonID="ImgFechaEntrega" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:CompareValidator ID="CompareValidator1" runat="server" ControlToValidate="TxtFechaEntrega" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha Entrega''</b> no tiene el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date"></asp:CompareValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender4" runat="server" HighlightCssClass="vco" TargetControlID="CompareValidator1" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row" runat="server" id="divFechaLlegada">
|
||||
<label class="col-md-3">F. Llegada:</label>
|
||||
<div class="col-md-4" style="padding-top: 0px;">
|
||||
<div class="input-group input-sm input-small date date-picker" data-date-format="dd/mm/yyyy" style="width: 125px !important;">
|
||||
<asp:TextBox ID="TxtFechaLlegada" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10" Width="80px" ClientIDMode="Static"></asp:TextBox>
|
||||
<span class="input-group-btn ">
|
||||
<asp:LinkButton runat="server" ID="ImgFechaEnvio" class="btn default"> <i class="fa fa-calendar"></i> </asp:LinkButton>
|
||||
</span>
|
||||
<ajax:MaskedEditExtender ID="MaskedEditExtender3" runat="server" TargetControlID="TxtFechaLlegada" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="CalendarExtender3" TargetControlID="TxtFechaLlegada" PopupButtonID="ImgFechaEnvio" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:CompareValidator ID="CompareValidator2" runat="server" ControlToValidate="TxtFechaLlegada" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha Envío''</b> no tiene el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date"></asp:CompareValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender3" runat="server" HighlightCssClass="vco" TargetControlID="CompareValidator2" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
<label class="col-md-1">Dist:</label>
|
||||
<div class="col-md-3">
|
||||
<asp:TextBox ID="TxtDistancia" runat="server" CssClass="form-control input-sm" Width="100%" Text="1"></asp:TextBox>
|
||||
<ajax:TextBoxWatermarkExtender ID="TBWEDistancia" runat="server" TargetControlID="TxtDistancia" WatermarkText="Distancia" WatermarkCssClass="watermarked" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<asp:UpdatePanel runat="server">
|
||||
@@ -218,6 +284,144 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div id="divAddDireccionEnvio" class="modal ADS fade" role="dialog">
|
||||
<div class="modal-dialog">
|
||||
<asp:UpdatePanel ID="UpModalDVDireccionEnvio" class="modal-content rowpadding" tabindex="-1" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
<h4 class="modal-title" id="myModalLabel"> <asp:Label runat="server" ID="LblTitulodireccion"></asp:Label> </h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<asp:UpdatePanel ID="UpBodyDireccion" UpdateMode="Conditional" runat="server">
|
||||
<ContentTemplate>
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox ID="TxtEnvioDireccion" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="100"></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtEnvioDireccion" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Direccion''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>
|
||||
<label for="<%= TxtEnvioDireccion.ClientID.ToString()%>">Calle:</label>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group form-md-line-input">
|
||||
<asp:TextBox ID="TxtEnvioNoExt" runat="server" CssClass="form-control" MaxLength="15"></asp:TextBox>
|
||||
<label for="<%= TxtEnvioNoExt.ClientID.ToString()%>">No. Ext. </label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class="form-group form-md-line-input">
|
||||
<asp:TextBox ID="TxtEnvioNoInt" runat="server" CssClass="form-control" MaxLength="50"></asp:TextBox>
|
||||
<label for="<%= TxtEnvioNoInt.ClientID.ToString()%>">No. Int.</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row ">
|
||||
|
||||
<div class="col-md-6">
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:TextBox ID="TxtEnvioCP" runat="server" Width="100%" CssClass="form-control" CausesValidation="true" TextMode="Number" onblur="DirclienteValidaCodigoPostal()" onkeypress="if(event.key === 'Enter'){return false;}"></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="RequiredFieldValidator14" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtEnvioCP" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Código Postal''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>
|
||||
<label for="<%= TxtEnvioCP.ClientID.ToString()%>">Código Postal:</label>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:DropDownList ID="DdlDirClientePais" AutoPostBack="true" AppendDataBoundItems="true" OnSelectedIndexChanged="DdlDirClientePais_SelectedIndexChanged" runat="server" DataTextField="Descripcion" DataValueField="CvePais" CssClass="form-control select2me" Width="100%" CausesValidation="true">
|
||||
</asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RFVDdlDirClientePais" InitialValue="-1" runat="server" CssClass="help-block errorimput" ControlToValidate="DdlDirClientePais" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Pais''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>
|
||||
<label for="<%= DdlDirClientePais.ClientID.ToString()%>">Pais:</label>
|
||||
<i></i>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-6">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:DropDownList ID="DdlDirClienteEstado" AutoPostBack="true" AppendDataBoundItems="true" OnSelectedIndexChanged="DdlDirClienteEstado_SelectedIndexChanged" runat="server" DataTextField="NombreEstado" DataValueField="CveEstado" CssClass="form-control select2me" Width="100%" CausesValidation="true">
|
||||
</asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RFVDdlDirClienteEstado" InitialValue="-1" runat="server" CssClass="help-block errorimput" ControlToValidate="DdlDirClienteEstado" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Estado''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>
|
||||
<label for="<%= DdlDirClienteEstado.ClientID.ToString()%>">Estado:</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:DropDownList ID="DdlDirClienteMunicipio" AutoPostBack="true" AppendDataBoundItems="true" OnSelectedIndexChanged="DdlDirClienteMunicipio_SelectedIndexChanged" runat="server" DataTextField="Descripcion" DataValueField="CveMunicipio" CssClass="form-control select2me" Width="100%" CausesValidation="true">
|
||||
</asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RFVDdlDirClienteMunicipio" InitialValue="-1" runat="server" CssClass="help-block errorimput" ControlToValidate="DdlDirClienteMunicipio" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Municipio''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>
|
||||
<label for="<%= DdlDirClienteMunicipio.ClientID.ToString()%>">Municipio:</label>
|
||||
<i></i>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:DropDownList runat="server" ID="DdlDirClienteLocalidad" CssClass="form-control select2me" DataValueField="CveLocalidad" DataTextField="NombreLocalidad" Width="100%" CausesValidation="true"></asp:DropDownList>
|
||||
<%--<asp:RequiredFieldValidator ID="RfvDdlDirClienteLocalidad" InitialValue="-1" runat="server" CssClass="help-block errorimput" ControlToValidate="DdlDirClienteLocalidad" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Localidad''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>--%>
|
||||
<label for="<%= DdlDirClienteLocalidad.ClientID.ToString()%>">Localidad:</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:DropDownList ID="DdlDirClienteColonia" runat="server" AppendDataBoundItems="true" DataTextField="NombreAsentamiento" DataValueField="CveColonia" CssClass="form-control select2me" Width="100%" AutoPostBack="true" OnSelectedIndexChanged="DdlDirClienteColonia_SelectedIndexChanged" CausesValidation="true">
|
||||
</asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RFVDdlDirClienteColonia" InitialValue="-1" runat="server" CssClass="help-block errorimput" ControlToValidate="DdlDirClienteColonia" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Colonia''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>
|
||||
<label for="<%= DdlDirClienteColonia.ClientID.ToString()%>">Colonia:</label>
|
||||
<i></i>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div style="display: none">
|
||||
<asp:Button ID="BtnDirClienteValidar" ClientIDMode="Static" runat="server" CssClass="btn btn-primary" OnClick="BtnDirClienteValidar_Click" Text="validar" />
|
||||
</div>
|
||||
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
<div class="modal-footer">
|
||||
<asp:UpdatePanel ID="UpFooter" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<asp:LinkButton ID="BtnAgregarDireccion" runat="server" CssClass="btn btn-success" Text="Actualizar" ValidationGroup="GrpObligatorio" OnClick="BtnAgregarDireccion_Click"></asp:LinkButton>
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">Cancelar</button>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
</div>
|
||||
</div>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</asp:Content>
|
||||
<asp:Content ID="Content8" ContentPlaceHolderID="JS" runat="Server">
|
||||
|
||||
@@ -176,6 +176,81 @@ public partial class General_RepEntregaAlmacenRuta : ClsPaginas
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private int CveDireccionEditar
|
||||
{
|
||||
get
|
||||
{
|
||||
if (ViewState["CveDireccionEditar"] == null)
|
||||
{
|
||||
ViewState["CveDireccionEditar"] = -1;
|
||||
}
|
||||
return ViewState["CveDireccionEditar"].ToString().ToEntero();
|
||||
}
|
||||
|
||||
set
|
||||
{
|
||||
ViewState["CveDireccionEditar"] = value;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
private int CveDireccionOrigen
|
||||
{
|
||||
get
|
||||
{
|
||||
if (ViewState["CveDireccionOrigen"] == null)
|
||||
{
|
||||
ViewState["CveDireccionOrigen"] = -1;
|
||||
}
|
||||
return ViewState["CveDireccionOrigen"].ToString().ToEntero();
|
||||
}
|
||||
|
||||
set
|
||||
{
|
||||
ViewState["CveDireccionOrigen"] = value;
|
||||
}
|
||||
}
|
||||
|
||||
private int CveDireccionDestino
|
||||
{
|
||||
get
|
||||
{
|
||||
if (ViewState["CveDireccionDestino"] == null)
|
||||
{
|
||||
ViewState["CveDireccionDestino"] = -1;
|
||||
}
|
||||
return ViewState["CveDireccionDestino"].ToString().ToEntero();
|
||||
}
|
||||
|
||||
set
|
||||
{
|
||||
ViewState["CveDireccionDestino"] = value;
|
||||
}
|
||||
}
|
||||
private int CveTimbre
|
||||
{
|
||||
get
|
||||
{
|
||||
if (ViewState["CveTimbre"] == null)
|
||||
{
|
||||
ViewState["CveTimbre"] = -1;
|
||||
}
|
||||
return ViewState["CveTimbre"].ToString().ToEntero();
|
||||
}
|
||||
|
||||
set
|
||||
{
|
||||
ViewState["CveTimbre"] = value;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
#endregion
|
||||
|
||||
|
||||
@@ -189,7 +264,13 @@ public partial class General_RepEntregaAlmacenRuta : ClsPaginas
|
||||
CargaChoferes();
|
||||
UPFiltros.Update();
|
||||
CargarCentrosDeCosto(null, DdlSucursales, null, LblDdlSucursal);
|
||||
|
||||
CargaChoferes();
|
||||
CargarCamiones();
|
||||
|
||||
|
||||
CargaDatos();
|
||||
CargaCombosDirecionesClientesSAT();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -274,59 +355,124 @@ public partial class General_RepEntregaAlmacenRuta : ClsPaginas
|
||||
|
||||
protected void imgEditar_Click(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
GridViewRow GvRow = (GridViewRow)(((LinkButton)sender).NamingContainer);
|
||||
|
||||
CveEntregaAlmacen = GvRow.DataKey("CveEntregaAlmacen").ToEntero();
|
||||
CveTimbre = GvRow.DataKey("CveTimbre").ToEntero();
|
||||
|
||||
int CveCliente = GvRow.DataKey("CveCliente").ToEntero();
|
||||
int CveDireccionOrigen = GvRow.DataKey("CveDireccionOrigen").ToEntero();
|
||||
int CveCliente = GvRow.DataKey("CveCliente").ToEntero();
|
||||
int CveAlmacen = GvRow.DataKey("CveAlmacen").ToEntero();
|
||||
|
||||
CargaModalCombosDirecciones(CveCliente, CveDireccionOrigen, CveAlmacen);
|
||||
|
||||
DdlModalDireccionOrigen.SelectedValueExist(GvRow.DataKey("CveDireccionOrigen"));
|
||||
DdlModalDireccionDestino.SelectedValueExist(GvRow.DataKey("CveDireccionDestino"));
|
||||
|
||||
DdlModalCamion.SelectedValueExist(GvRow.DataKey("CveCamion"));
|
||||
DdlModalChofer.SelectedValueExist(GvRow.DataKey("CveChofer"));
|
||||
DdlModalChofer.SelectedValueExist(GvRow.DataKey("CveChofer"));
|
||||
|
||||
TxtFechaEntrega.Text = GvRow.DataKey("FechaEntrega").ToDate().ToString("dd/MM/yyyy");
|
||||
TxtFechaLlegada.Text = GvRow.DataKey("FechaLlegada").ToDate().ToString("dd/MM/yyyy");
|
||||
TxtDistancia.Text = GvRow.DataKey("Distancia");
|
||||
DdlConfigAuto.SelectedValueExist(GvRow.DataKey("ConfigCartaPorte"));
|
||||
DdlConfigAuto_SelectedIndexChanged(null, null);
|
||||
|
||||
if (GvRow.DataKey("CveCamionRemolque1").ToEntero() > 0)
|
||||
{
|
||||
DdlRemolque1.SelectedValueExist(GvRow.DataKey("CveCamionRemolque1"));
|
||||
DdlRemolque2.SelectedValueExist("-1");
|
||||
DdlRemolque1_SelectedIndexChanged(null, null);
|
||||
}
|
||||
|
||||
if (GvRow.DataKey("CveCamionRemolque2").ToEntero() > 0)
|
||||
{
|
||||
DdlRemolque2.SelectedValueExist(GvRow.DataKey("CveCamionRemolque2"));
|
||||
}
|
||||
|
||||
|
||||
|
||||
CveDireccionOrigen = GvRow.DataKey("CveDireccionOrigen").ToEntero();
|
||||
CveDireccionDestino = GvRow.DataKey("CveDireccionDestino").ToEntero();
|
||||
|
||||
ModalActualizaDirecciones( CveTimbre);
|
||||
|
||||
|
||||
//if( CveDireccionOrigen > 0)
|
||||
//{
|
||||
// DVDireccionOrigen.Visible = true;
|
||||
|
||||
// LnkDireccionOrigen.Text = GvRow.DataKey("DireccionOrigen") + " <i class='fa fa-search' aria-hidden='true'></i>";
|
||||
//}
|
||||
//if (CveDireccionDestino > 0)
|
||||
//{
|
||||
// DVDireccionDestino.Visible = true;
|
||||
// LnkDireccionDestino.Text = GvRow.DataKey("Direccion") + " <i class='fa fa-search' aria-hidden='true'></i>";
|
||||
//}
|
||||
|
||||
TxtmodalFechaEntrega.Text = GvRow.DataKey("FechaEntrega").ToDate().ToString("dd/MM/yyyy");
|
||||
|
||||
|
||||
UpModalEditarentrega.Update();
|
||||
this.RegistraScript("$('#DivEditarEntrega').modal('show');");
|
||||
this.RegistraScript("$('#DivEditarEntrega').modal({ backdrop: 'static', keyboard: false });");
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
private void ModalActualizaDirecciones(int CveTimbre)
|
||||
{
|
||||
ClsGenerales ObjGeneral = new ClsGenerales();
|
||||
|
||||
if (ObjGeneral.GetInvEntregaAlmacenRutaRep( -1, UsuarioActual.CveEmpresa, -1, new DateTime(1900,01,01), new DateTime(9000, 01, 01),-1, CveTimbre)) {
|
||||
|
||||
if (ObjGeneral.DtResultados.Rows.Count > 0)
|
||||
{
|
||||
if (CveDireccionOrigen > 0)
|
||||
{
|
||||
DVDireccionOrigen.Visible = true;
|
||||
|
||||
LnkDireccionOrigen.Text = ObjGeneral.DtResultados.Rows[0]["DireccionOrigen"].ToString() + " <i class='fa fa-search' aria-hidden='true'></i>";
|
||||
}
|
||||
if (CveDireccionDestino > 0)
|
||||
{
|
||||
DVDireccionDestino.Visible = true;
|
||||
LnkDireccionDestino.Text = ObjGeneral.DtResultados.Rows[0]["Direccion"].ToString() + " <i class='fa fa-search' aria-hidden='true'></i>";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
ObjGeneral.Dispose();
|
||||
UpModalDirecciones.Update();
|
||||
}
|
||||
|
||||
|
||||
|
||||
private void CargaModalCombosDirecciones(int CveCliente, int CveDireccionOrigen, int CveAlmacen )
|
||||
{
|
||||
|
||||
DdlModalDireccionOrigen.Items.Clear();
|
||||
DdlModalDireccionDestino.Items.Clear();
|
||||
//DdlModalDireccionOrigen.Items.Clear();
|
||||
//DdlModalDireccionDestino.Items.Clear();
|
||||
|
||||
DataTable DTDireccionesCliente = new DataTable();
|
||||
ClsClientes ObjClientes = new ClsClientes();
|
||||
if (ObjClientes.DireccionEnvioGet(-1, CveCliente, -1))
|
||||
{
|
||||
DTDireccionesCliente = ObjClientes.DtResultados ;
|
||||
}
|
||||
ObjClientes.Dispose();
|
||||
//DataTable DTDireccionesCliente = new DataTable();
|
||||
//ClsClientes ObjClientes = new ClsClientes();
|
||||
//if (ObjClientes.DireccionEnvioGet(-1, CveCliente, -1))
|
||||
//{
|
||||
// DTDireccionesCliente = ObjClientes.DtResultados ;
|
||||
//}
|
||||
//ObjClientes.Dispose();
|
||||
|
||||
DdlModalDireccionDestino.DataSource = DTDireccionesCliente;
|
||||
DdlModalDireccionDestino.DataBind();
|
||||
DdlModalDireccionDestino.Items.Insert(0,new ListItem("Seleccione Una", "-1"));
|
||||
//DdlModalDireccionDestino.DataSource = DTDireccionesCliente;
|
||||
//DdlModalDireccionDestino.DataBind();
|
||||
//DdlModalDireccionDestino.Items.Insert(0,new ListItem("Seleccione Una", "-1"));
|
||||
|
||||
string Almacen = get_GlobalDTAlmacen(UsuarioActual.CveEmpresa, CveAlmacen: CveAlmacen).FiltroPrimeroValor("Almacen", $"CveAlmacen = {CveAlmacen}");
|
||||
if (CveDireccionOrigen > 0)
|
||||
{
|
||||
DdlModalDireccionOrigen.DataSource = DTDireccionesCliente.FiltraParametros($"CveDireccionEnvio = {CveDireccionOrigen}");
|
||||
DdlModalDireccionOrigen.DataBind();
|
||||
DdlModalDireccionOrigen.Items.Insert(0, new ListItem($"Almacen: {Almacen}", "-2"));
|
||||
}else
|
||||
{
|
||||
DdlModalDireccionOrigen.Items.Insert(0, new ListItem($"Almacen: {Almacen}", "-2"));
|
||||
}
|
||||
DTDireccionesCliente.Dispose();
|
||||
//string Almacen = get_GlobalDTAlmacen(UsuarioActual.CveEmpresa, CveAlmacen: CveAlmacen).FiltroPrimeroValor("Almacen", $"CveAlmacen = {CveAlmacen}");
|
||||
//if (CveDireccionOrigen > 0)
|
||||
//{
|
||||
// DdlModalDireccionOrigen.DataSource = DTDireccionesCliente.FiltraParametros($"CveDireccionEnvio = {CveDireccionOrigen}");
|
||||
// DdlModalDireccionOrigen.DataBind();
|
||||
// DdlModalDireccionOrigen.Items.Insert(0, new ListItem($"Almacen: {Almacen}", "-2"));
|
||||
//}else
|
||||
//{
|
||||
// DdlModalDireccionOrigen.Items.Insert(0, new ListItem($"Almacen: {Almacen}", "-2"));
|
||||
//}
|
||||
|
||||
|
||||
|
||||
//DTDireccionesCliente.Dispose();
|
||||
}
|
||||
|
||||
|
||||
@@ -335,14 +481,16 @@ public partial class General_RepEntregaAlmacenRuta : ClsPaginas
|
||||
LinkButton LnkCancelarFolioFiscal = (LinkButton)sender;
|
||||
GridViewRow GvRow = (GridViewRow)LnkCancelarFolioFiscal.BindingContainer;
|
||||
int cvetimbre = GvRow.DataKey("CveTimbre").ToEntero();
|
||||
string TimbreTipoDocto = GvRow.DataKey("TimbreTipoDocto");
|
||||
|
||||
Timbres ObjTimbres = new Timbres("Tra", cvetimbre, UsuarioActual);
|
||||
Timbres ObjTimbres = new Timbres(TimbreTipoDocto, cvetimbre, UsuarioActual);
|
||||
StringBuilder MensajeAlert = new StringBuilder();
|
||||
MensajeAlert.AppendFormat("Folio: <b>{0}</b> ", ObjTimbres.ObjFactura.SerieFolio);
|
||||
if (ObjTimbres.MsgError =="" && ObjTimbres.Timbrar())
|
||||
{
|
||||
MensajeAlert.AppendFormat("<a class='texto' style='color:#337ab7' href='/Compras/PopUpVerFactura.aspx?P={0}' target='_blank'>XML <i class='fa fa-file'></i></i></a> ", ModExtensiones.Encripta(String.Format("OP=DesXmlTra&CveTimbre={0}&EXT={1}&FOLIO={2}&TIPODOCTO={3}", cvetimbre, "XML", ObjTimbres.ObjFactura.SerieFolio, ObjTimbres.ObjFactura.TipoDocto)));
|
||||
Alert(MensajeAlert.ToString(), ModExtensiones.TipoMensaje.MsgInformacion);
|
||||
CargaDatos();
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -429,7 +577,9 @@ public partial class General_RepEntregaAlmacenRuta : ClsPaginas
|
||||
bool ProcesoOK = true ;
|
||||
|
||||
ClsGenerales ObjGral = new ClsGenerales();
|
||||
if(!ObjGral.UpdateInvEntregaAlmacenRuta(CveEntregaAlmacen,DdlModalDireccionOrigen.SelectedValue.ToEntero(), DdlModalDireccionDestino.SelectedValue.ToEntero(), DdlModalChofer.SelectedValue.ToEntero(), DdlModalCamion.SelectedValue.ToEntero(), TxtmodalFechaEntrega.Text.ToDate(), UsuarioActual.CveEmpresa))
|
||||
if(!ObjGral.UpdateInvEntregaAlmacenRuta(CveEntregaAlmacen,-1,-1, DdlModalChofer.SelectedValue.ToEntero(), DdlModalCamion.SelectedValue.ToEntero(), TxtFechaEntrega.Text.ToDate(), UsuarioActual.CveEmpresa,
|
||||
TxtFechaLlegada.Text.ToDate(), CveCamionRemolque1: DdlRemolque1.SelectedValue.ToEntero(), CveCamionRemolque2: DdlRemolque2.SelectedValue.ToEntero(), Distancia: TxtDistancia.Text.ToEntero(),
|
||||
ConfigCartaPorte: DdlConfigAuto.SelectedValue))
|
||||
{
|
||||
ProcesoOK = false;
|
||||
}
|
||||
@@ -455,6 +605,9 @@ public partial class General_RepEntregaAlmacenRuta : ClsPaginas
|
||||
{
|
||||
if (e.Row.RowType == DataControlRowType.DataRow)
|
||||
{
|
||||
|
||||
e.Row.Cells[11].Text = "";
|
||||
|
||||
LinkButton LnkEditar = e.Row.FCLinkButton("LnkEditar");
|
||||
LinkButton LnkTimbrar = e.Row.FCLinkButton("LnkTimbrar");
|
||||
LinkButton LnkCancelaTimbre = e.Row.FCLinkButton("LnkCancelaTimbre");
|
||||
@@ -469,9 +622,35 @@ public partial class General_RepEntregaAlmacenRuta : ClsPaginas
|
||||
LnkTimbrar.Visible = true;
|
||||
}
|
||||
|
||||
if (e.Row.DataKey("TimbreTipoDocto") == "Man")
|
||||
{
|
||||
e.Row.FCLinkButton("LnkEditarDirOrigen").Visible = true;
|
||||
e.Row.FCLinkButton("LnkEditarDirDestino").Visible = true;
|
||||
}
|
||||
|
||||
if (e.Row.DataKey("Estatus").ToEntero() == 1)
|
||||
{
|
||||
LnkCancelaTimbre.Visible = true;
|
||||
|
||||
if (bool.Parse(e.Row.DataKey("AplicaCP")))
|
||||
{
|
||||
e.Row.Cells[10].Text = "<a CssClass='btn btn-circle btn-sm blue' target= '_blank' href=\"/Compras/PopUpVerFactura.aspx?P=" + Extensiones.ModExtensiones.Encripta(String.Format("OP=CARPOTIMBRE&CVETIMBRE={0}", e.Row.DataKey("CveTimbre"))) + "\" ><i class='fa fa-file-pdf-o'></i></a>";
|
||||
}
|
||||
else
|
||||
{
|
||||
e.Row.Cells[10].Text = "<a CssClass='btn btn-circle btn-sm blue' target= '_blank' href=\"/Compras/PopUpVerFactura.aspx?P=" + Extensiones.ModExtensiones.Encripta(String.Format("OP=CARPO&CVETIMBRE={0}", e.Row.DataKey("CveTimbre"))) + "\" ><i class='fa fa-file-pdf-o'></i></a>";
|
||||
}
|
||||
|
||||
string ArchivoXML = String.Format("{0}/XML/{1}/{2}.xml", UsuarioActual.Empresa.Ruta, e.Row.DataKey("TimbreTipoDocto"), e.Row.DataKey("SerieFolio"));
|
||||
|
||||
if (File.Exists(ArchivoXML))
|
||||
{
|
||||
e.Row.Cells[11].Text = "<a CssClass='btn btn-circle btn-sm blue' target= '_blank' href=\"/Compras/PopUpVerFactura.aspx?P=" + Extensiones.ModExtensiones.Encripta(String.Format("OP=DesXmlTra&CVEMOVIMIENTO={0}&EXT={1}&FOLIO={2}&TIPODOCTO={3}", -1, "XML", e.Row.DataKey("SerieFolio"), e.Row.DataKey("TimbreTipoDocto"))) + "\" ><i class='fa fa-file-code-o'></i></a>";
|
||||
}
|
||||
|
||||
}else
|
||||
{
|
||||
e.Row.Cells[10].Text = "";
|
||||
}
|
||||
|
||||
if (e.Row.DataKey("Estatus").ToEntero() == 2)
|
||||
@@ -482,7 +661,7 @@ public partial class General_RepEntregaAlmacenRuta : ClsPaginas
|
||||
|
||||
switch (e.Row.DataKey("Tipo"))
|
||||
{
|
||||
case "E":
|
||||
case "E":
|
||||
e.Row.FCLabel("LtTipo").CssClass = "label label-sm label-success";
|
||||
break;
|
||||
case "T":
|
||||
@@ -495,8 +674,450 @@ public partial class General_RepEntregaAlmacenRuta : ClsPaginas
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
private void CargaPersonalChofer()
|
||||
{
|
||||
DdlModalChofer.Items.Clear();
|
||||
|
||||
ClsAcarreos ObjAcar = new ClsAcarreos();
|
||||
|
||||
if (ObjAcar.GetChofer(-1, UsuarioActual.CveEmpresa, 1, -1))
|
||||
{
|
||||
DdlModalChofer.DataSource = ObjAcar.DtResultados;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
ObjAcar.Dispose();
|
||||
|
||||
|
||||
DdlModalChofer.DataBind();
|
||||
|
||||
DdlModalChofer.Items.Insert(0, new ListItem("Seleccione Uno", "-1"));
|
||||
|
||||
|
||||
UpModalEditarentrega.Update();
|
||||
}
|
||||
|
||||
protected void RdTipo_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
CargaPersonalChofer();
|
||||
}
|
||||
protected void DdlModalCamion_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
DvRemolque1.Visible = false;
|
||||
DvRemolque2.Visible = false;
|
||||
|
||||
DdlRemolque1.SelectedValueExist(-1);
|
||||
DdlRemolque2.SelectedValueExist(-1);
|
||||
|
||||
if (DdlModalCamion.SelectedValue.ToEntero() > 0)
|
||||
{
|
||||
using (ClsInventarios ObjInv = new ClsInventarios())
|
||||
{
|
||||
if (ObjInv.GetCamiones(DdlModalCamion.SelectedValue.ToEntero(), UsuarioActual.CveEmpresa, 1))
|
||||
{
|
||||
DdlConfigAuto.SelectedValueExist(ObjInv.DtResultados.FiltroPrimeroValor("ConfigCartaPorte"));
|
||||
DdlConfigAuto_SelectedIndexChanged(null, null);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
UpModalEditarentrega.Update();
|
||||
}
|
||||
|
||||
public bool RequiereRemolque
|
||||
{
|
||||
get
|
||||
{
|
||||
if (ViewState["RequiereRemolque"] == null)
|
||||
ViewState["RequiereRemolque"] = false;
|
||||
|
||||
return bool.Parse(ViewState["RequiereRemolque"].ToString());
|
||||
}
|
||||
set
|
||||
{
|
||||
ViewState["RequiereRemolque"] = value;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public bool MostrarRemolques
|
||||
{
|
||||
get
|
||||
{
|
||||
if (ViewState["MostrarRemolques"] == null)
|
||||
ViewState["MostrarRemolques"] = false;
|
||||
|
||||
return bool.Parse(ViewState["MostrarRemolques"].ToString());
|
||||
}
|
||||
set
|
||||
{
|
||||
ViewState["MostrarRemolques"] = value;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
protected void DdlConfigAuto_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
ValidaConfiguracionVeiculo();
|
||||
}
|
||||
|
||||
|
||||
private void ValidaConfiguracionVeiculo()
|
||||
{
|
||||
DvRemolque1.Visible = false;
|
||||
DvRemolque2.Visible = false;
|
||||
|
||||
DdlRemolque1.SelectedValueExist(-1);
|
||||
DdlRemolque2.SelectedValueExist(-1);
|
||||
|
||||
if (DdlConfigAuto.SelectedIndex > 0)
|
||||
{
|
||||
using (ClsGenerales ObjGrales = new ClsGenerales())
|
||||
{
|
||||
if (ObjGrales.GetCartaPorteConfigAutoTransportes())
|
||||
{
|
||||
string Remolque = ObjGrales.DtResultados.FiltroPrimeroValor("Remolque", $" ClaveConfigAutoTransporte ='{DdlConfigAuto.SelectedValue}'");
|
||||
|
||||
|
||||
if (Remolque == "1")
|
||||
{
|
||||
RequiereRemolque = true;
|
||||
MostrarRemolques = true;
|
||||
}
|
||||
|
||||
if (Remolque == "0, 1")
|
||||
{
|
||||
RequiereRemolque = false;
|
||||
MostrarRemolques = true;
|
||||
}
|
||||
|
||||
if (Remolque == "0")
|
||||
{
|
||||
RequiereRemolque = false;
|
||||
MostrarRemolques = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
RequiereRemolque = false;
|
||||
MostrarRemolques = false;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
if (RequiereRemolque | MostrarRemolques)
|
||||
DvRemolque1.Visible = true;
|
||||
|
||||
if (!RequiereRemolque)
|
||||
DvConfiguracionVeiculo.Visible = false;
|
||||
else
|
||||
DvConfiguracionVeiculo.Visible = true;
|
||||
|
||||
|
||||
UpModalEditarentrega.Update();
|
||||
}
|
||||
|
||||
protected void DdlRemolque1_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
DdlRemolque2.Items.Clear();
|
||||
|
||||
if (DdlRemolque1.SelectedValue.ToEntero() > 0)
|
||||
{
|
||||
DvRemolque2.Visible = true;
|
||||
|
||||
using (ClsInventarios ObjInv = new ClsInventarios())
|
||||
{
|
||||
if (ObjInv.GetCamiones(-1, UsuarioActual.CveEmpresa, 2))
|
||||
DdlRemolque2.DataSource = ObjInv.DtResultados.FiltraParametros($"CveCamion <> {DdlRemolque1.SelectedValue.ToEntero()}");
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
DdlRemolque2.DataBind();
|
||||
}
|
||||
catch { }
|
||||
|
||||
}
|
||||
else
|
||||
DvRemolque2.Visible = false;
|
||||
|
||||
DdlRemolque2.Items.Insert(0, new ListItem("Seleccione uno", "-1"));
|
||||
|
||||
UpModalEditarentrega.Update();
|
||||
}
|
||||
|
||||
private bool validarRemolques()
|
||||
{
|
||||
bool Respuesta = false;
|
||||
|
||||
|
||||
if (RequiereRemolque & DdlRemolque1.SelectedValue.ToEntero() <= 0)
|
||||
Alert("La configuración de la carta porte requiere que seleccione un remolque", ModExtensiones.TipoMensaje.MsgAdvertencia);
|
||||
|
||||
if (RequiereRemolque & DdlRemolque1.SelectedValue.ToEntero() > 0)
|
||||
Respuesta = true;
|
||||
|
||||
|
||||
return Respuesta;
|
||||
}
|
||||
|
||||
|
||||
public void CargarCamiones()
|
||||
{
|
||||
DdlModalCamion.Items.Clear();
|
||||
DdlConfigAuto.Items.Clear();
|
||||
|
||||
using (ClsInventarios ObjInv = new ClsInventarios())
|
||||
{
|
||||
if (ObjInv.GetCamiones(-1, UsuarioActual.CveEmpresa, 1))
|
||||
DdlModalCamion.DataSource = ObjInv.DtResultados;
|
||||
|
||||
|
||||
if (ObjInv.GetCamiones(-1, UsuarioActual.CveEmpresa, 2))
|
||||
DdlRemolque1.DataSource = ObjInv.DtResultados;
|
||||
}
|
||||
|
||||
DdlModalCamion.DataBind();
|
||||
DdlModalCamion.Items.Insert(0, new ListItem("Seleccione uno", "-1"));
|
||||
|
||||
|
||||
DdlRemolque1.DataBind();
|
||||
DdlRemolque1.Items.Insert(0, new ListItem("Seleccione uno", "-1"));
|
||||
|
||||
|
||||
using (ClsGenerales ObjGrales = new ClsGenerales())
|
||||
{
|
||||
if (ObjGrales.GetCartaPorteConfigAutoTransportes())
|
||||
DdlConfigAuto.DataSource = ObjGrales.DtResultados;
|
||||
}
|
||||
|
||||
DdlConfigAuto.DataBind();
|
||||
DdlConfigAuto.Items.Insert(0, new ListItem("Seleccione una", "-1"));
|
||||
}
|
||||
|
||||
private void CargaCombosDirecionesClientesSAT()
|
||||
{
|
||||
CargaDirClientePais();
|
||||
CargaDirClienteEstado();
|
||||
CargaDirClienteMunicipio();
|
||||
CargaDirClienteLocalidad();
|
||||
CargaDirClienteColonia();
|
||||
}
|
||||
|
||||
|
||||
private void CargaDirClientePais()
|
||||
{
|
||||
DdlDirClientePais.DataSource = GlobalDTGralPaises;
|
||||
DdlDirClientePais.DataBind();
|
||||
DdlDirClientePais.SelectedValueExist("151");
|
||||
}
|
||||
|
||||
private void CargaDirClienteEstado()
|
||||
{
|
||||
DdlDirClienteEstado.Items.Clear();
|
||||
if (DdlDirClientePais.SelectedValue.ToEntero() > 0)
|
||||
DdlDirClienteEstado.DataSource = get_GlobalDTGralEstados("-1", DdlDirClientePais.SelectedValue.ToEntero());
|
||||
DdlDirClienteEstado.Items.Insert(0, new ListItem("Seleccione", "-1"));
|
||||
DdlDirClienteEstado.DataBind();
|
||||
}
|
||||
|
||||
private void CargaDirClienteMunicipio()
|
||||
{
|
||||
DdlDirClienteMunicipio.Items.Clear();
|
||||
if (DdlDirClienteEstado.SelectedValue.ToEntero() > 0)
|
||||
DdlDirClienteMunicipio.DataSource = get_GlobalDTGralMunicipios("-1", DdlDirClienteEstado.SelectedValue.ToEntero());
|
||||
DdlDirClienteMunicipio.Items.Insert(0, new ListItem("Seleccione", "-1"));
|
||||
DdlDirClienteMunicipio.DataBind();
|
||||
}
|
||||
|
||||
private void CargaDirClienteColonia()
|
||||
{
|
||||
DdlDirClienteColonia.Items.Clear();
|
||||
if (DdlDirClienteMunicipio.SelectedValue.ToEntero() > 0)
|
||||
DdlDirClienteColonia.DataSource = get_GlobalDTGralColonias("-1", "-1", "-1", DdlDirClienteMunicipio.SelectedValue.ToEntero(), CodigoPostal: TxtEnvioCP.Text.Trim().Length > 0 ? TxtEnvioCP.Text.ToEntero() : -1);
|
||||
DdlDirClienteColonia.Items.Insert(0, new ListItem("Seleccione", "-1"));
|
||||
DdlDirClienteColonia.DataBind();
|
||||
}
|
||||
|
||||
|
||||
protected void CargaDirClienteLocalidad()
|
||||
{
|
||||
DdlDirClienteLocalidad.Items.Clear();
|
||||
if (DdlDirClienteEstado.SelectedValue.ToEntero() > 0)
|
||||
{
|
||||
DdlDirClienteLocalidad.DataSource = get_GlobalDTLocalidad(DdlDirClienteEstado.SelectedValue.ToEntero(), DdlDirClienteMunicipio.SelectedValue.ToEntero());
|
||||
DdlDirClienteLocalidad.DataBind();
|
||||
}
|
||||
|
||||
DdlDirClienteLocalidad.Items.Insert(0, new ListItem("Seleccione una", "-1"));
|
||||
}
|
||||
|
||||
|
||||
protected void DdlDirClientePais_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
CargaDirClienteEstado();
|
||||
CargaDirClienteMunicipio();
|
||||
CargaDirClienteColonia();
|
||||
CargaDirClienteLocalidad();
|
||||
}
|
||||
|
||||
protected void DdlDirClienteEstado_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
CargaDirClienteMunicipio();
|
||||
CargaDirClienteColonia();
|
||||
CargaDirClienteLocalidad();
|
||||
}
|
||||
|
||||
protected void DdlDirClienteMunicipio_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
CargaDirClienteColonia();
|
||||
CargaDirClienteLocalidad();
|
||||
}
|
||||
|
||||
|
||||
protected void BtnDirClienteValidar_Click(object sender, EventArgs e)
|
||||
{
|
||||
DirClientevalidaCodigoPostal();
|
||||
}
|
||||
|
||||
|
||||
protected void DdlDirClienteColonia_SelectedIndexChanged(object sender, EventArgs e)
|
||||
{
|
||||
DirClientevalidaCodigoPostal();
|
||||
}
|
||||
|
||||
private void DirClientevalidaCodigoPostal()
|
||||
{
|
||||
int CPTxt = TxtEnvioCP.Text.ToEntero();
|
||||
|
||||
int CveColonia = DdlDirClienteColonia.SelectedValue.ToEntero();
|
||||
|
||||
if (CPTxt > 0 & CveColonia > 0)
|
||||
{
|
||||
int CP = get_GlobalDTGralColonias("-1", "-1", "-1", CveColonia: CveColonia).FiltroPrimeroValor("CP", "").ToEntero();
|
||||
if (CPTxt != CP)
|
||||
Alert("El código postal selecionado es diferente del codigo postal de la Colonia.", ModExtensiones.TipoMensaje.MsgAdvertencia);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public void EditDireccionOrigen_Click(object sender, EventArgs e)
|
||||
{
|
||||
//GridViewRow GvRow = (GridViewRow)(((LinkButton)sender).NamingContainer);
|
||||
//int CveDireccionOrigen = GvRow.DataKey("CveDireccionOrigen").ToEntero();
|
||||
CveDireccionEditar = CveDireccionOrigen;
|
||||
LblTitulodireccion.Text = "Actualizar dirección origen";
|
||||
CargaDatosDireccion(CveDireccionOrigen);
|
||||
}
|
||||
|
||||
public void EditDireccionDestino_Click(object sender, EventArgs e)
|
||||
{
|
||||
//GridViewRow GvRow = (GridViewRow)(((LinkButton)sender).NamingContainer);
|
||||
//LblTitulodireccion.Text = "Actualizar dirección destino";
|
||||
//int CveDireccionDestino = GvRow.DataKey("CveDireccionDestino").ToEntero();
|
||||
CveDireccionEditar = CveDireccionDestino;
|
||||
LblTitulodireccion.Text = "Actualizar dirección Destino";
|
||||
CargaDatosDireccion(CveDireccionDestino);
|
||||
}
|
||||
|
||||
|
||||
private void CargaDatosDireccion(int CveDireccion)
|
||||
{
|
||||
|
||||
ClsClientes ObjClientes = new ClsClientes();
|
||||
|
||||
DataTable DT = new DataTable();
|
||||
|
||||
if (ObjClientes.DireccionEnvioGet(CveDireccion, -1,-1))
|
||||
{
|
||||
DT = ObjClientes.DtResultados;
|
||||
}
|
||||
|
||||
ObjClientes.Dispose();
|
||||
|
||||
if (DT.Rows.Count > 0)
|
||||
{
|
||||
TxtEnvioDireccion.Text = DT.Rows[0]["EnvioDireccion"].ToString();
|
||||
TxtEnvioNoExt.Text = DT.Rows[0]["EnvioNoExt"].ToString();
|
||||
TxtEnvioNoInt.Text = DT.Rows[0]["EnvioNoInt"].ToString();
|
||||
|
||||
TxtEnvioCP.Text = DT.Rows[0]["EnvioCP"].ToString();
|
||||
// TxtEnvioTel.Text = GvRow.DataKey("EnvioTel")
|
||||
|
||||
DdlDirClientePais.SelectedValueExist(DT.Rows[0]["CvePais"].ToString());
|
||||
CargaDirClienteEstado();
|
||||
DdlDirClienteEstado.SelectedValueExist(DT.Rows[0]["CveEstado"].ToString());
|
||||
CargaDirClienteMunicipio();
|
||||
DdlDirClienteMunicipio.SelectedValueExist(DT.Rows[0]["CveMunicipio"].ToString());
|
||||
CargaDirClienteColonia();
|
||||
DdlDirClienteLocalidad.SelectedValueExist(DT.Rows[0]["CveLocalidad"].ToString());
|
||||
CargaDirClienteLocalidad();
|
||||
|
||||
DdlDirClienteColonia.SelectedValueExist(DT.Rows[0]["CveColonia"].ToString());
|
||||
}
|
||||
|
||||
UpModalDVDireccionEnvio.Update();
|
||||
RegistraScript("$('#divAddDireccionEnvio').modal('show');");
|
||||
|
||||
|
||||
}
|
||||
|
||||
public void BtnAgregarDireccion_Click(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
ClsClientes ObjCli = new ClsClientes();
|
||||
bool ErrorProceso = false;
|
||||
|
||||
//CveDireccionEditar
|
||||
if (!ObjCli.DireccionEnvioUpdate(-1, TxtEnvioDireccion.Text, TxtEnvioNoExt.Text, TxtEnvioNoInt.Text, "-1", "-1", "-1", TxtEnvioCP.Text.ToEntero(), "-1", UsuarioActual.CveUsuario, -1, CveDireccionEditar, "-1", -1, "-1",
|
||||
DdlDirClientePais.SelectedValue.ToEntero(), DdlDirClienteEstado.SelectedValue.ToEntero(), DdlDirClienteMunicipio.SelectedValue.ToEntero(), DdlDirClienteLocalidad.SelectedValue.ToEntero(), DdlDirClienteColonia.SelectedValue.ToEntero())){
|
||||
ErrorProceso = true;
|
||||
}
|
||||
|
||||
ObjCli.Dispose();
|
||||
|
||||
if (!ErrorProceso)
|
||||
{
|
||||
Alert("Dirección actualizada correctamente.");
|
||||
RegistraScript("$('#divAddDireccionEnvio').modal('hide');");
|
||||
CargaDatos();
|
||||
}
|
||||
|
||||
|
||||
ModalActualizaDirecciones(CveTimbre);
|
||||
|
||||
|
||||
}
|
||||
|
||||
private void LnkAgregarDireccion_Click(object sender, EventArgs e)
|
||||
{
|
||||
TxtEnvioDireccion.Text = "";
|
||||
TxtEnvioNoExt.Text = "";
|
||||
TxtEnvioNoInt.Text = "";
|
||||
TxtEnvioCP.Text = "";
|
||||
|
||||
CargaCombosDirecionesClientesSAT();
|
||||
TxtFechaLlegada.Text = "";
|
||||
|
||||
|
||||
|
||||
UpModalDVDireccionEnvio.Update();
|
||||
RegistraScript("$('#divAddDireccionEnvio').modal('show');");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
#endregion
|
||||
|
||||
@@ -509,4 +1130,3 @@ public partial class General_RepEntregaAlmacenRuta : ClsPaginas
|
||||
|
||||
|
||||
|
||||
}
|
||||
@@ -224,11 +224,41 @@
|
||||
<div class="row rowpadding">
|
||||
<label class="col-md-3">Unidad:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList runat="server" ID="DdlUnidadCamion" AutoPostBack="true" Width="100%" AppendDataBoundItems="true" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca"></asp:DropDownList>
|
||||
<asp:DropDownList runat="server" ID="DdlUnidadCamion" AutoPostBack="true" Width="100%" AppendDataBoundItems="true" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca" OnSelectedIndexChanged="DdlUnidadCamionActivoFijo_SelectedIndexChanged"></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlUnidadCamion" runat="server" Enabled="false" ControlToValidate="DdlUnidadCamion" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Unidad''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VceDdlUnidadCamion" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlUnidadCamion" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row rowpadding" runat="server" id="DvConfiguracionVeiculo" visible="false">
|
||||
<label class="col-md-3">Configuración:</label>
|
||||
<div class="col-md-9">
|
||||
<%--<asp:DropDownList runat="server" ID="DropDownList1" AutoPostBack="true" Width="100%" AppendDataBoundItems="true" CssClass="form-control input-sm select2me" DataValueField="CveActivoFijo" DataTextField="CodigoDescripcion"></asp:DropDownList>--%>
|
||||
<asp:DropDownList ID="DdlConfigAuto" CssClass="form-control input-sm select2me" Width="100%" runat="server" AppendDataBoundItems="true" AutoPostBack="true" OnSelectedIndexChanged="DdlConfigAuto_SelectedIndexChanged" CausesValidation="true" DataTextField="ClaveConfigAutoTransporteDescripcion" DataValueField="ClaveConfigAutoTransporte" Style="padding: 0px">
|
||||
</asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RfvDdlConfigAuto" runat="server" Enabled="false" ControlToValidate="DdlConfigAuto" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Configuración Carta Porte''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VCERfvDdlConfigAuto" runat="server" HighlightCssClass="vco" TargetControlID="RfvDdlConfigAuto" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row rowpadding" runat="server" id="DvRemolque1" visible="false">
|
||||
<label class="col-md-3">Remolque 1:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList runat="server" ID="DdlRemolque1" AutoPostBack="true" Width="100%" AppendDataBoundItems="true" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca" OnSelectedIndexChanged="DdlRemolque1_SelectedIndexChanged"></asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row rowpadding" runat="server" id="DvRemolque2" visible="false">
|
||||
<label class="col-md-3">Remolque 2:</label>
|
||||
<div class="col-md-9">
|
||||
<asp:DropDownList runat="server" ID="DdlRemolque2" AutoPostBack="true" Width="100%" CssClass="form-control input-sm select2me" DataValueField="CveCamion" DataTextField="CamionPlaca" ></asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="row rowpadding">
|
||||
<label class="col-md-3">F. Salida:</label>
|
||||
<div class="col-md-9" style="padding-top: 0px;">
|
||||
|
||||
@@ -673,6 +673,15 @@ Partial Class Inventarios_TraspasoAlmacen
|
||||
Dim CveClasificacion As Integer
|
||||
|
||||
Dim DrPS As DataRow = GlobalDTPS(UsuarioActual.CveEmpresa, CvePS:=CvePS).FiltroPrimero("")
|
||||
|
||||
|
||||
If ChkEmitirTimbrado.Checked Then
|
||||
If Not ValidaPSSAT(DrPS) Then
|
||||
Exit Sub
|
||||
End If
|
||||
End If
|
||||
|
||||
|
||||
If DrPS IsNot Nothing Then
|
||||
CveClasificacion = DrPS("CveClasificacion").ToString.ToEntero
|
||||
Dim DrUM = GlobalDTUnidadesMedida(UsuarioActual.CveEmpresa).FiltroPrimero($"CveUnidadMedida = {CveUnidadMedida}")
|
||||
@@ -1190,7 +1199,8 @@ Partial Class Inventarios_TraspasoAlmacen
|
||||
Dim CveSubProyectoTimbre As Integer = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltraParametros($"CveAlmacen = {DdlAlmacenOrigen.SelectedValue}").Rows(0)("CveSubProyecto").ToString.ToEntero
|
||||
Dim Fechallegada As DateTime = (TxtFechaLlegada.Text & " 23:59:59").ToDateTime
|
||||
|
||||
Dim CveEntregaAlmacen As Integer = ObjGral.AddInvEntregaAlmacenRuta(CveSubProyectoTimbre, -1, -1, CveMovimientoSalida, DdlChofer.SelectedValue.ToEntero, DdlUnidadCamion.SelectedValue.ToEntero, TxtFechaEntrega.Text.ToDate, Fechallegada, "T", "", "", MinFecha, 1, 1, 1)
|
||||
Dim CveEntregaAlmacen As Integer = ObjGral.AddInvEntregaAlmacenRuta(CveSubProyectoTimbre, -1, -1, CveMovimientoSalida, DdlChofer.SelectedValue.ToEntero, DdlUnidadCamion.SelectedValue.ToEntero, TxtFechaEntrega.Text.ToDate, TxtFechaLlegada.Text.ToDate, "T", "", "", MinFecha, 1, 1, TxtDistancia.Text.ToEntero,
|
||||
ConfigCartaPorte:=DdlConfigAuto.SelectedValue, CveCamionRemolque1:=DdlRemolque1.SelectedValue.ToEntero, CveCamionRemolque2:=DdlRemolque2.SelectedValue.ToEntero)
|
||||
|
||||
If CveEntregaAlmacen > 0 Then
|
||||
CveTimbre = ObjGral.AddGralTimbre("Tra", CveSubProyectoTimbre, TxtFechaEntrega.Text.ToDate, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CveEntregaAlmacen:=CveEntregaAlmacen, AplicaCP:=ChkEmitirCartaPorte.Checked)
|
||||
@@ -2962,10 +2972,47 @@ Partial Class Inventarios_TraspasoAlmacen
|
||||
End Sub
|
||||
|
||||
Public Sub CargarCamiones()
|
||||
|
||||
DdlConfigAuto.Items.Clear()
|
||||
DdlUnidadCamion.Items.Clear()
|
||||
|
||||
DdlUnidadCamion.DataSource = GlobalDTInvCamiones(UsuarioActual.CveEmpresa)
|
||||
'DdlUnidadCamion.DataSource = GlobalDTInvCamiones(UsuarioActual.CveEmpresa)
|
||||
'DdlUnidadCamion.DataBind()
|
||||
|
||||
|
||||
|
||||
Using ObjInv As New ClsInventarios
|
||||
|
||||
If ObjInv.GetCamiones(-1, UsuarioActual.CveEmpresa, 1) Then
|
||||
DdlUnidadCamion.DataSource = ObjInv.DtResultados
|
||||
End If
|
||||
|
||||
|
||||
If ObjInv.GetCamiones(-1, UsuarioActual.CveEmpresa, 2) Then
|
||||
DdlRemolque1.DataSource = ObjInv.DtResultados
|
||||
End If
|
||||
|
||||
End Using
|
||||
|
||||
DdlUnidadCamion.DataBind()
|
||||
DdlUnidadCamion.Items.Insert(0, New ListItem("Seleccione Uno", "-1"))
|
||||
|
||||
|
||||
DdlRemolque1.DataBind()
|
||||
DdlRemolque1.Items.Insert(0, New ListItem("Seleccione Uno", "-1"))
|
||||
|
||||
|
||||
|
||||
Using ObjGrales As New ClsGenerales
|
||||
|
||||
If ObjGrales.GetCartaPorteConfigAutoTransportes() Then
|
||||
DdlConfigAuto.DataSource = ObjGrales.DtResultados
|
||||
End If
|
||||
|
||||
End Using
|
||||
|
||||
DdlConfigAuto.DataBind()
|
||||
DdlConfigAuto.Items.Insert(0, New ListItem("Seleccione una", "-1"))
|
||||
|
||||
'Using ObjGral As New ClsGenerales
|
||||
' If ObjGral.GetCartaPorteConfigAutoTransportes() Then
|
||||
@@ -3092,6 +3139,220 @@ Partial Class Inventarios_TraspasoAlmacen
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
#Region "remolques"
|
||||
|
||||
|
||||
|
||||
|
||||
Protected Sub DdlUnidadCamionActivoFijo_SelectedIndexChanged(sender As Object, e As EventArgs)
|
||||
|
||||
|
||||
DvRemolque1.Visible = False
|
||||
DvRemolque2.Visible = False
|
||||
|
||||
DdlRemolque1.SelectedValueExist(-1)
|
||||
DdlRemolque2.SelectedValueExist(-1)
|
||||
|
||||
If DdlUnidadCamion.SelectedValue.ToEntero > 0 Then
|
||||
|
||||
|
||||
Using ObjInv As New ClsInventarios
|
||||
|
||||
If ObjInv.GetCamiones(DdlUnidadCamion.SelectedValue.ToEntero, UsuarioActual.CveEmpresa, 1) Then
|
||||
DdlConfigAuto.SelectedValueExist(ObjInv.DtResultados.FiltroPrimeroValor("ConfigCartaPorte"))
|
||||
DdlConfigAuto_SelectedIndexChanged(Nothing, Nothing)
|
||||
End If
|
||||
|
||||
End Using
|
||||
|
||||
|
||||
End If
|
||||
|
||||
UpEmitirTransitorio.Update()
|
||||
|
||||
End Sub
|
||||
|
||||
Property RequiereRemolque As Boolean
|
||||
Get
|
||||
If ViewState("RequiereRemolque") Is Nothing Then
|
||||
ViewState("RequiereRemolque") = False
|
||||
End If
|
||||
|
||||
Return Boolean.Parse(ViewState("RequiereRemolque").ToString)
|
||||
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
ViewState("RequiereRemolque") = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
|
||||
Property MostrarRemolques As Boolean
|
||||
Get
|
||||
If ViewState("MostrarRemolques") Is Nothing Then
|
||||
ViewState("MostrarRemolques") = False
|
||||
End If
|
||||
|
||||
Return Boolean.Parse(ViewState("MostrarRemolques").ToString)
|
||||
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
ViewState("MostrarRemolques") = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
|
||||
|
||||
Protected Sub DdlConfigAuto_SelectedIndexChanged(sender As Object, e As EventArgs)
|
||||
ValidaConfiguracionVeiculo()
|
||||
End Sub
|
||||
|
||||
|
||||
Private Sub ValidaConfiguracionVeiculo()
|
||||
DvRemolque1.Visible = False
|
||||
DvRemolque2.Visible = False
|
||||
|
||||
DdlRemolque1.SelectedValueExist(-1)
|
||||
DdlRemolque2.SelectedValueExist(-1)
|
||||
|
||||
If DdlConfigAuto.SelectedIndex > 0 Then
|
||||
|
||||
Using ObjGrales As New ClsGenerales
|
||||
If ObjGrales.GetCartaPorteConfigAutoTransportes() Then
|
||||
Dim Remolque As String = ObjGrales.DtResultados.FiltroPrimeroValor("Remolque", $" ClaveConfigAutoTransporte ='{DdlConfigAuto.SelectedValue}'")
|
||||
|
||||
|
||||
If Remolque = "1" Then
|
||||
RequiereRemolque = True
|
||||
MostrarRemolques = True
|
||||
End If
|
||||
|
||||
If Remolque = "0, 1" Then
|
||||
RequiereRemolque = False
|
||||
MostrarRemolques = True
|
||||
End If
|
||||
|
||||
If Remolque = "0" Then
|
||||
RequiereRemolque = False
|
||||
MostrarRemolques = False
|
||||
End If
|
||||
End If
|
||||
End Using
|
||||
|
||||
Else
|
||||
RequiereRemolque = False
|
||||
MostrarRemolques = False
|
||||
End If
|
||||
|
||||
|
||||
|
||||
|
||||
If RequiereRemolque Or MostrarRemolques Then
|
||||
DvRemolque1.Visible = True
|
||||
End If
|
||||
|
||||
If Not RequiereRemolque Then
|
||||
DvConfiguracionVeiculo.Visible = False
|
||||
Else
|
||||
DvConfiguracionVeiculo.Visible = True
|
||||
End If
|
||||
|
||||
|
||||
UpEmitirTransitorio.Update()
|
||||
End Sub
|
||||
|
||||
Protected Sub DdlRemolque1_SelectedIndexChanged(sender As Object, e As EventArgs)
|
||||
|
||||
DdlRemolque2.Items.Clear()
|
||||
|
||||
If DdlRemolque1.SelectedValue.ToEntero > 0 Then
|
||||
DvRemolque2.Visible = True
|
||||
|
||||
Using ObjInv As New ClsInventarios
|
||||
If ObjInv.GetCamiones(-1, UsuarioActual.CveEmpresa, 2) Then
|
||||
DdlRemolque2.DataSource = ObjInv.DtResultados.FiltraParametros($"CveCamion <> {DdlRemolque1.SelectedValue.ToEntero}")
|
||||
End If
|
||||
End Using
|
||||
|
||||
DdlRemolque2.DataBind()
|
||||
|
||||
|
||||
Else
|
||||
DvRemolque2.Visible = False
|
||||
End If
|
||||
|
||||
DdlRemolque2.Items.Insert(0, New ListItem("Seleccione uno", "-1"))
|
||||
|
||||
UpEmitirTransitorio.Update()
|
||||
|
||||
End Sub
|
||||
|
||||
Private Function validarRemolques() As Boolean
|
||||
Dim Respuesta As Boolean = False
|
||||
|
||||
|
||||
If RequiereRemolque And DdlRemolque1.SelectedValue.ToEntero <= 0 Then
|
||||
Alert("La configuración de la carta porte requiere que seleccione un remolque", TipoMensaje.MsgAdvertencia)
|
||||
End If
|
||||
|
||||
If RequiereRemolque And DdlRemolque1.SelectedValue.ToEntero > 0 Then
|
||||
Respuesta = True
|
||||
End If
|
||||
|
||||
If Not RequiereRemolque Then
|
||||
Respuesta = True
|
||||
End If
|
||||
|
||||
Return Respuesta
|
||||
|
||||
End Function
|
||||
|
||||
|
||||
|
||||
Function ValidaPSSAT(DrPS As DataRow) As Boolean
|
||||
Dim Respuesta As Boolean = False
|
||||
|
||||
Dim CveSATPS As Integer = DrPS("CveSATPS").ToString.ToEntero
|
||||
Dim PesoKg As Decimal = DrPS("PesoKg").ToString.ToDecimal
|
||||
Dim SATClaveUnidadMedida As String = DrPS("SATClaveUnidadMedida").ToString.Trim
|
||||
|
||||
If CveSATPS > 0 And PesoKg > 0 And SATClaveUnidadMedida.Length > 0 Then
|
||||
Respuesta = True
|
||||
Else
|
||||
Respuesta = False
|
||||
Dim SBMensaje As New StringBuilder
|
||||
|
||||
SBMensaje.AppendLine("El producto seleccionado presenta la siguiente situación: <br>")
|
||||
|
||||
If CveSATPS <= 0 Then
|
||||
SBMensaje.AppendLine("-Producto SAT no asignado. <br>")
|
||||
End If
|
||||
|
||||
|
||||
If PesoKg = 0 Then
|
||||
SBMensaje.AppendLine("-Producto sin peso definido. <br>")
|
||||
End If
|
||||
|
||||
|
||||
If SATClaveUnidadMedida.Length = 0 Then
|
||||
SBMensaje.AppendLine("-Producto sin unidad de medida SAT asignada. ")
|
||||
End If
|
||||
|
||||
|
||||
SBMensaje.AppendLine($"<br><br> <strong><a class='texto' target='_blank' href='../Ventas/ProductosServicios.aspx?CvePS={DrPS("CvePS").ToString}' > Corregir Producto </a></strong>")
|
||||
|
||||
|
||||
Alert(SBMensaje.ToString, TipoMensaje.MsgAdvertencia)
|
||||
|
||||
End If
|
||||
|
||||
|
||||
Return Respuesta
|
||||
End Function
|
||||
|
||||
#End Region
|
||||
End Class
|
||||
|
||||
|
||||
|
||||
@@ -5826,4 +5826,9 @@ Partial Class RH_Reclutamiento
|
||||
#End Region
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
End Class
|
||||
@@ -1238,8 +1238,9 @@ Partial Class ProductosyServicios
|
||||
|
||||
|
||||
If DdlSATPS.txtValue.Value.ToEntero > 0 Then
|
||||
ValidaMaterialPeligroso(DdlSATPS.txtValue.Value.ToEntero)
|
||||
If Not ValidaMaterialPeligrosoMensaje Then
|
||||
ValidaMaterialPeligroso(DdlSATPS.txtValue.Value.ToEntero)
|
||||
|
||||
Exit Sub
|
||||
End If
|
||||
End If
|
||||
|
||||
Reference in New Issue
Block a user