From b07c40c9fb5878ec9c205033e861d2d162ebd982 Mon Sep 17 00:00:00 2001 From: rrene Date: Fri, 30 Sep 2022 19:11:31 -0700 Subject: [PATCH 01/12] -- aplicar anticipo --- Compras/Compras.aspx.vb | 30 +++++------------------------- 1 file changed, 5 insertions(+), 25 deletions(-) diff --git a/Compras/Compras.aspx.vb b/Compras/Compras.aspx.vb index d152d48e1..541b8f249 100644 --- a/Compras/Compras.aspx.vb +++ b/Compras/Compras.aspx.vb @@ -7818,10 +7818,8 @@ Partial Class Compras_Compras End If End If Next - End If - 'GUARDA BITACORA TIPO CAMBIO OC If Not ErrorOC And TipoCambioOC > 0 Then If Not ObjEventos.AddEventoBitacora(String.Format("La vinculación con la orden de compra fue con un tipo de cambio de ${0}", TipoCambioOC.ToString), "", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CveCompra:=CveCompra) Then @@ -7829,21 +7827,6 @@ Partial Class Compras_Compras End If End If - - 'If tDTAcarreos.Rows.Count > 0 Then - ' If TotAcarreos = TxtSubTotal.Text.ToDouble Then - ' 'ACARREOS - ' For Each tDTAcar As DataRow In tDTAcarreos.Rows - ' If Not ObjAcar.UpdatePreEstimacion(CInt(tDTAcar("CvePreEstimacion")), CveCompra) Then - ' ErrorAddAcarreos = True - ' Exit For - ' End If - ' Next - ' Else - ' ErrorAddAcarreos = True - ' End If - 'End If - 'AGREGAR OTROS GASTOS A ORDEN DE CORTE If CveOrdenCorte > 0 And UsuarioActual.CveEmpresa = 126 Then If ObjCGame.AddCorteGasto(CveOrdenCorte, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, Now, 0, CveCompra) Then @@ -8364,17 +8347,12 @@ Partial Class Compras_Compras 'If gvr.DataKey("Fecha").ToDate > Fecha Then Fecha = gvr.DataKey("Fecha").ToDate 'guardo la fecha mayor Importe += gvr.FCTextBox("TxtAnticipo").Text.ToDouble If Math.Round(Importe, 2) - Math.Round(CompraSaldo, 2) > 0.01 Then gvr.FCTextBox("TxtAnticipo").Text = "" : gvr.FCCheckBox("Chk").Checked = False - End If Next - Else Contador = 1 End If - - - 'If TxtFecha.Text.ToDate > Fecha Then Fecha = TxtFecha.Text.ToDate Fecha = TxtFechaEjecucion.Text.ToDate @@ -8429,6 +8407,8 @@ Partial Class Compras_Compras CompraActual.IdCtaContableProvComplementaria = CtaProveedorComplementaria CompraActual.EsImportacion = chkImportacion.Checked + Dim CvePrePolizaNueva As Integer = ObjConta.AddPrePolizas("Compras/Anticipos", 52, Importe, Importe, DdlMoneda.SelectedValue.ToEntero, Fecha, ConceptoPoliza, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa) + For Each gvr As GridViewRow In GVAnticipos.Rows If gvr.FCCheckBox("Chk") IsNot Nothing AndAlso gvr.FCCheckBox("Chk").Checked Then @@ -8476,20 +8456,20 @@ Partial Class Compras_Compras PorcentajePago = gvr.FCTextBox("TxtAnticipo").Text.ToDecimal / TxtTotal.Text.ToDecimal Dim ImporteAntMNComision As Decimal = (ImporteAnt + ImporComisionAnticipo) * TipoCambioAnt - If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimientoCompra, (ImporteAnt + ImporComisionAnticipo), "", CveConceptoCompra, "", TxtFechaPago.Text.ToDate, IdCtaContable, -1, CveCompra:=CveCompraNC, CveCompraAmortizacion:=CveCompra, CveProveedor:=CveProveedor, CveIE:=CveIE, ImporteMX:=ImporteAntMNComision, ImporteME:=If(TipoCambioAnt = 1, 0, (ImporteAnt + ImporComisionAnticipo)), CveSubProyecto:=CveSubProyectoAnticipo) Then + If Not ObjConta.AddPrePolizasDetalle(CvePrePolizaNueva, TipoMovimientoCompra, (ImporteAnt + ImporComisionAnticipo), "", CveConceptoCompra, "", TxtFechaPago.Text.ToDate, IdCtaContable, -1, CveCompra:=CveCompraNC, CveCompraAmortizacion:=CveCompra, CveProveedor:=CveProveedor, CveIE:=CveIE, ImporteMX:=ImporteAntMNComision, ImporteME:=If(TipoCambioAnt = 1, 0, (ImporteAnt + ImporComisionAnticipo)), CveSubProyecto:=CveSubProyectoAnticipo) Then ErrorMovtosCxP = 1 End If If CveMonedaAnticipo > 1 Then Dim ImporteAntMN As Decimal = TipoCambioAnt * ImporteAnt - ImporteAnt - If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimientoCompra, ImporteAntMN, "", CveConceptoCompraComplementaria, "", TxtFechaPago.Text.ToDate, IdCtaContableComp, -1, CveCompra:=CveCompraNC, CveCompraAmortizacion:=CveCompra, CveProveedor:=CveProveedor, CveIE:=CveIE, ImporteMX:=ImporteAntMN, ImporteME:=If(TipoCambioAnt = 1, 0, ImporteAnt), CveSubProyecto:=CveSubProyectoAnticipo) Then + If Not ObjConta.AddPrePolizasDetalle(CvePrePolizaNueva, TipoMovimientoCompra, ImporteAntMN, "", CveConceptoCompraComplementaria, "", TxtFechaPago.Text.ToDate, IdCtaContableComp, -1, CveCompra:=CveCompraNC, CveCompraAmortizacion:=CveCompra, CveProveedor:=CveProveedor, CveIE:=CveIE, ImporteMX:=ImporteAntMN, ImporteME:=If(TipoCambioAnt = 1, 0, ImporteAnt), CveSubProyecto:=CveSubProyectoAnticipo) Then ErrorMovtosCxP = 1 End If End If Pago.CveIE = CveIE Pago.CveCompraAmortizacion = CveCompraNC - AplicaPrePolizaPagoCompra(CompraActual, pago, CvePrePoliza, ObjConta) + AplicaPrePolizaPagoCompra(CompraActual, Pago, CvePrePolizaNueva, ObjConta) End If End If From 5ce4ff8125395364f980a239ecface1123fc8399 Mon Sep 17 00:00:00 2001 From: rrene Date: Fri, 30 Sep 2022 19:11:42 -0700 Subject: [PATCH 02/12] =?UTF-8?q?--=20correcci=C3=B3n,=20faltaba=20dispose?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Compras/eFacturas.aspx.vb | 1 + 1 file changed, 1 insertion(+) diff --git a/Compras/eFacturas.aspx.vb b/Compras/eFacturas.aspx.vb index 295d0a10a..29a3692fd 100644 --- a/Compras/eFacturas.aspx.vb +++ b/Compras/eFacturas.aspx.vb @@ -1351,6 +1351,7 @@ Partial Class Compras_eFacturas If Not ObjDatos.UpdateEstatus(ObjValidacion.EsValida, GvRow.DataKey("CveFactura").ToEntero, UsuarioActual.CveEmpresa) Then ErrorTrans = True End If + ObjDatos.Dispose() End If ObjValidacion.Dispose() End If From 50f8193962c11ae4b440bec583eb592ea55c2c88 Mon Sep 17 00:00:00 2001 From: Oscar Irigoyen Date: Mon, 3 Oct 2022 06:44:48 -0700 Subject: [PATCH 03/12] RDLCS --- Empresas/171/Formatos/Cotizacion.rdlc | 3011 +++++++++++++++++ Empresas/171/Formatos/Factura.rdlc | 4342 +++++++++++++++++++++++++ Empresas/171/Formatos/Remision.rdlc | 3011 +++++++++++++++++ Empresas/171/Logo.jpg | Bin 0 -> 52786 bytes Empresas/171/Logo.png | Bin 0 -> 42512 bytes Empresas/172/Formatos/OC.rdlc | 3467 ++++++++++++++++++++ 6 files changed, 13831 insertions(+) create mode 100644 Empresas/171/Formatos/Cotizacion.rdlc create mode 100644 Empresas/171/Formatos/Factura.rdlc create mode 100644 Empresas/171/Formatos/Remision.rdlc create mode 100644 Empresas/171/Logo.jpg create mode 100644 Empresas/171/Logo.png create mode 100644 Empresas/172/Formatos/OC.rdlc diff --git a/Empresas/171/Formatos/Cotizacion.rdlc b/Empresas/171/Formatos/Cotizacion.rdlc new file mode 100644 index 000000000..722411cb3 --- /dev/null +++ b/Empresas/171/Formatos/Cotizacion.rdlc @@ -0,0 +1,3011 @@ + + + + + + true + + + + + Tipo + + + + + + + Textbox3 + 0.90692in + 5.67236in + 0.5cm + 2.23561in + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + Fecha y hora de emisión + + + + + + + + + + + + + + + + Textbox3 + 0.46414in + 5.67236in + 0.5cm + 2.23561in + 1 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =IIF(Parameters!Serie.Value.ToString="",Parameters!Folio.Value,Parameters!Serie.Value & "-" &Parameters!Folio.Value) + + + + + + + Textbox3 + 0.22455in + 5.67236in + 0.60856cm + 2.23561in + 2 + + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!TipoDocumento.Value + + + + + + + Textbox3 + 0.0412cm + 5.67236in + 0.5cm + 2.23561in + 3 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + COYOTIRE + + + + + + + + + R.F.C. COYO010101AAA + + + + 0cm + 0cm + + + + + + Olivares 466 Col. Santa Isabe C.P. 83130 + + + + 0cm + 0cm + + + + + + Hermosillo, Sonora, México. + + + + 0cm + 0cm + + + + + + Tel. (662)1890411 + + + + 0cm + 0cm + + + + Textbox4 + 0.0635cm + 1.41912in + 1.04333in + 4.18732in + 4 + + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!Fecha.Value + + + + + + + Textbox3 + 0.66099in + 5.67236in + 0.25114in + 2.23561in + 5 + + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!Tipo.Value & Parameters!Ref.Value + + + + + + + Textbox3 + 1.10364in + 5.67236in + 0.25635in + 2.23561in + 6 + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Nombre + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!ClienteNombre.Value + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Dirección + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!ClienteDireccion.Value + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Ciudad + + + + + + + #4f81bd + + 1.25pt + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!ClienteLugar.Value + + + + + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + 2.12527cm + + + 2.02474cm + + + 10.17786cm + + + 2.52862cm + + + 3.15415cm + + + + + 0.6cm + + + + + true + true + + + + + Cantidad + + + + + + + Textbox34 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Unidad + + + + + + + Textbox53 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Descripción + + + + + + + Textbox79 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + P. Unitario + + + + + + + Textbox84 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Importe + + + + + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.49417cm + + + + + true + true + + + + + =Fields!Cantidad.Value + + + + + + + + + + + + + LightGrey + + + LightGrey + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!UM.Value + + + + + + + UM1 + + + + + + + + + + LightGrey + + + LightGrey + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!PS.Value & " " &Fields!Obs.Value + + + + + + + + + + + + + LightGrey + + + LightGrey + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!PU.Value + + + + + + + PU1 + + + + + + + + + + LightGrey + + + LightGrey + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!Cantidad.Value*Fields!PU.Value + + + + + + + Textbox88 + + + + + + + + + + LightGrey + + + LightGrey + + 2pt + 2pt + 2pt + 2pt + es-MX + + + + + + + + 0.16344cm + + + + + true + true + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + + + + + + + + + + + + + + After + + + + + + Before + + + + DsOC + 4.5569cm + 0.11468cm + 1.25761cm + 20.01064cm + 13 + + + + + + true + + + + + RFC: + + + + + + + + =Parameters!ClienteRFC.Value + + + + + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + 0.81609in + + + 0.69462in + + + 0.72263in + + + + + 0.19645in + + + + + true + true + + + + + Impuesto + + + + + + + Textbox22 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Tasa + + + + + + + Textbox15 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Importe + + + + + + + Textbox29 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.14436in + + + + + true + true + + + + + =Fields!Impuesto.Value + + + + + + + Cantidad1 + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!tasa.Value + + + + + + + UM + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!Importe.Value + + + + + + + Codigo + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + + + + + + + + + + + + After + + + + + + + DataSet3 + 2.65189in + 5.68499in + 0.34081in + 2.23334in + 15 + + + + + + + + + 3.11466cm + + + + + 0.6cm + + + + + true + true + + + + + =Fields!Importe.Value + + + + + + + Importe + + + 2pt + 2pt + 2pt + 2pt + es-MX + + + + + + + + + + + + + + + + + + + =Fields!ImpuestoLocal.Value + + + + 2.48915cm + + + true + true + + + + + =Fields!ImpuestoLocal.Value + + + + + + + ImpuestoLocal + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + DataSet1 + 5.83876cm + 14.4684cm + 0.6cm + 5.60381cm + 16 + + + + + + + + + 3.33075cm + + + 10.99712cm + + + + + 0.6cm + + + + + true + true + + + + + =Parameters!Observaciones.Value + + + + + + + Textbox128 + + + + 1pt + + 2pt + 2pt + 2pt + 2pt + + + 2 + + + + + + + 0.6cm + + + + + true + true + + + + + Importe con letra: + + + + + + + Textbox126 + + + LightGrey + Middle + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + ="SON: " & Microsoft.VisualBasic.Strings.UCase(Parameters!ImporteLetra.Value) + + + + + + + Textbox127 + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + + + + + + + + + + + + + + DsOC + 5.84979cm + 0.14053cm + 1.2cm + 14.32787cm + 17 + + + + + + Embedded + Logo1 + FitProportional + 2.71356cm + 3.49873cm + 18 + + + + + + true + true + + + + + Llanta nueva cuenta con 2 años de garantía contra defecto de fábrica, llanta usada no cuenta con garantía. + + + + + + 2pt + 2pt + 2pt + 2pt + + + + 8.06008cm + + + + + + + + =CDate(Today).ToString("dd/MM/yyyy") + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 27.94cm + 21.59cm + 0.5cm + 0.5cm + 1cm + 0.5cm + 1.27cm + + + + + + + Textbox3 + 0.90692in + 5.67236in + 0.5cm + 2.23561in + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + Fecha y hora de emisión + + + + + + + + + + + + + + + + Textbox3 + 0.46414in + 5.67236in + 0.5cm + 2.23561in + 1 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =IIF(Parameters!Serie.Value.ToString="",Parameters!Folio.Value,Parameters!Serie.Value & "-" &Parameters!Folio.Value) + + + + + + + Textbox3 + 0.22455in + 5.67236in + 0.60856cm + 2.23561in + 2 + + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!TipoDocumento.Value + + + + + + + Textbox3 + 0.0412cm + 5.67236in + 0.5cm + 2.23561in + 3 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + COYOTIRE + + + + + + + + + R.F.C. COYO010101AAA + + + + 0cm + 0cm + + + + + + Olivares 466 Col. Santa Isabe C.P. 83130 + + + + 0cm + 0cm + + + + + + Hermosillo, Sonora, México. + + + + 0cm + 0cm + + + + + + Tel. (662)1890411 + + + + 0cm + 0cm + + + + Textbox4 + 0.0635cm + 1.41912in + 1.04333in + 4.18732in + 4 + + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!CadenaOriginal.Value + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + External + =Parameters!QR.Value + FitProportional + 5.47055in + 0.04026in + 1.3497in + 1.5531in + 6 + + + + + + true + + + + + =Parameters!Fecha.Value + + + + + + + Textbox3 + 0.66099in + 5.67236in + 0.25114in + 2.23561in + 7 + + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!Tipo.Value & Parameters!Ref.Value + + + + + + + Textbox3 + 1.10364in + 5.67236in + 0.25635in + 2.23561in + 8 + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Nombre + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!ClienteNombre.Value + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Dirección + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!ClienteDireccion.Value + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Ciudad + + + + + + + #4f81bd + + 1.25pt + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!ClienteLugar.Value + + + + + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Folio Fiscal: + + + + + + + Textbox54 + 5.47132in + 1.6628in + 0.18056in + 4.02473in + 15 + + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + No. Serie del Certificado del SAT: + + + + + + + Textbox54 + 5.66577in + 1.6628in + 0.21105in + 4.02473in + 16 + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Fecha y Hora de certificación: + + + + + + + Textbox54 + 5.87682in + 1.6628in + 0.19444in + 4.01804in + 17 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Certificado del Contribuyente: + + + + + + + Textbox54 + 6.08243in + 1.6628in + 0.19445in + 4.02473in + 18 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + =Parameters!FolioFiscal.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + =Parameters!SerieCertificadoSAT.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + =Parameters!FechaCertificacion.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + =Parameters!CertificadoContribuyente.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Régimen: Régimen General de Ley Personas Morales; Condiciones de pago: + + + + =IIF(Parameters!CondicionPago.Value.ToString="","No Identificado",Parameters!CondicionPago.Value) + + + + ; Método de Pago: + + + + =IIF(Parameters!MetodoPago.Value.ToString="","No Identificado",Parameters!MetodoPago.Value) + + + + ; Num. Cta Pago: + + + + =IIF(Parameters!NumCta.Value="0" Orelse Parameters!NumCta.Value="","No Identificado",Parameters!NumCta.Value) + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Éste documento es una representacion impresa de un CFDi + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + 2.12527cm + + + 2.02474cm + + + 10.17786cm + + + 2.52862cm + + + 3.15415cm + + + + + 0.6cm + + + + + true + true + + + + + Cantidad + + + + + + + Textbox34 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Unidad + + + + + + + Textbox53 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Descripción + + + + + + + Textbox79 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + P. Unitario + + + + + + + Textbox84 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Importe + + + + + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.49417cm + + + + + true + true + + + + + =Fields!Cantidad.Value + + + + + + + + + + + + + LightGrey + + + LightGrey + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!UM.Value + + + + + + + UM1 + + + + + + + + + + LightGrey + + + LightGrey + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!PS.Value & " " &Fields!Obs.Value + + + + + + + + + + + + + LightGrey + + + LightGrey + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!PU.Value + + + + + + + PU1 + + + + + + + + + + LightGrey + + + LightGrey + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!Cantidad.Value*Fields!PU.Value + + + + + + + Textbox88 + + + + + + + + + + LightGrey + + + LightGrey + + 2pt + 2pt + 2pt + 2pt + es-MX + + + + + + + + 0.16344cm + + + + + true + true + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + + + + + + + + + + + + + + After + + + + + + Before + + + + DsOC + 4.5569cm + 0.11468cm + 1.25761cm + 20.01064cm + 25 + + + + + + true + + + + + RFC: + + + + + + + + =Parameters!ClienteRFC.Value + + + + + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + 0.81609in + + + 0.69462in + + + 0.72263in + + + + + 0.19645in + + + + + true + true + + + + + Impuesto + + + + + + + Textbox22 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Tasa + + + + + + + Textbox15 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Importe + + + + + + + Textbox29 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.14436in + + + + + true + true + + + + + =Fields!Impuesto.Value + + + + + + + Cantidad1 + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!tasa.Value + + + + + + + UM + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!Importe.Value + + + + + + + Codigo + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + + + + + + + + + + + + After + + + + + + + DataSet3 + 2.65189in + 5.68499in + 0.34081in + 2.23334in + 27 + + + + + + + + + 3.11466cm + + + + + 0.6cm + + + + + true + true + + + + + =Fields!Importe.Value + + + + + + + Importe + + + 2pt + 2pt + 2pt + 2pt + es-MX + + + + + + + + + + + + + + + + + + + =Fields!ImpuestoLocal.Value + + + + 2.48915cm + + + true + true + + + + + =Fields!ImpuestoLocal.Value + + + + + + + ImpuestoLocal + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + DataSet1 + 5.83876cm + 14.4684cm + 0.6cm + 5.60381cm + 28 + + + + + + + + + 3.33075cm + + + 10.99712cm + + + + + 0.6cm + + + + + true + true + + + + + =Parameters!Observaciones.Value + + + + + + + Textbox128 + + + + 1pt + + 2pt + 2pt + 2pt + 2pt + + + 2 + + + + + + + 0.6cm + + + + + true + true + + + + + Importe con letra: + + + + + + + Textbox126 + + + LightGrey + Middle + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + ="SON: " & Microsoft.VisualBasic.Strings.UCase(Parameters!ImporteLetra.Value) + + + + + + + Textbox127 + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.6cm + + + + + true + true + + + + + Forma de pago: + + + + + + + Textbox130 + + + LightGrey + Middle + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Parameters!FormaPago.Value + + + + + + + Textbox131 + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.6cm + + + + + true + true + + + + + Uso CFDI: + + + + + + + Textbox2 + + + LightGrey + Middle + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Parameters!UsoCFDI.Value + + + + + + + Textbox44 + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 1.8cm + + + + + true + true + + + + + Sello digital del CFDI: + + + + + + + Textbox132 + + + LightGrey + Middle + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Parameters!SelloCFDI.Value + + + + + + + Textbox133 + + + Top + 2pt + 2pt + 2pt + 2pt + + + + + + + + 1.2cm + + + + + true + true + + + + + Sello del SAT: + + + + + + + Textbox134 + + + LightGrey + Middle + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Parameters!SelloSAT.Value + + + + + + + Textbox135 + + + Top + 2pt + 2pt + 2pt + 2pt + + + + + + + + + + + + + + + + + + + + + + + + + DsOC + 5.84979cm + 0.14053cm + 5.4cm + 14.32787cm + 29 + + + + + + + + true + true + + + + + CFDI Relacionados + + + + + + + Textbox5 + 0.11382cm + 0.05336cm + 0.54004cm + 20.00281cm + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Tipo Relación: + + + + + + + Textbox29 + 0.83025cm + 4.33636cm + 0.41981cm + 5.31841cm + 1 + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + =Parameters!TipoRelacionTexto.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + 2.42456cm + + + 2.05585cm + + + 3.03631cm + + + 7.7847cm + + + + + 0.44125cm + + + + + true + true + + + + + Folio + + + + + + + Textbox10 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Fecha + + + + + + + Textbox12 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Importe + + + + + + + Textbox21 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Folio Fiscal + + + + + + + Textbox11 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.41479cm + + + + + true + true + + + + + =Fields!SerieFolio.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!Fecha.Value + + + + + + + Fecha + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!Importe.Value + + + + + + + Importe1 + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!FolioFiscal.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + + + + + + + + + + + + + After + + + + + + + DataSet4 + 1.39643cm + 2.83462cm + 0.85604cm + 15.30142cm + 3 + + + + + + true + 17.40531cm + 0.04112cm + 2.25247cm + 20.1554cm + 30 + + =Microsoft.VisualBasic.Interaction.IIF(First(Fields!SerieFolio.Value, "DataSet4") <> "", False, True) + + + + + + + true + true + + + + + Cadena original del complemento de certificación digital del SAT: + + + + + + + Textbox1 + 11.26418cm + 0.14053cm + 0.6cm + 19.93168cm + 31 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + VERSION + + + + =Parameters!CFDIVersion.Value + + + + + + + Textbox5 + 19.75983cm + 15.68372cm + 0.56043cm + 4.49042cm + 32 + + + 2pt + 2pt + 2pt + 2pt + + + + Embedded + Logo1 + FitProportional + 2.71356cm + 3.49873cm + 33 + + + + + + true + true + + + + + Llanta nueva cuenta con 2 años de garantía contra defecto de fábrica, llanta usada no cuenta con garantía. + + + + + + 2pt + 2pt + 2pt + 2pt + + + + 20.32026cm + + + + + + + + =CDate(Today).ToString("dd/MM/yyyy") + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 27.94cm + 21.59cm + 0.5cm + 0.5cm + 1cm + 0.5cm + 1.27cm + + + + + + + Textbox3 + 0.90692in + 5.67236in + 0.5cm + 2.23561in + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + Fecha y hora de emisión + + + + + + + + + + + + + + + + Textbox3 + 0.46414in + 5.67236in + 0.5cm + 2.23561in + 1 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =IIF(Parameters!Serie.Value.ToString="",Parameters!Folio.Value,Parameters!Serie.Value & "-" &Parameters!Folio.Value) + + + + + + + Textbox3 + 0.22455in + 5.67236in + 0.60856cm + 2.23561in + 2 + + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!TipoDocumento.Value + + + + + + + Textbox3 + 0.0412cm + 5.67236in + 0.5cm + 2.23561in + 3 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + COYOTIRE + + + + + + + + + R.F.C. COYO010101AAA + + + + 0cm + 0cm + + + + + + Olivares 466 Col. Santa Isabe C.P. 83130 + + + + 0cm + 0cm + + + + + + Hermosillo, Sonora, México. + + + + 0cm + 0cm + + + + + + Tel. (662)1890411 + + + + 0cm + 0cm + + + + Textbox4 + 0.0635cm + 1.41912in + 1.04333in + 4.18732in + 4 + + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!Fecha.Value + + + + + + + Textbox3 + 0.66099in + 5.67236in + 0.25114in + 2.23561in + 5 + + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!Tipo.Value & Parameters!Ref.Value + + + + + + + Textbox3 + 1.10364in + 5.67236in + 0.25635in + 2.23561in + 6 + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Nombre + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!ClienteNombre.Value + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Dirección + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!ClienteDireccion.Value + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Ciudad + + + + + + + #4f81bd + + 1.25pt + + 2pt + 2pt + 2pt + 2pt + + + + true + + + + + =Parameters!ClienteLugar.Value + + + + + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + 2.12527cm + + + 2.02474cm + + + 10.17786cm + + + 2.52862cm + + + 3.15415cm + + + + + 0.6cm + + + + + true + true + + + + + Cantidad + + + + + + + Textbox34 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Unidad + + + + + + + Textbox53 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Descripción + + + + + + + Textbox79 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + P. Unitario + + + + + + + Textbox84 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Importe + + + + + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.49417cm + + + + + true + true + + + + + =Fields!Cantidad.Value + + + + + + + + + + + + + LightGrey + + + LightGrey + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!UM.Value + + + + + + + UM1 + + + + + + + + + + LightGrey + + + LightGrey + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!PS.Value & " " &Fields!Obs.Value + + + + + + + + + + + + + LightGrey + + + LightGrey + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!PU.Value + + + + + + + PU1 + + + + + + + + + + LightGrey + + + LightGrey + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!Cantidad.Value*Fields!PU.Value + + + + + + + Textbox88 + + + + + + + + + + LightGrey + + + LightGrey + + 2pt + 2pt + 2pt + 2pt + es-MX + + + + + + + + 0.16344cm + + + + + true + true + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + + + + + + + + + + + + + + After + + + + + + Before + + + + DsOC + 4.5569cm + 0.11468cm + 1.25761cm + 20.01064cm + 13 + + + + + + true + + + + + RFC: + + + + + + + + =Parameters!ClienteRFC.Value + + + + + + + + + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + 0.81609in + + + 0.69462in + + + 0.72263in + + + + + 0.19645in + + + + + true + true + + + + + Impuesto + + + + + + + Textbox22 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Tasa + + + + + + + Textbox15 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Importe + + + + + + + Textbox29 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.14436in + + + + + true + true + + + + + =Fields!Impuesto.Value + + + + + + + Cantidad1 + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!tasa.Value + + + + + + + UM + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!Importe.Value + + + + + + + Codigo + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + + + + + + + + + + + + After + + + + + + + DataSet3 + 2.65189in + 5.68499in + 0.34081in + 2.23334in + 15 + + + + + + + + + 3.11466cm + + + + + 0.6cm + + + + + true + true + + + + + =Fields!Importe.Value + + + + + + + Importe + + + 2pt + 2pt + 2pt + 2pt + es-MX + + + + + + + + + + + + + + + + + + + =Fields!ImpuestoLocal.Value + + + + 2.48915cm + + + true + true + + + + + =Fields!ImpuestoLocal.Value + + + + + + + ImpuestoLocal + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + DataSet1 + 5.83876cm + 14.4684cm + 0.6cm + 5.60381cm + 16 + + + + + + + + + 3.33075cm + + + 10.99712cm + + + + + 0.6cm + + + + + true + true + + + + + =Parameters!Observaciones.Value + + + + + + + Textbox128 + + + + 1pt + + 2pt + 2pt + 2pt + 2pt + + + 2 + + + + + + + 0.6cm + + + + + true + true + + + + + Importe con letra: + + + + + + + Textbox126 + + + LightGrey + Middle + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + ="SON: " & Microsoft.VisualBasic.Strings.UCase(Parameters!ImporteLetra.Value) + + + + + + + Textbox127 + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + + + + + + + + + + + + + + DsOC + 5.84979cm + 0.14053cm + 1.2cm + 14.32787cm + 17 + + + + + + Embedded + Logo1 + FitProportional + 2.71356cm + 3.49873cm + 18 + + + + + + true + true + + + + + Llanta nueva cuenta con 2 años de garantía contra defecto de fábrica, llanta usada no cuenta con garantía. + + + + + + 2pt + 2pt + 2pt + 2pt + + + + 8.06008cm + + + + + + + + =CDate(Today).ToString("dd/MM/yyyy") + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 27.94cm + 21.59cm + 0.5cm + 0.5cm + 1cm + 0.5cm + 1.27cm + + + + + + #0e2455 + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + CLAVE + + + + + + + Textbox29 + + + #0e2455 + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + DESCRIPCIÓN + + + + + + + Textbox17 + + + #0e2455 + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + OBSERVACIÓN + + + + + + + Textbox46 + + + #0e2455 + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + P/U + + + + + + + Textbox23 + + + #0e2455 + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + DESC. + + + + + + + Textbox2 + + + #0e2455 + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + IMPORTE + + + + + + + Textbox1 + + + #0e2455 + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.19644in + + + + + true + true + + + + + =Fields!Cantidad.Value + + + + + + + Cantidad1 + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!CodPS.Value + + + + + + + CodPS + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!Producto.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!Obs.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!Importe.Value + + + + + + + Importe + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!Descuento.Value + + + + + + + Descuento + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!Total.Value + + + + + + + Total + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + + + + + + + + + + + + + + + + After + + + + + + + DsOC + 0.04788in + 0.41372in + 8.15357in + + + + + + + + true + true + + + + + I.V.A. + + + + + + + Textbox20 + 1.87711cm + 15.76748cm + 0.45183cm + 2.5cm + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + TOTAL: + + + + + + + Textbox20 + 3.97642cm + 15.77277cm + 0.45183cm + 2.5cm + 1 + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + =Parameters!IVA.Value + + + + + + + Textbox20 + 1.87711cm + 18.26748cm + 0.45183cm + 2.4365cm + 2 + + + 2pt + 2pt + 2pt + 2pt + es-MX + + + + true + true + + + + + =Parameters!Total.Value + + + + + + + Textbox20 + 3.97642cm + 18.27277cm + 0.45183cm + 2.43121cm + 3 + + + 2pt + 2pt + 2pt + 2pt + es-MX + + + + true + true + + + + + SUB-TOTAL + + + + + + + Textbox20 + 0.40195cm + 15.76748cm + 0.45183cm + 2.5cm + 4 + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + =Parameters!SubTotal.Value + + + + + + + Textbox20 + 0.40195cm + 18.26748cm + 0.45183cm + 2.4365cm + 5 + + + 2pt + 2pt + 2pt + 2pt + es-MX + + + + true + true + + + + + =UCase(Parameters!ImporteLetra.Value) + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + + + + #0e2455 + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + + + + #0e2455 + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + + + + #0e2455 + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + =Parameters!Descripcion.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Ret I.V.A + + + + + + + Textbox20 + 2.32894cm + 15.76669cm + 0.45183cm + 2.5cm + 11 + + =IIF(Parameters!RetIVA.Value > 0,FALSE,TRUE) + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + =Parameters!RetIVA.Value + + + + + + + Textbox20 + 2.32894cm + 18.26669cm + 0.45183cm + 2.4365cm + 12 + + =IIF(Parameters!RetIVA.Value > 0,FALSE,TRUE) + + + + 2pt + 2pt + 2pt + 2pt + es-MX + + + + true + true + + + + + Ret I.S.R + + + + + + + Textbox20 + 2.78077cm + 15.76669cm + 0.45183cm + 2.5cm + 13 + + =IIF(Parameters!RetISR.Value > 0,FALSE,TRUE) + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + =Parameters!RetISR.Value + + + + + + + Textbox20 + 2.78077cm + 18.26669cm + 0.45183cm + 2.4365cm + 14 + + =IIF(Parameters!RetISR.Value > 0,FALSE,TRUE) + + + + 2pt + 2pt + 2pt + 2pt + es-MX + + + + true + true + + + + + I.E.P.S + + + + + + + Textbox20 + 3.2326cm + 15.76669cm + 0.45183cm + 2.5cm + 15 + + =IIF(Sum(Fields!IEPS.Value, "DsOC") > 0,FALSE,TRUE) + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + =Sum(Fields!IEPS.Value, "DsOC") + + + + + + + Textbox20 + 3.2326cm + 18.26669cm + 0.45183cm + 2.4365cm + 16 + + =IIF(Sum(Fields!IEPS.Value, "DsOC") > 0,FALSE,TRUE) + + + + 2pt + 2pt + 2pt + 2pt + es-MX + + + + true + true + + + + + DESCUENTO + + + + + + + Textbox20 + 0.88906cm + 15.77355cm + 0.45183cm + 2.5cm + 17 + + =IIF(Parameters!Descuento.Value > 0,FALSE,TRUE) + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + =Parameters!Descuento.Value + + + + + + + Textbox20 + 0.88906cm + 18.27355cm + 0.45183cm + 2.4365cm + 18 + + =IIF(Parameters!Descuento.Value > 0,FALSE,TRUE) + + + + 2pt + 2pt + 2pt + 2pt + es-MX + + + + true + true + + + + + SUB-TOTAL2 + + + + + + + Textbox20 + 1.34089cm + 15.77355cm + 0.45183cm + 2.5cm + 19 + + =IIF(Parameters!Descuento.Value > 0,FALSE,TRUE) + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + =Parameters!SubTotal2.Value + + + + + + + Textbox20 + 1.34089cm + 18.27355cm + 0.45183cm + 2.4365cm + 20 + + =IIF(Parameters!Descuento.Value > 0,FALSE,TRUE) + + + + 2pt + 2pt + 2pt + 2pt + es-MX + + + + true + 1.12516cm + 0.12849cm + 5.34083cm + 20.74271cm + 1 + + + + + + 2.58039in + + + + + + true + true + + + + + Proveedor + + + + : + + + + + + + + + Nombre + + + + : + + + + + + + + =Parameters!ProveedorNombre.Value + + + + + + + + + RFC: + + + + + + + + =Parameters!ProveedorRFC.Value + + + + + + + + + Direccion: + + + + =Parameters!ProveedorDireccion.Value + + + + + + + + + Teléfono: + + + + =Parameters!ProveedorTel.Value + + + + + + + + + Contacto: + + + + =Parameters!ProveedorContacto.Value + + + + + + + + + + + Textbox2 + 1.60003in + 0.12161cm + 1.20291in + 3.07995in + 1 + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Enviar a: + + + + + + + + + Nombre: + + + + =Parameters!EnvioContacto.Value + + + + + + + + + + + + + Departamento: + + + + =Parameters!EnvioDepartamento.Value + + + + + + + + + Calle: + + + + + + + + =Parameters!EnvioDireccion.Value + + + + + + + + + Colonia: + + + + + + + + =Parameters!EnvioColonia.Value + + + + + + + + + Ciudad: + + + + + + + + =Parameters!EnvioCiudad.Value + + + + + + + + Estado: + + + + + + + + =Parameters!EnvioEstado.Value + + + + + + + + + Municipio y/o Delegación: + + + + =Parameters!EnvioCiudad.Value + + + + + + + + + + + + + Pais: + + + + + + + + =Parameters!ProveedorPais.Value + + + + + + + + + + + + + + + + CP: + + + + + + + + =Parameters!EnvioCP.Value + + + + + + + + + Teléfono: + + + + + + + + =Parameters!EnvioTel.Value + + + + + + + + + + + + + Pedido/Contrato: + + + + =Parameters!PedidoContrato.Value + + + + + + + Textbox36 + 4.06406cm + 7.94469cm + 4.25633cm + 8.32364cm + 2 + + =IIF(String.IsNullOrEmpty(Parameters!LugarEntrega.Value),False,True) + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Facturar a: + + + + + + + + + Compuproveedores, S.A. de C.V. + + + + + + + + + =Parameters!DomicilioSucursal.Value + + + + + + + + + COM890602EE8 + + + + + + + + + ="(" & Parameters!Telefono.Value.ToString().Substring(0,3) & ") " & Parameters!Telefono.Value.ToString().Substring(3) + + + + + + + + + + + + + + + + + + CFDI 3.3: + + + + + + + + + =Parameters!UsoCFDI.Value + + + + + + + Textbox40 + 4.06406cm + 16.26833cm + 4.25633cm + 4.55726cm + 3 + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + ="Envío Directo al Cliente" + + + + + + + EstatusEntrega + 1.27043cm + 4.61876cm + 0.6cm + 5.51419cm + 4 + + =IIF(Parameters!EntregaDirecta.Value <> "False",FALSE,TRUE) + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + + + + + + + + + =Parameters!TipoOC.Value + + + + + + + + + Folio: + + + + =Parameters!Folio.Value + + + + + + + + + Almacen: + + + + =Parameters!Proyecto.Value + + + + + + + + + Fecha de ElaboracIón: + + + + =Parameters!FechaSolicitud.Value + + + + + + + + + Fecha Estimada de Recepción: + + + + =iif(Parameters!FechaEntrega.Value="01/01/0001","",Parameters!FechaEntrega.Value) + + + + + + + + + + + + + Folio Pedido Proveedor: + + + + =Parameters!FolioAdicional.Value + + + + + + + + + Asignado a: + + + + =Parameters!Comprador.Value + + + + + + + + + Coordinador Empresarial: + + + + + + + + =Parameters!Vendedor.Value + + + + + + + Textbox40 + 0.16794cm + 12.50129cm + 3.79029cm + 8.3243cm + 5 + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Enviar a: + + + + + + + + + Dirección: + + + + =Parameters!LugarEntrega.Value + + + + + + + + + + + + + + + + + + + + Textbox36 + 4.09934cm + 7.94469cm + 4.25633cm + 8.32364cm + 7 + + =IIF(String.IsNullOrEmpty(Parameters!LugarEntrega.Value),True,False) + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + + 0.84696cm + true + true + + + true + true + + + + + Usuario: + + + + =Parameters!UsuarioImprimio.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + Fecha Impresión: + + + + =Parameters!FechaImpresion.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + true + true + + + + + ="Página " & Globals.PageNumber & " de " & Globals.TotalPages + + + + + + + Textbox35 + 0.25252cm + 18.19908cm + 0.41981cm + 2.5cm + 2 + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 27.94cm + 21.59cm + 0cm + 0cm + 0cm + 0.5cm + 0.13cm + @@ -179,7 +178,7 @@ - #0e2455 + Orange 2pt 2pt 2pt @@ -200,7 +199,6 @@ CLAVE @@ -216,7 +214,7 @@ - #0e2455 + Orange 2pt 2pt 2pt @@ -237,7 +235,6 @@ DESCRIPCIÓN @@ -253,7 +250,7 @@ - #0e2455 + Orange 2pt 2pt 2pt @@ -274,7 +271,6 @@ OBSERVACIÓN @@ -290,7 +286,7 @@ - #0e2455 + Orange 2pt 2pt 2pt @@ -311,7 +307,6 @@ P/U @@ -327,7 +322,7 @@ - #0e2455 + Orange 2pt 2pt 2pt @@ -348,7 +343,6 @@ DESC. @@ -364,7 +358,7 @@ - #0e2455 + Orange 2pt 2pt 2pt @@ -385,7 +379,6 @@ IMPORTE @@ -401,7 +394,7 @@ - #0e2455 + Orange 2pt 2pt 2pt @@ -413,7 +406,7 @@ - 0.19644in + 0.15024in @@ -690,7 +683,7 @@ DsOC 0.04788in - 0.41372in + 0.36752in 8.15357in @@ -719,9 +713,9 @@ Textbox20 - 1.87711cm + 1.36911cm 15.76748cm - 0.45183cm + 0.346cm 2.5cm @@ -752,9 +747,9 @@ Textbox20 - 3.97642cm + 3.11917cm 15.77277cm - 0.45183cm + 0.31777cm 2.5cm 1 @@ -860,7 +858,7 @@ Textbox20 - 0.40195cm + 0.08445cm 15.76748cm 0.45183cm 2.5cm @@ -884,6 +882,7 @@ =Parameters!SubTotal.Value @@ -929,7 +929,7 @@ Textbox46 - 4.85549cm + 3.77599cm 0.00001cm 0.45183cm 19.46272cm @@ -959,7 +959,6 @@ Textbox5 - 0.11768cm 0.14316cm 20.70398cm 7 @@ -967,7 +966,7 @@ - #0e2455 + Orange 2pt 2pt 2pt @@ -982,14 +981,16 @@ - - #0e2455 + Orange 2pt 2pt 2pt @@ -1013,14 +1014,16 @@ - - #0e2455 + Orange 2pt 2pt 2pt @@ -1054,7 +1057,7 @@ Textbox1 - 0.43723cm + 0.11973cm 0.00001cm 0.41479cm 14.67376cm @@ -1078,6 +1081,7 @@ Ret I.V.A @@ -1088,9 +1092,9 @@ Textbox20 - 2.32894cm + 1.75744cm 15.76669cm - 0.45183cm + 0.346cm 2.5cm 11 @@ -1115,6 +1119,7 @@ =Parameters!RetIVA.Value @@ -1165,9 +1171,9 @@ Textbox20 - 2.78077cm + 2.14577cm 15.76669cm - 0.45183cm + 0.346cm 2.5cm 13 @@ -1192,6 +1198,7 @@ =Parameters!RetISR.Value @@ -1242,9 +1250,9 @@ Textbox20 - 3.2326cm + 2.5341cm 15.76669cm - 0.45183cm + 0.33368cm 2.5cm 15 @@ -1269,6 +1277,7 @@ =Sum(Fields!IEPS.Value, "DsOC") @@ -1319,9 +1329,9 @@ Textbox20 - 0.88906cm + 0.57156cm 15.77355cm - 0.45183cm + 0.346cm 2.5cm 17 @@ -1346,6 +1356,7 @@ =Parameters!Descuento.Value @@ -1396,9 +1408,9 @@ Textbox20 - 1.34089cm + 0.95989cm 15.77355cm - 0.45183cm + 0.35983cm 2.5cm 19 @@ -1423,6 +1435,7 @@ =Parameters!SubTotal2.Value - 2.58039in + 2.10747in - - - true true @@ -1669,399 +1668,8 @@ Textbox2 1.60003in 0.12161cm - 1.20291in - 3.07995in - 1 - - - 2pt - 2pt - 2pt - 2pt - - - - true - true - - - - - Enviar a: - - - - - - - - - Nombre: - - - - =Parameters!EnvioContacto.Value - - - - - - - - - - - - - Departamento: - - - - =Parameters!EnvioDepartamento.Value - - - - - - - - - Calle: - - - - - - - - =Parameters!EnvioDireccion.Value - - - - - - - - - Colonia: - - - - - - - - =Parameters!EnvioColonia.Value - - - - - - - - - Ciudad: - - - - - - - - =Parameters!EnvioCiudad.Value - - - - - - - - Estado: - - - - - - - - =Parameters!EnvioEstado.Value - - - - - - - - - Municipio y/o Delegación: - - - - =Parameters!EnvioCiudad.Value - - - - - - - - - - - - - Pais: - - - - - - - - =Parameters!ProveedorPais.Value - - - - - - - - - - - - - - - - CP: - - - - - - - - =Parameters!EnvioCP.Value - - - - - - - - - Teléfono: - - - - - - - - =Parameters!EnvioTel.Value - - - - - - - - - - - - - Pedido/Contrato: - - - - =Parameters!PedidoContrato.Value - - - - - - - Textbox36 - 4.06406cm - 7.94469cm - 4.25633cm - 8.32364cm - 2 - - =IIF(String.IsNullOrEmpty(Parameters!LugarEntrega.Value),False,True) - + 1.06583in + 3.72333in @@ -2081,7 +1689,7 @@ Facturar a: @@ -2094,7 +1702,7 @@ - Compuproveedores, S.A. de C.V. + Citrus Game, S.A. de C.V. - - - - - - - - =Parameters!UsoCFDI.Value + @@ -2199,10 +1792,10 @@ Textbox40 4.06406cm - 16.26833cm - 4.25633cm - 4.55726cm - 3 + 12.50129cm + 2.70722cm + 8.3243cm + 1 @@ -2213,46 +1806,6 @@ 2pt - - true - true - - - - - ="Envío Directo al Cliente" - - - - - - - EstatusEntrega - 1.27043cm - 4.61876cm - 0.6cm - 5.51419cm - 4 - - =IIF(Parameters!EntregaDirecta.Value <> "False",FALSE,TRUE) - - - - 2pt - 2pt - 2pt - 2pt - - true true @@ -2302,6 +1855,7 @@ =Parameters!Folio.Value @@ -2468,7 +2022,7 @@ 12.50129cm 3.79029cm 8.3243cm - 5 + 2 @@ -2479,121 +2033,21 @@ 2pt - - true - true - - - - - - - 2pt - 2pt - 2pt - 2pt - - - true - true - - - - - Enviar a: - - - - - - - - - Dirección: - - - - =Parameters!LugarEntrega.Value - - - - - - - - - - - - - - - - - - - - Textbox36 - 4.09934cm - 7.94469cm - 4.25633cm - 8.32364cm - 7 - - =IIF(String.IsNullOrEmpty(Parameters!LugarEntrega.Value),True,False) - - - - 2pt - 2pt - 2pt - 2pt - - + - - - Conciliacion Emitidas Sat - - - - - - - - - - - - - -
-
-
- - -
-
-
- - -
- - - - - - - -
-
- Fecha Inicio: -
-
-
- - - - -
- - - - - - -
-
- Fecha Fin: -
-
-
- - - - -
- - - - - - -
-
-
-
- -
-
-
- -
-
-
- - Facturas emitidas en el sat sin registrar de -
-
- -
-
- - -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - <%-- --%> - XML - - - - - r - - - - - - -
-
- - - -
-
- -
- - - - diff --git a/Ventas/RepConciliacionEmitidosSat.aspx.cs b/Ventas/RepConciliacionEmitidosSat.aspx.cs deleted file mode 100644 index 7cf8cc869..000000000 --- a/Ventas/RepConciliacionEmitidosSat.aspx.cs +++ /dev/null @@ -1,1808 +0,0 @@ -using Microsoft.Reporting.WebForms; -using System; -using System.Collections.Generic; -using System.IO; -using System.Linq; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using System.Xml; -using Extensiones; -using System.Data; -using System.Text; -using ADSistemaLibrary2.SatXml; - -//using ADS_CFDI_SAT; - -public partial class Ventas_RepConciliacionEmitidosSat : ClsPaginas -{ - #region "Propiedades" - const string rqFechaInicio = "FechaInicio"; - const string rqFechaFin = "FechaFin"; - const string rqRegistroEn = "RegistroEn"; - - public string RfechaI - { - get - { - return ViewState["RfechaI"].ToString(); - } - set { ViewState["RfechaI"] = value; } - } - public string RfechaF - { - get - { - return ViewState["RfechaF"].ToString(); - } - set { ViewState["RfechaF"] = value; } - } - public object CurrentRow - { - get - { - return ViewState["CurrentRow"]; - } - set { ViewState["CurrentRow"] = value; } - } - public int RegistroEn - { - get - { - if (ViewState["RegistroEn"] != null) - { - return ViewState["RegistroEn"].ToString().ToEntero(); - } - else - { - return 0; - } - } - set { ViewState["RegistroEn"] = value; } - } - private StringBuilder strErrores; - #endregion - protected void Page_Load(object sender, EventArgs e) - { - if (!IsPostBack) - { - string path; - if (Request["op"] != null && Request["op"].ToString().Length > 0) - { - try - { - - if (System.IO.File.Exists((path = string.Format("{0}\\{1}", UsuarioActual.Empresa.Ruta.Trim(), Extensiones.ModExtensiones.Decripta(Request["op"].ToString()).Trim()).Replace("/", "\\")))) - { - - System.IO.FileInfo archivo = new System.IO.FileInfo(path); - - HttpContext.Current.Response.Clear(); - HttpContext.Current.Response.ClearContent(); - HttpContext.Current.Response.ContentType = "text/plain"; - HttpContext.Current.Response.AppendHeader("Content-disposition", string.Format("attachment; filename={0}", archivo.Name)); - HttpContext.Current.Response.AddHeader("Content-Length", archivo.Length.ToString()); - HttpContext.Current.Response.TransmitFile(path); - HttpContext.Current.Response.End(); - } - else - { - RegistraScript("window.close()"); - } - } - catch (Exception ex) - { - Extensiones.ModExtensiones.GuardaLog(ex.ToString()); - RegistraScript("window.close()"); - - } - - } - - fillrequestfields(); - DdlSubProyectoDatos.DataSource = get_GlobalDTSubProyectosUsuarios(UsuarioActual.CveUsuario, -1, UsuarioActual.CveEmpresa, -1, 1).FiltraParametros("EsSucursal = True "); - DdlSubProyectoDatos.DataBind(); - DdlClasificacion.DataSource = get_GlobalDTClasificaciones(UsuarioActual.CveEmpresa, UsoClasificacion: 1).FiltraParametros(" Codigo = '' OR Codigo IS NULL ", Orderby: "Clasificacion"); - - DdlClasificacion.DataBind(); - - - CargaConciliacionemitidasSATGet(); - int CveClasificacion = DdlClasificacion.SelectedValue.ToEntero(); - if (UsuarioActual.Empresa.Funcionalidad(141).ToString() == "1") - { - - DdlPS.setEsWebService(true); - DdlPS.ddlWS.Attributes.Add("data-cveclasificacion", CveClasificacion.ToString()); - DdlPS.ddlWS.Attributes.Add("data-pagina", "ventas/ventas"); - DdlPS.ddlWS.Attributes.Add("data-Estatus", "1"); - } - else - { - - DdlPS.setEsWebService(false); - DdlPS.ddl.DataSource = get_GlobalDTPSSimplificado(UsuarioActual.CveEmpresa, CveClasificacion: CveClasificacion, Estatus: 1, AplicaParaVenta: 1); - DdlPS.ddl.DataBind(); - } - } - } - private void downfile(string path) - { - - } - public void fillrequestfields() - { - - DateTime fecha; - DateTime fechaInicio = DateTime.Now; - DateTime fechaFin = DateTime.Now; - RegistroEn = -1; - if (fechaInicio.Day < 5) { fechaInicio = fechaInicio.AddMonths(-1); } - fechaInicio = fechaInicio.AddDays(1 - fechaInicio.Day); - fechaFin = fechaInicio.AddYears(1).AddDays(-1); - if (Request[rqRegistroEn] != null) { RegistroEn = Request[rqRegistroEn].ToEntero(); } - if (Request[rqFechaInicio] != null) { DateTime.TryParse(Request[rqFechaInicio], out fecha); fechaInicio = fecha.Year > 1900 ? fecha : fechaInicio; } - if (Request[rqFechaFin] != null) { DateTime.TryParse(Request[rqFechaFin], out fecha); fechaFin = fecha.Year > 1900 ? fecha : fechaFin; } - txtFechaI.Text = string.Format("{0:dd/MM/yyyy}", fechaInicio); - txtFechaF.Text = string.Format("{0:dd/MM/yyyy}", fechaFin); - ddlRegistroen.SelectedValueExist(RegistroEn); - } - - protected void CargaRepConciliacionSatGET() - { - string RtipoDocto; - RtipoDocto = "I"; - RfechaI = txtFechaI.Text.Length > 0 ? txtFechaI.Text.ToDateTime().ToString("yyyy/MM/dd") : ""; - RfechaF = txtFechaF.Text.Length > 0 ? string.Format("{0:yyyy/MM/dd}", txtFechaF.Text.ToDateTime()) : ""; - RegistroEn = ddlRegistroen.SelectedValue.ToEntero(); - using (ClsGenerales ObjRepC = new ClsGenerales()) - { - if (ObjRepC.RepConciliacionSatDetalleGET(UsuarioActual.CveEmpresa, RtipoDocto, RfechaI, RfechaF, RegistroEn)) - { - Ltlsinregistrar.Text = $"{ObjRepC.DtResultados.COUNT("FolioFiscal", "CveVenta IS NULL")}"; - ltlTotal.Text = $"{ObjRepC.DtResultados.Rows.Count}"; - - } - GVConciliacionemitidasSAT.DataSource = ObjRepC.DtResultados; - ObjRepC.Dispose(); - - } - GVConciliacionemitidasSAT.DataBind(); - UpDatosReporte.Update(); - } - protected void CargaConciliacionemitidasSATGet() - { - CargaRepConciliacionSatGET(); - //ClsVentas ObjV = new ClsVentas(); - //ObjV.ConciliacionemitidasSATGet(UsuarioActual.CveEmpresa); - //GVConciliacionemitidasSAT.DataSource = ObjV.DtResultados.FiltraParametros("", "CveVenta"); - //Ltlsinregistrar.Text = $"{ObjV.DtResultados.COUNT("FolioFiscal","CveVenta IS NULL")}"; - //ltlTotal.Text = $"{ObjV.DtResultados.Rows.Count}"; - //ObjV.Dispose(); - //GVConciliacionemitidasSAT.DataBind(); - //UpDatosReporte.Update(); - - } - private void registrarventa(GridViewRow gvrow) - { - - { - string rutaempresa = UsuarioActual.Empresa.Ruta.Trim().Replace("/", "\\"); - string rutafile = gvrow.DataKey("RutaXml").Trim().Replace("/", "\\"); - rutaempresa = rutaempresa.Substring(rutaempresa.Length - 1, 1) == "\\" ? rutaempresa.Substring(0, rutaempresa.Length - 1): rutaempresa; - rutafile = rutafile.Substring(0, 1) == "\\" ? rutafile.Substring(1): rutafile; - string ruta = string.Format("{0}\\{1}", rutaempresa, rutafile); //gvrow.DataKey("RutaXml"); - //Alert(ruta); - - //return false; - strErrores = new StringBuilder(); - XmlSatCFDI objxml = null; - Modelos.Factura objfact = null; - bool continuar = true; - objxml = XmlSatCFDI.readXML(ruta); - continuar = continuar && (objxml != null); - if (continuar) - { - - objfact = GetFacturaFromXML(objxml); - } - continuar = continuar && (objfact != null); - if (continuar) - { - - // Dim As New (ObjVentas.IniciaTransacSQL()) - // Dim As = Nothing - // Dim MensajeAlert = New StringBuilder - ClsVentas ObjVentas = new ClsVentas(); - ClsInventarios ObjInventario = new ClsInventarios(ObjVentas.IniciaTransacSQL()); - ClsContabilidad ObjConta = new ClsContabilidad(ObjVentas.IniciaTransacSQL()); - ClsContratos ObjContr = new ClsContratos(ObjVentas.IniciaTransacSQL()); - ClsOS ObjOS = new ClsOS(ObjVentas.IniciaTransacSQL()); - ClsBancos ObjBancos = new ClsBancos(ObjVentas.IniciaTransacSQL()); - ClsClientes ObjClientes = new ClsClientes(ObjVentas.IniciaTransacSQL()); - ClsOIEventos ObjEventos = new ClsOIEventos(ObjVentas.IniciaTransacSQL()); - ClsCGame ObjCGame = new ClsCGame(ObjVentas.IniciaTransacSQL()); - ClsEdocumentacion ObjDocCliente = new ClsEdocumentacion(ObjVentas.IniciaTransacSQL()); - ClsAcumuladores ObjAcum = new ClsAcumuladores(ObjVentas.IniciaTransacSQL()); - ClsContPAQi ObjContPaq = null; - //StringBuilder MensajeAlert = new StringBuilder() ; - Modelos.Factura.MMensajeFactura Resp = new Modelos.Factura.MMensajeFactura(); - DataTable DtDetalle = objfact.DtDetalle; - try - { - objfact.GuardarVenta(ref objfact, ref ObjVentas, ref ObjConta, ref ObjInventario, ref ObjContr, ref DtDetalle, objfact.CveNCaVincular, ref ObjContPaq, - ref ObjBancos, ref ObjOS, ref ObjEventos, ref ObjCGame, ref ObjClientes, false, ObjAcum,ref Resp); - - } - catch (Exception e) - { - objfact.CveVenta = -1; - e.ToString().GuardaLog(); - strErrores.AppendLine("
"); - strErrores.AppendLine(e.ToString()); - } - if (ObjVentas.UpdateEstatusFactura(3, objxml.complemento.UUID, "", DateTime.ParseExact(objxml.comprobante.Fecha.Replace("T", " "), "yyyy-MM-dd HH:mm:ss", System.Globalization.CultureInfo.InvariantCulture), ObjVentas.CveVenta, CvePAC: 4)) - if (objfact.CveVenta > 0 && objfact.ErrorList.Count == 0) - { - ObjVentas.Commit(); - } - else - { - foreach (string item in objfact.ErrorList) - { - strErrores.AppendLine("
"); - strErrores.AppendLine(item); - } - objfact.CveVenta = -1; - ObjVentas.RollBack(); - } - ObjVentas.Dispose(); - ObjConta.Dispose(); - ObjInventario.Dispose(); - ObjCGame.Dispose(); - ObjContr.Dispose(); - ObjDocCliente.Dispose(); - ObjClientes.Dispose(); - ObjAcum.Dispose(); - - } - if (objfact != null && objfact.CveVenta > 0) - { - CargaConciliacionemitidasSATGet(); - Alert($"se ha agregado la factura correctamente.
Ver Factura ", ModExtensiones.TipoMensaje.ToastInformacion, timeout: 25); - } - else { continuar = false; } - if (!continuar) - { - Alert($"no se pudo agregar la factura {strErrores.ToString()}", ModExtensiones.TipoMensaje.MsgAdvertencia); - } - } - - } - - protected void LnkRegistrar_Click(object sender, EventArgs e) - { - GridViewRow gvrow = (GridViewRow)(((LinkButton)sender).NamingContainer); - CurrentRow = gvrow; - RegistraScript("$('#DModalDefaults').modal();"); - //registrarventa(gvrow); - //string ruta = gvrow.DataKey("RutaXml"); - //strErrores = new StringBuilder(); - //XmlSatCFDI objxml = null; - //Modelos.Factura objfact = null; - //bool continuar = true; - //objxml = XmlSatCFDI.readXML(ruta); - //continuar = continuar && (objxml != null); - //if (continuar) - //{ - - // objfact = GetFacturaFromXML(objxml); - //} - //continuar = continuar && (objfact != null); - //if (continuar) - //{ - - // // Dim As New (ObjVentas.IniciaTransacSQL()) - // // Dim As = Nothing - // // Dim MensajeAlert = New StringBuilder - // ClsVentas ObjVentas = new ClsVentas(); - // ClsInventarios ObjInventario = new ClsInventarios(ObjVentas.IniciaTransacSQL()); - // ClsContabilidad ObjConta = new ClsContabilidad(ObjVentas.IniciaTransacSQL()); - // ClsContratos ObjContr = new ClsContratos(ObjVentas.IniciaTransacSQL()); - // ClsOS ObjOS = new ClsOS(ObjVentas.IniciaTransacSQL()); - // ClsBancos ObjBancos = new ClsBancos(ObjVentas.IniciaTransacSQL()); - // ClsClientes ObjClientes = new ClsClientes(ObjVentas.IniciaTransacSQL()); - // ClsOIEventos ObjEventos = new ClsOIEventos(ObjVentas.IniciaTransacSQL()); - // ClsCGame ObjCGame = new ClsCGame(ObjVentas.IniciaTransacSQL()); - // ClsEdocumentacion ObjDocCliente = new ClsEdocumentacion(ObjVentas.IniciaTransacSQL()); - // ClsAcumuladores ObjAcum = new ClsAcumuladores(ObjVentas.IniciaTransacSQL()); - // ClsContPAQi ObjContPaq = null; - // //StringBuilder MensajeAlert = new StringBuilder() ; - // try - // { - // objfact.GuardarVenta(ref objfact, ref ObjVentas, ref ObjConta, ref ObjInventario, ref ObjContr, ref objfact.DtDetalle, objfact.CveNCaVincular, ref ObjContPaq, ref ObjBancos, ref ObjOS, ref ObjEventos, ref ObjCGame, ref ObjClientes, ObjAcum: ObjAcum); - - // } - // catch (Exception ) - // { - // objfact.CveVenta = -1; - // } - // if (ObjVentas.UpdateEstatusFactura(3, objxml.complemento.UUID, "", DateTime.ParseExact(objxml.comprobante.Fecha.Replace("T", " "), "yyyy-MM-dd HH:mm:ss", System.Globalization.CultureInfo.InvariantCulture), ObjVentas.CveVenta, CvePAC: 4)) - // if (objfact.CveVenta > 0 && objfact.ErrorList.Count == 0) - // { - // ObjVentas.Commit(); - // } - // else - // { - // foreach (string item in objfact.ErrorList) - // { - // strErrores.AppendLine("
"); - // strErrores.AppendLine(item); - // } - // objfact.CveVenta = -1; - // ObjVentas.RollBack(); - // } - // ObjVentas.Dispose(); - // ObjConta.Dispose(); - // ObjInventario.Dispose(); - // ObjCGame.Dispose(); - // ObjContr.Dispose(); - // ObjDocCliente.Dispose(); - // ObjClientes.Dispose(); - // ObjAcum.Dispose(); - - //} - //if (objfact != null && objfact.CveVenta > 0) - //{ - // CargaConciliacionemitidasSATGet(); - // Alert($"se ha agregado la factura correctamente.
Ver Factura ", ModExtensiones.TipoMensaje.ToastInformacion,timeout:25); - //} - //else { continuar = false; } - //if (!continuar) - //{ - // Alert($"no se pudo agregar la factura {strErrores.ToString()}", ModExtensiones.TipoMensaje.MsgAdvertencia); - //} - } - - protected Modelos.Factura GetFacturaFromXML(XmlSatCFDI objxml) - { - int CvePsReconstruccion = DdlPS.SelectedValue.ToEntero(); - int CveSubProyectoReconstruccion = DdlSubProyectoDatos.SelectedValue.ToEntero(); - //Modelos.Factura.MMensajeFactura resp; - - string Moneda = objxml.comprobante.Moneda; - if (objxml.comprobante.Version == "3.2") - { - switch (Moneda) - { - case "Peso Mexicano": Moneda = "MXN"; break; - case "Dolar Americano": Moneda = "USD"; break; - } - - } - string formadepago = objxml.comprobante.FormaPago; - string metododepago = objxml.comprobante.MetodoPago; - if (objxml.comprobante.Version == "3.2") - { - switch (objxml.comprobante.MetodoPago)//si es correcto estan invertidos - { - case "TRANSFERENCIA ELECTRONICA": formadepago = "03"; break; - default: formadepago = objxml.comprobante.MetodoPago; break; - } - - } - if (objxml.comprobante.Version == "3.2") - { - switch (objxml.comprobante.FormaPago)//si es correcto estan invertidos - { - case "PAGO EN UNA SOLA EXHIBICION": metododepago = "PUE"; break; - default: metododepago = objxml.comprobante.FormaPago; break; - } - - } - - - Modelos.Factura objfact = new Modelos.Factura(UsuarioActual) - { - TipoMensajeRespuesta = Modelos.TipoMensajeRespuesta.TextoLimpio,//?que es esto - CveUsuario = UsuarioActual.CveUsuario, - CveEmpresa = UsuarioActual.CveEmpresa, - - FolioFiscal = objxml.complemento.UUID, - Serie = objxml.comprobante.Serie, - Folio = objxml.comprobante.Folio.ToEntero(),//Nota en el sat puede ser un string - Version = objxml.comprobante.Version, - TipoCambio = objxml.comprobante.TipoCambio, - //ConvertirPesos =false,//?para que sirve - MonedaSAT = objxml.comprobante.Moneda, - CveMoneda = GlobalDTMonedas.FiltroPrimeroValor("CveMoneda", $" AbreviaturaSAT= '{Moneda}' ").ToEntero(), - Moneda = GlobalDTMonedas.FiltroPrimeroValor("Moneda", $" AbreviaturaSAT= '{Moneda}' "), - TipoDocto = objxml.comprobante.TipoDeComprobanteSIG, - RefDocto = "", - CveMesa = -1, - Fecha = DateTime.ParseExact(objxml.comprobante.Fecha, "yyyy-MM-ddTHH:mm:ss", System.Globalization.CultureInfo.InvariantCulture), - CvePrePoliza = -1, - FechaPago = DateTime.Now, - MotivoDescuento = "", - FechaEjecucion = DateTime.Now, - UsuarioCreo = UsuarioActual.Usuario, - CveCondicionEntrega = -1, - CondicionEntrega = "", - NumeroCuenta = "", - CondicionesPago = 0, - FormaPago = 0, - PedidoContrato = "", - NumeroContrato = "", - DescripcionContrato = "", - CveCorte = -1, - TipoDocumento = objxml.comprobante.TipoDeComprobanteTexto, - Alfa1 = "", - Alfa2 = "", - Alfa3 = "", - CveContrato = -1 - }; - DataRow dr = get_GlobalDTSubProyectos(-1, -1, UsuarioActual.CveEmpresa, 1).FiltroPrimero(string.Format("Serie='{0}'", objfact.Serie)); - if (dr == null) { dr = get_GlobalDTSubProyectos(-1, CveSubProyectoReconstruccion, UsuarioActual.CveEmpresa, 1).Rows[0]; } - if (dr != null) - { - objfact.CveSubProyecto = dr["CveSubProyecto"].ToString().ToEntero(); - objfact.CveSubProyectoCobranza = dr["CveSubProyecto"].ToString().ToEntero(); - objfact.CveSubProyectoEjecucion = dr["CveSubProyecto"].ToString().ToEntero(); - objfact.SubProyecto = new Modelos.SubProyectoModel(dr); - objfact.SubProyectoMatriz = new Modelos.SubProyectoModel(get_GlobalDTSubProyectos(-1, CveSubProyecto: -1, CveEmpresa: UsuarioActual.CveEmpresa).FiltroPrimero("TipoSucursal=1")); - - } - using (ClsClientes objClientes = new ClsClientes()) - { - if (objClientes.GetClientes(-1, "-1", "-1", "-1", objxml.receptor.Rfc, "-1", "-1", -1, UsuarioActual.CveEmpresa, -1, TipoCliente: -1) && objClientes.DtResultados.Rows.Count > 0) - { - DataRow drCliente = objClientes.DtResultados.Rows[0]; - objfact.CveCliente = drCliente["CveCliente"].ToString().ToEntero(); - objfact.SetCliente(); - - - } - } - - objfact.CveAlmacen = -1; - objfact.CveFormaPago33 = GlobalDTVtaFormaPago.FiltroPrimeroValor("CveFormaPago", $"ClaveFormaPagoSAT = '{formadepago}'").ToEntero(); - objfact.FormaPagoSAT33 = objxml.comprobante.FormaPago; - objfact.FormaPago33 = objxml.comprobante.FormaPagoTexto; - objfact.CveMetodoPago33 = GlobalDTVtaMetodoPago.FiltroPrimeroValor("CveMetodoPago", $" ClaveMetodoPagoSAT = '{metododepago}'").ToEntero(); - objfact.CveMetodoPago = GlobalDTVtaMetodoPago.FiltroPrimeroValor("CveMetodoPago", $" ClaveMetodoPagoSAT = '{metododepago}'").ToEntero(); - objfact.ClaveMetodoPagoSAT = objxml.comprobante.MetodoPago; - objfact.MetodoPago33 = objxml.comprobante.MetodoPagoTexto; - objfact.CveUsoCFDI = get_GlobalDTSATUsosCFDI(-1).FiltroPrimeroValor("CveUsoCFDI", $"UsoCFDI = '{objxml.receptor.UsoCFDI}'").ToEntero(); - objfact.UsoCFDI = objxml.receptor.UsoCFDITexto; - objfact.ClaveUsoCFDI = objxml.receptor.UsoCFDI; - objfact.CveClienteSucursal = -1; - - objfact.DtDetalle = CreaDTDetalle(UsuarioActual, objxml.conceptos, objfact.CveSubProyecto, CvePsReconstruccion, objxml); - - objfact.TipoCambioDolares = objxml.comprobante.TipoCambio; - objfact.SubTotal = objxml.comprobante.SubTotal; - objfact.Descuento = objxml.comprobante.Descuento; - objfact.Amortizacion = 0; - objfact.IVA = objxml.Impuestos.Where(x => (x.Impuesto == "002" || x.Impuesto == "IVA") && x.Tipo == "Traslados").Sum(item => item.Importe); - objfact.RetIVA = objxml.Impuestos.Where(x => (x.Impuesto == "002" || x.Impuesto == "IVA") && x.Tipo == "Retenciones").Sum(item => item.Importe); - objfact.RetISR = objxml.Impuestos.Where(x => (x.Impuesto == "001" || x.Impuesto == "ISR") && x.Tipo == "Retenciones").Sum(item => item.Importe); - objfact.IEPS = objxml.Impuestos.Where(x => (x.Impuesto == "003" || x.Impuesto == "IEPS")).Sum(item => item.Importe); - objfact.Total = objxml.comprobante.Total; - objfact.TotalOtrosConceptos = 0; - - - objfact.Observaciones = ""; - objfact.OrdenCompra = ""; - objfact.PedidoContrato = ""; - objfact.ObservacionesAlmacen = ""; - if (strErrores.Length > 0) - { - objfact = null; - } - return objfact; - } - private DataTable CreaDTDetalle(Usuario UsuarioActual, List conceptos, int CveSubProyecto, int CvePsReconstruccion, XmlSatCFDI objxml) - { - bool continuar = true; - var TmpDT = new DataTable(); - #region TmpDT Fields - TmpDT.Columns.Add("CveVenta", typeof(int)); - TmpDT.Columns.Add("Consec", typeof(int)); - TmpDT.Columns.Add("Cantidad", typeof(decimal)); - TmpDT.Columns.Add("Codigo", typeof(string)); - TmpDT.Columns.Add("CveUM", typeof(int)); - TmpDT.Columns.Add("UM", typeof(string)); - TmpDT.Columns.Add("SATClaveUM", typeof(string)); - TmpDT.Columns.Add("CveClasificacion", typeof(int)); - TmpDT.Columns.Add("Clasificacion", typeof(string)); - TmpDT.Columns.Add("CvePS", typeof(int)); - TmpDT.Columns.Add("PS", typeof(string)); - TmpDT.Columns.Add("CodigoPS", typeof(string)); - TmpDT.Columns.Add("SATClaveProdServ", typeof(string)); - TmpDT.Columns.Add("NoIdentificacion", typeof(string)); - TmpDT.Columns.Add("CveTipoPS", typeof(int)); - TmpDT.Columns.Add("CveTipoInvPS", typeof(int)); - TmpDT.Columns.Add("Serie", typeof(string)); - TmpDT.Columns.Add("CuentaPredial", typeof(string)); - TmpDT.Columns.Add("Obs", typeof(string)); - TmpDT.Columns.Add("TiempoEntrega", typeof(string)); - TmpDT.Columns.Add("PU", typeof(decimal)); - TmpDT.Columns.Add("IVA", typeof(decimal)); - TmpDT.Columns.Add("ImporteIVA", typeof(decimal)); - TmpDT.Columns.Add("PorcentajeIVA", typeof(decimal)); - TmpDT.Columns.Add("ImporteRetIVA", typeof(decimal)); - TmpDT.Columns.Add("ImporteRetISR", typeof(decimal)); - TmpDT.Columns.Add("PorcentajeRetIVA", typeof(decimal)); - TmpDT.Columns.Add("PorcentajeRetISR", typeof(decimal)); - TmpDT.Columns.Add("ImporteIEPS", typeof(decimal)); - TmpDT.Columns.Add("IEPS", typeof(decimal)); - TmpDT.Columns.Add("PorcentajeIEPS", typeof(decimal)); - TmpDT.Columns.Add("Descuento", typeof(decimal)); - TmpDT.Columns.Add("TipoDescuento", typeof(int)); - TmpDT.Columns.Add("TotalImporte", typeof(decimal)); - TmpDT.Columns.Add("Total", typeof(decimal)); - // Para uso del módulo contable - TmpDT.Columns.Add("AsientoContableVentas", typeof(int)); - TmpDT.Columns.Add("IdCtaContVentas", typeof(int)); - TmpDT.Columns.Add("AplicaParaConcepto", typeof(bool)); - TmpDT.Columns.Add("CveProyecto", typeof(int)); - TmpDT.Columns.Add("Proyecto", typeof(string)); - TmpDT.Columns.Add("CveSubProyecto", typeof(int)); - TmpDT.Columns.Add("SubProyecto", typeof(string)); - // TipoDescuento: 1 = Descuento * PU; 2 = Descuento por Total del concepto - TmpDT.Columns.Add("CvePresupuestoIngreso", typeof(int)); - TmpDT.Columns.Add("CveFuenteRecaudacion", typeof(int)); - // Contratos - TmpDT.Columns.Add("CveContratoDetalle", typeof(int)); - // Remisiones a Facturas - TmpDT.Columns.Add("CveVentaDetalle", typeof(int)); - TmpDT.Columns.Add("CveVentaDetalleRemision", typeof(int)); - TmpDT.Columns.Add("CveVentaDetalleCotizacion", typeof(int)); - // Pedido2 a Facturas - TmpDT.Columns.Add("CveVentaDetallePedido2", typeof(int)); - TmpDT.Columns.Add("Origen", typeof(int)); - // Ordenes Servicio - TmpDT.Columns.Add("CveOS", typeof(int)); - TmpDT.Columns.Add("CveOSDetalle", typeof(int)); - TmpDT.Columns.Add("SeFacturara", typeof(int)); - TmpDT.Columns.Add("Folio", typeof(int)); - TmpDT.Columns.Add("Estatus", typeof(string)); - // Ordenamiento - TmpDT.Columns.Add("Orden", typeof(int)); - TmpDT.Columns.Add("TipoDocto", typeof(string)); - // OC - TmpDT.Columns.Add("CveOrdenCompraDetalle", typeof(int)); - TmpDT.Columns.Add("EntregaDirecta", typeof(int)); - TmpDT.Columns.Add("CveMovimientoDetallePedido", typeof(int)); - TmpDT.Columns.Add("CantidadFacturadaRem", typeof(decimal)); - TmpDT.Columns.Add("CantidadFacturadaCot", typeof(decimal)); - TmpDT.Columns.Add("CantidadInventario", typeof(decimal)); - TmpDT.Columns.Add("ClaveSATFraccionArancelaria", typeof(string)); - TmpDT.Columns.Add("ClaveSATUnidadAduana", typeof(string)); - TmpDT.Columns.Add("ClaveSATFraccionArancelariaDescripcion", typeof(string)); - TmpDT.Columns.Add("ClaveSATUnidadAduanaDescripcion", typeof(string)); - TmpDT.Columns.Add("CveTamaño", typeof(int)); - #endregion - foreach (CFDIConcepto item in conceptos) - { - DataRow DrPS = null;// get_GlobalDTPS(UsuarioActual.CveEmpresa).FiltroPrimero(string.Format("PS ={0}",item.Descripcion)); - - DataRow DrSubProyecto = null; - DataRow DrUmSat = null; - DataRow DrUm = null; - if (continuar) - { - using (ClsProductosServicios obj = new ClsProductosServicios()) - { - if (obj.GetPS(-1, -1, UsuarioActual.CveEmpresa, PS: item.Descripcion) && obj.DtResultados.Rows.Count > 0) - { - DrPS = obj.DtResultados.Rows[0]; - } - else if (obj.GetPS(CvePsReconstruccion, -1, UsuarioActual.CveEmpresa) && obj.DtResultados.Rows.Count > 0) - { - - DrPS = obj.DtResultados.Rows[0]; - } - - } - DrSubProyecto = get_GlobalDTSubProyectos(-1, CveSubProyecto, UsuarioActual.CveEmpresa).Rows[0]; - - - if (objxml.comprobante.Version == "3.2") - { - item.ClaveUnidad = item.Unidad; - switch (item.ClaveUnidad) - { - case "TON": item.ClaveUnidad = "A75"; break; - case "No aplica": item.ClaveUnidad = "ACT"; break; - case "LITROS": item.ClaveUnidad = "E32"; break; - case "M3-KM": item.ClaveUnidad = "M73"; break; - } - - } - - DrUmSat = GlobalDTPSATUM.FiltroPrimero(string.Format("SATClaveUnidadMedida='{0}'", item.ClaveUnidad)); - } - if (continuar && DrUmSat == null) { continuar = false; strErrores.AppendLine($"No se encontro la unidad de medida en el catalogo del sat '{item.ClaveUnidad}', favor de contactar a soporte tecnico."); } - if (continuar) - { - DrUm = get_GlobalDTUnidadesMedida(UsuarioActual.CveEmpresa).FiltroPrimero(string.Format("CveUnidadMedidaSAT={0}", DrUmSat["CveUnidadMedidaSAT"])); - } - if (continuar && DrUm == null) { continuar = false; strErrores.AppendLine($"No se encontro la unidad de medida relacionada a la clave del sat '{item.ClaveUnidad}', favor de asignarla en el catalogo de unidad de medida."); } - if (continuar) - { - //no se encontro una undidad de medida para - DataRow Row = TmpDT.NewRow(); - Row["CveProyecto"] = DrSubProyecto["CveProyecto"].ToString().ToEntero(); - Row["Proyecto"] = DrSubProyecto["Proyecto"].ToString(); - Row["CveSubProyecto"] = CveSubProyecto; - Row["SubProyecto"] = DrSubProyecto["SubProyecto"].ToString(); - Row["Serie"] = ""; - Row["TiempoEntrega"] = ""; - Row["Orden"] = TmpDT.Rows.Count + 1; - Row["Cantidad"] = item.Cantidad; - Row["CveUM"] = DrUm["CveUnidadMedida"]; - Row["UM"] = DrUm["UnidadMedida"]; - Row["CveClasificacion"] = DrPS["CveClasificacion"]; - Row["Clasificacion"] = DrPS["Clasificacion"]; - Row["CvePS"] = DrPS["CvePS"]; - Row["Obs"] = item.Descripcion; - - //TotalCalculableImpuestos = (Cantidad * PU) - Descuento; - - Row["PU"] = item.ValorUnitario; - Row["Codigo"] = DrPS["Codigo"]; - Row["NoIdentificacion"] = DrPS["Codigo"]; - Row["ClaveSATFraccionArancelaria"] = DrPS["ClaveSATFraccionArancelaria"]; - Row["ClaveSATUnidadAduana"] = DrPS["ClaveSATUnidadAduana"]; - Row["ClaveSATFraccionArancelariaDescripcion"] = DrPS["ClaveSATFraccionArancelariaDescripcion"]; - Row["ClaveSATUnidadAduanaDescripcion"] = DrPS["ClaveSATUnidadAduanaDescripcion"]; - Row["Consec"] = TmpDT.Rows.Count + 1; - Row["PS"] = item.Descripcion; - Row["CodigoPS"] = DrPS["PSCodigo"].ToString(); - Row["CveTipoPS"] = DrPS["CveTipoPS"]; - Row["CveTipoInvPS"] = DrPS["Inv_CveMetodoInventario"]; - Row["CveTamaño"] = DrPS["CveTamaño"]; - CFDIConceptoImpuesto impuesto = item.Impuestos.FirstOrDefault(x => x.Impuesto == "002" && x.Tipo == "Traslado"); - decimal sumaimpuesto = 0; - decimal PorcentajeIVA = 0; - if (impuesto != null) - { - decimal decimpuesto = 0; - decimal.TryParse(impuesto.TasaOCuota, out decimpuesto); - PorcentajeIVA = decimpuesto / 100; - Row["PorcentajeIVA"] = PorcentajeIVA; - Row["ImporteIVA"] = impuesto.Importe;// impuesto.Importe;//Math.Round(item.Importe * (decimpuesto/100), 2); - sumaimpuesto += impuesto.Importe; - } - else - { - Row["PorcentajeIVA"] = 0; - Row["ImporteIVA"] = 0; - if (objxml.comprobante.Version == "3.2") - { - if (item.Importe > 0) - { - PorcentajeIVA = .16M; - Row["PorcentajeIVA"] = PorcentajeIVA; - Row["ImporteIVA"] = item.Importe * PorcentajeIVA;//Math.Round(((item.Importe / (1 + PorcentajeIVA))*.16M),2); - - } - } - } - Row["IVA"] = Row["ImporteIVA"]; - impuesto = item.Impuestos.FirstOrDefault(x => x.Impuesto == "003" && x.Tipo == "Traslado"); - if (impuesto != null) - { - decimal decimpuesto = 0; - decimal.TryParse(impuesto.TasaOCuota, out decimpuesto); - Row["PorcentajeIEPS"] = decimpuesto / 100; - Row["ImporteIEPS"] = impuesto.Importe; - Row["IEPS"] = impuesto.Importe; - sumaimpuesto += impuesto.Importe; - } - else - { - Row["PorcentajeIEPS"] = 0; - Row["ImporteIEPS"] = 0; - Row["IEPS"] = 0; - } - impuesto = item.Impuestos.FirstOrDefault(x => x.Impuesto == "001" && x.Tipo == "Retencion"); - if (impuesto != null) - { - decimal decimpuesto = 0; - decimal.TryParse(impuesto.TasaOCuota, out decimpuesto); - Row["PorcentajeRetISR"] = decimpuesto / 100; - Row["ImporteRetISR"] = impuesto.Importe; - sumaimpuesto -= impuesto.Importe; - } - else - { - Row["ImporteRetISR"] = 0; - Row["PorcentajeRetISR"] = 0; - } - impuesto = item.Impuestos.FirstOrDefault(x => x.Impuesto == "002" && x.Tipo == "Retencion"); - if (impuesto != null) - { - decimal decimpuesto = 0; - decimal.TryParse(impuesto.TasaOCuota, out decimpuesto); - Row["PorcentajeRetIVA"] = decimpuesto / 100; - Row["ImporteRetIVA"] = impuesto.Importe; - sumaimpuesto -= impuesto.Importe; - } - else - { - Row["ImporteRetIVA"] = 0; - Row["PorcentajeRetIVA"] = 0; - } - Row["Descuento"] = item.Descuento; - Row["TipoDescuento"] = "2"; - - //Row["Total"] = item.Importe - sumaimpuesto; - Row["Total"] = item.Importe / (1 + PorcentajeIVA); - Row["TotalImporte"] = item.Importe; - - Row["SATClaveProdServ"] = item.ClaveProdServ; - Row["SATClaveUM"] = item.ClaveUnidad; - - Row["EntregaDirecta"] = "-1"; - // Contratos - Row["CveContratoDetalle"] = -1; - Row["CveVentaDetalle"] = -1; - Row["CveMovimientoDetallePedido"] = -1; - Row["CveOrdenCompraDetalle"] = -1; - Row["CveVentaDetalleRemision"] = -1; - Row["CveVentaDetalleCotizacion"] = -1; - Row["CveVentaDetallePedido2"] = -1; - Row["CuentaPredial"] = item.CuentaPredial; - - TmpDT.Rows.Add(Row); - } - } - - - return TmpDT; - } - - - - protected void LnkAceptarDefault_Click(object sender, EventArgs e) - { - RegistraScript("$('#DModalDefaults').modal('hide');"); - registrarventa((GridViewRow)CurrentRow); - //foreach (GridViewRow gvrow in GVConciliacionemitidasSAT.Rows) - //{ - - // registrarventa(gvrow); - //} - } - - protected void BtnConsultar_Click(object sender, EventArgs e) - { - CargaRepConciliacionSatGET(); - } - - protected void GVConciliacionemitidasSAT_RowDataBound(object sender, GridViewRowEventArgs e) - { - if (e.Row.RowType == DataControlRowType.DataRow) - { - string navurl = ""; - if (e.Row.DBCampo("Tipo") == "1") - { - string RutaXml = e.Row.DBCampo("RutaXml"); - //if (RutaXml.IndexOf("Empresas")>0) - //{ - // RutaXml = RutaXml.Substring(RutaXml.IndexOf("Empresas")); - //} - navurl = string.Format("RepConciliacionEmitidosSat.aspx?op={0}", Extensiones.ModExtensiones.Encripta(e.Row.DataKey("RutaXml"))); - } - else - { - navurl = string.Format("/Compras/PopUpVerFactura.aspx?P={0}", Extensiones.ModExtensiones.Encripta(String.Format("OP=FactVta&CVEVENTA={0}&EXT={1}&SERIEFOLIO={2}&TIPODOCTO={3}", e.Row.DBCampo("CveVenta"), "XML", e.Row.DBCampo("SerieFolio"), e.Row.DBCampo("TipoDocto")))); - } - e.Row.FCHyperLink("HypXml").NavigateUrl = navurl; - } - //String.Format("/Compras/PopUpVerFactura.aspx?P={0}", Encripta(String.Format("OP=FactVta&CVEVENTA={0}&EXT={1}&SERIEFOLIO={2}&TIPODOCTO={3}", CveVenta, "XML", DbRowVenta("SerieFolio"), DbRowVenta("TipoDocto")))) - } - - protected void DdlClasificacion_SelectedIndexChanged(object sender, EventArgs e) - { - - int CveClasificacion = DdlClasificacion.SelectedValue.ToEntero(); - if (UsuarioActual.Empresa.Funcionalidad(141).ToString() == "1") - { - - DdlPS.setEsWebService(true); - DdlPS.ddlWS.Attributes.Add("data-cveclasificacion", CveClasificacion.ToString()); - DdlPS.ddlWS.Attributes.Add("data-pagina", "ventas/ventas"); - DdlPS.ddlWS.Attributes.Add("data-Estatus", "1"); - } - else - { - - DdlPS.setEsWebService(false); - DdlPS.ddl.DataSource = get_GlobalDTPSSimplificado(UsuarioActual.CveEmpresa, CveClasificacion: CveClasificacion, Estatus: 1, AplicaParaVenta: 1); - DdlPS.ddl.DataBind(); - } - UpModalDefaults.Update(); - } -} -namespace ADSistemaLibrary2.SatXml -{ - public class XmlSatCFDI - { - public XmlSatCFDI() - { - comprobante = new CFDIComprobante(); - emisor = new CFDIEmisor(); - receptor = new CFDIReceptor(); - complemento = new CFDIComplemento(); - cFDIRelacionados = new List(); - conceptos = new List(); - Impuestos = new List(); - } - public CFDIComprobante comprobante; - public CFDIEmisor emisor; - public CFDIReceptor receptor; - public CFDIComplemento complemento; - public List cFDIRelacionados; - public List conceptos; - public List Impuestos; - public List GetConceptosforpdf() - { - List lcon = new List(); - if (conceptos != null) - { - int _orden = 0; - foreach (CFDIConcepto item in conceptos) - { - _orden += 1; - CFDIConcepto_I con = new CFDIConcepto_I - { - tipo = 1, - orden = _orden, - ClaveProdServ = item.ClaveProdServ, - NoIdentificacion = item.NoIdentificacion, - Cantidad = item.Cantidad, - ClaveUnidad = item.ClaveUnidad, - Unidad = item.Unidad, - ValorUnitario = item.ValorUnitario, - Importe = item.Importe, - Descuento = item.Descuento, - NumeroPedimento = item.NumeroPedimento, - CuentaPredial = item.CuentaPredial, - Descripcion = item.Descripcion - }; - int index = 0; - foreach (CFDIConceptoImpuesto Imp in item.Impuestos) - { - index++; - if (index > 1) - { - lcon.Add(con); - con = new CFDIConcepto_I - { - tipo = 2, - orden = _orden, - }; - - } - - con.Impuesto = Imp.ImpuestoTexto; - con.Impuesto_Tipo = Imp.Tipo; - con.Impuesto_Base = Imp.Base; - con.Impuesto_TipoFactor = Imp.TipoFactor; - con.Impuesto_TasaOCuota = Imp.TasaOCuota; - con.Impuesto_Importe = Imp.Importe; - } - lcon.Add(con); - } - } - - return lcon; - } - - public static XmlSatCFDI readXML(string fileUrl) - { - XmlSatCFDI xmlCFDI = new XmlSatCFDI(); - bool canread = true; - //keys - string keyComprobante = "Comprobante"; - string keyCfdiRelacionados = "CfdiRelacionados"; - string keyEmisor = "Emisor"; - string keyReceptor = "Receptor"; - string keyConceptos = "Conceptos"; - string keyImpuestos = "Impuestos"; - string keyComplemento = "Complemento"; - //endkeys - string[] PrimerNivel = new string[] { keyCfdiRelacionados, keyEmisor, keyReceptor, keyConceptos, keyImpuestos, keyComplemento }; - //(canread = xtr.Read()) para evitar ciclos infinitos, todos los .Read() los guardo en la variable Canread y en los while reviso primero esta variable - if (File.Exists(fileUrl)) - { - XmlReaderSettings settings = new XmlReaderSettings(); - settings.ConformanceLevel = ConformanceLevel.Fragment; - settings.IgnoreWhitespace = true; - settings.IgnoreComments = true; - using (XmlReader xtr = XmlReader.Create(fileUrl, settings)) - { - - while ((canread = xtr.Read()) && !(xtr.NodeType == XmlNodeType.Element && xtr.Name.Replace("cfdi:","") == keyComprobante)) - { - //if (xtr.NodeType != XmlNodeType.Element) { while (xtr.Read() && xtr.NodeType != XmlNodeType.Element) { } } - } - if (xtr.NodeType == XmlNodeType.Element && xtr.Name.Replace("cfdi:", "") == keyComprobante) - { - int Nivel = xtr.Depth; - bool cont = xtr.MoveToFirstAttribute(); - while (cont) - { - - switch (xtr.Name.ToUpper()) - { - case "XMLNS:CFDI": xmlCFDI.comprobante.xmlns_cfdi = xtr.Value; break; - case "XMLNS:XSI": xmlCFDI.comprobante.xmlns_xsi = xtr.Value; break; - case "XSI:SCHEMALOCATION": xmlCFDI.comprobante.xsi_schemaLocation = xtr.Value; break; - case "VERSION": xmlCFDI.comprobante.Version = xtr.Value; break; - case "SERIE": xmlCFDI.comprobante.Serie = xtr.Value; break; - case "FOLIO": xmlCFDI.comprobante.Folio = xtr.Value; break; - case "FECHA": xmlCFDI.comprobante.Fecha = xtr.Value; break; - case "MONEDA": xmlCFDI.comprobante.Moneda = xtr.Value; break; - case "SUBTOTAL": decimal SubTotal = 0; decimal.TryParse(xtr.Value, out SubTotal); xmlCFDI.comprobante.SubTotal = SubTotal; break; - case "TOTAL": decimal Total = 0; decimal.TryParse(xtr.Value, out Total); xmlCFDI.comprobante.Total = Total; break; - case "DESCUENTO": decimal Descuento = 0; decimal.TryParse(xtr.Value, out Descuento); xmlCFDI.comprobante.Descuento = Descuento; break; - case "TIPOCAMBIO": decimal TipoCambio = 0; decimal.TryParse(xtr.Value, out TipoCambio); xmlCFDI.comprobante.TipoCambio = TipoCambio; break; - case "TIPODECOMPROBANTE": xmlCFDI.comprobante.TipoDeComprobante = xtr.Value; break; - case "FORMAPAGO": xmlCFDI.comprobante.FormaPago = xtr.Value; break; - case "FORMADEPAGO": xmlCFDI.comprobante.FormaPago = xtr.Value; break; - case "METODOPAGO": xmlCFDI.comprobante.MetodoPago = xtr.Value; break; - case "METODODEPAGO": xmlCFDI.comprobante.MetodoPago = xtr.Value; break; - case "CONDICIONESDEPAGO": xmlCFDI.comprobante.CondicionesDePago = xtr.Value; break; - case "LUGAREXPEDICION": xmlCFDI.comprobante.LugarExpedicion = xtr.Value; break; - case "CONFIRMACION": xmlCFDI.comprobante.Confirmacion = xtr.Value; break; - case "NOCERTIFICADO": xmlCFDI.comprobante.NoCertificado = xtr.Value; break; - case "SELLO": xmlCFDI.comprobante.Sello = xtr.Value; break; - case "CERTIFICADO": xmlCFDI.comprobante.Certificado = xtr.Value; break; - } - cont = xtr.MoveToNextAttribute(); - } - cont = xtr.MoveToFirstAttribute(); - while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - while (canread && xtr.Depth > Nivel) - { - if (PrimerNivel.Contains(xtr.Name.Replace("cfdi:", ""))) - { - if (xtr.NodeType == XmlNodeType.Element && xtr.Name.Replace("cfdi:", "") == keyCfdiRelacionados) - { - int cDepth = xtr.Depth; - - string TipoRelacion = null; - cont = xtr.MoveToFirstAttribute(); - while (cont) - { - switch (xtr.Name.ToUpper()) - { - case "TIPORELACION": TipoRelacion = xtr.Value; break; - } - cont = xtr.MoveToNextAttribute(); - } - while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - while (canread && xtr.Depth > cDepth) - { - if (xtr.Name.Replace("cfdi:", "") == "CfdiRelacionado") - { - CFDIRelacionado cfdir = new CFDIRelacionado(); - cfdir.TipoRelacion = TipoRelacion; - cfdir.UUID = xtr.GetAttribute("UUID"); - xmlCFDI.cFDIRelacionados.Add(cfdir); - } - while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - } - - } - if (xtr.NodeType == XmlNodeType.Element && xtr.Name.Replace("cfdi:", "") == keyEmisor) - { - - - int curentNivel = xtr.Depth; - cont = xtr.MoveToFirstAttribute(); - while (cont) - { - switch (xtr.Name.ToUpper()) - { - case "REGIMENFISCAL": xmlCFDI.emisor.RegimenFiscal = xtr.Value; break; - case "NOMBRE": xmlCFDI.emisor.Nombre = xtr.Value; break; - case "RFC": xmlCFDI.emisor.Rfc = xtr.Value; break; - } - cont = xtr.MoveToNextAttribute(); - } - while ((canread = xtr.Read()) && !(xtr.NodeType == XmlNodeType.Element && curentNivel >= xtr.Depth)) { }//continua hasta que no tenga nodos y (el nodo sea tipo elemnto y ete en el mismo nivel) - } - if (xtr.NodeType == XmlNodeType.Element && xtr.Name.Replace("cfdi:", "") == keyReceptor) - { - int curentNivel = xtr.Depth; - cont = xtr.MoveToFirstAttribute(); - while (cont) - { - switch (xtr.Name.ToUpper()) - { - case "RFC": xmlCFDI.receptor.Rfc = xtr.Value; break; - case "NOMBRE": xmlCFDI.receptor.Nombre = xtr.Value; break; - case "RESIDENCIAFISCAL": xmlCFDI.receptor.ResidenciaFiscal = xtr.Value; break; - case "NUMREGIDTRIB": xmlCFDI.receptor.NumRegIdTrib = xtr.Value; break; - case "USOCFDI": xmlCFDI.receptor.UsoCFDI = xtr.Value; break; - } - cont = xtr.MoveToNextAttribute(); - } - - while ((canread = xtr.Read()) && !(xtr.NodeType == XmlNodeType.Element && curentNivel >= xtr.Depth)) { }//continua hasta que no tenga nodos y (el nodo sea tipo elemnto y ete en el mismo nivel) - } - if (xtr.NodeType == XmlNodeType.Element && xtr.Name.Replace("cfdi:", "") == keyConceptos) - { - int cDepth = xtr.Depth; - while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - while (canread && xtr.Depth > cDepth) - { - if (xtr.Name.Replace("cfdi:", "") == "Concepto") - { - int cDepthb = xtr.Depth; - CFDIConcepto concepto = new CFDIConcepto(); - - cont = xtr.MoveToFirstAttribute(); - while (cont) - { - switch (xtr.Name.ToUpper()) - { - case "CLAVEPRODSERV": concepto.ClaveProdServ = xtr.Value; break; - case "NOIDENTIFICACION": concepto.NoIdentificacion = xtr.Value; break; - case "CANTIDAD": concepto.Cantidad = xtr.Value; break; - case "CLAVEUNIDAD": concepto.ClaveUnidad = xtr.Value; break; - case "UNIDAD": concepto.Unidad = xtr.Value; break; - case "VALORUNITARIO": decimal ValorUnitario = 0; decimal.TryParse(xtr.Value, out ValorUnitario); concepto.ValorUnitario = ValorUnitario; ; break; - case "IMPORTE": decimal Importe = 0; decimal.TryParse(xtr.Value, out Importe); concepto.Importe = Importe; ; break; - case "DESCUENTO": decimal DDescuento = 0; decimal.TryParse(xtr.Value, out DDescuento); concepto.Descuento = DDescuento; ; break; - case "DESCRIPCION": concepto.Descripcion = xtr.Value; break; - } - cont = xtr.MoveToNextAttribute(); - } - xtr.MoveToFirstAttribute(); - while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - while (canread && xtr.Depth > cDepthb) - { - if (xtr.NodeType == XmlNodeType.Element && xtr.Name.Replace("cfdi:", "") == "Impuestos") - { - int cDepthc = xtr.Depth; - while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - while (canread && xtr.Depth > cDepthc) - { - if (xtr.Name.Replace("cfdi:", "") == "Traslado" || xtr.Name.Replace("cfdi:", "") == "Retencion") - { - CFDIConceptoImpuesto impuesto = new CFDIConceptoImpuesto(); - impuesto.Impuesto = xtr.GetAttribute("Impuesto"); - impuesto.Tipo = xtr.LocalName; - decimal Base = 0; - decimal.TryParse(xtr.GetAttribute("Base"), out Base); - impuesto.Base = Base; - impuesto.TipoFactor = xtr.GetAttribute("TipoFactor"); - decimal tasaOCuota = 0; - decimal.TryParse(xtr.GetAttribute("TasaOCuota"), out tasaOCuota); - impuesto.TasaOCuota = impuesto.TipoFactor == "Tasa" ? (tasaOCuota * 100).ToString("N4") : xtr.GetAttribute("TasaOCuota"); - decimal ImImporte = 0; - decimal.TryParse(xtr.GetAttribute("Importe"), out ImImporte); - impuesto.Importe = ImImporte; - - concepto.Impuestos.Add(impuesto); - } - while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - - } - } - else - { - bool rednew = true; - if (xtr.NodeType == XmlNodeType.Element && xtr.Name.Replace("cfdi:", "") == "InformacionAduanera") - { - concepto.NumeroPedimento = xtr.GetAttribute("NumeroPedimento"); - rednew = false; while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - } - if (xtr.NodeType == XmlNodeType.Element && xtr.Name.Replace("cfdi:", "") == "CuentaPredial") - { - concepto.CuentaPredial = xtr.GetAttribute("CuentaPredial"); - rednew = false; while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - } - if (rednew) { while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } } - - } - } - - xmlCFDI.conceptos.Add(concepto); - } - } - } - if (xtr.NodeType == XmlNodeType.Element && xtr.Name.Replace("cfdi:", "") == keyImpuestos) - { - int cDepth = xtr.Depth; - - while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - while (canread && xtr.Depth > cDepth) - { - CFDIImpuesto impuest = new CFDIImpuesto(); - if (xtr.Name.Replace("cfdi:", "") == "Traslado" || xtr.Name.Replace("cfdi:", "") == "Retencion" && xmlCFDI.comprobante.Version != null) - { - impuest.Tipo = xtr.LocalName == "Traslado" ? "Traslados" : (xtr.LocalName == "Retencion" ? "Retenciones" : ""); - impuest.Impuesto = xmlCFDI.comprobante.Version == "3.3" ? xtr.GetAttribute("Impuesto") : xtr.GetAttribute("impuesto"); - impuest.TipoFactor = xtr.GetAttribute("TipoFactor"); - impuest.TasaOCuota = xmlCFDI.comprobante.Version == "3.3" ? xtr.GetAttribute("TasaOCuota") : xtr.GetAttribute("tasa"); - decimal ImImporte = 0; - decimal.TryParse((xmlCFDI.comprobante.Version == "3.3" ? xtr.GetAttribute("Importe") : xtr.GetAttribute("importe")), out ImImporte); - impuest.Importe = ImImporte; - xmlCFDI.Impuestos.Add(impuest); - } - while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - - } - } - if (xtr.NodeType == XmlNodeType.Element && xtr.Name.Replace("cfdi:", "") == keyComplemento) - { - int cDepth = xtr.Depth; - while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - { - - - - - } - - - while (canread && xtr.Depth > cDepth) - { - if (xtr.NodeType == XmlNodeType.Element && xtr.LocalName == "TimbreFiscalDigital" && xmlCFDI.comprobante.Version != null) - { - xmlCFDI.complemento.xmlns_tfd = xtr.GetAttribute("xmlns:tfd"); - xmlCFDI.complemento.xsi_schemaLocation = xtr.GetAttribute("xsi:schemaLocation"); - xmlCFDI.complemento.Version = xtr.GetAttribute("Version"); - xmlCFDI.complemento.UUID = xtr.GetAttribute("UUID"); - xmlCFDI.complemento.FechaTimbrado = xtr.GetAttribute("FechaTimbrado"); - xmlCFDI.complemento.RfcProvCertif = xtr.GetAttribute("RfcProvCertif"); - xmlCFDI.complemento.SelloCFD = xmlCFDI.comprobante.Version == "3.3" ? xtr.GetAttribute("SelloCFD") : xtr.GetAttribute("selloCFD"); - xmlCFDI.complemento.NoCertificadoSAT = xmlCFDI.comprobante.Version == "3.3" ? xtr.GetAttribute("NoCertificadoSAT") : xtr.GetAttribute("noCertificadoSAT"); - xmlCFDI.complemento.SelloSAT = xmlCFDI.comprobante.Version == "3.3" ? xtr.GetAttribute("SelloSAT") : xtr.GetAttribute("selloSAT"); - - } else if (xtr.NodeType == XmlNodeType.Element && xtr.LocalName.ToUpper() == "NOMINA" && xmlCFDI.comprobante.Version != null) - { - xmlCFDI.complemento.nomina12 = new CFDINomina(); - //Version="1.2" TipoNomina="E" FechaPago="2021-12-08" - //="2021-12-08" ="2021-12-08" - //="1" ="5026.31" ="254.34" - cont = xtr.MoveToFirstAttribute(); - while (cont) - { - switch (xtr.Name.ToUpper()) - { - case "FECHAPAGO": xmlCFDI.complemento.nomina12.FechaPago = xtr.Value.ToDateTime(); break; - case "FECHAINICIALPAGO": xmlCFDI.complemento.nomina12.FechaInicio = xtr.Value; break; - case "FECHAFINALPAGO": xmlCFDI.complemento.nomina12.FechaFin = xtr.Value; break; - case "NUMDIASPAGADOS": xmlCFDI.complemento.nomina12.NumDiasPagados= xtr.Value.ToEntero(); break; - case "TIPONOMINA": xmlCFDI.complemento.nomina12.TipoNomina = xtr.Value; break; - case "Version": xmlCFDI.complemento.nomina12.Version = xtr.Value; break; - } - cont = xtr.MoveToNextAttribute(); - } - xtr.MoveToFirstAttribute(); - } - else if (xtr.NodeType == XmlNodeType.Element && xtr.LocalName == "Pagos" && xmlCFDI.comprobante.Version != null) - { - while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - xmlCFDI.complemento.Pagos = new CFDIPago(); - int depthpagos = xtr.Depth; - bool conts = xtr.MoveToFirstAttribute(); - while (conts) - { - - decimal Base = 0; - switch (xtr.Name.ToUpper()) - { - case "FECHAPAGO": xmlCFDI.complemento.Pagos.FechaPago = xtr.Value; break; - case "FORMADEPAGOP": xmlCFDI.complemento.Pagos.FormaDePagoP = xtr.Value; break; - case "FORMADEPAGOPTEXT": xmlCFDI.complemento.Pagos.FormaDePagoPText = xtr.Value; break; - case "MONEDAP": xmlCFDI.complemento.Pagos.MonedaP = xtr.Value; break; - case "MONTO": decimal.TryParse(xtr.Value, out Base); xmlCFDI.complemento.Pagos.Monto = Base; break; - case "TIPOCAMBIOP": decimal.TryParse(xtr.Value, out Base); xmlCFDI.complemento.Pagos.TipoCambioP = Base; break; - case "NUMOPERACION": xmlCFDI.complemento.Pagos.NumOperacion = xtr.Value; break; - case "NOMBANCOORDEXT": xmlCFDI.complemento.Pagos.NomBancoOrdExt = xtr.Value; break; - case "RFCEMISORCTAORD": xmlCFDI.complemento.Pagos.RfcEmisorCtaOrd = xtr.Value; break; - case "CTAORDENANTE": xmlCFDI.complemento.Pagos.CtaOrdenante = xtr.Value; break; - case "RFCEMISORCTABEN": xmlCFDI.complemento.Pagos.RfcEmisorCtaBen = xtr.Value; break; - case "CTABENEFICIARIO": xmlCFDI.complemento.Pagos.CtaBeneficiario = xtr.Value; break; - } - conts = xtr.MoveToNextAttribute(); - } - conts = xtr.MoveToFirstAttribute(); - while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - while (canread && xtr.Depth > depthpagos) - { - CFDIPagoDoctoRelacionado objpago = new CFDIPagoDoctoRelacionado(); - conts = xtr.MoveToFirstAttribute(); - while (conts) - { - - decimal Basep = 0; - switch (xtr.Name.ToUpper()) - { - case "IDDOCUMENTO": objpago.IdDocumento = xtr.Value; break; - case "SERIE": objpago.Serie = xtr.Value; break; - case "FOLIO": objpago.Folio = xtr.Value; break; - case "MONEDADR": objpago.MonedaDR = xtr.Value; break; - case "METODODEPAGODR": objpago.MetodoDePagoDR = xtr.Value; break; - case "NUMPARCIALIDAD": objpago.NumParcialidad = xtr.Value; break; - case "IMPSALDOANT": decimal.TryParse(xtr.Value, out Basep); objpago.ImpSaldoAnt = Basep; break; - case "IMPPAGADO": decimal.TryParse(xtr.Value, out Basep); objpago.ImpPagado = Basep; break; - case "IMPSALDOINSOLUTO": decimal.TryParse(xtr.Value, out Basep); objpago.ImpSaldoInsoluto = Basep; break; - - } - conts = xtr.MoveToNextAttribute(); - } - conts = xtr.MoveToFirstAttribute(); - xmlCFDI.complemento.Pagos.doctosRelacionados.Add(objpago); - while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - } - } - else - { - while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - - } - } - } - } - else - { - //si no entro en ninguna de los anteriores no se debe ciclar - while ((canread = xtr.Read()) && xtr.NodeType != XmlNodeType.Element) { } - } - } - } - - } - } - if (xmlCFDI.comprobante.Version == "3.3" || xmlCFDI.comprobante.Version == "3.2") - { - return xmlCFDI; - } - else - { - return null; - } - } - - public class utilValores - { - public utilValores(string nombre, string valor) - { - Nombre = nombre; - Valor = valor; - } - public string Nombre { get; set; } - public string Valor { get; set; } - } - public class utilImage - { - public utilImage(byte[] imagenByte) - { - ImagenByte = imagenByte; - } - public byte[] ImagenByte { get; set; } - } - } - - public class CFDIComplemento - { - - public string xmlns_tfd { get; set; } - public string xsi_schemaLocation { get; set; } - public string Version { get; set; } - public string UUID { get; set; } - public string FechaTimbrado { get; set; } - public string RfcProvCertif { get; set; } - public string SelloCFD { get; set; } - public string NoCertificadoSAT { get; set; } - public string SelloSAT { get; set; } - public CFDIPago Pagos { get; set; } - public CFDINomina nomina12 { get; set; } - public string CadenaOriginal - { - get - { - return string.Format("||{0}|{1}|{2}|{3}|{4}|{5}||", Version, UUID, FechaTimbrado, RfcProvCertif, SelloCFD, NoCertificadoSAT); - } - } - - } - public class CFDIComprobante - { - public string xmlns_cfdi { get; set; } - public string xmlns_xsi { get; set; } - public string xsi_schemaLocation { get; set; } - public string Version { get; set; } - public string Serie { get; set; } - public string Folio { get; set; } - public string Fecha { get; set; } - public string Moneda { get; set; } - public decimal SubTotal { get; set; } - public decimal Total { get; set; } - public decimal Descuento { get; set; } - public decimal TipoCambio { get; set; } - public string TipoDeComprobante { get; set; } - - public string TipoDeComprobanteSIG - { - get - { - string retorno = ""; - if (Version == "3.3") - { - switch (TipoDeComprobante) - { - case "I": - retorno = "Ing"; - break; - case "E": - retorno = "Egs"; - break; - case "P": - retorno = "PA"; - break; - //case "T": - // retorno = "Traslado"; - // break; - //case "N": - // retorno = "Nómina"; - // break; - - default: - break; - } - } - else if (Version == "3.2") - { - switch (TipoDeComprobante) - { - case "ingreso": - retorno = "Ing"; - break; - case "egreso": - retorno = "Egs"; - break; - case "P": - retorno = "PA"; - break; - //case "T": - // retorno = "Traslado"; - // break; - //case "N": - // retorno = "Nómina"; - // break; - - default: - break; - } - } - else { retorno = TipoDeComprobante; } - return retorno; - } - } - public string TipoDeComprobanteTexto - { - get - { - string retorno = ""; - - if (Version == "3.3") - { - switch (TipoDeComprobante) - { - case "I": - retorno = "Ingreso"; - break; - case "E": - retorno = "Egreso"; - break; - case "P": - retorno = "Pago"; - break; - case "T": - retorno = "Traslado"; - break; - case "N": - retorno = "Nómina"; - break; - - default: - retorno = TipoDeComprobante; - break; - } - } - else if (Version == "3.2") - { - switch (TipoDeComprobante) - { - case "ingreso": - retorno = "Ing"; - break; - case "egreso": - retorno = "Egs"; - break; - case "P": - retorno = "PA"; - break; - //case "T": - // retorno = "Traslado"; - // break; - //case "N": - // retorno = "Nómina"; - // break; - - default: - retorno = TipoDeComprobante; - break; - } - } - else { retorno = TipoDeComprobante; } - return retorno; - } - } - public string FormaPago { get; set; } - - public string FormaPagoTexto - { - get - { - string retorno = ""; - - switch (FormaPago) - { - case "01": retorno = "Efectivo"; break; - case "02": retorno = "Cheque nominativo"; break; - case "03": retorno = "Transferencia electrónica de fondos"; break; - case "04": retorno = "Tarjeta de crédito"; break; - case "05": retorno = "Monedero electrónico"; break; - case "06": retorno = "Dinero electrónico"; break; - case "08": retorno = "Vales de despensa"; break; - case "12": retorno = "Dación en pago"; break; - case "13": retorno = "Pago por subrogación"; break; - case "14": retorno = "Pago por consignación"; break; - case "15": retorno = "Condonación"; break; - case "17": retorno = "Compensación"; break; - case "23": retorno = "Novación"; break; - case "24": retorno = "Confusión"; break; - case "25": retorno = "Remisión de deuda"; break; - case "26": retorno = "Prescripción o caducidad"; break; - case "27": retorno = "A satisfacción del acreedor"; break; - case "28": retorno = "Tarjeta de débito"; break; - case "29": retorno = "Tarjeta de servicios"; break; - case "30": retorno = "Aplicación de anticipos"; break; - case "31": retorno = "Intermediario pagos"; break; - case "99": retorno = "Por definir"; break; - default: retorno = FormaPago; break; - } - return retorno; - } - } - public string MetodoPago { get; set; } - public string MetodoPagoTexto - { - get - { - string retorno = ""; - - switch (MetodoPago) - { - case "PUE": retorno = "Pago en una sola exhibición"; break; - case "PPD": retorno = "Pago en parcialidades o diferido"; break; - default: retorno = MetodoPago; break; - } - return retorno; - } - } - public string CondicionesDePago { get; set; } - public string LugarExpedicion { get; set; } - public string Confirmacion { get; set; } - public string NoCertificado { get; set; } - public string Sello { get; set; } - public string Certificado { get; set; } - - } - - public class CFDIConcepto - { - public CFDIConcepto() - { - Impuestos = new List(); - } - public string ClaveProdServ { get; set; } - public string NoIdentificacion { get; set; } - public string Cantidad { get; set; } - public string ClaveUnidad { get; set; } - public string Unidad { get; set; } - public decimal ValorUnitario { get; set; } - public decimal Importe { get; set; } - public decimal Descuento { get; set; } - public string NumeroPedimento { get; set; } - public string CuentaPredial { get; set; } - public string Descripcion { get; set; } - public List Impuestos { get; set; } - } - - public class CFDIConcepto_I - { - public int tipo { get; set; } - public int orden { get; set; } - public string ClaveProdServ { get; set; } - public string NoIdentificacion { get; set; } - public string Cantidad { get; set; } - public string ClaveUnidad { get; set; } - public string Unidad { get; set; } - public decimal ValorUnitario { get; set; } - public decimal Importe { get; set; } - public decimal Descuento { get; set; } - public string NumeroPedimento { get; set; } - public string CuentaPredial { get; set; } - public string Descripcion { get; set; } - - - public string Impuesto { get; set; } - - public string Impuesto_Tipo { get; set; } - public decimal Impuesto_Base { get; set; } - public string Impuesto_TipoFactor { get; set; } - public string Impuesto_TasaOCuota { get; set; } - public decimal Impuesto_Importe { get; set; } - } - - public class CFDIConceptoImpuesto - { - public string Impuesto { get; set; } - public string ImpuestoTexto - { - get - { - string retorno = ""; - - switch (Impuesto) - { - case "001": retorno = "ISR"; break; - case "002": retorno = "IVA"; break; - case "003": retorno = "IEPS"; break; - } - return retorno; - } - } - public string Tipo { get; set; } - public decimal Base { get; set; } - public string TipoFactor { get; set; } - public string TasaOCuota { get; set; } - public decimal Importe { get; set; } - - } - - public class CFDIEmisor - { - public string RegimenFiscal { get; set; } - - public string RegimenFiscalTexto - { - get - { - string retorno = ""; - - switch (RegimenFiscal) - { - case "601": retorno = "General de Ley Personas Morales"; break; - case "603": retorno = "Personas Morales con Fines no Lucrativos"; break; - case "605": retorno = "Sueldos y Salarios e Ingresos Asimilados a Salarios"; break; - case "606": retorno = "Arrendamiento"; break; - case "608": retorno = "Demás ingresos"; break; - case "609": retorno = "Consolidación"; break; - case "610": retorno = "Residentes en el Extranjero sin Establecimiento Permanente en México"; break; - case "611": retorno = "Ingresos por Dividendos (socios y accionistas)"; break; - case "612": retorno = "Personas Físicas con Actividades Empresariales y Profesionales"; break; - case "614": retorno = "Ingresos por intereses"; break; - case "616": retorno = "Sin obligaciones fiscales"; break; - case "620": retorno = "Sociedades Cooperativas de Producción que optan por diferir sus ingresos"; break; - case "621": retorno = "Incorporación Fiscal"; break; - case "622": retorno = "Actividades Agrícolas, Ganaderas, Silvícolas y Pesqueras"; break; - case "623": retorno = "Opcional para Grupos de Sociedades"; break; - case "624": retorno = "Coordinados"; break; - case "628": retorno = "Hidrocarburos"; break; - case "607": retorno = "Régimen de Enajenación o Adquisición de Bienes"; break; - case "629": retorno = "De los Regímenes Fiscales Preferentes y de las Empresas Multinacionales"; break; - case "630": retorno = "Enajenación de acciones en bolsa de valores"; break; - case "615": retorno = "Régimen de los ingresos por obtención de premios"; break; - - } - return retorno; - } - } - public string Nombre { get; set; } - public string Rfc { get; set; } - - } - - public class CFDIImpuesto - { - public string Tipo { get; set; } - public string Impuesto { get; set; } - public string ImpuestoTexto - { - get - { - string retorno = ""; - - switch (Impuesto) - { - case "001": retorno = "ISR"; break; - case "002": retorno = "IVA"; break; - case "003": retorno = "IEPS"; break; - } - return retorno; - } - } - public string TipoFactor { get; set; } - public string TasaOCuota { get; set; } - public decimal Importe { get; set; } - } - - public class CFDIPago - { - public CFDIPago() - { - doctosRelacionados = new List(); - } - public string FechaPago { get; set; } - public string FormaDePagoP { get; set; } - public string FormaDePagoPText { get; set; } - public string MonedaP { get; set; } - public decimal Monto { get; set; } - public decimal TipoCambioP { get; set; } - public string NumOperacion { get; set; } - public string NomBancoOrdExt { get; set; } - public string RfcEmisorCtaOrd { get; set; } - public string CtaOrdenante { get; set; } - public string RfcEmisorCtaBen { get; set; } - public string CtaBeneficiario { get; set; } - public List doctosRelacionados { get; set; } - } - - public class CFDIPagoDoctoRelacionado - { - public string IdDocumento { get; set; } - public string Serie { get; set; } - public string Folio { get; set; } - public string MonedaDR { get; set; } - public string MetodoDePagoDR { get; set; } - public string NumParcialidad { get; set; } - public decimal ImpSaldoAnt { get; set; } - public decimal ImpPagado { get; set; } - public decimal ImpSaldoInsoluto { get; set; } - } - - public class CFDIReceptor - { - public string Rfc { get; set; } - public string Nombre { get; set; } - public string ResidenciaFiscal { get; set; } - public string NumRegIdTrib { get; set; } - public string UsoCFDI { get; set; } - public string UsoCFDITexto - { - get - { - string retorno = "N/A"; - - switch (UsoCFDI) - { - case "G01": - retorno = "Adquisición de mercancías"; - break; - case "G02": - retorno = "Devoluciones, descuentos o bonificaciones"; - break; - case "G03": - retorno = "Gastos en general"; - break; - case "I01": - retorno = "Construcciones"; - break; - case "I02": - retorno = "Mobiliario y equipo de oficina por inversiones"; - break; - case "I03": - retorno = "Equipo de transporte"; - break; - case "I04": - retorno = "Equipo de cómputo y accesorios"; - break; - case "I05": - retorno = "Dados, troqueles, moldes, matrices y herramental"; - break; - case "I06": - retorno = "Comunicaciones telefónicas"; - break; - case "I07": - retorno = "Comunicaciones satelitales"; - break; - case "I08": - retorno = "Otra maquinaria y equipo"; - break; - case "D01": - retorno = "Honorarios médicos, dentales y gastos hospitalarios."; - break; - case "D02": - retorno = "Gastos médicos por incapacidad o discapacidad"; - break; - case "D03": - retorno = "Gastos funerales."; - break; - case "D04": - retorno = "Donativos."; - break; - case "D05": - retorno = "Intereses reales efectivamente pagados por créditos hipotecarios (casa habitación)."; - break; - case "D06": - retorno = "Aportaciones voluntarias al SAR."; - break; - case "D07": - retorno = "Primas por seguros de gastos médicos."; - break; - case "D08": - retorno = "Gastos de transportación escolar obligatoria."; - break; - case "D09": - retorno = "Depósitos en cuentas para el ahorro, primas que tengan como base planes de pensiones."; - break; - case "D10": - retorno = "Pagos por servicios educativos (colegiaturas)"; - break; - case "P01": - retorno = "Por definir"; - break; - - default: - break; - } - return retorno; - } - } - - } - - public class CFDIRelacionado - { - public string TipoRelacion { get; set; } - public string TipoRelacionTexto - { - - get - { - string retorno; - - switch (TipoRelacion) - { - case "01": retorno = "Nota de crédito de los documentos relacionados"; break; - case "02": retorno = "Nota de débito de los documentos relacionados"; break; - case "03": retorno = "Devolución de mercancía sobre facturas o traslados previos"; break; - case "04": retorno = "Sustitución de los CFDI previos"; break; - case "05": retorno = "Traslados de mercancias facturados previamente"; break; - case "06": retorno = "Factura generada por los traslados previos"; break; - case "07": retorno = "CFDI por aplicación de anticipo"; break; - default: - retorno = "Por definir"; - break; - } - return retorno; - } - } - public string UUID { get; set; } - - } -} \ No newline at end of file diff --git a/vwd.webinfo b/vwd.webinfo index c139fadbc..fdbdd590d 100644 --- a/vwd.webinfo +++ b/vwd.webinfo @@ -566,6 +566,12 @@ + + + + + + From fa0fa097ba2622426071645135f0896016619352 Mon Sep 17 00:00:00 2001 From: JORGE LUIS CAUDILLO ESPARZA Date: Tue, 4 Oct 2022 22:57:46 -0700 Subject: [PATCH 05/12] --- App_Code/ClsRH.vb | 18 + Ashx/SigFiles.ashx | 4 + GPS/PalletEtiqueta2 - copia.rdlc | 3684 ++++++++++++++++++++++++++++++ GPS/PalletEtiqueta2.rdlc | 1108 ++++----- RH/CatPersonal.aspx | 29 +- RH/CatPersonal.aspx.vb | 7 + RH/Personal.aspx.vb | 15 +- vwd.webinfo | 2 + 8 files changed, 4310 insertions(+), 557 deletions(-) create mode 100644 GPS/PalletEtiqueta2 - copia.rdlc diff --git a/App_Code/ClsRH.vb b/App_Code/ClsRH.vb index 2fc71f5d3..8d4a1894e 100644 --- a/App_Code/ClsRH.vb +++ b/App_Code/ClsRH.vb @@ -2264,6 +2264,24 @@ chkAplicaVacacion As Boolean, chkAplicaIncapacidad As Boolean, chkAplicaRetardo End Try Return Retorno End Function + Public Function PersonalUitimoCodigoGET(CveEmpresa As Integer, prefijo As String) As String + Dim Codigo As String = "-1" + SqlDataAdapter("PA_RH_PersonalUitimoCodigoGET") + With SqlAdapter.SelectCommand.Parameters + .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa + .Add("@Prefijo", SqlDbType.VarChar).Value = prefijo + .Add("@Codigo", SqlDbType.Int).Direction = ParameterDirection.Output + End With + Try + SqlAdapter.Fill(Data) + Codigo = SqlAdapter.SelectCommand.Parameters("@Codigo").Value.ToString() + Catch ex As SqlException + OnError("Ocurrió un error al intentar guardar los cambios en el Personal.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo) + End Try + Return Codigo + End Function + + Public Function Updateestemporal(CvePersonal As Integer, CveEmpresa As Integer, estemporal As Boolean) As Boolean Dim Retorno As Boolean = False SqlDataAdapter("PA_RH_PersonalUpdateesTemporal") diff --git a/Ashx/SigFiles.ashx b/Ashx/SigFiles.ashx index 3ab1e80ad..2cb7cab5d 100644 --- a/Ashx/SigFiles.ashx +++ b/Ashx/SigFiles.ashx @@ -12,6 +12,10 @@ public class SigFiles : IHttpHandler //context.Response.ContentType = "text/plain"; //context.Response.Write("Hello World"); string path = ""; + if (context.Request["Ru"] != null) + { + path = string.Format("{0}",ModExtensiones.Decripta( context.Request["Ru"])); + } if (context.Request["FileUrl"] != null) { path = string.Format("{0}{1}", ModExtensiones.DirectorioBaseEmpresas, context.Request["FileUrl"]); diff --git a/GPS/PalletEtiqueta2 - copia.rdlc b/GPS/PalletEtiqueta2 - copia.rdlc new file mode 100644 index 000000000..656ddb873 --- /dev/null +++ b/GPS/PalletEtiqueta2 - copia.rdlc @@ -0,0 +1,3684 @@ + + + 0 + + + + System.Data.DataSet + /* Local Connection */ + + 06ae5329-8ff5-42b5-b7f4-6d68e5186421 + + + + + + dsImagenes + /* Local Query */ + + + + ImagenByte + System.Byte[] + + + + dsImagenes + C:\Users\Caudillo\Documents\Visual Studio 2013\WebSites\WebSite3\App_Code\DataSet.xsd + dtImagenes + + + + + + + + + + + + + + + 2.81806cm + + + 2.93411cm + + + 2.28832cm + + + 2.65186cm + + + + + 0.44125cm + + + + + true + true + + + + + PALLET-TAG + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + 03 + + + + =Parameters!noPallet.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + 2 + + + + + + + true + true + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.44125cm + + + + + true + true + + + + + COMMODITY + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Parameters!Cultivo.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + 3 + + + + + + + + 0.38833cm + + + + + true + true + + + + + VARIETY + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Parameters!Variedad.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + 3 + + + + + + + + 0.44125cm + + + + + true + true + + + + + STYLE + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Parameters!Envase.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + 3 + + + + + + + + 0.36187cm + + + + + true + true + + + + + LABEL + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Grower + + + + + + 2pt + 2pt + 2pt + 2pt + + + 3 + + + + + + + + 0.36187cm + + + + + true + true + + + + + PACKS + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Parameters!NoCajas.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + 3 + + + + + + + + 0.25604cm + + + + + true + true + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.6cm + + + + + true + true + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + Database + =First(Fields!ImagenByte.Value, "dsImagenes") + image/png + FitProportional + 14 + + + + + 2 + + + + + + + true + true + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.49417cm + + + + + true + true + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + 03 + + + + =Parameters!noPallet.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + 2 + + + + + + + true + true + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.41479cm + + + + + true + true + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.41479cm + + + + + true + true + + + + + PALLET-TAG + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + 03 + + + + =Parameters!noPallet.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.44125cm + + + + + true + true + + + + + COMMODITY + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + VARIETY + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + COUNTRY + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + Database + =First(Fields!ImagenByte.Value, "dsImagenes") + image/png + FitProportional + 14 + + + + + + + + + + 0.45921cm + + + + + true + + + + + =Parameters!Cultivo.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + + + + + =Parameters!Variedad.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + MEXICO + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + 03 + + + + =Parameters!noPallet.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.3475cm + + + + + true + true + + + + + STYLE + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + SIZE + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + LABEL + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.6cm + + + + + true + true + + + + + =Parameters!Envase.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Parameters!Tamano.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Grower + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.36187cm + + + + + true + true + + + + + PALLET-TAG + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + 03 + + + + =Parameters!noPallet.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.17667cm + + + + + true + true + + + + + COMMODITY + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + VARIETY + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + COUNTRY + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + Database + =First(Fields!ImagenByte.Value, "dsImagenes") + image/png + FitProportional + 14 + + + + + + + + + + 0.44125cm + + + + + true + + + + + =Parameters!Cultivo.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + + + + + =Parameters!Variedad.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + MEXICO + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + 03 + + + + =Parameters!noPallet.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.36187cm + + + + + true + true + + + + + STYLE + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + SIZE + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + LABEL + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.62646cm + + + + + true + true + + + + + =Parameters!Envase.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Parameters!Tamano.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Grower + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.41479cm + + + + + true + true + + + + + PALLET-TAG + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + 03 + + + + =Parameters!noPallet.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.41479cm + + + + + true + true + + + + + COMMODITY + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + VARIETY + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + COUNTRY + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + Database + =First(Fields!ImagenByte.Value, "dsImagenes") + image/png + FitProportional + 14 + + + + + + + + + + 0.38833cm + + + + + true + + + + + =Parameters!Cultivo.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + + + + + =Parameters!Variedad.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + MEXICO + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + 03 + + + + =Parameters!noPallet.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.38833cm + + + + + true + true + + + + + STYLE + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + SIZE + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + LABEL + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.6cm + + + + + true + true + + + + + =Parameters!Envase.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Parameters!Tamano.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Grower + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.44125cm + + + + + true + true + + + + + PALLET-TAG + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + 03 + + + + =Parameters!noPallet.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.36187cm + + + + + true + true + + + + + COMMODITY + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + VARIETY + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + COUNTRY + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + Database + =First(Fields!ImagenByte.Value, "dsImagenes") + image/png + FitProportional + 14 + + + + + + + + + + 0.44125cm + + + + + true + + + + + =Parameters!Cultivo.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + + + + + =Parameters!Variedad.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + MEXICO + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + 03 + + + + =Parameters!noPallet.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.33542cm + + + + + true + true + + + + + STYLE + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + SIZE + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + LABEL + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + 0.36187cm + + + + + true + true + + + + + =Parameters!Envase.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Parameters!Tamano.Value + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Grower + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + + + + + + + 2pt + 2pt + 2pt + 2pt + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0.0762cm + 0.10266cm + 12.57959cm + 10.69235cm + + + + + + 5.09718in +
@@ -80,10 +80,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt
@@ -99,14 +99,14 @@ 03 =Parameters!noPallet.Value @@ -119,10 +119,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt 2 @@ -139,7 +139,9 @@ - - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -161,7 +163,7 @@
- 0.44125cm + 0.38833cm @@ -174,7 +176,7 @@ COMMODITY @@ -187,10 +189,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -206,7 +208,7 @@ =Parameters!Cultivo.Value @@ -218,10 +220,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt 3 @@ -232,7 +234,7 @@ - 0.38833cm + 0.30896cm @@ -245,7 +247,7 @@ VARIETY @@ -258,10 +260,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -277,7 +279,7 @@ =Parameters!Variedad.Value @@ -289,10 +291,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt 3 @@ -303,7 +305,7 @@ - 0.44125cm + 0.38833cm @@ -316,7 +318,7 @@ STYLE @@ -329,10 +331,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -348,7 +350,7 @@ =Parameters!Envase.Value @@ -360,10 +362,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt 3 @@ -387,7 +389,7 @@ LABEL @@ -400,10 +402,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -419,7 +421,7 @@ Grower @@ -432,10 +434,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt 3 @@ -446,7 +448,7 @@ - 0.36187cm + 0.33541cm @@ -459,7 +461,7 @@ PACKS @@ -472,10 +474,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -491,7 +493,7 @@ =Parameters!NoCajas.Value @@ -503,10 +505,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt 3 @@ -517,7 +519,7 @@ - 0.25604cm + 0.15021cm @@ -530,7 +532,7 @@ @@ -543,10 +545,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -561,7 +563,9 @@ - - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -590,7 +594,9 @@ - - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -619,7 +625,9 @@ - - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -654,7 +662,7 @@ @@ -667,10 +675,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -703,7 +711,9 @@ - - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -738,7 +748,7 @@ @@ -751,10 +761,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -770,14 +780,14 @@ 03 =Parameters!noPallet.Value @@ -790,10 +800,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt 2 @@ -810,7 +820,9 @@ - - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -832,7 +844,7 @@ - 0.41479cm + 0.22958cm @@ -845,7 +857,7 @@ @@ -858,10 +870,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -877,7 +889,7 @@ @@ -889,10 +901,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -908,7 +920,7 @@ @@ -921,10 +933,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -939,7 +951,9 @@ - - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -974,7 +988,7 @@ PALLET-TAG @@ -987,10 +1001,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1006,7 +1020,7 @@ @@ -1018,10 +1032,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1037,14 +1051,14 @@ 03 =Parameters!noPallet.Value @@ -1057,10 +1071,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1075,7 +1089,9 @@ - - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1110,7 +1126,7 @@ COMMODITY @@ -1123,10 +1139,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1142,7 +1158,7 @@ VARIETY @@ -1155,10 +1171,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1174,7 +1190,7 @@ COUNTRY @@ -1187,10 +1203,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1226,7 +1242,7 @@ =Parameters!Cultivo.Value @@ -1238,10 +1254,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1256,7 +1272,7 @@ =Parameters!Variedad.Value @@ -1268,10 +1284,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1287,7 +1303,7 @@ MEXICO @@ -1300,10 +1316,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1319,14 +1335,14 @@ 03 =Parameters!noPallet.Value @@ -1339,10 +1355,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1363,7 +1379,7 @@ STYLE @@ -1376,10 +1392,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1395,7 +1411,7 @@ SIZE @@ -1408,10 +1424,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1427,7 +1443,7 @@ LABEL @@ -1440,10 +1456,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1458,7 +1474,9 @@ - - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1493,7 +1511,7 @@ =Parameters!Envase.Value @@ -1505,10 +1523,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1524,7 +1542,7 @@ =Parameters!Tamano.Value @@ -1536,10 +1554,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1555,7 +1573,7 @@ Grower @@ -1568,10 +1586,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1587,7 +1605,7 @@ @@ -1600,10 +1618,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1624,7 +1642,7 @@ PALLET-TAG @@ -1637,10 +1655,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1656,7 +1674,7 @@ @@ -1668,10 +1686,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1687,14 +1705,14 @@ 03 =Parameters!noPallet.Value @@ -1707,10 +1725,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1725,7 +1743,9 @@ - - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1760,7 +1780,7 @@ COMMODITY @@ -1773,10 +1793,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1792,7 +1812,7 @@ VARIETY @@ -1805,10 +1825,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1824,7 +1844,7 @@ COUNTRY @@ -1837,10 +1857,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1876,7 +1896,7 @@ =Parameters!Cultivo.Value @@ -1888,10 +1908,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1906,7 +1926,7 @@ =Parameters!Variedad.Value @@ -1918,10 +1938,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1937,7 +1957,7 @@ MEXICO @@ -1950,10 +1970,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -1969,14 +1989,14 @@ 03 =Parameters!noPallet.Value @@ -1989,10 +2009,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2013,7 +2033,7 @@ STYLE @@ -2026,10 +2046,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2045,7 +2065,7 @@ SIZE @@ -2058,10 +2078,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2077,7 +2097,7 @@ LABEL @@ -2090,10 +2110,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2108,7 +2128,9 @@ - - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2143,7 +2165,7 @@ =Parameters!Envase.Value @@ -2155,10 +2177,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2174,7 +2196,7 @@ =Parameters!Tamano.Value @@ -2186,10 +2208,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2205,7 +2227,7 @@ Grower @@ -2218,10 +2240,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2237,7 +2259,7 @@ @@ -2250,10 +2272,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2274,7 +2296,7 @@ PALLET-TAG @@ -2287,10 +2309,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2306,7 +2328,7 @@ @@ -2318,10 +2340,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2337,14 +2359,14 @@ 03 =Parameters!noPallet.Value @@ -2357,10 +2379,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2375,7 +2397,9 @@ - - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2410,7 +2434,7 @@ COMMODITY @@ -2423,10 +2447,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2442,7 +2466,7 @@ VARIETY @@ -2455,10 +2479,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2474,7 +2498,7 @@ COUNTRY @@ -2487,10 +2511,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2526,7 +2550,7 @@ =Parameters!Cultivo.Value @@ -2538,10 +2562,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2556,7 +2580,7 @@ =Parameters!Variedad.Value @@ -2568,10 +2592,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2587,7 +2611,7 @@ MEXICO @@ -2600,10 +2624,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2619,14 +2643,14 @@ 03 =Parameters!noPallet.Value @@ -2639,10 +2663,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2663,7 +2687,7 @@ STYLE @@ -2676,10 +2700,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2695,7 +2719,7 @@ SIZE @@ -2708,10 +2732,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2727,7 +2751,7 @@ LABEL @@ -2740,10 +2764,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2758,7 +2782,9 @@ - - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2793,7 +2819,7 @@ =Parameters!Envase.Value @@ -2805,10 +2831,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2824,7 +2850,7 @@ =Parameters!Tamano.Value @@ -2836,10 +2862,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2855,7 +2881,7 @@ Grower @@ -2868,10 +2894,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2887,7 +2913,7 @@ @@ -2900,10 +2926,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2924,7 +2950,7 @@ PALLET-TAG @@ -2937,10 +2963,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2956,7 +2982,7 @@ @@ -2968,10 +2994,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -2987,14 +3013,14 @@ 03 =Parameters!noPallet.Value @@ -3007,10 +3033,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3025,7 +3051,9 @@ - - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3060,7 +3088,7 @@ COMMODITY @@ -3073,10 +3101,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3092,7 +3120,7 @@ VARIETY @@ -3105,10 +3133,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3124,7 +3152,7 @@ COUNTRY @@ -3137,10 +3165,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3176,7 +3204,7 @@ =Parameters!Cultivo.Value @@ -3188,10 +3216,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3206,7 +3234,7 @@ =Parameters!Variedad.Value @@ -3218,10 +3246,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3237,7 +3265,7 @@ MEXICO @@ -3250,10 +3278,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3269,14 +3297,14 @@ 03 =Parameters!noPallet.Value @@ -3289,10 +3317,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3313,7 +3341,7 @@ STYLE @@ -3326,10 +3354,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3345,7 +3373,7 @@ SIZE @@ -3358,10 +3386,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3377,7 +3405,7 @@ LABEL @@ -3390,10 +3418,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3408,7 +3436,9 @@ - - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3443,7 +3473,7 @@ =Parameters!Envase.Value @@ -3455,10 +3485,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3474,7 +3504,7 @@ =Parameters!Tamano.Value @@ -3486,10 +3516,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3505,7 +3535,7 @@ Grower @@ -3518,10 +3548,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3537,7 +3567,7 @@ @@ -3550,10 +3580,10 @@ - 2pt - 2pt - 2pt - 2pt + 0.5pt + 0.5pt + 0.5pt + 0.5pt @@ -3606,8 +3636,8 @@ 0.0762cm 0.10266cm - 12.57959cm - 10.69235cm + 11.99751cm + 9.15777cm @@ -3615,17 +3645,17 @@ - 5.09718in + 4.7951in - Textbox4 @@ -211,12 +230,14 @@ Sub Proyecto - Textbox14 @@ -243,14 +264,16 @@ - Descripcion + Activo Fijo - Textbox6 @@ -279,12 +302,14 @@ Producto - Textbox15 @@ -313,12 +338,14 @@ Responsable - Textbox16 @@ -345,26 +372,30 @@ - Horometro/ + Horo./ - - Odometro + Odo. - Textbox18 @@ -382,6 +413,78 @@ + + + + true + true + + + + + Tipo Mant. + + + + + + + Textbox17 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + Clasificacion 2 + + + + + + + Textbox21 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + @@ -393,12 +496,14 @@ U.M. - Textbox5 @@ -425,14 +530,16 @@ - Cantidad + Cant. - Textbox19 @@ -461,12 +568,14 @@ PU - Textbox3 @@ -495,12 +604,14 @@ Total - Textbox13 @@ -518,6 +629,42 @@ + + + + true + true + + + + + Cuenta Contable + + + + + + + Textbox20 + + + LightGrey + 2pt + 2pt + 2pt + 2pt + + + + @@ -534,7 +681,7 @@ =Fields!SerieFolio.Value @@ -567,7 +714,7 @@ =Fields!SubProyecto.Value @@ -599,7 +746,7 @@ =Fields!CodigoAF.Value @@ -631,7 +778,7 @@ =Fields!CodigoPS.Value @@ -664,7 +811,7 @@ =Fields!NombreCompleto.Value @@ -697,7 +844,7 @@ =Fields!AFMedida.Value @@ -719,6 +866,76 @@ + + + + true + true + + + + + =Fields!AFTipoMantenimientoStr.Value + + + + + + + AFTipoMantenimientoStr + + + =IIF(Fields!Orden.Value.ToString = "0","Silver","White") + 2pt + 2pt + 2pt + 2pt + + + + + + + + true + true + + + + + =Fields!Clasificacion2.Value + + + + + + + Clasificacion2 + + + =IIF(Fields!Orden.Value.ToString = "0","Silver","White") + 2pt + 2pt + 2pt + 2pt + + + + @@ -730,7 +947,7 @@ =Fields!UnidadMedida.Value @@ -763,7 +980,7 @@ =Fields!Cantidad.Value @@ -799,7 +1016,7 @@ =Fields!PU.Value @@ -835,7 +1052,7 @@ =Fields!Total.Value @@ -860,6 +1077,41 @@ + + + + true + true + + + + + =Fields!CuentaContable.Value + + + + + + + CuentaContable + + + =IIF(Fields!Orden.Value.ToString = "0","Silver","White") + 2pt + 2pt + 2pt + 2pt + + + + @@ -876,6 +1128,9 @@ + + + @@ -891,7 +1146,7 @@ DataSet1 0.9482cm 0.09525cm - 1.06771cm + 1.20002cm 26.76762cm 2 - - - Conciliación CFDI SAT - - - - -
  • Solicitudes SAT
  • - -
    - - - - - - -
    -
    -
    - - -
    -
    -
    - - -
    - Fecha Inicio: -
    -
    -
    - - - - -
    - - - - - - -
    -
    - Fecha Fin: -
    -
    -
    - - - - -
    - - - - - - -
    -
    -
    -
    - -
    -
    -
    - - - - - - - - - - - - <%# Eval("CFDISIG")%> - - - - - <%# Eval("CFDISAT")%> - - - - - <%# Eval("CFDISIGSinSAT")%> - - - - - <%# Eval("CFDISATSinSIG")%> - - - - - - - - - - - - - - <%----%> - - -
    - - - - diff --git a/Ventas/RepConciliacionSat.aspx.cs b/Ventas/RepConciliacionSat.aspx.cs deleted file mode 100644 index 6d282df49..000000000 --- a/Ventas/RepConciliacionSat.aspx.cs +++ /dev/null @@ -1,135 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using Extensiones; - -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) - { - DateTime fecha; - DateTime fechaInicio = DateTime.Now; - DateTime fechaFin = DateTime.Now; - if (fechaInicio.Day < 5) { fechaInicio = fechaInicio.AddMonths(-1); } - fechaInicio = fechaInicio.AddDays(1 - fechaInicio.DayOfYear); - fechaFin = fechaInicio.AddYears(1).AddDays(-1); - if (Request[rqFechaInicio] != null) { DateTime.TryParse(Request[rqFechaInicio], out fecha); fechaInicio = fecha.Year > 1900 ? fecha : fechaInicio; } - if (Request[rqFechaFin] != null) { DateTime.TryParse(Request[rqFechaFin], out fecha); fechaFin = fecha.Year > 1900 ? fecha : fechaFin; } - txtFechaI.Text = string.Format("{0:dd/MM/yyyy}", fechaInicio); - txtFechaF.Text = string.Format("{0:dd/MM/yyyy}", fechaFin); - - - } - CargaRepConciliacionSatGET(); - } - - - protected void CargaRepConciliacionSatGET() - { - string RtipoDocto; - RtipoDocto = "I"; - 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); - GVRepConciliacionSatGET.DataSource = ObjRepC.DtResultados; - ObjRepC.Dispose(); - - } - GVRepConciliacionSatGET.DataBind(); - upDatosRepC.Update(); - } - - protected void BtnConsultar_Click(object sender, EventArgs e) - { - CargaRepConciliacionSatGET(); - } - - protected void GVRepConciliacionSatGET_RowDataBound(object sender, GridViewRowEventArgs e) - { - if (e.Row.RowType == DataControlRowType.DataRow) - { - 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); - } - } -} \ No newline at end of file diff --git a/Ventas/RepIngresos.aspx b/Ventas/RepIngresos.aspx deleted file mode 100644 index 59b888063..000000000 --- a/Ventas/RepIngresos.aspx +++ /dev/null @@ -1,252 +0,0 @@ -<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="RepIngresos.aspx.vb" Inherits="Ventas_RepIngresos" %> - - - - - - - - Reporte de Ingresos - - - - - - -
  • - PDF -
  • -
  • - Excel -
  • -
  • - Ver Dlls en pesos -
  • -
    - - - - -
    -
    - - - - - - -
    -
    -
    - - - "> - - -
    -
    -
    -
    - -
    -
    -
    - - - - -
    - - -
    -
    - -
    -
    -
    - - - - -
    - - -
    -
    - -
    - -
    - - - - - - - - - - - - <%-- - - - - - - --%> -
    -
    - -
    -
    - <%-- - - --%> - - - - -
    -
    -
    -
    -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    -
    - - - - - -
    - - - diff --git a/Ventas/RepIngresos.aspx.vb b/Ventas/RepIngresos.aspx.vb deleted file mode 100644 index 8e5a5f6af..000000000 --- a/Ventas/RepIngresos.aspx.vb +++ /dev/null @@ -1,197 +0,0 @@ - -Imports System.Data -Imports Extensiones -Imports Microsoft.Reporting.WebForms - -Partial Class Ventas_RepIngresos - Inherits ClsPaginas - -#Region "Propiedades" - Protected ReadOnly Property Filtros As String - Get - Dim retorno As New StringBuilder - If RsFechaI <> "-1" Then - retorno.Append("&RsFechaI=") - retorno.Append(RsFechaI) - End If - If RsFechaF <> "-1" Then - retorno.Append("&RsFechaF=") - retorno.Append(RsFechaF) - End If - If TipoDoc <> "-1" Then - retorno.Append("&TipoDoc=") - retorno.Append(TipoDoc) - End If - If CveSubProyecto <> -1 Then - retorno.Append("&CveSubProyecto=") - retorno.Append(CveSubProyecto) - End If - Return retorno.ToString() - End Get - End Property - Private Property RsFechaI() As String - Get - Return If(IsNothing(ViewState("RsFechaI")), "-1", CStr(ViewState("RsFechaI"))) - End Get - Set - ViewState("RsFechaI") = Value - End Set - End Property - Private Property RsFechaF() As String - Get - Return If(IsNothing(ViewState("RsFechaF")), "-1", CStr(ViewState("RsFechaF"))) - End Get - Set - ViewState("RsFechaF") = Value - End Set - End Property - Private Property TipoDoc() As String - Get - Return If(IsNothing(ViewState("TipoDoc")), "-1", CStr(ViewState("TipoDoc"))) - End Get - Set - ViewState("TipoDoc") = Value - End Set - End Property - Private Property CveSubProyecto() As Integer - Get - Return If(IsNothing(ViewState("CveSubProyecto")), -1, ViewState("CveSubProyecto").ToString().ToEntero()) - End Get - Set - ViewState("CveSubProyecto") = Value - End Set - End Property - Private Property DtDatos As DataTable - Get - DtDatos = DirectCast(ViewState("DtDatos"), DataTable) - End Get - - Set(ByVal value As DataTable) - ViewState("DtDatos") = value - End Set - End Property - - Private Property TipoCambio As Integer - Get - Return ViewState("TipoCambio").ToString.ToEntero - End Get - - Set(value As Integer) - ViewState("TipoCambio") = value - End Set - End Property - Private Property TCEspecifico As Decimal - Get - Return ViewState("TCEspecifico").ToString.ToDecimal - End Get - - Set(value As Decimal) - ViewState("TCEspecifico") = value - End Set - End Property -#End Region - - Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load - If Not IsPostBack Then - TCEspecifico = -1 - TipoCambio = 1 - CveSubProyecto = -1 - TxtFechaInicio.Text = String.Format("01/01/{0}", Now.Year) - DdlSubProyecto.DataSource = GlobalDTSubProyectosUsuarios(UsuarioActual.CveUsuario, -1, UsuarioActual.CveEmpresa, -1, 1) - DdlSubProyecto.DataBind() - - End If - End Sub - - Protected Sub CargaRepIngresos(Optional tipoReporte As Integer = -1) - Dim Cves_Subprotectos As String = If(DdlSubProyecto.GetSelectedValuesM = "", "-1", DdlSubProyecto.GetSelectedValuesM) - Dim TiposDoc As String = If(DdlTipoDocto.GetSelectedValuesM = "", "-1", DdlTipoDocto.GetSelectedValuesM) - - 'If RblTipoCambio.SelectedValue.ToEntero = 3 And TxtEspecifico.Text <> "" Then - ' TCEspecifico = TxtEspecifico.Text.ToDecimal - 'Else - ' TCEspecifico = -1 - 'End If - - Dim ObjRepI As New ClsVentas() - If ObjRepI.RepIngresos(UsuarioActual.CveEmpresa, If(RsFechaI = "-1", MinFecha, RsFechaI.ToDate), If(RsFechaF = "-1", MaxFecha, RsFechaF.ToDate), TiposDoc, Cves_Subprotectos, TipoCambio:=TipoCambio, TCEspecifico:=TCEspecifico) Then - GVRepIngresos.DataSource = ObjRepI.DtResultados - DtDatos = ObjRepI.DtResultados - End If - ObjRepI.Dispose() - GVRepIngresos.DataBind() - upDatosRepI.Update() - End Sub - Protected Sub LnkFiltrar_Click(sender As Object, e As EventArgs) - RsFechaI = TxtFechaInicio.Text.Replace("__/__/____", "").Trim() - RsFechaI = If(RsFechaI.Length > 6, RsFechaI.ToDate().ToString("yyyy/MM/dd"), "-1") - RsFechaF = TxtFechaFin.Text.Replace("__/__/____", "").Trim() - RsFechaF = If(RsFechaF.Length > 6, RsFechaF.ToDate().ToString("yyyy/MM/dd"), "-1") - TipoDoc = DdlTipoDocto.SelectedValue - CveSubProyecto = DdlSubProyecto.SelectedValue.ToEntero() - CargaRepIngresos() - End Sub -#Region "IMPRESION" - Protected Sub LnkPDF_Click(sender As Object, e As EventArgs) - GeneraImpresion() - End Sub - Protected Sub LnkExcel_Click(sender As Object, e As EventArgs) - GeneraImpresion("Excel") - End Sub - - Private Sub GeneraImpresion(Optional Formato As String = "PDF") - - Dim Imagen As New System.IO.FileInfo(String.Format("{0}/Logo.png", UsuarioActual.Empresa.Ruta)) - Dim logouri = String.Format("{0}://{1}:{2}/Empresas/{3}/Logo.png", Request.Url.Scheme, Request.Url.Host, Request.Url.Port, UsuarioActual.CveEmpresa) - - Dim FI As String = If(TxtFechaInicio.Text = "", "", $"Fecha Inicio: {TxtFechaInicio.Text} ") - Dim FF As String = If(TxtFechaFin.Text = "", "", $"Fecha Fin: {TxtFechaFin.Text} ") - Dim Tipo As String = If(DdlTipoDocto.SelectedValue = "", "", $"Tipo Docto: {DdlTipoDocto.GetSelectedText} ") - Dim subProy As String = If(DdlSubProyecto.SelectedValue = "", "", $"SubProyecto: {DdlSubProyecto.GetSelectedText} ") - - If DtDatos IsNot Nothing AndAlso DtDatos.Rows.Count > 0 Then - - Dim params As New List(Of ReportParameter) - - params.Add(New ReportParameter("NombreEmpresa", UsuarioActual.Empresa.Empresa)) - params.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre)) - params.Add(New ReportParameter("AgrupadoPor", $"{FI}{FF}{Tipo}{subProy}")) - params.Add(New ReportParameter("FechaImpresion", DateAndTime.Now)) - If Imagen.Exists Then - params.Add(New ReportParameter("LogoPath", logouri)) - Else - params.Add(New ReportParameter("LogoPath", "")) - End If - - ImprimirPDF("Empresas/Grales/Formatos/RepIngresos.rdlc", DtDatos, params, "RepPUESinPago", Formato) - Else - Alert("No se encontraron datos con los filtros especificados", TipoMensaje.MsgAdvertencia) - End If - - End Sub -#End Region - Protected Sub GVRepIngresos_RowDataBound(sender As Object, e As GridViewRowEventArgs) - If e.Row.RowType = DataControlRowType.DataRow Then - If e.Row.DBCampo("TipoAmortizacion") = "" Then - e.Row.CssClass = "Totales" - ElseIf e.Row.DBCampo("TipoAmortizacion") <> "" AndAlso e.Row.DBCampo("CveConceptoContable") = "" Then - e.Row.CssClass = "SubTotales" - End If - End If - End Sub - Private Sub RblTipoCambio_SelectedIndexChanged(sender As Object, e As EventArgs) Handles RblTipoCambio.SelectedIndexChanged - TipoCambio = RblTipoCambio.SelectedValue.ToEntero - 'If TipoCambio = 3 Then - ' LiEspecifico.Visible = True - ' TCEspecifico = GlobalTipoCambio(Now).ToDecimal - ' TxtEspecifico.Text = TCEspecifico.ToString - 'Else - ' LiEspecifico.Visible = False - 'End If - UpBodyTipoCambio.Update() - End Sub - Private Sub BtnTipoCambio_Click(sender As Object, e As EventArgs) Handles BtnTipoCambio.Click - RegistraScript(String.Format("$('#{0}').modal('hide');", "DivTipoCambio")) - LnkFiltrar_Click(LnkFiltrar, EventArgs.Empty) - End Sub -End Class diff --git a/Ventas/ReporteDetalle.aspx b/Ventas/ReporteDetalle.aspx deleted file mode 100644 index 8b4f500cf..000000000 --- a/Ventas/ReporteDetalle.aspx +++ /dev/null @@ -1,52 +0,0 @@ -<%@ Page Language="C#" AutoEventWireup="true" CodeFile="ReporteDetalle.aspx.cs" Inherits="Ventas_ReporteDetalle" %> - -<%@ Register Assembly="Stimulsoft.Report.MobileDesign, Version=2017.1.10, Culture=neutral, PublicKeyToken=EBE6666CBA19647A" - Namespace="Stimulsoft.Report.MobileDesign" TagPrefix="cc2" %> - - - - - - - - - - -
    - - - - - diff --git a/Ventas/SolicitudesSAT.aspx b/Ventas/SolicitudesSAT.aspx deleted file mode 100644 index 66c61af18..000000000 --- a/Ventas/SolicitudesSAT.aspx +++ /dev/null @@ -1,406 +0,0 @@ -<%@ Page Title="" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true" CodeFile="SolicitudesSAT.aspx.cs" Inherits="Ventas_SolicitudesSAT" %> - - - - - - - - Solicitudes CFDI SAT - - - - - - -
  • - Verificar Solicitudes
  • -
  • - Solicitar SAT
  • -
    -
    -
    - - - - - -
    -
    -
    - - <%----%> -
    -
    -
    -
    - Tipo: -
    -
    - - - - - -
    -
    - Fecha Inicio(ing.): -
    -
    -
    - - - - -
    - - - - - - -
    -
    - Fecha Fin(ing.): -
    -
    -
    - - - - -
    - - - - - - -
    -
    - Fecha Inicio(Sol.): -
    -
    -
    - - - - -
    - - - - - - -
    -
    - Fecha Fin(Sol.): -
    -
    -
    - - - - -
    - - - - - - -
    -
    -
    -
    - -
    -
    -
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    - - - - diff --git a/Ventas/SolicitudesSAT.aspx.cs b/Ventas/SolicitudesSAT.aspx.cs deleted file mode 100644 index 4206749c7..000000000 --- a/Ventas/SolicitudesSAT.aspx.cs +++ /dev/null @@ -1,151 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using Extensiones; - -public partial class Ventas_SolicitudesSAT : ClsPaginas -{ - protected void Page_Load(object sender, EventArgs e) - { - - if (!IsPostBack) - { - //this.RegistraScript("$('#ModalSolicitarSat').modal();"); - int rtipo = Request["tipo"] == null ? -1 : Request["tipo"].ToString().ToEntero(); - string rfIngInicio = Request["fIngInicio"] == null ? "" : Request["fIngInicio"].ToString().Trim(); - string rfIngFin = Request["fIngFin"] == null ? "" : Request["fIngFin"].ToString().Trim(); - string rfSolInicio = Request["fSolInicio"] == null ? "" : Request["fSolInicio"].ToString().Trim(); - string rfSolFin = Request["fSolFin"] == null ? "" : Request["fSolFin"].ToString().Trim(); - - if (rfIngInicio == "") - { - rfIngInicio = string.Format("{0:01/MM/yyyy}",DateTime.Now); - } - if (rfIngFin == "") - { - rfIngFin = string.Format("{0:dd/MM/yyyy}",string.Format("{0:01/MM/yyyy}", DateTime.Now).ToDateTime().AddMonths(1).AddDays(-1)); - - } - DateTime dValor = DateTime.Now; - dValor = DateTime.Now; if (DateTime.TryParse(rfIngInicio, out dValor)) { rfIngInicio = string.Format("{0:dd/MM/yyyy}", dValor); } else { rfIngInicio = ""; } - dValor = DateTime.Now; if (DateTime.TryParse(rfIngFin, out dValor)) { rfIngFin = string.Format("{0:dd/MM/yyyy}", dValor); } else { rfIngFin = ""; } - dValor = DateTime.Now; if (DateTime.TryParse(rfSolInicio, out dValor)) { rfSolInicio = string.Format("{0:dd/MM/yyyy}", dValor); } else { rfSolInicio = ""; } - dValor = DateTime.Now; if (DateTime.TryParse(rfSolFin, out dValor)) { rfSolFin = string.Format("{0:dd/MM/yyyy}", dValor); } else { rfSolFin = ""; } - - DdlTipo.SelectedValueExist(rtipo); - txtFechaI.Text = rfIngInicio; - txtFechaF.Text = rfIngFin; - txtFechaISol.Text = rfSolInicio; - txtFechaFSol.Text = rfSolFin; - cargarDatos(); - } - } - - - private void cargarDatos() - { - int rtipo = DdlTipo.SelectedValue.ToEntero(); - string rfIngInicio = txtFechaI.Text; - string rfIngFin = txtFechaF.Text; - string rfSolInicio = txtFechaISol.Text; - string rfSolFin = txtFechaFSol.Text; - using (ClsGenerales objgral = new ClsGenerales()) - { - objgral.SAT_DescargaSolicitudesGET(UsuarioActual.CveEmpresa, rtipo, rfIngInicio, rfIngFin, rfSolInicio, rfSolFin); - GVSAT_DescargaSolicitudes.DataSource = objgral.DtResultados; - GVSAT_DescargaSolicitudes.DataBind(); - } - upDatosSAT.Update(); - } - - protected void BtnConsultar_Click(object sender, EventArgs e) - { - cargarDatos(); - } - - protected void LnkVerificarSolicitudes_Click(object sender, EventArgs e) - { - string direxe = string.Format("{0}{1}", AppDomain.CurrentDomain.BaseDirectory, "Utilerias\\ADSUtilerias.exe"); - - String json = string.Format("{{cveTareaProgramada:{0},cveEmpresa:{1},CveTareaProgramadaHistorial:{2},recursividad:{3},Resultado:{4},parametros:'Tipo=SP'}}", 1, UsuarioActual.CveEmpresa, -1, 0, 1);//Mod.ToLiteral(new System.Web.Script.Serialization.JavaScriptSerializer().Serialize(tarea)); - //this.Alert(string.Format("json:{0} : --mod TareaProgramada --Item {1}", DateTime.Now, json)); - try - { - string Mensajes = ""; - System.Diagnostics.Process ObjProcess = null; - { - ObjProcess = new System.Diagnostics.Process(); - ObjProcess.StartInfo.RedirectStandardOutput = true; - ObjProcess.StartInfo.FileName = direxe;//System.Configuration.ConfigurationManager.AppSettings["DirUtilerias"].ToString(); - ObjProcess.StartInfo.Arguments = $"--mod TareaProgramada --Item {json} "; - ObjProcess.StartInfo.UseShellExecute = false; - ObjProcess.StartInfo.WindowStyle = System.Diagnostics.ProcessWindowStyle.Normal; - ObjProcess.Start(); - } - using (System.IO.StreamReader myStreamReader = ObjProcess.StandardOutput) - { - Mensajes = myStreamReader.ReadLine(); - - } - } - catch (Exception ex) - { - ex.ToString().GuardaLog(); - } - cargarDatos(); - Alert("La solicitud ha sido enviada"); - } - - protected void LnkSolicitarCFDI_Click(object sender, EventArgs e) - { - 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"); - - String json = string.Format("{{cveTareaProgramada:{0},cveEmpresa:{1},CveTareaProgramadaHistorial:{2},recursividad:{3},Resultado:{4},parametros:'Tipo={5}&fechai={6}&fechaf={7}'}}", 1, UsuarioActual.CveEmpresa, -1, 0, 1, DdlTipoAdd.SelectedValue, FechaI, FechaF);//Mod.ToLiteral(new System.Web.Script.Serialization.JavaScriptSerializer().Serialize(tarea)); - //this.Alert(string.Format("json:{0} : --mod TareaProgramada --Item {1}", DateTime.Now, json)); - try - { - string Mensajes = ""; - System.Diagnostics.Process ObjProcess = null; - { - ObjProcess = new System.Diagnostics.Process(); - ObjProcess.StartInfo.RedirectStandardOutput = true; - ObjProcess.StartInfo.FileName = direxe;//System.Configuration.ConfigurationManager.AppSettings["DirUtilerias"].ToString(); - ObjProcess.StartInfo.Arguments = $"--mod TareaProgramada --Item {json} "; - ObjProcess.StartInfo.UseShellExecute = false; - ObjProcess.StartInfo.WindowStyle = System.Diagnostics.ProcessWindowStyle.Normal; - ObjProcess.Start(); - } - using (System.IO.StreamReader myStreamReader = ObjProcess.StandardOutput) - { - Mensajes = myStreamReader.ReadLine(); - - } - } - catch (Exception ex) - { - ex.ToString().GuardaLog(); - } - cargarDatos(); - Alert("La solicitud ha sido enviada"); - } - - protected void LnknoCFDI_Click(object sender, EventArgs e) - { - GridViewRow gvrow = (GridViewRow)(((LinkButton)sender).NamingContainer); - int CveSolicitudSat = gvrow.DataKey("CveSolicitudSat").ToEntero(); - using (ClsGenerales objgeneral = new ClsGenerales()) - { - objgeneral.SAT_DescargaSolicitudeUUIDSGET(CveSolicitudSat); - GVFoliosSAT.DataSource = objgeneral.DtResultados; - } - GVFoliosSAT.DataBind(); - RegistraScript("$('#ModalFoliosSolicitud').modal();"); - UpFoliosSAT.Update(); - } -} \ No newline at end of file From 10f86c3f9fba58f8c90b6c969d573890de415d52 Mon Sep 17 00:00:00 2001 From: Oscar Irigoyen Date: Wed, 5 Oct 2022 10:38:56 -0700 Subject: [PATCH 07/12] Ajsutes Clientes --- Ventas/Clientes.aspx | 78 +++++++++++++++++++++++++------------------- 1 file changed, 45 insertions(+), 33 deletions(-) diff --git a/Ventas/Clientes.aspx b/Ventas/Clientes.aspx index 3ddfef9e4..1726f0ca5 100644 --- a/Ventas/Clientes.aspx +++ b/Ventas/Clientes.aspx @@ -177,6 +177,10 @@ color: orange; background-color: orange; } + + .margenChk{ + margin-left:15px!important; + } @@ -1648,13 +1652,11 @@
    - Parametros - - - + Parametros
    +
    - +
    @@ -1802,12 +1804,26 @@ - -
    - - +
    +
    +
    + + +
    +
    +
    +
    + + + +
    +
    + + + +
    @@ -1817,17 +1833,12 @@
    - - - + +
    - -
    - - -
    +
    @@ -1871,53 +1882,54 @@
    - -
    + +
    - + +
    -
    - -
    +
    +
    - + +
    -
    - -
    +
    +
    - + +
    -
    - -
    +
    +
    - + +
    - +
    From c41fd5ddc099c2fa3cca83d0f86efa78a510e4c1 Mon Sep 17 00:00:00 2001 From: rrene Date: Wed, 5 Oct 2022 13:13:11 -0700 Subject: [PATCH 08/12] -- --- Bancos/DepositosCaja.aspx.vb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Bancos/DepositosCaja.aspx.vb b/Bancos/DepositosCaja.aspx.vb index 7cbb67f23..3dc18e324 100644 --- a/Bancos/DepositosCaja.aspx.vb +++ b/Bancos/DepositosCaja.aspx.vb @@ -43,8 +43,8 @@ Partial Class Bancos_DepositosCaja DdlCajaChica.DataSource = GlobalDTBancosCuentas(UsuarioActual.CveUsuario, CveEmpresa:=UsuarioActual.CveEmpresa).FiltraParametros(" CveTipoCuenta = 1", "", {"CveCuenta", "NumCuentaMoneda"}) DdlCajaChica.DataBind() - 'código temporal, para claudia y toñita - If UsuarioActual.CveUsuario.Contiene(1937, 2452) Then + 'código temporal, para claudia y toñita, monge, anadelia + If UsuarioActual.CveUsuario.Contiene(1937, 2452, 3358, 3033) Then DdlCajaChica.Items.Add(New ListItem("Todas", "-1")) End If From fbc1cac8d54c0477c59fef41531d9c46f98eb961 Mon Sep 17 00:00:00 2001 From: rrene Date: Wed, 5 Oct 2022 15:50:22 -0700 Subject: [PATCH 09/12] =?UTF-8?q?--=20se=20quitaron=20las=20fechas,=20y=20?= =?UTF-8?q?se=20activ=C3=B3=20el=20cambio=20de=20estatus=20en=20todos?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Ventas/RepLineasAdicionales.aspx | 100 ++++++++-------------------- Ventas/RepLineasAdicionales.aspx.cs | 40 ++++++++--- 2 files changed, 60 insertions(+), 80 deletions(-) diff --git a/Ventas/RepLineasAdicionales.aspx b/Ventas/RepLineasAdicionales.aspx index 4a65fdc2b..4c38cc00b 100644 --- a/Ventas/RepLineasAdicionales.aspx +++ b/Ventas/RepLineasAdicionales.aspx @@ -3,12 +3,7 @@ - + @@ -16,10 +11,7 @@ - - - - +
  • @@ -57,35 +49,13 @@
  • -
    Fecha Inicio:
    -
    -
    - - - - -
    - - - - - - -
    -
    Fecha Fin:
    -
    -
    - - - - -
    - - - - - - +
    Estatus:
    +
    + + + + +
    @@ -93,24 +63,14 @@
    - - - +
    @@ -130,38 +90,34 @@ + OnRowCommand ="GvLineasAdicionales_RowCommand" + OnRowDataBound="GvLineasAdicionales_RowDataBound"> - - - - - + + + - + <%----%> - + - - - + + +
    -
    + -
    -
    + -
    -
    - -
    + + +
    diff --git a/Ventas/RepLineasAdicionales.aspx.cs b/Ventas/RepLineasAdicionales.aspx.cs index f6266c005..c154e960b 100644 --- a/Ventas/RepLineasAdicionales.aspx.cs +++ b/Ventas/RepLineasAdicionales.aspx.cs @@ -2,7 +2,6 @@ using System.Collections.Generic; using System.IO; using ListItem = System.Web.UI.WebControls.ListItem; -using DocumentFormat.OpenXml.Spreadsheet; using System.Web.UI; public partial class Ventas_RepLineasAdicionales : ClsPaginas @@ -91,8 +90,8 @@ public partial class Ventas_RepLineasAdicionales : ClsPaginas DdlClientes.SelectedText = "Todos"; DdlClientes.SelectedValue = "-1"; - txtFechaI.Text = DateTime.Now.FirstDayOfMonth().ToShortDateString(); - txtFechaF.Text = DateTime.Now.AddMonths(3).ToString("dd/MM/yyyy"); + //txtFechaI.Text = DateTime.Now.FirstDayOfMonth().ToShortDateString(); + //txtFechaF.Text = DateTime.Now.AddMonths(3).ToString("dd/MM/yyyy"); } @@ -111,7 +110,7 @@ public partial class Ventas_RepLineasAdicionales : ClsPaginas int CveProveedor = DdlProveedor.SelectedValue.ToEntero() > 0 ? DdlProveedor.SelectedValue.ToEntero() : -1; - if(objVentas.GetLineasAdicionales(-1,DdlClientes.SelectedValue.ToEntero(),CveProveedor, TipoLinea, -1,txtFechaI.Text.ToDate(), txtFechaF.Text.ToDate(), DdlEstatus.SelectedValue.ToEntero(), UsuarioActual.CveEmpresa)){ + if(objVentas.GetLineasAdicionales(-1,DdlClientes.SelectedValue.ToEntero(),CveProveedor, TipoLinea, -1, MinFecha, MaxFecha, DdlEstatus.SelectedValue.ToEntero(), UsuarioActual.CveEmpresa)){ GvLineasAdicionales.DataSource = objVentas.DtResultados; if( objVentas.DtResultados.Rows.Count > 0) @@ -273,14 +272,12 @@ public partial class Ventas_RepLineasAdicionales : ClsPaginas gvTemp.Columns[8].Visible = false; gvTemp.ExportToExcelx( TipoLinea == 1 ? "RepLienasAdicionales":"RepPO"); } - - - + protected void GvLineasAdicionales_RowDataBound(object sender, GridViewRowEventArgs e) { if(e.Row.RowType == DataControlRowType.DataRow) { - if(e.Row.DataKey("CveLineaAdicionalEstatus").ToEntero().Contiene(1) && e.Row.DataKey("CveVenta").ToEntero() > 0) + if(e.Row.DataKey("CveVenta").ToEntero() > 0) { e.Row.FCLinkButton("LnkCambiarEstatus").Visible = true; } @@ -321,4 +318,31 @@ public partial class Ventas_RepLineasAdicionales : ClsPaginas Response.End(); } } + + protected void GvLineasAdicionales_RowCommand(object sender, GridViewCommandEventArgs e) + { + + GridViewRow GvRow = (GridViewRow)((LinkButton)e.CommandSource).NamingContainer; + int CveLineaAdicionalActualzarEstatus = GvRow.DataKey("CveLineaAdicional").ToString().ToEntero(); + int CveVenta = GvRow.DataKey("CveVenta").ToString().ToEntero(); + + bool errorCambioEstatus = false; + int cveestatus = e.CommandArgument.ToEntero() + 2; //pasar al siguiente estatus + + ClsVentas objVentas = new ClsVentas(); + + if (!objVentas.UpdateLineasAdicionales(CveLineaAdicionalActualzarEstatus, "-1", -1, -1, -1, -1, -1, MinFecha, 100, -1, UsuarioActual.CveEmpresa, CveVenta: CveVenta, CveLineaAdicionalEstatus: cveestatus)) + { + errorCambioEstatus = true; + } + + + objVentas.Dispose(); + if (!errorCambioEstatus) + { + CargaDatos(); + } + + + } } \ No newline at end of file From 5a49bc984e954a92ff0e00e387b0723075e7be30 Mon Sep 17 00:00:00 2001 From: Oscar Irigoyen Date: Wed, 5 Oct 2022 15:50:54 -0700 Subject: [PATCH 10/12] Limpieza modulos --- App_Code/ClsCompras.vb | 25 ----- App_Code/ClsPaginas.vb | 3 +- App_Code/ClsVentas.vb | 19 +--- Compras/RepPerioricidad.aspx | 153 ------------------------------- Compras/RepPerioricidad.aspx.vb | 111 ---------------------- Ventas/RepArqueosDetalle.aspx | 117 ----------------------- Ventas/RepArqueosDetalle.aspx.vb | 108 ---------------------- 7 files changed, 2 insertions(+), 534 deletions(-) delete mode 100644 Compras/RepPerioricidad.aspx delete mode 100644 Compras/RepPerioricidad.aspx.vb delete mode 100644 Ventas/RepArqueosDetalle.aspx delete mode 100644 Ventas/RepArqueosDetalle.aspx.vb diff --git a/App_Code/ClsCompras.vb b/App_Code/ClsCompras.vb index 8768624dd..abb33f395 100644 --- a/App_Code/ClsCompras.vb +++ b/App_Code/ClsCompras.vb @@ -921,31 +921,6 @@ Public Class ClsCompras Return Retorno End Function - 'Reporte de Perioricidad - Public Function GetRepComprasPerioricidad(CveSubProyecto As Integer, CveClasificacion As Integer, CvePS As Integer, - FechaInicio As Date, FechaFin As Date, CveEmpresa As Integer) As Boolean - - Dim Retorno As Boolean = False - DataAdapter("PA_Comp_ComprasPerioricidadRep") - - With SqlAdapter.SelectCommand.Parameters - .Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto - .Add("@CveClasificacion", SqlDbType.Int).Value = CveClasificacion - .Add("@CvePS", SqlDbType.Int).Value = CvePS - .Add("@FechaInicio", SqlDbType.Date).Value = FechaInicio - .Add("@FechaFin", SqlDbType.Date).Value = FechaFin - .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa - End With - - Try - SqlAdapter.Fill(Data) - Retorno = True - Catch ex As Exception - OnError("Ocurrió un error al obtener el Reporte de Perioricidad.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo) - End Try - - Return Retorno - End Function 'Reporte de Productos y Servicios Public Function GetRepProductosServicios(CveProyecto As Integer, CveSubProyecto As String, CveCategoria As String, CveClasificacion As Integer, CvePS As Integer, FechaI As Date, diff --git a/App_Code/ClsPaginas.vb b/App_Code/ClsPaginas.vb index 8dd0f20c4..65ef143b6 100644 --- a/App_Code/ClsPaginas.vb +++ b/App_Code/ClsPaginas.vb @@ -4729,7 +4729,7 @@ Public Class ClsPaginas PaginaDict.Add("/Compras/RepNotasCredito.aspx".ToUpper(), 337) PaginaDict.Add("/Compras/ReembolsosComprobaciones.aspx".ToUpper(), 350) PaginaDict.Add("/Compras/RepProductosServicios.aspx".ToUpper(), 97) - PaginaDict.Add("/Compras/RepPerioricidad.aspx".ToUpper(), 126) + PaginaDict.Add("/Compras/PopUpFacturasPendientesAutorizar.aspx".ToUpper(), 559) PaginaDict.Add("/Compras/RepEvaluacionProveedor.aspx".ToUpper(), 564) PaginaDict.Add("/Compras/RepRembolsoComprobaciones.aspx".ToUpper(), 591) @@ -5517,7 +5517,6 @@ Public Class ClsPaginas PaginaDict.Add("/Ventas/RepVentasResumen.aspx".ToUpper(), 674) PaginaDict.Add("/Ventas/RepAnticiposEspeciales.aspx".ToUpper(), 678) - PaginaDict.Add("/Ventas/RepArqueosDetalle.aspx".ToUpper(), 680) PaginaDict.Add("/Ventas/RepCotizacionesxFacturar.aspx".ToUpper(), 686) PaginaDict.Add("/Ventas/RepRemisionesNC.aspx".ToUpper(), 687) PaginaDict.Add("/Ventas/CatCobranzaEstatus.aspx".ToUpper(), 7003) diff --git a/App_Code/ClsVentas.vb b/App_Code/ClsVentas.vb index ebcea89aa..7378428ee 100644 --- a/App_Code/ClsVentas.vb +++ b/App_Code/ClsVentas.vb @@ -4806,24 +4806,7 @@ Public Class ClsVentas Return retorno 'compila End Function - Public Function GetRepArqueosDetalle(Fecha As DateTime, CveSubProyecto As Integer, CveEmpresa As Integer) As Boolean - Dim retorno As Boolean = False - Dataset = New DataSet() - DataAdapter("PA_Vta_RepArqueosDetalleGet") - With SqlAdapter.SelectCommand.Parameters - .Add("@Fecha", SqlDbType.DateTime).Value = Fecha - .Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto - .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa - End With - Try - SqlAdapter.Fill(Dataset) - retorno = True - Catch ex As Exception - OnError("Ocurrió un error al obtener el reporte de arqueos.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo) - End Try - Return retorno - 'compila - End Function + Public Function GetRepVentasMensuales(CveEmpresa As Integer, FechaInicio As Date, FechaFin As Date, Optional CveSubProyecto As Integer = -1, Optional CveClasificacion As Integer = -1, Optional CveVendedor As Integer = -1, Optional CveMarca As Integer = -1, Optional Modalidad As Integer = 0) As Boolean Dim retorno As Boolean = False diff --git a/Compras/RepPerioricidad.aspx b/Compras/RepPerioricidad.aspx deleted file mode 100644 index 17ad7be7d..000000000 --- a/Compras/RepPerioricidad.aspx +++ /dev/null @@ -1,153 +0,0 @@ -<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="RepPerioricidad.aspx.vb" Inherits="Compras_RepPerioricidad" %> - - - - - - - Reporte Perioricidad de Compra - - - - - - - - -
    -
    -
    - - -
    -
    -
    -
    -
    - - -
    - <%-- - --%> -
    -
    - - -
    - <%--
    -
    --%> -
    -
    - - -
    -
    -
    -
    -
    -
    - -
    - - -
    - -
    -
    - - - - - -
    -
    - -
    -
    - - - - - -
    -
    -
    -
    -
    -
    -
    - - - - - <%----%> - <%--ItemStyle-Width="20px"--%> - - - - - - - - - - - -
    ConceptoFechaUnidad MedidaCantidadImporteOCActivo Fijo
    -
    - - - - - - - - - - - - - - - - - - -
    - - - - - - - - - -
    - - - - - - - - - - - -
    -
    -
    - <%----%> - <%----%> - <%----%> - <%----%> -
    -
    -
    -
    -
    - - - diff --git a/Compras/RepPerioricidad.aspx.vb b/Compras/RepPerioricidad.aspx.vb deleted file mode 100644 index 013bb99b3..000000000 --- a/Compras/RepPerioricidad.aspx.vb +++ /dev/null @@ -1,111 +0,0 @@ -Option Explicit On -Option Strict On - -Imports System.Data -Imports Extensiones - -Partial Class Compras_RepPerioricidad - Inherits ClsPaginas - - Private Property DtDatos As DataTable - Get - Return CType(ViewState("DtDatos"), DataTable) - End Get - Set(value As DataTable) - ViewState("DtDatos") = value - End Set - End Property - - - - Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load - If Not IsPostBack Then - 'divfiltros.Attributes.CssStyle.Add("display", "none") - RegistraScript(String.Format("$('#{0}').css({{'display':'none'}});", divfiltros.ClientID)) - - txtFechaI.Text = Now.AddMonths(-6).ToShortDateString - txtFechaF.Text = Now.ToShortDateString - CargaCombos() - End If - End Sub - - Protected Sub BtnConsultar_Click(sender As Object, e As EventArgs) Handles BtnConsultar.Click - Dim ObjCompras As New ClsCompras - If ObjCompras.GetRepComprasPerioricidad(DdlSubProyecto.SelectedValue.ToEntero, DdlClasificacion.SelectedValue.ToEntero, DdlPS.SelectedValue.ToEntero, txtFechaI.Text.ToDate, txtFechaF.Text.ToDate, UsuarioActual.CveEmpresa) Then - DtDatos = ObjCompras.DtResultados - Gv.DataSource = DtDatos - Else - Gv.DataSource = Nothing - End If - ObjCompras.Dispose() - Gv.DataBind() - UPPDatos.Update() - End Sub - - Protected Sub Gv_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles Gv.RowDataBound - If e.Row.RowType = DataControlRowType.DataRow Then - If e.Row.DataKey("TipoRenglon").ToEntero = 1 Then - 'e.Row.FindControl("LblSpace").Visible = False - e.Row.FindControl("tr2").Visible = False - e.Row.CssClass = "Totales" - ElseIf e.Row.DataKey("TipoRenglon").ToEntero = 2 Then - 'e.Row.FCLiteral("LblAgrupador").Text = String.Format("    {0}", e.Row.DBCampo("Agrupador")) - e.Row.FindControl("tr2").Visible = False - e.Row.CssClass = "SubTotales2" - 'e.Row.FindControl("tdConcepto") - e.Row.Cells(0).Style.Add("padding-left", "15px;") - Else - e.Row.FindControl("tr1").Visible = False - 'e.Row.BackColor = Drawing.Color.LightSkyBlue - End If - End If - End Sub - - Private Sub CargaCombos() - DdlProyecto.DataSource = GlobalDTProyectos(UsuarioActual.CveEmpresa) - DdlProyecto.DataBind() - If DdlProyecto.Items.Count > 0 Then - DdlProyecto.Items.Insert(0, New ListItem("Todos", "-1")) - End If - - DdlSubProyecto.Items.Insert(0, New ListItem("Todos", "-1")) - DdlPS.Items.Insert(0, New ListItem("Todos", "-1")) - - 'DdlClasificacion.DataSource = GlobalDTClasificaciones(UsuarioActual.CveEmpresa) - 'DdlClasificacion.DataBind() - - If UsuarioActual.Empresa.UsaAC Then - DdlClasificacion.DataSource = GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltraParametros(" Codigo = '' OR Codigo IS NULL ", Orderby:="Clasificacion") - Else - DdlClasificacion.DataSource = GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltraParametros("", Orderby:="Clasificacion") - End If - DdlClasificacion.DataBind() - - If DdlClasificacion.Items.Count > 0 Then - DdlClasificacion.Items.Insert(0, New ListItem("Todas", "-1")) - End If - End Sub - - Private Sub CargaPS(CveClasificacion As Integer) - - DdlPS.DataSource = GlobalDTPSSimplificado(UsuarioActual.CveEmpresa, CveClasificacion:=CveClasificacion) - DdlPS.DataBind() - - If DdlPS.Items.Count > 0 Then - DdlPS.Items.Insert(0, New ListItem("Todos", "-1")) - End If - - End Sub - - Protected Sub DdlProyecto_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlProyecto.SelectedIndexChanged - DdlSubProyecto.DataSource = GlobalDTSubProyectos(DdlProyecto.SelectedValue.ToEntero, -1, UsuarioActual.CveEmpresa) - DdlSubProyecto.DataBind() - If DdlSubProyecto.Items.Count > 0 Then - DdlSubProyecto.Items.Insert(0, New ListItem("Todos", "-1")) - End If - End Sub - - Protected Sub DdlClasificacion_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlClasificacion.SelectedIndexChanged - CargaPS(DdlClasificacion.SelectedValue.ToEntero) - End Sub -End Class diff --git a/Ventas/RepArqueosDetalle.aspx b/Ventas/RepArqueosDetalle.aspx deleted file mode 100644 index 073de9608..000000000 --- a/Ventas/RepArqueosDetalle.aspx +++ /dev/null @@ -1,117 +0,0 @@ -<%@ Page Title="" Language="VB" MasterPageFile="~/Site.master" AutoEventWireup="false" CodeFile="RepArqueosDetalle.aspx.vb" Inherits="Ventas_RepArqueosDetalle" %> - - - - - - - - - - - -
  • - Generar PDF -
  • -
  • - Generar Excel -
  • -
    - - - - -
    -
    - - - - - - - -
    -
    -
    - Ventas -
    -
    -
    -
    -
    -
    - -
    -
    -
    -
    -
    -
    -
    - " style="display: inline-block; margin-right: -20px; width: 150px;" /> - " style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"> -
    -
    - - - - - - - - - - - - - - - -
    -
    -
    -
    -
    -
    -
    - CUENTAS -
    -
    -
    -
    -
    -
    - -
    -
    -
    -
    -
    -
    -
    - " style="display: inline-block; margin-right: -20px; width: 150px;" /> - " style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"> -
    -
    - - - - - - - - - -
    -
    -
    -
    -
    -
    -
    - - - diff --git a/Ventas/RepArqueosDetalle.aspx.vb b/Ventas/RepArqueosDetalle.aspx.vb deleted file mode 100644 index a9b726fed..000000000 --- a/Ventas/RepArqueosDetalle.aspx.vb +++ /dev/null @@ -1,108 +0,0 @@ -Option Explicit On -Option Strict On - -Imports Extensiones -Imports Microsoft.Reporting.WebForms -Imports System.Data - -Partial Class Ventas_RepArqueosDetalle - Inherits ClsPaginas -#Region "P R O P I E D A D E S" - Private Property DtVentas As DataTable - Get - Return DirectCast(ViewState("DtVentas"), DataTable) - End Get - Set(value As DataTable) - ViewState("DtVentas") = value - End Set - End Property - Private Property DtCuentas As DataTable - Get - Return DirectCast(ViewState("DtCuentas"), DataTable) - End Get - Set(value As DataTable) - ViewState("DtCuentas") = value - End Set - End Property -#End Region - Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load - If Not IsPostBack Then - Dim CveSubProyecto As Integer = -1 - Dim Fecha As DateTime = Now - If Request("CveSubProyecto") IsNot Nothing Then - CveSubProyecto = Request("CveSubProyecto").ToString().ToEntero() - End If - If Request("Fecha") IsNot Nothing Then - Fecha = Request("Fecha").ToString().ToDate() - End If - CargaDatos(Fecha, CveSubProyecto) - End If - End Sub - Private Sub CargaDatos(Fecha As DateTime, CveSubProyecto As Integer) - LtlTitulo.Text = String.Format("Reporte de Arqueos Detalle: Fecha {0:dd/MM/yyyy}", Fecha) - - Dim ObjVentas As New ClsVentas() - If ObjVentas.GetRepArqueosDetalle(Fecha, CveSubProyecto, UsuarioActual.CveEmpresa) Then - DtVentas = ObjVentas.DataSetResultados.Tables(0).Copy() - DtCuentas = ObjVentas.DataSetResultados.Tables(1).Copy() - End If - ObjVentas.Dispose() - GvDatos.DataSource = DtVentas - GvCuentas.DataSource = DtCuentas - GvDatos.DataBind() - GvCuentas.DataBind() - - UPDatos.Update() - End Sub - Protected Sub GvDatos_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GvDatos.RowDataBound - If e.Row.RowType = DataControlRowType.DataRow Then - If e.Row.DBCampo("SerieFolio") = "Total" Then - e.Row.CssClass = "Totales" - End If - End If - End Sub - Protected Sub GvCuentas_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GvCuentas.RowDataBound - If e.Row.RowType = DataControlRowType.DataRow Then - If e.Row.DBCampo("Folio") = "Total" Then - e.Row.CssClass = "Totales" - End If - End If - End Sub - Protected Sub GeneraPDF(Formato As String) - Dim params As List(Of ReportParameter) = New List(Of ReportParameter)() - Dim Imagen As System.IO.FileInfo = New System.IO.FileInfo(String.Format("{0}/Logo.png", UsuarioActual.Empresa.Ruta)) - Dim logouri = String.Format("{0}://{1}:{2}/Empresas/{3}/Logo.png", Request.Url.Scheme, Request.Url.Host, Request.Url.Port, UsuarioActual.CveEmpresa) - params.Add(New ReportParameter("NombreEmpresa", UsuarioActual.Empresa.Empresa)) - params.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre)) - params.Add(New ReportParameter("FechaImpresion", DateTime.Now.ToString())) - - params.Add(New ReportParameter("Encabezado", String.Format("Fecha:{0}", Request("Fecha").ToString().ToDate().ToString("dd/MM/yyyy")))) - - - Dim lrds As List(Of ReportDataSource) = New List(Of ReportDataSource)() - Dim rds As ReportDataSource = New ReportDataSource() - rds.Name = "DataSet1" - rds.Value = DtVentas - - Dim rds2 As ReportDataSource = New ReportDataSource() - rds2.Name = "DataSet2" - rds2.Value = DtCuentas - - lrds.Add(rds) - lrds.Add(rds2) - - If Imagen.Exists Then - params.Add(New ReportParameter("LogoPath", logouri)) - Else - params.Add(New ReportParameter("LogoPath", "")) - End If - - ImprimirPDF("Empresas/Grales/Formatos/RepArqueosDetalle.rdlc", lrds, params, "Rep Arqueos Detalle", Formato) - End Sub - Protected Sub LnkPdf_Click(sender As Object, e As EventArgs) - GeneraPDF("PDF") - End Sub - Protected Sub LnkExportar_Click(sender As Object, e As EventArgs) - GeneraPDF("EXCEL") - End Sub -End Class From 9636641f6cfe54973df52df843e35211dbd00e06 Mon Sep 17 00:00:00 2001 From: Oscar Irigoyen Date: Wed, 5 Oct 2022 17:02:37 -0700 Subject: [PATCH 11/12] RepLienas carga por venta --- App_Code/ClsVentas.vb | 4 +-- Ventas/RepLineasAdicionales.aspx | 7 ++--- Ventas/RepLineasAdicionales.aspx.cs | 44 +++++++++++++++++------------ 3 files changed, 31 insertions(+), 24 deletions(-) diff --git a/App_Code/ClsVentas.vb b/App_Code/ClsVentas.vb index 7378428ee..9b748d07f 100644 --- a/App_Code/ClsVentas.vb +++ b/App_Code/ClsVentas.vb @@ -5667,7 +5667,7 @@ Public Class ClsVentas Public Function UpdateLineasAdicionales(CveLineaAdicional As Integer, LineaAdicional As String, CveCliente As Integer, CveProveedor As Integer, TipoLinea As Integer, Importe As Decimal, CveMoneda As Integer, FechaVencimiento As Date, CveUsuario As Integer, CveCategoria As Integer, CveEmpresa As Integer, - Optional Comprobante As String = "-1", Optional DiasVencimiento As Integer = -1, Optional CveVenta As Integer = -1, Optional CveLineaAdicionalEstatus As Integer = -1) As Boolean + Optional LineaAdicionalComprobante As String = "-1", Optional DiasVencimiento As Integer = -1, Optional CveVenta As Integer = -1, Optional CveLineaAdicionalEstatus As Integer = -1) As Boolean Dim Retorno As Boolean = False DataAdapter("PA_Vta_LineasAdicionalesUpdate") @@ -5684,7 +5684,7 @@ Public Class ClsVentas .Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario .Add("@CveCategoria", SqlDbType.Int).Value = CveCategoria .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa - .Add("@Comprobante", SqlDbType.VarChar).Value = Comprobante + .Add("@LineaAdicionalComprobante", SqlDbType.VarChar).Value = LineaAdicionalComprobante .Add("@DiasVencimiento", SqlDbType.VarChar).Value = DiasVencimiento .Add("@CveVenta", SqlDbType.VarChar).Value = CveVenta .Add("@CveLineaAdicionalEstatus", SqlDbType.Int).Value = CveLineaAdicionalEstatus diff --git a/Ventas/RepLineasAdicionales.aspx b/Ventas/RepLineasAdicionales.aspx index 4c38cc00b..bfe5ef7aa 100644 --- a/Ventas/RepLineasAdicionales.aspx +++ b/Ventas/RepLineasAdicionales.aspx @@ -89,10 +89,10 @@ @@ -109,8 +109,7 @@ -
    - +
    diff --git a/Ventas/RepLineasAdicionales.aspx.cs b/Ventas/RepLineasAdicionales.aspx.cs index c154e960b..7340a5449 100644 --- a/Ventas/RepLineasAdicionales.aspx.cs +++ b/Ventas/RepLineasAdicionales.aspx.cs @@ -7,11 +7,18 @@ using System.Web.UI; public partial class Ventas_RepLineasAdicionales : ClsPaginas { #region PROPIEDADES - + + private int CveLineaAdicional { get { return (ViewState["CveLineaAdicional"] == null) ? 0 : int.Parse(ViewState["CveLineaAdicional"].ToString()); } - set { ViewState["CveLineaAdicional"] =(int) value; } + set { ViewState["CveLineaAdicional"] = (int)value; } + } + + private int CveVenta + { + get { return (ViewState["CveVenta"] == null) ? 0 : int.Parse(ViewState["CveVenta"].ToString()); } + set { ViewState["CveVenta"] =(int) value; } } private int TipoLinea @@ -33,18 +40,18 @@ public partial class Ventas_RepLineasAdicionales : ClsPaginas set { ViewState["DTDatosGvLineasAdicionales"] = (DataTable)value; } } - private string Comprobante + private string LineaAdicionalComprobante { get { - if(ViewState["Comprobante"] == null) + if(ViewState["LineaAdicionalComprobante"] == null) { - ViewState["Comprobante"] = ""; + ViewState["LineaAdicionalComprobante"] = ""; } - return ViewState["Comprobante"].ToString(); + return ViewState["LineaAdicionalComprobante"].ToString(); } - set { ViewState["Comprobante"] = value; } + set { ViewState["LineaAdicionalComprobante"] = value; } } #endregion @@ -135,9 +142,10 @@ public partial class Ventas_RepLineasAdicionales : ClsPaginas protected void LnkCargarComprobante_Click(object sender, EventArgs e) { GridViewRow GvRow = (GridViewRow) ((LinkButton) sender).NamingContainer; - + CveLineaAdicional = GvRow.DataKey("CveLineaAdicional").ToString().ToEntero(); - Comprobante = GvRow.DataKey("Comprobante").ToString(); + CveVenta = GvRow.DataKey("CveVenta").ToString().ToEntero(); + LineaAdicionalComprobante = GvRow.DataKey("LineaAdicionalComprobante").ToString(); RegistraScript("$('#ModalComprobante').modal('show');",""); } @@ -167,9 +175,9 @@ public partial class Ventas_RepLineasAdicionales : ClsPaginas } //borrar archivo anterior - if((!errorCargaComprobante) && Comprobante.Length > 0) + if((!errorCargaComprobante) && LineaAdicionalComprobante.Length > 0) { - FileInfo fiAnterior = new FileInfo($@"{df.FullName}{Comprobante}"); + FileInfo fiAnterior = new FileInfo($@"{df.FullName}{LineaAdicionalComprobante}"); if (fiAnterior.Exists) { try @@ -204,12 +212,12 @@ public partial class Ventas_RepLineasAdicionales : ClsPaginas try { - if (File.Exists($@"{df.FullName}\{CveLineaAdicional}{fiNuevo.Extension}")) + if (File.Exists($@"{df.FullName}\{CveVenta}{fiNuevo.Extension}")) { - File.Delete($@"{df.FullName}\{CveLineaAdicional}{fiNuevo.Extension}"); + File.Delete($@"{df.FullName}\{CveVenta}{fiNuevo.Extension}"); } - File.Move(fiNuevo.FullName, $@"{df.FullName}\{CveLineaAdicional}{fiNuevo.Extension}"); + File.Move(fiNuevo.FullName, $@"{df.FullName}\{CveVenta}{fiNuevo.Extension}"); errorCargaComprobante = false; } catch @@ -220,7 +228,7 @@ public partial class Ventas_RepLineasAdicionales : ClsPaginas if (!errorCargaComprobante) { ClsVentas objVentas = new ClsVentas(); - if (!objVentas.UpdateLineasAdicionales(CveLineaAdicional, "-1", -1, -1, -1, -1, -1, MinFecha, 100, -1, UsuarioActual.CveEmpresa, Comprobante: $@"{CveLineaAdicional}{fiNuevo.Extension}")) + if (!objVentas.UpdateLineasAdicionales(CveLineaAdicional, "-1", -1, -1, -1, -1, -1, MinFecha, 100, -1, UsuarioActual.CveEmpresa, LineaAdicionalComprobante: $@"{CveVenta}{fiNuevo.Extension}",CveVenta:CveVenta)) { errorCargaComprobante = true; } @@ -287,9 +295,9 @@ public partial class Ventas_RepLineasAdicionales : ClsPaginas e.Row.FCLinkButton("LnkCargarComprobante").Visible = false; } - if (e.Row.DataKey("Comprobante").Length > 0) + if (e.Row.DataKey("LineaAdicionalComprobante").Length > 0 && e.Row.DataKey("CveVenta").ToEntero() > 0 ) { - FileInfo fi = new FileInfo($@"{UsuarioActual.Empresa.Ruta}\LineasAdicionales\{e.Row.DataKey("Comprobante")}"); + FileInfo fi = new FileInfo($@"{UsuarioActual.Empresa.Ruta}\LineasAdicionales\{e.Row.DataKey("LineaAdicionalComprobante")}"); LinkButton LnkDescargaComprobante = e.Row.FCLinkButton("LnkDescargaComprobante"); if (fi.Exists) @@ -304,7 +312,7 @@ public partial class Ventas_RepLineasAdicionales : ClsPaginas protected void LnkDescargaComprobante_Click(object sender, EventArgs e) { GridViewRow GvRow = (GridViewRow)((LinkButton)sender).NamingContainer; - string Comprobante = GvRow.DataKey("Comprobante"); + string Comprobante = GvRow.DataKey("LineaAdicionalComprobante"); FileInfo fi = new FileInfo($@"{UsuarioActual.Empresa.Ruta}\LineasAdicionales\{Comprobante}"); if (fi.Exists) From ae86c09e64ef84606573a91deb8d49718c6b0710 Mon Sep 17 00:00:00 2001 From: JORGE LUIS CAUDILLO ESPARZA Date: Thu, 6 Oct 2022 02:26:18 -0700 Subject: [PATCH 12/12] --- App_Code/ClsNominas.vb | 23 +++++++++++++++++++++++ App_Code/ClsRH.vb | 26 +++++++++++++++++++++++++- App_Code/ClsVentas.vb | 18 ++++++++++++++++++ App_Code/modExtensiones.vb | 7 +++++++ RH/CatPersonal.aspx | 2 +- RH/CatPersonal.aspx.vb | 2 +- Ventas/Ventas.aspx.vb | 12 ++++++++++++ 7 files changed, 87 insertions(+), 3 deletions(-) diff --git a/App_Code/ClsNominas.vb b/App_Code/ClsNominas.vb index 22921dad9..c2289f545 100644 --- a/App_Code/ClsNominas.vb +++ b/App_Code/ClsNominas.vb @@ -237,6 +237,29 @@ Public Class ClsNominas End Sub #End Region + Public Function AgroOrdenProduccionForVtaGet(CveEmpresa As Integer, CveUsuario As Integer, CveOrdenProduccion As Integer) As Boolean + Dim retorno As Boolean = False + DataAdapter("PA_Vta_AgroOrdenProduccionForVtaGet", CommandType.StoredProcedure) + With SqlAdapter.SelectCommand.Parameters + .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa + .Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario + .Add("@CveOrdenProduccion", SqlDbType.Int).Value = CveOrdenProduccion + + End With + Try + SqlAdapter.Fill(DTSet) + If DTSet.Tables.Count > 0 Then + Data = DTSet.Tables(0) + End If + retorno = True + Catch Ex1 As SqlException + + Me.OnError("Ocurrió un error al obtener datos manifiesto.", Ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo()) + Catch ex As Exception + OnError("Ocurrió un error al obtener los datos manifiesto.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo) + End Try + Return retorno + End Function Public Function ManifiestoForVtaGet(CveEmpresa As Integer, CveUsuario As Integer, PersonalXml As String, CveEmbarqueManifiesto As Integer) As Boolean Dim retorno As Boolean = False DataAdapter("PA_Vta_ManifiestoForVtaGet", CommandType.StoredProcedure) diff --git a/App_Code/ClsRH.vb b/App_Code/ClsRH.vb index 8d4a1894e..b5c42d4a8 100644 --- a/App_Code/ClsRH.vb +++ b/App_Code/ClsRH.vb @@ -2226,9 +2226,33 @@ chkAplicaVacacion As Boolean, chkAplicaIncapacidad As Boolean, chkAplicaRetardo OnError("Ocurrió un error al intentar guardar los cambios en el Personal.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo) End Try Return Retorno + End Function + + Public Function PersonalSalarioUp(CvePersonal As Integer, Fecha As String, CveUsuario As Integer, CveEmpresa As Integer, SalarioDiario As Double, SDI As Double, SalarioDiarioSS As Double, SalarioDiarioPago As Double, SDUp As TipoUpdate, SDIUp As TipoUpdate, SDCUp As TipoUpdate) As Boolean + Dim Retorno As Boolean = False + SqlDataAdapter("PA_RH_PersonalSalarioUp") + With SqlAdapter.SelectCommand.Parameters + .Add("@CvePersonal", SqlDbType.Int).Value = CvePersonal + .Add("@Fecha", SqlDbType.Date).Value = Fecha + .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa + .Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario + .Add("@SalarioDiarioPago", SqlDbType.Money).Value = SalarioDiarioPago + .Add("@SalarioDiario", SqlDbType.Money).Value = SalarioDiario + .Add("@SDI", SqlDbType.Money).Value = SDI + .Add("@SalarioDiarioSS", SqlDbType.Money).Value = SalarioDiarioSS + .Add("@SDUp", SqlDbType.Int).Value = SDUp + .Add("@SDIUp", SqlDbType.Int).Value = SDIUp + .Add("@SDCUp", SqlDbType.Int).Value = SDCUp + End With + Try + SqlAdapter.Fill(Data) + Retorno = True + Catch ex As SqlException + OnError("Ocurrió un error al intentar guardar los cambios en el Personal.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo) + End Try + Return Retorno End Function - Public Function GetMovimientosToSUA(CveEmpresa As Integer, FechaI As String, FechaF As String) As Boolean Dim Retorno As Boolean = False SqlDataAdapter("PA_RH_MovimientosToSUA") diff --git a/App_Code/ClsVentas.vb b/App_Code/ClsVentas.vb index ebcea89aa..7f7f2cc8d 100644 --- a/App_Code/ClsVentas.vb +++ b/App_Code/ClsVentas.vb @@ -181,6 +181,24 @@ Public Class ClsVentas Return Retorno End Function + Public Function AgroOrdenProduccionUpvta(cveVenta As Int32, cveUsuario As Int32, cveEmpresa As Int32, CveOrdenProduccion As Int32) As Boolean + Dim retorno As Boolean = False + DataAdapter("PA_AGRO_OrdenProduccionUpvta", CommandType.StoredProcedure) + With SqlAdapter.SelectCommand.Parameters + .Add("@CveVenta", SqlDbType.Int).Value = cveVenta + .Add("@CveEmpresa", SqlDbType.Int).Value = cveEmpresa + .Add("@CveOrdenProduccion", SqlDbType.Int).Value = CveOrdenProduccion + .Add("@CveUsuario", SqlDbType.Int).Value = cveUsuario + End With + + Try + SqlAdapter.Fill(Data) + retorno = True + Catch ex As Exception + OnError("Ocurrió un error al actualizar venta manifiesto.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo) + End Try + Return retorno + End Function Public Function Embarque_ManifiestoUpvta(cveVenta As Int32, cveUsuario As Int32, cveEmpresa As Int32, cveEmbarqueManifiesto As Int32) As Boolean Dim retorno As Boolean = False DataAdapter("PA_AGRO_Embarque_ManifiestoUpvta", CommandType.StoredProcedure) diff --git a/App_Code/modExtensiones.vb b/App_Code/modExtensiones.vb index 40e68aafc..87171a475 100644 --- a/App_Code/modExtensiones.vb +++ b/App_Code/modExtensiones.vb @@ -301,6 +301,13 @@ Namespace Extensiones #Region "Alertas y notificaciones" + Public Enum TipoUpdate As Integer + + NoGuardar = 0 + Guardar = 1 + CalcularYGuardar = 2 + + End Enum Public Enum TipoMensaje As Integer MsgError = 1 diff --git a/RH/CatPersonal.aspx b/RH/CatPersonal.aspx index 4f78b5dc8..eb25ddb01 100644 --- a/RH/CatPersonal.aspx +++ b/RH/CatPersonal.aspx @@ -1115,7 +1115,7 @@
    - +
    diff --git a/RH/CatPersonal.aspx.vb b/RH/CatPersonal.aspx.vb index 95ec9d60b..2044c0802 100644 --- a/RH/CatPersonal.aspx.vb +++ b/RH/CatPersonal.aspx.vb @@ -1180,7 +1180,7 @@ Partial Class RH_CatPersonal Dim CvePersonal As Integer = 0 Using ObjPersonal As New ClsRH() ObjPersonal.IniciaTransacSQL() - If ObjPersonal.AddPersonal("-1", TxtAPaterno.Text.Trim, TxtAMaterno.Text.Trim, TxtNombres.Text.Trim, "", TxtFechaIngreso.Text.ToDate, + If ObjPersonal.AddPersonal(TxtCodigo.Text, TxtAPaterno.Text.Trim, TxtAMaterno.Text.Trim, TxtNombres.Text.Trim, "", TxtFechaIngreso.Text.ToDate, DdlTipoPeriodoAdd.SelectedValue.ToEntero, TxtNumeroSS.Text.Trim, True, SalarioDiario, SalarioDiario, 0, 0, 0, 15, 25, DdlMetodoPagoAdd.SelectedValue.ToEntero, TxtFechaIngreso.Text.Trim.ToDate, "-1", DdlTipoContratoAdd.SelectedValue.ToEntero, "", diff --git a/Ventas/Ventas.aspx.vb b/Ventas/Ventas.aspx.vb index 96797b397..ae3516748 100644 --- a/Ventas/Ventas.aspx.vb +++ b/Ventas/Ventas.aspx.vb @@ -9703,6 +9703,18 @@ Partial Class Ventas Catch ex As Exception OnError("Ocurrió un error al actualizar el embarque", ex) End Try + Try + ViewState("CveVenta") = ObjFactura.CveVenta + + If Request("CveOrdenProduccion") IsNot Nothing AndAlso IsNumeric(Request("CveOrdenProduccion")) AndAlso Request("CveOrdenProduccion").ToEntero() > 0 Then + + If ObjVentas.AgroOrdenProduccionUpvta(ObjFactura.CveVenta, UsuarioActual.CveEmpresa, UsuarioActual.CveUsuario, Request("CveOrdenProduccion").ToEntero()) Then + + End If + End If + Catch ex As Exception + OnError("Ocurrió un error al actualizar el embarque", ex) + End Try Try Dim DirectoriArchivoXML As String = String.Format("{0}{1}", UsuarioActual.Empresa.Ruta, ObjFactura.TipoDocto) ' System.IO.Path.Combine()