public async Task <ActionResult <Brand> > PostBrand(Brand brand) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } var userId = HttpContext.User.Claims.First().Value; _IBrand.Add(brand); await _IBrand.SaveAsync(); return(Ok(brand)); }
public bool Add(E_Model.Brand model) { return(dal.Add(model)); }