@@ -266,7 +266,7 @@ class Meta:
266266
267267
268268class AnnouncementAdmin (CustomTimeMixin , PostAdmin ):
269- list_display = ["__str__" , "organization" , "status" ]
269+ list_display = ["__str__" , "organization" , "organization_string" , " status" ]
270270 list_filter = [OrganizationListFilter , "status" ]
271271 ordering = ["-show_after" ]
272272 actions = [resend_approval_email ]
@@ -302,7 +302,7 @@ def get_readonly_fields(self, request, obj=None):
302302
303303 all_fields = [
304304 "organization" ,
305- "author " ,
305+ "organization_stringauthor " ,
306306 "title" ,
307307 "body" ,
308308 "tags" ,
@@ -319,6 +319,7 @@ def get_readonly_fields(self, request, obj=None):
319319 {
320320 "author" ,
321321 "organization" ,
322+ "organization_string" ,
322323 "title" ,
323324 "tags" ,
324325 "is_public" ,
@@ -327,6 +328,7 @@ def get_readonly_fields(self, request, obj=None):
327328 {
328329 "author" ,
329330 "organization" ,
331+ "organization_string" ,
330332 "title" ,
331333 "tags" ,
332334 "is_public" ,
@@ -335,6 +337,7 @@ def get_readonly_fields(self, request, obj=None):
335337 {
336338 "author" ,
337339 "organization" ,
340+ "organization_string" ,
338341 "title" ,
339342 "body" ,
340343 "tags" ,
@@ -346,6 +349,7 @@ def get_readonly_fields(self, request, obj=None):
346349 {
347350 "author" ,
348351 "organization" ,
352+ "organization_string" ,
349353 "title" ,
350354 "body" ,
351355 "tags" ,
@@ -356,18 +360,26 @@ def get_readonly_fields(self, request, obj=None):
356360 },
357361 ],
358362 [
359- {"author" , "organization" , "supervisor" },
360- {"author" , "organization" , "status" , "supervisor" },
363+ {"author" , "organization" , "organization_string" , "supervisor" },
364+ {
365+ "author" ,
366+ "organization" ,
367+ "organization_string" ,
368+ "status" ,
369+ "supervisor" ,
370+ },
361371 {
362372 "author" ,
363373 "organization" ,
374+ "organization_string" ,
364375 "status" ,
365376 "show_after" ,
366377 "supervisor" ,
367378 },
368379 {
369380 "author" ,
370381 "organization" ,
382+ "organization_string" ,
371383 "status" ,
372384 "supervisor" ,
373385 "rejection_reason" ,
@@ -389,6 +401,7 @@ def get_readonly_fields(self, request, obj=None):
389401 def get_fields (self , request , obj = None ):
390402 all_fields = [
391403 "organization" ,
404+ "organization_string" ,
392405 "author" ,
393406 "title" ,
394407 "body" ,
@@ -424,6 +437,7 @@ def get_exclude(self, request, obj=None):
424437 "body" ,
425438 "tags" ,
426439 "organization" ,
440+ "organization_string" ,
427441 "is_public" ,
428442 "supervisor" ,
429443 "status" ,
0 commit comments