Suppress the redundant loading indicator
authorAlexander Ebert <ebert@woltlab.com>
Mon, 9 May 2022 12:17:55 +0000 (14:17 +0200)
committerAlexander Ebert <ebert@woltlab.com>
Mon, 9 May 2022 12:17:55 +0000 (14:17 +0200)
See https://www.woltlab.com/community/thread/295539-doppelte-ladebalken/

ts/WoltLabSuite/Core/Ui/User/Menu/Data/ModerationQueue.ts
ts/WoltLabSuite/Core/Ui/User/Menu/Data/Notification.ts
wcfsetup/install/files/js/WoltLabSuite/Core/Ui/User/Menu/Data/ModerationQueue.js
wcfsetup/install/files/js/WoltLabSuite/Core/Ui/User/Menu/Data/Notification.js

index bbbe95c57f264b71b22c3515fe93e9c24abbc41a..9602a1f110644f417cc17fada0cbbc6ccb4c3c42 100644 (file)
@@ -63,10 +63,9 @@ class UserMenuDataModerationQueue implements UserMenuProvider {
   }
 
   async getData(): Promise<UserMenuData[]> {
-    const data = (await dboAction(
-      "getModerationQueueData",
-      "wcf\\data\\moderation\\queue\\ModerationQueueAction",
-    ).dispatch()) as UserMenuData[];
+    const data = (await dboAction("getModerationQueueData", "wcf\\data\\moderation\\queue\\ModerationQueueAction")
+      .disableLoadingIndicator()
+      .dispatch()) as UserMenuData[];
 
     const counter = data.filter((item) => item.isUnread).length;
     this.updateCounter(counter);
index 494a128ea292e8bd00af27c2abc136459c628fa6..04a4c296c2d459136c656a09ed477ae0a86cacaa 100644 (file)
@@ -177,10 +177,9 @@ class UserMenuDataNotification implements DesktopNotifications, UserMenuProvider
   }
 
   async getData(): Promise<UserMenuData[]> {
-    const data = (await dboAction(
-      "getNotificationData",
-      "wcf\\data\\user\\notification\\UserNotificationAction",
-    ).dispatch()) as UserMenuData[];
+    const data = (await dboAction("getNotificationData", "wcf\\data\\user\\notification\\UserNotificationAction")
+      .disableLoadingIndicator()
+      .dispatch()) as UserMenuData[];
 
     const counter = data.filter((item) => item.isUnread).length;
     this.updateCounter(counter);
index 7548a9ab630fdb4cc29ea9f3620569135ed28f47..76f1b6d905e9b8c7f203e9ecf7556a5c05f8a9af 100644 (file)
@@ -41,7 +41,9 @@ define(["require", "exports", "tslib", "../../../../Ajax", "../View", "../Manage
             ];
         }
         async getData() {
-            const data = (await (0, Ajax_1.dboAction)("getModerationQueueData", "wcf\\data\\moderation\\queue\\ModerationQueueAction").dispatch());
+            const data = (await (0, Ajax_1.dboAction)("getModerationQueueData", "wcf\\data\\moderation\\queue\\ModerationQueueAction")
+                .disableLoadingIndicator()
+                .dispatch());
             const counter = data.filter((item) => item.isUnread).length;
             this.updateCounter(counter);
             this.stale = false;
index b216b9e008303d47dbe570ffc4be817945ee8988..3ede4ef56c8e6b1acf05554e490a87ea17a7eee9 100644 (file)
@@ -132,7 +132,9 @@ define(["require", "exports", "tslib", "../../../../Ajax", "../View", "../Manage
             return "com.woltlab.wcf.notifications";
         }
         async getData() {
-            const data = (await (0, Ajax_1.dboAction)("getNotificationData", "wcf\\data\\user\\notification\\UserNotificationAction").dispatch());
+            const data = (await (0, Ajax_1.dboAction)("getNotificationData", "wcf\\data\\user\\notification\\UserNotificationAction")
+                .disableLoadingIndicator()
+                .dispatch());
             const counter = data.filter((item) => item.isUnread).length;
             this.updateCounter(counter);
             this.stale = false;