Skip to content

Add instance as member of timeline#50

Merged
pendingintent merged 7 commits intomasterfrom
add-instance-as-member-of-timeline
Jan 7, 2026
Merged

Add instance as member of timeline#50
pendingintent merged 7 commits intomasterfrom
add-instance-as-member-of-timeline

Conversation

@pendingintent
Copy link
Owner

Added code to select timeline for an instance to be member
Added select dropdown to instances.html
Added instances export to generate_scheduled_activity_instances.py
Database migrate function to add member_of_timeline column to the instances table

Copilot AI review requested due to automatic review settings January 7, 2026 15:54
@pendingintent pendingintent self-assigned this Jan 7, 2026
@pendingintent pendingintent added the enhancement New feature or request label Jan 7, 2026
@pendingintent pendingintent added this to the v1.2-beta milestone Jan 7, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds the ability to associate scheduled activity instances and timings with specific schedule timelines through a new member_of_timeline field. This enables filtering and organizing instances by their parent timeline.

Key changes:

  • Added member_of_timeline column to the instances table via database migration
  • Updated instance and timing export functions to support optional timeline filtering
  • Added UI dropdown for selecting timeline membership when creating/editing instances

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
src/usdm/generate_study_timings.py Added optional member_of_timeline parameter to filter timings by timeline
src/usdm/generate_scheduled_activity_instances.py Added optional member_of_timeline parameter to filter instances by timeline
src/usdm/generate_schedule_timelines.py New file that builds USDM schedule timeline objects with associated timings and instances
src/soa_builder/web/templates/instances.html Added "Member of Timeline" dropdown to instance creation and editing forms
src/soa_builder/web/schemas.py Added member_of_timeline field to InstanceUpdate and InstanceCreate schemas
src/soa_builder/web/routers/instances.py Updated instance CRUD operations to handle the new member_of_timeline field
src/soa_builder/web/migrate_database.py Added migration function to add member_of_timeline column to instances table
src/soa_builder/web/app.py Registered the new instances migration function

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

spelling

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings January 7, 2026 17:06
pendingintent and others added 2 commits January 7, 2026 12:06
spelling

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
spelling

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 8 out of 8 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

#!/usr/bin/env python3
# Prefer absolute import; fallback to adding src/ to sys.path when run directly
from typing import Optional, List, Dict, Any, Tuple
from typing import Optional, List, Dict, Any
Copy link

Copilot AI Jan 7, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Tuple import was removed but this may break code if it's used elsewhere in the file. Verify that Tuple is not needed in this file.

Suggested change
from typing import Optional, List, Dict, Any
from typing import Optional, List, Dict, Any, Tuple

Copilot uses AI. Check for mistakes.
@pendingintent pendingintent merged commit fa5426a into master Jan 7, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants