示例#1
0
 public Task Handle(JobAssignWeeksChangedEvent message)
 {
     return(UpdateJobAssign(Guid.Parse(message.SourceId),
                            Builders <JobAssign> .Update.Set(f => f.WeekList, message.Weeks),
                            Builders <JobAssign> .Update.Set(f => f.IsLocalIntervalChanged, message.IsLocalIntervalChanged),
                            Builders <JobAssign> .Update.Set(f => f.ChangedByRole, message.ChangedByRole)));
 }
示例#2
0
 private void Apply(JobAssignWeeksChangedEvent e)
 {
     WeekList               = e.Weeks.ToList();
     ChangedByRole          = e.ChangedByRole;
     IsLocalIntervalChanged = e.IsLocalIntervalChanged;
 }