Browse Source

Fix count of unused items and update on all transactions

Neal Wilson 6 years ago
parent
commit
06808861ac
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      config/Windows/navigation.xml

+ 2
- 2
config/Windows/navigation.xml View File

764
             query.exec("SELECT name FROM coffees WHERE id NOT IN (SELECT item FROM use) AND quantity > 0");
764
             query.exec("SELECT name FROM coffees WHERE id NOT IN (SELECT item FROM use) AND quantity > 0");
765
             var c = 0;
765
             var c = 0;
766
             if(query.next()) {
766
             if(query.next()) {
767
-                c += 1;
768
                 startCell(output, TTR("navwindow", "Unused Coffees"));
767
                 startCell(output, TTR("navwindow", "Unused Coffees"));
769
                 startStage(output);
768
                 startStage(output);
770
                 do {
769
                 do {
770
+                    c += 1;
771
                     output.writeTextElement("p", query.value(0));
771
                     output.writeTextElement("p", query.value(0));
772
                 } while(query.next());
772
                 } while(query.next());
773
                 endStage(output);
773
                 endStage(output);
793
         schedulenotification.notify.connect(function() {
793
         schedulenotification.notify.connect(function() {
794
             refresh();
794
             refresh();
795
         });
795
         });
796
-        var lognotification = Application.subscribe("roastinglogchange");
796
+        var lognotification = Application.subscribe("transactionschange");
797
         lognotification.notify.connect(function() {
797
         lognotification.notify.connect(function() {
798
             refresh();
798
             refresh();
799
         });
799
         });

Loading…
Cancel
Save