Ocultar boton de verificar en cancelaciones pendientes

This commit is contained in:
2023-03-29 11:14:02 -07:00
parent e155bd3391
commit c03f467442
2 changed files with 31 additions and 2 deletions

View File

@@ -623,6 +623,35 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
}
}
}
protected void GvRefacturaciones_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
GridView gv = (GridView)sender;
if (!(e.Row.DBCampo("PuedeRefacturar").ToEntero() == 0 || !string.IsNullOrEmpty(e.Row.DBCampo("FolioFiscalSustitucion"))))
{
e.Row.FCHyperLink("HplRefact").NavigateUrl = string.Format("/Ventas/Ventas.aspx?CveDevolucion={0}&NuevaFactura=1", e.Row.DBCampo("CveVenta"));
e.Row.FCHyperLink("HplRefact").Visible = true;
}
if (e.Row.DBCampo("CveEstatusFactura").ToString().ToEntero() == 23)
{
e.Row.FCLinkButton("LnkValidarRefac").Visible = false;
}
if (e.Row.DBCampo("PuedeRefacturar") == "0" && e.Row.DBCampo("CveEstatusFactura") == "23" && e.Row.DBCampo("CveVentaSustitucion").ToEntero() > 0)
{
if (e.Row.FCLinkButton("LnkCancelar") != null) e.Row.FCLinkButton("LnkCancelar").Visible = true;
}
if (string.IsNullOrEmpty(e.Row.DBCampo("FolioFiscal")))
{
e.Row.FCLinkButton("LnkValidarRefac").Visible = false;
}
}
}
public void BtnEnviarMailCancelacion_Click(object sender, EventArgs e)
{
if (this.CveVenta > 0)