Skip to content

Commit d6ff42b

Browse files
committed
fix: use NestedGenericTabularInline for ChangeHistoryInline
ChangeHistoryInline was a plain GenericTabularInline but used inside NestedModelAdmin views (WorkflowStageAdmin, etc.), causing AttributeError on 'sortable_options'. Switch to nested_admin.NestedGenericTabularInline for compatibility.
1 parent 57e78d2 commit d6ff42b

3 files changed

Lines changed: 7 additions & 3 deletions

File tree

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10+
## [0.42.2] - 2026-03-31
11+
12+
### Fixed
13+
- **WorkflowStage admin crash (`sortable_options`)**`ChangeHistoryInline` used Django's `GenericTabularInline` but was included inside `NestedModelAdmin` views, causing `AttributeError: 'ChangeHistoryInline' object has no attribute 'sortable_options'`. Changed to `nested_admin.NestedGenericTabularInline` for compatibility.
14+
1015
## [0.42.1] - 2026-03-31
1116

1217
### Fixed

django_forms_workflows/admin.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@
1212
from django.contrib import admin
1313
from django.contrib.auth.admin import GroupAdmin
1414
from django.contrib.auth.models import Group
15-
from django.contrib.contenttypes.admin import GenericTabularInline
1615
from django.db import transaction
1716
from django.http import HttpResponse, HttpResponseRedirect
1817
from django.shortcuts import render
@@ -53,7 +52,7 @@
5352
# ── Change History inline (read-only, for tracked models) ───────────────
5453

5554

56-
class ChangeHistoryInline(GenericTabularInline):
55+
class ChangeHistoryInline(nested_admin.NestedGenericTabularInline):
5756
model = ChangeHistory
5857
ct_field = "content_type"
5958
ct_fk_field = "object_id"

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "django-forms-workflows"
3-
version = "0.42.1"
3+
version = "0.42.2"
44
description = "Enterprise-grade, database-driven form builder with approval workflows and external data integration"
55
license = "LGPL-3.0-only"
66
readme = "README.md"

0 commit comments

Comments
 (0)