Skip to content

Commit

Permalink
EPICSYSTEM-17: Updating engagement slug on MET now publishes to EPIC (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
Ckoelewyn authored May 27, 2024
1 parent 91031ef commit ab29137
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions met-api/src/met_api/services/engagement_slug_service.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""Service for engagement slug management."""
from met_api.models.engagement_slug import EngagementSlug as EngagementSlugModel
from met_api.models.engagement import Engagement as EngagementModel
from met_api.services.project_service import ProjectService
from met_api.constants.engagement_status import Status
from met_api.services.slug_generation_service import SlugGenerationService

Expand Down Expand Up @@ -96,6 +97,10 @@ def update_engagement_slug(cls, slug: str, engagement_id: int) -> EngagementSlug
engagement_slug = EngagementSlugModel(engagement_id=engagement_id, slug=slug)

engagement_slug.save()

# publish changes to EPIC
ProjectService.update_project_info(engagement_id)

return {
'slug': engagement_slug.slug,
'engagement_id': engagement_slug.engagement_id,
Expand Down

0 comments on commit ab29137

Please sign in to comment.