83 lines
2.5 KiB
C#
83 lines
2.5 KiB
C#
namespace SteamWare
|
|
{
|
|
/// <summary>
|
|
/// classe di wrap verso i TableAdapter dell'area billing
|
|
/// </summary>
|
|
public class BillingProxy
|
|
{
|
|
#region area protected
|
|
|
|
/// <summary>
|
|
/// metodo protected di avvio della classe
|
|
/// </summary>
|
|
protected BillingProxy()
|
|
{
|
|
// inizializzo i table adapters
|
|
avvioTableAdapters();
|
|
setupConnectionString();
|
|
}
|
|
|
|
/// <summary>
|
|
/// procedura di avvio dei tableAdapter
|
|
/// </summary>
|
|
protected virtual void avvioTableAdapters()
|
|
{
|
|
taClienti = new DS_BillingTableAdapters.clientiTableAdapter();
|
|
taCostiAss = new DS_BillingTableAdapters.CostiAssorbitiTableAdapter();
|
|
taDocs = new DS_BillingTableAdapters.DocumentiTableAdapter();
|
|
taRows = new DS_BillingTableAdapters.RigheTableAdapter();
|
|
taScad = new DS_BillingTableAdapters.ScadenzeTableAdapter();
|
|
taVAT = new DS_BillingTableAdapters.VATTableAdapter();
|
|
}
|
|
/// <summary>
|
|
/// effettua setup dei connection strings da web.config delal singola applicazione
|
|
/// </summary>
|
|
protected virtual void setupConnectionString()
|
|
{
|
|
string connStr = memLayer.ML.CRS("BilligConnectionString");
|
|
taClienti.Connection.ConnectionString = connStr;
|
|
taCostiAss.Connection.ConnectionString = connStr;
|
|
taDocs.Connection.ConnectionString = connStr;
|
|
taRows.Connection.ConnectionString = connStr;
|
|
taScad.Connection.ConnectionString = connStr;
|
|
taVAT.Connection.ConnectionString = connStr;
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region area public
|
|
|
|
/// <summary>
|
|
/// tableAdapter documenti
|
|
/// </summary>
|
|
public DS_BillingTableAdapters.clientiTableAdapter taClienti;
|
|
/// <summary>
|
|
/// tableAdapter documenti
|
|
/// </summary>
|
|
public DS_BillingTableAdapters.CostiAssorbitiTableAdapter taCostiAss;
|
|
/// <summary>
|
|
/// tableAdapter documenti
|
|
/// </summary>
|
|
public DS_BillingTableAdapters.DocumentiTableAdapter taDocs;
|
|
/// <summary>
|
|
/// tableAdapter documenti
|
|
/// </summary>
|
|
public DS_BillingTableAdapters.RigheTableAdapter taRows;
|
|
/// <summary>
|
|
/// tableAdapter documenti
|
|
/// </summary>
|
|
public DS_BillingTableAdapters.ScadenzeTableAdapter taScad;
|
|
/// <summary>
|
|
/// tableAdapter documenti
|
|
/// </summary>
|
|
public DS_BillingTableAdapters.VATTableAdapter taVAT;
|
|
|
|
/// <summary>
|
|
/// classe singleton x la gestione dei tableadapters
|
|
/// </summary>
|
|
public static BillingProxy man = new BillingProxy();
|
|
|
|
#endregion
|
|
}
|
|
}
|