https://pulp.plan.io/https://pulp.plan.io/favicon.ico2018-12-19T15:43:05ZPulpPulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=328992018-12-19T15:43:05Zttereshcttereshc@redhat.com
<ul></ul><p>The example of the change which can be added to any "master" viewset.</p>
<pre><code class="diff syntaxhl" data-language="diff"><span class="gh">diff --git a/pulpcore/app/viewsets/content.py b/pulpcore/app/viewsets/content.py
index c42232853..c3d191c57 100644
</span><span class="gd">--- a/pulpcore/app/viewsets/content.py
</span><span class="gi">+++ b/pulpcore/app/viewsets/content.py
</span><span class="p">@@ -96,6 +96,17 @@</span> class ContentViewSet(NamedModelViewSet,
serializer_class = ContentSerializer
filterset_class = ContentFilter
+ def __init_subclass__(cls, **kwargs):
<span class="gi">+ """
+ For subclasses (plugin viewsets) add a plugin name to the endpoint name.
+ """
+ super().__init_subclass__(**kwargs)
+ app_label = cls.queryset.model._meta.app_label
+ if hasattr(cls, 'endpoint_name'):
+ cls.endpoint_name = '{app_label}/{plugin_endpoint_name}'.format(
+ app_label=app_label,
+ plugin_endpoint_name=cls.endpoint_name)
+
</span> @transaction.atomic
def create(self, request):
"""
</code></pre> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=329412018-12-20T19:10:53ZCodeHeeler
<ul><li><strong>Tracker</strong> changed from <i>Issue</i> to <i>Story</i></li><li><strong>% Done</strong> set to <i>0</i></li></ul> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=329982019-01-02T17:34:23Zttereshcttereshc@redhat.com
<ul><li><strong>Description</strong> updated (<a title="View differences" href="/journals/32998/diff?detail_id=33746">diff</a>)</li></ul> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=331612019-01-09T14:43:59Zttereshcttereshc@redhat.com
<ul></ul><p>Discussion of the issue on the pulp-dev mailing list: <a href="https://www.redhat.com/archives/pulp-dev/2019-January/msg00002.html" class="external">https://www.redhat.com/archives/pulp-dev/2019-January/msg00002.html</a></p> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=332352019-01-14T12:26:45Zttereshcttereshc@redhat.com
<ul></ul><p>The result of the discussion <a href="https://www.redhat.com/archives/pulp-dev/2019-January/msg00045.html" class="external">https://www.redhat.com/archives/pulp-dev/2019-January/msg00045.html</a></p> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=332372019-01-14T12:57:30Zttereshcttereshc@redhat.com
<ul><li><strong>Description</strong> updated (<a title="View differences" href="/journals/33237/diff?detail_id=33961">diff</a>)</li></ul> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=332382019-01-14T13:00:13Zttereshcttereshc@redhat.com
<ul><li><strong>Description</strong> updated (<a title="View differences" href="/journals/33238/diff?detail_id=33963">diff</a>)</li></ul> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=332392019-01-14T13:02:32Zttereshcttereshc@redhat.com
<ul><li><strong>Description</strong> updated (<a title="View differences" href="/journals/33239/diff?detail_id=33964">diff</a>)</li></ul> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=332402019-01-14T13:17:24Zdaviddavis
<ul><li><strong>Groomed</strong> changed from <i>No</i> to <i>Yes</i></li><li><strong>Sprint Candidate</strong> changed from <i>No</i> to <i>Yes</i></li></ul> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=332542019-01-14T19:24:18Zttereshcttereshc@redhat.com
<ul><li><strong>Sprint</strong> set to <i>Sprint 47</i></li></ul> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=333062019-01-16T17:33:49Zttereshcttereshc@redhat.com
<ul><li><strong>Status</strong> changed from <i>NEW</i> to <i>ASSIGNED</i></li><li><strong>Assignee</strong> set to <i>ttereshc</i></li></ul> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=334402019-01-23T23:12:19Zttereshcttereshc@redhat.com
<ul><li><strong>Status</strong> changed from <i>ASSIGNED</i> to <i>POST</i></li></ul><p><a href="https://github.com/pulp/pulp/pull/3836/" class="external">https://github.com/pulp/pulp/pull/3836/</a><br>
<a href="https://github.com/pulp/pulp_file/pull/157/" class="external">https://github.com/pulp/pulp_file/pull/157/</a><br>
<a href="https://github.com/pulp/pulp_rpm/pull/1257/" class="external">https://github.com/pulp/pulp_rpm/pull/1257/</a><br>
<a href="https://github.com/pulp/ansible-pulp3/pull/67" class="external">https://github.com/pulp/ansible-pulp3/pull/67</a><br>
<a href="https://github.com/pulp/devel/pull/210" class="external">https://github.com/pulp/devel/pull/210</a><br>
<a href="https://github.com/pulp/pulp_docker/pull/302" class="external">https://github.com/pulp/pulp_docker/pull/302</a><br>
<a href="https://github.com/pulp/pulp_python/pull/217" class="external">https://github.com/pulp/pulp_python/pull/217</a><br>
<a href="https://github.com/pulp/pulp_ansible/pull/76" class="external">https://github.com/pulp/pulp_ansible/pull/76</a><br>
<a href="https://github.com/pulp/plugin_template/pull/28" class="external">https://github.com/pulp/plugin_template/pull/28</a></p> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=334912019-01-25T22:38:52Zrchan
<ul><li><strong>Sprint</strong> changed from <i>Sprint 47</i> to <i>Sprint 48</i></li></ul> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=336152019-01-31T22:52:49Zttereshcttereshc@redhat.com
<ul><li><strong>Status</strong> changed from <i>POST</i> to <i>MODIFIED</i></li><li><strong>% Done</strong> changed from <i>0</i> to <i>100</i></li></ul><p>Applied in changeset <a class="changeset" title="Namespace plugin endpoints with Django app label closes #4279 https://pulp.plan.io/issues/4279 ..." href="https://pulp.plan.io/projects/pulp/repository/pulp/revisions/7654d5d2824f51f580e536ba4b5e931baf9f49b5">pulp|7654d5d2824f51f580e536ba4b5e931baf9f49b5</a>.</p> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=336172019-01-31T23:02:40Zttereshcttereshc@redhat.com
<ul><li><strong>Status</strong> changed from <i>MODIFIED</i> to <i>POST</i></li></ul> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=336212019-02-01T13:07:32Zttereshcttereshc@redhat.com
<ul><li><strong>Status</strong> changed from <i>POST</i> to <i>MODIFIED</i></li></ul> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=336322019-02-01T15:51:13Zttereshcttereshc@redhat.com
<ul></ul> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=413882019-04-25T16:44:56Zdaviddavis
<ul><li><strong>Sprint/Milestone</strong> set to <i>3.0.0</i></li></ul> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=421592019-04-26T20:32:45Zbmbouterbmbouter@redhat.com
<ul><li><strong>Tags</strong> deleted (<del><i>Pulp 3, Pulp 3 RC Blocker</i></del>)</li></ul> Pulp - Story #4279: Namespace plugin endpoints for viewsets of master/detail models.https://pulp.plan.io/issues/4279?journal_id=508402019-12-13T17:27:37Zbmbouterbmbouter@redhat.com
<ul><li><strong>Status</strong> changed from <i>MODIFIED</i> to <i>CLOSED - CURRENTRELEASE</i></li></ul>