From 64004e70d1f365c540607a1869aca871f9eba99a Mon Sep 17 00:00:00 2001 From: "Gleb O. Ivaniczkij" Date: Sun, 22 Sep 2024 18:01:28 +0300 Subject: [PATCH] =?UTF-8?q?=D0=9F=D1=80=D0=BE=D1=80=D0=B0=D0=B1=D0=BE?= =?UTF-8?q?=D1=82=D0=B0=D0=BD=D1=8B=20=D0=BF=D0=BE=D0=BB=D1=8F=20=D0=B4?= =?UTF-8?q?=D0=BB=D1=8F=20=D0=BE=D1=82=D0=BE=D0=B1=D1=80=D0=B0=D0=B6=D0=B5?= =?UTF-8?q?=D0=BD=D0=B8=D1=8F,=20=D1=81=D0=BE=D1=80=D1=82=D0=B8=D1=80?= =?UTF-8?q?=D0=BE=D0=B2=D0=BA=D0=B8=20=D0=B8=20=D0=BF=D0=BE=D0=B8=D1=81?= =?UTF-8?q?=D0=BA=D0=B0=20=D0=B2=20=D0=BF=D0=B0=D0=BD=D0=B5=D0=BB=D0=B8=20?= =?UTF-8?q?=D0=B0=D0=B4=D0=BC=D0=B8=D0=BD=D0=B8=D1=81=D1=82=D1=80=D0=B0?= =?UTF-8?q?=D1=82=D0=BE=D1=80=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/admin.py | 44 +++++++++++++++++++++++++++++++++++++++++--- 1 file changed, 41 insertions(+), 3 deletions(-) diff --git a/app/admin.py b/app/admin.py index 993d323..db33366 100644 --- a/app/admin.py +++ b/app/admin.py @@ -6,14 +6,52 @@ from .models import Room, RoomImage, RoomPanorama @admin.register(Room) class ModelNameAdmin(ModelAdmin): - pass + list_display = [ + 'id', + 'name', + 'area', + 'price', + 'is_visible', + 'is_available', + ] + list_filter = [ + 'id', + 'name', + 'area', + 'price', + 'is_visible', + 'is_available', + ] + search_fields = [ + 'name', + ] @admin.register(RoomImage) class ModelNameAdmin(ModelAdmin): - pass + list_display = [ + 'id', + 'name', + ] + list_filter = [ + 'id', + 'name', + ] + search_fields = [ + 'name', + ] @admin.register(RoomPanorama) class ModelNameAdmin(ModelAdmin): - pass + list_display = [ + 'id', + 'name', + ] + list_filter = [ + 'id', + 'name', + ] + search_fields = [ + 'name', + ]