Example #1
0
 /// <summary>
 /// Filters the visit changed events.
 /// </summary>
 /// <param name="visitChangedEventArgs">The <see cref="Rem.Ria.PatientModule.VisitChangedEventArgs"/> instance containing the event data.</param>
 /// <returns>A <see cref="System.Boolean"/></returns>
 public bool FilterVisitChangedEvents( VisitChangedEventArgs visitChangedEventArgs )
 {
     return ( _scheduledActivities != null && _scheduledActivities.Select ( a => a.VisitKey == visitChangedEventArgs.VisitKey ).Any () ) ||
            ( _recentActivities != null && _recentActivities.Select ( a => a.VisitKey == visitChangedEventArgs.VisitKey ).Any () );
 }
Example #2
0
 /// <summary>
 /// Visits the changed event handler.
 /// </summary>
 /// <param name="args">The <see cref="Rem.Ria.PatientModule.VisitChangedEventArgs"/> instance containing the event data.</param>
 public void VisitChangedEventHandler( VisitChangedEventArgs args )
 {
     GetScheduledActivitiesByClinicalCase ( _clinicalCaseKey );
     GetRecentActivitiesByClinicalCase ( _clinicalCaseKey );
 }
Example #3
0
 /// <summary>
 /// Visits the changed event handler.
 /// </summary>
 /// <param name="visitChangedEventArgs">The <see cref="Rem.Ria.PatientModule.VisitChangedEventArgs"/> instance containing the event data.</param>
 public void VisitChangedEventHandler( VisitChangedEventArgs visitChangedEventArgs )
 {
     Deployment.Current.InvokeIfNeeded ( () => GetVisitByVisitKeyAsync ( visitChangedEventArgs.VisitKey ) );
 }
Example #4
0
        private void RaiseVisitChanged()
        {
            var visitChangedEventArgs = new VisitChangedEventArgs
                {
                    Sender = this,
                    ClinicianKey = Visit.Staff.Key,
                    VisitKey = Visit.Key,
                    VisitStartDateTime = Visit.AppointmentStartDateTime,
                    PatientKey = _patientKey,
                    VisitStatus = Visit.VisitStatus
                };

            _eventAggregator.GetEvent<VisitChangedEvent> ().Publish ( visitChangedEventArgs );
        }
Example #5
0
 /// <summary>
 /// Filters the visit changed events.
 /// </summary>
 /// <param name="visitChangedEventArgs">The <see cref="Rem.Ria.PatientModule.VisitChangedEventArgs"/> instance containing the event data.</param>
 /// <returns>A <see cref="System.Boolean"/></returns>
 public bool FilterVisitChangedEvents( VisitChangedEventArgs visitChangedEventArgs )
 {
     var senderType = visitChangedEventArgs.Sender.GetType ();
     if ( senderType.BaseType != null )
     {
         if ( senderType.BaseType.IsGenericType && senderType.BaseType.GetGenericTypeDefinition () == typeof( ActivityViewModelBase<> ) )
         {
             return false;
         }
     }
     if ( visitChangedEventArgs.Sender == this )
     {
         return false;
     }
     return _visit != null && visitChangedEventArgs.VisitKey == _visit.Key;
 }
 /// <summary>
 /// Visits the changed event handler.
 /// </summary>
 /// <param name="obj">The <see cref="Rem.Ria.PatientModule.VisitChangedEventArgs"/> instance containing the event data.</param>
 public void VisitChangedEventHandler ( VisitChangedEventArgs obj )
 {
     Deployment.Current.InvokeIfNeeded ( () => UpdateSchedule ( true ) );
 }
 /// <summary>
 /// Filters the visit changed events.
 /// </summary>
 /// <param name="visitChangedEventArgs">The <see cref="Rem.Ria.PatientModule.VisitChangedEventArgs"/> instance containing the event data.</param>
 /// <returns>A <see cref="System.Boolean"/></returns>
 public bool FilterVisitChangedEvents ( VisitChangedEventArgs visitChangedEventArgs )
 {
     if ( visitChangedEventArgs.Sender == this )
     {
         return false;
     }
     var isVisitChanged = visitChangedEventArgs.ClinicianKey == ClinicianSchedule.ClinicianKey ||
                           ClinicianSchedule.ClinicianAppointments.Any (
                               a => a.Key == visitChangedEventArgs.VisitKey );
     return isVisitChanged &&
            visitChangedEventArgs.VisitStartDateTime.Date == SelectedDate;
 }
 /// <summary>
 /// Visits the changed event handler.
 /// </summary>
 /// <param name="args">The <see cref="Rem.Ria.PatientModule.VisitChangedEventArgs"/> instance containing the event data.</param>
 public void VisitChangedEventHandler( VisitChangedEventArgs args )
 {
     GetAllActivitiesByClinicalCase ( _clinicalCaseKey );
 }
 /// <summary>
 /// Filters the visit changed events.
 /// </summary>
 /// <param name="visitChangedEventArgs">The <see cref="Rem.Ria.PatientModule.VisitChangedEventArgs"/> instance containing the event data.</param>
 /// <returns>A <see cref="System.Boolean"/></returns>
 public bool FilterVisitChangedEvents( VisitChangedEventArgs visitChangedEventArgs )
 {
     return _activityList != null && _activityList.Select ( a => a.VisitKey == visitChangedEventArgs.VisitKey ).Any ();
 }