Commit 475852689b7918336415cfd017a75cf0af648a4e
1 parent
d5873bf97d
Exists in
master
Perbaikan sementara pageSpoolCount (hardcoded queues)
Showing 1 changed file with 5 additions and 3 deletions Side-by-side Diff
lib/apiserver/routers/smstools.js
... | ... | @@ -45,13 +45,15 @@ function pageLog(req, res) { |
45 | 45 | } |
46 | 46 | |
47 | 47 | async function pageSpoolCount(req, res) { |
48 | - const outgoingCount = await smstoolsUtil.fileCountOnDir('/var/spool/sms/outgoing'); | |
49 | 48 | const checkedCount = await smstoolsUtil.fileCountOnDir('/var/spool/sms/checked'); |
49 | + const indosatCount = await smstoolsUtil.fileCountOnDir('/var/spool/sms/queue/indosat'); | |
50 | + const otherCount = await smstoolsUtil.fileCountOnDir('/var/spool/sms/queue/other'); | |
50 | 51 | |
51 | 52 | res.json({ |
52 | - outgoingCount, | |
53 | 53 | checkedCount, |
54 | - totalQueueCount: Number(outgoingCount) + Number(checkedCount), | |
54 | + indosatCount, | |
55 | + otherCount, | |
56 | + totalQueueCount: Number(checkedCount) + Number(indosatCount) + Number(otherCount), | |
55 | 57 | }); |
56 | 58 | } |
57 | 59 |