from django.contrib import admin
from .models import Product, Category


class ProductAdmin(admin.ModelAdmin):
    exclude = ['addded']
    prepopulated_fields = {'slug': ('title',)}


class CategoryAdmin(admin.ModelAdmin):
    prepopulated_fields = {'slug': ('title',)}


admin.site.register(Product, ProductAdmin)
admin.site.register(Category, CategoryAdmin)

31f08e5f71bd25f09eafb705061dada872f0a075
<mask token>


class ProductAdmin(admin.ModelAdmin):
    <mask token>
    <mask token>


class CategoryAdmin(admin.ModelAdmin):
    prepopulated_fields = {'slug': ('title',)}


<mask token>

<mask token>


class ProductAdmin(admin.ModelAdmin):
    exclude = ['addded']
    prepopulated_fields = {'slug': ('title',)}


class CategoryAdmin(admin.ModelAdmin):
    prepopulated_fields = {'slug': ('title',)}


<mask token>

<mask token>


class ProductAdmin(admin.ModelAdmin):
    exclude = ['addded']
    prepopulated_fields = {'slug': ('title',)}


class CategoryAdmin(admin.ModelAdmin):
    prepopulated_fields = {'slug': ('title',)}


admin.site.register(Product, ProductAdmin)
admin.site.register(Category, CategoryAdmin)

from django.contrib import admin
from .models import Product, Category


class ProductAdmin(admin.ModelAdmin):
    exclude = ['addded']
    prepopulated_fields = {'slug': ('title',)}


class CategoryAdmin(admin.ModelAdmin):
    prepopulated_fields = {'slug': ('title',)}


admin.site.register(Product, ProductAdmin)
admin.site.register(Category, CategoryAdmin)
