Fixed issue where 'Identity file' control of SSH Tunnel tab is enabled when database is connected and 'Use SSH tunneling' flag is set to No.

pull/17/head
Akshay Joshi 2018-05-17 17:18:00 +05:30
parent a7ee85619d
commit 719938a14c
1 changed files with 2 additions and 2 deletions

View File

@ -847,12 +847,12 @@ define('pgadmin.node.server', [
control: Backform.FileControl, dialog_type: 'select_file', supp_types: ['*'],
deps: ['tunnel_authentication', 'use_ssh_tunnel'],
disabled: function(model) {
if (!model.get('tunnel_authentication') || !model.get('use_ssh_tunnel')) {
if (!model.get('tunnel_authentication')) {
setTimeout(function() {
model.set('tunnel_identity_file', '');
}, 10);
}
return !model.get('tunnel_authentication');
return !model.get('tunnel_authentication') || !model.get('use_ssh_tunnel');
},
},{
id: 'tunnel_identity_file', label: gettext('Identity file'), type: 'text',