Skip to content

Commit 5358fc5

Browse files
author
zsbahtiar
committed
feat(action_model): add query DeleteRunByID
1 parent 862237c commit 5358fc5

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

models/actions/run.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -435,3 +435,10 @@ func UpdateRun(ctx context.Context, run *ActionRun, cols ...string) error {
435435
}
436436

437437
type ActionRunIndex db.ResourceIndex
438+
439+
// DeleteRunByID delete action_run.
440+
func DeleteRunByID(ctx context.Context, id int64) error {
441+
var run ActionRun
442+
_, err := db.GetEngine(ctx).Where("id=?", id).Delete(&run)
443+
return err
444+
}

0 commit comments

Comments
 (0)