Fixed nested forms in Items tab.
authorJoe <unknown>
Thu, 27 Jun 2013 20:59:32 +0000 (22:59 +0200)
committerJoe <unknown>
Thu, 27 Jun 2013 20:59:32 +0000 (22:59 +0200)
inventory/cost_update.php
inventory/prices.php
inventory/purchasing_data.php
inventory/reorder_level.php

index 3afe0b6412e26c6d15389a2850b521c23ff902a1..75f04a0e055fd833c4fd63c5d367d613c28b2fb3 100644 (file)
@@ -84,10 +84,8 @@ if (list_updated('stock_id'))
        $Ajax->activate('cost_table');
 //-----------------------------------------------------------------------------------------
 
-$action = $_SERVER['PHP_SELF'];
-if (@$_GET['popup'])
-       $action .= "?stock_id=".get_post('stock_id');
-start_form(false, false, $action);
+if (!@$_GET['popup'])
+       start_form();
 
 if (!isset($_POST['stock_id']))
        $_POST['stock_id'] = get_global_stock_item();
@@ -137,8 +135,9 @@ end_table(1);
 div_end();
 submit_center('UpdateData', _("Update"), true, false, 'default');
 
-end_form();
 if (!@$_GET['popup'])
+{
+       end_form();
        end_page(@$_GET['popup'], false, false);
-
+}
 ?>
index f1c63c40b2b9a52f273a4f84e5495586754678d1..66d3bee099482041a449b56a27ddec6f9c900918 100644 (file)
@@ -50,11 +50,8 @@ if (!isset($_POST['curr_abrev']))
 }
 
 //---------------------------------------------------------------------------------------------------
-
-$action = $_SERVER['PHP_SELF'];
-if (@$_GET['popup'])
-       $action .= "?stock_id=".get_post('stock_id');
-start_form(false, false, $action);
+if (!@$_GET['popup'])
+       start_form();
 
 if (!isset($_POST['stock_id']))
        $_POST['stock_id'] = get_global_stock_item();
@@ -211,7 +208,9 @@ if ($calculated)
 submit_add_or_update_center($selected_id == -1, '', 'both');
 div_end();
 
-end_form();
 if (!@$_GET['popup'])
+{
+       end_form();
        end_page(@$_GET['popup'], false, false);
+}      
 ?>
index 1b4602ee785887b11ae5885e84183d502127a41d..d0b1685d8f5e0acbb5134d660aa2468532dab29b 100644 (file)
@@ -106,10 +106,8 @@ if (list_updated('stock_id'))
        $Ajax->activate('price_table');
 //--------------------------------------------------------------------------------------------------
 
-$action = $_SERVER['PHP_SELF'];
-if (@$_GET['popup'])
-       $action .= "?stock_id=".get_post('stock_id');
-start_form(false, false, $action);
+if (!@$_GET['popup'])
+       start_form();
 
 if (!isset($_POST['stock_id']))
        $_POST['stock_id'] = get_global_stock_item();
@@ -229,8 +227,9 @@ end_table(1);
 
 submit_add_or_update_center($selected_id == -1, '', 'both');
 
-end_form();
 if (!@$_GET['popup'])
+{
+       end_form();
        end_page(@$_GET['popup'], false, false);
-
+}
 ?>
index c863796a6ece9fbff25b16f9a78f59de59e6b56f..bd517f251221a18e5a762835ad5c2177c36bc665 100644 (file)
@@ -37,11 +37,8 @@ if (list_updated('stock_id'))
        $Ajax->activate('reorders');
 }
 //------------------------------------------------------------------------------------
-
-$action = $_SERVER['PHP_SELF'];
-if (@$_GET['popup'])
-       $action .= "?stock_id=".get_post('stock_id');
-start_form(false, false, $action);
+if (!@$_GET['popup'])
+       start_form();
 
 if (!isset($_POST['stock_id']))
        $_POST['stock_id'] = get_global_stock_item();
@@ -113,8 +110,9 @@ end_table(1);
 div_end();
 submit_center('UpdateData', _("Update"), true, false, 'default');
 
-end_form();
 if (!@$_GET['popup'])
+{
+       end_form();
        end_page(@$_GET['popup'], false, false);
-
+}
 ?>