Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
ビューから list_display や list_filter などのクラス変数の値を取得したいと思います。何かのようなもの:
def some_view(): print Order.list_display ...
では、モデルインスタンスから関連するModelAdminオブジェクトにアクセスしたいですか?これはどう:
from django.contrib import admin print admin.site._registry[Order].list_display