public bool Update(Propiedades entity) { try { var entityDAL = new InmDAL.Propiedades(); entityDAL.DomiciliosId = entity.DomiciliosId; entityDAL.IdAdmConsorcio = entity.DomiciliosId; entityDAL.NomenclaturaCatastral = entity.NomenclaturaCatastral; entityDAL.NroContratoEpec = entity.NroContratoEpec; entityDAL.NroFactura = entity.NroFactura; entityDAL.NumeroCtaRenta = entity.NumeroCtaRenta; entityDAL.PersonasId = entity.PersonasId; entityDAL.PropiedadesId = entity.PropiedadesId; entityDAL.UnidadFacturacion = entity.UnidadFacturacion; entityDAL.Tipo = int.Parse(entity.Tipo); entityDAL.Estado = entity.Estado; entityDAL.ClienteEpecNro = entity.ClienteEpecNro; entityDAL.NroMedidorGas = entity.NroMedidorGas; entityDAL.PrecioVenta = entity.PrecioVenta; entityDAL.TelExpensas = entity.TelExpensas; var response = genericDal.Update(entityDAL); return(response); } catch (Exception ex) { throw new Exception(ex.Message); } }
public int Add(Propiedades entity) { try { var entityDAL = new InmDAL.Propiedades { DomiciliosId = entity.DomiciliosId, NomenclaturaCatastral = entity.NomenclaturaCatastral, NroContratoEpec = entity.NroContratoEpec, NumeroCtaRenta = entity.NumeroCtaRenta, PersonasId = entity.PersonasId, UnidadFacturacion = entity.UnidadFacturacion, NroFactura = entity.NroFactura, Tipo = int.Parse(entity.Tipo), Estado = entity.Estado, ClienteEpecNro = entity.ClienteEpecNro, NroMedidorGas = entity.NroMedidorGas, PrecioVenta = entity.PrecioVenta, TelExpensas = entity.TelExpensas }; var response = genericDal.Add(entityDAL); return(response); } catch (Exception ex) { throw new Exception(ex.Message); } }
public bool Delete(Propiedades entity) { try { var entityDAL = new InmDAL.Propiedades(); entityDAL.PropiedadesId = entity.PropiedadesId; var response = genericDal.Delete(entityDAL); return(response); } catch (Exception ex) { throw new Exception(ex.Message); } }