diff --git a/web/pgadmin/tools/restore/__init__.py b/web/pgadmin/tools/restore/__init__.py index 393639bde..c27e4a624 100644 --- a/web/pgadmin/tools/restore/__init__.py +++ b/web/pgadmin/tools/restore/__init__.py @@ -303,11 +303,11 @@ def create_restore_job(sid): set_param('verbose', '--verbose') set_multiple('schemas', '--schema', False) - set_multiple('tables', '--table') - set_multiple('functions', '--function') - set_multiple('triggers', '--trigger') - set_multiple('trigger_funcs', '--function') - set_multiple('indexes', '--index') + set_multiple('tables', '--table', False) + set_multiple('functions', '--function', False) + set_multiple('triggers', '--trigger', False) + set_multiple('trigger_funcs', '--function', False) + set_multiple('indexes', '--index', False) args.append(fs_short_path(_file)) diff --git a/web/pgadmin/tools/restore/templates/restore/js/restore.js b/web/pgadmin/tools/restore/templates/restore/js/restore.js index b76927c08..df3e1935a 100644 --- a/web/pgadmin/tools/restore/templates/restore/js/restore.js +++ b/web/pgadmin/tools/restore/templates/restore/js/restore.js @@ -484,22 +484,27 @@ define([ if (!m.get('custom')) { switch (d._type) { case 'schema': - m.set('schemas', d._label); + m.set('schemas', [d._label]); break; case 'table': - m.set('tables', [info.schema._label, d._label]); + m.set('schemas', [info.schema._label]); + m.set('tables', [d._label]); break; case 'function': - m.set('functions', [info.schema._label, d._label]); + m.set('schemas', [info.schema._label]); + m.set('functions', [d._label]); break; case 'index': - m.set('indexes', [info.schema._label, d._label]); + m.set('schemas', [info.schema._label]); + m.set('indexes', [d._label]); break; case 'trigger': - m.set('triggers', [info.schema._label, d._label]); + m.set('schemas', [info.schema._label]); + m.set('triggers', [d._label]); break; case 'trigger_func': - m.set('trigger_funcs', [info.schema._label, d._label]); + m.set('schemas', [info.schema._label]); + m.set('trigger_funcs', [d._label]); break; } } else {