推进活动列表第一刀与联调回归
This commit is contained in:
@@ -129,7 +129,7 @@ func (s *EventPlayService) GetEventPlay(ctx context.Context, input EventPlayInpu
|
||||
}
|
||||
}
|
||||
|
||||
canLaunch := event.Status == "active" && event.CurrentReleaseID != nil && event.ManifestURL != nil
|
||||
canLaunch, launchReason := evaluateEventLaunchReadiness(event)
|
||||
result.Play.CanLaunch = canLaunch
|
||||
if canLaunch {
|
||||
result.Play.LaunchSource = LaunchSourceEventCurrentRelease
|
||||
@@ -141,13 +141,13 @@ func (s *EventPlayService) GetEventPlay(ctx context.Context, input EventPlayInpu
|
||||
result.Play.Reason = "user has an ongoing session for this event"
|
||||
case canLaunch:
|
||||
result.Play.PrimaryAction = "start"
|
||||
result.Play.Reason = "event is active and launchable"
|
||||
result.Play.Reason = launchReason
|
||||
case result.Play.RecentSession != nil:
|
||||
result.Play.PrimaryAction = "review_last_result"
|
||||
result.Play.Reason = "event is not launchable, but user has previous session history"
|
||||
result.Play.Reason = launchReason + ", but user has previous session history"
|
||||
default:
|
||||
result.Play.PrimaryAction = "unavailable"
|
||||
result.Play.Reason = "event is not launchable"
|
||||
result.Play.Reason = launchReason
|
||||
}
|
||||
|
||||
return result, nil
|
||||
|
||||
Reference in New Issue
Block a user