Item volume field in Sales Order and Delivery Note

52 views
Skip to first unread message

lxnow

unread,
Jul 3, 2013, 12:50:14 AM7/3/13
to erpnext-dev...@googlegroups.com
Hi everyone

We want to be able to compute and display the TOTAL volume in cubic meters of a sales order on the sales order form. We want to show both the volume per sales order line item, and for the total order.

We currently use a workaround by using the price field for this, but this has two drawbacks:

1) We can't use the price field anymore to display price, which we realize we want as well
2) The small fractional values of our item volumes creates quantity errors when pulling data (bug submitted to erpnext team)

I realize I may need to create custom fields and custom scripts in order to
get to a separate
  • VOLUME field
  • VOLUME*QUANTITY field
  • SUM(VOLUME*QUANTITY from line order 1 to line X)

I found this (https://gist.github.com/rmehta/3866677) but not sure how to implement for my needs.

I'm not sure which form to assign the script, and how to modify the script to allow for an indefinite number of fields to get to the final grand total volume for one particular sales order form.

Maybe someone has done something similar? Hope someone can point me in the right direction.

Thanks.

Nabin Hait

unread,
Jul 3, 2013, 2:11:45 AM7/3/13
to erpnext-dev...@googlegroups.com

For those fields you should create custom fields for all sales transactions.


Then for calculation, you have to write some custom script for doctype "Sales Common". To get started, you can look into following link:

https://github.com/webnotes/wnframework/wiki/Client-side-scripting#Calculate Incentive in Sales Team table based on some custom logic

lxnow

unread,
Jul 3, 2013, 7:11:29 AM7/3/13
to erpnext-dev...@googlegroups.com
Thanks. I'm not a programmer -- do you know what language erpnext language uses so I can read up on the syntax?

lxnow

unread,
Jul 3, 2013, 7:12:14 AM7/3/13
to erpnext-dev...@googlegroups.com
Sorry just to add if anyone is reading this who might be interested in freelancing to write these scripts... please ping me!
Reply all
Reply to author
Forward
0 new messages