From 5e896927ccb0df351239d670f1ebf70d92c5c2a4 Mon Sep 17 00:00:00 2001 From: Daniel Vaz Gaspar Date: Thu, 10 Sep 2020 13:52:32 +0100 Subject: [PATCH] fix(js): select2 readonly not working (#1467) --- flask_appbuilder/static/appbuilder/js/ab.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/flask_appbuilder/static/appbuilder/js/ab.js b/flask_appbuilder/static/appbuilder/js/ab.js index 5ee11ecf31..3f55266f46 100644 --- a/flask_appbuilder/static/appbuilder/js/ab.js +++ b/flask_appbuilder/static/appbuilder/js/ab.js @@ -51,9 +51,9 @@ $(function() { $('.appbuilder_date').datetimepicker({ pickTime: false }); $(".my_select2").select2({placeholder: "Select a State", allowClear: true}); + $(".my_select2.readonly").select2("readonly", true); loadSelectData(); loadSelectDataSlave(); - $(".my_select2.readonly").attr("readonly", "readonly"); $("a").tooltip({container:'.row', 'placement': 'bottom'}); });