wip medication and db (sqlite)
This commit is contained in:
15
src/actions/medication/medication.task.ts
Normal file
15
src/actions/medication/medication.task.ts
Normal file
@@ -0,0 +1,15 @@
|
||||
import { CronJob } from "cron";
|
||||
import { MedicationService } from "actions/medication/medication.service";
|
||||
|
||||
const medicationService = new MedicationService();
|
||||
|
||||
new CronJob(
|
||||
"0 0 19 * * *", // cronTime
|
||||
async () => {
|
||||
console.log("askMedication()");
|
||||
await medicationService.askMedication();
|
||||
}, // onTick
|
||||
null, // onComplete
|
||||
true, // start
|
||||
"Europe/Berlin", // timeZone
|
||||
);
|
||||
Reference in New Issue
Block a user