ab3ba0881e
- refresh dettaglio macchina - gestione eventi disposed
96 lines
2.8 KiB
C#
96 lines
2.8 KiB
C#
using System;
|
|
|
|
namespace MoonProTablet
|
|
{
|
|
public partial class Commenti : BasePage
|
|
{
|
|
#region Public Methods
|
|
|
|
public override void Dispose()
|
|
{
|
|
mod_insComm1.eh_newVal -= mod_insComm1_eh_newVal;
|
|
mod_insComm1.eh_reset -= mod_insComm1_eh_reset;
|
|
mod_insComm1.eh_inserting -= mod_insComm1_eh_inserting;
|
|
mod_commenti1.eh_reqEdit -= mod_commenti1_eh_reqEdit;
|
|
mod_fermate1.eh_reqEdit -= mod_fermate1_eh_reqEdit;
|
|
base.Dispose();
|
|
}
|
|
|
|
#endregion Public Methods
|
|
|
|
#region Protected Methods
|
|
|
|
protected void Page_Load(object sender, EventArgs e)
|
|
{
|
|
if (!Page.IsPostBack)
|
|
{
|
|
mod_dettMacchina1.doUpdate();
|
|
}
|
|
Session["TipoLink"] = "EditMacch";
|
|
mod_insComm1.eh_newVal += mod_insComm1_eh_newVal;
|
|
mod_insComm1.eh_reset += mod_insComm1_eh_reset;
|
|
mod_insComm1.eh_inserting += mod_insComm1_eh_inserting;
|
|
mod_commenti1.eh_reqEdit += mod_commenti1_eh_reqEdit;
|
|
mod_fermate1.eh_reqEdit += mod_fermate1_eh_reqEdit;
|
|
}
|
|
|
|
#endregion Protected Methods
|
|
|
|
#region Private Methods
|
|
|
|
/// <summary>
|
|
/// richiesta ins nuovo evento...
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
private void mod_commenti1_eh_newVal(object sender, EventArgs e)
|
|
{
|
|
showPnlDichiaraz(true);
|
|
}
|
|
|
|
private void mod_commenti1_eh_reqEdit(object sender, EventArgs e)
|
|
{
|
|
mod_insComm1.caricaCommento();
|
|
}
|
|
|
|
private void mod_commenti1_eh_reset(object sender, EventArgs e)
|
|
{
|
|
showPnlDichiaraz(false);
|
|
}
|
|
|
|
private void mod_dichiarazione1_eh_newVal(object sender, EventArgs e)
|
|
{
|
|
// ricarico tutto!
|
|
Response.Redirect("Commenti.aspx");
|
|
}
|
|
|
|
private void mod_fermate1_eh_reqEdit(object sender, EventArgs e)
|
|
{
|
|
// avendo in sessione inizio fermata DEVO andare a pagina DichFermi, in modalità
|
|
// "ritroso", precompilare data/ora ed eventuale descizione...
|
|
Response.Redirect("Fermate.aspx");
|
|
}
|
|
|
|
private void mod_insComm1_eh_inserting(object sender, EventArgs e)
|
|
{
|
|
}
|
|
|
|
private void mod_insComm1_eh_newVal(object sender, EventArgs e)
|
|
{
|
|
mod_commenti1.doUpdate();
|
|
}
|
|
|
|
private void mod_insComm1_eh_reset(object sender, EventArgs e)
|
|
{
|
|
showPnlDichiaraz(false);
|
|
mod_commenti1.doUpdate();
|
|
}
|
|
|
|
private void showPnlDichiaraz(bool showDich)
|
|
{
|
|
pnlEventi.Visible = !showDich;
|
|
}
|
|
|
|
#endregion Private Methods
|
|
}
|
|
} |