I have one more issue
I want to compare from date to the current date but the from date in Time log is of type datetype.
I appreciate if anyone can let me know how to extract date from from_date which is of type datetype?
Hi,
Can anyone tell me whats wrong with this code?
frappe.ui.form.on("Time Log", "validate", function(frm) {
var st_date=new Date(frm.doc.start_date);
var fr_date=new Date(frm.doc.from_time);
msgprint(fr_date); --gives null as output
msgprint(st_date); --gives the date
st_date=st_date.getDate();
fr_date=fr_date.getDate();
});
Below is the screenshot from where it should take values.