Browse Source

HUE-8262 [dashboard] Disable droppable area of the empty Gridster widget

Enrico Berti 7 years ago
parent
commit
61b42fbf79
1 changed files with 1 additions and 1 deletions
  1. 1 1
      desktop/core/src/desktop/templates/common_dashboard.mako

+ 1 - 1
desktop/core/src/desktop/templates/common_dashboard.mako

@@ -223,7 +223,7 @@
           <a href="javascript:void(0)" class="remove-widget" data-bind="publish: { 'gridster.remove': $data }"><i class="fa fa-times"></i></a>
           <a href="javascript:void(0)" class="remove-widget" data-bind="publish: { 'gridster.remove': $data }"><i class="fa fa-times"></i></a>
         </div>
         </div>
       </h2>
       </h2>
-      <div class="empty-content" data-bind="droppable: { data: function(w) { huePubSub.publish('gridster.empty.drop', { widget: w, target: $data }); }, options: { greedy:true, hoverClass: 'droppable-hover', drop: function(){ huePubSub.publish('gridster.added.widget'); } }}, css: { 'query-builder': $root.isQueryBuilder }">
+      <div class="empty-content" data-bind="droppable: { data: function(w) { huePubSub.publish('gridster.empty.drop', { widget: w, target: $data }); }, options: { disabled: $root.hasNewAdd(), greedy: true, hoverClass: 'droppable-hover', drop: function(){ huePubSub.publish('gridster.added.widget'); } }}, css: { 'query-builder': $root.isQueryBuilder }">
         % if USE_NEW_ADD_METHOD.get():
         % if USE_NEW_ADD_METHOD.get():
         <!-- ko with: emptyProperties -->
         <!-- ko with: emptyProperties -->
         <div class="edit-dimensions">
         <div class="edit-dimensions">