Skip to content

Commit 2ab1b27

Browse files
Merge pull request #2052 from IFRCGo/fix/dref-add-missing-auto-fields-in-admin
Add missing DREF report autocomplete fields
2 parents 2dc65aa + 95dff03 commit 2ab1b27

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

dref/admin.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
IdentifiedNeed,
1212
PlannedIntervention,
1313
RiskSecurity,
14+
SourceInformation,
1415
)
1516

1617

@@ -62,6 +63,11 @@ class DrefFileAdmin(admin.ModelAdmin):
6263
search_fields = ("file",)
6364

6465

66+
@admin.register(SourceInformation)
67+
class SourceInformationAdmin(admin.ModelAdmin):
68+
search_fields = ("source_name",)
69+
70+
6571
@admin.register(Dref)
6672
class DrefAdmin(
6773
CompareVersionAdmin,
@@ -202,6 +208,11 @@ class DrefFinalReportAdmin(
202208
"cover_image",
203209
"financial_report",
204210
"risk_security",
211+
"needs_identified",
212+
"planned_interventions",
213+
"users",
214+
"national_society_actions",
215+
"source_information",
205216
)
206217
list_filter = ["dref"]
207218
search_fields = ["title", "national_society__name", "appeal_code"]

0 commit comments

Comments
 (0)