Exemple #1
0
        public RegisterCounterResponse RegisterCounter([FromBody] object request)
        {
            //TODO: Move this logics to the business class
            if (request == null)
            {
                throw new ArgumentNullException("request", "No request object provided.");
            }

            try
            {
                var data = GetData(request);
                //return _counterBusiness.RegisterCounter(data);
                //return _counterBusiness.Register(data.)
                throw new NotImplementedException();
            }
            catch (Exception exception)
            {
                exception.AddData("Request", request.ToString());
                var response = _issueBusiness.RegisterIssue(exception, IssueLevel.Warning);
                exception.AddData("IssueTypeTicket", response.IssueTypeTicket);
                exception.AddData("IssueInstanceTicket", response.IssueInstanceTicket);
                exception.AddData("ResponseMessage", response.ResponseMessage);
                throw;
            }
        }
Exemple #2
0
        public void RegisterSession([FromBody] object request)
        {
            if (request == null)
            {
                throw new ArgumentNullException("request", "No request object provided.");
            }

            try
            {
                var data = GetData(request);
                _sessionBusiness.RegisterSession(data);
            }
            catch (Exception exception)
            {
                exception.AddData("Request", request.ToString());
                var response = _issueBusiness.RegisterIssue(exception, IssueLevel.Warning);
                exception.AddData("IssueTypeTicket", response.IssueTypeTicket);
                exception.AddData("IssueInstanceTicket", response.IssueInstanceTicket);
                exception.AddData("ResponseMessage", response.ResponseMessage);
                throw;
            }
        }