This commit is contained in:
JORGE LUIS CAUDILLO ESPARZA
2022-07-08 07:35:48 -07:00
48 changed files with 2797 additions and 2667 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -6,6 +6,16 @@
<asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="HB" runat="Server">
<asp:UpdatePanel runat="server" ID="UpAcciones">
<ContentTemplate>
<li>
<asp:LinkButton ID="LnkCerrarImportacion" runat="server" CausesValidation="False" Text="<i class='fa fa-pencil'></i> Cerrar Importación" OnClick="LnkCerrarImportacion_Click"
data-toggle="confirmation" data-popout="true" data-original-title="¿Cerrar Importación?" data-btn-ok-label="si" Visible="false" />
</li>
</ContentTemplate>
</asp:UpdatePanel>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="E" runat="Server">
Importaciones

View File

@@ -95,6 +95,11 @@ Partial Class Compras_Importaciones
'HLCompraSerieFolio.NavigateUrl = $"/Compras/Compras.aspx?CveCompra={HdnCveCompra.Value}"
'LbCompraImporte.Text = ObjImportaciones.DtResultados.Rows(0)("Total").ToString
If ObjImportaciones.DtResultados.Rows(0)("CveEstatus").ToString.ToEntero = 0 Then
LnkCerrarImportacion.Visible = True
End If
HdnCveAF.Value = ObjImportaciones.DtResultados.Rows(0)("CveActivoFijo").ToString
VincularAF()
@@ -491,4 +496,17 @@ Partial Class Compras_Importaciones
Protected Sub LnkCerrarImportacion_Click(sender As Object, e As EventArgs)
Dim ObjInv As New ClsInventarios
If ObjInv.UpdateImportacionCierre(CveImportacion, UsuarioActual.CveEmpresa, UsuarioActual.CveUsuario) Then
Alert("Importación cerrada correctamente.", TipoMensaje.MsgInformacion, $" location.href = ""./Importaciones.aspx?CveImportacion={CveImportacion}"" ")
End If
ObjInv.Dispose()
End Sub
End Class

View File

@@ -114,6 +114,17 @@
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender1" runat="server" HighlightCssClass="vco" TargetControlID="CVFechaF" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
</div>
<div class="col-md-1" style="max-width: 70px">Esatus:</div>
<div class="col-md-2">
<asp:DropDownList runat="server" ID="DdlEstatus" Width="100%" CssClass="select2me">
<asp:ListItem Value="-1">Todos</asp:ListItem>
<asp:ListItem Value="0" Selected="True">Activo</asp:ListItem>
<asp:ListItem Value="1">Cerrado</asp:ListItem>
</asp:DropDownList>
</div>
</div>
</div>
</div>

View File

@@ -40,9 +40,11 @@ Partial Class Compras_RepImportaciones
#Region " CARGA DAATOS "
Protected Sub BtnConsultarFiltros_Click(sender As Object, e As EventArgs)
CargaDatos()
End Sub
Private Sub CargaDatos()
Dim ObjImportaciones As New ClsCompras
Dim FechaI, FechaF As String
@@ -50,7 +52,7 @@ Partial Class Compras_RepImportaciones
If TxtFechaI.Text <> "" Then FechaI = TxtFechaI.Text Else FechaI = "-1"
If TxtFechaF.Text <> "" Then FechaF = TxtFechaF.Text Else FechaF = "-1"
If ObjImportaciones.GetImportaciones(-1, DdlProveedor.SelectedValue.ToString.ToEntero, -1, FechaI, FechaF, UsuarioActual.CveEmpresa) Then
If ObjImportaciones.GetImportaciones(-1, DdlProveedor.SelectedValue.ToString.ToEntero, -1, FechaI, FechaF, UsuarioActual.CveEmpresa, DdlEstatus.SelectedValue.ToEntero) Then
DtImportaciones = ObjImportaciones.DtResultados
Else
Alert("Ocurrió un error al cargar las importaciones", TipoMensaje.MsgError)
@@ -59,6 +61,7 @@ Partial Class Compras_RepImportaciones
CargaGrid()
End Sub
Private Sub CargaGrid()
GvDatos.DataSource = DtImportaciones
GvDatos.DataBind()

View File

@@ -75,7 +75,7 @@ public partial class Compras_RepPagadoPeriodo : ClsPaginas
txtFechaI.Text = $"01/{DateTime.Now.Month}/{DateTime.Now.Year}";
txtFechaF.Text = DateTime.Now.ToShortDateString();
TxtFechaICompra.Text = $"01/01/{DateTime.Now.Year}";
TxtFechaICompra.Text = MinFecha.ToShortDateString(); //'$"01/01/{DateTime.Now.Year}";
TxtFechaFCompra.Text = DateTime.Now.ToShortDateString();
//Carga Proyectos

View File

@@ -2918,6 +2918,9 @@ Partial Class Compras_eFacturas
Dim FechaPago As Date
Dim PagosCantidad As Integer = 0
Dim UUIDDuplicados As String = ""
Dim ListaUUIDDuplicados As New List(Of String)
DTGVPagosVinculacion = New DataTable
MontoPago = 0D
ComprasEnComplemento = 0
@@ -3067,6 +3070,25 @@ Partial Class Compras_eFacturas
Next
Next
Dim UUIDDuplicadosEnu = From row In DTDocumentosRelacionados.AsEnumerable()
Let IdDocumento = row.Field(Of String)("IdDocumento")
Group row By IdDocumento Into IdDocumentos = Group
Where IdDocumentos.Count() > 1
Select IdDocumentos
For Each UUIDDuplicadosRows In UUIDDuplicadosEnu
For Each row In UUIDDuplicadosRows
If Not ListaUUIDDuplicados.Contains(row.Field(Of String)("IdDocumento")) Then
UUIDDuplicados = $"{UUIDDuplicados} {If(ListaUUIDDuplicados.Count > 0, "<br>", "") } {row.Field(Of String)("IdDocumento")}"
ListaUUIDDuplicados.Add(row.Field(Of String)("IdDocumento"))
End If
Next
Next
MontoPago = Monto
Dim ObjCompraFolios As New ClsCompras
@@ -3253,7 +3275,7 @@ Partial Class Compras_eFacturas
If Math.Abs(DiferenciaImportes) > 5 Then
TextoDiferenciaImporte = $"<b>&nbsp;&nbsp;-&nbsp;&nbsp; IE ${ImporteIES.FormatoNumero}</b> <div style='color:red'><strong>Diferencia { DiferenciaImportes.FormatoNumero() }</strong></div>"
BtnVincularPago.Visible = False
MSGComplemento = MSGComplemento & $" Existe una diferencia mayor a $5.00 ({Math.Abs(DiferenciaImportes)})"
MSGComplemento = MSGComplemento & $" Existe una diferencia mayor a $5.00 ({Math.Abs(DiferenciaImportes).ToString("###,###,###.00")})"
If TieneRegistros AndAlso UsuarioActual.TienePermisoProceso(286) Then
DivVincularPagoManualmente.Visible = True
@@ -3285,9 +3307,20 @@ Partial Class Compras_eFacturas
LblDiferencia.Text = If(DiferenciaImportes <> 0 And ImporteIES > 0, DiferenciaImportes.FormatoNumero, "")
If MSGComplemento.Trim.Length > 0 And CveComplementoPagoCompra <= 0 Then
LblMensajeComlementoError.Text = MSGComplemento
DVMensajecomplementoError.Visible = True
If MSGComplemento.Trim.Length > 0 And CveComplementoPagoCompra <= 0 Or ListaUUIDDuplicados.Count > 0 And CveComplementoPagoCompra <= 0 Then
If ListaUUIDDuplicados.Count > 0 Then
LblMensajeComlementoError.Text = $"Las siguientes UUID se encuentran duplicadas:<br>{UUIDDuplicados}<br>{MSGComplemento}"
'<hr style='border: 0; height: 1px; background-image: linear-gradient(to right, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0));' />
DVMensajecomplementoError.Visible = True
Else
LblMensajeComlementoError.Text = MSGComplemento
DVMensajecomplementoError.Visible = True
End If
Else
LblMensajeComlementoError.Text = ""