AL
├───api
│ ├───v1
│ │ └───__pycache__
│ └───__pycache__
├───migrations
│ └───__pycache__
├───tests
│ ├───selectors
│ │ └───__pycache__
│ ├───services
│ │ └───__pycache__
│ ├───views
│ └───__pycache__
└───__pycache__
Size: a a a
AL
AS
@admin.register(Post)
class PostAdminModel(admin.ModelAdmin):
...
list_display = ('title', 'slug', 'created', 'user_name', 'likes_count')
... def likes_count(self, obj):
return obj.likes.count()
AS
A
@admin.register(Post)
class PostAdminModel(admin.ModelAdmin):
...
list_display = ('title', 'slug', 'created', 'user_name', 'likes_count')
... def likes_count(self, obj):
return obj.likes.count()
•
•
S
•
СА
NC
СА
NC
ИМ
Y
ИМ
NC
СА
NC
Y
Y