mirror of
https://github.com/goharbor/harbor
synced 2024-09-20 12:35:35 +00:00
Fix statuses condition when trigger replication
Signed-off-by: 陈德 <chende@caicloud.io>
This commit is contained in:
parent
98bcac6c8e
commit
254c1f4df1
|
@ -64,8 +64,9 @@ func (r *ReplicationAPI) Post() {
|
|||
}
|
||||
|
||||
count, err := dao.GetTotalCountOfRepJobs(&models.RepJobQuery{
|
||||
PolicyID: replication.PolicyID,
|
||||
Statuses: []string{models.RepOpTransfer, models.RepOpDelete},
|
||||
PolicyID: replication.PolicyID,
|
||||
Statuses: []string{models.JobPending, models.JobRunning},
|
||||
Operations: []string{models.RepOpTransfer, models.RepOpDelete},
|
||||
})
|
||||
if err != nil {
|
||||
r.HandleInternalServerError(fmt.Sprintf("failed to filter jobs of policy %d: %v",
|
||||
|
|
Loading…
Reference in New Issue
Block a user