X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=sales%2Fincludes%2Fsales_ui.inc;h=73b99ca610bcd6925f1f5782a706a8e245643c51;hb=615c63fbc4aea4d0e136e868993e71190aacadd2;hp=7e7f7afd195aeffd4e0b5e0729443a00295cfe0d;hpb=d567a10b7925c8bb97c734e213d6651a979af29d;p=fa-stable.git diff --git a/sales/includes/sales_ui.inc b/sales/includes/sales_ui.inc index 7e7f7afd..73b99ca6 100644 --- a/sales/includes/sales_ui.inc +++ b/sales/includes/sales_ui.inc @@ -19,12 +19,14 @@ include_once($path_to_root . "/includes/banking.inc"); // function processing_start() { + page_processing(false); processing_end(); $_SESSION['Processing'] = $_SERVER['PHP_SELF']; } function processing_end() { + page_processing(true); unset($_SESSION['Processing']); if ( isset($_SESSION['Items']) ) { unset($_SESSION['Items']->line_items); @@ -40,15 +42,14 @@ function processing_active() Check if the cart was not destroyed during opening the edition page in another browser tab. */ -function check_edit_conflicts($cartname='Items') +function check_edit_conflicts($cart_id, $cartname='Items') { - global $Ajax; - - if (isset($_POST['cart_id']) && $_POST['cart_id'] != $_SESSION[$cartname]->cart_id) { + global $Ajax, $SysPrefs; + + if ((!isset($SysPrefs->no_check_edit_conflicts) || $SysPrefs->no_check_edit_conflicts==0) && get_post('cart_id') && $cart_id != $_SESSION[$cartname]->cart_id) { display_error(_('This edit session has been abandoned by opening sales document in another browser tab. You cannot edit more than one sales document at once.')); $Ajax->activate('_page_body'); display_footer_exit(); } } -?> \ No newline at end of file