-- se quitaron las fechas, y se activó el cambio de estatus en todos
This commit is contained in:
@@ -2,7 +2,6 @@
|
||||
using System.Web.UI.WebControls;
|
||||
using Extensiones;
|
||||
using System.Data;
|
||||
using static Extensiones.ModExtensiones;
|
||||
using static Extensiones.ModExtensiones;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
@@ -91,8 +90,8 @@ public partial class Ventas_RepLineasAdicionales : ClsPaginas
|
||||
}
|
||||
|
||||
DdlClientes.setEsWebService(true);
|
||||
DdlClientes.Attributes.Add("data-metodo", "getcliente");
|
||||
DdlClientes.SelectedText = "Todos";
|
||||
DdlClientes.Attributes.Add("data-metodo", "getcliente");
|
||||
DdlClientes.SelectedText = "Todos";
|
||||
DdlClientes.SelectedValue = "-1";
|
||||
|
||||
//txtFechaI.Text = DateTime.Now.FirstDayOfMonth().ToShortDateString();
|
||||
@@ -111,7 +110,7 @@ public partial class Ventas_RepLineasAdicionales : ClsPaginas
|
||||
DTDatosGvLineasAdicionales = new DataTable();
|
||||
LnkDescargaExcel.Visible = false;
|
||||
|
||||
ClsVentas objVentas = new ClsVentas();
|
||||
ClsVentas objVentas = new ClsVentas();
|
||||
|
||||
int CveProveedor = DdlProveedor.SelectedValue.ToEntero() > 0 ? DdlProveedor.SelectedValue.ToEntero() : -1;
|
||||
|
||||
@@ -273,14 +272,12 @@ public partial class Ventas_RepLineasAdicionales : ClsPaginas
|
||||
|
||||
protected void LnkDescargaExcel_Click(object sender, EventArgs e)
|
||||
{
|
||||
GridView gvTemp = GvLineasAdicionales;
|
||||
gvTemp.Columns[8].Visible = false;
|
||||
gvTemp.ExportToExcelx( TipoLinea == 1 ? "RepLienasAdicionales":"RepPO");
|
||||
GridView gvTemp = GvLineasAdicionales;
|
||||
gvTemp.Columns[8].Visible = false;
|
||||
gvTemp.ExportToExcelx( TipoLinea == 1 ? "RepLienasAdicionales":"RepPO");
|
||||
}
|
||||
|
||||
protected void GvLineasAdicionales_RowDataBound(object sender, GridViewRowEventArgs e)
|
||||
protected void GvLineasAdicionales_RowDataBound(object sender, GridViewRowEventArgs e)
|
||||
{
|
||||
if(e.Row.RowType == DataControlRowType.DataRow)
|
||||
{
|
||||
@@ -321,4 +318,31 @@ public partial class Ventas_RepLineasAdicionales : ClsPaginas
|
||||
Response.AddHeader("Content-Length", fi.Length.ToString());
|
||||
Response.ContentType = "text/octet-stream";
|
||||
Response.Flush();
|
||||
Response.TransmitFile(fi.FullName);
|
||||
Response.End();
|
||||
}
|
||||
}
|
||||
|
||||
protected void GvLineasAdicionales_RowCommand(object sender, GridViewCommandEventArgs e)
|
||||
{
|
||||
|
||||
GridViewRow GvRow = (GridViewRow)((LinkButton)e.CommandSource).NamingContainer;
|
||||
int CveLineaAdicionalActualzarEstatus = GvRow.DataKey("CveLineaAdicional").ToString().ToEntero();
|
||||
int CveVenta = GvRow.DataKey("CveVenta").ToString().ToEntero();
|
||||
|
||||
bool errorCambioEstatus = false;
|
||||
int cveestatus = e.CommandArgument.ToEntero() + 2; //pasar al siguiente estatus
|
||||
|
||||
ClsVentas objVentas = new ClsVentas();
|
||||
|
||||
if (!objVentas.UpdateLineasAdicionales(CveLineaAdicionalActualzarEstatus, "-1", -1, -1, -1, -1, -1, MinFecha, 100, -1, UsuarioActual.CveEmpresa, CveVenta: CveVenta, CveLineaAdicionalEstatus: cveestatus))
|
||||
{
|
||||
errorCambioEstatus = true;
|
||||
}
|
||||
|
||||
|
||||
objVentas.Dispose();
|
||||
if (!errorCambioEstatus)
|
||||
{
|
||||
CargaDatos();
|
||||
}
|
||||
Reference in New Issue
Block a user