Declare Views integration contract

This commit is contained in:
2026-07-28 21:04:55 +02:00
parent 63e5ce949d
commit b015569b5e

View File

@@ -14,6 +14,7 @@ from govoplan_core.core.module_guards import (
from govoplan_core.core.modules import (
DocumentationTopic,
FrontendModule,
FrontendRoute,
MigrationSpec,
ModuleContext,
ModuleInterfaceProvider,
@@ -26,6 +27,7 @@ from govoplan_core.core.modules import (
from govoplan_core.core.policy import (
CAPABILITY_POLICY_DEFINITION_GOVERNANCE,
)
from govoplan_core.core.views import CAPABILITY_VIEWS_RESOLVER
from govoplan_core.db.base import Base
from govoplan_workflow.backend.db import models as workflow_models
@@ -132,12 +134,14 @@ manifest = ModuleManifest(
"notifications",
"policy",
"tasks",
"views",
),
optional_capabilities=(
CAPABILITY_AUTH_PRINCIPAL_RESOLVER,
CAPABILITY_AUTH_PERMISSION_EVALUATOR,
CAPABILITY_DATAFLOW_RUN_LIFECYCLE,
CAPABILITY_POLICY_DEFINITION_GOVERNANCE,
CAPABILITY_VIEWS_RESOLVER,
),
provides_interfaces=(
ModuleInterfaceProvider(name="workflow.definition_graph", version="0.1.0"),
@@ -157,6 +161,12 @@ manifest = ModuleManifest(
version_max_exclusive="1.0.0",
optional=True,
),
ModuleInterfaceRequirement(
name="views.resolver",
version_min="0.1.0",
version_max_exclusive="1.0.0",
optional=True,
),
),
permissions=PERMISSIONS,
role_templates=ROLE_TEMPLATES,
@@ -172,6 +182,14 @@ manifest = ModuleManifest(
frontend=FrontendModule(
module_id=MODULE_ID,
package_name="@govoplan/workflow-webui",
routes=(
FrontendRoute(
path="/workflow",
component="WorkflowPage",
required_any=(DEFINITION_READ_SCOPE, ADMIN_SCOPE),
order=74,
),
),
nav_items=(
NavItem(
path="/workflow",