public inbox for [email protected]
help / color / mirror / Atom feedFrom: Murtuza Zabuawala <[email protected]>
To: Akshay Joshi <[email protected]>
Cc: pgadmin-hackers <[email protected]>
Subject: Re: [pgAdmin4[RM#3935] Grant wizard fails to list down functions
Date: Mon, 28 Jan 2019 14:49:00 +0530
Message-ID: <CAKKotZQhaYR_NvPa_CKdd-7PoWQspCQFODCZj2AuLfU4qE39tA@mail.gmail.com> (raw)
In-Reply-To: <CANxoLDckA6XT51xibDmSdt0Jcv_suyAv1G7TBLYLJw6cVxj4+w@mail.gmail.com>
References: <CAKKotZTf=gmr3F6QvgbFfi1DEFZCAtB17Ai9UZD4fBHJqyLCaA@mail.gmail.com>
<CANxoLDckA6XT51xibDmSdt0Jcv_suyAv1G7TBLYLJw6cVxj4+w@mail.gmail.com>
Hi,
PFA minor patch, To display an error on UI when there is a backend error
for the grant wizard request.
Please review.
--
Regards,
Murtuza Zabuawala
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
On Mon, Jan 28, 2019 at 12:48 PM Akshay Joshi <[email protected]>
wrote:
> Thanks patch applied.
>
> On Mon, Jan 28, 2019 at 12:01 PM Murtuza Zabuawala <
> [email protected]> wrote:
>
>> Hi,
>>
>> PFA patch to fix the issue where EPAS DB instance running with
>> *no-redwood-compat* mode fails to list down functions objects in grant
>> wizard due to 'char' -> 'int' type cast error.
>>
>>
>> --
>> Regards,
>> Murtuza Zabuawala
>> EnterpriseDB: http://www.enterprisedb.com
>> The Enterprise PostgreSQL Company
>>
>>
>
> --
> *Akshay Joshi*
>
> *Sr. Software Architect *
>
>
>
> *Phone: +91 20-3058-9517Mobile: +91 976-788-8246*
>
Attachments:
[application/octet-stream] RM_3935_show_error_on_UI.diff (1.4K, 3-RM_3935_show_error_on_UI.diff)
download | inline diff:
diff --git a/web/pgadmin/static/scss/_alert.scss b/web/pgadmin/static/scss/_alert.scss
index e8676b8c..f5082c37 100644
--- a/web/pgadmin/static/scss/_alert.scss
+++ b/web/pgadmin/static/scss/_alert.scss
@@ -21,7 +21,8 @@
display: inline-block;
}
-.alert.alert-info {
+.alert.alert-info,
+.alert.alert-danger {
padding: 0.5rem;
}
diff --git a/web/pgadmin/tools/grant_wizard/static/js/grant_wizard.js b/web/pgadmin/tools/grant_wizard/static/js/grant_wizard.js
index 85d78da2..ee9e0c45 100644
--- a/web/pgadmin/tools/grant_wizard/static/js/grant_wizard.js
+++ b/web/pgadmin/tools/grant_wizard/static/js/grant_wizard.js
@@ -612,6 +612,18 @@ define([
$('.wizard-progress-bar p').html('');
$('.wizard-progress-bar').hide();
},
+ error: function(m, xhr) {
+ let msg;
+ if (xhr && xhr.responseJSON && xhr.responseJSON.errormsg) {
+ msg = xhr.responseJSON.errormsg;
+ }
+
+ if(!msg) {
+ msg = gettext('Unable to fetch the database objects due to an error');
+ }
+ $('.wizard-progress-bar p').removeClass('alert-info').addClass('alert-danger');
+ $('.wizard-progress-bar p').text(msg);
+ },
reset: true,
}, this);
view thread (6+ messages) latest in thread
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected]
Subject: Re: [pgAdmin4[RM#3935] Grant wizard fails to list down functions
In-Reply-To: <CAKKotZQhaYR_NvPa_CKdd-7PoWQspCQFODCZj2AuLfU4qE39tA@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox