Changeset 0.28.0.1 (#173)

This commit is contained in:
2026-03-11 14:45:37 +00:00
parent 93c72daadf
commit 58313f7e31
57 changed files with 5139 additions and 3206 deletions

View File

@@ -352,11 +352,12 @@ func TriggerWorkflowOnComplete(ctx context.Context, stores store.Stores, workflo
// Bind first stage persona
if len(stages) > 0 && stages[0].PersonaID != nil {
_, _ = database.DB.ExecContext(ctx, database.Q(`
INSERT INTO channel_participants (channel_id, participant_type, participant_id)
VALUES ($1, 'persona', $2)
ON CONFLICT DO NOTHING
`), ch.ID, *stages[0].PersonaID)
_ = stores.Channels.AddParticipant(ctx, &models.ChannelParticipant{
ChannelID: ch.ID,
ParticipantType: "persona",
ParticipantID: *stages[0].PersonaID,
Role: "member",
})
}
log.Printf("[workflow] on_complete: started chained workflow %s → %s (channel %s)",