mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2025-04-02 13:45:10 -05:00
Remove display_name property
This commit is contained in:
parent
c73688d167
commit
d15c701510
@ -1,7 +1,6 @@
|
||||
{
|
||||
"user_id": 1,
|
||||
"username": "admin",
|
||||
"display_name": "Admin",
|
||||
"settings": {
|
||||
"language": "",
|
||||
"bulk_edit": {
|
||||
|
@ -1,7 +1,6 @@
|
||||
{
|
||||
"user_id": 1,
|
||||
"username": "admin",
|
||||
"display_name": "Admin",
|
||||
"settings": {
|
||||
"language": "",
|
||||
"bulk_edit": {
|
||||
|
@ -1,7 +1,6 @@
|
||||
export interface PaperlessUiSettings {
|
||||
user_id: number
|
||||
username: string
|
||||
display_name: string
|
||||
settings: Object
|
||||
permissions: string[]
|
||||
}
|
||||
|
@ -872,9 +872,6 @@ class UiSettingsView(GenericAPIView):
|
||||
serializer.is_valid(raise_exception=True)
|
||||
|
||||
user = User.objects.get(pk=request.user.id)
|
||||
displayname = user.username
|
||||
if user.first_name or user.last_name:
|
||||
displayname = " ".join([user.first_name, user.last_name])
|
||||
ui_settings = {}
|
||||
if hasattr(user, "ui_settings"):
|
||||
ui_settings = user.ui_settings.settings
|
||||
@ -891,7 +888,6 @@ class UiSettingsView(GenericAPIView):
|
||||
{
|
||||
"user_id": user.id,
|
||||
"username": user.username,
|
||||
"display_name": displayname,
|
||||
"settings": ui_settings,
|
||||
"permissions": roles,
|
||||
},
|
||||
|
Loading…
x
Reference in New Issue
Block a user