mirror of
https://github.com/OPM/ResInsight.git
synced 2026-11-24 14:58:13 -06:00
#14688 Sim Events: Add API to query event dates and wells
Add event date and well queries with date, owner and event type/keyword filters to SimulatorEventsDocument and WellEventTimeline, including latest_event_date() and wells_with_msw_events() for building the export_msw_for_wells list.
This commit is contained in:
1 parent
360c3c69db
commit
8dc1d56bd3
11 files changed
+903
-3
No files matched your search
@@ -125,9 +125,15 @@ def main() -> None:
|
||||
if report.events_applied == 0:
|
||||
print(" No events found - skipping schedule generation.")
|
||||
return
|
||||
# Export multi-segment-well keywords only for the wells with SEGMENT events.
|
||||
msw_wells = timeline.wells_with_msw_events()
|
||||
print(
|
||||
f" Event dates: {timeline.earliest_event_date()} to {timeline.latest_event_date()}"
|
||||
)
|
||||
print(f" MSW wells: {[well.name for well in msw_wells]}")
|
||||
schedule_text = timeline.generate_schedule_text(
|
||||
eclipse_case=case,
|
||||
export_msw_for_wells=project.well_paths(),
|
||||
export_msw_for_wells=msw_wells,
|
||||
align_columns=True,
|
||||
)
|
||||
if schedule_text:
|
||||
|
||||
+1
-1
@@ -237,7 +237,7 @@ def main() -> None:
|
||||
# user, and each generated WELSPECS record has a matching COMPORD INPUT record.
|
||||
schedule_text = timeline.generate_schedule_text(
|
||||
eclipse_case=case,
|
||||
export_msw_for_wells=[well_path],
|
||||
export_msw_for_wells=timeline.wells_with_msw_events(),
|
||||
align_columns=True,
|
||||
)
|
||||
if schedule_text:
|
||||
|
||||
Reference in new issue
Block a user