diff --git a/js/src/database/routines.js b/js/src/database/routines.js index b39774105f..c47fc8fbed 100644 --- a/js/src/database/routines.js +++ b/js/src/database/routines.js @@ -3,9 +3,9 @@ AJAX.registerTeardown('database/routines.js', function () { $(document).off('click', 'a.ajax.edit_anchor'); $(document).off('click', 'a.ajax.exec_anchor'); $(document).off('click', 'a.ajax.export_anchor'); - $(document).off('click', '#rteListForm.ajax .mult_submit[value="export"]'); + $(document).off('click', '#bulkActionExportButton'); $(document).off('click', 'a.ajax.drop_anchor'); - $(document).off('click', '#rteListForm.ajax .mult_submit[value="drop"]'); + $(document).off('click', '#bulkActionDropButton'); $(document).off('change', 'select[name=item_type]'); $(document).off('change', 'select[name^=item_param_type]'); $(document).off('change', 'select[name=item_returntype]'); @@ -66,7 +66,7 @@ const DatabaseRoutines = { exportDialog: function ($this) { var $msg = Functions.ajaxShowMessage(); - if ($this.hasClass('mult_submit')) { + if ($this.attr('id') === 'bulkActionExportButton') { var combined = { success: true, title: Messages.strExport, @@ -850,7 +850,7 @@ AJAX.registerOnload('database/routines.js', function () { event.preventDefault(); DatabaseRoutines.exportDialog($(this)); }); - $(document).on('click', '#rteListForm.ajax .mult_submit[value="export"]', function (event) { + $(document).on('click', '#bulkActionExportButton', function (event) { event.preventDefault(); DatabaseRoutines.exportDialog($(this)); }); @@ -859,7 +859,7 @@ AJAX.registerOnload('database/routines.js', function () { event.preventDefault(); DatabaseRoutines.dropDialog($(this)); }); - $(document).on('click', '#rteListForm.ajax .mult_submit[value="drop"]', function (event) { + $(document).on('click', '#bulkActionDropButton', function (event) { event.preventDefault(); DatabaseRoutines.dropMultipleDialog($(this)); }); diff --git a/templates/database/routines/editor_form.twig b/templates/database/routines/editor_form.twig index 9cae29663d..74dd46aad3 100644 --- a/templates/database/routines/editor_form.twig +++ b/templates/database/routines/editor_form.twig @@ -7,7 +7,12 @@ {{ get_hidden_inputs(db) }}
- {% trans 'Details' %} + + {% trans 'Details' %} + {% if not is_edit_mode %} + {{ show_mysql_docu('CREATE_PROCEDURE') }} + {% endif %} + diff --git a/templates/database/routines/index.twig b/templates/database/routines/index.twig index c51ae8a119..d1d2f40da5 100644 --- a/templates/database/routines/index.twig +++ b/templates/database/routines/index.twig @@ -1,23 +1,42 @@ -
-
-
- {% trans "Filters" %} -
- - +
+

+ {{ get_icon('b_routines', 'Routines'|trans) }} + {{ show_mysql_docu('STORED_ROUTINES') }} +

+ +
+
+
+
+
+ + +
+
+ +
-
+
+ +
+
+ {{ get_image('b_search', 'Search'|trans) }} + +
+
+
- - - {{ get_hidden_inputs(db, table) }} - -
- - {% trans 'Routines' %} - {{ show_mysql_docu('STORED_ROUTINES') }} - + + {{ get_hidden_inputs(db, table) }}
{% trans 'There are no routines to display.' %} @@ -28,9 +47,9 @@
- + @@ -39,37 +58,5 @@ {{ rows|raw }}
{% trans 'Name' %}{% trans 'Action' %} {% trans 'Type' %} {% trans 'Returns' %}
- - {% if items is not empty %} -
- {% trans 'With selected:' %} - - - {% trans 'With selected:' %} - - - -
- {% endif %} -
- - -
- {% trans %}New{% context %}Create new routine{% endtrans %} -
- {% if has_privilege %} - - {{ get_icon('b_routine_add') }} - {% trans 'Add routine' %} - - {% else %} - {{ get_icon('bd_routine_add') }} - {% trans 'Add routine' %} - {% endif %} - {{ show_mysql_docu('CREATE_PROCEDURE') }} -
-
+ + diff --git a/templates/database/routines/row.twig b/templates/database/routines/row.twig index 62765d21ef..2c8a19be7a 100644 --- a/templates/database/routines/row.twig +++ b/templates/database/routines/row.twig @@ -6,6 +6,12 @@ {{ sql_drop }} {{ routine.name }} + + {{ routine.type }} + + + {{ routine.returns }} + {% if has_edit_privilege %} - {{ routine.returns }} -