X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=includes%2Forder_lines.inc;h=9366ecb97779182e80973b2bc9c7413cbfed6d90;hb=25a5b3f1d11f626d4d20033f0c942d71beb3abf5;hp=e8d161224d3e21a135abf973441c58df0a79a35d;hpb=b1db75caf17ed70df2de54711fe98c4e5f989bfe;p=order_line_extra.git diff --git a/includes/order_lines.inc b/includes/order_lines.inc index e8d1612..9366ecb 100644 --- a/includes/order_lines.inc +++ b/includes/order_lines.inc @@ -28,7 +28,6 @@ print_r('cacou'); } } - function update_extra_order_details() { if(!isset($_POST['Update']) || $_POST['Update'] != 'Update') return; @@ -68,6 +67,14 @@ commit_transaction(); } +function split_order_details() { + if(!isset($_POST['Split']) || $_POST['Split'] != 'Split') return; + $splitter = new Splitter($_POST); + begin_transaction(); + if($splitter->splitAll()) display_warning("Items have been split."); + commit_transaction(); +} + function compute_input_name($row, $field) { $row_id = $row['id']; return "detail[$row_id][$field]";