HiPhone_BE/graph/admin.py

13 lines
333 B
Python

from django.contrib import admin
from .models import Transaction, MonthlyTransaction
admin.site.register(Transaction)
@admin.register(MonthlyTransaction)
class MonthlyTransactionAdmin(admin.ModelAdmin):
list_display = ("product", "year", "month", "price")
list_filter = ("year", "month")
search_fields = ("product",)