2
0
mirror of https://github.com/frappe/books.git synced 2024-11-14 01:14:03 +00:00

Apply formula if readOnly always (#95)

This commit is contained in:
sahil28297 2018-09-25 17:45:10 +05:30 committed by Faris Ansari
parent fb4295a12b
commit 667a966769

View File

@ -251,11 +251,11 @@ module.exports = class BaseDocument extends Observable {
return true; return true;
function shouldApplyFormula (field, doc) { function shouldApplyFormula (field, doc) {
if (frappe.isServer) {
if (field.readOnly) { if (field.readOnly) {
return true; return true;
} }
} else {
if (!frappe.isServer) {
if (doc[field.fieldname] == null) { if (doc[field.fieldname] == null) {
return true; return true;
} }