Commit Graph

413 Commits (d53c47e1cf23c60f22bb4b30c013a4d4adad6083)

Author SHA1 Message Date
Murtuza Zabuawala 0cb57848f8 Ensure auto-indent honours the spaces/tabs config setting. Fixes #2780 2017-10-16 15:37:03 +01:00
Dave Page 354679e69b Fix an issue where we were executing SELECT statements in transactions in query tool which probably is not required because SELECT statements are already protected from dirty reads. Fixes #2683 2017-09-20 11:59:37 +01:00
Akshay Joshi 13665f68d8 Fix validation message styling on thegrant wizard. Fixes #2673 2017-09-20 11:34:01 +01:00
Akshay Joshi fe757c384b Filtered Rows dialog not opened from the context menu. Fixes #2699 2017-09-19 11:46:51 +05:30
Akshay Joshi bdc08d94c4 Fix View Data option and column config for Foreign Tables. Fixes #2691 2017-09-18 14:32:17 +01:00
Harshal Dhumal da40573f0b Fix user manager role handling. Fixes #2641 2017-09-18 11:45:57 +01:00
Harshal Dhumal 30e7016077 Changed array representation and formatting for the data types in Query Tool and View Data. Fixes #2671 2017-09-18 12:07:15 +05:30
Murtuza Zabuawala 9cfb2f3cbe Fix filtering of system schemas so pg_* is hidden but pg* is not. Fixes #2709 2017-09-15 13:50:06 +01:00
Atul Sharma 788f7f3a69 Bundle fonts with pgAdmin so we have a standard set for all platforms.
Research by Shirley at Pivotal.
2017-09-13 16:01:14 +01:00
Teng Zhang 512afd6618 Highlighting greenplum keywords in sql editor 2017-09-11 19:39:50 +05:30
Sarah McAlear b585063a26 Refactor keyboard shortcut functions in the query tool. Fix some incorrect keycodes and update docs.
Initial work by Sarah & Violet @ Pivotal, with additional tweaks by Murtuza @ EDB.
2017-08-21 15:27:29 +01:00
Surinder Kumar c7686dee05 Unset compression ratio if it is an empty string in Backup module. Fixes #2582 2017-08-17 16:35:42 +05:30
Hao Wang 5141debae7 UX improvements of the history in the query tool.
- Added copy button for query text.
- Historical queries are binned/grouped by day.

Patch By: Hao Wang, Sarah McAlear
2017-08-09 16:52:43 +05:30
Ashesh Vashi 845025db8f Some cosmetic changes.
- Loading 'pgadmin' as 'sources/pgadmin', as found under the 'sources'
  reference directory to be consistent with other files.
- Removed the 'pgadmin' reference from the base.html template.
- Renamed 'pgadmin.slickgrid.editors.js', and
  'pgadmin.slickgrid.formatters.js' as 'editors.js', and 'formatters.js'
  respectively, as they're already in the 'pgadmin/static/js/slickgrid'
  directory.
- Removed the duplicate entry of 'translations' from the webpack.shim.js
2017-08-09 16:52:12 +05:30
Murtuza Zabuawala ef48c2ed91 Fixed issue in query tool where messages were not displaying from functions/procedures properly. Fixes #2555 2017-08-04 15:50:39 +05:30
Akshay Joshi e506fa1dbe Improved alertify notification logic. Remove AlertifyWrapper class and extend notification methods in alertify itself. 2017-07-31 18:59:44 +05:30
Surinder Kumar 6d5417709c Moved the javascripts of different modules from 'templates' to 'static' directory.
Moving the javascripts for the following modules:
 - About
 - Browser nodes
 - Dashboard
 - FileManager
 - Vendor/snap.svg
 - Preferences
 - Settings
 - Backup
 - Datagrid
 - Debugger
 - Sqleditor
 - Grant Wizard
 - Import & Export
 - Maintenance
 - Restore and
 - User Management
2017-07-27 17:25:08 +05:30
Murtuza Zabuawala 1fa9648a21 Update keyboard shortcuts per discussion. Also, make the labels platform sensitive. 2017-07-26 12:50:42 +01:00
Surinder Kumar 03657df82a Ensure babel-polyfill is loaded in older qWebKits. Fixes #2593 2017-07-21 16:15:03 +01:00
Murtuza Zabuawala b313cbce0d Fix regression tests after Dave broke them. 2017-07-21 10:57:29 +01:00
Sarah McAlear 86dc1e81f1 Move Query Tool keyboard shortcut code into a new module and add tests. 2017-07-20 22:22:25 +01:00
Matthew Kleiman 21bfcd83f4 Allow navigation of query history using the arrow keys. Fixes #2590 2017-07-20 20:47:40 +01:00
Harshal Dhumal 54882e061c Don't attempt to render binary data in the query tool result grid. Fixes #2080. Fixes #2074. 2017-07-20 13:09:47 +01:00
Dave Page 1e1a9f2cf4 Add controls and shortcuts for commenting/uncommenting code in the SQL Editor. Fixes #2456.
Take the opportunity to tidy up the menus and add access keys to appropriate buttons.
2017-07-19 11:43:45 +01:00
Surinder Kumar 4a91bcde30 Webpack all the things! Fixes #2135
This significantly speeds up loading of the application; in an average of 3 tests, v1.6
loaded in 11.5s in the runtime on a Mac, whilst the webpacked version of the code
loaded in 5.53s.
2017-07-18 15:13:17 +01:00
Harshal Dhumal 8bbcf0ab36 Fix handline of large file uploads and properly show any errors that may occur. Fixes #2153 2017-07-17 10:51:26 +01:00
Dave Page ec739b3392 Revert "Open query tool and debugger windows in new tabs by default."
This reverts commit 1a6fe946ce.

This is going to break the regression tests, so reverting it for now.
2017-07-07 17:06:12 +01:00
Dave Page 1a6fe946ce Open query tool and debugger windows in new tabs by default. 2017-07-07 16:53:45 +01:00
Harshal Dhumal fc78202600 Fix clear history. 2017-07-07 15:51:06 +01:00
Akshay Joshi fae185ff66 Partitioned table does not present in grant wizard. Fixes #2543 2017-07-07 15:15:15 +05:30
Akshay Joshi c2fb0394bf Added support of Declarative Partitioning (Range, List) for PostgreSQL 10.
This allows the user to create partitioned table and it's partitions.

  - Edit partitions, Create/Listing of constraints, rules, triggers under partitions. (Implemented by Harshal)
  - Updating browser tree node when create/attach/detach partitions from table dialog.(Implemented by Ashesh)
2017-07-07 11:55:55 +05:30
Matthew Kleiman e2cbaaef71 UI tweaks for the query history. 2017-07-06 13:08:29 +01:00
Harshal Dhumal 76939e4f63 Prompt the user to save dirty queries rather than discard them for a more natural workflow. Fixes #1972 2017-07-04 23:39:10 +01:00
Murtuza Zabuawala 5c7dcaba81 Allow debugging of functions in packages. Fixes #1948 2017-07-03 16:30:12 +01:00
Khushboo Vashi 070a9c077e Allow breakpoints to be set on triggers on views. Fixes #2528 2017-07-03 16:15:42 +01:00
Khushboo Vashi f6b879233c Fix deletion of table rows with the column definition having NOT NULL TRUE and HAS NO DEFAULT VALUE. Fixes #2527 2017-07-03 15:49:59 +01:00
Murtuza Zabuawala 2d5e55964a Improve the debugger's default page layout, and prevent attempts to continue debugging after the user has stopped. Fixes #2512, Fixes #2511 2017-07-03 15:14:45 +01:00
Harshal Dhumal 4e21cdb64b Fix a syntax error in the SQL Editor. 2017-07-03 11:02:20 +01:00
Murtuza Zabuawala 1e427890de Fix an issue where duplicate entry is made of successful executed query, one with status message and one without status message. 2017-07-03 11:00:42 +01:00
Khushboo Vashi 7c09a8f827 Fix typo that caused a layout issue with the Edit Grid. 2017-06-30 12:58:47 +01:00
Joao Pedro De Almeida Pereira 2a30a86e7d Update alertify alerts to use the styling defined in the styleguide. 2017-06-30 10:21:05 +01:00
Khushboo Vashi 501120701e Allow the dashboard panel to be closed. Fixes #2506 2017-06-30 10:11:34 +01:00
Akshay Joshi c98b64fd82 1) Edit cellEditing function, in some cases grid object is undefined.
2) Modify SubNodeCollectionControl, so that user can pass custom backgrid row.
3) Handling of visible parameter in SubNodeCollectionControl.
4) Customise title and delete message for Delete Cell.
5) Added Backgrid.Extension.Select2DepCell and moved Backgrid.Extension.StringDepCell from user management to backgrid.pgadmin.js.
2017-06-29 19:01:29 +05:30
Harshal Dhumal 7389744ecf A number of minor cleanups to the recent changes to the query tool. 2017-06-28 09:49:39 -04:00
Murtuza Zabuawala a9fa093d4b Allow non-superusers to debug their own functions and prevent them from setting global breakpoints. Fixes #2162
Based on a patch from Kit Yam Tse
2017-06-27 16:58:07 -04:00
Joao Pedro De Almeida Pereira 7f55412059 Overhaul the query history tab to allow browsing of the history and full query text. Fixes #2282
Patch by Joao and the team at Pivotal.
2017-06-27 10:55:57 -04:00
Dave Page 96412b3219 Revert "Allow the user to close the dashboard panel. Fixes #2506"
This reverts commit a87ee6d059.
2017-06-27 10:35:43 -04:00
Murtuza Zabuawala 1b49bb8b22 Add preferences to enable brace matching and brace closing in the SQL editors. Fixes #2513 2017-06-27 09:57:38 -04:00
Khushboo Vashi a87ee6d059 Allow the user to close the dashboard panel. Fixes #2506 2017-06-27 09:21:24 -04:00
Harshal Dhumal c65158312d Use on-demand loading for results in the query tool. Fixes #2137
With a 27420 row query, pgAdmin III runs the query in 5.873s on my laptop. pgAdmin 4 now takes ~1s.
2017-06-27 09:03:04 -04:00
Surinder Kumar 3f4781cdcb Un-break query tool feature tests. 2017-06-26 15:25:05 -04:00
Surinder Kumar cfb4b11573 Use client-side url_for in the sql editor and data grid modules. 2017-06-26 07:43:03 -04:00
Matthew Kleiman 94aa5487fb Update Slickgrid to 2.3.7. As this version includes all the features we need, it can be moved out of the vendor directory and we'll use yarn to pull it in. 2017-06-23 09:35:56 +01:00
Murtuza Zabuawala 0ab637c7ab Fix import/export to work as expected with TSV data. Fixes #1934 2017-06-22 13:57:32 +01:00
Ashesh Vashi d26337a1ba Moved the javascripts of the following browser node modules to the
'static' directory from 'templates' in the respective module directory:
- Server Group
- Server
- Database
- Schema
- Cast
- Event trigger
- Extension
- Foreign data wrapper
- Language
- Catalog Object
- Collation
- Domain Constraint
- Domain
- Foreign server
- FTS Configuration
- FTS Dictionary
- FTS Parser
- FTS Template
- Function
- Procedure
- Trigger Function
- Package
- Sequence
- Catalog
- Schema
- Synonym
- Table
- Type
- Materialized View
- View
- pgAgent Modules
  + Job (pga_job)
  + Schedule (pga_schedule)
  + Steps (pga_jobstep)

Added new dynanic modules for listing the supported server types, and
current user information.

NOTE: We've not yet moved the javascripts for the children of the table
module.
2017-06-22 15:58:32 +05:30
Murtuza Zabuawala f0202228d0 Increase the default size of the Grant Wizard to enable it to properly display privileges at the default size on smaller displays. Fixes #2013 2017-06-21 11:08:23 +01:00
Ashesh Vashi 5c140b3f58 Using client-side 'url_for' implementation in the user management
module.
2017-06-16 00:16:30 +05:30
Ashesh Vashi e65b605912 Using client-side 'url_for' implementation in the import/export module. 2017-06-16 00:00:17 +05:30
Ashesh Vashi 07580b8444 Using client-side 'url_for' implementation in the maintenance module. 2017-06-15 23:50:53 +05:30
Surinder Kumar 2a87585665 Fix script options which were inadvertently broken in the query tool tab naming patch. 2017-06-15 12:19:47 +01:00
Murtuza Zabuawala 8376d33d77 Fix canceling of Grant Wizard on Windows. Fixes #2142 2017-06-15 11:42:13 +01:00
Surinder Kumar fdc9eed514 Ensure text editors render in an appropriate place on the results grid. Fixes #2477 2017-06-14 12:18:27 +01:00
Surinder Kumar 57d866f7b7 Use a more sensible name for Query Tool tabs. Fixes #2482 2017-06-13 11:34:24 +01:00
Shruti B Iyer 1208206bc0 Initial re-vamp of the History tab. 2017-06-13 09:50:41 +01:00
Ashesh Vashi 0243d886c3 Using client-side 'url_for' implementation in the Grant-Wizard module. 2017-06-13 11:47:55 +05:30
Ashesh Vashi f9a3878220 Using client-side 'url_for' implementation in the restore module. 2017-06-13 11:00:17 +05:30
Ashesh Vashi 4a46f7b1eb Using client-side 'url_for' implementation in the backup module. 2017-06-13 10:59:11 +05:30
Surinder Kumar af43ccfc07 Teach dialogues about Escape to cancel, Enter to Save/OK, and F1 for help. Fixes #1535 2017-06-12 16:43:29 +01:00
Murtuza Zabuawala 3743c6e86e Refresh the SQL editor view on resize to ensure the contents are re-rendered for the new viewport. Fixes #2078 2017-06-12 13:25:52 +01:00
Surinder Kumar 49976b1934 Fine tune result grid column sizing now we don't have checkboxes. 2017-06-09 09:24:20 +01:00
Surinder Kumar 73c6f1ca3b A little leanup of the styling of the edit grid 2017-06-08 17:06:34 +01:00
Sarah McAlear 01bfa88309 Improvements to the Query Results grid:
- Improve the UI
- Allow copy/paste from sets of rows, columns or arbitrary blocks of cells

Patch by Matt, Shruti, Joao and Sarah @ Pivotal

Fixes #2476
2017-06-08 13:31:36 +01:00
Surinder Kumar 2fddf750e6 Retain column sizing in the query tool results grid when the same query is re-run multiple times in a row. Fixes #1971 2017-06-08 12:41:56 +01:00
George Gelashvili 8d8e7dab3c Extract row staging into it's own module with tests. 2017-06-07 14:17:10 +01:00
Shruti B Iyer 0d05385585 Update the styling to use the set of grays defined in the WIP style guide. 2017-06-07 13:57:49 +01:00
Ashesh Vashi ae80976689 Using the client-side translation using the client-side 'gettext'
implementation.

This is the first step towards 'Avoid creating the javascript modules
using Jinja templates'.
2017-06-07 15:53:05 +05:30
Murtuza Zabuawala 7e9f82bc17 Prevent attempts to debug procedures with variadic arguments. Fixes #1466 2017-06-06 12:58:52 +01:00
Khushboo Vashi d21cbb8b1f Handle composite primary keys correctly when deleting rows in the Edit Grid. Fixes #2425 2017-06-06 09:58:47 +01:00
Surinder Kumar 456096092d Avoid re-rendering the edit grid for every row that is pasted. 2017-05-30 16:22:11 +01:00
Surinder Kumar 1f26953504 Cleanup handling of default/null values when data editting. FIxes #2400 2017-05-27 14:51:02 -04:00
Murtuza Zabuawala 8aabee352c Import the ordereddict module for Python 2.6 2017-05-26 12:34:05 -04:00
Murtuza Zabuawala dba64e77f1 Order columns in multi-column pkeys correctly. Fixes #2417 2017-05-26 11:04:32 -04:00
Surinder Kumar 1db81da020 Fix JS error when selecting a single grid cell. 2017-05-16 08:44:29 +01:00
Surinder Kumar d7d4bf475b Various improvements to the NULL/DEFAULT handling in the data editor. Fixes #2399 2017-05-15 15:04:16 +01:00
Murtuza Zabuawala 1cb2a62fa8 Ensure object names are properly escaped for external process management. Fixes #2405 2017-05-15 13:01:12 +01:00
Surinder Kumar 0e7efc0cf8 Track disabled rows properly in the edit grid. 2017-05-12 16:42:06 +01:00
Dave Page dd318e679d Minor colour tweaks for highlighted rows in the data editor. These are likely to be changed again when we overhaul and standardise the colouring, but at least now they're using colours from the style guide. 2017-05-12 11:29:46 +01:00
Surinder Kumar 4f9628ed43 Improve handling of nulls and default values in the data editor. Fixes #2257 2017-05-12 10:53:57 +01:00
Murtuza Zabuawala 13f4432bbd Support loading files with Unicode BOMs. Fixes #2369 2017-05-09 12:06:49 +01:00
Neel Patel d0e9c82fea Fixes #2328
1) Fixed issue of opening Query Tool and Debugger in new Tab with QT 5.8 and annulen webkit
 2) Moved unload event of window from javascript files to html.
 3) Change alertify messages for debugger.
 4) Closed all connections created by debugger. Previously only one connection has been closed.
2017-05-09 13:03:44 +05:30
Murtuza Zabuawala 63d42745ef Fix various issues in CSV file download feature:
1) To handle non-ascii filenames which we set from table name. Fixes #2314

2) To handle non-ascii query data. Fixes #2253

3) To dump JSON type columns properly in csv. Fixes #2360
2017-05-08 13:36:11 +01:00
Murtuza Zabuawala 155348d712 Fix the Backup module where it was not working if user changes its preference language other than english. Fixes #2354 2017-05-04 16:06:10 +01:00
Surinder Kumar 93df5e3e54 Ensure errors thrown when deleting rows in the query tool in edit mode are shown properly. Fixes #2356 2017-05-02 12:20:30 +01:00
Murtuza Zabuawala 928c0d3de8 startsWith() function of java script is not supported in IE, instead use startsWith() function of underscore string. Fixes #2347 2017-04-25 12:00:15 +05:30
Joao Pedro De Almeida Pereira f718e1f49c Only display the header row in SlickGrid where columns actually exist. 2017-04-24 20:26:59 +01:00
Matthew Kleiman d663d553c5 Allow column or row selection in the query tool. Fixes #2216 2017-04-18 13:28:45 +01:00
Murtuza Zabuawala a2a2b8b888 Ensure the query tool displays but does not render HTML returned by the server in the results grid. Fixes #2330. 2017-04-10 14:07:48 +01:00
RAJASEKAR G c758920890 Properly handle EXPLAIN queries entered directly by the user in the query tool. Fixes #2287 2017-04-06 09:46:42 +01:00
Jonas Thelemann 37120bf199 (De)Capitalized strings to fit the common/usual format, corrected spelling, removed unnecessary characters. 2017-04-05 13:50:49 +01:00
Jonas Thelemann 65f21a8cd7 Replace all occurrences of "can not" with "cannot". 2017-04-05 13:38:14 +01:00
Khushboo Vashi efb077b7f7 Fix error highlighting in the query tool. Fixes #2291 2017-03-31 20:06:55 -04:00
Maxim Zakharov 8005b05292 Fixes #2304, #2145 - Resolve the issue for restoring the table from the backup.
Earlier - implementation was generating the backup code like as below:
XXX/pg_restore.exe --host "x.x.x.x" --port "xxxx" --username "osboxes" --no-password --dbname "test" --data-only --verbose --table "tt.test2" "XXX-FILE.bak"

It should have been:
XXX/pg_restore.exe --host "x.x.x.x" --port "xxxx" --username "osboxes" --no-password --dbname "test" --data-only --verbose --schema "tt" --table "test2" "XXX-FILE.bak"
2017-03-31 13:16:17 +05:30
Joao Pedro De Almeida Pereira eb89998dc0 From a visual standpoint, grey highlight makes selection look deselected rather than selected. A brighter color would quickly provide visual feedback on an action.
With this patch the color of selected rows look more highlighted.
2017-03-30 22:56:13 -04:00
Dave Page 6152d73f13 Fix some code inspection complaints 2017-03-25 22:04:52 -04:00
Dave Page a6fa35789c Fix broken markup 2017-03-25 22:04:52 -04:00
Akshay Joshi 569ceb3906 Modify the web code to allow the Query Tool and Debugger to be opened in new tabs, per settings in Preferences. Fixes #1344
Note that this does *not* enable the runtime to use multiple windows at this stage. It's really only useful in Server mode.
2017-03-24 14:43:56 +00:00
Wayne Winch Jr 5f2a15dd6d Fix deletion of rows where the primary key isn't at ordinal zero. Fixes #2274 2017-03-24 13:32:56 +00:00
Murtuza Zabuawala d4e88217eb Added timeout in _wait_timeout function in our psycopg2 module.
Fixes debugger module, Added common function to covert 2d array data to dict for BackGrid.
2017-03-24 14:01:59 +05:30
Harshal Dhumal 2142824448 PRevent an error being displayed if the user views data on a table with no columns. Fixes #2244 2017-03-21 16:40:21 +00:00
Surinder Kumar aee1492d0d Correct some EDB Postgres Advanced Server branding. 2017-03-21 10:12:26 +00:00
Ashesh Vashi 4eafdbeff6 Resolved a typo - show a '?' after the 'Show timing' preference. 2017-03-21 11:17:35 +05:30
Murtuza Zabuawala 461086c17d Fix View Data filter options. Fixes #2265 2017-03-17 12:45:59 +00:00
Dave Page 648c332488 Import from flask_babel instead of the deprecated flask.ext.babel. Fixes #2264 2017-03-17 10:22:41 +00:00
Atira Odhner ae0d8e89eb Fix the path to JS 2017-03-15 17:12:58 +00:00
Atira Odhner 889050b71d Fix quotes to ensure we have valid JS. 2017-03-15 17:11:53 +00:00
Atira Odhner 172b41cba8 Refactor clipboard copying into a separate file for use outside the SQL Editor. 2017-03-15 17:11:11 +00:00
Atira Odhner 4445f9dd63 Add a mechanism for centralising JS translations, to avoid having to render many JS files with Jinja. 2017-03-15 17:10:22 +00:00
Atira Odhner 28deb34283 Remove some dead code. 2017-03-10 10:27:17 +00:00
Murtuza Zabuawala bc63652811 Fix the issue where Import/Export was failing in linux runtime. Fixes #2166
Issue:
Changes done by Ashesh in pgAdmin4.py file for setting up PYTHONHOME variable to sys.prefix was applicable only for windows only.

Additionally I have also added exception handling for file provided by user for Backup/Restore/Import/Export.
2017-03-09 09:54:55 +00:00
Murtuza Zabuawala 533833cb02 Cleanup some ugly code formatting. 2017-03-09 09:27:41 +00:00
Dave Page fb44ffffa0 Fix a couple of translation issues, and remove the test French translation files. 2017-03-08 10:13:15 +00:00
Jonas Thelemann c34f5fd2d4 Use "could not" consistently, instead of "couldn't" which was used in some places. 2017-03-07 10:29:54 +00:00
Ashesh Vashi f2fc1ceba8 Resolved quite a few file-system encoding/decoding related cases.
In order to resolve the non-ascii characters in path (in user directory,
storage path, etc) on windows, we have converted the path into the
short-path, so that - we don't need to deal with the encoding issues
(specially with Python 2).

We've resolved majority of the issues with this patch.
We still need couple issues to resolve after this in the same area.

TODO
* Add better support for non-ascii characters in the database name on
  windows with Python 3
* Improve the messages created after the background processes by
  different modules (such as Backup, Restore, Import/Export, etc.),
  which does not show short-paths, and xml representable characters for
  non-ascii characters, when found in the database objects, and the file
  PATH.

Fixes #2174, #1797, #2166, #1940

Initial patch by: Surinder Kumar
Reviewed by: Murtuza Zabuawala
2017-03-07 15:31:03 +05:30
Murtuza Zabuawala 480e00fddf Query tool efficiency.Convert the data as a 2D array instead of dict. Fixes #2036
Incremental back off when polling. Fixes #2038

Initial Patch By: Dave Page
2017-03-01 16:58:51 +05:30
Dave Page 3638d63330 Move pgadmin plugins for codemirror back out of the vendor area. 2017-02-27 13:18:28 +00:00
Sarah McAlear a0a31e55ae Move 3rd party client code into vendor/ directories for ease of maintenance. 2017-02-24 17:01:21 +00:00
Dave Page b19081421b Ensure primary key column names are quoted in View Data mode of the Query Tool. Fixes #2208 2017-02-24 13:58:23 +00:00
Murtuza Zabuawala 89137f57b2 Display un-sized varlen column types correctly in the query tool. Fixes #2151 2017-02-21 13:12:50 +00:00
Murtuza Zabuawala a914ea088c Python 2.6 compatibility fixes. 2017-02-08 16:28:04 +00:00
Surinder Kumar 4566877188 Handle NULL booleans in the data editor. Fixes #1790 2017-02-05 11:06:48 +01:00
Surinder Kumar 54ba1fbe59 Support setting text fields to empty strings or NULL in the data editor grid. Fixes #1790 2017-02-04 14:10:30 +01:00
Harshal Dhumal 4ef26a528b Allow direct navigation (i.e. typing of paths) in the file manager. Fixes #1911 2017-02-03 10:51:36 +01:00
George Gelashvili 6d05302ca1 Rename the 9.1_plus templates to "default" to more appropriately support Greenplum which is based on 8.3. 2017-02-01 09:57:49 +00:00
George Gelashvili 19be3529f8 Create a template loader for SQL templates.
This will automatically find the correct version of a template for the server version, and allows us to remove templates that were previously duplicated for different server versions.

Patch by George & Tira at Pivotal. Review by me and Murtuza from EDB.

Discussion: https://www.postgresql.org/message-id/flat/CAHowoHaU9_pkCt%2B1g8dpY3hsXXZmsJZiJH-3-_Hd%2BC1MxiGhtA%40mail.gmail.com#CAHowoHaU9_pkCt+1g8dpY3hsXXZmsJZiJH-3-_Hd+C1MxiGhtA@mail.gmail.com
2017-01-30 11:25:03 +00:00
Neel Patel d87345ef52 Ensure breakpoints are cleared properly when clearing all of them. Fixes #1745 2017-01-08 19:05:13 +05:30
Murtuza Zabuawala bdf9761472 Improve consistency of dialogue controls offered. Fixes #1364 2017-01-08 16:05:34 +05:30
Neel Patel a33ee2ae32 Improve detection of the pldbgapi extension and functions before allowing debugging. Fixes #2026 2017-01-08 15:27:58 +05:30
Akshay Joshi ae809c4506 Properly detect when files have changed in the query tool and set the dirty flag accordingly. Fixes #1807
Note that (like pgAdmin 3) we don't make any attempt to detect if all changes have been undone and completely reverted as that could be very expensive with large scripts.
2017-01-08 15:27:58 +05:30
Dave Page f221194bcc Update copyright notices for 2017. 2017-01-04 13:33:32 +00:00
Dave Page 87d4937726 Minimise memory requirements for rendered cells and rows in SlickGrid. Fixes #2035
- The CSS class 'slick-row' has been renamed to 'sr'

- The CSS class 'slick-cell' has been renamed to 'sc'

- The SQL Editor included an unused 'normal_row' class on each row which has been removed as it was unreferenced in the code or CSS.

The intent of these changes is to minimise memory usage by the grid, by saving a few bytes per row/cell.
It's questionable how much difference this actually makes given that SlickGrid updates the document so it
only includes the visible rows on the fly, but every little helps.
2016-12-22 17:43:42 +00:00
Dave Page d3862eef3f Fix some additional table styling inconsistencies. 2016-12-19 14:26:33 +00:00
Khushboo Vashi 5008872203 Ensure the SQL editor has enough space to show block folding arrows in the gutter. 2016-12-19 11:35:27 +00:00
Harshal Dhumal 5adc6b71ca fix display of double scrollbars on the grant wizard. Fixes #2028 2016-12-19 09:25:14 +00:00
Murtuza Zabuawala 6fc8f040ff Allow users to enable wrapping of code in SQL boxes. Fixes#2025 2016-12-16 17:07:41 +00:00
Khushboo Vashi 53ea991907 Properly size the SQL Editor gutter as the width of the line numbers increases. Fixes #1780 2016-12-16 13:04:16 +00:00
Akshay Joshi 686237413c Use more sensible column sizes for the data output in the query tool. Fixes #1789
Per Akshay:

I have tried to get the width of the content but we are sending complete data as collection to the SlickGrid. We will have to fetch the content of each column and figure out the maximum length for that column by iterating all the rows is too expensive. Apart from that to set the width in 'ch' we will have to do it using css. With current implementation we are setting the column option of the SlickGrid from javascript code.

I have fixed this issue by setting the width of the columns based on data type. I have set the width of boolean column to 60, all the numeric/integer columns to 80 and for all other data types it is 20% of the container width as 33% is too wide.
2016-12-12 10:13:53 +00:00
Khushboo Vashi 53481023fa Properly sort rows by the pkey when viewing first/last 100. Fixes #2007 2016-12-12 10:06:34 +00:00
Dave Page 4a280b2517 Only show the filename in query tool tabs, not the whole path. 2016-12-09 12:42:30 +00:00
Akshay Joshi b8d03d5dc2 Don't cast data when saving in the edit grid, so errors are seen and data doesn't get silently modified. Fixes #1994 2016-12-09 12:05:46 +00:00
Khushboo Vashi 81841cdb3c Treat databases with datallowconn=false appropriately. Fixes #1801 2016-12-09 11:59:13 +00:00