mirror of
https://github.com/nikdoof/test-auth.git
synced 2025-12-13 22:32:15 +00:00
Switch to readonly fields for some views, stop the app lagging
This commit is contained in:
@@ -15,8 +15,7 @@ account_api_update.short_description = "Update account from the EVE API"
|
||||
class EVEAccountAdmin(admin.ModelAdmin):
|
||||
list_display = ('id', 'user', 'api_keytype', 'api_status', 'api_last_updated')
|
||||
search_fields = ['id', 'user__username']
|
||||
readonly_fields = ('api_keytype', 'api_user_id', 'api_key', 'api_status', 'characters', 'api_last_updated')
|
||||
filter_horizontal = ('characters',)
|
||||
readonly_fields = ('api_keytype', 'api_user_id', 'api_key', 'api_status', 'characters', 'api_last_updated', 'characters')
|
||||
|
||||
actions = [account_api_update]
|
||||
|
||||
|
||||
@@ -13,7 +13,7 @@ class SSOGroupInformationInline(admin.StackedInline):
|
||||
fk_name = 'group'
|
||||
max_num = 1
|
||||
|
||||
filter_horizontal = ('admins',)
|
||||
readonly_fields = ('admins',)
|
||||
|
||||
# Define a new UserAdmin class
|
||||
class SSOGroupAdmin(GroupAdmin):
|
||||
|
||||
Reference in New Issue
Block a user