public bool EkleMusteri(Musteriler entity) { try { using (MusterilerBusiness musterilerBusiness = new MusterilerBusiness()) { musterilerBusiness.Ekle(entity); } return(true); } catch (Exception) { return(false); } }
public IHttpActionResult Post([FromBody] Musteriler musteriler) { var content = new ResponseContent <Musteriler>(null); if (musteriler != null) { using (var musterilerBusiness = new MusterilerBusiness()) { content.Result = musterilerBusiness.Ekle(musteriler) ? "1" : "0"; return(new StandartResult <Musteriler>(content, Request)); } } content.Result = "0"; return(new StandartResult <Musteriler>(content, Request)); }