Fixed an issue where unexpected error messages are displayed when users change the language via preferences. Fixes #7267

This commit is contained in:
Nikhil Mohite
2022-03-24 16:08:13 +05:30
committed by Akshay Joshi
parent 473afd950c
commit 0b4a874f30
6 changed files with 27 additions and 8 deletions

View File

@@ -49,7 +49,13 @@ export default class BinaryPathSchema extends BaseUISchema {
},
{
id: 'binaryPath', label: gettext('Binary Path'), cell: 'file', type: 'file',
isvalidate: true, controlProps: { dialogType: 'select_folder', supportedTypes: ['*', 'sql', 'backup'], dialogTitle: 'Select folder' },
isvalidate: true,
controlProps: {
dialogType: 'select_folder',
supportedTypes: ['*', 'sql', 'backup'],
dialogTitle: gettext('Select folder'),
placeholder: pgAdmin.server_mode == 'False' ? gettext('Select binary path...') : gettext('Enter binary path...')
},
hideBrowseButton: pgAdmin.server_mode == 'True',
validate: (data) => {
const api = getApiInstance();