Hi, PFA patches to fix the issues in SQL Editor & Function nodes.
1) Add handling of DATERANGE[] type RM#2258 2) "By Selection" and "Exclude selection" filter options was broken due to 2d array data conversion. RM#2265 3) Barces are missing on function parameters on SQL tab. RM#2246 Please review. -- Regards, Murtuza Zabuawala EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company
diff --git a/web/pgadmin/browser/server_groups/servers/databases/schemas/functions/__init__.py b/web/pgadmin/browser/server_groups/servers/databases/schemas/functions/__init__.py index d2a787f..96dcec5 100644 --- a/web/pgadmin/browser/server_groups/servers/databases/schemas/functions/__init__.py +++ b/web/pgadmin/browser/server_groups/servers/databases/schemas/functions/__init__.py @@ -996,16 +996,16 @@ class FunctionView(PGChildNodeView, DataTypeReader): func_def=name_with_default_args, query_for="sql_panel") - sql_header = u"""-- {0}: {1}{2} + sql_header = u"""-- {0}: {1}({2}) --- DROP {0} {1}{2}; +-- DROP {0} {1}({2}); """.format(object_type.upper(), self.qtIdent( self.conn, resp_data['pronamespace'], resp_data['proname']), - resp_data['proargtypenames']) + resp_data['proargtypenames'].lstrip('(').rstrip(')')) SQL = sql_header + func_def SQL = re.sub('\n{2,}', '\n\n', SQL)
diff --git a/web/pgadmin/utils/driver/psycopg2/__init__.py b/web/pgadmin/utils/driver/psycopg2/__init__.py index 18be00e..b76209f 100644 --- a/web/pgadmin/utils/driver/psycopg2/__init__.py +++ b/web/pgadmin/utils/driver/psycopg2/__init__.py @@ -56,8 +56,8 @@ psycopg2.extensions.register_type( ( # To cast bytea and interval type 17, 1186, - # to cast int4range, int8range, numrange tsrange, tstzrange - 3904,3926, 3906, 3908, 3910, 3912, + # to cast int4range, int8range, numrange tsrange, tstzrange, daterange + 3904,3926, 3906, 3908, 3910, 3912, 3913, # date, timestamp, timestamptz, bigint, double precision 1700, 1082, 1114, 1184, 20, 701 ),
diff --git a/web/pgadmin/tools/sqleditor/templates/sqleditor/js/sqleditor.js b/web/pgadmin/tools/sqleditor/templates/sqleditor/js/sqleditor.js index d0ad28e..fe6aaef 100644 --- a/web/pgadmin/tools/sqleditor/templates/sqleditor/js/sqleditor.js +++ b/web/pgadmin/tools/sqleditor/templates/sqleditor/js/sqleditor.js @@ -2705,7 +2705,7 @@ define( return; // Add column position and it's value to data - data[column_info.pos] = _values[column_info.pos] || ''; + data[column_info.field] = _values[column_info.pos] || ''; self.trigger( 'pgadmin-sqleditor:loading-icon:show', @@ -2775,7 +2775,7 @@ define( return; // Add column position and it's value to data - data[column_info.pos] = _values[column_info.pos] || ''; + data[column_info.field] = _values[column_info.pos] || ''; self.trigger( 'pgadmin-sqleditor:loading-icon:show',
-- Sent via pgadmin-hackers mailing list (pgadmin-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgadmin-hackers