So based on what you just said, I think that the following js code will solve your issue, however, since I don't know what is your current environment, you will have to change the code to your needs:
// Always use a 24 hour format with this implementation.
function scheduleDailyConferences(timeArray) {
const offset = 60; // alert offset (1h prior in minutes)
const now = new Date();
const current = now.getHours() * 60 + now.getMinutes();
for (let time of timeArray) {
let tot = time.h * 60 + time.m - offset;
if (tot < current) continue;
tot -= current;
setTimeout(() => {
alert(`Your meeting starts in ${offset} minutes.`);
}, tot * 60 * 1000);
}
}
// assuming the following conferences of the day:
scheduleDailyConferences([
{ h: 13, m: 45 } // 1:45 pm
{ h: 4, m: 00 } // 4:00 pm
]);
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…