762 lines
20 KiB
C#
762 lines
20 KiB
C#
using GMW_data;
|
|
using SteamWare;
|
|
using System;
|
|
using System.Web.UI;
|
|
|
|
namespace GMW.WebUserControls
|
|
{
|
|
public partial class mod_manSAO : System.Web.UI.UserControl
|
|
{
|
|
#region variabili con persistenza da sessione
|
|
|
|
/// <summary>
|
|
/// idxEvento selezionato
|
|
/// </summary>
|
|
protected int idxEvento
|
|
{
|
|
get
|
|
{
|
|
return memLayer.ML.IntSessionObj(string.Format("idxEvento_{0}", this.ID));
|
|
}
|
|
set
|
|
{
|
|
memLayer.ML.setSessionVal(string.Format("idxEvento_{0}", this.ID), value);
|
|
}
|
|
}
|
|
/// <summary>
|
|
/// udc correntemente selezionato
|
|
/// </summary>
|
|
protected string udcSel
|
|
{
|
|
get
|
|
{
|
|
return memLayer.ML.StringSessionObj("udcSelSAO");
|
|
}
|
|
set
|
|
{
|
|
memLayer.ML.setSessionVal("udcSelSAO", value);
|
|
memLayer.ML.setSessionVal("UDS_sel", value);
|
|
memLayer.ML.setSessionVal("FullSearchValue", value);
|
|
}
|
|
}
|
|
/// <summary>
|
|
/// definisce se sia possibile cambiare le postazioni
|
|
/// </summary>
|
|
public bool canSelPost
|
|
{
|
|
get
|
|
{
|
|
return filtroPostazione.changeSelEnabled;
|
|
}
|
|
set
|
|
{
|
|
filtroPostazione.changeSelEnabled = value;
|
|
}
|
|
}
|
|
/// <summary>
|
|
/// calcola postazione corrente (ip, name, printer)
|
|
/// </summary>
|
|
private void calcolaPostazione()
|
|
{
|
|
postazione_IP = Request.UserHostName;
|
|
postazione_name = dnsUtils.DetermineCompName(postazione_IP);
|
|
// cerco stampante x postazione
|
|
postazione_printer = "n.d.";
|
|
try
|
|
{
|
|
DS_Applicazione.ElencoPostazioniDataTable tabPost = DataProxy.obj.taElPost.getByCod(postazione_name);
|
|
if (tabPost.Rows.Count > 0)
|
|
{
|
|
postazione_printer = tabPost[0].stampante;
|
|
}
|
|
else
|
|
{
|
|
tabPost = DataProxy.obj.taElPost.getByCod("default");
|
|
postazione_printer = tabPost[0].stampante;
|
|
}
|
|
}
|
|
catch
|
|
{ }
|
|
}
|
|
/// <summary>
|
|
/// udc da stampare
|
|
/// </summary>
|
|
protected string udcReq
|
|
{
|
|
get
|
|
{
|
|
return memLayer.ML.StringSessionObj("udcSelSAO");
|
|
}
|
|
}
|
|
/// <summary>
|
|
/// indica ip della postazione corrente
|
|
/// </summary>
|
|
protected string postazione_IP
|
|
{
|
|
get
|
|
{
|
|
return memLayer.ML.StringSessionObj("postazione_IP");
|
|
}
|
|
set
|
|
{
|
|
memLayer.ML.setSessionVal("postazione_IP", value);
|
|
}
|
|
}
|
|
/// <summary>
|
|
/// indica name della postazione corrente
|
|
/// </summary>
|
|
protected string postazione_name
|
|
{
|
|
get
|
|
{
|
|
return memLayer.ML.StringSessionObj("postazione_name");
|
|
}
|
|
set
|
|
{
|
|
memLayer.ML.setSessionVal("postazione_name", value);
|
|
}
|
|
}
|
|
/// <summary>
|
|
/// indica name della postazione correntemente SELEZIONATA
|
|
/// </summary>
|
|
protected string postazione_nameSel
|
|
{
|
|
get
|
|
{
|
|
return memLayer.ML.StringSessionObj("postazione_nameSel");
|
|
}
|
|
set
|
|
{
|
|
memLayer.ML.setSessionVal("postazione_nameSel", value);
|
|
}
|
|
}
|
|
/// <summary>
|
|
/// indica stampante associata alla postazione corrente
|
|
/// </summary>
|
|
protected string postazione_printer
|
|
{
|
|
get
|
|
{
|
|
return memLayer.ML.StringSessionObj("postazione_printer");
|
|
}
|
|
set
|
|
{
|
|
memLayer.ML.setSessionVal("postazione_printer", value);
|
|
}
|
|
}
|
|
/// <summary>
|
|
/// IdxPosizione abilitata x cancellazione
|
|
/// </summary>
|
|
public int idxPosizione2del
|
|
{
|
|
get
|
|
{
|
|
return memLayer.ML.IntSessionObj(string.Format("IdxPosizione_{0}", this.ID));
|
|
}
|
|
set
|
|
{
|
|
memLayer.ML.setSessionVal(string.Format("IdxPosizione_{0}", this.ID), value);
|
|
}
|
|
}
|
|
/// <summary>
|
|
/// numero righe gridview da mostrare legato a controllo textbox
|
|
/// </summary>
|
|
public int numRigheGrView
|
|
{
|
|
get
|
|
{
|
|
int answ = 20;
|
|
try
|
|
{
|
|
answ = Convert.ToInt32(txtNumRighe.Text.Trim());
|
|
if (answ == 0)
|
|
{
|
|
answ = memLayer.ML.cdvi("_righeDataGridMed");
|
|
txtNumRighe.Text = answ.ToString();
|
|
}
|
|
}
|
|
catch
|
|
{ }
|
|
return answ;
|
|
}
|
|
set
|
|
{
|
|
txtNumRighe.Text = value.ToString();
|
|
}
|
|
}
|
|
/// <summary>
|
|
/// cod soggetto selezionato
|
|
/// </summary>
|
|
public string CodSoggettoSAO
|
|
{
|
|
get
|
|
{
|
|
return memLayer.ML.StringSessionObj("CodSoggettoSAO");
|
|
}
|
|
set
|
|
{
|
|
memLayer.ML.setSessionVal("CodSoggettoSAO", value);
|
|
}
|
|
}
|
|
/// <summary>
|
|
/// cod azione selezionato
|
|
/// </summary>
|
|
public string CodAzioneUt
|
|
{
|
|
get
|
|
{
|
|
return memLayer.ML.StringSessionObj("CodAzioneUt");
|
|
}
|
|
set
|
|
{
|
|
memLayer.ML.setSessionVal("CodAzioneUt", value);
|
|
}
|
|
}
|
|
/// <summary>
|
|
/// udc selezionato
|
|
/// </summary>
|
|
public string udcSAO
|
|
{
|
|
get
|
|
{
|
|
return memLayer.ML.StringSessionObj("UdcSAO");
|
|
}
|
|
set
|
|
{
|
|
memLayer.ML.setSessionVal("UdcSAO", value);
|
|
}
|
|
}
|
|
/// <summary>
|
|
/// particolare selezionato
|
|
/// </summary>
|
|
public string ParticSAO
|
|
{
|
|
get
|
|
{
|
|
return memLayer.ML.StringSessionObj("ParticSAO");
|
|
}
|
|
set
|
|
{
|
|
memLayer.ML.setSessionVal("ParticSAO", value);
|
|
}
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region init pagina
|
|
|
|
/// <summary>
|
|
/// caricamento pagina
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
protected void Page_Load(object sender, EventArgs e)
|
|
{
|
|
if (!Page.IsPostBack)
|
|
{
|
|
calcolaPostazione();
|
|
setFilterOds();
|
|
// disattivo filtri a primo caricamento
|
|
filtroAzioni.isChecked = false;
|
|
filtroPostazione.isChecked = false;
|
|
filtroSoggetto.isChecked = false;
|
|
filtroParticolare.isChecked = false;
|
|
// forzo a empty postazione corrente/filtro
|
|
postazione_nameSel = "*";
|
|
// altri parametri
|
|
idxEvento = -1;
|
|
numRigheGrView = 20;
|
|
updateFiltroUdc();
|
|
aggiornaControlliDataGL();
|
|
}
|
|
setBtnState();
|
|
filtroPostazione.eh_selValore += new EventHandler(filtroPostazione_eh_selValore);
|
|
filtroSoggetto.eh_selValore += new EventHandler(filtroSoggetto_eh_selValore);
|
|
filtroAzioni.eh_selValore += new EventHandler(filtroAzioni_eh_selValore);
|
|
filtroParticolare.eh_selValore += new EventHandler(filtroParticolare_eh_selValore);
|
|
mod_periodoAnalisi1.eh_doUpdate += new EventHandler(mod_periodoAnalisi1_eh_doUpdate);
|
|
traduciObj();
|
|
}
|
|
|
|
private void setFilterOds()
|
|
{
|
|
filtroPostazione.ods = odsPostazione;
|
|
filtroSoggetto.ods = odsSoggetto;
|
|
filtroAzioni.ods = odsAzioni;
|
|
filtroParticolare.ods = odsPartic;
|
|
}
|
|
|
|
/// <summary>
|
|
/// wrapper traduzione
|
|
/// </summary>
|
|
/// <param name="lemma"></param>
|
|
/// <returns></returns>
|
|
public string traduci(object lemma)
|
|
{
|
|
return user_std.UtSn.Traduci(lemma.ToString());
|
|
}
|
|
/// <summary>
|
|
/// sistema labels
|
|
/// </summary>
|
|
private void traduciObj()
|
|
{
|
|
btnElimina.Text = traduci("btnEliminaUDC");
|
|
btnStampa.Text = traduci("btnRiStampaUdc");
|
|
lblNumRighe.Text = traduci("lblNumRighe");
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region controlli ed utility x visualizzazione dati
|
|
|
|
/// <summary>
|
|
/// ssitema visualizzazione dal filtraggi
|
|
/// </summary>
|
|
private void checkFixOds()
|
|
{
|
|
grView.DataBind();
|
|
}
|
|
/// <summary>
|
|
/// restituisce url immagine da cod azione
|
|
/// </summary>
|
|
/// <param name="codAzione"></param>
|
|
/// <returns></returns>
|
|
public string imgAzione(object codAzione)
|
|
{
|
|
string answ = "";
|
|
try
|
|
{
|
|
answ = string.Format("~/images/{0}_m.png", codAzione);
|
|
}
|
|
catch
|
|
{ }
|
|
return answ;
|
|
}
|
|
/// <summary>
|
|
/// sistema visibilità/abilitazione buttons
|
|
/// </summary>
|
|
private void setBtnState()
|
|
{
|
|
bool abilita = false;
|
|
btnElimina.Visible = false;
|
|
bool showDelUdc = false;
|
|
// se ho udc selezionato verifico se sia eliminabile
|
|
if (udcSel != "")
|
|
{
|
|
// controllo con stored SE sia possibile cancellare UDC:
|
|
// inizio stringa può essere OK --> mostro delete (e POTREI aggiungere nota su cosa sia e che posso cancellare)
|
|
// ERR --> NON mostro delete ma solo errore
|
|
|
|
string answ = "";
|
|
MagClass.magazzino.taUdcChk4Del.GetData(udcSel, ref answ);
|
|
// controllo esito
|
|
if (answ.StartsWith("OK"))
|
|
{
|
|
showDelUdc = true;
|
|
}
|
|
lblOutChkDelUdc.Text = traduci(answ);
|
|
btnElimina.Visible = showDelUdc;
|
|
lblOutChkDelUdc.Visible = !showDelUdc;
|
|
}
|
|
if (idxEvento > 0 && udcSel != "")
|
|
{
|
|
if (MagClass.magazzino.checkUDC(udcSel) || (MagClass.magazzino.checkAL(udcSel) && udcSel.StartsWith("A")))
|
|
{
|
|
abilita = true;
|
|
}
|
|
}
|
|
|
|
// 2014.06.22 visibile stampa se è ok x abilitazione elimina...
|
|
btnStampa.Visible = abilita;
|
|
btnElimina.Enabled = abilita;
|
|
// se è AL NON permetto ristampa (SE consumato)
|
|
if (udcSel.StartsWith("A"))
|
|
{
|
|
btnStampa.Visible = showDelUdc;
|
|
}
|
|
// fix pnl dettaglio UDC
|
|
pnlDettUDC.Visible = memLayer.ML.isInSessionObject("udcSelSAO");
|
|
}
|
|
/// <summary>
|
|
/// resetta la selezione dei valori in caso di modifiche su altri controlli
|
|
/// </summary>
|
|
public void resetSelezione()
|
|
{
|
|
memLayer.ML.emptySessionVal("udcSelSAO");
|
|
idxEvento = -1;
|
|
try
|
|
{
|
|
grView.SelectedIndex = -1;
|
|
grView.DataBind();
|
|
}
|
|
catch
|
|
{ }
|
|
// aggiorno tutti gli ODS
|
|
setFilterOds();
|
|
// fix button
|
|
setBtnState();
|
|
}
|
|
/// <summary>
|
|
/// forza update controllo
|
|
/// </summary>
|
|
public void doUpdate()
|
|
{
|
|
memLayer.ML.setSessionVal("dataFromPost", DateTime.Now.AddDays(-7));
|
|
memLayer.ML.setSessionVal("dataToPost", DateTime.Now.AddDays(1));
|
|
grView.DataBind();
|
|
}
|
|
/// <summary>
|
|
/// converte CodSoggetto in cognome/nome
|
|
/// </summary>
|
|
/// <param name="codOperatore"></param>
|
|
/// <returns></returns>
|
|
public string getOperatoreByCod(object CodSoggetto)
|
|
{
|
|
return utils.obj.getOperatoreByCod(CodSoggetto.ToString());
|
|
}
|
|
|
|
#endregion
|
|
|
|
#region controlli interazione (buttons, gridviews)
|
|
|
|
/// <summary>
|
|
/// richiede stampa
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
protected void btnStampa_Click(object sender, EventArgs e)
|
|
{
|
|
// effettua ristampa usando metodo "ad hoc" di ristampa da prima creazione
|
|
bool fatto = false;
|
|
// registro ri-stampa UDC
|
|
DateTime adesso = DateTime.Now;
|
|
// calcolo particolare...
|
|
DS_magazzino.ElencoCartelliniRow rigaUDC;
|
|
string particolare = "";
|
|
try
|
|
{
|
|
rigaUDC = MagClass.magazzino.taCartellini.getByUdc(udcReq)[0];
|
|
particolare = rigaUDC.Particolare;
|
|
fatto = MagClass.magazzino.ristampaUdc(udcReq, Postazione.printer, Request.UserHostName);
|
|
}
|
|
catch
|
|
{
|
|
logger.lg.scriviLog(string.Format("Errore recupero particolare in ManSAO, UDC: {0}", udcReq), tipoLog.EXCEPTION);
|
|
}
|
|
if (fatto)
|
|
{
|
|
MagClass.magazzino.taSAO.insertQuery(adesso, MagClass.magazzino.CodSoggCurrUser, Postazione.name, Postazione.IP, udcReq, particolare, "stampaUDC", "Ri-Stampato UDC ");
|
|
}
|
|
// reset finale
|
|
resetSelezione();
|
|
}
|
|
/// <summary>
|
|
/// Effettua eliminazione
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
protected void btnElimina_Click(object sender, EventArgs e)
|
|
{
|
|
//in primis ricalcolo la postazione...
|
|
calcolaPostazione();
|
|
/**********************************************
|
|
* controllo che l'UDC
|
|
* - esista
|
|
* - NON SIA in liste di prelievo
|
|
* - IdxPosizione > 0 (PRIMA controllavo fosse = IdxPosizione2del)
|
|
**********************************************/
|
|
// check condizioni
|
|
bool okLDP = false;
|
|
bool okIdxPos = false;
|
|
string particolare = "";
|
|
DS_magazzino.ElencoCartelliniRow rigaUDC;
|
|
// verifica preliminare della possibilità di cancellazione...
|
|
string answ = "";
|
|
MagClass.magazzino.taUdcChk4Del.GetData(udcReq, ref answ);
|
|
lblOutChkDelUdc.Visible = true;
|
|
// controllo esito
|
|
if (answ.StartsWith("OK"))
|
|
{
|
|
// controllo UDC esista
|
|
if (MagClass.magazzino.checkUDC(udcReq))
|
|
{
|
|
try
|
|
{
|
|
rigaUDC = MagClass.magazzino.taCartellini.getByUdc(udcReq)[0];
|
|
if (rigaUDC.IdxPosizione >= 0) // permette di cancellare SOLO posizioni > 0 cioè valide
|
|
{
|
|
okIdxPos = true;
|
|
}
|
|
particolare = rigaUDC.Particolare;
|
|
}
|
|
catch
|
|
{ }
|
|
try
|
|
{
|
|
// non sia in alcuna LDP
|
|
okLDP = (MagClass.magazzino.taRigheListePrelievo.getByUdc(udcReq).Count == 0);
|
|
}
|
|
catch
|
|
{ }
|
|
|
|
if (okLDP && okIdxPos)
|
|
{
|
|
// a questo punto elimino UDC
|
|
MagClass.magazzino.taCartellini.deleteUDC(udcReq);
|
|
// indico che è stato cancellato
|
|
lblOutChkDelUdc.Text = traduci("Udc_deleted");
|
|
// registro eliminazione nuovo UDC
|
|
DateTime adesso = DateTime.Now;
|
|
MagClass.magazzino.taSAO.insertQuery(adesso, MagClass.magazzino.CodSoggCurrUser, postazione_nameSel, postazione_IP, udcReq, particolare, "eliminaUDC", "Eliminato UDC");
|
|
}
|
|
// reset finale
|
|
resetSelezione();
|
|
// resetto postazione...
|
|
postazione_nameSel = "*";
|
|
}
|
|
// controllo sia AL ed esista...
|
|
else if (udcReq.StartsWith("A") && MagClass.magazzino.checkAL(udcReq))
|
|
{
|
|
// posso procedere con eliminazione DI TUTTI gli UDC
|
|
foreach (var rigaAL2UDC in MagClass.magazzino.taAL2UDC.getByAL(udcReq))
|
|
{
|
|
eliminaUDC(rigaAL2UDC.UDC);
|
|
}
|
|
// ...e poi posso anche DISATTIVARE l'AL...
|
|
MagClass.magazzino.taEA.DisattivaAL(udcReq);
|
|
// indico che è stato cancellato
|
|
lblOutChkDelUdc.Text = traduci("KIT_deleted");
|
|
string codKIT = MagClass.magazzino.taEA.getByAL(udcReq)[0].CodKIT;
|
|
DateTime adesso = DateTime.Now;
|
|
MagClass.magazzino.taSAO.insertQuery(adesso, MagClass.magazzino.CodSoggCurrUser, postazione_name, postazione_IP, udcReq, codKIT, "eliminaUDC", "Eliminato UDC + disattivato AL");
|
|
}
|
|
}
|
|
else
|
|
{
|
|
// scrivo errore che non posso cancellare...
|
|
lblOutChkDelUdc.Text = traduci(answ);
|
|
}
|
|
// faccio update grView!
|
|
grView.DataBind();
|
|
}
|
|
/// <summary>
|
|
/// Elimino ogni UDC dell'AL...
|
|
/// </summary>
|
|
/// <param name="UDC"></param>
|
|
private void eliminaUDC(string UDC)
|
|
{
|
|
DS_magazzino.ElencoCartelliniRow rigaUDC;
|
|
bool okLDP = false;
|
|
bool okIdxPos = false;
|
|
string particolare = "";
|
|
try
|
|
{
|
|
rigaUDC = MagClass.magazzino.taCartellini.getByUdc(UDC)[0];
|
|
if (rigaUDC.IdxPosizione >= 0)
|
|
{
|
|
okIdxPos = true;
|
|
}
|
|
particolare = rigaUDC.Particolare;
|
|
}
|
|
catch (Exception exc)
|
|
{
|
|
logger.lg.scriviLog(string.Format("Eccezione in eliminaUDC{0}{1}", Environment.NewLine, exc));
|
|
}
|
|
try
|
|
{
|
|
// non sia in alcuna LDP
|
|
okLDP = (MagClass.magazzino.taRigheListePrelievo.getByUdc(UDC).Count == 0);
|
|
}
|
|
catch
|
|
{ }
|
|
|
|
if (okLDP && okIdxPos)
|
|
{
|
|
// a questo punto elimino UDC
|
|
MagClass.magazzino.taCartellini.deleteUDC(UDC);
|
|
}
|
|
}
|
|
/// <summary>
|
|
/// reset della selezione
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
protected void btnReset_Click(object sender, EventArgs e)
|
|
{
|
|
resetSelezione();
|
|
}
|
|
/// <summary>
|
|
/// gestione evento select
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
protected void grView_SelectedIndexChanged(object sender, EventArgs e)
|
|
{
|
|
// salvo idxEvento x abilitare buttons
|
|
idxEvento = Convert.ToInt32(grView.SelectedDataKey["idxEvento"]);
|
|
// salvo UDC x reprint
|
|
string udc = "";
|
|
try
|
|
{
|
|
udc = MagClass.magazzino.taSAO.getByIdxEvento(idxEvento)[0].UDC;
|
|
}
|
|
catch
|
|
{ }
|
|
if (udc != "")
|
|
{
|
|
udcSel = udc;
|
|
bool showCurUdc = false;
|
|
// verifico UDC valido (non cancellato!!!)
|
|
if (MagClass.magazzino.checkUDC(udc))
|
|
{
|
|
showCurUdc = true;
|
|
}
|
|
mod_detailUDC1.Visible = showCurUdc;
|
|
mod_detailUDC_storico1.Visible = !showCurUdc;
|
|
}
|
|
else
|
|
{
|
|
udcSel = "";
|
|
}
|
|
setBtnState();
|
|
}
|
|
/// <summary>
|
|
/// gestione evento selezione
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
public void filtroPostazione_eh_selValore(object sender, EventArgs e)
|
|
{
|
|
resetSelezione();
|
|
postazione_nameSel = filtroPostazione.valore;
|
|
checkFixOds();
|
|
}
|
|
/// <summary>
|
|
/// evento selezione soggetto
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
void filtroSoggetto_eh_selValore(object sender, EventArgs e)
|
|
{
|
|
resetSelezione();
|
|
CodSoggettoSAO = filtroSoggetto.valore;
|
|
checkFixOds();
|
|
}
|
|
/// <summary>
|
|
/// evento scelta azioni
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
void filtroAzioni_eh_selValore(object sender, EventArgs e)
|
|
{
|
|
resetSelezione();
|
|
CodAzioneUt = filtroAzioni.valore;
|
|
checkFixOds();
|
|
}
|
|
/// <summary>
|
|
/// update UDC filtrato
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
protected void txtUdcSAO_TextChanged(object sender, EventArgs e)
|
|
{
|
|
updateFiltroUdcSAO(txtUdcSAO.Text.Trim());
|
|
}
|
|
/// <summary>
|
|
/// verifico filtro x UDC
|
|
/// </summary>
|
|
/// <param name="UDC"></param>
|
|
private void updateFiltroUdcSAO(string _udc)
|
|
{
|
|
resetSelezione();
|
|
udcSAO = _udc;
|
|
checkFixOds();
|
|
}
|
|
/// <summary>
|
|
/// verifica se deve cambiare filtro x UDC
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
protected void chkFiltraUdcSAO_CheckedChanged(object sender, EventArgs e)
|
|
{
|
|
updateFiltroUdc();
|
|
}
|
|
/// <summary>
|
|
/// sistema filtro UDC
|
|
/// </summary>
|
|
private void updateFiltroUdc()
|
|
{
|
|
txtUdcSAO.Visible = chkFiltraUdcSAO.Checked;
|
|
if (chkFiltraUdcSAO.Checked)
|
|
{
|
|
updateFiltroUdcSAO(txtUdcSAO.Text.Trim());
|
|
chkFiltraUdcSAO.Text = traduci("mostraSoloSelez");
|
|
}
|
|
else
|
|
{
|
|
updateFiltroUdcSAO("*");
|
|
chkFiltraUdcSAO.Text = traduci("filtraUdcSAO");
|
|
}
|
|
}
|
|
/// <summary>
|
|
/// evento scelta particolare
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
void filtroParticolare_eh_selValore(object sender, EventArgs e)
|
|
{
|
|
resetSelezione();
|
|
ParticSAO = filtroParticolare.valore;
|
|
checkFixOds();
|
|
}
|
|
/// <summary>
|
|
/// aggiorno controllo paginazione...
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
protected void txtNumRighe_TextChanged(object sender, EventArgs e)
|
|
{
|
|
resetSelezione();
|
|
aggiornaControlliDataGL();
|
|
checkFixOds();
|
|
}
|
|
/// <summary>
|
|
/// aggiornamento dati
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
void mod_periodoAnalisi1_eh_doUpdate(object sender, EventArgs e)
|
|
{
|
|
resetSelezione();
|
|
aggiornaControlliDataGL();
|
|
checkFixOds();
|
|
}
|
|
/// <summary>
|
|
/// aggiorna controlli datagrid e numero righe in pagina
|
|
/// </summary>
|
|
protected void aggiornaControlliDataGL()
|
|
{
|
|
// indico num righe da controllo
|
|
grView.PageSize = numRigheGrView;
|
|
}
|
|
/// <summary>
|
|
/// permette di imposstare periodo analisi
|
|
/// </summary>
|
|
public intervalloDate intAnalisiSAO
|
|
{
|
|
get
|
|
{
|
|
return mod_periodoAnalisi1.intervalloAnalisi;
|
|
}
|
|
set
|
|
{
|
|
mod_periodoAnalisi1.intervalloAnalisi = value;
|
|
mod_periodoAnalisi1.doUpdate(false);
|
|
//updateFiltroUdc();
|
|
}
|
|
}
|
|
|
|
#endregion
|
|
|
|
}
|
|
} |