From d3ff23ddfeb38e91cde3c90e479f56baeaaf754a Mon Sep 17 00:00:00 2001 From: Dan Sosedoff Date: Sat, 3 Dec 2022 15:21:17 -0600 Subject: [PATCH] Add context menu for materialized views --- static/js/app.js | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/static/js/app.js b/static/js/app.js index 1a50af6..341ae10 100644 --- a/static/js/app.js +++ b/static/js/app.js @@ -1177,6 +1177,19 @@ function bindContextMenus() { } }); } + + if (group == "materialized_view") { + $(el).contextmenu({ + target: "#view_context_menu", + scopes: "li.schema-materialized_view", + onItem: function(context, e) { + var el = $(e.target); + var table = getQuotedSchemaTableName($(context[0]).data("id")); + var action = el.data("action"); + performViewAction(table, action, el); + } + }); + } }); }