Skip to content

Commit

Permalink
add support for minutes
Browse files Browse the repository at this point in the history
see #617

TODO now it is not possible to select the related sittings from the minute.
this seems a problem due to how django treats many-to-one relations (and
their admin interfaces)
  • Loading branch information
fspegni committed Feb 17, 2016
1 parent b40d5c2 commit 557b20d
Show file tree
Hide file tree
Showing 10 changed files with 1,027 additions and 142 deletions.
10 changes: 9 additions & 1 deletion open_municipio/acts/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,6 @@ class ActInSpeechInline(admin.TabularInline):
raw_id_fields = ('act', )



class SpeechAdmin(admin.ModelAdmin):

form = SpeechAdminForm
Expand All @@ -301,6 +300,7 @@ class SpeechAdmin(admin.ModelAdmin):

list_filter = ( SpeechByYearFilterSpec, SpeechByMonthFilterSpec, )


class AttachAdmin(admin.ModelAdmin):

list_display = ('title','document_date','document_type','act_title','act_type')
Expand Down Expand Up @@ -462,6 +462,12 @@ def recipients(self, obj):
return ",".join(names)
recipients.short_description = _("recipients")


class MinuteAdmin(ActAdmin):

pass


admin.site.register(Act, ActAdmin)

# The following two lines restore the default admin for the class Act
Expand All @@ -485,3 +491,5 @@ def recipients(self, obj):
admin.site.register(Decision, DecisionAdmin)
admin.site.register(Commitment, CommitmentAdmin)
admin.site.register(Audit, AuditAdmin)

admin.site.register(Minute, MinuteAdmin)
Binary file modified open_municipio/acts/locale/it/LC_MESSAGES/django.mo
Binary file not shown.

0 comments on commit 557b20d

Please sign in to comment.