Hi All,
Is there possibility to limit the creation of document 2 per day, We are trying to Limit user of adding Employee Checkin only 2/day.
Is possible to client script can do this, something disable the button if you reach 2 document.
Here’s my Custom Script
frappe.ui.form.on(‘Employee Checkin’, {
refresh: function(frm) {
if (added_row && added_row.length==2) {
setTimeout(() => {
cur_frm.set_df_property(‘Add Employee Checkin’, ‘hidden’, true);
}, 10);
}
}
});
Thanks