Re: [pgAdmin][RM7031]: Database definition wrong

2021-12-02 Thread Pradip Parkale
Hi Akshay/Aditya,

Please find the updated patch.

On Wed, Dec 1, 2021 at 5:56 PM Aditya Toshniwal <
aditya.toshni...@enterprisedb.com> wrote:

> Hi Pradip,
>
> You did not include the server_old table for query_history.
>
Fixed.

> Please also remove the commented code:
> +# db.engine.execute("PRAGMA foreign_keys=ON")
> +
> +# db.session.commit()
> +
> +# db.engine.execute("PRAGMA foreign_keys=ON")
> +
>
Fixed.

>
>
>
> On Wed, Dec 1, 2021 at 5:25 PM Akshay Joshi 
> wrote:
>
>> Thanks, the patch applied.
>>
>> On Wed, Dec 1, 2021 at 4:23 PM Pradip Parkale <
>> pradip.park...@enterprisedb.com> wrote:
>>
>>> Hi Hackers,
>>>
>>> Please find the attached for #7031 Database definition wrong.
>>>
>>> --
>>> Thanks & Regards,
>>> Pradip Parkale
>>> Software Engineer | EnterpriseDB Corporation
>>>
>>
>>
>> --
>> *Thanks & Regards*
>> *Akshay Joshi*
>> *pgAdmin Hacker | Principal Software Architect*
>> *EDB Postgres *
>>
>> *Mobile: +91 976-788-8246*
>>
>
>
> --
> Thanks,
> Aditya Toshniwal
> pgAdmin Hacker | Software Architect | *edbpostgres.com*
> 
> "Don't Complain about Heat, Plant a TREE"
>


-- 
Thanks & Regards,
Pradip Parkale
Software Engineer | EnterpriseDB Corporation


RM7031_v2.patch
Description: Binary data


pgAdmin 4 commit: Change the logic to rename the table in the SQLite da

2021-12-02 Thread Akshay Joshi
Change the logic to rename the table in the SQLite database to fix the 
migration issue.

refs #7031

Branch
--
master

Details
---
https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=fe096116be1b36f57665b34672f238e112a72d92
Author: Pradip Parkale 

Modified Files
--
web/migrations/versions/09d53fca90c7_.py | 12 ++--
web/migrations/versions/35f29b1701bd_.py |  6 --
web/migrations/versions/3ce25f562f3b_.py | 11 +--
web/migrations/versions/50aad68f99c2_.py |  7 +--
web/migrations/versions/7c56ea250085_.py |  7 +--
web/migrations/versions/a39bd015b644_.py |  9 +++--
web/migrations/versions/a77a0932a568_.py |  6 --
7 files changed, 40 insertions(+), 18 deletions(-)



pgAdmin 4 commit: Replaced alertifyjs notifiers with React-based notist

2021-12-02 Thread Akshay Joshi
Replaced alertifyjs notifiers with React-based notistack. Fixes #7004

Branch
--
master

Details
---
https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=c6424e3897a3476a0cd7563b20ab1c5f4b79e70b

Modified Files
--
docs/en_US/release_notes_6_3.rst   |   1 +
web/package.json   |   1 +
.../static/js/compound_trigger.js  |  15 +-
.../check_constraint/static/js/check_constraint.js |   9 +-
.../foreign_key/static/js/foreign_key.js   |  10 +-
.../tables/partitions/static/js/partition.js   |  17 +-
.../schemas/tables/rules/static/js/rule.js |  14 +-
.../tables/static/js/enable_disable_triggers.js|  14 +-
.../databases/schemas/tables/static/js/table.js|  19 +-
.../schemas/tables/triggers/static/js/trigger.js   |  15 +-
.../databases/schemas/views/static/js/mview.js |   5 +-
.../servers/databases/static/js/database.js|  15 +-
.../servers/pgagent/static/js/pga_job.js   |   7 +-
.../server_groups/servers/roles/static/js/role.js  |   3 +-
.../server_groups/servers/static/js/server.js  |  63 +++---
.../servers/tablespaces/static/js/tablespace.js|   7 +-
web/pgadmin/browser/static/js/browser.js   |  11 +-
web/pgadmin/browser/static/js/collection.js|   5 +-
web/pgadmin/browser/static/js/layout.js|   6 +-
web/pgadmin/browser/static/js/node.js  |  15 +-
web/pgadmin/browser/static/js/preferences.js   |   8 +-
web/pgadmin/browser/static/js/runtime.js   |   4 +-
web/pgadmin/dashboard/static/js/dashboard.js   |  20 +-
.../misc/dependencies/static/js/dependencies.js|   6 +-
.../misc/dependents/static/js/dependents.js|   4 +-
.../misc/file_manager/static/js/create_dialogue.js |   5 +-
web/pgadmin/misc/file_manager/static/js/utility.js |  36 ++--
web/pgadmin/misc/sql/static/js/sql.js  |   4 +-
.../misc/statistics/static/js/statistics.js|   4 +-
web/pgadmin/static/js/SchemaView/DepListener.js|   8 +
web/pgadmin/static/js/alertify.pgadmin.defaults.js | 238 -
web/pgadmin/static/js/backgrid.pgadmin.js  |   4 +-
.../static/js/components/FormComponents.jsx|  59 +++--
web/pgadmin/static/js/components/GrantWizard.jsx   |   7 +-
.../js/helpers/DataGridViewWithHeaderForm.jsx  |   9 +
web/pgadmin/static/js/helpers/Notifier.jsx | 181 
web/pgadmin/static/js/helpers/wizard/Wizard.jsx|   8 +
.../static/js/helpers/wizard/WizardStep.jsx|   9 +
web/pgadmin/static/js/slickgrid/editors.js |   6 +-
.../static/js/sqleditor/call_render_after_poll.js  |   6 +-
web/pgadmin/static/js/sqleditor/filter_dialog.js   |   5 +-
web/pgadmin/static/js/sqleditor/macro.js   |   5 +-
.../static/js/sqleditor/new_connection_dialog.js   |   3 +-
.../js/sqleditor/new_connection_dialog_model.js|   3 +-
.../js/sqleditor/query_tool_notifications.js   |   4 +-
web/pgadmin/templates/base.html|   1 +
web/pgadmin/tools/debugger/static/js/direct.js |  14 +-
.../tools/import_export/static/js/import_export.js |   4 +-
.../tools/maintenance/static/js/maintenance.js |   5 +-
.../tools/schema_diff/static/js/schema_diff_ui.js  |   6 +-
web/pgadmin/tools/sqleditor/__init__.py|   2 +-
web/pgadmin/tools/sqleditor/static/js/sqleditor.js |  31 +--
.../tools/sqleditor/utils/start_running_query.py   |   2 +-
.../user_management/static/js/user_management.js   |  20 +-
.../javascript/alerts/alertify_wrapper_spec.js | 116 --
.../javascript/components/FormComponents.spec.js   |  17 +-
.../jasmine_capture_warnings_beforeall.js  |   1 +
.../sqleditor/call_render_after_poll_spec.js   |  50 ++---
.../sqleditor/query_tool_actions_spec.js   |   2 -
.../table/enable_disable_triggers_spec.js  |  44 ++--
web/yarn.lock  |  12 +-
61 files changed, 584 insertions(+), 641 deletions(-)



pgAdmin 4 commit: Fixed some accessibility issues:

2021-12-02 Thread Akshay Joshi
Fixed some accessibility issues:
1) Focus is not visible while navigating through top navbar menu items(File, 
Object, Tools)
2) In preference dialog wherever access key is used for a shortcut declaration, 
unable to get out of the textbox.
3) Focus is not visible for the links on the dashboard

Fixes #7046

Branch
--
master

Details
---
https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=e30cbe2579e49ecb03ae3244424f9c8b88bf40d3
Author: Ganesh Jaybhay 

Modified Files
--
docs/en_US/release_notes_6_3.rst   |  1 +
web/pgadmin/static/js/alertify.pgadmin.defaults.js | 17 +
web/pgadmin/static/scss/_jsoneditor.overrides.scss |  4 
3 files changed, 18 insertions(+), 4 deletions(-)



Re: [pgAdmin][RM7031]: Database definition wrong

2021-12-02 Thread Akshay Joshi
Thanks, the patch applied.

On Thu, Dec 2, 2021 at 3:09 PM Pradip Parkale <
pradip.park...@enterprisedb.com> wrote:

> Hi Akshay/Aditya,
>
> Please find the updated patch.
>
> On Wed, Dec 1, 2021 at 5:56 PM Aditya Toshniwal <
> aditya.toshni...@enterprisedb.com> wrote:
>
>> Hi Pradip,
>>
>> You did not include the server_old table for query_history.
>>
> Fixed.
>
>> Please also remove the commented code:
>> +# db.engine.execute("PRAGMA foreign_keys=ON")
>> +
>> +# db.session.commit()
>> +
>> +# db.engine.execute("PRAGMA foreign_keys=ON")
>> +
>>
> Fixed.
>
>>
>>
>>
>> On Wed, Dec 1, 2021 at 5:25 PM Akshay Joshi <
>> akshay.jo...@enterprisedb.com> wrote:
>>
>>> Thanks, the patch applied.
>>>
>>> On Wed, Dec 1, 2021 at 4:23 PM Pradip Parkale <
>>> pradip.park...@enterprisedb.com> wrote:
>>>
 Hi Hackers,

 Please find the attached for #7031 Database definition wrong.

 --
 Thanks & Regards,
 Pradip Parkale
 Software Engineer | EnterpriseDB Corporation

>>>
>>>
>>> --
>>> *Thanks & Regards*
>>> *Akshay Joshi*
>>> *pgAdmin Hacker | Principal Software Architect*
>>> *EDB Postgres *
>>>
>>> *Mobile: +91 976-788-8246*
>>>
>>
>>
>> --
>> Thanks,
>> Aditya Toshniwal
>> pgAdmin Hacker | Software Architect | *edbpostgres.com*
>> 
>> "Don't Complain about Heat, Plant a TREE"
>>
>
>
> --
> Thanks & Regards,
> Pradip Parkale
> Software Engineer | EnterpriseDB Corporation
>


-- 
*Thanks & Regards*
*Akshay Joshi*
*pgAdmin Hacker | Principal Software Architect*
*EDB Postgres *

*Mobile: +91 976-788-8246*


Re: [pgAdmin][7046] Accessibility fixes

2021-12-02 Thread Akshay Joshi
Thanks, the patch applied.

On Wed, Dec 1, 2021 at 6:37 PM Ganesh Jaybhay <
ganesh.jayb...@enterprisedb.com> wrote:

> Hi Hackers,
>
> Please find the attached patch to fix the below accessibility issues:
>
>- Focus is not visible while navigating through top navbar menu
>items(File, Object, Tools)
>- In preference dialog- wherever access key is used for a shortcut
>declaration, unable to get out of the textbox  *Solution Added*: ESC
>key is used to come out of the textbox for the access key and move to the
>next field
>- Focus is not visible for the links on the dashboard
>
> Please review.
>
> Regards,
> Ganesh Jaybhay
>


-- 
*Thanks & Regards*
*Akshay Joshi*
*pgAdmin Hacker | Principal Software Architect*
*EDB Postgres *

*Mobile: +91 976-788-8246*


pgAdmin 4 commit: Added support for Two-factor authentication for impro

2021-12-02 Thread Akshay Joshi
Added support for Two-factor authentication for improving security. Fixes #6543

Branch
--
master

Details
---
https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=36c9eb3dfd9202c5ab46272d573619c75cfdd79a
Author: Ashesh Vashi 

Modified Files
--
.dockerignore  |   6 +
Dockerfile |   4 +
docs/en_US/getting_started.rst |   1 +
docs/en_US/images/mfa_registration.png | Bin 0 -> 147202 bytes
docs/en_US/mfa.rst |  57 +++
docs/en_US/release_notes_6_3.rst   |   1 +
pkg/mac/build-functions.sh |  11 +-
requirements.txt   |   3 +
web/.eslintignore  |   1 +
web/config.py  |  23 ++
web/migrations/script.py.mako  |   3 +-
web/migrations/versions/15c88f765bc8_.py   |  44 +++
web/migrations/versions/6650c52670c2_.py   |  12 +-
web/pgadmin/authenticate/__init__.py   |  22 +-
web/pgadmin/authenticate/mfa/__init__.py   | 110 ++
web/pgadmin/authenticate/mfa/authenticator.py  | 222 +++
web/pgadmin/authenticate/mfa/email.py  | 310 
web/pgadmin/authenticate/mfa/registry.py   | 167 +
.../authenticate/mfa/static/images/email_lock.svg  |   5 +
.../authenticate/mfa/static/images/totp_lock.svg   |   5 +
.../authenticate/mfa/templates/mfa/email.js|  66 
.../mfa/templates/mfa/email_code_sent.html |  19 +
.../authenticate/mfa/templates/mfa/email_view.html |   7 +
.../authenticate/mfa/templates/mfa/register.html   |  78 
.../authenticate/mfa/templates/mfa/validate.html   | 121 ++
.../templates/security/email/send_email_otp.html   |   2 +
.../templates/security/email/send_email_otp.txt|   2 +
web/pgadmin/authenticate/mfa/tests/test_config.py  | 154 
web/pgadmin/authenticate/mfa/tests/test_mfa.py |  56 +++
.../authenticate/mfa/tests/test_mfa_view.py|  66 
.../authenticate/mfa/tests/test_user_execution.py  | 125 +++
web/pgadmin/authenticate/mfa/tests/utils.py| 111 ++
web/pgadmin/authenticate/mfa/utils.py  | 408 +
web/pgadmin/authenticate/mfa/views.py  | 346 +
web/pgadmin/browser/__init__.py|  12 +-
web/pgadmin/browser/static/js/browser.js   |   4 +-
web/pgadmin/browser/static/js/dialog.js| 110 ++
web/pgadmin/browser/templates/browser/index.html   |  11 +
web/pgadmin/model/__init__.py  |   8 +
web/pgadmin/static/img/login.svg   |   2 +-
web/pgadmin/static/js/pgadmin.js   |   2 +
web/pgadmin/static/scss/_pgadmin.style.scss|  26 +-
.../static/scss/resources/_default.variables.scss  |   1 +
.../scss/resources/dark/_theme.variables.scss  |   2 +
.../resources/high_contrast/_theme.variables.scss  |   2 +
web/pgadmin/templates/base.html|   6 +-
.../templates/security/change_password.html|   4 +-
web/pgadmin/templates/security/panel.html  |  25 +-
web/pgadmin/tools/datagrid/__init__.py |   2 +
web/pgadmin/tools/debugger/__init__.py |   2 +
web/pgadmin/tools/erd/__init__.py  |   2 +
web/pgadmin/tools/psql/__init__.py |   2 +
web/pgadmin/tools/schema_diff/__init__.py  |   2 +
web/pgadmin/tools/sqleditor/__init__.py|   3 +-
.../user_management/static/js/user_management.js   |  94 +
web/webpack.shim.js|   1 +
56 files changed, 2771 insertions(+), 120 deletions(-)



pgAdmin 4 commit: Corrected the down_version in migration file.

2021-12-02 Thread Akshay Joshi
Corrected the down_version in migration file.

Branch
--
master

Details
---
https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=5ae1036a246202830a510273b273cb6a6fbbd951

Modified Files
--
web/migrations/versions/15c88f765bc8_.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)



[pgAdmin][patch] React based Modal provider to replace Altertify alert

2021-12-02 Thread Aditya Toshniwal
Hi Hackers,

Attached patch adds a React based modal provider to pgAdmin. It can be used
to create modals on the fly.
Based on this, I've created two functions - alert and confirm in the
Notifier. This will help to replace Alertify alert and confirm.

Please review.

-- 
Thanks,
Aditya Toshniwal
pgAdmin Hacker | Software Architect | *edbpostgres.com*

"Don't Complain about Heat, Plant a TREE"


modalprovider.patch
Description: Binary data


pgAdmin 4 commit: Fixed API test cases for StartRunningQueryTest.

2021-12-02 Thread Akshay Joshi
Fixed API test cases for StartRunningQueryTest.

Branch
--
master

Details
---
https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=f8cb62180e81e49385ab7390a481d71c20bab882

Modified Files
--
.../tools/sqleditor/utils/tests/test_start_running_query.py| 10 +-
1 file changed, 5 insertions(+), 5 deletions(-)



pgAdmin 4 commit: Implemented React based modal provider to create mode

2021-12-02 Thread Akshay Joshi
Implemented React based modal provider to create models on the fly.
Also, use this to replace Alertify alert and confirm dialog.

Branch
--
master

Details
---
https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=dfdaf7f6d19c3efb7f9959f8b18ea0407996d0f1
Author: Aditya Toshniwal 

Modified Files
--
web/package.json|   1 +
web/pgadmin/static/js/Theme/index.jsx   |  21 -
web/pgadmin/static/js/components/Buttons.jsx|  49 +--
web/pgadmin/static/js/helpers/ModalProvider.jsx |  92 +
web/pgadmin/static/js/helpers/Notifier.jsx  | 104 ++--
web/pgadmin/templates/base.html |   1 +
web/yarn.lock   |  10 ++-
7 files changed, 262 insertions(+), 16 deletions(-)



pgAdmin 4 commit: Fixed unhashable type issue while opening the about d

2021-12-02 Thread Akshay Joshi
Fixed unhashable type issue while opening the about dialog. Fixes #7048

Branch
--
master

Details
---
https://git.postgresql.org/gitweb?p=pgadmin4.git;a=commitdiff;h=9c0c046a38ed8a59588dff4ca09bc42f60c5fba7

Modified Files
--
docs/en_US/release_notes_6_3.rst | 1 +
web/pgadmin/__init__.py  | 2 +-
web/pgadmin/about/__init__.py| 7 +++
3 files changed, 5 insertions(+), 5 deletions(-)



Re: [pgAdmin][patch] React based Modal provider to replace Altertify alert

2021-12-02 Thread Akshay Joshi
Thanks, the patch applied.

On Fri, Dec 3, 2021 at 12:11 PM Aditya Toshniwal <
aditya.toshni...@enterprisedb.com> wrote:

> Hi Hackers,
>
> Attached patch adds a React based modal provider to pgAdmin. It can be
> used to create modals on the fly.
> Based on this, I've created two functions - alert and confirm in the
> Notifier. This will help to replace Alertify alert and confirm.
>
> Please review.
>
> --
> Thanks,
> Aditya Toshniwal
> pgAdmin Hacker | Software Architect | *edbpostgres.com*
> 
> "Don't Complain about Heat, Plant a TREE"
>


-- 
*Thanks & Regards*
*Akshay Joshi*
*pgAdmin Hacker | Principal Software Architect*
*EDB Postgres *

*Mobile: +91 976-788-8246*