/// <summary> /// Check token string is working or expired /// </summary> /// <param name="userID">The user identifier</param> /// <param name="token">Token string</param> /// <returns>-1: expired time, 1: still working</returns> private int CheckToken(Guid userID, string token) { try { using (var _context = new TDHEntities()) { ObjectParameter _output = new ObjectParameter("STATUS", typeof(int)); var _return = _context.PROC_COMMON_CheckToken(token, _output); return((int)_output.Value); } } catch (Exception ex) { Notifier.Notification(userID, Message.Error, Notifier.TYPE.Error); Log.WriteLog(FILE_NAME, MethodInfo.GetCurrentMethod().Name, userID, ex); throw new ApplicationException(); } }