from django.contrib import admin
from .models import *
# Register your models here.

@admin.register(Categories)
class CategoriesAdmin(admin.ModelAdmin):
    list_display = ['title']

@admin.register(SubCate)
class SubCategoryAdmin(admin.ModelAdmin):
    list_display = ['id','name', 'category']

@admin.register(Product)
class ProductAdmin(admin.ModelAdmin):
    list_display = [
        "title",
        "selling_price",
        "discount",
        "description",
        "categories",
        "product_image",
    ]

@admin.register(Customer)
class CustomerAdmin(admin.ModelAdmin):
    list_display = [
        'user',
        'name',
        'locality',
        'city',
        'mobile',
        'zipcode',
        'state',
    ]

@admin.register(Cart)
class CartAdmin(admin.ModelAdmin):
    list_display = [
        'id',
        'user',
        'product',
        'quantity',
        'total_cost'
    ]

# @admin.register(Payment)
# class PaymentAdmin(admin.ModelAdmin):
#     list_display = [
#         'id',
#         "user",
#         "amount",
#         "order_id",
#         "payment_Status",
#         "payment_id",
#         "paid",
#     ]

@admin.register(OrderPlaced)
class OrderPlacedAdmin(admin.ModelAdmin):
    list_display = [
        'id',
        "user",
        "customer",
        "product",
        "quantity",
        "ordered_date",
        "status",
        "payment",
        "amount",  
        'total_cost'
    ]

@admin.register(WishList)
class WishListAdmin(admin.ModelAdmin):
    list_display = [
        "id",
        "user",
        "product",
    ]
    
    