public List <LeaseAgreementDto> AgreementLeaseRead(int ID) { var result = new List <LeaseAgreementDto>(); using (var db = new ONRRDatabaseEntities()) { var query = db.AgreementLeaseSelect(ID); result.AddRange(query.Select(Mapper.Map <LeaseAgreementDto>)); } return(result); }
public LeaseDto LeaseRead(int ID) { LeaseDto result; using (var db = new ONRRDatabaseEntities()) { var query = db.LeasesSelect(ID); result = Mapper.Map <LeaseDto>(query.FirstOrDefault()); } return(result); }
public List <WellLeaseAgreementDto> WellLeaseAgreementRead(string ID) { var result = new List <WellLeaseAgreementDto>(); using (var db = new ONRRDatabaseEntities()) { var query = db.WellLeaseAgreementSelectByWell(ID); result.AddRange(query.Select(Mapper.Map <WellLeaseAgreementDto>)); } return(result); }
public void CompanyPayorUpdate(CompanyPayorCodesDto dto) { try { using (var db = new ONRRDatabaseEntities()) { db.CompanyPayorCodesUpdate(dto.CompanyID, dto.QRACompanyCode, dto.CompanyName, dto.ONRRPayorCode); } } catch (Exception ex) { log.Error(ex.Message + Environment.NewLine + ex.StackTrace); throw; } }
public void StateUpdate(StatesDto dto) { try { using (var db = new ONRRDatabaseEntities()) { db.StatesUpdate(dto.StateCode, dto.State, dto.PressureBase); } } catch (Exception ex) { log.Error(ex.Message + Environment.NewLine + ex.StackTrace); throw; } }
public void ONRRTransactionCodeUpdate(ONRRTransactionCodesDto dto) { try { using (var db = new ONRRDatabaseEntities()) { db.ONRRTransactionCodesUpdate(dto.TransactionCodeID, dto.ONRRTransactionCode, dto.ProductCode, dto.DispositionCode); } } catch (Exception ex) { log.Error(ex.Message + Environment.NewLine + ex.StackTrace); throw; } }
public void PayorCodeUpdate(PayorCodesDto dto) { try { using (var db = new ONRRDatabaseEntities()) { db.PayorCodesUpdate(dto.PayorCodeID, dto.PayorCode, dto.Payor); } } catch (Exception ex) { log.Error(ex.Message + Environment.NewLine + ex.StackTrace); throw; } }
public void ProductCodeCrossReferenceUpdate(ProductCodeCrossReferenceDto dto) { try { using (var db = new ONRRDatabaseEntities()) { db.ProductCodeCrossReferenceUpdate(dto.ProductCodeID, dto.ONRRProductCode, dto.QRAMajorProductCode); } } catch (Exception ex) { log.Error(ex.Message + Environment.NewLine + ex.StackTrace); throw; } }
public void SalesTypeUpdate(SalesTypeDto dto) { try { using (var db = new ONRRDatabaseEntities()) { db.SalesTypesUpdate(dto.SalesTypeID, dto.SalesType); } } catch (Exception ex) { log.Error(ex.Message + Environment.NewLine + ex.StackTrace); throw; } }
public void LeaseAgreementDelete(LeaseAgreementDto dto) { try { using (var db = new ONRRDatabaseEntities()) { db.LeaseAgreementsDelete(dto.LeaseAgreementID); } } catch (Exception ex) { log.Error(ex.Message + Environment.NewLine + ex.StackTrace); throw; } }
public void LeaseClassificationUpdate(LeaseClassificationsDto dto) { try { using (var db = new ONRRDatabaseEntities()) { db.LeaseClassificationsUpdate(dto.LeaseClassificationID, dto.QLSClassificationID, dto.Classification, dto.Active); } } catch (Exception ex) { log.Error(ex.Message + Environment.NewLine + ex.StackTrace); throw; } }
public void CompanyPayorCreate(CompanyPayorCodesDto dto) { try { using (var db = new ONRRDatabaseEntities()) { var newId = new ObjectParameter("newId", 0); var id = db.CompanyPayorCodesInsert(dto.QRACompanyCode, dto.CompanyName, dto.ONRRPayorCode, newId); } } catch (Exception ex) { log.Error(ex.ToString()); throw; } }
public void AgreementClassificationCreate(AgreementClassificationsDto dto) { try { using (var db = new ONRRDatabaseEntities()) { var newId = new ObjectParameter("newId", 0); var id = db.AgreementClassificationsInsert(dto.AgreementClassification, newId); } } catch (Exception ex) { log.Error(ex.ToString()); throw; } }
public void AdjustmentReasonCreate(AdjustmentReasonCodesDto dto) { try { using (var db = new ONRRDatabaseEntities()) { var newId = new ObjectParameter("newId", 0); var id = db.AdjustmentReasonCodesInsert(dto.AdjustmentReasonCode, dto.AdjustmentReason, newId); } } catch (Exception ex) { log.Error(ex.ToString()); throw; } }
public void StateCreate(StatesDto dto) { try { using (var db = new ONRRDatabaseEntities()) { var newId = new ObjectParameter("newId", 0); var id = db.StatesInsert(dto.State, dto.StateCode, dto.PressureBase, newId); } } catch (Exception ex) { log.Error(ex.ToString()); throw; } }
public void SalesTypeCreate(SalesTypeDto dto) { try { using (var db = new ONRRDatabaseEntities()) { var newId = new ObjectParameter("newId", 0); var id = db.SalesTypesInsert(dto.SalesType, newId); } } catch (Exception ex) { log.Error(ex.ToString()); throw; } }
public void LeaseAgreementUpdate(LeaseAgreementDto dto) { try { using (var db = new ONRRDatabaseEntities()) { db.LeaseAgreementsUpdate(dto.LeaseAgreementID, dto.LeaseID, dto.AgreementID, dto.EffectiveFrom, dto.EffectiveFrom, dto.TractFactor, dto.OverrideTractFactor, dto.MarketShare, dto.TractAcreage); } } catch (Exception ex) { log.Error(ex.Message + Environment.NewLine + ex.StackTrace); throw; } }
public void ProductCodeCrossReferenceCreate(ProductCodeCrossReferenceDto dto) { try { using (var db = new ONRRDatabaseEntities()) { var newId = new ObjectParameter("newId", 0); var id = db.ProductCodeCrossReferenceInsert(dto.ONRRProductCode, dto.QRAMajorProductCode, newId); } } catch (Exception ex) { log.Error(ex.ToString()); throw; } }
public void ONRRTransactionCodeCreate(ONRRTransactionCodesDto dto) { try { using (var db = new ONRRDatabaseEntities()) { var newId = new ObjectParameter("newId", 0); var id = db.ONRRTransactionCodesInsert(dto.ONRRTransactionCode, dto.ProductCode, dto.DispositionCode, newId); } } catch (Exception ex) { log.Error(ex.ToString()); throw; } }
public void PaymentMethodCreate(PaymentMethodsDto dto) { try { using (var db = new ONRRDatabaseEntities()) { var newId = new ObjectParameter("newId", 0); var id = db.PaymentMethodsInsert(dto.PaymentMethod, newId); } } catch (Exception ex) { log.Error(ex.ToString()); throw; } }
public void LeaseClassificationCreate(LeaseClassificationsDto dto) { try { using (var db = new ONRRDatabaseEntities()) { var newId = new ObjectParameter("newId", 0); var id = db.LeaseClassificationsInsert(dto.QLSClassificationID, dto.Classification, dto.Active, newId); } } catch (Exception ex) { log.Error(ex.ToString()); throw; } }
public void AgreementUpdate(AgreementDto dto) { try { using (var db = new ONRRDatabaseEntities()) { db.AgreementsUpdate(dto.AgreementID, dto.ONRRAgreementID, dto.BLMSerialNumber, dto.ONRRAgreementDescription, dto.Formation, dto.AgreementClassificationID, dto.AgreementTypeID, dto.TotalAcreage, dto.EffectiveFrom, dto.EffectiveTo, dto.CompanyID); } } catch (Exception ex) { log.Error(ex.Message + Environment.NewLine + ex.StackTrace); throw; } }
public void LeaseAgreementCreate(LeaseAgreementDto dto) { try { using (var db = new ONRRDatabaseEntities()) { var newId = new ObjectParameter("newId", 0); var id = db.LeaseAgreementsInsert(dto.LeaseID, dto.AgreementID, dto.EffectiveFrom, dto.EffectiveFrom, dto.TractFactor, dto.OverrideTractFactor, dto.MarketShare, dto.TractAcreage, newId); } } catch (Exception ex) { log.Error(ex.ToString()); throw; } }
public void LeaseUpdate(LeaseDto dto) { try { using (var db = new ONRRDatabaseEntities()) { db.LeasesUpdate(dto.LeaseID, dto.ONRRLeaseID, dto.BLMSerialNumber, dto.QEPLeaseID, dto.QEPLeaseName, dto.LeaseClassificationID, dto.BIAClassificationID, dto.QEPEffectiveDate, dto.StateCode, dto.County, dto.RoyaltyRate, dto.EffectiveFrom, dto.EffectiveTo, dto.CompanyID); } } catch (Exception ex) { log.Error(ex.Message + Environment.NewLine + ex.StackTrace); throw; } }
public void AgreementCreate(AgreementDto dto) { try { using (var db = new ONRRDatabaseEntities()) { var newId = new ObjectParameter("newId", 0); var id = db.AgreementsInsert(dto.ONRRAgreementID, dto.BLMSerialNumber, dto.ONRRAgreementDescription, dto.Formation, dto.AgreementClassificationID, dto.AgreementTypeID, dto.TotalAcreage, dto.EffectiveFrom, dto.EffectiveTo, dto.CompanyID, newId); } } catch (Exception ex) { log.Error(ex.ToString()); throw; } }
public IEnumerable <StatesDto> StatesRead() { var result = new List <StatesDto>(); try { using (var db = new ONRRDatabaseEntities()) { var query = db.StatesSelectAll(); result.AddRange(query.Select(Mapper.Map <StatesDto>)); } return(result); } catch (Exception ex) { log.Error(ex.Message + Environment.NewLine + ex.StackTrace); throw; } }
public AgreementDto AgreementRead(int ID) { var result = new AgreementDto(); try { using (var db = new ONRRDatabaseEntities()) { var query = db.AgreementsSelect(ID); result = Mapper.Map <AgreementDto>(query.FirstOrDefault()); } return(result); } catch (Exception ex) { log.Error(ex.Message + Environment.NewLine + ex.StackTrace); throw; } }
public WellDto WellRead(string ID) { var result = new WellDto(); try { using (var db = new ONRRDatabaseEntities()) { var query = db.WellCompletionsSelect(ID); result = Mapper.Map <WellDto>(query.FirstOrDefault()); } return(result); } catch (Exception ex) { log.Error(ex.Message + Environment.NewLine + ex.StackTrace); throw; } }
public IEnumerable <DetailDto> DetailsReadForAggregate(int aggregateID) { var result = new List <DetailDto>(); try { using (var db = new ONRRDatabaseEntities()) { var query = db.ONRRDetailSelectByAggregate(aggregateID); result.AddRange(query.Select(Mapper.Map <DetailDto>)); } return(result); } catch (Exception ex) { log.Error(ex.Message + Environment.NewLine + ex.StackTrace); throw; } }
public void LeaseCreate(LeaseDto dto) { try { using (var db = new ONRRDatabaseEntities()) { var newId = new ObjectParameter("newId", 0); var id = db.LeasesInsert(dto.ONRRLeaseID, dto.BLMSerialNumber, dto.QEPLeaseID, dto.QEPLeaseName, dto.LeaseClassificationID, dto.BIAClassificationID, dto.QEPEffectiveDate, dto.StateCode, dto.County, dto.RoyaltyRate, dto.EffectiveFrom, dto.EffectiveTo, dto.CompanyID, newId); } } catch (Exception ex) { log.Error(ex.ToString()); throw; } }