Skip to content

Commit

Permalink
"Added SystemHealth model to admin panel with list display, filtering…
Browse files Browse the repository at this point in the history
…, and search fields"
  • Loading branch information
NexusGKSoftwares committed Dec 1, 2024
1 parent 80073cc commit ccea5f2
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion admin_panel/admin.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
from django.contrib import admin
from .models import SystemHealth

# Register your models here.
@admin.register(SystemHealth)
class SystemHealthAdmin(admin.ModelAdmin):
list_display = ('timestamp', 'cpu_usage', 'memory_usage', 'disk_space')
list_filter = ('timestamp',)
search_fields = ('timestamp',)

0 comments on commit ccea5f2

Please sign in to comment.