public HttpResponseMessage Create(HttpRequestMessage request, ControlPanelViewModel controPanelVM)
        {
            return(CreateHttpResponse(request, () =>
            {
                HttpResponseMessage response = null;

                if (!ModelState.IsValid)
                {
                    response = request.CreateErrorResponse(HttpStatusCode.BadRequest, ModelState);
                }
                else
                {
                    ControlPanel newControlPanel = new ControlPanel();
                    newControlPanel.UpdateControlPanel(controPanelVM);
                    var page = _controlPanelService.Add(newControlPanel);
                    _controlPanelService.Save();
                    response = request.CreateResponse(HttpStatusCode.Created, page);
                }
                return response;
            }));
        }