Guest Posted March 23, 2007 Share Posted March 23, 2007 is this possible, or does a contribution currently exist for this? i have a table in my ORDERS table called 'products_stock_detail' i want to be able to hit a button on the order details (history view in admin) to add a Y or N (depending if the item is instock or not) that's it. i cannot, for the life of me, figure out how to add a button to this page that would be saved whenever i hit "update" on the comment box in the admin panel for the specific order i'm viewing (i.e. i don't want a separate module, but for this to be updated only when i change the status of the order or add order comments) Link to comment Share on other sites More sharing options...
Guest Posted March 24, 2007 Share Posted March 24, 2007 sorry, i suppose this would have made more said if i'd used the word "checkbox" instead of button on the order history page ;) Link to comment Share on other sites More sharing options...
Guest Posted March 25, 2007 Share Posted March 25, 2007 this is what i've got and so far, nothing happens. no errors... can anyone spot the bugs in my code? in admin/orders.php i have: if (isset($HTTP_POST_VARS['products_stock_detail'])) { tep_db_query("update " . TABLE_ORDERS_PRODUCTS . " set products_stock_detail = '1' where orders_id = '" . (int)$this_orderID . "' and products_name = '.$order->products[$i]['name'].'"); } beneath $order_updated = false; and <input name="products_stock_detail" type="checkbox" value="1"> beneath ' . $order->products[$i]['qty'] . ' x all of the proper tables have been added to the database properly and i can pull the results.. just can't edit them Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.