Commits

George Notaras  committed 89df8a2

The ``date_modified`` field is no longer visible in the InlineAdmins.

  • Participants
  • Parent commits 41a223e

Comments (0)

Files changed (1)

File src/powerdns_manager/admin.py

 
 class DynamicZoneInline(admin.StackedInline):
     model = cache.get_model('powerdns_manager', 'DynamicZone')
-    fields = ('is_dynamic', 'api_key', 'date_modified')
-    readonly_fields = ('api_key', 'date_modified')
+    fields = ('is_dynamic', 'api_key')
+    readonly_fields = ('api_key', )
     search_fields = ('domain', )
     verbose_name = 'Dynamic Zone'
     verbose_name_plural = 'Dynamic Zone'    # Only one dynamic zone per domain
     form = '__OVERRIDE__'
     model = cache.get_model('powerdns_manager', 'Record')
     extra = 0
-    fields = ('name', 'ttl', 'content', 'date_modified')
-    readonly_fields = ('date_modified', )
+    fields = ('name', 'ttl', 'content')
     
     def __init__(self, *args, **kwargs):
         self.verbose_name = '%s Resource Record' % self.RR_TYPE
     verbose_name_plural = 'SOA Resource Record' # Only one SOA RR per zone
     # The ``name`` field is not available for editing. It is always set to the
     # name of the domain in ``forms.SoaRecordModelForm.save()`` method.
-    fields = ('ttl', 'primary', 'hostmaster', 'serial', 'refresh', 'retry', 'expire', 'default_ttl', 'date_modified')
-    readonly_fields = ('date_modified', )
+    fields = ('ttl', 'primary', 'hostmaster', 'serial', 'refresh', 'retry', 'expire', 'default_ttl')
     can_delete = False
     
     def queryset(self, request):
 class MxRecordInline(BaseTabularRecordInline):
     RR_TYPE = 'MX'
     form = MxRecordModelForm
-    fields = ('name', 'ttl', 'prio', 'content', 'date_modified')
+    fields = ('name', 'ttl', 'prio', 'content')
     
 class SrvRecordInline(BaseTabularRecordInline):
     RR_TYPE = 'SRV'
     form = SrvRecordModelForm
-    fields = ('name', 'ttl', 'prio', 'weight', 'port', 'target', 'date_modified')
+    fields = ('name', 'ttl', 'prio', 'weight', 'port', 'target')
 
 class ARecordInline(BaseTabularRecordInline):
     RR_TYPE = 'A'
     extra = 0
     verbose_name = 'Empty Non-Terminal Resource Record'
     verbose_name_plural = 'Empty Non-Terminal Resource Record' # Only one SOA RR per zone
-    fields = ('name', 'ttl', 'content', 'date_modified')
-    readonly_fields = ('name', 'ttl', 'content', 'date_modified')
+    fields = ('name', 'ttl', 'content')
+    readonly_fields = ('name', 'ttl', 'content')
     can_delete = False
     
     def queryset(self, request):
 
 class DomainMetadataInline(admin.TabularInline):
     model = cache.get_model('powerdns_manager', 'DomainMetadata')
-    fields = ('kind', 'content', 'date_modified')
-    readonly_fields = ('date_modified', )
+    fields = ('kind', 'content', )
     extra = 0
     verbose_name_plural = 'Domain Metadata'
 
     
 class CryptoKeyInline(admin.TabularInline):
     model = cache.get_model('powerdns_manager', 'CryptoKey')
-    fields = ('flags', 'active', 'content', 'date_modified')
-    readonly_fields = ('date_modified', )
+    fields = ('flags', 'active', 'content')
     extra = 0
     verbose_name_plural = 'Crypto Keys'
 
     #form = DomainModelForm
     #actions = [test_action, ]
     
-    fields = ('name', 'type', 'master', 'date_modified')
+    fields = ('date_modified', 'name', 'type', 'master')
     readonly_fields = ('date_modified', )
     list_display = ('name', 'export_zone_html_link', 'type', 'master', 'date_modified')
     list_filter = ('type', )