required by its javascript module.
This will allow us to load the javascript modules as a static file, and
not as a Jinja2 template. This will increase the load time, as it will
decrease number of templates to be processed during loading those
javascripts.
While accessing the configuration database from multiple session, it
results in to the error - OperationError, because - sqlite locks all the
database, and does not allow to access it simultaneously. We added the
timeout to give some time window for accessing it simultaneously.
- The button bar be moved out into an HTML template
- create.sql should perhaps be renamed to insert.sql
- The "Add Row" button only works if you're on the last page of the resultset.
- Use one wcDocker instead of two
- Added support of code folding
- Removed the "lineWrapping" option from the codemirror textarea because
it was creating issue in the code folding.
- Handle the values while depositing during debugging.
- Properly handle the Array values while saving it to sqlite database
and displayed in input dialog.
- SQL code folding was not supported in codemirror so added the same.
will always have latest data related to that type of node. Also, fixed
the cache_level for different node types.
This commit also contains fixes for the following issue:
* In extension module - use the 'node-list-by-name' instead of using a
custom 'node-ajax-options' control, and removed redundant template
schemas from it.
* When we tries to destroy the select2 object from
Select2Cell/Select2Control while releasing the properties view,
sometimes select2 can not find the instance related it for some
unknown reason. Hence - before removing it we will check for manual
instance existance using $.data('select2').
* When we traverse through the browser tree nodes very quickly, it tries
to remove the object before it gets created completely, and results
into an exception.
* Icon in the select2 drop down list was not visible due to some CSS
issues.
Apart of that, we will generate two new browser events -
'pgadmin-node:created:<NODE-TYPE>', 'pgadmin-node:updated:<NODE-TYPE>'
whenever a new node is created, or an existing node will be updated.
Introduced a class 'noclose'. Then - menu-item having this class will
not propograte the events to its parent, hence - it will not be closed.
Some of the CSS applicable only to the immediate buttons only, and not
the grand-children.
DriverRegistry is executed second time.
Also, initialize the driver before registering different blueprints,
which uses those driver inside them.
Thanks Khushboo for reporting the issue.
the CAST module. Make the changes in the CAST module too for the
changes done in the NodeAjaxOptionsControl in the commit-id:
944bdbb96c.
We've changed the signature (arguments) of the 'options' & 'transform'
functions.
Also, remove the CodeMirror object for better clean up process.
When a SQL control/tab is rendered in a hidden element, it does not
render really well. Because - it rely on the height, and width of the
container to count the gutten position, and margin, and other elements.
Hence - whenever the tab, panel becomes visible, we will refresh the
control.
aciTree.
Also - fixed few CSS specifically for the preferences dialog.
Returning the sorted preferences from the server, so that - it lists
down in correct order.
due to internal 'set' function call from the internal 'reset' function.
We will stop the session management, before doing any clean up for
ignoring such events.
Select2 does not allow to scroll any of the parent container once it was
opened, and if it was not properly closed.
Also, resolved an issue - existing selection was not working, while
re-rendering the Select2Cell.
- Renaming or changing the schema for a shell type should not be allowed.
- I'm allowed to try to add ACL entries or security labels to an
existing shell type. This should be disallowed.
- Changing the schema on a (non-shell) type doesn't work - the type
name is omitted, e.g.
ALTER TYPE pem
SET SCHEMA pemhistory;
Which should be:
ALTER TYPE pem.foo
SET SCHEMA pemhistory;
on the object everytime, it hits the buttons, and the callback functions
are being executed. The original implementation was not using the same
panel, when it was recalled from other function. And, results into
unexpected behaviour like not able to work with Edit object again.
Thanks Murtuza for reporting the issue.
Removed the use of separate editor for both of these cell types. There
were two instance of select2 were getting created in the Select2Cell,
one in the Select2Cell itself, and another in Select2CellEditor. And,
loosing the focus mysteriously, and making the scrollbar in the property
dialog non-responsive.
Also, modified the NodeAjaxOptionsCell to use the above logic, and
removed its own version of render function to make it consitent across
the system.
This patch [changes sent by Murtuza] also includes improvisation in the
DeleteCell, and ObjectCell, which will honour now 'canRemoveRow', and
''canEditRow' respective properties of Column.
The current implementaton binds the cell/control object, and the ajax
data in the asychronous Cells/Controls with the 'options' functions
extended from the Select2Cell.
The problem starts when we try to fetch the current model from that
options/transform/filter function to do some operation, which does not
require in most of the cases. Except the privileges control - where we
needed the current model for omitting the existing selected object
during transformation, and filtering.
In order resolved the issue, we need a common object, which is shared
among the Cell. In backgrid, the 'Column' object is mong the cell,
hence - implementation logic has been changed to bid the 'Column' object
with the 'options' function and, passed the 'Cell' object as an
arguments.
Because - we do use the common function 'transform' between 'Control'
and 'Cell', we needed make changes in the Select2Control to pass the
Control object as an arguments.
And, make the changes in the privileges control to use the new
implementation. The same logic is also required in some of the
operations, we will be/are working on the table/column nodes.
At the moment, we will only allow to fetch status messages from the
asynchronous connection only, later - we may implement to fetch the
status message from the normal connection too.
This allows us to use the Backgrid key navigation as expected.
This has also resulted into an issue - related unresponsive scrollbar
issue in the SubNodeControl.
operation.
Some of the nodes do not return id as result, when they were created.
Modified the logic to allow to open the parent node in such conditions.
was not honouring the change events after execution of the function -
'render' more than one time. Change the label of the Add button to make
it consistent with the Unique Collection Control.
order to fix the issue rendering the context menu for longer text.
Needs to do some modification in the existing pgAdmin4 CSS theme to make
it looks like/near the existing look and feel.
configuration database due to unable to identify the change properly.
Thanks Dave for reporting.
This also includes a support to use a 'text' type of preference, and
show help string next to the control.
Following are the enhancements:
1. Added border to control which was missing earlier.
2. Allows user to provide height to sql-field control by specifying extraClasses field in model schema.
3. Defined new classes for sql-field control height in overrides.css
4. Added scrollbar to the control.
Usage:
{
id: 'definition', label:'{{ _("Definition") }}', cell: 'string',
type: 'text', mode: ['create', 'edit'], group: 'Definition',
control: Backform.SqlFieldControl, extraClasses:['custom_height_css_class']
}
multiple menu-items (not just the 'create' menu-group).
Moved all the main menu/context menu generation implementation in the
'menu' javascript menu.
In this implementation, if more than one menu-items specify same type
of categories, they will be created withing that group, otherwise - it
will be created separately (unless 'single' property of that category is
set to true).
We can also provide icon, priority, separator(s) above/below it for the
individual sub-menu too using pgAdmin.Browser.add_menu_category
function(...).
With previous implementation each node will have to send the values of 'show_system_objects'
while calling get_dependencies/get_dependents function. Now I have changed the logic to use the
value directly into the base class functions.
generated for the privilege control. Also, made changes in the
PrivilegeRoleModel, to allow to select a grantee only once for the
current user (as grantor), and omit them from other cell objects.
Valid/Invalid event was not properly triggered, whenever the child
attribute is a collection/model within a model (nested mode/collection
within model). This patch tried to take care of all such scenarios in
general.
change events.
- In input & textarea control, call the change event on key up (but -
not on every key up events, wait for sometime before trigger that
event, so that - we do not overdo that).
- In unique/subnode control, whenever we create new model object, set
all the required static fields used by pgAdmin form generation logic.
- In NodeAjaxListCell, we don't need to call the list generation
operation (ajax operation) for each and every cell. They use the same
shared column object.
- Remove unnecessary columns from collection property lists.
- Standardise property names and groupings.
- pg_attribute doesn't have an OID column, so use attnum instead (of atttypid!?!)
- Don't display the OID on Edit dialogues
- Use the ACL summary display in the properties panel, not the subnode editor.
- s/Oid/OID/g
- Ensure all security properties are displayed in the Security group
- Ensure all object definition values are stored in the Definition (or a more precise) group, not General.
- Fix the ordering of General properties so the comment is always show last.
- Display the ACL string in properties, not the subnode panel.
- Offer default values for the owner of new objects.
- Add missing context menu option to create a tablespace from a server node.
This will also allow us to operate on individual privileges & also we
needed this functionality for column nodes.
For example,
*Earlier:* priv was string
GRANT {{ priv }} ON {{ type }} TO {{ conn|qtIdent(role) }};
*Now:* priv will be List, which we need to handle in jinja templates.
GRANT *{{ priv|join(', ') }}* ON {{ type }} TO {{ conn|qtIdent(role) }};