Topic: Insert rows between lines

Hi there,

When creating new or editing SO, DN, Quotation etc, I need to insert a new row between rows of items which I already entered.  This is because some customers required me to follow the exact sequence of their orders.   This happened often for some customers as their demands are changing very often. 

If there are 20 line items in the order and the customer make a change of their order by inserting a new line item say at row 2, I will have to delete the rows from 2 and below and re-enter everything after inserting the new line.

How do I modify the codes to allow a insertion of row in between rows?

Thanks.

/Mark

Re: Insert rows between lines

You could take the same approach for item insertion when modifying the code: make a copy of the cart, insert a new line, delete the cart items after the new line, then add the items after the new line from the cart copy.   This would be a nice feature to offer for inclusion into the base code.

Alternatively, you could avoid using the FA editor and instead enter orders as csv files and use the import transactions extension.  When a customer makes a change, void the entire order, and update the csv using a text editor and reimport.  However, I think this only currently supports sales orders and direct invoices and not quotations.

Because FA does not have line numbers on the order, you can also use a pdf editor to move stuff around to match the look of the customer's PO before you print.   For this purpose, I use Libreoffice Draw, which works quite well.

Re: Insert rows between lines

Changing the primary keys of the respective tables and re-ordering them is possible but must be done carefully or through a separate script / extension.

Re: Insert rows between lines

Braath Waate wrote:

You could take the same approach for item insertion when modifying the code: make a copy of the cart, insert a new line, delete the cart items after the new line, then add the items after the new line from the cart copy.   This would be a nice feature to offer for inclusion into the base code.

Alternatively, you could avoid using the FA editor and instead enter orders as csv files and use the import transactions extension.  When a customer makes a change, void the entire order, and update the csv using a text editor and reimport.  However, I think this only currently supports sales orders and direct invoices and not quotations.

Because FA does not have line numbers on the order, you can also use a pdf editor to move stuff around to match the look of the customer's PO before you print.   For this purpose, I use Libreoffice Draw, which works quite well.

Hi Braath,

I got what you mean.  I will look into it.

Thanks!

/Mark

Re: Insert rows between lines

apmuthu wrote:

Changing the primary keys of the respective tables and re-ordering them is possible but must be done carefully or through a separate script / extension.

Hi APMuthu,

Noted with thanks.

/Mark

Re: Insert rows between lines

Braath Waate wrote:

You could take the same approach for item insertion when modifying the code: make a copy of the cart, insert a new line, delete the cart items after the new line, then add the items after the new line from the cart copy.   This would be a nice feature to offer for inclusion into the base code.

Alternatively, you could avoid using the FA editor and instead enter orders as csv files and use the import transactions extension.  When a customer makes a change, void the entire order, and update the csv using a text editor and reimport.  However, I think this only currently supports sales orders and direct invoices and not quotations.

Because FA does not have line numbers on the order, you can also use a pdf editor to move stuff around to match the look of the customer's PO before you print.   For this purpose, I use Libreoffice Draw, which works quite well.

Hi Braath, APMuthu,

I ran through the functions of copy_to_cart(), function handle_new_item(), function handle_delete_item($line_no).   I am getting a bit frustrated when I try to construct something out on Sales Order Entry.  My idea is to add a "+" icon next to the pencil icon (edit) such that when I click on the "+" icon, it will add a line above it.  However, I got stuck after adding the "+" icon.  I can't add a new line above the current line and I do not know how to push the rest of the lines downward.  Would you be able to guide me with some codes or provide some simple function codes so that I could get things moving...?

Thanks...

/Mark