需求文档
This commit is contained in:
@@ -77,9 +77,6 @@ type PlanRepository interface {
|
||||
// FindPlansWithPendingTasks 查找所有正在执行的计划
|
||||
FindPlansWithPendingTasks() ([]*models.Plan, error)
|
||||
|
||||
// DB 返回底层的数据库连接实例,用于服务层事务
|
||||
DB() *gorm.DB
|
||||
|
||||
// StopPlanTransactionally 停止一个计划的执行,包括更新状态、移除待执行任务和更新执行日志
|
||||
StopPlanTransactionally(planID uint) error
|
||||
|
||||
@@ -715,11 +712,6 @@ func (r *gormPlanRepository) FindPlansWithPendingTasks() ([]*models.Plan, error)
|
||||
return plans, err
|
||||
}
|
||||
|
||||
// DB 返回底层的数据库连接实例
|
||||
func (r *gormPlanRepository) DB() *gorm.DB {
|
||||
return r.db
|
||||
}
|
||||
|
||||
// StopPlanTransactionally 停止一个计划的执行,包括更新状态、移除待执行任务和更新执行日志。
|
||||
func (r *gormPlanRepository) StopPlanTransactionally(planID uint) error {
|
||||
return r.db.Transaction(func(tx *gorm.DB) error {
|
||||
|
||||
Reference in New Issue
Block a user