Merge branch 'master' of http://oirigoyen@192.168.10.111:8383/SIG.git
This commit is contained in:
14
AF/AF.aspx
14
AF/AF.aspx
@@ -428,12 +428,10 @@
|
||||
<label class=" control-label">Cliente: </label>
|
||||
</div>
|
||||
|
||||
<div class="col-md-7">
|
||||
<div class="form-group">
|
||||
<asp:DropDownList CssClass="form-control input-sm input-medium select2me" ID="DdlClientes" runat="server" AppendDataBoundItems="true" DataTextField="Nombre" DataValueField="CveCliente" Width="200px" ValidationGroup="GrpGuardar">
|
||||
<asp:ListItem Selected="True" Text="Sin Cliente Asignado" Value="-1"></asp:ListItem>
|
||||
</asp:DropDownList>
|
||||
</div>
|
||||
<div class="col-md-7">
|
||||
<div class="form-group">
|
||||
<ADS:Dropdownlost ID="Ddlclientes" Width="100%" CssStyle="width: 100%;" UsaWebService="true" AppendDataBoundItems="true" AutoPostBack="true" CssClass="select2me" data-metodo="getcliente" runat="server" DataTextField="NombreComercial" DataValueField="CveCliente"></ADS:Dropdownlost>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -2555,8 +2553,8 @@
|
||||
<div class="row">
|
||||
<div class="col-md-5">
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<asp:DropDownList ID="DdlProveedor" runat="server" DataValueField="CveProveedor" DataTextField="RazonSocial" CssClass="form-control select2me" AppendDataBoundItems="true"></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator ID="RFVProveedor" runat="server" ControlToValidate="DdlProveedor" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Compañia''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpObligatorioP"></asp:RequiredFieldValidator>
|
||||
<ADS:DropDownLost ID="DdlProveedor" Width="100%" CssStyle="width: 100%;" runat="server" UsaWebService="true" data-metodo="getproveedores" DataValueField="CveProveedor" DataTextField="RazonSocial" CssClass="form-control select2me" AppendDataBoundItems="true"></ADS:DropDownLost>
|
||||
<%--<asp:RequiredFieldValidator ID="RFVProveedor" runat="server" ControlToValidate="DdlProveedor" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Compañia''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpObligatorioP"></asp:RequiredFieldValidator>--%>
|
||||
<label for="<%= DdlProveedor.ClientID.ToString()%>">Proveedor:</label>
|
||||
</div>
|
||||
|
||||
|
||||
@@ -381,7 +381,7 @@ Partial Class AF_AF
|
||||
CargaEstatusActivoFijo()
|
||||
CargarCentrosDeCosto(DdlProyecto, DdlSubProyecto, lblProyecto, LblSubProyecto)
|
||||
RowProyecto.Visible = DdlProyecto.Visible
|
||||
CargaCliente()
|
||||
'CargaCliente()
|
||||
CargaGrupos()
|
||||
CargaMarcas()
|
||||
CargaTiposAgenda()
|
||||
@@ -471,10 +471,10 @@ Partial Class AF_AF
|
||||
DdlEstadoActivoFijo.DataSource = GlobalDTEstadoActivoFijo
|
||||
DdlEstadoActivoFijo.DataBind()
|
||||
End Sub
|
||||
Private Sub CargaCliente()
|
||||
DdlClientes.DataSource = GlobalDTCliente(UsuarioActual.CveEmpresa)
|
||||
DdlClientes.DataBind()
|
||||
End Sub
|
||||
'Private Sub CargaCliente()
|
||||
' DdlClientes.DataSource = GlobalDTCliente(UsuarioActual.CveEmpresa)
|
||||
' DdlClientes.DataBind()
|
||||
'End Sub
|
||||
|
||||
Protected Sub DdlProyecto_SelectedIndexChanged(sender As Object, e As System.EventArgs) Handles DdlProyecto.SelectedIndexChanged
|
||||
CargaSubProyecto()
|
||||
@@ -667,8 +667,11 @@ Partial Class AF_AF
|
||||
DdlResponsable.SelectedValue = ObjActivoFijo.DtResultados.Rows(0)("CvePersonaResponsable").ToString
|
||||
DdlProyecto.SelectedValue = ObjActivoFijo.CveProyecto.ToString
|
||||
CargaSubProyecto()
|
||||
DdlSubProyecto.SelectedValue = ObjActivoFijo.DtResultados.Rows(0)("CveSubProyecto").ToString
|
||||
DdlClientes.SelectedValueExist(ObjActivoFijo.CveCliente)
|
||||
DdlSubProyecto.SelectedValue = ObjActivoFijo.DtResultados.Rows(0)("CveSubProyecto").ToString
|
||||
Ddlclientes.SelectedValue = ObjActivoFijo.CveCliente.ToString
|
||||
If ObjActivoFijo.CveCliente > 0 Then
|
||||
Ddlclientes.SelectedText = GlobalDTCliente(UsuarioActual.CveEmpresa, CveCliente:=ObjActivoFijo.CveCliente).FiltroPrimeroValor("NombreComercial")
|
||||
End If
|
||||
DdlMarcas.SelectedValueExist(ObjActivoFijo.CveMarcaActivoFijo)
|
||||
CargaModelos(DdlMarcas.SelectedValue.ToEntero)
|
||||
DdlModelos.SelectedValueExist(ObjActivoFijo.CveModeloActivoFijo)
|
||||
@@ -971,10 +974,10 @@ Partial Class AF_AF
|
||||
UpDatos.Update()
|
||||
End Sub
|
||||
Private Sub CargaProveedor()
|
||||
DdlProveedor.Items.Clear()
|
||||
DdlProveedor.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
DdlProveedor.DataSource = GlobalDTCompProveedores(UsuarioActual.CveEmpresa)
|
||||
DdlProveedor.DataBind()
|
||||
'DdlProveedor.Items.Clear()
|
||||
'DdlProveedor.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
'DdlProveedor.DataSource = GlobalDTCompProveedores(UsuarioActual.CveEmpresa)
|
||||
'DdlProveedor.DataBind()
|
||||
|
||||
UpAddPolizas.Update()
|
||||
End Sub
|
||||
@@ -1009,7 +1012,7 @@ Partial Class AF_AF
|
||||
UpDatos.Update()
|
||||
BtnAgregarPoliza.Text = "Agregar"
|
||||
LabelPolizas.InnerText = "Agregar Póliza de seguro"
|
||||
DdlProveedor.SelectedIndex = 0
|
||||
'DdlProveedor.SelectedIndex = 0
|
||||
TxtPolizaSeguro.Text = ""
|
||||
TxtFechaExpPoliza.Text = ""
|
||||
TxtFechaVenPoliza.Text = ""
|
||||
|
||||
@@ -6229,30 +6229,6 @@ Public Class ClsContabilidad
|
||||
|
||||
#End Region
|
||||
|
||||
#Region "IDisposable Support"
|
||||
' IDisposable
|
||||
Protected Overridable Sub Dispose(disposing As Boolean)
|
||||
If Not Me.disposedValue Then
|
||||
If disposing Then
|
||||
|
||||
If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
|
||||
If Not DSet Is Nothing Then DSet.Dispose() : DSet = Nothing
|
||||
If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
|
||||
If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
|
||||
If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
|
||||
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
|
||||
If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
|
||||
|
||||
End If
|
||||
End If
|
||||
Me.disposedValue = True
|
||||
End Sub
|
||||
Public Sub Dispose() Implements IDisposable.Dispose
|
||||
ConexionClose()
|
||||
Dispose(True)
|
||||
GC.SuppressFinalize(Me)
|
||||
End Sub
|
||||
#End Region
|
||||
#Region "Periodos Bloqueo Meses"
|
||||
Public Function GetPeriodosBloqueo(CveEmpresa As Integer) As Boolean
|
||||
Dim Retorno = False
|
||||
@@ -6376,8 +6352,6 @@ Public Class ClsContabilidad
|
||||
End Function
|
||||
#End Region
|
||||
|
||||
|
||||
|
||||
#Region "ESTADO RESULTADOS HORIZONTAL"
|
||||
|
||||
|
||||
@@ -6567,4 +6541,32 @@ Public Class ClsContabilidad
|
||||
|
||||
Return Retorno
|
||||
End Function
|
||||
|
||||
|
||||
#Region "IDisposable Support"
|
||||
' IDisposable
|
||||
Protected Overridable Sub Dispose(disposing As Boolean)
|
||||
If Not Me.disposedValue Then
|
||||
If disposing Then
|
||||
|
||||
If Not Data Is Nothing Then Data.Dispose() : Data = Nothing
|
||||
If Not DSet Is Nothing Then DSet.Dispose() : DSet = Nothing
|
||||
If Not SqlAdapter Is Nothing Then SqlAdapter.Dispose() : SqlAdapter = Nothing
|
||||
If Not SqlCommand Is Nothing Then SqlCommand.Dispose() : SqlCommand = Nothing
|
||||
If Not SqlTransacc Is Nothing Then SqlTransacc.Dispose() : SqlTransacc = Nothing
|
||||
If SqlConexion.State <> ConnectionState.Closed Then SqlConexion.Close()
|
||||
If Not SqlConexion Is Nothing Then SqlConexion.Dispose() : SqlConexion = Nothing
|
||||
|
||||
End If
|
||||
End If
|
||||
Me.disposedValue = True
|
||||
End Sub
|
||||
Public Sub Dispose() Implements IDisposable.Dispose
|
||||
ConexionClose()
|
||||
Dispose(True)
|
||||
GC.SuppressFinalize(Me)
|
||||
End Sub
|
||||
#End Region
|
||||
|
||||
|
||||
End Class
|
||||
@@ -131,6 +131,8 @@ Public Class ClsInventarios
|
||||
Public Property ResponsableCarga As String
|
||||
Public Property ResponsableRecibio As String
|
||||
Public Property Modulo As String
|
||||
Public Property ConAplicacion As Boolean
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1279,7 +1281,7 @@ Public Class ClsInventarios
|
||||
Optional CveSeccionAlmacen As Integer = -1, Optional Serie As String = "", Optional Lote As String = "", Optional FechaCaducidad As Date = MinFecha,
|
||||
Optional Observaciones As String = "", Optional CveMovimientoDetalleEntrada As Integer = -1, Optional PUTC As Decimal = -1,
|
||||
Optional CostoIndirecto As Decimal = 0, Optional CveCompraDetalle As Integer = -1, Optional CveOrdenCompraDetalle As Integer = -1, Optional CveVentaDetalle As Integer = -1,
|
||||
Optional CveContratoDetalle As Integer = -1, Optional CveUsuarioModifico As Integer = -1, Optional EsInterno As Integer = -1) As Boolean
|
||||
Optional CveContratoDetalle As Integer = -1, Optional CveUsuarioModifico As Integer = -1, Optional EsInterno As Integer = -1, Optional CveVentaDetallePadre As Integer = -1) As Boolean
|
||||
Dim Retorno As Boolean = False
|
||||
|
||||
DataAdapter("PA_Inv_MovimientosDetalleAdd")
|
||||
@@ -1305,6 +1307,7 @@ Public Class ClsInventarios
|
||||
.Add("@CveContratoDetalle", SqlDbType.Int).Value = CveContratoDetalle
|
||||
.Add("@CveUsuarioModifico", SqlDbType.Int).Value = CveUsuarioModifico
|
||||
.Add("@EsInterno", SqlDbType.Int).Value = EsInterno
|
||||
.Add("@CveVentaDetallePadre", SqlDbType.Int).Value = CveVentaDetallePadre
|
||||
|
||||
.Add("@CveMovimientoDetalle", SqlDbType.Int).Direction = ParameterDirection.Output
|
||||
End With
|
||||
@@ -2306,6 +2309,8 @@ Public Class ClsInventarios
|
||||
FechaI = dr("FechaInicio").ToString
|
||||
FechaF = dr("FechaFin").ToString
|
||||
Estatus = dr("Estatus").ToString
|
||||
ConAplicacion = Convert.ToBoolean(dr("ConAplicacion").ToString)
|
||||
|
||||
Retorno = True
|
||||
End If
|
||||
|
||||
|
||||
@@ -1157,7 +1157,7 @@ Public Class ClsPaginas
|
||||
Dim AppNombre As String = String.Format("GlobalDTProyectosUsuarios-{0}", CveEmpresa)
|
||||
If Application(AppNombre) Is Nothing Then
|
||||
Dim ObjSubProyectos As New ClsSubProyectos()
|
||||
If ObjSubProyectos.GetSubProyectosUsuarios Then Application(AppNombre) = ObjSubProyectos.DtResultados.FiltraParametros("", "", {"Proyecto", "CveProyecto", "CveUsuario", "CveEmpresa", "CveEstatusProyecto"}) Else Alert("Ocurrió un error al cargar los Proyectos. Por favor comuniquese con sistemas.", TipoMensaje.MsgError)
|
||||
If ObjSubProyectos.GetSubProyectosUsuarios(CveEmpresa:=CveEmpresa) Then Application(AppNombre) = ObjSubProyectos.DtResultados.FiltraParametros("", "", {"Proyecto", "CveProyecto", "CveUsuario", "CveEmpresa", "CveEstatusProyecto"}) Else Alert("Ocurrió un error al cargar los Proyectos. Por favor comuniquese con sistemas.", TipoMensaje.MsgError)
|
||||
ObjSubProyectos.Dispose()
|
||||
GuardaLog("Se Cargo GlobalDTProyectosUsuarios")
|
||||
End If
|
||||
@@ -5706,6 +5706,7 @@ Public Class ClsPaginas
|
||||
Bytes = wsreport.StreamPDFBytes(RutaReporte, ds, params.ToArray(), NombreArchivo, Formato, CveEmpresa, CveUsuario)
|
||||
wsreport = Nothing
|
||||
params = Nothing
|
||||
ds.Dispose() : ds = Nothing
|
||||
Else
|
||||
If IsNothing(MR) Then MR = New ReportViewer
|
||||
Try
|
||||
@@ -5735,6 +5736,7 @@ Public Class ClsPaginas
|
||||
'GuardaLog($"Error {ex.InnerException.Message} | Descripcion: {If(ex.InnerException.InnerException IsNot Nothing, ex.InnerException.InnerException.Message, "Sin descripcion")} - Ruta {RutaReporte}")
|
||||
End Try
|
||||
MR.Dispose()
|
||||
MR = Nothing
|
||||
'Dim ruta = wsreport.StreamPDF(RutaReporte, ds, params.ToArray(), NombreArchivo, Formato, CveEmpresa, CveUsuario)
|
||||
'If File.Exists(ruta) Then
|
||||
' Bytes = File.ReadAllBytes(ruta)
|
||||
|
||||
@@ -6582,6 +6582,8 @@ Namespace Modelos
|
||||
Me.ClienteSucursal.Sucursal = Cliente.Sucursal
|
||||
Me.ClienteSucursal.ImprimeNombreSucursal = Cliente.ImprimeNombreSucursal.ToString()
|
||||
End If
|
||||
Else
|
||||
Cliente = New Modelos.ClienteModel()
|
||||
End If
|
||||
End Sub
|
||||
Public Sub SetMoneda()
|
||||
@@ -9791,6 +9793,9 @@ Namespace Modelos
|
||||
Inherits Modelos.EntityModel
|
||||
Protected Overloads Sub SetDefaultValues()
|
||||
CveCliente = -1
|
||||
Nombre = ""
|
||||
RFC = ""
|
||||
Codigo = ""
|
||||
EnviarFactura = "Si"
|
||||
Estatus = "Activo"
|
||||
NoExt = ""
|
||||
|
||||
@@ -3658,6 +3658,7 @@ Public Class Timbrado
|
||||
|
||||
|
||||
|
||||
|
||||
End If
|
||||
|
||||
#Region "Complemento Pago"
|
||||
@@ -3780,6 +3781,159 @@ Public Class Timbrado
|
||||
End If
|
||||
#End Region
|
||||
|
||||
|
||||
#Region "C O M P L E M E N T O C A R T A P O R T E"
|
||||
|
||||
If ObjCFDITimbre.Complementos.CartaPorte IsNot Nothing Then
|
||||
If ObjCFDITimbre.Complementos.CartaPorte IsNot Nothing Then
|
||||
|
||||
Dim Carta As CFDICartaPorte = ObjCFDITimbre.Complementos.CartaPorte
|
||||
|
||||
|
||||
|
||||
''DATOS GENERALES
|
||||
Dim ComCartaPorte = New Profact.TimbraCFDI33.Complementos.CartaPorte10.CartaPorte()
|
||||
Dim Transp As Profact.TimbraCFDI33.Complementos.CartaPorte10.CartaPorteTranspInternac
|
||||
ComCartaPorte.TranspInternac = If(Carta.TranspInternac = "No", Transp.No, Transp.Sí)
|
||||
ComCartaPorte.EntradaSalidaMercSpecified = False
|
||||
ComCartaPorte.ViaEntradaSalidaSpecified = False
|
||||
ComCartaPorte.TotalDistRecSpecified = False
|
||||
|
||||
'UBICACIONES
|
||||
If Carta.Ubicaciones IsNot Nothing AndAlso Carta.Ubicaciones.Count > 0 Then
|
||||
Dim i As Integer = 0
|
||||
ComCartaPorte.Ubicaciones = New Profact.TimbraCFDI33.Complementos.CartaPorte10.CartaPorteUbicacion(Carta.Ubicaciones.Count - 1) {}
|
||||
For Each ubica As CFDICartaPorteUbicaciones In Carta.Ubicaciones
|
||||
'origen
|
||||
ComCartaPorte.Ubicaciones(i) = New Profact.TimbraCFDI33.Complementos.CartaPorte10.CartaPorteUbicacion
|
||||
ComCartaPorte.Ubicaciones(i).TipoEstacionSpecified = False
|
||||
ComCartaPorte.Ubicaciones(i).DistanciaRecorrida = ubica.DistanciaRecorrida
|
||||
ComCartaPorte.Ubicaciones(i).Origen = New Profact.TimbraCFDI33.Complementos.CartaPorte10.CartaPorteUbicacionOrigen With {.IDOrigen = ubica.Origen.IDOrigen,
|
||||
.RFCRemitente = ubica.Origen.RFCRemitente,
|
||||
.NombreRemitente = ubica.Origen.NombreRemitente,
|
||||
.FechaHoraSalida = ubica.Origen.FechaHoraSalida.ToDate}
|
||||
ComCartaPorte.Ubicaciones(i).Domicilio = New Profact.TimbraCFDI33.Complementos.CartaPorte10.CartaPorteUbicacionDomicilio With {.Calle = ubica.Origen.Domicilio.Calle,
|
||||
.NumeroExterior = ubica.Origen.Domicilio.NumeroExterior,
|
||||
.NumeroInterior = ubica.Origen.Domicilio.NumeroInterior,
|
||||
.Colonia = ubica.Origen.Domicilio.Colonia,
|
||||
.Localidad = ubica.Origen.Domicilio.Localidad,
|
||||
.Referencia = ubica.Origen.Domicilio.Referencia,
|
||||
.Municipio = ubica.Origen.Domicilio.Municipio,
|
||||
.Estado = ubica.Origen.Domicilio.Estado,
|
||||
.CodigoPostal = ubica.Origen.Domicilio.CP}
|
||||
'falta pais
|
||||
|
||||
|
||||
|
||||
ComCartaPorte.Ubicaciones(i).Destino = New Profact.TimbraCFDI33.Complementos.CartaPorte10.CartaPorteUbicacionDestino With {.IDDestino = ubica.Destino.IDDestino,
|
||||
.RFCDestinatario = ubica.Destino.RFCDestinatario,
|
||||
.NombreDestinatario = ubica.Destino.NombreDestinatario,
|
||||
.FechaHoraProgLlegada = ubica.Destino.FechaHoraProgLlegada.ToDate}
|
||||
|
||||
ComCartaPorte.Ubicaciones(i).Domicilio = New Profact.TimbraCFDI33.Complementos.CartaPorte10.CartaPorteUbicacionDomicilio With {.Calle = ubica.Destino.Domicilio.Calle,
|
||||
.NumeroExterior = ubica.Destino.Domicilio.NumeroExterior,
|
||||
.NumeroInterior = ubica.Destino.Domicilio.NumeroInterior,
|
||||
.Colonia = ubica.Destino.Domicilio.Colonia,
|
||||
.Localidad = ubica.Destino.Domicilio.Localidad,
|
||||
.Referencia = ubica.Destino.Domicilio.Referencia,
|
||||
.Municipio = ubica.Destino.Domicilio.Municipio,
|
||||
.Estado = ubica.Destino.Domicilio.Estado,
|
||||
.CodigoPostal = ubica.Destino.Domicilio.CP}
|
||||
|
||||
|
||||
'cfdi.CartaPorteUbicacion(ubica.TipoEstacion, ubica.DistanciaRecorrida)
|
||||
'cfdi.CartaPorteOrigen(ubica.Origen.IDOrigen, ubica.Origen.RFCRemitente, ubica.Origen.NombreRemitente, ubica.Origen.NumRegIdTrib, ubica.Origen.ResidenciaFiscal, ubica.Origen.NumEstacion, ubica.Origen.NombreEstacion, ubica.Origen.NavegacionTrafico, ubica.Origen.FechaHoraSalida)
|
||||
'cfdi.CartaPorteDomicilio(ubica.Origen.Domicilio.Calle, ubica.Origen.Domicilio.NumeroExterior, ubica.Origen.Domicilio.NumeroInterior, ubica.Origen.Domicilio.Colonia, ubica.Origen.Domicilio.Localidad, ubica.Origen.Domicilio.Referencia, ubica.Origen.Domicilio.Municipio, ubica.Origen.Domicilio.Estado, ubica.Origen.Domicilio.Pais, ubica.Origen.Domicilio.CP)
|
||||
'destino
|
||||
'cfdi.CartaPorteUbicacion(ubica.TipoEstacion, ubica.DistanciaRecorrida)
|
||||
'cfdi.CartaPorteDestino(ubica.Destino.IDDestino, ubica.Destino.RFCDestinatario, ubica.Destino.NombreDestinatario, ubica.Destino.NumRegIdTrib, ubica.Destino.ResidenciaFiscal, ubica.Destino.NumEstacion, ubica.Destino.NombreEstacion, ubica.Destino.NavegacionTrafico, ubica.Destino.FechaHoraProgLlegada)
|
||||
'cfdi.CartaPorteDomicilio(ubica.Destino.Domicilio.Calle, ubica.Destino.Domicilio.NumeroExterior, ubica.Destino.Domicilio.NumeroInterior, ubica.Destino.Domicilio.Colonia, ubica.Destino.Domicilio.Localidad, ubica.Destino.Domicilio.Referencia, ubica.Destino.Domicilio.Municipio, ubica.Destino.Domicilio.Estado, ubica.Destino.Domicilio.Pais, ubica.Destino.Domicilio.CP)
|
||||
Next
|
||||
|
||||
End If
|
||||
|
||||
'MERCANCIAS
|
||||
If Carta.Mercancias IsNot Nothing Then
|
||||
ComCartaPorte.Mercancias = New Profact.TimbraCFDI33.Complementos.CartaPorte10.CartaPorteMercancias
|
||||
ComCartaPorte.Mercancias.PesoBrutoTotal = Carta.Mercancias.PesoBrutoTotal.ToDecimal
|
||||
ComCartaPorte.Mercancias.PesoNetoTotal = Carta.Mercancias.PesoNetoTotal.ToDecimal
|
||||
ComCartaPorte.Mercancias.NumTotalMercancias = Carta.Mercancias.NumTotalMercancias
|
||||
ComCartaPorte.Mercancias.CargoPorTasacion = Carta.Mercancias.CargoporTasacion.ToDecimal
|
||||
' ComCartaPorte.Mercancias.UnidadPeso = Carta.Mercancias.UnidadPeso
|
||||
|
||||
If Carta.Mercancias IsNot Nothing AndAlso Carta.Mercancias.Mercancias.Count > 0 Then
|
||||
Dim i As Integer = 0
|
||||
ComCartaPorte.Mercancias.Mercancia = New Profact.TimbraCFDI33.Complementos.CartaPorte10.CartaPorteMercanciasMercancia(Carta.Mercancias.Mercancias.Count - 1) {}
|
||||
For Each concep As CFDICartaPorteMercancia In Carta.Mercancias.Mercancias
|
||||
ComCartaPorte.Mercancias.Mercancia(i) = New Profact.TimbraCFDI33.Complementos.CartaPorte10.CartaPorteMercanciasMercancia
|
||||
ComCartaPorte.Mercancias.Mercancia(i).BienesTranspSpecified = False
|
||||
ComCartaPorte.Mercancias.Mercancia(i).ClaveSTCCSpecified = False
|
||||
ComCartaPorte.Mercancias.Mercancia(i).Descripcion = concep.Descripción
|
||||
ComCartaPorte.Mercancias.Mercancia(i).Cantidad = concep.Cantidad
|
||||
ComCartaPorte.Mercancias.Mercancia(i).ClaveUnidadSpecified = False
|
||||
ComCartaPorte.Mercancias.Mercancia(i).Unidad = concep.Unidad
|
||||
ComCartaPorte.Mercancias.Mercancia(i).Dimensiones = concep.Dimensiones
|
||||
ComCartaPorte.Mercancias.Mercancia(i).MaterialPeligrosoSpecified = False
|
||||
ComCartaPorte.Mercancias.Mercancia(i).CveMaterialPeligrosoSpecified = False
|
||||
ComCartaPorte.Mercancias.Mercancia(i).EmbalajeSpecified = False
|
||||
ComCartaPorte.Mercancias.Mercancia(i).DescripEmbalaje = concep.DescripEmbalaje
|
||||
ComCartaPorte.Mercancias.Mercancia(i).PesoEnKg = concep.PesoenKg
|
||||
ComCartaPorte.Mercancias.Mercancia(i).ValorMercanciaSpecified = False
|
||||
ComCartaPorte.Mercancias.Mercancia(i).MonedaSpecified = False
|
||||
ComCartaPorte.Mercancias.Mercancia(i).FraccionArancelariaSpecified = False
|
||||
ComCartaPorte.Mercancias.Mercancia(i).UUIDComercioExt = concep.UUIDComercioExt
|
||||
|
||||
'cfdi.CartaPorteMercancia(concep.BienesTransp, concep.ClaveSTCC, concep.Descripción, concep.Cantidad, concep.ClaveUnidad, concep.Unidad, concep.Dimensiones, concep.MaterialPeligroso, concep.ClaveMaterialPeligroso, concep.Embalaje, concep.DescripEmbalaje, concep.PesoenKg, concep.ValorMercancia, concep.Moneda, concep.FraccionArrancelaria, concep.UUIDComercioExt)
|
||||
Next
|
||||
End If
|
||||
End If
|
||||
|
||||
'
|
||||
If Carta.FiguraTransporte IsNot Nothing Then
|
||||
|
||||
If Carta.FiguraTransporte.AutoTransporteFederal IsNot Nothing Then
|
||||
ComCartaPorte.FiguraTransporte = New Profact.TimbraCFDI33.Complementos.CartaPorte10.CartaPorteFiguraTransporte
|
||||
|
||||
ComCartaPorte.FiguraTransporte.CveTransporte = Profact.TimbraCFDI33.Complementos.CartaPorte10.c_CveTransporte.Item02
|
||||
'ComCartaPorte.FiguraTransporte.CveTransporte.
|
||||
|
||||
'cfdi.CartaPorteAutotransporteFederal(Carta.FiguraTransporte.AutoTransporteFederal.PermSCT, Carta.FiguraTransporte.AutoTransporteFederal.NumPermisoSCT, Carta.FiguraTransporte.AutoTransporteFederal.NombreAseg, Carta.FiguraTransporte.AutoTransporteFederal.NumPolizaSeguro)
|
||||
|
||||
'cfdi.CartaPorteIdentificacionVehicular(Carta.FiguraTransporte.AutoTransporteFederal.Vehiculo.ConfigVehicular, Carta.FiguraTransporte.AutoTransporteFederal.Vehiculo.PlacaVM, Carta.FiguraTransporte.AutoTransporteFederal.Vehiculo.AnioModeloVM)
|
||||
|
||||
'If Carta.FiguraTransporte.AutoTransporteFederal.Remolques IsNot Nothing AndAlso Carta.FiguraTransporte.AutoTransporteFederal.Remolques.Count > 0 Then
|
||||
'For Each concep As CFDICartaPorteRemolque In Carta.FiguraTransporte.AutoTransporteFederal.Remolques
|
||||
'cfdi.CartaPorteRemolque(concep.SubTipoRemolque, concep.Placa)
|
||||
' Next
|
||||
'
|
||||
'End If
|
||||
End If
|
||||
|
||||
|
||||
'If Carta.FiguraTransporte.Operadores IsNot Nothing AndAlso Carta.FiguraTransporte.Operadores.Count > 0 Then
|
||||
' Dim i As Integer = 0
|
||||
' ComCartaPorte.FiguraTransporte.Operadores = New Profact.TimbraCFDI33.Complementos.CartaPorte10.CartaPorteFiguraTransporteOperadoresOperador(Carta.FiguraTransporte.Operadores.Count - 1)() {}
|
||||
' For Each concep As CFDICartaPorteOperador In Carta.FiguraTransporte.Operadores
|
||||
' Dim Oper = New Profact.TimbraCFDI33.Complementos.CartaPorte10.CartaPorteFiguraTransporteOperadoresOperador()
|
||||
' Oper.RFCOperador = concep.RFCOperador
|
||||
' Oper.NumLicencia = concep.NumLicencia
|
||||
' Oper.NombreOperador = concep.NombreOperador
|
||||
' Oper.NumRegIdTribOperador = concep.NumRegidTribOperador
|
||||
' 'Oper.ResidenciaFiscalOperador = concep.ResidenciaFiscalOperador
|
||||
' ComCartaPorte.FiguraTransporte.Operadores
|
||||
' 'cfdi.CartaPorteOperador(concep.RFCOperador, concep.NumLicencia, concep.NombreOperador, concep.NumRegidTribOperador, concep.ResidenciaFiscalOperador)
|
||||
' Next
|
||||
'End If
|
||||
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
#End Region
|
||||
|
||||
|
||||
#Region "Nomina12"
|
||||
If ObjCFDITimbre.Comprobante.TipoComprobante = "N" Then
|
||||
Dim Nom = New Profact.TimbraCFDI33.Complementos.Nomina12.Nomina()
|
||||
|
||||
@@ -600,6 +600,15 @@ Public Class SIGWeb : Implements IHttpHandler, IRequiresSessionState
|
||||
End If
|
||||
|
||||
If DtRetorno IsNot Nothing AndAlso DtRetorno.Rows.Count > 0 Then
|
||||
Dim i As Integer = 0 'limpieza de columnas
|
||||
While i < DtRetorno.Columns.Count
|
||||
If Not DtRetorno.Columns(i).ColumnName.Contiene("CveCliente", ColumnaNombre) Then
|
||||
DtRetorno.Columns.RemoveAt(i)
|
||||
Else
|
||||
i = i + 1
|
||||
End If
|
||||
End While
|
||||
|
||||
DtRetorno.Columns("CveCliente").ColumnName = "id"
|
||||
DtRetorno.Columns(ColumnaNombre).ColumnName = "text"
|
||||
retorno = JsonConvert.SerializeObject(DtRetorno).ToString
|
||||
@@ -913,7 +922,7 @@ Public Class SIGWeb : Implements IHttpHandler, IRequiresSessionState
|
||||
DtPSRetorno = DTTmp.Copy
|
||||
|
||||
Else
|
||||
'no regresar datos herror al consultar
|
||||
'no regresar datos error al consultar
|
||||
DtPSRetorno.Clear()
|
||||
End If
|
||||
DTTmp.Dispose()
|
||||
|
||||
@@ -1810,6 +1810,18 @@ Partial Class PopUpVerFactura
|
||||
End If
|
||||
End If
|
||||
|
||||
'SI ES TIPO RELACION 07- APLICACION DE ANTICIPOS
|
||||
If dtVentas(0)("CveTipoRelacion").ToString.ToEntero = 7 Then
|
||||
Dim RowTipoRelacion As DataRow = GlobalDTVtaTiposRelacion().FiltroPrimero($"CveTipoRelacion = {dtVentas(0)("CveTipoRelacion").ToString.ToEntero}")
|
||||
|
||||
Vta.Timbre.CFDIRelacionados.TipoRelacion = RowTipoRelacion("SATClaveTipoRelacion").ToString()
|
||||
Vta.Timbre.CFDIRelacionados.TipoRelacionTexto = RowTipoRelacion("SATTipoRelacion").ToString()
|
||||
|
||||
If ObjVentas.GetVentasRelacionadas(CveVenta, UsuarioActual.CveEmpresa) Then
|
||||
Vta.DtDocumentosRelacionados = ObjVentas.DtResultados.FiltraParametros("FolioFiscal IS NOT NULL")
|
||||
End If
|
||||
End If
|
||||
|
||||
'End If
|
||||
|
||||
'If Vta.TipoDocto.Contiene("Egs", "Dev", "Ant") Then
|
||||
|
||||
@@ -143,7 +143,7 @@
|
||||
<label for="<%= TxtIdCuentaContable.ClientID.ToString()%>">IdCuentaContable:</label>
|
||||
</div>
|
||||
<div class="form-group form-md-line-input input-iconright" id="divProveedor" runat="server" visible="false">
|
||||
<asp:DropDownList ID="DdlProveedor" CssClass="form-control input-sm select2me js-cuenta-programmatic select2me" runat="server" AppendDataBoundItems="true" DataTextField="RazonSocial" DataValueField="CveProveedor" Width="240px" ValidationGroup="GrpModulo" Enabled="false"></asp:DropDownList>
|
||||
<ADS:Dropdownlost ID="DdlProveedor" CssClassDdl="select2me" CssClass="form-control input-sm select2me js-cuenta-programmatic select2me" runat="server" data-metodo="getproveedores" CssStyle="width: 100%;" AppendDataBoundItems="true" DataTextField="RazonSocial" DataValueField="CveProveedor" Width="240px" ValidationGroup="GrpModulo" ></ADS:Dropdownlost>
|
||||
<label for="<%= DdlProveedor.ClientID.ToString()%>">Proveedor: </label>
|
||||
</div>
|
||||
<div class="form-group form-md-line-input input-iconright" id="divCliente" runat="server" visible="false">
|
||||
|
||||
@@ -26,14 +26,14 @@ Partial Class Contabilidad2_CatCuentasAsignaciones
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub CargaDatos()
|
||||
Dim ObjConta As New ClsContabilidad
|
||||
If ObjConta.GetCuentasAsignaciones(UsuarioActual.CveEmpresa) Then
|
||||
GvDatos.DataSource = ObjConta.DtResultados
|
||||
End If
|
||||
ObjConta.Dispose()
|
||||
GvDatos.DataBind()
|
||||
End Sub
|
||||
'Private Sub CargaDatos()
|
||||
' Dim ObjConta As New ClsContabilidad
|
||||
' If ObjConta.GetCuentasAsignaciones(UsuarioActual.CveEmpresa) Then
|
||||
' GvDatos.DataSource = ObjConta.DtResultados
|
||||
' End If
|
||||
' ObjConta.Dispose()
|
||||
' GvDatos.DataBind()
|
||||
'End Sub
|
||||
|
||||
Private Sub CargaDatosSistema()
|
||||
Dim ObjConta As New ClsContabilidad
|
||||
@@ -67,8 +67,8 @@ Partial Class Contabilidad2_CatCuentasAsignaciones
|
||||
DdlCuentaGlobal.DataSource = ObjConta.DtResultados
|
||||
End If
|
||||
ObjConta.Dispose()
|
||||
DdlProveedor.DataSource = GlobalDTCompProveedores(UsuarioActual.CveEmpresa)
|
||||
|
||||
DdlProveedor.setEsWebService(True) 'GlobalDTCompProveedores(UsuarioActual.CveEmpresa)
|
||||
|
||||
DdlClientes.setEsWebService(True)
|
||||
|
||||
DdlPersonal.setEsWebService(True)
|
||||
@@ -102,7 +102,7 @@ Partial Class Contabilidad2_CatCuentasAsignaciones
|
||||
DdlConceptoNomina.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
DdlCconceptosContables.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
DdlCuenta.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
DdlProveedor.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
'DdlProveedor.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
DdlClasificacion.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
DdlAlmacen.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||
End Sub
|
||||
@@ -123,7 +123,7 @@ Partial Class Contabilidad2_CatCuentasAsignaciones
|
||||
DdlCconceptosContables.SelectedValueExist(GvRow.DataKey("CveConceptoContable"))
|
||||
DdlCuenta.SelectedValueExist(GvRow.DataKey("CveCuenta"))
|
||||
DdlConceptoNomina.SelectedValueExist(GvRow.DataKey("CveConceptoNomina").ToEntero)
|
||||
DdlProveedor.SelectedValueExist(GvRow.DataKey("CveProveedor"))
|
||||
DdlProveedor.ddl.SelectedValueExist(GvRow.DataKey("CveProveedor"))
|
||||
DdlClasificacion.SelectedValueExist(GvRow.DataKey("CveClasificacion"))
|
||||
DdlAlmacen.SelectedValueExist(GvRow.DataKey("CveAlmacen"))
|
||||
TxtIdCuentaContable.Text = GvRow.DataKey("IdCuenta")
|
||||
@@ -151,41 +151,22 @@ Partial Class Contabilidad2_CatCuentasAsignaciones
|
||||
|
||||
If Dr IsNot Nothing Then
|
||||
|
||||
If Dr("AplicaCliente").ToString = "True" Then
|
||||
divCliente.Visible = True
|
||||
DdlClientes.setEsWebService(True)
|
||||
End If
|
||||
|
||||
If Dr("AplicaProveedor").ToString = "True" Then
|
||||
divProveedor.Visible = True
|
||||
End If
|
||||
divCliente.Visible = Dr("AplicaCliente").ToString = "True"
|
||||
|
||||
If Dr("AplicaPersonal").ToString = "True" Then
|
||||
divPersonal.Visible = True
|
||||
DdlPersonal.setEsWebService(True)
|
||||
divProveedor.Visible = Dr("AplicaProveedor").ToString = "True"
|
||||
|
||||
End If
|
||||
divPersonal.Visible = Dr("AplicaPersonal").ToString = "True"
|
||||
|
||||
If Dr("AplicaImpuesto").ToString = "True" Then
|
||||
divPorcentajeIVA.Visible = True
|
||||
End If
|
||||
divPorcentajeIVA.Visible = Dr("AplicaImpuesto").ToString = "True"
|
||||
|
||||
divClasificacion.Visible = Dr("AplicaClasificacion").ToString = "True"
|
||||
|
||||
If Dr("AplicaClasificacion").ToString = "True" Then
|
||||
divClasificacion.Visible = True
|
||||
End If
|
||||
divBancos.Visible = Dr("AplicaBancos").ToString = "True"
|
||||
|
||||
If Dr("AplicaBancos").ToString = "True" Then
|
||||
divBancos.Visible = True
|
||||
End If
|
||||
divAlmacen.Visible = Dr("AplicaAlmacen").ToString = "True"
|
||||
|
||||
If Dr("AplicaAlmacen").ToString = "True" Then
|
||||
divAlmacen.Visible = True
|
||||
End If
|
||||
|
||||
If Dr("AplicaSubProyecto").ToString = "True" Then
|
||||
divSubProyectos.Visible = True
|
||||
End If
|
||||
divSubProyectos.Visible = Dr("AplicaSubProyecto").ToString = "True"
|
||||
|
||||
If Dr("AplicaActivoFijo").ToString = "True" Then
|
||||
divActivoFijo.Visible = True
|
||||
@@ -194,9 +175,7 @@ Partial Class Contabilidad2_CatCuentasAsignaciones
|
||||
' DdlActivoFijo.SelectedValueExist(GvRow.DataKey("CveActivoFijo"))
|
||||
End If
|
||||
|
||||
If Dr("AplicaNomina").ToString = "True" Then
|
||||
divConceptoNomina.Visible = True
|
||||
End If
|
||||
divConceptoNomina.Visible = Dr("AplicaNomina").ToString = "True"
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
@@ -814,7 +814,7 @@ public partial class General_PopUpPaqueteriasGuias : ClsPaginas
|
||||
private string getCorreoString()
|
||||
{
|
||||
ClsVentas ObjVentas = new ClsVentas();
|
||||
if (ObjVentas.GetVenta(CveVenta,UsuarioActual.CveEmpresa))
|
||||
if (ObjVentas.GetVenta(CveVenta,UsuarioActual.CveEmpresa) && ObjVentas.DtResultados.Rows.Count > 0 )
|
||||
{
|
||||
int CveVendedor = ObjVentas.DtResultados.Rows[0]["CveVendedor"].ToEntero();
|
||||
int CveCliente = ObjVentas.DtResultados.Rows[0]["CveCliente"].ToEntero();
|
||||
|
||||
@@ -123,7 +123,7 @@
|
||||
<ContentTemplate>
|
||||
<asp:Panel ID="Panel1" runat="server" DefaultButton="BtnConsultar">
|
||||
<div class="portlet solid grey-cascade portlet-filter">
|
||||
<div class="portlet-title portlet-filterT smalltitle" style="min-height: 49px;">
|
||||
<div class="portlet-title portlet-filterT smalltitle" style="min-height: 39px;">
|
||||
<div class="tools">
|
||||
<asp:Button ID="BtnConsultar" CssClass="btn btn-default" runat="server" Text="Consultar" />
|
||||
</div>
|
||||
@@ -134,7 +134,7 @@
|
||||
<asp:DropDownList ID="DdlCAlmacen" runat="server" CssClass="form-control input-sm" Style="max-width: 200px" DataTextField="Almacen" DataValueField="CveAlmacen"></asp:DropDownList>
|
||||
</div>--%>
|
||||
<label class="col-md-1 truncate">Concepto:</label>
|
||||
<div class="col-md-2 ">
|
||||
<div class="col-md-3 ">
|
||||
<asp:DropDownList ID="DdlCConcepto" DataTextField="Concepto" CssClass="form-control input-sm" DataValueField="CveConcepto" runat="server" Style="max-width: 200px"></asp:DropDownList>
|
||||
</div>
|
||||
<label class="col-md-1 truncate">Folio:</label>
|
||||
@@ -165,23 +165,20 @@
|
||||
</div>
|
||||
<div class="caption uppercase" style="position: relative;">
|
||||
<i class="fa fa-info-circle"></i>Información del movimiento
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="portlet-body" <%= IIf(chkexpand.Checked = True, "", "style='display:none;'")%>>
|
||||
<div id="tbEncabezado" runat="server" class="rowpadding" visible="true">
|
||||
<div class="row">
|
||||
|
||||
<label class="col-md-1 truncate" style="width: 110px">Almacén:</label>
|
||||
<div class="col-md-2">
|
||||
<asp:DropDownList ID="DdlAlmacen" AutoPostBack="true" AppendDataBoundItems="true" OnSelectedIndexChanged="DdlAlmacen_SelectedIndexChanged" runat="server" CssClass="form-control input-sm select2me" Style="max-width: 200px" DataTextField="Almacen" DataValueField="CveAlmacen"></asp:DropDownList>
|
||||
<div class="col-md-4">
|
||||
<asp:DropDownList ID="DdlAlmacen" AutoPostBack="true" AppendDataBoundItems="true" OnSelectedIndexChanged="DdlAlmacen_SelectedIndexChanged" runat="server" CssClass="form-control input-sm select2me" DataTextField="Almacen" DataValueField="CveAlmacen"></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator InitialValue="-1" ID="RfvAlmacen" Display="None" ValidationGroup="GrpGuardar" runat="server" ControlToValidate="DdlAlmacen" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Almacen''</b> es necesario, por favor seleccione uno."></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender1" runat="server" HighlightCssClass="vco" TargetControlID="RfvAlmacen" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
<label class="col-md-1 truncate" style="width: 110px" id="DivConcepto1" runat="server">Concepto:</label>
|
||||
<div class="col-md-2 " id="DivConcepto2" runat="server">
|
||||
<asp:DropDownList ID="DdlConcepto" DataTextField="Concepto" CssClass="form-control input-sm select2me" AutoPostBack="true" DataValueField="CveConcepto" runat="server" Style="max-width: 200px"></asp:DropDownList>
|
||||
<div class="col-md-4 " id="DivConcepto2" runat="server">
|
||||
<asp:DropDownList ID="DdlConcepto" DataTextField="Concepto" CssClass="form-control input-sm select2me" AutoPostBack="true" DataValueField="CveConcepto" runat="server" ></asp:DropDownList>
|
||||
<asp:RequiredFieldValidator InitialValue="-1" ID="RfvConcepto" Display="None" ValidationGroup="GrpGuardar" runat="server" ControlToValidate="DdlConcepto" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Concepto''</b> es necesario, por favor seleccione uno."></asp:RequiredFieldValidator>
|
||||
<ajax:ValidatorCalloutExtender ID="VcoConcepto" runat="server" HighlightCssClass="vco" TargetControlID="RfvConcepto" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
@@ -191,8 +188,8 @@
|
||||
|
||||
<div id="DivCliente" runat="server" visible="false">
|
||||
<label class="col-md-1 truncate" style="width: 110px">Cliente:</label>
|
||||
<div class="col-md-2">
|
||||
<asp:DropDownList ID="DdlClientes" AutoPostBack="true" OnSelectedIndexChanged="DdlClientes_SelectedIndexChanged" AppendDataBoundItems="true" runat="server" CssClass="form-control input-sm select2me" Style="max-width: 200px" DataTextField="NombreComercial" DataValueField="CveCliente"></asp:DropDownList>
|
||||
<div class="col-md-4">
|
||||
<asp:DropDownList ID="DdlClientes" AutoPostBack="true" OnSelectedIndexChanged="DdlClientes_SelectedIndexChanged" AppendDataBoundItems="true" runat="server" CssClass="form-control input-sm select2me" DataTextField="NombreComercial" DataValueField="CveCliente"></asp:DropDownList>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -286,26 +283,26 @@
|
||||
<div class="col-md-2">
|
||||
</div>
|
||||
</div>
|
||||
<div class="row" id="divGuia" runat="server" visible="False">
|
||||
<div class="row">
|
||||
<div id="divGuia" runat="server" visible="False">
|
||||
<label class="col-md-1 truncate" style="width: 110px">
|
||||
<asp:Label runat="server" ID="LblGuia">Guía:</asp:Label>
|
||||
</label>
|
||||
<div class="col-md-2">
|
||||
<asp:TextBox ID="TxtGuia" runat="server" MaxLength="20" Width="100%"></asp:TextBox>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row" runat="server" id="TrResponsable">
|
||||
<div class="col-md-6" runat="server" id="TrResponsable">
|
||||
<label class="col-md-1" style="width: 110px">Recibe:</label>
|
||||
<div class="col-md-3">
|
||||
<asp:TextBox runat="server" Text="" ID="TxtResponsable" Width="100%" />
|
||||
<%--<asp:DropDownList ID="DdlResponsable" runat="server" DataTextField="Nombre" DataValueField="CveUsuario" CssClass="form-control input-sm" Style="width: 200px !important;"></asp:DropDownList>--%>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<label class="col-md-1 truncate" style="width: 110px">
|
||||
Observaciones:
|
||||
|
||||
|
||||
Observaciones:
|
||||
</label>
|
||||
<div class="col-md-5">
|
||||
<asp:TextBox ID="TxtObservaciones" TextMode="MultiLine" Rows="2" CssClass="form-control input-sm" runat="server" MaxLength="232"></asp:TextBox>
|
||||
|
||||
@@ -329,7 +329,7 @@ Partial Class Inventarios_EntradasSalidas
|
||||
Case "1"
|
||||
|
||||
Case "2"
|
||||
divMonedaSeccion.Visible = True
|
||||
'divMonedaSeccion.Visible = True
|
||||
divGuia.Visible = True
|
||||
End Select
|
||||
|
||||
|
||||
@@ -1036,13 +1036,16 @@ Partial Class Inventarios_EntregaAlmacen
|
||||
End Sub
|
||||
|
||||
Private Sub CargaDocumentos(tCveVenta As Integer)
|
||||
Dim objInv As New ClsEdocumentacion
|
||||
|
||||
If objInv.DocumentacionElectronicaGet(-1, -1, -1, UsuarioActual.CveEmpresa, -1, tCveVenta) Then
|
||||
GvDocs.DataSource = objInv.DtResultados.FiltraParametros("Adjunto <> ''")
|
||||
End If
|
||||
objInv.Dispose()
|
||||
GvDocs.DataBind()
|
||||
If tCveVenta > 0 Then
|
||||
Dim objInv As New ClsEdocumentacion
|
||||
|
||||
If objInv.DocumentacionElectronicaGet(-1, -1, -1, UsuarioActual.CveEmpresa, -1, tCveVenta) Then
|
||||
GvDocs.DataSource = objInv.DtResultados.FiltraParametros("Adjunto <> ''")
|
||||
End If
|
||||
objInv.Dispose()
|
||||
GvDocs.DataBind()
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
|
||||
@@ -507,6 +507,7 @@ Partial Class Inventarios_InventarioFisico
|
||||
FechaFin = GvRow.DataKey("FechaFin").ToEntero
|
||||
DdlSubProyecto.SelectedValueExist(GvRow.DataKey("CveSubProyecto").ToEntero)
|
||||
chkUsarApp.Checked = Convert.ToBoolean(GvRow.DataKey("ConAplicacion").ToString)
|
||||
divUsuarios.Visible = chkUsarApp.Checked
|
||||
CargaGvAlmacen()
|
||||
CargaGvClasificacion()
|
||||
CargaGvProductosServicios()
|
||||
|
||||
@@ -161,7 +161,7 @@ Partial Class Inventarios_InventarioFisicoDetalle
|
||||
End If
|
||||
str.Clear()
|
||||
|
||||
CveAlmacenes = CveAlmacenesStr.ToString.Substring(0, CveAlmacenesStr.Length - 1)
|
||||
CveAlmacenes = CveAlmacenesStr.ToString.Substring(0, CveAlmacenesStr.Length)
|
||||
End If
|
||||
|
||||
If ObjInventario.GetInventarioFisicoDetallesClasificacion(CveInventarioFisico, UsuarioActual.CveEmpresa) Then
|
||||
|
||||
@@ -41,6 +41,24 @@ Partial Class Inventarios_RepAnomalias
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property aplicacion As Boolean
|
||||
Get
|
||||
Return CType(ViewState("aplicacion"), Boolean)
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
ViewState("aplicacion") = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
Public Property CreandoNuevoInventario As Boolean
|
||||
Get
|
||||
Return CType(ViewState("CreandoNuevoInventario"), Boolean)
|
||||
End Get
|
||||
Set(value As Boolean)
|
||||
ViewState("CreandoNuevoInventario") = value
|
||||
End Set
|
||||
End Property
|
||||
|
||||
#End Region
|
||||
|
||||
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
|
||||
@@ -51,6 +69,7 @@ Partial Class Inventarios_RepAnomalias
|
||||
|
||||
If CveInventarioFisico > 0 Then
|
||||
CargaDatos(CveInventarioFisico)
|
||||
CreandoNuevoInventario = False
|
||||
End If
|
||||
|
||||
End If
|
||||
@@ -72,7 +91,7 @@ Partial Class Inventarios_RepAnomalias
|
||||
lbFechaI.Text = Inventario.FechaI
|
||||
lbFechaF.Text = Inventario.FechaF
|
||||
CveSubProyecto = Inventario.CveSubProyectoInventario
|
||||
|
||||
aplicacion = Inventario.ConAplicacion
|
||||
If Inventario.Estatus = "Finalizado" Then
|
||||
btnFin.Visible = False
|
||||
End If
|
||||
@@ -254,7 +273,7 @@ Partial Class Inventarios_RepAnomalias
|
||||
#End Region
|
||||
|
||||
|
||||
Protected Sub GV_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GvF.RowDataBound, GvS.RowDataBound
|
||||
Protected Sub GVF_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GvF.RowDataBound
|
||||
If e.Row.RowType = DataControlRowType.DataRow Then
|
||||
If e.Row.DBCampo("Costo") = "-1" Then
|
||||
e.Row.Cells(8).Text = "0"
|
||||
@@ -264,6 +283,29 @@ Partial Class Inventarios_RepAnomalias
|
||||
End If
|
||||
e.Row.FCLabel("Lblc").Text = e.Row.RowIndex + 1
|
||||
End If
|
||||
If e.Row.RowType = DataControlRowType.Header Then
|
||||
If CreandoNuevoInventario Then
|
||||
e.Row.FCCheckBox("ChkAllFaltante").Attributes.Add("onclick", "SeleccionarTodosFaltante(this);")
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
|
||||
|
||||
Protected Sub GVS_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GvS.RowDataBound
|
||||
If e.Row.RowType = DataControlRowType.DataRow Then
|
||||
If e.Row.DBCampo("Costo") = "-1" Then
|
||||
e.Row.Cells(8).Text = "0"
|
||||
End If
|
||||
If e.Row.Cells(7).Text = MinFecha.ToString Then
|
||||
e.Row.Cells(7).Text = ""
|
||||
End If
|
||||
e.Row.FCLabel("Lblc").Text = e.Row.RowIndex + 1
|
||||
End If
|
||||
If e.Row.RowType = DataControlRowType.Header Then
|
||||
If CreandoNuevoInventario Then
|
||||
e.Row.FCCheckBox("ChkAllSobrante").Attributes.Add("onclick", "SeleccionarTodosSobrante(this);")
|
||||
End If
|
||||
End If
|
||||
End Sub
|
||||
|
||||
#Region " IMPRIMIR "
|
||||
@@ -353,14 +395,14 @@ Partial Class Inventarios_RepAnomalias
|
||||
GvF.Columns(0).Visible = True
|
||||
LnkGuardar.Visible = True
|
||||
LnkCrear.Visible = False
|
||||
GvF.HeaderRow.FCCheckBox("ChkAllFaltante").Attributes.Add("onclick", "SeleccionarTodosFaltante(this);")
|
||||
CreandoNuevoInventario = True
|
||||
End If
|
||||
|
||||
If GvS.Rows.Count > 0 Then
|
||||
GvS.Columns(0).Visible = True
|
||||
LnkGuardar.Visible = True
|
||||
LnkCrear.Visible = False
|
||||
GvS.HeaderRow.FCCheckBox("ChkAllSobrante").Attributes.Add("onclick", "SeleccionarTodosSobrante(this);")
|
||||
CreandoNuevoInventario = True
|
||||
End If
|
||||
UPAnomalias.Update()
|
||||
UpdateGvS.Update()
|
||||
@@ -374,13 +416,15 @@ Partial Class Inventarios_RepAnomalias
|
||||
Dim ErrorClasif As Boolean = False
|
||||
Dim ObjInventario As New ClsInventarios
|
||||
Dim CveInventarioFisicoNew As Integer
|
||||
Dim DtAlmacen, DtClasificacion, DtClasificacionExcluida, DtProveedor As DataTable
|
||||
Dim DtAlmacen, DtClasificacion, DtClasificacionExcluida, DtProveedor, DtUsuario As DataTable
|
||||
DtAlmacen = Nothing
|
||||
DtClasificacion = Nothing
|
||||
DtClasificacionExcluida = Nothing
|
||||
DtProveedor = Nothing
|
||||
DtUsuario = Nothing
|
||||
|
||||
ObjInventario.IniciaTransacSQL()
|
||||
If ObjInventario.AddInventarioFisico(UsuarioActual.CveEmpresa, TxtTitulo.Text, lbObservaciones.Text, 0, CveSubProyecto) Then
|
||||
If ObjInventario.AddInventarioFisico(UsuarioActual.CveEmpresa, TxtTitulo.Text, lbObservaciones.Text, 0, CveSubProyecto, aplicacion) Then
|
||||
CveInventarioFisicoNew = ObjInventario.CveInventarioFisico
|
||||
|
||||
If ObjInventario.GetInventarioFisicoDetallesAlmacen(CveInventarioFisico, UsuarioActual.CveEmpresa) Then
|
||||
@@ -396,6 +440,18 @@ Partial Class Inventarios_RepAnomalias
|
||||
DtProveedor = ObjInventario.DtResultados.FiltraParametros("Incluye = 1")
|
||||
End If
|
||||
|
||||
If ObjInventario.GetInventarioFisicoDetallesUsuarios(CveInventarioFisico, UsuarioActual.CveEmpresa) Then
|
||||
DtUsuario = ObjInventario.DtResultados.FiltraParametros("Incluye = 1")
|
||||
End If
|
||||
|
||||
|
||||
For Each Gvr As DataRow In DtUsuario.Rows
|
||||
If Not ObjInventario.AddInventarioFisicoUsuarios(CveInventarioFisicoNew, Gvr("CveUsuario").ToString.ToEntero, Convert.ToBoolean(Gvr("Incluye").ToString), Convert.ToBoolean(Gvr("Cerrado").ToString), Convert.ToBoolean(Gvr("Bloqueado").ToString)) Then
|
||||
ErrorClasif = True
|
||||
Exit For
|
||||
End If
|
||||
Next
|
||||
|
||||
For Each Gvr As DataRow In DtAlmacen.Rows
|
||||
If Not ObjInventario.AddInventarioFisicoAlmacenes(CveInventarioFisicoNew, Gvr("CveAlmacen").ToString.ToEntero) Then
|
||||
ErrorClasif = True
|
||||
@@ -455,6 +511,7 @@ Partial Class Inventarios_RepAnomalias
|
||||
GvS.Columns(0).Visible = False
|
||||
LnkGuardar.Visible = False
|
||||
LnkCrear.Visible = True
|
||||
CreandoNuevoInventario = False
|
||||
CargaDatos(CveInventarioFisico)
|
||||
Else
|
||||
ObjInventario.RollBack()
|
||||
|
||||
@@ -195,7 +195,7 @@
|
||||
<asp:TemplateField ItemStyle-Width="70px" HeaderText="Acción" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<span data-placement="top" data-toggle="tooltip" title="Marcar el producto como que no se recibirá">
|
||||
<asp:LinkButton runat="server" OnClick="BtnActulizarEstatus_Click" CssClass="btn btn-sm red" Text="<i class='fa fa-eye-slash' aria-hidden='true'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro de marcar el producto como que no se recibirá?" data-btn-ok-label="si"></asp:LinkButton>
|
||||
<asp:LinkButton ID="lnkAccion" runat="server" OnClick="BtnActulizarEstatus_Click" CssClass="btn btn-sm red" Text="<i class='fa fa-eye-slash' aria-hidden='true'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro de marcar el producto como que no se recibirá?" data-btn-ok-label="si"></asp:LinkButton>
|
||||
</span>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
|
||||
@@ -279,7 +279,7 @@ Partial Class RepNotasSinAlmacen
|
||||
e.Row.Cells(1).Text = e.Row.DBCampo("Fecha").ToDate.ToShortDateString
|
||||
e.Row.Cells(1).HorizontalAlign = HorizontalAlign.Center
|
||||
e.Row.Cells(2).Text = "<a class=""Texto"" href=""/Compras/Proveedores.aspx?CveProveedor=" & e.Row.DBCampo("CveProveedor") & """>" & e.Row.DBCampo("RazonSocial") & "</a>"
|
||||
|
||||
e.Row.FCLinkButton("lnkAccion").Visible = False
|
||||
If GvCompras.Columns(4).Visible Then
|
||||
e.Row.Cells(4).Text = ""
|
||||
End If
|
||||
|
||||
@@ -190,6 +190,20 @@
|
||||
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender4" runat="server" HighlightCssClass="vco" TargetControlID="CompareValidator1" Width="350px"></ajax:ValidatorCalloutExtender>
|
||||
</div>
|
||||
</div>
|
||||
<label class="col-md-2">F. Envío:</label>
|
||||
<div class="col-md-2" style="padding-left: 5px; padding-top: 0px;" runat="server" id="divFechaEnvio" visible="false">
|
||||
|
||||
<div class="input-group input-sm input-small date date-picker" data-date-format="dd/mm/yyyy" style="width: 120px !important;">
|
||||
<asp:TextBox ID="TxtFechaEnvio" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10" Width="75px" 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="TxtFechaEnvio" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||
<ajax:CalendarExtender runat="server" ID="CalendarExtender2" TargetControlID="TxtFechaEnvio" PopupButtonID="ImgFechaEnvio" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
|
||||
<asp:CompareValidator ID="CompareValidator2" runat="server" ControlToValidate="TxtFechaEnvio" 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>
|
||||
</div>
|
||||
<div class="row">
|
||||
<label class="col-md-1">Unidad:</label>
|
||||
@@ -827,7 +841,7 @@
|
||||
</div>
|
||||
<div class="form-group form-md-line-input input-iconright">
|
||||
<label for="<%= DdlConfigAuto.ClientID.ToString()%>">Configuración Carta Porte:</label>
|
||||
<asp:DropDownList ID="DdlConfigAuto" CssClass="form-control input-sm select2me " Width="100%" runat="server" AppendDataBoundItems="true" AutoPostBack="false" CausesValidation="true" DataTextField="ConfigAutoTransporte" DataValueField="ClaveConfigAutoTransporte">
|
||||
<asp:DropDownList ID="DdlConfigAuto" CssClass="form-control input-sm select2me " Width="100%" runat="server" AppendDataBoundItems="true" AutoPostBack="false" CausesValidation="true" DataTextField="ClaveConfigAutoTransporteDescripcion" DataValueField="ClaveConfigAutoTransporte">
|
||||
<asp:ListItem Selected="True" Text="Seleccione" Value=""></asp:ListItem>
|
||||
</asp:DropDownList>
|
||||
</div>
|
||||
|
||||
@@ -189,6 +189,10 @@ Partial Class Inventarios_TraspasoAlmacen
|
||||
LblResponsable.Visible = False
|
||||
End If
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(161) = "1" Then
|
||||
divFechaEnvio.Visible = True
|
||||
End If
|
||||
|
||||
|
||||
CargaCombos()
|
||||
CreaDT()
|
||||
|
||||
@@ -5129,8 +5129,8 @@ Partial Class OC
|
||||
option72.Visible = True
|
||||
DivFolioAdicional.Visible = True
|
||||
generarAnticipo.Visible = True
|
||||
Ddlcliente.DataSource = GlobalDTCliente(CveEmpresaActual)
|
||||
Ddlcliente.DataBind()
|
||||
'Ddlcliente.DataSource = GlobalDTCliente(CveEmpresaActual)
|
||||
'Ddlcliente.DataBind()
|
||||
|
||||
'Ddlcliente.Items.Insert(0, New ListItem(" - ", "-1"))
|
||||
|
||||
|
||||
@@ -1231,8 +1231,12 @@
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
|
||||
<ajax:TabPanel ID="TabHis" runat="server" HeaderText="Historial de Ventas">
|
||||
<ajax:TabPanel ID="TabHis" runat="server">
|
||||
<HeaderTemplate>
|
||||
<span>Historial de Ventas</span>
|
||||
</HeaderTemplate>
|
||||
<ContentTemplate>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-3">
|
||||
<div class="portlet light xspadding bordered">
|
||||
@@ -1343,8 +1347,7 @@
|
||||
<asp:PostBackTrigger ControlID="BtnPDFHistorial" />
|
||||
</Triggers>
|
||||
<ContentTemplate>
|
||||
|
||||
|
||||
<asp:Button ID="BtnHistorialVentas" runat="server" ClientIDMode="Static" Text="HistorialVentas" Style="display: none;" OnClick="BtnHistorialVentas_Click" />
|
||||
<asp:GridView ID="GVHistorial" runat="server" DataKeyNames="CveVenta, Folio, TipoDocto" AutoGenerateColumns="False" EmptyDataText="No se encontraron Ventas en el Cliente" ToolTip="Listado de Historial de Ventas" CssClass="table table-striped table-advance table-hover" Style="text-align: center; min-width: 783px; width: 100%;" GridLines="None">
|
||||
<Columns>
|
||||
<asp:BoundField HeaderText="Tipo" DataField="TipoDocto" ItemStyle-HorizontalAlign="Center" />
|
||||
@@ -1560,12 +1563,14 @@
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
|
||||
<ajax:TabPanel ID="TabCxC" runat="server" HeaderText="Cuentas x Cobrar">
|
||||
<ajax:TabPanel ID="TabCxC" runat="server">
|
||||
<HeaderTemplate>
|
||||
<span>Cuentas x Cobrar</span>
|
||||
</HeaderTemplate>
|
||||
<ContentTemplate>
|
||||
|
||||
<asp:UpdatePanel ID="UpImprimir" runat="server">
|
||||
<ContentTemplate>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-7">
|
||||
|
||||
@@ -1582,6 +1587,7 @@
|
||||
<div class="portlet-body">
|
||||
<asp:UpdatePanel ID="UpParametros" UpdateMode="Conditional" runat="server">
|
||||
<ContentTemplate>
|
||||
<asp:Button ID="BtnCargaCxC" runat="server" ClientIDMode="Static" Text="CargaCxC" Style="display: none;" OnClick="BtnCargaCxC_Click" />
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
|
||||
@@ -2169,7 +2175,7 @@
|
||||
|
||||
<asp:UpdatePanel ID="UpAnticipos" runat="server">
|
||||
<ContentTemplate>
|
||||
|
||||
<asp:Button ID="BtnCargaAnticipos" runat="server" ClientIDMode="Static" Text="CargaAnt" Style="display: none;" OnClick="BtnCargaAnticipos_Click" />
|
||||
<div class="row col-md-12" align="right">
|
||||
<input type="text" id="TxtBusquedaAnticipos" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusquedaAnticipos','{0}')", GVAnticipos.ClientID) %>" style="display: inline-block; margin-right: -20px; width: 150px;" />
|
||||
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusquedaAnticipos','{0}')", GVAnticipos.ClientID) %>" style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
|
||||
@@ -2298,7 +2304,10 @@
|
||||
</ContentTemplate>
|
||||
</ajax:TabPanel>
|
||||
|
||||
<ajax:TabPanel ID="TabBancos" runat="server" HeaderText="Bancos">
|
||||
<ajax:TabPanel ID="TabBancos" runat="server">
|
||||
<HeaderTemplate>
|
||||
<span>Bancos</span>
|
||||
</HeaderTemplate>
|
||||
<ContentTemplate>
|
||||
|
||||
<div class="portlet light xspadding bordered ">
|
||||
@@ -2442,55 +2451,61 @@
|
||||
</div>
|
||||
|
||||
<div class="table-scrollable">
|
||||
<asp:GridView ID="GvBancos" runat="server" AutoGenerateColumns="False" EmptyDataText="No se encontró Historial de Abonos"
|
||||
CssClass="table table-striped table-advance table-hover ScrollAD" data-sort="false" BorderWidth="1" BorderColor="#D3D3D3" GridLines="None" DataKeyNames="SerieFolioCP">
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="Factura" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="HplFactura" CssClass="Texto" runat="server" Text='<%# Eval("SerieFolio")%>' NavigateUrl='<%# Eval("CveVenta", "/Ventas/Ventas.aspx?CveVenta={0}")%>'></asp:HyperLink>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField HeaderText="Fecha Venta" DataField="Fecha" DataFormatString="{0:d}" ItemStyle-HorizontalAlign="Center" />
|
||||
<asp:TemplateField HeaderText="Fecha Vencimiento" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LtlFechaVenci" runat="server" Text='<%# Eval("FechaVencimiento", "{0:d}") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Cheque" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="HplCheque" Visible="False" runat="server" CssClass="Texto" Text='<%# Eval("FolioCobro")%>' NavigateUrl='<%# Eval("CveIE", "/Bancos/IE.aspx?CveIE={0}") %>'></asp:HyperLink>
|
||||
<asp:UpdatePanel ID="UpBancos" runat="server" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<asp:Button ID="BtnCargaBancos" runat="server" ClientIDMode="Static" Text="CargaBancos" Style="display: none;" OnClick="BtnCargaBancos_Click" />
|
||||
|
||||
<asp:GridView ID="GvBancos" runat="server" AutoGenerateColumns="False" EmptyDataText="No se encontró Historial de Abonos"
|
||||
CssClass="table table-striped table-advance table-hover ScrollAD" data-sort="false" BorderWidth="1" BorderColor="#D3D3D3" GridLines="None" DataKeyNames="SerieFolioCP">
|
||||
<Columns>
|
||||
<asp:TemplateField HeaderText="Factura" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="HplFactura" CssClass="Texto" runat="server" Text='<%# Eval("SerieFolio")%>' NavigateUrl='<%# Eval("CveVenta", "/Ventas/Ventas.aspx?CveVenta={0}")%>'></asp:HyperLink>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:BoundField HeaderText="Fecha Venta" DataField="Fecha" DataFormatString="{0:d}" ItemStyle-HorizontalAlign="Center" />
|
||||
<asp:TemplateField HeaderText="Fecha Vencimiento" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LtlFechaVenci" runat="server" Text='<%# Eval("FechaVencimiento", "{0:d}") %>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Cheque" ItemStyle-HorizontalAlign="Center">
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="HplCheque" Visible="False" runat="server" CssClass="Texto" Text='<%# Eval("FolioCobro")%>' NavigateUrl='<%# Eval("CveIE", "/Bancos/IE.aspx?CveIE={0}") %>'></asp:HyperLink>
|
||||
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Abonado" ItemStyle-HorizontalAlign="Right">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LtlImp" runat="server" Text='<%# Eval("ImporteAbonado", "{0:N2}")%>'></asp:Literal>
|
||||
<asp:Literal ID="LtlMon" runat="server" Text='<%# Eval("MonedaVenta")%>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField>
|
||||
<HeaderTemplate>Archivos</HeaderTemplate>
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="HplXML" runat="server" Visible="false" Target="_blank"><i class='fa fa-file-excel-o' style="font-weight:bold;"></i></asp:HyperLink>
|
||||
<asp:HyperLink ID="HplPDF" runat="server" Visible="false" Target="_blank"><i class='fa fa-file-pdf-o' style="font-weight:bold;"></i></asp:HyperLink>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField>
|
||||
<HeaderTemplate>Reenviar Complemento</HeaderTemplate>
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
<ItemTemplate>
|
||||
<%-- <a id="HLSendMail" runat="server" class="Texto" visible="false">
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField HeaderText="Abonado" ItemStyle-HorizontalAlign="Right">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="LtlImp" runat="server" Text='<%# Eval("ImporteAbonado", "{0:N2}")%>'></asp:Literal>
|
||||
<asp:Literal ID="LtlMon" runat="server" Text='<%# Eval("MonedaVenta")%>'></asp:Literal>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField>
|
||||
<HeaderTemplate>Archivos</HeaderTemplate>
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
<ItemTemplate>
|
||||
<asp:HyperLink ID="HplXML" runat="server" Visible="false" Target="_blank"><i class='fa fa-file-excel-o' style="font-weight:bold;"></i></asp:HyperLink>
|
||||
<asp:HyperLink ID="HplPDF" runat="server" Visible="false" Target="_blank"><i class='fa fa-file-pdf-o' style="font-weight:bold;"></i></asp:HyperLink>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField>
|
||||
<HeaderTemplate>Reenviar Complemento</HeaderTemplate>
|
||||
<ItemStyle HorizontalAlign="Center" />
|
||||
<ItemTemplate>
|
||||
<%-- <a id="HLSendMail" runat="server" class="Texto" visible="false">
|
||||
<i class="fa fa-envelope fa-2" aria-hidden="true"></i>
|
||||
</a>--%>
|
||||
<asp:LinkButton ID="LnkSendMail" CssClass="Texto" OnClick="LnkSendMail_Click" runat="server" Visible="false"> <i class="fa fa-envelope fa-2" aria-hidden="true"></i></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
<RowStyle CssClass="Texto" />
|
||||
<AlternatingRowStyle CssClass="TextoAlterno" />
|
||||
<HeaderStyle CssClass="Titulos" />
|
||||
</asp:GridView>
|
||||
<asp:LinkButton ID="LnkSendMail" CssClass="Texto" OnClick="LnkSendMail_Click" runat="server" Visible="false"> <i class="fa fa-envelope fa-2" aria-hidden="true"></i></asp:LinkButton>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
</Columns>
|
||||
<RowStyle CssClass="Texto" />
|
||||
<AlternatingRowStyle CssClass="TextoAlterno" />
|
||||
<HeaderStyle CssClass="Titulos" />
|
||||
</asp:GridView>
|
||||
</ContentTemplate>
|
||||
</asp:UpdatePanel>
|
||||
</div>
|
||||
<div class="text-right ">
|
||||
<asp:LinkButton ID="BtnVerMasBancos" runat="server" Text="Ver Más" OnClick="BtnVerMasBancos_Click" class="btn btn-primary" />
|
||||
@@ -6525,7 +6540,7 @@
|
||||
$.fn.dataTable.tables({ visible: true, api: true }).columns.adjust();
|
||||
});
|
||||
|
||||
<%-- $("C_Tab_TabAlta_TxtTelefono").inputmask("mask", {
|
||||
<%-- $("C_Tab_TabAlta_TxtTelefono").inputmask("mask", {
|
||||
"mask": "(999) 999-9999"
|
||||
});
|
||||
|
||||
@@ -6534,6 +6549,18 @@
|
||||
"mask": "(999) 999-9999"
|
||||
});
|
||||
});--%>
|
||||
|
||||
if (<%= Me.CveCliente %> > 0) {
|
||||
//CARGA EL HISTORIAL DE VENTAS
|
||||
$("#C_Tab_TabHis_tab").click(function () { CargaHistorialVentas(); });
|
||||
//CARGA EL CXC
|
||||
$("#C_Tab_TabCxC_tab").click(function () { CargaCxC(); });
|
||||
//CARGA ANTICIPOS
|
||||
$("#C_Tab_TabAnticipos_tab").click(function () { CargaAnticipos(); });
|
||||
//CARGA BANCOS
|
||||
$("#C_Tab_TabBancos_tab").click(function () { CargaBancos(); });
|
||||
}
|
||||
|
||||
}
|
||||
$(document).on('mouseenter', ".truncate", function () {
|
||||
var $this = $(this);
|
||||
@@ -6706,6 +6733,23 @@
|
||||
$get("HdnCuenta").value = op;
|
||||
$("#BtnCargarCuentas").click();
|
||||
}
|
||||
|
||||
function CargaCxC() {
|
||||
$('#BtnCargaCxC').click();
|
||||
}
|
||||
|
||||
function CargaAnticipos() {
|
||||
$('#BtnCargaAnticipos').click();
|
||||
}
|
||||
|
||||
function CargaBancos() {
|
||||
$('#BtnCargaBancos').click();
|
||||
}
|
||||
|
||||
function CargaHistorialVentas() {
|
||||
$('#BtnHistorialVentas').click();
|
||||
}
|
||||
|
||||
function LimpiaModal() {
|
||||
$('#<%= TxtEnvioDireccion.ClientID %>').val('');
|
||||
$('#<%= TxtEnvioNoExt.ClientID %>').val('');
|
||||
|
||||
@@ -25,9 +25,9 @@ Partial Class Clientes
|
||||
Private Opcion As Integer
|
||||
<PersistenceModeAttribute(PersistenceMode.InnerProperty)>
|
||||
Public ReadOnly Property RowStyle As TableItemStyle
|
||||
Private ReadOnly Property CveCliente As Integer
|
||||
Public ReadOnly Property CveCliente As Integer
|
||||
Get
|
||||
Return ViewState("CveCliente").ToString().ToEntero()
|
||||
Return If(IsNothing(ViewState("CveCliente")), "-1", ViewState("CveCliente").ToString()).ToEntero()
|
||||
End Get
|
||||
End Property
|
||||
Private Property DTCuentasBancos As DataTable
|
||||
@@ -1400,6 +1400,7 @@ Partial Class Clientes
|
||||
HeedarContable.Attributes.Remove("onclick")
|
||||
UpFiscalContable.Update()
|
||||
End Sub
|
||||
|
||||
Private Function CargaDatos() As Boolean
|
||||
Dim watch As New Diagnostics.Stopwatch()
|
||||
watch.Start()
|
||||
@@ -1413,15 +1414,11 @@ Partial Class Clientes
|
||||
CargaDdlSucursalCliente()
|
||||
CargaDocumentosVenta(CveCliente)
|
||||
|
||||
Dim RetSC As Boolean = CargaSucursalesCliente()
|
||||
Dim RetCC As Boolean = CargaCotizaciones()
|
||||
CargaHistorial()
|
||||
CargaResumenHistorial()
|
||||
Dim RetCxC As Boolean = CargaCxC()
|
||||
CargaAnticipos()
|
||||
Dim RetSC As Boolean = CargaSucursalesCliente()
|
||||
|
||||
|
||||
CargaPersonalAsignado()
|
||||
CargaUsuariosPortal()
|
||||
CargaBancos()
|
||||
CargaOrdenesServiciosCliente()
|
||||
CargaImpuestosLocales()
|
||||
CargaCuentasContablesDdls()
|
||||
@@ -2059,6 +2056,8 @@ Partial Class Clientes
|
||||
End If
|
||||
ObjMovtos.Dispose()
|
||||
GvBancos.DataBind()
|
||||
|
||||
UpBancos.Update()
|
||||
End Sub
|
||||
|
||||
Protected Sub GvBancos_RowDataBound(sender As Object, e As System.Web.UI.WebControls.GridViewRowEventArgs) Handles GvBancos.RowDataBound
|
||||
@@ -10627,5 +10626,32 @@ Partial Class Clientes
|
||||
|
||||
CargaDispositivos(DdlEstatusDispositivos.SelectedValue.ToEntero())
|
||||
End Sub
|
||||
Protected Sub BtnCargaCxC_Click(sender As Object, e As EventArgs)
|
||||
If CveCliente > 0 Then
|
||||
CargaCxC()
|
||||
UpDatos.Update()
|
||||
End If
|
||||
End Sub
|
||||
Protected Sub BtnHistorialVentas_Click(sender As Object, e As EventArgs)
|
||||
If CveCliente > 0 Then
|
||||
CargaCotizaciones()
|
||||
CargaHistorial()
|
||||
CargaResumenHistorial()
|
||||
|
||||
UpnHistorial.Update()
|
||||
UpDatos.Update()
|
||||
End If
|
||||
End Sub
|
||||
Protected Sub BtnCargaAnticipos_Click(sender As Object, e As EventArgs)
|
||||
If CveCliente > 0 Then
|
||||
CargaAnticipos()
|
||||
End If
|
||||
End Sub
|
||||
Protected Sub BtnCargaBancos_Click(sender As Object, e As EventArgs)
|
||||
If CveCliente > 0 Then
|
||||
CargaBancos()
|
||||
UpDatos.Update()
|
||||
End If
|
||||
End Sub
|
||||
End Class
|
||||
|
||||
|
||||
@@ -1018,7 +1018,13 @@
|
||||
<div class="row">
|
||||
<label class="col-md-4 truncate">Peso en Kg:</label>
|
||||
<div class="col-md-8">
|
||||
<asp:TextBox ID="TxtPesoKg" runat="server" Width="60px"></asp:TextBox>
|
||||
<asp:TextBox ID="TxtPesoKg" runat="server" Width="60px" Class="form-control input-sm"></asp:TextBox>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<label class="col-md-4 truncate">Dimensiones:</label>
|
||||
<div class="col-md-8">
|
||||
<asp:TextBox ID="TxtDimensiones" runat="server" Width="120px" Class="form-control input-sm"></asp:TextBox>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -812,6 +812,7 @@ Partial Class ProductosyServicios
|
||||
If ObjProductosServicios.PesoKg > 0 Then
|
||||
TxtPesoKg.Text = ObjProductosServicios.PesoKg.ToString
|
||||
End If
|
||||
TxtDimensiones.Text = ObjProductosServicios.Dimensiones
|
||||
|
||||
DdlTipoPSDes.SelectedValueExist(ObjProductosServicios.CveClasificacionDetalle.ToString)
|
||||
DdlUnidadMedida.SelectedValue = ObjProductosServicios.CveUnidadMedida.ToString
|
||||
@@ -939,10 +940,9 @@ Partial Class ProductosyServicios
|
||||
ChkLote.Checked = ObjProductosServicios.AplicaLote
|
||||
ChkCaducidad.Checked = ObjProductosServicios.AplicaCaducidad
|
||||
ChkSeccion.Checked = ObjProductosServicios.AplicaSeccion
|
||||
If ObjProductosServicios.DtResultados.Rows(0)("TiempoCaducidad") IsNot Nothing Then
|
||||
TxtTiempoCaducidad.Text = ObjProductosServicios.DtResultados.Rows(0)("TiempoCaducidad").ToString()
|
||||
DivTiempoCaducidad.Visible = ChkCaducidad.Checked
|
||||
End If
|
||||
|
||||
TxtTiempoCaducidad.Text = ObjProductosServicios.DtResultados.Rows(0)("TiempoCaducidad").ToString()
|
||||
DivTiempoCaducidad.Visible = ChkCaducidad.Checked
|
||||
|
||||
If ObjProductosServicios.AplicaSeccion Then
|
||||
CargaGvSeccionAlmacen()
|
||||
@@ -1330,7 +1330,7 @@ Partial Class ProductosyServicios
|
||||
CveModelo:=DdlModelo.SelectedValue.ToEntero(), CveMedida:=DdlMedida.SelectedValue.ToEntero(), CveRinTamaño:=DdlRin.SelectedValue.ToEntero(),
|
||||
ClaveImpuestoEmpaque:=DdlImpEmpaque.SelectedValue.ToString, ClaveImpuestoUM:=DdlImpUM.SelectedValue.ToString, ClaveCategoriaToxicidad:=DdlCategoriaToxicidad.SelectedValue.ToString,
|
||||
ClaveImpuestoTipoProducto:=DdlImpTipoProducto.SelectedValue.ToString, EsOutSourcing:=ChkEsOutSourcing.Checked, TiempoCaducidad:=TiempoCaducidad, CvePSAdicionalVigencia:=DdlPSAdicionalVigencia.SelectedValue.ToEntero(), PrecioLibre:=ChkPrecioLibre.Checked,
|
||||
CveMaterialPeligroso:=DdlMaterialPeligroso.SelectedValue.ToEntero, CveEmbalaje:=DdlEmbalaje.SelectedValue.ToEntero, PesoKg:=TxtPesoKg.Text.ToDecimal) > 0 Then
|
||||
CveMaterialPeligroso:=DdlMaterialPeligroso.SelectedValue.ToEntero, CveEmbalaje:=DdlEmbalaje.SelectedValue.ToEntero, PesoKg:=TxtPesoKg.Text.ToDecimal, Dimensiones:=TxtDimensiones.Text.Trim) > 0 Then
|
||||
ViewState("CvePS") = ObjProductosServicios.CvePS
|
||||
For Each GVR As GridViewRow In GvImpuestosLocales.Rows
|
||||
If GVR.FCCheckBox("ChkDeduccion").Checked Then
|
||||
@@ -1380,7 +1380,7 @@ Partial Class ProductosyServicios
|
||||
ClaveImpuestoEmpaque:=DdlImpEmpaque.SelectedValue.ToString, ClaveImpuestoUM:=DdlImpUM.SelectedValue.ToString, ClaveCategoriaToxicidad:=DdlCategoriaToxicidad.SelectedValue.ToString,
|
||||
ClaveImpuestoTipoProducto:=DdlImpTipoProducto.SelectedValue.ToString, EsOutSourcing:=ChkEsOutSourcing.Checked,
|
||||
AplicaSerie:=ChkSerie.Checked, AplicaLote:=ChkLote.Checked, AplicaCaducidad:=ChkCaducidad.Checked, AplicaSeccion:=ChkSeccion.Checked, TiempoCaducidad:=TiempoCaducidad, CvePSAdicionalVigencia:=DdlPSAdicionalVigencia.SelectedValue.ToEntero(), PrecioLibre:=ChkPrecioLibre.Checked,
|
||||
CveMaterialPeligroso:=DdlMaterialPeligroso.SelectedValue.ToEntero, CveEmbalaje:=DdlEmbalaje.SelectedValue.ToEntero, PesoKg:=TxtPesoKg.Text.ToDecimal) Then
|
||||
CveMaterialPeligroso:=DdlMaterialPeligroso.SelectedValue.ToEntero, CveEmbalaje:=DdlEmbalaje.SelectedValue.ToEntero, PesoKg:=TxtPesoKg.Text.ToDecimal, Dimensiones:=TxtDimensiones.Text.Trim) Then
|
||||
|
||||
If Not ObjProductosServicios.LimpiaImpuestosLocales(CvePS) Then
|
||||
TieneError = True
|
||||
|
||||
@@ -6216,7 +6216,7 @@ Partial Class Ventas
|
||||
Dim ValorAutorizacion As String = UsuarioActual.Empresa.Funcionalidad(595)
|
||||
|
||||
'OBLIGAR PAGO DE CONTADO SI EL CLIENTE NO PERMITE CREDITO
|
||||
If UsuarioActual.Empresa.Funcionalidad(570) = "1" AndAlso Me.PermiteCredito = False AndAlso DdlTipoComprobante.SelectedValue.Contiene("Ing", "Ant", "Rem") AndAlso CveVenta <= 0 Then
|
||||
If UsuarioActual.Empresa.Funcionalidad(570) = "1" AndAlso Me.PermiteCredito = False AndAlso ((DdlTipoComprobante.SelectedValue.Contiene("Ing", "Ant", "Rem") AndAlso CveVenta < 1) OrElse (DdlTipoComprobante.SelectedValue.Contiene("Ing", "Ant", "Rem", "Cot") AndAlso EsCreaApartirDe)) Then
|
||||
RBLPago.SelectedValue = "2"
|
||||
RBLPago.Items(0).Enabled = False
|
||||
RBLPago_SelectedIndexChanged(Nothing, Nothing)
|
||||
@@ -6234,12 +6234,14 @@ Partial Class Ventas
|
||||
DdlTipoComprobante.Items.Remove(DdlTipoComprobante.Items.FindByValue("Rem"))
|
||||
LnkPedido2SinFacturar.Visible = False
|
||||
LnkCotizaciones.Visible = False
|
||||
BtnsFacturar.Visible = False
|
||||
End If
|
||||
UPCondicionesPago.Update()
|
||||
'CARGAR CREDITO DISPONIBLE AL GENERAR UNA FACTURA
|
||||
End If
|
||||
|
||||
If DdlTipoComprobante.SelectedValue.Contiene("Ing", "Ant", "Rem", "Cot", "PA") AndAlso CveVenta <= 0 AndAlso RBLPago.SelectedValue = "1" AndAlso PermiteCredito Then
|
||||
'FUNCIONALIDAD 702 - NO VERIFICAR LIMITE DE CRÉDITO Y CANDADOS DE VENTA
|
||||
If Not UsuarioActual.Empresa.Funcionalidad(702) = "1" Then
|
||||
RBLPago.SelectedValue = "1"
|
||||
RBLPago_SelectedIndexChanged(Nothing, Nothing)
|
||||
@@ -6252,7 +6254,7 @@ Partial Class Ventas
|
||||
LblCreditoDisponible.Text = CreditoDispo.FormatoNumero
|
||||
If PorcentajeCredito > 80 Then TrPorcentajeCredito.Visible = True : LblPorcentajeCredito.Text = $"{PorcentajeCredito.FormatoNumero}%"
|
||||
|
||||
If Not UsuarioActual.TienePermisoProceso(268) AndAlso DdlTipoComprobante.SelectedValue.Contiene("Ing", "Ant", "Rem", "PA") Then
|
||||
If Not UsuarioActual.TienePermisoProceso(268) AndAlso DdlTipoComprobante.SelectedValue.Contiene("Ing", "Ant", "Rem", "PA") AndAlso (Not UsuarioActual.Empresa.Funcionalidad(702).Contiene("2")) Then
|
||||
Dim Vta As New ClsVentas
|
||||
Dim Opcion As Integer = Vta.ObtenerClienteLimitesVenta(CveCliente, UsuarioActual.CveEmpresa)
|
||||
Dim OpcionMsg As String = String.Format("El Cliente se encuentra bloqueado por la siguiente razón: <br> <br> {0}", Vta.SerieVenta)
|
||||
@@ -6288,8 +6290,9 @@ Partial Class Ventas
|
||||
' el cliente tiene crédito disponible, no tiene bloqueo
|
||||
DdlTipoComprobante.Items.Remove(DdlTipoComprobante.Items.FindByValue("PA"))
|
||||
|
||||
If UsuarioActual.TienePermisoProceso(60) Then DdlTipoComprobante.SelectedValueExistInsert("Ing", "Ingresos") 'puede facturar
|
||||
If UsuarioActual.TienePermisoProceso(199) Then DdlTipoComprobante.SelectedValueExistInsert("Rem", "Remisión") ' puede remisionar
|
||||
If UsuarioActual.TienePermisoProceso(60) Then DdlTipoComprobante.SelectedValueExistInsert("Ing", "Ingresos") 'puede facturar
|
||||
|
||||
DdlTipoComprobante.SelectedValueExist(UsuarioActual.CveTipoDocumento)
|
||||
|
||||
TxtFechaPago.Text = If(DdlTipoComprobante.SelectedValue = "Rem", Now.AddDays(PlazoCobranzaRemision), Now.AddDays(PlazoCobranza)).ToShortDateString
|
||||
@@ -6301,7 +6304,7 @@ Partial Class Ventas
|
||||
'GENERAR AUTORIZACION SI TIENE EXCEDIO EL LIMITE DE CREDITO
|
||||
Select Case ValorAutorizacion
|
||||
Case "1" 'CREAR DOCUMENTO DE AUTORIZACION PA
|
||||
If Not UsuarioActual.TienePermisoProceso(268) AndAlso DdlTipoComprobante.SelectedValue.Contiene("Rem", "Ing", "Ant", "PA") Then
|
||||
If Not UsuarioActual.TienePermisoProceso(268) AndAlso DdlTipoComprobante.SelectedValue.Contiene("Rem", "Ing", "Ant", "PA") AndAlso Not (UsuarioActual.Empresa.Funcionalidad(702).Contiene("2")) Then
|
||||
|
||||
'VERIFICAR CANDADOS DE VENTA, REMISIONES SIN FACTURAR, FACTURAS QUE NO TENGAN VENCIDAS
|
||||
Dim Vta As New ClsVentas
|
||||
@@ -6311,6 +6314,7 @@ Partial Class Ventas
|
||||
If Opcion > 0 Then
|
||||
If Opcion = 1 Then
|
||||
BtnEmitirImprimir.Visible = False
|
||||
BtnsFacturar.Visible = False
|
||||
End If
|
||||
If Alertas Then Alert(OpcionMsg, TipoMensaje.MsgAdvertencia)
|
||||
Else
|
||||
@@ -6387,7 +6391,7 @@ Partial Class Ventas
|
||||
End If
|
||||
|
||||
'Puede hacer pedido
|
||||
If Me.CveVenta <= 0 Then
|
||||
If CveVenta <= 0 Then
|
||||
If Not UsuarioActual.TienePermisoProceso(177) Then
|
||||
If DdlTipoComprobante.Items.FindByValue("Pd2") IsNot Nothing Then
|
||||
DdlTipoComprobante.Items.Remove(DdlTipoComprobante.Items.FindByValue("Pd2"))
|
||||
@@ -7645,36 +7649,40 @@ Partial Class Ventas
|
||||
'No exceder el limite de credito, Si no tiene contrato limita el credito, si tiene no hace nada. Si no tiene remisiones tampoco hace nada.
|
||||
If (Not CveContrato > 0 Or CveContratoTipo.Contiene(28)) AndAlso (Not NuevaFactura = 1) AndAlso RBLPago.SelectedValue = "1" AndAlso DdlTipoComprobante.SelectedValue.Contiene("Ing", "Rem", "Ant") AndAlso RemisionesLista.Count <= 0 AndAlso TxtTotal.Text.ToDecimal > 0 AndAlso Not CvePedidoA > 0 Then
|
||||
'If UsuarioActual.Empresa.Funcionalidad(518) = "1" AndAlso Not UsuarioActual.TienePermisoProceso(185) Then
|
||||
Dim ObjVentas As New ClsVentas
|
||||
|
||||
If ObjVentas.ObtenerCreditoRestante(CveCliente, DdlSucursalCliente.SelectedValue.ToEntero()) Then
|
||||
If ObjVentas.DtResultados.Rows.Count > 0 Then
|
||||
If Not UsuarioActual.Empresa.Funcionalidad(702) = "1" Then
|
||||
Dim ObjVentas As New ClsVentas
|
||||
|
||||
If DdlSucursalCliente.SelectedValue.ToEntero() > 0 Then
|
||||
If ObjVentas.DtResultados(0)("LimiteRestanteSucursal").ToString().ToDecimal - If(TxtTipoCambio.Visible, TxtTotal.Text.ToDecimal * TxtTipoCambio.Text.ToDecimal, TxtTotal.Text.ToDecimal) < 0 Then
|
||||
ObjVentas.Dispose()
|
||||
Alert("Se está excediendo el límite de credito permitido de la Sucursal del Cliente.", TipoMensaje.MsgInformacion)
|
||||
Exit Sub
|
||||
If ObjVentas.ObtenerCreditoRestante(CveCliente, DdlSucursalCliente.SelectedValue.ToEntero()) Then
|
||||
If ObjVentas.DtResultados.Rows.Count > 0 Then
|
||||
|
||||
If DdlSucursalCliente.SelectedValue.ToEntero() > 0 Then
|
||||
If ObjVentas.DtResultados(0)("LimiteRestanteSucursal").ToString().ToDecimal - If(TxtTipoCambio.Visible, TxtTotal.Text.ToDecimal * TxtTipoCambio.Text.ToDecimal, TxtTotal.Text.ToDecimal) < 0 Then
|
||||
ObjVentas.Dispose()
|
||||
Alert("Se está excediendo el límite de credito permitido de la Sucursal del Cliente.", TipoMensaje.MsgInformacion)
|
||||
Exit Sub
|
||||
End If
|
||||
Else
|
||||
If ObjVentas.DtResultados(0)("LimiteRestanteCliente").ToString().ToDecimal - If(TxtTipoCambio.Visible, TxtTotal.Text.ToDecimal * TxtTipoCambio.Text.ToDecimal, TxtTotal.Text.ToDecimal) < 0 Then
|
||||
ObjVentas.Dispose()
|
||||
Alert("Se está excediendo el límite de credito permitido del Cliente.", TipoMensaje.MsgInformacion)
|
||||
Exit Sub
|
||||
End If
|
||||
End If
|
||||
|
||||
Else
|
||||
If ObjVentas.DtResultados(0)("LimiteRestanteCliente").ToString().ToDecimal - If(TxtTipoCambio.Visible, TxtTotal.Text.ToDecimal * TxtTipoCambio.Text.ToDecimal, TxtTotal.Text.ToDecimal) < 0 Then
|
||||
ObjVentas.Dispose()
|
||||
Alert("Se está excediendo el límite de credito permitido del Cliente.", TipoMensaje.MsgInformacion)
|
||||
Exit Sub
|
||||
End If
|
||||
ObjVentas.Dispose()
|
||||
Alert("Ocurrio un error al obtener el limite de credito del cliente", TipoMensaje.MsgError)
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
Else
|
||||
ObjVentas.Dispose()
|
||||
Alert("Ocurrio un error al obtener el limite de credito del cliente", TipoMensaje.MsgError)
|
||||
Exit Sub
|
||||
End If
|
||||
Else
|
||||
ObjVentas.Dispose()
|
||||
Alert("Ocurrio un error al obtener el limite de credito del cliente", TipoMensaje.MsgError)
|
||||
Exit Sub
|
||||
End If
|
||||
ObjVentas.Dispose()
|
||||
|
||||
'End If
|
||||
End If
|
||||
|
||||
@@ -8196,7 +8204,7 @@ Partial Class Ventas
|
||||
Dim CveVentaAnterior As Integer = Me.CveVenta
|
||||
|
||||
GuardarVenta(ObjVentas, ObjConta, ObjInventario, ObjContr, ObjFactura, TmpDT, ObjFactura.CveNCaVincular, ObjContPaq, ObjBancos, ObjOS,
|
||||
ObjEventos, ObjCGame, ObjClientes, EsNCAmortizacion:=EsNCAmortizacion)
|
||||
ObjEventos, ObjCGame, ObjClientes, EsNCAmortizacion:=EsNCAmortizacion, CveAnticipoPadre:=CveAnticipoPadre)
|
||||
|
||||
'Agregamos las OCs a la tabla
|
||||
If ObjFactura.CveVenta > 0 AndAlso ErrorList.Count = 0 AndAlso DTOrdenesCompraPS IsNot Nothing AndAlso DTOrdenesCompraPS.Rows.Count > 0 AndAlso ErrorList.Count = 0 Then
|
||||
@@ -10048,6 +10056,11 @@ Partial Class Ventas
|
||||
'CLIENTE
|
||||
ObjFactura.CveCliente = CveCliente
|
||||
ObjFactura.SetCliente()
|
||||
ObjFactura.CveEmpresaCRM = CveEmpresaCRM
|
||||
If CveCliente = -1 And CveEmpresaCRM > 0 Then
|
||||
ObjFactura.Cliente.Nombre = LblEmpresaCRM.Text
|
||||
ObjFactura.Cliente.RFC = LblRFCCRM.Text
|
||||
End If
|
||||
|
||||
'SUCURSAL
|
||||
'ObjFactura.CveSubProyecto = DdlSubProyectoDatos.SelectedValue.ToEntero()
|
||||
@@ -11171,7 +11184,7 @@ Partial Class Ventas
|
||||
#Region " GUARDAR - VENTA, PREPOLIZAS, INV, ESTIMACIONES, AC, NOTA DE CRÉDITO "
|
||||
Private Sub GuardarVenta(ByRef ObjVentas As ClsVentas, ByRef ObjConta As ClsContabilidad, ByRef ObjInventario As ClsInventarios, ByRef ObjContr As ClsContratos, factura As Modelos.Factura, ByRef TmpDTDetalle As DataTable, CveNCaVincular As Integer,
|
||||
ByRef objContPaqi As ClsContPAQi, Optional ByRef ObjBancos As ClsBancos = Nothing, Optional ByRef ObjOS As ClsOS = Nothing, ByRef Optional ObjEventos As ClsOIEventos = Nothing, ByRef Optional ObjCGame As ClsCGame = Nothing,
|
||||
ByRef Optional ObjCliente As ClsClientes = Nothing, Optional EsNCAmortizacion As Boolean = False, Optional NCDescuento As Boolean = False, Optional ListaNCDescuento As List(Of Modelos.Factura) = Nothing)
|
||||
ByRef Optional ObjCliente As ClsClientes = Nothing, Optional EsNCAmortizacion As Boolean = False, Optional NCDescuento As Boolean = False, Optional ListaNCDescuento As List(Of Modelos.Factura) = Nothing, Optional CveAnticipoPadre As Integer = -1)
|
||||
|
||||
Dim Msgok As New StringBuilder
|
||||
Dim CveAlmacenTraspasoOrigen As Integer = -1
|
||||
@@ -11277,7 +11290,7 @@ Partial Class Ventas
|
||||
FormaPaqueteria:=RblPaqueteria.SelectedValue.ToEntero, FacturarSucursal:=factura.FacturarSucursal, VentaDesglosaIEPS:=factura.VentaDesglosaIEPS, RFCReceptor:=RFCReceptor, Adjunto:=Adjunto, DevolucionImportePagado:=factura.DevolucionImportePagado) Then
|
||||
ErrorList.Add("Ocurrió un error al Generar la Venta.<br />Revise su factura y cualquier detalle comuníquese a Soporte Técnico")
|
||||
Else
|
||||
If factura.TipoDocto.Contiene("Dev", "Egs") OrElse DtVentasNC IsNot Nothing OrElse CveEstatusRefacturacion > 0 Then
|
||||
If factura.TipoDocto.Contiene("Dev", "Egs") OrElse DtVentasNC IsNot Nothing OrElse CveEstatusRefacturacion > 0 OrElse CveAnticipoPadre > 0 Then
|
||||
If DtVentasNC IsNot Nothing Then
|
||||
For Each row As DataRow In DtVentasNC.Rows
|
||||
If Not row("CveVenta").ToString().ToEntero() = -1 Then
|
||||
@@ -11287,6 +11300,7 @@ Partial Class Ventas
|
||||
End If
|
||||
Next
|
||||
Else
|
||||
'SI ES REFACTURACION DEBE AGREGAR LA VENTA ANTERIOR COMO RELACIONADA TAMBIEN
|
||||
If Not CveVenta = -1 Then
|
||||
If Not ObjVentas.AddVentasRelacionadas(ObjVentas.CveVenta, CveVenta) Then
|
||||
ErrorList.Add("Ocurrió un error al relacionar las ventas entre si comuníquese a Soporte Técnico")
|
||||
@@ -11298,6 +11312,14 @@ Partial Class Ventas
|
||||
End If
|
||||
End If
|
||||
End If
|
||||
|
||||
'SI TIENE UN ANTICIPO TAMBIEN DEBE RELACIONARLO
|
||||
If CveAnticipoPadre > 0 Then
|
||||
If Not ObjVentas.AddVentasRelacionadas(ObjVentas.CveVenta, CveAnticipoPadre) Then
|
||||
ErrorList.Add("Ocurrió un error al relacionar las ventas entre si comuníquese a Soporte Técnico")
|
||||
End If
|
||||
End If
|
||||
|
||||
End If
|
||||
End If
|
||||
|
||||
@@ -13824,7 +13846,7 @@ Partial Class Ventas
|
||||
|
||||
CreaObjetosVenta(True)
|
||||
|
||||
If ObjFactura Is Nothing Or ObjFactura.Cliente Is Nothing Then
|
||||
If ObjFactura Is Nothing Or (ObjFactura.Cliente Is Nothing And Not CveEmpresaCRM > 0) Then
|
||||
Alert("Ocurrió un error al procesar los datos para la vista previa. Por favor rectifique y vuelva a intentar.", TipoMensaje.MsgError)
|
||||
ObjFactura = Nothing
|
||||
Exit Sub
|
||||
@@ -18142,7 +18164,7 @@ Partial Class Ventas
|
||||
|
||||
End Sub
|
||||
Private Sub SetPermisos()
|
||||
If CveVenta < 1 Then
|
||||
If CveVenta < 1 OrElse EsCreaApartirDe Then
|
||||
'Puede cotizar
|
||||
If Not UsuarioActual.TienePermisoProceso(59) Then
|
||||
DdlTipoComprobante.Items.Remove(DdlTipoComprobante.Items.FindByValue("Cot"))
|
||||
@@ -18933,13 +18955,6 @@ Partial Class Ventas
|
||||
End If
|
||||
End If
|
||||
|
||||
If Not OcurrioError AndAlso ConSalida Then
|
||||
'Esquema viejo, evitamos que aparezca por surtir
|
||||
If Not ObjInventario.ActualizarEsDevolucionVenta(ObjFactura.CveVenta, 2) Then
|
||||
OcurrioError = True
|
||||
End If
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
End If
|
||||
@@ -19108,6 +19123,23 @@ Partial Class Ventas
|
||||
'COMIENZA: VENTADETALLE
|
||||
'CUANDO SEA SALIDA VA POR LA VENTA DETALLE DE LA FACTURA DE LA REMISION - OJO!! SOLO FUNCIONA HASTA ORITA QUE SE HACE SALIDA SOLO CUANDO SE FACTURA LA REMISION
|
||||
Dim CveVentaDetalle = If(ConceptoEntrada.Contiene(3, 40), TmpDT.FiltroPrimeroValor("CveVentaDetalle", $"Consec={Consec}").ToEntero(), MovDet("CveVentaDetalle").ToString().ToEntero())
|
||||
Dim CveVentaDetallePadre As Integer = -1
|
||||
|
||||
'If ConceptoEntrada = 3 Then
|
||||
' CveVentaDetalle = TmpDT.FiltroPrimeroValor("CveVentaDetalle", $"Consec={Consec}").ToEntero()
|
||||
'ElseIf ConceptoEntrada = 40 Then
|
||||
' CveVentaDetalle = MovDet("CveVentaDetalle").ToString().ToEntero()
|
||||
' CveVentaDetallePadre = TmpDT.FiltroPrimeroValor("CveVentaDetalle", $"Consec={Consec}").ToEntero()
|
||||
' 'CUANDO LA VENTADETALLE NO TENGA VALOR DEBE MARCAR ERROR, NUEVA RESTRICCION DE ALMACEN
|
||||
' If CveVentaDetallePadre < 0 Then
|
||||
' Alert("no se encontro la venta detalle nueva. Por favor comuniquese con atención SIG.", TipoMensaje.ToastError)
|
||||
' OcurrioError = True
|
||||
' Exit For
|
||||
' End If
|
||||
'Else
|
||||
' CveVentaDetalle = MovDet("CveVentaDetalle").ToString().ToEntero()
|
||||
'End If
|
||||
|
||||
'CUANDO LA VENTADETALLE NO TENGA VALOR DEBE MARCAR ERROR, NUEVA RESTRICCION DE ALMACEN
|
||||
If CveVentaDetalle < 0 Then
|
||||
Alert("no se encontro la venta detalle. Por favor comuniquese con atención SIG.", TipoMensaje.ToastError)
|
||||
@@ -19128,7 +19160,7 @@ Partial Class Ventas
|
||||
CveMovimientoDetalleEntrada = MovDet("CveMovimientoDetalle").ToString().ToEntero()
|
||||
End If
|
||||
|
||||
If ObjInventario.AddMovimientoDetalle(CveMovimientoInventario, Cantidad, CveUnidad, CveProducto, PU, -1, CveSeccionAlmacen:=CveSeccionAlmacen, Serie:=Serie, Lote:=Lote, FechaCaducidad:=FechaCaducidad, CveVentaDetalle:=CveVentaDetalle, CveMovimientoDetalleEntrada:=CveMovimientoDetalleEntrada) Then
|
||||
If ObjInventario.AddMovimientoDetalle(CveMovimientoInventario, Cantidad, CveUnidad, CveProducto, PU, -1, CveSeccionAlmacen:=CveSeccionAlmacen, Serie:=Serie, Lote:=Lote, FechaCaducidad:=FechaCaducidad, CveVentaDetalle:=CveVentaDetalle, CveMovimientoDetalleEntrada:=CveMovimientoDetalleEntrada, CveVentaDetallePadre:=CveVentaDetallePadre) Then
|
||||
ContadorMovtosDetalles += 1
|
||||
Else
|
||||
OcurrioError = True
|
||||
@@ -23101,7 +23133,7 @@ Partial Class Ventas
|
||||
RequiereAlmacenDestino = True
|
||||
DdlAlmacenAsignado.Items.Clear()
|
||||
DdlAlmacenAsignado.Items.Insert(0, New ListItem(" Seleccione ", "-1"))
|
||||
DdlAlmacenAsignado.SelectedValue = "-1"
|
||||
DdlAlmacenAsignado.SelectedValueExist("-1")
|
||||
DdlAlmacenAsignado.DataBind()
|
||||
DdlAlmacenAsignado.Items.Insert(0, New ListItem("Almacen", DbRowVenta("CveAlmacenTraspasoOrigen").ToString()))
|
||||
DdlAlmacenAsignado.SelectedValueExist(DbRowVenta("CveAlmacenTraspasoOrigen").ToString())
|
||||
@@ -29831,6 +29863,8 @@ Partial Class Ventas
|
||||
GvPS.Columns(17).Visible = True
|
||||
GvPS.Columns(18).Visible = True
|
||||
|
||||
SetPermisos()
|
||||
|
||||
CambiaTipoDocto()
|
||||
CambiaSucursalGeneral(RecargarPartidas:=False)
|
||||
CargaAnticipos(CveCliente)
|
||||
|
||||
Reference in New Issue
Block a user