admin fayllari to'g'irlandi
This commit is contained in:
@@ -5,8 +5,56 @@ from core.apps.evaluation.models import RealEstateEvaluationModel
|
||||
|
||||
|
||||
@admin.register(RealEstateEvaluationModel)
|
||||
class RealestateevaluationAdmin(ModelAdmin):
|
||||
class RealEstateEvaluationAdmin(ModelAdmin):
|
||||
list_display = (
|
||||
"id",
|
||||
"__str__",
|
||||
"valuation",
|
||||
"property_type",
|
||||
"address",
|
||||
"total_area",
|
||||
"floor",
|
||||
"build_year",
|
||||
"condition",
|
||||
)
|
||||
list_filter = (
|
||||
"property_type",
|
||||
"condition",
|
||||
"has_renovation",
|
||||
)
|
||||
search_fields = (
|
||||
"address",
|
||||
"cadastral_number",
|
||||
"valuation__conclusion_number",
|
||||
)
|
||||
readonly_fields = ("created_at", "updated_at")
|
||||
raw_id_fields = ("valuation",)
|
||||
fieldsets = (
|
||||
("Ariza", {
|
||||
"fields": ("valuation",),
|
||||
}),
|
||||
("Mulk ma'lumotlari", {
|
||||
"fields": (
|
||||
"property_type",
|
||||
"address",
|
||||
"cadastral_number",
|
||||
),
|
||||
}),
|
||||
("Texnik parametrlar", {
|
||||
"fields": (
|
||||
("total_area", "living_area"),
|
||||
("floor", "total_floors"),
|
||||
"rooms_count",
|
||||
"build_year",
|
||||
),
|
||||
}),
|
||||
("Holat", {
|
||||
"fields": (
|
||||
"condition",
|
||||
"has_renovation",
|
||||
),
|
||||
}),
|
||||
("Tizim", {
|
||||
"classes": ("collapse",),
|
||||
"fields": ("created_at", "updated_at"),
|
||||
}),
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user