You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

issue_milestone.go 1.2KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. // Copyright 2016 The Gogs Authors. All rights reserved.
  2. // Use of this source code is governed by a MIT-style
  3. // license that can be found in the LICENSE file.
  4. package structs
  5. import (
  6. "time"
  7. )
  8. // Milestone milestone is a collection of issues on one repository
  9. type Milestone struct {
  10. ID int64 `json:"id"`
  11. Title string `json:"title"`
  12. Description string `json:"description"`
  13. State StateType `json:"state"`
  14. OpenIssues int `json:"open_issues"`
  15. ClosedIssues int `json:"closed_issues"`
  16. // swagger:strfmt date-time
  17. Closed *time.Time `json:"closed_at"`
  18. // swagger:strfmt date-time
  19. Deadline *time.Time `json:"due_on"`
  20. }
  21. // CreateMilestoneOption options for creating a milestone
  22. type CreateMilestoneOption struct {
  23. Title string `json:"title"`
  24. Description string `json:"description"`
  25. // swagger:strfmt date-time
  26. Deadline *time.Time `json:"due_on"`
  27. // enum: open,closed
  28. State string `json:"state"`
  29. }
  30. // EditMilestoneOption options for editing a milestone
  31. type EditMilestoneOption struct {
  32. Title string `json:"title"`
  33. Description *string `json:"description"`
  34. State *string `json:"state"`
  35. Deadline *time.Time `json:"due_on"`
  36. }