| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,5 +1,5 @@ | |||
| 1 | 1 | from gitlab.base import RequiredOptional, RESTManager, RESTObject | |
| 2 | - from gitlab.mixins import CRUDMixin, NoUpdateMixin, ObjectDeleteMixin, SaveMixin | ||
| 2 | + from gitlab.mixins import CRUDMixin, ObjectDeleteMixin, SaveMixin | ||
| 3 | 3 | ||
| 4 | 4 | __all__ = [ | |
| 5 | 5 | "ProjectRelease", | |
@@ -9,18 +9,21 @@ | |||
| 9 | 9 | ] | |
| 10 | 10 | ||
| 11 | 11 | ||
| 12 | - class ProjectRelease(RESTObject): | ||
| 12 | + class ProjectRelease(SaveMixin, RESTObject): | ||
| 13 | 13 | _id_attr = "tag_name" | |
| 14 | 14 | _managers = (("links", "ProjectReleaseLinkManager"),) | |
| 15 | 15 | ||
| 16 | 16 | ||
| 17 | - class ProjectReleaseManager(NoUpdateMixin, RESTManager): | ||
| 17 | + class ProjectReleaseManager(CRUDMixin, RESTManager): | ||
| 18 | 18 | _path = "/projects/%(project_id)s/releases" | |
| 19 | 19 | _obj_cls = ProjectRelease | |
| 20 | 20 | _from_parent_attrs = {"project_id": "id"} | |
| 21 | 21 | _create_attrs = RequiredOptional( | |
| 22 | 22 | required=("name", "tag_name", "description"), optional=("ref", "assets") | |
| 23 | 23 | ) | |
| 24 | + _update_attrs = RequiredOptional( | ||
| 25 | + optional=("name", "description", "milestones", "released_at") | ||
| 26 | + ) | ||
| 24 | 27 | ||
| 25 | 28 | ||
| 26 | 29 | class ProjectReleaseLink(ObjectDeleteMixin, SaveMixin, RESTObject): | |
| Back | FazBrowse Home | New Git URL |
0 commit comments