Update web for daily intervals
This commit is contained in:
@ -7,9 +7,9 @@ function get_interval(element) {
|
||||
|
||||
return {
|
||||
months: parseInt(months) || null,
|
||||
days: parseInt(days) || null,
|
||||
seconds:
|
||||
(parseInt(days) || 0) * 86400 +
|
||||
(parseInt(hours) || 0) * 3600 +
|
||||
(parseInt(hours) || 0) * 3600 +
|
||||
(parseInt(minutes) || 0) * 60 +
|
||||
(parseInt(seconds) || 0) || null,
|
||||
};
|
||||
@ -42,13 +42,6 @@ function update_interval(element) {
|
||||
minutes.value = String(remainder).padStart(2, "0");
|
||||
hours.value = String(Number(hours.value) + Number(quotient)).padStart(2, "0");
|
||||
}
|
||||
if (hours.value >= 24) {
|
||||
let quotient = Math.floor(hours.value / 24);
|
||||
let remainder = hours.value % 24;
|
||||
|
||||
hours.value = String(remainder).padStart(2, "0");
|
||||
days.value = Number(days.value) + Number(quotient);
|
||||
}
|
||||
}
|
||||
|
||||
const $intervalGroup = document.querySelector(".interval-group");
|
||||
|
@ -319,6 +319,7 @@ async function serialize_reminder(node, mode) {
|
||||
embed_fields: fields,
|
||||
expires: expiration_time,
|
||||
interval_seconds: mode !== "template" ? interval.seconds : null,
|
||||
interval_days: mode !== "template" ? interval.days : null,
|
||||
interval_months: mode !== "template" ? interval.months : null,
|
||||
name: node.querySelector('input[name="name"]').value,
|
||||
tts: node.querySelector('input[name="tts"]').checked,
|
||||
|
Reference in New Issue
Block a user