Implementacion de módulo de Exportación y Partidas

This commit is contained in:
SLopez
2025-06-26 11:59:56 -07:00
parent 0e6fa86ee5
commit 1305ad5572
7 changed files with 2517 additions and 6 deletions

View File

@@ -0,0 +1,61 @@
using DocumentFormat.OpenXml.Wordprocessing;
using Extensiones;
using StackExchange.Redis;
using System;
using System.Activities;
using System.Activities.Expressions;
using System.Activities.Statements;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using static Microsoft.EntityFrameworkCore.DbLoggerCategory;
using static Stimulsoft.Report.Export.DeflaterHuffman;
public partial class Export_RepExportaciones : ClsPaginas
{
#region Propiedades
private int CveExportacion
{
get { return (ViewState["CveExportacion"] == null) ? -1 : Convert.ToInt32(ViewState["CveExportacion"]); }
set { ViewState["CveExportacion"] = value; }
}
#endregion
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
CargaExportaciones();
}
}
protected void CargaExportaciones()
{
ClsExportaciones Exportaciones = new ClsExportaciones();
if (Exportaciones.GetExportacion(-1, UsuarioActual.CveEmpresa))
{
GVExportaciones.DataSource = Exportaciones.DtResultados;
GVExportaciones.DataBind();
}
Exportaciones.Dispose();
upDatosExp.Update();
}
protected void EditarExp_Click(object sender, EventArgs e)
{
GridViewRow gvRow = (GridViewRow)(((LinkButton)sender).NamingContainer);
Response.Redirect($"/Export/ExpDetalle.aspx?CveExportacion={gvRow.DataKey("CveExportacion")}", true);
upDatosExp.Update();
}
protected void EliminarExp_Click(object sender, EventArgs e)
{
GridViewRow gvRow = (GridViewRow)(((LinkButton)sender).NamingContainer);
ClsExportaciones Exportaciones = new ClsExportaciones();
bool Continuar = Exportaciones.RemoveExportacion(gvRow.DataKey("CveExportacion").ToEntero());
Exportaciones.Dispose();
if (Continuar)
{
CargaExportaciones();
Alert("La Exportación se ha eliminado correctamente.");
}
}
}