2018-09-07 10:10:39 +00:00
|
|
|
const title = 'Sales Register';
|
|
|
|
module.exports = {
|
|
|
|
title: title,
|
|
|
|
method: 'sales-register',
|
|
|
|
filterFields: [
|
2019-08-01 11:52:58 +00:00
|
|
|
{
|
|
|
|
fieldtype: 'Link',
|
|
|
|
target: 'Party',
|
|
|
|
label: 'Customer Name',
|
|
|
|
fieldname: 'customer',
|
|
|
|
getFilters: query => {
|
|
|
|
if (query)
|
|
|
|
return {
|
|
|
|
keywords: ['like', query],
|
|
|
|
customer: 1
|
|
|
|
};
|
|
|
|
|
|
|
|
return {
|
|
|
|
customer: 1
|
|
|
|
};
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
fieldtype: 'Date',
|
|
|
|
fieldname: 'fromDate',
|
|
|
|
label: 'From Date',
|
|
|
|
required: 1
|
|
|
|
},
|
2018-09-07 10:10:39 +00:00
|
|
|
{ fieldtype: 'Date', fieldname: 'toDate', label: 'To Date', required: 1 }
|
|
|
|
],
|
|
|
|
getColumns() {
|
|
|
|
return [
|
2019-08-01 11:52:58 +00:00
|
|
|
{ label: 'SalesInvoice', fieldname: 'name' },
|
|
|
|
{ label: 'Posting Date', fieldname: 'date', fieldtype: 'Date' },
|
2018-09-07 10:10:39 +00:00
|
|
|
{ label: 'Customer', fieldname: 'customer' },
|
|
|
|
{ label: 'Receivable Account', fieldname: 'account' },
|
|
|
|
{ label: 'Net Total', fieldname: 'netTotal', fieldtype: 'Currency' },
|
|
|
|
{ label: 'Total Tax', fieldname: 'totalTax', fieldtype: 'Currency' },
|
2019-08-01 11:52:58 +00:00
|
|
|
{ label: 'Grand Total', fieldname: 'grandTotal', fieldtype: 'Currency' }
|
2018-09-07 10:10:39 +00:00
|
|
|
];
|
|
|
|
}
|
|
|
|
};
|