Пример #1
0
        public void checkAndChange()
        {
            IEnumerable <RequestValue> allRequestValue = _requestValueRepository.GetAll();

            DateTime timeNow     = DateTime.Now;
            DateTime timeNow5min = timeNow.AddMinutes(-5);

            foreach (RequestValue i in allRequestValue)
            {
                RequestValue rv = new RequestValue();
                rv.data      = "chien dep trai vkl ha ha ha bonus them nhieu thu nua";
                rv.ID        = new Guid();
                rv.timeStamp = DateTime.Now;



                if ((DateTime.Compare(timeNow, i.timeStamp) > 0) && (DateTime.Compare(timeNow5min, i.timeStamp) < 0))
                {
                    _requestValueRepository.Add(rv);
                }
                else
                {
                    rv.data = "chien galang ahihi <3";
                    _requestValueRepository.Add(rv);
                }
            }
            Save();
        }
Пример #2
0
 public void Create(RequestValue requestValue)
 {
     _requestValueRepository.Add(requestValue);
 }