Add publish batch command
This commit is contained in:
parent
2123820586
commit
e5ed57c3d8
1 changed files with 9 additions and 0 deletions
|
@ -143,5 +143,14 @@ func (c *JiraClient) PublishAll(cmp *model.Campaign) (int, error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *JiraClient) PublishBatch(cmp *model.Campaign, batch int) error {
|
func (c *JiraClient) PublishBatch(cmp *model.Campaign, batch int) error {
|
||||||
|
for i := 0; i <= batch; i++ {
|
||||||
|
next, err := c.PublishNextTicket(cmp)
|
||||||
|
if err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
|
if !next {
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
}
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue