42 lines
996 B
Python
42 lines
996 B
Python
"""Админские классы Django для управления моделями резюме."""
|
|
|
|
from django.contrib import admin
|
|
|
|
from .models import Experience, Profile, SkillGroup
|
|
|
|
|
|
@admin.register(Profile)
|
|
class ProfileAdmin(admin.ModelAdmin):
|
|
"""Админка для модели профиля."""
|
|
|
|
list_display = ("role", "full_name", "gender")
|
|
list_display_links = (
|
|
"full_name",
|
|
"role",
|
|
)
|
|
|
|
|
|
@admin.register(Experience)
|
|
class ExperienceAdmin(admin.ModelAdmin):
|
|
"""Админка для модели опыта работы."""
|
|
|
|
list_display = ("profile", "company", "start_date", "end_date")
|
|
list_display_links = (
|
|
"profile",
|
|
"company",
|
|
)
|
|
|
|
|
|
@admin.register(SkillGroup)
|
|
class SkillGroupAdmin(admin.ModelAdmin):
|
|
"""Админка для модели групп навыков."""
|
|
|
|
list_display = (
|
|
"profile",
|
|
"group",
|
|
)
|
|
list_display_links = (
|
|
"profile",
|
|
"group",
|
|
)
|