admin fayllari to'g'irlandi
This commit is contained in:
@@ -5,8 +5,46 @@ from core.apps.evaluation.models import EvaluationReportModel
|
||||
|
||||
|
||||
@admin.register(EvaluationReportModel)
|
||||
class EvaluationreportAdmin(ModelAdmin):
|
||||
class EvaluationReportAdmin(ModelAdmin):
|
||||
list_display = (
|
||||
"id",
|
||||
"__str__",
|
||||
"report_number",
|
||||
"valuation",
|
||||
"evaluator",
|
||||
"final_value",
|
||||
"approved_at",
|
||||
"created_at",
|
||||
)
|
||||
list_filter = ("approved_at",)
|
||||
search_fields = (
|
||||
"report_number",
|
||||
"valuation__conclusion_number",
|
||||
"evaluator__phone",
|
||||
"evaluator__first_name",
|
||||
"conclusion_text",
|
||||
)
|
||||
readonly_fields = ("created_at", "updated_at")
|
||||
raw_id_fields = ("valuation", "evaluator")
|
||||
fieldsets = (
|
||||
("Hisobot", {
|
||||
"fields": (
|
||||
"report_number",
|
||||
"valuation",
|
||||
"evaluator",
|
||||
),
|
||||
}),
|
||||
("Natija", {
|
||||
"fields": (
|
||||
"final_value",
|
||||
"conclusion_text",
|
||||
"report_file",
|
||||
),
|
||||
}),
|
||||
("Tasdiqlash", {
|
||||
"fields": ("approved_at",),
|
||||
}),
|
||||
("Tizim", {
|
||||
"classes": ("collapse",),
|
||||
"fields": ("created_at", "updated_at"),
|
||||
}),
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user