>> a.get_status_display()
-->: models.CustomerInfo._meta.fields 获取model所有字段对象
>> models.CustomerInfo._meta.get_field(‘status‘) 取一个字段的对象
-->: <django.db.models.fields.SmallIntergerField:status>
a = admin_class.model._meta.get_field(‘name‘)
a.choices #取choices属性
原文:https://www.cnblogs.com/lovelygang/p/9567296.html