Skip to content

Commit

Permalink
fix: consider now datetime if the default value is now for datetime f…
Browse files Browse the repository at this point in the history
…ield

(cherry picked from commit 5bbb9b4)
  • Loading branch information
phot0n authored and mergify[bot] committed Oct 19, 2022
1 parent 5c0bb7e commit b42013c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions frappe/public/js/frappe/form/controls/datetime.js
Expand Up @@ -7,6 +7,8 @@ frappe.ui.form.ControlDatetime = class ControlDatetime extends frappe.ui.form.Co
return;
} else if (value === "Today") {
value = this.get_now_date();
} else if (value.toLowerCase() === "now") {
value = frappe.datetime.now_datetime();
}
value = this.format_for_input(value);
this.$input && this.$input.val(value);
Expand Down

0 comments on commit b42013c

Please sign in to comment.