Пример #1
0
        private void RimuoviFiltriDocs()
        {
            // Rimozione del filtro correntemente impostato sui documenti
            ricercaDoc.FiltriRicercaDocumenti.CurrentFilterSessionStorage.RemoveCurrentFilter();

            //Impostazione dell'indice della pagina corrente del datagrid a 0
            this.dt_Prot.CurrentPageIndex = 0;

            FascicoliManager.SetProtoDocsGridPaging(this, this.dt_Prot.CurrentPageIndex);

            // Caricamento dati senza filtri impostati
            this.FillData(this.dt_Prot.CurrentPageIndex + 1);
        }
Пример #2
0
        private void FiltraDocs()
        {
            //if (bool.Parse(Request.QueryString["FilterDocumentsRetValue"].ToString()) == true)
            //{
            // Impostazione dell'indice della pagina corrente del datagrid a 0
            FascicoliManager.SetProtoDocsGridPaging(this, 0);

            this.dt_Prot.CurrentPageIndex = 0;

            // Caricamento dati applicando il filtro correntemente impostato
            this.FillData(this.dt_Prot.CurrentPageIndex + 1);
            //}
        }
Пример #3
0
        protected void dt_Prot_SelectedIndexChanged(object sender, EventArgs e)
        {
            string newUrl = "";

            FascicoliManager.SetProtoDocsGridPaging(this, this.dt_Prot.CurrentPageIndex);
            FascicoliManager.SetFolderViewTracing(this, true);

            /* Debug */
            this.SendDebugAlert("Prot=" + this.dt_Prot.CurrentPageIndex);

            string key = ((Label)this.dt_Prot.Items[this.dt_Prot.SelectedIndex].Cells[6].Controls[1]).Text;

            string tipoP = ((Label)this.dt_Prot.Items[this.dt_Prot.SelectedIndex].Cells[4].Controls[1]).Text;

            if (!tipoP.Equals("NP"))
            {
                newUrl = "../documento/gestioneDoc.aspx?tab=protocollo";
            }
            else
            {
                newUrl = "../documento/gestioneDoc.aspx?tab=profilo";
            }

            int idDocumento = Int32.Parse(key);

            // Aggiornamento contesto chiamante
            this.RefreshCallerContext(this.dt_Prot.CurrentPageIndex, idDocumento);

            dettaglioDocumento(idDocumento, newUrl);

            FascicoliManager.setMemoriaFascicoloSelezionato(this, FascicoliManager.getFascicoloSelezionato());
            FascicoliManager.setMemoriaFolderSelezionata(this, FascicoliManager.getFolderSelezionato(this));

            FascicoliManager.removeFascicoloSelezionato(this);
            FascicoliManager.removeFolderSelezionato(this);

            //Inserisco in sessione l'oggetto per lo scorrimento continuo della lista
            ArrayList listaDoc = new ArrayList(FascicoliManager.getHashDocProtENonProt(this).Values);

            listaDoc.Reverse();
            //UserControls.ScrollElementsList.ScrollManager.setInSessionNewObjScrollElementsList(dt_Prot.VirtualItemCount, dt_Prot.PageCount, dt_Prot.PageSize, idDocumento, dt_Prot.CurrentPageIndex, listaDoc, UserControls.ScrollElementsList.ObjScrollElementsList.EmunSearchContext.RICERCA_DOC_IN_FASC);
            UserControls.ScrollElementsList.ScrollManager.setInContextNewObjScrollElementsList(dt_Prot.VirtualItemCount, dt_Prot.PageCount, dt_Prot.PageSize, idDocumento, dt_Prot.CurrentPageIndex, listaDoc, UserControls.ScrollElementsList.ObjScrollElementsList.EmunSearchContext.RICERCA_DOC_IN_FASC);
        }
Пример #4
0
        /// <summary>
        /// Page_Load
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void Page_Load(object sender, System.EventArgs e)
        {
            try
            {
                logger.Debug("tabfasclistadoc.aspx_pg");
                Utils.startUp(this);

                getLettereProtocolli();
                logger.Debug("tabfasclistadoc.aspx_pg2");

                if (!Page.IsPostBack)
                {
                    this.btn_stampa.Attributes.Add("onclick", "StampaRisultatoRicerca();");

                    this.AttachWaitingControl();

                    this.dt_Prot.CurrentPageIndex = this.GetCurrentPageIndex();
                    logger.Debug("tabfasclistadoc.aspx_pg3");

                    FascicoliManager.SetProtoDocsGridPaging(this, 0);
                    logger.Debug("tabfasclistadoc.aspx_pg4");

                    this.FillData(this.dt_Prot.CurrentPageIndex + 1);
                    logger.Debug("tabfasclistadoc.aspx_pg5");
                }
                //else
                //{
                //    bool filtra = ((Request.QueryString["FilterDocumentsRetValue"] != null && Request.QueryString["FilterDocumentsRetValue"].ToString() == "true") || ricercaDoc.FiltriRicercaDocumenti.CurrentFilterSessionStorage.GetCurrentFilter() != null);

                //    if (filtra)
                //        this.FiltraDocs();
                //    else
                //        this.RimuoviFiltriDocs();
                //}
            }
            catch (Exception es)
            {
                ErrorManager.redirect(this, es);
            }
        }
Пример #5
0
        private DocsPaWR.SearchObject[] searchDoc(ObjScrollElementsList objScrollElementsList, Page page)
        {
            DocsPAWA.DocsPaWR.InfoUtente        infoUtente  = UserManager.getInfoUtente(page);
            DocsPAWA.DocsPaWR.FiltroRicerca[][] listaFiltri = null;
            DocsPAWA.DocsPaWR.SearchObject[]    listaDoc    = null;
            SearchResultInfo[] idProfilesList;

            switch (objScrollElementsList.searchContext)
            {
            case ObjScrollElementsList.EmunSearchContext.RICERCA_DOCUMENTI:
                listaFiltri = (DocsPAWA.DocsPaWR.FiltroRicerca[][])SiteNavigation.CallContextStack.CallerContext.SessionState["ricDoc.listaFiltri"];

                // Se non ci sono filtri vengono caricati quelli per la nuova ricerca
                if (listaFiltri == null)
                {
                    listaFiltri = CallContextStack.CallerContext.ContextState["SearchFilters"] as FiltroRicerca[][];
                }


                // listaDoc = DocumentManager.getQueryInfoDocumentoPaging(infoUtente.idGruppo, infoUtente.idPeople, page, listaFiltri, objScrollElementsList.selectedPage + 1, out objScrollElementsList.totalNumberOfPage, out objScrollElementsList.totalNumberOfElements, false, false, true, false, out idProfilesList);
                listaDoc = DocumentManager.getQueryInfoDocumentoPagingCustom(infoUtente, page, listaFiltri, objScrollElementsList.selectedPage + 1, out objScrollElementsList.totalNumberOfPage, out objScrollElementsList.totalNumberOfElements, true, false, GridManager.IsRoleEnabledToUseGrids(), objScrollElementsList.pageSize, false, null, null, out idProfilesList);

                break;

            case ObjScrollElementsList.EmunSearchContext.RICERCA_DOC_IN_FASC:
                listaFiltri = ricercaDoc.FiltriRicercaDocumenti.CurrentFilterSessionStorage.GetCurrentFilter();

                // Se non ci sono filtri vengono caricati quelli per la nuova ricerca
                if (listaFiltri == null)
                {
                    listaFiltri = CallContextStack.CallerContext.ContextState["SearchFilters"] as FiltroRicerca[][];
                }

                DocsPaWR.Folder folder;

                // Se nel call context è salvato un fascicolo selezionato viene caricato il folder relativo altrimenti viene prelevato
                // dal call context il folder salvato dalla pagina di ricerca documenti in fascicolo
                if (SiteNavigation.CallContextStack.CallerContext.SessionState.ContainsKey("FascicoloSelezionato"))
                {
                    folder = FascicoliManager.getFolder(
                        page,
                        (DocsPaWR.Fascicolo)SiteNavigation.CallContextStack.CallerContext.SessionState["FascicoloSelezionato"]);
                }
                else
                {
                    folder = CallContextStack.CallerContext.ContextState["Folder"] as Folder;
                }

                FascicoliManager.SetProtoDocsGridPaging(page, objScrollElementsList.selectedPage);

                FascicolazioneClassificazione a = new FascicolazioneClassificazione();
                SearchResultInfo[]            idProfiles;
                if (folder != null)
                {
                    if (listaFiltri == null)
                    {
                        // listaDoc = FascicoliManager.getListaDocumentiPaging(page, folder, objScrollElementsList.selectedPage + 1, out objScrollElementsList.totalNumberOfPage, out objScrollElementsList.totalNumberOfElements, false, out idProfiles);
                        //listaDoc = FascicoliManager.getListaFascicoliPagingCustom(page, a, UserManager.getRegistroSelezionato(page), listaFiltri, false, objScrollElementsList.selectedPage + 1, out objScrollElementsList.totalNumberOfPage, out objScrollElementsList.totalNumberOfElements, objScrollElementsList.pageSize, false, out idProfilesList, null, GridManager.IsRoleEnabledToUseGrids(), false, null, null);
                        listaDoc = FascicoliManager.getListaDocumentiPagingCustom(page, folder, listaFiltri, objScrollElementsList.selectedPage + 1, out objScrollElementsList.totalNumberOfPage, out objScrollElementsList.totalNumberOfElements, false, GridManager.IsRoleEnabledToUseGrids(), false, null, null, objScrollElementsList.pageSize, FiltriRicercaDocumenti.CurrentFilterSessionOrderFilter.GetCurrentFilter(), out idProfiles);
                    }
                    else
                    {
                        // listaDoc = FascicoliManager.getListaDocumentiPaging(page, folder, listaFiltri, objScrollElementsList.selectedPage + 1, out objScrollElementsList.totalNumberOfPage, out objScrollElementsList.totalNumberOfElements, false, out idProfiles);
                        listaDoc = FascicoliManager.getListaDocumentiPagingCustom(page, folder, listaFiltri, objScrollElementsList.selectedPage + 1, out objScrollElementsList.totalNumberOfPage, out objScrollElementsList.totalNumberOfElements, false, GridManager.IsRoleEnabledToUseGrids(), false, null, null, objScrollElementsList.pageSize, FiltriRicercaDocumenti.CurrentFilterSessionOrderFilter.GetCurrentFilter(), out idProfiles);
                    }
                }
                break;
            }

            return(listaDoc);
        }