fix(Duration): save null for empty value
This commit is contained in:
parent
32ecbcca84
commit
d476cbdf84
1 changed files with 7 additions and 0 deletions
|
|
@ -4,6 +4,13 @@ frappe.ui.form.ControlDuration = class ControlDuration extends frappe.ui.form.Co
|
|||
this.make_picker();
|
||||
}
|
||||
|
||||
validate(value) {
|
||||
if(!value) {
|
||||
return null;
|
||||
}
|
||||
return super.validate(value);
|
||||
}
|
||||
|
||||
make_picker() {
|
||||
this.inputs = [];
|
||||
this.set_duration_options();
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue