feat(puchase history): purhcase history changed to long running no notification
This commit is contained in:
@@ -10,6 +10,7 @@ import {
|
||||
killOpendockSocket,
|
||||
opendockSocketMonitor,
|
||||
} from "../opendock/opendockSocketMonitor.utils.js";
|
||||
import { monitorAlplaPurchase } from "../purchase/purchase.controller.js";
|
||||
import {
|
||||
createCronJob,
|
||||
resumeCronJob,
|
||||
@@ -31,8 +32,24 @@ export const featureControl = async (data: Setting) => {
|
||||
createCronJob("opendockAptCleanup", "0 30 5 * * *", () =>
|
||||
dbCleanup("opendockApt", 90),
|
||||
);
|
||||
} else {
|
||||
}
|
||||
|
||||
if (data.name === "opendock_sync" && !data.active) {
|
||||
killOpendockSocket();
|
||||
stopCronJob("opendockAptCleanup");
|
||||
}
|
||||
|
||||
// purchase stuff
|
||||
if (data.name === "purchaseMonitor" && data.active) {
|
||||
monitorAlplaPurchase();
|
||||
}
|
||||
|
||||
if (data.name === "purchaseMonitor" && !data.active) {
|
||||
stopCronJob("purchaseMonitor");
|
||||
}
|
||||
|
||||
// this means the data time has changed
|
||||
if (data.name === "purchaseMonitor" && data.value) {
|
||||
monitorAlplaPurchase();
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user