From 5c71d22215dd274353e6f24789ff5695e0f6c709 Mon Sep 17 00:00:00 2001 From: djmaze <> Date: Tue, 28 Dec 2021 15:05:03 +0100 Subject: [PATCH] Admin -> Config application.ini passwords as input password --- dev/Settings/Admin/Config.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dev/Settings/Admin/Config.js b/dev/Settings/Admin/Config.js index cff8e4a28..eaf1b4efc 100644 --- a/dev/Settings/Admin/Config.js +++ b/dev/Settings/Admin/Config.js @@ -12,13 +12,13 @@ export class ConfigAdminSettings /*extends AbstractViewSettings*/ { Remote.request('AdminSettingsGet', (iError, data) => { if (!iError) { const cfg = [], - getInputType = value => { + getInputType = (value, pass) => { switch (typeof value) { case 'boolean': return 'checkbox'; case 'number': return 'number'; } - return 'text'; + return pass ? 'password' : 'text'; }; Object.entries(data.Result).forEach(([key, items]) => { const section = { @@ -30,7 +30,7 @@ export class ConfigAdminSettings /*extends AbstractViewSettings*/ { key: `config[${key}][${skey}]`, name: skey, value: item[0], - type: getInputType(item[0]), + type: getInputType(item[0], skey.includes('password')), comment: item[1] }); });