public Bobblehead Put(long id, Bobblehead bobblehead)
        {
            var updatedRecord = this.context.Bobbleheads.Update(bobblehead);

            this.context.SaveChanges();
            this.logger.LogInformation("Updated bobblehead - Id: " + id);
            return(updatedRecord.Entity);
        }
        public Bobblehead Post(Bobblehead bobblehead)
        {
            var addedRecord = this.context.Bobbleheads.Add(bobblehead);

            this.context.SaveChanges();
            this.logger.LogInformation("Added new bobblehead: " + bobblehead.Type);
            return(addedRecord.Entity);
        }
 public BobbleheadDetailViewModel(Bobblehead bobblehead)
 {
     Bobblehead = bobblehead;
     IsExpanded = !IsChecked;
 }
 public Bobblehead Put(long id, [FromBody] Bobblehead bobblehead)
 {
     return(this.repository.Put(id, bobblehead));
 }
 public Bobblehead Post([FromBody] Bobblehead bobblehead)
 {
     return(this.repository.Post(bobblehead));
 }