diff --git a/buying/doctype/purchase_order/purchase_order.js b/buying/doctype/purchase_order/purchase_order.js index 9967f15a50..d35072d09e 100644 --- a/buying/doctype/purchase_order/purchase_order.js +++ b/buying/doctype/purchase_order/purchase_order.js @@ -24,7 +24,7 @@ erpnext.buying.PurchaseOrderController = erpnext.buying.BuyingController.extend( doc.per_billed); - cur_frm.add_custom_button('Send SMS', cur_frm.cscript['Send SMS']); + cur_frm.add_custom_button('Send SMS', cur_frm.cscript.send_sms); if(flt(doc.per_received, 2) < 100) cur_frm.add_custom_button('Make Purchase Receipt', this.make_purchase_receipt); if(flt(doc.per_billed, 2) < 100) diff --git a/stock/doctype/purchase_receipt/purchase_receipt.js b/stock/doctype/purchase_receipt/purchase_receipt.js index 5333c21be0..9f9aa15de1 100644 --- a/stock/doctype/purchase_receipt/purchase_receipt.js +++ b/stock/doctype/purchase_receipt/purchase_receipt.js @@ -20,7 +20,7 @@ erpnext.stock.PurchaseReceiptController = erpnext.buying.BuyingController.extend cur_frm.add_custom_button('Make Purchase Invoice', this.make_purchase_invoice); } - cur_frm.add_custom_button('Send SMS', cur_frm.cscript['Send SMS']); + cur_frm.add_custom_button('Send SMS', cur_frm.cscript.send_sms); this.show_stock_ledger(); this.show_general_ledger();