public async Task <ActionResult <DProductCategory> > PostDProductCategory(DProductCategory dProductCategory)
        {
            _context.DProductCategories.Add(dProductCategory);
            await _context.SaveChangesAsync();

            return(CreatedAtAction("GetDProductCategory", new { id = dProductCategory.Id }, dProductCategory));
        }
        public async Task <IActionResult> PutDProductCategory(int id, DProductCategory dProductCategory)
        {
            if (id != dProductCategory.Id)
            {
                return(BadRequest());
            }

            _context.Entry(dProductCategory).State = EntityState.Modified;

            try
            {
                await _context.SaveChangesAsync();
            }
            catch (DbUpdateConcurrencyException)
            {
                if (!DProductCategoryExists(id))
                {
                    return(NotFound());
                }
                else
                {
                    throw;
                }
            }

            return(NoContent());
        }