mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
1) Port query tool to React. Fixes #6131
2) Added status bar to the Query Tool. Fixes #3253 3) Ensure that row numbers should be visible in view when scrolling horizontally. Fixes #3989 4) Allow removing a single query history. Refs #4113 5) Partially fixed Macros usability issues. Ref #6969 6) Fixed an issue where the Query tool opens on minimum size if the user opens multiple query tool Window quickly. Fixes #6725 7) Relocate GIS Viewer Button to the Left Side of the Results Table. Fixes #6830 8) Fixed an issue where the connection bar is not visible. Fixes #7188 9) Fixed an issue where an Empty message popup after running a query. Fixes #7260 10) Ensure that Autocomplete should work after changing the connection. Fixes #7262 11) Fixed an issue where the copy and paste row does not work if the first column contains no data. Fixes #7294
This commit is contained in:
committed by
Akshay Joshi
parent
bf8e569bde
commit
b5b9ee46a1
@@ -27,7 +27,7 @@ class TestDownloadCSV(BaseTestGenerator):
|
||||
'Download csv URL with valid query',
|
||||
dict(
|
||||
sql='SELECT 1 as "A",2 as "B",3 as "C"',
|
||||
init_url='/datagrid/initialize/query_tool/{0}/{1}/{2}/{3}',
|
||||
init_url='/sqleditor/initialize/sqleditor/{0}/{1}/{2}/{3}',
|
||||
donwload_url="/sqleditor/query_tool/download/{0}",
|
||||
output_columns='"A","B","C"',
|
||||
output_values='1,2,3',
|
||||
@@ -41,7 +41,7 @@ class TestDownloadCSV(BaseTestGenerator):
|
||||
'Download csv URL with wrong TX id',
|
||||
dict(
|
||||
sql='SELECT 1 as "A",2 as "B",3 as "C"',
|
||||
init_url='/datagrid/initialize/query_tool/{0}/{1}/{2}/{3}',
|
||||
init_url='/sqleditor/initialize/sqleditor/{0}/{1}/{2}/{3}',
|
||||
donwload_url="/sqleditor/query_tool/download/{0}",
|
||||
output_columns=None,
|
||||
output_values=None,
|
||||
@@ -55,7 +55,7 @@ class TestDownloadCSV(BaseTestGenerator):
|
||||
'Download csv URL with wrong query',
|
||||
dict(
|
||||
sql='SELECT * FROM this_table_does_not_exist',
|
||||
init_url='/datagrid/initialize/query_tool/{0}/{1}/{2}/{3}',
|
||||
init_url='/sqleditor/initialize/sqleditor/{0}/{1}/{2}/{3}',
|
||||
donwload_url="/sqleditor/query_tool/download/{0}",
|
||||
output_columns=None,
|
||||
output_values=None,
|
||||
@@ -69,7 +69,7 @@ class TestDownloadCSV(BaseTestGenerator):
|
||||
'Download as txt without filename parameter',
|
||||
dict(
|
||||
sql='SELECT 1 as "A",2 as "B",3 as "C"',
|
||||
init_url='/datagrid/initialize/query_tool/{0}/{1}/{2}/{3}',
|
||||
init_url='/sqleditor/initialize/sqleditor/{0}/{1}/{2}/{3}',
|
||||
donwload_url="/sqleditor/query_tool/download/{0}",
|
||||
output_columns='"A";"B";"C"',
|
||||
output_values='1;2;3',
|
||||
@@ -83,7 +83,7 @@ class TestDownloadCSV(BaseTestGenerator):
|
||||
'Download as csv without filename parameter',
|
||||
dict(
|
||||
sql='SELECT 1 as "A",2 as "B",3 as "C"',
|
||||
init_url='/datagrid/initialize/query_tool/{0}/{1}/{2}/{3}',
|
||||
init_url='/sqleditor/initialize/sqleditor/{0}/{1}/{2}/{3}',
|
||||
donwload_url="/sqleditor/query_tool/download/{0}",
|
||||
output_columns='"A","B","C"',
|
||||
output_values='1,2,3',
|
||||
@@ -211,7 +211,7 @@ class TestDownloadCSV(BaseTestGenerator):
|
||||
self.assertEqual(response.status_code, 500)
|
||||
|
||||
# Close query tool
|
||||
url = '/datagrid/close/{0}'.format(self.trans_id)
|
||||
url = '/sqleditor/close/{0}'.format(self.trans_id)
|
||||
response = self.tester.delete(url)
|
||||
self.assertEqual(response.status_code, 200)
|
||||
|
||||
|
||||
@@ -70,7 +70,7 @@ class TestEditorHistory(BaseTestGenerator):
|
||||
|
||||
# Initialize query tool
|
||||
self.trans_id = str(random.randint(1, 9999999))
|
||||
url = '/datagrid/initialize/query_tool/{0}/{1}/{2}/{3}'.format(
|
||||
url = '/sqleditor/initialize/sqleditor/{0}/{1}/{2}/{3}'.format(
|
||||
self.trans_id, utils.SERVER_GROUP, self.server_id, self.db_id)
|
||||
response = self.tester.post(url)
|
||||
self.assertEqual(response.status_code, 200)
|
||||
@@ -101,7 +101,7 @@ class TestEditorHistory(BaseTestGenerator):
|
||||
|
||||
def tearDown(self):
|
||||
# Close query tool
|
||||
url = '/datagrid/close/{0}'.format(self.trans_id)
|
||||
url = '/sqleditor/close/{0}'.format(self.trans_id)
|
||||
response = self.tester.delete(url)
|
||||
self.assertEqual(response.status_code, 200)
|
||||
|
||||
|
||||
@@ -262,7 +262,7 @@ class TestEncodingCharset(BaseTestGenerator):
|
||||
|
||||
# Initialize query tool
|
||||
self.trans_id = str(random.randint(1, 9999999))
|
||||
url = '/datagrid/initialize/query_tool/{0}/{1}/{2}/{3}'\
|
||||
url = '/sqleditor/initialize/sqleditor/{0}/{1}/{2}/{3}'\
|
||||
.format(self.trans_id, test_utils.SERVER_GROUP, self.encode_sid,
|
||||
self.encode_did)
|
||||
response = self.tester.post(url)
|
||||
@@ -283,7 +283,7 @@ class TestEncodingCharset(BaseTestGenerator):
|
||||
self.assertEqual(result, self.test_str)
|
||||
|
||||
# Close query tool
|
||||
url = '/datagrid/close/{0}'.format(self.trans_id)
|
||||
url = '/sqleditor/close/{0}'.format(self.trans_id)
|
||||
response = self.tester.delete(url)
|
||||
self.assertEqual(response.status_code, 200)
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@ class TestExplainPlan(BaseTestGenerator):
|
||||
|
||||
# Initialize query tool
|
||||
self.trans_id = str(random.randint(1, 9999999))
|
||||
url = '/datagrid/initialize/query_tool/{0}/{1}/{2}/{3}'.format(
|
||||
url = '/sqleditor/initialize/sqleditor/{0}/{1}/{2}/{3}'.format(
|
||||
self.trans_id, utils.SERVER_GROUP, self.server_id, self.db_id)
|
||||
response = self.tester.post(url)
|
||||
self.assertEqual(response.status_code, 200)
|
||||
@@ -68,7 +68,7 @@ class TestExplainPlan(BaseTestGenerator):
|
||||
self.assertEqual(len(response_data['data']['result'][0]), 1)
|
||||
|
||||
# Close query tool
|
||||
url = '/datagrid/close/{0}'.format(self.trans_id)
|
||||
url = '/sqleditor/close/{0}'.format(self.trans_id)
|
||||
response = self.tester.delete(url)
|
||||
self.assertEqual(response.status_code, 200)
|
||||
|
||||
|
||||
@@ -106,7 +106,7 @@ class TestMacros(BaseTestGenerator):
|
||||
|
||||
# Initialize query tool
|
||||
self.trans_id = str(random.randint(1, 9999999))
|
||||
url = '/datagrid/initialize/query_tool/{0}/{1}/{2}/{3}'.format(
|
||||
url = '/sqleditor/initialize/sqleditor/{0}/{1}/{2}/{3}'.format(
|
||||
self.trans_id, utils.SERVER_GROUP, self.server_id, self.db_id)
|
||||
response = self.tester.post(url)
|
||||
self.assertEqual(response.status_code, 200)
|
||||
@@ -150,7 +150,7 @@ class TestMacros(BaseTestGenerator):
|
||||
|
||||
def tearDown(self):
|
||||
# Close query tool
|
||||
url = '/datagrid/close/{0}'.format(self.trans_id)
|
||||
url = '/sqleditor/close/{0}'.format(self.trans_id)
|
||||
response = self.tester.delete(url)
|
||||
self.assertEqual(response.status_code, 200)
|
||||
|
||||
|
||||
@@ -77,7 +77,7 @@ NOTICE: Hello, world!
|
||||
|
||||
# Initialize query tool
|
||||
self.trans_id = str(random.randint(1, 9999999))
|
||||
url = '/datagrid/initialize/query_tool/{0}/{1}/{2}/{3}'.format(
|
||||
url = '/sqleditor/initialize/sqleditor/{0}/{1}/{2}/{3}'.format(
|
||||
self.trans_id, utils.SERVER_GROUP, self.server_id, self.db_id)
|
||||
response = self.tester.post(url)
|
||||
self.assertEqual(response.status_code, 200)
|
||||
@@ -110,7 +110,7 @@ NOTICE: Hello, world!
|
||||
cnt += 1
|
||||
|
||||
# Close query tool
|
||||
url = '/datagrid/close/{0}'.format(self.trans_id)
|
||||
url = '/sqleditor/close/{0}'.format(self.trans_id)
|
||||
response = self.tester.delete(url)
|
||||
self.assertEqual(response.status_code, 200)
|
||||
|
||||
|
||||
@@ -304,7 +304,7 @@ class TestTransactionControl(BaseTestGenerator):
|
||||
|
||||
def _initialize_query_tool(self):
|
||||
self.trans_id = str(random.randint(1, 9999999))
|
||||
url = '/datagrid/initialize/query_tool/{0}/{1}/{2}/{3}'.format(
|
||||
url = '/sqleditor/initialize/sqleditor/{0}/{1}/{2}/{3}'.format(
|
||||
self.trans_id, utils.SERVER_GROUP, self.server_id, self.db_id)
|
||||
response = self.tester.post(url)
|
||||
self.assertEqual(response.status_code, 200)
|
||||
@@ -339,6 +339,6 @@ class TestTransactionControl(BaseTestGenerator):
|
||||
utils.create_table_with_query(self.server, self.db_name, create_sql)
|
||||
|
||||
def _close_query_tool(self):
|
||||
url = '/datagrid/close/{0}'.format(self.trans_id)
|
||||
url = '/sqleditor/close/{0}'.format(self.trans_id)
|
||||
response = self.tester.delete(url)
|
||||
self.assertEqual(response.status_code, 200)
|
||||
|
||||
@@ -97,7 +97,7 @@ class TestViewData(BaseTestGenerator):
|
||||
|
||||
# Initialize query tool
|
||||
self.trans_id = str(random.randint(1, 9999999))
|
||||
url = '/datagrid/initialize/datagrid/{0}/3/table/{1}/{2}/{3}/{4}' \
|
||||
url = '/sqleditor/initialize/viewdata/{0}/3/table/{1}/{2}/{3}/{4}' \
|
||||
.format(self.trans_id, test_utils.SERVER_GROUP, self.server_id,
|
||||
self.db_id, table_id)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user