예제 #1
0
		public void RemovePersonFromQueue(WaitingPersonMeta personMeta, int queueId) {
			if (Queues.ContainsKey(queueId)) {
				var queue = Queues[queueId];

				queue.WaitingHistory.Add(personMeta);

				if (queue.WaitingPeoplesCount > 0)
					queue.WaitingPeoples.RemoveAll(x => x.Guid == personMeta.PersonGuid);
			}
		}
예제 #2
0
파일: QmsHub.cs 프로젝트: TomaszKorecki/QMS
		public void PersonHandledInQueue(int queueId, WaitingPersonMeta personMeta) {
			queuesRepository.RemovePersonFromQueue(personMeta, queueId);

			var handledPerson = StatisticsService.Instance.HandledPeople[personMeta.PersonGuid];
			handledPerson.WaitingTime = personMeta.StopWaitingTime - personMeta.StartWaitingTime;

			if (!String.IsNullOrEmpty(BrowserStateRepository.ConnectionId)) {
				var queue = queuesRepository.Queues[queueId];
				Clients.Client(BrowserStateRepository.ConnectionId).updateQueueLogs(queue);
			}
		}