mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-20 11:48:31 -06:00
Fix RE-SQL for triggers with a single arg. Fixes #2668
This commit is contained in:
parent
821442ed8f
commit
52840d68a8
@ -952,7 +952,7 @@ class TriggerView(PGChildNodeView):
|
||||
# We know that trigger has more than 1 argument, let's join them
|
||||
data['tgargs'] = self._format_args(data['custom_tgargs'])
|
||||
|
||||
if len(data['tgattr']) > 1:
|
||||
if len(data['tgattr']) >= 1:
|
||||
columns = ', '.join(data['tgattr'].split(' '))
|
||||
data['columns'] = self._column_details(tid, columns)
|
||||
|
||||
|
@ -995,7 +995,7 @@ class BaseTableView(PGChildNodeView):
|
||||
# We know that trigger has more than 1 argument, let's join them
|
||||
data['tgargs'] = self._format_args(data['custom_tgargs'])
|
||||
|
||||
if len(data['tgattr']) > 1:
|
||||
if len(data['tgattr']) >= 1:
|
||||
columns = ', '.join(data['tgattr'].split(' '))
|
||||
|
||||
SQL = render_template("/".join([self.trigger_template_path,
|
||||
@ -1009,7 +1009,7 @@ class BaseTableView(PGChildNodeView):
|
||||
columns = []
|
||||
|
||||
for col_row in rset['rows']:
|
||||
columns.append({'column': col_row['name']})
|
||||
columns.append(col_row['name'])
|
||||
|
||||
data['columns'] = columns
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user