-editor_redirect( array(
- 'customer_id' => $path_to_root.'/sales/manage/customers.php?debtor_no='.get_post('customer_id'),
- 'branch_id' => $path_to_root.'/sales/manage/customer_branches.php?branch_id='.get_post('branch_id'),
- ));
+set_page_security( @$_SESSION['Items']->trans_type,
+ array( ST_SALESORDER=>'SA_SALESORDER',
+ ST_SALESQUOTE => 'SA_SALESQUOTE',
+ ST_CUSTDELIVERY => 'SA_SALESDELIVERY',
+ ST_SALESINVOICE => 'SA_SALESINVOICE'),
+ array( 'NewOrder' => 'SA_SALESORDER',
+ 'ModifyOrderNumber' => 'SA_SALESORDER',
+ 'AddedID' => 'SA_SALESORDER',
+ 'UpdatedID' => 'SA_SALESORDER',
+ 'NewQuotation' => 'SA_SALESQUOTE',
+ 'ModifyQuotationNumber' => 'SA_SALESQUOTE',
+ 'NewQuoteToSalesOrder' => 'SA_SALESQUOTE',
+ 'AddedQU' => 'SA_SALESQUOTE',
+ 'UpdatedQU' => 'SA_SALESQUOTE',
+ 'NewDelivery' => 'SA_SALESDELIVERY',
+ 'AddedDN' => 'SA_SALESDELIVERY',
+ 'NewInvoice' => 'SA_SALESINVOICE',
+ 'AddedDI' => 'SA_SALESINVOICE'
+ )
+);