From 00b4e9f6025fd3024ea030247926ce8ea706b641 Mon Sep 17 00:00:00 2001 From: JORGE LUIS CAUDILLO ESPARZA Date: Wed, 22 Dec 2021 20:41:01 -0700 Subject: [PATCH] --- Documentacion/TableroMaterialidad.aspx | 11 ++++-- Documentacion/TableroMaterialidad.aspx.cs | 7 +++- Documentacion/TableroMaterialidadDetalle.aspx | 39 +++++++++++++++++-- .../TableroMaterialidadDetalle.aspx.cs | 20 ++++++++++ 4 files changed, 70 insertions(+), 7 deletions(-) diff --git a/Documentacion/TableroMaterialidad.aspx b/Documentacion/TableroMaterialidad.aspx index d165a0b51..744690695 100644 --- a/Documentacion/TableroMaterialidad.aspx +++ b/Documentacion/TableroMaterialidad.aspx @@ -241,7 +241,6 @@
- Procesar
@@ -249,6 +248,10 @@
+
+ Procesar +
+
@@ -262,7 +265,6 @@
- Guardar
@@ -437,7 +439,10 @@ - + +
+ Guardar +
diff --git a/Documentacion/TableroMaterialidad.aspx.cs b/Documentacion/TableroMaterialidad.aspx.cs index fa5ac978e..d232db48c 100644 --- a/Documentacion/TableroMaterialidad.aspx.cs +++ b/Documentacion/TableroMaterialidad.aspx.cs @@ -383,11 +383,15 @@ public partial class Documentacion_TableroMaterialidad : ClsPaginas GvPeriodo.DataBind(); } } + Upxmlpdf.Update(); } } protected void LnkProcesarDoctos_Click(object sender, EventArgs e) { + + procesararchivo(xmlobject, string.Format("{0}{1}", anio, mes).ToEntero(), true); + procesararchivo(xmlobject, string.Format("{0}{1}", anio, mes).ToEntero(), false); } protected void GVmaterialidadDoctos_RowDataBound(object sender, GridViewRowEventArgs e) { @@ -413,11 +417,12 @@ public partial class Documentacion_TableroMaterialidad : ClsPaginas e.Row.CssClass = "danger"; toolTip = string.Format("{0}{1}No se encontro el personal", toolTip, (toolTip.Length > 0 ? " " : "")); } + /* if (CvePeriodo <= 0) { e.Row.CssClass = "danger"; toolTip = string.Format("{0}{1}No se encontro el periodo", toolTip, (toolTip.Length > 0 ? " " : "")); - } + }*/ e.Row.ToolTip = toolTip; } diff --git a/Documentacion/TableroMaterialidadDetalle.aspx b/Documentacion/TableroMaterialidadDetalle.aspx index 1f5d39474..77ea2befb 100644 --- a/Documentacion/TableroMaterialidadDetalle.aspx +++ b/Documentacion/TableroMaterialidadDetalle.aspx @@ -49,7 +49,7 @@
MES:
- + @@ -92,16 +92,49 @@ - + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Documentacion/TableroMaterialidadDetalle.aspx.cs b/Documentacion/TableroMaterialidadDetalle.aspx.cs index 450e86419..4515ae359 100644 --- a/Documentacion/TableroMaterialidadDetalle.aspx.cs +++ b/Documentacion/TableroMaterialidadDetalle.aspx.cs @@ -1,5 +1,6 @@ using System; using System.Collections.Generic; +using System.Data; using System.Linq; using System.Web; using System.Web.UI; @@ -56,6 +57,25 @@ public partial class Documentacion_TableroMaterialidadDetalle : ClsPaginas if (edoc.TableroMaterialidadDetalleGET(UsuarioActual.CveEmpresa, (anio = Txtanio.Text.ToEntero()), (mes = ddlMes.SelectedValue.ToEntero()), CveCliente) && edoc.DSResultados.Tables.Count > 0) { GVData.DataSource = edoc.DSResultados.Tables[0]; + int CurrentColumn = 4; + BoundField bf; + foreach (DataRow item in edoc.DSResultados.Tables[1].Rows) + { + GVData.Columns[CurrentColumn].Visible = true; + bf = (BoundField)GVData.Columns[CurrentColumn]; + bf.DataField = string.Format("V_{0}", item["CvePeriodo"]); + bf.HeaderText = string.Format("({0:dd/MM/yyyy}-{1:dd/MM/yyyy})", item["FechaInicio"], item["FechaFin"]); + bf.Visible = true; + //Alert(string.Format("{0}-{1}", item["FechaInicio"], item["FechaFin"])); + CurrentColumn = CurrentColumn + 1; + } + for (int i = CurrentColumn; i < GVData.Columns.Count; i++) + { + GVData.Columns[i].Visible = false; + bf = (BoundField)GVData.Columns[i]; + bf.DataField = ""; + bf.HeaderText = ""; + } GVData.DataBind(); }