2
0
mirror of https://github.com/frappe/books.git synced 2024-11-10 07:40:55 +00:00
books/client/view/index.js
2018-02-20 12:09:41 +05:30

12 lines
404 B
JavaScript

const BaseList = require('frappejs/client/view/list');
const BaseForm = require('frappejs/client/view/form');
const frappe = require('frappejs');
module.exports = {
getFormClass(doctype) {
return (frappe.views['Form'] && frappe.views['Form'][doctype]) || BaseForm;
},
getListClass(doctype) {
return (frappe.views['List'] && frappe.views['List'][doctype]) || BaseList;
}
}