public HttpResponseMessage UpdateShelf(BookShelfViewModel viewModel)
        {
            var bookShelf = _shelfRepository.GetById(viewModel.Id);
            Mapper.Map(viewModel, bookShelf);
            bookShelf.Storage = _storRepository.GetById(viewModel.StorageId);
            _shelfRepository.Update(bookShelf);
            SaveChanges();

            return Request.CreateResponse(HttpStatusCode.OK,"ok");
        }
        public HttpResponseMessage AddShelf(BookShelfViewModel viewModel)
        {
            var bookShelf = Mapper.Map<BookShelfViewModel, BookShelf>(viewModel);

            bookShelf.Storage = _storRepository.GetById(viewModel.StorageId);
            _shelfRepository.Insert(bookShelf);
            SaveChanges();

            return Request.CreateResponse(HttpStatusCode.OK,"ok");
        }