Multiple Migfeat: Update publishing terminology and add publishing settings - Changed references from "WordPress" to "Site" across multiple components for consistency. - Introduced a new "Publishing" tab in Site Settings to manage automatic content approval and publishing behavior. - Added publishing settings model to the backend with fields for auto-approval, auto-publish, and publishing limits. - Implemented Celery tasks for scheduling and processing automated content publishing. - Enhanced Writer Dashboard to include metrics for content published to the site and scheduled for publishing.
35 lines
1.1 KiB
Python
35 lines
1.1 KiB
Python
"""
|
|
Integration URLs
|
|
Phase 6: Site Integration & Multi-Destination Publishing
|
|
"""
|
|
from django.urls import path, include
|
|
from rest_framework.routers import DefaultRouter
|
|
|
|
from igny8_core.modules.integration.views import IntegrationViewSet, PublishingSettingsViewSet
|
|
from igny8_core.modules.integration.webhooks import (
|
|
wordpress_status_webhook,
|
|
wordpress_metadata_webhook,
|
|
)
|
|
|
|
router = DefaultRouter()
|
|
router.register(r'integrations', IntegrationViewSet, basename='integration')
|
|
|
|
# Create PublishingSettings ViewSet instance
|
|
publishing_settings_viewset = PublishingSettingsViewSet.as_view({
|
|
'get': 'retrieve',
|
|
'put': 'update',
|
|
'patch': 'partial_update',
|
|
})
|
|
|
|
urlpatterns = [
|
|
path('', include(router.urls)),
|
|
|
|
# Site-level publishing settings
|
|
path('sites/<int:site_id>/publishing-settings/', publishing_settings_viewset, name='publishing-settings'),
|
|
|
|
# Webhook endpoints
|
|
path('webhooks/wordpress/status/', wordpress_status_webhook, name='wordpress-status-webhook'),
|
|
path('webhooks/wordpress/metadata/', wordpress_metadata_webhook, name='wordpress-metadata-webhook'),
|
|
]
|
|
|