public HttpResponseMessage UpdateLandlords(CollectionLandlordModel model) { using (CollectionsTier ct = new CollectionsTier()) { if (ct.UpdateMerchantLandlordInformation(model)) return this.Request.CreateResponse(HttpStatusCode.OK); else return this.Request.CreateResponse(HttpStatusCode.NotModified); } }
/// <summary> /// /// </summary> /// <param name="entity"></param> /// <returns></returns> public bool UpdateMerchantLandlordInformation(CollectionLandlordModel entity) { return new DataAccess.DataAccess().ExecuteNonQuery("avz_MRC_spUpdateMerchantLandlordInformation", new { merchantId = entity.merchantId, TypeofPropertyId = entity.typeOfPropertyId, LandlordCompanyName = entity.landlordCompanyName, LandlordFirstName = entity.landlordFirstName, LandlordLastName = entity.landlordLastName, RentedAmount = entity.monthlyRentAmount, Address = entity.address, City = entity.city, Phone = entity.telePhone, CellPhone = entity.cellPhone, Email = entity.email, UserId= entity.userId }); }