Files
MoonPro.net/MP-Site/WebUserControls/baseProdControl.cs
T
2020-03-02 18:44:39 +01:00

60 lines
1.3 KiB
C#

using MapoDb;
using System;
namespace MP_SITE.WebUserControls
{
public class baseProdControl : System.Web.UI.UserControl
{
/// <summary>
/// Oggetto datalayer specifico
/// </summary>
DataLayer DataLayerObj = new DataLayer();
/// <summary>
/// evento update
/// </summary>
public event EventHandler eh_doUpdate;
protected resoconti _resoconti;
protected int _numRighe = 17;
protected void Page_Load(object sender, EventArgs e)
{
_resoconti = new resoconti();
if (!Page.IsPostBack)
{
aggiornamento();
}
}
public virtual void aggiornamento()
{
}
public int numRighe
{
get
{
return _numRighe;
}
set
{
_numRighe = value;
}
}
public void reportUpdate()
{
// alzo l'evento d update/inserimento e ricarico cache...
if (eh_doUpdate != null)
{
eh_doUpdate(this, new EventArgs());
}
}
/// <summary>
/// Verifica se la macchina MAIN sia MULTI (da DatiMacchina / redis...)
/// </summary>
/// <param name="idxMacchina"></param>
/// <returns></returns>
protected bool isMulti(string idxMacchina)
{
return DataLayerObj.isMulti(idxMacchina);
}
}
}