450 lines
24 KiB
C#
450 lines
24 KiB
C#
|
|
using System;
|
|
using System.Data;
|
|
using System.Configuration;
|
|
using System.Web;
|
|
using System.Web.Security;
|
|
using System.Web.UI;
|
|
using System.Web.UI.WebControls;
|
|
using System.Web.UI.WebControls.WebParts;
|
|
using System.Web.UI.HtmlControls;
|
|
using System.Collections;
|
|
using ceTe.DynamicPDF;
|
|
using ceTe.DynamicPDF.Text;
|
|
using ceTe.DynamicPDF.PageElements.Charting;
|
|
using PDFGenerator.BusinessLayer;
|
|
using PDFGenerator.BusinessLayer.DataSection;
|
|
using PDFGenerator.Presentation.Section.Tables;
|
|
using PDFGenerator.Presentation.Section.Charts;
|
|
using PDFGenerator.BusinessLayer.Utils;
|
|
|
|
|
|
namespace PDFGenerator.Presentation.Section
|
|
{
|
|
class S132: ISezione
|
|
{
|
|
private string _titolo = string.Empty;
|
|
private string _testointroduttivo = string.Empty;
|
|
|
|
/// <summary>
|
|
/// Titolo della sezione
|
|
/// </summary>
|
|
public string Titolo
|
|
{
|
|
get
|
|
{
|
|
return _titolo;
|
|
}
|
|
set
|
|
{
|
|
_titolo = value;
|
|
}
|
|
}
|
|
|
|
|
|
/// <summary>
|
|
/// Testo introduttivo della Sezione.
|
|
/// </summary>
|
|
public string TestoIntroduttivo
|
|
{
|
|
get
|
|
{
|
|
return _testointroduttivo;
|
|
}
|
|
set
|
|
{
|
|
_testointroduttivo = value;
|
|
}
|
|
}
|
|
|
|
|
|
public S132()
|
|
{
|
|
//
|
|
// TODO: Add constructor logic here
|
|
//
|
|
}
|
|
|
|
|
|
public void writeSezione(DataThread dataThread)
|
|
{
|
|
DocumentPDF document = dataThread.DocumentPDF;
|
|
document.setSezTitolo(dataThread.SezioneReport.Titolo);
|
|
string tempTesto = dataThread.SezioneReport.TestoIntroduttivo.Replace("/$Banca$/", dataThread.NomeRete);
|
|
string tempTestoAlt = dataThread.SezioneReport.TestoIntroduttivoAlternativo.Replace("/$Banca$/", dataThread.NomeRete);
|
|
|
|
//if (dataThread.Rete.ToUpper() == "S")
|
|
// {
|
|
// tempTesto = tempTesto.Replace("Banca Fideuram", "Sanpaolo Invest");
|
|
// tempTestoAlt = tempTesto.Replace("Banca Fideuram", "Sanpaolo Invest");
|
|
// }
|
|
//setChapterHeader(string label, int x, int width, float font)
|
|
document.setChapterHeader(tempTesto,0,520,8);
|
|
|
|
|
|
DataSetS132 set = (DataSetS132)dataThread.Data.DatiSezione;
|
|
|
|
|
|
# region profiloRischio
|
|
DatiTabella profilofinanziarioDatiTab = new DatiTabella();
|
|
profilofinanziarioDatiTab.table = set.Tables["ProfiloRischio"];
|
|
profilofinanziarioDatiTab.setCell(200, ceTe.DynamicPDF.TextAlign.Left, Globals.OpenTypeFontVerdanaB, false,8);
|
|
profilofinanziarioDatiTab.setCell(312, ceTe.DynamicPDF.TextAlign.Left, Globals.OpenTypeFontVerdana, false,8);
|
|
profilofinanziarioDatiTab.setX(document.getMargineLeft());
|
|
Tabella profilofinanziarioTab = new Tabella();
|
|
//profilofinanziarioTab.LineaFineTabella = true;
|
|
//profilofinanziarioTab.
|
|
# endregion
|
|
|
|
# region profiloDate
|
|
DatiTabella profiloDateDatiTab = new DatiTabella();
|
|
profiloDateDatiTab.table = set.Tables["ProfiloDate"];
|
|
//profilofinanziarioDatiTab.setIsLinee(1);
|
|
profiloDateDatiTab.setCell(200, ceTe.DynamicPDF.TextAlign.Left, Globals.OpenTypeFontVerdanaB, false,8);
|
|
profiloDateDatiTab.setCell(312, ceTe.DynamicPDF.TextAlign.Left, Globals.OpenTypeFontVerdana, false,8);
|
|
profiloDateDatiTab.setX(document.getMargineLeft());
|
|
Tabella profiloDateTab = new Tabella();
|
|
//profilofinanziarioTab.LineaFineTabella = true;
|
|
//profilofinanziarioTab.
|
|
# endregion
|
|
|
|
|
|
profilofinanziarioDatiTab.setY(document.getLastPos()-5);
|
|
document.InsertTable(profilofinanziarioTab.getTabella(profilofinanziarioDatiTab));
|
|
|
|
float ycolonneRed = document.getLastPos() + profilofinanziarioDatiTab.getNumRow();
|
|
|
|
float ydatitab = ycolonneRed + 14;
|
|
profiloDateDatiTab.setY(ydatitab);
|
|
document.InsertTable(profiloDateTab.getTabella(profiloDateDatiTab));
|
|
|
|
document.setHeaderSpace(35);
|
|
|
|
document.writeText(document.getMargineLeft() -5, document.getLastPos(), tempTestoAlt, 8, 520, ceTe.DynamicPDF.TextAlign.Justify);
|
|
|
|
//document.setHeaderSpace(60);
|
|
document.setLastPos(40);
|
|
|
|
ceTe.DynamicPDF.Merger.ImportedPage page = document.getCurrentPage();
|
|
|
|
|
|
#region Grafico
|
|
|
|
DataTable _datasource = set.Tables["DatiGrafico"];
|
|
|
|
#region recupero dati frecce
|
|
int classeRischio = 0;
|
|
|
|
if (_datasource.Rows[0]["ClasseRischioCreditoStr"] != DBNull.Value)
|
|
{
|
|
if (_datasource.Rows[0]["ClasseRischioCreditoStr"].ToString().ToUpper() == "N.A.")
|
|
classeRischio = -1;
|
|
}
|
|
else
|
|
classeRischio = Convert.ToInt32(_datasource.Rows[0]["ClasseRischioCredito"]);
|
|
|
|
|
|
// Rischio Mercato/VarP
|
|
double varP = 0;
|
|
if (_datasource.Rows[0]["RischioMercatoStr"] != DBNull.Value)
|
|
{
|
|
if (_datasource.Rows[0]["RischioMercatoStr"].ToString().ToUpper() == "N.A.")
|
|
varP = -1;
|
|
}
|
|
else
|
|
varP = Convert.ToInt32(_datasource.Rows[0]["RischioMercato"]);
|
|
|
|
// Rischio Mercato Massimo
|
|
decimal varMassimo = 0;
|
|
if (_datasource.Rows[0]["RischioMercatoMaxStr"] != DBNull.Value)
|
|
{
|
|
if (_datasource.Rows[0]["RischioMercatoMaxStr"].ToString().ToUpper() == "N.A.")
|
|
varMassimo = -1;
|
|
}
|
|
else
|
|
varMassimo = Convert.ToDecimal(_datasource.Rows[0]["RischioMercatoMax"]);
|
|
|
|
|
|
// Rischio Credito Massimo
|
|
int classeRiskCredMax = 0;
|
|
if (_datasource.Rows[0]["RischioCreditoMaxStr"] != DBNull.Value)
|
|
{
|
|
if (_datasource.Rows[0]["RischioCreditoMaxStr"].ToString().ToUpper() == "N.A.")
|
|
classeRiskCredMax = -1;
|
|
}
|
|
else
|
|
classeRiskCredMax = Convert.ToInt32(_datasource.Rows[0]["RischioCreditoMax"]);
|
|
|
|
#endregion
|
|
//document.setLastPos(420);
|
|
|
|
GraficoS132 grafico = new GraficoS132();
|
|
grafico.Datasource = _datasource;
|
|
document.InsertGraficoS132(grafico.ToPage(), document.getMargineLeft() + 60, document.getLastPos());
|
|
|
|
#endregion
|
|
|
|
//
|
|
// I marcatori sull'asse X e sull'asse Y non vengono visualizzati se il cliente
|
|
// non e' mai stato profilato o se il profilo e' scaduto
|
|
// Non vengono visualizzati se il rischio credito max o il rischio mercato max sono uguali ad "N.C."
|
|
// se rischio credito max = n.a. ugualmente non facciamo vedere le frecce.
|
|
//
|
|
#region FRECCE
|
|
if ((_datasource.Rows[0]["Profilo"].ToString() == "A") && (varMassimo > 0) && (classeRiskCredMax > 0))
|
|
{
|
|
|
|
#region Marcatore AsseY
|
|
|
|
//Freccia
|
|
float posZero = 157;//259
|
|
float fattIncr = 5;
|
|
float offsetFreccia = 6;
|
|
//float posVar1 = posZero - (fattIncr * (float.Parse(BusinessLayer.SoglieVar.sVar1)));
|
|
//float posVar2 = posZero - (fattIncr * (float.Parse(BusinessLayer.SoglieVar.sVar2)));
|
|
//float posVar3 = posZero - (fattIncr * (float.Parse(BusinessLayer.SoglieVar.sVar3)));
|
|
//float posVar4 = posZero - (fattIncr * (float.Parse(BusinessLayer.SoglieVar.sVar4)));
|
|
//float posVar5 = posZero - (fattIncr * (float.Parse(BusinessLayer.SoglieVar.sVar5)));
|
|
//page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("--" + posVar1, document.getMargineLeft() + 101, document.getLastPos() + posVar1, 50F, 50F));
|
|
//page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("--" + posVar2, document.getMargineLeft() + 101, document.getLastPos() + posVar2, 50F, 50F));
|
|
//page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("--" + posVar3, document.getMargineLeft() + 101, document.getLastPos() + posVar3, 50F, 50F));
|
|
//page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("--" + posVar4, document.getMargineLeft() + 101, document.getLastPos() + posVar4, 50F, 50F));
|
|
//page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("--" + posVar5, document.getMargineLeft() + 101, document.getLastPos() + posVar5, 50F, 50F));
|
|
float yMarcatoreAsseYRettangolo = document.getLastPos() + posZero - (fattIncr * (float)varMassimo) - offsetFreccia;
|
|
ceTe.DynamicPDF.PageElements.Rectangle FrecciaMarcatoreAsseY = new ceTe.DynamicPDF.PageElements.Rectangle(document.getMargineLeft() + 55, yMarcatoreAsseYRettangolo, 20, 20, new RgbColor(234, 234, 234), new RgbColor(234, 234, 234));
|
|
FrecciaMarcatoreAsseY.Angle = 45;
|
|
page.Elements.Add(FrecciaMarcatoreAsseY);
|
|
|
|
// Rettangolo
|
|
ceTe.DynamicPDF.PageElements.Rectangle RettangolomarcatoreAsseY = new ceTe.DynamicPDF.PageElements.Rectangle(document.getMargineLeft(), yMarcatoreAsseYRettangolo, 55, FrecciaMarcatoreAsseY.Width * 1.414F, new RgbColor(234, 234, 234), new RgbColor(234, 234, 234));
|
|
page.Elements.Add(RettangolomarcatoreAsseY);
|
|
|
|
//Label
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("Rischio Mercato", document.getMargineLeft() + 2, yMarcatoreAsseYRettangolo + 2, 80, FrecciaMarcatoreAsseY.Width * 1.414F, Globals.OpenTypeFontVerdana, 6));
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("(VaR) massimo", document.getMargineLeft() + 2, yMarcatoreAsseYRettangolo + 10, 80, FrecciaMarcatoreAsseY.Width * 1.414F, Globals.OpenTypeFontVerdana, 6));
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("(" + varMassimo.ToString() + "%)", document.getMargineLeft() + 14, yMarcatoreAsseYRettangolo + 18, 80, FrecciaMarcatoreAsseY.Width * 1.414F, Globals.OpenTypeFontVerdana, 6));
|
|
|
|
#endregion
|
|
|
|
#region Marcatore AsseX
|
|
|
|
// Recupero la X
|
|
float xMarcatoreAsseXRettangolo = 0; //classeRiskCredMax
|
|
|
|
#region pecetta grafico
|
|
|
|
//Legent
|
|
//Title
|
|
//int LastPosition = 380;
|
|
float lastpos = document.getLastPos();
|
|
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Rectangle(437, lastpos + 100, 20, 8, ceTe.DynamicPDF.CmykColor.Black, new RgbColor(234, 234, 234), 0.3F));//RgbColor(255, 255, 255)));
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("Area di non adeguatezza", 460, lastpos + 100, 160, 10, Globals.OpenTypeFontVerdana, 7, ceTe.DynamicPDF.TextAlign.Left, ceTe.DynamicPDF.CmykColor.Black));
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Rectangle(437, lastpos + 100 + 13, 20, 8, ceTe.DynamicPDF.CmykColor.Black, ceTe.DynamicPDF.CmykColor.White, 0.3F));//RgbColor(255, 255, 255)));
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("Area di adeguatezza", 460, lastpos + 100 + 13, 160, 10, Globals.OpenTypeFontVerdana, 7, ceTe.DynamicPDF.TextAlign.Left, ceTe.DynamicPDF.CmykColor.Black));
|
|
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("Rischio Mercato (VaR%)", document.getMargineLeft(), lastpos + 7, 120, 12, Globals.OpenTypeFontVerdana, 7, ceTe.DynamicPDF.TextAlign.Left, ceTe.DynamicPDF.CmykColor.Black));
|
|
|
|
//LastPosition = 427;
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("Rischio Credito", 420, lastpos + 159, 100, 8, Globals.OpenTypeFontVerdana, 7, ceTe.DynamicPDF.TextAlign.Left, ceTe.DynamicPDF.CmykColor.Black));
|
|
#endregion
|
|
|
|
|
|
//classeRiskCredMax = 3; per fare test
|
|
if (classeRiskCredMax == 1)
|
|
xMarcatoreAsseXRettangolo = document.getMargineLeft() + 152; // selezione su Classe 1
|
|
else if (classeRiskCredMax == 2)
|
|
xMarcatoreAsseXRettangolo = document.getMargineLeft() + 222;// selezione su Classe 2
|
|
else if (classeRiskCredMax == 3)
|
|
xMarcatoreAsseXRettangolo = document.getMargineLeft() + 296; // selezione su Classe 3
|
|
|
|
|
|
// Recupero la Y
|
|
float yMarcatoreAsseXRettangolo = document.getLastPos() + grafico.Height;
|
|
|
|
// Rettangolo Base (principale)
|
|
ceTe.DynamicPDF.PageElements.Rectangle FrecciaMarcatoreAsseX_Base = new ceTe.DynamicPDF.PageElements.Rectangle(xMarcatoreAsseXRettangolo, yMarcatoreAsseXRettangolo, 55, 25, new RgbColor(234, 234, 234), new RgbColor(234, 234, 234));
|
|
page.Elements.Add(FrecciaMarcatoreAsseX_Base);
|
|
|
|
// Rettangolo a destra (punta destra)
|
|
ceTe.DynamicPDF.PageElements.Rectangle FrecciaMarcatoreAsseX_dx = new ceTe.DynamicPDF.PageElements.Rectangle(xMarcatoreAsseXRettangolo + (FrecciaMarcatoreAsseX_Base.Width / 2), yMarcatoreAsseXRettangolo - 10, 29, 10, new RgbColor(234, 234, 234), new RgbColor(234, 234, 234));
|
|
FrecciaMarcatoreAsseX_dx.Angle = 19.3F;
|
|
page.Elements.Add(FrecciaMarcatoreAsseX_dx);
|
|
|
|
//Rettangolo a sinistra (punta sinistra)
|
|
ceTe.DynamicPDF.PageElements.Rectangle FrecciaMarcatoreAsseX_sx = new ceTe.DynamicPDF.PageElements.Rectangle(xMarcatoreAsseXRettangolo, yMarcatoreAsseXRettangolo, 28.6F, 10, new RgbColor(234, 234, 234), new RgbColor(234, 234, 234));
|
|
FrecciaMarcatoreAsseX_sx.Angle = 339.4F;
|
|
page.Elements.Add(FrecciaMarcatoreAsseX_sx);
|
|
|
|
//Label
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("Rischio Credito", xMarcatoreAsseXRettangolo + 4, yMarcatoreAsseXRettangolo, 80, 12, Globals.OpenTypeFontVerdana, 6));
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("massimo", xMarcatoreAsseXRettangolo + 14, yMarcatoreAsseXRettangolo + 7, 80, 12, Globals.OpenTypeFontVerdana, 6));
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("("+UtilityBusinessLayer.GetRiskCreditClassName(classeRiskCredMax.ToString())+")", xMarcatoreAsseXRettangolo + 12, yMarcatoreAsseXRettangolo + 14, 80, 12, Globals.OpenTypeFontVerdana, 6));
|
|
|
|
|
|
#endregion
|
|
}
|
|
#endregion
|
|
|
|
#region Tabella
|
|
|
|
DatiTabella datitab = new DatiTabella();
|
|
datitab.SetRowDim(15);
|
|
|
|
|
|
|
|
float dimTabella = 0;
|
|
|
|
#region Tabella Monitoraggio
|
|
datitab.table = set.Tables["DatiTabellaMonitoraggio"];
|
|
Tabella tabellaPatrimonio = new Tabella(document.getMargineLeft(), document.getLastPos() + grafico.Height + 40);
|
|
tabellaPatrimonio.Header = true;
|
|
|
|
tabellaPatrimonio.Id = "TabellaPatrimonio";
|
|
//tabellaPatrimonio.Datasource = _datasource;
|
|
|
|
|
|
|
|
//V vedere come gestiore la leggenda nella tabella
|
|
tabellaPatrimonio.Colonne.Add(new Colonna("DescrizionePatrimonio", "Patrimonio", 150, TipoAllineamento.SINISTRA, false, 9, false, TipoColonna.IMMAGINE_E_TESTO));
|
|
tabellaPatrimonio.Colonne.Add(new Colonna("TotalePatrimonio", "Totale Patrimonio<BR>(€)", 110, TipoAllineamento.DESTRA, false, 9, false));
|
|
tabellaPatrimonio.Colonne.Add(new Colonna("RischioCredito", "Rischio<BR>Credito", 70,TipoAllineamento.DESTRA, false, 9, false));
|
|
tabellaPatrimonio.Colonne.Add(new Colonna("RischioMercato", "Rischio Mercato<BR>(VaR%)", 106, TipoAllineamento.DESTRA, false, 9, false));
|
|
tabellaPatrimonio.Colonne.Add(new Colonna("Copertura", "Copertura<BR>(%)", 76, TipoAllineamento.DESTRA, false, 9, false));
|
|
|
|
tabellaPatrimonio.Draw(datitab, document);
|
|
|
|
|
|
#region Simboli del patrimonio
|
|
//Monitoraggio avrà solo il dettaglio per patrimonio bf o spi (un rombo come simbolo)
|
|
ceTe.DynamicPDF.PageElements.Rectangle rect = new ceTe.DynamicPDF.PageElements.Rectangle(document.getMargineLeft(), tabellaPatrimonio.Y + 18, 10 / 1.414F, 10 / 1.414F, 0, new RgbColor(0, 0, 0));
|
|
rect.Angle = 45;
|
|
page.Elements.Add(rect);
|
|
|
|
#endregion
|
|
|
|
#region Indicatore rischio mercato
|
|
//Monitoraggio avrà solo il dettaglio per patrimonio bf o spi (un rombo come simbolo)
|
|
string flagOK = WebConfigParameter.getParameter("FlagOK_RIDOTTA");
|
|
string flagNO = WebConfigParameter.getParameter("FlagNO_RIDOTTA");
|
|
|
|
System.Reflection.Assembly thisExe;
|
|
thisExe = System.Reflection.Assembly.GetExecutingAssembly();
|
|
System.IO.Stream fileOk = thisExe.GetManifestResourceStream(flagOK);
|
|
System.IO.Stream fileNo = thisExe.GetManifestResourceStream(flagNO);
|
|
|
|
// Indicatore Rischio Mercato
|
|
if (!set.Indicatori[0].RischioCredito)
|
|
{ // INDICATORE "RischioMercato" NO
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Image(fileNo, document.getMargineLeft()+331, tabellaPatrimonio.Y + 18, 0.15F));
|
|
}
|
|
else
|
|
{ // INDICATORE "RischioMercato" OK
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Image(fileOk, document.getMargineLeft() + 331, tabellaPatrimonio.Y + 18, 0.15F));
|
|
}
|
|
|
|
if (!set.Indicatori[0].RischioMercato)
|
|
{ // INDICATORE "RischioCredito" NO
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Image(fileNo, document.getMargineLeft() + 437, tabellaPatrimonio.Y + 18, 0.15F));
|
|
}
|
|
else
|
|
{ // INDICATORE "RischioMercato" OK
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Image(fileOk, document.getMargineLeft() + 437, tabellaPatrimonio.Y + 18, 0.15F));
|
|
}
|
|
|
|
#endregion
|
|
|
|
|
|
if (dataThread.profiloIsAct == false)
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label(Resource.Nota_S96_Scaduto, datitab.getX(), datitab.getY() + datitab.GetRowDim() * (datitab.table.Rows.Count + 1), 500F, 30F, Globals.OpenTypeFontVerdana, 8, ceTe.DynamicPDF.CmykColor.Red));
|
|
|
|
dimTabella = tabellaPatrimonio.AltezzaTabella;
|
|
#endregion
|
|
|
|
#endregion
|
|
|
|
#region indicatori Monitoraggio
|
|
////
|
|
//// Inseriamo gli Indicatori: non vengono visualizzati se il cliente
|
|
//// non e' mai stato profilato o se il profilo e' scaduto
|
|
//// Non vengono visualizzati se il rischio credito max o il rischio mercato max sono uguali ad "N.C."
|
|
//// se rischio credito max = n.a. ugualmente non facciamo vedere le frecce.
|
|
////
|
|
|
|
float xIndicatore = document.getMargineLeft();
|
|
//float yIndicatore = document.getLastPos() + grafico.Height + dimTabella + 35;
|
|
float yIndicatore = document.getLastPos() + grafico.Height + dimTabella + 35;
|
|
|
|
|
|
|
|
//if (dataThread.TipoReport.ToUpper() == "MONITORAGGIO" && dataThread.profiloIsAct && (varMassimo > 0) && (classeRiskCredMax > 0))
|
|
//{
|
|
// string flagOK = WebConfigParameter.getParameter("FlagOK_RIDOTTA");
|
|
// string flagNO = WebConfigParameter.getParameter("FlagNO_RIDOTTA");
|
|
|
|
// System.Reflection.Assembly thisExe;
|
|
// thisExe = System.Reflection.Assembly.GetExecutingAssembly();
|
|
// System.IO.Stream fileOk = thisExe.GetManifestResourceStream(flagOK);
|
|
// System.IO.Stream fileNo = thisExe.GetManifestResourceStream(flagNO);
|
|
|
|
// // Indicatore Rischio Mercato
|
|
// if (!set.Indicatori[0].RischioMercato)
|
|
// { // INDICATORE "RischioMercato" NO
|
|
// page.Elements.Add(new ceTe.DynamicPDF.PageElements.Image(fileNo, document.getMargineLeft(), yIndicatore, 0.15F)); //0.2F
|
|
// page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("Il livello di Rischio Mercato dei Suoi Investimenti è, oggi, NON coerente con il Suo profilo finanziario.", xIndicatore + 25, yIndicatore, 512, 12, Globals.OpenTypeFontVerdana, 7));
|
|
// }
|
|
// else
|
|
// { // INDICATORE "RischioMercato" OK
|
|
// page.Elements.Add(new ceTe.DynamicPDF.PageElements.Image(fileOk, document.getMargineLeft(), yIndicatore, 0.15F));
|
|
// page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("Il livello di Rischio Mercato dei Suoi Investimenti è, oggi, coerente con il Suo profilo finanziario.", xIndicatore + 25, yIndicatore, 512, 12, Globals.OpenTypeFontVerdana, 7));
|
|
// }
|
|
|
|
// yIndicatore += 20;
|
|
// // Indicatore Rischio Credito
|
|
// if (!set.Indicatori[0].RischioCredito)
|
|
// { // INDICATORE "RischioCredito" NO
|
|
// page.Elements.Add(new ceTe.DynamicPDF.PageElements.Image(fileNo, xIndicatore, yIndicatore, 0.15F));
|
|
// page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("Il livello di Rischio Credito dei Suoi Investimenti è, oggi, NON coerente con il Suo profilo finanziario.", xIndicatore + 25, yIndicatore, 512, 12, Globals.OpenTypeFontVerdana, 7));
|
|
// }
|
|
// else
|
|
// { // INDICATORE "RischioCredito" OK
|
|
// page.Elements.Add(new ceTe.DynamicPDF.PageElements.Image(fileOk, xIndicatore, yIndicatore, 0.15F));
|
|
// page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("Il livello di Rischio Credito dei Suoi Investimenti è, oggi, coerente con il Suo profilo finanziario.", xIndicatore + 25, yIndicatore, 512, 12, Globals.OpenTypeFontVerdana, 7));
|
|
// // page.Elements.Add(new ceTe.DynamicPDF.PageElements.
|
|
// }
|
|
//document.setLastPos(600);
|
|
|
|
|
|
//V Spostare nel resource file
|
|
//
|
|
// Indicatore Complessita'
|
|
//
|
|
//yIndicatore += 20;
|
|
|
|
|
|
#region AdeguadezzaCompl
|
|
|
|
string labelText = SimpleTextGenerator.ProduceText(this, "BottomLabel", dataThread, null);//new object[1] { set.Indicatori[0].Complessita }
|
|
if (labelText == String.Empty)
|
|
throw new GeneratorException("missing label data for S132");
|
|
page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label(labelText, xIndicatore, yIndicatore, 512, 24, Globals.OpenTypeFontVerdana, 7));
|
|
//commented by pk
|
|
//if (set.Indicatori[0].Complessita)
|
|
// page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("Tutti gli strumenti finanziari nel Suo portafoglio risultano avere una complessità coerente con il Suo livello di esperienza e conoscenza risultante dal questionario di profilatura.", xIndicatore, yIndicatore, 512, 24, Globals.OpenTypeFontVerdana, 7));
|
|
//else
|
|
// page.Elements.Add(new ceTe.DynamicPDF.PageElements.Label("Alcuni strumenti finanziari nel suo portafoglio risultano avere una complessità elevata rispetto al Suo livello di esperienza e conoscenza risultante dal questionario di profilatura.", xIndicatore, yIndicatore, 512, 24, Globals.OpenTypeFontVerdana, 7));
|
|
#endregion
|
|
// }
|
|
#endregion
|
|
|
|
|
|
//aggiorno il puntatore alla posizione da cui si può scrivere
|
|
//document.setLastPos(600);
|
|
document.addPage();
|
|
}
|
|
|
|
|
|
|
|
}
|
|
}
|