/// <summary> /// Check Notification /// </summary> /// <returns></returns> public static bool CheckNotification(Notification notification) { bool result = false; try { if (NotificationManager.GetTypeEvent(notification.TYPE_EVENT).Equals(EventType.TRASM)) { Trasmissione trasm = (Trasmissione)HttpContext.Current.Session["Transmission"]; if (trasm != null) { result = notification.DOMAINOBJECT.Equals(NotificationManager.ListDomainObject.DOCUMENT) ? TrasmManager.setdatavistaSP_TV(UserManager.GetInfoUser(), trasm.infoDocumento.docNumber, "D", trasm.infoDocumento.idRegistro, trasm.systemId) : TrasmManager.setdatavistaSP_TV(UserManager.GetInfoUser(), trasm.infoFascicolo.idFascicolo, "F", trasm.infoFascicolo.idRegistro, trasm.systemId); } } else { result = docsPaWS.CheckNotification(notification, UserManager.GetInfoUser()); } } catch (System.Exception ex) { UIManager.AdministrationManager.DiagnosticError(ex); return(result); } return(result); }
private void CreateAndTrasmDoc(SchedaDocumento scheda, InfoUtente userInfo, Ruolo ruolo) { //creo la trasmissione Trasmissione trasm = new Trasmissione(); TrasmissioneSingola trasmS = new TrasmissioneSingola(); TrasmissioneUtente trasmU = new TrasmissioneUtente(); //trasm.dataInvio = DateTime.Now.ToShortDateString(); trasm.DataDocFasc = scheda.dataCreazione; trasm.infoDocumento = DocsPAWA.DocumentManager.getInfoDocumento(scheda); trasm.ruolo = ruolo; trasm.tipoOggetto = TrasmissioneTipoOggetto.DOCUMENTO; trasm.utente = DocsPAWA.UserManager.getUtente(); trasmS.ragione = TrasmManager.GetRagioneNotifica(userInfo.idAmministrazione); trasmS.tipoDest = TrasmissioneTipoDestinatario.RUOLO; trasmS.tipoTrasm = "S"; trasmS.corrispondenteInterno = UserManager.getCorrispondenteBySystemID(this.Page, ruolo.systemId); trasmU.daNotificare = true; trasmU.utente = UserManager.getUtente(); trasmS.trasmissioneUtente = new TrasmissioneUtente[1]; trasmS.trasmissioneUtente[0] = trasmU; trasm.trasmissioniSingole = new TrasmissioneSingola[1]; trasm.trasmissioniSingole[0] = trasmS; Trasmissione trasmRes = TrasmManager.saveExecuteTrasm(this.Page, trasm, userInfo); }
public static SmistamentoElement BuildInstance(infoToDoList input, Trasmissione trasm, UserInfo userInfo) { SmistamentoElement res = new SmistamentoElement(); res.DataDoc = toDate(input.dataDoc); res.Id = input.sysIdDoc; res.Mittente = input.utenteMittente; res.NoteGenerali = trasm.noteGenerali; res.Oggetto = input.oggetto; res.IdTrasmissione = trasm.systemId; res.Extension = input.cha_img; foreach (TrasmissioneSingola temp in trasm.trasmissioniSingole) { res.IdTrasmissioneSingola = temp.systemId; foreach (TrasmissioneUtente tempUt in temp.trasmissioneUtente) { if (userInfo.UserId.Equals(tempUt.utente.userId)) { res.RagioneTrasmissione = temp.ragione.descrizione; res.NoteIndividuali = temp.noteSingole; res.IdTrasmissioneUtente = tempUt.systemId; if ("W".Equals(temp.ragione.tipo)) { res.HasWorkflow = true; } } } } res.Segnatura = input.infoDoc; return(res); }
public static bool InserimentoInLibroFirma(System.Web.UI.Page page, Trasmissione trasm, string idTrasmSingola) { try { SchedaDocumento sch = DocumentManager.getDocumentDetailsNoSecurity(page, trasm.infoDocumento.docNumber, trasm.infoDocumento.docNumber); TrasmissioneSingola trasmSingola = (from n in trasm.trasmissioniSingole where n.systemId.Equals(idTrasmSingola) select n).FirstOrDefault(); string noteNoteSing = trasmSingola.noteSingole; string note = !string.IsNullOrEmpty(trasm.noteGenerali) ? (string.IsNullOrEmpty(noteNoteSing) ? trasm.noteGenerali : trasm.noteGenerali + " - " + noteNoteSing) : noteNoteSing; ElementoInLibroFirma elemento = new ElementoInLibroFirma() { InfoDocumento = new InfoDocLibroFirma() { Docnumber = sch.docNumber, VersionId = sch.documenti[0].versionId, NumVersione = Convert.ToInt32(sch.documenti[0].version) }, DataAccettazione = DateTime.Now.ToString(), Modalita = LibroFirmaManager.Modalita.MANUALE, TipoFirma = trasmSingola.ragione.azioneRichiesta.ToString(), StatoFirma = TipoStatoElemento.DA_FIRMARE, RuoloProponente = trasm.ruolo, UtenteProponente = trasm.utente, IdRuoloTitolare = RoleManager.GetRoleInSession().idGruppo, IdUtenteTitolare = UserManager.GetUserInSession().idPeople, IdUtenteLocker = UserManager.GetUserInSession().idPeople, IdTrasmSingola = idTrasmSingola, Note = note }; return(docsPaWS.InserimentoInLibroFirma(elemento, UserManager.GetInfoUser())); } catch (System.Exception ex) { UIManager.AdministrationManager.DiagnosticError(ex); return(false); } }
/// <summary> /// Caricamento dati /// </summary> /// <param name="trasmissione"></param> public void Initialize(Trasmissione trasmissione) { this.Fetch(trasmissione); TrasmissioniHandler handler = new TrasmissioniHandler(); this.SetVisibilityPanelAccRif(handler.IsRequiredAccettazioneRifiuto(trasmissione)); }
public static ToDoListElement buildInstance(infoToDoList input, Trasmissione trasm, UserInfo userInfo) { ToDoListElement res = new ToDoListElement(); res.Oggetto = input.oggetto; res.DataDoc = input.dataInvio; res.Note = input.noteGenerali; res.Extension = input.cha_img; // modifica per vedere il mittente delegato in todolist if (!string.IsNullOrEmpty(input.ut_delegato)) { res.Mittente = input.ut_delegato + " sostituto di " + input.utenteMittente; } else { res.Mittente = input.utenteMittente; } res.Ragione = input.ragione; res.TipoProto = input.tipoProto; res.Segnatura = input.infoDoc; if (res.Segnatura.StartsWith("IdDoc:")) { res.Segnatura = null; } if (trasm != null) { foreach (TrasmissioneSingola temp in trasm.trasmissioniSingole) { foreach (TrasmissioneUtente tempUt in temp.trasmissioneUtente) { if (tempUt.utente != null) { if (userInfo.UserId.Equals(tempUt.utente.userId)) { if ("W".Equals(temp.ragione.tipo)) { res.HasWorkflow = true; } } } } } } if (!string.IsNullOrEmpty(input.sysIdFasc)) { res.Id = input.sysIdFasc; res.Tipo = ElementType.FASCICOLO; } else { res.Id = input.sysIdDoc; res.Tipo = ElementType.DOCUMENTO; } res.IdTrasm = input.sysIdTrasm; return(res); }
/// <summary> /// Metodo costruttore per l'inizializzazione della lista dei dettagli delle /// trasmissioni da effettuare /// </summary> public MassiveOperationTrasmissionDetailsCollection(string objType) { this.transmissionCollection = new Dictionary <string, MassiveOperationTransmissionDetailsElement>(); this.transmission = new Trasmissione(); this.transmission.ruolo = UserManager.getRuolo(); this.transmission.utente = UserManager.getUtente(); this.transmission.tipoOggetto = objType.Equals("D") ? TrasmissioneTipoOggetto.DOCUMENTO : TrasmissioneTipoOggetto.FASCICOLO; this.NoNotify = false; this.FromModel = false; }
public Trasmissione BuildTrasmissione(InfoDocumento documento) { Trasmissione trasm = new Trasmissione(); trasm.infoDocumento = documento; trasm.tipoOggetto = DocsPaVO.trasmissione.TipoOggetto.DOCUMENTO; trasm.noteGenerali = _trasmInfo.Note; trasm.utente = _mittente; trasm.ruolo = _ruoloMittente; _tsStrategy.TrasmissioniSingole.ForEach(e => trasm.trasmissioniSingole.Add(e)); return(trasm); }
private static void EseguiTrasmissioni(TrasmissioneVO trasmInfo, List <SchedaDocumento> docs, InfoUtente infoUtente, Ruolo ruolo) { TrasmissioneBuilder trasmBuilder = new TrasmissioneBuilder(infoUtente, ruolo, trasmInfo); foreach (SchedaDocumento doc in docs) { Trasmissione trasm = trasmBuilder.BuildTrasmissione(doc.InfoDocumento); logger.Debug("Salvataggio trasmissione..."); trasm = TrasmManager.saveTrasmMethod(trasm); logger.Debug("Esecuzione trasmissione con id " + trasm.systemId); ExecTrasmManager.executeTrasmMethod("", trasm); } }
/// <summary> /// Reperimento trasmissione utente visualizzata /// </summary> /// <returns></returns> private TrasmissioneUtente GetTrasmissioneUtente() { TrasmissioneUtente trasmUtente = null; Trasmissione trasmissione = this.GetTrasmissione(); if (trasmissione.trasmissioniSingole.Length > 0) { TrasmissioneSingola trasmSingola = trasmissione.trasmissioniSingole[0]; if (trasmSingola.trasmissioneUtente.Length > 0) { trasmUtente = trasmSingola.trasmissioneUtente[0]; } } return(trasmUtente); }
/// <summary> /// Reperimento trasmissioni dell'utente e del ruolo, con la possibilità di effettuare filtri /// </summary> /// <param name="searchType"></param> /// <param name="pagingContext"></param> /// <param name="filters"></param> /// <returns></returns> public Trasmissione[] GetTrasmissioni(TipiTrasmissioniEnum searchType, PagingContext pagingContext, FiltroRicerca[] filters) { Trasmissione[] retValue = null; Utente utente = UserManager.getUtente(); Ruolo ruolo = UserManager.getRuolo(); DocsPaWebService ws = new DocsPaWebService(); int pageCount; int recordCount; if (searchType == TipiTrasmissioniEnum.Effettuate) { retValue = ws.TrasmissioneGetQueryEffettuatePaging( new TrasmissioneOggettoTrasm(), filters, utente, ruolo, pagingContext.PageNumber, out pageCount, out recordCount); } else { retValue = ws.TrasmissioneGetQueryRicevutePaging( new TrasmissioneOggettoTrasm(), filters, utente, ruolo, pagingContext.PageNumber, out pageCount, out recordCount); } pagingContext.PageCount = pageCount; pagingContext.RecordCount = recordCount; if (retValue == null) { retValue = new Trasmissione[0]; } return(retValue); }
/// <summary> /// Metodo costruttore per l'inizializzazione della lista dei dettagli delle /// trasmissioni da effettuare /// </summary> public MassiveOperationTrasmissionDetailsCollection(string objType) { try { this.transmissionCollection = new Dictionary <string, MassiveOperationTransmissionDetailsElement>(); this.transmission = new Trasmissione(); this.transmission.ruolo = UIManager.RoleManager.GetRoleInSession(); this.transmission.utente = UserManager.GetUserInSession();; this.transmission.tipoOggetto = objType.Equals("D") ? TrasmissioneTipoOggetto.DOCUMENTO : TrasmissioneTipoOggetto.FASCICOLO; this.NoNotify = false; this.FromModel = false; } catch (System.Exception ex) { UIManager.AdministrationManager.DiagnosticError(ex); } }
private void init() { _trasm = new Trasmissione(); _trasm.noteGenerali = _modello.VAR_NOTE_GENERALI; if (_isDoc) { _trasm.infoDocumento = BusinessLogic.Documenti.DocManager.GetInfoDocumento(_infoUtente, _id, null); _trasm.tipoOggetto = TipoOggetto.DOCUMENTO; } else { Fascicolo fasc = BusinessLogic.Fascicoli.FascicoloManager.getFascicoloById(_id, _infoUtente); _trasm.infoFascicolo = this.getInfoFascicoloDaFascicolo(fasc); _trasm.tipoOggetto = TipoOggetto.FASCICOLO; } _trasm.utente = BusinessLogic.Utenti.UserManager.getUtente(_infoUtente.idPeople); //aggiunta delegato if (_infoUtente.delegato != null) { _trasm.delegato = _infoUtente.delegato.idPeople; } _trasm.ruolo = _ruolo; _trasm.NO_NOTIFY = _modello.NO_NOTIFY; TrasmSingoleBuilder trasmSingoleBuilder = new TrasmSingoleBuilder(_infoUtente, _ruolo, _modello); for (int i = 0; i < _modello.RAGIONI_DESTINATARI.Count; i++) { RagioneDest ragDest = (RagioneDest)_modello.RAGIONI_DESTINATARI[i]; ArrayList destinatari = new ArrayList(ragDest.DESTINATARI); for (int j = 0; j < destinatari.Count; j++) { MittDest mittDest = (MittDest)destinatari[j]; Corrispondente corr = getCorrispondente(mittDest); if (corr != null) { RagioneTrasmissione ragione = BusinessLogic.Trasmissioni.QueryTrasmManager.getRagioneById("" + mittDest.ID_RAGIONE); trasmSingoleBuilder.addTrasmSingole(corr, ragione, mittDest.VAR_NOTE_SING, mittDest.CHA_TIPO_TRASM, mittDest.SCADENZA); } } } _trasm.trasmissioniSingole = trasmSingoleBuilder.TrasmissioniSingole; }
/// <summary> /// Verifica se, per la trasmissione, è richiesta la /// gestione dell'accettazione/rifiuto da parte dell'utente /// </summary> /// <param name="trasmissione"></param> /// <returns></returns> public bool IsRequiredAccettazioneRifiuto(Trasmissione trasmissione) { bool retValue = false; if (trasmissione.trasmissioniSingole.Length > 0) { TrasmissioneSingola trasmSingola = trasmissione.trasmissioniSingole[0]; if (trasmSingola.trasmissioneUtente.Length > 0) { TrasmissioneUtente trasmUtente = trasmSingola.trasmissioneUtente[0]; retValue = (trasmSingola.ragione.tipo.Equals("W") && trasmUtente.dataRifiutata.Equals(string.Empty) && trasmUtente.dataAccettata.Equals(string.Empty)); } } return(retValue); }
public static TrasmInfo buildInstance(Trasmissione input, UserInfo userInfo, DocsPaVO.utente.Utente delegato) { TrasmInfo trasmInfo = new TrasmInfo(); trasmInfo.IdTrasm = input.systemId; trasmInfo.NoteGenerali = input.noteGenerali; trasmInfo.Mittente = input.utente.descrizione; if (delegato != null) { trasmInfo.Mittente = delegato.descrizione + " sostituto di " + input.utente.descrizione; } foreach (TrasmissioneSingola temp in input.trasmissioniSingole) { foreach (TrasmissioneUtente tempUt in temp.trasmissioneUtente) { if (userInfo.UserId.Equals(tempUt.utente.userId)) { trasmInfo.Ragione = temp.ragione.descrizione; trasmInfo.NoteIndividuali = temp.noteSingole; trasmInfo.IdTrasmUtente = tempUt.systemId; if (!String.IsNullOrEmpty(tempUt.dataAccettata)) { trasmInfo.Accettata = true; } if (!String.IsNullOrEmpty(tempUt.dataRifiutata)) { trasmInfo.Rifiutata = true; } if ("W".Equals(temp.ragione.tipo)) { trasmInfo.HasWorkflow = true; } } } } trasmInfo.Data = toDate(input.dataInvio); return(trasmInfo); }
/// <summary> /// Creazione tabella trasmissioni /// </summary> /// <param name="trasmissione"></param> /// <returns></returns> private void FetchTableTrasmissione(Trasmissione trasmissione) { Table table = new Table(); table.ID = "tableTrasmissione_" + trasmissione.systemId; table.Attributes.Add("summary", "Dati generali trasmissione"); TableRow row = new TableRow(); this.AppendHeaderTableCell(row, "Note generali"); table.Rows.Add(row); row = new TableRow(); this.AppendStandardTableCell(row, trasmissione.noteGenerali); table.Rows.Add(row); this.detailsContainer.Controls.Add(table); if (trasmissione.trasmissioniSingole.Length > 0) { this.FetchTableTrasmissioneSingola(trasmissione.trasmissioniSingole[0]); } }
/// <summary> /// Creazione tabella trasmissioni /// </summary> /// <param name="trasmissione"></param> /// <returns></returns> private void FetchTableTrasmissione(Trasmissione trasmissione) { Table table = new Table(); table.ID = "tableTrasmissione_" + trasmissione.systemId; table.Attributes.Add("summary", "Dati generali trasmissione"); table.Style.Add("WIDTH", "100%"); TableRow row = new TableRow(); this.AppendHeaderTableCell(row, "Note generali"); table.Rows.Add(row); row = new TableRow(); this.AppendStandardTableCell(row, trasmissione.noteGenerali); table.Rows.Add(row); this.detailsContainer.Controls.Add(table); foreach (TrasmissioneSingola trasmissioneSingola in trasmissione.trasmissioniSingole) { this.FetchTableTrasmissioneSingola(trasmissioneSingola, this.CheckTrasmEffettuataDaUtenteCorrente(trasmissione)); } }
/// <summary> /// Metodo per la trasmissione del documento ai destinatari interni (utenti che si trovano in ruoli cui sono associate /// le microfunzioni relative all'IS) /// </summary> /// <param name="settings">Impostazioni relative all'interoperabilità semplificata per il registro su cui è stato creato il documento</param> /// <param name="document">Documento da trasmettere</param> /// <param name="userRole">Ruolo utilizzato per la trasmissione</param> /// <param name="user">Utente mittente della trasmissione</param> /// <param name="privateDocument">Flag utilizzato per indicare se il documento è stato ricevuto marcato come privato dal mittente della spedizione</param> /// <param name="receiversInfo">Informaizoni sui destinari da contattare</param> /// <returns>Lista dei destinatari per cui si è verificato un problema</returns> private static List <ReceiverInfo> TransmitDocument(InteroperabilitySettings settings, SchedaDocumento document, Ruolo userRole, Utente user, bool privateDocument, List <ReceiverInfo> receiversInfo) { logger.Debug("RAFFREDDORE - Start"); logger.Debug("RAFFREDDORE - " + (document == null ? "Documento nullo" : document.systemId)); // Recupero delle informazioni sui corrispondenti interni all'amministrazione che devono ricevere // la trasmissione del documento List <Corrispondente> corrs = null; // Lista dei destinatari della spedizione per cui non sono stati individuati destinatari List <ReceiverInfo> uneachableReceivers = new List <ReceiverInfo>(); try { logger.Debug("RAFFREDDORE - prima del caricamento destinatari"); corrs = InteroperabilitaSemplificataManager.LoadTransmissionReceivers(settings, privateDocument, receiversInfo, out uneachableReceivers); if (corrs == null || corrs.Count == 0) { logger.Error("Nessun destinatario trovato per la trasmissione del documento"); throw new RetrivingTransmissionReceiverException("Nessun destinatario trovato per la trasmissione del documento"); } } catch (Exception e) { SimplifiedInteroperabilityLogAndRegistryManager.InsertItemInLog(document.systemId, true, e.Message); throw new RetrivingTransmissionReceiverException(e.Message); } // Creazione dell'oggetto trasmissione Trasmissione transmission = new Trasmissione(); transmission.ruolo = userRole; transmission.utente = user; transmission.noteGenerali = receiversInfo.Select(r => r.Code).Aggregate((r1, r2) => String.Format("{0} {1}", r1, r2)); transmission.infoDocumento = new InfoDocumento(document); // Creazione della ragione di trasmissione per interoperabilità semplificata RagioneTrasmissione reason = InteroperabilitaSegnatura.getRagioneTrasm(user.idAmministrazione, "S"); if (reason != null && privateDocument) { reason.eredita = "0"; } if (reason != null) { logger.DebugFormat("IS - Effettuato caricamento della ragione di trasmissione per interoperabilità. Id ragione: {0}; Eredita: {1}", reason.systemId, reason.eredita); } // Creazione delle trasmissioni singole transmission.trasmissioniSingole = new System.Collections.ArrayList(); foreach (var corr in corrs) { // Creazione della trasmissione singola TrasmissioneSingola singleTransmission = new TrasmissioneSingola() { ragione = reason, corrispondenteInterno = corr, tipoTrasm = "S", tipoDest = TipoDestinatario.RUOLO }; // Caricamento degli utenti del ruolo singleTransmission.trasmissioneUtente = new System.Collections.ArrayList(); // Caricamento utenti del ruolo QueryCorrispondente qc = new QueryCorrispondente(); qc.codiceRubrica = ((DocsPaVO.utente.Ruolo)corr).codiceRubrica; qc.idRegistri = new System.Collections.ArrayList(); qc.idRegistri.Add(settings.RegistryId); qc.idAmministrazione = user.idAmministrazione; qc.getChildren = true; qc.fineValidita = true; ArrayList users = addressBookManager.listaCorrispondentiIntMethod(qc); // Costruzione delle trasmissioni utente foreach (Utente u in users) { u.dst = user.dst; singleTransmission.trasmissioneUtente.Add(new TrasmissioneUtente() { utente = u }); } transmission.trasmissioniSingole.Add(singleTransmission); } // Esecuzione della trasmissione try { // INCIDENT 104707 // modifica PALUMBO per consentire invio mail di notifica in caso di trasmissione ricevuta per IS // necessaria chiave "URL_PATH_IS" webconfig ws . string path = String.Empty; if (System.Configuration.ConfigurationManager.AppSettings["URL_PATH_IS"] != null) { path = System.Configuration.ConfigurationManager.AppSettings["URL_PATH_IS"].ToString(); } logger.Debug("RAFFREDDORE - url path is " + path); //ExecTrasmManager.saveExecuteTrasmMethod(String.Empty, transmission); Trasmissione resultTrasm = ExecTrasmManager.saveExecuteTrasmMethod(path, transmission); logger.Debug("RAFFREDDORE - Trasmissione nulla? " + (resultTrasm == null?"Nulla":"NON nulla")); //traccio l'evento di trasmssione string method = string.Empty, desc = string.Empty; if (resultTrasm != null && resultTrasm.infoDocumento != null && !string.IsNullOrEmpty(resultTrasm.infoDocumento.docNumber)) { List <string> includedList = new List <string>(); string idCorr = string.Empty; foreach (DocsPaVO.trasmissione.TrasmissioneSingola single in resultTrasm.trasmissioniSingole) { logger.Warn("DEBUG: WriteLog-IS- " + resultTrasm.utente.userId + " " + resultTrasm.infoDocumento.docNumber + " " + resultTrasm.utente.idPeople + " " + resultTrasm.ruolo.idGruppo + " " + resultTrasm.utente.idAmministrazione + " " + resultTrasm.utente.idPeople + " " + method + " " + desc + " " + single.systemId); method = "TRASM_DOC_" + single.ragione.descrizione.ToUpper().Replace(" ", "_"); desc = "Trasmesso Documento predisposto in arrivo : " + resultTrasm.infoDocumento.docNumber.ToString(); idCorr = single.corrispondenteInterno.systemId; if (!includedList.Contains(idCorr)) { BusinessLogic.UserLog.UserLog.WriteLog(resultTrasm.utente.userId, resultTrasm.utente.idPeople, resultTrasm.ruolo.idGruppo, resultTrasm.utente.idAmministrazione, method, resultTrasm.infoDocumento.docNumber, desc, DocsPaVO.Logger.CodAzione.Esito.OK, null, "1", single.systemId); includedList.Add(idCorr); } else { BusinessLogic.UserLog.UserLog.WriteLog(resultTrasm.utente.userId, resultTrasm.utente.idPeople, resultTrasm.ruolo.idGruppo, resultTrasm.utente.idAmministrazione, method, resultTrasm.infoDocumento.docNumber, desc, DocsPaVO.Logger.CodAzione.Esito.OK, null, "0", single.systemId); } logger.Warn("DEBUG: WriteLog-IS- OK"); } } } catch (Exception e) { logger.Error("RAFFREDDORE - Errore durante la trasmissione del documento ai destinatari"); SimplifiedInteroperabilityLogAndRegistryManager.InsertItemInLog(document.systemId, true, "Errore nella trasmissione del documento ai ruoli designati"); throw new ExecuteTransmissionException("Errore durante la trasmissione del documento ai destinatari"); } // Se si è arrivati fin qui la trasmissione è stata effettuata correttamente, quindi viene aggiunta // una voce al log SimplifiedInteroperabilityLogAndRegistryManager.InsertItemInLog(document.systemId, false, String.Format("Documento con id {0} trasmesso correttamente ai destinatari", document.systemId)); // Restituzione dei corrispondenti non troviati return(uneachableReceivers); }
/// <summary> /// Accettazione trasmissione /// </summary> /// <param name="trasmissioneUtente"></param> /// <param name="noteAccettazione"></param> /// <returns></returns> public bool AccettaTrasmissione(TrasmissioneUtente trasmissioneUtente, string noteAccettazione, Trasmissione trasm) { string errore = string.Empty; trasmissioneUtente.noteAccettazione = noteAccettazione; trasmissioneUtente.dataAccettata = DateTime.Now.ToString("dd/MM/yyyy"); trasmissioneUtente.tipoRisposta = DocsPaWR.TrasmissioneTipoRisposta.ACCETTAZIONE; DocsPaWebService ws = new DocsPaWebService(); return(ws.TrasmissioneExecuteAccRif(trasmissioneUtente, trasm.systemId, UserManager.getRuolo(), UserManager.getInfoUtente(), out errore)); }
/// <summary> /// Rifiuto di una trasmissione /// </summary> /// <param name="trasmissioneUtente"></param> /// <param name="noteRifiuto"></param> /// <returns></returns> public bool RifiutaTrasmissione(TrasmissioneUtente trasmissioneUtente, string noteRifiuto, Trasmissione trasmissione) { bool retValue = false; string errore = string.Empty; if (noteRifiuto == null || noteRifiuto == string.Empty) { throw new ApplicationException("Note di rifiuto non impostate"); } trasmissioneUtente.noteRifiuto = noteRifiuto; trasmissioneUtente.dataRifiutata = DateTime.Now.ToString("dd/MM/yyyy"); trasmissioneUtente.tipoRisposta = DocsPaWR.TrasmissioneTipoRisposta.RIFIUTO; DocsPaWebService ws = new DocsPaWebService(); if (ws.TrasmissioneExecuteAccRif(trasmissioneUtente, trasmissione.systemId, UserManager.getRuolo(), UserManager.getInfoUtente(), out errore)) { if (trasmissioneUtente.tipoRisposta.Equals(TrasmissioneTipoRisposta.RIFIUTO)) { retValue = ws.RitornaAlMittTrasmUt(trasmissioneUtente, UserManager.getInfoUtente()); } } return(retValue); }
/// <summary> /// Caricamento dati dettagli trasmissione /// </summary> /// <param name="trasmissione"></param> private void Fetch(Trasmissione trasmissione) { this.FetchTableTrasmissione(trasmissione); }
/// <summary> /// Caricamento dati trasmissione /// </summary> /// <param name="trasmissione"></param> public void Initialize(Trasmissione trasmissione) { this.Fetch(trasmissione); }
/// <summary> /// verifica se la trasmissione è stata effettuata /// dall'utente correntemente connesso /// </summary> /// <returns></returns> private bool CheckTrasmEffettuataDaUtenteCorrente(Trasmissione trasmissione) { return(trasmissione.utente.idPeople.Equals(UserManager.getInfoUtente().idPeople)); }
/// <summary> /// Caricamento dati dettagli trasmissione /// </summary> /// <param name="trasmissione"></param> private void Fetch(Trasmissione trasmissione) { this.FetchTableTrasmissione(trasmissione); this.txtNoteAccRif.Text = string.Empty; }