70 lines
2.7 KiB
C#
70 lines
2.7 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Data;
|
|
|
|
namespace PDFGenerator.BusinessLayer.DataSection
|
|
{
|
|
|
|
/// <summary>
|
|
/// Summary description for DSS172ProtezioneCapitaleAreeBisogno
|
|
/// </summary>
|
|
public class DSS172BisProtezioneLineeProtette : IDataSection
|
|
{
|
|
|
|
public DSS172BisProtezioneLineeProtette()
|
|
{
|
|
//
|
|
// TODO: Add constructor logic here
|
|
//
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
/// Recupera i dati per la stampa della S172.
|
|
/// </summary>
|
|
/// <param name="tabelleSessione"></param>
|
|
/// <param name="querySql"></param>
|
|
/// <param name="dataThread"></param>
|
|
/// <returns></returns>
|
|
public DataSectionResult getDataSection(List<SessionStruct> tabelleSessione, string querySql, DataThread dataThread)
|
|
{
|
|
DataSetS172Bis dataset172Bis = new DataSetS172Bis();
|
|
FormatNum conv = new FormatNum();
|
|
DataSectionResult dsr = new DataSectionResult();
|
|
|
|
Random rnd = new Random();
|
|
DataTable dt = new DataTable();
|
|
|
|
dt = SectionManager.GetDataSection(tabelleSessione, querySql, dataThread);
|
|
|
|
#region Tabella Linee Protette
|
|
|
|
foreach (DataRow row in dt.Rows)
|
|
{
|
|
|
|
//Grafico Piramide
|
|
DataSetS172Bis.LineeProtetteBisRow rowDSS172BisLineeProtette;
|
|
rowDSS172BisLineeProtette = dataset172Bis.LineeProtetteBis.NewLineeProtetteBisRow();
|
|
rowDSS172BisLineeProtette.Linea = row["Linea"].ToString();
|
|
rowDSS172BisLineeProtette.Contratto = row["Contratto"].ToString();
|
|
|
|
rowDSS172BisLineeProtette.VersatoNetto = Convert.ToDecimal(row["VersatoNetto"]);
|
|
rowDSS172BisLineeProtette.Controvalore = Convert.ToDecimal(row["Contratto"]);
|
|
rowDSS172BisLineeProtette.ComponentePerformance = Convert.ToDecimal(row["ComponentePerformance"]);
|
|
rowDSS172BisLineeProtette.ComponenteProtezione = Convert.ToDecimal(row["ComponenteProtezione"]);
|
|
rowDSS172BisLineeProtette.ControvaloreProtetto = Convert.ToDecimal(row["ControvaloreProtetto"]);
|
|
rowDSS172BisLineeProtette.DataRiferimento = row["DataRiferimento"].ToString();
|
|
rowDSS172BisLineeProtette.PercentualePerformance = Convert.ToDecimal(row["PercentualePerformance"]);
|
|
rowDSS172BisLineeProtette.PercentualeProtezione = Convert.ToDecimal(row["PercentualeProtezione"]);
|
|
|
|
}
|
|
#endregion
|
|
|
|
dsr.DatiSezione = dataset172Bis;
|
|
dsr.Esito = dataset172Bis.LineeProtetteBis.Rows.Count;
|
|
|
|
return dsr;
|
|
}
|
|
}
|
|
}
|