public void DeleteCallLog(ConfigCallLog callLogRow, string hashKey)
        {
            if (callLogRow == null)
            {
                callLogRow = _context.CallLog
                             .Where(b => b.Key == hashKey)
                             .FirstOrDefault();
            }

            _context.CallLog.Remove(callLogRow);
            _context.SaveChanges();
        }
        public void CreateCallLog(string hashKey, CallLogStatus status)
        {
            ConfigCallLog cl = new ConfigCallLog
            {
                Key              = hashKey,
                Status           = status.ToString(),
                RequestStartTime = DateTime.UtcNow
            };

            _context.CallLog.Add(cl);
            _context.SaveChanges();
        }
        public void UpdateCallLog(ConfigCallLog callLogRow, string hashKey, CallLogStatus status)
        {
            if (callLogRow == null)
            {
                callLogRow = _context.CallLog
                             .Where(b => b.Key == hashKey)
                             .FirstOrDefault();
            }

            callLogRow.Status     = status.ToString();
            callLogRow.FinishTime = DateTime.UtcNow;


            _context.CallLog.Update(callLogRow);
            _context.SaveChanges();
        }