ERPNext Foundation ERPNext Cloud User Manual Blog Discuss Frappé* Donate

About ERPNext mobile app,Can I call the function of the cordova plugin in doctype.js?


This is a requirement that needs to be implemented on an Android phone.
I need to use the abc.js function under Doctype to call the scan code plug-in function in cordova to scan the QR code. Is it feasible?
Thank you.


I tested successfully.
1.frappe/public/js/frappe/desk.js +447 (example: redirect_to_login), Add “mobile_to_scanner: function() {},”
2. The js file under Doctype:
var test =;
3.erpnext mobile app, mobile-master/www/js/desk.js +90 (eg: redirect_to_login) = function() {
//cordova code
return “”;