public HttpResponseMessage Create(HttpRequestMessage request, CompanyInfoViewmodel vm)
        {
            string mess   = "";
            var    entity = vm.UpdateModel();

            if (IoC.Resolve <ICompanyInfoService>().Create(entity, out mess))
            {
                return(request.CreateResponse(HttpStatusCode.OK, mess));
            }
            return(request.CreateResponse(HttpStatusCode.BadRequest, mess));
        }
        public HttpResponseMessage ChangeInfo(HttpRequestMessage request, CompanyInfoViewmodel vm)
        {
            string mess = "";
            var    srv  = IoC.Resolve <ICompanyInfoService>();

            if (srv.ChangeInfo(vm.UpdateModel(srv.GetbyKey(vm.Id)), out mess))
            {
                return(request.CreateResponse(HttpStatusCode.OK, mess));
            }
            return(request.CreateResponse(HttpStatusCode.BadRequest, mess));
        }