public inbox for [email protected]
help / color / mirror / Atom feedFrom: Surinder Kumar <[email protected]>
To: pgadmin-hackers <[email protected]>
Subject: Fwd: [pgAdmin4] [Patch]: Grant Wizard
Date: Fri, 6 May 2016 15:00:34 +0530
Message-ID: <CAM5-9D8p6_Vht-Fd-3xq_Fxc4TgJ_4aqzYaArbgNJsa34e4Lww@mail.gmail.com> (raw)
In-Reply-To: <CAM5-9D_29dfZZ8wG8wWQz41H3UTMUhRX5YU4X7Nehyh3bsMh2A@mail.gmail.com>
References: <CAM5-9D8oYyEaL89coD9FozPDziGhYutYAat9dMP9dAwhOp5OKQ@mail.gmail.com>
<CA+OCxozy4aH9=2T0Sp_WworU_3UQaaHBcQXTDhEUKHAkZJT8ow@mail.gmail.com>
<CA+OCxoyGKAorswp0fwUojT4gB0Ex+dcRxzKbLkfG48qeCmSCrQ@mail.gmail.com>
<CAM5-9D_D3TGq9-DbcR+07=p2cgT=yEtmEJnHU9rtmov_nby9+g@mail.gmail.com>
<CAM5-9D_6kD3yEcZ3A4A6WOT7aRk_EGru6LSswQv+PBmK=2QKfA@mail.gmail.com>
<CA+OCxozwOV+FixF3-9KgmGOaytZQ3Fsn3_BNAyCNqQPtLp+_VQ@mail.gmail.com>
<CAM5-9D9vGUgGaACFZc1YxFNp_gi-fAm=w2rf_JmNtD+HBi64=w@mail.gmail.com>
<CA+OCxozvNDNi0MBVQ3Gq7GhT27o2MX2=KuFUE+pUUqOCbufe+A@mail.gmail.com>
<CAM5-9D8ZHTvx53WhL2S0XUt8o+LE0aiCxMLQJGP2PUg_Q4S1dw@mail.gmail.com>
<CAM5-9D-bSJx-u_K+o2eQhd8r_39+CTxmabg9wkXP_NzVu9Eo2A@mail.gmail.com>
<CA+OCxozp8ZS5wHLAFuONT9Ap93De6so2Eg=ta028eusQwt=fEA@mail.gmail.com>
<CAM5-9D9Z9-x9Bbb0rFFS34xCy_GNsdot2bQ4rbYMPq=pWL3Vew@mail.gmail.com>
<CAM5-9D9hQZWsYETszCV7=dVsLf6KHojC9P+_icmHFGCh8jFHnQ@mail.gmail.com>
<CAG7mmowJONpMzMva7qxLQ=Wd5bFxXMsV7URosk8O5zVKLPXwnA@mail.gmail.com>
<CAM5-9D9R4vR6TfOLd+NiSVWZy+L0Z+8Jj=A-v-tP5f_5Of5ksA@mail.gmail.com>
<CA+OCxownatDkVQsZGKJUwO1=co0XOf0J=U5ydSYh8=xXi7ogTQ@mail.gmail.com>
<CAM5-9D-ixhoFahG2dxmZCxhv_VVm0ncsqm075kemZ+M7kuoKPw@mail.gmail.com>
<CA+OCxoyC-U+u8eESm8NXchX+s9dwdCFKMJ3x5JcZNCAgN4CnPw@mail.gmail.com>
<CAM5-9D_TmnFfVEw1OXTL-f4jgtCiE+e2rQuSKa4yqPX7ZsSBNg@mail.gmail.com>
<CA+OCxoy_DPvhJfViwsmKSBgwxBx51g=W6qu+NuqED_yTDm2gCw@mail.gmail.com>
<CAM5-9D_29dfZZ8wG8wWQz41H3UTMUhRX5YU4X7Nehyh3bsMh2A@mail.gmail.com>
List-Unsubscribe: <mailto:[email protected]?body=unsub%20pgadmin-hackers>
Hi,
PFA patch with following issues fixed:
1. As SqlTab Control is renamed to SqlCtrl, throws error on grant wizard
close. it is Fixed.
2. Moved grant wizard specific css from wizard.css to grant_wizard.css.
On Wed, Apr 13, 2016 at 8:41 PM, Dave Page <[email protected]> wrote:
> Hi
>
> On Fri, Apr 8, 2016 at 6:59 PM, Surinder Kumar <
> [email protected]> wrote:
>
>> Hi
>>
>> PFA patch with resolved review comments.
>>
>> On Fri, Apr 8, 2016 at 12:52 AM, Dave Page <[email protected]> wrote:
>>
>>> Hi
>>>
>>> Nearly there :-). Assuming no regressions, I believe we'll be ready to
>>> commit once the following issues are resolved:
>>>
>>> - The select object grid should fill the available vertical space in the
>>> dialogue - at present there's a gap below it.
>>>
>> Done
>>
>
> This does not seem to be fixed (see attached screenshot). In fact, the gap
> gets bigger proportionally as the window is resized.
>
Fixed
>
>
>>
>>> - When selecting privileges, each time I click on a checkbox, the row
>>> closes. Similar grids elsewhere in the app close the row when the cell
>>> loses focus, *however*, that is also the incorrect behaviour - the row
>>> should only close when the row itself loses focus (and should open when it
>>> gets focus).
>>>
>> I checked the row closes either when gets clicked on row or outside row,
>> it doesn't seems to close on click on checkbox.
>>
>
> This is still broken for me. I'm using Chrome on OS X. As soon as I click
> any checkbox, the row closes, and I have to click again to see the
> checkboxes again.
>
I checked with Chrome on OS X, windows and ubuntu, it is working fine. Can
you please send me screenshot if possible?
>
> One additional issue:
>
> - If I select some objects and permissions (in my case, everything in a
> PEM database, and ALL), hit Next so I can see the SQL, then hit back
> *twice*, I see the second attached screenshot.
>
I followed the same steps and when hit back twice on *previous* button of
SQL page, it takes me to first page which is right.
It would be easy for me to find out the exact cause if you send me output
of browser console panel.
>
> I'm going to commit the code with these issues as they are largely
> cosmetic. Please submit a patch to fix them (I'll add a new card to our
> internal Kanban chart).
>
> Thanks.
>
> --
> Dave Page
> Blog: http://pgsnake.blogspot.com
> Twitter: @pgsnake
>
> EnterpriseDB UK: http://www.enterprisedb.com
> The Enterprise PostgreSQL Company
>
--
Sent via pgadmin-hackers mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers
Attachments:
[application/octet-stream] grant_wizard_v10.patch (6.5K, 3-grant_wizard_v10.patch)
download | inline diff:
diff --git a/web/pgadmin/browser/static/css/wizard.css b/web/pgadmin/browser/static/css/wizard.css
index 2c19a09..ab96b6e 100644
--- a/web/pgadmin/browser/static/css/wizard.css
+++ b/web/pgadmin/browser/static/css/wizard.css
@@ -4,7 +4,7 @@
}
.wizard-header {
- padding: 6px 10px!important;
+ padding: 6px 10px!important;
min-height: 35px;
max-height: 35px;
border-bottom: 2px solid darkgray;
@@ -29,25 +29,18 @@
width: 100%;
}
-.grant_wizard_container {
- position: relative;
- overflow: hidden;
- width: 100%;
- height: 100%;
-}
-
-.grant_wizard_container .pgadmin-wizard {
+.pgadmin-wizard {
width: 100%;
height: 100%;
}
-.grant_wizard_container .wizard-content {
+.wizard-content {
position: relative;
padding: 0;
- height: 78%;
+ height: calc(100% - 97px);
}
-.grant_wizard_container .wizard-right-panel {
+.wizard-right-panel {
overflow-y: auto;
height: 100%;
top: 0;
@@ -56,7 +49,7 @@
bottom: 0;
}
-.grant_wizard_container .wizard-left-panel {
+.wizard-left-panel {
position: absolute;
top: 0;
display: flex;
@@ -67,20 +60,16 @@
right: 0;
}
-.grant_wizard_container .wizard-left-panel img {
+.wizard-left-panel img {
width: 140px;
}
-.grant_wizard_container .wizard-right-panel_content {
- height: 60%;
-}
-
-.grant_wizard_container {
- height: 100%;
+.wizard-right-panel_content {
+ height: calc(100% - 113px);
}
/* Wizard Footer CSS */
-.grant_wizard_container .footer {
+.pgadmin-wizard .footer {
background-color: #D2D2D2;
border-width: 2px 0px 0px 0px;
border-style: solid;
@@ -94,41 +83,41 @@
}
/* Wizard Button CSS */
-.grant_wizard_container .wizard-buttons {
+.pgadmin-wizard .wizard-buttons {
float: right;
}
-.grant_wizard_container .wizard-buttons button {
+.pgadmin-wizard .wizard-buttons button {
float: left;
font-size: 14px;
margin: 3px 5px 0 0 !important;
}
-.grant_wizard_container .wizard-buttons button.wizard-next i.fa {
+.pgadmin-wizard .wizard-buttons button.wizard-next i.fa {
padding-left: 5px;
}
-.grant_wizard_container .wizard-buttons button.wizard-back i.fa,
-.grant_wizard_container .wizard-buttons button.wizard-cancel i.fa {
+.pgadmin-wizard .wizard-buttons button.wizard-back i.fa,
+.pgadmin-wizard .wizard-buttons button.wizard-cancel i.fa {
padding-right: 5px;
}
-.grant_wizard_container .wizard-buttons .wizard-finish {
+.pgadmin-wizard .wizard-buttons .wizard-finish {
margin-right: 0 !important;
}
/* Wizard Status bar CSS */
-.grant_wizard_container .wizard-description {
+.pgadmin-wizard .wizard-description {
padding: 1.0em 0.1em;
}
/* Error message css */
-.grant_wizard_container .error_msg_div {
- display: block;
+.pgadmin-wizard .error_msg_div {
background: #fff;
+ font-size: 13px;
}
-.grant_wizard_container .error_msg_div p {
+.pgadmin-wizard .error_msg_div p {
background: #fff;
color: #b92c28;
}
@@ -146,4 +135,4 @@
.alertify .ajs-body .ajs-content {
padding: 0px;
-}
\ No newline at end of file
+}
diff --git a/web/pgadmin/tools/grant_wizard/static/css/grant_wizard.css b/web/pgadmin/tools/grant_wizard/static/css/grant_wizard.css
index 18240e9..7681b9a 100644
--- a/web/pgadmin/tools/grant_wizard/static/css/grant_wizard.css
+++ b/web/pgadmin/tools/grant_wizard/static/css/grant_wizard.css
@@ -11,9 +11,14 @@
}
.object_type_table {
- display: inline-block;
height: 100%;
border: 0 !important;
+ display: inline;
+}
+
+.object_type_table thead {
+ display: table;
+ width: 100%;
}
.object_type_table thead tr {
@@ -24,7 +29,7 @@
.object_type_table tbody {
display: block;
- overflow: scroll;
+ overflow: auto;
border: 1px solid #ddd;
width: 100%;
min-height: 100%;
@@ -107,3 +112,10 @@
.wizard-right-panel_content .CodeMirror-gutters {
min-height: 285px !important;
}
+
+.grant_wizard_container {
+ position: relative;
+ overflow: hidden;
+ width: 100%;
+ height: 100%;
+}
diff --git a/web/pgadmin/tools/grant_wizard/templates/grant_wizard/js/grant_wizard.js b/web/pgadmin/tools/grant_wizard/templates/grant_wizard/js/grant_wizard.js
index b167447..543455d 100644
--- a/web/pgadmin/tools/grant_wizard/templates/grant_wizard/js/grant_wizard.js
+++ b/web/pgadmin/tools/grant_wizard/templates/grant_wizard/js/grant_wizard.js
@@ -93,7 +93,6 @@ define([
var col = this.column.get('name');
if (this.model && this.model.has(col)) {
if (this.model.get(col)) {
- this.checkbox().prop("checked", true);
this.$el.parent().toggleClass("selected", true);
this.model.trigger("backgrid:selected", this.model, true);
}
@@ -201,7 +200,6 @@ define([
},
setup:function() {
return {
-
// Set options for dialog
options: {
frameless: true,
@@ -946,8 +944,9 @@ define([
dataType: "json",
contentType: "application/json"
}).done(function(res) {
- self.sqlTab.clearHistory();
- self.sqlTab.setValue(res.data);
+ self.sqlCtrl.clearHistory();
+ self.sqlCtrl.setValue(res.data);
+ self.sqlCtrl.refresh();
}).fail(function() {
self.model.trigger('pgadmin-view:msql:error');
}).always(function() {
@@ -959,9 +958,9 @@ define([
// Clear html dom elements of CodeMirror sql tab
self.sqlControl.unbind(); // Unbind all local event bindings
- var cmElem = self.sqlControl.sqlTab.getWrapperElement();
+ var cmElem = self.sqlControl.sqlCtrl.getWrapperElement();
cmElem.remove();
- self.sqlControl.sqlTab = undefined;
+ self.sqlControl.sqlCtrl = undefined;
}
})
@@ -987,9 +986,9 @@ define([
view: new(function() {
// Render SqlTab control to generate its html markup
- var sqlTabHtml = sqlControl.render().$el;
+ var sqlCtrlHtml = sqlControl.render().$el;
this.render = function() {
- return { el: sqlTabHtml };
+ return { el: sqlCtrlHtml };
};
}),
view thread (24+ 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]
Subject: Re: Fwd: [pgAdmin4] [Patch]: Grant Wizard
In-Reply-To: <CAM5-9D8p6_Vht-Fd-3xq_Fxc4TgJ_4aqzYaArbgNJsa34e4Lww@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