webERP Forum

Full Version: Sales Order Item Import
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi is there anyway to import the items for a sales order from a .csv We have up to 100 items per sales order and what to speed up the process. We use the quick entry but its still takes to much time. Thank you in advance.
The solution might depend on whether the import is one-time, or if you will do it often. Do you expect, for example, 10 orders per day with 100 different items and quantities in each order?

Also, where does the CSV file come from? If this type of sales is something that will be done often, and the order already exists as data (the CSV file), then using the API programmatically might be the ideal solution.
There is no way currently ... would need additional code - would be a nice addition :-)


There are API methods to import orders ... and process into invoices too.
InsertSalesOrderHeader the repeated calls to InsertSalesOrderLine
Then InvoiceSalesOrder
(03-09-2017 02:40 AM)miguelitrojop Wrote: [ -> ]Hi is there anyway to import the items for a sales order from a .csv We have up to 100 items per sales order and what to speed up the process. We use the quick entry but its still takes to much time. Thank you in advance.

Hi Miguel,
It's actually quite easy. Attached is a new version of SelectOrderItems.php which offers you an option to upload a csv file for the order lines. the csv file should just contain 2 columns:

partcode,quantity

It needs some error checking adding in which I can do if this meets your needs. Please test it first

Tim
.
For those interested I attach the completed script

thanks
Tim
I've committed it for you
Thanks
Thanks Phil, shame about the stupid commit message though. The history of the project will now forever show you using the subversion commit messaging to pursue your personal vendettas. Childish Sad
>committed for Tim - not sure why he didnt commit it himself - improvment to selectorderitems.php to allow import of order line items from a CSV
As I said, a childish commit message, as I'm sure everyone agrees.

https://github.com/erlang/otp/wiki/Writi...t-messages

Says nothing about using a commit message to further a personal vendetta. As I have said to you many times Phil, if you want me to commit to your project you need to start by making a proper public apology for the campaign of lies you have waged against me.
(03-10-2017 09:41 PM)falkoner Wrote: [ -> ]For those interested I attach the completed script

thanks
Tim

Thank you for your answer that really helps me
Reference URL's