]> git.ipfire.org Git - thirdparty/tvheadend.git/commitdiff
WEBUI: always reload grid (table) on delete request
authorJaroslav Kysela <perex@perex.cz>
Tue, 13 Oct 2015 06:47:00 +0000 (08:47 +0200)
committerJaroslav Kysela <perex@perex.cz>
Tue, 13 Oct 2015 06:50:17 +0000 (08:50 +0200)
src/webui/static/app/idnode.js

index 777eb3f03dac7f6d8fd0a4cbca101da1a7e23c15..c6d301b91c4d1b102e192264859d8f3713b98919 100644 (file)
@@ -1137,12 +1137,17 @@ tvheadend.idnode_grid = function(panel, conf)
     var idnode = null;
 
     var update = function(o) {
-        if ('delete' in o)
+        if ((o.create || 'delete' in o) && auto.getValue()) {
+            store.reload();
+            return;
+        }
+        if ('delete' in o) {
             Ext.each(o['delete'], function (d) {
                 var r = store.getById(d);
                 if (r)
                     store.remove(r);
             });
+        }
         if (o.change) {
             var ids = [];
             Ext.each(o.change, function(id) {
@@ -1168,8 +1173,6 @@ tvheadend.idnode_grid = function(panel, conf)
                 });
             }
         }
-        if (o.create && auto.getValue())
-            store.reload();
     };
 
     var update2 = function(o) {