This commit is contained in:
Rakcsle Supertramp
2020-01-14 13:17:33 -07:00
51 changed files with 16555 additions and 15800 deletions

View File

@@ -483,7 +483,7 @@ Public Class ClsAcumuladores
#Region " FOLIOS GARANTÍA "
Public Function FoliosGarantiaGet(CveFolioGarantia As Integer, CveEmpresa As Integer) As Boolean
Public Function FoliosGarantiaGet(CveFolioGarantia As Integer, CveEmpresa As Integer, Optional Estatus As Integer = -1) As Boolean
Dim Retorno As Boolean = False
'Data = New DataTable
@@ -491,6 +491,7 @@ Public Class ClsAcumuladores
With SqlAdapter.SelectCommand.Parameters
.Add("@CveFolioGarantia", SqlDbType.Int).Value = CveFolioGarantia
.Add("@Estatus", SqlDbType.Int).Value = Estatus
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
End With
@@ -753,7 +754,21 @@ Public Class ClsAcumuladores
SqlAdapter.Fill(Data)
Retorno = True
Catch ex As SqlException
OnError("Ocurrió un al agregar la garantia detalle. ", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
OnError("Ocurrió un al obtener la garantía detalle. ", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
End Try
Return Retorno
End Function
Public Function GetGarantiasPolizaVirtual(CveVenta As Integer) As Boolean
Dim Retorno As Boolean = False
SqlDataAdapter("PA_Acum_GarantiasPolizaVirtualGet")
With SqlAdapter.SelectCommand.Parameters
.Add("@CveVenta", SqlDbType.Int).Value = CveVenta
End With
Try
SqlAdapter.Fill(Data)
Retorno = True
Catch ex As SqlException
OnError("Ocurrió un al obtener la información de poliza virtual.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
End Try
Return Retorno
End Function

View File

@@ -568,7 +568,7 @@ Public Class ClsClientes
Optional ObservacionRevsion As String = "-1", Optional ReferenciaFiscal As String = "-1", Optional Celular As String = "-1", Optional ExtOtros As String = "-1", Optional CveUsoCFDI As Integer = -1, Optional CveFormaPago33 As Integer = -1, Optional CveMetodoPago33 As Integer = -1, Optional DesglosaIEPS As Boolean = True,
Optional AplicaComercioExterior As Boolean = False, Optional CveTipoOperacion As Integer = -1, Optional CvePedimento As Integer = -1, Optional CveIncoterm As Integer = -1, Optional CvePais As Integer = -1, Optional CveEstado As Integer = -1, Optional CveMunicipio As Integer = -1, Optional CveColonia As Integer = -1,
Optional CveMotivoTraslado As Integer = 0, Optional NumRegIdTrib As String = "", Optional ComExtEstado As String = "-1", Optional ComExtMunicipio As String = "-1", Optional ComExtColonia As String = "-1", Optional RequiereOC As Boolean = False,
Optional LT As String = "0", Optional LG As String = "0", Optional EsDistribuidor As Boolean = False, Optional TipoCliente As Integer = 1, Optional CargoUsado As Boolean = False, Optional BonificacionUsado As Boolean = False) As Boolean
Optional LT As String = "0", Optional LG As String = "0", Optional EsDistribuidor As Boolean = False, Optional TipoCliente As Integer = 1, Optional CargoUsado As Boolean = False, Optional BonificacionUsado As Boolean = False, Optional CveTipoRetencion As Integer = 0) As Boolean
Dim Retorno As Boolean = False
@@ -702,6 +702,7 @@ Public Class ClsClientes
.Add("@TipoCliente", SqlDbType.Int).Value = TipoCliente
.Add("@CargoUsado", SqlDbType.Bit).Value = CargoUsado
.Add("@BonificacionUsado", SqlDbType.Bit).Value = BonificacionUsado
.Add("@CveTipoRetencion", SqlDbType.TinyInt).Value = CveTipoRetencion
.Add("@RETURN_VALUE", SqlDbType.Int).Direction = ParameterDirection.ReturnValue
End With
@@ -747,7 +748,7 @@ Public Class ClsClientes
Optional AplicaComercioExterior As Boolean = False, Optional CveTipoOperacion As Integer = -1, Optional CvePedimento As Integer = -1, Optional CveIncoterm As Integer = -1, Optional CvePais As Integer = -1, Optional CveEstado As Integer = -1, Optional CveMunicipio As Integer = -1, Optional CveColonia As Integer = -1,
Optional CveMotivoTraslado As Integer = 0, Optional NumRegIdTrib As String = "-1", Optional ComExtEstado As String = "-1", Optional ComExtMunicipio As String = "-1", Optional ComExtColonia As String = "-1",
Optional ApellidoPaternoPF As String = "-1", Optional ApellidoMaternoPF As String = "-1", Optional NombresPF As String = "-1", Optional RequiereOC As Boolean = False,
Optional LT As String = "0", Optional LG As String = "0", Optional EsDistribuidor As Boolean = False, Optional TipoCliente As Integer = 1, Optional CargoUsado As Boolean = False, Optional BonificacionUsado As Boolean = False) As Boolean
Optional LT As String = "0", Optional LG As String = "0", Optional EsDistribuidor As Boolean = False, Optional TipoCliente As Integer = 1, Optional CargoUsado As Boolean = False, Optional BonificacionUsado As Boolean = False, Optional CveTipoRetencion As Integer = 0) As Boolean
Dim Retorno As Boolean = False
@@ -897,6 +898,7 @@ Public Class ClsClientes
.Add("@TipoCliente", SqlDbType.Int).Value = TipoCliente
.Add("@CargoUsado", SqlDbType.Bit).Value = CargoUsado
.Add("@BonificacionUsado", SqlDbType.Bit).Value = BonificacionUsado
.Add("@CveTipoRetencion", SqlDbType.TinyInt).Value = CveTipoRetencion
End With
Try
SqlAdapter.Fill(Data)
@@ -1581,6 +1583,22 @@ Public Class ClsClientes
Try
SqlAdapter.Fill(Data)
Retorno = True
Catch Ex1 As SqlException
If Ex1.Message.Contains("Número: 2627;") Then
Alert("El Nuevo Cliente no se guardo debido a que actualmente se encuentra registrado", TipoMensaje.MsgAdvertencia)
ElseIf Ex1.Message.Contains("Número: 2601;") Then
If Ex1.Message.Contains("UN_ClientesRFCEmpresa") Then
Alert("Ya existe un cliente registrado con el mismo RFC.", TipoMensaje.MsgAdvertencia)
End If
If Ex1.Message.Contains("IND_Clientes_Codigo") Then
Alert("Ya existe un cliente registrado con el mismo Código.", TipoMensaje.MsgAdvertencia)
End If
Else
Me.OnError("Ocurrió un error al Intentar guardar el Nuevo Cliente.", Ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
End If
Catch ex As Exception
OnError("Ocurrió un error al agregar el cliente", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
End Try

View File

@@ -5768,6 +5768,7 @@ Public Class ClsContabilidad
.Add("@Opcion", SqlDbType.Int).Value = Opcion
.Add("@Valor", SqlDbType.Int).Direction = ParameterDirection.Output
.Add("@MsgSalida", SqlDbType.VarChar, 100).Direction = ParameterDirection.Output
.Add("@MsgPrePolizaSalida", SqlDbType.VarChar, 800).Direction = ParameterDirection.Output
.Add("@Diferencia", SqlDbType.Float).Direction = ParameterDirection.Output
End With

View File

@@ -133,6 +133,24 @@ Public Class ClsGenerales
End With
End Sub
Public Function RepConciliacionSatDetalleGET(cveEmpresa As Int32, tipoDocto As String, fechaI As String, fechaF As String, RegistroEn As Integer) As Boolean
Dim retorno As Boolean = False
DataAdapter("PA_RepConciliacionSatDetalleGET", CommandType.StoredProcedure)
With SqlAdapter.SelectCommand.Parameters
.Add("@CveEmpresa", SqlDbType.Int).Value = cveEmpresa
.Add("@TipoDocto", SqlDbType.VarChar).Value = tipoDocto
.Add("@RegistroEn", SqlDbType.Int).Value = RegistroEn
.Add("@FechaI", SqlDbType.VarChar).Value = fechaI
.Add("@FechaF", SqlDbType.VarChar).Value = fechaF
End With
Try
SqlAdapter.Fill(Data)
retorno = True
Catch ex As Exception
OnError("Ocurrió un error al obtener los registros de Conciliaciones SAT.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
End Try
Return retorno
End Function
Public Function RepConciliacionSatGET(cveEmpresa As Int32, tipoDocto As String, fechaI As String, fechaF As String) As Boolean
Dim retorno As Boolean = False

View File

@@ -3986,6 +3986,8 @@ Public Class ClsPaginas
PaginaDict.Add("/Contabilidad/CatCuentasSIG.aspx".ToUpper(), 405)
PaginaDict.Add("/Contabilidad/RepIEPS.aspx".ToUpper(), 714)
PaginaDict.Add("/Contabilidad/CatPeriodosBloqueo.aspx".ToUpper(), 677)
PaginaDict.Add("/Contabilidad/CatClasificacionPorcentaje.aspx".ToUpper(), 752)
#End Region
'CONTABILIDAD2
#Region "Contabilidad2"

View File

@@ -317,7 +317,7 @@ Public Class ClsVentas
Optional ObservacionesAlmacen As String = "", Optional CveSubProyecto As Integer = -1, Optional CveSubProyectoEjecucion As Integer = -1, Optional CveSubProyectoCobranza As Integer = -1,
Optional CveFormaPago33 As Integer = -1, Optional CveMetodoPago33 As Integer = -1, Optional CveUsoCFDI As Integer = -1, Optional OrdenCompra As String = "-1", Optional CveCuentaTerminal As Integer = -1, Optional CveTipoRelacion As Integer = -1, Optional ImpuestoLocal As Double = 0,
Optional CveTipoAmortizacionAnticipo As Integer = -1, Optional CveVentaRelacion As Integer = -1, Optional ImporteRelacion As Decimal = -1, Optional CveEmpresaCRM As Integer = -1, Optional EsInterno As Integer = -1, Optional CveAcercamientoCRM As Integer = -1,
Optional DiasCredito As Integer = 0, Optional EsDiasCreditoFijo As Boolean = False, Optional AnticipoEspecial As Boolean = False) As Boolean
Optional DiasCredito As Integer = 0, Optional EsDiasCreditoFijo As Boolean = False, Optional AnticipoEspecial As Boolean = False, Optional Kilometraje As Double = 0) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_VentasAdd")
@@ -403,6 +403,7 @@ Public Class ClsVentas
.Add("@DiasCredito", SqlDbType.Int).Value = DiasCredito
.Add("@EsDiasCreditoFijo", SqlDbType.Bit).Value = EsDiasCreditoFijo
.Add("@AnticipoEspecial", SqlDbType.Bit).Value = AnticipoEspecial
.Add("@Kilometraje", SqlDbType.Float).Value = Kilometraje
.Add("@RETURN_VALUE", SqlDbType.Int).Direction = ParameterDirection.ReturnValue
End With
@@ -430,7 +431,8 @@ Public Class ClsVentas
Fecha As Date, Observaciones As String, CveEmpresa As Integer, CveVenta As Integer, CveMetodoPago As Integer, FormaPago As Integer,
Optional TipoDocto As String = "Cot", Optional Vigencia As Date = MinFecha, Optional CondicionesPago As Integer = -1,
Optional AtencionA As String = "-1", Optional PedidoContrato As String = "-1", Optional CveFormaPago33 As Integer = -1, Optional CveMetodoPago33 As Integer = -1,
Optional CveCliente As Integer = -1, Optional CveClienteSucursal As Integer = -1, Optional OrdenCompra As String = "-1", Optional RetIVA As Double = -1, Optional RetISR As Double = -1) As Boolean
Optional CveCliente As Integer = -1, Optional CveClienteSucursal As Integer = -1, Optional OrdenCompra As String = "-1", Optional RetIVA As Double = -1,
Optional RetISR As Double = -1, Optional Kilometraje As Double = 0) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_Vta_VentasUpdate")
@@ -460,6 +462,7 @@ Public Class ClsVentas
.Add("@CveCliente", SqlDbType.Int).Value = CveCliente
.Add("@CveClienteSucursal", SqlDbType.Int).Value = CveClienteSucursal
.Add("@OrdenCompra", SqlDbType.VarChar).Value = OrdenCompra
.Add("@Kilometraje", SqlDbType.Float).Value = Kilometraje
End With
Try
@@ -2674,6 +2677,45 @@ Public Class ClsVentas
Return OnError
End Function
Public Function GetFacturasCanceladasPendientesWS(RFC As String, CveEmpresa As Integer, Optional showalert As Boolean = True) As Boolean
Dim retorno As Boolean = False
Try
Dim objServicio As Cancelacion.CancelacionSoapClient = New Cancelacion.CancelacionSoapClient()
Dim resp As Cancelacion.StructCancel = objServicio.ObtienePendientes(RFC, "UserTest", "1234567890")
If resp.Estado = 0 Then
Dim XmlPendientes As String = System.Text.Encoding.UTF8.GetString(Convert.FromBase64String(resp.Xml))
Dim theReader As IO.StringReader = New IO.StringReader(XmlPendientes)
Dim theDataSet As DataSet = New DataSet()
theDataSet.ReadXml(theReader)
If theDataSet.Tables(0).Rows(0)("Uuid").ToString() <> "null" Then
Dim sb = New StringBuilder()
For Each item As DataRow In theDataSet.Tables(0).Rows
sb.AppendFormat("{0};", item("Uuid").ToString())
Next
If GetFacturasCanceladasPendientes(sb.ToString(), CveEmpresa) Then
retorno = True
End If
Else
If showalert Then
Alert("No se encontraron cancelaciones pendientes", ModExtensiones.TipoMensaje.MsgError)
End If
End If
Else
Alert("Error al obtener cancelaciones pendientes: " & resp.Descripcion, ModExtensiones.TipoMensaje.MsgError)
End If
Catch ex As Exception
retorno = False
Me.OnError("Error al obtener cancelaciones pendientes: ", ex, "")
End Try
Return retorno
End Function
Public Function UpdateVentaFacturas(CveFactura As Integer, CveVenta As Integer, CveEmpresa As Integer) As Boolean
Dim OnError As Boolean = False

View File

@@ -368,7 +368,7 @@ Namespace Modelos
End If
Timbre = New CFDITimbre
End Sub
Public Sub New(UsuarioActual As Usuario, CveVenta As Integer, CveEmpresa As Integer, Optional DirectorioServidor As String = "")
Public Sub New(UsuarioActual As Usuario, CveVenta As Integer, CveEmpresa As Integer, Optional DirectorioServidor As String = "", Optional EsCancelacion As Boolean = False)
Me.UsuarioActual = UsuarioActual
Me.CveVenta = CveVenta
Me.CveEmpresa = CveEmpresa
@@ -393,7 +393,7 @@ Namespace Modelos
Me.DtDetalle = ObjVentas.DtResultados.Copy()
End If
ObjVentas.Dispose()
IniciaValoresVentas()
IniciaValoresVentas(EsCancelacion)
If String.IsNullOrEmpty(DirectorioServidor) Then
DirectorioServidor = HttpContext.Current.Server.MapPath("/")
End If
@@ -446,7 +446,7 @@ Namespace Modelos
Me.IEPS = 0
Me.CveAlmacenTraspasoOrigen = 0
End Sub
Private Sub IniciaValoresVentas()
Private Sub IniciaValoresVentas(Optional EsCancelacion As Boolean = False)
If CveVenta > 0 AndAlso CveEmpresa > 0 Then
Me.DtAnticipos = New DataTable()
Me.DtAntNCVinculadas = New DataTable()
@@ -492,6 +492,10 @@ Namespace Modelos
Me.DtNCVinculadas = ObjVentas.DtResultados.Copy()
End If
If TipoDocto.Contiene("Ant") AndAlso EsCancelacion Then
EsNCAmortizacion = True
End If
If ObjVentas.GetVentasAntNC(-1, CveVenta, AplicaAmortizacion:=EsNCAmortizacion) Then
Me.DtAnticipos = ObjVentas.DtResultados.Copy()
End If
@@ -2333,7 +2337,7 @@ Namespace Modelos
Exit Select
End If
If ObjFactura.TipoDocto.Contiene("Ing", "Egs") AndAlso ValorMultiplicador = -1 Then
If ObjFactura.TipoDocto.Contiene("Ing", "Egs", "Ant") AndAlso ValorMultiplicador = -1 Then
For Each row2 As DataRow In ObjFactura.DtAnticipos.Rows
If row2("CveConceptoContable").ToString().ToEntero = 11 Then
importeMovimiento = row2("Importe").ToString().ToDecimal * ValorMultiplicador '- ((row2.FCTextBox("TxtAnticipo" & row2.RowIndex).Text.ToDecimal / row2.DataKey("TotalAnticipo").ToDecimal) * row2.DataKey("IVAAnticipo").ToDecimal)
@@ -2344,7 +2348,10 @@ Namespace Modelos
CveSubProyectoContabilizar = CveSubProyectoVenta
If importeMovimiento <> 0 Then
If Not ObjConta.AddPrePolizasDetalle(ObjFactura.CvePrePoliza, TipoMovimiento, importeMovimiento, Referencia, ConceptoContable, Concepto, FechaMovimiento, IdCtaContable, -1, CveVenta:=row2("CveVenta").ToString().ToEntero, CveVentaAmortizacion:=ObjFactura.CveVenta, CveCliente:=ObjFactura.CveCliente, CveIE:=CveIEAnticipo, ImporteMX:=importeMovimiento * tipoCambio, ImporteME:=If(tipoCambio = 1, 0, importeMovimiento), CveCuenta:=CveCuenta, CveSubProyecto:=CveSubProyectoContabilizar, Contabilizable:=SeContabiliza) Then
If Not ObjConta.AddPrePolizasDetalle(ObjFactura.CvePrePoliza, TipoMovimiento, importeMovimiento, Referencia, ConceptoContable, Concepto, FechaMovimiento, IdCtaContable, -1,
CveVenta:=ObjFactura.CveVenta, CveVentaAmortizacion:=row2("CveVenta").ToString().ToEntero, CveCliente:=ObjFactura.CveCliente,
CveIE:=CveIEAnticipo, ImporteMX:=importeMovimiento * tipoCambio, ImporteME:=If(tipoCambio = 1, 0, importeMovimiento), CveCuenta:=CveCuenta,
CveSubProyecto:=CveSubProyectoContabilizar, Contabilizable:=SeContabiliza) Then
ErrorPrepoliza = True
Exit For
Else

View File

@@ -54,8 +54,8 @@ Namespace Extensiones
' BaseDatos = CType(System.Web.HttpContext.Current.Session("UsuarioSIG"), Usuario).Empresa.BaseDatosNombre
'End If
Return String.Format("Data Source=192.168.0.2;Initial Catalog={0};User Id=JCaudillo;Password=JCau127*953;pooling=True; Min Pool Size=10;Application Name=SIG;", BaseDatos)
Return ConfigurationManager.ConnectionStrings("Conexion").ConnectionString
' Return String.Format("Data Source=192.168.0.2;Initial Catalog={0};User Id=JCaudillo;Password=JCau127*953;pooling=True; Min Pool Size=10;Application Name=SIG;", BaseDatos)
End Function

View File

@@ -247,13 +247,13 @@ Public Class SIGWeb : Implements IHttpHandler, IRequiresSessionState
'ObjProveedores.Dispose()
Dim dt As DataTable = DirectCast(context.Application(AppNombre), DataTable).FiltraParametros($"CveEmpresa = {CveEmpresa}")
If dt IsNot Nothing AndAlso dt.Rows.Count > 0 Then
DtRetorno = dt.FiltraParametros($"RazonSocial like '%{Name}%'")
DtRetorno = dt.FiltraParametros($"NombreCortoProveedor like '%{Name}%'")
End If
End If
If DtRetorno IsNot Nothing AndAlso DtRetorno.Rows.Count > 0 Then
DtRetorno.Columns("CveProveedor").ColumnName = "id"
DtRetorno.Columns("RazonSocial").ColumnName = "text"
DtRetorno.Columns("NombreCortoProveedor").ColumnName = "text"
retorno = JsonConvert.SerializeObject(DtRetorno).ToString
context.Response.Write(retorno)
Else

View File

@@ -613,6 +613,7 @@ Partial Class Bancos_ConciliacionesBancariasaspx
params.Add(New ReportParameter("SaldoFinalLibros", SaldoFinalLibros.FormatoNumero))
Dim SaldoFinalContabilidad As Double = 0
Dim SaldoFinalContabilidadComplementaria As Double = 0
If DdlCuenta.SelectedValue.ToEntero > 0 Then
Dim CveCuenta As Integer = 0
Dim CveCuentaComplementaria As Integer = 0
@@ -636,7 +637,7 @@ Partial Class Bancos_ConciliacionesBancariasaspx
If CveCuentaComplementaria > 0 Then
If ObjConta.GetMovimientosAuxiliaresCatalogo(CveCuentaComplementaria, txtFechaI.Text.ToDate, txtFechaF.Text.ToDate, CveMoneda, "-1", UsuarioActual.CveEmpresa, "1") Then
If ObjConta.DtResultados.Rows.Count > 1 Then
SaldoFinalContabilidad += ObjConta.DtResultados.Rows(1)("SaldoActual").ToString.ToDouble
SaldoFinalContabilidadComplementaria = ObjConta.DtResultados.Rows(1)("SaldoActual").ToString.ToDouble
End If
End If
End If
@@ -644,6 +645,7 @@ Partial Class Bancos_ConciliacionesBancariasaspx
End If
params.Add(New ReportParameter("SaldoFinalContabilidad", (SaldoFinalContabilidad.FormatoNumero)))
params.Add(New ReportParameter("SaldoFinalContabilidadComplementaria", (SaldoFinalContabilidadComplementaria.FormatoNumero)))
params.Add(New ReportParameter("Diferencia", (SaldoFinalLibros - SaldoFinalContabilidad).FormatoNumero))
If Imagen.Exists Then

View File

@@ -315,6 +315,8 @@ Partial Class Bancos_FluctuacionCambiaria
Dim Total As Decimal = 0
Dim Conta As New ClsContabilidad
Conta.IniciaTransacSQL()
Dim ObjContPaq As New ClsContPAQi(UsuarioActual.Empresa)
ObjContPaq.IniciaTransacSQL()
Dim CvePrePoliza As Integer = Conta.AddPrePolizas("Banc/Fluctua", 1, 0, 0, 1, TxtFecha.Text.ToDate, "Fluctuación", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
Dim idCta As Integer = 0
Dim CveCuenta As Integer = 0
@@ -372,8 +374,19 @@ Partial Class Bancos_FluctuacionCambiaria
End If
Next
Dim SeContabilizo As Boolean = False
Dim AutoConta As Boolean = UsuarioActual.Empresa.Funcionalidad(200) = "1"
If AutoConta Then
If Conta.ContabilizarPrePoliza(CvePrePoliza, UsuarioActual.CveUsuario, UsuarioActual.Empresa, ObjConta:=ObjContPaq) Then
SeContabilizo = True
Else
Alert("Ocurrio un Error al contabilizar, pongase en contacto con Soporte Técnico", TipoMensaje.MsgError)
End If
End If
If Not ErrorRegistrar And SeContabilizo Then
If Not ErrorRegistrar Then
Conta.Commit()
Alert(String.Format("La Fluctuación se ha generado <br/> <a href='/Contabilidad/RegPrePoliza.aspx?CvePrePoliza={0}'>Ver Póliza</a>", CvePrePoliza), TipoMensaje.MsgInformacion)
CargaDatosCuentas()

View File

@@ -2323,6 +2323,8 @@ Partial Class Bancos_IE
CveConceptoCompra = 21 'Pago a Proveedor/CAncelacion Anticipos
CveConceptoContable = 30 'Bancos
CvePlantillaPoliza = 7
ElseIf CveCliente > 0 Then
CvePlantillaPoliza = 11
End If
End If

View File

@@ -827,7 +827,7 @@ Partial Class Bancos_ProveedoresAbonar
'cheque
If DdlTipoTransaccion.SelectedValue = "1" Then FolioFijo = TxtFolio.Text.ToEntero
If DdlTipoTransaccion.SelectedValue = "1" AndAlso UsuarioActual.CveEmpresa.Contiene(13, 83) Then FolioFijo = TxtFolio.Text.ToEntero
CvePrePoliza = ObjMov.AddPrePolizas("Bancos/ProveedoresAbonar", 2, ImporteSeleccionado, ImporteSeleccionado, GlobalDTBancosCuentas(UsuarioActual.CveUsuario).FiltroPrimeroValor("CveMoneda", "CveCuenta = " & DdlCuenta.SelectedValue).ToEntero, TxtFechaDocumento.Text.ToDate, ConceptoPoliza, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, FolioFijo:=FolioFijo, ReglaFolioPoliza:=ObjComp.ObtenerReglaFolio(DdlTipoTransaccion.SelectedValue, Nothing, UsuarioActual.CveEmpresa), CveTipoPoliza:=ObjMov.ObtenerTipoPoliza(DdlTipoTransaccion.SelectedValue, "-1", UsuarioActual.CveEmpresa))

View File

@@ -13594,34 +13594,39 @@ Partial Class Compras_Compras
' guardardevolucion(ObjInventario, cvecompra, subtotal, Now.ToDate)
'End Sub
Protected Sub BtnVinculaDevolucion_Click(sender As Object, e As EventArgs)
Dim subtotaldevolucion As Double = 0
Dim realizadevolucion As Boolean = False
Try
Dim subtotaldevolucion As Double = 0
Dim realizadevolucion As Boolean = False
'Calculo los subtotales para comparar con la NC
Dim cantidad As Double = 0.0
'Calculo los subtotales para comparar con la NC
Dim cantidad As Double = 0.0
For Each Dr As GridViewRow In GVDevolucion.Rows
cantidad = Dr.FCTextBox("TxtCantidad").Text.ToDouble
If cantidad > 0 Then
realizadevolucion = True
subtotaldevolucion += Dr.DataKey("PU").ToString.ToDouble * cantidad
End If
Next
For Each Dr As GridViewRow In GVDevolucion.Rows
cantidad = Dr.FCTextBox("TxtCantidad").Text.ToDouble
If cantidad > 0 Then
realizadevolucion = True
subtotaldevolucion += Dr.DataKey("PU").ToString.ToDouble * cantidad
End If
Next
'si no esta vinculado a nc simplemente me lo brinco
If realizadevolucion Then
'si el subtotal es iwal a la nc lo guardo si no marco error
If TxtSubTotal.Text.ToDouble > subtotaldevolucion - 1 AndAlso TxtSubTotal.Text.ToDouble < subtotaldevolucion + 1 Then
'si no esta vinculado a nc simplemente me lo brinco
If realizadevolucion Then
'si el subtotal es iwal a la nc lo guardo si no marco error
If TxtSubTotal.Text.ToDouble > subtotaldevolucion - 1 AndAlso TxtSubTotal.Text.ToDouble < subtotaldevolucion + 1 Then
VinculaDevolucion()
VinculaDevolucion()
Else
Alert("El Total de la NC debe ser igual al total de la devolucion", TipoMensaje.MsgAdvertencia)
End If
Else
Alert("El Total de la NC debe ser igual al total de la devolucion", TipoMensaje.MsgAdvertencia)
Alert("No se ha seleccionado nada para la devolución. Por favor rectifique y vuelva a intentar.", TipoMensaje.MsgAdvertencia)
End If
Else
Alert("No se ha seleccionado nada para la devolución. Por favor rectifique y vuelva a intentar.", TipoMensaje.MsgAdvertencia)
End If
Catch ex As Exception
OnError("Ocurrió un error al realizar la vinculación", ex)
End Try
End Sub
@@ -13685,7 +13690,7 @@ Partial Class Compras_Compras
GvOC1.DataSource = DTOCTemp
Dim DTCVEOCS As DataTable = DTOCTemp.FiltraParametros("", "", {"CveOrdenCompra"})
If DTCVEOCS.Rows.Count > 1 Then
If DTCVEOCS IsNot Nothing AndAlso DTCVEOCS.Rows.Count > 1 Then
GvOC1.Columns(0).Visible = True
Else
GvOC1.Columns(0).Visible = False

View File

@@ -1471,7 +1471,7 @@ Partial Class PopUpVerFactura
If Archivo.Exists Then
'IMPRESION ESPECIAL SALIDA DE COMPUPROVEEDORES y VSH
If UsuarioActual.CveEmpresa.Contiene(1, 72, 80, 119, 4, 145) Then
If UsuarioActual.CveEmpresa.Contiene(1, 72, 80, 119, 4, 145, 146) Then
Dim CiudadSucursal As String = ""
Dim DomicilioSucursal As String = ""
Dim DomicilioCliente As String = String.Format("{0} #{1}, {2}, Col. {3}, CP: {4}, {5}, {6}", DtMovimientos(0)("SucClienteDireccion").ToString, DtMovimientos(0)("SucClienteNoExt").ToString, DtMovimientos(0)("SucClienteNoInt").ToString, DtMovimientos(0)("SucClienteColonia"), DtMovimientos(0)("SucClienteCP").ToString, DtMovimientos(0)("SucClienteCiudad"), DtMovimientos(0)("SucClientePais").ToString)
@@ -1487,7 +1487,7 @@ Partial Class PopUpVerFactura
End If
If UsuarioActual.CveEmpresa.Contiene(72, 80) Then
If UsuarioActual.CveEmpresa.Contiene(72, 80, 146) Then
params.Add(New ReportParameter("Fecha", String.Format("{0} {1}", FechaHora.ToDate.ToString("yyyy-MM-dd"), FechaHora.ToDateTime.ToString("HH:mm:ss"))))
params.Add(New ReportParameter("SucursalCliente", DtMovimientos(0)("SucCliente").ToString))

View File

@@ -0,0 +1,137 @@
<%@ Page Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="CatClasificacionPorcentaje.aspx.vb" Inherits="Contabilidad_CatClasificacionPorcentaje" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="HB" runat="Server">
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="E" runat="Server">
Catálogo de Clasificacion Porcentaje
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
<asp:UpdatePanel runat="server" ID="UpAgregar">
<ContentTemplate>
<li>
<asp:LinkButton runat="server" ID="BtnAgregarClas" data-toggle="tooltip" data-placement="left" title="Agregar un Defecto" Text="<i class='fa fa-plus'></i>Agregar Clas. Porcentaje"></asp:LinkButton>
</li>
</ContentTemplate>
</asp:UpdatePanel>
</asp:Content>
<asp:Content ID="Content6" ContentPlaceHolderID="C" runat="Server">
<asp:UpdatePanel ID="UpDatos" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<asp:GridView ID="GvDatos" runat="server" AutoGenerateColumns="False" DataKeyNames="CveClasificacionPorcentaje,Clasificacion,CveEmpresa,CveClasificacion,PorcentajeIVA,
CuentaXAcreditar,CuentaAcreditable,CuentaXTrasladar,CuentaTrasladado,IdCtaIVAXAcreditar,IdCtaIVAAcreditable,IdCtaIVAXTrasladar,IdCtaIVATrasladado,IdCtaIVANoAcreditable"
EmptyDataText="No se encontraron Motivo de Baja Registrados" ToolTip="Listado de Motivo de Baja" CssClass="table table-striped table-advance table-hover" Style="margin-top: -10px;
text-align: center; width: 100%" GridLines="None">
<Columns>
<asp:BoundField DataField="Clasificacion" HeaderText="Clasificacion" />
<asp:BoundField DataField="PorcentajeIVA" HeaderText="PorcentajeIVA" />
<asp:BoundField DataField="CuentaXAcreditar" HeaderText="C. Por Acreditar" />
<asp:BoundField DataField="CuentaAcreditable" HeaderText="C. Acreditable" />
<asp:BoundField DataField="CuentaXTrasladar" HeaderText="C. Por trasladar" />
<asp:BoundField DataField="CuentaTrasladado" HeaderText="C. Trasladado" />
<%--<asp:BoundField DataField="IdCtaIVANoAcreditable" HeaderText="IdCtaIVANoAcreditable" />--%>
<asp:TemplateField HeaderText="Editar">
<EditItemTemplate>
<center>
<asp:LinkButton ID="imgU" runat="server" AlternateText="Actualizar" CausesValidation="True" CommandName="Update" CssClass="btn btn-circle btn-sm green" Text="<i class='fa fa-check'></i>" ValidationGroup="GrpGV" />
&nbsp;<asp:LinkButton ID="imgC" runat="server" AlternateText="Cancelar" CausesValidation="False" CommandName="Cancel" CssClass="btn btn-circle btn-sm red" Text="<i class='fa fa-times'></i>" />
</center>
</EditItemTemplate>
<ItemTemplate>
<asp:LinkButton ID="imgE" runat="server" OnClick="GvDatos_RowEditing" AlternateText="Editar" CausesValidation="False" CssClass="btn btn-circle btn-sm green" Text="<i class='fa fa-pencil'></i>" />
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Eliminar">
<ItemTemplate>
<asp:LinkButton ID="imgD" runat="server" AlternateText="Eliminar" CausesValidation="False" CommandName="Delete" CssClass="btn btn-circle btn-sm red" Text="<i class='icon-trash'></i>" data-toggle="confirmation" data-popout="true" data-original-title="Confirmar" data-btn-ok-label="si" />
</ItemTemplate>
</asp:TemplateField>
</Columns>
<RowStyle CssClass="Texto" />
<AlternatingRowStyle CssClass="TextoAlterno" />
</asp:GridView>
<div id="DivAgregarTiposD" class="modal ADS fade" role="dialog">
<div class="modal-dialog" style="width: 450px;">
<asp:UpdatePanel runat="server" class="modal-content" ID="UpModalTiposD" UpdateMode="Conditional">
<ContentTemplate>
<div class="modal-header ">
<button type="button" class="close" data-dismiss="modal">×</button>
<h4 class="modal-title">
<asp:Literal ID="LtlTituloModalTiposD" runat="server">Clasificación porcentaje</asp:Literal></h4>
</div>
<div class="modal-body">
<div class="form-group form-md-line-input input-iconright">
<asp:dropdownlist runat="server" ID="DdlClasificaciones" CssClass="form-control input-sm select2me js-cuenta-programmatic select2me" AppendDataBoundItems="true" Width="100%" DataTextField="Clasificacion" DataValueField="CveClasificacion"></asp:dropdownlist>
<asp:RequiredFieldValidator ID="RfvDdlClasificaciones" runat="server" ControlToValidate="DdlClasificaciones" InitialValue="-1" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Clasificación''</b> es necesario, por favor ingréselo." ValidationGroup="GrpTiposD"></asp:RequiredFieldValidator>
<label for="MotivoTxt">Clasificación:</label>
<i></i>
</div>
<br />
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtPorcentajeIva" CssClass="form-control " runat="server" MaxLength="70" CausesValidation="true"></asp:TextBox>
<asp:RequiredFieldValidator ID="RfvTxtTiposD" runat="server" ControlToValidate="TxtPorcentajeIva" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Tipo''</b> es necesario, por favor ingréselo." ValidationGroup="GrpTiposD"></asp:RequiredFieldValidator>
<label for="TxtPorcentajeIva">Porcentaje IVA:</label>
<i></i>
</div>
<br />
<div class="form-group form-md-line-input input-iconright">
<asp:dropdownlist runat="server" ID="DdlIdCtaIVAXAcreditar" CssClass="form-control input-sm select2me js-cuenta-programmatic select2me" AppendDataBoundItems="true" Width="100%" DataTextField="Nombre" DataValueField="Id"></asp:dropdownlist>
<asp:RequiredFieldValidator ID="RfvDdlIdCtaIVAXAcreditar" runat="server" ControlToValidate="DdlIdCtaIVAXAcreditar" InitialValue="-1" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Clasificación''</b> es necesario, por favor ingréselo." ValidationGroup="GrpTiposD"></asp:RequiredFieldValidator>
<label for="DdlIdCtaIVAXAcreditar">Cuenta IVA por acreditar:</label>
<i></i>
</div>
<br />
<div class="form-group form-md-line-input input-iconright">
<asp:dropdownlist runat="server" ID="DdlIdCtaIVAAcreditable" CssClass="form-control input-sm select2me js-cuenta-programmatic select2me" AppendDataBoundItems="true" Width="100%" DataTextField="Nombre" DataValueField="Id"></asp:dropdownlist>
<asp:RequiredFieldValidator ID="RfvDdlIdCtaIVAAcreditable" runat="server" ControlToValidate="DdlIdCtaIVAAcreditable" InitialValue="-1" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Clasificación''</b> es necesario, por favor ingréselo." ValidationGroup="GrpTiposD"></asp:RequiredFieldValidator>
<label for="DdlIdCtaIVAAcreditable">Cuenta IVA acreditable:</label>
<i></i>
</div>
<br />
<div class="form-group form-md-line-input input-iconright">
<asp:dropdownlist runat="server" ID="DdlIdCtaIVAXTrasladar" CssClass="form-control input-sm select2me js-cuenta-programmatic select2me" AppendDataBoundItems="true" Width="100%" DataTextField="Nombre" DataValueField="Id"></asp:dropdownlist>
<asp:RequiredFieldValidator ID="RfvDdlIdCtaIVAXTrasladar" runat="server" ControlToValidate="DdlIdCtaIVAXTrasladar" InitialValue="-1" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Clasificación''</b> es necesario, por favor ingréselo." ValidationGroup="GrpTiposD"></asp:RequiredFieldValidator>
<label for="DdlIdCtaIVAXTrasladar">Cuenta IVA por trasladar:</label>
<i></i>
</div>
<br />
<div class="form-group form-md-line-input input-iconright">
<asp:dropdownlist runat="server" ID="DdlIdCtaIVATrasladado" CssClass="form-control input-sm select2me js-cuenta-programmatic select2me" AppendDataBoundItems="true" Width="100%" DataTextField="Nombre" DataValueField="Id"></asp:dropdownlist>
<asp:RequiredFieldValidator ID="RfvDdlIdCtaIVATrasladado" runat="server" ControlToValidate="DdlIdCtaIVATrasladado" InitialValue="-1" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Clasificación''</b> es necesario, por favor ingréselo." ValidationGroup="GrpTiposD"></asp:RequiredFieldValidator>
<label for="DdlIdCtaIVATrasladado">Cuenta IVA Traslado:</label>
<i></i>
</div>
<br />
<div class="form-group form-md-line-input input-iconright">
<asp:dropdownlist runat="server" ID="DdlIdCtaIVANoAcreditable" CssClass="form-control input-sm select2me js-cuenta-programmatic select2me" AppendDataBoundItems="true" Width="100%" DataTextField="Nombre" DataValueField="Id"></asp:dropdownlist>
<asp:RequiredFieldValidator ID="RfvDdlIdCtaIVANoAcreditable" runat="server" ControlToValidate="DdlIdCtaIVANoAcreditable" InitialValue="-1" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Clasificación''</b> es necesario, por favor ingréselo." ValidationGroup="GrpTiposD"></asp:RequiredFieldValidator>
<label for="DdlIdCtaIVANoAcreditable">Cuenta IVA no acreditable:</label>
<i></i>
</div>
<br />
</div>
<br />
<div class="modal-footer">
<asp:Button ID="BtnAgregarTiposDModal" runat="server" class="btn btn-success" Text="Agregar" ValidationGroup="GrpTiposD" />
<asp:Button ID="BtnEditarTiposDModal" runat="server" class="btn btn-success" Text="Confirmar" ValidationGroup="GrpTiposD" />
<button id="Button3" runat="server" type="button" class="btn default" data-dismiss="modal">Cancelar</button>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</asp:Content>
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
</asp:Content>

View File

@@ -0,0 +1,150 @@
Imports System.Data
Imports Extensiones
Imports Microsoft.Reporting.WebForms
Partial Class Contabilidad_CatClasificacionPorcentaje
Inherits ClsPaginas
Private Property DtClasificacionPorcentaje As DataTable
Get
Return CType(ViewState("DtClasificacionPorcentaje"), DataTable)
End Get
Set(value As DataTable)
ViewState("DtClasificacionPorcentaje") = value
End Set
End Property
Private Property CveClasificacion As Integer
Get
Return CType(ViewState("CveClasificacion"), Integer)
End Get
Set(value As Integer)
ViewState("CveClasificacion") = value
End Set
End Property
Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load
If Not Page.IsPostBack Then
CargaDatos()
CargaContPaq()
End If
End Sub
Protected Sub CargaDatos()
Dim ObjGenerales As New ClsGenerales
If ObjGenerales.GetClasificacionPorcentaje(UsuarioActual.CveEmpresa, CveClasificacionPorcentaje:=-1, CveClasificacion:=-1, PorcentajeIVA:=-1, Opcion:=2) Then
GvDatos.DataSource = ObjGenerales.DtResultados
DtClasificacionPorcentaje = ObjGenerales.DtResultados
End If
ObjGenerales.Dispose()
GvDatos.DataBind()
DdlClasificaciones.Items.Add(New ListItem("Seleccione", "-1"))
DdlClasificaciones.DataSource = GlobalDTClasificaciones(UsuarioActual.CveEmpresa)
DdlClasificaciones.DataBind()
End Sub
Protected Sub CargaContPaq()
Dim Empresa As DataTable = GlobalDTEmpresas(UsuarioActual.CveEmpresa)
Dim Servidor As String = Empresa.FiltroPrimeroValor("ServerContPAQi")
Dim BD As String = Empresa.FiltroPrimeroValor("BDContPAQi")
Dim Usuario As String = Empresa.FiltroPrimeroValor("UsrContPAQi")
Dim Contra As String = Empresa.FiltroPrimeroValor("PwdContPAQi")
Dim ObjPaq As New ClsContPAQi(Servidor, BD, Usuario, Contra)
DdlIdCtaIVAXAcreditar.Items.Add(New ListItem("Seleccione una cuenta", "-1"))
DdlIdCtaIVAAcreditable.Items.Add(New ListItem("Seleccione una cuenta", "-1"))
DdlIdCtaIVAXTrasladar.Items.Add(New ListItem("Seleccione una cuenta", "-1"))
DdlIdCtaIVATrasladado.Items.Add(New ListItem("Seleccione una cuenta", "-1"))
DdlIdCtaIVANoAcreditable.Items.Add(New ListItem("Seleccione una cuenta", "-1"))
If ObjPaq.GetCuentas(-1, "-1", -1, IdPadre:=-1) Then
DdlIdCtaIVAXAcreditar.DataSource = ObjPaq.DtResultados
DdlIdCtaIVAAcreditable.DataSource = ObjPaq.DtResultados
DdlIdCtaIVAXTrasladar.DataSource = ObjPaq.DtResultados
DdlIdCtaIVATrasladado.DataSource = ObjPaq.DtResultados
DdlIdCtaIVANoAcreditable.DataSource = ObjPaq.DtResultados
End If
ObjPaq.Dispose()
DdlIdCtaIVAXAcreditar.DataBind()
DdlIdCtaIVAAcreditable.DataBind()
DdlIdCtaIVAXTrasladar.DataBind()
DdlIdCtaIVATrasladado.DataBind()
DdlIdCtaIVANoAcreditable.DataBind()
End Sub
Protected Sub BtnAgregarMotivo_Click(sender As Object, e As EventArgs) Handles BtnAgregarClas.Click
BtnAgregarTiposDModal.Text = "Agregar"
BtnEditarTiposDModal.Visible = False
BtnAgregarTiposDModal.Visible = True
TxtPorcentajeIva.Text = ""
UpModalTiposD.Update()
RegistraScript(String.Format("$('#{0}').modal();", "DivAgregarTiposD"))
End Sub
Protected Sub LbAgregar_Click(sender As Object, e As System.EventArgs) Handles BtnAgregarTiposDModal.Click 'esta funcion es la que agrega un nuevo motivo de baja se activa con el boton "Agregar" de la ventana modal"
Dim ObjGenerales As New ClsGenerales
If BtnAgregarTiposDModal.Text = "Agregar" Then
If ObjGenerales.AddClasificacionPorcentaje(DdlClasificaciones.SelectedValue, TxtPorcentajeIva.Text.ToDouble, DdlIdCtaIVAXAcreditar.SelectedValue, DdlIdCtaIVAAcreditable.SelectedValue,
DdlIdCtaIVAXTrasladar.SelectedValue, DdlIdCtaIVATrasladado.SelectedValue, UsuarioActual.CveEmpresa) Then
RegistraScript(String.Format("$('#{0}').modal('hide');", "DivAgregarTiposD"))
Alert("Clasificación porcentaje agregado correctamente")
If ObjGenerales.GetClasificacionPorcentaje(-1) Then
GlobalDTClasificacionPorcentaje(-1) = ObjGenerales.DtResultados
End If
CargaDatos()
CargaContPaq()
UpDatos.Update()
End If
ElseIf BtnAgregarTiposDModal.Text = "Actualizar" Then
If ObjGenerales.UpdateClasificacionPorcentaje(CveClasificacion, DdlClasificaciones.SelectedValue, TxtPorcentajeIva.Text.ToDouble, DdlIdCtaIVAXAcreditar.SelectedValue,
DdlIdCtaIVAAcreditable.SelectedValue, DdlIdCtaIVAXTrasladar.SelectedValue, DdlIdCtaIVATrasladado.SelectedValue) Then
RegistraScript(String.Format("$('#{0}').modal('hide');", "DivAgregarTiposD"))
Alert("Clasificación porcentaje actualizado correctamente")
If ObjGenerales.GetClasificacionPorcentaje(-1) Then
GlobalDTClasificacionPorcentaje(-1) = ObjGenerales.DtResultados
End If
CargaDatos()
CargaContPaq()
UpDatos.Update()
End If
End If
ObjGenerales.Dispose()
End Sub
Protected Sub GvDatos_RowDeleting(sender As Object, e As System.Web.UI.WebControls.GridViewDeleteEventArgs) Handles GvDatos.RowDeleting
Dim objgenerales As New ClsGenerales
If objgenerales.RemoveClasificacionPorcentaje(GvDatos.DataKeys(e.RowIndex).Value.ToString) Then
Alert("la clasificación porcentaje se eliminó correctamente")
If objgenerales.GetClasificacionPorcentaje(-1) Then
GlobalDTClasificacionPorcentaje(-1) = objgenerales.DtResultados
End If
CargaDatos()
CargaContPaq()
UpDatos.Update()
End If
objgenerales.Dispose()
End Sub
Public Sub GvDatos_RowEditing(sender As Object, e As EventArgs)
BtnAgregarTiposDModal.Text = "Actualizar"
Dim renglon As GridViewRow = DirectCast(DirectCast(sender, LinkButton).NamingContainer, GridViewRow)
DdlClasificaciones.SelectedValue = If(renglon.DataKey("CveClasificacion").ToString IsNot "", renglon.DataKey("CveClasificacion"), "-1")
TxtPorcentajeIva.Text = renglon.DataKey("PorcentajeIVA")
DdlIdCtaIVAXAcreditar.SelectedValue = If(renglon.DataKey("IdCtaIVAXAcreditar").ToString IsNot "", renglon.DataKey("IdCtaIVAXAcreditar"), "-1")
DdlIdCtaIVAAcreditable.SelectedValue = If(renglon.DataKey("IdCtaIVAAcreditable").ToString IsNot "", renglon.DataKey("IdCtaIVAAcreditable"), "-1")
DdlIdCtaIVAXTrasladar.SelectedValue = If(renglon.DataKey("IdCtaIVAXTrasladar").ToString IsNot "", renglon.DataKey("IdCtaIVAXTrasladar"), "-1")
DdlIdCtaIVATrasladado.SelectedValue = If(renglon.DataKey("IdCtaIVATrasladado").ToString IsNot "", renglon.DataKey("IdCtaIVATrasladado"), "-1")
DdlIdCtaIVANoAcreditable.SelectedValue = If(renglon.DataKey("IdCtaIVANoAcreditable").ToString IsNot "", renglon.DataKey("IdCtaIVANoAcreditable"), "-1")
BtnEditarTiposDModal.Visible = False
BtnAgregarTiposDModal.Visible = True
UpModalTiposD.Update()
RegistraScript(String.Format("$('#{0}').modal();", "DivAgregarTiposD"))
End Sub
End Class

View File

@@ -373,6 +373,9 @@
<asp:TemplateField ItemStyle-HorizontalAlign="Center">
<ItemTemplate>
<asp:LinkButton ID="ImgBancos" runat="server" CausesValidation="False" CssClass="btn btn-circle btn-sm btn-warning" OnClick="Bancos_Click" Text="<i class='fa fa-money'></i>" Visible="false" />
<asp:DropDownList ID="DdlProveedores" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="true" DataTextField="RazonSocial" DataValueField="CveProveedor" Width="160px" Visible="false" AutoPostBack="true" OnSelectedIndexChanged="DdlProveedores_SelectedIndexChanged1"></asp:DropDownList><br />
<asp:DropDownList ID="DdlCompras" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="true" DataTextField="SerieFolio" DataValueField="CveCompra" Width="160px" Visible="false"></asp:DropDownList><br />
</ItemTemplate>
</asp:TemplateField>

View File

@@ -794,6 +794,18 @@ Partial Class ContabilidadC_RegPrePoliza
e.Row.FCLinkButton("ImgBancos").CssClass = "btn btn-circle btn-sm green"
End If
End If
If e.Row.DataKey("CveConcepto").ToEntero.Contiene(17) Then
e.Row.FCDropDownList("DdlProveedores").Visible = True
e.Row.FCDropDownList("DdlProveedores").DataSource = GlobalDTCompProveedores(UsuarioActual.CveEmpresa)
e.Row.FCDropDownList("DdlProveedores").DataBind()
e.Row.FCDropDownList("DdlProveedores").Items.Insert(0, New ListItem(" - ", "-1"))
'If CveTipoTransaccion > 0 And CveCuenta > 0 And Folio.Length > 0 And ImporteDocumento > 0 And Beneficiario.Length > 0 Then
' e.Row.FCLinkButton("ImgPagoCompra").CssClass = "btn btn-circle btn-sm green"
'End If
End If
End If
End Sub
@@ -857,12 +869,17 @@ Partial Class ContabilidadC_RegPrePoliza
End If
Dim CveProveedor As Integer = -1
Dim CveCompra As Integer = -1
'inserto las compras que voy a pagarDdlSaldos
For Each gvr As GridViewRow In GvMov.Rows
If gvr.DataKey("IDCuenta").ToEntero > 0 Then
IdCtaContable = gvr.DataKey("IDCuenta")
End If
CveProveedor = gvr.DataKey("CveProveedor").ToEntero
CveCompra = gvr.DataKey("CveCompra").ToEntero
CveConcepto = gvr.DataKey("CveConcepto").ToEntero
If gvr.DataKey("TipoMovto").ToDouble <> 0 Then
Importe = gvr.FCTextBox("TxtAbono").Text.ToDouble
@@ -871,6 +888,11 @@ Partial Class ContabilidadC_RegPrePoliza
Importe = gvr.FCTextBox("TxtCargo").Text.ToDouble
TipoMovto = False
End If
'Registra pago de compra
If CveConcepto = 17 Then
CveProveedor = gvr.FCDropDownList("DdlProveedores").SelectedValue.ToEntero
CveCompra = gvr.FCDropDownList("DdlCompras").SelectedValue.ToEntero
End If
If CveConcepto = 41 Then
CveIE = gvr.FCDropDownList("DdlSaldos").SelectedValue.ToEntero
@@ -890,7 +912,7 @@ Partial Class ContabilidadC_RegPrePoliza
If Importe <> 0 Then
If ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovto, Importe, gvr.FCLiteral("LtlReferencia").Text, gvr.DataKey("CveConcepto").ToEntero, gvr.FCTextBox("TxtConcepto").Text,
TxtFecha.Text.ToDate, IdCtaContable, -1, CveSubProyecto:=gvr.FCDropDownList("DdlSubProyecto").SelectedValue.ToEntero, CveIE:=CveIE,
CveProveedor:=gvr.DataKey("CveProveedor").ToEntero, CveCompra:=gvr.DataKey("CveCompra").ToEntero,
CveProveedor:=CveProveedor, CveCompra:=CveCompra,
CvePersonal:=gvr.DataKey("CvePersonal").ToEntero, CveClasificacion:=gvr.DataKey("CveClasificacion").ToEntero,
ImporteMX:=Importe, CveTipoGasto:=gvr.FCDropDownList("DdlTipoGasto").SelectedValue.ToEntero,
CveCliente:=gvr.DataKey("CveCliente").ToEntero, CveVenta:=gvr.DataKey("CveVenta").ToEntero, TipoCambio:=If(gvr.DataKey("TC").ToString.ToDouble > 0, gvr.DataKey("TC").ToString.ToDouble, 1),
@@ -1565,5 +1587,29 @@ Partial Class ContabilidadC_RegPrePoliza
Protected Sub DdlProveedores_SelectedIndexChanged1(sender As Object, e As EventArgs)
Dim ddl As DropDownList = CType(sender, DropDownList)
Dim ddl2 As DropDownList = DirectCast(ddl.BindingContainer, GridViewRow).FCDropDownList("DdlCompras")
CargaCompras2(ddl.SelectedValue.ToEntero, ddl2)
End Sub
Private Sub CargaCompras2(CveProveedor As Integer, ddl As DropDownList)
Dim ObjCompras As New ClsCompras
ddl.ClearSelection()
If ObjCompras.GetCompras(-1, "-1", "-1", CveProveedor, -1, UsuarioActual.CveEmpresa) Then
ddl.DataSource = ObjCompras.DtResultados.FiltraParametros("Saldo > 0")
ddl.DataBind()
ddl.Items.Insert(0, New ListItem(" - ", "-1"))
ddl.Visible = True
Else
ddl.DataSource = Nothing
ddl.DataBind()
ddl.Items.Insert(0, New ListItem(" - ", "-1"))
End If
ObjCompras.Dispose()
End Sub
End Class

View File

@@ -23,9 +23,9 @@
</Paragraphs>
<rd:DefaultName>Textbox3</rd:DefaultName>
<Top>1.37762in</Top>
<Left>5.662in</Left>
<Left>5.81465in</Left>
<Height>0.5cm</Height>
<Width>2.24597in</Width>
<Width>2.09332in</Width>
<Style>
<Border>
<Style>Solid</Style>
@@ -73,9 +73,9 @@
</Paragraphs>
<rd:DefaultName>Textbox3</rd:DefaultName>
<Top>0.93484in</Top>
<Left>5.662in</Left>
<Left>5.81465in</Left>
<Height>0.5cm</Height>
<Width>2.24597in</Width>
<Width>2.09332in</Width>
<ZIndex>1</ZIndex>
<Style>
<Border>
@@ -108,9 +108,9 @@
</Paragraphs>
<rd:DefaultName>Textbox3</rd:DefaultName>
<Top>0.69525in</Top>
<Left>5.662in</Left>
<Left>5.81465in</Left>
<Height>0.60856cm</Height>
<Width>2.24597in</Width>
<Width>2.09332in</Width>
<ZIndex>2</ZIndex>
<Style>
<Border>
@@ -143,9 +143,9 @@
</Paragraphs>
<rd:DefaultName>Textbox3</rd:DefaultName>
<Top>1.23676cm</Top>
<Left>5.662in</Left>
<Left>5.81465in</Left>
<Height>0.5cm</Height>
<Width>2.24597in</Width>
<Width>2.09332in</Width>
<ZIndex>3</ZIndex>
<Style>
<Border>
@@ -259,9 +259,9 @@
</Paragraphs>
<rd:DefaultName>Textbox3</rd:DefaultName>
<Top>1.13169in</Top>
<Left>5.662in</Left>
<Left>5.81465in</Left>
<Height>0.25114in</Height>
<Width>2.24597in</Width>
<Width>2.09332in</Width>
<ZIndex>6</ZIndex>
<Style>
<Border>
@@ -295,9 +295,9 @@
</Paragraphs>
<rd:DefaultName>Textbox3</rd:DefaultName>
<Top>1.57434in</Top>
<Left>5.662in</Left>
<Left>5.81465in</Left>
<Height>0.25635in</Height>
<Width>2.24597in</Width>
<Width>2.09332in</Width>
<ZIndex>7</ZIndex>
<Style>
<Border>
@@ -347,10 +347,10 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox10</rd:DefaultName>
<Top>0.98172in</Top>
<Left>1.48781in</Left>
<Height>0.65513in</Height>
<Width>2.06754in</Width>
<Top>0.99561in</Top>
<Left>0.05904in</Left>
<Height>0.62735in</Height>
<Width>1.9981in</Width>
<ZIndex>8</ZIndex>
<Style>
<Border>
@@ -397,10 +397,10 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox10</rd:DefaultName>
<Top>0.98172in</Top>
<Left>3.64748in</Left>
<Height>0.65513in</Height>
<Width>1.93674in</Width>
<Top>1.00949in</Top>
<Left>2.05714in</Left>
<Height>0.62735in</Height>
<Width>1.76588in</Width>
<ZIndex>9</ZIndex>
<Style>
<Border>
@@ -956,74 +956,6 @@
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox62">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Régimen: Sociedad Anónima de Capital Variable; Condiciones de pago: </Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value>=IIF(Parameters!CondicionPago.Value.ToString="","No Identificado",Parameters!CondicionPago.Value)</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value>; Método de Pago: </Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value>=IIF(Parameters!MetodoPago.Value.ToString="","No Identificado",Parameters!MetodoPago.Value)</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value>; Num. Cta Pago:</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value>=IIF(Parameters!NumCta.Value="0" Orelse Parameters!NumCta.Value="","No Identificado",Parameters!NumCta.Value)</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style />
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox62</rd:DefaultName>
<Top>6.65199in</Top>
<Left>1.5367in</Left>
<Height>0.29498in</Height>
<Width>6.38809in</Width>
<ZIndex>24</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox63">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
@@ -1045,7 +977,7 @@
<Left>2.54119in</Left>
<Height>0.25in</Height>
<Width>3.69856in</Width>
<ZIndex>25</ZIndex>
<ZIndex>24</ZIndex>
<Style>
<Border>
<Style>None</Style>
@@ -1104,7 +1036,7 @@
</Style>
</TextRun>
<TextRun>
<Value> Por éste pagare prometo (emos) pagar incondicionalmente a la orden de Localización Precisa GPS de México SA de CV, a su vencimiento el </Value>
<Value> Por éste pagare prometo (emos) pagar incondicionalmente a la orden de VICTOR MANUEL RAMIREZ CASTILLO, a su vencimiento el </Value>
<Style>
<FontStyle>Normal</FontStyle>
<FontFamily>calibri</FontFamily>
@@ -1128,7 +1060,7 @@
</Style>
</TextRun>
<TextRun>
<Value>, en Hermosillo, Sonora o en el domicilio señalado a elección del acreedor o tenedor la cantidad de $ </Value>
<Value>, en Tijuana, Baja California o en el domicilio señalado a elección del acreedor o tenedor la cantidad de $ </Value>
<Style>
<FontStyle>Normal</FontStyle>
<FontFamily>calibri</FontFamily>
@@ -1176,7 +1108,7 @@
</Style>
</TextRun>
<TextRun>
<Value> ). Valor recibido a mi (nuestra) entera satisfacción. La falta de pago de éste documento a su vencimiento dará derecho a Localización Precisa GPS de México SA de CV o tenedor, desde el día siguiente a cobrar el 10% mensual de interes moratorios hasta su total liquidación y los gastos judiciales que se ocasionen. Lugar y Fecha de Suscripción: Hermosillo, Sonora a </Value>
<Value> ). Valor recibido a mi (nuestra) entera satisfacción. La falta de pago de éste documento a su vencimiento dará derecho a VICTOR MANUEL RAMIREZ CASTILLO o tenedor, desde el día siguiente a cobrar el 5% mensual de interes moratorios hasta su total liquidación y los gastos judiciales que se ocasionen. Lugar y Fecha de Suscripción: Tijuana, Baja California a </Value>
<Style>
<FontStyle>Normal</FontStyle>
<FontFamily>calibri</FontFamily>
@@ -1803,7 +1735,7 @@
<Left>0.04398cm</Left>
<Height>4.04843cm</Height>
<Width>20.06179cm</Width>
<ZIndex>26</ZIndex>
<ZIndex>25</ZIndex>
<Visibility>
<Hidden>= (Parameters!AplicaPagare.Value="0" ORelse Parameters!AplicaPagare.Value="")</Hidden>
</Visibility>
@@ -1817,19 +1749,22 @@
<TablixBody>
<TablixColumns>
<TablixColumn>
<Width>2.12527cm</Width>
<Width>1.34132cm</Width>
</TablixColumn>
<TablixColumn>
<Width>2.02474cm</Width>
<Width>1.32237cm</Width>
</TablixColumn>
<TablixColumn>
<Width>10.17786cm</Width>
<Width>2.53649cm</Width>
</TablixColumn>
<TablixColumn>
<Width>8.96945cm</Width>
</TablixColumn>
<TablixColumn>
<Width>2.52862cm</Width>
</TablixColumn>
<TablixColumn>
<Width>3.15415cm</Width>
<Width>3.27979cm</Width>
</TablixColumn>
</TablixColumns>
<TablixRows>
@@ -1844,7 +1779,7 @@
<Paragraph>
<TextRuns>
<TextRun>
<Value>Cantidad</Value>
<Value>Cant.</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>9pt</FontSize>
@@ -1906,6 +1841,42 @@
</Textbox>
</CellContents>
</TablixCell>
<TablixCell>
<CellContents>
<Textbox Name="Textbox1">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Código</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>9pt</FontSize>
<Color>White</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Center</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox1</rd:DefaultName>
<Style>
<Border>
<Style>Solid</Style>
</Border>
<BackgroundColor>#ff1037</BackgroundColor>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
</CellContents>
</TablixCell>
<TablixCell>
<CellContents>
<Textbox Name="Textbox79">
@@ -2041,7 +2012,7 @@
<Value>=Fields!Cantidad.Value</Value>
<Style>
<FontSize>7pt</FontSize>
<Format>#,0.00;(#,0.00)</Format>
<Format>#,0;(#,0)</Format>
</Style>
</TextRun>
</TextRuns>
@@ -2109,6 +2080,48 @@
</Textbox>
</CellContents>
</TablixCell>
<TablixCell>
<CellContents>
<Textbox Name="Codigo">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>=Fields!Codigo.Value</Value>
<Style>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Center</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Codigo</rd:DefaultName>
<Style>
<Border>
<Style>Solid</Style>
</Border>
<TopBorder>
<Style>None</Style>
</TopBorder>
<BottomBorder>
<Style>None</Style>
</BottomBorder>
<LeftBorder>
<Style>None</Style>
</LeftBorder>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
</CellContents>
</TablixCell>
<TablixCell>
<CellContents>
<Textbox Name="PS1">
@@ -2293,6 +2306,38 @@
</Textbox>
</CellContents>
</TablixCell>
<TablixCell>
<CellContents>
<Textbox Name="Textbox5">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value />
<Style />
</TextRun>
</TextRuns>
<Style />
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox5</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
</Border>
<TopBorder>
<Style>Solid</Style>
</TopBorder>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
</CellContents>
</TablixCell>
<TablixCell>
<CellContents>
<Textbox Name="Textbox83">
@@ -2404,6 +2449,7 @@
<TablixMember />
<TablixMember />
<TablixMember />
<TablixMember />
</TablixMembers>
</TablixColumnHierarchy>
<TablixRowHierarchy>
@@ -2423,8 +2469,8 @@
<Top>5.75246cm</Top>
<Left>0.11468cm</Left>
<Height>1.07241cm</Height>
<Width>20.01064cm</Width>
<ZIndex>27</ZIndex>
<Width>19.97804cm</Width>
<ZIndex>26</ZIndex>
<Style>
<Border>
<Style>None</Style>
@@ -2463,7 +2509,7 @@
<Left>5.662in</Left>
<Height>0.21567in</Height>
<Width>2.26391in</Width>
<ZIndex>28</ZIndex>
<ZIndex>27</ZIndex>
<Style>
<Border>
<Style>Solid</Style>
@@ -2748,7 +2794,7 @@
<Left>5.73412in</Left>
<Height>0.34081in</Height>
<Width>2.19818in</Width>
<ZIndex>29</ZIndex>
<ZIndex>28</ZIndex>
<Style>
<Border>
<Style>None</Style>
@@ -2862,7 +2908,7 @@
<Left>14.56464cm</Left>
<Height>0.6cm</Height>
<Width>5.58343cm</Width>
<ZIndex>30</ZIndex>
<ZIndex>29</ZIndex>
<Style>
<Border>
<Style>None</Style>
@@ -2876,7 +2922,13 @@
<Width>3.33888cm</Width>
</TablixColumn>
<TablixColumn>
<Width>11.00525cm</Width>
<Width>3.672cm</Width>
</TablixColumn>
<TablixColumn>
<Width>3.83158cm</Width>
</TablixColumn>
<TablixColumn>
<Width>3.48541cm</Width>
</TablixColumn>
</TablixColumns>
<TablixRows>
@@ -2928,10 +2980,58 @@
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<ColSpan>2</ColSpan>
<ColSpan>3</ColSpan>
</CellContents>
</TablixCell>
<TablixCell />
<TablixCell />
<TablixCell>
<CellContents>
<Textbox Name="Textbox74">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value />
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>9pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox74</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
</Border>
<TopBorder>
<Style>Solid</Style>
</TopBorder>
<BottomBorder>
<Style>Solid</Style>
</BottomBorder>
<LeftBorder>
<Style>Solid</Style>
</LeftBorder>
<RightBorder>
<Style>Solid</Style>
<Width>1pt</Width>
</RightBorder>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
</CellContents>
</TablixCell>
</TablixCells>
</TablixRow>
<TablixRow>
@@ -2986,7 +3086,7 @@
</TablixCell>
<TablixCell>
<CellContents>
<Textbox Name="Textbox127">
<Textbox Name="Textbox67">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -3005,19 +3105,34 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox127</rd:DefaultName>
<rd:DefaultName>Textbox67</rd:DefaultName>
<Style>
<Border>
<Color>White</Color>
<Style>None</Style>
</Border>
<BottomBorder>
<Style>Solid</Style>
</BottomBorder>
<LeftBorder>
<Style>Solid</Style>
</LeftBorder>
<RightBorder>
<Style>Solid</Style>
</RightBorder>
<BackgroundColor>White</BackgroundColor>
<VerticalAlign>Middle</VerticalAlign>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<ColSpan>3</ColSpan>
</CellContents>
</TablixCell>
<TablixCell />
<TablixCell />
</TablixCells>
</TablixRow>
<TablixRow>
@@ -3049,7 +3164,7 @@
<Style>
<Border>
<Color>White</Color>
<Style>None</Style>
<Style>Solid</Style>
</Border>
<TopBorder>
<Style>Solid</Style>
@@ -3079,7 +3194,7 @@
</TablixCell>
<TablixCell>
<CellContents>
<Textbox Name="Textbox131">
<Textbox Name="Textbox70">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -3098,19 +3213,25 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox131</rd:DefaultName>
<rd:DefaultName>Textbox70</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
<Color>White</Color>
<Style>Solid</Style>
</Border>
<BackgroundColor>White</BackgroundColor>
<VerticalAlign>Middle</VerticalAlign>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<ColSpan>3</ColSpan>
</CellContents>
</TablixCell>
<TablixCell />
<TablixCell />
</TablixCells>
</TablixRow>
<TablixRow>
@@ -3118,14 +3239,14 @@
<TablixCells>
<TablixCell>
<CellContents>
<Textbox Name="Textbox15">
<Textbox Name="Textbox39">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Uso CFDI:</Value>
<Value>Orden de compra:</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>9pt</FontSize>
@@ -3138,11 +3259,11 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox15</rd:DefaultName>
<rd:DefaultName>Textbox39</rd:DefaultName>
<Style>
<Border>
<Color>White</Color>
<Style>None</Style>
<Style>Solid</Style>
</Border>
<TopBorder>
<Style>Solid</Style>
@@ -3172,14 +3293,14 @@
</TablixCell>
<TablixCell>
<CellContents>
<Textbox Name="Textbox17">
<Textbox Name="Textbox71">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>=Parameters!UsoCFDI.Value</Value>
<Value>=IIF(Parameters!OrdenCompra.Value = "-1","",Parameters!OrdenCompra.Value)</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>8pt</FontSize>
@@ -3191,7 +3312,79 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox17</rd:DefaultName>
<rd:DefaultName>Textbox71</rd:DefaultName>
<Style>
<Border>
<Color>White</Color>
<Style>Solid</Style>
</Border>
<VerticalAlign>Middle</VerticalAlign>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
</CellContents>
</TablixCell>
<TablixCell>
<CellContents>
<Textbox Name="Textbox40">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>fecha de vencimiento:</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>9pt</FontSize>
<Color>White</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Center</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox40</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
</Border>
<BackgroundColor>#ff1037</BackgroundColor>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
</CellContents>
</TablixCell>
<TablixCell>
<CellContents>
<Textbox Name="Textbox78">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>=Parameters!Vencimiento.Value</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox78</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
@@ -3236,7 +3429,7 @@
<Style>
<Border>
<Color>White</Color>
<Style>None</Style>
<Style>Solid</Style>
</Border>
<TopBorder>
<Style>Solid</Style>
@@ -3266,7 +3459,7 @@
</TablixCell>
<TablixCell>
<CellContents>
<Textbox Name="Textbox133">
<Textbox Name="Textbox72">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -3285,20 +3478,25 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox133</rd:DefaultName>
<rd:DefaultName>Textbox72</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
<Color>White</Color>
<Style>Solid</Style>
</Border>
<VerticalAlign>Top</VerticalAlign>
<BackgroundColor>White</BackgroundColor>
<VerticalAlign>Middle</VerticalAlign>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<ColSpan>3</ColSpan>
</CellContents>
</TablixCell>
<TablixCell />
<TablixCell />
</TablixCells>
</TablixRow>
<TablixRow>
@@ -3330,7 +3528,7 @@
<Style>
<Border>
<Color>White</Color>
<Style>None</Style>
<Style>Solid</Style>
</Border>
<TopBorder>
<Style>Solid</Style>
@@ -3360,7 +3558,7 @@
</TablixCell>
<TablixCell>
<CellContents>
<Textbox Name="Textbox135">
<Textbox Name="Textbox73">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -3379,20 +3577,25 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox135</rd:DefaultName>
<rd:DefaultName>Textbox73</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
<Color>White</Color>
<Style>Solid</Style>
</Border>
<VerticalAlign>Top</VerticalAlign>
<BackgroundColor>White</BackgroundColor>
<VerticalAlign>Middle</VerticalAlign>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<ColSpan>3</ColSpan>
</CellContents>
</TablixCell>
<TablixCell />
<TablixCell />
</TablixCells>
</TablixRow>
<TablixRow>
@@ -3447,10 +3650,12 @@
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<ColSpan>2</ColSpan>
<ColSpan>4</ColSpan>
</CellContents>
</TablixCell>
<TablixCell />
<TablixCell />
<TablixCell />
</TablixCells>
</TablixRow>
</TablixRows>
@@ -3459,6 +3664,8 @@
<TablixMembers>
<TablixMember />
<TablixMember />
<TablixMember />
<TablixMember />
</TablixMembers>
</TablixColumnHierarchy>
<TablixRowHierarchy>
@@ -3476,8 +3683,8 @@
<Top>6.91306cm</Top>
<Left>0.11468cm</Left>
<Height>5.76188cm</Height>
<Width>14.34413cm</Width>
<ZIndex>31</ZIndex>
<Width>14.32787cm</Width>
<ZIndex>30</ZIndex>
<Style>
<Border>
<Style>None</Style>
@@ -3520,7 +3727,7 @@
<Left>0.04404in</Left>
<Height>0.36457in</Height>
<Width>7.87931in</Width>
<ZIndex>32</ZIndex>
<ZIndex>31</ZIndex>
<Style>
<Border>
<Style>None</Style>
@@ -4022,7 +4229,7 @@
<Left>0.05568cm</Left>
<Height>2.97096cm</Height>
<Width>20.1554cm</Width>
<ZIndex>33</ZIndex>
<ZIndex>32</ZIndex>
<Visibility>
<Hidden>=Microsoft.VisualBasic.Interaction.IIF(First(Fields!SerieFolio.Value, "DataSet4") &lt;&gt; "", False, True)</Hidden>
</Visibility>
@@ -4036,11 +4243,10 @@
<Source>Embedded</Source>
<Value>VISTAPREVIA22</Value>
<Sizing>FitProportional</Sizing>
<Top>0cm</Top>
<Left>19.87567cm</Left>
<Height>18.27471cm</Height>
<Width>0.33541cm</Width>
<ZIndex>34</ZIndex>
<ZIndex>33</ZIndex>
<Visibility>
<Hidden>=IIf(Parameters!CveVenta.Value &gt; 0, True,False)</Hidden>
</Visibility>
@@ -4056,9 +4262,9 @@
<Sizing>FitProportional</Sizing>
<Top>1.19556cm</Top>
<Left>0.14361cm</Left>
<Height>1.67893cm</Height>
<Height>1.22745cm</Height>
<Width>4.7959cm</Width>
<ZIndex>35</ZIndex>
<ZIndex>34</ZIndex>
<Style>
<Border>
<Style>None</Style>
@@ -4104,7 +4310,7 @@
<Left>0.04515in</Left>
<Height>0.37389in</Height>
<Width>4.70134in</Width>
<ZIndex>36</ZIndex>
<ZIndex>35</ZIndex>
<Style>
<Border>
<Style>None</Style>
@@ -4115,11 +4321,108 @@
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox14">
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Uso CFDI: </Value>
<Style>
<FontFamily>Calibri</FontFamily>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
</Style>
</TextRun>
<TextRun>
<Value>=Parameters!UsoCFDI.Value</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Center</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Régime: </Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
</Style>
</TextRun>
<TextRun>
<Value>Personas Físicas con Actividades Empresariales y Profesionales</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Center</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Método de Pago:</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
</Style>
</TextRun>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value>=IIF(Parameters!MetodoPago.Value.ToString="","No Identificado",Parameters!MetodoPago.Value)</Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style>
<FontFamily>calibri</FontFamily>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Center</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox10</rd:DefaultName>
<Top>0.99561in</Top>
<Left>3.82301in</Left>
<Height>0.62735in</Height>
<Width>1.99164in</Width>
<ZIndex>36</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
<VerticalAlign>Top</VerticalAlign>
</Style>
</Textbox>
</ReportItems>
<Height>25.59192cm</Height>
<Style />
</Body>
<Width>20.22041cm</Width>
<Width>20.21108cm</Width>
<Page>
<PageHeight>27.94cm</PageHeight>
<PageWidth>21.59cm</PageWidth>

View File

@@ -1742,6 +1742,12 @@
<AllowBlank>true</AllowBlank>
<Prompt>ReportParameter1</Prompt>
</ReportParameter>
<ReportParameter Name="TipoDocumento">
<DataType>String</DataType>
<Nullable>true</Nullable>
<AllowBlank>true</AllowBlank>
<Prompt>ReportParameter1</Prompt>
</ReportParameter>
</ReportParameters>
<EmbeddedImages>
<EmbeddedImage Name="compuproveedores">

View File

@@ -1664,7 +1664,7 @@
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>10.21319cm</Top>
<Height>0.52945cm</Height>
<Height>0.42362cm</Height>
<Width>477.16077pt</Width>
<ZIndex>9</ZIndex>
<Style>
@@ -1711,8 +1711,8 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>11.09954cm</Top>
<Height>0.52945cm</Height>
<Top>10.63681cm</Top>
<Height>0.42362cm</Height>
<Width>477.16077pt</Width>
<ZIndex>10</ZIndex>
<Style>
@@ -1768,7 +1768,7 @@
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>10.21319cm</Top>
<Left>16.83317cm</Left>
<Height>0.52945cm</Height>
<Height>0.42362cm</Height>
<Width>84.80665pt</Width>
<ZIndex>11</ZIndex>
<Style>
@@ -1815,9 +1815,9 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>11.09954cm</Top>
<Top>10.63681cm</Top>
<Left>16.83317cm</Left>
<Height>0.52945cm</Height>
<Height>0.42362cm</Height>
<Width>84.80665pt</Width>
<ZIndex>12</ZIndex>
<Style>
@@ -1913,7 +1913,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>12.12288cm</Top>
<Top>12.33483cm</Top>
<Left>16.83317cm</Left>
<Height>0.52945cm</Height>
<Width>84.80665pt</Width>
@@ -1958,7 +1958,7 @@
</Style>
</TextRun>
<TextRun>
<Value>LCP Sara Eduwiges Ruíz Félix</Value>
<Value>CP Sara Eduwiges Ruíz Félix</Value>
<MarkupType>HTML</MarkupType>
<Style />
</TextRun>
@@ -1969,7 +1969,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>AgrupadoPor</rd:DefaultName>
<Top>16.10059cm</Top>
<Top>16.31254cm</Top>
<Height>0.6cm</Height>
<Width>561.96737pt</Width>
<ZIndex>15</ZIndex>
@@ -2038,7 +2038,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>AgrupadoPor</rd:DefaultName>
<Top>15.43045cm</Top>
<Top>15.6424cm</Top>
<Height>0.6cm</Height>
<Width>561.96737pt</Width>
<ZIndex>16</ZIndex>
@@ -2094,7 +2094,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>AgrupadoPor</rd:DefaultName>
<Top>12.91208cm</Top>
<Top>13.12403cm</Top>
<Height>0.6cm</Height>
<Width>561.96737pt</Width>
<ZIndex>17</ZIndex>
@@ -2163,7 +2163,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>AgrupadoPor</rd:DefaultName>
<Top>13.68847cm</Top>
<Top>13.90042cm</Top>
<Height>1.25264cm</Height>
<Width>561.96737pt</Width>
<ZIndex>18</ZIndex>
@@ -2177,11 +2177,114 @@
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox38">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>SALDO FINAL SEGUN CONTABILIDAD COMPLEMENTARIA: </Value>
<Style>
<FontSize>10.5pt</FontSize>
<FontWeight>Bold</FontWeight>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value />
<Style>
<FontSize>10.5pt</FontSize>
<FontWeight>Bold</FontWeight>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Center</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>11.06042cm</Top>
<Height>0.42362cm</Height>
<Width>477.16077pt</Width>
<ZIndex>19</ZIndex>
<Visibility>
<Hidden>=IIF(Parameters!SaldoFinalContabilidadComplementaria.Value = 0,true,false)</Hidden>
</Visibility>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox39">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>=Parameters!SaldoFinalContabilidadComplementaria.Value</Value>
<Style>
<FontSize>10.5pt</FontSize>
<FontWeight>Bold</FontWeight>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value />
<Style>
<FontSize>10.5pt</FontSize>
<FontWeight>Bold</FontWeight>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Center</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>11.06042cm</Top>
<Left>16.83317cm</Left>
<Height>0.42362cm</Height>
<Width>84.80665pt</Width>
<ZIndex>20</ZIndex>
<Visibility>
<Hidden>=IIF(Parameters!SaldoFinalContabilidadComplementaria.Value = 0,true,false)</Hidden>
</Visibility>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
</ReportItems>
<Height>6.69322in</Height>
<Height>6.6828in</Height>
<Style />
</Body>
<Width>7.8051in</Width>
<Width>7.81552in</Width>
<Page>
<PageHeader>
<Height>2.88508cm</Height>
@@ -2715,6 +2818,12 @@
<AllowBlank>true</AllowBlank>
<Prompt>ReportParameter1</Prompt>
</ReportParameter>
<ReportParameter Name="SaldoFinalContabilidadComplementaria">
<DataType>String</DataType>
<Nullable>true</Nullable>
<AllowBlank>true</AllowBlank>
<Prompt>ReportParameter1</Prompt>
</ReportParameter>
</ReportParameters>
<rd:ReportUnitType>Cm</rd:ReportUnitType>
<rd:ReportID>40c94aad-a12a-44fb-ab0d-ea36a9656792</rd:ReportID>

View File

@@ -296,17 +296,17 @@ Partial Class General_SaldosIniciales
Exit Sub
End If
If RblFormato.SelectedValue = "4" Then
If Not dt.Columns(15).ColumnName = "ImpuestoLocal" Then
Alert("El nombre de la diesciseisava columna debe ser 'ImpuestoLocal'. Favor de corregirlo", TipoMensaje.MsgError)
Exit Sub
End If
'If RblFormato.SelectedValue = "4" Then
' If Not dt.Columns(15).ColumnName = "ImpuestoLocal" Then
' Alert("El nombre de la diesciseisava columna debe ser 'ImpuestoLocal'. Favor de corregirlo", TipoMensaje.MsgError)
' Exit Sub
' End If
If Not dt.Columns(16).ColumnName = "Amort.Ant" Then
Alert("El nombre de la diescisieteava columna debe ser 'Amort.Ant'. Favor de corregirlo", TipoMensaje.MsgError)
Exit Sub
End If
End If
' If Not dt.Columns(16).ColumnName = "Amort.Ant" Then
' Alert("El nombre de la diescisieteava columna debe ser 'Amort.Ant'. Favor de corregirlo", TipoMensaje.MsgError)
' Exit Sub
' End If
'End If
ElseIf RblFormato.SelectedValue = "5" Then
@@ -683,6 +683,7 @@ Partial Class General_SaldosIniciales
DTPS = ObjPS.DtResultados
End If
Dim NuevaClasificacion As Boolean = False
For Each Row As DataRow In dt.Rows
Dim Codigo As String = Row("Codigo").ToString
@@ -718,8 +719,9 @@ Partial Class General_SaldosIniciales
If ObjClas.AddClasificaciones(Clasificacion, "", -1, "-1", -1, "-1", -1, "-1",
GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltroPrimeroValor("CveCategoria", "").ToString.ToEntero, UsuarioActual.CveUsuario,
UsuarioActual.CveEmpresa) Then
If ObjClas.GetClasificaciones() Then Application("GlobalDTClasificaciones") = ObjClas.DtResultados
GlobalDTClasificaciones(UsuarioActual.CveEmpresa) = Nothing
CveClasificacion = GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltroPrimeroValor("CveClasificacion", $"Clasificacion = '{Clasificacion}'").ToString.ToEntero
NuevaClasificacion = True
End If
End If
@@ -831,7 +833,7 @@ Partial Class General_SaldosIniciales
'If Not CveClasificacion2 > 0 AndAlso Clasificacion2 <> "" Then Alert("No se encontró la Serie: " + Clasificacion2, TipoMensaje.MsgAdvertencia) : ErrorPS = True : Exit For
If CvePS > 0 Then
If Not ObjPS.UpdatePS(CveClasificacion, 1, CveUnidadMedida, Codigo, "", CodigoBarras, Descripcion, Precio, 1, 1, False, 0, True, True, True, UsuarioActual.CveUsuario, CvePS, -1, -1, CveSATPS,
If Not ObjPS.UpdatePS(CveClasificacion, 1, CveUnidadMedida, Codigo, "", CodigoBarras, Descripcion, Precio, -1, 1, False, 0, True, True, True, UsuarioActual.CveUsuario, CvePS, -1, -1, CveSATPS,
CveTipoPS:=CveTipoPS, CveMarca:=CveMarca, CveMedida:=CveMedida, CveRinTamaño:=CveRinTamaño,
CveModelo:=CveModelo, Litraje:=Litraje, IEPSPorcentaje:=IEPS, CveClasificacion2:=CveClasificacion2, CveTamaño:=CveTamaño) Then
'If Not ObjPS.UpdatePS(CveClasificacion, 1, CveUnidadMedida, Codigo, "", CodigoBarras, Descripcion, 0, 1, 1, False, 0, True, True, True, UsuarioActual.CveUsuario, CvePS, -1, -1, CveSATPS,
@@ -878,6 +880,9 @@ Partial Class General_SaldosIniciales
UpDatos.Update()
Else
ObjPS.RollBack()
If NuevaClasificacion Then
GlobalDTClasificaciones(UsuarioActual.CveEmpresa) = Nothing
End If
End If
ObjPS.Dispose()
ObjGral.Dispose()
@@ -1356,8 +1361,8 @@ Partial Class General_SaldosIniciales
Dim Folio As Integer = Row("Folio").ToString.ToEntero
Dim Fecha As Date = Row("Fecha").ToString.ToDate
Dim FechaVencimiento As Date = Row("Fecha Vencimiento").ToString.ToDate
Dim ImpuestoLocal As Double = Row("ImpuestoLocal").ToString.ToDouble
Dim Amortizacion As Double = Row("Amort.Ant").ToString.ToDouble
Dim ImpuestoLocal As Double = If(dt.Columns.Contains("ImpuestoLocal"), Row("ImpuestoLocal").ToString.ToDouble, 0.0)
Dim Amortizacion As Double = If(dt.Columns.Contains("Amort.Ant"), Row("Amort.Ant").ToString.ToDouble, 0.0)
Dim SubTotal As Decimal = Row("SubTotal").ToString.ToDecimal
Dim IVA As Decimal = Row("IVA").ToString.ToDecimal
Dim Total As Decimal = Row("Total").ToString.ToDecimal
@@ -1372,7 +1377,8 @@ Partial Class General_SaldosIniciales
Dim CveVendedor As Integer = 0
Dim IEPS As Decimal = 0 'Row("IEPS").ToString.ToDecimal
Dim CveClienteSucursal As Integer = 0 'Row("CveClienteSucursal").ToString.ToEntero
Dim ImpuestosLocales As Decimal = Row("ImpuestoLocal").ToString.ToDecimal
Dim ImpuestosLocales As Decimal = If(dt.Columns.Contains("ImpuestoLocal"), Row("ImpuestoLocal").ToString.ToDecimal, 0)
Dim FolioFiscal As String = If(dt.Columns.Contains("Folio Fiscal"), Row("Folio Fiscal").ToString, "")
GuardaLog(Sucursal + "-" + Row("Folio").ToString)
'Temporalmente SE BORRARA
@@ -1437,6 +1443,12 @@ Partial Class General_SaldosIniciales
ConceptoContablePago = 91
End If
If FolioFiscal <> "" Then
If Not ObjVentas.UpdateVentaFolioFiscal(FolioFiscal, CveVenta, UsuarioActual.CveEmpresa) Then
ErrorVentas = True
Exit For
End If
End If
'PrePólizaDetalle
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, SubTotal, Folio.ToString, 4, String.Format("{0}-{1}", Serie, Folio), Fecha, -1, -1, CveVenta:=CveVenta, CveCliente:=CveCliente, CveClasificacion:=CveClasificacion, ImporteMX:=SubTotal, CveSubProyecto:=Sucursal.ToEntero) Then ErrorVentas = True : Exit For

View File

@@ -605,62 +605,62 @@
<div class="modal-body">
<div align="right">
<input type="text" id="TxtBusq" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusq','{0}')", GvVtaPUE.ClientID) %>" style="display: inline-block; width: 150px;" />
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusq','{0}')", GvVtaPUE.ClientID) %>" style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusq','{0}')", GvVtaPUE.ClientID) %>" style="margin-top: -3px; margin-left: -13px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
</div>
<asp:GridView ID="GvVtaPUE" runat="server" AutoGenerateColumns="False"
DataKeysNames="CveVenta"
EmptyDataText="No se encontraron registros" ToolTip="Listado de Temas"
CssClass="table table-striped table-advance table-hover Widthall ScrollAD"
data-sort="true"
data-freezerows="1"
GridLines="None">
<Columns>
<asp:TemplateField HeaderText="SerieFolio">
<ItemTemplate>
&nbsp;<asp:HyperLink ID="HplNum" runat="server" CssClass="Texto" Target="_blank" NavigateUrl='<%# Eval("CveVenta", "/Ventas/Ventas.aspx?CveVenta={0}") %>' Text='<%# Eval("SerieFolio") %>'></asp:HyperLink>
</ItemTemplate>
</asp:TemplateField>
DataKeysNames="CveVenta"
EmptyDataText="No se encontraron registros" ToolTip="Listado de Temas"
CssClass="table table-striped table-advance table-hover Widthall ScrollAD"
data-sort="true"
data-freezerows="1"
GridLines="None">
<Columns>
<asp:TemplateField HeaderText="SerieFolio">
<ItemTemplate>
&nbsp;<asp:HyperLink ID="HplNum" runat="server" CssClass="Texto" Target="_blank" NavigateUrl='<%# Eval("CveVenta", "/Ventas/Ventas.aspx?CveVenta={0}") %>' Text='<%# Eval("SerieFolio") %>'></asp:HyperLink>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha">
<ItemTemplate>
&nbsp;<asp:Literal runat="server" Text='<%# Eval("Fecha", "{0:d}")%>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha">
<ItemTemplate>
&nbsp;<asp:Literal runat="server" Text='<%# Eval("Fecha", "{0:d}")%>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Cliente">
<ItemTemplate>
&nbsp;<asp:Literal runat="server" Text='<%# Eval("NombreComercial")%>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Cliente">
<ItemTemplate>
&nbsp;<asp:Literal runat="server" Text='<%# Eval("NombreComercial")%>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="SubProyecto">
<ItemTemplate>
<asp:Literal runat="server" Text='<%# Eval("SubProyecto") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="SubProyecto">
<ItemTemplate>
<asp:Literal runat="server" Text='<%# Eval("SubProyecto") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Total" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Literal runat="server" Text='<%# Eval("Total", "{0:N2}") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Total" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Literal runat="server" Text='<%# Eval("Total", "{0:N2}") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField ItemStyle-Width="10px" ItemStyle-HorizontalAlign="Left">
<ItemTemplate>
<asp:Literal runat="server" Text='<%# Eval("Abreviatura") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField ItemStyle-Width="10px" ItemStyle-HorizontalAlign="Left">
<ItemTemplate>
<asp:Literal runat="server" Text='<%# Eval("Abreviatura") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Saldo" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<div style="margin-right: 20px">
<asp:Literal runat="server" Text='<%# Eval("Saldo", "{0:N2}") %>'></asp:Literal>
</div>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Saldo" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<div style="margin-right: 20px">
<asp:Literal runat="server" Text='<%# Eval("Saldo", "{0:N2}") %>'></asp:Literal>
</div>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</Columns>
</asp:GridView>
<div class="modal-footer">
<asp:UpdatePanel runat="server">
<ContentTemplate>
@@ -674,6 +674,104 @@
</div>
<div id="ModalMitoteresat" class="modal ADS fade " role="dialog">
<div class="modal-dialog">
<!-- Modal content-->
<div class="modal-content modal-lg">
<div class="modal-header ">
<button type="button" class="close" data-dismiss="modal">&times;</button>
<h4 class="modal-title">Ventas sin registrar en SIG</h4>
</div>
<div class="modal-body">
<div style="text-align: right">
<asp:HyperLink runat="server" NavigateUrl="/Ventas/RepConciliacionEmitidosSat.aspx?RegistroEn=4">Ver más</asp:HyperLink>
<input type="text" id="TxtBusquedaFolioSat" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusquedaFolioSat','{0}')", GvFoliosSAT.ClientID) %>" style="display: inline-block; width: 150px;" />
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusquedaFolioSat','{0}')", GvFoliosSAT.ClientID) %>" style="margin-top: -3px; margin-left: -13px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
</div>
<asp:GridView ID="GvFoliosSAT" runat="server" AutoGenerateColumns="false" EmptyDataText="No se encontraron factura canceladas pendientes"
DataKeyNames="FolioFiscal,RFC,Total"
CssClass="table table-striped table-advance table-hover Widthall ScrollAD" data-sort="true" Style="text-align: center;" GridLines="None" Width="99%">
<Columns>
<asp:BoundField HeaderText="Folio Fiscal" DataField="FolioFiscal" ItemStyle-Width="20%" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField HeaderText="Serie Folio" DataField="SerieFolio" ItemStyle-Width="15%" ItemStyle-HorizontalAlign="Center" />
<asp:BoundField HeaderText="Proveedor" DataField="NombreProveedor" ItemStyle-Width="20%" ItemStyle-HorizontalAlign="Center" />
<asp:BoundField HeaderText="Importe" DataField="Total" DataFormatString="{0:N2}" ItemStyle-Width="15%" ItemStyle-HorizontalAlign="Center" />
<asp:BoundField HeaderText="Fecha" DataField="Fecha" DataFormatString="{0:dd/MM/yyyy}" ItemStyle-Width="15%" ItemStyle-HorizontalAlign="Center" />
<%--<asp:TemplateField ItemStyle-HorizontalAlign="Center" ItemStyle-Width="15%" HeaderText=" ">
<ItemTemplate>
<asp:LinkButton runat="server" CssClass="btn btn-circle btn-sm blue" Text="<i class='fa fa-plus'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea Agregar la factura?" data-btn-ok-label="si"></asp:LinkButton>
<asp:LinkButton runat="server" CssClass="btn btn-circle btn-sm red" Text="<i class='fa fa-remove'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea cancelacar la factura ante el sat?" data-btn-ok-label="si" />
</ItemTemplate>
</asp:TemplateField>--%>
</Columns>
<RowStyle CssClass="Texto" />
<HeaderStyle CssClass="Titulos" />
</asp:GridView>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-danger" data-dismiss="modal">Cancelar</button>
</div>
</div>
</div>
</div>
<div id="ModalMitotereCancelaPendiente" class="modal ADS fade " role="dialog">
<div class="modal-dialog">
<!-- Modal content-->
<div class="modal-content modal-lg">
<div class="modal-header ">
<button type="button" class="close" data-dismiss="modal">&times;</button>
<h4 class="modal-title">Cancelaciones por Atender</h4>
</div>
<div class="modal-body">
<div style="text-align: right">
<asp:HyperLink runat="server" NavigateUrl="/Ventas/RepCancelacionesPorAtender.aspx">Ver más</asp:HyperLink>
<input type="text" id="TxtBusquedaCancelaPendiente" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusquedaCancelaPendiente','{0}')", gvCancelaPendiente.ClientID) %>" style="display: inline-block; width: 150px;" />
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusquedaCancelaPendiente','{0}')", gvCancelaPendiente.ClientID) %>" style="margin-top: -3px; margin-left: -13px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
</div>
<asp:GridView ID="gvCancelaPendiente" runat="server" AutoGenerateColumns="false" EmptyDataText="No se encontraron factura canceladas pendientes"
DataKeyNames="FolioFiscal,RFC,Total"
CssClass="table table-striped table-advance table-hover Widthall ScrollAD" data-sort="true" Style="text-align: center;" GridLines="None" Width="99%">
<Columns>
<asp:BoundField HeaderText="Folio Fiscal" DataField="FolioFiscal" ItemStyle-Width="20%" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField HeaderText="Serie Folio" DataField="SerieFolio" ItemStyle-Width="15%" ItemStyle-HorizontalAlign="Center" />
<asp:BoundField HeaderText="Proveedor" DataField="NombreProveedor" ItemStyle-Width="20%" ItemStyle-HorizontalAlign="Center" />
<asp:BoundField HeaderText="Importe" DataField="Total" DataFormatString="{0:N2}" ItemStyle-Width="15%" ItemStyle-HorizontalAlign="Center" />
<asp:BoundField HeaderText="Fecha" DataField="Fecha" DataFormatString="{0:dd/MM/yyyy}" ItemStyle-Width="15%" ItemStyle-HorizontalAlign="Center" />
<%--<asp:TemplateField ItemStyle-HorizontalAlign="Center" ItemStyle-Width="15%" HeaderText=" ">
<ItemTemplate>
<asp:LinkButton runat="server" CssClass="btn btn-circle btn-sm blue" Text="<i class='fa fa-plus'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea Agregar la factura?" data-btn-ok-label="si"></asp:LinkButton>
<asp:LinkButton runat="server" CssClass="btn btn-circle btn-sm red" Text="<i class='fa fa-remove'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea cancelacar la factura ante el sat?" data-btn-ok-label="si" />
</ItemTemplate>
</asp:TemplateField>--%>
</Columns>
<RowStyle CssClass="Texto" />
<HeaderStyle CssClass="Titulos" />
</asp:GridView>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-danger" data-dismiss="modal">Cancelar</button>
</div>
</div>
</div>
</div>
<div id="ModalComprasPUE" class="modal ADS fade" role="dialog">
<div class="modal-dialog">
@@ -687,62 +785,62 @@
<div class="modal-body">
<div align="right">
<input type="text" id="TxtBus" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBus','{0}')", GvCompPUE.ClientID) %>" style="display: inline-block; width: 150px;" />
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBus','{0}')", GvCompPUE.ClientID) %>" style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBus','{0}')", GvCompPUE.ClientID) %>" style="margin-top: -3px; margin-left: -13px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
</div>
<asp:GridView ID="GvCompPUE" runat="server" AutoGenerateColumns="False"
DataKeysNames="CveCompra"
EmptyDataText="No se encontraron registros" ToolTip="Listado de Temas"
CssClass="table table-striped table-advance table-hover Widthall ScrollAD"
data-sort="true"
data-freezerows="1"
GridLines="None">
<Columns>
<asp:TemplateField HeaderText="SerieFolio">
<ItemTemplate>
&nbsp;<asp:HyperLink ID="HplNum" runat="server" CssClass="Texto" Target="_blank" NavigateUrl='<%# Eval("CveCompra", "/Compras/Compras.aspx?CveCompra={0}") %>' Text='<%# Eval("SerieFolio") %>'></asp:HyperLink>
</ItemTemplate>
</asp:TemplateField>
DataKeysNames="CveCompra"
EmptyDataText="No se encontraron registros" ToolTip="Listado de Temas"
CssClass="table table-striped table-advance table-hover Widthall ScrollAD"
data-sort="true"
data-freezerows="1"
GridLines="None">
<Columns>
<asp:TemplateField HeaderText="SerieFolio">
<ItemTemplate>
&nbsp;<asp:HyperLink ID="HplNum" runat="server" CssClass="Texto" Target="_blank" NavigateUrl='<%# Eval("CveCompra", "/Compras/Compras.aspx?CveCompra={0}") %>' Text='<%# Eval("SerieFolio") %>'></asp:HyperLink>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha">
<ItemTemplate>
&nbsp;<asp:Literal runat="server" Text='<%# Eval("Fecha", "{0:d}")%>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha">
<ItemTemplate>
&nbsp;<asp:Literal runat="server" Text='<%# Eval("Fecha", "{0:d}")%>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Proveedor">
<ItemTemplate>
&nbsp;<asp:Literal runat="server" Text='<%# Eval("NombreComercial")%>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Proveedor">
<ItemTemplate>
&nbsp;<asp:Literal runat="server" Text='<%# Eval("NombreComercial")%>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="SubProyecto">
<ItemTemplate>
<asp:Literal runat="server" Text='<%# Eval("SubProyecto") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="SubProyecto">
<ItemTemplate>
<asp:Literal runat="server" Text='<%# Eval("SubProyecto") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Total" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Literal runat="server" Text='<%# Eval("Total", "{0:N2}") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Total" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Literal runat="server" Text='<%# Eval("Total", "{0:N2}") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField ItemStyle-Width="10px" ItemStyle-HorizontalAlign="Left">
<ItemTemplate>
<asp:Literal runat="server" Text='<%# Eval("Abreviatura") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField ItemStyle-Width="10px" ItemStyle-HorizontalAlign="Left">
<ItemTemplate>
<asp:Literal runat="server" Text='<%# Eval("Abreviatura") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Saldo" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<div style="margin-right: 20px">
<asp:Literal runat="server" Text='<%# Eval("Saldo", "{0:N2}") %>'></asp:Literal>
</div>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Saldo" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<div style="margin-right: 20px">
<asp:Literal runat="server" Text='<%# Eval("Saldo", "{0:N2}") %>'></asp:Literal>
</div>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</Columns>
</asp:GridView>
<div class="modal-footer">
<asp:UpdatePanel runat="server">
<ContentTemplate>
@@ -767,13 +865,15 @@
</div>
<div class="modal-body">
<div align="left">
<div class="row">
<div class="col-md-6">
# Inconsistencias:
<asp:Label ID="LblInconsistenciasNum" runat="server" Text="0" Font-Bold="true"></asp:Label>
</div>
<div align="right">
<div class="col-md-6" style="text-align :right">
<input type="text" id="TxtBusqueda" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvIncons.ClientID) %>" style="display: inline-block; width: 150px;" />
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvIncons.ClientID) %>" style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvIncons.ClientID) %>" style="margin-top: -3px; margin-left: -13px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
</div>
</div>
<asp:GridView ID="GvIncons" runat="server" CssClass="table table-striped table-advance table-hover Widthall ScrollAD mysmallbtn" GridLines="None">
</asp:GridView>
@@ -800,7 +900,15 @@
</div>
<div class="modal-body">
# No Timbradas:
<div class="row">
<div class="col-md-6"># No Timbradas:</div>
<div class="col-md-6" style="text-align :right">
<input type="text" id="TxtBusquedaCentroCosto" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusquedaCentroCosto','{0}')", GvNoTimbradasCentroCosto.ClientID) %>" style="display: inline-block; width: 150px;" />
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusquedaCentroCosto','{0}')", GvNoTimbradasCentroCosto.ClientID) %>" style="margin-top: -3px; margin-left: -13px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
</div>
</div>
<asp:Label ID="LblNoTimbradas" runat="server" Text="0" Font-Bold="true"></asp:Label>
<asp:GridView ID="GvNoTimbradasCentroCosto" CssClass="table table-striped table-advance table-hover Widthall ScrollAD mysmallbtn" AutoGenerateColumns="false" runat="server" GridLines="None">
<Columns>

View File

@@ -16,6 +16,28 @@ Partial Class Inicio
Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load
If Not IsPostBack Then
If UsuarioActual.CveUsuario = 100 Then
Using objgral As New ClsGenerales
objgral.RepConciliacionSatDetalleGET(UsuarioActual.CveEmpresa, "I", "", "", 10)
If objgral.DtResultados.Rows.Count > 0 Then
GvFoliosSAT.DataSource = objgral.DtResultados
RegistraScript("$('#ModalMitoteresat').modal();", "mitoterosat")
End If
End Using
GvFoliosSAT.DataBind()
End If
If UsuarioActual.CveUsuario = 100 Then
Using objventas As New ClsVentas
If (objventas.GetFacturasCanceladasPendientesWS(UsuarioActual.Empresa.RFC, UsuarioActual.CveEmpresa, False)) AndAlso objventas.DtResultados.Rows.Count > 0 Then
RegistraScript("$('#ModalMitotereCancelaPendiente').modal();", "mitoterosatCanceladasPendientesWS")
End If
End Using
End If
'Exit Sub
'RESTRICCION AD
If Not IsNothing(Request("ADCod")) Then
'viene el msg encriptado, para sacar el modulo

View File

@@ -161,6 +161,10 @@
</span>
<ajax:MaskedEditExtender ID="MEEFechaI" runat="server" TargetControlID="TxtFechaI" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="CEFechaI" TargetControlID="TxtFechaI" PopupButtonID="ImgFechaI" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
<asp:RequiredFieldValidator ID="rfvFechaI" runat="server" ControlToValidate="txtFechaI" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="Valida"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="cvFechaI" runat="server" ControlToValidate="txtFechaI" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="Valida"></asp:CompareValidator>
<ajax:ValidatorCalloutExtender ID="vcoFfvFI" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaI" Width="350px"></ajax:ValidatorCalloutExtender>
<ajax:ValidatorCalloutExtender ID="vcoCvFI" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaI" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
</div>
</div>
@@ -175,6 +179,10 @@
</div>
<ajax:MaskedEditExtender ID="MEEFechaF" runat="server" TargetControlID="TxtFechaF" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="CalendarExtender1" TargetControlID="TxtFechaF" PopupButtonID="ImgFechaF" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
<asp:RequiredFieldValidator ID="rfvFechaF" runat="server" ControlToValidate="txtFechaF" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="Valida"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="cvFechaF" runat="server" ControlToValidate="txtFechaF" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="Valida"></asp:CompareValidator>
<ajax:ValidatorCalloutExtender ID="vcoRfvFF" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
<ajax:ValidatorCalloutExtender ID="vcoCvFF" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
</div>
<div class="col-md-1">

View File

@@ -1868,112 +1868,7 @@ Partial Class Inventarios_RecepcionEntrega
End If
' TERMINA: GARANTIAS
' COMIENZA: VIRTUAL
If TipoDocto.Contiene("Ing") AndAlso UsuarioActual.Empresa.Funcionalidad(573) = "1" Then
Dim DtPSVirtual As New DataTable("DtTamanios")
DtPSVirtual.Columns.Add(New DataColumn("CvePS", GetType(Integer)))
DtPSVirtual.Columns.Add(New DataColumn("Cantidad", GetType(Decimal)))
DtPSVirtual.Columns.Add(New DataColumn("PU", GetType(Decimal)))
DtPSVirtual.Columns.Add(New DataColumn("CveUM", GetType(Integer)))
Dim DtTamanios As DataTable = Nothing
If ObjAcumuladores.TamañoGet(-1, UsuarioActual.CveEmpresa) Then
DtTamanios = ObjAcumuladores.DtResultados.Copy()
End If
Dim CveConceptoMovimientoVirtual As Integer = -1
Dim CveAlmacenVirtual As Integer = -1
Dim CveMovimientoRelacionadoVirtual As Integer = -1
Dim ValidaVirtual As Boolean = False
If TipoMovimiento = 1 Then
For Each GvRow As GridViewRow In GvDatos.Rows
If GvRow.RowType = DataControlRowType.DataRow Then
If GvRow.datakey("CveTamaño").tostring.toentero > 0 Then
ValidaVirtual = True ' si tiene tamaño, debe de tener virtual
Dim drr As DataRow = DtTamanios.FiltroPrimero(String.Format("CveTamaño={0}", GvRow.DataKey("CveTamaño")))
If drr IsNot Nothing Then
Dim CvePSCargo = drr("CvePSCargo").ToString().ToEntero()
Dim Row As DataRow = DtPSVirtual.NewRow()
Row("CvePS") = CvePSCargo
Row("Cantidad") = GvRow.FCTextBox("TbCantidadF").Text.ToDecimal()
Row("PU") = 0
Row("CveUM") = GvRow.DataKey("CveUM").ToEntero()
DtPSVirtual.Rows.Add(Row)
End If
End If
End If
Next
CveConceptoMovimientoVirtual = 3
CveAlmacenVirtual = GlobalDTAlmacenUsuarios(UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, 24).FiltroPrimeroValor("CveAlmacen", $"CveSubProyecto={CveSubProyecto}").ToEntero()
ElseIf TipoMovimiento = 2 Then
ValidaVirtual = True
Dim CveMovimientoSalidaDev As Integer = -1
If ObjInventario.GetInv_Mov(CveVentaSurtir, UsuarioActual.CveEmpresa) Then
Dim RowMovimiento As DataRow = ObjInventario.DtResultados.FiltroPrimero("CvePS IS NULL AND CveTipoAlmacen = 24 AND CveConcepto = 3 AND CveVenta > 0")
CveMovimientoSalidaDev = RowMovimiento("CveMovimiento").ToString().ToEntero()
CveAlmacenVirtual = RowMovimiento("CveAlmacen").ToString().ToEntero()
CveMovimientoRelacionadoVirtual = CveMovimientoSalidaDev
Else
ErrorMovInv = True
TextoError = "Ocurrió un error al procesar el movimiento. Por favor vuelva a intentar."
End If
'CARGA CONCEPTOS DEVUELTOS EN LA VENTA
If ObjInventario.GetMovimientosDetalle(CveMovimientoSalidaDev, UsuarioActual.CveEmpresa) Then
DtPSVirtual = ObjInventario.DtResultados.Copy()
Else
ErrorMovInv = True
TextoError = "Ocurrió un error al procesar los movimientos de devolución. Por favor vuelva a intentar."
End If
CveConceptoMovimientoVirtual = 18
End If
If DtPSVirtual IsNot Nothing AndAlso DtPSVirtual.Rows.Count > 0 AndAlso CveAlmacenVirtual > 0 AndAlso CveConceptoMovimientoVirtual > 0 Then
CveMovimientoVirtual = ObjInventario.AddMovimiento(CveAlmacenVirtual, CveConceptoMovimientoVirtual, 1, TxtFecha.Text.ToDate, -1, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1, CveVentaSurtir, -1, -1,
Observaciones:=TxtObservaciones.Text.Trim, Guia:=TxtGuia.Text, CveMovimientoRelacionado:=CveMovimientoRelacionadoVirtual, Modulo:="RE/G6")
FolioVirtual = ObjInventario.Folio
If CveMovimientoVirtual > 0 Then
For Each RowUsado As DataRow In DtPSVirtual.Rows
Dim CvePS = RowUsado("CvePS").ToString().ToEntero()
Dim CantidadUsado As Double = RowUsado("Cantidad").ToString().ToDouble()
Dim PU As Double = RowUsado("PU").ToString().ToDouble()
Dim CveUM As Integer = RowUsado("CveUM").ToString().ToEntero()
If Not ObjInventario.AddMovimientoDetalle(CveMovimientoVirtual, CantidadUsado, CveUM, CvePS, PU, -1) Then
ErrorMovInv = True
TextoError = "Ocurrió un error al procesar los conceptos de traspaso de apartado. Por favor vuelva a intentar."
Exit For
End If
Next
Else
ErrorMovInv = True
End If
Else
If ValidaVirtual Then
ErrorMovInv = True
TextoError = "Ocurrió un error al procesar el movimiento en almacen virtual. Por favor vuelva a intentar."
End If
End If
If DtPSVirtual.Rows.Count = 0 AndAlso ValidaVirtual = True Then
ErrorMovInv = True
TextoError = "No se tienen productos para el almacen virtual."
End If
End If
' TERMINA: VIRTUAL
If Not ErrorMovInv Then
Dim ConceptoMovimiento = 3
@@ -2097,7 +1992,7 @@ Partial Class Inventarios_RecepcionEntrega
Else
If ObjInventario.GetMovimientosDetalle(CveMovimiento, UsuarioActual.CveEmpresa) Then
For Each Dr As DataRow In ObjInventario.DtResultados.Rows
If Not ObjInventario.AddMovimientoDetalle(CveMovimientoEntrada, Dr("Cantidad").ToString.ToDouble, Dr("CveUM").ToString.ToEntero, Dr("CvePS").ToString.ToEntero, Dr("PU").ToString.ToDouble, Dr("CveAF").ToString.ToEntero, -1, Dr("SerieLote").ToString, CveVentaDetalle:=Dr("CveVentaDetalle").ToString.ToEntero, Lote:=Dr("Lote").ToString, Batch:=Dr("Batch").ToString, EsInterno:=EsInterno) Then
If Not ObjInventario.AddMovimientoDetalle(CveMovimientoEntrada, Dr("Cantidad").ToString.ToDouble, Dr("CveUM").ToString.ToEntero, Dr("CvePS").ToString.ToEntero, Dr("PU").ToString.ToDouble, Dr("CveAF").ToString.ToEntero, -1, Dr("SerieLote").ToString, CveVentaDetalle:=Dr("CveVentaDetalle").ToString.ToEntero, Lote:=Dr("Lote").ToString, Batch:=Dr("Batch").ToString, EsInterno:=EsInterno, CveMovimientoDetalleEntrada:=Dr("CveMovimientoDetalle").ToString.ToEntero()) Then
ErrorMovInv = True
TextoError = "Ocurrió un error al guardar los movimientos de entrada"
Exit For
@@ -2316,8 +2211,81 @@ Partial Class Inventarios_RecepcionEntrega
End If
End If
'AGREGA BITACORA A VENTA
If Not ErrorMovInv Then
' COMIENZA: VIRTUAL
If TipoDocto.Contiene("Ing", "Dev") AndAlso UsuarioActual.Empresa.Funcionalidad(573) = "1" AndAlso CveMovimiento > 0 Then
Dim DtPSVirtual As New DataTable("DtTamanios")
If ObjInventario.GetMovimientosDetalleVirtual(CveMovimiento, UsuarioActual.CveEmpresa) Then
DtPSVirtual = ObjInventario.DtResultados
End If
'
'DtPSVirtual.Columns.Add(New DataColumn("CvePS", GetType(Integer)))
'DtPSVirtual.Columns.Add(New DataColumn("Cantidad", GetType(Decimal)))
'DtPSVirtual.Columns.Add(New DataColumn("PU", GetType(Decimal)))
'DtPSVirtual.Columns.Add(New DataColumn("CveUM", GetType(Integer)))
'Dim DtTamanios As DataTable = Nothing
'If ObjAcumuladores.TamañoGet(-1, UsuarioActual.CveEmpresa) Then
' DtTamanios = ObjAcumuladores.DtResultados.Copy()
'End If
Dim CveConceptoMovimientoVirtual As Integer = -1
Dim CveAlmacenVirtual As Integer = -1
Dim CveMovimientoRelacionadoVirtual As Integer = CveMovimiento
Dim ValidaVirtual As Boolean = False
CveAlmacenVirtual = GlobalDTAlmacenUsuarios(UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, 24).FiltroPrimeroValor("CveAlmacen", $"CveSubProyecto={CveSubProyecto}").ToEntero()
If TipoMovimiento = 1 Then
CveConceptoMovimientoVirtual = 37
ElseIf TipoMovimiento = 2 Then
ValidaVirtual = True
CveConceptoMovimientoVirtual = 36
End If
If DtPSVirtual IsNot Nothing AndAlso DtPSVirtual.Rows.Count > 0 AndAlso CveAlmacenVirtual > 0 AndAlso CveConceptoMovimientoVirtual > 0 Then
CveMovimientoVirtual = ObjInventario.AddMovimiento(CveAlmacenVirtual, CveConceptoMovimientoVirtual, 1, TxtFecha.Text.ToDate, -1, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1, CveVentaSurtir, -1, -1,
Observaciones:=TxtObservaciones.Text.Trim, Guia:=TxtGuia.Text, CveMovimientoRelacionado:=CveMovimientoRelacionadoVirtual, Modulo:="RE/G6")
FolioVirtual = ObjInventario.Folio
If CveMovimientoVirtual > 0 Then
For Each RowUsado As DataRow In DtPSVirtual.Rows
Dim CvePS = RowUsado("CvePS").ToString().ToEntero()
Dim CantidadUsado As Double = RowUsado("Cantidad").ToString().ToDouble()
Dim PU As Double = RowUsado("PU").ToString().ToDouble()
Dim CveUM As Integer = RowUsado("CveUM").ToString().ToEntero()
If Not ObjInventario.AddMovimientoDetalle(CveMovimientoVirtual, CantidadUsado, CveUM, CvePS, PU, -1) Then
ErrorMovInv = True
TextoError = "Ocurrió un error al procesar los conceptos de traspaso de apartado. Por favor vuelva a intentar."
Exit For
End If
Next
Else
ErrorMovInv = True
End If
Else
If ValidaVirtual Then
ErrorMovInv = True
TextoError = "Ocurrió un error al procesar el movimiento en almacen virtual. Por favor vuelva a intentar."
End If
End If
If DtPSVirtual.Rows.Count = 0 AndAlso ValidaVirtual = True Then
ErrorMovInv = True
TextoError = "No se tienen productos para el almacen virtual."
End If
End If
' TERMINA: VIRTUAL
'AGREGA BITACORA A VENTA
If Not ErrorMovInv Then
Dim MensajeBitacora = If(TipoMovimiento = 1, "Surtida", "Devuelta")
If Not ObjEventos.AddEventoBitacora(String.Format("Venta {2} en Folio: <a href=""/Inventarios/EntradasSalidas.aspx?CveMovimiento={0}"" target=""_blank"">{1}</a>", CveMovimiento, Folio, MensajeBitacora), "-1", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CveVenta:=CveVentaSurtir) Then
ErrorMovInv = True
@@ -2334,7 +2302,7 @@ Partial Class Inventarios_RecepcionEntrega
RegistraScript("playsonidito('beep-07.wav')")
Dim Msg As New StringBuilder
Msg.AppendFormat("Movimiento Salida: <b><a href=""/Inventarios/EntradasSalidas.aspx?CveMovimiento={0}"" target=""_blank"">{1}</a></b>", CveMovimiento, Folio)
Msg.AppendFormat("Movimiento {2}: <b><a href=""/Inventarios/EntradasSalidas.aspx?CveMovimiento={0}"" target=""_blank"">{1}</a></b>", CveMovimiento, Folio, If(TipoMovimiento = 1, "Salida", "Entrada"))
Msg.AppendFormat("<br/><a class=""Texto"" target='_blank' href=""/Compras/PopUpVerFactura.aspx?P={0}"">Imprimir Movimiento</a> ", Encripta(String.Format("OP=Alm&CveMovimiento={0}", CveMovimiento)))
If CveMovimientoEntrada > 0 Then
@@ -2355,7 +2323,7 @@ Partial Class Inventarios_RecepcionEntrega
End If
If CveMovimientoVirtual > 0 Then
Msg.AppendFormat("<br/><br/> Movimiento de Salida del Almacen Virtual: ")
Msg.AppendFormat("<br/><br/> {0} Almacen Virtual: ", If(TipoMovimiento = 1, "Salida", "Entrada"))
Msg.AppendFormat("<b><a href=""/Inventarios/EntradasSalidas.aspx?CveMovimiento={0}"" target=""_blank"">{1}</a></b>", CveMovimientoVirtual, FolioVirtual)
Msg.AppendFormat("<br/><a class=""Texto"" target='_blank' href=""/Compras/PopUpVerFactura.aspx?P={0}"">Imprimir Movimiento</a> ", Encripta(String.Format("OP=Alm&CveMovimiento={0}", CveMovimientoVirtual)))
End If

View File

@@ -309,6 +309,14 @@ Partial Class Inventarios_RecepcionUsados
ViewState("TmpDTAjustes") = value
End Set
End Property
Private Property DtPorcentajeMarcas As DataTable
Get
Return If(IsNothing(ViewState("DtPorcentajeMarcas")), Nothing, CType(ViewState("DtPorcentajeMarcas"), DataTable))
End Get
Set(value As DataTable)
ViewState("DtPorcentajeMarcas") = value
End Set
End Property
#End Region
@@ -2442,13 +2450,18 @@ Partial Class Inventarios_RecepcionUsados
Public Sub OnRblUsadosAjuste_Change(sender As Object, e As EventArgs)
DdlAlmacen.Items.Clear()
If RblUsadosAjuste.SelectedValue = "1" Then
CargaAjuste()
DivAjuste.Visible = True
'Llenar el dropdownlist de almacén
DdlAlmacen.DataSource = GlobalDTAlmacenUsuarios(UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, 6)
LnkAgregarUsado.Visible = False
UppAcciones.Update()
If DdlClientes.SelectedValue <> "-1" Then
CargaAjuste()
DivAjuste.Visible = True
'Llenar el dropdownlist de almacén
DdlAlmacen.DataSource = GlobalDTAlmacenUsuarios(UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, 6)
CargarDescuento()
LnkAgregarUsado.Visible = False
UppAcciones.Update()
Else
Alert("hace falta seleccionar un cliente")
RblUsadosAjuste.SelectedValue = "0"
End If
Else
DivAjuste.Visible = False
'Llenar el dropdownlist de almacén
@@ -2545,6 +2558,31 @@ Partial Class Inventarios_RecepcionUsados
End If
End If
Dim MarcaPorcentaje As DataRow = DtPorcentajeMarcas.FiltroPrimero(String.Format("CveMarca = {0}", drPS("CveMarca").ToString))
If MarcaPorcentaje IsNot Nothing Then
Dim PorcentajeProducto As Decimal = MarcaPorcentaje("PorcentajeProducto").ToString.ToDecimal / 100
Dim PorcentajeProducto2 As Decimal = MarcaPorcentaje("PorcentajeProducto2").ToString.ToDecimal / 100
Dim PorcentajeProducto3 As Decimal = MarcaPorcentaje("PorcentajeProducto3").ToString.ToDecimal / 100
If PorcentajeProducto > 0 Then
Dim MontoDescuento As Decimal = PrecioSugerido * PorcentajeProducto
PrecioSugerido -= MontoDescuento
If PorcentajeProducto2 > 0 Then
MontoDescuento = PrecioSugerido * PorcentajeProducto2
PrecioSugerido -= MontoDescuento
If PorcentajeProducto3 > 0 Then
MontoDescuento = PrecioSugerido * PorcentajeProducto3
PrecioSugerido -= MontoDescuento
End If
End If
End If
End If
txtPrecio.Text = PrecioSugerido.FormatoNumero(2)
TxtPUFactura.Text = PrecioSugerido.FormatoNumero(2)
End If
@@ -2713,6 +2751,14 @@ Partial Class Inventarios_RecepcionUsados
End If
ObjPS.Dispose()
End Sub
Protected Sub CargarDescuento()
Dim ObjPS As New ClsProductosServicios
If ObjPS.GetPorcentajeMarcas(DdlClientes.SelectedValue.ToEntero) Then
DtPorcentajeMarcas = ObjPS.DtResultados.Copy()
End If
ObjPS.Dispose()
End Sub
#End Region
End Class

View File

@@ -804,7 +804,7 @@ Partial Class Inventarios_TraspasoAlmacen
Dim CveAlmacenVirtual As Integer = GlobalDTAlmacenUsuarios(UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, 24).FiltroPrimeroValor("CveAlmacen", $"CveSubProyecto={CveSubProyecto}").ToEntero()
CveMovimientoVirtualSalida = ObjInventario.AddMovimiento(CveAlmacenVirtual, 3, 1, TxtFecha.Text.ToDate, -1, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1, -1, -1, -1, Observaciones:=TxtObservaciones.Text.Trim, Modulo:="TA/V", CveMovimientoRelacionado:=CveMovimientoSalida)
CveMovimientoVirtualSalida = ObjInventario.AddMovimiento(CveAlmacenVirtual, 37, 1, TxtFecha.Text.ToDate, -1, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1, -1, -1, -1, Observaciones:=TxtObservaciones.Text.Trim, Modulo:="TA/V", CveMovimientoRelacionado:=CveMovimientoSalida)
FolioVirtualSalida = ObjInventario.Folio
Dim dtvirtual As DataTable = Nothing
@@ -829,11 +829,11 @@ Partial Class Inventarios_TraspasoAlmacen
'AGREGAMOS LA ENTRADA
If Not ChkTransitorio.Checked Then 'SI NO ES TRANSITORIO SE HACE LA RECEPCION DE INMEDIATO
If Not ErrorMovInv Then
Dim TipoMovimientoEntrada = 9
Dim TipoMovimientoEntrada = 36
AlmacenEntrada = If(ChkTransitorio.Checked, DdlAlmacenTransitorio.SelectedValue.ToEntero, DdlAlmacenDestino.SelectedValue.ToEntero)
CveMovimientoEntrada = ObjInventario.AddMovimiento(AlmacenEntrada, TipoMovimientoEntrada, 1, Fecha, -1, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1, -1, -1, -1, -1, -1,
Observaciones:=TxtObservaciones.Text.Trim, Recibio:=If(ChkTransitorio.Checked, TxtResponsable.Text.Trim, "-1"),
CveAlmacenDestino:=If(ChkTransitorio.Checked, DdlAlmacenDestino.SelectedValue.ToEntero, -1), CveMovimientoRelacionado:=CveMovimientoSalida, Modulo:="TA/G")
CveAlmacenDestino:=If(ChkTransitorio.Checked, DdlAlmacenDestino.SelectedValue.ToEntero, -1), CveMovimientoRelacionado:=CveMovimientoEntrada, Modulo:="TA/G")
FolioEntrada = ObjInventario.Folio
If CveMovimientoEntrada <= 0 Then
TextoError = "Ocurrió un error al generar el movimiento de entrada"

View File

@@ -286,11 +286,12 @@
<div class="row">
<label class="col-md-2">Proveedor:</label>
<div class="col-md-9">
<asp:DropDownList ID="DdlProveedores" CssClass="select2me" AutoPostBack="True" Style="width: 100%;" runat="server" DataTextField="RazonSocial" DataValueField="CveProveedor">
<%--<asp:DropDownList ID="DdlProveedores" CssClass="select2me" AutoPostBack="True" Style="width: 100%;" runat="server" DataTextField="NombreCortoProveedor" DataValueField="CveProveedor">
<asp:ListItem Selected="True" Text="Todos" Value="-1"></asp:ListItem>
</asp:DropDownList>
<asp:RangeValidator ID="RVProveedores" CssClass="form-control" runat="server" ControlToValidate="DdlProveedores" Display="None" Type="Integer" MinimumValue="1" MaximumValue="2147483647" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Proveedor''</b> es necesario, por favor seleccione uno." ValidationGroup="GrpGuardar"></asp:RangeValidator>
<ajax:ValidatorCalloutExtender ID="VCOProveedores" runat="server" HighlightCssClass="vco" TargetControlID="RVProveedores" Width="300px"></ajax:ValidatorCalloutExtender>
</asp:DropDownList>--%>
<ADS:Dropdownlost runat="server" ID="DdlProveedores" CssStyle="width: 100%;" CssClassDdl="select2me " DataTextField="NombreCortoProveedor" DataValueField="CveProveedor" />
<%--<asp:RangeValidator ID="RVProveedores" CssClass="form-control" runat="server" ControlToValidate="DdlProveedores" Display="None" Type="Integer" MinimumValue="1" MaximumValue="2147483647" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Proveedor''</b> es necesario, por favor seleccione uno." ValidationGroup="GrpGuardar"></asp:RangeValidator>
<ajax:ValidatorCalloutExtender ID="VCOProveedores" runat="server" HighlightCssClass="vco" TargetControlID="RVProveedores" Width="300px"></ajax:ValidatorCalloutExtender>--%>
<asp:ImageButton ID="ImgCambiaProv" Visible="false" ImageUrl="/Imagenes/accept.png" runat="server" />
</div>
<div class="col-md-1" style="padding-left: 0px;">
@@ -2555,9 +2556,11 @@
<div class="col-md-6 v-center">
<label class="col-md-6 v-center truncate">Proveedor:</label>
<div class="col-md-6 v-center">
<asp:DropDownList ID="DdlProveedorCot" runat="server" Width="100%" CssClass="select2me" DataTextField="RazonSocial" DataValueField="CveProveedor"></asp:DropDownList>
<asp:RequiredFieldValidator ID="RFVProveedorExcel" runat="server" ControlToValidate="DdlProveedorCot" InitialValue="-1" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Proveedor''</b> es necesario, por favor selecionarlo." ValidationGroup="GrpCargarExcel"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCProveedor" runat="server" HighlightCssClass="vco" TargetControlID="RFVProveedorExcel" Width="300px"></ajax:ValidatorCalloutExtender>
<%--<asp:DropDownList ID="DdlProveedorCot" runat="server" Width="100%" CssClass="select2me" DataTextField="RazonSocial" DataValueField="CveProveedor"></asp:DropDownList>--%>
<ADS:Dropdownlost runat="server" ID="DdlProveedorCot" CssStyle="width: 100%;" CssClassDdl="select2me " DataTextField="NombreCortoProveedor" DataValueField="CveProveedor" />
<%-- <asp:RequiredFieldValidator ID="RFVProveedorExcel" runat="server" ControlToValidate="DdlProveedorCot" InitialValue="-1" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Proveedor''</b> es necesario, por favor selecionarlo." ValidationGroup="GrpCargarExcel"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCProveedor" runat="server" HighlightCssClass="vco" TargetControlID="RFVProveedorExcel" Width="300px"></ajax:ValidatorCalloutExtender>--%>
</div>
</div>
</div>

View File

@@ -476,6 +476,7 @@ Partial Class OC
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
If Not Page.IsPostBack Then
CargaDatosAgregarPS()
'MODALIDAD MULTIEMPRESA
CveEmpresaActual = UsuarioActual.CveEmpresa
@@ -754,7 +755,6 @@ Partial Class OC
UPPDetalle.Update()
PermisosPagina()
RegistraScript("$get('HdnWidth').value = $('#C_Tab_TabC_DivConceptosContenido').width();")
End If
Me.Form.DefaultButton = ""
@@ -1294,7 +1294,12 @@ Partial Class OC
HplCompraContabilizada.Text = "No"
End If
DdlProveedores.SelectedValueExist(objOC.CveProveedor.ToString)
DdlProveedores.SelectedValue = objOC.CveProveedor.ToString
If DdlProveedores.SelectedValue.ToEntero > 0 Then
DdlProveedores.SelectedText = GlobalDTCompProveedores(UsuarioActual.CveEmpresa).FiltraParametros($"CveProveedor = {objOC.CveProveedor}").Rows(0)("RazonSocial").ToString
Else
DdlProveedores.SelectedText = "-"
End If
'CARGAMOS LA SUCURSAL SI NO EXISTE SE AGREGA MATRIZ
Dim CveProveedorSucursal As Integer = IIf(objOC.CveProveedorSucursal.ToEntero = -1, 0, objOC.CveProveedorSucursal.ToEntero).ToString.ToEntero
@@ -1330,7 +1335,12 @@ Partial Class OC
lblFolio.Text = "REQ " + objOC.Folio.ToString
lblTipoPadreHijo.Text = "OC"
ChkCotizacion.Visible = True
DdlProveedores.SelectedValueExist(objOC.CveProveedor.ToString)
DdlProveedores.SelectedValue = objOC.CveProveedor.ToString
If DdlProveedores.SelectedValue.ToEntero > 0 Then
DdlProveedores.SelectedText = GlobalDTCompProveedores(UsuarioActual.CveEmpresa).FiltraParametros($"CveProveedor = {objOC.CveProveedor}").Rows(0)("RazonSocial").ToString
Else
DdlProveedores.SelectedText = "-"
End If
If objOC.CveProveedorSucursal.ToEntero > 0 Then
DivProveedorSucursal.Visible = True
@@ -1494,14 +1504,14 @@ Partial Class OC
'Permisos, para cambiar el proveedor en una OC
If objOC.Tipo.ToUpper = "OC" AndAlso UsuarioActual.TienePermisoProceso(111) Then
DdlProveedores.Enabled = True
DdlProveedores.SelectedValueExist(objOC.CveProveedor.ToString)
DdlProveedores.ddl.SelectedValueExist(objOC.CveProveedor.ToString)
DdlIVA.Enabled = True
ImgCambiaProv.Visible = True
UPProv.Update()
End If
If DdlProveedores.SelectedValue <> objOC.CveProveedor.ToString Then
DdlProveedores.Items.Insert(1, New ListItem(GlobalDTCompProveedores(CveEmpresaActual).FiltroPrimeroValor("RazonSocial", $"CveProveedor = {objOC.CveProveedor}"), objOC.CveProveedor.ToString))
'DdlProveedores.Items.Insert(1, New ListItem(GlobalDTCompProveedores(CveEmpresaActual).FiltroPrimeroValor("RazonSocial", $"CveProveedor = {objOC.CveProveedor}"), objOC.CveProveedor.ToString))
End If
CargaCotizaciones(CveOrdenCompra)
@@ -1741,13 +1751,25 @@ Partial Class OC
CboUnidadMedida.DataBind()
End Sub
Private Sub CargaProveedores()
DdlProveedores.DataSource = GlobalDTCompProveedores(CveEmpresaActual)
DdlProveedores.DataBind()
DdlProveedores.Items.Insert(0, New ListItem("Seleccione", "-1"))
If UsuarioActual.Empresa.Funcionalidad(105) = "1" Then
DdlProveedores.setEsWebService(True)
DdlProveedores.Attributes.Add("data-metodo", "getproveedores")
DdlProveedores.SelectedText = "Seleccione"
DdlProveedores.SelectedValue = "-1"
DdlProveedorCot.setEsWebService(True)
DdlProveedorCot.Attributes.Add("data-metodo", "getproveedores")
Else
DdlProveedores.DataSource = GlobalDTCompProveedores(CveEmpresaActual)
DdlProveedores.DataBind()
DdlProveedores.ddl.Items.Insert(0, New ListItem("Seleccione", "-1"))
DdlProveedorCot.DataSource = GlobalDTCompProveedores(CveEmpresaActual)
DdlProveedorCot.DataBind()
DdlProveedorCot.ddl.Items.Insert(0, New ListItem("Seleccione", "-1"))
End If
DdlProveedorCot.DataSource = GlobalDTCompProveedores(CveEmpresaActual)
DdlProveedorCot.DataBind()
DdlProveedorCot.Items.Insert(0, New ListItem("Seleccione", "-1"))
UPProv.Update() : UPPEmp.Update()
End Sub
@@ -1755,7 +1777,7 @@ Partial Class OC
Private Sub CargaProveedorSucursal()
DdlProveedores.DataSource = GlobalDTCompProveedores(CveEmpresaActual)
DdlProveedores.DataBind()
DdlProveedores.Items.Insert(0, New ListItem("Seleccione", "-1"))
'DdlProveedores.Items.Insert(0, New ListItem("Seleccione", "-1"))
UPProv.Update() : UPPEmp.Update()
End Sub
Private Sub CargaEstatusOC()
@@ -2098,6 +2120,8 @@ Partial Class OC
Return True
End If
'SI ES REQUISICION, NO REQUIERE COTIZACION Y ES ESTATUSFINALOK... ENTONCES DEBE DE TENER UN PROVEEDOR SELECCIONADO Y LOS PRECIOS CAPTURADOS
'If (TipoOC = "REQ" And ChkCotizacion.Checked = False And CboE.SelectedValue.ToEntero = CveEstatusFinalOK) OrElse TipoOC = "OC" Then
' If Not UsuarioActual.TienePermisoProceso(179) Then 'PERMISO PARA GENERAR CON O
@@ -2215,6 +2239,13 @@ Partial Class OC
TieneError = True
End If
'Valida que tenga proveedore
If (EsNuevo = True AndAlso TipoOC.ToUpper = "OC"4) AndAlso DdlProveedores.SelectedValue.ToEntero() <= 0 Then
Alert("Debe seleccionar un proveedor.", TipoMensaje.MsgAdvertencia)
TieneError = True
End If
'VALIDA QUE ANTES DE QUE PUEDA MANDARLA A SUPERVISADA SE TIENE QUE SELECCIONAR UN PROVEEDOR
If UsuarioActual.Empresa.Funcionalidad(565) = "1" Then
If (TipoOC.ToUpper = "REQ" And CboE.SelectedValue.ToEntero.Contiene(CveEstatusSupervisada, CveEstatusFinalOK)) AndAlso DdlProveedores.SelectedValue.ToEntero() <= 0 Then
@@ -2614,7 +2645,7 @@ Partial Class OC
If Not TieneError Then
Fecha = Now
CveProveedor = DdlProveedores.SelectedValue.ToEntero
ProveedorNombre = DdlProveedores.SelectedItem.Text
ProveedorNombre = DdlProveedores.SelectedText
SerieFolio = $"OC: {Folio}"
If DtInvOCDiferencias.FiltraParametros("ConceptoSalida IN (0,1) AND Diferencia <> 0 ").Rows.Count > 0 Then
@@ -4724,7 +4755,7 @@ Partial Class OC
ChkEventoPrioridad.Checked = False
RegistraScript("$('#ModalBitacora').modal('hide')", "hidemodal")
CargaEventoBitacoraTemp()
CargaEventoBitacoraTemp()
End Sub
@@ -4880,7 +4911,7 @@ Partial Class OC
Dim DtPara As DataTable = GlobalDTUsuarios(DdlSAUsuario.SelectedValue.ToString.ToEntero, CveEmpresaActual)
Param.Add(DtPara.Rows(0)("Correo").ToString()) 'Para
Param.Add("Solicitud de anticipo de Orden de Compra") 'Asunto
Param.Add(GeneraCorreoAnticipo(lblFolio.Text, DtPara.Rows(0)("Nombre").ToString(), String.Format("http://sig.adssistemas.mx/OI/EventoDetalle.aspx?CveTipoEvento=1&CveEvento={0}", CveEvento), TxtSAImporte.Text, DdlProveedores.SelectedItem.Text))
Param.Add(GeneraCorreoAnticipo(lblFolio.Text, DtPara.Rows(0)("Nombre").ToString(), String.Format("http://sig.adssistemas.mx/OI/EventoDetalle.aspx?CveTipoEvento=1&CveEvento={0}", CveEvento), TxtSAImporte.Text, DdlProveedores.SelectedText))
Param.Add(String.Format("{0}PDF\OC-{1}.pdf", UsuarioActual.Empresa.Ruta, CveOrdenCompra))
Dim Hilo As New Threading.Thread(AddressOf MandaCorreoAnticipo)
Hilo.Start(Param)
@@ -4894,7 +4925,7 @@ Partial Class OC
Dim DtPara As DataTable = GlobalDTUsuarios(Dr("CveUsuarioPara").ToString.ToEntero, CveEmpresaActual)
Param.Add(DtPara.Rows(0)("Correo").ToString()) 'Para
Param.Add("Solicitud de anticipo de Orden de Compra Cancelada") 'Asunto
Param.Add(GeneraCorreoAnticipo(lblFolio.Text, DtPara.Rows(0)("Nombre").ToString(), String.Format("http://sig.s/OI/EventoDetalle.aspx?CveTipoEvento=1&CveEvento={0}", Dr("CveEvento").ToString.ToEntero), "", DdlProveedores.SelectedItem.Text))
Param.Add(GeneraCorreoAnticipo(lblFolio.Text, DtPara.Rows(0)("Nombre").ToString(), String.Format("http://sig.s/OI/EventoDetalle.aspx?CveTipoEvento=1&CveEvento={0}", Dr("CveEvento").ToString.ToEntero), "", DdlProveedores.SelectedText))
Param.Add(String.Format("{0}PDF\OC-{1}.pdf", UsuarioActual.Empresa.Ruta, CveOrdenCompra))
Dim Hilo As New Threading.Thread(AddressOf MandaCorreoAnticipo)
Hilo.Start(Param)
@@ -5118,7 +5149,7 @@ Partial Class OC
Return CveEmpresaActual = 66
End Function
Protected Sub DdlProveedores_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlProveedores.SelectedIndexChanged
Protected Sub DdlProveedores_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlProveedores.selectedindexchange
Dim Objeto As New ClsCompProveedores
DdlProveedorSucursal.Items.Clear()
@@ -5191,7 +5222,7 @@ Partial Class OC
PnlUsuarioAsignado.Visible = False
RVProveedores.Enabled = False
'RVProveedores.Enabled = False
'Si NO requiere cotizacion y el estatus siguiente es el final,
If TipoOC.ToUpper = "REQ" Then
@@ -5203,7 +5234,7 @@ Partial Class OC
If ChkCotizacion.Checked = False AndAlso CboE.SelectedValue.ToEntero.Contiene(CveEstatusFinalOK) AndAlso TipoOS = False Then
BtnGuardar.Text = "Guardar y Generar OC" : uppOpciones.Update()
RVProveedores.Enabled = True
'RVProveedores.Enabled = True
If CveEmpresaActual.Contiene(13, 83, 72) Then
PnlUsuarioAsignado.Visible = True
@@ -5228,7 +5259,7 @@ Partial Class OC
If CveEstatus <> CveEstatusFinalError Then RegistraScript("$get('divCE').style.display='';PosicionaObjeto('C_CboE','divCE'); ")
End If
Else
RVProveedores.Enabled = True
'RVProveedores.Enabled = True
End If
@@ -6392,7 +6423,7 @@ Partial Class OC
Dim CveProveedorPrevio As String = DdlProveedores.SelectedValue
Dim CveProveedorSucursalPrevio As String = DdlProveedorSucursal.SelectedValue
CargaProveedores()
DdlProveedores.SelectedValueExist(CveProveedorPrevio)
DdlProveedores.ddl.SelectedValueExist(CveProveedorPrevio)
DdlProveedores_SelectedIndexChanged(DdlProveedores, EventArgs.Empty)
If DdlProveedorSucursal.Visible Then
DdlProveedorSucursal.SelectedValueExist(CveProveedorSucursalPrevio)

View File

@@ -119,7 +119,7 @@ Partial Class CatSubProyectos
Public Sub CargaDatos()
Dim ObjSub As New ClsSubProyectos
If ObjSub.GetSubProyectos() Then
If ObjSub.GetSubProyectos(UsuarioActual.CveEmpresa) Then
GvDatos.DataSource = ObjSub.DtResultados.FiltraParametros($"CveEmpresa = {UsuarioActual.CveEmpresa}")
GvDatos.DataBind()
End If
@@ -204,7 +204,7 @@ Partial Class CatSubProyectos
If ObjSubProyectos.RemoveSubProyecto(GvDatos.DataKeys(e.RowIndex).Value.ToString.ToEntero) Then
GvDatos.EditIndex = -1
ViewState("DTSubProyectos") = ObjSubProyectos.DtResultados.FiltraParametros("CveEmpresa = " & UsuarioActual.CveEmpresa)
GlobalDTSubProyectos(-1) = ObjSubProyectos.DtResultados
GlobalDTSubProyectos(UsuarioActual.CveEmpresa) = ObjSubProyectos.DtResultados
Alert("El SubProyecto se eliminó correctamente.", TipoMensaje.MsgInformacion)
End If
@@ -232,7 +232,7 @@ Partial Class CatSubProyectos
If ObjSubProyectos.UpdateSubProyectoSegNeg(CveSubProyecto, CveSegmento, UsuarioActual.CveEmpresa) Then
GvDatos.EditIndex = -1
ViewState("DTSubProyectos") = ObjSubProyectos.DtResultados.FiltraParametros("CveEmpresa = " & UsuarioActual.CveEmpresa)
GlobalDTSubProyectos(-1) = ObjSubProyectos.DtResultados
GlobalDTSubProyectos(UsuarioActual.CveEmpresa) = ObjSubProyectos.DtResultados
Alert("Los cambios se guardaron correctamente.", TipoMensaje.MsgInformacion)
Else
ErrorSubProyecto = True

View File

@@ -655,14 +655,14 @@ function AbrirVentana(Pagina, Ancho, Alto, tmp, Titulo) {
if (!(Alto)) { Alto = '601'; }
$('#ajaxidmodal #myFrame').css({ width: Ancho, height: Alto });
$('#ajaxidmodal ').css({ width: Ancho, height: Alto });
$('#ajaxidmodal #myFrame').load(function() {
$('#ajaxidmodal').removeClass("hidden");
$("#ajax").modal();
$("#ajax").modal();
$('#ajaxidmodal').removeClass("hidden");
$("#ajaxidmodal #myFrame").unbind("load");
$('#ajaxidmodal #myFrame').load(function () {
Metronic.unblockUI();
});
$('#ajaxidmodal #myFrame').prop('src', Pagina);
$("#ajax").modal();
return false;
//$("#ajax").modal();
}
function CerrarVentana() {

View File

@@ -89,7 +89,6 @@ Partial Class CatClasificaciones
CargaDdlSATPS()
CargaDDLs()
CargaGlobal()
DdlCategoriaFiltro.DataSource = GlobalDTGralCategorias(UsuarioActual.CveEmpresa)
DdlCategoriaFiltro.Items.Insert(0, New ListItem("Todos", "-1"))
@@ -152,20 +151,20 @@ Partial Class CatClasificaciones
CargaGrid()
End Sub
Public Sub CargaGlobal()
'Public Sub CargaGlobal()
Dim ObjClasificaciones As New ClsClasificaciones
' Dim ObjClasificaciones As New ClsClasificaciones
If ObjClasificaciones.GetClasificaciones() Then
ViewState("DTClasificaciones") = ObjClasificaciones.DtResultados.FiltraParametros($"(Codigo IS NULL OR Codigo = '') AND CveEmpresa = {UsuarioActual.CveEmpresa} AND (CveCategoria = {DdlCategoriaFiltro.SelectedValue.ToEntero} OR {DdlCategoriaFiltro.SelectedValue.ToEntero} = -1) AND (UsoClasificacion = {DdlTipoClasificacion.SelectedValue.ToEntero} OR {DdlTipoClasificacion.SelectedValue.ToEntero} = -1 ) AND (Estado = {DdlEstatus.SelectedValue.ToEntero} OR {DdlEstatus.SelectedValue.ToEntero} = -1)")
GlobalDTClasificaciones = ObjClasificaciones.DtResultados
Else
Me.GvDatos.DataSource = Nothing
Alert("Ocurrió un error al cargar las clasificaciones. Por favor vuelva a intentar.", TipoMensaje.MsgError)
End If
' If ObjClasificaciones.GetClasificaciones(UsuarioActual.CveEmpresa) Then
' ViewState("DTClasificaciones") = ObjClasificaciones.DtResultados.FiltraParametros($"(Codigo IS NULL OR Codigo = '') AND CveEmpresa = {UsuarioActual.CveEmpresa} AND (CveCategoria = {DdlCategoriaFiltro.SelectedValue.ToEntero} OR {DdlCategoriaFiltro.SelectedValue.ToEntero} = -1) AND (UsoClasificacion = {DdlTipoClasificacion.SelectedValue.ToEntero} OR {DdlTipoClasificacion.SelectedValue.ToEntero} = -1 ) AND (Estado = {DdlEstatus.SelectedValue.ToEntero} OR {DdlEstatus.SelectedValue.ToEntero} = -1)")
' GlobalDTClasificaciones(UsuarioActual.CveEmpresa) = Nothing
' Else
' Me.GvDatos.DataSource = Nothing
' Alert("Ocurrió un error al cargar las clasificaciones. Por favor vuelva a intentar.", TipoMensaje.MsgError)
' End If
ObjClasificaciones.Dispose()
End Sub
' ObjClasificaciones.Dispose()
'End Sub
Protected Sub LbAgregar_Click(sender As Object, e As System.EventArgs) Handles LbAgregar.Click
@@ -212,7 +211,7 @@ Partial Class CatClasificaciones
End If
End If
CargaGlobal()
GlobalDTClasificaciones(UsuarioActual.CveEmpresa) = Nothing
ObjClasificaciones.Dispose()
CargaDatos()
@@ -317,6 +316,7 @@ Partial Class CatClasificaciones
If ObjClasificaciones.RemoveClasificacion(GvDatos.DataKeys(e.RowIndex).Value.ToString.ToEntero) Then
GvDatos.EditIndex = -1
ViewState("DTClasificaciones") = ObjClasificaciones.DtResultados.FiltraParametros("CveEmpresa = " & UsuarioActual.CveEmpresa)
GlobalDTClasificaciones(UsuarioActual.CveEmpresa) = Nothing
Alert("La Clasificación se eliminó correctamente.", TipoMensaje.MsgInformacion)
Else
Alert("Ocurrió un error al eliminar la clasificación. Por favor vuelva a intentar.", TipoMensaje.MsgError)
@@ -324,7 +324,7 @@ Partial Class CatClasificaciones
ObjClasificaciones.Dispose()
CargaGrid()
CargaGlobal()
End Sub
#End Region
@@ -348,7 +348,9 @@ Partial Class CatClasificaciones
TxtClasificacion.Text = ""
TxtPrecioBaseCosto.Text = ""
DdlCategoria.SelectedIndex = 0
If DdlCategoria.Items.Count > 0 Then
DdlCategoria.SelectedIndex = 0
End If
DdlSATPS.SelectedValue = ""
DdlSATPS.SelectedText = ""
LtlTituloModal.Text = "Agregar Clasificación"

View File

@@ -137,11 +137,12 @@ Partial Class Ventas_CatVendedores
#Region "CARGA GLOBAL"
Private Sub CargaGlobal()
Dim ObjVendedores As New ClsVtaVendedores
If ObjVendedores.GetVendedores(-1) Then
GlobalDTVendedores(-1) = ObjVendedores.DtResultados
End If
ObjVendedores.Dispose()
GlobalDTVendedores(UsuarioActual.CveEmpresa) = Nothing
'Dim ObjVendedores As New ClsVtaVendedores
'If ObjVendedores.GetVendedores(UsuarioActual.CveEmpresa) Then
' GlobalDTVendedores(-1) = ObjVendedores.DtResultados
'End If
'ObjVendedores.Dispose()
End Sub
#End Region

View File

@@ -271,10 +271,10 @@
</ContentTemplate>
</asp:UpdatePanel>
<asp:UpdatePanel runat="server" ID="UPUsadosReset" RenderMode="Inline" UpdateMode="Conditional" Visible="false">
<asp:UpdatePanel runat="server" ID="UPUsadosReset" RenderMode="Inline" UpdateMode="Conditional" Visible="false">
<ContentTemplate>
<li>
<asp:LinkButton ID="LnkUsadosReset" data-toggle="confirmation" data-popout="true" data-original-title="Confirmar" data-btn-ok-label="si" data-placement="left" title="Inicializar Usados" runat="server" Text="<i class='fa fa-pencil'></i> Inicializar Usados"></asp:LinkButton>
<asp:LinkButton ID="LnkUsadosReset" data-toggle="confirmation" data-popout="true" data-original-title="Confirmar" data-btn-ok-label="si" data-placement="left" title="Inicializar Usados" runat="server" Text="<i class='fa fa-pencil'></i> Inicializar Usados"></asp:LinkButton>
</li>
</ContentTemplate>
</asp:UpdatePanel>
@@ -594,7 +594,7 @@
</div>
<div class="form-group form-md-line-input input-iconright" runat="server" id="DivCargoUsado" visible="false">
<label>Cargo Usado:</label>
<asp:CheckBox ID="ChkCargoUsado" runat="server" CssClass="make-switchsd" data-size="small" Text="" ClientIDMode="Static" Enabled="true" />
<asp:CheckBox ID="ChkCargoUsado" runat="server" CssClass="make-switchsd" data-size="small" Text="" ClientIDMode="Static" Enabled="true" />
</div>
<div class="form-group form-md-line-input input-iconright" runat="server" id="DivBonificacionUsado" visible="false">
<label>Bonificación Usado:</label>
@@ -732,6 +732,7 @@
<asp:TemplateField>
<HeaderTemplate>
Sucursal/Depto
</HeaderTemplate>
<ItemTemplate>
<div class="truncate" style="width: 200px;">
@@ -742,6 +743,7 @@
<asp:TemplateField>
<HeaderTemplate>
Contacto
</HeaderTemplate>
<ItemTemplate>
<div class="truncate" style="width: 100px;">
@@ -752,6 +754,7 @@
<asp:TemplateField>
<HeaderTemplate>
Ciudad
</HeaderTemplate>
<ItemTemplate>
<div class="truncate" style="width: 90px;">
@@ -773,6 +776,7 @@
</asp:GridView>
<div>
Condiciones Entrega:
<asp:DropDownList ID="DdlCondicionesEntrega" runat="server" DataValueField="CveCondicionEntrega" DataTextField="CondicionEntrega" Width="200px"></asp:DropDownList>
</div>
</div>
@@ -832,29 +836,44 @@
<asp:RequiredFieldValidator ID="RFVMetodoPago" runat="server" ControlToValidate="DdlMetodoPago" CssClass="help-block" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Método de Pago''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<i></i>
</div>
<div class="row" id="DivRetenciones" runat="server">
<div class="col-md-6">
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtRetIVA" CssClass="form-control" runat="server" MaxLength="9" Text="0"></asp:TextBox>
<asp:RequiredFieldValidator ID="RFVRetIVA" class="help-block errorimput" runat="server" ControlToValidate="TxtRetIVA" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Retención de IVA''</b> es necesario, por favor ingréselo." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CVRetIVA" class="help-block errorimput" runat="server" ControlToValidate="TxtRetIVA" ErrorMessage="El campo <b>''Retención de IVA''</b> no tiene el formato correcto, por favor corrija e intente de nuevo (Solo formato numérico)." Operator="DataTypeCheck" Type="Double" ValidationGroup="GrpGuardar"></asp:CompareValidator>
<label for="<%= TxtRetIVA.ClientID.ToString()%>">¿El Cliente nos retiene IVA?: </label>
<i style="font-weight: bold;">%</i>
</div>
<div id="DivRetenciones" runat="server">
<div id="DivTipoRetenciones" runat="server" visible="false" class="form-group form-md-line-input input-iconright">
<asp:DropDownList ID="DdlTipoRetencion" CssClass="form-control select2me" runat="server" AppendDataBoundItems="true" CausesValidation="true" DataTextField="MetodoPago" DataValueField="CveMetodoPago" ValidationGroup="GrpGuardar">
<asp:ListItem Selected="True" Text="Sin Retención" Value="0"></asp:ListItem>
<asp:ListItem Text="Arrendamiento" Value="1"></asp:ListItem>
<asp:ListItem Text="Servicios Profesionales" Value="2"></asp:ListItem>
<asp:ListItem Text="Fletes" Value="3"></asp:ListItem>
<asp:ListItem Text="Servicios" Value="4"></asp:ListItem>
</asp:DropDownList>
<label for="<%= DdlTipoRetencion.ClientID.ToString()%>">Tipo de Retención:</label>
<asp:RequiredFieldValidator ID="RFVTipoRetencion" runat="server" ControlToValidate="DdlTipoRetencion" CssClass="help-block" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Tipo de Retención''</b> es necesario, por favor seleccione uno." InitialValue="-1" ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<i></i>
</div>
<div class="col-md-6">
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtRetISR" CssClass="form-control" runat="server" MaxLength="9" Text="0"></asp:TextBox>
<asp:RequiredFieldValidator ID="RFVRetISR" runat="server" class="help-block errorimput" ControlToValidate="TxtRetISR" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Retención ISR''</b> es necesario, por favor ingréselo." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CVRetISR" runat="server" class="help-block errorimput" ControlToValidate="TxtRetISR" ErrorMessage="El campo <b>''Retención ISR''</b> no tiene el formato correcto, por favor corrija e intente de nuevo (Solo formato numérico)." Operator="DataTypeCheck" Type="Double" ValidationGroup="GrpGuardar"></asp:CompareValidator>
<label for="<%= TxtRetISR.ClientID.ToString()%>">¿El Cliente nos retiene ISR?: </label>
<i style="font-weight: bold;">%</i>
<div class="row">
<div class="col-md-6">
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtRetIVA" CssClass="form-control" runat="server" MaxLength="9" Text="0"></asp:TextBox>
<asp:RequiredFieldValidator ID="RFVRetIVA" class="help-block errorimput" runat="server" ControlToValidate="TxtRetIVA" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Retención de IVA''</b> es necesario, por favor ingréselo." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CVRetIVA" class="help-block errorimput" runat="server" ControlToValidate="TxtRetIVA" ErrorMessage="El campo <b>''Retención de IVA''</b> no tiene el formato correcto, por favor corrija e intente de nuevo (Solo formato numérico)." Operator="DataTypeCheck" Type="Double" ValidationGroup="GrpGuardar"></asp:CompareValidator>
<label for="<%= TxtRetIVA.ClientID.ToString()%>">¿El Cliente nos retiene IVA?: </label>
<i style="font-weight: bold;">%</i>
</div>
</div>
<div class="col-md-6">
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtRetISR" CssClass="form-control" runat="server" MaxLength="9" Text="0"></asp:TextBox>
<asp:RequiredFieldValidator ID="RFVRetISR" runat="server" class="help-block errorimput" ControlToValidate="TxtRetISR" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Retención ISR''</b> es necesario, por favor ingréselo." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CVRetISR" runat="server" class="help-block errorimput" ControlToValidate="TxtRetISR" ErrorMessage="El campo <b>''Retención ISR''</b> no tiene el formato correcto, por favor corrija e intente de nuevo (Solo formato numérico)." Operator="DataTypeCheck" Type="Double" ValidationGroup="GrpGuardar"></asp:CompareValidator>
<label for="<%= TxtRetISR.ClientID.ToString()%>">¿El Cliente nos retiene ISR?: </label>
<i style="font-weight: bold;">%</i>
</div>
</div>
</div>
</div>
<div class="form-group form-md-line-input" id="DivRetFletes" runat="server" visible="false">
¿El Cliente nos retiene IVA por Fletes y Acarreos?:
<asp:CheckBox ID="ChkRetIVAFletesAcarreos" CssClass="make-switchsd" runat="server" />
<asp:CheckBox ID="ChkRetIVAFletesAcarreos" CssClass="make-switchsd" runat="server" />
</div>
<br />
<br />
@@ -888,7 +907,8 @@
<div class="form-group form-md-line-input" id="DivDesglosaIEPS" runat="server">
El cliente desglosa IEPS:
<asp:CheckBox ID="ChkDesglosarIEPS" Checked="true" CssClass="make-switchsd" runat="server" />
<asp:CheckBox ID="ChkDesglosarIEPS" Checked="true" CssClass="make-switchsd" runat="server" />
</div>
<br />
@@ -1059,6 +1079,7 @@
<div class="row">
<div class="col-md-6">
Cantidad de Ventas:
</div>
<div class="col-md-6">
@@ -1068,6 +1089,7 @@
<div class="row">
<div class="col-md-6">
Total Vendido:
</div>
<div class="col-md-6">
@@ -1078,6 +1100,7 @@
<div class="row">
<div class="col-md-6">
Venta Mínima:
</div>
<div class="col-md-6">
<asp:Literal ID="LtlMinima" runat="server"></asp:Literal>
@@ -1086,6 +1109,7 @@
<div class="row">
<div class="col-md-6">
Promedio de Ventas:
</div>
<div class="col-md-6">
<asp:Literal ID="LtlPromedio" runat="server"></asp:Literal>
@@ -1094,6 +1118,7 @@
<div class="row">
<div class="col-md-6">
Venta Máxima:
</div>
<div class="col-md-6">
@@ -1231,6 +1256,7 @@
<div class="row">
<div class="col-md-9">
Cantidad de Cotizaciones:
</div>
<div class="col-md-3 ">
<asp:Literal ID="LtlCantidadCotizaciones" runat="server"></asp:Literal>
@@ -1239,9 +1265,11 @@
<div class="row">
<div class="col-md-9">
Factor de Cotizaciones VS Ventas:
</div>
<div class="col-md-3 ">
<asp:Literal ID="LtlFactorCotVentas" runat="server"></asp:Literal>&nbsp;%
</div>
</div>
</div>
@@ -1269,7 +1297,7 @@
<div class="actions">
<div class="btn-group">
<asp:UpdatePanel UpdateMode="Conditional" runat="server" ID="UpRepProveedoresPagosBancos" >
<asp:UpdatePanel UpdateMode="Conditional" runat="server" ID="UpRepProveedoresPagosBancos">
<ContentTemplate>
<asp:LinkButton ID="LnkCotizacionesPDF" runat="server" data-toggle="tooltip" Title="PDF"> <i class="fa fa-file-pdf-o" style="margin-right: 10px; font-size:15px; font-weight:bold; color:dimgray;"></i> </asp:LinkButton>
<asp:LinkButton ID="LnkCotizacionesExcel" runat="server" data-toggle="tooltip" Title="Excel"><i class="fa fa-file-excel-o" style="margin-right: 10px; font-size:15px; font-weight:bold; color:dimgray;"></i> </asp:LinkButton>
@@ -1418,19 +1446,31 @@
<asp:Label ID="LblDiasPago" runat="server" Text="Dias de pago:"></asp:Label>
<br />
<label><b>L</b></label>&nbsp;&nbsp;
<label><b>M</b></label>&nbsp;&nbsp;&nbsp;
<label><b>MI</b></label>&nbsp;&nbsp;
<label><b>J</b></label>&nbsp;&nbsp;
<label><b>V</b></label>&nbsp;&nbsp;
<label><b>S</b></label>&nbsp;&nbsp;
<br />
<asp:CheckBox ID="ChkLunes" runat="server" />&nbsp;
<asp:CheckBox ID="ChkMartes" runat="server" />&nbsp;
<asp:CheckBox ID="ChkMiercoles" runat="server" />&nbsp;
<asp:CheckBox ID="ChkJueves" runat="server" />&nbsp;
<asp:CheckBox ID="ChkViernes" runat="server" />&nbsp;
<asp:CheckBox ID="ChkSabado" runat="server" />&nbsp;
</div>
</div>
@@ -1464,19 +1504,31 @@
<asp:Label ID="LblDiasRevision" runat="server" Text="Dias de Revisión:"></asp:Label>
<br />
<label><b>L</b></label>&nbsp;&nbsp;
<label><b>M</b></label>&nbsp;&nbsp;&nbsp;
<label><b>MI</b></label>&nbsp;&nbsp;
<label><b>J</b></label>&nbsp;&nbsp;
<label><b>V</b></label>&nbsp;&nbsp;
<label><b>S</b></label>&nbsp;&nbsp;
<br />
<asp:CheckBox ID="ChkRevLunes" runat="server" />&nbsp;
<asp:CheckBox ID="ChkRevMartes" runat="server" />&nbsp;
<asp:CheckBox ID="ChkRevMiercoles" runat="server" />&nbsp;
<asp:CheckBox ID="ChkRevJueves" runat="server" />&nbsp;
<asp:CheckBox ID="ChkRevViernes" runat="server" />&nbsp;
<asp:CheckBox ID="ChkRevSabado" runat="server" />&nbsp;
</div>
</div>
</div>
@@ -1783,6 +1835,7 @@
<div class="row">
<div class="pull-right">
<asp:HyperLink ID="HplAbonarMasivo" Visible="True" runat="server" NavigateUrl="#" ToolTip="Pago de múltiples facturas">Pago múltiples facturas&nbsp;<img src="/Imagenes/Money_Add.png" alt="Pagar múltiples facturas" /></asp:HyperLink>&nbsp; &nbsp;&nbsp;&nbsp
</div>
</div>
<asp:GridView ID="GvCxC" runat="server" AutoGenerateColumns="False" EmptyDataText="No se encontraron Cuentas X Cobrar Pendientes" ToolTip="Listado de CxC"
@@ -1801,16 +1854,19 @@
<asp:TemplateField HeaderText="Monto Venta" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Literal ID="LtlSaldoOriginal" runat="server" Text='<%# Eval("Original", "{0:N2}") %>'></asp:Literal>&nbsp;
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Abonado" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Literal ID="LtlAbonado" runat="server" Text='<%# Eval("Abonado", "{0:N2}")%>'></asp:Literal>&nbsp;
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Saldo" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Literal ID="LtlSaldo" runat="server" Text='<%# Eval("Saldo", "{0:N2}") %>'></asp:Literal>&nbsp;
</ItemTemplate>
</asp:TemplateField>
<asp:BoundField HeaderText="Estatus" DataField="CobranzaEstatus" />
@@ -1888,16 +1944,19 @@
<asp:TemplateField HeaderText="Monto Venta (Saldo Orig)" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Literal ID="LtlSaldoOriginal" runat="server" Text='<%# Eval("Original", "{0:N2}") %>'></asp:Literal>&nbsp;
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Abonado" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Literal ID="LtlAbonado" runat="server" Text='<%# Eval("Abonado", "{0:N2}") %>'></asp:Literal>&nbsp;
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Saldo" ItemStyle-HorizontalAlign="Right">
<ItemTemplate>
<asp:Literal ID="LtlSaldo" runat="server" Text='<%# Eval("Saldo", "{0:N2}") %>'></asp:Literal>&nbsp;
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Auxiliar" ItemStyle-HorizontalAlign="Center">
@@ -2219,6 +2278,7 @@
<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>&nbsp;
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Abonado" ItemStyle-HorizontalAlign="Right">
@@ -2851,37 +2911,39 @@
<div class="row">
<div class="col-md-4">
Fecha Inicial:
<div class="input-group input-small date date-picker" data-date-format="dd/mm/yyyy">
<asp:TextBox ID="txtFechaI" runat="server" CssClass="form-control"></asp:TextBox>
<span class="input-group-btn ">
<button runat="server" id="imgCalendario" class="btn default" type="button">
<i class="fa fa-calendar"></i>
</button>
</span>
<ajax:MaskedEditExtender ID="MEEFechaI" runat="server" TargetControlID="txtFechaI" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="Calendario" TargetControlID="txtFechaI" PopupButtonID="ImgCalendario" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
<asp:RequiredFieldValidator ID="rfvFechaI" runat="server" ControlToValidate="txtFechaI" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrpConsultarAsistencia"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="cvFechaI" runat="server" ControlToValidate="txtFechaI" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrpConsultarAsistencia"></asp:CompareValidator>
<ajax:ValidatorCalloutExtender ID="vcoFfvFI" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaI" Width="350px"></ajax:ValidatorCalloutExtender>
<ajax:ValidatorCalloutExtender ID="vcoCvFI" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaI" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
<div class="input-group input-small date date-picker" data-date-format="dd/mm/yyyy">
<asp:TextBox ID="txtFechaI" runat="server" CssClass="form-control"></asp:TextBox>
<span class="input-group-btn ">
<button runat="server" id="imgCalendario" class="btn default" type="button">
<i class="fa fa-calendar"></i>
</button>
</span>
<ajax:MaskedEditExtender ID="MEEFechaI" runat="server" TargetControlID="txtFechaI" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="Calendario" TargetControlID="txtFechaI" PopupButtonID="ImgCalendario" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
<asp:RequiredFieldValidator ID="rfvFechaI" runat="server" ControlToValidate="txtFechaI" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrpConsultarAsistencia"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="cvFechaI" runat="server" ControlToValidate="txtFechaI" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrpConsultarAsistencia"></asp:CompareValidator>
<ajax:ValidatorCalloutExtender ID="vcoFfvFI" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaI" Width="350px"></ajax:ValidatorCalloutExtender>
<ajax:ValidatorCalloutExtender ID="vcoCvFI" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaI" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
</div>
<div class="col-md-4">
Fecha Final:
<div class="input-group input-small date date-picker" data-date-format="dd/mm/yyyy">
<asp:TextBox ID="txtFechaF" CssClass="form-control" runat="server"></asp:TextBox>
<span class="input-group-btn ">
<button runat="server" id="imgCalendarioF" class="btn default" type="button">
<i class="fa fa-calendar"></i>
</button>
</span>
<ajax:MaskedEditExtender ID="MEEFechaF" runat="server" TargetControlID="txtFechaF" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="Calendario2" TargetControlID="txtFechaF" PopupButtonID="imgCalendarioF" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
<asp:RequiredFieldValidator ID="rfvFechaF" runat="server" ControlToValidate="txtFechaF" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrpConsultarAsistencia"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="cvFechaF" runat="server" ControlToValidate="txtFechaF" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrpConsultarAsistencia"></asp:CompareValidator>
<ajax:ValidatorCalloutExtender ID="vcoRfvFF" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
<ajax:ValidatorCalloutExtender ID="vcoCvFF" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
<div class="input-group input-small date date-picker" data-date-format="dd/mm/yyyy">
<asp:TextBox ID="txtFechaF" CssClass="form-control" runat="server"></asp:TextBox>
<span class="input-group-btn ">
<button runat="server" id="imgCalendarioF" class="btn default" type="button">
<i class="fa fa-calendar"></i>
</button>
</span>
<ajax:MaskedEditExtender ID="MEEFechaF" runat="server" TargetControlID="txtFechaF" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="Calendario2" TargetControlID="txtFechaF" PopupButtonID="imgCalendarioF" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
<asp:RequiredFieldValidator ID="rfvFechaF" runat="server" ControlToValidate="txtFechaF" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="GrpConsultarAsistencia"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="cvFechaF" runat="server" ControlToValidate="txtFechaF" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GrpConsultarAsistencia"></asp:CompareValidator>
<ajax:ValidatorCalloutExtender ID="vcoRfvFF" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
<ajax:ValidatorCalloutExtender ID="vcoCvFF" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
</div>
<div class="col-md-2">
<asp:Button ID="BtnConsultarAsistencia" runat="server" Text="Consultar" ValidationGroup="GrpConsultarAsistencia" class="btn btn-primary" />
@@ -3194,14 +3256,17 @@
<div class="portlet-body">
<div class="form-group">
Estado:
<asp:CheckBox ID="ChkEstado" runat="server" CssClass="make-switchsd" data-size="small" />
</div>
<div class="form-group">
Fecha de Captura:
<asp:Label ID="LblFechaCaptura" runat="server"></asp:Label>
</div>
<div class="form-group">
Usuario Capturó:
<asp:Label ID="LblUsuarioCapturo" runat="server"></asp:Label>
</div>
</div>
@@ -3227,21 +3292,25 @@
<div class="col-md-6">
<div class="form-group">
Usuario Activo:
<asp:Label ID="LblUsuarioActivo" runat="server" Text="No"></asp:Label>
<asp:HiddenField ID="HdnCveUsuarioPortalAdmin" runat="server" />
<asp:HiddenField ID="HdnCveUsuarioPortalActivado" Value="0" runat="server" />
</div>
Usuario:
<asp:Label ID="LblUsuarioPortalCliente" runat="server" Text=""></asp:Label><br />
<br />
<div id="trEnviarActivacion" visible="true" runat="server" class="form-group">
Enviar Activación:
<asp:Label ID="LblActivacionPortal" runat="server" Text="Capturar correo del responsable" Visible="false"></asp:Label>
<asp:LinkButton ID="LbEnviarActivacionPortal" runat="server" CssClass="Texto" Text="Envíar Activación al portal"></asp:LinkButton>
</div>
<div id="trDesactivarUsuario" visible="false" runat="server" class="form-group">
Desactivar Usuario:
<asp:LinkButton ID="LbDesactivaPortal" runat="server" Text="Desactivar Usuarios del portal" CausesValidation="False" CssClass="Texto" data-toggle="confirmation" data-popout="true" data-original-title="Confirmar" data-btn-ok-label="si"></asp:LinkButton>
</div>
</div>
@@ -3334,12 +3403,14 @@
<th width="15%">
<asp:LinkButton ID="LbNombre1" runat="server" CausesValidation="false" Text="" CommandArgument="Nombre1;1">
Nombre
<asp:Literal ID="ImgNombre1" runat="server" Text=" <i class='fa fa-sort' style='color:#999' ></i>"></asp:Literal>
</asp:LinkButton>
</th>
<th width="16%">
<asp:LinkButton ID="LbCorreo" runat="server" CausesValidation="false" Text="" CommandArgument="Usuario/Correo1;1">
Correo/Usuario
<asp:Literal ID="ImgCorreo1" runat="server" Text=" <i class='fa fa-sort' style='color:#999' ></i>"></asp:Literal>
</asp:LinkButton>
</th>
@@ -3368,13 +3439,15 @@
<th width="7%">
<asp:LinkButton ID="LbFechaIng1" runat="server" CausesValidation="false" Text="" CommandArgument="FechaIng1;1">
Fecha
<asp:Literal ID="ImgFechaIn1" runat="server" Text=" <i class='fa fa-sort' style='color:#999' ></i>"></asp:Literal>
<asp:Literal ID="ImgFechaIn1" runat="server" Text=" <i class='fa fa-sort' style='color:#999' ></i>"></asp:Literal>
</asp:LinkButton>
</th>
<th width="16%">
<asp:LinkButton ID="LbUsuarioCreo" runat="server" CausesValidation="false" Text="" CommandArgument="UsuarioCreo1;1">
Usuario
<asp:Literal ID="ImgUsuarioCreo1" runat="server" Text=" <i class='fa fa-sort' style='color:#999' ></i>"></asp:Literal>
<asp:Literal ID="ImgUsuarioCreo1" runat="server" Text=" <i class='fa fa-sort' style='color:#999' ></i>"></asp:Literal>
</asp:LinkButton>
</th>
<th width="10%">Comandos</th>
@@ -3570,7 +3643,8 @@
<asp:LinkButton ID="ImgE" runat="server" AlternateText="Editar" CausesValidation="False" CommandName="Edit" CssClass="btn btn-circle btn-sm green" Text="<i class='fa fa-pencil'></i>" />
&nbsp;<asp:LinkButton ID="ImgR" runat="server" AlternateText="Restablecer Contraseña" ToolTip="Restablecer Contraseña" CausesValidation="False" CommandName="RestablecerContraseña" CssClass="btn btn-circle btn-sm blue" CommandArgument='<%# Eval("CveUsuarioIng").ToString() %>' OnClientClick="return confirm('Está seguro que desea restablecer la contraseña?')" Text="<i class='fa fa-rotate-left'></i>" />
&nbsp;
<asp:LinkButton ID="ImgEE" runat="server" AlternateText="Eliminar" CausesValidation="False" CommandName="Delete" CssClass="btn btn-circle btn-sm red" Text="<i class='icon-trash'></i>" data-toggle="confirmation" data-popout="true" data-original-title="confirmar" data-btn-ok-label="si" />
<asp:LinkButton ID="ImgEE" runat="server" AlternateText="Eliminar" CausesValidation="False" CommandName="Delete" CssClass="btn btn-circle btn-sm red" Text="<i class='icon-trash'></i>" data-toggle="confirmation" data-popout="true" data-original-title="confirmar" data-btn-ok-label="si" />
</ItemTemplate>
<ItemStyle Width="10%" />
</asp:TemplateField>
@@ -3799,6 +3873,7 @@
<div class="row">
<div class="col-md-1 truncate" style="width: 120px">
Fecha Inicio:
</div>
<div class="col-md-1" style="width: 120px">
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 100px !important; padding: 0px;">
@@ -3814,6 +3889,7 @@
</div>
<div class="col-md-1 truncate" style="width: 120px">
Fecha Fin:
</div>
<div class="col-md-1" style="width: 120px">
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 100px !important; padding: 0px;">
@@ -3936,14 +4012,16 @@
<tr>
<td>Importe Cargo</td>
<td style="text-align: right!important">$
<asp:Label runat="server" ID="LblUsadosImpCargo"></asp:Label></td>
<td style="text-align: right!important">
<asp:Button runat="server" Visible="false" Height="34px" Width="180px" ID="LnkFacturaUsadosCargos" CssClass="btn btn-primary" Text="Generar NC Cargo" data-toggle="confirmation" data-popout="true" data-original-title="Comfirmar generación de nota de crédito de cargos" data-btn-ok-label="si" OnClick="LnkFacturaUsadosCargos_Click"></asp:Button>
<asp:Button runat="server" Visible="false" Height="34px" Width="180px" ID="LnkFacturaUsadosCargos" CssClass="btn btn-primary" Text="Generar NC Cargo" data-toggle="confirmation" data-popout="true" data-original-title="Comfirmar generación de nota de crédito de cargos" data-btn-ok-label="si" OnClick="LnkFacturaUsadosCargos_Click"></asp:Button>
</td>
</tr>
<tr>
<td>Importe Bonificación</td>
<td style="text-align: right!important">$
<asp:Label runat="server" ID="LblusadosImpBonificacion"></asp:Label></td>
<td style="text-align: right!important">
<asp:Button runat="server" Height="34px" Width="180px" ID="LnkFacturaUsadosBonificacion" CssClass="btn btn-primary" Text="Generar NC Bonificación" data-toggle="confirmation" data-popout="true" data-original-title="Comfirmar generación de nota de crédito de bonificación" data-btn-ok-label="si" OnClick="LnkFacturaUsadosBonificacion_Click"></asp:Button>
@@ -3988,6 +4066,7 @@
<div class="row">
<div class="col-md-1 truncate" style="width: 120px">
Fecha Inicio:
</div>
<div class="col-md-1" style="width: 120px">
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 100px !important; padding: 0px;">
@@ -4003,6 +4082,7 @@
</div>
<div class="col-md-1 truncate" style="width: 120px">
Fecha Fin:
</div>
<div class="col-md-1" style="width: 120px">
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 100px !important; padding: 0px;">
@@ -4141,6 +4221,7 @@
<div class="col-xs-4">
Con copia para:<br />
(Separar con: ;)
</div>
<div class="col-xs-8">
<asp:TextBox ID="TxtCC" runat="server" TextMode="MultiLine" Columns="3" Rows="3" CssClass="form-control"></asp:TextBox>
@@ -4193,6 +4274,7 @@
<div class="col-xs-4">
Con copia para:<br />
(Separar con: ;)
</div>
<div class="col-xs-8">
<asp:TextBox ID="TxtCC2" runat="server" TextMode="MultiLine" Columns="3" Rows="3" CssClass="form-control"></asp:TextBox>
@@ -4246,7 +4328,8 @@
<asp:CompareValidator ID="CVFechaPago" runat="server" ControlToValidate="TxtFechaPago" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha''</b> no tiene el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="GpoGuardarAbonar"></asp:CompareValidator>
<ajax:ValidatorCalloutExtender ID="VCOFechaPago1" runat="server" HighlightCssClass="vco" TargetControlID="RFVFechaPago" Width="350px"></ajax:ValidatorCalloutExtender>
&nbsp;
<ajax:ValidatorCalloutExtender ID="VCOFechaPago2" runat="server" HighlightCssClass="vco" TargetControlID="CVFechaPago" Width="350px"></ajax:ValidatorCalloutExtender>
<ajax:ValidatorCalloutExtender ID="VCOFechaPago2" runat="server" HighlightCssClass="vco" TargetControlID="CVFechaPago" Width="350px"></ajax:ValidatorCalloutExtender>
&nbsp;
</td>
<tr>
@@ -4750,6 +4833,7 @@
<div class="row">
<div class="col-md-1">
Cliente:
</div>
<div class="col-md-5">
<ADS:Dropdownlost ID="DdlClienteImportarSaldos" data-metodo="getcliente" DataValueField="CveCliente" DataTextField="CodigoNombre" Width="260px" CssClass="select2me" runat="server"></ADS:Dropdownlost>
@@ -4758,6 +4842,7 @@
</div>
<div class="col-md-1">
Fecha:
</div>
<div class="col-md-3">
<div class="input-group input-small date date-picker" style="width: 100px !important;" data-date-format="dd/mm/yyyy">
@@ -4784,6 +4869,7 @@
<div class="col-md-6 pull-right" style="text-align: right;">
Importe total:
<asp:TextBox Text="" ID="TxtSaldoImportar" ClientIDMode="Static" Enabled="false" runat="server" />
</div>
</div>
@@ -5249,6 +5335,7 @@
</div>
<div class="row" align="center">
<h4>Estatus:
<asp:Label ID="LblEstatusModal" runat="server"></asp:Label></h4>
</div>
<div class="row">
@@ -5266,7 +5353,8 @@
<span data-counter="counterup" data-value="1349">
<b>
<asp:Label runat="server" Text="0" ID="LblVentasModal"></asp:Label></span></b>
<asp:Label runat="server" ID="LblPor" Text=""></asp:Label>
<asp:Label runat="server" ID="LblPor" Text=""></asp:Label>
</h4>
<small>Ventas</small>
</div>
@@ -5281,7 +5369,8 @@
<span data-counter="counterup" data-value="1349">
<b>
<asp:Label runat="server" Text="0" ID="LblPagadoModal"></asp:Label></span></b>
<asp:Label runat="server" ID="Label2" Text=""></asp:Label>
<asp:Label runat="server" ID="Label2" Text=""></asp:Label>
</h4>
<small>Pagado</small>
</div>
@@ -5296,7 +5385,8 @@
<span data-counter="counterup" data-value="1349">
<b>
<asp:Label runat="server" Text="0" ID="LblRotacionModal"></asp:Label></span></b>
<asp:Label runat="server" ID="Label3" Text=""></asp:Label>
<asp:Label runat="server" ID="Label3" Text=""></asp:Label>
</h4>
<small>Rotación</small>
</div>
@@ -5311,7 +5401,8 @@
<span data-counter="counterup" data-value="1349">
<b>
<asp:Label runat="server" Text="0" ID="LblDiasModal"></asp:Label></span></b>
<asp:Label runat="server" ID="Label4" Text=""></asp:Label>
<asp:Label runat="server" ID="Label4" Text=""></asp:Label>
</h4>
<small>Dias</small>
</div>
@@ -5326,7 +5417,8 @@
<span data-counter="counterup" data-value="1349">
<b>
<asp:Label runat="server" Text="0" ID="LblDiasCreditoModal"></asp:Label></span></b>
<asp:Label runat="server" ID="Label5" Text=""></asp:Label>
<asp:Label runat="server" ID="Label5" Text=""></asp:Label>
</h4>
<small>Dias Credito</small>
</div>
@@ -5349,6 +5441,7 @@
</div>
<div class="col-md-6" align="center">
<h4>Límite de Crédito $
<asp:Literal ID="LtlLimiteCreditoModal" runat="server"></asp:Literal>MN</h4>
<br />
<div id="chartdiv2"></div>
@@ -5402,6 +5495,7 @@
<asp:TemplateField ItemStyle-HorizontalAlign="Center" ItemStyle-Width="15%" HeaderText="Comandos">
<ItemTemplate>
<asp:LinkButton ID="LnkAutorizar" runat="server" OnClick="LnkAutorizar_Click" Text="Autorizar" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea autorizar el pedido?" data-btn-ok-label="si" />&nbsp;&nbsp;&nbsp;&nbsp;
<asp:LinkButton ID="LnkCancelar" runat="server" OnClick="LnkCancelar_Click" Text="Cancelar" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea cancelar el pedido?" data-btn-ok-label="si" />
</ItemTemplate>
</asp:TemplateField>

View File

@@ -820,6 +820,10 @@ Partial Class Clientes
UpFiscalContable.Update()
End If
If UsuarioActual.Empresa.Funcionalidad(579) = "1" Then
DivTipoRetenciones.Visible = True
End If
If Request("CveEmpresaCRM") IsNot Nothing AndAlso IsNumeric(Request("CveEmpresaCRM")) AndAlso Request("CveEmpresaCRM").ToEntero > 0 Then
ViewState("CveEmpresaCRM") = Request("CveEmpresaCRM")
CargaDatosCRM()
@@ -1375,6 +1379,7 @@ Partial Class Clientes
DdlPrecioLista.SelectedValue = ObjClientes.CvePrecioLista.ToString
TxtCC.Text = ObjClientes.NotificarA
ChkMail.Checked = ObjClientes.EnviarFactura
DdlTipoRetencion.SelectedValueExist(ObjClientes.DtResultados(0)("CveTipoRetencion").ToString)
TxtRetIVA.Text = ObjClientes.RetIVA.ToString
TxtRetISR.Text = ObjClientes.RetISR.ToString
ChkRetIVAFletesAcarreos.Checked = ObjClientes.RetieneIVAFletes
@@ -2411,7 +2416,7 @@ Partial Class Clientes
CveFormaPago33:=DdlFormaPago33.SelectedValue.ToEntero, CveMetodoPago33:=DdlMetodoPago33.SelectedValue.ToEntero, DesglosaIEPS:=ChkDesglosarIEPS.Checked, AplicaComercioExterior:=ChkAplicaComercioExterior.Checked, CveTipoOperacion:=DdlTipoOperacion.SelectedValue.ToEntero, CvePedimento:=DdlClavePedimento.SelectedValue.ToEntero, CveIncoterm:=DdlIncoterm.SelectedValue.ToEntero,
CvePais:=DdlPais.SelectedValue.ToEntero, CveEstado:=DdlEstado.SelectedValue.ToEntero, CveMunicipio:=DdlMunicipio.SelectedValue.ToEntero, CveColonia:=DdlColonia.SelectedValue.ToEntero, CveMotivoTraslado:=IIf(DdlMotivoTraslado.SelectedValue = "-1", "0", DdlMotivoTraslado.SelectedValue).ToString().ToEntero, NumRegIdTrib:=IIf(TxtNumRegIdTrib.Text = "", "-1", TxtNumRegIdTrib.Text).ToString(),
ComExtEstado:=IIf(TxtComExtEstado.Text = "", "-1", TxtComExtEstado.Text).ToString(), ComExtMunicipio:=IIf(TxtComExtMunicipio.Text = "", "-1", TxtComExtMunicipio.Text).ToString(), ComExtColonia:=IIf(TxtComExtColonia.Text = "", "-1", TxtComExtColonia.Text).ToString(), RequiereOC:=ChkRequiereOC.Checked, LT:=LT, LG:=LG, EsDistribuidor:=ChkEsDistribuidor.Checked,
TipoCliente:=DdlTipoCliente.SelectedValue.ToEntero, CargoUsado:=ChkCargoUsado.Checked, BonificacionUsado:=ChkBonificacionUsado.Checked) Then
TipoCliente:=DdlTipoCliente.SelectedValue.ToEntero, CargoUsado:=ChkCargoUsado.Checked, BonificacionUsado:=ChkBonificacionUsado.Checked, CveTipoRetencion:=DdlTipoRetencion.SelectedValue.ToEntero()) Then
ViewState("CveCliente") = ObjClientes.CveCliente
@@ -2505,7 +2510,8 @@ Partial Class Clientes
AplicaComercioExterior:=ChkAplicaComercioExterior.Checked, CveTipoOperacion:=DdlTipoOperacion.SelectedValue.ToEntero, CvePedimento:=DdlClavePedimento.SelectedValue.ToEntero, CveIncoterm:=DdlIncoterm.SelectedValue.ToEntero, CvePais:=DdlPais.SelectedValue.ToEntero, CveEstado:=DdlEstado.SelectedValue.ToEntero, CveMunicipio:=DdlMunicipio.SelectedValue.ToEntero, CveColonia:=DdlColonia.SelectedValue.ToEntero,
CveMotivoTraslado:=IIf(DdlMotivoTraslado.SelectedValue = "-1", "0", DdlMotivoTraslado.SelectedValue).ToString().ToEntero, NumRegIdTrib:=IIf(TxtNumRegIdTrib.Text = "", "-1", TxtNumRegIdTrib.Text).ToString(),
ComExtEstado:=IIf(TxtComExtEstado.Text = "", "-1", TxtComExtEstado.Text).ToString(), ComExtMunicipio:=IIf(TxtComExtMunicipio.Text = "", "-1", TxtComExtMunicipio.Text).ToString(), ComExtColonia:=IIf(TxtComExtColonia.Text = "", "-1", TxtComExtColonia.Text).ToString(),
ApellidoPaternoPF:=IIf(TxtApellidoPaterno.Text = "", "-1", TxtApellidoPaterno.Text).ToString(), ApellidoMaternoPF:=IIf(TxtApellidoMaterno.Text = "", "-1", TxtApellidoMaterno.Text).ToString(), NombresPF:=IIf(TxtNombres.Text = "", "-1", TxtNombres.Text).ToString(), RequiereOC:=ChkRequiereOC.Checked, LT:=LT, LG:=LG, EsDistribuidor:=ChkEsDistribuidor.Checked, TipoCliente:=DdlTipoCliente.SelectedValue.ToEntero, CargoUsado:=ChkCargoUsado.Checked, BonificacionUsado:=ChkBonificacionUsado.Checked) Then
ApellidoPaternoPF:=IIf(TxtApellidoPaterno.Text = "", "-1", TxtApellidoPaterno.Text).ToString(), ApellidoMaternoPF:=IIf(TxtApellidoMaterno.Text = "", "-1", TxtApellidoMaterno.Text).ToString(), NombresPF:=IIf(TxtNombres.Text = "", "-1", TxtNombres.Text).ToString(),
RequiereOC:=ChkRequiereOC.Checked, LT:=LT, LG:=LG, EsDistribuidor:=ChkEsDistribuidor.Checked, TipoCliente:=DdlTipoCliente.SelectedValue.ToEntero, CargoUsado:=ChkCargoUsado.Checked, BonificacionUsado:=ChkBonificacionUsado.Checked, CveTipoRetencion:=DdlTipoRetencion.SelectedValue.ToEntero()) Then
ObjClientes.LimpiaImpuestosLocales(CveCliente)
@@ -3912,7 +3918,7 @@ Partial Class Clientes
Gracias por la atención brindada al presente.<br /> Reciba un cordial saludo.<br />
<br />
<b>ESTE CORREO SE GENERO EN FORMA AUTOMATICA.</b>", TxtNombreComercial.Text, UsuarioActual.Empresa.Empresa)
Dim Hilo As New System.Threading.Thread(Sub() MandaCorreoEstadoCuenta(File, TxtCobranzaCorreo.Text, $"Estado Actual de Cartera {UsuarioActual.Empresa.Empresa}", Cuerpo, GuardarBitacora:=True))
Dim Hilo As New System.Threading.Thread(Sub() MandaCorreoEstadoCuenta(UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, Me.CveCliente, File, TxtCobranzaCorreo.Text, $"Estado Actual de Cartera {UsuarioActual.Empresa.Empresa}", Cuerpo, GuardarBitacora:=True))
Hilo.Start()
Alert("El correo se envió con éxito", TipoMensaje.MsgInformacion)
Catch ex As Exception
@@ -3979,7 +3985,7 @@ Partial Class Clientes
End If
End If
End Sub
Private Sub MandaCorreoEstadoCuenta(File As Byte(), Para As String, Asunto As String, Body As String, Optional GuardarBitacora As Boolean = False)
Private Sub MandaCorreoEstadoCuenta(CveUsuario As Integer, CveEmpresa As Integer, CveCliente As Integer, File As Byte(), Para As String, Asunto As String, Body As String, Optional GuardarBitacora As Boolean = False)
Dim a As String = String.Format("{0} -- {1} ---- -->", Asunto, Para)
'a.GuardaLog()
@@ -3992,7 +3998,7 @@ Partial Class Clientes
If Envio AndAlso GuardarBitacora Then
Using ObjBitacora As New ClsOIEventos
ObjBitacora.AddEventoBitacora("Se envió correo con el estado de cuenta del cliente", "", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CveCliente:=Me.CveCliente)
ObjBitacora.AddEventoBitacora("Se envió correo con el estado de cuenta del cliente", "", CveUsuario, CveEmpresa, CveCliente:=CveCliente)
End Using
End If

View File

@@ -459,7 +459,7 @@ Partial Class Ventas_ClientesAbonar
TxtImporte.Text = ""
TxtObservaciones.Text = ""
If SumDescuentoProntoPago > 0.0 Then
GvCxC.Columns("DescuentoProntoPago").Visible = True
GvCxC.Columns(14).Visible = True
End If
Mov.Dispose()

View File

@@ -616,8 +616,7 @@
</th>
<th id="thEncIEPS1" runat="server" visible="false">IEPS
</th>
<th>Total&nbsp<%--;<asp:LinkButton ID="ImgDescConcepto" runat="server" Text="<i class='fa fa-comment-o'></i>" Style="cursor: pointer;" AlternateText="Agregar Descuento" /></th>--%>
<th style="width: 100px;" colspan="3">Comandos</th>
<th>Total&nbsp<%--;<asp:LinkButton ID="ImgDescConcepto" runat="server" Text="<i class='fa fa-comment-o'></i>" Style="cursor: pointer;" AlternateText="Agregar Descuento" /></th>--%><th style="width: 100px;" colspan="3">Comandos</th>
<th></th>
<th runat="server" visible="false" id="nomostrar2"></th>
</tr>

View File

@@ -5018,7 +5018,7 @@ Partial Class PV
Private Sub CargaAjuste()
Dim ObjAcum As New ClsAcumuladores
If ObjAcum.FoliosGarantiaGet(-1, UsuarioActual.CveEmpresa) Then
If ObjAcum.FoliosGarantiaGet(-1, UsuarioActual.CveEmpresa, 1) Then
DdlFolioGarantia.DataSource = ObjAcum.DtResultados
DdlFolioGarantia.Items.Insert(0, New ListItem("Seleccione", "-1"))
End If

View File

@@ -410,11 +410,11 @@
</div>
<div class="portlet-body form">
<asp:GridView ID="GvPSAdicionales" runat="server" AutoGenerateColumns="False" DataKeyNames="CvePS, CvePSAdicional,Cantidad, PS" EmptyDataText="No se encontraron Productos/Servicios Adicionales" CssClass="table table-striped table-hover Widthall ScrollAD mysmallbtn" GridLines="None">
<asp:GridView ID="GvPSAdicionales" runat="server" AutoGenerateColumns="False" DataKeyNames="CvePS, CvePSAdicional,Cantidad, PS,CodigoPS" EmptyDataText="No se encontraron Productos/Servicios Adicionales" CssClass="table table-striped table-hover Widthall ScrollAD mysmallbtn" GridLines="None">
<Columns>
<asp:TemplateField HeaderText="Producto/Servicio">
<ItemTemplate>
<asp:Literal ID="Ltum" runat="server" Text='<%# Eval("PS")%>'></asp:Literal>
<asp:Literal ID="Ltum" runat="server" Text='<%# Eval("CodigoPS")%>'></asp:Literal>
</ItemTemplate>
<EditItemTemplate>
<asp:DropDownList ID="DdlPSAdicional" CssClass="form-control input-sm select2me" runat="server" DataTextField="PS" DataValueField="CvePS" AppendDataBoundItems="true" AutoPostBack="True" />

View File

@@ -27,39 +27,49 @@ public partial class Ventas_RepCancelacionesPorAtender : ClsPaginas
}
private void CargarPendientes()
{
Cancelacion.CancelacionSoapClient objServicio = new Cancelacion.CancelacionSoapClient();
Cancelacion.StructCancel resp = objServicio.ObtienePendientes(UsuarioActual.Empresa.RFC, "UserTest", "1234567890");
if (resp.Estado == 0)
//Cancelacion.CancelacionSoapClient objServicio = new Cancelacion.CancelacionSoapClient();
//Cancelacion.StructCancel resp = objServicio.ObtienePendientes(UsuarioActual.Empresa.RFC, "UserTest", "1234567890");
//if (resp.Estado == 0)
//{
// string XmlPendientes = DecodeBase64(resp.Xml);
// StringReader theReader = new StringReader(XmlPendientes);
// DataSet theDataSet = new DataSet();
// theDataSet.ReadXml(theReader);
// if (theDataSet.Tables[0].Rows[0]["Uuid"].ToString() != "null")
// {
// var sb = new StringBuilder();
// foreach (DataRow item in theDataSet.Tables[0].Rows)
// {
// sb.AppendFormat("{0};", item["Uuid"].ToString());
// }
// var ObjVentas = new ClsVentas();
// if (ObjVentas.GetFacturasCanceladasPendientes(sb.ToString(), UsuarioActual.CveEmpresa))
// {
// GvDatos.DataSource = ObjVentas.DtResultados;
// }
// ObjVentas.Dispose();
// }
// else
// {
// GvDatos.DataSource = null;
// Alert("No se encontraron cancelaciones pendientes");
// }
//}
//else
//{
// GvDatos.DataSource = null;
// Alert("Error al obtener cancelaciones pendientes: " + resp.Descripcion, ModExtensiones.TipoMensaje.MsgError);
//}
using (ClsVentas ObjVentas = new ClsVentas())
{
string XmlPendientes = DecodeBase64(resp.Xml);
StringReader theReader = new StringReader(XmlPendientes);
DataSet theDataSet = new DataSet();
theDataSet.ReadXml(theReader);
if (theDataSet.Tables[0].Rows[0]["Uuid"].ToString() != "null")
if (ObjVentas.GetFacturasCanceladasPendientesWS(UsuarioActual.Empresa.RFC, UsuarioActual.CveEmpresa))
{
var sb = new StringBuilder();
foreach (DataRow item in theDataSet.Tables[0].Rows)
{
sb.AppendFormat("{0};", item["Uuid"].ToString());
}
var ObjVentas = new ClsVentas();
if (ObjVentas.GetFacturasCanceladasPendientes(sb.ToString(), UsuarioActual.CveEmpresa))
{
GvDatos.DataSource = ObjVentas.DtResultados;
}
ObjVentas.Dispose();
}
else
{
GvDatos.DataSource = null;
Alert("No se encontraron cancelaciones pendientes");
GvDatos.DataSource = ObjVentas.DtResultados;
}
}
else
{
GvDatos.DataSource = null;
Alert("Error al obtener cancelaciones pendientes: " + resp.Descripcion, ModExtensiones.TipoMensaje.MsgError);
}
GvDatos.DataBind();
UPDatos.Update();
}
@@ -154,8 +164,7 @@ public partial class Ventas_RepCancelacionesPorAtender : ClsPaginas
{
try
{
byte[] decbuff = Convert.FromBase64String(strXMLCodificado);
return System.Text.Encoding.UTF8.GetString(decbuff);
return System.Text.Encoding.UTF8.GetString(Convert.FromBase64String(strXMLCodificado));
}
catch
{

View File

@@ -8,16 +8,16 @@
text-align: left;
}
.GVConciliacionemitidasSAT tr th:nth-child(6) {
.GVConciliacionemitidasSAT tr th:nth-child(7) {
text-align: center;
}
.GVConciliacionemitidasSAT tr td:nth-child(6) {
.GVConciliacionemitidasSAT tr td:nth-child(7) {
text-align: right;
}
.GVConciliacionemitidasSAT tr th:nth-child(7),
.GVConciliacionemitidasSAT tr td:nth-child(7) {
.GVConciliacionemitidasSAT tr th:nth-child(8),
.GVConciliacionemitidasSAT tr td:nth-child(8) {
text-align: center;
}
</style>
@@ -35,6 +35,80 @@
<asp:UpdatePanel ID="UpDatosReporte" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<asp:UpdatePanel ID="UPFiltros" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div class="portlet solid grey-cascade portlet-filter" id="idnecesaria">
<div class="portlet-title portlet-filterT smalltitle" style="min-height: 51px;">
<div class="tools">
<asp:Button ID="BtnConsultar" OnClick="BtnConsultar_Click" runat="server" Text="Consultar" class="btn btn-primary" />
<a href="javascript:;" class="expand"></a>
</div>
<div class="titlefiltros caption">
<div class="row">
<label class="col-md-1" style="padding-top: 13px; display: none;">Tipo: </label>
<div class="col-md-2" style="display: none;">
<asp:ListBox ID="DdlTipoComprobante" data-text="Todos" SelectionMode="Multiple" CssClass="form-control ddlFiltros input-sm select2me Widthall" Style="width: 100%;" runat="server">
<asp:ListItem Text="Ingresos" Value="Ing"></asp:ListItem>
<asp:ListItem Text="Egresos" Value="Egs"></asp:ListItem>
<asp:ListItem Text="Remisión" Value="Rem"></asp:ListItem>
<asp:ListItem Text="Cotización" Value="Cot"></asp:ListItem>
<asp:ListItem Text="Anticipos" Value="Ant"></asp:ListItem>
<asp:ListItem Text="Pedido Con" Value="Ped"></asp:ListItem>
<asp:ListItem Text="Devolucion" Value="Dev"></asp:ListItem>
<asp:ListItem Text="Pedido" Value="Pd2"></asp:ListItem>
</asp:ListBox>
</div>
<div class="col-md-2" style="padding-top: 13px;" >
<asp:DropDownList ID="ddlRegistroen" CssClass="select2me form-control " Width="100%" runat="server">
<asp:ListItem Text="Todos" Value="0"></asp:ListItem>
<asp:ListItem Text="SIG" Value="1"></asp:ListItem>
<asp:ListItem Text="SAT" Value="2"></asp:ListItem>
<asp:ListItem Text="SIG Sin Encontrar SAT" Value="3"></asp:ListItem>
<asp:ListItem Text="SAT Sin Encontrar SIG" Value="4"></asp:ListItem>
</asp:DropDownList>
</div>
<div class="col-md-1 truncate" style="padding-top: 13px;">
Fecha Inicio:
</div>
<div class="col-md-1" style="padding-top: 9px;">
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 100px !important; padding: 0px;">
<asp:TextBox Width="80px" ID="txtFechaI" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10"></asp:TextBox>
<span class="input-group-btn ">
<asp:LinkButton ID="imgCalendario" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
</span>
</div>
<ajax:MaskedEditExtender ID="MEEFechaI" runat="server" TargetControlID="txtFechaI" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="Calendario" TargetControlID="txtFechaI" PopupButtonID="ImgCalendario" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
<asp:RequiredFieldValidator ID="rfvFechaI" runat="server" ControlToValidate="txtFechaI" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="Valida"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="cvFechaI" runat="server" ControlToValidate="txtFechaI" Display="None" ErrorMessage="El campo <b>''Fecha Inicial''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="Valida"></asp:CompareValidator>
<ajax:ValidatorCalloutExtender ID="vcoFfvFI" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaI" Width="350px"></ajax:ValidatorCalloutExtender>
<ajax:ValidatorCalloutExtender ID="vcoCvFI" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaI" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
<div class="col-md-1 truncate" style="padding-top: 13px;">
Fecha Fin:
</div>
<div class="col-md-1" style="padding-top: 9px;">
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 100px !important; padding: 0px;">
<asp:TextBox Width="80px" ID="txtFechaF" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10"></asp:TextBox>
<span class="input-group-btn ">
<asp:LinkButton ID="imgCalendarioF" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
</span>
</div>
<ajax:MaskedEditExtender ID="MEEFechaF" runat="server" TargetControlID="txtFechaF" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="Calendario2" TargetControlID="txtFechaF" PopupButtonID="imgCalendarioF" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
<asp:RequiredFieldValidator ID="rfvFechaF" runat="server" ControlToValidate="txtFechaF" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> es requerido por la aplicación, por favor ingrese una fecha." ValidationGroup="Valida"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="cvFechaF" runat="server" ControlToValidate="txtFechaF" Display="None" ErrorMessage="El campo <b>''Fecha Final''</b> no tienes el formato correcto, por favor intente de nuevo con el siguiente formato: (dd/mm/yyyy)." Operator="DataTypeCheck" Type="Date" ValidationGroup="Valida"></asp:CompareValidator>
<ajax:ValidatorCalloutExtender ID="vcoRfvFF" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
<ajax:ValidatorCalloutExtender ID="vcoCvFF" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
</div>
</div>
</div>
<div class="portlet-body" style="display: none">
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
<div class="portlet light xspadding bordered " id="PorletDatos" style="margin-bottom: 0px;">
<div class="portlet-title">
@@ -52,8 +126,13 @@
</div>
<div class="portlet-body ">
<asp:GridView ID="GVConciliacionemitidasSAT" runat="server" GridLines="None" CssClass="table table-hover table-striped ScrollAD Widthall GVConciliacionemitidasSAT" AutoGenerateColumns="False"
DataKeyNames="FolioFiscal,TipoDocto,ImporteTotal,Estatus,Fecha,Moneda,RFCReceptor,CveEmpresa,RutaXml,RFCEmisor,TipoDoctoTexto">
DataKeyNames="FolioFiscal,TipoDocto,ImporteTotal,Estatus,Fecha,Moneda,RFCReceptor,CveEmpresa,RutaXml,RFCEmisor,TipoDoctoTexto" OnRowDataBound="GVConciliacionemitidasSAT_RowDataBound">
<Columns>
<asp:TemplateField HeaderText=" ">
<ItemTemplate>
<asp:Label runat="server" Text='<%# Eval("TipoText")%>'> </asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Tipo documento">
<ItemTemplate>
<asp:Label ID="lbltipoDocto" runat="server" Text='<%# Eval("TipoDoctoTexto")%>'> </asp:Label>
@@ -69,6 +148,11 @@
<asp:Label ID="lblfecha" runat="server" Text='<%# Eval("Fecha","{0:dd/MM/yyyy}")%>'> </asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha SIG">
<ItemTemplate>
<asp:Label ID="lblfechaSIG" runat="server" Text='<%# Eval("FechaSIG","{0:dd/MM/yyyy}")%>'> </asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Serie-Folio">
<ItemTemplate>
<asp:Label ID="lblSerieFolio" runat="server" Text='<%# string.Format("{0}-{1}",Eval("Serie"),Eval("Folio"))%>'> </asp:Label>
@@ -91,12 +175,13 @@
</asp:TemplateField>
<asp:TemplateField HeaderText="Estatus">
<ItemTemplate>
<asp:Label ID="lblestatus" runat="server" Text='<%# Eval("EstatusFactura")%>'> </asp:Label>
<asp:Label ID="lblestatus" runat="server" Text='<%# Eval("Estatus")%>'> </asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Xml" Visible="false">
<asp:TemplateField HeaderText="Xml" >
<ItemTemplate>
<%--<asp:Label ID="lblrutaXml" runat="server" Text='<%# Eval("RutaXml")%>'> </asp:Label>--%>
<asp:HyperLink ID="HypXml" runat="server" target="_blank"><i class="fa fa-download" aria-hidden="true"></i>XML</asp:HyperLink>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="">
@@ -153,7 +238,6 @@
</asp:Content>
<asp:Content ID="Content8" ContentPlaceHolderID="JS" runat="Server">
<script>
$('#DModalDefaults').modal();
function FiltrarTabla(idtxt, idtable, idcontador) {
if ($('' + idtxt).val() == '') { $('table' + idtable + ' tr').css('display', 'table-row'); }

File diff suppressed because it is too large Load Diff

View File

@@ -10,12 +10,32 @@
table.table > tbody > tr.Grupo1 {
background-color: #CCC !important;
cursor:pointer;
cursor: pointer;
}
table.table > tbody > tr.Grupo2 {
background-color: #DDD !important;
cursor:pointer;
cursor: pointer;
}
.GVRepConciliacionSatGET > tbody > tr > td:not(:nth-child(1)) {
text-align: center;
}
.GVRepConciliacionSatGET tr:not(.Grupo0):not(.Grupo3) .showhideicon {
width: 14px;
height: 14px;
font-size: 7px;
display: block;
background-image: url(/Metronic/assets/global/img/portlet-collapse-icon-white.png);
}
.GVRepConciliacionSatGET tr:not(.Grupo0):not(.Grupo3).hidex .showhideicon {
background-image: url(/Metronic/assets/global/img/portlet-expand-icon-white.png);
}
.GVRepConciliacionSatGET .bactions {
width: 5px;
}
</style>
</asp:Content>
@@ -25,7 +45,7 @@
<asp:Content ID="Content4" ContentPlaceHolderID="HB" runat="Server">
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
<li><a onclick="javascript:AbrirVentana('/Ventas/SolicitudesSAT.aspx?Masterimpoup=true',1400);"><i class="fa fa-dropbox"></i>Solicitudes SAT </a></li>
<li><a onclick="javascript:AbrirVentana('/Ventas/SolicitudesSAT.aspx?tipo=2&Masterimpoup=true',1400);"><i class="fa fa-dropbox"></i>Solicitudes SAT </a></li>
</asp:Content>
<asp:Content ID="Content6" ContentPlaceHolderID="HA" runat="Server">
@@ -42,8 +62,8 @@
</div>
<div class="titlefiltros caption">
<div class="row">
<label class="col-md-1" style="padding-top: 13px; display:none;">Tipo: </label>
<div class="col-md-2" style="display:none;">
<label class="col-md-1" style="padding-top: 13px; display: none;">Tipo: </label>
<div class="col-md-2" style="display: none;">
<asp:ListBox ID="DdlTipoComprobante" data-text="Todos" SelectionMode="Multiple" CssClass="form-control ddlFiltros input-sm select2me Widthall" Style="width: 100%;" runat="server">
<asp:ListItem Text="Ingresos" Value="Ing"></asp:ListItem>
<asp:ListItem Text="Egresos" Value="Egs"></asp:ListItem>
@@ -99,7 +119,7 @@
</asp:UpdatePanel>
<asp:UpdatePanel ID="upDatosRepC" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<asp:GridView ID="GVRepConciliacionSatGET" runat="server" GridLines="None" CssClass="table table-hover table-striped ScrollAD Widthall" AutoGenerateColumns="False"
<asp:GridView ID="GVRepConciliacionSatGET" runat="server" GridLines="None" CssClass="table table-hover table-striped ScrollAD Widthall GVRepConciliacionSatGET" AutoGenerateColumns="False"
DataKeyNames="anio,Mes,MesText,Dia,GRUPOCve,Grupo,CFDISIG,CFDISAT,CFDISIGSinSAT,CFDISATSinSIG" OnRowDataBound="GVRepConciliacionSatGET_RowDataBound">
<Columns>
<asp:TemplateField HeaderText=" ">
@@ -109,26 +129,36 @@
</asp:TemplateField>
<asp:TemplateField HeaderText="SIG">
<ItemTemplate>
<asp:Label ID="lblcFDISIG" runat="server" Text='<%# Eval("CFDISIG")%>'> </asp:Label>
<asp:HyperLink ID="HypSIG" runat="server"><%# Eval("CFDISIG")%></asp:HyperLink>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="SAT">
<ItemTemplate>
<asp:Label ID="lblcFDISAT" runat="server" Text='<%# Eval("CFDISAT")%>'> </asp:Label>
<asp:HyperLink ID="HypSAT" runat="server"><%# Eval("CFDISAT")%></asp:HyperLink>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Sin Encontrar SAT">
<ItemTemplate>
<asp:Label ID="lblcFDISIGSinSAT" runat="server" Text='<%# Eval("CFDISIGSinSAT")%>'> </asp:Label>
<asp:HyperLink ID="HypSIGnoSAT" runat="server"><%# Eval("CFDISIGSinSAT")%></asp:HyperLink>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Sin Encontrar SIG">
<ItemTemplate>
<asp:Label ID="lblcFDISATSinSIG" runat="server" Text='<%# Eval("CFDISATSinSIG")%>'> </asp:Label>
<asp:HyperLink ID="HypSatnoSIG" runat="server"><%# Eval("CFDISATSinSIG")%></asp:HyperLink>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderStyle-CssClass="bactions">
<ItemTemplate>
<span class="showhideicon"></span>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderStyle-CssClass="bactions">
<ItemTemplate>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
<%--<CR:CrystalReportViewer ID="reports" runat="server" AutoDataBind="true"></CR:CrystalReportViewer>--%>
</ContentTemplate>
</asp:UpdatePanel>
</asp:Content>
@@ -157,6 +187,14 @@
$(this).show();
}
});
//
$('.Grupo2').removeClass('hidex');
$('.Grupo2').each(function () {
let gmes = $(this).attr('gmes');
if (Grupo3Show.indexOf(gmes) == -1) {
$(this).addClass('hidex');
}
});
}
$('body').on('click', 'tr.Grupo1 ', function (e) {
let ganio = $(this).attr('ganio');
@@ -179,6 +217,15 @@
$(this).hide();
}
});
$('.Grupo1').removeClass('hidex');
$('.Grupo1').each(function () {
let gmes = $(this).attr('gmes');
let ganio = $(this).attr('ganio');
if (Grupo2hide.indexOf(gmes) > -1) {
$(this).addClass('hidex');
}
});
}
function ADSBegin() {
showhideg3();

View File

@@ -10,10 +10,48 @@ public partial class Ventas_RepConciliacionSat : ClsPaginas
{
const string rqFechaInicio = "FechaInicio";
const string rqFechaFin = "FechaFin";
public string RfechaI
{
get
{
return ViewState["RfechaI"].ToString();
}
set { ViewState["RfechaI"] = value; }
}
public string RfechaF
{
get
{
return ViewState["RfechaF"].ToString();
}
set { ViewState["RfechaF"] = value; }
}
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
//CrystalDecisions.CrystalReports.Engine.ReportDocument cryRpt = new CrystalDecisions.CrystalReports.Engine.ReportDocument();
//cryRpt.Load(String.Format("C:\\Proyectos\\wwwSIG\\Empresas\\Grales\\Formatos\\CatPS.rpt", UsuarioActual.Empresa.Ruta));
//System.Data.DataTable DtDatos = new System.Data.DataTable();
//using (ClsProductosServicios ObjPS = new ClsProductosServicios())
//{
// if (ObjPS.GetPSLite(-1, 119, "-1", "-1", "02541", -1, -1, -1, -1))
// {
// DtDatos = ObjPS.DtResultados;
// }
//}
//cryRpt.SetDataSource(DtDatos);
//CrystalDecisions.ReportAppServer.DataDefModel.ConnectionInfo coninfo = new CrystalDecisions.ReportAppServer.DataDefModel.ConnectionInfo();
//cryRpt.
////cryRpt.SetDatabaseLogon("JCaudillo", "JCau127*953");// 293357
//reports.ReportSource = cryRpt;
//reports.RefreshReport();
//// reports.Refresh();
DateTime fecha;
DateTime fechaInicio = DateTime.Now;
DateTime fechaFin = DateTime.Now;
@@ -33,10 +71,10 @@ public partial class Ventas_RepConciliacionSat : ClsPaginas
protected void CargaRepConciliacionSatGET()
{
string RtipoDocto, RfechaI, RfechaF;
string RtipoDocto;
RtipoDocto = "I";
RfechaI = txtFechaI.Text.ToDateTime().ToString();
RfechaF = txtFechaF.Text.ToDateTime().ToString();
RfechaI = txtFechaI.Text.Length > 0 ? txtFechaI.Text.ToDateTime().ToString("yyyy/MM/dd") : "";
RfechaF = txtFechaF.Text.Length > 0 ? txtFechaF.Text.ToDateTime().ToString("yyyy/MM/dd") : "";
using (ClsGenerales ObjRepC = new ClsGenerales())
{
ObjRepC.RepConciliacionSatGET(UsuarioActual.CveEmpresa, RtipoDocto, RfechaI, RfechaF);
@@ -55,11 +93,65 @@ public partial class Ventas_RepConciliacionSat : ClsPaginas
protected void GVRepConciliacionSatGET_RowDataBound(object sender, GridViewRowEventArgs e)
{
if(e.Row.RowType == DataControlRowType.DataRow)
if (e.Row.RowType == DataControlRowType.DataRow)
{
e.Row.CssClass = string.Format("Grupo{0}", e.Row.DBCampo("GRUPOCve"));
string fechaI = RfechaI;
string fechaF = RfechaF;
DateTime danio;
DateTime danioF;
int GRUPOCve = e.Row.DBCampo("GRUPOCve").ToString().ToEntero();
e.Row.CssClass = string.Format("Grupo{0}", GRUPOCve);
e.Row.Attributes.Add("ganio", string.Format("{0}", e.Row.DBCampo("anio")));
e.Row.Attributes.Add("gMes", string.Format("{0}", e.Row.DBCampo("Mes")));
string navigateurl = "";
switch (GRUPOCve)
{
case 0:
break;
case 1:
danio = string.Format("{0}/01/01", e.Row.DBCampo("anio")).ToDateTime();
danioF = danio.AddYears(1).AddSeconds(-1);
if (RfechaI.ToDateTime() < danio)
{
fechaI = danio.ToString("yyyy/MM/dd");
}
if (RfechaF.ToDateTime() > danioF || RfechaF.Length == 0)
{
fechaF = danioF.ToString("yyyy/MM/dd HH:mm:ss");
}
break;
case 2:
danio = string.Format("{0}/{1}/01", e.Row.DBCampo("anio"), e.Row.DBCampo("Mes").Substring(4)).ToDateTime();
danioF = danio.AddMonths(1).AddSeconds(-1);
if (RfechaI.ToDateTime() < danio)
{
fechaI = danio.ToString("yyyy/MM/dd");
}
if (RfechaF.ToDateTime() > danioF || RfechaF.Length == 0)
{
fechaF = danioF.ToString("yyyy/MM/dd HH:mm:ss");
}
break;
case 3:
danio = string.Format("{0:yyyy/MM/dd}", e.Row.DBCampo("dia")).ToDateTime();
danioF = danio.AddDays(1).AddSeconds(-1);
if (RfechaI.ToDateTime() < danio)
{
fechaI = danio.ToString("yyyy/MM/dd");
}
if (RfechaF.ToDateTime() > danioF || RfechaF.Length == 0)
{
fechaF = danioF.ToString("yyyy/MM/dd HH:mm:ss");
}
break;
default:
break;
}
navigateurl = string.Format("{0}&{3}={1}&{4}={2}", navigateurl, fechaI, fechaF, rqFechaInicio, rqFechaFin);
e.Row.FCHyperLink("HypSIG").NavigateUrl = string.Format("/Ventas/RepConciliacionEmitidosSat.aspx?RegistroEn=1{0}", navigateurl);
e.Row.FCHyperLink("HypSAT").NavigateUrl = string.Format("/Ventas/RepConciliacionEmitidosSat.aspx?RegistroEn=2{0}", navigateurl);
e.Row.FCHyperLink("HypSIGnoSAT").NavigateUrl = string.Format("/Ventas/RepConciliacionEmitidosSat.aspx?RegistroEn=3{0}", navigateurl);
e.Row.FCHyperLink("HypSatnoSIG").NavigateUrl = string.Format("/Ventas/RepConciliacionEmitidosSat.aspx?RegistroEn=4{0}", navigateurl);
}
}
}

View File

@@ -131,22 +131,22 @@
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha Ingreso">
<ItemTemplate>
<asp:Label ID="lblfechaIngreso" runat="server" Text='<%# Eval("FechaIngreso","{0:dd/MM/yyyy HH:mm}")%>'> </asp:Label>
<asp:Label ID="lblfechaIngreso" runat="server" Text='<%# Eval("FechaIngreso","{0:dd/MM/yyyy}")%>' data-toggle="tooltip" title='<%# Eval("FechaIngreso","{0:dd/MM/yyyy HH:mm}")%>'> </asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="id Solicitud">
<asp:TemplateField HeaderText="id Solicitud" Visible="false">
<ItemTemplate>
<asp:Label ID="lblidSolicitud" runat="server" Text='<%# Eval("idSolicitud")%>'> </asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha Inicio Solicitud">
<ItemTemplate>
<asp:Label ID="lblfechaInicioSolicitud" runat="server" Text='<%# Eval("FechaInicioSolicitud","{0:dd/MM/yyyy HH:mm}")%>'> </asp:Label>
<asp:Label ID="lblfechaInicioSolicitud" runat="server" Text='<%# Eval("FechaInicioSolicitud","{0:dd/MM/yyyy}")%>' data-toggle="tooltip" title='<%# Eval("FechaInicioSolicitud","{0:dd/MM/yyyy HH:mm}")%>'> </asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha Fin Solicitud">
<ItemTemplate>
<asp:Label ID="lblfechaFinSolicitud" runat="server" Text='<%# Eval("FechaFinSolicitud","{0:dd/MM/yyyy HH:mm}")%>'> </asp:Label>
<asp:Label ID="lblfechaFinSolicitud" runat="server" Text='<%# Eval("FechaFinSolicitud","{0:dd/MM/yyyy}")%>' data-toggle="tooltip" title='<%# Eval("FechaFinSolicitud","{0:dd/MM/yyyy HH:mm}")%>'> </asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Estatus">
@@ -199,7 +199,7 @@
</div>
</div>
<div class="row">
<div class="col-sm-3 ">
<%--<div class="col-sm-3 ">
Fecha Inicio:
</div>
<div class="col-sm-6">
@@ -224,8 +224,8 @@
<span class="input-group-btn"><a class="btn default lnkFechaFAdd"><i class="fa fa-calendar"></i></a></span>
</div>
</div>
<%--<div class="col-md-4" data-date-format="dd/mm/yyyy" style ="padding-right: 0px;">
</div>--%>
<div class="col-md-4" data-date-format="dd/mm/yyyy" style ="padding-right: 0px;">
<div class="form-group form-md-line-input form-md-floating-label input-iconright">
<asp:TextBox ID="txtFechaIAdd" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10"></asp:TextBox>
<asp:Label runat="server" Text="Fecha Inicio" AssociatedControlID="txtFechaIAdd"></asp:Label>
@@ -258,6 +258,7 @@
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender3" runat="server" HighlightCssClass="vco" TargetControlID="rfvFechaFAdd" Width="350px"></ajax:ValidatorCalloutExtender>
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender4" runat="server" HighlightCssClass="vco" TargetControlID="cvFechaFAdd" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
<%--
<div class="col-md-2" style ="padding-top: 14px;padding-left: 0px;">
<div class="input-group input-sm input-small date date-picker " style ="padding-left: 0px;" data-date-format="dd/mm/yyyy" >
<span class="input-group-btn ">

View File

@@ -92,8 +92,8 @@ public partial class Ventas_SolicitudesSAT : ClsPaginas
protected void LnkSolicitarCFDI_Click(object sender, EventArgs e)
{
string FechaI = string.Format("{0:yyyy-MM-ddTHH}:{0:mm}:{0:ss}", txtFechaIAdd.Text.ToDateTime());
string FechaF = string.Format("{0:yyyy-MM-ddTHH}:{0:mm}:{0:ss}", txtFechaFAdd.Text.ToDateTime());
string FechaI = string.Format("{0:yyyy-MM-dd}T00:00:00", txtFechaIAdd.Text.ToDateTime());
string FechaF = string.Format("{0:yyyy-MM-dd}T23:59:59", txtFechaFAdd.Text.ToDateTime());
string direxe = string.Format("{0}{1}", AppDomain.CurrentDomain.BaseDirectory, "Utilerias\\ADSUtilerias.exe");

File diff suppressed because it is too large Load Diff

View File

@@ -2522,7 +2522,9 @@ Partial Class Ventas
DivMesesSinIntereses.Visible = True
DivDdlCuentaTarjetaCredito.Attributes.Add("class", "col-md-4")
DivContadoOtros.Visible = True
TrKilometraje.Visible = True
TrPedido.Visible = False
' TrKilometrajeTxt.Visible = True
End If
End If
@@ -2575,12 +2577,15 @@ Partial Class Ventas
If ObjPVenta.DtResultados.Rows.Count > 0 Then
CveCorte = ObjPVenta.CveCorte
LblEstatusCaja.Text = ObjPVenta.FechaInicial.ToShortDateString
LblTurno.Text = ObjPVenta.FechaInicial.ToShortDateString
TrEstatusCaja.Visible = True
BtnIniciarTurno.Visible = False
LkbEstadodeCaja.Visible = True
LkbIngreso.Visible = True
LkbRetiro.Visible = True
UpTurno.Visible = True
Else
UpTurno.Visible = False
'Ingresar un nuevo Turno
RegistraScript("window.onload = function MuestraCorteCaja() { document.getElementById(""C_btnShow"").click(); }")
End If
@@ -3839,7 +3844,7 @@ Partial Class Ventas
HdnIVAOriginal.Value = TxtIVA.Text
TxtPedidoContrato.Text = DbRowVenta("PedidoContrato").ToString
TxtPedidoContrato.Enabled = False
TxtKilometraje.Text = DbRowVenta("Kilometraje").ToString
HdnAmortizacion.Value = LblAmort.Text.ToDouble.ToString
HdnSubTotalDescuestos.Value = (TxtSubTotal.Text.Replace(",", "").ToDouble - LblDescuentos.Text.Replace(",", "").ToDouble - LblAmortizacion.Text.Trim.Replace(",", "").ToDouble - TxtRetISR.Text.Replace(",", "").ToDouble).FormatoNumero(2)
@@ -4108,6 +4113,7 @@ Partial Class Ventas
'Sección Detalle
DdlMoneda.Enabled = False
DdlTipoRetencion.Enabled = False
TxtFechaEjecucion.ReadOnly = True
ImgCalendarFechaEje.Enabled = False
'DdlSucursalEjecucion.Enabled = False
@@ -4696,6 +4702,9 @@ Partial Class Ventas
ViewState("ClienteRetIVA") = ObjCliente.RetIVA / 100
ViewState("ClienteRetISR") = ObjCliente.RetISR / 100
DdlTipoRetencion.SelectedValueExist(ObjCliente.DtResultados(0)("CveTipoRetencion").ToString)
DdlTipoRetencion_SelectedIndexChanged(DdlTipoRetencion, EventArgs.Empty)
ViewState("RetIVAFletes") = ObjCliente.RetieneIVAFletes
If ObjCliente.RetieneIVAFletes Then
TrRetIVA.Style.Add("display", "")
@@ -5611,6 +5620,9 @@ Partial Class Ventas
'LO NO PERMITIDO MODIFICAR
e.Row.FCDropDownList("DdlUnidadMedida").Enabled = False
If UsuarioActual.CveEmpresa = 119 Then
e.Row.FCTextBox("TxtCantidad").Enabled = False
End If
'e.Row.FCDropDownList("DdlClasificacion").Enabled = False
'e.Row.FCDropDownLost("DdlPS").Enabled = False
@@ -5914,6 +5926,20 @@ Partial Class Ventas
Dim TotalCalculableImpuestosIVA As Decimal = 0
TotalCalculableImpuestosIVA = TotalCalculableImpuestos * (1 + TmpDT.Rows(e.RowIndex)("PorcentajeIEPS").ToString.ToDecimal)
Dim ClienteRetIVA = Me.ClienteRetIVA
If UsuarioActual.Empresa.Funcionalidad(579) = "1" Then
If DdlTipoRetencion.SelectedValue.Contiene("1", "2") Then
ClienteRetIVA = 0.1D
ElseIf DdlTipoRetencion.SelectedValue.Contiene("3") Then
ClienteRetIVA = 0.04D
ElseIf DdlTipoRetencion.SelectedValue.Contiene("4") Then
ClienteRetIVA = 0.06D
End If
LblRetIVA.Text = (ClienteRetIVA * 100).FormatoNumero
DdlTipoRetencion.Visible = True
End If
TmpDT.Rows(e.RowIndex)("CveUM") = GvPS.Rows(e.RowIndex).FCDropDownList("DdlUnidadMedida").SelectedValue.ToEntero
TmpDT.Rows(e.RowIndex)("UM") = GvPS.Rows(e.RowIndex).FCDropDownList("DdlUnidadMedida").SelectedItem.Text
@@ -6456,22 +6482,32 @@ Partial Class Ventas
End If
'Valida si en caso de que el detalle tenga llantas o polizas se agreguén kilometraje/serie en la parte de observaciones(solo para el caso de empresas llanteras)
If UsuarioActual.Empresa.Funcionalidad(558) = "1" Then
If txtkilometraje.text.toentero = 0 Then
'cuando es la clasificacion de llantas
Dim FaltaObservacion As Integer = TmpDT.FiltroPrimeroValor("CveClasificacion", "CveClasificacion = 20342").ToEntero
If FaltaObservacion = 20342 Then
Alert("No se ha especificado el <strong>kilometraje</strong>.", TipoMensaje.MsgAdvertencia)
Exit Sub
End If
End If
If TxtObsFact.Text = "" Then
Dim FaltaObservacion As Integer = -1
For Each PS As GridViewRow In GvPS.Rows
Dim PsRenglon As GridViewRow = PS
Dim CveClasificacion As Integer = PsRenglon.DataKey("CveClasificacion").ToEntero
If CveClasificacion = 20345 Or CveClasificacion = 20342 Then
FaltaObservacion = CveClasificacion
Exit For
End If
Next
'For Each PS As GridViewRow In GvPS.Rows
' Dim PsRenglon As GridViewRow = PS
' Dim CveClasificacion As Integer = PsRenglon.DataKey("CveClasificacion").ToEntero
' If CveClasificacion = 20345 Or CveClasificacion = 20342 Then
' FaltaObservacion = CveClasificacion
' Exit For
' End If
'
FaltaObservacion = TmpDT.FiltroPrimeroValor("CveClasificacion", "CveClasificacion = 20345").ToEntero
'cuando es la clasificacion de polizas
If FaltaObservacion = 20345 Then
Alert("No se ha especificado la <strong>serie</strong> para la poliza en la sección de Observaciones", TipoMensaje.MsgAdvertencia)
Exit Sub
ElseIf FaltaObservacion = 20342 Then
Alert("No se ha especificado el <strong>kilometraje</strong> para la llanta en el sección de Observaciones", TipoMensaje.MsgAdvertencia)
Exit Sub
End If
End If
End If
@@ -6704,6 +6740,23 @@ Partial Class Ventas
GuardarVenta(ObjVentas, ObjConta, ObjInventario, ObjContr, ObjFactura, TmpDT, ObjFactura.CveNCaVincular, ObjContPaq, ObjBancos, ObjOS,
ObjEventos, ObjCGame, ObjClientes, EsNCAmortizacion:=EsNCAmortizacion)
'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
Dim CveVentaDetalle As Integer = 0
Dim CveOrdenCompraDetalle As Integer = 0
Dim Cantidad As Decimal = 0
For Each row As DataRow In TmpDT.Rows
Cantidad = row("Cantidad").ToString.ToDecimal
CveVentaDetalle = row("CveVentaDetalle").ToString.ToEntero
CveOrdenCompraDetalle = row("CveOrdenCompraDetalle").ToString.ToEntero
If Not ObjVentas.AgregarVentaOCDetalle(CveVentaDetalle, CveOrdenCompraDetalle, Cantidad) Then
ErrorList.Add("Ocurrió un Error al agregar el detalle de la Remision")
Exit For
End If
Next
End If
'SI ES REFACTURACION
Dim ObjNC As List(Of Object) = Nothing
If ErrorList.Count = 0 Then
@@ -6723,7 +6776,6 @@ Partial Class Ventas
End If
End If
End If
End If
End If
@@ -6789,24 +6841,6 @@ Partial Class Ventas
End If
End If
'Agregamos las OCs a la tabla
If DTOrdenesCompraPS IsNot Nothing AndAlso DTOrdenesCompraPS.Rows.Count > 0 AndAlso ErrorList.Count = 0 Then
Dim CveVentaDetalle As Integer = 0
Dim CveOrdenCompraDetalle As Integer = 0
Dim Cantidad As Decimal = 0
For Each row As DataRow In TmpDT.Rows
Cantidad = row("Cantidad").ToString.ToDecimal
CveVentaDetalle = row("CveVentaDetalle").ToString.ToEntero
CveOrdenCompraDetalle = row("CveOrdenCompraDetalle").ToString.ToEntero
If Not ObjVentas.AgregarVentaOCDetalle(CveVentaDetalle, CveOrdenCompraDetalle, Cantidad) Then
ErrorList.Add("Ocurrió un Error al agregar el detalle de la Remision")
End If
Next
End If
'Agregamos las Cotizaciones a la tabla
If DtCotizacionesPS IsNot Nothing AndAlso DtCotizacionesPS.Rows.Count > 0 AndAlso ErrorList.Count = 0 Then
Dim CveVentaDetalle As Integer = 0
@@ -6828,8 +6862,6 @@ Partial Class Ventas
Next
End If
'Marcamos las ventas anteriores a febrero como surtidas - Ajuste Compu
If ErrorList.Count = 0 Then
If Not ObjVentas.MarcarRemisionesSinSurtir(ObjVentas.CveVenta) Then
@@ -7579,10 +7611,10 @@ Partial Class Ventas
End Function
Private Sub CreaObjetosVenta(Optional VistaPrevia As Boolean = False)
Private Sub CreaObjetosVenta(Optional VistaPrevia As Boolean = False, Optional EsCancelacion As Boolean = False)
If Me.CveVenta > 0 AndAlso NuevaFactura <> 1 Then
ObjFactura = New Modelos.Factura(UsuarioActual, CveVenta, UsuarioActual.CveEmpresa)
ObjFactura = New Modelos.Factura(UsuarioActual, CveVenta, UsuarioActual.CveEmpresa, EsCancelacion:=EsCancelacion)
Else
ObjFactura = New Modelos.Factura
End If
@@ -7723,15 +7755,21 @@ Partial Class Ventas
'CONVERTIR REMISION - TIPO MONEDA -DOLARES A PESOS
If (ObjFactura.CveMoneda = 2 AndAlso ObjFactura.ConvertirPesos = True AndAlso ObjFactura.TipodeComprobante = "Ingresos" AndAlso RemisionesLista.Count > 0) Then
Dim TotalCalculableImpuestos, TotalCalculableImpuestosIVA As Decimal
For Each Row As DataRow In TmpDT.Rows
Row("PU") = Math.Round(Row("PU").ToString.ToDouble * ObjFactura.TipoCambio, 6)
Row("PU") = Math.Round(Row("PU").ToString.ToDecimal * ObjFactura.TipoCambio, 6)
Row("Descuento") = Math.Round(Row("Descuento").ToString.ToDouble * ObjFactura.TipoCambio, NumeroDecimales)
TotalCalculableImpuestos = (Row("Cantidad").ToString.ToDecimal * Row("PU").ToString.ToDecimal) - Row("Descuento").ToString.ToDecimal
TotalCalculableImpuestosIVA = TotalCalculableImpuestos * (1 + Row("PorcentajeIEPS").ToString.ToDecimal)
Row("IVA") = Row("PorcentajeIVA")
Row("ImporteIVA") = Math.Round(Row("PorcentajeIVA").ToString.ToDecimal * TotalCalculableImpuestosIVA, NumeroDecimales)
Row("ImporteRetIVA") = Math.Round(ClienteRetIVA * TotalCalculableImpuestos, NumeroDecimales)
Row("ImporteRetISR") = Math.Round(ClienteRetISR * TotalCalculableImpuestos, NumeroDecimales)
Row("ImporteIEPS") = Math.Round(Row("PorcentajeIEPS").ToString.ToDecimal * TotalCalculableImpuestos, NumeroDecimales)
Row("IEPS") = Row("ImporteIEPS")
Row("Total") = Math.Round(Row("Cantidad").ToString.ToDouble * Row("PU").ToString.ToDouble, NumeroDecimales)
Row("TotalImporte") = Math.Round(Row("Cantidad").ToString.ToDouble * Row("PU").ToString.ToDouble, NumeroDecimales)
Row("Descuento") = Math.Round(Row("Descuento").ToString.ToDouble * ObjFactura.TipoCambio, NumeroDecimales)
Row("ImporteRetIVA") = Math.Round(Row("ImporteRetIVA").ToString.ToDouble * ObjFactura.TipoCambio, NumeroDecimales)
Row("ImporteRetISR") = Math.Round(Row("ImporteRetISR").ToString.ToDouble * ObjFactura.TipoCambio, NumeroDecimales)
Row("ImporteIVA") = Math.Round(Row("ImporteIVA").ToString.ToDouble * ObjFactura.TipoCambio, NumeroDecimales)
Row("ImporteIEPS") = Math.Round(Row("ImporteIEPS").ToString.ToDouble * ObjFactura.TipoCambio, NumeroDecimales)
Next
Dim ImpuestosLocales As Double = 0
@@ -7799,21 +7837,28 @@ Partial Class Ventas
'CONVERTIR REMISION - TIPO MONEDA -DOLARES A PESOS REGISTRO DIRECTO SIN VENTA
ElseIf (EditoRemision = False AndAlso ObjFactura.CveMoneda = 2 AndAlso ObjFactura.ConvertirPesos = True) Then
Dim TotalCalculableImpuestos, TotalCalculableImpuestosIVA As Decimal
For Each Row As DataRow In TmpDT.Rows
Row("PU") = Math.Round(Row("PU").ToString.ToDouble * ObjFactura.TipoCambio, 6)
Row("PU") = Math.Round(Row("PU").ToString.ToDecimal * ObjFactura.TipoCambio, 6)
Row("Descuento") = Math.Round(Row("Descuento").ToString.ToDouble * ObjFactura.TipoCambio, NumeroDecimales)
TotalCalculableImpuestos = (Row("Cantidad").ToString.ToDecimal * Row("PU").ToString.ToDecimal) - Row("Descuento").ToString.ToDecimal
TotalCalculableImpuestosIVA = TotalCalculableImpuestos * (1 + Row("PorcentajeIEPS").ToString.ToDecimal)
Row("IVA") = Row("PorcentajeIVA")
Row("ImporteIVA") = Math.Round(Row("PorcentajeIVA").ToString.ToDecimal * TotalCalculableImpuestosIVA, NumeroDecimales)
Row("ImporteRetIVA") = Math.Round(ClienteRetIVA * TotalCalculableImpuestos, NumeroDecimales)
Row("ImporteRetISR") = Math.Round(ClienteRetISR * TotalCalculableImpuestos, NumeroDecimales)
Row("ImporteIEPS") = Math.Round(Row("PorcentajeIEPS").ToString.ToDecimal * TotalCalculableImpuestos, NumeroDecimales)
Row("IEPS") = Row("ImporteIEPS")
Row("Total") = Math.Round(Row("Cantidad").ToString.ToDouble * Row("PU").ToString.ToDouble, NumeroDecimales)
Row("TotalImporte") = Math.Round(Row("Cantidad").ToString.ToDouble * Row("PU").ToString.ToDouble, NumeroDecimales)
Row("Descuento") = Math.Round(Row("Descuento").ToString.ToDouble * ObjFactura.TipoCambio, NumeroDecimales)
Row("ImporteRetIVA") = Math.Round(Row("ImporteRetIVA").ToString.ToDouble * ObjFactura.TipoCambio, NumeroDecimales)
Row("ImporteRetISR") = Math.Round(Row("ImporteRetISR").ToString.ToDouble * ObjFactura.TipoCambio, NumeroDecimales)
Row("ImporteIVA") = Math.Round(Row("ImporteIVA").ToString.ToDouble * ObjFactura.TipoCambio, NumeroDecimales)
Row("ImporteIEPS") = Math.Round(Row("ImporteIEPS").ToString.ToDouble * ObjFactura.TipoCambio, NumeroDecimales)
Next
Dim ImpuestosLocales As Double = 0
For Each gvr As GridViewRow In GvImpuestosLocales2.Rows
If gvr.RowType = DataControlRowType.DataRow Then
gvr.FCTextBox("TxtImpuestoLocalPS").Text = (gvr.FCTextBox("TxtImpuestoLocalPS").Text.ToDouble * ObjFactura.TipoCambio).FormatoNumero
gvr.FCTextBox("TxtImpuestoLocalPS").Text = (gvr.FCTextBox("TxtImpuestoLocalPS").Text.ToDecimal * ObjFactura.TipoCambio).FormatoNumero
ImpuestosLocales += Math.Round(gvr.FCTextBox("TxtImpuestoLocalPS").Text.ToDouble * ObjFactura.TipoCambio, NumeroDecimales)
End If
Next
@@ -9037,7 +9082,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, TmpDTDetalle As DataTable, CveNCaVincular As Integer,
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)
@@ -9108,8 +9153,9 @@ Partial Class Ventas
PedidoContrato:=TxtPedidoContrato.Text, ObservacionesAlmacen:=TxtObsAlmacen.Text, CveSubProyecto:=factura.CveSubProyecto, CveSubProyectoCobranza:=factura.CveSubProyectoCobranza, CveSubProyectoEjecucion:=factura.CveSubProyectoEjecucion, CveFormaPago33:=factura.CveFormaPago33,
CveMetodoPago33:=factura.CveMetodoPago33, CveUsoCFDI:=factura.CveUsoCFDI, OrdenCompra:=TxtOrdenCompra.Text, CveCuentaTerminal:=DdlCuentasTerminal.SelectedValue.ToEntero, CveTipoRelacion:=factura.CveTipoRelacion, ImpuestoLocal:=TotalImpuestoLocal,
CveVentaRelacion:=(If(factura.CveVentaRelacion.ToEntero > 0, factura.CveVentaRelacion, -1)), ImporteRelacion:=(If(factura.ImporteRelacion <> Nothing, factura.ImporteRelacion, -1)),
CveTipoAmortizacionAnticipo:=factura.CveTipoAmortizacionAnticipo, CveEmpresaCRM:=CveEmpresaCRM, EsInterno:=EsInterno, CveAcercamientoCRM:=CveAcercamientoCRM,
DiasCredito:=factura.DiasCredito, EsDiasCreditoFijo:=factura.EsDiasCreditoFijo, AnticipoEspecial:=If(TrAntEspecial.Visible, ChkAntEspecial.Checked, False)) Then
CveTipoAmortizacionAnticipo:=factura.CveTipoAmortizacionAnticipo, CveEmpresaCRM:=CveEmpresaCRM, EsInterno:=EsInterno, CveAcercamientoCRM:=CveAcercamientoCRM,
DiasCredito:=factura.DiasCredito, EsDiasCreditoFijo:=factura.EsDiasCreditoFijo, AnticipoEspecial:=If(TrAntEspecial.Visible, ChkAntEspecial.Checked, False),
Kilometraje:=TxtKilometraje.Text.todouble) Then
ErrorList.Add("Ocurrió un error al Generar la Venta.<br />Revise su factura y cualquier detalle comuníquese a Soporte Técnico")
@@ -9171,7 +9217,7 @@ Partial Class Ventas
End If
End If
Dim TmpDr As DataRow = TmpDT.Select($"Consec = {Row("Consec").ToString}")(0)
Dim TmpDr As DataRow = TmpDTDetalle.Select($"Consec = {Row("Consec").ToString}")(0)
TmpDr("CveVentaDetalle") = ObjVentas.CveVentaDetalle
Try
@@ -9342,7 +9388,7 @@ Partial Class Ventas
Cantidad = DtPedidos2TmpDT.FiltroPrimeroValor("Cantidad", $"CveVentaDetallePedido2={row("CveVentaDetalle")}").ToDecimal
CvePS = DtPedidos2TmpDT.FiltroPrimeroValor("CvePS", $"CveVentaDetallePedido2={row("CveVentaDetalle")}").ToEntero
PU = DtPedidos2TmpDT.FiltroPrimeroValor("PU", $"CveVentaDetallePedido2={row("CveVentaDetalle")}").ToDecimal
CveVentaDetalle = TmpDT.FiltroPrimeroValor("CveVentaDetalle", $"CveVentaDetallePedido2={row("CveVentaDetalle")}").ToEntero
CveVentaDetalle = TmpDTDetalle.FiltroPrimeroValor("CveVentaDetalle", $"CveVentaDetallePedido2={row("CveVentaDetalle")}").ToEntero
CveVentaDetallePadre = row("CveVentaDetalle").ToString.ToEntero
If Not ObjVentas.AddVentaDetallePedido2(CveVentaDetalle, CveVentaDetallePadre, Cantidad) Then
@@ -9393,6 +9439,7 @@ Partial Class Ventas
End If
End Sub
Private Sub GuardarVentaPrePolizas(ByRef ObjConta As ClsContabilidad, factura As Modelos.Factura, TmpDTDetalleMovimientos As DataTable, CveNCaVincular As Integer,
ByRef objContPaqi As ClsContPAQi, Optional ByRef ObjBancos As ClsBancos = Nothing, ByRef Optional ObjVentas As ClsVentas = Nothing,
ByRef Optional ObjEventos As ClsOIEventos = Nothing, Optional EsNCAmortizacion As Boolean = False, Optional NCDescuento As Boolean = False)
@@ -10259,7 +10306,9 @@ Partial Class Ventas
If tipoCambio > 1 Then Concepto += $" TC:{tipoCambio} ${importeMovimiento.FormatoNumero(2)}"
'Nota cuando es Nota de crédiot, debe de tomar el devoluciones y rebajas
If ObjFactura.TipoDocto.Contiene("Egs", "Dev") Then
IdCtaContable = GlobalDTClasificaciones(ObjFactura.CveEmpresa).FiltroPrimeroValor("IdCuentaGasto", String.Format("CveClasificacion = {0}", Row2("CveClasificacion"))).ToEntero
Dim CampoCuenta As String = "IdCuentaGasto"
If UsuarioActual.CveEmpresa.Contiene(80, 72, 146) Then CampoCuenta = "IdCuentaDescuento"
IdCtaContable = GlobalDTClasificaciones(ObjFactura.CveEmpresa).FiltroPrimeroValor(CampoCuenta, String.Format("CveClasificacion = {0}", Row2("CveClasificacion"))).ToEntero
Else
IdCtaContable = GlobalDTClasificaciones(ObjFactura.CveEmpresa).FiltroPrimeroValor("IdCuentaIngresos", String.Format("CveClasificacion = {0}", Row2("CveClasificacion"))).ToEntero
End If
@@ -13827,10 +13876,12 @@ Partial Class Ventas
If DtPromociones.Rows.Count > 0 And DtPromociones IsNot Nothing Then
Dim dr As DataRow = DtPromociones.FiltroPrimero($"CvePS = {CvePS}")
TipoPromo = dr("TipoPromocion").ToString.ToEntero
TotalPromocion = dr("PUPromocion").ToString.ToDecimal * TxtCantidad.Text.ToDecimal
PromocionPorcentaje = dr("Promocion").ToString.ToDecimal
CantMinima = dr("CantidadMinima").ToString.ToEntero
If dr IsNot Nothing Then
TipoPromo = dr("TipoPromocion").ToString.ToEntero
TotalPromocion = dr("PUPromocion").ToString.ToDecimal * TxtCantidad.Text.ToDecimal
PromocionPorcentaje = dr("Promocion").ToString.ToDecimal
CantMinima = dr("CantidadMinima").ToString.ToEntero
End If
End If
If TipoPromo = 1 Then 'Promocion por Importe $
@@ -14194,6 +14245,20 @@ Partial Class Ventas
Row("PorcentajeIVA") = DrPS("IVA")
End If
Dim ClienteRetIVA = Me.ClienteRetIVA
If UsuarioActual.Empresa.Funcionalidad(579) = "1" Then
If DdlTipoRetencion.SelectedValue.Contiene("1", "2") Then
ClienteRetIVA = 0.1D
ElseIf DdlTipoRetencion.SelectedValue.Contiene("3") Then
ClienteRetIVA = 0.04D
ElseIf DdlTipoRetencion.SelectedValue.Contiene("4") AndAlso DrPS("CveTipoPS").ToString().ToEntero() = 1 Then
ClienteRetIVA = 0.06D
End If
LblRetIVA.Text = (ClienteRetIVA * 100).FormatoNumero
DdlTipoRetencion.Visible = True
End If
Row("IVA") = Row("PorcentajeIVA")
Row("ImporteIVA") = Math.Round(Row("PorcentajeIVA").ToString.ToDecimal * TotalCalculableImpuestosIVA, NumeroDecimales)
Row("ImporteRetIVA") = Math.Round(ClienteRetIVA * TotalCalculableImpuestos, NumeroDecimales)
@@ -14255,7 +14320,8 @@ Partial Class Ventas
'AGREGA PS ADICIONAL
If UsuarioActual.Empresa.Funcionalidad(561).ToString = "1" AndAlso GlobalDTPSAdicionales(CvePS, UsuarioActual.CveEmpresa).Rows.Count > 0 AndAlso Not SeActualiza Then
If UsuarioActual.Empresa.Funcionalidad(561).ToString = "1" AndAlso Not UsuarioActual.TienePermisoProceso(285) AndAlso GlobalDTPSAdicionales(CvePS, UsuarioActual.CveEmpresa).Rows.Count > 0 AndAlso Not SeActualiza Then
For Each Dr As DataRow In GlobalDTPSAdicionales(CvePS, UsuarioActual.CveEmpresa).Rows
Dim CvePSAdicional As Integer = Dr("CvePSAdicional").ToString.ToEntero
Dim DrPoliza As DataRow = TmpDT.NewRow()
@@ -14337,6 +14403,8 @@ Partial Class Ventas
TmpDT.Rows.Add(DrPoliza)
End If
Next
End If
Retorno = True
@@ -15354,6 +15422,7 @@ Partial Class Ventas
If UsuarioActual.Empresa.Funcionalidad(575) = "1" Then
CveConceptoSalidaAlmacen = 40
CveAlmacenParaSalida = CveAlmacenSalida
AplicaMovimientoDetalleEntrada = True
''Le damos salida normal
'If ConSalida Then
' GeneroMovimientoAlmacen = GenerarMovimientoAlmacen(ObjInventario, MovDetalle, CveAlmacenSalida, 40, CveMoneda, CveVenta, AplicaMovimientoDetalleEntrada:=AplicaMovimientoDetalleEntrada, MovimientoPrePoliza:=True, ObjConta:=ObjConta) > 0
@@ -15380,7 +15449,7 @@ Partial Class Ventas
'Le damos entrada al general por traspaso
If Not OcurrioError Then
GeneroMovimientoAlmacen = GenerarMovimientoAlmacen(ObjInventario, MovDetalle, CveAlmacenEntrada, 9, CveMoneda, CveRemision, CveMovimientoRelacionado:=CveMovimientoSalidaPorTraspaso) > 0
GeneroMovimientoAlmacen = GenerarMovimientoAlmacen(ObjInventario, MovDetalle, CveAlmacenEntrada, 9, CveMoneda, CveRemision, CveMovimientoRelacionado:=CveMovimientoSalidaPorTraspaso, AplicaMovimientoDetalleEntrada:=AplicaMovimientoDetalleEntrada) > 0
If Not GeneroMovimientoAlmacen Then
OcurrioError = True
@@ -15398,7 +15467,7 @@ Partial Class Ventas
End If
If Not OcurrioError Then
GeneroMovimientoAlmacen = GenerarMovimientoAlmacen(ObjInventario, MovDetalle, CveAlmacenParaSalida, CveConceptoSalidaAlmacen, CveMoneda, ObjFactura.CveVenta, MovimientoPrePoliza:=True, ObjConta:=ObjConta) > 0
GeneroMovimientoAlmacen = GenerarMovimientoAlmacen(ObjInventario, MovDetalle, CveAlmacenParaSalida, CveConceptoSalidaAlmacen, CveMoneda, ObjFactura.CveVenta, AplicaMovimientoDetalleEntrada:=AplicaMovimientoDetalleEntrada, MovimientoPrePoliza:=True, ObjConta:=ObjConta) > 0
If Not GeneroMovimientoAlmacen Then
OcurrioError = True
@@ -15523,6 +15592,12 @@ Partial Class Ventas
Dim OcurrioError As Boolean = False
Dim ContadorMovtosDetalles = 0
'If Not AplicaMovimientoDetalleEntrada Then
' Dim rowa As DataRow = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltroPrimero(String.Format("CveAlmacen={0}", CveAlmacen))
' If Not IsNothing(rowa) AndAlso rowa("CveTipoAlmacen").ToString() = "10" Then
' AplicaMovimientoDetalleEntrada = True
' End If
'End If
'Creamos el movimiento
Dim CveMovimientoInventario As Integer = ObjInventario.AddMovimiento(CveAlmacen, ConceptoEntrada, CveMoneda, Now, -1, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1, CveVenta, -1, -1,
CveMovimientoRelacionado:=CveMovimientoRelacionado, Modulo:="Vta/E4")
@@ -16261,7 +16336,7 @@ Partial Class Ventas
Next
'ACTIVA CAMBIO DE CLIENTE - SI NO TIENE NADA FACTURADO
If Not CantidadFacturadaRemision > 0 Then
If Not CantidadFacturadaRemision > 0 AndAlso UsuarioActual.TienePermisoProceso(284) Then
HlCliente.Attributes.Remove("class")
HlCliente.Attributes.Add("class", "Texto")
TxtCodigo.ReadOnly = False
@@ -16375,7 +16450,9 @@ Partial Class Ventas
If Not ObjVentas.UpdateVentas(TxtSubTotal.Text.ToDecimal, LblDescuentos.Text.ToDecimal, TxtIVA.Text.ToDecimal, TxtIEPS.Text.ToDecimal, TxtTotal.Text.ToDecimal, Moneda, TipoCambio, TxtFecha.Text.Trim.ToDate, TxtObsFact.Text.Trim,
UsuarioActual.CveEmpresa, CveVenta, 0, 0,
Vigencia:=TxtFechaVencimientoCotizacion.Text.Trim.ToDate, CondicionesPago:=If(RBLPago.SelectedValue = "2", 0, 1),
PedidoContrato:=TxtPedidoContrato.Text, AtencionA:=TxtAtencionA.Text.Trim, CveMetodoPago33:=DdlMetodoPago33.SelectedValue.ToEntero, CveFormaPago33:=DdlFormaPago33.SelectedValue.ToEntero, TipoDocto:="Rem", CveCliente:=CveCliente, CveClienteSucursal:=CveClienteSucursal, OrdenCompra:=TxtOrdenCompra.Text, RetIVA:=TxtRetIVA.Text.ToDecimal, RetISR:=TxtRetISR.Text.ToDecimal) Then
PedidoContrato:=TxtPedidoContrato.Text, AtencionA:=TxtAtencionA.Text.Trim, CveMetodoPago33:=DdlMetodoPago33.SelectedValue.ToEntero,
CveFormaPago33:=DdlFormaPago33.SelectedValue.ToEntero, TipoDocto:="Rem", CveCliente:=CveCliente, CveClienteSucursal:=CveClienteSucursal,
OrdenCompra:=TxtOrdenCompra.Text, RetIVA:=TxtRetIVA.Text.ToDecimal, RetISR:=TxtRetISR.Text.ToDecimal, Kilometraje:=TxtKilometraje.Text.ToDouble) Then
OcurrioError = True
End If
@@ -18237,6 +18314,10 @@ Partial Class Ventas
Exit Sub
End If
If String.IsNullOrEmpty(Vigencia.EsCancelable) Then
If Not String.IsNullOrEmpty(FolioFiscal) Then
Alert("No se pudo encontrar el estatus de la factura en el SAT.", TipoMensaje.MsgAdvertencia)
Exit Sub
End If
sb.Append("<b>No encontrado</b> <br/>")
Else
sb.AppendFormat("<b>{0}</b> <br/>", Vigencia.EsCancelable)
@@ -18396,7 +18477,8 @@ Partial Class Ventas
CancelarRefacturada()
End If
CreaObjetosVenta()
CreaObjetosVenta(EsCancelacion:=True)
Dim resp As Modelos.Factura.MCancelacionVentaMensaje = Nothing
If ObjFactura IsNot Nothing AndAlso ObjFactura.CveVenta > 0 Then
@@ -18414,9 +18496,6 @@ Partial Class Ventas
End If
ObjFactura.CveAlmacenDevolucion = CveAlmacenDevolucion
If ChkDevAlm.Checked Then
ObjFactura.CveAlmacenDevolucion = CveAlmacenDevolucion
End If
resp = ObjFactura.CancelarFactura(ChkDevAlm.Checked, ListaRemisionesCancelar)
End If
@@ -22043,7 +22122,7 @@ Partial Class Ventas
Vigencia:=TxtFechaVencimientoCotizacion.Text.Trim.ToDate, CondicionesPago:=If(RBLPago.SelectedValue = "2", 0, 1),
PedidoContrato:=TxtPedidoContrato.Text, AtencionA:=TxtAtencionA.Text.Trim, CveMetodoPago33:=DdlMetodoPago33.SelectedValue.ToEntero, CveFormaPago33:=DdlFormaPago33.SelectedValue.ToEntero,
CveCliente:=CveCliente, CveClienteSucursal:=CveClienteSucursal, OrdenCompra:=TxtOrdenCompra.Text, RetIVA:=TxtRetIVA.Text.ToDecimal, RetISR:=TxtRetISR.Text.ToDecimal,
TipoDocto:=DdlTipoComprobante.SelectedValue) Then
TipoDocto:=DdlTipoComprobante.SelectedValue, Kilometraje:=TxtKilometraje.Text.ToDouble) Then
MensajeError = "Ocurrió un error al actualizar la información de la cotización"
OcurrioError = True
End If
@@ -23515,12 +23594,15 @@ Partial Class Ventas
End If
For Each drow As DataRow In TmpDT.Rows
For Each drow2 As DataRow In DTCvePSCostos.Rows
If drow("CvePS").ToString.ToEntero = drow2("CvePSCargo").ToString.ToEntero Then
drow("Eliminar") = 1
Exit For
End If
Next
If DTCvePSCostos IsNot Nothing Then
For Each drow2 As DataRow In DTCvePSCostos.Rows
If drow("CvePS").ToString.ToEntero = drow2("CvePSCargo").ToString.ToEntero Then
drow("Eliminar") = 1
Exit For
End If
Next
End If
Next
Dim TmpDTView As New DataView(TmpDT)
@@ -23817,10 +23899,12 @@ Partial Class Ventas
CargaRNC()
RegistraScript("$('#ModalAplicarRemisionesNC').modal({backdrop: 'static', keyboard: false });")
End Sub
#Region "P O L I Z A - V I R T U A L"
Protected Sub GeneraPolizaVentaWS(ObjFactura As Modelos.Factura)
Dim DtUsados As DataTable = Nothing
Dim ObjAcum As New ClsAcumuladores
If ObjAcum.GetGarantiasDetalle(ObjFactura.CveVenta) Then
If ObjAcum.GetGarantiasPolizaVirtual(ObjFactura.CveVenta) Then
DtUsados = ObjAcum.DtResultados.Copy()
End If
ObjAcum.Dispose()
@@ -23850,8 +23934,8 @@ Partial Class Ventas
obj.sale_id = String.Format("{0}{1}{2}", ObjFactura.Serie, ObjFactura.Folio, ObjFactura.CveVenta)
'DATOS DEL PRODUCTO
obj.product_code = Row("Code17").ToString()
obj.product_unique_code = "" 'se indique el código único de la batería.
obj.product_code = Row("IdProductoPolizaVirtual").ToString()
obj.product_unique_code = Row("SerieLote").ToString() 'se indique el código único de la batería. (SERIE LOTE)
obj.product_sale_type = "01 " 'VENTA
Dim FechaUsado As DateTime = Row("FechaAjuste").ToString().ToDateTime()
@@ -23944,5 +24028,39 @@ Partial Class Ventas
Return Retorno
End Function
#End Region
Protected Sub DdlTipoRetencion_SelectedIndexChanged(sender As Object, e As EventArgs)
If UsuarioActual.Empresa.Funcionalidad(579) = "1" Then
If TmpDT IsNot Nothing AndAlso TmpDT.Rows.Count > 0 Then
For Each RowServicio As DataRow In TmpDT.Rows
Dim ClienteRetIVA = Me.ClienteRetIVA
If DdlTipoRetencion.SelectedValue.Contiene("1", "2") Then
ClienteRetIVA = 0.1D
ElseIf DdlTipoRetencion.SelectedValue.Contiene("3") Then
ClienteRetIVA = 0.04D
ElseIf DdlTipoRetencion.SelectedValue.Contiene("4") AndAlso RowServicio("CveTipoPS").ToString().ToEntero() = 1 Then
ClienteRetIVA = 0.06D
End If
Dim TotalCalculableImpuestos As Decimal = (RowServicio("Cantidad").ToString().ToDecimal() * RowServicio("PU").ToString().ToDecimal()) - RowServicio("Descuento").ToString().ToDecimal()
RowServicio("ImporteRetIVA") = (TotalCalculableImpuestos * ClienteRetIVA).RoundSQL()
RowServicio("PorcentajeRetIVA") = ClienteRetIVA
Next
TxtRetIVA.Text = TmpDT.SUM("ImporteRetIVA").ToDecimal().FormatoNumero(2)
Dim PorcentajeRetIVA = (TmpDT.MAX("PorcentajeRetIVA").ToDecimal() * 100)
LblRetIVA.Text = PorcentajeRetIVA.FormatoNumero(2)
If PorcentajeRetIVA > 0 Then
DdlTipoRetencion.Visible = True
End If
GvPS.DataSource = TmpDT
GvPS.DataBind()
UpPS.Update()
End If
End If
End Sub
End Class

View File

@@ -67,52 +67,52 @@ Public Class WSSIGApp
Application("GlobalDTVtaFormaPago") = value
End Set
End Property
'Property GlobalDTSubProyectos(CveProyecto As Integer, Optional CveSubProyecto As Integer = -1, Optional CveEmpresa As Integer = -1, Optional Estatus As Integer = 1) As DataTable
' Get
Property GlobalDTSubProyectos(CveProyecto As Integer, Optional CveSubProyecto As Integer = -1, Optional CveEmpresa As Integer = -1, Optional Estatus As Integer = 1) As DataTable
Get
' If DirectCast(Application("GlobalDTSubProyectos"), DataTable) Is Nothing Or (DirectCast(Application("GlobalDTSubProyectos"), DataTable) IsNot Nothing AndAlso DirectCast(Application("GlobalDTSubProyectos"), DataTable).Rows.Count = 0) Then
' Dim P As New ClsSubProyectos
' If P.GetSubProyectos Then
' Application("GlobalDTSubProyectos") = P.DtResultados
' End If
' P.Dispose()
If DirectCast(Application("GlobalDTSubProyectos"), DataTable) Is Nothing Or (DirectCast(Application("GlobalDTSubProyectos"), DataTable) IsNot Nothing AndAlso DirectCast(Application("GlobalDTSubProyectos"), DataTable).Rows.Count = 0) Then
Dim P As New ClsSubProyectos
If P.GetSubProyectos Then
Application("GlobalDTSubProyectos") = P.DtResultados
End If
P.Dispose()
' Dim msg As String = "aqui no se carga subproyectos"
' 'If Request IsNot Nothing Then
' ' msg = msg & Request.ServerVariables("URL")
' 'End If
' msg.GuardaLog()
Dim msg As String = "aqui no se carga subproyectos"
'If Request IsNot Nothing Then
' msg = msg & Request.ServerVariables("URL")
'End If
msg.GuardaLog()
' End If
End If
' If CveProyecto <> -1 OrElse CveSubProyecto <> -1 OrElse CveEmpresa <> -1 OrElse Estatus <> -1 Then
' Dim StrSQL As New StringBuilder
' If CveProyecto <> -1 Then StrSQL.AppendFormat(" AND CveProyecto = {0}", CveProyecto)
' If CveSubProyecto <> -1 Then StrSQL.AppendFormat(" AND CveSubProyecto = {0}", CveSubProyecto)
' If Estatus <> -1 Then StrSQL.AppendFormat(" AND CveEstatus = {0}", Estatus)
' If CveEmpresa <> -1 Then StrSQL.AppendFormat(" AND CveEmpresa = {0}", CveEmpresa)
If CveProyecto <> -1 OrElse CveSubProyecto <> -1 OrElse CveEmpresa <> -1 OrElse Estatus <> -1 Then
Dim StrSQL As New StringBuilder
If CveProyecto <> -1 Then StrSQL.AppendFormat(" AND CveProyecto = {0}", CveProyecto)
If CveSubProyecto <> -1 Then StrSQL.AppendFormat(" AND CveSubProyecto = {0}", CveSubProyecto)
If Estatus <> -1 Then StrSQL.AppendFormat(" AND CveEstatus = {0}", Estatus)
If CveEmpresa <> -1 Then StrSQL.AppendFormat(" AND CveEmpresa = {0}", CveEmpresa)
' Dim Dv As New DataView(DirectCast(Application("GlobalDTSubProyectos"), DataTable), StrSQL.ToString.Trim.TrimStart("A"c, "N"c, "D"c), "", DataViewRowState.CurrentRows)
' GlobalDTSubProyectos = Dv.ToTable
' Dv.Dispose()
Dim Dv As New DataView(DirectCast(Application("GlobalDTSubProyectos"), DataTable), StrSQL.ToString.Trim.TrimStart("A"c, "N"c, "D"c), "", DataViewRowState.CurrentRows)
GlobalDTSubProyectos = Dv.ToTable
Dv.Dispose()
' Else
' GlobalDTSubProyectos = DirectCast(Application("GlobalDTSubProyectos"), DataTable)
' End If
Else
GlobalDTSubProyectos = DirectCast(Application("GlobalDTSubProyectos"), DataTable)
End If
' End Get
' Set(ByVal value As DataTable)
' If value Is Nothing OrElse value.Rows.Count = 0 Then
' Dim msg As String = "aqui no se carga subproyectos"
' 'If Request IsNot Nothing Then
' ' msg = msg & Request.ServerVariables("URL")
' 'End If
' msg.GuardaLog()
End Get
Set(ByVal value As DataTable)
If value Is Nothing OrElse value.Rows.Count = 0 Then
Dim msg As String = "aqui no se carga subproyectos"
'If Request IsNot Nothing Then
' msg = msg & Request.ServerVariables("URL")
'End If
msg.GuardaLog()
' End If
' Application("GlobalDTSubProyectos") = value
' End Set
'End Property
End If
Application("GlobalDTSubProyectos") = value
End Set
End Property
Property GlobalDTSATUsosCFDI(Optional EsPersonaFisica As Integer = -1) As DataTable
Get
If EsPersonaFisica <> -1 Then
@@ -151,20 +151,20 @@ Public Class WSSIGApp
Application("GlobalDTUsuarios") = value
End Set
End Property
'Property GlobalDTUnidadesMedida(Optional CveEmpresa As Integer = -1) As DataTable
' Get
' If CveEmpresa <> -1 Then
' Dim Dv As New DataView(DirectCast(Application("GlobalDTUnidadesMedida"), DataTable), String.Format("CveEmpresa = {0}", CveEmpresa), " UnidadMedida", DataViewRowState.CurrentRows)
' GlobalDTUnidadesMedida = Dv.ToTable
' Dv.Dispose()
' Else
' GlobalDTUnidadesMedida = DirectCast(Application("GlobalDTUnidadesMedida"), DataTable)
' End If
' End Get
' Set(value As DataTable)
' Application("GlobalDTUnidadesMedida") = value
' End Set
'End Property
Property GlobalDTUnidadesMedida(Optional CveEmpresa As Integer = -1) As DataTable
Get
If CveEmpresa <> -1 Then
Dim Dv As New DataView(DirectCast(Application("GlobalDTUnidadesMedida"), DataTable), String.Format("CveEmpresa = {0}", CveEmpresa), " UnidadMedida", DataViewRowState.CurrentRows)
GlobalDTUnidadesMedida = Dv.ToTable
Dv.Dispose()
Else
GlobalDTUnidadesMedida = DirectCast(Application("GlobalDTUnidadesMedida"), DataTable)
End If
End Get
Set(value As DataTable)
Application("GlobalDTUnidadesMedida") = value
End Set
End Property
Property GlobalDTGralCategorias(CveEmpresa As Integer) As DataTable
Get
If CveEmpresa <> -1 Then
@@ -2142,7 +2142,7 @@ Public Class WSSIGApp
Timbre.Comprobante.TipoComprobante = If(Obj.TipoDocto.Contiene("Ing", "Ant"), "I", If(Obj.TipoDocto.Contiene("Egs", "Dev"), "E", ""))
Timbre.Comprobante.Folio = Obj.Folio.ToString
Timbre.Comprobante.Serie = Obj.Serie
Timbre.Comprobante.Fecha = Obj.FechaCP
Timbre.Comprobante.Fecha = Obj.Fecha
Timbre.Comprobante.FormadePago = Obj.FormaPagoSAT33
Timbre.Comprobante.CondicionesdePago = Obj.FormaPago33
Timbre.Comprobante.MetodoPago = Obj.ClaveMetodoPagoSAT
@@ -4158,6 +4158,86 @@ Public Class WSSIGApp
Return Events
End Function
<WebMethod>
Public Function GetRepAcercamientos(CveEmpresa As Integer, CveVendedor As Integer, FechaInicio As DateTime, FechaFin As DateTime) As String
Dim Retorno = "[]"
Using ObjCRM As New ClsCRM
If ObjCRM.GetAcercamiento(CveEmpresa, CveVendedor:=CveVendedor, FechaInicio:=FechaInicio, FechaFin:="-1") Then
Retorno = ObjCRM.DtResultados.DataTableToJSONIPP()
End If
End Using
Return Retorno
End Function
<WebMethod>
Public Function GetRepAcercamientosProcesos(CveEmpresa As Integer, AgrupadoPor As Integer, CveTipoProceso As Integer, CveVendedor As Integer, CveMedioCaptacion As Integer, CveProbabilidadAcercamiento As Integer, FechaInicio As DateTime, FechaFin As DateTime) As String
Dim Retorno As New JObject()
' <asp:ListItem Value = "-1" Text="Ninguno" Selected="True"></asp: ListItem>
' <asp:ListItem Value="1" Text="Vendedor"></asp:ListItem>
'<asp:ListItem Value = "2" Text="Medio Captacion"></asp: ListItem>
' <asp:ListItem Value="3" Text="Probabilidad de Acercamiento"></asp:ListItem>
'<asp:ListItem Value = "4" Text="Fecha"></asp: ListItem>
Dim idgrupo2 = -1
Dim FechaI = FechaInicio.ToString("yyyy/MM/dd")
Dim FechaF = FechaFin.ToString("yyyy/MM/dd")
Select Case AgrupadoPor
Case 1
Retorno("Agrupado") = "Vendedor"
Case 2
Retorno("Agrupado") = "Medio Captación"
Case 3
Retorno("Agrupado") = "Probabilidad de Acercamiento"
Case 4
Retorno("Agrupado") = "Fecha"
End Select
Using ObjCRM As New ClsCRM
If ObjCRM.RepAcercamientosEtapas(CveEmpresa, CveTipoProceso, AgrupadoPor, idgrupo2, FechaI, FechaF, CveVendedor, CveMedioCaptacion, cveProbabilidadAcercamiento) Then
Dim Reporte = JArray.Parse(ObjCRM.DSResultados.Tables(0).DataTableToJSONIPP())
Dim Etapas = JArray.Parse(ObjCRM.DSResultados.Tables(1).DataTableToJSONIPP())
Dim Visible1 As Boolean = Etapas.Any(Function(etapa) etapa("Orden").ToString().ToEntero() = 0)
Dim Visible2 As Boolean = Etapas.Any(Function(etapa) etapa("Orden").ToString().ToEntero() = 1)
Dim Visible3 As Boolean = Etapas.Any(Function(etapa) etapa("Orden").ToString().ToEntero() = 2)
Dim Visible4 As Boolean = Etapas.Any(Function(etapa) etapa("Orden").ToString().ToEntero() = 3)
Dim Visible5 As Boolean = Etapas.Any(Function(etapa) etapa("Orden").ToString().ToEntero() = 4)
Dim Visible6 As Boolean = Etapas.Any(Function(etapa) etapa("Orden").ToString().ToEntero() = 5)
For Each Rep As JObject In Reporte
Rep("Visible1") = Visible1
Rep("Visible2") = Visible2
Rep("Visible3") = Visible3
Rep("Visible4") = Visible4
Rep("Visible5") = Visible5
Rep("Visible6") = Visible6
Next
Retorno("Reporte") = Reporte
Retorno("Etapas") = Etapas
End If
End Using
Return Retorno.ToString()
End Function
<WebMethod>
Public Function GetRepAcercamientosRechazos(CveEmpresa As Integer, CveVendedor As Integer, FechaInicio As DateTime, FechaFin As DateTime) As String
Dim Retorno = "[]"
Dim cveTipoProceso = -1
Dim idgrupo1 = 1
Dim idgrupo2 = -1
Dim FechaI = FechaInicio.ToString("yyyy/MM/dd")
Dim FechaF = FechaFin.ToString("yyyy/MM/dd")
Dim cveMedioCaptacion = -1
Dim cveProbabilidadAcercamiento = -1
Using ObjCRM As New ClsCRM
If ObjCRM.RepAcercamientosEtapas(CveEmpresa, cveTipoProceso, idgrupo1, idgrupo2, FechaI, FechaF, CveVendedor, cveMedioCaptacion, cveProbabilidadAcercamiento) Then
Retorno = ObjCRM.DtResultados.DataTableToJSONIPP()
End If
End Using
Return Retorno
End Function
#End Region
<WebMethod()>
@@ -4841,8 +4921,5 @@ Namespace WebServiceAppModels
Public Property Correcto As Boolean
Public Property Mensajes As List(Of String)
End Class
End Namespace