This commit is contained in:
2025-06-20 19:47:04 -07:00
23 changed files with 1998 additions and 1032 deletions

View File

@@ -3,6 +3,7 @@ Option Strict On
Imports System.Data
Imports System.Data.SqlClient
Imports DocumentFormat.OpenXml.Math
Imports Extensiones
Public Class ClsBancos
@@ -1284,7 +1285,7 @@ Public Class ClsBancos
End With
Try
SqlAdapter.Fill(Data)
Retorno = True
retorno = True
Catch ex As Exception
retorno = False
OnError("Ocurrió un error al cancelar estatus complemento de pago", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
@@ -1301,7 +1302,7 @@ Public Class ClsBancos
End With
Try
SqlAdapter.Fill(Data)
Retorno = True
retorno = True
Catch ex As Exception
retorno = False
OnError("Ocurrió un error al cancelar estatus complemento de pago", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
@@ -3344,7 +3345,10 @@ Public Class ClsBancos
Return Retorno
End Function
Public Function GetLayoutProveedores(CveCuenta As Integer, CveEmpresa As Integer, Optional PorGrupos As Boolean = False) As Boolean
Public Function GetLayoutProveedores(CveCuenta As Integer, CveEmpresa As Integer, Optional PorGrupos As Boolean = False, Optional OpBanco As Integer = 1) As Boolean
'OpBanco 1 Bancomer, 2 Bajio, 3 Scotia
Dim Retorno As Boolean = False
DataAdapter("PA_Banc_LayoutProveedores")
@@ -3353,6 +3357,7 @@ Public Class ClsBancos
.Add("@CveCuenta", SqlDbType.Int).Value = CveCuenta
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@PorGrupos", SqlDbType.Bit).Value = PorGrupos
.Add("@OpBanco", SqlDbType.Int).Value = OpBanco
End With
Try

View File

@@ -471,7 +471,7 @@ public partial class Bancos_Devoluciones : ClsPaginas
if (gvr.FCTextBox("TxtIVA").Text.ToDecimal() > 0)
{
//INGxC
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, true, gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), CveConceptoContableDevolucion, Ref, Conc, CveIE: gvr.DataKey("CveIE").ToEntero(), CveSubProyecto: DdlSubProyecto.SelectedValue.ToEntero(), CveCliente: DdlCliente.SelectedValue.ToEntero(), CveIEDevolucion: CveIE))
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, true, gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), CveConceptoContableDevolucion, Ref, Conc, CveIE: gvr.DataKey("CveIE").ToEntero(), CveSubProyecto: DdlSubProyecto.SelectedValue.ToEntero(), CveCliente: DdlCliente.SelectedValue.ToEntero()))
{
MsgError = "No se pudo insertar concepto de devolución";
}
@@ -488,7 +488,7 @@ public partial class Bancos_Devoluciones : ClsPaginas
else
{
//INGxC
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovtoDevolucion, gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), CveConceptoContableDevolucion, Ref, Conc, CveIE: CveIE, CveSubProyecto: DdlSubProyecto.SelectedValue.ToEntero(), CveCliente: DdlCliente.SelectedValue.ToEntero(), CveIEDevolucion: gvr.DataKey("CveIE").ToEntero()))
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovtoDevolucion, gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), CveConceptoContableDevolucion, Ref, Conc, CveIE: gvr.DataKey("CveIE").ToEntero(), CveSubProyecto: DdlSubProyecto.SelectedValue.ToEntero(), CveCliente: DdlCliente.SelectedValue.ToEntero() ))
{
MsgError = "No se pudo insertar concepto de bancos";
}

View File

@@ -33,7 +33,10 @@
<div class="titlefiltros caption ">
<ul class="list-inline">
<li>Cuenta:
<asp:DropDownList ID="DdlCuenta" runat="server" DataTextField="NumCuentaMoneda" DataValueField="CveCuenta" CssClass="form-control input-sm select2me" Width="350px"></asp:DropDownList>
<asp:DropDownList ID="DdlCuenta" runat="server" DataTextField="NumCuentaMoneda" DataValueField="CveCuenta" CssClass="form-control input-sm select2me" Width="350px"
AutoPostBack="true"
OnSelectedIndexChanged="DdlCuenta_SelectedIndexChanged"
></asp:DropDownList>
</li>
<li>Tipo:
<asp:DropDownList ID="DdlTipoGeneracion" runat="server" CssClass="form-control input-sm select2me" Width="350px">
@@ -110,12 +113,22 @@
<td>
<asp:Label runat="server" ID="LbNumeroInterbancarias" Width="80px"></asp:Label></td>
</tr>
<tr>
<tr runat="server" id="TrNumeroBancomer" visible="false">
<td>Bancomer:</td>
<td>
<asp:Label runat="server" ID="LbNumeroBancomer" Width="80px"></asp:Label></td>
</tr>
<tr>
<tr runat="server" id="TrNumeroBajio" visible="false">
<td>Bajio:</td>
<td>
<asp:Label runat="server" ID="LbNumeroBajio" Width="80px"></asp:Label></td>
</tr>
<tr runat="server" id="TrNumeroScotia" visible="false">
<td>Scotia:</td>
<td>
<asp:Label runat="server" ID="LbNumeroScotia" Width="80px"></asp:Label></td>
</tr>
<tr >
<td colspan="2" align="center">
<asp:Button runat="server" ID="BtnGenerarAlta" Text="Generar Alta" OnClick="BtnAltas_Click" class="btn btn-primary" />
</td>
@@ -852,7 +865,7 @@
</div>
<div class="col-md-12" runat="server" id="DVDescargaCuentas1" visible=" false" >
<p> Cuentas Bancomer <asp:LinkButton runat="server" ID="LnkDescargaCuentas1" OnClick="LnkDescargaCuentas1_Click" CssClass="Texto"></asp:LinkButton> </p>
<p><asp:Label runat="server" ID="LblCuentas" Text="Cuentas Bancomer"></asp:Label> <asp:LinkButton runat="server" ID="LnkDescargaCuentas1" OnClick="LnkDescargaCuentas1_Click" CssClass="Texto"></asp:LinkButton> </p>
</div>
<div class="col-md-12" runat="server" id="DVDescargaCuentas2" visible=" false">

View File

@@ -4,8 +4,10 @@ Option Strict On
Imports System.Data
Imports System.Globalization
Imports System.IO
Imports CFDI_GenCodigo
Imports Extensiones
Imports Ionic.Zip
Imports iText.Barcodes.Dmcode
Imports Microsoft.Reporting.WebForms
Partial Class Bancos_PagoElectronicoGrupos
@@ -283,6 +285,28 @@ Partial Class Bancos_PagoElectronicoGrupos
End Property
ReadOnly Property OpBancos As Integer
Get
Dim OpBanco As Integer = -1
If (DdlCuenta.SelectedItem.Text.ToUpper.Contains("BANCOMER") OrElse DdlCuenta.SelectedItem.Text.ToUpper.Contains("BBVA")) Then
OpBanco = 1
End If
If DdlCuenta.SelectedItem.Text.ToUpper.Contains("BAJIO") Then
OpBanco = 2
End If
If DdlCuenta.SelectedItem.Text.ToUpper.Contains("SCOTIA") Then
OpBanco = 3
End If
Return OpBanco
End Get
End Property
#End Region
Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load
@@ -302,7 +326,7 @@ Partial Class Bancos_PagoElectronicoGrupos
txtFechaF.Text = NowADS().ToShortDateString
CargaCuentas()
CargaProveedores()
'CargaProveedores()
InicializaDatosGenerales()
End If
@@ -355,12 +379,8 @@ Partial Class Bancos_PagoElectronicoGrupos
DTPendientes = Nothing
End If
ObjBancos.Dispose()
If DTPendientes IsNot Nothing AndAlso DTPendientes.Rows.Count > 0 Then
CargaDatosInformativos()
Else
@@ -385,38 +405,151 @@ Partial Class Bancos_PagoElectronicoGrupos
Dim Altas As Integer = 0
Dim Interbancarias As Integer = 0
Dim Bancomer As Integer = 0
Dim Bajio As Integer = 0
Dim Scotia As Integer = 0
Dim Movimientos As Integer = 0
Dim Importe As Decimal = 0
For Each dr As DataRow In DTPendientes.Rows
TrNumeroBancomer.Visible = False
TrNumeroBajio.Visible = False
TrNumeroScotia.Visible = False
'--- Asume que existen contadores: Altas, Movimientos, Importe, Bancomer,
' Bajio, Scotia, Interbancarias declarados y con valor inicial 0.
For Each dr As DataRow In DTPendientes.Rows
' 1. Filtrar filas cuya cuenta‑depósito no está activa
If dr("EstatusCtaDeposito").ToString <> "True" Then Continue For
Dim tieneCuenta As Boolean = dr("CveCuentaDeposito").ToString <> ""
Dim altaCuenta As Boolean = dr("AltaCuenta").ToString = "1"
' 2. ALTA de cuentas NO habilitadas todavía
If tieneCuenta AndAlso altaCuenta Then
'–– Determina si la cuenta ya está **habilitada** para el banco elegido en la pantalla ––'
Dim habilitada As Boolean
Select Case True
Case DdlCuenta.SelectedItem.Text.ToUpper.Contains("BANCOMER") OrElse DdlCuenta.SelectedItem.Text.ToUpper.Contains("BBVA")
habilitada = (dr("EstatusPagoElectronicoGrupos").ToString = "True")
Case DdlCuenta.SelectedItem.Text.ToUpper.Contains("BAJIO")
habilitada = (dr("EstatusPagoElectronicoGruposBajio").ToString = "True")
Case DdlCuenta.SelectedItem.Text.ToUpper.Contains("SCOTIA")
habilitada = (dr("EstatusPagoElectronicoGruposScotia").ToString = "True")
Case Else
habilitada = False 'Otros bancos sin bandera propia
End Select
If Not habilitada Then
Altas += 1 '‑‑‑ cuenta el alta sólo una vez
'‑‑‑ Clasificación por banco real del beneficiario –‑‑'
Select Case True
Case dr("BancoNombre").ToString.ToUpper.Contains("BANCOMER") _
OrElse dr("BancoNombre").ToString.ToUpper.Contains("BBVA")
Bancomer += 1
Case dr("BancoNombre").ToString.ToUpper.Contains("BAJIO")
Bajio += 1
Case dr("BancoNombre").ToString.ToUpper.Contains("SCOTIA")
Scotia += 1
Case Else
Interbancarias += 1
End Select
Else
Movimientos += 1
Importe += dr("Abonado").ToString.ToDecimal
End If
' 3. MOVIMIENTOS de cuentas ya existentes
ElseIf dr("CveCuentaDeposito").ToString.ToEntero > 0 Then
Movimientos += 1
Importe += dr("Abonado").ToString.ToDecimal
End If
Next
'For Each dr As DataRow In DTPendientes.Rows
If dr("EstatusCtaDeposito").ToString <> "True" Then
Continue For
End If
' If dr("EstatusCtaDeposito").ToString <> "True" Then
' Continue For
' End If
If dr("CveCuentaDeposito").ToString <> "" And dr("EstatusPagoElectronicoGrupos").ToString <> "True" And dr("AltaCuenta").ToString = "1" Then
Altas += 1
If dr("BancoNombre").ToString.ToUpper.Contains("BANCOMER") OrElse dr("BancoNombre").ToString.ToUpper.Contains("BBVA") Then
Bancomer += 1
Else
Interbancarias += 1
End If
' If dr("CveCuentaDeposito").ToString <> "" And dr("AltaCuenta").ToString = "1" Then
ElseIf dr("CveCuentaDeposito").ToString.ToEntero > 0 Then
Movimientos += 1
Importe += dr("Abonado").ToString.ToDecimal
End If
Next
' If DdlCuenta.SelectedItem.Text.ToUpper.Contains("BANCOMER") OrElse DdlCuenta.SelectedItem.Text.ToUpper.Contains("BBVA") Then
' If dr("EstatusPagoElectronicoGrupos").ToString <> "True" Then
' If dr("BancoNombre").ToString.ToUpper.Contains("BANCOMER") OrElse dr("BancoNombre").ToString.ToUpper.Contains("BBVA") Then
' Bancomer += 1
' Else
' Interbancarias += 1
' End If
' Altas += 1
' End If
' End If
' If DdlCuenta.SelectedItem.Text.ToUpper.Contains("BAJIO") Then
' If dr("EstatusPagoElectronicoGruposBajio").ToString <> "True" Then
' If dr("BancoNombre").ToString.ToUpper.Contains("BAJIO") Then
' Bajio += 1
' Else
' Interbancarias += 1
' End If
' Altas += 1
' End If
' End If
' If DdlCuenta.SelectedItem.Text.ToUpper.Contains("SCOTIA") Then
' If dr("EstatusPagoElectronicoGruposScotia").ToString <> "True" Then
' If dr("BancoNombre").ToString.ToUpper.Contains("SCOTIA") Then
' Scotia += 1
' Else
' Interbancarias += 1
' End If
' Altas += 1
' End If
' End If
' ElseIf dr("CveCuentaDeposito").ToString.ToEntero > 0 Then
' Movimientos += 1
' Importe += dr("Abonado").ToString.ToDecimal
' End If
'Next
LnkNumeroAltas.Text = Altas.ToString
LbNumeroInterbancarias.Text = Interbancarias.ToString
LbNumeroBancomer.Text = Bancomer.ToString
LbNumeroBajio.Text = Bajio.ToString
LbNumeroScotia.Text = Scotia.ToString
LbNumeroMovimientos.Text = Movimientos.ToString
LbImporteMovimientos.Text = Importe.ToString.FormatoNumero
UpComandosGeneracion.Update()
If DdlCuenta.SelectedItem.Text.ToUpper.Contains("BANCOMER") OrElse DdlCuenta.SelectedItem.Text.ToUpper.Contains("BBVA") Then
TrNumeroBancomer.Visible = True
End If
If DdlCuenta.SelectedItem.Text.ToUpper.Contains("BAJIO") Then
TrNumeroBajio.Visible = True
End If
If DdlCuenta.SelectedItem.Text.ToUpper.Contains("SCOTIA") Then
TrNumeroScotia.Visible = True
End If
UpComandosGeneracion.Update()
End Sub
#End Region
@@ -544,15 +677,29 @@ Partial Class Bancos_PagoElectronicoGrupos
'Colorea GV
If e.Row.DBCampo("RazonSocial").ToString = "" Then
e.Row.BackColor = Drawing.Color.WhiteSmoke
Else
If e.Row.DBCampo("EstatusPagoElectronicoGrupos").ToString <> "True" Then
Else
Dim CuentaDepositoSinAlta As Boolean = False
If (DdlCuenta.SelectedItem.Text.ToUpper.Contains("BANCOMER") OrElse DdlCuenta.SelectedItem.Text.ToUpper.Contains("BBVA")) AndAlso e.Row.DBCampo("EstatusPagoElectronicoGrupos").ToString <> "True" Then
CuentaDepositoSinAlta = True
End If
If DdlCuenta.SelectedItem.Text.ToUpper.Contains("BAJIO") AndAlso e.Row.DBCampo("EstatusPagoElectronicoGruposBajio").ToString <> "True" Then
CuentaDepositoSinAlta = True
End If
If DdlCuenta.SelectedItem.Text.ToUpper.Contains("SCOTIA") AndAlso e.Row.DBCampo("EstatusPagoElectronicoGruposScotia").ToString <> "True" Then
CuentaDepositoSinAlta = True
End If
If CuentaDepositoSinAlta Then
'e.Row.BackColor = Drawing.Color.LightSalmon
e.Row.ToolTip = "Cuenta Deposito aun sin dar de Alta."
LnkAyuda.Attributes.Add("data-content", "Cuenta Deposito aún sin dar de Alta.")
LnkAyuda.Visible = True
End If
If e.Row.DBCampo("CveProveedor").ToString.ToEntero > 0 Then
@@ -688,10 +835,15 @@ Partial Class Bancos_PagoElectronicoGrupos
Private Sub RecargaDatos()
CargaDatos()
TipoMasiva = 1
DdlTipoCargaMasiva.SelectedValueExist("1")
CargaProveedores()
DdlTipoCargaMasiva.SelectedValueExist("1")
CargaProveedores(OpBancos)
End Sub
#End Region
@@ -707,9 +859,17 @@ Partial Class Bancos_PagoElectronicoGrupos
If Not DdlCuenta.SelectedValue.ToEntero > 0 Then
Alert("Primero debe seleccionar una Cuenta", TipoMensaje.MsgAdvertencia)
Exit Sub
End If
AltaProveedores()
End If
If OpBancos = 1 Then
AltaProveedores()
ElseIf OpBancos = 2 Then
AltaProveedoresBajio()
ElseIf OpBancos = 3 Then
'AltaProveedoresScotia()
End If
End Sub
Private Sub AltaProveedores(Optional DtCuentasPendientesTemp As DataTable = Nothing)
@@ -960,6 +1120,7 @@ Partial Class Bancos_PagoElectronicoGrupos
If NombreArchivoBancomer.Length > 0 Or NombreArchivoInterbancario.Length > 0 Or NombreArchivoCIE.Length > 0 Then
LblCuentas.Text = "Cuentas Bancomer"
LnkDescargaCuentas1.Text = NombreArchivoBancomer
LnkDescargaCuentas2.Text = NombreArchivoInterbancario
LnkDescargaCuentas3.Text = NombreArchivoCIE
@@ -974,6 +1135,217 @@ Partial Class Bancos_PagoElectronicoGrupos
End Sub
'---------------------------------------------------------------------------------
' Banco: BAJÍO – Alta de Proveedores y Cuentas (layout 541 espacios)
' Notas:
' • Header: 01 + Nº archivo(7) + fecha(yyyyMMdd) + divisa("001") = 20 bytes
' • Detalle: 02 + consecutivo(7) + "0140" + [banco(3)+tipo(2)+cta(20)] + alias(15) +
' nombre(40) + RFC(13) + correo(55) + importeMax(15) + tiempoUso(20) +
' periodoImp(40) + usuarios(100) + moneda(3) + tipoRel(2) + otroRel(60) +
' filler(140) = 541 bytes
' • Pie: 09 + totalLíneas(7) + totalReg(7) + "00000000" + "0000000000" = 34 bytes
'---------------------------------------------------------------------------------
Private Sub AltaProveedoresBajio(Optional ByVal DtCuentasPendientesTemp As DataTable = Nothing)
'------------------- Inicialización de variables y filtros ----------------
NombreArchivo = ""
DVDescargaCuentas1.Visible = False 're uso los mismos controles que Bancomer
DVDescargaCuentas2.Visible = False
DVDescargaCuentas3.Visible = False
Dim RegistrosAltaBajio As New StringBuilder
Dim SBErrores As New StringBuilder
Dim CeroRelleno As Char = "0"c
Dim EspacioRelleno As Char = ChrW(32)
If DtCuentasPendientesTemp Is Nothing Then DtCuentasPendientesTemp = DTPendientes.Copy
DtCuentasPendientesTemp.CaseSensitive = False
'Sólo tomamos cuentas cuyo estatus aún no está confirmado
Dim DtCuentasPendientes As DataTable =
DtCuentasPendientesTemp.FiltraParametros(
"(EstatusPagoElectronicoGruposBajio IS NULL OR EstatusPagoElectronicoGruposBajio = 0)",
"",
{"BancoNombre", "CveBanco", "CLABEDestino", "Cuenta", "Abreviatura",
"RazonSocial", "RFC", "BBVAAlias"})
If DtCuentasPendientes.Rows.Count = 0 Then
Alert("No hay cuentas pendientes de alta para Bajío.", TipoMensaje.MsgAdvertencia)
Exit Sub
End If
'------------------- Constantes de layout ----------------
Const CABECERA_LEN As Integer = 20
Const DETALLE_LEN As Integer = 541
Const PIE_LEN As Integer = 16
Const DIVISA_MXN As String = "001"
'Const FILLER_8CEROS As String = "00000000"
Const FILLER_140ESP As String = " " '140 espacios
Const CONST_0140 As String = "0140"
Dim NumeroArchivo As Integer = 1 '→ ajústalo si manejas consecutivo diario
Dim FechaArchivo As Date = NowADS().Date
'------------------- CABECERA (20 espacios) ----------------
Dim Header As String = $"01{NumeroArchivo:D7}{FechaArchivo:yyyyMMdd}{DIVISA_MXN}"
If Header.Length <> CABECERA_LEN Then
Alert($"Header inválido. Esperado: {CABECERA_LEN} bytes, real: {Header.Length}.", TipoMensaje.MsgAdvertencia)
Exit Sub
End If
RegistrosAltaBajio.Append(Header & vbCrLf)
'------------------- DETALLES (541 espacios) ----------------
Dim ConsecArchivo As Integer = 2 'Ya contamos el header
For Each dRow As DataRow In DtCuentasPendientes.Rows
Dim SBTmp As New StringBuilder
Dim SBErrLinea As New StringBuilder
Dim ErrorLinea As Boolean = False
SBErrLinea.Append($"[{dRow("RazonSocial")}] ")
'---- Banco (3) + TipoCuenta (2) + Cuenta/CLABE (≤20) ---------------
Dim CveBanco As String = dRow("CveBanco").ToString.Trim.PadLeft(3, CeroRelleno)
If CveBanco.Length <> 3 OrElse Not IsNumeric(CveBanco) Then
SBErrLinea.Append("Banco inválido. ")
ErrorLinea = True
End If
Dim Cuenta As String = New String(
dRow("CLABEDestino").ToString _
.Where(AddressOf Char.IsDigit).ToArray()) 'sólo dígitos
If Cuenta.Length = 18 Then
Cuenta = Cuenta.PadLeft(20, CeroRelleno)
SBTmp.Append("40") 'tipo cuenta
ElseIf Cuenta.Length = 11 Or Cuenta.Length = 12 Then
Cuenta = Cuenta.PadLeft(20, CeroRelleno)
SBTmp.Append("01") 'tipo cuenta
Else
SBErrLinea.Append("Cuenta/CLABE debe tener 11-12-18 dígitos. ")
ErrorLinea = True
Cuenta = Cuenta.PadLeft(20, CeroRelleno)
SBTmp.Append("00")
End If
'---- AliasProveedor (15) + Nombre (40) --------------------------------------
Dim AliasProveedor As String = LimpiarBajio(If(dRow("BBVAAlias").ToString.Trim.Length > 0, dRow("BBVAAlias").ToString, dRow("RazonSocial").ToString).ToString, 15)
Dim Nombre As String = LimpiarBajio(dRow("RazonSocial").ToString, 40)
'---- RFC (13) + Correo (55) ----------------------------------------
Dim Rfc As String = LimpiarBajio(dRow("RFC").ToString, 13, True)
'Dim Correo As String = LimpiarBajio(dRow("CorreoElectronico").ToString, 55, True)
Dim Correo As String = LimpiarBajio("", 55, True)
'---- Campos opcionales en blanco / ceros ---------------------------
Const IMPORTE_MAX As String = "000000000000000"
Const TIEMPO_USO As String = " " '20 esp
Const PERIODO_IMP As String = " " '40 esp
Const USUARIOS As String = " " '94 esp
Const MONEDA As String = " "
Const TIPO_REL As String = " "
Const OTRO_REL As String = " "
'---- Armar línea detalle -------------------------------------------
If Not ErrorLinea Then
With SBTmp
.Insert(0, "02") 'tipo registro
.Insert(2, ConsecArchivo.ToString("D7")) 'consecutivo archivo
.Insert(9, CONST_0140) 'constante 0140
.Insert(13, CveBanco) 'banco (3)
'En 16 ya está tipo (2) y cuenta (20) que añadimos antes
.Append(Cuenta) '20
.Append(AliasProveedor.PadRight(15, EspacioRelleno))
.Append(Nombre.PadRight(40, EspacioRelleno))
.Append(Rfc.PadRight(13, EspacioRelleno))
.Append(Correo.PadRight(55, EspacioRelleno))
.Append(IMPORTE_MAX)
.Append(TIEMPO_USO)
.Append(PERIODO_IMP)
.Append(USUARIOS)
.Append(MONEDA)
.Append(TIPO_REL)
.Append(OTRO_REL)
.Append(FILLER_140ESP)
End With
If SBTmp.Length <> DETALLE_LEN Then
SBErrLinea.Append($"Longitud {SBTmp.Length}/541 incorrecta. ")
ErrorLinea = True
End If
End If
'---- Añadir al archivo o a la lista de errores ----------------------
If ErrorLinea Then
RegistrosAltaBajio.Append(SBTmp.ToString & vbCrLf)
SBErrLinea.Append("<br>")
SBErrores.AppendLine(SBErrLinea.ToString)
Else
RegistrosAltaBajio.Append(SBTmp.ToString & vbCrLf)
'Aquí puedes marcar la cuenta como “AltaGenerada” en BD si lo deseas
ConsecArchivo += 1
End If
Next
'------------------- PIE (16 ) ----------------
Dim TotalLineas As Integer = ConsecArchivo 'header + detalles + pie aún no añadido
Dim TotalRegistros As Integer = TotalLineas - 2
Dim Pie As String = $"09{TotalLineas:D7}{TotalRegistros:D7}"
If Pie.Length <> PIE_LEN Then
Alert($"Pie inválido ({Pie.Length} bytes).", TipoMensaje.MsgAdvertencia)
Exit Sub
End If
RegistrosAltaBajio.Append(Pie)
'------------------- Crear archivo y mostrar descargas ------------------
TextoCompleto = RegistrosAltaBajio.ToString
If RegistrosAltaBajio.Length = 0 Then
Alert("No se generó ningún registro válido para Bajío.", TipoMensaje.MsgAdvertencia)
Exit Sub
End If
Dim NombreArchivoEnviado As String = $"altacuentasbajio_{FechaArchivo:ddMMyyyy}_{NumeroArchivo:D3}.txt"
If CreaArchivo(2, True, NombreArchivoEnviado) Then
DVDescargaPagos.Visible = False
DVDescargaReporte.Visible = False
LblCuentas.Text = "Cuentas Bajio"
NombreArchivoBancomer = "" 'No usamos estos para Bajío
NombreArchivoInterbancario = ""
NombreArchivoCIE = ""
NombreArchivo = NombreArchivoEnviado
DVDescargaCuentas1.Visible = True
LnkDescargaCuentas1.Text = NombreArchivo
RegistraScript("$('#ModalDescarga').modal({ backdrop: 'static', keyboard: false});")
UpModalDescarga.Update()
End If
If SBErrores.Length > 0 Then
Alert(SBErrores.ToString, TipoMensaje.MsgAdvertencia)
End If
CargaDatos()
End Sub
Private Function LimpiarBajio(ByVal texto As String,
ByVal maxLen As Integer,
Optional ByVal permitirVacio As Boolean = False) As String
Dim _rxProhibidos As New Regex("[\$\,\./\-ñÑÁÉÍÓÚÜáéíóúü]", RegexOptions.Compiled)
texto = If(texto, "").Trim()
If Not permitirVacio AndAlso texto.Length = 0 Then Return ""
texto = New String(texto.Normalize(NormalizationForm.FormD) _
.Where(Function(ch) CharUnicodeInfo.GetUnicodeCategory(ch) <> UnicodeCategory.NonSpacingMark) _
.ToArray()) _
.Normalize(NormalizationForm.FormC)
texto = _rxProhibidos.Replace(texto, "")
If texto.Length > maxLen Then texto = texto.Substring(0, maxLen)
Return texto
End Function
@@ -1177,7 +1549,7 @@ Partial Class Bancos_PagoElectronicoGrupos
If DTPendientes.FiltraParametros("EstatusPagoElectronicoGrupos = 'True' AND EstatusCtaDeposito = 'True'") IsNot Nothing Then
Dim CuentaCargo As String = "0382755740201"
Dim CuentaCargo As String = "382755740201"
If DdlCuenta.SelectedItem.Text.Contains("BAJIO") Then
@@ -1185,7 +1557,9 @@ Partial Class Bancos_PagoElectronicoGrupos
numeroArchivo:=1,
fechaCargo:=NowADS,
cuentaCargo:=CuentaCargo,
DTPendientes.FiltraParametros("EstatusPagoElectronicoGrupos = 'True' AND EstatusCtaDeposito > 0"))
DTDatos:=DTPendientes.FiltraParametros("EstatusPagoElectronicoGrupos = 'True' AND EstatusCtaDeposito > 0"),
InsertaEnDB:=False
)
ElseIf DdlCuenta.SelectedItem.Text.Contains("Scotiabank") Then
@@ -1210,30 +1584,35 @@ Partial Class Bancos_PagoElectronicoGrupos
Public Sub GeneraPagoBajio(numeroArchivo As Integer,
fechaCargo As Date,
cuentaCargo As String,
DTDatos As DataTable)
DTDatos As DataTable,
InsertaEnDB As Boolean)
Dim ErrorLayout As Boolean = False
Dim HEADER_LEN As Integer = 20
Dim CABECERA_LEN As Integer = 20
Dim DETALLE_LEN As Integer = 384
Dim TRAILER_LEN As Integer = 34
Dim PIE_LEN As Integer = 34
' --- columnas fijas del header / trailer ---
' --- columnas fijas del header / Pie ---
Dim DIVISA_MXN As String = "001"
'Dim FILLER_7CEROS As String = "0000000"
Dim FILLER_8CEROS As String = "00000000"
Dim FILLER_4CEROS As String = "0000"
Dim FILLER_9CEROS As String = "000000000"
'Dim FILLER_4CEROS As String = "0000"
Dim CONST_0140 As String = "0140" '/** Pregunta */: tu banco usa siempre 0140?
Dim _mediosValidos As HashSet(Of String) = New HashSet(Of String)({"BCO", "TEF", "SPE", "SPD"})
Dim _tiposCuentaValidos As HashSet(Of String) = New HashSet(Of String)({"40", "1", "3"})
' --------------------------- Header (20 bytes) ---------------------------
Dim header As String = $"01{numeroArchivo:D7}{fechaCargo:yyyyMMdd}{DIVISA_MXN}"
If header.Length <> HEADER_LEN Then
Alert($"Header debe medir {HEADER_LEN} bytes, mide {header.Length}.", TipoMensaje.MsgAdvertencia)
If header.Length <> CABECERA_LEN Then
Alert($"Header debe medir {CABECERA_LEN} bytes, mide {header.Length}.", TipoMensaje.MsgAdvertencia)
Exit Sub
End If
' --------------------------- Detalles (384 bytes) ------------------------
Dim detalles As New List(Of String)(DTDatos.Rows.Count)
Dim consecArchivo As Integer = 2 'el #1 lo ocupa el header
Dim consecPago As Integer = 1
@@ -1250,6 +1629,7 @@ Partial Class Bancos_PagoElectronicoGrupos
Dim TipoCuentaDestino As String = ""
Dim Importe As Decimal = DRow("Importe").ToString.ToDecimal
Dim IVA As Decimal = 0D
Dim CveBanco As String = DRow("CveBanco").ToString.Trim 'CveBanco es el código SAT del banco tres dígitos
If nCaracteresClabeCuenta <> 18 Then
If nCaracteresClabeCuenta <> 12 Then
@@ -1265,9 +1645,9 @@ Partial Class Bancos_PagoElectronicoGrupos
End If
' ----------- Validaciones de negocio --------------------------------
DRow("RazonSocial") = LimpiarDatosBajio(DRow("RazonSocial").ToString, 15, "Alias")
DRow("RazonSocial") = LimpiarDatosBajio(DRow("RazonSocial").ToString, 250, "Descripción")
' ----------- Validaciones --------------------------------
DRow("RazonSocial") = LimpiarDatosBajio(DRow("RazonSocial").ToString, 15, "AliasProveedor")
DRow("Observaciones") = LimpiarDatosBajio(DRow("Observaciones").ToString, 250, "Descripción")
If Not _tiposCuentaValidos.Contains(TipoCuentaDestino) Then
Alert($"TipoCuentaDestino inválido: {TipoCuentaDestino}", TipoMensaje.MsgAdvertencia)
@@ -1294,6 +1674,16 @@ Partial Class Bancos_PagoElectronicoGrupos
Exit Sub
End If
If cuentaCargo.Length <> 12 Then
Alert($"Cuenta de cargo debe tener 12 caracteres, tiene {cuentaCargo.Length}.", TipoMensaje.MsgAdvertencia)
Exit Sub
End If
If CveBanco.Length <> 3 Then
Alert($"Clabe SAT de cuenta deposito no valida, cuenta: {ClabeOCuenta}, valor SAT:{CveBanco}.", TipoMensaje.MsgAdvertencia)
Exit Sub
End If
'If DRow.IVA < 0D Then
' Alert("IVA no puede ser negativo.", TipoMensaje.MsgAdvertencia)
' Exit Sub
@@ -1302,47 +1692,138 @@ Partial Class Bancos_PagoElectronicoGrupos
' ----------- Construcción de la línea --------------------------------
Dim sb As New StringBuilder(DETALLE_LEN)
sb.Append("02") 'tipo registro
sb.Append(consecArchivo.ToString("D7")) 'consec archivo
sb.Append("01") 'tipo cta origen fijo
sb.Append(FILLER_8CEROS) 'filler
sb.Append(cuentaCargo.PadLeft(12, "0"c)) 'cta cargo
sb.Append(CONST_0140) 'constante 0140
sb.Append(ClabeOCuenta.PadLeft(3, "0"c))
sb.Append("00") '5 dígitos banco destino
sb.Append(consecPago.ToString("D10")) 'consec pago
sb.Append("000" & fechaCargo.ToString("yyyyMMdd")) 'prefijo 000 + fecha
sb.Append("02") 'tipo registro
sb.Append(consecArchivo.ToString("D7")) 'consec archivo
sb.Append("01") 'tipo cta origen fijo
sb.Append(FILLER_8CEROS) 'filler
sb.Append(cuentaCargo.PadLeft(12, "0"c)) 'cta cargo
sb.Append(CONST_0140) 'constante 0140?
sb.Append(CveBanco.Substring(0, 3).PadLeft(3, "0"c)) 'codigo de banco SAT
sb.Append(consecPago.ToString.PadLeft(10, "0"c)) 'consec pago
sb.Append("00000" & fechaCargo.ToString("yyyyMMdd")) 'prefijo 000 + fecha
sb.Append(MedioPago) 'BCO/TEF/SPE/SPD
sb.Append(TipoCuentaDestino.PadLeft(2, "0"c)) 'tipo cta destino
sb.Append(FILLER_4CEROS) 'filler
sb.Append(DRow("RazonSocial").ToString.PadRight(15)) 'alias (15)
'sb.Append(FILLER_4CEROS) 'filler
sb.Append(ClabeOCuenta.PadLeft(20, "0"c))
sb.Append(FILLER_9CEROS)
'sb.Append(DRow("RazonSocial").ToString.PadRight(15))
sb.Append(LimpiarBajio(If(DRow("BBVAAlias").ToString.Trim.Length > 0, DRow("BBVAAlias").ToString, DRow("RazonSocial").ToString).ToString, 15)) 'alias (15)
sb.Append(CLng(IVA).ToString("D15")) 'IVA ×100
sb.Append(DRow("RazonSocial").ToString.PadRight(250)) 'descripción (250)
sb.Append(DRow("Observaciones").ToString.PadRight(250)) 'descripción (250)
sb.Append(If(String.IsNullOrEmpty(ReferenciaSPEI),
New String("0"c, 7),
ReferenciaSPEI)) 'referencia SPEI
ReferenciaSPEI)) 'referencia SPEI
sb.Append(If(String.IsNullOrEmpty(ClasificacionSPID),
"00",
ClasificacionSPID.PadLeft(2, "0"c))) 'clasif SPID
sb.Append(New String(" "c, 25)) 'filler final
ClasificacionSPID.PadLeft(2, "0"c))) 'clasif SPID
sb.Append(New String(" "c, 25)) 'filler final
If sb.Length <> DETALLE_LEN Then
Throw New InvalidOperationException($"Detalle #{consecPago} mide {sb.Length} bytes, debería {DETALLE_LEN}.")
End If
detalles.Add(sb.ToString())
detalles.Add($"{sb.ToString()}{vbCrLf}")
consecArchivo += 1
consecPago += 1
totalCentavos += CLng(Importe * 100)
Next
' --------------------------- Trailer (34 bytes) -------------------------
Dim totalLineas As Integer = 1 + DTDatos.Rows.Count + 1 'header + detalles + trailer
Dim trailer As String = $"09{totalLineas:D7}{DTDatos.Rows.Count:D7}{FILLER_8CEROS}{totalCentavos:D10}"
If trailer.Length <> TRAILER_LEN Then Throw New InvalidOperationException($"Trailer debe medir {TRAILER_LEN} bytes, mide {trailer.Length}.")
' --------------------------- Resultado ----------------------------------
'Return {header}.Concat(detalles).Concat({trailer})
Dim totalLineas As Integer = 1 + DTDatos.Rows.Count + 1 'header + detalles + Pie
Dim Pie As String = $"09{totalLineas:D7}{DTDatos.Rows.Count:D7}{FILLER_8CEROS}{totalCentavos:D10}"
If Pie.Length <> PIE_LEN Then
Alert($"Pie debe medir {PIE_LEN} bytes, mide {Pie.Length}.", TipoMensaje.MsgAdvertencia)
ErrorLayout = True
End If
Dim NombreArchivo As String = $"pagos_{NowADS.ToString("ddMMyyyy")}_001.txt"
'"pagos_03062025_001.txt"
If InsertaEnDB Then
Dim ObjBancos As New ClsBancos
ObjBancos.IniciaTransacSQL()
Dim CveLayoutEnvio As Integer = ObjBancos.AddLayoutEnvios(NombreArchivo, NowADS(), CveCuenta, PorGrupos:=True)
If CveLayoutEnvio > 0 Then
For Each dr As DataRow In DTDatos.Rows
If dr("CveProveedor").ToString <> "" Or dr("CvePersonal").ToString <> "" Then
If Not ObjBancos.AddLayoutEnviosDetalle(CveLayoutEnvio, dr("CveIE").ToString.ToEntero, dr("CveProveedor").ToString.ToEntero, dr("CvePersonal").ToString.ToEntero, 1, "Observaciones") Then
ErrorLayout = True
Exit For
End If
End If
Next
Else
ErrorLayout = True
End If
If ErrorLayout Then
ObjBancos.RollBack()
ObjBancos.Dispose()
Else
ObjBancos.Commit()
ObjBancos.Dispose()
End If
End If
Dim path As String = String.Format("{0}Layout\{1}", UsuarioActual.Empresa.Ruta, NombreArchivo)
Dim pathDirectorio As String = String.Format("{0}Layout\", UsuarioActual.Empresa.Ruta)
If File.Exists(path) Then
File.Delete(path)
End If
If Not Directory.Exists(pathDirectorio) Then
Directory.CreateDirectory(pathDirectorio)
End If
Dim Texto As String = $"{header}{vbCrLf}{String.Join(vbCrLf, detalles)}{Pie}"
Dim fs As FileStream = File.Create(path)
Dim info As Byte() = New UTF8Encoding(True).GetBytes(Texto)
fs.Write(info, 0, info.Length)
fs.Close()
If ErrorLayout = False And consecPago > 0 Then
Dim Mensaje As New StringBuilder
Mensaje.Append("Descarga Layout<br>")
'If NombreArchivo.Length > 0 Then
' NombreArchivoPago = NombreArchivoEnviado
'End If
'If NombreArchivoPago.Trim.Length > 0 Then
' Mensaje.Append($"Pagos Descarga <a class='Texto' href='../Empresas/{UsuarioActual.CveEmpresa}/Layout/{NombreArchivoPago}' download> {NombreArchivoPago}<a> <br><br>")
'End If
If NombreArchivo.Length > 0 Then
DVDescargaPagos.Visible = True
DVDescargaCuentas1.Visible = False
DVDescargaCuentas2.Visible = False
DVDescargaCuentas3.Visible = False
DVDescargaReporte.Visible = True
DT_PagosReporte = DTDatos.Copy
LnkDescarga.Text = NombreArchivo
RegistraScript("$('#ModalDescarga').modal({ backdrop: 'static', keyboard: false});")
UpModalDescarga.Update()
End If
CargaDatos()
End If
End Sub
Private Function LimpiarDatosBajio(texto As String, maxLen As Integer, campo As String) As String
@@ -1350,7 +1831,7 @@ Partial Class Bancos_PagoElectronicoGrupos
Dim _rxProhibidos As Regex = New Regex("[\$\,\./\-ñÑÁÉÍÓÚÜáéíóúü]", RegexOptions.Compiled)
If String.IsNullOrWhiteSpace(texto) Then
Throw New ArgumentException($"{campo} es obligatorio.")
Alert($"{campo} es obligatorio.", TipoMensaje.MsgAdvertencia)
End If
' Normalizar y quitar diacríticos
@@ -1363,9 +1844,16 @@ Partial Class Bancos_PagoElectronicoGrupos
s = _rxProhibidos.Replace(s, "")
If s.Length > maxLen Then
Throw New ArgumentException($"{campo} ({s}) excede {maxLen} caracteres.")
If campo = "AliasProveedor" Or campo = "Descripción" Then
s = s.Substring(0, maxLen)
Else
Alert($"{campo} ({s}) excede {maxLen} caracteres.", TipoMensaje.MsgAdvertencia)
End If
End If
Return s
End Function
Private Sub GeneraPagoScotiabank(dataTable As DataTable)
@@ -1621,31 +2109,22 @@ Partial Class Bancos_PagoElectronicoGrupos
End If
If ErrorLayout = False And RegistrosPago.Length > 0 Then
Dim Mensaje As New StringBuilder
Mensaje.Append("Descarga Layout<br>")
If NombreArchivoEnviado.Length > 0 Then
NombreArchivoPago = NombreArchivoEnviado
End If
'If NombreArchivoPago.Trim.Length > 0 Then
' Mensaje.Append($"Pagos Descarga <a class='Texto' href='../Empresas/{UsuarioActual.CveEmpresa}/Layout/{NombreArchivoPago}' download> {NombreArchivoPago}<a> <br><br>")
'End If
If NombreArchivoPago.Length > 0 Then
DVDescargaPagos.Visible = True
DVDescargaCuentas1.Visible = False
DVDescargaCuentas2.Visible = False
@@ -2239,7 +2718,7 @@ Partial Class Bancos_PagoElectronicoGrupos
If DdlTipoCargaMasiva.SelectedValue.ToEntero = 1 Then
TipoMasiva = 1
GvProveedores.Columns(0).HeaderText = "Proveedor"
CargaProveedores()
CargaProveedores(OpBancos)
BtnGenerarProveedores.Text = "Generar Layout Alta Proveedores"
Else
TipoMasiva = 2
@@ -2255,17 +2734,28 @@ Partial Class Bancos_PagoElectronicoGrupos
Exit Sub
End If
If TipoMasiva = 1 Then
AltaProveedores(DTProveedores)
If TipoMasiva = 1 Then
If OpBancos = 1 Then
AltaProveedores(DTProveedores)
ElseIf OpBancos = 2 Then
AltaProveedoresBajio(DTProveedores)
ElseIf OpBancos = 3 Then
'AltaProveedoresScotia(DTProveedores)
End If
Else
AltaFyE()
End If
End Sub
Private Sub CargaProveedores()
Private Sub CargaProveedores(OpBanco As Integer)
Dim ObjBancos As New ClsBancos
If ObjBancos.GetLayoutProveedores(DdlCuenta.SelectedValue.ToEntero, UsuarioActual.CveEmpresa, PorGrupos:=True) Then
If ObjBancos.GetLayoutProveedores(DdlCuenta.SelectedValue.ToEntero, UsuarioActual.CveEmpresa, PorGrupos:=True, OpBanco:=OpBanco) Then
DTProveedores = ObjBancos.DtResultados.FiltraParametros("LEN(RFC) IN (12,13)")
Else
DTProveedores = New DataTable
@@ -2915,6 +3405,12 @@ Partial Class Bancos_PagoElectronicoGrupos
Dim FileName As String = NombreArchivo
Dim FilePath As String = $"{UsuarioActual.Empresa.Ruta}Layout\{NombreArchivo}"
If NombreArchivo.Length = 0 Then
FileName = LnkDescarga.Text
FilePath = $"{UsuarioActual.Empresa.Ruta}Layout\{ LnkDescarga.Text}"
End If
Response.Clear()
Response.ContentType = "application/octet-stream"
Response.AddHeader("Content-Disposition", "attachment; filename=" & FileName)
@@ -2925,13 +3421,21 @@ Partial Class Bancos_PagoElectronicoGrupos
Protected Sub LnkDescargaCuentas1_Click(sender As Object, e As EventArgs)
Dim FileName As String = NombreArchivoBancomer
Dim FilePath As String = $"{UsuarioActual.Empresa.Ruta}Layout\{NombreArchivoBancomer}"
If DdlCuenta.SelectedItem.Text.ToUpper.Contains("BAJIO") Or DdlCuenta.SelectedItem.Text.ToUpper.Contains("SCOTIA") Then
FileName = LnkDescargaCuentas1.Text
FilePath = $"{UsuarioActual.Empresa.Ruta}Layout\{LnkDescargaCuentas1.Text}"
End If
Response.Clear()
Response.ContentType = "application/octet-stream"
Response.AddHeader("Content-Disposition", "attachment; filename=" & FileName)
Response.TransmitFile(FilePath)
Response.End()
End Sub
Protected Sub LnkDescargaCuentas2_Click(sender As Object, e As EventArgs)
Dim FileName As String = NombreArchivoInterbancario
@@ -3057,4 +3561,28 @@ Partial Class Bancos_PagoElectronicoGrupos
Alert("Correos ya enviados.")
End Sub
Protected Sub DdlCuenta_SelectedIndexChanged(sender As Object, e As EventArgs)
DdlTipoCargaMasiva.Items(1).Enabled = False
DdlTipoCargaMasiva.SelectedValueExist(-1)
DdlTipoGeneracion.Items(2).Enabled = False
DdlTipoGeneracion.Items(3).Enabled = False
DdlTipoGeneracion.SelectedValueExist(-1)
If OpBancos = 1 Then
DdlTipoGeneracion.Items(2).Enabled = True
DdlTipoGeneracion.Items(3).Enabled = True
DdlTipoCargaMasiva.Items(1).Enabled = True
ElseIf OpBancos = 2 Then
'
ElseIf OpBancos = 3 Then
'
End If
UpFiltroCargaMasiva.Update()
UpFiltros.Update()
End Sub
End Class

View File

@@ -238,6 +238,10 @@ Partial Class Bancos_RepComplementoPago
e.Row.FCLabel("LblImp").Text = e.Row.DBCampo("VentasTotalPagado").FormatoNumero
e.Row.FCLabel("LblImp").ToolTip = String.Format("Importe Pagado:{0} ", e.Row.DBCampo("Importe").FormatoNumero) ' VentasTotalPagado
Dim importe As Decimal = e.Row.DBCampo("Importe").ToDecimal.RoundAD
Dim ventasTotalPagado As Decimal = e.Row.DBCampo("VentasTotalPagado").ToDecimal.RoundAD
If e.Row.DBCampo("Importe").ToDecimal.RoundAD <> e.Row.DBCampo("VentasTotalPagado").ToDecimal.RoundAD Then
e.Row.FCLabel("LblImp").ForeColor = Drawing.Color.Red
e.Row.FCLabel("LblImp").ToolTip = String.Format("Importe Pagado:{0} Importe Pagado PUE: {1}, Ot. Ingresos {2}", e.Row.DBCampo("Importe").FormatoNumero, e.Row.DBCampo("PagadoPUE").FormatoNumero, e.Row.DBCampo("PagadoOtIngresos").FormatoNumero) ' VentasTotalPagado

View File

@@ -9164,9 +9164,12 @@ Partial Class Compras_Compras
Next
'If UsuarioActual.Empresa.Funcionalidad(207) = "1" Then
If Not ActualizarPrePoliza(ObjContabilidad, ObjCompra) Then
Retorno = False
If Not ComparaDatatables(False) Then
If Not ActualizarPrePoliza(ObjContabilidad, ObjCompra) Then
Retorno = False
End If
End If
'End If
@@ -9972,26 +9975,32 @@ Partial Class Compras_Compras
End Sub
Private Function ComparaDatatables() As Boolean
Private Function ComparaDatatables(Optional ValidaNoDeducible As Boolean = True) As Boolean
Dim NumRow As Integer = 0
For Each row1 As DataRow In TmpDT.Rows
Dim NumRow2 As Integer = 0
For Each row2 As DataRow In TmpDTOriginal.Rows
'Dim test As Boolean = (row1("NoDeducible").ToString <> row2("NoDeducible").ToString And ValidaNoDeducible)
'Dim test2 As Boolean = (row1("IVAPorcentaje").ToString.ToDecimal <> row2("IVAPorcentaje").ToString.ToDecimal AndAlso CveCompra > 0 AndAlso CveCompraFactura = 0)
Dim TipoCompra As Integer = If(DdlTipoCompra.SelectedValue.ToEntero > 0, DdlTipoCompra.SelectedValue.ToEntero, 0)
If NumRow2 = NumRow Then
If (row1("CveSubProyecto").ToString.ToEntero <> row2("CveSubProyecto").ToString.ToEntero) Or
(row1("CveClasificacion").ToString.ToEntero <> row2("CveClasificacion").ToString.ToEntero) Or
(row1("CveTipoGasto").ToString.ToEntero <> row2("CveTipoGasto").ToString.ToEntero) Or
(row1("Total").ToString.ToDouble <> row2("Total").ToString.ToDouble) Or
(row1("NoDeducible").ToString <> row2("NoDeducible").ToString) Or
(row1("NoDeducible").ToString <> row2("NoDeducible").ToString And ValidaNoDeducible) Or
(row1("CveActivoFijo").ToString.ToEntero <> row2("CveActivoFijo").ToString.ToEntero) Or
(row1("AFMedida").ToString.ToEntero <> row2("AFMedida").ToString.ToEntero) Or
(row1("TipoAF").ToString.ToEntero <> row2("TipoAF").ToString.ToEntero) Or
(row1("CvePS").ToString.ToEntero <> row2("CvePS").ToString.ToEntero) Or
(row1("Obs").ToString <> row2("Obs").ToString) Or
(row1("IVAPorcentaje").ToString <> row2("IVAPorcentaje").ToString AndAlso CveCompra > 0 AndAlso CveCompraFactura = 0) Or
(DdlTipoCompra.SelectedValue.ToEntero <> TipoCompraOriginal) Then
(row1("IVAPorcentaje").ToString.ToDecimal <> row2("IVAPorcentaje").ToString.ToDecimal AndAlso CveCompra > 0 AndAlso CveCompraFactura = 0) Or
(TipoCompra <> TipoCompraOriginal) Then
Return False
End If
End If

View File

@@ -742,6 +742,7 @@ Partial Class Contabilidad2_CatCuentas
params.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre))
ImprimirPDF("Empresas/Grales/Formatos/Cuentas.rdlc", DtDatos, params, "Cuentas", Formato)
'ImprimirPDFStimul("Empresas/Grales/Formatos/Cuentas.mrt", DtDatos, params, NombreArchivo:="Cuentas", RDSName:="Cuentas", Formato:=Formato)
Else
Alert("No hay datos consultados", TipoMensaje.MsgAdvertencia)
End If

View File

@@ -251,6 +251,8 @@
<asp:HiddenField ID="HdnIdSegNeg" runat="server" Value='<%# Eval("IdSegNeg")%>' />
<asp:HiddenField ID="HdnCompraIdPoliza" runat="server" Value='<%# Eval("CompraIdPoliza")%>' />
<asp:HiddenField ID="HdnPorcentajeIVA" runat="server" Value='<%# Eval("PorcentajeIVA")%>' />
<asp:HiddenField ID="HdnCveMonedaCompra" runat="server" Value='<%# Eval("CveMonedaCompra")%>' />
<table width="100%" cellpadding="0" cellspacing="0" runat="server" id="TbCompra">
<tr class="SubTotales">
@@ -432,6 +434,7 @@
<asp:HiddenField ID="HdnIdSegNeg" runat="server" Value='<%# Eval("IdSegNeg")%>' />
<asp:HiddenField ID="HdnCompraIdPoliza" runat="server" Value='<%# Eval("CompraIdPoliza")%>' />
<asp:HiddenField ID="HdnPorcentajeIVA" runat="server" Value='<%# Eval("PorcentajeIVA")%>' />
<asp:HiddenField ID="HdnCveMonedaCompra" runat="server" Value='<%# Eval("CveMonedaCompra")%>' />
<table width="100%" cellpadding="0" cellspacing="0" runat="server" id="TbCompra">
<tr class="SubTotales">
<td>

View File

@@ -649,13 +649,27 @@ Partial Class Contabilidad_DiarioPagos
'recorro el grid de compras
Dim GvCompras As GridView = gvr.FCGridView("GvPC")
Dim MonExtOriginal As Boolean = MonExt
For Each gvrc As GridViewRow In GvCompras.Rows
MonExt = MonExtOriginal
Dim CveMonedaCompra As Integer = gvrc.FCHiddenField("HdnCveMonedaCompra").Value.ToEntero()
If CveMoneda = 1 AndAlso CveMonedaCompra = 2 Then
MonExt = True
End If
Dim PorcentajeIVA As Decimal = (gvrc.FCHiddenField("HdnPorcentajeIVA").Value.ToDecimal() * 100).ToEntero
Cargos = 0
AbonoProveedor = 0 : CargoProveedor = 0 : CargoAnticipo = 0 : AbonoAnticipo = 0
'ya viene el tipo de cambio entre la fecha de compra y la ultima fluctuacion
If CveMoneda = 2 Then TipoCambioCompra = gvrc.FCHiddenField("HdnTC").Value.ToDecimal Else TipoCambioCompra = 1
If CveMoneda = 2 Or MonExt Then TipoCambioCompra = gvrc.FCHiddenField("HdnTC").Value.ToDecimal Else TipoCambioCompra = 1
ConceptoDetalle = gvrc.FCHiddenField("HdnRazonSocial").Value
CargoProveedor = 0 : CargoAnticipo = 0
@@ -1016,7 +1030,7 @@ Partial Class Contabilidad_DiarioPagos
If CargoProveedor > 0 Then ' cuando el pago no cubre el 100%
Dim TmpTotal As Decimal
Dim TmpTotalME As Decimal = CargoProveedor
If CveMoneda = 2 Then
If CveMoneda = 2 Or (CveMoneda = 1 And CveMonedaCompra = 2) Then
'registro a la cuenta complementaria del proveedor
If gvr.DataKey("IdCtaContComplementaria").ToEntero > 0 Then

View File

@@ -1237,7 +1237,6 @@
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<rd:Selected>true</rd:Selected>
</CellContents>
</TablixCell>
<TablixCell>
@@ -1649,7 +1648,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>16.4177cm</Top>
<Top>10.96728cm</Top>
<Left>3.65232cm</Left>
<Height>0.57354cm</Height>
<Width>12.91587cm</Width>
@@ -1665,7 +1664,7 @@
</Style>
</Textbox>
<Line Name="Line1">
<Top>17.86437cm</Top>
<Top>12.41395cm</Top>
<Left>7.71741cm</Left>
<Height>0cm</Height>
<Width>5.675cm</Width>
@@ -1693,7 +1692,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox3</rd:DefaultName>
<Top>17.93492cm</Top>
<Top>12.4845cm</Top>
<Left>7.71741cm</Left>
<Height>0.6cm</Height>
<Width>5.675cm</Width>
@@ -1708,412 +1707,6 @@
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox25">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Nombre Comercial: </Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Beneficiario:</Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style>
<FontSize>8pt</FontSize>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Banco:</Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style>
<FontSize>8pt</FontSize>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Clabe: </Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Cuenta:</Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style>
<FontSize>8pt</FontSize>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox1</rd:DefaultName>
<Top>12.29987cm</Top>
<Left>0.10282cm</Left>
<Height>2.03296cm</Height>
<Width>3.74249cm</Width>
<ZIndex>13</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox26">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>AGROQUIMICOS JAM SA DE CV</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>AGROQUIMICOS JAM SA DE CV</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>BBVA BANCOMER, MONEDA NACIONAL</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>012760004510539065</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>0451053906</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox1</rd:DefaultName>
<Top>12.29987cm</Top>
<Left>3.84531cm</Left>
<Height>2.03295cm</Height>
<Width>5.75197cm</Width>
<ZIndex>14</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox27">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Nombre Comercial: </Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Beneficiario:</Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style>
<FontSize>8pt</FontSize>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Banco:</Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style>
<FontSize>8pt</FontSize>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Clabe: </Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Cuenta:</Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style>
<FontSize>8pt</FontSize>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox1</rd:DefaultName>
<Top>12.29987cm</Top>
<Left>9.70311cm</Left>
<Height>2.03295cm</Height>
<Width>4.17266cm</Width>
<ZIndex>15</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox28">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>AGROQUIMICOS JAM SA DE CV</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>AGROQUIMICOS JAM SA DE CV</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>BBVA BANCOMER, MONEDA DOLARES</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>012760001097398900</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>0109739890</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox1</rd:DefaultName>
<Top>12.29987cm</Top>
<Left>13.87577cm</Left>
<Height>2.03294cm</Height>
<Width>6.94061cm</Width>
<ZIndex>16</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox4">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
@@ -2162,7 +1755,7 @@
<Left>0.08425cm</Left>
<Height>0.99688cm</Height>
<Width>8.10248cm</Width>
<ZIndex>17</ZIndex>
<ZIndex>13</ZIndex>
<Style>
<Border>
<Style>None</Style>
@@ -2174,7 +1767,7 @@
</Style>
</Textbox>
</ReportItems>
<Height>18.53492cm</Height>
<Height>13.16388cm</Height>
<Style />
</Body>
<Width>20.98934cm</Width>

View File

@@ -3768,412 +3768,6 @@
</Border>
</Style>
</Tablix>
<Textbox Name="Textbox24">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Nombre Comercial: </Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Beneficiario:</Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style>
<FontSize>8pt</FontSize>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Banco:</Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style>
<FontSize>8pt</FontSize>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Clabe: </Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Cuenta:</Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style>
<FontSize>8pt</FontSize>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox1</rd:DefaultName>
<Top>12.32756cm</Top>
<Left>0.10282cm</Left>
<Height>2.03296cm</Height>
<Width>3.74249cm</Width>
<ZIndex>18</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox25">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>AGROQUIMICOS JAM SA DE CV</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>AGROQUIMICOS JAM SA DE CV</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>BBVA BANCOMER, MONEDA NACIONAL</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>012760004510539065</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>0451053906</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox1</rd:DefaultName>
<Top>12.32756cm</Top>
<Left>3.84531cm</Left>
<Height>2.03295cm</Height>
<Width>5.75197cm</Width>
<ZIndex>19</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox27">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Nombre Comercial: </Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Beneficiario:</Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style>
<FontSize>8pt</FontSize>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Banco:</Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style>
<FontSize>8pt</FontSize>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Clabe: </Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Cuenta:</Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>
<Color>#008204</Color>
</Style>
</TextRun>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style>
<FontSize>8pt</FontSize>
<Color>#008204</Color>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Right</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox1</rd:DefaultName>
<Top>12.32756cm</Top>
<Left>9.70311cm</Left>
<Height>2.03295cm</Height>
<Width>4.17266cm</Width>
<ZIndex>20</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox28">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>AGROQUIMICOS JAM SA DE CV</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>AGROQUIMICOS JAM SA DE CV</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>BBVA BANCOMER, MONEDA DOLARES</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>012760001097398900</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
<Paragraph>
<TextRuns>
<TextRun>
<Value>0109739890</Value>
<Style>
<FontSize>8pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox1</rd:DefaultName>
<Top>12.32756cm</Top>
<Left>13.87577cm</Left>
<Height>2.03294cm</Height>
<Width>6.94061cm</Width>
<ZIndex>21</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox5">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
@@ -4205,7 +3799,7 @@
<Left>17.31584cm</Left>
<Height>0.65292cm</Height>
<Width>3.68516cm</Width>
<ZIndex>22</ZIndex>
<ZIndex>18</ZIndex>
<Style>
<Border>
<Style>None</Style>

View File

@@ -1549,7 +1549,7 @@
<Paragraph>
<TextRuns>
<TextRun>
<Value>Fecha Impresión</Value>
<Value>Fecha</Value>
<Style>
<FontSize>8pt</FontSize>
<Color>White</Color>
@@ -1586,7 +1586,8 @@
<Paragraph>
<TextRuns>
<TextRun>
<Value>=Format(Globals!ExecutionTime,"dd/MM/yyyy")</Value>
<Value>=
IIf(Len(Parameters!FechaSolicitud.Value) &gt;= 10, Mid(Parameters!FechaSolicitud.Value, 1, 10), Parameters!FechaSolicitud.Value)</Value>
<Style>
<FontSize>8pt</FontSize>
<Format>dd/MM/yyyy</Format>
@@ -2714,7 +2715,7 @@
<Paragraph>
<TextRuns>
<TextRun>
<Value>Fecha Impresión:</Value>
<Value>Fecha:</Value>
<Style>
<FontSize>8pt</FontSize>
<FontWeight>Bold</FontWeight>

View File

@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<Report xmlns="http://schemas.microsoft.com/sqlserver/reporting/2010/01/reportdefinition" xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">
<AutoRefresh>0</AutoRefresh>
<AutoRefresh>0</AutoRefresh>
<DataSources>
<DataSource Name="DataSet3">
<ConnectionProperties>
@@ -18,53 +18,57 @@
</Query>
<Fields>
<Field Name="Codigo">
<DataField>Codigo</DataField>
<rd:TypeName>System.String</rd:TypeName>
<DataField>Codigo</DataField>
</Field>
<Field Name="Nombre">
<DataField>Nombre</DataField>
<rd:TypeName>System.String</rd:TypeName>
<DataField>Nombre</DataField>
</Field>
<Field Name="CuentaFormato">
<DataField>CuentaFormato</DataField>
<rd:TypeName>System.String</rd:TypeName>
<DataField>CuentaFormato</DataField>
</Field>
<Field Name="Tipo">
<DataField>Tipo</DataField>
<rd:TypeName>System.String</rd:TypeName>
<DataField>Tipo</DataField>
</Field>
<Field Name="CtaMayor">
<DataField>CtaMayor</DataField>
<rd:TypeName>System.String</rd:TypeName>
<DataField>CtaMayor</DataField>
</Field>
<Field Name="AgrupadorSAT">
<DataField>AgrupadorSAT</DataField>
<rd:TypeName>System.String</rd:TypeName>
<DataField>AgrupadorSAT</DataField>
</Field>
<Field Name="Moneda">
<DataField>Moneda</DataField>
<rd:TypeName>System.String</rd:TypeName>
<DataField>Moneda</DataField>
</Field>
<Field Name="DigAgrup">
<DataField>DigAgrup</DataField>
<rd:TypeName>System.String</rd:TypeName>
<DataField>DigAgrup</DataField>
</Field>
<Field Name="NomIdioma">
<DataField>NomIdioma</DataField>
<rd:TypeName>System.String</rd:TypeName>
<DataField>NomIdioma</DataField>
</Field>
<Field Name="ConceptoContable">
<DataField>ConceptoContable</DataField>
<rd:TypeName>System.String</rd:TypeName>
<DataField>ConceptoContable</DataField>
</Field>
<Field Name="CodigoPadre">
<DataField>CodigoPadre</DataField>
<rd:TypeName>System.String</rd:TypeName>
<DataField>CodigoPadre</DataField>
</Field>
<Field Name="CodigoNombreSAT">
<DataField>CodigoNombreSAT</DataField>
<rd:TypeName>System.String</rd:TypeName>
<DataField>CodigoNombreSAT</DataField>
</Field>
<Field Name="Nivel">
<rd:TypeName>System.String</rd:TypeName>
<DataField>Nivel</DataField>
</Field>
</Fields>
<rd:DataSetInfo>
<rd:DataSetName>DataSet3</rd:DataSetName>
@@ -111,7 +115,10 @@
<Width>2.10313cm</Width>
</TablixColumn>
<TablixColumn>
<Width>2.10458cm</Width>
<Width>4.59166cm</Width>
</TablixColumn>
<TablixColumn>
<Width>2.5cm</Width>
</TablixColumn>
</TablixColumns>
<TablixRows>
@@ -121,6 +128,7 @@
<TablixCell>
<CellContents>
<Textbox Name="Textbox3">
<rd:DefaultName>Textbox3</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -139,7 +147,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox3</rd:DefaultName>
<RepeatWith>Tablix2</RepeatWith>
<Style>
<Border>
@@ -170,6 +177,7 @@
<TablixCell>
<CellContents>
<Textbox Name="Textbox2">
<rd:DefaultName>Textbox2</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -188,7 +196,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<RepeatWith>Tablix2</RepeatWith>
<Style>
<Border>
@@ -219,6 +226,7 @@
<TablixCell>
<CellContents>
<Textbox Name="Textbox22">
<rd:DefaultName>Textbox22</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -237,7 +245,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox22</rd:DefaultName>
<Style>
<Border>
<Color>LightGrey</Color>
@@ -267,6 +274,7 @@
<TablixCell>
<CellContents>
<Textbox Name="Textbox20">
<rd:DefaultName>Textbox20</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -285,7 +293,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox20</rd:DefaultName>
<Style>
<Border>
<Color>LightGrey</Color>
@@ -315,6 +322,7 @@
<TablixCell>
<CellContents>
<Textbox Name="Textbox18">
<rd:DefaultName>Textbox18</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -333,7 +341,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox18</rd:DefaultName>
<Style>
<Border>
<Color>LightGrey</Color>
@@ -363,6 +370,7 @@
<TablixCell>
<CellContents>
<Textbox Name="Textbox16">
<rd:DefaultName>Textbox16</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -381,7 +389,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox16</rd:DefaultName>
<Style>
<Border>
<Color>LightGrey</Color>
@@ -411,6 +418,7 @@
<TablixCell>
<CellContents>
<Textbox Name="Textbox14">
<rd:DefaultName>Textbox14</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -429,7 +437,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox14</rd:DefaultName>
<Style>
<Border>
<Color>LightGrey</Color>
@@ -459,6 +466,7 @@
<TablixCell>
<CellContents>
<Textbox Name="Textbox7">
<rd:DefaultName>Textbox7</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -477,7 +485,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox7</rd:DefaultName>
<Style>
<Border>
<Color>LightGrey</Color>
@@ -507,6 +514,7 @@
<TablixCell>
<CellContents>
<Textbox Name="Textbox1">
<rd:DefaultName>Textbox1</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -525,7 +533,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox1</rd:DefaultName>
<Style>
<Border>
<Color>LightGrey</Color>
@@ -555,6 +562,7 @@
<TablixCell>
<CellContents>
<Textbox Name="Textbox24">
<rd:DefaultName>Textbox24</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -573,7 +581,54 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox24</rd:DefaultName>
<Style>
<Border>
<Color>LightGrey</Color>
<Style>Solid</Style>
</Border>
<TopBorder>
<Color>Black</Color>
</TopBorder>
<BottomBorder>
<Color>Black</Color>
</BottomBorder>
<LeftBorder>
<Style>None</Style>
</LeftBorder>
<RightBorder>
<Style>None</Style>
</RightBorder>
<BackgroundColor>LightGrey</BackgroundColor>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
</CellContents>
</TablixCell>
<TablixCell>
<CellContents>
<Textbox Name="Textbox4">
<rd:DefaultName>Textbox4</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>Nivel</Value>
<Style>
<FontSize>9pt</FontSize>
<FontWeight>Bold</FontWeight>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Center</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<Style>
<Border>
<Color>LightGrey</Color>
@@ -608,6 +663,7 @@
<TablixCell>
<CellContents>
<Textbox Name="CuentaFormato">
<rd:DefaultName>CuentaFormato</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -625,7 +681,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>CuentaFormato</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
@@ -642,6 +697,7 @@
<TablixCell>
<CellContents>
<Textbox Name="Nombre">
<rd:DefaultName>Nombre</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -659,7 +715,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Nombre</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
@@ -676,6 +731,7 @@
<TablixCell>
<CellContents>
<Textbox Name="CodigoPadre">
<rd:DefaultName>CodigoPadre</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -693,7 +749,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>CodigoPadre</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
@@ -710,6 +765,7 @@
<TablixCell>
<CellContents>
<Textbox Name="Tipo">
<rd:DefaultName>Tipo</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -727,7 +783,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Tipo</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
@@ -744,6 +799,7 @@
<TablixCell>
<CellContents>
<Textbox Name="CtaMayor">
<rd:DefaultName>CtaMayor</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -761,7 +817,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>CtaMayor</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
@@ -778,6 +833,7 @@
<TablixCell>
<CellContents>
<Textbox Name="CodigoNombreSAT">
<rd:DefaultName>CodigoNombreSAT</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -795,7 +851,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>CodigoNombreSAT</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
@@ -807,12 +862,12 @@
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<rd:Selected>true</rd:Selected>
</CellContents>
</TablixCell>
<TablixCell>
<CellContents>
<Textbox Name="Moneda">
<rd:DefaultName>Moneda</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -830,7 +885,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Moneda</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
@@ -847,6 +901,7 @@
<TablixCell>
<CellContents>
<Textbox Name="DigAgrup">
<rd:DefaultName>DigAgrup</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -864,7 +919,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>DigAgrup</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
@@ -881,6 +935,7 @@
<TablixCell>
<CellContents>
<Textbox Name="NomIdioma">
<rd:DefaultName>NomIdioma</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -898,7 +953,6 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>NomIdioma</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
@@ -915,6 +969,7 @@
<TablixCell>
<CellContents>
<Textbox Name="ConceptoContable">
<rd:DefaultName>ConceptoContable</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
@@ -932,7 +987,41 @@
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>ConceptoContable</rd:DefaultName>
<Style>
<Border>
<Style>None</Style>
</Border>
<BackgroundColor>=iif((RunningValue(CountDistinct(Fields!Codigo.Value), Sum, "DataSet1") mod 2) = 0, "LightSteelBlue", "White")</BackgroundColor>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
</CellContents>
</TablixCell>
<TablixCell>
<CellContents>
<rd:Selected>true</rd:Selected>
<Textbox Name="Nivel">
<rd:DefaultName>Nivel</rd:DefaultName>
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>=Fields!Nivel.Value</Value>
<Style>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style>
<TextAlign>Center</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<Style>
<Border>
<Style>None</Style>
@@ -962,6 +1051,7 @@
<TablixMember />
<TablixMember />
<TablixMember />
<TablixMember />
</TablixMembers>
</TablixColumnHierarchy>
<TablixRowHierarchy>
@@ -980,7 +1070,7 @@
<RepeatRowHeaders>true</RepeatRowHeaders>
<DataSetName>DataSet1</DataSetName>
<Height>0.98834cm</Height>
<Width>24.33862cm</Width>
<Width>29.3257cm</Width>
<Style>
<Border>
<Style>None</Style>
@@ -991,7 +1081,7 @@
<Height>0.38911in</Height>
<Style />
</Body>
<Width>9.58214in</Width>
<Width>11.54555in</Width>
<Page>
<PageHeight>21.59cm</PageHeight>
<PageWidth>27.94cm</PageWidth>
@@ -1018,7 +1108,7 @@
<Prompt>ReportParameter1</Prompt>
</ReportParameter>
</ReportParameters>
<rd:ReportUnitType>Cm</rd:ReportUnitType>
<rd:ReportID>2ec96151-d7c1-4609-bfdd-795b02d33b5a</rd:ReportID>
</Report>

View File

@@ -1550,11 +1550,59 @@
<asp:GridView ID="gvRecuperacionPorSucursal" runat="server"
CssClass="adssigrid-scroll adssigrid-order table table-hover table-light custom-grid"
AutoGenerateColumns="false"
Width="100%">
Width="100%"
OnRowCreated="gvRecuperacionPorSucursal_RowCreated">
<Columns>
<asp:BoundField DataField="Sucursal" HeaderText="Sucursal" />
<asp:BoundField DataField="Recuperado" HeaderText="Recuperado" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="PromedioDiasRecuperacion" HeaderText="Avg. Días Recuperación" DataFormatString="{0:N1}" ItemStyle-HorizontalAlign="Right" />
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; align-items: center;">
<span>Sucursal</span>
<asp:HyperLink ID="HypGraficaHeader" runat="server" CssClass="pull-right"
NavigateUrl='<%# "javascript:generarGrafica(\""" & Me.gvRecuperacionPorSucursal.ClientID & "\"");" %>'>
<i class="fa fa-bar-chart"></i>
</asp:HyperLink>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblSucursal" runat="server" Text='<%# Bind("Sucursal") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Recuperado</span>
<div>
<asp:CheckBox ID="chkRecuperado" runat="server" CssClass="header-checkbox"
data-field="Recuperado" />
<label for="chkRecuperado">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblRecuperado" runat="server"
Text='<%# Bind("Recuperado", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Avg. Días Recuperación</span>
<div>
<asp:CheckBox ID="chkDiasRecuperado" runat="server" CssClass="header-checkbox"
data-field="PromedioDiasRecuperacion" />
<label for="chkDiasRecuperado">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblDiasRecuperado" runat="server"
Text='<%# Bind("PromedioDiasRecuperacion", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>
@@ -1572,11 +1620,59 @@
<asp:GridView ID="gvRecuperacionPorCliente" runat="server"
CssClass="adssigrid-scroll adssigrid-order table table-hover table-light custom-grid"
AutoGenerateColumns="false"
Width="100%">
Width="100%"
OnRowCreated="gvRecuperacionPorCliente_RowCreated">
<Columns>
<asp:BoundField DataField="Cliente" HeaderText="Cliente" />
<asp:BoundField DataField="Recuperado" HeaderText="Recuperado" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="PromedioDiasRecuperacion" HeaderText="Avg. Días Recuperación" DataFormatString="{0:N1}" ItemStyle-HorizontalAlign="Right" />
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; align-items: center;">
<span>Cliente</span>
<asp:HyperLink ID="HypGraficaHeader" runat="server" CssClass="pull-right"
NavigateUrl='<%# "javascript:generarGrafica(\""" & Me.gvRecuperacionPorCliente.ClientID & "\"");" %>'>
<i class="fa fa-bar-chart"></i>
</asp:HyperLink>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblCliente" runat="server" Text='<%# Bind("Cliente") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Recuperado</span>
<div>
<asp:CheckBox ID="chkRecuperado" runat="server" CssClass="header-checkbox"
data-field="Recuperado" />
<label for="chkRecuperado">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblRecuperado" runat="server"
Text='<%# Bind("Recuperado", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Avg. Días Recuperación</span>
<div>
<asp:CheckBox ID="chkDiasRecuperado" runat="server" CssClass="header-checkbox"
data-field="PromedioDiasRecuperacion" />
<label for="chkDiasRecuperado">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblDiasRecuperado" runat="server"
Text='<%# Bind("PromedioDiasRecuperacion", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>
@@ -1601,13 +1697,95 @@
<asp:GridView ID="gvComprasPorClasificacion" runat="server"
CssClass="adssigrid-scroll adssigrid-order table table-hover table-light custom-grid"
AutoGenerateColumns="false"
Width="100%">
Width="100%"
OnRowCreated="gvComprasPorClasificacion_RowCreated">
<Columns>
<asp:BoundField DataField="Clasificacion" HeaderText="Clasificación" />
<asp:BoundField DataField="Año" HeaderText="Año" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="Mes" HeaderText="Mes" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="Semana" HeaderText="Semana" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="Dia" HeaderText="Día" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; align-items: center;">
<span>Clasificación</span>
<asp:HyperLink ID="HypGraficaHeader" runat="server" CssClass="pull-right"
NavigateUrl='<%# "javascript:generarGrafica(\""" & Me.gvComprasPorClasificacion.ClientID & "\"");" %>'>
<i class="fa fa-bar-chart"></i>
</asp:HyperLink>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblClasificacion" runat="server" Text='<%# Bind("Clasificacion") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Año</span>
<div>
<asp:CheckBox ID="chkAño" runat="server" CssClass="header-checkbox"
data-field="Año" />
<label for="chkAño">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblAño" runat="server"
Text='<%# Bind("Año", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Mes</span>
<div>
<asp:CheckBox ID="chkMes" runat="server" CssClass="header-checkbox"
data-field="Mes" />
<label for="chkMes">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblMes" runat="server"
Text='<%# Bind("Mes", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Semana</span>
<div>
<asp:CheckBox ID="chkSemana" runat="server" CssClass="header-checkbox"
data-field="Semana" />
<label for="chkSemana">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblSemana" runat="server"
Text='<%# Bind("Semana", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Día</span>
<div>
<asp:CheckBox ID="chkDia" runat="server" CssClass="header-checkbox"
data-field="Dia" />
<label for="chkDia">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblDia" runat="server"
Text='<%# Bind("Dia", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>
@@ -1625,13 +1803,95 @@
<asp:GridView ID="gvComprasPorMarca" runat="server"
CssClass="adssigrid-scroll adssigrid-order table table-hover table-light custom-grid"
AutoGenerateColumns="false"
Width="100%">
Width="100%"
OnRowCreated="gvComprasPorMarca_RowCreated">
<Columns>
<asp:BoundField DataField="Marca" HeaderText="Marca" />
<asp:BoundField DataField="Año" HeaderText="Año" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="Mes" HeaderText="Mes" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="Semana" HeaderText="Semana" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="Dia" HeaderText="Día" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; align-items: center;">
<span>Marca</span>
<asp:HyperLink ID="HypGraficaHeader" runat="server" CssClass="pull-right"
NavigateUrl='<%# "javascript:generarGrafica(\""" & Me.gvComprasPorMarca.ClientID & "\"");" %>'>
<i class="fa fa-bar-chart"></i>
</asp:HyperLink>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblMarca" runat="server" Text='<%# Bind("Marca") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Año</span>
<div>
<asp:CheckBox ID="chkAño" runat="server" CssClass="header-checkbox"
data-field="Año" />
<label for="chkAño">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblAño" runat="server"
Text='<%# Bind("Año", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Mes</span>
<div>
<asp:CheckBox ID="chkMes" runat="server" CssClass="header-checkbox"
data-field="Mes" />
<label for="chkMes">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblMes" runat="server"
Text='<%# Bind("Mes", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Semana</span>
<div>
<asp:CheckBox ID="chkSemana" runat="server" CssClass="header-checkbox"
data-field="Semana" />
<label for="chkSemana">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblSemana" runat="server"
Text='<%# Bind("Semana", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Día</span>
<div>
<asp:CheckBox ID="chkDia" runat="server" CssClass="header-checkbox"
data-field="Dia" />
<label for="chkDia">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblDia" runat="server"
Text='<%# Bind("Dia", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>
@@ -1652,13 +1912,95 @@
<asp:GridView ID="gvComprasPorPS" runat="server"
CssClass="adssigrid-scroll adssigrid-order table table-hover table-light custom-grid"
AutoGenerateColumns="false"
Width="100%">
Width="100%"
OnRowCreated="gvComprasPorPS_RowCreated">
<Columns>
<asp:BoundField DataField="ProductoServicio" HeaderText="PS" />
<asp:BoundField DataField="Año" HeaderText="Año" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="Mes" HeaderText="Mes" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="Semana" HeaderText="Semana" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="Dia" HeaderText="Día" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; align-items: center;">
<span>PS</span>
<asp:HyperLink ID="HypGraficaHeader" runat="server" CssClass="pull-right"
NavigateUrl='<%# "javascript:generarGrafica(\""" & Me.gvComprasPorPS.ClientID & "\"");" %>'>
<i class="fa fa-bar-chart"></i>
</asp:HyperLink>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblPS" runat="server" Text='<%# Bind("ProductoServicio") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Año</span>
<div>
<asp:CheckBox ID="chkAño" runat="server" CssClass="header-checkbox"
data-field="Año" />
<label for="chkAño">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblAño" runat="server"
Text='<%# Bind("Año", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Mes</span>
<div>
<asp:CheckBox ID="chkMes" runat="server" CssClass="header-checkbox"
data-field="Mes" />
<label for="chkMes">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblMes" runat="server"
Text='<%# Bind("Mes", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Semana</span>
<div>
<asp:CheckBox ID="chkSemana" runat="server" CssClass="header-checkbox"
data-field="Semana" />
<label for="chkSemana">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblSemana" runat="server"
Text='<%# Bind("Semana", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Día</span>
<div>
<asp:CheckBox ID="chkDia" runat="server" CssClass="header-checkbox"
data-field="Dia" />
<label for="chkDia">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblDia" runat="server"
Text='<%# Bind("Dia", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>
@@ -1676,13 +2018,95 @@
<asp:GridView ID="gvComprasPorProveedor" runat="server"
CssClass="adssigrid-scroll adssigrid-order table table-hover table-light custom-grid"
AutoGenerateColumns="false"
Width="100%">
Width="100%"
OnRowCreated="gvComprasPorProveedor_RowCreated">
<Columns>
<asp:BoundField DataField="NombreProveedor" HeaderText="Proveedor" />
<asp:BoundField DataField="Año" HeaderText="Año" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="Mes" HeaderText="Mes" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="Semana" HeaderText="Semana" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="Dia" HeaderText="Día" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; align-items: center;">
<span>Proveedor</span>
<asp:HyperLink ID="HypGraficaHeader" runat="server" CssClass="pull-right"
NavigateUrl='<%# "javascript:generarGrafica(\""" & Me.gvComprasPorProveedor.ClientID & "\"");" %>'>
<i class="fa fa-bar-chart"></i>
</asp:HyperLink>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblPS" runat="server" Text='<%# Bind("NombreProveedor") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Año</span>
<div>
<asp:CheckBox ID="chkAño" runat="server" CssClass="header-checkbox"
data-field="Año" />
<label for="chkAño">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblAño" runat="server"
Text='<%# Bind("Año", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Mes</span>
<div>
<asp:CheckBox ID="chkMes" runat="server" CssClass="header-checkbox"
data-field="Mes" />
<label for="chkMes">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblMes" runat="server"
Text='<%# Bind("Mes", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Semana</span>
<div>
<asp:CheckBox ID="chkSemana" runat="server" CssClass="header-checkbox"
data-field="Semana" />
<label for="chkSemana">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblSemana" runat="server"
Text='<%# Bind("Semana", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Día</span>
<div>
<asp:CheckBox ID="chkDia" runat="server" CssClass="header-checkbox"
data-field="Dia" />
<label for="chkDia">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblDia" runat="server"
Text='<%# Bind("Dia", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>
@@ -1725,12 +2149,75 @@
<asp:GridView ID="gvCxPPorSucursal" runat="server"
CssClass="adssigrid-scroll adssigrid-order table table-hover table-light custom-grid"
AutoGenerateColumns="false"
Width="100%">
Width="100%"
OnRowCreated="gvCxPPorSucursal_RowCreated">
<Columns>
<asp:BoundField DataField="Sucursal" HeaderText="Sucursal" />
<asp:BoundField DataField="Vencido" HeaderText="Vencido" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="PorVencer" HeaderText="Por Vencer" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="Total" HeaderText="Total CxP" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; align-items: center;">
<span>Sucursal</span>
<asp:HyperLink ID="HypGraficaHeader" runat="server" CssClass="pull-right"
NavigateUrl='<%# "javascript:generarGrafica(\""" & Me.gvCxPPorSucursal.ClientID & "\"");" %>'>
<i class="fa fa-bar-chart"></i>
</asp:HyperLink>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblSucursal" runat="server" Text='<%# Bind("Sucursal") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Vencido</span>
<div>
<asp:CheckBox ID="chkVencido" runat="server" CssClass="header-checkbox"
data-field="Vencido" />
<label for="chkVencido">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblVencido" runat="server"
Text='<%# Bind("Vencido", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Por Vencer</span>
<div>
<asp:CheckBox ID="chkPorVencer" runat="server" CssClass="header-checkbox"
data-field="PorVencer" />
<label for="chkPorVencer">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblPorVencer" runat="server"
Text='<%# Bind("PorVencer", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Total CxP</span>
<div>
<asp:CheckBox ID="chkTotalCxC" runat="server" CssClass="header-checkbox"
data-field="Total" />
<label for="chkTotalCxC">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblTotal" runat="server"
Text='<%# Bind("Total", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>
@@ -1748,12 +2235,75 @@
<asp:GridView ID="gvCxPPorProveedor" runat="server"
CssClass="adssigrid-scroll adssigrid-order table table-hover table-light custom-grid"
AutoGenerateColumns="false"
Width="100%">
Width="100%"
OnRowCreated="gvCxPPorProveedor_RowCreated">
<Columns>
<asp:BoundField DataField="RazonSocial" HeaderText="Proveedor" />
<asp:BoundField DataField="Vencido" HeaderText="Vencido" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="PorVencer" HeaderText="Por Vencer" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="Total" HeaderText="Total CxP" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; align-items: center;">
<span>Proveedor</span>
<asp:HyperLink ID="HypGraficaHeader" runat="server" CssClass="pull-right"
NavigateUrl='<%# "javascript:generarGrafica(\""" & Me.gvCxPPorProveedor.ClientID & "\"");" %>'>
<i class="fa fa-bar-chart"></i>
</asp:HyperLink>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblProveedor" runat="server" Text='<%# Bind("RazonSocial") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Vencido</span>
<div>
<asp:CheckBox ID="chkVencido" runat="server" CssClass="header-checkbox"
data-field="Vencido" />
<label for="chkVencido">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblVencido" runat="server"
Text='<%# Bind("Vencido", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Por Vencer</span>
<div>
<asp:CheckBox ID="chkPorVencer" runat="server" CssClass="header-checkbox"
data-field="PorVencer" />
<label for="chkPorVencer">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblPorVencer" runat="server"
Text='<%# Bind("PorVencer", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Total CxP</span>
<div>
<asp:CheckBox ID="chkTotalCxP" runat="server" CssClass="header-checkbox"
data-field="Total" />
<label for="chkTotalCxP">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblTotal" runat="server"
Text='<%# Bind("Total", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>
@@ -1774,11 +2324,59 @@
<asp:GridView ID="gvPagosPorSucursal" runat="server"
CssClass="adssigrid-scroll adssigrid-order table table-hover table-light custom-grid"
AutoGenerateColumns="false"
Width="100%">
Width="100%"
OnRowCreated="gvPagosPorSucursal_RowCreated">
<Columns>
<asp:BoundField DataField="Sucursal" HeaderText="Sucursal" />
<asp:BoundField DataField="Recuperado" HeaderText="Pagado" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="PromedioDias" HeaderText="Avg. Días" DataFormatString="{0:N1}" ItemStyle-HorizontalAlign="Right" />
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; align-items: center;">
<span>Sucursal</span>
<asp:HyperLink ID="HypGraficaHeader" runat="server" CssClass="pull-right"
NavigateUrl='<%# "javascript:generarGrafica(\""" & Me.gvPagosPorSucursal.ClientID & "\"");" %>'>
<i class="fa fa-bar-chart"></i>
</asp:HyperLink>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblSucursal" runat="server" Text='<%# Bind("Sucursal") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Pagado</span>
<div>
<asp:CheckBox ID="chkRecuperado" runat="server" CssClass="header-checkbox"
data-field="Recuperado" />
<label for="chkRecuperado">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblRecuperado" runat="server"
Text='<%# Bind("Recuperado", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Avg. Días</span>
<div>
<asp:CheckBox ID="chkDiasRecuperado" runat="server" CssClass="header-checkbox"
data-field="PromedioDiasRecuperacion" />
<label for="chkDiasRecuperado">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblDiasRecuperado" runat="server"
Text='<%# Bind("PromedioDias", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>
@@ -1796,11 +2394,59 @@
<asp:GridView ID="gvPagosPorProveedor" runat="server"
CssClass="adssigrid-scroll adssigrid-order table table-hover table-light custom-grid"
AutoGenerateColumns="false"
Width="100%">
Width="100%"
OnRowCreated="gvPagosPorProveedor_RowCreated">
<Columns>
<asp:BoundField DataField="RazonSocial" HeaderText="Proveedor" />
<asp:BoundField DataField="Recuperado" HeaderText="Pagado" DataFormatString="{0:N2}" ItemStyle-HorizontalAlign="Right" />
<asp:BoundField DataField="PromedioDias" HeaderText="Avg. Días" DataFormatString="{0:N1}" ItemStyle-HorizontalAlign="Right" />
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; align-items: center;">
<span>Proveedor</span>
<asp:HyperLink ID="HypGraficaHeader" runat="server" CssClass="pull-right"
NavigateUrl='<%# "javascript:generarGrafica(\""" & Me.gvPagosPorProveedor.ClientID & "\"");" %>'>
<i class="fa fa-bar-chart"></i>
</asp:HyperLink>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblProveedor" runat="server" Text='<%# Bind("RazonSocial") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Recuperado</span>
<div>
<asp:CheckBox ID="chkRecuperado" runat="server" CssClass="header-checkbox"
data-field="Recuperado" />
<label for="chkRecuperado">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblRecuperado" runat="server"
Text='<%# Bind("Recuperado", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<HeaderTemplate>
<div style="display: flex; flex-direction: column; align-items: center;">
<span>Avg. Días</span>
<div>
<asp:CheckBox ID="chkDiasRecuperado" runat="server" CssClass="header-checkbox"
data-field="PromedioDiasRecuperacion" />
<label for="chkDiasRecuperado">Graficar</label>
</div>
</div>
</HeaderTemplate>
<ItemTemplate>
<asp:Label ID="lblDiasRecuperado" runat="server"
Text='<%# Bind("PromedioDias", "{0:N2}") %>'></asp:Label>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</div>

View File

@@ -758,6 +758,378 @@ Partial Class General_Dashboard
End If
End Sub
Protected Sub gvRecuperacionPorSucursal_RowCreated(sender As Object, e As GridViewRowEventArgs)
If e.Row.RowType = DataControlRowType.Header Then
e.Row.Cells.Clear()
Dim grid As GridView = DirectCast(sender, GridView)
' --- Fila 1 ---
Dim headerRow1 As New GridViewRow(0, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Celda principal (Sucursal)
Dim cellSucursal As New TableHeaderCell()
cellSucursal.RowSpan = 2
cellSucursal.VerticalAlign = VerticalAlign.Middle
cellSucursal.Controls.Add(New LiteralControl("<span>Sucursal</span>&nbsp;"))
Dim hypGrafica As New HyperLink()
hypGrafica.NavigateUrl = "javascript:void(0);"
hypGrafica.Attributes.Add("onclick", "return generarGrafica('" & grid.ClientID & "');")
hypGrafica.CssClass = "grafica-icon"
hypGrafica.Controls.Add(New LiteralControl("<i class='fa fa-bar-chart'></i>"))
cellSucursal.Controls.Add(hypGrafica)
headerRow1.Cells.Add(cellSucursal)
headerRow1.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(0, headerRow1)
' --- Fila 2 (Subheaders) ---
Dim headerRow2 As New GridViewRow(1, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Subheaders con checkboxes
headerRow2.Cells.Add(CreateSubHeaderCell("Recuperado", "chkRecuperado", "Recuperado"))
headerRow2.Cells.Add(CreateSubHeaderCell("PromedioDiasRecuperacion", "chkDiasRecuperado", "Avg. Días Recuperación"))
headerRow2.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(1, headerRow2)
End If
End Sub
Protected Sub gvRecuperacionPorCliente_RowCreated(sender As Object, e As GridViewRowEventArgs)
If e.Row.RowType = DataControlRowType.Header Then
e.Row.Cells.Clear()
Dim grid As GridView = DirectCast(sender, GridView)
' --- Fila 1 ---
Dim headerRow1 As New GridViewRow(0, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Celda principal (Sucursal)
Dim cellSucursal As New TableHeaderCell()
cellSucursal.RowSpan = 2
cellSucursal.VerticalAlign = VerticalAlign.Middle
cellSucursal.Controls.Add(New LiteralControl("<span>Cliente</span>&nbsp;"))
Dim hypGrafica As New HyperLink()
hypGrafica.NavigateUrl = "javascript:void(0);"
hypGrafica.Attributes.Add("onclick", "return generarGrafica('" & grid.ClientID & "');")
hypGrafica.CssClass = "grafica-icon"
hypGrafica.Controls.Add(New LiteralControl("<i class='fa fa-bar-chart'></i>"))
cellSucursal.Controls.Add(hypGrafica)
headerRow1.Cells.Add(cellSucursal)
headerRow1.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(0, headerRow1)
' --- Fila 2 (Subheaders) ---
Dim headerRow2 As New GridViewRow(1, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Subheaders con checkboxes
headerRow2.Cells.Add(CreateSubHeaderCell("Recuperado", "chkRecuperado", "Recuperado"))
headerRow2.Cells.Add(CreateSubHeaderCell("PromedioDiasRecuperacion", "chkDiasRecuperado", "Avg. Días Recuperación"))
headerRow2.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(1, headerRow2)
End If
End Sub
Protected Sub gvComprasPorClasificacion_RowCreated(sender As Object, e As GridViewRowEventArgs)
If e.Row.RowType = DataControlRowType.Header Then
e.Row.Cells.Clear()
Dim grid As GridView = DirectCast(sender, GridView)
' --- Fila 1 ---
Dim headerRow1 As New GridViewRow(0, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Celda principal (Sucursal)
Dim cellSucursal As New TableHeaderCell()
cellSucursal.RowSpan = 2
cellSucursal.VerticalAlign = VerticalAlign.Middle
cellSucursal.Controls.Add(New LiteralControl("<span>Clasificación</span>&nbsp;"))
Dim hypGrafica As New HyperLink()
hypGrafica.NavigateUrl = "javascript:void(0);"
hypGrafica.Attributes.Add("onclick", "return generarGrafica('" & grid.ClientID & "');")
hypGrafica.CssClass = "grafica-icon"
hypGrafica.Controls.Add(New LiteralControl("<i class='fa fa-bar-chart'></i>"))
cellSucursal.Controls.Add(hypGrafica)
headerRow1.Cells.Add(cellSucursal)
headerRow1.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(0, headerRow1)
' --- Fila 2 (Subheaders) ---
Dim headerRow2 As New GridViewRow(1, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Subheaders con checkboxes
headerRow2.Cells.Add(CreateSubHeaderCell("Año", "chkAño", "Año"))
headerRow2.Cells.Add(CreateSubHeaderCell("Mes", "chkMes", "Mes"))
headerRow2.Cells.Add(CreateSubHeaderCell("Semana", "chkSemana", "Semana"))
headerRow2.Cells.Add(CreateSubHeaderCell("Dia", "chkDia", "Dia"))
headerRow2.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(1, headerRow2)
End If
End Sub
Protected Sub gvComprasPorMarca_RowCreated(sender As Object, e As GridViewRowEventArgs)
If e.Row.RowType = DataControlRowType.Header Then
e.Row.Cells.Clear()
Dim grid As GridView = DirectCast(sender, GridView)
' --- Fila 1 ---
Dim headerRow1 As New GridViewRow(0, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Celda principal (Sucursal)
Dim cellSucursal As New TableHeaderCell()
cellSucursal.RowSpan = 2
cellSucursal.VerticalAlign = VerticalAlign.Middle
cellSucursal.Controls.Add(New LiteralControl("<span>Marca</span>&nbsp;"))
Dim hypGrafica As New HyperLink()
hypGrafica.NavigateUrl = "javascript:void(0);"
hypGrafica.Attributes.Add("onclick", "return generarGrafica('" & grid.ClientID & "');")
hypGrafica.CssClass = "grafica-icon"
hypGrafica.Controls.Add(New LiteralControl("<i class='fa fa-bar-chart'></i>"))
cellSucursal.Controls.Add(hypGrafica)
headerRow1.Cells.Add(cellSucursal)
headerRow1.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(0, headerRow1)
' --- Fila 2 (Subheaders) ---
Dim headerRow2 As New GridViewRow(1, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Subheaders con checkboxes
headerRow2.Cells.Add(CreateSubHeaderCell("Año", "chkAño", "Año"))
headerRow2.Cells.Add(CreateSubHeaderCell("Mes", "chkMes", "Mes"))
headerRow2.Cells.Add(CreateSubHeaderCell("Semana", "chkSemana", "Semana"))
headerRow2.Cells.Add(CreateSubHeaderCell("Dia", "chkDia", "Dia"))
headerRow2.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(1, headerRow2)
End If
End Sub
Protected Sub gvComprasPorPS_RowCreated(sender As Object, e As GridViewRowEventArgs)
If e.Row.RowType = DataControlRowType.Header Then
e.Row.Cells.Clear()
Dim grid As GridView = DirectCast(sender, GridView)
' --- Fila 1 ---
Dim headerRow1 As New GridViewRow(0, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Celda principal (Sucursal)
Dim cellSucursal As New TableHeaderCell()
cellSucursal.RowSpan = 2
cellSucursal.VerticalAlign = VerticalAlign.Middle
cellSucursal.Controls.Add(New LiteralControl("<span>PS</span>&nbsp;"))
Dim hypGrafica As New HyperLink()
hypGrafica.NavigateUrl = "javascript:void(0);"
hypGrafica.Attributes.Add("onclick", "return generarGrafica('" & grid.ClientID & "');")
hypGrafica.CssClass = "grafica-icon"
hypGrafica.Controls.Add(New LiteralControl("<i class='fa fa-bar-chart'></i>"))
cellSucursal.Controls.Add(hypGrafica)
headerRow1.Cells.Add(cellSucursal)
headerRow1.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(0, headerRow1)
' --- Fila 2 (Subheaders) ---
Dim headerRow2 As New GridViewRow(1, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Subheaders con checkboxes
headerRow2.Cells.Add(CreateSubHeaderCell("Año", "chkAño", "Año"))
headerRow2.Cells.Add(CreateSubHeaderCell("Mes", "chkMes", "Mes"))
headerRow2.Cells.Add(CreateSubHeaderCell("Semana", "chkSemana", "Semana"))
headerRow2.Cells.Add(CreateSubHeaderCell("Dia", "chkDia", "Dia"))
headerRow2.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(1, headerRow2)
End If
End Sub
Protected Sub gvComprasPorProveedor_RowCreated(sender As Object, e As GridViewRowEventArgs)
If e.Row.RowType = DataControlRowType.Header Then
e.Row.Cells.Clear()
Dim grid As GridView = DirectCast(sender, GridView)
' --- Fila 1 ---
Dim headerRow1 As New GridViewRow(0, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Celda principal (Sucursal)
Dim cellSucursal As New TableHeaderCell()
cellSucursal.RowSpan = 2
cellSucursal.VerticalAlign = VerticalAlign.Middle
cellSucursal.Controls.Add(New LiteralControl("<span>Proveedor</span>&nbsp;"))
Dim hypGrafica As New HyperLink()
hypGrafica.NavigateUrl = "javascript:void(0);"
hypGrafica.Attributes.Add("onclick", "return generarGrafica('" & grid.ClientID & "');")
hypGrafica.CssClass = "grafica-icon"
hypGrafica.Controls.Add(New LiteralControl("<i class='fa fa-bar-chart'></i>"))
cellSucursal.Controls.Add(hypGrafica)
headerRow1.Cells.Add(cellSucursal)
headerRow1.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(0, headerRow1)
' --- Fila 2 (Subheaders) ---
Dim headerRow2 As New GridViewRow(1, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Subheaders con checkboxes
headerRow2.Cells.Add(CreateSubHeaderCell("Año", "chkAño", "Año"))
headerRow2.Cells.Add(CreateSubHeaderCell("Mes", "chkMes", "Mes"))
headerRow2.Cells.Add(CreateSubHeaderCell("Semana", "chkSemana", "Semana"))
headerRow2.Cells.Add(CreateSubHeaderCell("Dia", "chkDia", "Dia"))
headerRow2.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(1, headerRow2)
End If
End Sub
Protected Sub gvCxPPorSucursal_RowCreated(sender As Object, e As GridViewRowEventArgs)
If e.Row.RowType = DataControlRowType.Header Then
e.Row.Cells.Clear()
Dim grid As GridView = DirectCast(sender, GridView)
' --- Fila 1 ---
Dim headerRow1 As New GridViewRow(0, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Celda principal (Sucursal)
Dim cellSucursal As New TableHeaderCell()
cellSucursal.RowSpan = 2
cellSucursal.VerticalAlign = VerticalAlign.Middle
cellSucursal.Controls.Add(New LiteralControl("<span>Sucursal</span>&nbsp;"))
Dim hypGrafica As New HyperLink()
hypGrafica.NavigateUrl = "javascript:void(0);"
hypGrafica.Attributes.Add("onclick", "return generarGrafica('" & grid.ClientID & "');")
hypGrafica.CssClass = "grafica-icon"
hypGrafica.Controls.Add(New LiteralControl("<i class='fa fa-bar-chart'></i>"))
cellSucursal.Controls.Add(hypGrafica)
headerRow1.Cells.Add(cellSucursal)
headerRow1.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(0, headerRow1)
' --- Fila 2 (Subheaders) ---
Dim headerRow2 As New GridViewRow(1, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Subheaders con checkboxes
headerRow2.Cells.Add(CreateSubHeaderCell("Vencido", "chkVencido", "Vencido"))
headerRow2.Cells.Add(CreateSubHeaderCell("Por Vencer", "chkPorVencer", "PorVencer"))
headerRow2.Cells.Add(CreateSubHeaderCell("Total", "chkTotalCxC", "Total CxP"))
headerRow2.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(1, headerRow2)
End If
End Sub
Protected Sub gvCxPPorProveedor_RowCreated(sender As Object, e As GridViewRowEventArgs)
If e.Row.RowType = DataControlRowType.Header Then
e.Row.Cells.Clear()
Dim grid As GridView = DirectCast(sender, GridView)
' --- Fila 1 ---
Dim headerRow1 As New GridViewRow(0, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Celda principal (Sucursal)
Dim cellSucursal As New TableHeaderCell()
cellSucursal.RowSpan = 2
cellSucursal.VerticalAlign = VerticalAlign.Middle
cellSucursal.Controls.Add(New LiteralControl("<span>Proveedor</span>&nbsp;"))
Dim hypGrafica As New HyperLink()
hypGrafica.NavigateUrl = "javascript:void(0);"
hypGrafica.Attributes.Add("onclick", "return generarGrafica('" & grid.ClientID & "');")
hypGrafica.CssClass = "grafica-icon"
hypGrafica.Controls.Add(New LiteralControl("<i class='fa fa-bar-chart'></i>"))
cellSucursal.Controls.Add(hypGrafica)
headerRow1.Cells.Add(cellSucursal)
headerRow1.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(0, headerRow1)
' --- Fila 2 (Subheaders) ---
Dim headerRow2 As New GridViewRow(1, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Subheaders con checkboxes
headerRow2.Cells.Add(CreateSubHeaderCell("Vencido", "chkVencido", "Vencido"))
headerRow2.Cells.Add(CreateSubHeaderCell("Por Vencer", "chkPorVencer", "PorVencer"))
headerRow2.Cells.Add(CreateSubHeaderCell("Total", "chkTotalCxP", "Total CxP"))
headerRow2.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(1, headerRow2)
End If
End Sub
Protected Sub gvPagosPorSucursal_RowCreated(sender As Object, e As GridViewRowEventArgs)
If e.Row.RowType = DataControlRowType.Header Then
e.Row.Cells.Clear()
Dim grid As GridView = DirectCast(sender, GridView)
' --- Fila 1 ---
Dim headerRow1 As New GridViewRow(0, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Celda principal (Sucursal)
Dim cellSucursal As New TableHeaderCell()
cellSucursal.RowSpan = 2
cellSucursal.VerticalAlign = VerticalAlign.Middle
cellSucursal.Controls.Add(New LiteralControl("<span>Sucursal</span>&nbsp;"))
Dim hypGrafica As New HyperLink()
hypGrafica.NavigateUrl = "javascript:void(0);"
hypGrafica.Attributes.Add("onclick", "return generarGrafica('" & grid.ClientID & "');")
hypGrafica.CssClass = "grafica-icon"
hypGrafica.Controls.Add(New LiteralControl("<i class='fa fa-bar-chart'></i>"))
cellSucursal.Controls.Add(hypGrafica)
headerRow1.Cells.Add(cellSucursal)
headerRow1.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(0, headerRow1)
' --- Fila 2 (Subheaders) ---
Dim headerRow2 As New GridViewRow(1, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Subheaders con checkboxes
headerRow2.Cells.Add(CreateSubHeaderCell("Recuperado", "chkRecuperado", "Pagado"))
headerRow2.Cells.Add(CreateSubHeaderCell("PromedioDias", "chkDiasRecuperado", "Avg. Días"))
headerRow2.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(1, headerRow2)
End If
End Sub
Protected Sub gvPagosPorProveedor_RowCreated(sender As Object, e As GridViewRowEventArgs)
If e.Row.RowType = DataControlRowType.Header Then
e.Row.Cells.Clear()
Dim grid As GridView = DirectCast(sender, GridView)
' --- Fila 1 ---
Dim headerRow1 As New GridViewRow(0, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Celda principal (Sucursal)
Dim cellSucursal As New TableHeaderCell()
cellSucursal.RowSpan = 2
cellSucursal.VerticalAlign = VerticalAlign.Middle
cellSucursal.Controls.Add(New LiteralControl("<span>Proveedor</span>&nbsp;"))
Dim hypGrafica As New HyperLink()
hypGrafica.NavigateUrl = "javascript:void(0);"
hypGrafica.Attributes.Add("onclick", "return generarGrafica('" & grid.ClientID & "');")
hypGrafica.CssClass = "grafica-icon"
hypGrafica.Controls.Add(New LiteralControl("<i class='fa fa-bar-chart'></i>"))
cellSucursal.Controls.Add(hypGrafica)
headerRow1.Cells.Add(cellSucursal)
headerRow1.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(0, headerRow1)
' --- Fila 2 (Subheaders) ---
Dim headerRow2 As New GridViewRow(1, 0, DataControlRowType.Header, DataControlRowState.Normal)
' Subheaders con checkboxes
headerRow2.Cells.Add(CreateSubHeaderCell("Recuperado", "chkRecuperado", "Recuperado"))
headerRow2.Cells.Add(CreateSubHeaderCell("PromedioDias", "chkDiasRecuperado", "Avg. Días"))
headerRow2.TableSection = TableRowSection.TableHeader
grid.Controls(0).Controls.AddAt(1, headerRow2)
End If
End Sub
''' <summary>
''' Ahora emitimos HTML puro para el checkbox + label,
''' así el label realmente dispara el toggle del input.

View File

@@ -1036,6 +1036,7 @@
<li>{"Sucursal"}</li>
<li>{"DescripcionVenta"}</li>
<li>{"AtencionA"}</li>
<li>{"CodigoCliente"}</li>
</ul>
</div>
<br />

View File

@@ -1435,6 +1435,7 @@
<li>{"RazonSocialReceptor"}</li>
<li>{"Vigencia"}</li>
<li>{"AtencionA"}</li>
<li>{"CodigoCliente"}</li>
</ul>
</div>
<br />

View File

@@ -2569,7 +2569,7 @@
<div class="portlet-body ">
<asp:UpdatePanel ID="UpCuentasBancos" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<asp:GridView ID="GvBancosCuentas" GridLines="None" BorderColor="#D3D3D3" CssClass="table table-striped table-hover Widthall ScrollAD mysmallbtn" data-sort="true" runat="server" DataKeyNames="CveCuentaDeposito,BancoNombre,Sucursal,Cuenta,CLABE,SWIFT,Plaza,CIE,Referencia,CveMoneda,Estatus" AutoGenerateColumns="False" EmptyDataText="No se encontraron registros" ToolTip="Listado de Cuentas Bancarias">
<asp:GridView ID="GvBancosCuentas" GridLines="None" BorderColor="#D3D3D3" CssClass="table table-striped table-hover Widthall ScrollAD mysmallbtn" data-sort="true" runat="server" DataKeyNames="CveCuentaDeposito,BancoNombre,Sucursal,Cuenta,CLABE,SWIFT,Plaza,CIE,Referencia,CveMoneda,Estatus,EstatusTexto" AutoGenerateColumns="False" EmptyDataText="No se encontraron registros" ToolTip="Listado de Cuentas Bancarias">
<Columns>
<asp:TemplateField ItemStyle-HorizontalAlign="Left" HeaderText="Banco" ItemStyle-CssClass="Excede">
<ItemTemplate>

View File

@@ -2302,6 +2302,7 @@ Partial Class Clientes
Cuerpo = Cuerpo.Replace("{""FechaVencimiento""}", Dr("FechaVencimiento").ToString().ToDate().ToShortDateString())
Cuerpo = Cuerpo.Replace("{""Vigencia""}", Dr("Vigencia").ToString())
Cuerpo = Cuerpo.Replace("{""AtencionA""}", Dr("AtencionA").ToString())
Cuerpo = Cuerpo.Replace("{""CodigoCliente""}", Dr("ClienteCodigo").ToString())
Cuerpo = Cuerpo.Replace("{""Sucursal""}", Dr("SubProyecto").ToString())
Cuerpo = Cuerpo.Replace("{""DescripcionVenta""}", Dr("DescripcionVenta").ToString())
End If
@@ -2324,6 +2325,7 @@ Partial Class Clientes
Asunto = Asunto.Replace("{""FechaVencimiento""}", Dr("FechaVencimiento").ToString().ToDate().ToShortDateString())
Asunto = Asunto.Replace("{""Vigencia""}", Dr("Vigencia").ToString())
Asunto = Asunto.Replace("{""AtencionA""}", Dr("AtencionA").ToString())
Asunto = Asunto.Replace("{""CodigoCliente""}", Dr("ClienteCodigo").ToString())
Asunto = Asunto.Replace("{""Sucursal""}", Dr("SubProyecto").ToString())
Asunto = Asunto.Replace("{""DescripcionVenta""}", Dr("DescripcionVenta").ToString())
@@ -2348,6 +2350,7 @@ Partial Class Clientes
Cuerpo = Cuerpo.Replace("{""FechaVencimiento""}", Dr("FechaVencimiento").ToString().ToDate().ToShortDateString())
Cuerpo = Cuerpo.Replace("{""Vigencia""}", Dr("Vigencia").ToString())
Cuerpo = Cuerpo.Replace("{""AtencionA""}", Dr("AtencionA").ToString())
Cuerpo = Cuerpo.Replace("{""CodigoCliente""}", Dr("ClienteCodigo").ToString())
Cuerpo = Cuerpo.Replace("{""Sucursal""}", Dr("SubProyecto").ToString())
Cuerpo = Cuerpo.Replace("{""DescripcionVenta""}", Dr("DescripcionVenta").ToString())
End If
@@ -2367,6 +2370,7 @@ Partial Class Clientes
Asunto = Asunto.Replace("{""FechaVencimiento""}", Dr("FechaVencimiento").ToString().ToDate().ToShortDateString())
Asunto = Asunto.Replace("{""Vigencia""}", Dr("Vigencia").ToString())
Asunto = Asunto.Replace("{""AtencionA""}", Dr("AtencionA").ToString())
Asunto = Asunto.Replace("{""CodigoCliente""}", Dr("ClienteCodigo").ToString())
Asunto = Asunto.Replace("{""Sucursal""}", Dr("SubProyecto").ToString())
Asunto = Asunto.Replace("{""DescripcionVenta""}", Dr("DescripcionVenta").ToString())
@@ -2588,6 +2592,7 @@ Partial Class Clientes
If TxtLimiteCredito.Text.ToDecimal = 0 OrElse TxtCobranzaContacto.Text.Trim = "" OrElse TxtCobranzaTelefono.Text.Trim = "" OrElse TxtDiasEspecifico.Text.Trim = "" OrElse TxtCobranzaCorreo.Text.Trim = "" Then
InformacionCompleta = False
End If
If DdlTipoPago.SelectedValue = "-1" Then InformacionCompleta = False
'si es el concepto de pagaré
tPagare = 0
For Each dRow As GridViewRow In GvDocumentosCliente.Rows
@@ -2597,18 +2602,26 @@ Partial Class Clientes
End If
Next
If tPagare = 0 Then InformacionCompleta = False
If GvClentesPersonalEntrega.Rows.Count = 0 Then InformacionCompleta = False
End If
If TxtTelefono.Text.Trim() = "" Then InformacionCompleta = False
If TxtEmail.Text.Trim() = "" Then InformacionCompleta = False
'SOLO VALIDA EN CLIENTES FRECUENTE
If DdlTipoCliente.SelectedValue = "1" Then
If GvClentesPersonalEntrega.Rows.Count = 0 Then InformacionCompleta = False
'VALIDACIONES DE BANCOS
If Not GvBancosCuentas.Rows.Cast(Of GridViewRow).Any(Function(c) c.DataKey("EstatusTexto") = "Activo") Then InformacionCompleta = False
If Not GvBancosCuentas.Rows.Cast(Of GridViewRow).Any(Function(c) c.DataKey("CLABE") <> "") Then InformacionCompleta = False
If Not GvBancosCuentas.Rows.Cast(Of GridViewRow).Any(Function(c) c.DataKey("BancoNombre") <> "") Then InformacionCompleta = False
'If Not GvBancosCuentas.Rows.Cast(Of GridViewRow).Any(Function(c) c.DataKey("Sucursal") <> "") Then InformacionCompleta = False
If Not GvBancosCuentas.Rows.Cast(Of GridViewRow).Any(Function(c) c.DataKey("Cuenta") <> "") Then InformacionCompleta = False
If TxtContacto.Text.Trim() = "" Then InformacionCompleta = False
If TxtRepresentanteLegal.Text.Trim() = "" Then InformacionCompleta = False
If DdlClasificacion.SelectedValue.ToEntero() <= 0 Then InformacionCompleta = False
End If
If TxtTelefono.Text.Trim() = "" Then InformacionCompleta = False
If TxtEmail.Text.Trim() = "" Then InformacionCompleta = False
End If
'CargaSucursal()
@@ -5900,7 +5913,7 @@ Partial Class Clientes
Cuerpo = Cuerpo.Replace("{""AtencionA""}", Dr("AtencionA").ToString())
Cuerpo = Cuerpo.Replace("{""Sucursal""}", Dr("SubProyecto").ToString())
Cuerpo = Cuerpo.Replace("{""DescripcionVenta""}", Dr("DescripcionVenta").ToString())
Cuerpo = Cuerpo.Replace("{""AtencionA""}", Dr("AtencionA").ToString())
Cuerpo = Cuerpo.Replace("{""CodigoCliente""}", Dr("ClienteCodigo").ToString())
End If
End If
@@ -5920,7 +5933,7 @@ Partial Class Clientes
Asunto = Asunto.Replace("{""AtencionA""}", Dr("AtencionA").ToString())
Asunto = Asunto.Replace("{""Sucursal""}", Dr("SubProyecto").ToString())
Asunto = Asunto.Replace("{""DescripcionVenta""}", Dr("DescripcionVenta").ToString())
Asunto = Asunto.Replace("{""AtencionA""}", Dr("AtencionA").ToString())
Asunto = Asunto.Replace("{""CodigoCliente""}", Dr("ClienteCodigo").ToString())
End If
End If
@@ -5942,7 +5955,8 @@ Partial Class Clientes
Cuerpo = Cuerpo.Replace("{""AtencionA""}", Dr("AtencionA").ToString())
Cuerpo = Cuerpo.Replace("{""Sucursal""}", Dr("SubProyecto").ToString())
Cuerpo = Cuerpo.Replace("{""DescripcionVenta""}", Dr("DescripcionVenta").ToString())
Cuerpo = Cuerpo.Replace("{""AtencionA""}", Dr("AtencionA").ToString())
Cuerpo = Cuerpo.Replace("{""CodigoCliente""}", Dr("ClienteCodigo").ToString())
End If
End If
@@ -5962,7 +5976,7 @@ Partial Class Clientes
Asunto = Asunto.Replace("{""AtencionA""}", Dr("AtencionA").ToString())
Asunto = Asunto.Replace("{""Sucursal""}", Dr("SubProyecto").ToString())
Asunto = Asunto.Replace("{""DescripcionVenta""}", Dr("DescripcionVenta").ToString())
Asunto = Asunto.Replace("{""AtencionA""}", Dr("AtencionA").ToString())
Asunto = Asunto.Replace("{""CodigoCliente""}", Dr("ClienteCodigo").ToString())
End If
End If

View File

@@ -3603,6 +3603,41 @@ Partial Class PV
End If
'VALIDA DESCUENTOS GENERALES
If UsuarioActual.Empresa.Funcionalidad(531) = "1" AndAlso DdlTipoComprobante.SelectedValue.Contiene("Rem") Then
Dim ValidoDescuentos As Boolean = True
Dim DtTamanios As DataTable = GlobalDTAcumTamaños(UsuarioActual.CveEmpresa).FiltraParametros($" CvePSCargo > 0")
For Each Row As DataRow In TmpDT.Rows
Dim CvePS As Integer = Row("CvePS").ToString().ToEntero()
Dim Cantidad As Decimal = Row("Cantidad").ToString().ToDecimal()
Dim PU As Decimal = Row("PU").ToString().ToDecimal()
Dim Descuento As Decimal = Row("Descuento").ToString().ToDecimal()
Dim EsGarantia As Boolean = ObjFactura.EsGarantia OrElse Row("Obs").ToString().Contains("Descuento por garantía")
Dim EsCargo As Boolean = DtTamanios IsNot Nothing AndAlso DtTamanios.FiltraParametros($"CvePSCargo = {CvePS}").Rows.Count = 1
If Not EsGarantia AndAlso Not EsCargo Then
Dim porcentaje = ((Descuento) / (Cantidad * PU).RoundSQL(2)) * 100D
If porcentaje > 41 Then
Alert($"El producto '{Row("CodigoPS")}' no puede tener un descuento mayor al 40%", TipoMensaje.MsgAdvertencia)
ValidoDescuentos = False
Exit For
End If
End If
Next
If Not ValidoDescuentos Then
Exit Sub
End If
End If
If ObjFactura.CveCliente > 0 Then
If TmpDT.Rows.Count > 0 Then

View File

@@ -491,7 +491,7 @@
<asp:Literal ID="LtLTipoSaldo" runat="server" Text="Total:"></asp:Literal>
</b>&nbsp;
<asp:Literal ID="LtlSaldo" runat="server" Text=""></asp:Literal>
<asp:Label ID="LtlSaldo" runat="server" Text=""></asp:Label>
&nbsp;
<b>
<asp:Literal ID="LtlMoneda" runat="server"></asp:Literal></b>
@@ -1476,9 +1476,9 @@
let totalAnt = 0;
//si es con.nc,es.el.total
let Total = ToDouble($get("C_LtlSaldo").value.replace(",", ""));
let Total = ToDouble($get("C_LtlSaldo").innerText.replace(",", ""));
let SaldoCompra = parseFloat(parseFloat($get("C_LtlSaldo").value.replace(",", "")).toFixed(2));
let SaldoCompra = parseFloat(parseFloat($get("C_LtlSaldo").innerText.replace(",", "")).toFixed(2));
if (t.checked) {
@@ -1517,7 +1517,7 @@
function FnCambiaAnt(chk, txt, saldo) {
let Total = ToDouble($get("C_LtlSaldo").value.replace(",", ""));// ToDouble($get('TxtSubTotal').value);
let Total = ToDouble($get("C_LtlSaldo").innerText.replace(",", ""));// ToDouble($get('TxtSubTotal').value);
let importeTxt = parseFloat(txt.value.replace(/,/g, ''));

View File

@@ -1402,6 +1402,8 @@ Partial Class Ventas_PVCobranza
Dim Importe = GvRow.FCTextBox(String.Format("TxtAnticipo{0}", GvRow.RowIndex)).Text.ToDecimal()
DtPagos.Rows.Add({CveFormaPagoAnt, Importe})
PagadoSinEfectivo += Importe
End If
Next
End If

View File

@@ -2868,6 +2868,7 @@ Partial Class Ventas
TmpDT.Columns("Costo").DefaultValue = 0D
TmpDT.Columns.Add("UltimoCosto", GetType(Decimal))
TmpDT.Columns("UltimoCosto").DefaultValue = 0D
If Not TmpDT.Columns.Contains("NumeroParte") Then TmpDT.Columns.Add("NumeroParte", GetType(String))
GvPS.DataSource = ObjVentas.DtResultados
GvPS.DataBind()
@@ -8422,7 +8423,8 @@ Partial Class Ventas
Dim ObjClie As New ClsClientes
If ObjClie.GetClienteInformacionCompleta(CveCliente, UsuarioActual.CveEmpresa) Then
If Not CBool(ObjClie.DtResultados.FiltroPrimeroValor("InformacionCompleta")) Then
Dim OpcionMsg As String = String.Format("El Cliente se encuentra bloqueado por la siguiente razón: <br> <br> {0}", "Información incompleta")
Dim Faltante As String = ObjClie.DtResultados.FiltroPrimeroValor("Faltante")
Dim OpcionMsg As String = String.Format("El Cliente se encuentra bloqueado por la siguiente razón: <br> <br> {0} <br><br> Falta la siguiente información: <br>{1}", "Información incompleta", Faltante)
Alert(OpcionMsg, TipoMensaje.MsgAdvertencia)
TieneBloqueoPorCreditoVencimiento = 1
End If
@@ -9171,10 +9173,16 @@ Partial Class Ventas
End If
If e.Row.DBCampo("CvePromocionDetalle").ToEntero() > 0 Then
If DtPromociones IsNot Nothing Then
Dim NombrePromo As String = DtPromociones.FiltroPrimeroValor("NombrePromocion", $"CvePromocionDetalle={e.Row.DBCampo("CvePromocionDetalle")}")
If CveVenta > 0 Then
Dim NombrePromo As String = If(TmpDT.Columns.Contains("Promocion"), e.Row.DBCampo("Promocion"), "")
e.Row.FCHtmlGenericControl("TagPromocion").Attributes.Add("title", NombrePromo)
Else
If DtPromociones IsNot Nothing Then
Dim NombrePromo As String = DtPromociones.FiltroPrimeroValor("NombrePromocion", $"CvePromocionDetalle={e.Row.DBCampo("CvePromocionDetalle")}")
e.Row.FCHtmlGenericControl("TagPromocion").Attributes.Add("title", NombrePromo)
End If
End If
End If
If DdlTipoComprobante.SelectedValue.Contiene("Cot") Then
@@ -10481,7 +10489,7 @@ Partial Class Ventas
Dim TienePermisoImportes As Boolean = UsuarioActual.TienePermisoProceso(201)
If Not EsValido Then
MensajeCosto.AppendFormat("El Producto <b>{0}</b>. No se puede vender a un precio menor de su Costo ni a un precio mayor de su rango aceptado<br/>", dr("CodigoPS").ToString())
MensajeCosto.AppendFormat("El Producto <b>{0}</b>. No se puede vender a un precio menor de su Costo.<br/>", dr("CodigoPS").ToString())
If TienePermisoImportes Then
MensajeCosto.AppendFormat("El costo del producto es: <b>{0:#,###.00}$</b> <br/>", Costo)
MensajeCosto.AppendFormat("El rango menor aceptado es: {0} <b>{1:#,###.00}$</b> <br/>", PorcentajeMinimoCostoEmpresa, CostoMenor)
@@ -11495,6 +11503,10 @@ Partial Class Ventas
DebeTimbrar = False
End If
If UsuarioActual.CveEmpresa = 188 AndAlso ObjFactura.CveSubProyecto.Contiene(12696, 12698) Then
DebeTimbrar = False
End If
If DebeTimbrar AndAlso ObjFactura.TipoDocto.Contiene("Ing", "Egs", "Ant", "Dev") Then
If UsuarioActual.Empresa.TipoFacturacion = "CFDi" AndAlso (UsuarioActual.Empresa.FacturaProduccion OrElse UsuarioActual.CveEmpresa = 1) Then
@@ -18467,9 +18479,25 @@ Partial Class Ventas
Exit Sub
End If
If UsuarioActual.CveEmpresa = 188 AndAlso DdlSubProyectoDatos.SelectedValue.ToEntero().Contiene(12696, 12698) Then
Alert("Esta factura no puede ser timbrada", TipoMensaje.MsgAdvertencia)
Exit Sub
End If
If UsuarioActual.Empresa.TipoFacturacion = "CFDi" Then
If UsuarioActual.Empresa.FacturaProduccion Then
Using ObjVta As New ClsVentas
If ObjVta.GetVenta(Me.CveVenta, UsuarioActual.CveEmpresa) Then
Dim RowVenta As DataRow = ObjVta.DtResultados.FiltroPrimero("")
If RowVenta IsNot Nothing AndAlso RowVenta("SeTimbro").ToString() = "Si" Then
Dim Liga = $"document.location.href=""/Ventas/Ventas.aspx?CveVenta={Me.CveVenta}"";"
Alert("La factura ya ha sido timbrada previamente", TipoMensaje.MsgAdvertencia, JSBtnAceptar:=Liga, ShowCloseButton:=False)
Exit Sub
End If
End If
End Using
CreaObjetosVenta()
'PARA CUANDO YA ESTA GUARDADA LA VENTA
@@ -24012,6 +24040,7 @@ Partial Class Ventas
Cuerpo = Cuerpo.Replace("{""SerieFolio""}", SerieFolio)
Cuerpo = Cuerpo.Replace("{""Vigencia""}", TxtFechaVencimientoCotizacion.Text)
Cuerpo = Cuerpo.Replace("{""AtencionA""}", TxtAtencionA.Text)
Cuerpo = Cuerpo.Replace("{""CodigoCliente""}", TxtCodigo.Text)
Cuerpo = Cuerpo.Replace("{""Sucursal""}", DdlSubProyectoDatos.SelectedItem.Text)
Cuerpo = Cuerpo.Replace("{""DescripcionVenta""}", TxtDescripcionVenta.Text)
End If
@@ -24027,6 +24056,7 @@ Partial Class Ventas
Asunto = Asunto.Replace("{""SerieFolio""}", SerieFolio)
Asunto = Asunto.Replace("{""Vigencia""}", TxtFechaVencimientoCotizacion.Text)
Asunto = Asunto.Replace("{""AtencionA""}", TxtAtencionA.Text)
Asunto = Asunto.Replace("{""CodigoCliente""}", TxtCodigo.Text)
Asunto = Asunto.Replace("{""Sucursal""}", DdlSubProyectoDatos.SelectedItem.Text)
Asunto = Asunto.Replace("{""DescripcionVenta""}", TxtDescripcionVenta.Text)
End If
@@ -24042,6 +24072,7 @@ Partial Class Ventas
Cuerpo = Cuerpo.Replace("{""FechaVencimiento""}", TxtFechaPago.Text)
Cuerpo = Cuerpo.Replace("{""SerieFolio""}", SerieFolio)
Cuerpo = Cuerpo.Replace("{""AtencionA""}", TxtAtencionA.Text)
Cuerpo = Cuerpo.Replace("{""CodigoCliente""}", TxtCodigo.Text)
Cuerpo = Cuerpo.Replace("{""Sucursal""}", DdlSubProyectoDatos.SelectedItem.Text)
Cuerpo = Cuerpo.Replace("{""DescripcionVenta""}", TxtDescripcionVenta.Text)
End If
@@ -24056,6 +24087,7 @@ Partial Class Ventas
Asunto = Asunto.Replace("{""FechaVencimiento""}", TxtFechaPago.Text)
Asunto = Asunto.Replace("{""SerieFolio""}", SerieFolio)
Asunto = Asunto.Replace("{""AtencionA""}", TxtAtencionA.Text)
Asunto = Asunto.Replace("{""CodigoCliente""}", TxtCodigo.Text)
Asunto = Asunto.Replace("{""Sucursal""}", DdlSubProyectoDatos.SelectedItem.Text)
Asunto = Asunto.Replace("{""DescripcionVenta""}", TxtDescripcionVenta.Text)
End If
@@ -41478,6 +41510,10 @@ Partial Class Ventas
Protected Sub DdlVendedor_SelectedIndexChanged(sender As Object, e As EventArgs)
'RECARGAR PROMOCIONES
CargarDTPromociones()
End Sub
Private Sub CargarDTPromociones()
Dim ObjVentas As New ClsVentas
If ObjVentas.GetPromocionesPS(-1, TxtFecha.Text.ToDateTime, DdlSubProyectoDatos.SelectedValue.ToEntero(), CveCliente, DdlVendedor.SelectedValue.ToEntero(), 1, UsuarioActual.CveEmpresa) Then
DtPromociones = ObjVentas.DtResultados.Copy()
@@ -41668,6 +41704,7 @@ Partial Class Ventas
Cuerpo = Cuerpo.Replace("{""FechaVencimiento""}", Dr("FechaVencimiento").ToString().ToDate().ToShortDateString())
Cuerpo = Cuerpo.Replace("{""Vigencia""}", Dr("Vigencia").ToString())
Cuerpo = Cuerpo.Replace("{""AtencionA""}", Dr("AtencionA").ToString())
Cuerpo = Cuerpo.Replace("{""CodigoCliente""}", Dr("ClienteCodigo").ToString())
Cuerpo = Cuerpo.Replace("{""Sucursal""}", Dr("SubProyecto").ToString())
Cuerpo = Cuerpo.Replace("{""DescripcionVenta""}", Dr("DescripcionVenta").ToString())
End If
@@ -41690,6 +41727,7 @@ Partial Class Ventas
Asunto = Asunto.Replace("{""FechaVencimiento""}", Dr("FechaVencimiento").ToString().ToDate().ToShortDateString())
Asunto = Asunto.Replace("{""Vigencia""}", Dr("Vigencia").ToString())
Asunto = Asunto.Replace("{""AtencionA""}", Dr("AtencionA").ToString())
Asunto = Asunto.Replace("{""CodigoCliente""}", Dr("ClienteCodigo").ToString())
Asunto = Asunto.Replace("{""Sucursal""}", Dr("SubProyecto").ToString())
Asunto = Asunto.Replace("{""DescripcionVenta""}", Dr("DescripcionVenta").ToString())
@@ -41714,6 +41752,7 @@ Partial Class Ventas
Cuerpo = Cuerpo.Replace("{""FechaVencimiento""}", Dr("FechaVencimiento").ToString().ToDate().ToShortDateString())
Cuerpo = Cuerpo.Replace("{""Vigencia""}", Dr("Vigencia").ToString())
Cuerpo = Cuerpo.Replace("{""AtencionA""}", Dr("AtencionA").ToString())
Cuerpo = Cuerpo.Replace("{""CodigoCliente""}", Dr("ClienteCodigo").ToString())
Cuerpo = Cuerpo.Replace("{""Sucursal""}", Dr("SubProyecto").ToString())
Cuerpo = Cuerpo.Replace("{""DescripcionVenta""}", Dr("DescripcionVenta").ToString())
End If
@@ -41733,6 +41772,7 @@ Partial Class Ventas
Asunto = Asunto.Replace("{""FechaVencimiento""}", Dr("FechaVencimiento").ToString().ToDate().ToShortDateString())
Asunto = Asunto.Replace("{""Vigencia""}", Dr("Vigencia").ToString())
Asunto = Asunto.Replace("{""AtencionA""}", Dr("AtencionA").ToString())
Asunto = Asunto.Replace("{""CodigoCliente""}", Dr("ClienteCodigo").ToString())
Asunto = Asunto.Replace("{""Sucursal""}", Dr("SubProyecto").ToString())
Asunto = Asunto.Replace("{""DescripcionVenta""}", Dr("DescripcionVenta").ToString())