Jump to content
jhilgeman

NEW! Complete Order Editing Tool!

Recommended Posts

Hi there

 

have installed this contrib on 2.3.1 with a few others and for the most seems to work ok, i have a problem though when new order email is clicked i get the error

Fatal error: Call to undefined function tep_add_base_ref() in XXX/XXX/XXX/admin/edit_orders_ajax.php on line 1144

 

I have looked through previous posts and see this has been mentioned a few times but couldnt see a fix mentioned.

 

any help appriciated

 

thank you

 

David


David

Share this post


Link to post
Share on other sites

Adding this in 2.3.1 with this version 1.1 ( http://addons.oscommerce.com/info/7844/v,23 )

 

I also have the warning about the headers. (Warning: Cannot modify header information - headers already sent by (output started at /home/virtual/site7/fst/var/www/html/shop/admin/includes/template_top.php:14) in /home/virtual/site7/fst/var/www/html/shop/admin/includes/functions/general.php on line 34)

 

I looked in template_top for blank spaces on wrong places, altered the line 14 in the same way this was done in de template_top for the catalog but nothing works. So can somebody please tell me how I can get rid of it?

 

 

<?php
/*
 $Id$

 osCommerce, Open Source E-Commerce Solutions
 http://www.oscommerce.com

 Copyright (c) 2010 osCommerce

 Released under the GNU General Public License
*/
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html <?php echo HTML_PARAMS; ?>>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>">
<meta name="robots" content="noindex,nofollow">
<title><?php echo TITLE; ?></title>
<base href="<?php echo HTTP_SERVER . DIR_WS_ADMIN; ?>" />
<!--[if IE]><script type="text/javascript" src="<?php echo tep_catalog_href_link('ext/flot/excanvas.min.js'); ?>"></script><![endif]-->
<link rel="stylesheet" type="text/css" href="<?php echo tep_catalog_href_link('ext/jquery/ui/redmond/jquery-ui-1.8.6.css'); ?>">
<script type="text/javascript" src="<?php echo tep_catalog_href_link('ext/jquery/jquery-1.4.2.min.js'); ?>"></script>
<script type="text/javascript" src="<?php echo tep_catalog_href_link('ext/jquery/ui/jquery-ui-1.8.6.min.js'); ?>"></script>

<?php
 if (tep_not_null(JQUERY_DATEPICKER_I18N_CODE)) {
?>
<script type="text/javascript" src="<?php echo tep_catalog_href_link('ext/jquery/ui/i18n/jquery.ui.datepicker-' . JQUERY_DATEPICKER_I18N_CODE . '.js'); ?>"></script>
<script type="text/javascript">
$.datepicker.setDefaults($.datepicker.regional['<?php echo JQUERY_DATEPICKER_I18N_CODE; ?>']);
</script>
<?php
 }
?>

<script type="text/javascript" src="<?php echo tep_catalog_href_link('ext/flot/jquery.flot.js'); ?>"></script>
<link rel="stylesheet" type="text/css" href="includes/stylesheet.css">
<script type="text/javascript" src="includes/general.js"></script>
</head>
<body>

<?php require(DIR_WS_INCLUDES . 'header.php'); ?>

<?php
 if (tep_session_is_registered('admin')) {
   include(DIR_WS_INCLUDES . 'column_left.php');
 } else {
?>

<style>
#contentText {
 margin-left: 0;
}
</style>

<?php
 }
?>

<div id="contentText">

 

 

Move "require(DIR_WS_INCLUDES . 'template_top.php');" After

 

  $currency_query = tep_db_query("select distinct title, code from " . TABLE_CURRENCIES . " order by code ASC");  
 $currency_array = array();
 while($currency = tep_db_fetch_array($currency_query)) {
   $currency_array[] = array('id' => $currency['code'],
                             'text' => $currency['code'] . ' - ' . $currency['title']);
 }

Share this post


Link to post
Share on other sites

Move "require(DIR_WS_INCLUDES . 'template_top.php');" After

 

  $currency_query = tep_db_query("select distinct title, code from " . TABLE_CURRENCIES . " order by code ASC");  
 $currency_array = array();
 while($currency = tep_db_fetch_array($currency_query)) {
   $currency_array[] = array('id' => $currency['code'],
                             'text' => $currency['code'] . ' - ' . $currency['title']);
 }

 

Changed this in edit_orders.php and it worked for me as i was having same problem, thanks woots_p

 

Regards

 

david


David

Share this post


Link to post
Share on other sites

I installed version 1.1 for osC 2.3.1 and all seemed well, but I realized I had forgotten to run the SQL scripts. So I did that and now the "Update" button no longer shows up. The entire Order Edit page is there with all of the information and options, but I can't actually edit anything because there is no "Update" button to click.

 

Anyone have an idea of what happened?

Share this post


Link to post
Share on other sites

Telling it not to use AJAX brought the Update button back, but now when I click the button I get a blank page. The menus on the side are there, and I have to click on "Customers", then "Orders" to get back where I was. There is a "Success" message at the top and the new information is correct, but why does it not just update the page instead of going off somewhere else? And why would it not work right using AJAX even though I have Javascript on? This isn't a big deal as long as it works, but it is annoying.

 

Anybody know how to fix it?

Share this post


Link to post
Share on other sites

Hi,

 

Just to drop in, just installed the latest 1.1 version op an 2.3.1 install and all i get is an Blank page when i press "Edit" seems it cannot find it?

Very strange, all files are there, did the sql update, reviewed the options, all new files are in place...

Even tried it with the new fix and with option off and on..

 

Triple checked the adjusted files, but everything is okay..

Still an blank 501 page..

 

Hope someone can help me out :)

Edited by demz

Share this post


Link to post
Share on other sites

Hi there

 

I have installed 5_0_9b on 2.2 RCa and all appears to be working except the new order email gets delivered blank also there is no pdf attachement, have toggled swicth in admin>pdf invoices and mime / html . i see this question has been asked a couple of times but no answer.

 

I have seen a number of comments about various additions to this contrib that are not supported, shoudld i roll back to a previous version for the contrib (i thought 5-0-9b0 looked like the latest full one), if so what is the proper one to install?

 

Thank you

 

David


David

Share this post


Link to post
Share on other sites

I have modified the shop, so I have 2 buttons for order confirmation -- with or without editing. My customers usually like to have modifications, and I hope that the order-edit shall limit on the e-mails. If the order is OK or not, don't matter much for invoice, or advance payment orders, as I can make an invoice on paper and send to the customer. It DO matter for Pay-pal. I have found that the paypal paypal_standard.php function before_process() actually hi-jack the shop, and process the order itself. I can easily block this, as I have kind-a fixed processing in a separate file, while the checkout_process.php handle orders that are OK; the normal way.

 

What is needed now, is a button in the order-edit, or on the customer-view-orders, or a link that is sent in the e-mail, or whatever --

I need to open the order, crate a shopping cart, and then send it to "paypal_standard.php function before_process()" for processing and communication with pay-pal.

 

That would just be super-cool. I run 2.2 ....rc2 I think; and I have much to many hacks to consider any upgrading.

If the edited order can be moved back into the shopping cart, this have many uses. It would also, in good weather, work with many payment modules.

 

I don't have any php editor/debugger, and I don't have any local machine for software testing.

Edited by TRNG98

Share this post


Link to post
Share on other sites

Does this mod work with 2.3.1? Please let me know...and can you add different areas maybe a "retail price" and "discount" section... etc?

Share this post


Link to post
Share on other sites

Hello,

 

All seems to be working fine. Was wondering is there away to have the order tool not add a product if inventory is zero, or some how when adding products, it show quanity level?

 

Thanks Jr

Share this post


Link to post
Share on other sites

hi

 

i have installed track and trace contribution 3736 in this contribution

 

the problem is if i use the non-ajax version it works well

 

in the ajax version it is working except for the part where i want to save the data for the table order_history

 

the filled in $track_num and $track_pcode are not stored

 

 

the code i use in admin/edit_orders_ajax.php is :

//SADESA ORDER TRACKING

// tep_db_query("INSERT into " . TABLE_ORDERS_STATUS_HISTORY . " (orders_id, orders_status_id, date_added, customer_notified, comments) values

// ('" . tep_db_input($_GET['oID']) . "',

// '" . tep_db_input($_GET['status']) . "',

// now(), " .

// tep_db_input($customer_notified) . ", '" .

// oe_iconv($_GET['comments']) . "')");

 

tep_db_query("INSERT into " . TABLE_ORDERS_STATUS_HISTORY . " (orders_id, orders_status_id, date_added, customer_notified, track_num, track_pcode, comments) values

('" . tep_db_input($_GET['oID']) . "', '" .

tep_db_input($_GET['status']) . "',

now(), " .

tep_db_input($customer_notified) . ", '" .

tep_db_input($_GET['track_num'])) . "', '" .

tep_db_input($_GET['track_pcode']) . "', '" .

oe_iconv($_GET['comments']) . "')");

//SADESA ORDER TRACKING

 

 

the code used in admin/edit_orders.php is

//SADESA ORDER TRACKING

// tep_db_query("INSERT into " . TABLE_ORDERS_STATUS_HISTORY . " (orders_id, orders_status_id, date_added, customer_notified, comments) values ('" . tep_db_input($_GET['oID']) . "', '" . tep_db_input($_POST['status']) . "',

// now(), " . tep_db_input($customer_notified) . ", '" . tep_db_input(tep_db_prepare_input($_POST['comments'])) . "')");

tep_db_query("INSERT into " . TABLE_ORDERS_STATUS_HISTORY . " (orders_id, orders_status_id, date_added, customer_notified, track_num, track_pcode, comments) values

('" . tep_db_input($_GET['oID']) . "', '" . tep_db_input($_POST['status']) . "', now(), " . tep_db_input($customer_notified) . ", '" .

tep_db_input(tep_db_prepare_input($_POST['track_num'])) . "', '" . tep_db_input(tep_db_prepare_input($_POST['track_pcode'])) . "', '" . tep_db_input(tep_db_prepare_input($_POST['comments'])) . "')");

//SADESA ORDER TRACKING

 

 

 

in the file edit_orders_ajax.php i already changed $_get with $http_get_vars etc but no luck

 

greetings eric

Share this post


Link to post
Share on other sites

Wonder if someone can help with this.

 

I have 2.3.1 installed with latest version of order editor and it seems that when i edit an order the colons go missing from the end of the order total titles.

 

It isnt a big issue, but annoying nonetheless.

 

If the customer places the order through the website they appear fine, but if I enter the order in the admin area they arent there. the only exception to this is the VAT line. The sub-total lines and total lines are missing the colon however.

 

The shipping line updates to include the colon if I click it on the left hand selection.

 

I cant seem to find where the colon comes from at the moment (still digging), can anyone help please?

 

Tony

Share this post


Link to post
Share on other sites

Hi!

 

I have installed Order Editor 5.0.9c and I have the following problem.

When I enter to the EDIT ORDER page, if the billin or shipping country address is the "default country address" of the shopping cart, it shows ok. But if the user has choosed other country, I always see "AFHGANISTAN"... Whan can I do?

Thanks!!!

Francisco

 

 

Hi,

 

I have the same problem.

Does anyone know the solution.

 

Yours

Plustm

Share this post


Link to post
Share on other sites

Hi, when I modify the order and try to send the new order clicking the button "new order mail", nothing happens and appear this message:

 

1146 - Table 'chucho_osc1.eorder_text' doesn't exist

 

SELECT * FROM eorder_text where eorder_text_id = '1' and language_id = '2'

 

¿What i need to do to fix this and send mails with the correct orders to my customers?

Share this post


Link to post
Share on other sites

Hi

 

I have installed the contrib "order_editor_5_0_9b". If i use the orders.php from this contrib, it will displayed this message

 

Fatal error: Call to undefined function tep_hide_session_id() in /home/www/web255/html/stempelgarten/shop/catalog/admin/orders.php on line 338

 

the line 338 is: <?php echo tep_hide_session_id(); ?></form></tr>

 

so, where is the bug? with the original orders.php, the shop will function normaly, but without the possibility of manual changes of orders.

 

greetz

Daniel

Share this post


Link to post
Share on other sites

Hello I installed "Order Editor 5.0.9c". I can't update my order when ajax is activated (the order is showing up but nothing is happening when I change something). When it is off it works.

I tested my browser on an other site and ajax worked, so Iguess it is not comming from my browser.

If someone could give me an advice where to look, would be very nice.

Thank you

Regards

Share this post


Link to post
Share on other sites

I've installed it in the past and have updated as well, but I am not able to change discount codes. If, for example, I have a 20 percent discount on the total purchase, and I edit an order and add a few more items, the discount stays the same as the original. Nor do I have the option of deleting a coupon/discount used.

 

Am I missing something?

Share this post


Link to post
Share on other sites

Hi

 

Has anyone an idea, for my problem in post 3224?

 

I have edit the line 1003 in "edit_orders_ajax.php"

 

if ( FILENAME_EMAIL_ORDER_TEXT !== FILENAME_EMAIL_ORDER_TEXT ){

 

But now, the problem is, that i add a product, the following error displays:

 

1054 - Unknown column 'products_stock_attributes' in 'field list'

 

SELECT products_id, products_quantity, products_stock_attributes FROM orders_products WHERE orders_id = '4340' AND orders_products_id = '38684'

 

[TEP STOP]

 

when i delete a product, the following error displays:

 

1054 - Unknown column 'products_stock_attributes' in 'field list'

 

SELECT products_id, products_quantity, products_stock_attributes FROM orders_products WHERE orders_id = '4340' AND orders_products_id = '38766'

 

[TEP STOP]

 

wurde aktualisiert

Where is the problem in the code? Or is there a problem with rights on the server?

 

 

greetz

Daniel

Share this post


Link to post
Share on other sites

Hi

Been using this contribution successfully for some time but have an issue that I wonder if any one else has spotted and solved.

Basically if I create a negative value product (to create a refund for a customer), then the tax row dissappears from the order totals section. The tax is being calculated, my sub-total and total are different by the right amount, but the tax value is no longer separately shown. Make the value positive and it comes back.

I really want to use negative values so that other reporting tools in oscommerce don't perceive a refund as extra income, rather it is money lost and the maths on that should be straight forward enough so long as I can successfully post negative value order. I even have code that writes "Credit" instead of "Invoice" on the invoices if the total is detected as negative. Just need the tax to show on a separate line!

Thanks

J

Share this post


Link to post
Share on other sites

Hi,

 

I have server error when I add RusNNs' update for QT Pro which relates to his update for qtpro

 

This section causes a 500 server error

 

REPLACE WITH

	if (ORDER_EDITOR_USE_QTPRO == 'true') {
	  if (isset($_POST['add_product_options'])) {
		foreach($_POST['add_product_options'] as $option_id => $option_value_id) {
			$products_stock_attributes[] = $option_id . '-'. $option_value_id;
		} // for loop
		sort($products_stock_attributes, SORT_NUMERIC); // Same sort as QT Pro stock
		$products_stock_attributes = implode($products_stock_attributes, ',');
	  }
	}

	$sql_data_array = array('orders_id' => tep_db_prepare_input($oID),
							'products_id' => tep_db_prepare_input($add_product_products_id),
							'products_model' => tep_db_prepare_input($product['products_model']),
							'products_name' => tep_db_prepare_input($product['products_name']),
							'products_price' => tep_db_prepare_input($product['products_price']),
							'final_price' => tep_db_prepare_input(($product['products_price'] + $AddedOptionsPrice)),
							'products_tax' => tep_db_prepare_input($products_tax),
							'products_quantity' => tep_db_prepare_input($_POST['add_product_quantity']),
							'products_stock_attributes' => tep_db_prepare_input($products_stock_attributes));
	tep_db_perform(TABLE_ORDERS_PRODUCTS, $sql_data_array);

 

The first section causes the issue.

 

Any ideas?

 

Thanks

 

Dave

Edited by stubbsy

Share this post


Link to post
Share on other sites

First of great tool,

 

Some bugs/areas of improvement I noticed.

 

I have installed version 5.09c + patch

- If I edit an order which has shipping but falls in the free shipping range the complete shipping entry is removed after an update and if I add it later it will appear after the total (so I manually have to set it straight in the database).

- If I want to remove a product from the order it takes very long to update (5min), if i refresh in the meanwhile the order is not updated. (same goes for altering the amount of ordered products, if I change the price it is updated instantly)

Edited by Sickboards

Share this post


Link to post
Share on other sites

I'm having problem with downloadable products. When I add this kind of product, the system include only one item referring to the group name and nothing else. Also the link does not work. Could anyone help me? Thank you.

Edited by rdbello

Share this post


Link to post
Share on other sites

Hi,

 

Great contribution and works perfect for me... almost.

 

Does anyone know of a way of showing the number of items in stock when adding a product from the drop down. Would make my life easier rather than looking up my stock on the site?

 

Thanks.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×