Display settings with hacky solution to retain order

Python utility included to convert config-base.json into a new version
which includes lists that define the order settings should be displayed.
admin.js edited to recognize this.
This commit is contained in:
Harvey Tindall
2020-07-31 16:09:30 +01:00
parent ef4f2503c9
commit 024c0b56aa
9 changed files with 811 additions and 20 deletions
+94 -1
View File
@@ -1,5 +1,27 @@
{
"order": [
"jellyfin",
"ui",
"password_validation",
"email",
"password_resets",
"invite_emails",
"notifications",
"mailgun",
"smtp",
"files"
],
"jellyfin": {
"order": [
"username",
"password",
"server",
"public_server",
"client",
"version",
"device",
"device_id"
],
"meta": {
"name": "Jellyfin",
"description": "Settings for connecting to Jellyfin"
@@ -66,6 +88,21 @@
}
},
"ui": {
"order": [
"theme",
"host",
"port",
"jellyfin_login",
"admin_only",
"username",
"password",
"email",
"debug",
"contact_message",
"help_message",
"success_message",
"bs5"
],
"meta": {
"name": "General",
"description": "Settings related to the UI and program functionality."
@@ -183,6 +220,14 @@
}
},
"password_validation": {
"order": [
"enabled",
"min_length",
"upper",
"lower",
"number",
"special"
],
"meta": {
"name": "Password Validation",
"description": "Password validation (minimum length, etc.)"
@@ -231,6 +276,15 @@
}
},
"email": {
"order": [
"no_username",
"use_24h",
"date_format",
"message",
"method",
"address",
"from"
],
"meta": {
"name": "Email",
"description": "General email settings. Ignore if not using email features."
@@ -302,6 +356,13 @@
}
},
"password_resets": {
"order": [
"enabled",
"watch_directory",
"email_html",
"email_text",
"subject"
],
"meta": {
"name": "Password Resets",
"description": "Settings for the password reset handler."
@@ -352,6 +413,13 @@
}
},
"invite_emails": {
"order": [
"enabled",
"email_html",
"email_text",
"subject",
"url_base"
],
"meta": {
"name": "Invite emails",
"description": "Settings for sending invites directly to users."
@@ -401,6 +469,13 @@
}
},
"notifications": {
"order": [
"enabled",
"expiry_html",
"expiry_text",
"created_html",
"created_text"
],
"meta": {
"name": "Notifications",
"description": "Notification related settings."
@@ -451,6 +526,10 @@
}
},
"mailgun": {
"order": [
"api_url",
"api_key"
],
"meta": {
"name": "Mailgun (Email)",
"description": "Mailgun API connection settings"
@@ -471,6 +550,12 @@
}
},
"smtp": {
"order": [
"encryption",
"server",
"port",
"password"
],
"meta": {
"name": "SMTP (Email)",
"description": "SMTP Server connection settings."
@@ -511,6 +596,14 @@
}
},
"files": {
"order": [
"invites",
"emails",
"user_template",
"user_configuration",
"user_displayprefs",
"custom_css"
],
"meta": {
"name": "File Storage",
"description": "Optional settings for changing storage locations."
@@ -564,4 +657,4 @@
"description": "Location of custom bootstrap CSS."
}
}
}
}