From 8b569ef6d3f758030289e3a4ad70b85da78a2be0 Mon Sep 17 00:00:00 2001 From: ermanno Date: Wed, 21 Oct 2009 15:32:39 +0000 Subject: [PATCH] cancellati file messi in sottodir webusercontrols git-svn-id: https://keyhammer.ath.cx/svn/WebGIM/trunk@148 3e04ef4b-3b25-4b6c-be27-bb5389ca777b --- WebSites/WebGIM/mod_anagAmbitiGuasto.ascx | 86 -- WebSites/WebGIM/mod_anagAmbitiGuasto.ascx.cs | 85 -- WebSites/WebGIM/mod_anagOpMtz.ascx | 105 --- WebSites/WebGIM/mod_anagOpMtz.ascx.cs | 96 --- WebSites/WebGIM/mod_aperturaImpianti.ascx | 54 -- WebSites/WebGIM/mod_aperturaImpianti.ascx.cs | 33 - .../mod_assegnazioniMacchineImpianti.ascx | 41 - .../mod_assegnazioniMacchineImpianti.ascx.cs | 93 --- WebSites/WebGIM/mod_calChiusura.ascx | 120 --- WebSites/WebGIM/mod_calChiusura.ascx.cs | 114 --- WebSites/WebGIM/mod_chLang.ascx | 28 - WebSites/WebGIM/mod_chLang.ascx.cs | 34 - WebSites/WebGIM/mod_dataOra.ascx | 42 - WebSites/WebGIM/mod_dataOra.ascx.cs | 214 ----- WebSites/WebGIM/mod_dettMtzProg.ascx | 102 --- WebSites/WebGIM/mod_dettMtzProg.ascx.cs | 80 -- WebSites/WebGIM/mod_dettaglioIntervento.ascx | 763 ------------------ .../WebGIM/mod_dettaglioIntervento.ascx.cs | 144 ---- WebSites/WebGIM/mod_elFamMacch.ascx | 88 -- WebSites/WebGIM/mod_elFamMacch.ascx.cs | 134 --- WebSites/WebGIM/mod_elMacch2Fam.ascx | 56 -- WebSites/WebGIM/mod_elMacch2Fam.ascx.cs | 73 -- WebSites/WebGIM/mod_elencoMtzProg.ascx | 145 ---- WebSites/WebGIM/mod_elencoMtzProg.ascx.cs | 269 ------ WebSites/WebGIM/mod_elencoRichieste.ascx | 112 --- WebSites/WebGIM/mod_elencoRichieste.ascx.cs | 374 --------- WebSites/WebGIM/mod_famiglieMacchine.ascx | 50 -- WebSites/WebGIM/mod_famiglieMacchine.ascx.cs | 111 --- WebSites/WebGIM/mod_filtro.ascx | 7 - WebSites/WebGIM/mod_filtro.ascx.cs | 309 ------- WebSites/WebGIM/mod_fixCal.ascx | 6 - WebSites/WebGIM/mod_fixCal.ascx.cs | 18 - WebSites/WebGIM/mod_gestCausali.ascx | 103 --- WebSites/WebGIM/mod_gestCausali.ascx.cs | 112 --- WebSites/WebGIM/mod_gestUtentiGIM.ascx | 106 --- WebSites/WebGIM/mod_gestUtentiGIM.ascx.cs | 101 --- WebSites/WebGIM/mod_impianti.ascx | 185 ----- WebSites/WebGIM/mod_impianti.ascx.cs | 448 ---------- WebSites/WebGIM/mod_insertRichiesta.ascx | 164 ---- WebSites/WebGIM/mod_insertRichiesta.ascx.cs | 182 ----- WebSites/WebGIM/mod_interventoOpMtz.ascx | 112 --- WebSites/WebGIM/mod_interventoOpMtz.ascx.cs | 128 --- WebSites/WebGIM/mod_lemmiVocab.ascx | 53 -- WebSites/WebGIM/mod_lemmiVocab.ascx.cs | 57 -- WebSites/WebGIM/mod_login.ascx | 54 -- WebSites/WebGIM/mod_login.ascx.cs | 242 ------ WebSites/WebGIM/mod_macchine.ascx | 366 --------- WebSites/WebGIM/mod_macchine.ascx.cs | 584 -------------- WebSites/WebGIM/mod_main_help.ascx | 15 - WebSites/WebGIM/mod_main_help.ascx.cs | 52 -- WebSites/WebGIM/mod_menuBottom.ascx | 4 - WebSites/WebGIM/mod_menuBottom.ascx.cs | 20 - WebSites/WebGIM/mod_menuBottom.ascx.in | 4 - WebSites/WebGIM/mod_menuBottomPortable.ascx | 4 - .../WebGIM/mod_menuBottomPortable.ascx.cs | 18 - WebSites/WebGIM/mod_menuSx.ascx | 16 - WebSites/WebGIM/mod_menuSx.ascx.cs | 43 - WebSites/WebGIM/mod_menuTop.ascx | 35 - WebSites/WebGIM/mod_menuTop.ascx.cs | 151 ---- WebSites/WebGIM/mod_mtzPrevPending.ascx | 41 - WebSites/WebGIM/mod_mtzPrevPending.ascx.cs | 59 -- WebSites/WebGIM/mod_pageTitleAndSearch.ascx | 25 - .../WebGIM/mod_pageTitleAndSearch.ascx.cs | 28 - WebSites/WebGIM/mod_periodoAnalisi.ascx | 35 - WebSites/WebGIM/mod_periodoAnalisi.ascx.cs | 205 ----- WebSites/WebGIM/mod_priorita.ascx | 104 --- WebSites/WebGIM/mod_priorita.ascx.cs | 95 --- WebSites/WebGIM/mod_reportInterventi.ascx | 101 --- WebSites/WebGIM/mod_reportInterventi.ascx.cs | 191 ----- WebSites/WebGIM/mod_ricercaGenerica.ascx | 6 - WebSites/WebGIM/mod_ricercaGenerica.ascx.cs | 181 ----- WebSites/WebGIM/mod_selettore.ascx | 58 -- WebSites/WebGIM/mod_selettore.ascx.cs | 464 ----------- WebSites/WebGIM/mod_selettore_ajax.ascx | 77 -- WebSites/WebGIM/mod_selettore_ajax.ascx.cs | 499 ------------ WebSites/WebGIM/mod_tipoGuasto.ascx | 85 -- WebSites/WebGIM/mod_tipoGuasto.ascx.cs | 85 -- WebSites/WebGIM/mod_titlePortable.ascx | 4 - WebSites/WebGIM/mod_titlePortable.ascx.cs | 18 - WebSites/WebGIM/mod_unauthorized.ascx | 16 - WebSites/WebGIM/mod_unauthorized.ascx.cs | 19 - WebSites/WebGIM/mod_vocabolario.ascx | 105 --- WebSites/WebGIM/mod_vocabolario.ascx.cs | 146 ---- 83 files changed, 9992 deletions(-) delete mode 100644 WebSites/WebGIM/mod_anagAmbitiGuasto.ascx delete mode 100644 WebSites/WebGIM/mod_anagAmbitiGuasto.ascx.cs delete mode 100644 WebSites/WebGIM/mod_anagOpMtz.ascx delete mode 100644 WebSites/WebGIM/mod_anagOpMtz.ascx.cs delete mode 100644 WebSites/WebGIM/mod_aperturaImpianti.ascx delete mode 100644 WebSites/WebGIM/mod_aperturaImpianti.ascx.cs delete mode 100644 WebSites/WebGIM/mod_assegnazioniMacchineImpianti.ascx delete mode 100644 WebSites/WebGIM/mod_assegnazioniMacchineImpianti.ascx.cs delete mode 100644 WebSites/WebGIM/mod_calChiusura.ascx delete mode 100644 WebSites/WebGIM/mod_calChiusura.ascx.cs delete mode 100644 WebSites/WebGIM/mod_chLang.ascx delete mode 100644 WebSites/WebGIM/mod_chLang.ascx.cs delete mode 100644 WebSites/WebGIM/mod_dataOra.ascx delete mode 100644 WebSites/WebGIM/mod_dataOra.ascx.cs delete mode 100644 WebSites/WebGIM/mod_dettMtzProg.ascx delete mode 100644 WebSites/WebGIM/mod_dettMtzProg.ascx.cs delete mode 100644 WebSites/WebGIM/mod_dettaglioIntervento.ascx delete mode 100644 WebSites/WebGIM/mod_dettaglioIntervento.ascx.cs delete mode 100644 WebSites/WebGIM/mod_elFamMacch.ascx delete mode 100644 WebSites/WebGIM/mod_elFamMacch.ascx.cs delete mode 100644 WebSites/WebGIM/mod_elMacch2Fam.ascx delete mode 100644 WebSites/WebGIM/mod_elMacch2Fam.ascx.cs delete mode 100644 WebSites/WebGIM/mod_elencoMtzProg.ascx delete mode 100644 WebSites/WebGIM/mod_elencoMtzProg.ascx.cs delete mode 100644 WebSites/WebGIM/mod_elencoRichieste.ascx delete mode 100644 WebSites/WebGIM/mod_elencoRichieste.ascx.cs delete mode 100644 WebSites/WebGIM/mod_famiglieMacchine.ascx delete mode 100644 WebSites/WebGIM/mod_famiglieMacchine.ascx.cs delete mode 100644 WebSites/WebGIM/mod_filtro.ascx delete mode 100644 WebSites/WebGIM/mod_filtro.ascx.cs delete mode 100644 WebSites/WebGIM/mod_fixCal.ascx delete mode 100644 WebSites/WebGIM/mod_fixCal.ascx.cs delete mode 100644 WebSites/WebGIM/mod_gestCausali.ascx delete mode 100644 WebSites/WebGIM/mod_gestCausali.ascx.cs delete mode 100644 WebSites/WebGIM/mod_gestUtentiGIM.ascx delete mode 100644 WebSites/WebGIM/mod_gestUtentiGIM.ascx.cs delete mode 100644 WebSites/WebGIM/mod_impianti.ascx delete mode 100644 WebSites/WebGIM/mod_impianti.ascx.cs delete mode 100644 WebSites/WebGIM/mod_insertRichiesta.ascx delete mode 100644 WebSites/WebGIM/mod_insertRichiesta.ascx.cs delete mode 100644 WebSites/WebGIM/mod_interventoOpMtz.ascx delete mode 100644 WebSites/WebGIM/mod_interventoOpMtz.ascx.cs delete mode 100644 WebSites/WebGIM/mod_lemmiVocab.ascx delete mode 100644 WebSites/WebGIM/mod_lemmiVocab.ascx.cs delete mode 100644 WebSites/WebGIM/mod_login.ascx delete mode 100644 WebSites/WebGIM/mod_login.ascx.cs delete mode 100644 WebSites/WebGIM/mod_macchine.ascx delete mode 100644 WebSites/WebGIM/mod_macchine.ascx.cs delete mode 100644 WebSites/WebGIM/mod_main_help.ascx delete mode 100644 WebSites/WebGIM/mod_main_help.ascx.cs delete mode 100644 WebSites/WebGIM/mod_menuBottom.ascx delete mode 100644 WebSites/WebGIM/mod_menuBottom.ascx.cs delete mode 100644 WebSites/WebGIM/mod_menuBottom.ascx.in delete mode 100644 WebSites/WebGIM/mod_menuBottomPortable.ascx delete mode 100644 WebSites/WebGIM/mod_menuBottomPortable.ascx.cs delete mode 100644 WebSites/WebGIM/mod_menuSx.ascx delete mode 100644 WebSites/WebGIM/mod_menuSx.ascx.cs delete mode 100644 WebSites/WebGIM/mod_menuTop.ascx delete mode 100644 WebSites/WebGIM/mod_menuTop.ascx.cs delete mode 100644 WebSites/WebGIM/mod_mtzPrevPending.ascx delete mode 100644 WebSites/WebGIM/mod_mtzPrevPending.ascx.cs delete mode 100644 WebSites/WebGIM/mod_pageTitleAndSearch.ascx delete mode 100644 WebSites/WebGIM/mod_pageTitleAndSearch.ascx.cs delete mode 100644 WebSites/WebGIM/mod_periodoAnalisi.ascx delete mode 100644 WebSites/WebGIM/mod_periodoAnalisi.ascx.cs delete mode 100644 WebSites/WebGIM/mod_priorita.ascx delete mode 100644 WebSites/WebGIM/mod_priorita.ascx.cs delete mode 100644 WebSites/WebGIM/mod_reportInterventi.ascx delete mode 100644 WebSites/WebGIM/mod_reportInterventi.ascx.cs delete mode 100644 WebSites/WebGIM/mod_ricercaGenerica.ascx delete mode 100644 WebSites/WebGIM/mod_ricercaGenerica.ascx.cs delete mode 100644 WebSites/WebGIM/mod_selettore.ascx delete mode 100644 WebSites/WebGIM/mod_selettore.ascx.cs delete mode 100644 WebSites/WebGIM/mod_selettore_ajax.ascx delete mode 100644 WebSites/WebGIM/mod_selettore_ajax.ascx.cs delete mode 100644 WebSites/WebGIM/mod_tipoGuasto.ascx delete mode 100644 WebSites/WebGIM/mod_tipoGuasto.ascx.cs delete mode 100644 WebSites/WebGIM/mod_titlePortable.ascx delete mode 100644 WebSites/WebGIM/mod_titlePortable.ascx.cs delete mode 100644 WebSites/WebGIM/mod_unauthorized.ascx delete mode 100644 WebSites/WebGIM/mod_unauthorized.ascx.cs delete mode 100644 WebSites/WebGIM/mod_vocabolario.ascx delete mode 100644 WebSites/WebGIM/mod_vocabolario.ascx.cs diff --git a/WebSites/WebGIM/mod_anagAmbitiGuasto.ascx b/WebSites/WebGIM/mod_anagAmbitiGuasto.ascx deleted file mode 100644 index 8ce8da5..0000000 --- a/WebSites/WebGIM/mod_anagAmbitiGuasto.ascx +++ /dev/null @@ -1,86 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_anagAmbitiGuasto.ascx.cs" - Inherits="mod_anagAmbitiGuasto" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/WebSites/WebGIM/mod_anagAmbitiGuasto.ascx.cs b/WebSites/WebGIM/mod_anagAmbitiGuasto.ascx.cs deleted file mode 100644 index 479ddb9..0000000 --- a/WebSites/WebGIM/mod_anagAmbitiGuasto.ascx.cs +++ /dev/null @@ -1,85 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_anagAmbitiGuasto : ApplicationUserControl -{ - public event EventHandler eh_resetSelezione; - /// - /// evento dati associati a controllo - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - /// - /// reset delle selezioni - /// - /// - /// - protected void btnReset_Click(object sender, EventArgs e) - { - resetSelezione(); - } - /// - /// resetta la selezione dei valori in caso di modifiche su altri controlli - /// - public void resetSelezione() - { - grView.SelectedIndex = -1; - grView.DataBind(); - if (eh_resetSelezione != null) - { - eh_resetSelezione(this, new EventArgs()); - } - } - /// - /// seleziono valore in editing... - /// - /// - /// - protected void grView_RowEditing(object sender, GridViewEditEventArgs e) - { - // seleziono la riga corrente... - grView.SelectedIndex = e.NewEditIndex; - } - /// - /// gestione evento inserimento nuovo record standard (se ZERO presenti) - /// - /// - /// - protected void btnNewFromEmpty_Click(object sender, EventArgs e) - { - // reset selezione... - resetSelezione(); - // i primi valori ("0") di default sono "ND"... li inserisco come standard... - DS_applicazioneTableAdapters.AnagAmbitoGuastoTableAdapter taAnagAmbito = new DS_applicazioneTableAdapters.AnagAmbitoGuastoTableAdapter(); - taAnagAmbito.Insert("-- [NUOVO] non definito --"); - grView.DataBind(); - } -} diff --git a/WebSites/WebGIM/mod_anagOpMtz.ascx b/WebSites/WebGIM/mod_anagOpMtz.ascx deleted file mode 100644 index 0a64132..0000000 --- a/WebSites/WebGIM/mod_anagOpMtz.ascx +++ /dev/null @@ -1,105 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_anagOpMtz.ascx.cs" - Inherits="mod_anagOpMtz" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/WebSites/WebGIM/mod_anagOpMtz.ascx.cs b/WebSites/WebGIM/mod_anagOpMtz.ascx.cs deleted file mode 100644 index 345245a..0000000 --- a/WebSites/WebGIM/mod_anagOpMtz.ascx.cs +++ /dev/null @@ -1,96 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_anagOpMtz : ApplicationUserControl -{ - public event EventHandler eh_resetSelezione; - /// - /// evento dati associati a controllo - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - /// - /// reset delle selezioni - /// - /// - /// - protected void btnReset_Click(object sender, EventArgs e) - { - resetSelezione(); - } - /// - /// resetta la selezione dei valori in caso di modifiche su altri controlli - /// - public void resetSelezione() - { - grView.SelectedIndex = -1; - grView.DataBind(); - if (eh_resetSelezione != null) - { - eh_resetSelezione(this, new EventArgs()); - } - } - /// - /// seleziono valore in editing... - /// - /// - /// - protected void grView_RowEditing(object sender, GridViewEditEventArgs e) - { - // seleziono la riga corrente... - grView.SelectedIndex = e.NewEditIndex; - } - /// - /// gestione evento inserimento nuovo record standard (se ZERO presenti) - /// - /// - /// - protected void btnNewFromEmpty_Click(object sender, EventArgs e) - { - // reset selezione... - resetSelezione(); - // i primi valori ("0") di default sono "ND"... li inserisco come standard... - DS_applicazioneTableAdapters.AnagrOperMtzTableAdapter taAnagOpMtz = new DS_applicazioneTableAdapters.AnagrOperMtzTableAdapter(); - taAnagOpMtz.Insert("9999", "-- [NUOVO] Cognome --", "-- [NUOVO] Nome --"); - grView.DataBind(); - } - /// - /// è editabile SOLO se non è il primo user 0000 che è un segnaposto - /// - /// - /// - public bool isEditable(object matricola) - { - bool answ = (memLayer.ML.confReadString("defaultMatr") != matricola.ToString()); - return answ; - } - -} \ No newline at end of file diff --git a/WebSites/WebGIM/mod_aperturaImpianti.ascx b/WebSites/WebGIM/mod_aperturaImpianti.ascx deleted file mode 100644 index 71aaebd..0000000 --- a/WebSites/WebGIM/mod_aperturaImpianti.ascx +++ /dev/null @@ -1,54 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_aperturaImpianti.ascx.cs" - Inherits="mod_aperturaImpianti" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/WebSites/WebGIM/mod_aperturaImpianti.ascx.cs b/WebSites/WebGIM/mod_aperturaImpianti.ascx.cs deleted file mode 100644 index 90fa92d..0000000 --- a/WebSites/WebGIM/mod_aperturaImpianti.ascx.cs +++ /dev/null @@ -1,33 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_aperturaImpianti : ApplicationUserControl -{ - /// - /// evento dati associati a controllo - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - } - } -} diff --git a/WebSites/WebGIM/mod_assegnazioniMacchineImpianti.ascx b/WebSites/WebGIM/mod_assegnazioniMacchineImpianti.ascx deleted file mode 100644 index 3454e21..0000000 --- a/WebSites/WebGIM/mod_assegnazioniMacchineImpianti.ascx +++ /dev/null @@ -1,41 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_assegnazioniMacchineImpianti.ascx.cs" - Inherits="mod_assegnazioniMacchineImpianti" %> -<%@ Register Src="mod_selettore_ajax.ascx" TagName="mod_selettore_ajax" TagPrefix="uc1" %> -<%@ Register Src="mod_macchine.ascx" TagName="mod_macchine" TagPrefix="uc2" %> - - - - - - - - - - - -
- - - - -
-
- -
-
- -
- -
-
- -
-
- - - \ No newline at end of file diff --git a/WebSites/WebGIM/mod_assegnazioniMacchineImpianti.ascx.cs b/WebSites/WebGIM/mod_assegnazioniMacchineImpianti.ascx.cs deleted file mode 100644 index 7df721e..0000000 --- a/WebSites/WebGIM/mod_assegnazioniMacchineImpianti.ascx.cs +++ /dev/null @@ -1,93 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_assegnazioniMacchineImpianti : System.Web.UI.UserControl -{ - protected void Page_Load(object sender, EventArgs e) - { - } - /// - /// click spostamento da A a B - /// - /// - /// - protected void btnA2B_Click(object sender, EventArgs e) - { - // solo se macchina selezionata... - if (mod_macchine1.idxMacchinaSel != 0) - { - // sposto da A a B - TA_app.obj.taMacchine.sp_spostaMacchina(mod_macchine1.idxMacchinaSel, Convert.ToInt32(ddlImpianto_B.SelectedValue)); - updateAll(); - lblWarning.Visible = false; - } - else - { - // mostro errore... - lblWarning.Text = user_std.UtSn.Traduci("ErroreNoMaccSel"); - lblWarning.Visible = true; - } - } - /// - /// click spostamento da B ad A - /// - /// - /// - protected void btnB2A_Click(object sender, EventArgs e) - { - if (mod_macchine2.idxMacchinaSel != 0) - { // sposto da B ad A - TA_app.obj.taMacchine.sp_spostaMacchina(mod_macchine2.idxMacchinaSel, Convert.ToInt32(ddlImpianto_A.SelectedValue)); - updateAll(); - lblWarning.Visible = false; - } - else - { - // mostro errore... - lblWarning.Text = user_std.UtSn.Traduci("ErroreNoMaccSel"); - lblWarning.Visible = true; - } - } - /// - /// aggiorna visualizzazioni delle 2 tab di dettaglio - /// - private void updateAll() - { - update_A(); - update_B(); - } - /// - /// aggiorno tab impianto A - /// - /// - /// - protected void ddlImpianto_A_SelectedIndexChanged(object sender, EventArgs e) - { - update_A(); - } - - private void update_A() - { - mod_macchine1.idxImpiantoSel = Convert.ToInt32(ddlImpianto_A.SelectedValue); - mod_macchine1.doUpdate(); - } - /// - /// aggiorno tab impianto B - /// - /// - /// - protected void ddlImpianto_B_SelectedIndexChanged(object sender, EventArgs e) - { - update_B(); - } - - private void update_B() - { - mod_macchine2.idxImpiantoSel = Convert.ToInt32(ddlImpianto_B.SelectedValue); - mod_macchine2.doUpdate(); - } -} diff --git a/WebSites/WebGIM/mod_calChiusura.ascx b/WebSites/WebGIM/mod_calChiusura.ascx deleted file mode 100644 index 6538981..0000000 --- a/WebSites/WebGIM/mod_calChiusura.ascx +++ /dev/null @@ -1,120 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_calChiusura.ascx.cs" - Inherits="mod_calChiusura" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - -
- - - -
-
- - - -
-
- -
-
- -
- -
-
diff --git a/WebSites/WebGIM/mod_calChiusura.ascx.cs b/WebSites/WebGIM/mod_calChiusura.ascx.cs deleted file mode 100644 index ed9e081..0000000 --- a/WebSites/WebGIM/mod_calChiusura.ascx.cs +++ /dev/null @@ -1,114 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_calChiusura : ApplicationUserControl -{ - public event EventHandler eh_resetSelezione; - - protected override void Page_Load(object sender, EventArgs e) - { - base.Page_Load(sender, e); - if (!Page.IsPostBack) - { - grView.PageSize = _righeDataGridMed; - btnShowInsPeriodo.Text = traduci("btnShowInsPeriodo"); - btnInsPeriodo.Text = traduci("btnInsPeriodo"); - } - } - - /// - /// gestione evento inserimento nuovo record standard (se ZERO presenti) - /// - /// - /// - protected void btnNewFromEmpty_Click(object sender, EventArgs e) - { - // reset selezione... - resetSelezione(); - // i primi valori ("0") di default sono "ND"... li inserisco come standard... - TA_app.obj.taCalFF.Insert(DateTime.Now.Date, "-- [NUOVO] non definito --"); - grView.DataBind(); - } - /// - /// resetta la selezione dei valori in caso di modifiche su altri controlli - /// - public void resetSelezione() - { - grView.SelectedIndex = -1; - grView.DataBind(); - if (eh_resetSelezione != null) - { - eh_resetSelezione(this, new EventArgs()); - } - } - /// - /// evento dati associati a controllo - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - protected void btnShowInsPeriodo_Click(object sender, EventArgs e) - { - pnlInsPeriodo.Visible = !pnlInsPeriodo.Visible; - if (pnlInsPeriodo.Visible) - { - btnShowInsPeriodo.Text = traduci("btnHideInsPeriodo"); - } - else - { - btnShowInsPeriodo.Text = traduci("btnShowInsPeriodo"); - } - } - protected void btnInsPeriodo_Click(object sender, EventArgs e) - { - // verifico date congrue... - DateTime inizio = Convert.ToDateTime(txtDataFrom.Text); - DateTime fine = Convert.ToDateTime(txtDataTo.Text); - if (fine.CompareTo(inizio) >= 0) - { - // inserisco le voci x tutte le date nell'intervallo... - while (fine.CompareTo(inizio) >= 0) - { - TA_app.obj.taCalFF.Insert(inizio, txtDescrizione.Text); - inizio = inizio.AddDays(1); - } - // update e nascondo pannello - grView.DataBind(); - pnlInsPeriodo.Visible = false; - btnShowInsPeriodo.Text = traduci("btnShowInsPeriodo"); - lblWarning.Visible = false; - } - else - { - lblWarning.Visible = true; - lblWarning.Text = traduci("OrdineDateErrato"); - } - } -} diff --git a/WebSites/WebGIM/mod_chLang.ascx b/WebSites/WebGIM/mod_chLang.ascx deleted file mode 100644 index 408f8ab..0000000 --- a/WebSites/WebGIM/mod_chLang.ascx +++ /dev/null @@ -1,28 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_chLang.ascx.cs" Inherits="mod_chLang" %> - - - - - - - - -
- -
- - - - - - <%# DataBinder.Eval(Container, "DataItem.Lingua") %> - - - <%# DataBinder.Eval(Container, "DataItem.Lingua") %> - - - - - -
diff --git a/WebSites/WebGIM/mod_chLang.ascx.cs b/WebSites/WebGIM/mod_chLang.ascx.cs deleted file mode 100644 index 2ac1f49..0000000 --- a/WebSites/WebGIM/mod_chLang.ascx.cs +++ /dev/null @@ -1,34 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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 SteamWare; - -public partial class mod_chLang : ApplicationUserControl -{ - protected void dataListLingue_SelectedIndexChanged(object sender, EventArgs e) - { - // impongo ad oggetto user la lingua selezionata... - user_std.UtSn.lingua = dataListLingue.SelectedValue.ToString(); - // salvo richiesta udpate in sessione... - SteamWare.memLayer.ML.setSessionVal("doUpdateNow","true"); - user_std.UtSn.ricaricaMappaSito(); - Response.Redirect(_paginaCorrente); - } - - protected override void traduciObj() - { - lblScegli.Text = traduci("scegliLingua"); - } - - public string formattaLingua(object breve, object lungo) - { - return string.Format("{0} - {1}", breve, lungo); - } -} diff --git a/WebSites/WebGIM/mod_dataOra.ascx b/WebSites/WebGIM/mod_dataOra.ascx deleted file mode 100644 index 92baa1d..0000000 --- a/WebSites/WebGIM/mod_dataOra.ascx +++ /dev/null @@ -1,42 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_dataOra.ascx.cs" Inherits="mod_dataOra" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> - - - - - - -
-
-
- - - -
- - - - - - -
-
-
- -
-
-
- -
-
-
- -
-
- - - -
-
diff --git a/WebSites/WebGIM/mod_dataOra.ascx.cs b/WebSites/WebGIM/mod_dataOra.ascx.cs deleted file mode 100644 index 4bd1fb6..0000000 --- a/WebSites/WebGIM/mod_dataOra.ascx.cs +++ /dev/null @@ -1,214 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -[ValidationProperty("valore")] -public partial class mod_dataOra : System.Web.UI.UserControl -{ - /// - /// definisce se siano visibili e selezionabili i secondi - /// - protected bool _showSeconds = false; - /// - /// tipo selettore orario richiesto - /// - protected tipoSelOrario _tipoOrario; - /// - /// calsse css applicata ai controlli - /// - protected string _css; - /// - /// valore di riferimento... - /// - protected DateTime _valore; - /// - /// avvio pagina - /// - /// - /// - protected void Page_Load(object sender, EventArgs e) - { - if (!Page.IsPostBack) - { - traduciObj(); - fixPnlVisibility(); - //setupControlli(); - fixCss(); - } - } - /// - /// traduce gli oggetti - /// - private void traduciObj() - { - lblData.Text = traduci("lblData"); - lblOra.Text = traduci("lblOra"); - lblMin.Text = traduci("lblMin"); - lblTime.Text = traduci("lblTime"); - } - /// - /// sistema valori default dei controlli - /// - private void setupControlli() - { - // mostro data - txtData.Text = _valore.Date.ToString("dd/MM/yy"); - switch (_tipoOrario) - { - case tipoSelOrario.tendina: - // aggiongo valori ora e minuti... - ddlOra.Items.Clear(); - ddlMin.Items.Clear(); - for (int i = 0; i < 24; i++) - { - ddlOra.Items.Add(new ListItem(string.Format("{0:00}", i), i.ToString())); - } - for (int i = 0; i < 60; i++) - { - ddlMin.Items.Add(new ListItem(string.Format("{0:00}", i), i.ToString())); - } - // imposto i valori - ddlOra.SelectedValue = _valore.Hour.ToString(); - ddlMin.SelectedValue = _valore.Minute.ToString(); - break; - case tipoSelOrario.testuale: - txtTime.Text = string.Format("{0:HH:mm}", _valore); - break; - } - } - /// - /// sistema visualizzazione controlli - /// - private void fixPnlVisibility() - { - switch (_tipoOrario) - { - case tipoSelOrario.tendina: - pnlDropDown.Visible = true; - pnlText.Visible = false; - break; - case tipoSelOrario.testuale: - pnlDropDown.Visible = false; - pnlText.Visible = true; - break; - } - } - /// - /// sistema i css del controllo... - /// - private void fixCss() - { - txtData.CssClass = _css; - switch (_tipoOrario) - { - case tipoSelOrario.tendina: - ddlOra.CssClass = _css; - ddlMin.CssClass = _css; - break; - case tipoSelOrario.testuale: - txtTime.CssClass = _css; - break; - } - } - /// - /// wrapper traduzione - /// - /// - /// - public string traduci(object lemma) - { - return user_std.UtSn.Traduci(lemma.ToString()); - } - /// - /// scelta del tipo di selettore per ora/min/sec - /// - public tipoSelOrario tipoOrario - { - get - { - return _tipoOrario; - } - set - { - _tipoOrario = value; - fixPnlVisibility(); - } - } - /// - /// valore del controllo - /// - public DateTime valore - { - get - { - int ora = 0; - int min = 0; - switch (_tipoOrario) - { - case tipoSelOrario.tendina: - ora = Convert.ToInt32(ddlOra.SelectedValue); - min = Convert.ToInt32(ddlMin.SelectedValue); - break; - case tipoSelOrario.testuale: - ora = Convert.ToDateTime(txtTime.Text).Hour; - min = Convert.ToDateTime(txtTime.Text).Minute; - break; - } - DateTime answ = Convert.ToDateTime(txtData.Text).AddHours(ora).AddMinutes(min); - return answ; - } - set - { - _valore = value; - if (ddlOra.SelectedValue == "") - { - setupControlli(); - } - } - } - /// - /// css applicato agli elementi del controllo - /// - public string css - { - get - { - return _css; - } - set - { - _css = value; - fixCss(); - } - } - /// - /// nasconde se richiesto le label dei controlli dataOra - /// - public bool mostraLabel - { - set - { - lblData.Visible = value; - lblMin.Visible = value; - lblOra.Visible = value; - lblTime.Visible = value; - } - } -} -/// -/// tipo di selettore impiegato per la seleizone dell'orario -/// -public enum tipoSelOrario -{ - /// - /// selettore a tendina per l'ora (00 -> 23) ed i minuti/secondi (00 -> 59) - /// - tendina, - /// - /// selettore testuale con masked input - /// - testuale -} \ No newline at end of file diff --git a/WebSites/WebGIM/mod_dettMtzProg.ascx b/WebSites/WebGIM/mod_dettMtzProg.ascx deleted file mode 100644 index 0b0cc26..0000000 --- a/WebSites/WebGIM/mod_dettMtzProg.ascx +++ /dev/null @@ -1,102 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_dettMtzProg.ascx.cs" - Inherits="mod_dettMtzProg" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> - - - - - - - - - - - - - - -
-

- -

-
-
- - -
-
- -
-
- -
-
- - - - - - -
-
-
-
-
- - - - -
-
-
- - - -
-
-
-
- -
-
-
- - - - -
-
-
-
-
- - - - -
-
-
- - -
-
-
- - -
diff --git a/WebSites/WebGIM/mod_dettMtzProg.ascx.cs b/WebSites/WebGIM/mod_dettMtzProg.ascx.cs deleted file mode 100644 index 5aef33a..0000000 --- a/WebSites/WebGIM/mod_dettMtzProg.ascx.cs +++ /dev/null @@ -1,80 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_dettMtzProg : System.Web.UI.UserControl -{ - public event EventHandler eh_newInserted; - - protected void Page_Load(object sender, EventArgs e) - { - if (!Page.IsPostBack) - { - traduciObj(); - setupValori(); - } - } - - private void setupValori() - { - txtDataInizio.Text = DateTime.Now.ToString("dd/MM/yy"); - txtCadenza.Text = "1"; - } - - private void traduciObj() - { - lblInsNewIntPro.Text = traduci("lblInsNewIntPro"); - lblDescrMtzPro.Text = traduci("lblDescrMtzPro"); - lblInizioMtzPro.Text = traduci("lblInizioMtzPro"); - lblPrior.Text = traduci("lblPrior"); - chkImpFermo.Text = traduci("chkImpFermo"); - lblTipoGuasto.Text = traduci("lblTipoGuasto"); - lblFreq.Text = traduci("lblFreq"); - lblCadenza.Text = traduci("lblCadenza"); - btnCreaMtzPro.Text = traduci("btnCreaMtzPro"); - lblMacchineInteressate.Text = traduci("lblMacchineInteressate"); - rfvCad.Text = traduci("cadIntReq"); - rfvDescrizione.Text = traduci("descrIntReq"); - rfvData.Text = traduci("dataReq"); - } - /// - /// wrap traduzione - /// - /// - /// - public string traduci(object lemma) - { - return user_std.UtSn.Traduci(lemma.ToString()); - } - protected void btnCreaMtzPro_Click(object sender, EventArgs e) - { - // spazzo TUTTE le righe del controllo... - foreach (ListItem riga in listMacchine.Items) - { - // se è selezionata creo riga anche x lei... - if (riga.Selected) - { - creaInterventoMtzPro(Convert.ToInt32(riga.Value)); - } - } - // resetto selezioni e controlli... - txtDescrizione.Text = ""; - txtCercaMacchine.Text = "*"; - listMacchine.SelectedIndex = -1; - if (eh_newInserted != null) - { - eh_newInserted(this, new EventArgs()); - } - } - /// - /// crea un intervento di mtz programmata x la macchina con idx passato - /// - /// - private void creaInterventoMtzPro(int idx) - { - TA_app.obj.taMtzPro.Insert(idx, Convert.ToDateTime(txtDataInizio.Text), ddlFreq.SelectedValue, Convert.ToInt32(txtCadenza.Text), txtDescrizione.Text.Trim(), Convert.ToInt32(ddlPrior.SelectedValue), chkImpFermo.Checked, Convert.ToInt32(ddlTipo.SelectedValue)); - } -} diff --git a/WebSites/WebGIM/mod_dettaglioIntervento.ascx b/WebSites/WebGIM/mod_dettaglioIntervento.ascx deleted file mode 100644 index 241ec6e..0000000 --- a/WebSites/WebGIM/mod_dettaglioIntervento.ascx +++ /dev/null @@ -1,763 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_dettaglioIntervento.ascx.cs" - Inherits="mod_dettaglioIntervento" %> -<%@ Register Src="mod_interventoOpMtz.ascx" TagName="mod_interventoOpMtz" TagPrefix="uc1" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> -<%@ Register Src="mod_dataOra.ascx" TagName="mod_dataOra" TagPrefix="uc2" %> -
-
- -
-
- -
-
- - -
-
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - -
- - - - - - - - - - - -
- - - -
- - - -
- - - - - - -
- - - - - <%-- - - - - --%> - - -
- - - -
- - - -
- - - -
- -
- -
-
-
- - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - -
- - - - - - - - - - - - -
- - - - -
- -
-
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - -
- - - - - - - - - - - -
- - - -
- - - -
- - - - - - -
- - - - - <%-- - - - - --%> - - -
- - - -
- - - -
- - - -
- -
- -
-
-
- - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - -
- - - - - - - - - - - - -
- - - - -
- -
-
-
-
-
- - -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - - - -
- - - - - - - - - - - -
- - - -
- - - - - - - -
- - - - - - -
- - - - - <%-- - - - - --%> - - -
- - - - - - - - - -
- - - -
-
- - - -
- - -
- -
-
- - - - -
-
-
- - - - - - - - - - - - - - - - - - - - - - -
- - - - - - - - - -
- <%----%> - - - - - - - - - - - - -
- - - - -
- -
-
-
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/WebSites/WebGIM/mod_dettaglioIntervento.ascx.cs b/WebSites/WebGIM/mod_dettaglioIntervento.ascx.cs deleted file mode 100644 index a511b5e..0000000 --- a/WebSites/WebGIM/mod_dettaglioIntervento.ascx.cs +++ /dev/null @@ -1,144 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_dettaglioIntervento : System.Web.UI.UserControl -{ - #region gestione eventi - - public event EventHandler eh_chiudi; - //public event EventHandler eh_nuovoValore; - //public event EventHandler eh_selValore; - - #endregion - - protected void Page_Load(object sender, EventArgs e) - { - if (!Page.IsPostBack) - { - setupInizialeControlli(); - } - if (frmView_default.CurrentMode == FormViewMode.ReadOnly) - { - btnCancel.Visible = false; - } - - } - /// - /// setup iniziale e di reset dei controlli - /// - private void setupInizialeControlli() - { - traduciObj(); - frmView_default.ChangeMode(FormViewMode.ReadOnly); - frmView_default.Visible = true; - frmView_full.Visible = false; - btnCancel.Enabled= userCanEditData; - btnCompilaMtz.Enabled = userCanEditData; - btnEditFull.Enabled = userCanEditData; - } - /// - /// effettua traduzione pagina in lingua corrente - /// - private void traduciObj() - { - btnElenco.Text = traduci("btnElencoRichiesteMtz"); - btnCancel.Text = traduci("btnCancel"); - btnCompilaMtz.Text = traduci("btnCompilaMtz"); - btnEditFull.Text = traduci("btnEditFull"); - } - /// - /// wrapper alla traduzione - /// - /// - /// - public string traduci(object lemma) - { - return user_std.UtSn.Traduci(lemma.ToString()); - } - /// - /// aggiorna il dato mostrato - /// - public void doUpdate() - { - setupInizialeControlli(); - } - /// - /// abilita compilazione parte mtz dell'intervento - /// - /// - /// - protected void btnCompilaMtz_Click(object sender, EventArgs e) - { - frmView_default.ChangeMode(FormViewMode.Edit); - frmView_default.Visible = true; - frmView_full.Visible = false; - btnCancel.Visible = true; - } - /// - /// permette editing di tutto - /// - /// - /// - protected void btnEditFull_Click(object sender, EventArgs e) - { - frmView_full.ChangeMode(FormViewMode.Edit); - frmView_full.Visible = true; - frmView_default.Visible = false; - btnCancel.Visible = true; - frmView_default.DataBind(); - frmView_full.DataBind(); - } - /// - /// chiude la parte di editing - /// - /// - /// - protected void btnCancel_Click(object sender, EventArgs e) - { - frmView_default.ChangeMode(FormViewMode.ReadOnly); - frmView_default.Visible = true; - frmView_full.Visible = false; - btnCancel.Visible = false; - frmView_default.DataBind(); - frmView_full.DataBind(); - } - /// - /// chiude la parte di editing - /// - /// - /// - protected void btnElenco_Click(object sender, EventArgs e) - { - if (eh_chiudi != null) - { - eh_chiudi(this, new EventArgs()); - } - } - protected void ods_full_Updated(object sender, ObjectDataSourceStatusEventArgs e) - { - frmView_default.ChangeMode(FormViewMode.ReadOnly); - frmView_default.Visible = true; - frmView_full.Visible = false; - frmView_default.DataBind(); - } - protected void listCausali_TextChanged(object sender, EventArgs e) - { - btnCancel.Visible = true; - } - - /// - /// determina se l'utente possa editare i dati (permesso "_SU" - /// - public bool userCanEditData - { - get - { - return (user_std.UtSn.diritti.Select("COD_FUNZIONE = 'GIM_SU'").Length > 0); - } - } - -} diff --git a/WebSites/WebGIM/mod_elFamMacch.ascx b/WebSites/WebGIM/mod_elFamMacch.ascx deleted file mode 100644 index 992ffb3..0000000 --- a/WebSites/WebGIM/mod_elFamMacch.ascx +++ /dev/null @@ -1,88 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_elFamMacch.ascx.cs" - Inherits="mod_elFamMacch" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/WebSites/WebGIM/mod_elFamMacch.ascx.cs b/WebSites/WebGIM/mod_elFamMacch.ascx.cs deleted file mode 100644 index 1653ac1..0000000 --- a/WebSites/WebGIM/mod_elFamMacch.ascx.cs +++ /dev/null @@ -1,134 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_elFamMacch : ApplicationUserControl -{ - public event EventHandler eh_selezioneValore; - public event EventHandler eh_resetSelezione; - /// - /// evento dati associati a controllo - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - /// - /// reset delle selezioni - /// - /// - /// - protected void btnReset_Click(object sender, EventArgs e) - { - resetSelezione(); - } - /// - /// resetta la selezione dei valori in caso di modifiche su altri controlli - /// - public void resetSelezione() - { - grView.SelectedIndex = -1; - grView.DataBind(); - if (eh_resetSelezione != null) - { - eh_resetSelezione(this, new EventArgs()); - } - } - /// - /// seleziono valore in editing... - /// - /// - /// - protected void grView_RowEditing(object sender, GridViewEditEventArgs e) - { - // seleziono la riga corrente... - grView.SelectedIndex = e.NewEditIndex; - } - /// - /// gestione evento inserimento nuovo record standard (se ZERO presenti) - /// - /// - /// - protected void btnNewFromEmpty_Click(object sender, EventArgs e) - { - // reset selezione... - resetSelezione(); - // i primi valori ("0") di default sono "ND"... li inserisco come standard... - DS_applicazioneTableAdapters.AnagFamMacchineTableAdapter taFamMacc = new DS_applicazioneTableAdapters.AnagFamMacchineTableAdapter(); - taFamMacc.Insert("-- [NUOVA] n.d. --"); - grView.DataBind(); - } - protected void grView_SelectedIndexChanged(object sender, EventArgs e) - { - if (eh_selezioneValore != null) - { - eh_selezioneValore(this, new EventArgs()); - } - } - /// - /// restituisce il valore selezionato... se non selezionato restituisce -1 - /// - public int idxFamMacc_sel - { - get - { - int answ = -1; - if (grView.SelectedIndex != -1) - { - answ = Convert.ToInt32(grView.SelectedValue); - } - return answ; - } - } - protected void ods_Updated(object sender, ObjectDataSourceStatusEventArgs e) - { - grView.SelectedIndex = -1; - grView.DataBind(); - } - /// - /// determina se sia cancellabile - /// - /// - /// - public bool isDeletable(object idx) - { - bool answ=false; - if (TA_app.obj.taMacc2Fam.getByFam(Convert.ToInt32(idx)).Rows.Count == 0) - { - answ = true; - } - return answ; - } - /// - /// esegue update - /// - public void doUpdate() - { - grView.DataBind(); - } -} diff --git a/WebSites/WebGIM/mod_elMacch2Fam.ascx b/WebSites/WebGIM/mod_elMacch2Fam.ascx deleted file mode 100644 index 62953db..0000000 --- a/WebSites/WebGIM/mod_elMacch2Fam.ascx +++ /dev/null @@ -1,56 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_elMacch2Fam.ascx.cs" - Inherits="mod_elMacch2Fam" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/WebSites/WebGIM/mod_elMacch2Fam.ascx.cs b/WebSites/WebGIM/mod_elMacch2Fam.ascx.cs deleted file mode 100644 index c9e0491..0000000 --- a/WebSites/WebGIM/mod_elMacch2Fam.ascx.cs +++ /dev/null @@ -1,73 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_elMacch2Fam : ApplicationUserControl -{ - public event EventHandler eh_delValore; - /// - /// evento dati associati a controllo - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - /// - /// indica il valore dell'impianto filtrato in visualizzazione - /// - public int idxFamMacchSel - { - get - { - return Convert.ToInt32(lblFamMacc.Text); - } - set - { - lblFamMacc.Text = value.ToString(); - } - } - /// - /// eliminato il valore genera l'evento - /// - /// - /// - protected void ods_Deleted(object sender, ObjectDataSourceStatusEventArgs e) - { - if (eh_delValore != null) - { - eh_delValore(this, new EventArgs()); - } - } - /// - /// esegue update - /// - public void doUpdate() - { - grView.DataBind(); - } -} diff --git a/WebSites/WebGIM/mod_elencoMtzProg.ascx b/WebSites/WebGIM/mod_elencoMtzProg.ascx deleted file mode 100644 index d42e082..0000000 --- a/WebSites/WebGIM/mod_elencoMtzProg.ascx +++ /dev/null @@ -1,145 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_elencoMtzProg.ascx.cs" - Inherits="mod_elencoMtzProg" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> -<%@ Register Src="mod_filtro.ascx" TagName="mod_filtro" TagPrefix="uc1" %> -
- - - - - -
-
- -
-
- - - -
-
-
- -
-
- - - -
-
- - - - - - -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
diff --git a/WebSites/WebGIM/mod_elencoMtzProg.ascx.cs b/WebSites/WebGIM/mod_elencoMtzProg.ascx.cs deleted file mode 100644 index ce3a4d3..0000000 --- a/WebSites/WebGIM/mod_elencoMtzProg.ascx.cs +++ /dev/null @@ -1,269 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; -using System.Data; - -public partial class mod_elencoMtzProg : ApplicationUserControl -{ - #region gestione eventi - - public event EventHandler eh_newReq; - public event EventHandler eh_resetSelezione; - public event EventHandler eh_selValore; - - #endregion - protected string _idxGridView; - - /// - /// traduzioni - /// - protected override void traduciObj() - { - base.traduciObj(); - btnShowNew.Text = traduci("btnShowNew"); - lblFiltMacchina.Text = traduci("lblFiltMacchina"); - lblFiltTipo.Text = traduci("lblFiltTipo"); - } - - /// - /// cambio visibilità pannello new data - /// - /// - /// - protected void btnShowNew_Click(object sender, EventArgs e) - { - if (btnShowNew.Text == traduci("btnHideNew")) - { - btnShowNew.Text = traduci("btnShowNew"); - } - else - { - btnShowNew.Text = traduci("btnHideNew"); - } - // chiamo evento - if (eh_newReq != null) - { - eh_newReq(this, new EventArgs()); - } - } - /// - /// aggiorno il controllo - /// - public void doUpdate() - { - grView.DataBind(); - } - /// - /// reset della selezione - /// - /// - /// - protected void btnReset_Click(object sender, EventArgs e) - { - resetSelezione(); - } - /// - /// gestione cambio selezione valore - /// - /// - /// - protected void grView_SelectedIndexChanged(object sender, EventArgs e) - { - // salvo in session il valore selezionato... - SteamWare.memLayer.ML.setSessionVal(string.Format("{0}_sel", _idxGridView), grView.SelectedValue); - // sollevo evento nuovo valore... - if (eh_selValore != null) - { - eh_selValore(this, new EventArgs()); - } - } - /// - /// resetta la selezione dei valori in caso di modifiche su altri controlli - /// - public void resetSelezione() - { - SteamWare.memLayer.ML.emptySessionVal(string.Format("{0}_sel", _idxGridView)); - grView.SelectedIndex = -1; - grView.DataBind(); - lblWarning.Visible = false; - if (eh_resetSelezione != null) - { - eh_resetSelezione(this, new EventArgs()); - } - } - /// - /// restituisce un testo trimamto a maxChar caratteri - /// - /// - /// - /// - public string trimmaTesto(object _testo, object _maxChar) - { - string answ = ""; - string testo = _testo.ToString(); - int maxChar = Convert.ToInt32(_maxChar); - if (testo.Length <= maxChar) - { - answ = testo; - } - else - { - answ = string.Format("{0}...", testo.Substring(0, maxChar)); - } - return answ; - } - /// - /// traduce gli header delle colonne - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - /// - /// setta selected alla riga il cui valore key è in session - /// - /// - /// - protected void grView_RowDataBound(object sender, GridViewRowEventArgs e) - { - // se riga di dati... - if (e.Row.RowType == DataControlRowType.DataRow) - { - // ottengo la riga tipizzata... - System.Data.DataRowView _drv = (System.Data.DataRowView)e.Row.DataItem; - DS_applicazione.v_mtzProgExpRow riga = (DS_applicazione.v_mtzProgExpRow)_drv.Row; - if (SteamWare.memLayer.ML.StringSessionObj(_idxGridView) == riga.idxIntPro.ToString()) - { - grView.SelectedIndex = e.Row.RowIndex; - // salvo in session il valore selezionato... - SteamWare.memLayer.ML.setSessionVal(string.Format("{0}_sel", _idxGridView), SteamWare.memLayer.ML.StringSessionObj(_idxGridView)); - // sollevo evento nuovo valore... - if (eh_selValore != null) - { - eh_selValore(this, new EventArgs()); - } - } - } - } - /// - /// in caso di aggiornamento verifico se sia salvato un comando clona... - /// - /// - /// - protected void grView_RowUpdating(object sender, GridViewUpdateEventArgs e) - { - // carico l'idx dell'oggetto - int _idx = Convert.ToInt32(e.Keys["numIntMtz"]); - string _comando = ""; - if (SteamWare.memLayer.ML.isInSessionObject("nextObjCommand")) - { - _comando = SteamWare.memLayer.ML.StringSessionObj("nextObjCommand"); - SteamWare.memLayer.ML.emptySessionVal("nextObjCommand"); - } - // verifico il tipo di richiesta (up/down level, clona o update normale - switch (_comando) - { - case "clonaObj": - // blocco update! - e.Cancel = true; - break; - default: - // faccio update! - break; - } - } - /// - /// inizializzazione valori di default - /// - /// - protected override void OnInit(EventArgs e) - { - base.OnInit(e); - _idxGridView = "idxIntPro"; - if (!Page.IsPostBack) - { - mod_filtroImpianto.ods = odsImpianti; - mod_filtroMacchina.ods = odsMacchine; - mod_filtroTipo.ods = odsTipo; - } - mod_filtroTipo.eh_selValore += new EventHandler(mod_filtroTipo_eh_selValore); - mod_filtroMacchina.eh_selValore += new EventHandler(mod_filtroMacchina_eh_selValore); - } - - void mod_filtroMacchina_eh_selValore(object sender, EventArgs e) - { - // chiamo procedura ricostruzione ods con filtri... - checkFixOds(); - } - void mod_filtroTipo_eh_selValore(object sender, EventArgs e) - { - // chiamo procedura ricostruzione ods con filtri... - checkFixOds(); - } - /// - /// sistemo filtraggio con valori selezionati - /// - private void checkFixOds() - { - ods.FilterExpression = "( codMacchina LIKE '%{0}%' OR nomeMacchina LIKE '%{0}%' OR descrizione LIKE '%{0}%' )"; - if (mod_filtroTipo.valoreInt != 0) - { - ods.FilterExpression += " AND (idxTipo = {1})"; - } - if (mod_filtroMacchina.valoreInt != 0) - { - ods.FilterExpression += " AND (idxMacchina = {2})"; - } - ods.DataBind(); - } - /// - /// chiamato post modifica valore check/selezione nel selettore filtro impianto - /// - /// - /// - public void eh_selectedImpianto(object sender, EventArgs e) - { - if (mod_filtroImpianto.valoreInt != 0) - { - if (!mod_filtroMacchina.Visible) - { - mod_filtroMacchina.Visible = true; - } - else - { - mod_filtroMacchina.reset(); - } - mod_filtroMacchina.ods = odsMacchine; - } - else - { - mod_filtroMacchina.reset(); - mod_filtroMacchina.Visible = false; - } - } -} diff --git a/WebSites/WebGIM/mod_elencoRichieste.ascx b/WebSites/WebGIM/mod_elencoRichieste.ascx deleted file mode 100644 index bb22abc..0000000 --- a/WebSites/WebGIM/mod_elencoRichieste.ascx +++ /dev/null @@ -1,112 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_elencoRichieste.ascx.cs" - Inherits="mod_elencoRichieste" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> -<%@ Register Src="mod_periodoAnalisi.ascx" TagName="mod_periodoAnalisi" TagPrefix="uc1" %> -
-
- -
-
- -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
diff --git a/WebSites/WebGIM/mod_elencoRichieste.ascx.cs b/WebSites/WebGIM/mod_elencoRichieste.ascx.cs deleted file mode 100644 index d517926..0000000 --- a/WebSites/WebGIM/mod_elencoRichieste.ascx.cs +++ /dev/null @@ -1,374 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; -using System.Data; - -public partial class mod_elencoRichieste : ApplicationUserControl -{ - #region area da NON modificare - - #region area protected - - protected string _idxGridView; - protected string _idxGridViewExt; - protected bool _showNewBtn = false; - - - /// - /// aggiorna controlli datagrid e numero righe in pagina - /// - protected override void aggiornaControlliDataGL() - { - base.aggiornaControlliDataGL(); - grView.PageSize = _righeDataGridMed; - } - /// - /// traduce gli header delle colonne - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - /// - /// gestione evento richeista nuovo valore (mostra footer, ...) - /// - /// - /// - protected void btnNew_Click(object sender, EventArgs e) - { - // reset selezione... - resetSelezione(); - // mostro il footer oppure la riga dei dettagli x nuovo... - if (grView.FooterRow != null) - { - grView.FooterRow.Visible = true; - } - // sollevo evento nuovo valore... - if (eh_nuovoValore != null) - { - eh_nuovoValore(this, new EventArgs()); - } - } - /// - /// reset della selezione - /// - /// - /// - protected void btnReset_Click(object sender, EventArgs e) - { - resetSelezione(); - } - /// - /// gestione cambio selezione valore - /// - /// - /// - protected void grView_SelectedIndexChanged(object sender, EventArgs e) - { - // salvo in session il valore selezionato... - SteamWare.memLayer.ML.setSessionVal(string.Format("{0}_sel", _idxGridView), grView.SelectedValue, true); - // sollevo evento nuovo valore... - if (eh_selValore != null) - { - eh_selValore(this, new EventArgs()); - } - } - /// - /// resetta la selezione dei valori in caso di modifiche su altri controlli - /// - public void resetSelezione() - { - SteamWare.memLayer.ML.emptySessionVal(string.Format("{0}_sel", _idxGridView)); - grView.SelectedIndex = -1; - grView.DataBind(); - lblWarning.Visible = false; - if (eh_resetSelezione != null) - { - eh_resetSelezione(this, new EventArgs()); - } - } - - #endregion - - #region gestione eventi - - public event EventHandler eh_resetSelezione; - public event EventHandler eh_nuovoValore; - public event EventHandler eh_selValore; - - #endregion - - #region public - - /// - /// definisce visibilità btnNew - /// - public bool showNewBtn - { - get - { - return _showNewBtn; - } - set - { - _showNewBtn = value; - } - } - /// - /// effettua update del modulo - /// - public void doUpdate() - { - resetSelezione(); - } - - - #endregion - - #endregion - - #region area codice variabile - - /// - /// elenco colonne del datagrid - /// - /// - protected DataColumnCollection colonneObj() - { - DS_applicazione.v_intervExpDataTable tabella = new DS_applicazione.v_intervExpDataTable(); - DataColumnCollection colonne = tabella.Columns; - return colonne; - } - /// - /// inizializzazione valori di default - /// - /// - protected override void OnInit(EventArgs e) - { - base.OnInit(e); - _idxGridView = "numIntMtz"; - mod_periodoAnalisi1.eh_doUpdate += new EventHandler(mod_periodoAnalisi1_eh_doUpdate); - } - - void mod_periodoAnalisi1_eh_doUpdate(object sender, EventArgs e) - { - checkFixOds(); - } - /// - /// setta selected alla riga il cui valore key è in session - /// - /// - /// - protected void grView_RowDataBound(object sender, GridViewRowEventArgs e) - { - // se riga di dati... - if (e.Row.RowType == DataControlRowType.DataRow) - { - // ottengo la riga tipizzata... - System.Data.DataRowView _drv = (System.Data.DataRowView)e.Row.DataItem; - DS_applicazione.v_intervExpRow riga = (DS_applicazione.v_intervExpRow)_drv.Row; - if (SteamWare.memLayer.ML.StringSessionObj(_idxGridView) == riga.numIntMtz.ToString()) - { - grView.SelectedIndex = e.Row.RowIndex; - // salvo in session il valore selezionato... - SteamWare.memLayer.ML.setSessionVal(string.Format("{0}_sel", _idxGridView), SteamWare.memLayer.ML.StringSessionObj(_idxGridView)); - // sollevo evento nuovo valore... - if (eh_selValore != null) - { - eh_selValore(this, new EventArgs()); - } - } - } - } - /// - /// formatta il tooltip del ferma dalle... - /// - /// - /// - public string formatFermaDalle(object dataOraFermo) - { - return string.Format("{0}: {1:dd/MM/yy HH:mm}", traduci("inizioFermata"), dataOraFermo); - } - /// - /// restituice lo stile css dato lo stato dell'intervento - /// - /// - /// - public string stileDaStato(object idxStato) - { - string answ = "semaforoRosso"; - try - { - answ = TA_app.obj.taStati.getByIdxStato(Convert.ToInt32(idxStato))[0].stile; - } - catch - { } - return answ; - } - /// - /// restituice lo stile css data la priorità dell'intervento - /// - /// - /// - public string stileDaPrior(object idxPrior) - { - string answ = "semaforoRosso"; - try - { - answ = TA_app.obj.taPrior.getByIdxPriorita(Convert.ToInt32(idxPrior))[0].stile; - } - catch - { } - return answ; - } - /// - /// restituisce un testo trimamto a maxChar caratteri - /// - /// - /// - /// - public string trimmaTesto(object _testo, object _maxChar) - { - string answ = ""; - string testo = _testo.ToString(); - int maxChar = Convert.ToInt32(_maxChar); - if (testo.Length <= maxChar) - { - answ = testo; - } - else - { - answ = string.Format("{0}...", testo.Substring(0, maxChar)); - } - return answ; - } - /// - /// restituisce url contenente parametri per rendering pdf - /// - /// - /// - public string formattaUrl(object idx) - { - return String.Format("~/ExportPdf.aspx?tipo={0}&idx={1}", Convert.ToInt32(reportRichiesto.RichiestaIntervento), idx); - } - /// - /// prende in carico e stampa la scheda selezionata - /// - /// - /// - protected void btnPrendeInCarico_Click(object sender, ImageClickEventArgs e) - { - ImageButton imgBtn = (ImageButton)sender; - int idx = Convert.ToInt32(imgBtn.CommandArgument); - // prende in carico la scheda... - try - { - int? newStato = 0; - TA_app.obj.taInterventiMtz.sp_setPresaInCarico(Convert.ToInt32(idx), ref newStato); - } - catch (Exception exc) - { - logger.lg.scriviLog(string.Format("Errore durante presa in carico: {0}", exc), tipoLog.ERROR); - } - // stampo! - reportPrinter.obj.printReport(reportRichiesto.RichiestaIntervento, memLayer.ML.confReadString("stampanteRichiesteMtz"), idx.ToString()); - // update del gridView... - grView.DataBind(); - } - /// - /// restituisce true se è una richeista solo inserita e non ancora presa in carico - /// - /// - /// - public bool isPrInCarEnabl(object num) - { - bool answ = false; - // se l'utente è BASE la presa in carico NON è permessa... - if (user_std.UtSn.diritti.Select("COD_FUNZIONE = 'GIM_SU'").Length > 0) - { - try - { - int idxStato = TA_app.obj.taInterventiMtz.getByIdx(Convert.ToInt32(num))[0].idxStato; - if (idxStato == 1) - { - answ = true; - } - } - catch - { } - } - return answ; - } - /// - /// esegue traduzioni labels - /// - protected override void traduciObj() - { - base.traduciObj(); - chkMostraIntChiusi.Text = traduci("chkMostraIntChiusi_mostra"); - } - /// - /// cambia filtraggio... - /// - /// - /// - protected void chkMostraIntChiusi_CheckedChanged(object sender, EventArgs e) - { - checkFixOds(); - if (chkMostraIntChiusi.Checked == false) - { - chkMostraIntChiusi.Text = traduci("chkMostraIntChiusi_mostra"); - } - else - { - chkMostraIntChiusi.Text = traduci("chkMostraIntChiusi_nascondi"); - } - } - /// - /// sistemo filtraggio con valori selezionati - /// - private void checkFixOds() - { - ods.FilterExpression = "( codImpianto LIKE '%{0}%' OR nomeImpianto LIKE '%{0}%' OR codMacchina LIKE '%{0}%' OR nomeMacchina LIKE '%{0}%' OR descrizione LIKE '%{0}%' )"; - if (!chkMostraIntChiusi.Checked) - { - ods.FilterExpression += " AND (idxStato < 3)"; - } - ods.DataBind(); - } - /// - /// fix l'ods... - /// - /// - /// - protected void grView_PageIndexChanged(object sender, EventArgs e) - { - checkFixOds(); - } - #endregion -} diff --git a/WebSites/WebGIM/mod_famiglieMacchine.ascx b/WebSites/WebGIM/mod_famiglieMacchine.ascx deleted file mode 100644 index 4bbbe6a..0000000 --- a/WebSites/WebGIM/mod_famiglieMacchine.ascx +++ /dev/null @@ -1,50 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_famiglieMacchine.ascx.cs" - Inherits="mod_famiglieMacchine" %> -<%@ Register Src="mod_elFamMacch.ascx" TagName="mod_elFamMacch" TagPrefix="uc1" %> -<%@ Register Src="mod_elMacch2Fam.ascx" TagName="mod_elMacch2Fam" TagPrefix="uc2" %> -<%@ Register Src="mod_selettore.ascx" TagName="mod_selettore" TagPrefix="uc3" %> -
- - - - - - - - -
- -
- -
- -
-
- -
-
- -
-
- - - - - - -
- -
- -
-
-
- -
-
-
diff --git a/WebSites/WebGIM/mod_famiglieMacchine.ascx.cs b/WebSites/WebGIM/mod_famiglieMacchine.ascx.cs deleted file mode 100644 index 7acad57..0000000 --- a/WebSites/WebGIM/mod_famiglieMacchine.ascx.cs +++ /dev/null @@ -1,111 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_famiglieMacchine : System.Web.UI.UserControl -{ - protected void Page_Load(object sender, EventArgs e) - { - mod_elFamMacch1.eh_selezioneValore += new EventHandler(mod_elFamMacch1_eh_selezioneValore); - mod_elFamMacch1.eh_resetSelezione += new EventHandler(mod_elFamMacch1_eh_resetSelezione); - mod_elMacch2Fam1.eh_delValore += new EventHandler(mod_elMacch2Fam1_eh_delValore); - traduciObj(); - // assicura che la label del pulsante venga sempre aggiornata - if (pnlSceltaMacchine.Visible) - { - btnShowAdd.Text = user_std.UtSn.Traduci("hideAddMacchine"); - } - else - { - btnShowAdd.Text = user_std.UtSn.Traduci("showAddMacchine"); - } - - } - - private void traduciObj() - { - btnShowAdd.Text = traduci("showAddMacchine"); - btnAddMacchine.Text = traduci("AddMacchine2Fam"); - lblMacchineInteressate.Text = traduci("lblMacchineInteressate"); - } - /// - /// wrapper traduzione - /// - /// - /// - public string traduci(object lemma) - { - return user_std.UtSn.Traduci(lemma.ToString()); - } - void mod_elMacch2Fam1_eh_delValore(object sender, EventArgs e) - { - mod_elFamMacch1.doUpdate(); - } - - void mod_elFamMacch1_eh_resetSelezione(object sender, EventArgs e) - { - mod_elMacch2Fam1.Visible = false; - } - - void mod_elFamMacch1_eh_selezioneValore(object sender, EventArgs e) - { - mod_elMacch2Fam1.idxFamMacchSel = mod_elFamMacch1.idxFamMacc_sel; - mod_elMacch2Fam1.Visible = true; - } - protected void btnAddMacchine_Click(object sender, EventArgs e) - { - // controllo se si possa salvare - if ((mod_elFamMacch1.idxFamMacc_sel != -1) && (listMacchine.SelectedIndex != -1)) - { - lblWarning.Visible = false; - // ciclo ed inserisco le macchine selezionate - foreach (ListItem riga in listMacchine.Items) - { - // se è selezionata creo riga anche x lei... - if (riga.Selected) - { - associaMacchinaFamiglia(Convert.ToInt32(riga.Value), mod_elFamMacch1.idxFamMacc_sel); - } - } - mod_elMacch2Fam1.doUpdate(); - } - else - { - lblWarning.Visible = true; - lblWarning.Text = traduci("pregoSelMacchFamMacch"); - } - } - /// - /// associa la macchina indicata alla famiglia - /// - /// - /// - private bool associaMacchinaFamiglia(int idxMacchina, int idxFamMacc) - { - bool answ = false; - try - { - TA_app.obj.taMacc2Fam.InsertQuery(idxMacchina, idxFamMacc); - answ = true; - } - catch - { } - return answ; - } - protected void btnShowAdd_Click(object sender, EventArgs e) - { - pnlSceltaMacchine.Visible = !pnlSceltaMacchine.Visible; - if (pnlSceltaMacchine.Visible) - { - btnShowAdd.Text = user_std.UtSn.Traduci("hideAddMacchine"); - } - else - { - btnShowAdd.Text = user_std.UtSn.Traduci("showAddMacchine"); - } - - } -} diff --git a/WebSites/WebGIM/mod_filtro.ascx b/WebSites/WebGIM/mod_filtro.ascx deleted file mode 100644 index 7bb4e08..0000000 --- a/WebSites/WebGIM/mod_filtro.ascx +++ /dev/null @@ -1,7 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_filtro.ascx.cs" Inherits="mod_filtro" %> - - - - \ No newline at end of file diff --git a/WebSites/WebGIM/mod_filtro.ascx.cs b/WebSites/WebGIM/mod_filtro.ascx.cs deleted file mode 100644 index 0ca6a57..0000000 --- a/WebSites/WebGIM/mod_filtro.ascx.cs +++ /dev/null @@ -1,309 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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 SteamWare; - -public partial class mod_filtro : ApplicationUserControl -{ - protected string _css; - protected ObjectDataSource _ods; - protected string _valore - { - get - { - return memLayer.ML.StringSessionObj(string.Format("valFiltro_{0}", this.ID)); - } - set - { - memLayer.ML.setSessionVal(string.Format("valFiltro_{0}", this.ID), value, false); - } - } - protected bool _changeCheckEnabled = true; - protected bool _changeCheckVisible = true; - protected bool _changeSelEnabled = true; - protected string _where = ""; - protected override void traduciObj() - { - if (_changeCheckVisible) - { - if (!chkFilt.Checked) - { - chkFilt.Text = traduci("mostraSoloSelez"); - } - else - { - chkFilt.Text = traduci("mostraTutti"); - } - } - } - protected void chkFilt_CheckedChanged(object sender, EventArgs e) - { - // cambio modalità visualizzazione del filtro... - dlFilt.Visible = !dlFilt.Visible; - raiseSelEvent(); - } - - protected void raiseSelEvent() - { - if (!dlFilt.Visible) - { - memLayer.ML.setSessionVal(string.Format("valFiltro_{0}", this.ID), "", false); - } - else - { - _valore = dlFilt.SelectedValue; - } - if (eh_selValore != null) - { - eh_selValore(this, new EventArgs()); - } - } - protected void updateChk() - { - chkFilt.Enabled = _changeCheckEnabled; - if (!_changeCheckEnabled) - { - chkFilt.Checked = true; - dlFilt.Visible = true; - } - } - protected void updateSel() - { - dlFilt.Enabled = _changeSelEnabled; - } - protected void updateChkLbl() - { - chkFilt.Visible = _changeCheckVisible; - } - protected override void bindControlli() - { - updateChk(); - fixValore(); - where.Text = _where; - traduciObj(); - } - protected SteamWare.tipoVistaMod _modo = SteamWare.tipoVistaMod.editing; - - - /// - /// condizione where per ridurre elementi mostrati in selettore - /// - public string condizione - { - get - { - return _where; - } - set - { - _where = value; - } - } - - /// - /// fornisce il valore scelto o "*" se nulla selezionato - /// - public string valore - { - get - { - string answ = "*"; - if (chkFilt.Checked) - { - answ = dlFilt.SelectedValue; - } - return answ; - } - set - { - _valore = value; - fixValore(); - } - } - - /// - /// primo valore di una chiave multicampo - /// - public string val_1 - { - get - { - string answ = ""; - if (chkFilt.Checked) - { - try - { - string[] _dataKey = dlFilt.SelectedValue.Split('#'); - answ = _dataKey[0]; - } - catch - { } - } - else - { - answ = "*"; - } - return answ; - } - } - /// - /// secondo valore di una chiave multicampo - /// - public string val_2 - { - get - { - string answ = ""; - if (chkFilt.Checked) - { - try - { - string[] _dataKey = dlFilt.SelectedValue.Split('#'); - answ = _dataKey[1]; - } - catch - { } - } - else - { - answ = "*"; - } - return answ; - } - } - /// - /// fornisce il valore scelto o "0" se nulla selezionato o non valido - /// - public int valoreInt - { - get - { - int answ = 0; - try - { - if (chkFilt.Checked) - { - answ = Convert.ToInt32(dlFilt.SelectedValue); - } - } - catch - { } - return answ; - } - } - protected void fixValore() - { - if (_ods != null) - { - dlFilt.DataSource = _ods; - dlFilt.DataBind(); - if (_valore != "") - { - dlFilt.SelectedValue = _valore; - dlFilt.Visible = true; - chkFilt.Checked = true; - } - } - } - - - public event EventHandler eh_selValore; - - - /// - /// determina se sia possibile (de)selezionare il check di filtraggio, altrimenti sempre attivo - /// - public bool changeCheckEnabled - { - get - { - return _changeCheckEnabled; - } - set - { - _changeCheckEnabled = value; - updateChk(); - } - } - /// - /// determina se sia possibile modificare la selezione - /// - public bool changeSelEnabled - { - get - { - return _changeSelEnabled; - } - set - { - _changeSelEnabled = value; - updateSel(); - } - } - /// - /// determina se sia possibile visibile il check di filtraggio - /// - public bool changeCheckVisible - { - get - { - return _changeCheckVisible; - } - set - { - _changeCheckVisible = value; - updateChkLbl(); - } - } - protected void dlFilt_SelectedIndexChanged(object sender, EventArgs e) - { - raiseSelEvent(); - // salvo val selezionato... - } - - /// - /// oggetto ODS con cui popolare il selettore, VINCOLO abbia campi value(key) / label - /// - public ObjectDataSource ods - { - get - { - return _ods; - } - set - { - _ods = value; - bindControlli(); - } - } - /// - /// css applicato agli elementi del controllo - /// - public string css - { - get - { - return _css; - } - set - { - _css = value; - } - } - /// - /// resetta il controllo (un-checked) - /// - public void reset() - { - chkFilt.Checked = false; - dlFilt.Visible = false; - memLayer.ML.emptySessionVal(string.Format("valFiltro_{0}", this.ID)); - } -} \ No newline at end of file diff --git a/WebSites/WebGIM/mod_fixCal.ascx b/WebSites/WebGIM/mod_fixCal.ascx deleted file mode 100644 index 388fe1a..0000000 --- a/WebSites/WebGIM/mod_fixCal.ascx +++ /dev/null @@ -1,6 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_fixCal.ascx.cs" Inherits="mod_fixCal" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> - - - diff --git a/WebSites/WebGIM/mod_fixCal.ascx.cs b/WebSites/WebGIM/mod_fixCal.ascx.cs deleted file mode 100644 index 5f419e1..0000000 --- a/WebSites/WebGIM/mod_fixCal.ascx.cs +++ /dev/null @@ -1,18 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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; - -public partial class mod_fixCal : System.Web.UI.UserControl -{ - protected void Page_Load(object sender, EventArgs e) - { - - } -} diff --git a/WebSites/WebGIM/mod_gestCausali.ascx b/WebSites/WebGIM/mod_gestCausali.ascx deleted file mode 100644 index c2dcca9..0000000 --- a/WebSites/WebGIM/mod_gestCausali.ascx +++ /dev/null @@ -1,103 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_gestCausali.ascx.cs" - Inherits="mod_gestCausali" %> -<%@ Register Src="mod_filtro.ascx" TagName="mod_filtro" TagPrefix="uc1" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/WebSites/WebGIM/mod_gestCausali.ascx.cs b/WebSites/WebGIM/mod_gestCausali.ascx.cs deleted file mode 100644 index a43ad2d..0000000 --- a/WebSites/WebGIM/mod_gestCausali.ascx.cs +++ /dev/null @@ -1,112 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_gestCausali : ApplicationUserControl -{ - public event EventHandler eh_delValore; - - protected override void OnInit(EventArgs e) - { - base.OnInit(e); - if (!Page.IsPostBack) - { - mod_filtroFam.ods = odsFam; - } - } - /// - /// evento dati associati a controllo - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - /// - /// eliminato il valore genera l'evento - /// - /// - /// - protected void ods_Deleted(object sender, ObjectDataSourceStatusEventArgs e) - { - if (eh_delValore != null) - { - eh_delValore(this, new EventArgs()); - } - } - /// - /// esegue update - /// - public void doUpdate() - { - grView.DataBind(); - } - /// - /// determina se la causale sia cancellabile (ovvero non sia impiegata in alcuna registrazione di intervento... - /// - public bool isDeletable(object idxCausale) - { - bool answ = false; - try - { - if (TA_app.obj.taInterventiMtz.getByIdxCausale(Convert.ToInt32(idxCausale)).Rows.Count == 0) answ = true; - } - catch - { } - return answ; - } - /// - /// gestione evento inserimento nuovo record standard (se ZERO presenti) - /// - /// - /// - protected void btnNewFromEmpty_Click(object sender, EventArgs e) - { - // reset selezione... - resetSelezione(); - // i primi valori ("0") di default sono "ND"... li inserisco come standard... - TA_app.obj.taAnagCau.Insert(mod_filtroFam.valoreInt, "-- [NUOVA] non definita --", true); - grView.DataBind(); - } - /// - /// resetta la selezione dei valori in caso di modifiche su altri controlli - /// - public void resetSelezione() - { - grView.SelectedIndex = -1; - grView.DataBind(); - } - /// - /// reset delle selezioni - /// - /// - /// - protected void btnReset_Click(object sender, EventArgs e) - { - resetSelezione(); - } -} diff --git a/WebSites/WebGIM/mod_gestUtentiGIM.ascx b/WebSites/WebGIM/mod_gestUtentiGIM.ascx deleted file mode 100644 index 447e83e..0000000 --- a/WebSites/WebGIM/mod_gestUtentiGIM.ascx +++ /dev/null @@ -1,106 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_gestUtentiGIM.ascx.cs" - Inherits="mod_gestUtentiGIM" %> -
- - - - - - - - - - - - - - -
-

- -

-
- -

- -

-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- -
-
diff --git a/WebSites/WebGIM/mod_gestUtentiGIM.ascx.cs b/WebSites/WebGIM/mod_gestUtentiGIM.ascx.cs deleted file mode 100644 index f27087c..0000000 --- a/WebSites/WebGIM/mod_gestUtentiGIM.ascx.cs +++ /dev/null @@ -1,101 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_gestUtentiGIM : System.Web.UI.UserControl -{ - protected void Page_Load(object sender, EventArgs e) - { - traduciObj(); - } - - private void traduciObj() - { - lblUsers.Text = traduci("ElencoUtentiStd"); - lblSuperusers.Text = traduci("ElencoElUtentiSU"); - btnPromuovi.Text = traduci("promuoviUtente"); - btnDeclassa.Text = traduci("declassaUtente"); - } - /// - /// wrapper traduzione - /// - /// - /// - public string traduci(object lemma) - { - return user_std.UtSn.Traduci(lemma.ToString()); - } - /// - /// reset delle selezioni - /// - /// - /// - protected void btnResetU_Click(object sender, EventArgs e) - { - resetSelezioneUser(); - lblWarning.Visible = false; - } - /// - /// resetta la selezione dei valori in caso di modifiche su altri controlli - /// - public void resetSelezioneUser() - { - grViewUsers.SelectedIndex = -1; - grViewUsers.DataBind(); - } - /// - /// reset delle selezioni - /// - /// - /// - protected void btnResetSU_Click(object sender, EventArgs e) - { - resetSelezioneSuperUser(); - lblWarning.Visible = false; - } - /// - /// resetta la selezione dei valori in caso di modifiche su altri controlli - /// - public void resetSelezioneSuperUser() - { - grViewSuperusers.SelectedIndex = -1; - grViewSuperusers.DataBind(); - } - protected void btnPromuovi_Click(object sender, EventArgs e) - { - if (grViewUsers.SelectedIndex != -1) - { - lblWarning.Visible = false; - user_std.UtSn.assegnaDirittoUtente(grViewUsers.SelectedValue.ToString(), memLayer.ML.confReadString("autoEnrollCdc"), "GIM", "GIM_SU"); - } - else - { - lblWarning.Visible = true; - lblWarning.Text = traduci("utenteNonSelezionato"); - } - resetSelezioneUser(); - grViewUsers.DataBind(); - resetSelezioneSuperUser(); - grViewSuperusers.DataBind(); - } - protected void btnDeclassa_Click(object sender, EventArgs e) - { - if (grViewSuperusers.SelectedIndex != -1) - { - lblWarning.Visible = false; - user_std.UtSn.rimuoviDirittoUtente(grViewSuperusers.SelectedValue.ToString(), memLayer.ML.confReadString("autoEnrollCdc"), "GIM", "GIM_SU"); - } - else - { - lblWarning.Visible = true; - lblWarning.Text = traduci("utenteNonSelezionato"); - } - resetSelezioneUser(); - grViewUsers.DataBind(); - resetSelezioneSuperUser(); - grViewSuperusers.DataBind(); - } -} diff --git a/WebSites/WebGIM/mod_impianti.ascx b/WebSites/WebGIM/mod_impianti.ascx deleted file mode 100644 index 5f92cf1..0000000 --- a/WebSites/WebGIM/mod_impianti.ascx +++ /dev/null @@ -1,185 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_impianti.ascx.cs" - Inherits="mod_impianti" %> -<%@ Register Src="mod_selettore_ajax.ascx" TagName="mod_selettore_ajax" TagPrefix="uc1" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> - - - - - - - - - - - - - - - - - - - -
- - - -
-
- - - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/WebSites/WebGIM/mod_impianti.ascx.cs b/WebSites/WebGIM/mod_impianti.ascx.cs deleted file mode 100644 index bfbf8c1..0000000 --- a/WebSites/WebGIM/mod_impianti.ascx.cs +++ /dev/null @@ -1,448 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; -using System.Data; - -public partial class mod_impianti : ApplicationUserControl -{ - #region area da NON modificare - - #region area protected - - protected string _idxGridView; - protected string _idxGridViewExt; - protected bool _showNewBtn = false; - - /// - /// imposta errore non cancellabilità per record correlati - /// - protected void setNoDeletableErrorMessage() - { - // mostro avviso di non cancellabilità... - lblWarning.Text = traduci("notDeletable_hasChild"); - lblWarning.Visible = true; - grView.DataBind(); - } - /// - /// esegue cancellazione record - /// - protected void doDelete() - { - // posso cancellare... - lblWarning.Visible = false; - ods.Delete(); - } - /// - /// Valida la cancellazione per i dati mostrati dal gridView - /// richiede sia preventivamentedichiarato _idxGridView - /// - /// - /// - protected virtual void validaDelete(object sender, ObjectDataSourceMethodEventArgs e) - { - int idx = Convert.ToInt32(e.InputParameters[string.Format("Original_{0}", _idxGridView)]); - if (objIsNotRelated(idx)) - { - // annullo cancellazione... - e.Cancel = true; - // seleziono record... metto in session valore idx e poi ridisegno... - SteamWare.memLayer.ML.setSessionVal(_idxGridView, idx); - setNoDeletableErrorMessage(); - } - else - { - doDelete(); - } - } - - /// - /// recupera i dati di un nuovo record contenuti nel footer di un gridView; - /// questi devono esses opportunamente nominati (es: txt{0}, dl{0}, ...) - /// - /// - /// - protected void recuperaFooter(object sender, ObjectDataSourceMethodEventArgs e) - { - //recupero la riga footer... - DataColumnCollection colonne = colonneObj(); - string nomeCol; - string tipoColonna = ""; - foreach (DataColumn colonna in colonne) - { - nomeCol = colonna.ColumnName; - // cerco un textbox o quello che sia... - if (grView.FooterRow.FindControl(string.Format("txt{0}", nomeCol)) != null) - { - tipoColonna = "textBox"; - } - else if (grView.FooterRow.FindControl(string.Format("cal_{0}", nomeCol)) != null) - { - tipoColonna = "calTextBox"; - } - else if (grView.FooterRow.FindControl(string.Format("dl{0}", nomeCol)) != null) - { - tipoColonna = "dropDownList"; - } - else if (grView.FooterRow.FindControl(string.Format("chk{0}", nomeCol)) != null) - { - tipoColonna = "checkBox"; - } - else if (grView.FooterRow.FindControl(string.Format("selAjax_{0}", nomeCol)) != null) - { - tipoColonna = "selAjax"; - } - // in base al tipo salvo negli inputparameters dell'ODS - switch (tipoColonna) - { - case "textBox": - e.InputParameters[nomeCol] = ((TextBox)grView.FooterRow.FindControl(string.Format("txt{0}", nomeCol))).Text; - break; - case "calTextBox": - e.InputParameters[nomeCol] = Convert.ToDateTime(((TextBox)grView.FooterRow.FindControl(string.Format("cal_{0}", nomeCol))).Text); - break; - case "dropDownList": - e.InputParameters[nomeCol] = ((DropDownList)grView.FooterRow.FindControl(string.Format("dl{0}", nomeCol))).SelectedValue; - break; - case "checkBox": - e.InputParameters[nomeCol] = ((CheckBox)grView.FooterRow.FindControl(string.Format("dl{0}", nomeCol))).Checked; - break; - case "selAjax": - e.InputParameters[nomeCol] = ((mod_selettore_ajax)grView.FooterRow.FindControl(string.Format("selAjax_{0}", nomeCol))).valore; - break; - default: - break; - } - tipoColonna = ""; - } - } - /// - /// inserisce nuovo valore da footer - /// - /// - /// - protected void lblIns_click(object sender, EventArgs e) - { - // click su inserimento, chiamo il metodo insert dell'ObjectDataSource - ods.Insert(); - } - /// - /// annulla inserimento nuovo valore da footer - /// - /// - /// - protected void lblCanc_click(object sender, EventArgs e) - { - // annullo inserimento: nascondo footer, bind controlli... - grView.FooterRow.Visible = false; - } - - /// - /// aggiorna controlli datagrid e numero righe in pagina - /// - protected override void aggiornaControlliDataGL() - { - base.aggiornaControlliDataGL(); - grView.PageSize = _righeDataGridMed; - } - - /// - /// gestione evento richeista nuovo valore (mostra footer, ...) - /// - /// - /// - protected void btnNew_Click(object sender, EventArgs e) - { - // reset selezione... - resetSelezione(); - // mostro il footer oppure la riga dei dettagli x nuovo... - if (grView.FooterRow != null) - { - grView.FooterRow.Visible = true; - } - // sollevo evento nuovo valore... - if (eh_nuovoValore != null) - { - eh_nuovoValore(this, new EventArgs()); - } - } - /// - /// reset della selezione - /// - /// - /// - protected void btnReset_Click(object sender, EventArgs e) - { - resetSelezione(); - } - /// - /// gestione cambio selezione valore - /// - /// - /// - protected void grView_SelectedIndexChanged(object sender, EventArgs e) - { - // salvo in session il valore selezionato... - SteamWare.memLayer.ML.setSessionVal(string.Format("{0}_sel", _idxGridView), grView.SelectedValue); - // sollevo evento nuovo valore... - if (eh_selValore != null) - { - eh_selValore(this, new EventArgs()); - } - } - /// - /// resetta la selezione dei valori in caso di modifiche su altri controlli - /// - public void resetSelezione() - { - SteamWare.memLayer.ML.emptySessionVal(string.Format("{0}_sel", _idxGridView)); - grView.SelectedIndex = -1; - grView.DataBind(); - lblWarning.Visible = false; - if (eh_resetSelezione != null) - { - eh_resetSelezione(this, new EventArgs()); - } - } - - #endregion - - #region gestione eventi - - public event EventHandler eh_resetSelezione; - public event EventHandler eh_nuovoValore; - public event EventHandler eh_selValore; - - #endregion - - #region public - - /// - /// definisce visibilità btnNew - /// - public bool showNewBtn - { - get - { - return _showNewBtn; - } - set - { - _showNewBtn = value; - } - } - /// - /// effettua update del modulo - /// - public void doUpdate() - { - resetSelezione(); - } - - - #endregion - - #endregion - - #region area codice variabile - - /// - /// verifica complessiva non esistenza record child - /// - /// - /// - protected bool objIsNotRelated(object idxObj) - { - bool answ = false; - try - { - answ = (TA_app.obj.taInterventiMtz.getByIdxImpianto(Convert.ToInt32(idxObj)).Rows.Count == 0); - } - catch - { } - return answ; - } - /// - /// elenco colonne del datagrid - /// - /// - protected DataColumnCollection colonneObj() - { - DS_applicazione.AnagImpiantiDataTable tabella = new DS_applicazione.AnagImpiantiDataTable(); - DataColumnCollection colonne = tabella.Columns; - return colonne; - } - /// - /// inizializzazione valori di default - /// - /// - protected override void OnInit(EventArgs e) - { - base.OnInit(e); - _idxGridView = "idxImpianto"; - } - /// - /// setta selected alla riga il cui valore key è in session - /// - /// - /// - protected void grView_RowDataBound(object sender, GridViewRowEventArgs e) - { - // se riga di dati... - if (e.Row.RowType == DataControlRowType.DataRow) - { - // ottengo la riga tipizzata... - System.Data.DataRowView _drv = (System.Data.DataRowView)e.Row.DataItem; - DS_applicazione.AnagImpiantiRow riga = (DS_applicazione.AnagImpiantiRow)_drv.Row; - if (SteamWare.memLayer.ML.StringSessionObj(_idxGridView) == riga.idxImpianto.ToString()) - { - grView.SelectedIndex = e.Row.RowIndex; - // salvo in session il valore selezionato... - SteamWare.memLayer.ML.setSessionVal(string.Format("{0}_sel", _idxGridView), SteamWare.memLayer.ML.StringSessionObj(_idxGridView)); - // sollevo evento nuovo valore... - if (eh_selValore != null) - { - eh_selValore(this, new EventArgs()); - } - } - } - } - /// - /// svuoto da cache post update - /// - /// - /// - protected void ods_Updated(object sender, ObjectDataSourceStatusEventArgs e) - { - // svuoto da cache... - } - /// - /// gestione evento inserimento nuovo record standard (se ZERO presenti) - /// - /// - /// - protected void btnNewFromEmpty_Click(object sender, EventArgs e) - { - // reset selezione... - resetSelezione(); - // i primi valori ("0") di default sono "ND"... li inserisco come standard... - string codImp = memLayer.ML.confReadString("defaultCodImp"); - TA_app.obj.taImpianti.Insert(codImp, "-- [NUOVO] Nome Impianto non definito --", "tipo n.d.", DateTime.Today, DateTime.Today.AddYears(10)); - grView.DataBind(); - } - /// - /// salvo in session che il prox comando è clonare... - /// - /// - /// - protected void imgClona_Click(object sender, ImageClickEventArgs e) - { - SteamWare.memLayer.ML.setSessionVal("nextObjCommand", "clonaObj"); - } - /// - /// in caso di aggiornamento verifico se sia salvato un comando clona... - /// - /// - /// - protected void grView_RowUpdating(object sender, GridViewUpdateEventArgs e) - { - // carico l'idx dell'oggetto - int _idx = Convert.ToInt32(e.Keys["idxImpianto"]); - string _comando = ""; - if (SteamWare.memLayer.ML.isInSessionObject("nextObjCommand")) - { - _comando = SteamWare.memLayer.ML.StringSessionObj("nextObjCommand"); - SteamWare.memLayer.ML.emptySessionVal("nextObjCommand"); - } - // verifico il tipo di richiesta (up/down level, clona o update normale - switch (_comando) - { - case "clonaObj": - TA_app.obj.taImpianti.sp_clonaImpianto(_idx); - grView.EditIndex = -1; - grView.DataBind(); - // blocco update! - e.Cancel = true; - break; - default: - // faccio update! - break; - } - } - /// - /// determina se sia cancellabile dall'idx (1 e quelli con child NON LO SONO...) - /// - /// - /// - public bool isDeletable(object _idx) - { - bool answ = false; - int idx = -1; - try - { - idx = Convert.ToInt32(_idx); - } - catch - { } - int numMacchineImpianto = TA_app.obj.taMacchine.getByIdxImpianto(idx).Rows.Count; - if (idx > 1 && numMacchineImpianto < 1) answ = true; - return answ; - } - - /// - /// determina se sia editabile dall'idx (1 NON LO E'...) - /// - /// - /// - public bool isEditable(object _idx) - { - bool answ = false; - int idx = -1; - try - { - idx = Convert.ToInt32(_idx); - } - catch - { } - if (idx > 1) answ = true; - return answ; - } - - /// - /// traduce gli header delle colonne - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - if (eh_resetSelezione != null) - { - eh_resetSelezione(this, new EventArgs()); - } - } - } - - #endregion -} \ No newline at end of file diff --git a/WebSites/WebGIM/mod_insertRichiesta.ascx b/WebSites/WebGIM/mod_insertRichiesta.ascx deleted file mode 100644 index bd594ad..0000000 --- a/WebSites/WebGIM/mod_insertRichiesta.ascx +++ /dev/null @@ -1,164 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_insertRichiesta.ascx.cs" - Inherits="mod_insertRichiesta" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> -<%@ Register Src="mod_dataOra.ascx" TagName="mod_dataOra" TagPrefix="uc1" %> - -
-
-
- -
-
-
-
- -
-
-
- -
-
-
- -
-
-
- - - - - - - - - - -
-
-
- - - - - - -
-
-
-
- - - - - - - - - -
-
-
- -
-
-
-
-
- - - -
-
-
- - -
-
-
-
-
- -
-
-
-
- - - - -
-
-
- - - - -
-
- -
-
- -
-
-
-
-
- - - - - - - - -
-
-
- -
- - -
- -
-
-
-
- -
-

- -

-
- -
-
- -    - -
-
-
diff --git a/WebSites/WebGIM/mod_insertRichiesta.ascx.cs b/WebSites/WebGIM/mod_insertRichiesta.ascx.cs deleted file mode 100644 index a4cda81..0000000 --- a/WebSites/WebGIM/mod_insertRichiesta.ascx.cs +++ /dev/null @@ -1,182 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_insertRichiesta : System.Web.UI.UserControl -{ - #region eventi - - public event EventHandler eh_newReq; - public event EventHandler eh_done; - - #endregion - - protected bool _causVis = false; - /// - /// determina la visibilità del panel causali - /// - public bool causaliVisibili - { - get - { - return _causVis; - } - set - { - _causVis = value; - } - } - /// - /// avvio controllo - /// - /// - /// - protected void Page_Load(object sender, EventArgs e) - { - if (!Page.IsPostBack) - { - traduciObj(); - setFixedVal(); - fixVisibPnl(); - } - } - /// - /// imposta i valori calcolati e fissi... - /// - private void setFixedVal() - { - // recupero valori di riferimento - int shift = memLayer.ML.confReadInt("shiftTurno"); - int durataTurno = memLayer.ML.confReadInt("durataTurno"); - int turno = Convert.ToInt32(Math.Ceiling((double)Convert.ToDouble(DateTime.Now.AddHours(-shift + 1).Hour) / durataTurno)); - int delay = memLayer.ML.confReadInt("defaultDelay"); - // inserisco valori di default - txtDataOra.Text = string.Format("{0:dd/MM/yyyy HH:mm}", DateTime.Now); - txtDataLav.Text = string.Format("{0:dd/MM/yyyy}", DateTime.Now.AddHours(-shift + 1)); - txtTurnoLav.Text = turno.ToString(); - mod_dataOra1.valore = DateTime.Now.AddMinutes(-delay); - chkImpFermo.Checked = false; - } - /// - /// sistema la visibilità dei controlli - /// - private void fixVisibPnl() - { - pnlCausali.Visible = _causVis; - } - /// - /// traduzione - /// - /// - /// - public string traduci(object lemma) - { - return user_std.UtSn.Traduci(lemma.ToString()); - } - /// - /// sistema le labels - /// - private void traduciObj() - { - lblTitolo.Text = traduci("lblInsRichiestaMtz"); - lblDataOra.Text = traduci("lblDataOraRich"); - lblDataLav.Text = traduci("lblDataLav"); - lblTurnoLav.Text = traduci("lblTurnoLav"); - btnSend.Text = traduci("btnInviaRichiesta"); - lblImpianto.Text = traduci("lblImpianto"); - lblMacchina.Text = traduci("lblMacchina"); - lblDescrGuasto.Text = traduci("lblDescrGuasto"); - lblDettagliGuasto.Text = traduci("lblDettagliGuasto"); - lblMatr.Text = traduci("lblMatr"); - lblPrior.Text = traduci("lblPrior"); - lblFermaDalleData.Text = traduci("lblFermaDalle"); - lblAmbito.Text = traduci("lblAmbito"); - lblTipoGuasto.Text = traduci("lblTipoGuasto"); - chkImpFermo.Text = traduci("chkImpFermo"); - // setup stringhe rimando link - lnkbInsertNewReq.Text = traduci("lnkbInsertNewReq"); - lnkGoToReqList.Text = traduci("lnkGoToReqList"); - lblEsitoInserimento.Text = traduci("lblEsitoInserimento"); - // setup stringhe validazione - valSummary.HeaderText = traduci("errori"); - rfvReparto.ErrorMessage = string.Format("{0}: {1}", traduci("campoRichiesto"), traduci("reparto")); - rfvMacchina.ErrorMessage = string.Format("{0}: {1}", traduci("campoRichiesto"), traduci("macchina")); - rfvMatr.ErrorMessage = string.Format("{0}: {1}", traduci("campoRichiesto"), traduci("matricola")); - } - /// - /// aggiorna elenco macchine selezionato impianto - /// - /// - /// - protected void listImpianti_SelectedIndexChanged(object sender, EventArgs e) - { - // aggiorno altro selettore... - listMacchine.DataBind(); - } - /// - /// salva ed invia richeista - /// - /// - /// - protected void btnSend_Click(object sender, EventArgs e) - { - // salvare valori... - int? numReq = 0; - try - { - // sistemo i valori - DateTime richiesta = Convert.ToDateTime(txtDataOra.Text.Trim()); - DateTime dataLav = Convert.ToDateTime(txtDataLav.Text.Trim()); - int turno = Convert.ToInt32(txtTurnoLav.Text); - string matr = txtMatr.Text.Trim(); - DateTime inizioGuasto = mod_dataOra1.valore; - int idxAmbito = Convert.ToInt32(ddlAmbito.SelectedValue); - int idxPrior = Convert.ToInt32(ddlPrior.SelectedValue); - bool isFermo = chkImpFermo.Checked; - int idxTipo = Convert.ToInt32(ddlTipo.SelectedValue); - int idxImpianto = Convert.ToInt32(listImpianti.SelectedValue); - int idxMacchina = Convert.ToInt32(listMacchine.SelectedValue); - string descrizione = txtDescrizione.Text.Trim(); - int idxCausale = 1; - // cerco se ci sia un altro valore selezionato... - try - { - idxCausale = Convert.ToInt32(listCausali.SelectedValue); - } - catch - { } - // stored inserimento! - TA_app.obj.taInterventiMtz.sp_insRichiesta(richiesta, dataLav, turno, matr, inizioGuasto, idxAmbito, idxPrior, isFermo, idxTipo, idxImpianto, idxMacchina, descrizione, idxCausale, ref numReq); - } - catch (Exception exc) - { - logger.lg.scriviLog("Errore inserimento nuova richiesta!", tipoLog.ERROR); - logger.lg.scriviLog(exc.ToString(), tipoLog.EXCEPTION); - } - //poi mostrare pnl richiesta con "ticket" generato + link x vedere elenco oppure nuova... - pnlMain_InsRichiesta.Visible = false; - pnlMain_ShowTicket.Visible = true; - lblNumRichInserted.Text = string.Format("{0} {1}", traduci("newReqInserted"), (int)numReq); - if (eh_done != null) - { - eh_done(this, new EventArgs()); - } - } - /// - /// inverte visibilità pannelli - /// - /// - /// - protected void lnkbtnInsertNewReq_Click(object sender, EventArgs e) - { - pnlMain_InsRichiesta.Visible = true; - pnlMain_ShowTicket.Visible = false; - if (eh_newReq != null) - { - eh_newReq(this, new EventArgs()); - } - } -} diff --git a/WebSites/WebGIM/mod_interventoOpMtz.ascx b/WebSites/WebGIM/mod_interventoOpMtz.ascx deleted file mode 100644 index 1b9a9e8..0000000 --- a/WebSites/WebGIM/mod_interventoOpMtz.ascx +++ /dev/null @@ -1,112 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_interventoOpMtz.ascx.cs" - Inherits="mod_interventoOpMtz" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/WebSites/WebGIM/mod_interventoOpMtz.ascx.cs b/WebSites/WebGIM/mod_interventoOpMtz.ascx.cs deleted file mode 100644 index 47385ae..0000000 --- a/WebSites/WebGIM/mod_interventoOpMtz.ascx.cs +++ /dev/null @@ -1,128 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_interventoOpMtz : ApplicationUserControl -{ - public event EventHandler eh_resetSelezione; - /// - /// evento dati associati a controllo - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - /// - /// reset delle selezioni - /// - /// - /// - protected void btnReset_Click(object sender, EventArgs e) - { - resetSelezione(); - } - /// - /// resetta la selezione dei valori in caso di modifiche su altri controlli - /// - public void resetSelezione() - { - grView.SelectedIndex = -1; - grView.DataBind(); - if (eh_resetSelezione != null) - { - eh_resetSelezione(this, new EventArgs()); - } - } - /// - /// seleziono valore in editing... - /// - /// - /// - protected void grView_RowEditing(object sender, GridViewEditEventArgs e) - { - // seleziono la riga corrente... - grView.SelectedIndex = e.NewEditIndex; - } - /// - /// gestione evento inserimento nuovo record standard (se ZERO presenti) - /// - /// - /// - protected void btnNewFromEmpty_Click(object sender, EventArgs e) - { - // reset selezione... - resetSelezione(); - int numIntMtz = memLayer.ML.IntSessionObj("numIntMtz_sel"); - string matr = memLayer.ML.confReadString("defaultMatr"); - TA_app.obj.taIntOpMtz.Insert(numIntMtz, matr, 0); - grView.DataBind(); - } - /// - /// restituisce un booleano se sia abilitato inserimento nuovi valori (solo se NON C'E' GIA' un operatore con amtricola di default...) - /// - /// - public bool canInsertNew() - { - bool answ = false; - int numIntMtz = memLayer.ML.IntSessionObj("numIntMtz_sel"); - string matr = memLayer.ML.confReadString("defaultMatr"); - try - { - answ = (TA_app.obj.taIntOpMtz.getByMatrNumIntMtz(numIntMtz, matr).Rows.Count == 0); - } - catch - { } - return (answ && isOnEdit); - } - /// - /// restituisce true se il controllo è in modalità editing (e non selezione...) - /// - public bool isOnEdit - { - get - { - return _vistaModulo == tipoVistaMod.editing; - } - } - /// - /// traduce matricola in matr + cognome + nome - /// - /// - /// - public string traduciMatrOp(object matr) - { - string answ = ""; - try - { - answ = TA_app.obj.taSelMatrOp.getByValue(matr.ToString())[0].label; - } - catch - { } - return answ; - } -} diff --git a/WebSites/WebGIM/mod_lemmiVocab.ascx b/WebSites/WebGIM/mod_lemmiVocab.ascx deleted file mode 100644 index a01f83f..0000000 --- a/WebSites/WebGIM/mod_lemmiVocab.ascx +++ /dev/null @@ -1,53 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_lemmiVocab.ascx.cs" - Inherits="mod_lemmiVocab" %> - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
diff --git a/WebSites/WebGIM/mod_lemmiVocab.ascx.cs b/WebSites/WebGIM/mod_lemmiVocab.ascx.cs deleted file mode 100644 index 00ff1d3..0000000 --- a/WebSites/WebGIM/mod_lemmiVocab.ascx.cs +++ /dev/null @@ -1,57 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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 SteamWare; - -public partial class mod_lemmiVocab : ApplicationUserControl -{ - #region protected - - protected override void aggiornaControlliDataGL() - { - base.aggiornaControlliDataGL(); - grView.PageSize = _righeDataGridAnagr; - } - - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - /// - /// aggiorna i dati mostrati - /// - public void doUpdate() - { - ods.DataBind(); - grView.DataBind(); - } - - #endregion -} diff --git a/WebSites/WebGIM/mod_login.ascx b/WebSites/WebGIM/mod_login.ascx deleted file mode 100644 index a891cc9..0000000 --- a/WebSites/WebGIM/mod_login.ascx +++ /dev/null @@ -1,54 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_login.ascx.cs" Inherits="mod_login" %> - - - - - -
- -
- - - - - - - - - - - - - - - - -
- - - -
- - - -
- - - -
- -
-
- - - - - - - -
- -
- -
diff --git a/WebSites/WebGIM/mod_login.ascx.cs b/WebSites/WebGIM/mod_login.ascx.cs deleted file mode 100644 index dd17a41..0000000 --- a/WebSites/WebGIM/mod_login.ascx.cs +++ /dev/null @@ -1,242 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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 SteamWare; - -/// -/// classe gestione login e forzatura login -/// -public partial class mod_login : ApplicationUserControl -{ - #region area protected/private - - #region area proprietà - - private SteamWare.loginMode _isForceUser = SteamWare.loginMode.normale; - - #endregion - - #region area metodi - - /// - /// imposta la modalità di login tra normale / forceUser - /// - private void setLoginMode() - { - if (_isForceUser == SteamWare.loginMode.forceUser) - { - pnlForceUser.Visible = true; - } - else - { - pnlForceUser.Visible = false; - } - } - - protected override void traduciObj() - { - lblPwd.Text = user_std.UtSn.Traduci("lblPwd"); - lblUser.Text = user_std.UtSn.Traduci("lblUser"); - lblDominio.Text = user_std.UtSn.Traduci("lblDominio"); - lblTitolo.Text = user_std.UtSn.Traduci("ForzaUtente"); - btnOk.Text = user_std.UtSn.Traduci("btnCommit"); - } - - /// - /// prova a verificare se l'utente sia ok x AD credentials - /// - private void AdLogin() - { - lblMessage.Text = "User not authenticated..."; - if (Page.User.Identity.IsAuthenticated) - { - //recupera user windows se c'è... - string ad_name = Page.User.Identity.Name; - string delimStr = "\\"; - char[] delimiter = delimStr.ToCharArray(); - string[] dom_user = ad_name.Split(delimiter, 2); - // passo al controllo di verifica ADuserOk... - user_std _utente = new user_std(); - if (_utente.ADuserOk(dom_user[0], dom_user[1])) - { - bool fatto = _utente.startUpUtente(dom_user[0], dom_user[1]); - if (fatto) - { - SteamWare.logger.lg.scriviLog(string.Format("L'utente {0} ({1}) ha effettuato il login correttamente", _utente.CognomeNome, _utente.userNameAD), SteamWare.tipoLog.INFO); - if (Login_ok != null) - { - Login_ok(this, new EventArgs()); - } - } - else - { - lblMessage.Text = String.Format("{0}
There are some problems instatiating user: {1}/{2}", user_std.UtSn.Traduci("AccessFail"), dom_user[0], dom_user[1]); - SteamWare.logger.lg.scriviLog(String.Format("Accesso fallito, problemi ad istanziare l'utente {0}/{1}", dom_user[0], dom_user[1]), SteamWare.tipoLog.ERROR); - if (Login_Error != null) - { - Login_Error(this, new EventArgs()); - } - } - } - else - { - if (memLayer.ML.confReadBool("autoEnrollEnabled")) - { - // rimando al modulo di auto enroll... - Response.Redirect("autoEnroll.aspx"); - } - else - { - lblMessage.Text = String.Format("{0}
user not allowed: {1}/{2}", user_std.UtSn.Traduci("AccessFail"), dom_user[0], dom_user[1]); - SteamWare.logger.lg.scriviLog(String.Format("Utente non autorizzato: {0}/{1}", dom_user[0], dom_user[1]), SteamWare.tipoLog.WARNING); - if (Login_Error != null) - { - Login_Error(this, new EventArgs()); - } - } - } - } - else - { - lblMessage.Text = user_std.UtSn.Traduci("AccessFail") + user_std.UtSn.Traduci("UsrNotAuth"); - SteamWare.logger.lg.scriviLog(String.Format("Accesso fallito, utente non autenticato"), SteamWare.tipoLog.WARNING); - if (Login_Error != null) - { - Login_Error(this, new EventArgs()); - } - } - } - - /// - /// effettua verifiche e se concesso permette di forzare l'accesso utente - /// - private void ForceUserIdentity() - { - if (Page.User.Identity.IsAuthenticated) - { - bool _allowForceUser = false; - try - { - _allowForceUser = SteamWare.memLayer.ML.confReadBool("_allowForceUser"); - } - catch - { - _allowForceUser = false; - } - if (_allowForceUser) - { - if (authKey.Text == "forzaInter") // verifica passphrase... - { - user_std _utente = new user_std(); - user_std.UtSn.isForcedUser = true; - bool fatto = _utente.startUpUtente(dominio.Text, user.Text); - if (fatto) - { - string _rigaLog = String.Format("User {0} has forced user identity ok: logged as \t {1}\\{2}", Page.User.Identity.Name, dominio.Text, user.Text); - SteamWare.logger.lg.scriviLog(_rigaLog, SteamWare.tipoLog.INFO); - if (Login_ok != null) - { - Login_ok(this, new EventArgs()); - } - } - } - else - { - lblMessage.Text = String.Format("{0}
key not allowed for operation!!! operation logged!!!", user_std.UtSn.Traduci("AccessFail")); - mandaEmail(_fromEmail, _adminEmail, "Attenzione: tentativo di accesso non autorizzato!", String.Format("Tentativo di forcing user non autorizzato!
L'utente {0} ha tentato di accedere a {1} forzando l'utente ma la sua key autorizzativa e' sbagliata...", Page.User.Identity.Name, user_std.UtSn.Traduci(SteamWare.memLayer.ML.confReadString("defaultApp")))); - string _rigaLog = String.Format("User {0}\t tried to force user - wrong password - he tried to log as \t {1}\\{2}", Page.User.Identity.Name, dominio.Text, user.Text); - SteamWare.logger.lg.scriviLog(_rigaLog, SteamWare.tipoLog.WARNING); - if (Login_Error != null) - { - Login_Error(this, new EventArgs()); - } - } - } - else - { - mandaEmail(_fromEmail, _adminEmail, "Attenzione: tentativo di accesso non autorizzato!", String.Format("Tentativo di forcing user non autorizzato!
L'utente {0} ha tentato di accedere a {1} forzando l'utente ma la funzione e' disabilitata...", Page.User.Identity.Name, user_std.UtSn.Traduci(SteamWare.memLayer.ML.confReadString("defaultApp")))); - string _rigaLog = String.Format("User {0}\t tried to force user - access disabled - he tried to log as \t {1}\\{2}", Page.User.Identity.Name, dominio.Text, user.Text); - SteamWare.logger.lg.scriviLog(_rigaLog, SteamWare.tipoLog.WARNING); - if (Login_Error != null) - { - Login_Error(this, new EventArgs()); - } - } - } - else - { - lblMessage.Text = string.Format("{0}
user not authenticated!
", user_std.UtSn.Traduci("AccessFail")); - if (Login_Error != null) - { - Login_Error(this, new EventArgs()); - } - string _rigaLog = String.Format("\t Someone tried to force user - real user: \t - not autenticated - \t tried to log as \t {0}\\{1}", dominio.Text, user.Text); - SteamWare.logger.lg.scriviLog(_rigaLog, SteamWare.tipoLog.WARNING); - } - } - - protected void btnOk_Click(object sender, EventArgs e) - { - ForceUserIdentity(); - } - - #endregion - - #endregion - - #region area public - - #region eventi pubblici esposti - - public event EventHandler Login_ok; - public event EventHandler Login_Error; - - #endregion - - #region area proprietà - - /// - /// modalità funzionamento controllo tra normale (ActiveDirectory e user auth di default) e forceUser - /// - public SteamWare.loginMode modoLogin - { - get - { - return _isForceUser; - } - set - { - _isForceUser = value; - } - } - - #endregion - - - /// - /// avvio pagina - /// - protected override void Page_Load(object sender, EventArgs e) - { - base.Page_Load(sender, e); - //carico da web.config i default values - loadDefaultsWebConfig(); - // procedo... - setLoginMode(); - Session.RemoveAll(); - if (_isForceUser == SteamWare.loginMode.normale) - { - AdLogin(); - } - } - - #endregion - -} diff --git a/WebSites/WebGIM/mod_macchine.ascx b/WebSites/WebGIM/mod_macchine.ascx deleted file mode 100644 index 7aa7468..0000000 --- a/WebSites/WebGIM/mod_macchine.ascx +++ /dev/null @@ -1,366 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_macchine.ascx.cs" - Inherits="mod_macchine" %> -<%@ Register Src="mod_selettore_ajax.ascx" TagName="mod_selettore_ajax" TagPrefix="uc1" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> -<%@ Register Src="mod_filtro.ascx" TagName="mod_filtro" TagPrefix="uc2" %> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - <%--  - --%> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/WebSites/WebGIM/mod_macchine.ascx.cs b/WebSites/WebGIM/mod_macchine.ascx.cs deleted file mode 100644 index 9798182..0000000 --- a/WebSites/WebGIM/mod_macchine.ascx.cs +++ /dev/null @@ -1,584 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; -using System.Data; - -public partial class mod_macchine : ApplicationUserControl -{ - #region area da NON modificare - - #region area protected - - protected string _idxGridView; - protected string _idxGridViewExt; - protected bool _showNewBtn = false; - - /// - /// imposta errore non cancellabilità per record correlati - /// - protected void setNoDeletableErrorMessage() - { - // mostro avviso di non cancellabilità... - lblWarning.Text = traduci("notDeletable_hasChild"); - lblWarning.Visible = true; - grView.DataBind(); - } - /// - /// esegue cancellazione record - /// - protected void doDelete() - { - // posso cancellare... - lblWarning.Visible = false; - ods.Delete(); - } - /// - /// Valida la cancellazione per i dati mostrati dal gridView - /// richiede sia preventivamentedichiarato _idxGridView - /// - /// - /// - protected virtual void validaDelete(object sender, ObjectDataSourceMethodEventArgs e) - { - int idx = Convert.ToInt32(e.InputParameters[string.Format("Original_{0}", _idxGridView)]); - if (objIsNotRelated(idx)) - { - // annullo cancellazione... - e.Cancel = true; - // seleziono record... metto in session valore idx e poi ridisegno... - SteamWare.memLayer.ML.setSessionVal(_idxGridView, idx); - setNoDeletableErrorMessage(); - } - else - { - doDelete(); - } - } - - /// - /// recupera i dati di un nuovo record contenuti nel footer di un gridView; - /// questi devono esses opportunamente nominati (es: txt{0}, dl{0}, ...) - /// - /// - /// - protected void recuperaFooter(object sender, ObjectDataSourceMethodEventArgs e) - { - //recupero la riga footer... - DataColumnCollection colonne = colonneObj(); - string nomeCol; - string tipoColonna = ""; - foreach (DataColumn colonna in colonne) - { - nomeCol = colonna.ColumnName; - // cerco un textbox o quello che sia... - if (grView.FooterRow.FindControl(string.Format("txt{0}", nomeCol)) != null) - { - tipoColonna = "textBox"; - } - else if (grView.FooterRow.FindControl(string.Format("cal_{0}", nomeCol)) != null) - { - tipoColonna = "calTextBox"; - } - else if (grView.FooterRow.FindControl(string.Format("dl{0}", nomeCol)) != null) - { - tipoColonna = "dropDownList"; - } - else if (grView.FooterRow.FindControl(string.Format("chk{0}", nomeCol)) != null) - { - tipoColonna = "checkBox"; - } - else if (grView.FooterRow.FindControl(string.Format("selAjax_{0}", nomeCol)) != null) - { - tipoColonna = "selAjax"; - } - // in base al tipo salvo negli inputparameters dell'ODS - switch (tipoColonna) - { - case "textBox": - e.InputParameters[nomeCol] = ((TextBox)grView.FooterRow.FindControl(string.Format("txt{0}", nomeCol))).Text; - break; - case "calTextBox": - e.InputParameters[nomeCol] = Convert.ToDateTime(((TextBox)grView.FooterRow.FindControl(string.Format("cal_{0}", nomeCol))).Text); - break; - case "dropDownList": - e.InputParameters[nomeCol] = ((DropDownList)grView.FooterRow.FindControl(string.Format("dl{0}", nomeCol))).SelectedValue; - break; - case "checkBox": - e.InputParameters[nomeCol] = ((CheckBox)grView.FooterRow.FindControl(string.Format("dl{0}", nomeCol))).Checked; - break; - case "selAjax": - e.InputParameters[nomeCol] = ((mod_selettore_ajax)grView.FooterRow.FindControl(string.Format("selAjax_{0}", nomeCol))).valore; - break; - default: - break; - } - tipoColonna = ""; - } - } - /// - /// inserisce nuovo valore da footer - /// - /// - /// - protected void lblIns_click(object sender, EventArgs e) - { - // click su inserimento, chiamo il metodo insert dell'ObjectDataSource - ods.Insert(); - } - /// - /// annulla inserimento nuovo valore da footer - /// - /// - /// - protected void lblCanc_click(object sender, EventArgs e) - { - // annullo inserimento: nascondo footer, bind controlli... - grView.FooterRow.Visible = false; - } - - /// - /// aggiorna controlli datagrid e numero righe in pagina - /// - protected override void aggiornaControlliDataGL() - { - base.aggiornaControlliDataGL(); - grViewShort.PageSize = _righeDataGridAnagr; - grView.PageSize = _righeDataGridMed; - } - /// - /// traduce gli header delle colonne - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - /// - /// traduce gli header delle colonne - /// - /// - /// - protected void grViewShort_DataBound(object sender, EventArgs e) - { - if (grViewShort.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grViewShort.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grViewShort.Rows.Count + grViewShort.PageSize * (grViewShort.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grViewShort.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - - /// - /// gestione evento richeista nuovo valore (mostra footer, ...) - /// - /// - /// - protected void btnNew_Click(object sender, EventArgs e) - { - // reset selezione... - resetSelezione(); - // mostro il footer oppure la riga dei dettagli x nuovo... - if (grView.FooterRow != null) - { - grView.FooterRow.Visible = true; - } - // sollevo evento nuovo valore... - if (eh_nuovoValore != null) - { - eh_nuovoValore(this, new EventArgs()); - } - } - /// - /// reset della selezione - /// - /// - /// - protected void btnReset_Click(object sender, EventArgs e) - { - resetSelezione(); - } - /// - /// reset della selezione - /// - /// - /// - protected void btnResetShort_Click(object sender, EventArgs e) - { - grViewShort.SelectedIndex = -1; - grViewShort.DataBind(); - lblWarning.Visible = false; - } - /// - /// gestione cambio selezione valore - /// - /// - /// - protected void grView_SelectedIndexChanged(object sender, EventArgs e) - { - // salvo in session il valore selezionato... - SteamWare.memLayer.ML.setSessionVal(string.Format("{0}_sel", _idxGridView), grView.SelectedValue); - // sollevo evento nuovo valore... - if (eh_selValore != null) - { - eh_selValore(this, new EventArgs()); - } - } - /// - /// resetta la selezione dei valori in caso di modifiche su altri controlli - /// - public void resetSelezione() - { - SteamWare.memLayer.ML.emptySessionVal(string.Format("{0}_sel", _idxGridView)); - grView.SelectedIndex = -1; - grView.DataBind(); - lblWarning.Visible = false; - if (eh_resetSelezione != null) - { - eh_resetSelezione(this, new EventArgs()); - } - } - - #endregion - - #region gestione eventi - - public event EventHandler eh_resetSelezione; - public event EventHandler eh_nuovoValore; - public event EventHandler eh_selValore; - - #endregion - - #region public - - /// - /// definisce visibilità btnNew - /// - public bool showNewBtn - { - get - { - return _showNewBtn; - } - set - { - _showNewBtn = value; - } - } - - - #endregion - - #endregion - - #region area codice variabile - - /// - /// devo mostrare meno colonne - /// - protected bool _dispLessCol = false; - /// - /// effettua update del modulo - /// - public void doUpdate() - { - resetSelezione(); - updateOdsDaFiltro(); - grView.SelectedIndex = -1; - grView.DataBind(); - grViewShort.SelectedIndex = -1; - grViewShort.DataBind(); - } - - /// - /// verifica complessiva non esistenza record child - /// - /// - /// - protected bool objIsNotRelated(object idxObj) - { - bool answ = false; - try - { - answ = (TA_app.obj.taInterventiMtz.getByIdxMacchina(Convert.ToInt32(idxObj)).Rows.Count == 0); - } - catch - { } - return answ; - } - /// - /// elenco colonne del datagrid - /// - /// - protected DataColumnCollection colonneObj() - { - DS_applicazione.v_macchineDataTable tabella = new DS_applicazione.v_macchineDataTable(); - DataColumnCollection colonne = tabella.Columns; - return colonne; - } - /// - /// inizializzazione valori di default - /// - /// - protected override void OnInit(EventArgs e) - { - base.OnInit(e); - mod_filtroImpianti.eh_selValore += new EventHandler(mod_filtroImpianti_eh_selValore); - if (!Page.IsPostBack) - { - mod_filtroImpianti.ods = odsImpianti; - } - _idxGridView = "idxmacchina"; - // determino quale grView a seconda del tipo visibilità colonne... - if (_dispLessCol) - { - grView.Visible = false; - grViewShort.Visible = true; - } - else - { - grView.Visible = true; - grViewShort.Visible = false; - } - updateOdsDaFiltro(); - } - - /// - /// aggiorna visualizzazioni varie - /// - private void aggiornaAll() - { - // imposto visibilità filtro in base a tipo controllo - if (vistaModulo == tipoVistaMod.selezione) - { - mod_filtroImpianti.Visible = false; - } - else - { - mod_filtroImpianti.Visible = true; - } - } - - void mod_filtroImpianti_eh_selValore(object sender, EventArgs e) - { - if (mod_filtroImpianti.valoreInt != 0) - { - // salvo il valore selezionato... - idxImpiantoSel = mod_filtroImpianti.valoreInt; - } - doUpdate(); - } - /// - /// verifica e sistema il filtro dell'ods... - /// - private void updateOdsDaFiltro() - { - string filterExpr = " (codMacchina LIKE '%{0}%' OR nomeMacchina LIKE '%{0}%' OR modello LIKE '%{0}%' OR matricola LIKE '%{0}%' OR descrImpianto LIKE '%{0}%') "; - if (vistaModulo == tipoVistaMod.selezione || (mod_filtroImpianti.Visible && mod_filtroImpianti.valore != "*")) - { - filterExpr += " AND idxImpianto = {1} "; - } - ods.FilterExpression = filterExpr; - } - /// - /// setta selected alla riga il cui valore key è in session - /// - /// - /// - protected void grView_RowDataBound(object sender, GridViewRowEventArgs e) - { - // se riga di dati... - if (e.Row.RowType == DataControlRowType.DataRow) - { - // ottengo la riga tipizzata... - System.Data.DataRowView _drv = (System.Data.DataRowView)e.Row.DataItem; - DS_applicazione.v_macchineRow riga = (DS_applicazione.v_macchineRow)_drv.Row; - if (SteamWare.memLayer.ML.StringSessionObj(_idxGridView) == riga.idxImpianto.ToString()) - { - grView.SelectedIndex = e.Row.RowIndex; - // salvo in session il valore selezionato... - SteamWare.memLayer.ML.setSessionVal(string.Format("{0}_sel", _idxGridView), SteamWare.memLayer.ML.StringSessionObj(_idxGridView)); - // sollevo evento nuovo valore... - if (eh_selValore != null) - { - eh_selValore(this, new EventArgs()); - } - } - } - } - /// - /// svuoto da cache post update - /// - /// - /// - protected void ods_Updated(object sender, ObjectDataSourceStatusEventArgs e) - { - // svuoto da cache... - } - /// - /// gestione evento inserimento nuovo record standard (se ZERO presenti) - /// - /// - /// - protected void btnNewFromEmpty_Click(object sender, EventArgs e) - { - // reset selezione... - resetSelezione(); - // i primi valori ("0") di default sono "ND"... li inserisco come standard... - string codMacc = memLayer.ML.confReadString("defaultCodMacc"); - TA_app.obj.taMacchine.Insert(1, codMacc, "-- [NUOVA] Nome Macchina non definito --", "modello n.d.", "", DateTime.Now.Year, 0, 0, DateTime.Today, DateTime.Today.AddYears(10)); - grView.DataBind(); - } - /// - /// salvo in session che il prox comando è clonare... - /// - /// - /// - protected void imgClona_Click(object sender, ImageClickEventArgs e) - { - SteamWare.memLayer.ML.setSessionVal("nextObjCommand", "clonaObj"); - } - /// - /// in caso di aggiornamento verifico se sia salvato un comando clona... - /// - /// - /// - protected void grView_RowUpdating(object sender, GridViewUpdateEventArgs e) - { - // carico l'idx dell'oggetto - int _idx = Convert.ToInt32(e.Keys["idxMacchina"]); - string _comando = ""; - if (SteamWare.memLayer.ML.isInSessionObject("nextObjCommand")) - { - _comando = SteamWare.memLayer.ML.StringSessionObj("nextObjCommand"); - SteamWare.memLayer.ML.emptySessionVal("nextObjCommand"); - } - // verifico il tipo di richiesta (up/down level, clona o update normale - switch (_comando) - { - case "clonaObj": - TA_app.obj.taMacchine.sp_clonaMacchina(_idx); - grView.EditIndex = -1; - grView.DataBind(); - // blocco update! - e.Cancel = true; - break; - default: - // faccio update! - break; - } - } - /// - /// determina se sia abilitata la cancellazione della macchina - /// - public bool isDelEnabled(object cosa, object idx) - { - bool answ = false; - // controllo se ci siano record correlati... - if (objIsNotRelated(idx)) - { - answ = isVisible(cosa); - } - else - { - answ = false; - } - return answ; - } - /// - /// indica il valore dell'impianto filtrato in visualizzazione - /// - public int idxImpiantoSel - { - get - { - return Convert.ToInt32(lblImpianto.Text); - } - set - { - lblImpianto.Text = value.ToString(); - aggiornaAll(); - } - } - - /// - /// definisce se mostrare meno colonne (per funzione MOVE delle macchine tra diversi impianti) - /// - public bool dispLessCol - { - get - { - return _dispLessCol; - } - set - { - _dispLessCol = value; - } - } - /// - /// definisce se mostrare o meno una colonna... - /// - public bool mostraColonna - { - get - { - return !_dispLessCol; - } - } - /// - /// restituisce idx della macchina selezionata nel grVIew versione "short" - /// - public int idxMacchinaSel - { - get - { - int answ = -1; - try - { - answ = Convert.ToInt32(grViewShort.SelectedValue); - } - catch - { } - return answ; - } - } - #endregion -} \ No newline at end of file diff --git a/WebSites/WebGIM/mod_main_help.ascx b/WebSites/WebGIM/mod_main_help.ascx deleted file mode 100644 index 199b0f0..0000000 --- a/WebSites/WebGIM/mod_main_help.ascx +++ /dev/null @@ -1,15 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_main_help.ascx.cs" Inherits="mod_main_help" %> - - - - - - - - - - -
-
-
-
diff --git a/WebSites/WebGIM/mod_main_help.ascx.cs b/WebSites/WebGIM/mod_main_help.ascx.cs deleted file mode 100644 index fba38b1..0000000 --- a/WebSites/WebGIM/mod_main_help.ascx.cs +++ /dev/null @@ -1,52 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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 SteamWare; - -public partial class mod_main_help : ApplicationUserControl -{ - - #region inizializzazione generica & utility - - protected string defaultApp; - protected string defaultTitle; - protected string defaultBody; - - protected override void traduciObj() - { - defaultApp = SteamWare.memLayer.ML.confReadString("defaultApp"); - defaultTitle = SteamWare.memLayer.ML.confReadString("defaultTitle"); - defaultBody = SteamWare.memLayer.ML.confReadString("defaultBody"); - lblAppl.Text = user_std.UtSn.Traduci(defaultApp); - lblTitle.Text = user_std.UtSn.Traduci(defaultTitle); - lblMess.Text = user_std.UtSn.Traduci(defaultBody); - } - - #endregion - - #region public - - /// - /// imposta app, title e body del generico messaggio mostrato dal modulo - /// NB: vanno passate le stringhe da tradurre!!! - /// - /// - /// - /// - public void setupMessaggio(string app2transl, string titolo2transl, string body2transl) - { - defaultApp = app2transl; - defaultTitle = titolo2transl; - defaultBody = body2transl; - } - - #endregion - -} diff --git a/WebSites/WebGIM/mod_menuBottom.ascx b/WebSites/WebGIM/mod_menuBottom.ascx deleted file mode 100644 index 5447596..0000000 --- a/WebSites/WebGIM/mod_menuBottom.ascx +++ /dev/null @@ -1,4 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_menuBottom.ascx.cs" - Inherits="mod_menuBottom" %> -142 - - diff --git a/WebSites/WebGIM/mod_menuBottom.ascx.cs b/WebSites/WebGIM/mod_menuBottom.ascx.cs deleted file mode 100644 index eb750d5..0000000 --- a/WebSites/WebGIM/mod_menuBottom.ascx.cs +++ /dev/null @@ -1,20 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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; - -public partial class mod_menuBottom : System.Web.UI.UserControl -{ - protected void Page_Load(object sender, EventArgs e) - { - // sistemo le stringhe... - lblApp.Text = string.Format("{0} v.{1}.", ConfigurationManager.AppSettings.Get("appName"), ConfigurationManager.AppSettings.Get("mainRev")); - lblCopyRight.Text = string.Format("{0}",ConfigurationManager.AppSettings.Get("copyRight")); - } -} diff --git a/WebSites/WebGIM/mod_menuBottom.ascx.in b/WebSites/WebGIM/mod_menuBottom.ascx.in deleted file mode 100644 index e7e897c..0000000 --- a/WebSites/WebGIM/mod_menuBottom.ascx.in +++ /dev/null @@ -1,4 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_menuBottom.ascx.cs" - Inherits="mod_menuBottom" %> -$WCREV$ - - diff --git a/WebSites/WebGIM/mod_menuBottomPortable.ascx b/WebSites/WebGIM/mod_menuBottomPortable.ascx deleted file mode 100644 index 67b2b27..0000000 --- a/WebSites/WebGIM/mod_menuBottomPortable.ascx +++ /dev/null @@ -1,4 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_menuBottomPortable.ascx.cs" Inherits="mod_menuBottomMini" %> -
- - diff --git a/WebSites/WebGIM/mod_menuBottomPortable.ascx.cs b/WebSites/WebGIM/mod_menuBottomPortable.ascx.cs deleted file mode 100644 index c15d581..0000000 --- a/WebSites/WebGIM/mod_menuBottomPortable.ascx.cs +++ /dev/null @@ -1,18 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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; - -public partial class mod_menuBottomMini : System.Web.UI.UserControl -{ - protected void Page_Load(object sender, EventArgs e) - { - lblCopyRight.Text = string.Format("{0}", ConfigurationManager.AppSettings.Get("copyRight")); - } -} diff --git a/WebSites/WebGIM/mod_menuSx.ascx b/WebSites/WebGIM/mod_menuSx.ascx deleted file mode 100644 index e1febef..0000000 --- a/WebSites/WebGIM/mod_menuSx.ascx +++ /dev/null @@ -1,16 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_menuSx.ascx.cs" Inherits="mod_menuSx" %> - - - - - - - - - - - - - \ No newline at end of file diff --git a/WebSites/WebGIM/mod_menuSx.ascx.cs b/WebSites/WebGIM/mod_menuSx.ascx.cs deleted file mode 100644 index f439628..0000000 --- a/WebSites/WebGIM/mod_menuSx.ascx.cs +++ /dev/null @@ -1,43 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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 SteamWare; - -public partial class mod_menuSx : ApplicationUserControl -{ - - protected override void aggiornaControlliDataGL() - { - // se l'utente c'è... - if (user_std.UtSn.isAuth && !Page.IsPostBack) - { - updateTreeMenu(); - } - } - /// - /// aggiornamento del menù - /// - private void updateTreeMenu() - { - XmlDataSource1.Data = user_std.UtSn.mappaSito; - //user_std.UtSn.ricaricaMappaSito(); - //XmlDataSource1.Data = user_std.UtSn.mappaSitoLive; - XmlDataSource1.XPath = "mainMenu/menu"; - XmlDataSource1.DataBind(); - } - /// - /// forza l'update del menù sx - /// - public void forzaUpdateMenu() - { - user_std.UtSn.ricaricaMappaSito(); - updateTreeMenu(); - } -} diff --git a/WebSites/WebGIM/mod_menuTop.ascx b/WebSites/WebGIM/mod_menuTop.ascx deleted file mode 100644 index ff1a960..0000000 --- a/WebSites/WebGIM/mod_menuTop.ascx +++ /dev/null @@ -1,35 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_menuTop.ascx.cs" Inherits="mod_menuTop" %> - - - - - - -
- - - - - - - - - - - -
- - - - - - -
- Show/Hide Menu - - - - -
-
diff --git a/WebSites/WebGIM/mod_menuTop.ascx.cs b/WebSites/WebGIM/mod_menuTop.ascx.cs deleted file mode 100644 index 12d65c3..0000000 --- a/WebSites/WebGIM/mod_menuTop.ascx.cs +++ /dev/null @@ -1,151 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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.Generic; -using SteamWare; - -public partial class mod_menuTop : ApplicationUserControl -{ - private string _titleString; - - #region gestione eventi - - public event EventHandler eh_toggleMenuSx; - public event EventHandler eh_reqUpdateMenu; - - #endregion - - protected override void Page_Load(object sender, EventArgs e) - { - base.Page_Load(sender, e); - btnLogOut.Visible = user_std.UtSn.isForcedUser; - if(memLayer.ML.isInSessionObject("doUpdateNow")) - { - doFullDataUpdate(); - memLayer.ML.emptySessionVal("doUpdateNow"); - } - } - - protected void btnLogOut_Click(object sender, EventArgs e) - { - Session.Abandon(); - Response.Redirect("forceUser.aspx"); - } - protected void btnUpdate_Click(object sender, EventArgs e) - { - doFullDataUpdate(); - } - - private void doFullDataUpdate() - { - // salvo i dati attuali... - string cod_cdc = SteamWare.memLayer.ML.StringSessionObj("valRicercaCdC"); - string lingua = user_std.UtSn.lingua; - string USER_NAME = SteamWare.memLayer.ML.StringSessionObj("USER_NAME"); - string DOMINIO = SteamWare.memLayer.ML.StringSessionObj("DOMINIO"); - bool isForceUser = user_std.UtSn.isForcedUser; - // salvo i valori delle tab in session... - Dictionary sessionParam = SteamWare.memLayer.ML.valSess2SurvUpd; - - // svuoto session e cache per rileggere i dati da Db - Session.RemoveAll(); - - SteamWare.memLayer.ML.flushRegisteredCache(); - - // rimemorizzo - SteamWare.memLayer.ML.setSessionVal("valRicercaCdC", cod_cdc); - user_std.UtSn.startUpUtente(DOMINIO, USER_NAME); - user_std.UtSn.lingua = lingua; - user_std.UtSn.isForcedUser = isForceUser; - DataWrap.DW.resetVocabolario(); - - // risalvo in session i valori... - foreach (KeyValuePair kvp in sessionParam) - { - SteamWare.memLayer.ML.setSessionVal(kvp.Key, kvp.Value, true); - } - - // cambio visibilità del menù laterale... - if (eh_reqUpdateMenu != null) - { - eh_reqUpdateMenu(this, new EventArgs()); - } - - Response.Redirect(_paginaCorrente); - } - - protected override void loadSessionData() - { - base.loadSessionData(); - _titleString = SteamWare.memLayer.ML.StringSessionObj("_titleString"); - } - - protected override void bindControlli() - { - if (!Page.IsPostBack) - { - // solo se user è auth... - if (user_std.UtSn.isAuth) - { - lblTitle.Text = user_std.UtSn.Traduci(SteamWare.memLayer.ML.confReadString("titleApp")); - if (_titleString != "") - { - // traduzione di tutti i termini - lblMessUtente.Text = user_std.UtSn.Traduci(_titleString); - //doppio in english! - lblMessUtenteEn.Text = "(" + user_std.UtSn.TraduciEn(_titleString) + ")"; - _titleString = ""; - Session["_titleString"] = _titleString; - Session["SessionUpdateMenu"] = true; - } - else - { - lblMessUtente.Text = user_std.UtSn.Traduci(SteamWare.memLayer.ML.confReadString("welcomeApp")); - lblMessUtenteEn.Text = ""; - Session["SessionUpdateMenu"] = false; - } - btnLogOut.Text = user_std.UtSn.Traduci("LogOut"); - btnUpdate.Text = user_std.UtSn.Traduci("Update"); - lblUser.Text = String.Format("{0}: {1}", user_std.UtSn.Traduci("User"), user_std.UtSn.CognomeNome); - setTimer(); - setClock(); - } - } - } - /// - /// imposta il tempo di scadenza del timer x il refresh della pagina (della parte top) per evitare che la sessione sul server scada - /// - private void setTimer() - { - Timer1.Interval = SteamWare.memLayer.ML.confReadInt("intUpdatePagina_ms"); - } - protected void lnkShowHide_Click(object sender, EventArgs e) - { - // cambio visibilità del menù laterale... - if (eh_toggleMenuSx != null) - { - eh_toggleMenuSx(this, new EventArgs()); - } - - } - protected void Timer1_Tick(object sender, EventArgs e) - { - setClock(); - } - - private void setClock() - { - lblDateTime.Text = DateTime.Now.ToString("HH:mm:ss"); - } - protected void lblUser_Click(object sender, EventArgs e) - { - Response.Redirect("./chLang.aspx"); - } -} diff --git a/WebSites/WebGIM/mod_mtzPrevPending.ascx b/WebSites/WebGIM/mod_mtzPrevPending.ascx deleted file mode 100644 index c2a9caf..0000000 --- a/WebSites/WebGIM/mod_mtzPrevPending.ascx +++ /dev/null @@ -1,41 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_mtzPrevPending.ascx.cs" - Inherits="mod_mtzPrevPending" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> -
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
diff --git a/WebSites/WebGIM/mod_mtzPrevPending.ascx.cs b/WebSites/WebGIM/mod_mtzPrevPending.ascx.cs deleted file mode 100644 index c484223..0000000 --- a/WebSites/WebGIM/mod_mtzPrevPending.ascx.cs +++ /dev/null @@ -1,59 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_mtzPrevPending : ApplicationUserControl -{ - public event EventHandler eh_resetSelezione; - /// - /// evento dati associati a controllo - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - protected override void Page_Load(object sender, EventArgs e) - { - base.Page_Load(sender, e); - if (!Page.IsPostBack) - { - hlExportExcel.Text = traduci("hlExportExcel"); - hlExportExcel.NavigateUrl = "./ExcelExportMtzPrevPending.aspx"; - // vedo di rigenerare la coda... - // verifico se devo generare degli interventi di MTZ programmata.. - try - { - mtzProgr.obj.processaCodaMtzPro(); - } - catch (Exception errore) - { - SteamWare.logger.lg.scriviLog(string.Format("Non sono riuscito ad accodare gli interventi di mtz preventiva pending, errore:\r\n {0}", errore), SteamWare.tipoLog.EXCEPTION); - } - } - } -} \ No newline at end of file diff --git a/WebSites/WebGIM/mod_pageTitleAndSearch.ascx b/WebSites/WebGIM/mod_pageTitleAndSearch.ascx deleted file mode 100644 index bbe2ac9..0000000 --- a/WebSites/WebGIM/mod_pageTitleAndSearch.ascx +++ /dev/null @@ -1,25 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_pageTitleAndSearch.ascx.cs" - Inherits="mod_pageTitleAndSearch" %> -
- - - - - - -
- - -   - - - -
-
-
- -
-
-
-
-
diff --git a/WebSites/WebGIM/mod_pageTitleAndSearch.ascx.cs b/WebSites/WebGIM/mod_pageTitleAndSearch.ascx.cs deleted file mode 100644 index 4d66a9b..0000000 --- a/WebSites/WebGIM/mod_pageTitleAndSearch.ascx.cs +++ /dev/null @@ -1,28 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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 SteamWare; - -public partial class mod_pageTitleAndSearch : ApplicationUserControl -{ - #region area protected - - protected string _titolo; - protected override void traduciObj() - { - DataLayer_AnagGen.PermessiRow riga = (DataLayer_AnagGen.PermessiRow)user_std.UtSn.permessi.Select(string.Format("URL = '{0}'", _paginaCorrente))[0]; - _titolo = riga.NOME; - lblTitolo.Text = traduci(_titolo); - } - - - #endregion - -} diff --git a/WebSites/WebGIM/mod_periodoAnalisi.ascx b/WebSites/WebGIM/mod_periodoAnalisi.ascx deleted file mode 100644 index 61c2b75..0000000 --- a/WebSites/WebGIM/mod_periodoAnalisi.ascx +++ /dev/null @@ -1,35 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_periodoAnalisi.ascx.cs" - Inherits="mod_periodoAnalisi" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> -
-
- -
-
- - - - -
-
- - - - -
-
- - - - - - - -
-
diff --git a/WebSites/WebGIM/mod_periodoAnalisi.ascx.cs b/WebSites/WebGIM/mod_periodoAnalisi.ascx.cs deleted file mode 100644 index 6be7b2d..0000000 --- a/WebSites/WebGIM/mod_periodoAnalisi.ascx.cs +++ /dev/null @@ -1,205 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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 SteamWare; - -public partial class mod_periodoAnalisi : System.Web.UI.UserControl -{ - #region area protected - - protected intervalloDate _intervallo; - - protected override void OnInit(EventArgs e) - { - base.OnInit(e); - setIntervallo(); - } - - /// - /// gestione del selettore rapido dell'intervallo temporale... - /// - /// - /// - protected void DropDownList1_SelectedIndexChanged(object sender, EventArgs e) - { - intervalloDate _intervallo = new intervalloDate(); - // verifico cosa sia cambiato ed imposto date... - datario _datario = new datario(); - switch (DropDownList1.SelectedValue) - { - case "1_today": - _intervallo = _datario.giornata(DateTime.Now); - break; - case "2_yesterday": - _intervallo = _datario.giornata(DateTime.Now.AddDays(-1)); - break; - case "3_last_7": - _intervallo = _datario.ultimiGiorni(DateTime.Now, 7); - break; - case "4_this_week": - _intervallo = _datario.questaSett(DateTime.Now); - break; - case "5_last_30": - _intervallo = _datario.ultimiGiorni(DateTime.Now, 30); - break; - case "6_this_month": - _intervallo = _datario.questoMese(DateTime.Now); - break; - case "7_last_month": - _intervallo = _datario.estremiMese(DateTime.Now.AddMonths(-1)); - break; - case "8_this_year": - _intervallo = _datario.estremiAnno(DateTime.Now); - break; - case "9_last_year": - _intervallo = _datario.estremiAnno(DateTime.Now.AddYears(-1)); - break; - default: - break; - } - intervalloAnalisi = _intervallo; - aggiornaDateMostrate(); - } - - private void aggiornaDateMostrate() - { - txtInizio.Text = intervalloAnalisi.inizio.ToShortDateString(); - txtFine.Text = intervalloAnalisi.fine.AddDays(-1).ToShortDateString(); // mostro 1 gg in meno xché termina alle 00:00... - reportUpdate(); - } - - private void setIntervallo() - { - intervalloDate _intervallo; - try - { - _intervallo = (intervalloDate)Session["_intervallo"]; - } - catch - { - _intervallo = new intervalloDate(); - _intervallo.fine = DateTime.Now.Subtract(DateTime.Now.TimeOfDay).AddDays(1); - _intervallo.inizio = _intervallo.fine.AddMonths(-1); - Session["_intervallo"] = _intervallo; - Session["_inizio"] = _intervallo.inizio; - Session["_fine"] = _intervallo.fine; - } - txtInizio.Text = _intervallo.inizio.ToShortDateString(); - txtFine.Text = _intervallo.fine.ToShortDateString(); - } - /// - /// wrapper traduzione - /// - /// - /// - public string traduci(object lemma) - { - return user_std.UtSn.Traduci(lemma.ToString()); - } - protected void Page_Load(object sender, EventArgs e) - { - if (!Page.IsPostBack) - { - lblPeriodo.Text = traduci("periodoRif"); - txtInizio.ToolTip = traduci("inizioPeriodo"); - txtFine.ToolTip = traduci("finePeriodo"); - } - } - protected void txtInizio_TextChanged(object sender, EventArgs e) - { - // imposto il selettore a discesa... - DropDownList1.SelectedIndex = 0; - // se campo vuoto imposto oggi... - if (txtInizio.Text == "") - { - txtInizio.Text = DateTime.Now.ToShortDateString(); - } - else - { - txtInizio.Text = Convert.ToDateTime(txtInizio.Text).ToShortDateString(); - } - // aggiorno dati in session... - aggiornaPeriodo(); - } - - private void aggiornaPeriodo() - { - _intervallo = new intervalloDate(); - _intervallo.inizio = Convert.ToDateTime(txtInizio.Text); - _intervallo.fine = ((DateTime)Convert.ToDateTime(txtFine.Text)).Date.AddDays(1); - //_intervallo.fine = ((DateTime)Convert.ToDateTime(txtFine.Text)).Date.AddDays(1).AddMinutes(-1); - intervalloAnalisi = _intervallo; - reportUpdate(); - - } - protected void txtFine_TextChanged(object sender, EventArgs e) - { - // imposto il selettore a discesa... - DropDownList1.SelectedIndex = 0; - // se campo vuoto imposto oggi... - if (txtFine.Text == "") - { - txtFine.Text = DateTime.Now.AddDays(1).ToShortDateString(); - } - else - { - txtFine.Text = Convert.ToDateTime(txtFine.Text).ToShortDateString(); - } - // aggiorno dati in session... - aggiornaPeriodo(); - } - - protected void reportUpdate() - { - // alzo l'evento d update/inserimento e ricarico cache... - if (eh_doUpdate != null) - { - eh_doUpdate(this, new EventArgs()); - } - } - - #endregion - - #region area public - - public intervalloDate intervalloAnalisi - { - get - { - return (intervalloDate)Session["_intervallo"]; - } - set - { - intervalloDate interv = value; - Session["_intervallo"] = interv; - Session["_inizio"] = interv.inizio; - Session["_fine"] = interv.fine; - } - } - - public void doUpdate() - { - aggiornaDateMostrate(); - } - - public void setPeriodoFree() - { - DropDownList1.SelectedIndex = 0; - } - - #region gestione eventi - - public event EventHandler eh_doUpdate; - - #endregion - - #endregion - -} diff --git a/WebSites/WebGIM/mod_priorita.ascx b/WebSites/WebGIM/mod_priorita.ascx deleted file mode 100644 index 2167a92..0000000 --- a/WebSites/WebGIM/mod_priorita.ascx +++ /dev/null @@ -1,104 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_priorita.ascx.cs" - Inherits="mod_priorita" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/WebSites/WebGIM/mod_priorita.ascx.cs b/WebSites/WebGIM/mod_priorita.ascx.cs deleted file mode 100644 index e5df86a..0000000 --- a/WebSites/WebGIM/mod_priorita.ascx.cs +++ /dev/null @@ -1,95 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_priorita : ApplicationUserControl -{ - public event EventHandler eh_resetSelezione; - /// - /// evento dati associati a controllo - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - /// - /// reset delle selezioni - /// - /// - /// - protected void btnReset_Click(object sender, EventArgs e) - { - resetSelezione(); - } - /// - /// resetta la selezione dei valori in caso di modifiche su altri controlli - /// - public void resetSelezione() - { - grView.SelectedIndex = -1; - grView.DataBind(); - if (eh_resetSelezione != null) - { - eh_resetSelezione(this, new EventArgs()); - } - } - /// - /// seleziono valore in editing... - /// - /// - /// - protected void grView_RowEditing(object sender, GridViewEditEventArgs e) - { - // seleziono la riga corrente... - grView.SelectedIndex = e.NewEditIndex; - } - /// - /// gestione evento inserimento nuovo record standard (se ZERO presenti) - /// - /// - /// - protected void btnNewFromEmpty_Click(object sender, EventArgs e) - { - // reset selezione... - resetSelezione(); - // i primi valori ("0") di default sono "ND"... li inserisco come standard... - DS_applicazioneTableAdapters.AnagPrioritaTableAdapter taPrior = new DS_applicazioneTableAdapters.AnagPrioritaTableAdapter(); - // calcolo ultimo libero e aggiungo 1... - int nextFree = 1; - try - { - nextFree = (int)taPrior.getMaxPriorita() + 1; - } - catch - { - logger.lg.scriviLog("Errore nel recupero del max idx di prorità", tipoLog.EXCEPTION); - } - taPrior.Insert(nextFree, "-- [NUOVA] non definita --", "semaforoVerde"); - grView.DataBind(); - } -} \ No newline at end of file diff --git a/WebSites/WebGIM/mod_reportInterventi.ascx b/WebSites/WebGIM/mod_reportInterventi.ascx deleted file mode 100644 index 6b04028..0000000 --- a/WebSites/WebGIM/mod_reportInterventi.ascx +++ /dev/null @@ -1,101 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_reportInterventi.ascx.cs" - Inherits="mod_reportInterventi" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> -<%@ Register Src="mod_periodoAnalisi.ascx" TagName="mod_periodoAnalisi" TagPrefix="uc1" %> -
-
-
-
- -
-
-
-
- -
-
- -
-
- - - - - - -
-
-
-
- -
-
- -
-
- - - - - - -
-
-
-
-
- - - - -
-
-
-
- - - - - - - - - -
-

- -

- -
- -

- -

- -
-
- -
-
-
-
-
diff --git a/WebSites/WebGIM/mod_reportInterventi.ascx.cs b/WebSites/WebGIM/mod_reportInterventi.ascx.cs deleted file mode 100644 index 01b9b6d..0000000 --- a/WebSites/WebGIM/mod_reportInterventi.ascx.cs +++ /dev/null @@ -1,191 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_reportInterventi : System.Web.UI.UserControl -{ - protected void Page_Load(object sender, EventArgs e) - { - if (!Page.IsPostBack) - { - // traduzioni - traduciObj(); - // popolo valori default - setDefaultValues(); - // aggancio evento selezione x aggiornare hyperlink - } - } - - protected override void OnInit(EventArgs e) - { - base.OnInit(e); - mod_periodoAnalisi1.eh_doUpdate += new EventHandler(mod_periodoAnalisi1_eh_doUpdate); - } - - void mod_periodoAnalisi1_eh_doUpdate(object sender, EventArgs e) - { - setDefaultValues(); - } - /// - /// wrapper traduzione - /// - /// - /// - public string traduci(object lemma) - { - return user_std.UtSn.Traduci(lemma.ToString()); - } - private void traduciObj() - { - lblMostraStati.Text = traduci("lblMostraStati"); - lblImpiantiInteressati.Text = traduci("lblImpiantiSel"); - lblMacchineInteressate.Text = traduci("lblMacchineSel"); - lnkGuidaPerReport.Text = traduci("lnkGuidaPerReport"); - lblReportInterventi.Text = traduci("lblReportInterventi"); - lblReportMTBFMTTR.Text = traduci("lblReportMTBFMTTR"); - } - private void setDefaultValues() - { - // valori degli hyperlink - hlElencoInterventi_Pdf.NavigateUrl = formattaUrl(reportRichiesto.ElencoInterventi, mod_periodoAnalisi1.intervalloAnalisi); - hlMTBF_MTTR_Pdf.NavigateUrl = formattaUrl(reportRichiesto.MTBF_MTTR, mod_periodoAnalisi1.intervalloAnalisi); - } - private string formattaUrl(reportRichiesto tipo, intervalloDate periodo) - { - return String.Format("~/ExportPdf.aspx?tipo={0}&inizio={1}&fine={2}&username={3}", Convert.ToInt32(tipo), periodo.inizio, periodo.fine, user_std.UtSn.userNameAD); - } - - #region gestione selettori valori multipli - - #region stati - - /// - /// valorizzazione iniziale filtro stati - /// - /// - /// - protected void listaStati_DataBound(object sender, EventArgs e) - { - foreach (ListItem item in ((ListBox)sender).Items) - { - item.Selected = true; - } - generaFiltroStati(); - } - /// - /// salva elenco stati selected - /// - /// - /// - protected void listaStati_SelectedIndexChanged(object sender, EventArgs e) - { - generaFiltroStati(); - } - - private void generaFiltroStati() - { - // svuoto elenco utente delle macchine selezionate - TA_app.obj.taFiltSta.EmptyUserData(user_std.UtSn.userNameAD); - // spazzo TUTTE le righe del controllo... - foreach (ListItem riga in listaStati.Items) - { - // se è selezionata creo riga anche x lei... - if (riga.Selected) - { - TA_app.obj.taFiltSta.Insert(user_std.UtSn.userNameAD, Convert.ToInt32(riga.Value)); - } - } - } - - #endregion - - #region impianti - - /// - /// valorizzazione iniziale filtro impianti - /// - /// - /// - protected void listImpianti_DataBound(object sender, EventArgs e) - { - foreach (ListItem item in ((ListBox)sender).Items) - { - item.Selected = true; - } - generaFiltroImpianti(); - } - /// - /// salvo elenco impianti selected - /// - /// - /// - protected void listImpianti_SelectedIndexChanged(object sender, EventArgs e) - { - generaFiltroImpianti(); - } - - private void generaFiltroImpianti() - { - // svuoto elenco utente delle macchine selezionate - TA_app.obj.taFiltImp.EmptyUserData(user_std.UtSn.userNameAD); - // spazzo TUTTE le righe del controllo... - foreach (ListItem riga in listImpianti.Items) - { - // se è selezionata creo riga anche x lei... - if (riga.Selected) - { - TA_app.obj.taFiltImp.Insert(user_std.UtSn.userNameAD, Convert.ToInt32(riga.Value)); - } - } - } - - #endregion - - #region macchine - - /// - /// valorizzazione iniziale filtro macchine - /// - /// - /// - protected void listMacchine_DataBound(object sender, EventArgs e) - { - foreach (ListItem item in ((ListBox)sender).Items) - { - item.Selected = true; - } - generaFiltroMacchine(); - } - /// - /// salvo elenco macchine selected - /// - /// - /// - protected void listMacchine_SelectedIndexChanged(object sender, EventArgs e) - { - generaFiltroMacchine(); - } - - private void generaFiltroMacchine() - { - // svuoto elenco utente delle macchine selezionate - TA_app.obj.taFiltMac.EmptyUserData(user_std.UtSn.userNameAD); - // spazzo TUTTE le righe del controllo... - foreach (ListItem riga in listMacchine.Items) - { - // se è selezionata creo riga anche x lei... - if (riga.Selected) - { - TA_app.obj.taFiltMac.Insert(user_std.UtSn.userNameAD, Convert.ToInt32(riga.Value)); - } - } - } - #endregion - - #endregion - - -} diff --git a/WebSites/WebGIM/mod_ricercaGenerica.ascx b/WebSites/WebGIM/mod_ricercaGenerica.ascx deleted file mode 100644 index 2f355b1..0000000 --- a/WebSites/WebGIM/mod_ricercaGenerica.ascx +++ /dev/null @@ -1,6 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_ricercaGenerica.ascx.cs" - Inherits="mod_ricercaGenerica" %> -
- - -
diff --git a/WebSites/WebGIM/mod_ricercaGenerica.ascx.cs b/WebSites/WebGIM/mod_ricercaGenerica.ascx.cs deleted file mode 100644 index 8362fd4..0000000 --- a/WebSites/WebGIM/mod_ricercaGenerica.ascx.cs +++ /dev/null @@ -1,181 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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 SteamWare; - -public partial class mod_ricercaGenerica : ApplicationUserControl -{ - - #region gestione eventi - - public event EventHandler eh_nuovaRicerca; - - #endregion - - # region area protected - - #region area ricerche dettaglio specifiche - - protected bool _cercaMatricole = false; - protected bool _cercaUsername = false; - //protected bool _cercaManufacturer = false; - //protected bool _cercaCategorie = false; - protected bool _cercaModelli = false; - protected bool _cercaMag = false; - - #endregion - - protected override void Page_Load(object sender, EventArgs e) - { - base.Page_Load(sender, e); - updateText(); - } - /// - /// cambiato valore in ricerca - /// - /// - /// - protected void txtCerca_TextChanged(object sender, EventArgs e) - { - salvaCerca(); - } - /// - /// pressione del button di ricerca - /// - /// - /// - protected void btnCerca_Click(object sender, EventArgs e) - { - salvaCerca(); - } - /// - /// testo ricerca trimmato da spazi - /// - protected string testoRicerca - { - get - { - return txtCerca.Text.Trim(); - } - set - { - txtCerca.Text = value; - } - } - - protected void salvaCerca() - { - if (testoRicerca == "") - { - SteamWare.memLayer.ML.emptySessionVal("valoreCercato"); - SteamWare.memLayer.ML.emptySessionVal("listaMatricoleSearch"); - } - else - { - SteamWare.memLayer.ML.setSessionVal("valoreCercato", testoRicerca); - // verifico ricerche accessorie - if (_cercaMatricole) - { - salvaCercaMatricole(); - } - if (_cercaUsername) - { - salvaCercaUsername(); - } - // raise dell'evento - if (eh_nuovaRicerca != null) - { - eh_nuovaRicerca(this, new EventArgs()); - } - } - } - /// - /// ricerca utenti e salva lista matricole x SQL IN - /// - protected void salvaCercaMatricole() - { - // salvo anche l'elenco delle matricole compatibili... - DataLayer_AnagGen.UTENTEDataTable righeUtenti = DataWrap.DW.taUtente.getByRicercaNomeCognome(testoRicerca); - string listaMatricoleSearch = ""; - foreach (DataLayer_AnagGen.UTENTERow riga in righeUtenti) - { - listaMatricoleSearch += string.Format("'{0}', ", riga.MATRICOLA); - } - if (listaMatricoleSearch.Length > 0) - { - listaMatricoleSearch = listaMatricoleSearch.Remove(listaMatricoleSearch.Length - 2); - } - SteamWare.memLayer.ML.setSessionVal("listaMatricoleSearch", listaMatricoleSearch); - } - /// - /// ricerca utenti e salva lista username x SQL IN - /// - protected void salvaCercaUsername() - { - // salvo anche l'elenco delle matricole compatibili... - DataLayer_AnagGen.UTENTEDataTable righeUtenti = DataWrap.DW.taUtente.getByRicercaNomeCognome(testoRicerca); - string listaUsernameSearch = ""; - foreach (DataLayer_AnagGen.UTENTERow riga in righeUtenti) - { - listaUsernameSearch += string.Format("'{0}', ", riga.USER_NAME); - } - if (listaUsernameSearch.Length > 0) - { - listaUsernameSearch = listaUsernameSearch.Remove(listaUsernameSearch.Length - 2); - } - SteamWare.memLayer.ML.setSessionVal("listaUsernameSearch", listaUsernameSearch); - } - - #endregion - - #region area public - - /// - /// aggiorna il testo cercato - /// - public void updateText() - { - if (SteamWare.memLayer.ML.StringSessionObj("valoreCercato") != "" && !Page.IsPostBack) - { - testoRicerca = SteamWare.memLayer.ML.StringSessionObj("valoreCercato"); - } - } - - /// - /// indica se generare da stringa search un elenco delle matricole corrispondenti - /// - public bool cercaMatricole - { - get - { - return _cercaMatricole; - } - set - { - _cercaMatricole = value; - } - } - /// - /// indica se generare da stringa search un elenco di username corrispondenti - /// - public bool cercaUsername - { - get - { - return _cercaUsername; - } - set - { - _cercaUsername = value; - } - } - #endregion - -} diff --git a/WebSites/WebGIM/mod_selettore.ascx b/WebSites/WebGIM/mod_selettore.ascx deleted file mode 100644 index be3d0be..0000000 --- a/WebSites/WebGIM/mod_selettore.ascx +++ /dev/null @@ -1,58 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_selettore.ascx.cs" - Inherits="mod_selettore" %> - - - - - - - -
- - - - -
- -   - -   - -   - -
-
- - - - - - - - - - - - - - - - - - - - - - -    - - - - - -
diff --git a/WebSites/WebGIM/mod_selettore.ascx.cs b/WebSites/WebGIM/mod_selettore.ascx.cs deleted file mode 100644 index 05727bb..0000000 --- a/WebSites/WebGIM/mod_selettore.ascx.cs +++ /dev/null @@ -1,464 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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 SteamWare; - -[ValidationProperty("valore")] -public partial class mod_selettore : ApplicationUserControl -{ - - protected bool _chkVisibile = false; - protected bool _isValueVisible = false; - protected bool _cambioTipo = false; - - protected string _valoreFull; - protected string _val1; - protected string _val2; - #region gestione eventi - - public event EventHandler eh_selDone; - - #endregion - - #region gestione pagina - - protected override void Page_Load(object sender, EventArgs e) - { - base.Page_Load(sender, e); - updateChkOpzione(); - if (!Page.IsPostBack) - { - memLayer.ML.emptySessionVal(searchSessionName); - } - } - - protected override void traduciObj() - { - base.traduciObj(); - lblCerca.Text = traduci("lblCerca"); - btnCerca.Text = traduci("search"); - if (_chkVisibile) - { - updateChkOpzione(); - } - } - - protected override void OnInit(EventArgs e) - { - base.OnInit(e); - if (!Page.IsPostBack) - { - _val1 = ""; - _val2 = ""; - traduciObj(); - } - if (vistaModulo == tipoVistaMod.editing) - { - setSearchValue(); - impostaCampoRicerca(); - } - } - /// - /// imposta il valore della ricerca da quello in session - /// - private void setSearchValue() - { - if (memLayer.ML.isInSessionObject(searchSessionName)) - { - testoRicerca = memLayer.ML.StringSessionObj(searchSessionName); - } - } - /// - /// imposta i campi del filtro ricerca in session - /// - private void impostaCampoRicerca() - { - // imposto il nome del valore session x ricerca a campo univoco... - SessionParameter parametroFiltro = new SessionParameter(); - parametroFiltro.SessionField = searchSessionName; - parametroFiltro.Name = searchSessionName; - parametroFiltro.DefaultValue = "*"; - ods.FilterParameters.Clear(); - ods.FilterParameters.Add(parametroFiltro); - } - /// - /// setta il nome del campo di ricerca - /// - protected string searchSessionName - { - get - { - return string.Format("ricerca_{0}", _tipoSelettore); - } - } - - #endregion - - #region area protected - - protected string _conditio = ""; - protected string testoRicerca - { - get - { - return txtCerca.Text.Trim(); - } - set - { - txtCerca.Text = value; - } - } - - protected selettori _selettori = new selettori(); - /// - /// a seconda del tipo di selettore cambierà l'origine ods - /// - /// - /// - protected void chkOpzione_CheckedChanged(object sender, EventArgs e) - { - fixChkOds(); - } - - protected void setCheck() - { - if (_tipoSelettore == tipoSelettore.utentiAll || _tipoSelettore == tipoSelettore.utentiCdc) - { - _chkVisibile = true; - } - else - { - _chkVisibile = false; - } - } - - /// - /// aggiorna visualizzazione del check opzionale con label e visibilità - /// - protected void updateChkOpzione() - { - // se definito il tipo decido SE mostrare il check e tradurre la label... - if (_tipoSelettore == tipoSelettore.utentiAll || _tipoSelettore == tipoSelettore.utentiCdc) - { - chkOpzione.Visible = true; - chkOpzione.Text = traduci("chkSoloGer"); - if (_tipoSelettore == tipoSelettore.utentiCdc) - { - chkOpzione.Checked = true; - } - } - else - { - chkOpzione.Visible = false; - } - } - - - /// - /// aggiorna label e valore principale da una chiave multipart - /// - private void aggiornaDaValMulti() - { - // eseguo SE E SOLO SE entrambi i valori sono popolati - if (val1 != "" && val1 != null) - { - if (val2 != "" && val2 != null && val2 != "na") - { - _valoreFull = string.Format("{0}#{1}", val1, val2); - } - else - { - _valoreFull = val1; - } - } - } - - - /// - /// tipo di valori mostrati - /// - protected tipoSelettore _tipoSelettore = tipoSelettore.cdc; - /// - /// nome del controllo gestito dal nostro popup - /// - protected string _targetControl = ""; - /// - /// sistemo gli ods - /// - protected override void bindControlli() - { - base.bindControlli(); - fixChkOds(); - fixOds(); - } - /// - /// sistema l'ods dato lo stato del chk - /// - protected void fixChkOds() - { - if (_tipoSelettore == tipoSelettore.utentiAll || _tipoSelettore == tipoSelettore.utentiCdc) - { - // verifico se sia o meno checked "solo cdc utente"... - if (chkOpzione.Checked) - { - //imposto nuovo tipo selettore - _tipoSelettore = tipoSelettore.utentiCdc; - fixOds(); - } - else - { - //imposto nuovo tipo selettore - _tipoSelettore = tipoSelettore.utentiAll; - fixOds(); - } - // faccio databind... - grView.PageIndex = 0; - grView.DataBind(); - } - } - /// - /// sistemazione fonte ods... - /// - protected void fixOds() - { - string _selectMethod = ""; - switch (_tipoSelettore) - { - case tipoSelettore.cdc: - _selectMethod = "getSelAllCdC"; - break; - case tipoSelettore.impianti: - _selectMethod = "getSelImpianti"; - break; - case tipoSelettore.macchine: - _selectMethod = "getSelMacchine"; - break; - case tipoSelettore.utentiAll: - _selectMethod = "getSelAllUsers"; - break; - case tipoSelettore.utentiCdc: - _selectMethod = "getSelUsersGer"; - break; - } - ods.SelectMethod = _selectMethod; - } - - /// - /// traduce gli header delle colonne - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - /// - /// selezione annullata su cambio pagina - /// - /// - /// - protected void grView_PageIndexChanged(object sender, EventArgs e) - { - grView.SelectedIndex = -1; - } - /// - /// aggiornamento filtro da stringa di ricerca del popup - /// - /// - /// - protected void txtCerca_TextChanged(object sender, EventArgs e) - { - // se cambio filtro tolgo il selected... - grView.SelectedIndex = -1; - // salvo la ricerca in session e filter dell'ods... - memLayer.ML.setSessionVal(searchSessionName, txtCerca.Text); - impostaCampoRicerca(); - fixChkOds(); - fixOds(); - } - /// - /// salvo il valore selezionato - /// - /// - /// - protected void grView_SelectedIndexChanged(object sender, EventArgs e) - { - string valore = grView.SelectedValue.ToString(); - // se ho una chiave multiparte salvo nei 2 valori... - if (valore.IndexOf('#') > -1) - { - string[] valori = valore.Split('#'); - val1 = valori[0]; - val2 = valori[1]; - } - if (eh_selDone != null) - { - eh_selDone(this, new EventArgs()); - } - } - - /// - /// resetta ricerca e selezione - /// - /// - /// - protected void btnReset_Click(object sender, EventArgs e) - { - grView.SelectedIndex = -1; - testoRicerca = ""; - memLayer.ML.emptySessionVal(searchSessionName); - } - - #endregion - - #region area public - - /// - /// tipo di selettore da istanziare - /// - public tipoSelettore tipo - { - get - { - return _tipoSelettore; - } - set - { - _tipoSelettore = value; - setCheck(); - } - } - - /// - /// effettua update del controllo - /// - public void doUpdate() - { - // svuoto ricerca... - memLayer.ML.emptySessionVal(searchSessionName); - testoRicerca = ""; - // imposto valori cercati... - setSearchValue(); - impostaCampoRicerca(); - // continuo con update - updateChkOpzione(); - fixOds(); - aggiornaDaValMulti(); - // faccio databind... - grView.PageIndex = 0; - grView.DataBind(); - } - - /// - /// valore mostrato nel campo testo del selettore - /// - public string valore - { - get - { - return grView.SelectedValue.ToString(); - } - set - { - _valoreFull = value; - } - } - /// - /// valore di una chiave multiparte - /// - public string val1 - { - get - { - return _val1; - } - set - { - _val1 = value; - aggiornaDaValMulti(); - } - } - - /// - /// valore di una chiave multiparte - /// - public string val2 - { - get - { - return _val2; - } - set - { - _val2 = value; - aggiornaDaValMulti(); - } - } - /// - /// impone una condizione di filtro sui valori mostrati - /// - public string conditio - { - get - { - return _conditio; - } - set - { - _conditio = value; - if (_conditio != "") - { - ods.SelectParameters.Clear(); - ods.SelectParameters.Add("where", string.Format(" conditio = '{0}' ", _conditio)); - } - else - { - ods.SelectParameters.Clear(); - ods.SelectParameters.Add("where", " conditio = '*' "); - } - } - } - /// - /// determina se il valore da selezionare sia da visualizzare o meno - /// - public bool isValueVisible - { - get - { - return _isValueVisible; - } - set - { - _isValueVisible = value; - } - } - - #endregion -} diff --git a/WebSites/WebGIM/mod_selettore_ajax.ascx b/WebSites/WebGIM/mod_selettore_ajax.ascx deleted file mode 100644 index 97e83b2..0000000 --- a/WebSites/WebGIM/mod_selettore_ajax.ascx +++ /dev/null @@ -1,77 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_selettore_ajax.ascx.cs" - Inherits="mod_selettore_ajax" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="ajaxToolkit" %> - - - - -
- - -
-
-
- - - - - - - - - - -
- - - - -
- -   - -   - -   - -
-
- - - - - - - - - - - - - - - - - - - - - - -    - - - - - -
-
-
-
diff --git a/WebSites/WebGIM/mod_selettore_ajax.ascx.cs b/WebSites/WebGIM/mod_selettore_ajax.ascx.cs deleted file mode 100644 index 7a6e5a7..0000000 --- a/WebSites/WebGIM/mod_selettore_ajax.ascx.cs +++ /dev/null @@ -1,499 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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 SteamWare; - -[ValidationProperty("valore")] -public partial class mod_selettore_ajax : ApplicationUserControl -{ - - protected bool _chkVisibile = false; - protected bool _isValueVisible = false; - protected bool _cambioTipo = false; - - protected string _val1; - protected string _val2; - #region gestione eventi - - public event EventHandler eh_selDone; - - #endregion - - #region gestione pagina - - protected override void Page_Load(object sender, EventArgs e) - { - base.Page_Load(sender, e); - updateChkOpzione(); - if (!Page.IsPostBack) - { - SteamWare.memLayer.ML.emptySessionVal(searchSessionName); - } - } - - protected override void traduciObj() - { - base.traduciObj(); - lblCerca.Text = traduci("lblCerca"); - btnCerca.Text = traduci("search"); - if (_chkVisibile) - { - updateChkOpzione(); - } - } - - protected override void OnInit(EventArgs e) - { - base.OnInit(e); - if (!Page.IsPostBack) - { - _val1 = ""; - _val2 = ""; - if (vistaModulo == SteamWare.tipoVistaMod.editing) - { - setSearchValue(); - impostaCampoRicerca(); - pce.Enabled = true; - pce2.Enabled = true; - lblDescr.CssClass = "txtLink"; - } - else if (vistaModulo == SteamWare.tipoVistaMod.selezione) - { - pce.Enabled = false; - pce2.Enabled = false; - lblDescr.CssClass = "txtValue"; - } - traduciObj(); - } - } - /// - /// imposta il valore della ricerca da quello in session - /// - private void setSearchValue() - { - if (SteamWare.memLayer.ML.isInSessionObject(searchSessionName)) - { - testoRicerca = SteamWare.memLayer.ML.StringSessionObj(searchSessionName); - } - } - /// - /// imposta i campi del filtro ricerca in session - /// - private void impostaCampoRicerca() - { - // imposto il nome del valore session x ricerca a campo univoco... - SessionParameter parametroFiltro = new SessionParameter(); - parametroFiltro.SessionField = searchSessionName; - parametroFiltro.Name = searchSessionName; - parametroFiltro.DefaultValue = "*"; - ods.FilterParameters.Clear(); - ods.FilterParameters.Add(parametroFiltro); - } - /// - /// setta il nome del campo di ricerca - /// - protected string searchSessionName - { - get - { - return string.Format("ricerca_{0}", _tipoSelettore); - } - } - - #endregion - - #region area protected - - protected string _conditio = ""; - protected string testoRicerca - { - get - { - return txtCerca.Text.Trim(); - } - set - { - txtCerca.Text = value; - } - } - - protected selettori _selettori = new selettori(); - /// - /// a seconda del tipo di selettore cambierà l'origine ods - /// - /// - /// - protected void chkOpzione_CheckedChanged(object sender, EventArgs e) - { - fixChkOds(); - } - - protected void setCheck() - { - if (_tipoSelettore == tipoSelettore.utentiAll || _tipoSelettore == tipoSelettore.utentiCdc) - { - _chkVisibile = true; - } - else - { - _chkVisibile = false; - } - } - - /// - /// aggiorna visualizzazione del check opzionale con label e visibilità - /// - protected void updateChkOpzione() - { - // se definito il tipo decido SE mostrare il check e tradurre la label... - if (_tipoSelettore == tipoSelettore.utentiAll || _tipoSelettore == tipoSelettore.utentiCdc) - { - chkOpzione.Visible = true; - chkOpzione.Text = traduci("chkSoloGer"); - if (_tipoSelettore == tipoSelettore.utentiCdc) - { - chkOpzione.Checked = true; - } - } - else - { - chkOpzione.Visible = false; - } - } - - /// - /// aggiorna la label che traduce il valore a seconda del tipo di oggetto... - /// - protected void aggiornaLabelDaValore() - { - // x ora metto valore di default... - string _answ = "-"; - if (txtSelValue.Text != "") - { - System.Data.DataView tabella = (System.Data.DataView)ods.Select(); - tabella.RowFilter = string.Format("value = '{0}'", txtSelValue.Text); - try - { - _answ = tabella.ToTable().Rows[0]["label"].ToString(); - } - catch - { } - } - lblDescr.Text = _answ; - } - /// - /// aggiorna label e valore principale da una chiave multipart - /// - private void aggiornaDaValMulti() - { - // eseguo SE E SOLO SE entrambi i valori sono popolati - if (val1 != "" && val1 != null) - { - if (val2 != "" && val2 != null && val2 != "na") - { - txtSelValue.Text = string.Format("{0}#{1}", val1, val2); - aggiornaLabelDaValore(); - } - else - { - txtSelValue.Text = val1; - aggiornaLabelDaValore(); - } - } - } - - - /// - /// tipo di valori mostrati - /// - protected tipoSelettore _tipoSelettore = tipoSelettore.cdc; - /// - /// nome del controllo gestito dal nostro popup - /// - protected string _targetControl = ""; - /// - /// sistemo gli ods - /// - protected override void bindControlli() - { - base.bindControlli(); - fixChkOds(); - fixOds(); - } - /// - /// sistema l'ods dato lo stato del chk - /// - protected void fixChkOds() - { - if (_tipoSelettore == tipoSelettore.utentiAll || _tipoSelettore == tipoSelettore.utentiCdc) - { - // verifico se sia o meno checked "solo cdc utente"... - if (chkOpzione.Checked) - { - //imposto nuovo tipo selettore - _tipoSelettore = tipoSelettore.utentiCdc; - fixOds(); - } - else - { - //imposto nuovo tipo selettore - _tipoSelettore = tipoSelettore.utentiAll; - fixOds(); - } - // faccio databind... - grView.PageIndex = 0; - grView.DataBind(); - - } - } - /// - /// sistemazione fonte ods... - /// - protected void fixOds() - { - string _selectMethod = ""; - switch (_tipoSelettore) - { - case tipoSelettore.cdc: - _selectMethod = "getSelAllCdC"; - break; - case tipoSelettore.impianti: - _selectMethod = "getSelImpianti"; - break; - case tipoSelettore.macchine: - _selectMethod = "getSelMacchine"; - break; - case tipoSelettore.utentiAll: - _selectMethod = "getSelAllUsers"; - break; - case tipoSelettore.utentiCdc: - _selectMethod = "getSelUsersGer"; - break; - } - ods.SelectMethod = _selectMethod; - } - - /// - /// traduce gli header delle colonne - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - /// - /// selezione annullata su cambio pagina - /// - /// - /// - protected void grView_PageIndexChanged(object sender, EventArgs e) - { - grView.SelectedIndex = -1; - } - /// - /// aggiornamento filtro da stringa di ricerca del popup - /// - /// - /// - protected void txtCerca_TextChanged(object sender, EventArgs e) - { - // se cambio filtro tolgo il selected... - grView.SelectedIndex = -1; - // salvo la ricerca in session e filter dell'ods... - SteamWare.memLayer.ML.setSessionVal(searchSessionName, txtCerca.Text); - impostaCampoRicerca(); - fixChkOds(); - fixOds(); - } - /// - /// salvo il valore selezionato - /// - /// - /// - protected void grView_SelectedIndexChanged(object sender, EventArgs e) - { - string valore = grView.SelectedValue.ToString(); - lblDescr.Text = grView.SelectedRow.Cells[2].Text.ToString(); - UpdatePanel1.Update(); - pce.Commit(valore); - pce2.Commit(grView.SelectedRow.Cells[2].Text.ToString()); - // se ho una chiave multiparte salvo nei 2 valori... - if (valore.IndexOf('#') > -1) - { - string[] valori = valore.Split('#'); - val1 = valori[0]; - val2 = valori[1]; - } - if (eh_selDone != null) - { - eh_selDone(this, new EventArgs()); - } - } - - /// - /// resetta ricerca e selezione - /// - /// - /// - protected void btnReset_Click(object sender, EventArgs e) - { - grView.SelectedIndex = -1; - testoRicerca = ""; - SteamWare.memLayer.ML.emptySessionVal(searchSessionName); - } - - #endregion - - #region area public - - /// - /// tipo di selettore da istanziare - /// - public tipoSelettore tipo - { - get - { - return _tipoSelettore; - } - set - { - _tipoSelettore = value; - setCheck(); - } - } - - /// - /// effettua update del controllo - /// - public void doUpdate() - { - // svuoto ricerca... - SteamWare.memLayer.ML.emptySessionVal(searchSessionName); - testoRicerca = ""; - // imposto valori cercati... - setSearchValue(); - impostaCampoRicerca(); - // continuo con update - updateChkOpzione(); - fixOds(); - aggiornaDaValMulti(); - // faccio databind... - grView.PageIndex = 0; - grView.DataBind(); - } - - /// - /// valore mostrato nel campo testo del selettore - /// - public string valore - { - get - { - return txtSelValue.Text; - } - set - { - txtSelValue.Text = value; - aggiornaLabelDaValore(); - } - } - /// - /// valore di una chiave multiparte - /// - public string val1 - { - get - { - return _val1; - } - set - { - _val1 = value; - aggiornaDaValMulti(); - } - } - - /// - /// valore di una chiave multiparte - /// - public string val2 - { - get - { - return _val2; - } - set - { - _val2 = value; - aggiornaDaValMulti(); - } - } - /// - /// impone una condizione di filtro sui valori mostrati - /// - public string conditio - { - get - { - return _conditio; - } - set - { - _conditio = value; - if (_conditio != "") - { - ods.SelectParameters.Clear(); - ods.SelectParameters.Add("where", string.Format(" conditio = '{0}' ", _conditio)); - } - else - { - ods.SelectParameters.Clear(); - ods.SelectParameters.Add("where", " conditio = '*' "); - } - } - } - /// - /// determina se il valore da selezionare sia da visualizzare o meno - /// - public bool isValueVisible - { - get - { - return _isValueVisible; - } - set - { - _isValueVisible = value; - } - } - - #endregion -} diff --git a/WebSites/WebGIM/mod_tipoGuasto.ascx b/WebSites/WebGIM/mod_tipoGuasto.ascx deleted file mode 100644 index 3e72891..0000000 --- a/WebSites/WebGIM/mod_tipoGuasto.ascx +++ /dev/null @@ -1,85 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_tipoGuasto.ascx.cs" Inherits="mod_tipoGuasto" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/WebSites/WebGIM/mod_tipoGuasto.ascx.cs b/WebSites/WebGIM/mod_tipoGuasto.ascx.cs deleted file mode 100644 index 7b6b45a..0000000 --- a/WebSites/WebGIM/mod_tipoGuasto.ascx.cs +++ /dev/null @@ -1,85 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Web; -using System.Web.UI; -using System.Web.UI.WebControls; -using SteamWare; - -public partial class mod_tipoGuasto : ApplicationUserControl -{ - public event EventHandler eh_resetSelezione; - /// - /// evento dati associati a controllo - /// - /// - /// - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - /// - /// reset delle selezioni - /// - /// - /// - protected void btnReset_Click(object sender, EventArgs e) - { - resetSelezione(); - } - /// - /// resetta la selezione dei valori in caso di modifiche su altri controlli - /// - public void resetSelezione() - { - grView.SelectedIndex = -1; - grView.DataBind(); - if (eh_resetSelezione != null) - { - eh_resetSelezione(this, new EventArgs()); - } - } - /// - /// seleziono valore in editing... - /// - /// - /// - protected void grView_RowEditing(object sender, GridViewEditEventArgs e) - { - // seleziono la riga corrente... - grView.SelectedIndex = e.NewEditIndex; - } - /// - /// gestione evento inserimento nuovo record standard (se ZERO presenti) - /// - /// - /// - protected void btnNewFromEmpty_Click(object sender, EventArgs e) - { - // reset selezione... - resetSelezione(); - // i primi valori ("0") di default sono "ND"... li inserisco come standard... - DS_applicazioneTableAdapters.AnagTipoGuastoTableAdapter taTipo = new DS_applicazioneTableAdapters.AnagTipoGuastoTableAdapter(); - taTipo.Insert("-- [NUOVO] non definito --"); - grView.DataBind(); - } -} \ No newline at end of file diff --git a/WebSites/WebGIM/mod_titlePortable.ascx b/WebSites/WebGIM/mod_titlePortable.ascx deleted file mode 100644 index e56cc56..0000000 --- a/WebSites/WebGIM/mod_titlePortable.ascx +++ /dev/null @@ -1,4 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_titlePortable.ascx.cs" Inherits="mod_titleMini" %> - -
-
\ No newline at end of file diff --git a/WebSites/WebGIM/mod_titlePortable.ascx.cs b/WebSites/WebGIM/mod_titlePortable.ascx.cs deleted file mode 100644 index 96da0ac..0000000 --- a/WebSites/WebGIM/mod_titlePortable.ascx.cs +++ /dev/null @@ -1,18 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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; - -public partial class mod_titleMini : System.Web.UI.UserControl -{ - protected void Page_Load(object sender, EventArgs e) - { - lblTitle.Text = string.Format("{0} {1}", ConfigurationManager.AppSettings.Get("portableAppName"), ConfigurationManager.AppSettings.Get("portableAppVersion")); - } -} diff --git a/WebSites/WebGIM/mod_unauthorized.ascx b/WebSites/WebGIM/mod_unauthorized.ascx deleted file mode 100644 index 7ea144e..0000000 --- a/WebSites/WebGIM/mod_unauthorized.ascx +++ /dev/null @@ -1,16 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_unauthorized.ascx.cs" Inherits="mod_unauthorized" %> - - - - - - - - - - -
- SteamWare -
-
-
diff --git a/WebSites/WebGIM/mod_unauthorized.ascx.cs b/WebSites/WebGIM/mod_unauthorized.ascx.cs deleted file mode 100644 index f0bbd12..0000000 --- a/WebSites/WebGIM/mod_unauthorized.ascx.cs +++ /dev/null @@ -1,19 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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; - -public partial class mod_unauthorized : System.Web.UI.UserControl -{ - protected void Page_Load(object sender, EventArgs e) - { - lblTitle.Text = "Attenzione! pagina non disponibile."; - lblMess.Text = "L'utente non è autorizzato alla visione del sito o pagina non è disponibile, verificare l'indirizzo della pagina inserito o contattare l'amministratore."; - } -} diff --git a/WebSites/WebGIM/mod_vocabolario.ascx b/WebSites/WebGIM/mod_vocabolario.ascx deleted file mode 100644 index 03d5c92..0000000 --- a/WebSites/WebGIM/mod_vocabolario.ascx +++ /dev/null @@ -1,105 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeFile="mod_vocabolario.ascx.cs" - Inherits="mod_vocabolario" %> -<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="cc1" %> - - - - - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
diff --git a/WebSites/WebGIM/mod_vocabolario.ascx.cs b/WebSites/WebGIM/mod_vocabolario.ascx.cs deleted file mode 100644 index ec9d032..0000000 --- a/WebSites/WebGIM/mod_vocabolario.ascx.cs +++ /dev/null @@ -1,146 +0,0 @@ -using System; -using System.Data; -using System.Configuration; -using System.Collections; -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 SteamWare; - -public partial class mod_vocabolario : ApplicationUserControl -{ - - #region gestione eventi - - public event EventHandler eh_selezioneValore; - public event EventHandler eh_resetSelezione; - - #endregion - - #region protected - - protected override void traduciObj() - { - base.traduciObj(); - btnNewLemma.Text = user_std.UtSn.Traduci("btnNewLemma"); - txtNewLemma.Text = ""; - TBW_newLemma.WatermarkText = user_std.UtSn.Traduci("insertNewLemma"); - } - - /// - /// inserisco nel db il nuovo lemma... - /// - /// - /// - protected void btnNewLemma_Click(object sender, EventArgs e) - { - creaNuovoLemma(); - } - /// - /// creazione nuovo lemma - /// - private void creaNuovoLemma() - { - if (txtNewLemma.Text != "") - { - // inserisco - DataWrap.DW.creaNuovoLemmaVoc(txtNewLemma.Text.Trim()); - // metto in campo ricerca... - memLayer.ML.setSessionVal("valoreCercato", txtNewLemma.Text.Trim()); - // svuoto campo text - txtNewLemma.Text = ""; - // aggiorno il vocabolario in memoria... - DataWrap.DW.resetVocabolario(); - // riparto... - Response.Redirect(_paginaCorrente); - } - } - - protected override void aggiornaControlliDataGL() - { - base.aggiornaControlliDataGL(); - grView.PageSize = _righeDataGridAnagr; - ods.DataBind(); - } - - protected void grView_DataBound(object sender, EventArgs e) - { - if (grView.Rows.Count > 0) - { - LinkButton lb; - // aggiorno gli headers - foreach (TableCell cella in grView.HeaderRow.Cells) - { - try - { - lb = (LinkButton)cella.Controls[0]; - lb.Text = traduci(lb.Text); - } - catch - { } - } - int totRecord = grView.Rows.Count + grView.PageSize * (grView.PageCount - 1); - lblNumRec.Text = string.Format("{0} records of ~ {1}", grView.Rows.Count, totRecord); - } - else - { - lblNumRec.Text = ""; - } - } - - protected void btnReset_Click(object sender, EventArgs e) - { - resetSelezione(); - } - - protected void grView_SelectedIndexChanged(object sender, EventArgs e) - { - selezionatoValore(); - } - - private void selezionatoValore() - { - SteamWare.memLayer.ML.setSessionVal("lemma_sel", grView.SelectedDataKey.Values[1]); - if (eh_selezioneValore != null) - { - eh_selezioneValore(this, new EventArgs()); - } - } - - protected void grView_RowEditing(object sender, GridViewEditEventArgs e) - { - // seleziono la riga corrente... - grView.SelectedIndex = e.NewEditIndex; - selezionatoValore(); - } - - protected void ods_Updated(object sender, ObjectDataSourceStatusEventArgs e) - { - selezionatoValore(); - } - - #endregion - - #region area public - - /// - /// resetta la selezione dei valori in caso di modifiche su altri controlli - /// - public void resetSelezione() - { - SteamWare.memLayer.ML.emptySessionVal("lemma_sel"); - grView.SelectedIndex = -1; - grView.DataBind(); - if (eh_resetSelezione != null) - { - eh_resetSelezione(this, new EventArgs()); - } - } - - #endregion - -} -