public async Task <ActionResult <ProductSizeVM> > Post(ProductSizeVM sizeVM)
        {
            if (!ModelState.IsValid)
            {
                return(BadRequest());
            }
            var data = repository.Add(sizeVM);

            return(CreatedAtAction(nameof(data), new { id = data.ID }, data));
        }
 public async Task <ActionResult <ProductSizeVM> > Put(ProductSizeVM sizeVM)
 {
     if (!ModelState.IsValid)
     {
         return(BadRequest());
     }
     else
     {
         var mainData = repository.Get(sizeVM.ID);
         if (mainData == null)
         {
             return(NotFound());
         }
         var data = repository.Update(sizeVM);
         return(data);
     }
 }