This commit is contained in:
JORGE LUIS CAUDILLO ESPARZA
2020-07-02 17:47:27 -07:00
parent 4ed018bb4d
commit 5cda2592ec
5 changed files with 333 additions and 184 deletions

View File

@@ -3841,12 +3841,12 @@ public partial class Nomina_Nomina2 : ClsPaginas
{
TxtArchivoSua.Text = "";
GVProcesarSUA.DataSource = null;
GVProcesarSUA.DataBind();
GVProcesarSUA.DataBind();
RegistraScript("$('#DmodalCompareSua').modal();shownew();");
UpArchivoSua.Update();
}
protected void LnkUpSuaFile_Click(object sender, EventArgs e)
{
{
string fileurl = "";
GVProcesarSUA.DataSource = null;
Files archivos = TxtArchivoSua.getfiles();
@@ -3870,8 +3870,91 @@ public partial class Nomina_Nomina2 : ClsPaginas
}
protected void GVProcesarSUA_DataBound(object sender, EventArgs e)
protected void GVProcesarSUA_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
//CvePersonal,CodigoNombreCompleto,,,,,
//,,,,,,
//,,,,,,,
//Literal LtlNombre = e.Row.FCLiteral("LtlNombre");
//LinkButton LnkTimbrar = (LinkButton)e.Row.FindControl("LnkTimbrar");
string SalarioSUA = string.Format("{0:N2}",e.Row.DataKey("SalarioSUA").ToDecimal());
string SalarioSIG = string.Format("{0:N2}", e.Row.DataKey("SalarioSIG").ToDecimal());
int celda = 1;
if (SalarioSUA != SalarioSIG)
{
e.Row.Cells[celda].CssClass = "cellFail";
e.Row.Cells[celda + 1].CssClass = "cellFail";
}
celda = celda + 2;
string CuotaFijaSUA = string.Format("{0:N2}", e.Row.DataKey("CuotaFijaSUA").ToDecimal());
string CuotaFijaSIG = string.Format("{0:N2}", e.Row.DataKey("CuotaFijaSIG").ToDecimal());
if (CuotaFijaSUA != CuotaFijaSIG)
{
e.Row.Cells[celda].CssClass = "cellFail";
e.Row.Cells[celda + 1].CssClass = "cellFail";
}
celda = celda + 2;
string CuotaExcedenteSUA = string.Format("{0:N2}", e.Row.DataKey("CuotaExcedenteSUA").ToDecimal());
string CuotaExcedenteSIG = string.Format("{0:N2}", e.Row.DataKey("CuotaExcedenteSIG").ToDecimal());
if (CuotaExcedenteSUA != CuotaExcedenteSIG)
{
e.Row.Cells[celda].CssClass = "cellFail";
e.Row.Cells[celda + 1].CssClass = "cellFail";
}
celda = celda + 2;
string PrestacionesDineroSUA = string.Format("{0:N2}", e.Row.DataKey("PrestacionesDineroSUA").ToDecimal());
string PrestacionesSIG = string.Format("{0:N2}", e.Row.DataKey("PrestacionesSIG").ToDecimal());
if (PrestacionesDineroSUA != PrestacionesSIG)
{
e.Row.Cells[celda].CssClass = "cellFail";
e.Row.Cells[celda + 1].CssClass = "cellFail";
}
celda = celda + 2;
string GastosMedPenSUA = string.Format("{0:N2}", e.Row.DataKey("GastosMedPenSUA").ToDecimal());
string GastosMedicosSIG = string.Format("{0:N2}", e.Row.DataKey("GastosMedicosSIG").ToDecimal());
if (GastosMedPenSUA != GastosMedicosSIG)
{
e.Row.Cells[celda].CssClass = "cellFail";
e.Row.Cells[celda + 1].CssClass = "cellFail";
}
celda = celda + 2;
string RiesgosdeTrabajoSUA = string.Format("{0:N2}", e.Row.DataKey("RiesgosdeTrabajoSUA").ToDecimal());
string RiesgoTrabajoSIG = string.Format("{0:N2}", e.Row.DataKey("RiesgoTrabajoSIG").ToDecimal());
if (RiesgosdeTrabajoSUA != RiesgoTrabajoSIG)
{
e.Row.Cells[celda].CssClass = "cellFail";
e.Row.Cells[celda + 1].CssClass = "cellFail";
}
celda = celda + 2;
string InvalidezyVidaSUA = string.Format("{0:N2}", e.Row.DataKey("InvalidezyVidaSUA").ToDecimal());
string InvalidezyVidaSIG = string.Format("{0:N2}", e.Row.DataKey("InvalidezyVidaSIG").ToDecimal());
if (InvalidezyVidaSUA != InvalidezyVidaSIG)
{
e.Row.Cells[celda].CssClass = "cellFail";
e.Row.Cells[celda + 1].CssClass = "cellFail";
}
celda = celda + 2;
string GuarderiaSUA = string.Format("{0:N2}", e.Row.DataKey("GuarderiaSUA").ToDecimal());
string GuarderiaSIG = string.Format("{0:N2}", e.Row.DataKey("GuarderiaSIG").ToDecimal());
if (GuarderiaSUA != GuarderiaSIG)
{
e.Row.Cells[celda].CssClass = "cellFail";
e.Row.Cells[celda + 1].CssClass = "cellFail";
}
celda = celda + 2;
string RetiroSUA = string.Format("{0:N2}", e.Row.DataKey("RetiroSUA").ToDecimal());
string RetiroSIG = string.Format("{0:N2}", e.Row.DataKey("RetiroSIG").ToDecimal());
if (RetiroSUA != RetiroSIG)
{
e.Row.Cells[celda].CssClass = "cellFail";
e.Row.Cells[celda + 1].CssClass = "cellFail";
}
}
}
}