How to get Default Price List in Script Report?

9 views
Skip to first unread message

Aditya Duggal

unread,
Mar 20, 2014, 3:27:26 AM3/20/14
to erpnext-dev...@googlegroups.com
Hi,

I have a field in a custom report which is a link field with Price List. I would like to automatically fill this field with the Default Price list mentioned in the Selling Settings but I am unable to achieve the same, kindly advice on the correct syntax for the same in JS file of the script report.

wn.query_reports["Price List"] = {
"filters": [
{
"fieldname":"price_list",
"label": "Price List",
"fieldtype": "Link",
"options": "Price List"
"default": wn.defaults.get_user_default("price_list")
}


Another thing I have noticed which seems kind of wrong is that the Price List table is under the stock module whereas price list settings, like setting the default price list is under the selling settings. I guess there is a disconnect and it might confuse the new users a bit and maybe the price list could be moved to the selling module if it does not create a lot of problem for the users.
Reply all
Reply to author
Forward
0 new messages