hi all,
I am having a prob with getting the logic straight on the processing of a couple hidden fields.
a table is holding a portfolio of products bought at diff points in time.
upon selling them - partially - FIFO (first in first out) is to be employed upon booking them out so that after the first sales the table for a single product should look as depicted in img1
on the submission form fields cf_id, cp, cp_ids, cp_quantities are hidden fields
Field cp is boulian and indicates if the respective posisiton is a closing position or not
Upon saving the only sales not only should db save create dataset 6 but it should also split the sales quantity (750) amongst the oldest purchases (highlightest in pink)
With several sales the above table might then look as depicted in img2
Only how am I to get fields cp_ids and cp_quantities filled? I am struggling with getting the logic sorted.
Could somebody pls help?
J!2.5.9; CF4.0 RC3.5.2
I am having a prob with getting the logic straight on the processing of a couple hidden fields.
a table is holding a portfolio of products bought at diff points in time.
upon selling them - partially - FIFO (first in first out) is to be employed upon booking them out so that after the first sales the table for a single product should look as depicted in img1
on the submission form fields cf_id, cp, cp_ids, cp_quantities are hidden fields
Field cp is boulian and indicates if the respective posisiton is a closing position or not
Upon saving the only sales not only should db save create dataset 6 but it should also split the sales quantity (750) amongst the oldest purchases (highlightest in pink)
With several sales the above table might then look as depicted in img2
Only how am I to get fields cp_ids and cp_quantities filled? I am struggling with getting the logic sorted.
Could somebody pls help?
J!2.5.9; CF4.0 RC3.5.2